/* ==========================================================================
   1. GLOBAL STYLES & VARIABLES
   ========================================================================== */
:root {
    --bg-dark: #101010;
    --bg-medium: #1a1a1a;
    --bg-light: #252525;
    --text-primary: #f0f0f0;
    --text-secondary: #a0a0a0;
    --accent-blue: #00AEEF;
    --accent-blue-dark: #008fbf;
    --accent-gold: #FFC107;
    --white: #ffffff;
    --border-color: #333333;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px; /* Offset for sticky header */
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
}

h2 {
    /* Responsive font size: scales between 2.2rem and 2.8rem based on viewport width */
    font-size: clamp(2.2rem, 5vw, 2.8rem);
    text-align: center;
    margin-bottom: 50px;
}

.text-gradient {
    background: -webkit-linear-gradient(45deg, var(--accent-blue), var(--white) 80%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text; /* Fallback for browsers without vendor prefix */
    text-fill-color: transparent; /* Fallback */
}

p {
    margin-bottom: 15px;
    color: var(--text-secondary);
}

a {
    color: var(--accent-blue);
    text-decoration: none;
}

section {
    padding: 80px 0;
    overflow-x: hidden; /* Prevents horizontal scroll from animations */
}

/* Zebra-striping for main content sections */
main > section {
    border-top: 1px solid var(--border-color);
}
main > section:nth-of-type(odd) {
    background-color: var(--bg-dark);
}
main > section:nth-of-type(even) {
    /* background-color: var(--bg-medium); */
    background-color: #080808;
}
/* Exclude specific sections from automatic top border */
#hero, #final-cta, #pricing, .main-footer {
    border-top: none;
}


/* ==========================================================================
   2. ANIMATIONS & UTILITIES
   ========================================================================== */
.animate-on-scroll {
    opacity: 0;
    --initial-transform-y: 30px; /* CSS variable for starting position */
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.animate-on-scroll.is-visible {
    opacity: 1;
    --initial-transform-y: 0px; /* Move to final position */
}

/* Combines scroll-in animation with parallax effect */
[data-parallax-speed].animate-on-scroll {
    transform: translateY(calc(var(--initial-transform-y, 0px) + var(--parallax-transform-y, 0px)));
    transition: opacity 0.6s ease-out, --initial-transform-y 0.6s ease-out; /* Note: transform itself doesn't transition for smooth parallax */
}

/* Staggered animation delays for grid items */
.is-visible .animate-on-scroll:nth-child(2) { transition-delay: 0.1s; }
.is-visible .animate-on-scroll:nth-child(3) { transition-delay: 0.2s; }
.is-visible .animate-on-scroll:nth-child(4) { transition-delay: 0.3s; }
.is-visible .animate-on-scroll:nth-child(5) { transition-delay: 0.4s; }
.is-visible .animate-on-scroll:nth-child(6) { transition-delay: 0.5s; }

/* Utility for screen reader only text */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}


/* ==========================================================================
   3. BUTTONS
   ========================================================================== */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 8px;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}
.btn-primary {
    background-color: var(--accent-blue);
    color: var(--white);
}
.btn-primary:hover {
    background-color: var(--accent-blue-dark);
    transform: translateY(-2px);
}
.btn-secondary {
    background-color: transparent;
    color: var(--white);
    border: 2px solid var(--border-color);
}
.btn-secondary:hover {
    background-color: var(--bg-light);
    border-color: var(--bg-light);
}


/* ==========================================================================
   4. HEADER & NAVIGATION
   ========================================================================== */
.main-header {
    padding: 10px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    width: 100%;
    transition: background-color 0.4s ease, backdrop-filter 0.4s ease, border-color 0.4s ease;
    background: transparent;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.main-header.scrolled {
    background: rgba(16, 16, 16, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}
.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    transform: scale(1);
    transform-origin: center;
    transition: transform 0.4s ease;
}
.main-header.scrolled .container {
    transform: scale(0.8); /* Shrinks the header content on scroll */
}
.logo img {
    height: 70px;
}
.nav-links { list-style: none; display: flex; align-items: center; position: relative; }
.nav-links li { margin: 0 5px; }
.nav-links a { color: var(--text-primary); font-weight: 600; padding: 5px 10px; transition: color 0.3s ease; display: inline-block; }
.nav-links a:hover { color: var(--white); }
.nav-underline { position: absolute; bottom: -10px; height: 3px; background-color: var(--accent-blue); border-radius: 2px; opacity: 0; pointer-events: none; transition: all 0.35s cubic-bezier(0.25, 1, 0.5, 1); }
.header-btn { display: block; }
.mobile-nav-toggle { display: none; background: none; border: none; color: var(--white); font-size: 1.5rem; cursor: pointer; }


/* ==========================================================================
   5. PAGE SECTIONS
   ========================================================================== */

/* 5.1 HERO SECTION */
#hero {
    min-height: calc(100vh - 81px);
    display: flex;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    background-image: url('assets/final-frame.jpg');
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}
.hero-background-video { display: none; position: absolute; top: 50%; left: 50%; min-width: 100%; min-height: 100%; width: auto; height: auto; transform: translateX(-50%) translateY(-50%); z-index: 1; }
#hero.hero-video-bg .hero-background-video { display: block; }
#hero::before { content: ''; position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: rgba(16, 16, 16, 0.7); z-index: 2; }
.hero-content { position: relative; z-index: 3; max-width: 800px; margin: 0 auto; }
#hero h1 { font-size: clamp(3rem, 7vw, 4.5rem); font-weight: 900; }
#hero .subtitle { font-size: 1.2rem; max-width: 600px; margin: 20px auto 30px; color: var(--text-primary); }

.platform-badges-container { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; margin-top: 2.5rem; }
.platform-badge { background-color: rgba(0, 0, 0, 0.4); border: 1px solid var(--border-color); color: var(--text-secondary); width: 200px; padding: 0.75rem; border-radius: 8px; display: flex; align-items: center; justify-content: center; gap: 0.75rem; font-weight: 600; text-align: left; transition: background-color 0.3s ease; }
.platform-badge:hover { background-color: rgba(255, 255, 255, 0.1); }
.platform-badge i { font-size: 2.5rem; }
.platform-badge span { font-size: 0.9rem; line-height: 1.2; }
.hero-actions { display: flex; flex-direction: column; align-items: center; gap: 1rem; margin-top: 2rem; }
.hero-play-btn { display: inline-flex; align-items: center; gap: 0.75rem; font-size: 1rem; padding: 12px 28px; background-color: transparent; color: var(--text-secondary); border: none; transition: color 0.3s ease; }
.hero-play-btn:hover { color: var(--white); }

/* HubSpot Form Styles */
.form-container { max-width: 800px; width: 100%; margin: 0; }
form.hs-form .hs-form-field { padding: 0 0.5rem; }
form.hs-form > fieldset { display: flex; flex-wrap: wrap; margin: 0 -0.5rem; width: calc(100% + 1rem); }
.hs-form-field { flex-grow: 1; flex-basis: 0; min-width: 180px; margin-bottom: 1.25rem; }
.hs-form-field label { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; }
.hs-input { width: 100%; padding: 14px 16px; border-radius: 8px; border: 2px solid var(--border-color); background-color: rgba(0, 0, 0, 0.2); color: var(--text-primary); font-size: 1rem; font-family: 'Poppins', sans-serif; transition: border-color 0.3s, box-shadow 0.3s; }
.hs-input:focus { outline: none; border-color: var(--accent-blue); box-shadow: 0 0 0 3px rgba(0, 174, 239, 0.2); background-color: rgba(0, 0, 0, 0.5); }
.hs-submit { margin-top: 0 !important; }
.hs-button { width: 100%; height: 100%; display: inline-block; padding: 12px 28px; border-radius: 8px; font-weight: 600; text-align: center; transition: all 0.3s ease; border: none; cursor: pointer; background-color: var(--accent-blue); color: var(--white); font-size: 1.1rem; }
.hs-button:hover { background-color: var(--accent-blue-dark); transform: translateY(-2px); }
.form-message { padding: 0.75rem; margin-top: 1rem; border-radius: 6px; display: none; text-align: center; }
.form-message.success { background-color: #008fbf; color: var(--white); }
.form-message.error { background-color: #ffffff; color: var(--white); }
.form-message.info { background-color: var(--bg-light); color: var(--text-secondary); }

/* Countdown Timer */
.countdown-container { display: flex; flex-wrap: wrap; justify-content: center; gap: 1rem; margin: 2.5rem auto 0; }
.countdown-box { background: rgba(0, 0, 0, 0.3); border: 1px solid var(--border-color); border-radius: 8px; padding: 0.75rem 1rem; min-width: 5.5rem; text-align: center; }
.countdown-value { display: block; font-size: clamp(2rem, 5vw, 2.5rem); font-weight: 700; color: var(--white); line-height: 1.1; }
.countdown-label { display: block; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-secondary); }

/* 5.2 SOCIAL PROOF */
.proof-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px; }
.proof-card { background: var(--bg-dark); padding: 30px 20px; border-radius: 12px; border: 1px solid var(--border-color); transition: transform 0.3s ease, box-shadow 0.3s ease; flex: 1 1 250px; max-width: 300px; }
.proof-card:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2); }
.proof-card h3 { font-size: 1.2rem; color: var(--text-secondary); margin: 0; font-weight: 600; }

/* 5.3 IDEAL FOR */
.ideal-for-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.ideal-card { background: var(--bg-dark); padding: 40px 30px; border-radius: 12px; border: 1px solid var(--border-color); text-align: center; display: flex; flex-direction: column; }
.ideal-for-grid:has(.ideal-card:hover) .ideal-card:not(:hover) { opacity: 0.6; transform: scale(0.98); }
.ideal-card { transition: opacity 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease; }
.ideal-card:hover { transform: translateY(-8px) scale(1.02); box-shadow: 0 10px 20px rgba(0, 174, 239, 0.1); border-color: var(--accent-blue); }
.ideal-icon { font-size: 2.5rem; color: var(--accent-blue); margin-bottom: 20px; }
.ideal-card h3 { font-size: 1.4rem; color: var(--white); margin-bottom: 10px; }
.micro-tagline { display: block; font-style: italic; font-weight: 400; color: var(--text-secondary); font-size: 0.95rem; margin-bottom: 15px; }
.ideal-card p { font-size: 1rem; color: var(--text-primary); opacity: 0.9; line-height: 1.6; margin-bottom: 0; flex-grow: 1; }

/* 5.4 HPT ADVANTAGE */
.advantage-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.advantage-visual { width: 100%; transform: translateY(var(--parallax-transform-y, 0px)); }
.advantage-visual img { width: 100%; border-radius: 16px; box-shadow: 0 15px 40px rgba(0,0,0,0.5); }
.value-pillars { display: flex; flex-direction: column; gap: 2.5rem; }
.pillar-card { display: flex; align-items: flex-start; gap: 1.5rem; }
.pillar-icon { font-size: 1.8rem; line-height: 1; color: var(--accent-blue); flex-shrink: 0; }
.pillar-text h3 { font-size: 1.5rem; color: var(--white); margin-bottom: 0.5rem; margin-top: 0; }
.pillar-text p { font-size: 1rem; color: var(--text-secondary); line-height: 1.6; margin: 0; }

/* 5.5 APP CAROUSEL */
#app-carousel { overflow-x: visible; }
.carousel-container { position: relative; }
.carousel-viewport { position: relative; width: 100%; margin: 0 auto; overflow-x: hidden; overflow-y: visible; padding: 3rem 0; margin-top: -3rem; }
.carousel-track { display: flex; align-items: center; width: fit-content; transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1); touch-action: pan-y; }
.carousel-slide { flex: 0 0 300px; max-width: 300px; padding: 0 15px; transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.5s ease; transform: scale(0.85); opacity: 0.6; cursor: pointer; }
.carousel-slide.current-slide { transform: scale(1); opacity: 1; z-index: 10; cursor: default; }
.slide-content { position: relative; width: 100%; aspect-ratio: 418 / 868; box-shadow: 0 10px 30px rgba(0,0,0,0.4); }
.phone-frame { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 5; pointer-events: none; }
.phone-screen { position: absolute; inset: 13px 14px 11px 14px; border-radius: 28px; overflow: hidden; z-index: 1; }
.screen-content { position: relative; width: 100%; height: 100%; }
.app-screenshot { width: 100%; height: auto; display: block; }
.slide-content:not([data-scrollable="true"]) .app-screenshot { height: 100%; object-fit: cover; object-position: top; }
.bullet-point { position: absolute; z-index: 6; width: 40px; height: 40px; background-color: rgba(0, 174, 239, 0.8); border-radius: 50%; cursor: pointer; display: flex; justify-content: center; align-items: center; color: var(--white); font-size: 16px; font-weight: bold; transition: transform 0.3s ease, opacity 0.3s ease; box-shadow: 0 0 0 4px rgba(26, 26, 26, 0.5); animation: pulsate 2s infinite; }
.bullet-point:hover { transform: scale(1.2); }
.bullet-content { display: none; }
.carousel-nav-btn { position: absolute; top: 50%; transform: translateY(-50%); background-color: var(--bg-light); border: 1px solid var(--border-color); color: var(--white); width: 50px; height: 50px; border-radius: 50%; cursor: pointer; z-index: 20; transition: background-color 0.3s; }
.carousel-nav-btn:hover { background-color: var(--accent-blue); }
#prev-btn { left: -60px; }
#next-btn { right: -60px; }
.bullet-point.is-hidden { opacity: 0; pointer-events: none; animation: none; }
@keyframes nudge-scroll-transform { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-30px); } }
.slide-content[data-scrollable="true"].has-nudge-animation .screen-content { animation: nudge-scroll-transform 2s ease-in-out 1 forwards; }
.slide-content[data-scrollable="true"].current-slide { cursor: grab; }
.slide-content[data-scrollable="true"].is-grabbing { cursor: grabbing; }
.carousel-dots { text-align: center; margin-top: 1rem; }
.carousel-dot { display: inline-block; width: 12px; height: 12px; margin: 0 6px; background-color: var(--border-color); border-radius: 50%; border: none; padding: 0; cursor: pointer; transition: all 0.3s ease; }
.carousel-dot:hover { background-color: var(--text-secondary); }
.carousel-dot.active { background-color: var(--accent-blue); transform: scale(1.3); }

/* 5.6 TESTIMONIALS & PRICING & FAQ */
.testimonial-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.testimonial-card { background-color: var(--bg-light); padding: 30px; border-radius: 12px; border: 1px solid var(--border-color); }
.testimonial-card p { font-style: italic; margin-bottom: 20px; }
.testimonial-card .author { font-weight: 600; color: var(--white); }
#pricing { background-color: var(--bg-light); }
#pricing .subtitle { text-align: center; max-width: 500px; margin: -30px auto 50px; }
.pricing-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; align-items: stretch; }
.pricing-card { background-color: var(--bg-dark); padding: 30px; border-radius: 12px; border: 1px solid var(--border-color); text-align: center; transition: transform 0.3s ease, box-shadow 0.3s ease; display: flex; flex-direction: column; }
.pricing-card:hover { transform: translateY(-10px); }
.pricing-card p { flex-grow: 1; }
.annual-price { font-size: 0.9rem; color: var(--text-secondary); margin-top: -15px; font-weight: 600; }
.pricing-card.popular { border: 2px solid var(--accent-blue); transform: scale(1.05); position: relative; }
.popular-badge { position: absolute; top: -15px; left: 50%; transform: translateX(-50%); background-color: var(--accent-blue); color: var(--white); padding: 5px 15px; border-radius: 20px; font-size: .8rem; font-weight: 700; }
.pricing-card.lifetime { border: 2px solid var(--accent-gold); }
.pricing-card.lifetime .btn-secondary { border-color: var(--accent-gold); color: var(--accent-gold); }
.pricing-card.lifetime .btn-secondary:hover { background-color: rgba(255,193,7,.1); }
.pricing-card h3 { font-size: 1.5rem; }
.pricing-card .price { font-size: 2.8rem; font-weight: 900; margin: 10px 0; color: var(--white); }
.pricing-card .price sup { font-size: 1.5rem; font-weight: 600; }
.pricing-card .price span { font-size: 1rem; font-weight: 400; color: var(--text-secondary); }
.pricing-card ul { list-style: none; margin: 30px 0; text-align: left; flex-grow: 1; }
.pricing-card li { margin-bottom: 15px; }
.pricing-card li i { margin-right: 10px; width: 20px; }
.pricing-card li .fa-check { color: var(--accent-blue); }
.pricing-card li .fa-times { color: #666; }
.pricing-card .btn { width: 100%; margin-top: auto; }
.faq-accordion { max-width: 800px; margin: 0 auto; }
.faq-accordion details { background-color: var(--bg-light); border-bottom: 1px solid var(--border-color); margin-bottom: 10px; border-radius: 8px; }
.faq-accordion summary { padding: 20px; font-weight: 600; cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; color: var(--text-primary); }
.faq-accordion summary::after { content: '\f078'; font-family: 'Font Awesome 6 Free'; font-weight: 900; transition: transform .3s ease; }
.faq-accordion details[open] summary { color: var(--accent-blue); }
.faq-accordion details[open] summary::after { transform: rotate(180deg); }
.faq-accordion details p { padding: 0 20px 20px; margin: 0; }
.faq-link-container { text-align: center; margin-top: 50px; }

/* 5.7 FINAL CTA & FOOTER */
#final-cta { background-color: var(--accent-blue); text-align: center;  padding-bottom: 40px; max-height: 1000px; /* big enough for full content */
  transition: max-height 0.5s ease, padding 0.5s ease; }
#final-cta.collapsed {
  max-height: 0;
  padding-top: 0;
  padding-bottom: 0;
  overflow: hidden;
  transition: max-height 0.5s ease, padding 0.5s ease;
}
#final-cta h2, #final-cta p { color: var(--white); }
#final-cta h2 { font-size: 2.8rem; }
.main-footer { background-color: #000; padding: 60px 0; border-top: 1px solid var(--border-color); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr 1fr; gap: 40px; }
.footer-logo { height: 40px; margin-bottom: 15px; opacity: .8; }
.footer-col h4 { font-size: 1.1rem; margin-bottom: 15px; color: var(--white); }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { color: var(--text-secondary); transition: color .3s; }
.footer-col a:hover { color: var(--accent-blue); }
.social-links a { font-size: 1.5rem; margin-right: 15px; }
.social-links a:last-child { margin-right: 0; }


/* ==========================================================================
   6. MODALS & OVERLAYS
   ========================================================================== */

/* 6.1 VIDEO LIGHTBOX (MODAL) */
.video-modal { position: fixed; inset: 0; z-index: 2000; background-color: rgba(0,0,0,.85); display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity .3s ease; visibility: hidden; }
.video-modal:not([hidden]) { opacity: 1; visibility: visible; }
.video-modal-content { position: relative; width: 90%; max-width: 900px; max-height: 90vh; aspect-ratio: 16 / 9; transform: scale(.95); transition: transform .3s ease; box-shadow: 0 10px 40px rgba(0,0,0,.5); }
.video-modal:not([hidden]) .video-modal-content { transform: scale(1); }
#promo-video-player { width: 100%; height: 100%; border-radius: 16px; border: 2px solid var(--border-color); }
.close-modal-btn { position: absolute; top: -15px; right: -15px; width: 40px; height: 40px; background: var(--bg-light); color: var(--white); border: 1px solid var(--border-color); border-radius: 50%; font-size: 2rem; font-weight: 300; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; padding-bottom: 4px; transition: transform .3s ease,background-color .3s ease; z-index: 10; }
.close-modal-btn:hover { transform: scale(1.1) rotate(90deg); background-color: var(--accent-blue); }
[hidden] {
  display: none !important;
}


/* Tooltip Portal (dynamically created) */
#tooltip-portal { position: fixed; z-index: 2000; background-color: var(--bg-light); padding: 15px; border-radius: 8px; width: 220px; text-align: left; box-shadow: 0 5px 15px rgba(0,0,0,0.3); opacity: 0; transform-origin: top center; transition: opacity 0.2s ease, transform 0.2s ease; pointer-events: none; transform: scale(0.9); }
#tooltip-portal.is-visible { opacity: 1; transform: scale(1); }
#tooltip-portal h4 { font-size: 1rem; color: var(--accent-blue); margin-bottom: 5px; }
#tooltip-portal p { font-size: 0.9rem; margin: 0; color: var(--text-secondary); line-height: 1.4; }

#hero-video-container {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999; /* Above hero video */
}

#hero-video-container .video-content {
    position: relative;
    width: 90%;
    max-width: 900px;
    aspect-ratio: 16 / 9;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
}

#close-modal-btn {
    position: absolute;
    top: -15px;
    right: -15px;
    width: 40px;
    height: 40px;
    background: #1a1a1a;
    color: #fff;
    font-size: 2rem;
    border: 1px solid #333;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
}


/* ==========================================================================
   7. FLOATING & FIXED ELEMENTS
   ========================================================================== */

#backToTop { position: fixed; bottom: 30px; right: 30px; background-color: var(--accent-blue); color: var(--white); width: 50px; height: 50px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; box-shadow: 0 4px 10px rgba(0,0,0,.3); text-decoration: none; opacity: 0; visibility: hidden; transform: translateY(20px); transition: opacity .3s,visibility .3s,transform .3s; z-index: 1000; }
#backToTop.visible { opacity: 1; visibility: visible; transform: translateY(0); }
#backToTop:hover { background-color: var(--accent-blue-dark); }

/* ==========================================================================
   8. CONTENT PAGES (FAQ, LEGAL)
   ========================================================================== */
#legal-content, #faq-page-content { padding: 80px 0; background-color: var(--bg-dark); }
#legal-content .container, #faq-page-content .container { max-width: 900px; }
#legal-content h1, #faq-page-content h1 { font-size: clamp(2.5rem,6vw,4rem); text-align: center; color: var(--accent-blue); margin-bottom: 10px; }
#legal-content .subtitle, #faq-page-content .subtitle { text-align: center; color: var(--text-secondary); font-weight: 600; margin-bottom: 60px; }
#legal-content h2, #faq-page-content h2 { font-size: 1.8rem; text-align: left; color: var(--white); border-bottom: 1px solid var(--border-color); padding-bottom: 10px; margin-top: 40px; margin-bottom: 30px; }
#legal-content p, #legal-content li, #faq-page-content p, #faq-page-content li { color: var(--text-primary); opacity: .9; margin-bottom: 20px; line-height: 1.7; }
#legal-content ul, #faq-page-content ul { list-style-type: disc; list-style-position: inside; padding-left: 20px; }
#legal-content a, #faq-page-content a { font-weight: 600; text-decoration: underline; }
#legal-content a:hover, #faq-page-content a:hover { color: var(--accent-blue-dark); }
.faq-category-title { font-size: 1.8rem; color: var(--white); text-align: left; margin-top: 50px; margin-bottom: 20px; padding-bottom: 10px; border-bottom: 1px solid var(--border-color); }
#faq-page-content .faq-accordion { max-width: 100%; }
.faq-accordion pre { background-color: var(--bg-dark); border: 1px solid var(--border-color); border-radius: 8px; padding: 1rem; margin-top: 1rem; font-family: 'Menlo','Consolas',monospace; font-size: .9rem; white-space: pre-wrap; color: var(--text-secondary); }
.faq-contact { text-align: center; background-color: var(--bg-medium); border: 1px solid var(--border-color); border-radius: 12px; padding: 40px; margin-top: 80px; }
.faq-contact h3 { font-size: 1.8rem; color: var(--white); }
.faq-contact p { font-size: 1.1rem; max-width: 500px; margin: 0 auto 30px; }


/* ==========================================================================
   9. RESPONSIVE DESIGN
   ========================================================================== */
@media (max-width: 1200px) {
    .pricing-grid { grid-template-columns: repeat(2,1fr); gap: 30px; }
    .pricing-card { margin-bottom: 20px; }
    .pricing-card.popular { transform: scale(1); }
    #prev-btn, #next-btn { display: none; } /* Hide side arrows on smaller screens */
}
@media (max-width: 992px) {
    h2 { font-size: 2.2rem; }
    .carousel-slide { flex: 0 0 50%; max-width: 50%; }
    .advantage-grid { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
    .nav-links { display: none; flex-direction: column; position: absolute; top: 100%; left: 0; width: 100%; background-color: var(--bg-medium); padding: 20px 0; }
    .nav-links.is-active { display: flex; }
    .mobile-nav-toggle { display: block; }
    .header-btn { display: none; }
    #hero h1 { font-size: 3rem; }
    #hero .subtitle { font-size: 1rem; }
    .pricing-grid { grid-template-columns: 1fr; }
    .pricing-card { max-width: 450px; margin: 0 auto 30px; }
    .footer-grid { grid-template-columns: 1fr 1fr; text-align: center; }
    .footer-col:first-child { grid-column: 1 / -1; }
    .social-links { justify-content: center; }

    /* START: Carousel Mobile Fixes */
    #app-carousel .container {
        padding-left: 0;
        padding-right: 0;
    }
    .carousel-slide {
        flex: 0 0 100%;
        max-width: 100%;
        /* Widen padding to give the full-width slide some breathing room */
        padding: 0 40px;
        /* On mobile, remove the scaling effect for a cleaner, full-width look */
        transform: none;
        opacity: 1;
    }
    .carousel-slide.current-slide {
        /* Ensure the current slide also has its transform reset */
        transform: none;
        opacity: 1;
    }
    /* END: Carousel Mobile Fixes */

    .carousel-viewport {
        padding: 3rem 0;
    }
    #hubspot-form-hero form.hs-form>fieldset {
        flex-direction: column;
    }
    .hs-submit {
        width: 100%;
    }
}
@media (max-width: 480px) {
    #hero h1 { font-size: 2.5rem; }
}

/* ==========================================================================
   10. HUBSPOT FORM
   ========================================================================== */
.form-card {
  border: 0px solid var(--border-color);
  border-radius: 12px;
  margin-bottom: 0;
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

#final-cta .form-message {
  margin-top: 1rem;
  margin-bottom: 0;
}

#final-cta h2 {
  font-size: 2rem;
  margin-bottom: 0.75rem;
  color: var(--white);
}

#final-cta .form-card p {
  color: var(--white); /* High contrast text */
}

#final-cta p {
  color: var(--text-secondary);
  margin-bottom: 2rem;
  font-size: 1rem;
}

/* Remove extra space below submit button in final CTA */
#final-cta .form-container form {
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
}

/* Prevent HubSpot from injecting spacing after the form */
#hubspot-form-final > div:last-child {
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
}

.form-container form {
  max-width: 100%;
  text-align: left;
}

form.hs-form .hs-form-field {
  margin-bottom: 1.25rem;
}

form.hs-form input[type="text"],
form.hs-form input[type="email"],
form.hs-form input[type="tel"],
form.hs-form textarea,
form.hs-form select {
  width: 100%;
  padding: 14px 16px;
  border-radius: 8px;
  border: 2px solid var(--border-color);
  background-color: rgba(0, 0, 0, 0.2);
  color: var(--text-primary);
  font-size: 1rem;
  font-family: 'Poppins', sans-serif;
  transition: border-color 0.3s, box-shadow 0.3s;
}

form.hs-form input:focus,
form.hs-form textarea:focus,
form.hs-form select:focus {
  border-color: var(--accent-blue);
  box-shadow: 0 0 0 3px rgba(0, 174, 239, 0.2);
  outline: none;
  background-color: rgba(0, 0, 0, 0.5);
}

form.hs-form .hs-button {
  background-color: var(--accent-blue);
  color: var(--white);
  border: none;
  padding: 14px 28px;
  font-size: 1rem;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  transition: background-color 0.3s ease;
}

form.hs-form .hs-button:hover {
  background-color: var(--accent-blue-dark);
}

@media (max-width: 768px) {
  #hero {
    min-height: 100vh !important;
    height: 100vh !important;
    position: relative !important;
    overflow: hidden !important;
  }
  .hero-background-video {
    display: block !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover !important;
    z-index: 1 !important;
    background: #000 !important;
    transform: none !important;
  }
  #hero .container,
  .hero-content-wrapper,
  .hero-content {
    position: relative;
    z-index: 2;
  }
}

@media (max-width: 900px) {
  #hero {
    position: relative !important;
    min-height: 100vh !important;
    height: 100vh !important;
    width: 100vw !important;
    overflow: hidden !important;
  }
  #hero .hero-background-video {
    display: block !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    min-width: 100vw !important;
    min-height: 100vh !important;
    object-fit: cover !important;
    background: #000 !important;
    z-index: 1 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    transform: none !important;
  }
  #hero .container,
  #hero .hero-content-wrapper,
  #hero .hero-content {
    position: relative !important;
    z-index: 2 !important;
  }
}