/* ============================================
   RESERVACANCHAS PRO - STYLES
   System de Reservas de Canchas Deportivas
   ============================================ */

/* ========== BASE STYLES ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
    min-height: 100vh;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #18181b;
}
::-webkit-scrollbar-thumb {
    background: #3f3f46;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #52525b;
}

/* Hide scrollbar for horizontal scroll */
.scrollbar-hide::-webkit-scrollbar {
    display: none;
}
.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* ========== NAVBAR ========== */
#navbar {
    background: rgba(24, 24, 27, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

#navbar.scrolled {
    background: rgba(24, 24, 27, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.nav-link {
    font-size: 0.875rem;
    color: #a1a1aa;
    transition: all 0.3s ease;
    position: relative;
    padding: 0.5rem 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(to right, #6366f1, #10b981);
    border-radius: 1px;
    transition: width 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* ========== HERO ========== */
.hero-bg {
    background-image: radial-gradient(circle at 1px 1px, rgba(255,255,255,0.03) 1px, transparent 0);
    background-size: 40px 40px;
}

.grid-pattern {
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
}

/* Floating Particles */
.particle {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    animation: float-particle linear infinite;
}

@keyframes float-particle {
    0% {
        transform: translateY(100vh) scale(0);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-10vh) scale(1);
        opacity: 0;
    }
}

/* Hero Animations */
.hero-badge {
    animation: hero-fade-in 0.8s ease-out 0.2s both;
}

.hero-title {
    animation: hero-slide-up 0.8s ease-out 0.4s both;
}

.hero-subtitle {
    animation: hero-slide-up 0.8s ease-out 0.6s both;
}

.hero-buttons {
    animation: hero-slide-up 0.8s ease-out 0.8s both;
}

.hero-stats {
    animation: hero-fade-in 1s ease-out 1.2s both;
}

@keyframes hero-fade-in {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes hero-slide-up {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Pulse Slow */
@keyframes pulse-slow {
    0%, 100% { opacity: 0.2; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(1.05); }
}

.animate-pulse-slow {
    animation: pulse-slow 4s ease-in-out infinite;
}

/* Scroll Dot */
@keyframes scroll-dot {
    0% { opacity: 1; transform: translateY(0); }
    50% { opacity: 0.5; transform: translateY(8px); }
    100% { opacity: 1; transform: translateY(0); }
}

.animate-scroll-dot {
    animation: scroll-dot 1.5s ease-in-out infinite;
}

.scroll-indicator {
    animation: hero-fade-in 1s ease-out 1.5s both;
}

/* ========== SEDE CARDS ========== */
.sede-card {
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.sede-card:hover {
    transform: translateY(-8px);
}

.sede-card:hover .sede-card-shine {
    opacity: 1;
    transform: translateX(100px);
}

/* ========== SLOT BUTTONS ========== */
.slot-btn {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid transparent;
}

.slot-btn .slot-ripple {
    transition: opacity 0.3s;
}

.slot-btn:active .slot-ripple {
    opacity: 0.3;
}

/* Available Slot */
.slot-available {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(16, 185, 129, 0.05));
    border-color: rgba(16, 185, 129, 0.25);
}

.slot-available:hover {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(16, 185, 129, 0.1));
    border-color: rgba(16, 185, 129, 0.5);
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.15);
}

.slot-available::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.1), transparent);
    animation: shimmer 3s infinite;
}

/* Occupied Slot */
.slot-occupied {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(239, 68, 68, 0.05));
    border-color: rgba(239, 68, 68, 0.25);
    cursor: pointer;
}

.slot-occupied:hover {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(239, 68, 68, 0.1));
    border-color: rgba(239, 68, 68, 0.5);
    box-shadow: 0 4px 20px rgba(239, 68, 68, 0.15);
}

/* Unavailable Slot */
.slot-unavailable {
    background: linear-gradient(135deg, rgba(113, 113, 122, 0.1), rgba(113, 113, 122, 0.05));
    border-color: rgba(113, 113, 122, 0.2);
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* Shimmer Animation */
@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* ========== MODALS ========== */
.modal-overlay {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: opacity 0.3s ease;
}

.modal-content {
    animation: modal-enter 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    transform-origin: center;
}

@keyframes modal-enter {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* ========== STEP CARDS ========== */
.step-card {
    position: relative;
}

.step-card::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 100%;
    width: 40px;
    height: 2px;
    background: linear-gradient(to right, rgba(99, 102, 241, 0.3), transparent);
    z-index: 0;
}

.step-card:last-child::before {
    display: none;
}

@media (max-width: 768px) {
    .step-card::before {
        display: none;
    }
}

/* ========== PAYMENT OPTIONS ========== */
.payment-option {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.payment-option:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
}

/* ========== FORM INPUTS ========== */
input:focus {
    animation: input-glow 0.3s ease;
}

@keyframes input-glow {
    from { box-shadow: none; }
    to { box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1); }
}

/* ========== COUNTER ANIMATION ========== */
.counter {
    display: inline-block;
    font-variant-numeric: tabular-nums;
}

/* ========== BOUNCE ONCE ========== */
@keyframes bounce-once {
    0%, 100% { transform: translateY(0); }
    30% { transform: translateY(-15px); }
    60% { transform: translateY(-7px); }
}

.animate-bounce-once {
    animation: bounce-once 0.8s ease-out;
}

/* ========== LINE CLAMP ========== */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ========== TOAST NOTIFICATION ========== */
.toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 200;
    background: rgba(24, 24, 27, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 12px 20px;
    color: white;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 8px;
    animation: toast-in 0.4s ease-out, toast-out 0.3s ease-in 2.7s forwards;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

@keyframes toast-in {
    from { opacity: 0; transform: translateY(20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes toast-out {
    from { opacity: 1; transform: translateY(0) scale(1); }
    to { opacity: 0; transform: translateY(20px) scale(0.95); }
}

/* ========== RESPONSIVE ========== */
@media (max-width: 640px) {
    .hero-title {
        font-size: 2.5rem;
        line-height: 1.1;
    }

    .hero-subtitle {
        font-size: 1rem;
    }
}

/* ========== LOADING SKELETON ========== */
.skeleton {
    background: linear-gradient(90deg,
        rgba(255, 255, 255, 0.03) 25%,
        rgba(255, 255, 255, 0.08) 50%,
        rgba(255, 255, 255, 0.03) 75%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: 8px;
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ========== GRADIENT TEXT ========== */
.gradient-text {
    background: linear-gradient(135deg, #6366f1, #10b981);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ========== CANCHA SECTION SEPARATOR ========== */
.cancha-section + .cancha-section {
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    padding-top: 2.5rem;
}

/* ========== CUSTOM TRANSITIONS ========== */
.transition-all {
    transition-property: all;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Focus visible for accessibility */
button:focus-visible,
a:focus-visible,
input:focus-visible {
    outline: 2px solid #6366f1;
    outline-offset: 2px;
}
