/* Base styles and variables */
:root {
    --color-red: #8B0000;
    --color-red-glow: rgba(139, 0, 0, 0.4);
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
    font-family: var(--font-primary);
    background-color: #050505;
    margin: 0;
    overscroll-behavior: none;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 1. HERO & 3D SCROLL ZONE */
#hero-scroll-zone {
    /* Limit the scroll to 350vh for the hero before the next section arrives */
    height: 350vh;
    position: relative;
    width: 100%;
}

.sticky-canvas-container {
    position: sticky;
    top: 0;
    width: 100%;
    height: 100vh;
    height: 100lvh;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
    overflow: hidden;
    background: radial-gradient(circle at center, #1a0808 0%, #050505 100%);
}

#apple-sequence, #fallback-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 2;
}

#fallback-img.hidden {
    display: none !important;
}

.canvas-glow {
    position: absolute;
    width: 250px;
    height: 250px;
    background: var(--color-red-glow);
    border-radius: 50%;
    filter: blur(100px);
    z-index: 1;
    animation: pulse 4s infinite alternate ease-in-out;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

@keyframes pulse {
    0% { transform: translate(-50%, -50%) scale(0.8); opacity: 0.5; }
    100% { transform: translate(-50%, -50%) scale(1.2); opacity: 0.9; }
}

.ui-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    height: 100lvh;
    z-index: 20;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 2.5rem 1.5rem;
    box-sizing: border-box;
    background:
        radial-gradient(ellipse at center, transparent 30%, rgba(0,0,0,0.75) 100%),
        linear-gradient(to bottom, rgba(0,0,0,0.35) 0%, transparent 25%, transparent 65%, rgba(0,0,0,0.75) 100%);
}

.hero-content {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1.6s cubic-bezier(0.16, 1, 0.3, 1) 0.3s forwards;
    pointer-events: none;
    text-align: center;
    margin-top: 0;
}

@keyframes fadeInUp {
    to { opacity: 1; transform: translateY(0); }
}

.hero-title {
    font-size: clamp(28px, 8vw, 64px);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1.05;
    margin-bottom: 0.75rem;
    /* Multi-layer premium gradient typography */
    background: linear-gradient(160deg,
        #ffffff 0%,
        #f0f0f0 30%,
        #d4d4d4 60%,
        #a0a0b0 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 2px 12px rgba(255,255,255,0.25));
}

.hero-subtitle {
    font-size: clamp(14px, 4vw, 20px);
    color: rgba(200,200,210,0.85);
    font-weight: 400;
    margin-bottom: 2rem;
    max-width: 360px;
    margin-inline: auto;
    letter-spacing: 0.01em;
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 14px;
    width: 100%;
    max-width: 280px;
    margin: 0 auto;
}

.btn {
    width: 100%;
    padding: 18px 32px;
    border-radius: 999px;
    font-size: 17px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    outline: none;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

.btn-sm {
    padding: 14px 24px;
    font-size: 15px;
}

.btn-primary {
    background-color: rgba(255, 255, 255, 0.95);
    color: #000;
    border: 1px solid rgba(255, 255, 255, 1);
    box-shadow: 0 10px 30px -10px rgba(255, 255, 255, 0.4);
}

.btn-primary:hover, .btn-primary:active {
    background-color: #fff;
    transform: scale(0.97);
    box-shadow: 0 6px 16px -8px rgba(255, 255, 255, 0.6);
}

.btn-secondary {
    background-color: rgba(255, 255, 255, 0.04);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-secondary:hover, .btn-secondary:active {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.4);
    transform: scale(0.97);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 2vh;
    left: 0;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    opacity: 0;
    animation: fadeIn 1s ease-out 1.5s forwards;
}

.scroll-text {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(255, 255, 255, 0.6);
}

.scroll-line {
    width: 1px;
    height: 50px;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.6), transparent);
    animation: scrollSlide 2s infinite cubic-bezier(0.645, 0.045, 0.355, 1);
    transform-origin: top;
}

@keyframes scrollSlide {
    0% { transform: scaleY(0); transform-origin: top; opacity: 1; }
    50% { transform: scaleY(1); transform-origin: top; opacity: 1; }
    50.1% { transform: scaleY(1); transform-origin: bottom; opacity: 1; }
    100% { transform: scaleY(0); transform-origin: bottom; opacity: 0; }
}

/* Loading Screen */
.loading-bg { background-color: #050505; }
.spinner {
    width: 40px; height: 40px;
    border: 3px solid rgba(255,255,255,0.1);
    border-top-color: var(--color-red);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}
@keyframes spin { to { transform: rotate(360deg); } }
.loading-text { font-size: 12px; color: rgba(255,255,255,0.5); letter-spacing: 0.2em; text-transform: uppercase; }

/* 2. GLOBAL COMPONENTS & LAYOUT */
.section-padding { padding: 10rem 0; }
@media (max-width: 768px) { .section-padding { padding: 7rem 0; } }

.section-title {
    font-size: clamp(28px, 6vw, 48px);
    font-weight: 600;
    letter-spacing: -0.03em;
    background: linear-gradient(180deg, #fff 0%, #86868b 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}
.section-desc {
    font-size: clamp(17px, 4vw, 21px);
    color: #86868b;
    font-weight: 400;
    line-height: 1.5;
    letter-spacing: -0.01em;
}

/* Reveal Up Animation Core */
.reveal-up {
    opacity: 0;
    transform: translateY(40px);
    transition: all 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-up.active {
    opacity: 1;
    transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.15s; }
.reveal-delay-2 { transition-delay: 0.3s; }
.reveal-delay-3 { transition-delay: 0.45s; }

/* 3. PRODUCTS SECTION */
.product-card {
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.04);
    border-radius: 28px;
    overflow: hidden;
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 20px 40px -20px rgba(0,0,0,0.5);
}
.product-card:hover {
    transform: translateY(-8px) scale(1.02);
    background: rgba(255,255,255,0.05);
    border-color: rgba(255,255,255,0.1);
    box-shadow: 0 30px 60px -20px rgba(0,0,0,0.8);
}
.product-img-wrapper {
    height: 300px;
    width: 100%;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Premium Placeholders */
.bg-gradient-red { background: radial-gradient(circle at center, rgba(163,29,29,0.3) 0%, transparent 70%); }
.bg-gradient-yellow { background: radial-gradient(circle at center, rgba(163,136,29,0.3) 0%, transparent 70%); }
.bg-gradient-green { background: radial-gradient(circle at center, rgba(74,163,29,0.3) 0%, transparent 70%); }

.badge {
    text-transform: uppercase;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.12em;
    padding: 6px 14px;
    border-radius: 999px;
}
.product-title {
    font-size: 26px;
    font-weight: 600;
    letter-spacing: -0.02em;
}
.product-desc {
    font-size: 15px;
    color: #86868b;
    margin-top: 10px;
    line-height: 1.5;
}

/* 4. PROCESS SECTION */
.step-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    border: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 16px;
    position: relative;
    z-index: 2;
}
.process-step { position: relative; flex: 1; }
.step-title { font-size: 20px; font-weight: 600; margin-bottom: 6px; letter-spacing: -0.01em; }
.step-desc { font-size: 15px; color: #86868b; line-height: 1.5; }

@media (max-width: 767px) {
    .process-step::before {
        content: ''; position: absolute; left: -24px; top: 24px;
        width: 16px; height: 1px; background: rgba(255,255,255,0.2);
    }
}
@media (min-width: 768px) {
    .process-container::before {
        content: ''; position: absolute; left: 24px; right: calc(100% / 4 + 24px); top: 24px;
        height: 1px; background: rgba(255,255,255,0.1); z-index: 1;
    }
}

/* 5. TRUST SECTION */
.bg-radial-trust { background: radial-gradient(ellipse at bottom, rgba(20,20,20,1) 0%, #050505 100%); }
.trust-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.trust-value {
    font-size: clamp(28px, 5vw, 48px);
    font-weight: 600;
    margin-bottom: 4px;
    letter-spacing: -0.02em;
}
.trust-label { font-size: 13px; color: #86868b; text-transform: uppercase; letter-spacing: 0.15em; font-weight: 500; }

/* 7. FORM FIELDS */
.input-field {
    width: 100%;
    background: rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
    padding: 16px 18px;
    color: #fff;
    font-size: 16px;
    outline: none;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.input-field:focus {
    border-color: rgba(255,255,255,0.4);
    background: rgba(255,255,255,0.04);
    box-shadow: 0 0 0 4px rgba(255,255,255,0.05);
}
.input-field::placeholder { color: #52525b; }

/* ====================================================
   JOURNEY TRACKER — Scroll-animated green line + plane
   ==================================================== */

/* Desktop track wrapper */
.journey-track-wrapper {
    display: none; /* hidden on mobile */
    position: relative;
    padding-top: 36px;   /* space above nodes for plane */
}
@media (min-width: 768px) {
    .journey-track-wrapper { display: block; }
}

/* Grey background track line */
.journey-track-bg {
    position: absolute;
    top: 36px; /* vertically centred on the nodes */
    left: 0; right: 0;
    height: 2px;
    background: #27272a;
    border-radius: 999px;
}

/* Green fill — width grows from 0% → 100% via JS */
.journey-track-fill {
    position: absolute;
    top: 36px;
    left: 0;
    height: 2px;
    width: 0%;
    background: linear-gradient(90deg, #22C55E, #16A34A);
    border-radius: 999px;
    transition: width 0.08s linear;
    box-shadow: 0 0 10px rgba(34, 197, 94, 0.55);
}

/* Plane icon — slides horizontally with the fill */
.journey-plane {
    position: absolute;
    top: 16px;            /* sits above the track line */
    left: 0%;
    transform: translateX(-50%);
    width: 28px;
    height: 28px;
    color: #22C55E;
    transition: left 0.08s linear;
    filter: drop-shadow(0 0 6px rgba(34,197,94,0.7));
}
.journey-plane svg {
    width: 100%;
    height: 100%;
}

/* Steps row — sits on top of track */
.journey-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    z-index: 2;
}

/* Each step */
.journey-step {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0 0.5rem;
}

/* Number node circle */
.journey-node {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #18181b;
    border: 2px solid #3f3f46;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    color: #71717a;
    margin-bottom: 1.25rem;
    transition: all 0.45s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    z-index: 3;
}

/* Active / reached node */
.journey-node.reached {
    background: rgba(34, 197, 94, 0.12);
    border-color: #22C55E;
    color: #22C55E;
    box-shadow: 0 0 18px rgba(34, 197, 94, 0.35);
}

.journey-step-title {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    margin: 0 0 0.4rem;
}
.journey-step-desc {
    font-size: 13px;
    color: #71717a;
    line-height: 1.55;
    max-width: 160px;
}

/* ---- MOBILE vertical variant ---- */
.journey-mobile {
    display: block;
    position: relative;
    padding-left: 1.75rem;
}
@media (min-width: 768px) {
    .journey-mobile { display: none; }
}

/* Vertical grey track */
.journey-mobile-line {
    position: absolute;
    left: 13px;
    top: 0;
    width: 2px;
    height: 100%;
    background: #27272a;
    border-radius: 999px;
}

/* Green fill on mobile (height grows) */
.journey-mobile-fill {
    position: absolute;
    left: 13px;
    top: 0;
    width: 2px;
    height: 0%;
    background: linear-gradient(180deg, #22C55E, #16A34A);
    border-radius: 999px;
    transition: height 0.08s linear;
    box-shadow: 0 0 8px rgba(34,197,94,0.5);
    z-index: 1;
}

.journey-mobile-steps {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.journey-mobile-step {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    position: relative;
    z-index: 2;
}

.jm-node {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #18181b;
    border: 2px solid #3f3f46;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: #71717a;
    flex-shrink: 0;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.jm-node.active-m {
    background: rgba(34, 197, 94, 0.12);
    border-color: #22C55E;
    color: #22C55E;
    box-shadow: 0 0 14px rgba(34, 197, 94, 0.35);
}

/* --- Brochure & Utility --- */
.spinner-sm {
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255,255,255,0.2);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

[onclick="downloadBrochure()"]:active {
    transform: scale(0.95);
}

/* --- Video Gallery Carousel --- */
.video-carousel {
    scroll-behavior: smooth;
    -ms-overflow-style: none; /* IE and Edge */
    scrollbar-width: none; /* Firefox */
}
.video-carousel::-webkit-scrollbar {
    display: none; /* Chrome, Safari and Opera */
}

@keyframes bounce-x {
    0%, 100% { transform: translateX(-25%); animation-timing-function: cubic-bezier(0.8, 0, 1, 1); }
    50% { transform: translateX(0); animation-timing-function: cubic-bezier(0, 0, 0.2, 1); }
}
.animate-bounce-x {
    animation: bounce-x 1s infinite;
}
