:root {
    /* Couleurs */
    --primary-color: #6D28D9;
    --secondary-color: #f4f4f4;
    --background-color: #F9FAFB;
    --text-color: #333;
    --border-color: #ddd;

    --button-bg-color: #6D28D9;
    --button-text-color: #f4f4f4;
    --button-hover-bg-color: #F97316;

    --border-radius: 5px;

    --font-family: Montserrat, sans-serif;
    --font-size: 1em;
    --line-height: 1.6;
}

html  {
    scroll-behavior: smooth;
    scroll-padding-top: 20px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body.modal-open {
    overflow: hidden; 
}

body {
    font-family: var(--font-family);
    line-height: var(--line-height);
    color: var(--text-color);
    background-color: var(--background-color);
    padding-top: 56px;
}

.container {
    width: 90%;
    margin: auto;
    padding: 0 10px;
}

.topbar-container {
    width: 80%;
    margin: auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.topbar {
    position: fixed;
    top: 0;
    width: 100%;
    background-color: var(--background-color);
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 5px 10px;
}

.topbar-logo {
    height: 40px;
    width: auto;
    color: var(--primary-color);
}

.topbar-cta {
    padding: 8px 14px;
    font-family: var(--font-family);
}

.main-nav {
    list-style: none;
    display: none;
    margin: 0;
    padding: 0;
}

.main-nav li {
    display: inline-block;
    margin-left: 20px;
}

.main-nav a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    font-size: 0.95em;
    transition: color 0.2s;
    padding: 5px 0; /* Add padding for a better clickable area */
}

.main-nav a:hover {
    color: var(--primary-color);
    border-bottom: 2px solid var(--primary-color); 
}

h1 {
    margin-bottom: 10px;
    color: var(--primary-color);
    text-align: center;
    font-weight: bold;
}


h2{
    margin-bottom: 20px;
    color: var(--primary-color);
    text-align: center;
    font-weight: bold;
}

.hero {
    background: linear-gradient(180deg, var(--background-color) 0%, #6c28d95b 100%);
    text-align: center;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    max-width: 1100px;
    margin: 0 auto;
    position: relative;
}

.hero-image {
    width: 80%;
    max-width: 420px; 
    height: auto;
    object-fit: cover;
    border-radius: 8px;
}

.hero-text {
    max-width: 680px;
    text-align: center;
}

#hero h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

.cta-hero {
    margin-top: 20px;
    font-family: var(--font-family);
}

.small-text {
    font-size: 0.8em;
    color: #666;
    margin-top: 5px;
}

.cta-proof {
    font-size: 0.9em;
    font-weight: 600;
    color: var(--primary-color);
    margin-top: 15px;
    margin-bottom: 5px;
}

.cta-button {
    background-color: var(--button-bg-color);
    color: var(--button-text-color);
    border: none;
    padding: 10px 20px;
    font-size: var(--font-size);
    cursor: pointer;
    border-radius: var(--border-radius);
}

.cta-button:hover {
    background-color: var(--button-hover-bg-color);
    color: var(--button-text-color);
    transform: translateY(-2px); 
    box-shadow: 0 8px 15px rgba(249, 115, 22, 0.4);
    transition: 0.1s;
}


/* Section 2: How you will learn to speak */
#learning {
    padding: 20px 0;
    text-align: left;
}

.video-wrapper {
    margin: 20px auto;
    width: 100%;
    max-width: 600px;
}

#learning video {
    display: block;
    width: 100%;
    max-width: 600px;
    margin: 20px auto;
}

.method-intro {
    margin-bottom: 15px;
}

.method-subtitle {
    font-size: 1.1em;
    color: var(--primary-color);
    margin-top:10px;
}

.method-list {
    list-style: none; /* Remove default dots/numbers */
    padding: 0;
    margin: 5px 0 0px 0;
}

.method-list li {
    padding: 10px 0 10px 0;
    position: relative;
    line-height: 1.5;
}

/* Section 3: Bio */
#bio {
    padding: 20px 0;
    text-align: left;
}

.bio-content-wrapper {
    display: flex;
    flex-direction: column; /* Stack image/text on mobile */
    gap: 30px;
    align-items: center; /* Center items when stacked */
    margin-top: 30px;
}

.bio-image {
    width: 100%;
    max-width: 200px; 
    height: 200px; /* Fixed height for perfect circle */
    object-fit: cover;
    border-radius: 50%; /* Makes the image circular */
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1); /* Subtle shadow for depth */
}

/* Media Query for side-by-side layout on desktop */
@media (min-width: 768px) {
    .bio-content-wrapper {
        flex-direction: row; /* Image and text side-by-side */
        text-align: left;
        align-items: flex-start;
    }
}
/* Section 4: Pricing */
#pricing {
    padding: 20px 0;
    text-align: center;
}

.pricing-options {
    display: flex;
    flex-direction: column;
    gap:20px;
    justify-content: space-around;
    margin-bottom: 20px;
}

.pricing-note{
    font-size: 0.8em;
}

.option {
    padding: 20px;
    border-radius: var(--border-radius);
    width: 100%;
    box-shadow:  0px 0px 10px #6c28d95c;
    cursor: pointer; 
    transition: transform 0.3s ease, box-shadow 0.3s ease, border 0.3s ease;
}

.option:hover {
    transform: translateY(-3px); /* Subtle lift on hover */
    box-shadow: 0px 8px 15px rgba(109, 40, 217, 0.2); /* Softer shadow */
}

.option.selected {
    border: 2px solid var(--primary-color);
    box-shadow: 0 0 0 3px rgba(109, 40, 217, 0.3), 0 8px 15px rgba(109, 40, 217, 0.1);
    background-color: var(--secondary-color); /* Light background for visual pop */
    transform: none; 
}


.option h3 {
    margin-bottom: 10px;
}

.option p {
    margin-bottom: 5px;
}

/* Section 5: Reviews */
#testimonials {
    padding: 20px 0;
    text-align: center;
}

.carousel {
    /* --- NEW FLEX/WRAP SETUP FOR GRID --- */
    display: flex;
    flex-wrap: wrap; /* Key change: Allows items to wrap to the next row */
    justify-content: center; /* Center the grid container */
    gap: 20px; /* Add consistent space between cards */
    margin-top: 30px;
    max-width: 1200px; /* Constrain the overall width on large screens */
    margin-left: auto;
    margin-right: auto;
}

.testimonial {
    padding: 20px;
    border-radius: var(--border-radius);
    /* Remove fixed width: Width is now managed by media queries below */
    box-shadow: 0 4px 8px #6c28d93e;
    /* Ensure the content itself is flexible */
    flex-grow: 1; 
}

/* --- REVISED TESTIMONIALS STYLE --- */

/* Container for Name and Flag */
.student-info {
    /* Uses Flexbox to put name and flag on the same line */
    display: flex;
    align-items: center;
    gap: 10px; /* Space between name and flag */
    margin-bottom: 10px;
    /* Optional: A subtle separator line */
    border-bottom: 1px solid var(--border-color); 
    padding-bottom: 8px;
}

/* Name Style */
.student-name {
    font-weight: 700;
    font-size: 1.1em;
    margin: 0; /* Remove default paragraph margin */
}

/* Flag Style (Emojis are high-resolution by default) */
.student-country-flag {
    font-size: 1.1em;
    color: #666; /* Use a slightly muted color for the text */
}

/* Review Text Style */
.review-text {
    font-style: italic;
    color: #555;
    margin-top: 5px; /* Reduced margin since the rating is gone */
}
/* Section 6: FAQ */
/* ----------- FAQ STYLES ----------- */

#faq {
    padding-top: 20px;
    text-align: center;
}

.faq-list {
    max-width: 800px;
    margin: 30px auto 0;
    text-align: left;
}

.faq-item {
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    margin-bottom: 10px;
    overflow: hidden; /* Important for clean transition */
}

.faq-question {
    background: none;
    border: none;
    width: 100%;
    padding: 18px 20px;
    text-align: left;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.1em;
    font-weight: 600;
    color: var(--text-color);
    transition: background-color 0.2s;
}

.faq-question:hover {
    background-color: var(--secondary-color);
}

.faq-question h3 {
    margin: 0; /* Remove default margin from h3 */
    font-size: 1em;
}

.faq-icon {
    font-size: 1.5em;
    line-height: 1;
    transition: transform 0.3s ease;
}

/* State when the question is active (open) */
.faq-question.active .faq-icon {
    transform: rotate(45deg); /
}

.faq-answer-content {
    /* Initially hide the content */
    max-height: 0; 
    opacity: 0;
    transition: max-height 0.4s ease-out, opacity 0.3s ease;
    padding: 0 20px;
}

.faq-answer-content.open {
    /* State when open */
    max-height: 500px; /* Use a large enough value to accommodate the content */
    opacity: 1;
    padding: 10px 20px 20px;
}

.faq-answer-content p {
    margin: 0;
    padding-top: 5px;
}

/* ----------- MODAL STYLES ----------- */

.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    display: none;
    justify-content: center;
    align-items: center;
    animation: fadeIn 0.25s ease-out;
    z-index: 2000;
}

.modal-window {
    background: var(--background-color);
    padding: 30px 26px;
    width: 92%;
    max-width: 420px;
    border-radius: 14px;
    box-shadow: 0 8px 28px rgba(0,0,0,0.18);
    position: relative;
    animation: popIn 0.25s ease-out;
}

.modal-title {
    margin-bottom: 14px;
    font-size: 1.6rem;
    font-weight: 600;
    text-align: center;
    color: #333;
}

.modal-window label {
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 6px;
    display: block;
    color: #444;
}

.modal-window input,
.modal-window textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 16px;
    border-radius: 10px;
    border: 1px solid #ccc;
    font-family:  var(--font-family);
    font-size: 0.95rem;
    outline: none;
    transition: border 0.2s;
}

.modal-window input:focus,
.modal-window textarea:focus {
    border: 1px solid #6D28D9;
}

.modal-prefilled {
    font-family: var(--font-family);
    font-size: 0.95rem;
    line-height: 1.45;
    color: #333;
}

.modal-submit {
    background: #6D28D9;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 10px;
    width: 100%;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s;
}

.modal-submit:hover {
    background: #F97316;
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: none;
    border: none;
    font-size: 1.6rem;
    cursor: pointer;
    color: #666;
    transition: color 0.2s;
}

.modal-close:hover {
    color: #111;
}

.modal-trust-note {
    text-align: center;
    font-size: 0.6rem;
    color: #666;
    margin-top: 10px;
    padding: 0 10px;
}

.getback {
    font-size: 0.85rem;
    color: #444;
    text-align: center;
    margin-top: 10px;
    margin-bottom: 10px;
}

/* ANIMATIONS */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes popIn {
    from { transform: translateY(14px) scale(0.97); opacity: 0; }
    to { transform: translateY(0) scale(1); opacity: 1; }
}

/* Sticky CTA for Mobile */
#sticky-mobile-cta {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    border-radius: 0; /* Make it full width and rectangular */
    padding: 18px 20px; /* Make it thick and easy to tap */
    font-size: 1.1em;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 1000;
    box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.15); /* Shadow from the bottom */
}

/* Hide on larger screens where the fixed topbar CTA is visible */
@media (min-width: 768px) {
    #sticky-mobile-cta {
        display: none;
    }
}

/* Ensure the sticky CTA doesn't cover content on mobile */
body {
    /* ... existing styles ... */
    padding-bottom: 70px; /* Add padding to the body bottom equal to the CTA height */
}

/* --- UTILITY ANIMATION CLASS --- */
/* Base styles for elements that will be animated */
.pop-in-element {
    opacity: 0;
    animation-fill-mode: forwards; /* Holds the end state (opacity: 1) */
}

/* --- FIX: INITIAL HIDE STATE (The key to fixing the disappearing elements) --- */
/* This rule ensures all elements in the hero-text block start invisible. */
#hero .hero-text h1,
#hero .hero-text p,
#hero .hero-text button,
.cta-credential-text,
.cta-trust-claim {
    opacity: 0;
}


/* --- ANIMATION APPLICATION: Staggered Entrance with Delay --- */

/* 1. Slogan (H1) */
#hero h1 {
    animation: popIn 0.8s ease-out 0.2s forwards;
}

/* 2. Subtitle (The first P tag) */
#hero .hero-text p:first-of-type {
    animation: popIn 0.8s ease-out 0.4s forwards;
}

/* 4. CTA Button */
#hero .cta-button {
    animation: popIn 0.8s ease-out 0.8s forwards;
}

/* 5. Trust Claim (Trusted by 100+ students) */
.cta-proof {
    animation: popIn 0.8s ease-out 1.0s forwards;
}

/* 6. Fine Print (30-minute trial) */
#hero .hero-text p:last-of-type {
    animation: popIn 0.8s ease-out 1.2s forwards;
}

/* --- SCROLL REVEAL ANIMATION CLASSES --- */

/* Initial state: Hidden and slightly offset (opacity: 0) */
.reveal-on-scroll {
    opacity: 0;
}

/* Final state: Visible and animated (popIn keyframe) */
.reveal-on-scroll.reveal {
    /* Uses the existing popIn keyframes, which translate and scale to 1 */
    animation: popIn 0.5s ease-out forwards;
}

/* ------------------------------------------------------------------- */
/* MEDIA QUERIES START HERE */
/* ------------------------------------------------------------------- */

/* ------------------------------------------------------------------- */
/* Tablet & Small Desktop (768px and up) */
/* ------------------------------------------------------------------- */

@media (max-width: 768px) {

    #hero h1 {
        font-size: 2rem;
        line-height: 1.1; 
        margin-top: 0; 
    }
}

@media (min-width: 768px) {
    
    /* --- NAVBAR --- */
    .main-nav {
        display: block; /* SHOW NAVIGATION LINKS */
    }
    
    /* --- PRICING --- */
    .pricing-options {
        /* Switch from stacking (column) to a row layout */
        flex-direction: row;
        justify-content: space-around;
        gap: 30px;
    }

    .option {
        width: 30%; 
    }


    /* --- TESTIMONIALS --- */
    .testimonial {
        /* Show 2 columns per row with a 20px gap */
        width: calc(50% - 10px); 
    }
}


/* ------------------------------------------------------------------- */
/* Desktop (1000px and up) */
/* ------------------------------------------------------------------- */
@media (min-width: 1000px) {
    
    /* --- HERO SECTION --- */
    /* This overrides the base mobile styles for the hero section */
    #hero {
        text-align: left;
    }

    .hero-content {
        flex-direction: row-reverse; /* Puts image on the right */
        align-items: center;
        gap: 48px;
        height:80vh;
    }

    .hero-image {
        width: 90%;
        max-width: 800px; 
        margin: 0;
        flex: 0 0 auto;
    }

    .hero-text {
        flex: 1 1 auto;
        text-align: left;
        padding-right: 20px;
    }

    #hero h1 {
        text-align: left;
        font-size: 3rem;
    }

    /* --- TESTIMONIALS --- */
    .testimonial {
        /* Show 3 columns per row with a 20px gap */
        width: calc(33.333% - 14px); 
    }

    .container {
        width: 80%;
    }
}

/* ------------------------------------------------------------------- */
/* Extra Large Screens (1200px and up) */
/* ------------------------------------------------------------------- */
@media (min-width: 1200px) {
    .hero-image {
        max-height: 70vh;
        height: auto;
    }
}
