/* ==========================================================================
   VARIABLES & BASE STYLES
   ========================================================================== */
:root {
    --color-primary: #005A9C;
    --color-primary-dark: #004070;
    --color-text-heading: #1A202C;
    --color-text-body: #4A5568;
    --color-background-light: #F7FAFC;
    --color-background-white: #FFFFFF;
    --color-border: #E2E8F0;
    --font-heading: 'Lato', sans-serif;
    --font-body: 'Roboto', sans-serif;
    --container-width: 1140px;
    --header-height: 80px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--header-height);
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    color: var(--color-text-body);
    background-color: var(--color-background-white);
    line-height: 1.6;
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--color-text-heading);
    font-weight: 700;
    line-height: 1.2;
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--color-primary-dark);
}

img {
    max-width: 100%;
    height: auto;
}

.content-section {
    padding: 80px 0;
}

.section-title {
    font-size: 36px;
    text-align: center;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 18px;
    text-align: center;
    max-width: 600px;
    margin: 0 auto 48px auto;
}

/* ==========================================================================
   BUTTONS
   ========================================================================== */
.cta-button {
    display: inline-block;
    background-color: var(--color-primary);
    color: var(--color-background-white);
    padding: 12px 28px;
    border-radius: 5px;
    font-weight: 700;
    font-family: var(--font-body);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    cursor: pointer;
}

.cta-button:hover {
    background-color: var(--color-primary-dark);
    color: var(--color-background-white);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 90, 156, 0.2);
}

/* ==========================================================================
   HEADER
   ========================================================================== */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background-color: rgba(255, 255, 255, 0.9);
    z-index: 1000;
    transition: all 0.3s ease;
}

.main-header.scrolled {
    height: 70px;
    background-color: rgba(255, 255, 255, 0.98);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    max-width: 100%;
    padding: 0 40px;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 35px;
    width: auto;
    transition: all 0.3s ease;
}

.logo:hover img {
    transform: scale(1.05);
}

.main-header.scrolled .logo img {
    height: 30px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 30px;
}

.main-nav {
    display: flex; 
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
    align-items: center;
}

.main-nav a {
    color: var(--color-text-body);
    font-weight: 500;
    position: relative;
    padding: 5px 0;
}

/* Force White Text on Buttons inside Nav (Fix for Mobile Menu) */
.main-nav a.cta-button {
    color: var(--color-background-white) !important;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--color-primary);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease-out;
}

.main-nav a:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* Remove underline effect for buttons in nav */
.main-nav a.cta-button::after {
    display: none;
}

/* Auth Buttons (Desktop) */
.auth-buttons-desktop {
    display: flex;
    align-items: center;
    gap: 20px;
}

.login-link {
    font-weight: 700;
    color: var(--color-text-heading);
    font-size: 16px;
}

.login-link:hover {
    color: var(--color-primary);
}

/* Mobile Specific Elements (Hidden by default) */
.mobile-top-signup {
    display: none;
    padding: 8px 16px;
    font-size: 14px;
    margin-right: 15px;
    color: white !important;
}

.mobile-nav-item {
    display: none;
}

.mobile-menu-toggle {
    display: none; 
    background: none;
    border: none;
    padding: 0;
    font-size: 24px;
    cursor: pointer;
    color: var(--color-text-heading);
}


/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero-section {
    /* INCREASED HEIGHT FOR WEB (65vh / 500px) */
    height: 65vh; 
    min-height: 500px;
    
    /* Variable for Desktop Image */
    background-image: var(--bg-desktop);
    background-size: cover;
    background-position: center center;
    
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.5), transparent 60%);
}

.hero-content {
    position: relative;
    z-index: 2;
    color: var(--color-background-white);
}

.hero-content h1 {
    font-size: 56px;
    font-weight: 900;
    color: var(--color-background-white);
    margin-bottom: 20px;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.8);
}

.hero-content p {
    font-size: 20px;
    max-width: 650px;
    margin: 0 auto 30px auto;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.8);
    font-weight: 500;
}

.hero-cta {
    padding: 15px 35px;
    font-size: 16px;
}

/* ==========================================================================
   HOW IT WORKS SECTION
   ========================================================================== */
.how-it-works-section {
    background-color: var(--color-background-light);
}

.steps-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    text-align: center;
}

.step-card {
    padding: 30px;
}

.step-icon {
    font-size: 40px;
    color: var(--color-primary);
    margin-bottom: 20px;
}

.step-card h3 {
    font-size: 22px;
    margin-bottom: 10px;
}

/* ==========================================================================
   NEW REPORT SHOWCASE (DARK SCROLL REVEAL)
   ========================================================================== */
.showcase-section.dark-mode {
    background-color: #000000;
    color: #ffffff;
    height: 100vh; 
    min-height: 600px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 20px 0; 
}

.showcase-header {
    z-index: 20; 
    position: relative;
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px auto; 
    flex-shrink: 0; 
}

/* Apple-Style Headline */
.showcase-section.dark-mode .section-title {
    font-size: 56px; 
    font-weight: 700;
    line-height: 1.05; 
    letter-spacing: -1.5px; 
    margin-bottom: 20px;
    background: linear-gradient(135deg, #FFFFFF 0%, #A5A5A5 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: #ffffff; 
}

/* Apple-Style Subtitle */
.showcase-section.dark-mode .section-subtitle {
    font-size: 24px;
    font-weight: 400;
    line-height: 1.4;
    color: #86868b;
    max-width: 600px;
    margin: 0 auto;
    letter-spacing: -0.5px;
}

.showcase-content {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

/* The Stage - Responsive height */
.showcase-stage {
    position: relative;
    width: 100%;
    height: 55vh; 
    max-height: 550px;
    display: flex;
    justify-content: center;
    overflow: hidden; 
    perspective: 1000px;
    margin-top: 20px;
}

.showcase-card {
    position: relative;
    width: 95%;
    max-width: 1100px; 
    z-index: 10;
}

.showcase-card img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 20px 20px 0 0;
    box-shadow: 0 -10px 50px rgba(255, 255, 255, 0.08);
}

.showcase-shadow-gradient {
    position: absolute;
    bottom: -2px; 
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(to bottom, transparent 0%, #000000 90%);
    z-index: 20;
    pointer-events: none;
}

/* Short Screen Fix (Laptop Landscape / Chromebooks) */
@media screen and (max-height: 800px) {
    .showcase-section.dark-mode .section-title { font-size: 36px; margin-bottom: 10px; }
    .showcase-section.dark-mode .section-subtitle { font-size: 18px; margin-bottom: 15px; }
    .showcase-header { margin-bottom: 20px; }
    .showcase-stage { height: 50vh; }
}

/* ==========================================================================
   SAMPLE REPORT SECTION
   ========================================================================== */
.sample-report-section {
    background-color: var(--color-background-white);
}

.report-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.report-text-content .section-title,
.report-text-content .section-subtitle {
    text-align: left;
    margin-left: 0;
    margin-right: 0;
}

.report-text-content ul {
    list-style: none;
    margin: 30px 0;
    padding: 0;
}

.report-text-content ul li {
    font-size: 18px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}

.report-text-content ul li i {
    color: var(--color-primary);
    margin-right: 15px;
    font-size: 22px;
}

.report-image-content img {
    border-radius: 8px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
}

.report-image-content img:hover {
    transform: scale(1.05);
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

/* ==========================================================================
   FANCY FEATURES SECTION
   ========================================================================== */
.features-section {
    background-color: var(--color-background-light);
    overflow: hidden; 
    padding-bottom: 100px;
}

.features-carousel-wrapper {
    position: relative;
    height: 480px; 
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 40px;
    perspective: 1200px; 
}

.features-track {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.feature-card {
    position: absolute;
    width: 340px;
    height: 400px;
    background: var(--color-background-white);
    border-radius: 24px;
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 90, 156, 0.15); 
    border: 1px solid rgba(255, 255, 255, 0.8);
    transition: box-shadow 0.3s ease;
}

.feature-card .card-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--color-background-light), #fff);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 25px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}

.feature-card i {
    font-size: 36px;
    color: var(--color-primary);
}

.feature-card h3 {
    font-size: 22px;
    margin-bottom: 15px;
    color: var(--color-text-heading);
}

.feature-card p {
    font-size: 16px;
    color: var(--color-text-body);
    line-height: 1.5;
}

/* Carousel Buttons */
.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #fff;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 50, 100, 0.1); /* Reduced shadow */
    color: var(--color-primary);
    font-size: 18px;
    cursor: pointer;
    z-index: 200;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
}

.carousel-btn:hover {
    background: var(--color-primary);
    color: #fff;
    transform: translateY(-50%) scale(1.1);
}

.prev-btn { left: 20px; }
.next-btn { right: 20px; }

/* Carousel Dots */
.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.carousel-dot {
    width: 10px;
    height: 10px;
    background-color: #cbd5e0;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-dot.active {
    background-color: var(--color-primary);
    transform: scale(1.3);
}

/* ==========================================================================
   FAQ SECTION
   ========================================================================== */
.faq-section {
    background-color: var(--color-background-white);
}

.faq-container {
    max-width: 750px;
    margin: 0 auto;
}

.faq-item {
    border-bottom: 1px solid var(--color-border);
}

.faq-question {
    width: 100%;
    background: none;
    border: none;
    text-align: left;
    padding: 20px 0;
    font-size: 18px;
    font-weight: 500;
    color: var(--color-text-heading);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-question i {
    transition: transform 0.3s ease;
    color: var(--color-primary);
}

.faq-question.active i {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
}

.faq-answer p {
    padding: 0 0 20px 0;
}

/* ==========================================================================
   SIGNUP SECTION
   ========================================================================== */
.signup-section {
    background-color: var(--color-primary);
    color: var(--color-background-white);
    text-align: center;
}

.signup-section h2 {
    color: var(--color-background-white);
    font-size: 32px;
    margin-bottom: 10px;
}

.signup-section p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 30px;
}

.signup-form {
    display: flex;
    justify-content: center;
    gap: 10px;
    max-width: 500px;
    margin: 0 auto;
}

.signup-form input {
    width: 100%;
    padding: 14px;
    border-radius: 5px;
    border: 1px solid transparent;
    font-size: 16px;
}

.signup-form input:focus {
    outline: none;
    border-color: var(--color-primary-dark);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.5);
}

.signup-form .cta-button {
    background-color: var(--color-background-white);
    color: var(--color-primary);
    flex-shrink: 0;
}

.signup-form .cta-button:hover {
    background-color: #f0f0f0;
    color: var(--color-primary-dark);
}


/* ==========================================================================
   FOOTER
   ========================================================================== */
.main-footer {
    background-color: var(--color-text-heading);
    color: #A0AEC0;
    padding: 60px 0 30px 0;
}

.footer-top {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
    margin-bottom: 40px;
    border-bottom: 1px solid #2D3748;
}

.footer-logo {
    margin-bottom: 15px;
    filter: brightness(0) invert(1);
    opacity: 0.8;
}

.footer-about p {
    max-width: 300px;
}

.footer-links h4 {
    color: var(--color-background-white);
    font-size: 16px;
    margin-bottom: 15px;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #A0AEC0;
}

.footer-links a:hover {
    color: var(--color-background-white);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */
.animate-on-load {
    opacity: 0;
    transform: translateY(20px);
}

.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@keyframes pulse-animation {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* ==========================================================================
   RESPONSIVE DESIGN (MOBILE & TABLET)
   ========================================================================== */
@media (max-width: 992px) {
    .auth-buttons-desktop { display: none; } /* Hide Desktop Buttons */
    
    .mobile-top-signup { display: inline-block; } /* Show Header Signup Button */
    
    .main-nav {
        display: none;
        position: absolute;
        top: var(--header-height);
        left: 0;
        width: 100%;
        background-color: var(--color-background-white);
        box-shadow: 0 4px 10px rgba(0,0,0,0.1);
        flex-direction: column;
        padding: 20px;
    }
    .main-nav.active { display: flex; }
    .main-nav ul { flex-direction: column; gap: 20px; width: 100%; }
    .main-nav ul li { width: 100%; text-align: center; }
    
    /* Show Mobile Menu Auth Links */
    .mobile-nav-item { display: block; width: 100%; }
    
    /* Ensure the button takes full width in mobile menu and text is white */
    .mobile-nav-item a.cta-button { 
        width: 100%; 
        text-align: center;
        color: #ffffff !important; 
    }
    
    .mobile-menu-toggle { display: flex; align-items: center; }
    
    .footer-top { grid-template-columns: 1fr 1fr; }
    
    .report-content-wrapper { grid-template-columns: 1fr; gap: 40px; }
    .report-image-content { order: -1; text-align: center; }
    .report-text-content { text-align: center; }
    .report-text-content ul { display: inline-block; text-align: left; }

    /* Adjust Carousel for Tablet */
    .features-carousel-wrapper { perspective: 800px; height: 420px; }
    .feature-card { width: 300px; height: 350px; padding: 30px 20px; }
}

/* --- MOBILE PHONE STYLES --- */
@media (max-width: 768px) {
    /* Layout Adjustments */
    .content-section { padding: 50px 0; }
    .main-header .container { padding: 0 20px; }
    .logo img { height: 26px; }

    /* Typography Overrides */
    h1, .hero-content h1 { font-size: 32px !important; line-height: 1.2; }
    .hero-content p { font-size: 16px; max-width: 100%; }
    .section-title { font-size: 28px; }
    .section-subtitle { font-size: 16px; margin-bottom: 30px; }

    /* HERO BANNER MOBILE FIX (REDUCED SIZE - KEPT SMALLER AS REQUESTED) */
    .hero-section { 
        min-height: 380px; 
        height: auto; 
        
        /* Switches to Mobile Banner Variable */
        background-image: var(--bg-mobile);
        
        /* UPDATED: Centers the image vertically */
        background-position: center center; 
        
        background-size: cover;
        padding: 60px 0 30px 0;
    }
    .hero-cta { width: 100%; text-align: center; }
    
    /* Steps Container */
    .steps-container { grid-template-columns: 1fr; gap: 40px; }
    
    /* Carousel Fix for Mobile */
    .features-carousel-wrapper { 
        height: 380px; 
        overflow: hidden; 
    }
    .feature-card { 
        width: 260px;
        height: 320px; 
    }
    .prev-btn { left: 5px; }
    .next-btn { right: 5px; }

    /* "Apple Style" Showcase Section - Mobile Fix */
    .showcase-section.dark-mode {
        height: auto;
        min-height: 100vh;
        padding: 80px 0 40px 0;
    }
    .showcase-header {
        margin-bottom: 30px;
        padding: 0 15px;
    }
    .showcase-section.dark-mode .section-title {
        font-size: 32px;
        letter-spacing: -0.5px;
        line-height: 1.2;
    }
    .showcase-section.dark-mode .section-subtitle {
        font-size: 18px;
        max-width: 100%;
    }
    .showcase-stage {
        height: 40vh;
        min-height: 300px;
        margin-top: 10px;
    }

    /* Footer Fixes */
    .footer-top { grid-template-columns: 1fr; text-align: center; }
    .footer-bottom { flex-direction: column; gap: 20px; text-align: center; }
}
/* =========================================
   MOBILE HEADER & BUTTON FIXES
   ========================================= */

@media (max-width: 992px) {

    /* 1. Remove the invisible desktop nav container so it doesn't take up space */
    .header-right {
        display: none !important;
    }

    /* 2. Fix the Mobile Sign Up Button */
    .mobile-top-signup {
        white-space: nowrap; /* Prevents text from wrapping to two lines */
        flex-shrink: 0;      /* Prevents the button from being squashed */
        font-size: 14px;     /* Ensure font size stays readable but compact */
        padding: 8px 16px;   /* Consistent padding */
        
        /* Optional: Vertical alignment fix */
        align-self: center;
    }

    /* 3. Ensure the Logo doesn't shrink either */
    .logo {
        flex-shrink: 0;
    }
    
    /* 4. Enforce fixed height on scroll to prevent "growing" */
    .main-header.scrolled {
        height: 70px !important; /* Force the height constraint */
    }
    
    /* 5. Ensure the flex container centers everything perfectly */
    .main-header .container {
        justify-content: space-between;
        align-items: center;
        flex-wrap: nowrap; /* Never let elements wrap to a new line */
    }
}
/* =========================================
   MOBILE HEADER ADJUSTMENTS (CORRECTED)
   ========================================= */

@media (max-width: 992px) {

    /* 1. RESTORE MENU FUNCTIONALITY */
    /* We must allow this to display so the nav inside it works, 
       but we crush its width to 0 so it doesn't mess up the layout. */
    .header-right {
        display: flex !important;
        width: 0;
        height: 0;
        padding: 0;
        margin: 0;
        overflow: visible; /* Important: lets the absolute nav menu spill out */
    }

    /* 2. Fix Logo Sizing */
    .logo img {
        height: 24px !important; 
        width: auto;
    }
    .main-header.scrolled .logo img {
        height: 22px !important; 
    }

    /* 3. Group Button & Menu to the Right */
    .mobile-top-signup {
        margin-left: auto;   /* Pushes Button + Burger to the far right */
        margin-right: 12px;  /* Space between button and burger */
        
        /* Compact Button Styles */
        font-size: 13px;
        padding: 6px 12px;
        white-space: nowrap; 
        flex-shrink: 0;
    }

    /* 4. Hamburger Menu Positioning */
    .mobile-menu-toggle {
        font-size: 22px;
        margin-left: 0;
        padding: 0;
        border: none;
        background: transparent;
        flex-shrink: 0;
    }

    /* 5. Container Layout Force */
    .main-header .container {
        padding-right: 20px; 
        justify-content: flex-start; /* Aligns Logo left; margin-auto handles the rest */
        flex-wrap: nowrap;           /* Prevents wrapping */
    }
}
/* =========================================
   MOBILE FOOTER FIXES (LEFT ALIGN)
   ========================================= */

@media (max-width: 768px) {
    
    /* 1. Force Left Alignment for the Top Section */
    .footer-top {
        text-align: left !important;
        grid-template-columns: 1fr; /* Stack vertically */
        gap: 40px;
    }

    /* 2. Fix the 'About' paragraph width */
    .footer-about p {
        max-width: 100% !important; /* Let text fill the screen */
        margin-right: 0;
    }

    /* 3. Force Left Alignment for the Bottom Section */
    .footer-bottom {
        text-align: left !important;
        align-items: flex-start !important; /* Stops flexbox from centering items */
        padding-bottom: 20px;
    }
    
    /* 4. Ensure the logo stays on the left */
    .footer-logo {
        margin-left: 0;
        display: block;
    }
}
@media (max-width: 768px) {
    /* ... previous footer fixes ... */

    .footer-logo {
        width: 150px; /* Restricts the logo width */
        height: auto; /* Keeps the aspect ratio correct */
        margin-bottom: 20px;
    }
}