/*
==============================================
          THEME & COLOR DEFINITIONS
==============================================
*/

/* :root defines the default theme (VIP) */
:root {
    --bg-gradient: radial-gradient(ellipse at bottom, #1b2735 0%, #090a0f 100%);
    --surface-color: #1e1e1e;
    --text-color: #ffffff;
    --text-muted: #a0a0a0;
    --border-color: rgba(255, 255, 255, 0.1);
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.1);

    /* Accent colors for the default theme (VIP) */
    --accent-color: #f7b300;
    --accent-color-hover: #B98B12;
    --hero-gradient-start: rgba(165, 124, 16, 0.1);
}

/* Definition for the VIP theme (Gold) */
body.theme-vip {
    --accent-color: #f7b300;
    --accent-color-hover: #B98B12;
    --hero-gradient-start: rgba(165, 124, 16, 0.1);
}

/* We can also define the Volt theme on a body class for explicit switching */
body.theme-volt {
    --accent-color: #c1ff00;
    --accent-color-hover: #d4ff33;
    --hero-gradient-start: rgba(193, 255, 0, 0.05);
}

/* Definition for the Luxe theme (Light Gold) */
body.theme-luxe {
    --bg-color: #FDFBF5;
    --bg-gradient: var(--bg-color); /* Override gradient for light theme */
    --surface-color: #FBF8F0;
    --text-color: #1a1a1a;
    --text-muted: #555555;
    --border-color: rgba(0, 0, 0, 0.1);
    --glass-bg: #FBF8F0;
    --glass-border: rgba(0, 0, 0, 0.1);

    --accent-color: #A57C10;
    --accent-color-hover: #8F6A0D;
    --hero-gradient-start: rgba(165, 124, 16, 0.05);
}


/*
==============================================
                BASE STYLES
==============================================
*/

body {
    background: var(--bg-gradient);
    color: var(--text-color);
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    margin: 0;
    padding: 0 2rem;
    line-height: 1.5;
    transition: background-color 0.3s, color 0.3s;
    min-height: 100vh;
}

body.nav-open-overflow-hidden {
    overflow: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

h1, h2, h3, h4 {
    font-family: 'Outfit', 'Inter', sans-serif;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: -0.02em;
}

/*
==============================================
               COMPONENTS
==============================================
*/

.card {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.5rem;
}

.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
}

.btn-primary {
    background-color: var(--accent-color);
    color: #000;
    font-weight: 700;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    transition: transform 0.2s, background-color 0.2s;
    display: inline-block;
}

.btn-primary:hover {
    transform: translateY(-2px);
    background-color: var(--accent-color-hover);
}

.btn-secondary {
    background-color: transparent;
    color: var(--text-muted);
    border: 1px solid var(--border-color);
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s ease-in-out;
    display: inline-block;
    font-weight: 700;
}

.btn-secondary:hover {
    background-color: var(--border-color);
    color: var(--text-color);
}

.btn-whatsapp {
    background-color: #25D366;
    color: #fff;
    font-weight: 700;
}

.btn-whatsapp:hover {
    background-color: #1DAE54;
    color: #fff;
}

.btn-cancel {
    background-color: transparent;
    color: var(--accent-color);
    border: 1px solid var(--border-color);
    padding: 0.4rem 0.8rem;
    border-radius: 5px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}

.btn-cancel:hover {
    background-color: var(--surface-color);
    color: var(--text-color);
    border-color: var(--text-muted);
}

/*
==============================================
                  NAVBAR
==============================================
*/

.navbar {
    position: sticky;
    top: 1rem;
    z-index: 1000;
    margin: 1rem 2rem;
    padding: 0.75rem 2rem;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.brand {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--accent-color);
    text-decoration: none;
    letter-spacing: -1px;
    z-index: 1101; /* Ensure brand is above the mobile nav background */
}

.navbar-logo {
    height: 85px;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-link:hover {
    color: var(--accent-color);
}

/*
==============================================
               PAGE SECTIONS
==============================================
*/

.hero {
    padding: 8rem 2rem;
    text-align: center;
    background: radial-gradient(circle at center, var(--hero-gradient-start) 0%, transparent 70%);
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 1rem;
    line-height: 1;
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 2rem;
}

.plans-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.plan-card {
    text-align: center;
    transition: transform 0.3s, border-color 0.3s;
}

.plan-card:hover {
    transform: scale(1.02);
    border-color: var(--accent-color);
}

.plan-price {
    font-size: 1.8rem;
    font-weight: 800;
    margin: 1.5rem 0;
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.25rem;
}

.plan-price small, .plan-price span {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
}

.features-list {
    list-style: none;
    padding: 0;
    margin: 2rem 0;
    text-align: left;
}

.features-list li {
    margin-bottom: 0.75rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.features-list li::before {
    content: "✓";
    color: var(--accent-color);
    font-weight: bold;
}

.location-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 4rem;
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.location-image-wrapper img {
    width: 100%;
    border-radius: 16px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

.location-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.location-content p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.contact-section {
    padding: 6rem 2rem;
    text-align: center;
}

.contact-header h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.contact-main-action h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    text-transform: none;
    font-weight: 500;
    color: var(--text-muted);
}

.whatsapp-contact-link {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    margin-bottom: 2rem;
    transition: transform 0.2s;
}

.whatsapp-contact-link:hover {
    transform: scale(1.05);
}

.whatsapp-contact-link span {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-color);
}

.contact-separator p {
    color: var(--text-muted);
    margin-top: 3rem;
    margin-bottom: 2rem;
}

.contact-form-wrapper {
    max-width: 600px;
    margin: 0 auto;
    padding: 2.5rem;
    text-align: left;
}

.footer {
    padding: 4rem 2rem;
    text-align: center;
    border-top: 1px solid var(--border-color);
    margin-top: 4rem;
    color: var(--text-muted);
}

/*
==============================================
                   FORMS
==============================================
*/
.contact-form div {
    margin-bottom: 1rem;
}

.contact-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea,
.contact-form select {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(0,0,0,0.2);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-color);
    font-size: 1rem;
    box-sizing: border-box; /* Important for padding and width */
}

.contact-form input[type="text"]:focus,
.contact-form input[type="email"]:focus,
.contact-form textarea:focus,
.contact-form select:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(247, 179, 0, 0.2);
}

/*
==============================================
               SCHEDULE PAGE
==============================================
*/

.schedule-view-toggles {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin: 2rem 0;
    background: rgba(255, 255, 255, 0.03);
    padding: 0.4rem;
    border-radius: 12px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    border: 1px solid var(--border-color);
}

.view-toggle-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    padding: 0.6rem 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    transition: all 0.2s;
}

.view-toggle-btn.active {
    background: var(--accent-color);
    color: #000;
}

.view-timeline .timeline-wrapper {
    overflow-x: auto;
    background: var(--glass-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
}

.view-timeline .timeline-grid {
    display: grid;
    grid-template-columns: 80px repeat(7, 1fr);
    min-width: 1100px;
    border-top: 1px solid var(--border-color);
    border-left: 1px solid var(--border-color);
}

.view-timeline .timeline-header-cell, .view-timeline .time-axis-cell, .view-timeline .grid-cell {
    border-right: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.view-timeline .timeline-header-cell {
    padding: 1rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.02);
}

.view-timeline .day-label {
    display: block;
    color: var(--accent-color);
    font-weight: 800;
    font-size: 0.85rem;
}

.view-timeline .date-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.view-timeline .time-axis-cell {
    padding: 1rem 0.5rem;
    text-align: right;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.view-timeline .grid-cell {
    position: relative;
    height: 100px;
}

.view-timeline .timeline-event {
    position: absolute;
    left: 4px;
    right: 4px;
    background: var(--accent-color);
    color: #000;
    border-radius: 6px;
    padding: 0.5rem;
    font-size: 0.75rem;
    overflow: hidden;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.view-agenda .date-selector {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding: 1rem 0;
    margin-bottom: 2rem;
    scrollbar-width: none;
}

.view-agenda .date-selector::-webkit-scrollbar {
    display: none;
}

.view-agenda .date-btn {
    flex: 0 0 70px;
    background: var(--glass-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1rem 0.5rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.view-agenda .date-btn.active {
    background: var(--accent-color);
    border-color: var(--accent-color);
}

.view-agenda .date-btn.active * {
    color: #000 !important;
}

.view-agenda .agenda-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.view-agenda .agenda-card {
    display: flex;
    background: var(--glass-bg);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.25rem;
    gap: 1.5rem;
    align-items: center;
}

.view-agenda .agenda-time span {
    color: var(--accent-color);
}

.class-history-card {
    background: var(--glass-bg);
    padding: 1.5rem;
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.class-history-card .class-details h3 {
    margin: 0;
    font-size: 1.1rem;
}

.class-history-card .class-details div {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

.class-history-card .status-badge {
    color: var(--text-muted);
    font-size: 0.8rem;
    text-align: right;
}


/*
==============================================
           THEME-SPECIFIC OVERRIDES
==============================================
*/

body.theme-luxe .btn-primary,
body.theme-luxe .view-toggle-btn.active {
    color: #FFFFFF;
}

body.theme-luxe .theme-btn:hover {
    color: #FFFFFF;
}

body.theme-luxe .toast {
    background-color: #FDFBF5;
    color: var(--text-color);
    border-color: var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

body.theme-luxe .toast strong {
    color: var(--accent-color);
}

body.theme-luxe .toast .close {
    color: var(--text-color);
}

/*
==============================================
           VISIBILITY & TOASTS
==============================================
*/

.view-timeline .agenda-container, .view-agenda .timeline-container {
    display: none;
}

.view-timeline .timeline-container, .view-agenda .agenda-container {
    display: block;
}

#toast-container {
    position: fixed;
    top: 90px;
    right: 20px;
    z-index: 1050;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.toast {
    background-color: var(--surface-color);
    color: var(--text-color);
    padding: 1rem 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    min-width: 250px;
    position: relative;
}

.toast.show {
    opacity: 1;
    transform: translateX(0);
}

.toast strong {
    color: var(--accent-color);
    font-family: 'Outfit', 'Inter', sans-serif;
    font-weight: 700;
}

.toast .close {
    position: absolute;
    top: 0.5rem;
    right: 0.75rem;
    background: none;
    border: none;
    color: inherit;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0.6;
}

/*
==============================================
                THEME SWITCHER
==============================================
*/

.theme-switcher {
    display: flex;
    gap: 0.5rem;
    margin-top: 1.5rem;
    justify-content: center;
}

.theme-btn {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.theme-btn:hover {
    background: var(--accent-color);
    color: #000;
    border-color: var(--accent-color);
}

/* Style for the active theme button */
body.theme-volt .theme-switcher .theme-btn[data-theme-switcher-theme-param="volt"],
body.theme-vip .theme-switcher .theme-btn[data-theme-switcher-theme-param="vip"] {
    background: var(--accent-color);
    color: #000;
    border-color: var(--accent-color);
    font-weight: bold;
}

body.theme-luxe .theme-switcher .theme-btn[data-theme-switcher-theme-param="luxe"] {
    background: var(--accent-color);
    color: #FFFFFF;
    border-color: var(--accent-color);
    font-weight: bold;
}

/*
==============================================
                RESPONSIVE
==============================================
*/

.nav-toggle {
    display: none; /* Hidden by default */
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    z-index: 1101;
    position: relative;
}

.nav-toggle .icon-bar {
    display: block;
    width: 100%;
    height: 3px;
    background-color: var(--text-color);
    border-radius: 3px;
    transition: all 0.3s ease-in-out;
}

.nav-toggle .icon-bar + .icon-bar {
    margin-top: 5px;
}

.nav-toggle.is-active .icon-bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}
.nav-toggle.is-active .icon-bar:nth-child(2) {
    opacity: 0;
}
.nav-toggle.is-active .icon-bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}


@media (max-width: 992px) {
    .navbar {
        margin: 1rem;
        padding: 0.75rem 1rem;
    }

    .nav-toggle {
        display: block;
        position: fixed;
        top: 2.5rem;
        right: 2rem;
    }

    /* Override desktop nav-links and set up for mobile animation */
    .nav-links {
        height: 100vh;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1050;

        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 1rem;

        /* Liquid Glass effect */
        background: radial-gradient(ellipse at top, rgba(247, 179, 0, 0.2), transparent 80%),
                    rgba(10, 10, 10, 0.85);
        backdrop-filter: blur(25px);
        -webkit-backdrop-filter: blur(25px);

        /* Hidden by default, for animation */
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transform: translateY(-10px);
        transition: opacity 0.4s ease, transform 0.4s ease, visibility 0.4s;
    }

    .nav-links.is-open {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }

    /* Style links inside the mobile menu */
    .nav-links .nav-link {
        font-size: 1.75rem;
        font-weight: 700;
        opacity: 0;
        transform: translateY(10px);
        transition: opacity 0.3s ease 0.1s, transform 0.3s ease 0.1s;
    }

    /* Animate links when menu is open */
    .nav-links.is-open .nav-link {
        opacity: 1;
        transform: translateY(0);
    }

    /* Stagger the animation of each link */
    .nav-links.is-open .nav-link:nth-child(1) { transition-delay: 0.2s; }
    .nav-links.is-open .nav-link:nth-child(2) { transition-delay: 0.3s; }
    .nav-links.is-open .nav-link:nth-child(3) { transition-delay: 0.4s; }
    .nav-links.is-open .nav-link:nth-child(4) { transition-delay: 0.5s; }
    .nav-links.is-open .nav-link:nth-child(5) { transition-delay: 0.6s; }
    .nav-links.is-open .nav-link:nth-child(6) { transition-delay: 0.7s; }

    /* Reset btn-primary to look like a nav-link inside the mobile menu */
    .nav-links .btn-primary {
        background: none;
        padding: 0;
        border: none;
        color: inherit;
        font-weight: 700; /* Match other mobile nav-links */
        transform: none;
    }

    .nav-links .btn-primary:hover {
        color: var(--accent-color);
        background: none;
    }

    .location-section {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 4rem 2rem;
        text-align: center;
    }

    .contact-section {
        padding: 4rem 1rem;
    }
}

@media (max-width: 768px) {
    html {
        font-size: 15px;
    }

    body {
        padding: 0 0.5rem;
    }

    .hero {
        padding: 5rem 0.5rem;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

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

    .plans-grid {
        padding: 2rem 0.5rem;
        grid-template-columns: 1fr;
    }

    .location-section {
        padding: 4rem 0.5rem;
    }

    .footer {
        padding: 3rem 0.5rem;
    }

    .view-timeline {
        display: none;
    }

    .schedule-view-toggles .view-toggle-btn[data-view="timeline"] {
        display: none;
    }

     .schedule-view-toggles .view-toggle-btn[data-view="agenda"] {
        flex-grow: 1;
    }
    
    .whatsapp-contact-link span {
        font-size: 1.5rem;
    }
}
