/* ═══════════════════════════════════════════════════════════
   i2x Landing Page — style.css
   Stack: Vanilla CSS, no frameworks
   Font: Inter — self-hosted in assets/fonts/ (DSGVO-compliant)
   Primary: #4550E6
═══════════════════════════════════════════════════════════ */

/* ── Inter — self-hosted, no Google Fonts request ──────── */
/* Paths resolve relative to this CSS file (css/style.css). */
/* cyrillic-ext */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 800;
    font-display: swap;
    src: url('../assets/fonts/inter-v20-cyrillic-ext.woff2') format('woff2');
    unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* cyrillic */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 800;
    font-display: swap;
    src: url('../assets/fonts/inter-v20-cyrillic.woff2') format('woff2');
    unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* greek-ext */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 800;
    font-display: swap;
    src: url('../assets/fonts/inter-v20-greek-ext.woff2') format('woff2');
    unicode-range: U+1F00-1FFF;
}
/* greek */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 800;
    font-display: swap;
    src: url('../assets/fonts/inter-v20-greek.woff2') format('woff2');
    unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
/* vietnamese */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 800;
    font-display: swap;
    src: url('../assets/fonts/inter-v20-vietnamese.woff2') format('woff2');
    unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
/* latin-ext */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 800;
    font-display: swap;
    src: url('../assets/fonts/inter-v20-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* latin */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 800;
    font-display: swap;
    src: url('../assets/fonts/inter-v20-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ── Reset & Base ─────────────────────────────────────── */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family:
        "Inter",
        system-ui,
        -apple-system,
        sans-serif;
    font-weight: 400;
    color: var(--color-text-primary);
    background: var(--bg-page);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

img,
svg {
    display: block;
}

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

ul {
    list-style: none;
}

/* ── CSS Variables ────────────────────────────────────── */
:root {
    --brand: #4550e6;
    --brand-dark: #3340c8;
    --brand-light: #eef0fd;
    --near-black: #161729;
    --gray-light: #f0f1f7;
    --gray-mid: #8b8fa8;
    --gray-border: #e2e4ee;
    --white: #ffffff;
    --green: #22c55e;
    --red-de: #dd0000;
    --gold-de: #ffcc00;

    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;

    --shadow-sm: 0 1px 3px rgba(13, 14, 26, 0.08), 0 1px 2px rgba(13, 14, 26, 0.04);
    --shadow-md: 0 4px 16px rgba(13, 14, 26, 0.1), 0 2px 6px rgba(13, 14, 26, 0.06);
    --shadow-lg: 0 16px 48px rgba(69, 80, 230, 0.15), 0 4px 12px rgba(13, 14, 26, 0.08);

    --nav-h: 68px;
    --container: 1120px;

    /* ── Theme tokens (semantic layer) ──────────────── */
    /* Middle sections — same in both themes */
    --bg-page: var(--white);
    --bg-page-alt: var(--gray-light);
    --bg-card: var(--white);
    --bg-nav: rgba(255, 255, 255, 0.9);
    --color-text-primary: #161729;
    --color-text-body: #4b4e65;
    --color-text-nav: #4b4e65;
    --border-ui: var(--gray-border);
    --brand-icon-bg: var(--brand-light);
    --card-border-base: #D1D5E8;

    /* ── Frame section tokens (dark defaults = current design) ── */
    --bg-hero: var(--near-black);
    --bg-contact: var(--near-black);
    --bg-footer: #111220;

    --hero-heading: var(--white);
    --hero-sub: rgba(255, 255, 255, 0.72);
    --hero-phone: rgba(255, 255, 255, 0.5);
    --hero-phone-link: rgba(255, 255, 255, 0.7);
    --hero-bg-overlay:
        radial-gradient(ellipse 80% 60% at 70% 40%, rgba(69, 80, 230, 0.35) 0%, transparent 70%),
        radial-gradient(ellipse 50% 40% at 20% 80%, rgba(69, 80, 230, 0.15) 0%, transparent 60%);

    --btn-ghost-color: var(--white);
    --btn-ghost-border: rgba(255, 255, 255, 0.4);
    --btn-ghost-hover-bg: rgba(255, 255, 255, 0.12);
    --btn-ghost-hover-border: rgba(255, 255, 255, 0.7);

    --contact-heading: var(--white);
    --contact-sub: rgba(255, 255, 255, 0.65);
    --contact-detail: rgba(255, 255, 255, 0.6);
    --contact-detail-link: rgba(255, 255, 255, 0.7);
    --contact-form-bg: rgba(255, 255, 255, 0.05);
    --contact-form-border: rgba(255, 255, 255, 0.1);
    --contact-input-bg: rgba(255, 255, 255, 0.07);
    --contact-input-border: rgba(255, 255, 255, 0.15);
    --contact-input-color: var(--white);
    --contact-label: rgba(255, 255, 255, 0.7);
    --contact-placeholder: rgba(255, 255, 255, 0.3);
    --contact-privacy: rgba(255, 255, 255, 0.5);
    --contact-privacy-link: rgba(255, 255, 255, 0.7);
    --contact-select-option-bg: #1a1b2e;
    --contact-select-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='rgba(255,255,255,0.4)' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");

    --footer-text: rgba(255, 255, 255, 0.5);
    --footer-brand-p: rgba(255, 255, 255, 0.4);
    --footer-link: rgba(255, 255, 255, 0.4);
    --footer-copy: rgba(255, 255, 255, 0.25);

    /* Demo card (stays dark in both themes — it's a product UI mockup) */
    --demo-card-bg: rgba(255, 255, 255, 0.06);
    --demo-card-border: rgba(255, 255, 255, 0.12);

    /* Label light variant (used on dark frame sections) */
    --label-light-color: rgba(255, 255, 255, 0.7);
    --label-light-bg: rgba(255, 255, 255, 0.12);
}

/* ── Light Theme overrides ──────────────────────────── */
/* The default (:root) IS the dark theme (current design).
   Light mode flips only the "frame" sections:
   hero, contact, footer — the middle content sections
   (logos, stats, features, how, roles, trust) stay white/gray. */

[data-theme="light"],
@media (prefers-color-scheme: light) {
    :root:not([data-theme="dark"]) {
        --bg-hero: #f0f1f7;
        --bg-contact: var(--gray-light);
        --bg-footer: #e2e4ee;

        --hero-heading: var(--near-black);
        --hero-sub: #4b4e65;
        --hero-phone: var(--gray-mid);
        --hero-phone-link: #4b4e65;
        --hero-bg-overlay:
            radial-gradient(ellipse 80% 60% at 70% 40%, rgba(69, 80, 230, 0.1) 0%, transparent 70%),
            radial-gradient(ellipse 50% 40% at 20% 80%, rgba(69, 80, 230, 0.06) 0%, transparent 60%);

        --btn-ghost-color: var(--near-black);
        --btn-ghost-border: rgba(22, 23, 41, 0.3);
        --btn-ghost-hover-bg: rgba(22, 23, 41, 0.06);
        --btn-ghost-hover-border: rgba(22, 23, 41, 0.55);

        --contact-heading: var(--near-black);
        --contact-sub: #4b4e65;
        --contact-detail: #4b4e65;
        --contact-detail-link: #4b4e65;
        --contact-form-bg: var(--white);
        --contact-form-border: var(--gray-border);
        --contact-input-bg: var(--white);
        --contact-input-border: var(--gray-border);
        --contact-input-color: var(--near-black);
        --contact-label: #4b4e65;
        --contact-placeholder: var(--gray-mid);
        --contact-privacy: #4b4e65;
        --contact-privacy-link: #4b4e65;
        --contact-select-option-bg: var(--white);
        --contact-select-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='rgba(22,23,41,0.45)' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");

        --footer-text: #4b4e65;
        --footer-brand-p: #4b4e65;
        --footer-link: var(--gray-mid);
        --footer-copy: var(--gray-mid);

        /* Demo card — keep dark on the light hero */
        --demo-card-bg: rgba(22, 23, 41, 0.88);
        --demo-card-border: rgba(22, 23, 41, 0.14);

        /* Label light variant — use brand colours on light bg */
        --label-light-color: var(--brand);
        --label-light-bg: var(--brand-light);
    }
}

/* Explicit [data-theme="light"] duplicated for specificity when set by JS */
[data-theme="light"] {
    --bg-hero: #f0f1f7;
    --bg-contact: var(--gray-light);
    --bg-footer: #e2e4ee;

    --hero-heading: var(--near-black);
    --hero-sub: #4b4e65;
    --hero-phone: var(--gray-mid);
    --hero-phone-link: #4b4e65;
    --hero-bg-overlay:
        radial-gradient(ellipse 80% 60% at 70% 40%, rgba(69, 80, 230, 0.1) 0%, transparent 70%),
        radial-gradient(ellipse 50% 40% at 20% 80%, rgba(69, 80, 230, 0.06) 0%, transparent 60%);

    --btn-ghost-color: var(--near-black);
    --btn-ghost-border: rgba(22, 23, 41, 0.3);
    --btn-ghost-hover-bg: rgba(22, 23, 41, 0.06);
    --btn-ghost-hover-border: rgba(22, 23, 41, 0.55);

    --contact-heading: var(--near-black);
    --contact-sub: #4b4e65;
    --contact-detail: #4b4e65;
    --contact-detail-link: #4b4e65;
    --contact-form-bg: var(--white);
    --contact-form-border: var(--gray-border);
    --contact-input-bg: var(--white);
    --contact-input-border: var(--gray-border);
    --contact-input-color: var(--near-black);
    --contact-label: #4b4e65;
    --contact-placeholder: var(--gray-mid);
    --contact-privacy: #4b4e65;
    --contact-privacy-link: #4b4e65;
    --contact-select-option-bg: var(--white);
    --contact-select-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='rgba(22,23,41,0.45)' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");

    --footer-text: #4b4e65;
    --footer-brand-p: #4b4e65;
    --footer-link: var(--gray-mid);
    --footer-copy: var(--gray-mid);

    /* Demo card — keep dark on the light hero */
    --demo-card-bg: rgba(22, 23, 41, 0.88);
    --demo-card-border: rgba(22, 23, 41, 0.14);

    /* Label light variant — use brand colours on light bg */
    --label-light-color: var(--brand);
    --label-light-bg: var(--brand-light);
}

/* ── Container ───────────────────────────────────────── */
.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: clamp(1rem, 4vw, 2.5rem);
}

/* ── Typography ──────────────────────────────────────── */
h1,
h2,
h3,
h4 {
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
}

h1 {
    font-size: clamp(2rem, 5vw, 3rem);
}
h2 {
    font-size: clamp(1.6rem, 3.5vw, 2.4rem);
}
h3 {
    font-size: 1.15rem;
    font-weight: 700;
}

p {
    line-height: 1.65;
    color: var(--color-text-body);
}

.label {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--brand);
    background: var(--brand-light);
    padding: 0.3em 0.8em;
    border-radius: 99px;
    margin-bottom: 0.9rem;
}

.label--light {
    color: var(--label-light-color);
    background: var(--label-light-bg);
}

.section-header {
    text-align: center;
    max-width: 680px;
    margin: 0 auto 3.5rem;
}

.section-sub {
    margin-top: 0.9rem;
    font-size: 1.05rem;
}

/* ── Buttons ─────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: inherit;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: var(--radius-sm);
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.18s ease;
    text-decoration: none;
    white-space: nowrap;
    padding: 0.65em 1.4em;
    line-height: 1;
}

.btn--primary {
    background: var(--brand);
    color: var(--white);
    border-color: var(--brand);
}
.btn--primary:hover {
    background: var(--brand-dark);
    border-color: var(--brand-dark);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(69, 80, 230, 0.35);
}

.btn--ghost {
    background: transparent;
    color: var(--btn-ghost-color);
    border-color: var(--btn-ghost-border);
}
.btn--ghost:hover {
    background: var(--btn-ghost-hover-bg);
    border-color: var(--btn-ghost-hover-border);
}

.btn--sm {
    padding: 0.5em 1.1em;
    font-size: 0.875rem;
}
.btn--lg {
    padding: 0.8em 1.8em;
    font-size: 1rem;
}
.btn--full {
    width: 100%;
    justify-content: center;
}

.btn__spinner {
    display: none;
    animation: spin 0.7s linear infinite;
}
.btn--loading .btn__text {
    opacity: 0.5;
}
.btn--loading .btn__spinner {
    display: inline-block;
}

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

/* ── Navigation ──────────────────────────────────────── */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    height: var(--nav-h);
    background: var(--bg-nav);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid transparent;
    transition:
        border-color 0.2s,
        box-shadow 0.2s,
        background 0.3s;
}

.nav--scrolled {
    border-bottom-color: var(--border-ui);
    box-shadow: var(--shadow-sm);
}

.nav__inner {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.nav__logo {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

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

.nav__link {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--color-text-nav);
    transition: color 0.15s;
}
.nav__link:hover {
    color: var(--brand);
}

.nav__actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav__lang {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--gray-mid);
    letter-spacing: 0.05em;
    padding: 0.25em 0.5em;
    border-radius: 4px;
    transition:
        color 0.15s,
        background 0.15s;
}
.nav__lang:hover {
    color: var(--brand);
    background: var(--brand-light);
}

.nav__hamburger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-text-primary);
    padding: 0.25rem;
}

.nav__mobile {
    display: none;
    flex-direction: column;
    padding: 1rem 1.5rem 1.5rem;
    background: var(--bg-page);
    border-top: 1px solid var(--border-ui);
    gap: 0.25rem;
}

.nav__mobile-link {
    padding: 0.75rem 0;
    font-weight: 500;
    color: var(--color-text-nav);
    border-bottom: 1px solid var(--border-ui);
    transition: color 0.15s;
}
.nav__mobile-link:hover {
    color: var(--brand);
}

.nav__mobile.is-open {
    display: flex;
}

/* ── Hero ────────────────────────────────────────────── */
.hero {
    position: relative;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    background: var(--bg-hero);
    overflow: hidden;
    padding-top: var(--nav-h);
}

.hero__bg {
    position: absolute;
    inset: 0;
    background: var(--hero-bg-overlay);
    animation: heroBgPulse 8s ease-in-out infinite alternate;
}

@keyframes heroBgPulse {
    from {
        opacity: 0.7;
    }
    to {
        opacity: 1;
    }
}

.hero__inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    padding-block: 6rem;
}

.hero__content {
    color: var(--hero-heading);
}
.hero__content .label {
    margin-bottom: 1.2rem;
}

.hero__content h1 {
    color: var(--hero-heading);
    margin-bottom: 1.2rem;
}

.hero__sub {
    font-size: 1.1rem;
    color: var(--hero-sub);
    max-width: 520px;
    margin-bottom: 2rem;
    line-height: 1.7;
}

.hero__ctas {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1.8rem;
}

.hero__phone {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--hero-phone);
}
.hero__phone svg {
    color: var(--hero-phone);
    opacity: 0.7;
}
.hero__phone a {
    color: var(--hero-phone-link);
    transition: color 0.15s;
}
.hero__phone a:hover {
    color: var(--hero-heading);
}

/* Demo card */
.hero__demo {
    display: flex;
    justify-content: center;
}

.demo-card {
    background: var(--demo-card-bg);
    border: 1px solid var(--demo-card-border);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    width: 100%;
    max-width: 400px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.demo-card__header {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.8rem 1.2rem;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.demo-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}
.demo-dot--red {
    background: #ff5f57;
}
.demo-dot--yellow {
    background: #febc2e;
}
.demo-dot--green {
    background: #28c840;
}

.demo-card__title {
    margin-left: 0.5rem;
    font-size: 0.78rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.5);
}

.demo-card__call {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.demo-call-icon {
    width: 36px;
    height: 36px;
    background: rgba(34, 197, 94, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.demo-call-label {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.45);
    font-weight: 500;
}

.demo-call-timer {
    font-size: 1rem;
    font-weight: 700;
    color: var(--white);
    font-variant-numeric: tabular-nums;
}

.demo-call-quality {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.5);
}
.demo-call-quality strong {
    color: var(--green);
}

.demo-card__suggestions {
    padding: 1rem 1.2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.demo-label {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.35);
    margin-bottom: 0.8rem;
}

.demo-suggestion {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.5);
    padding: 0.45rem 0.6rem;
    border-radius: var(--radius-sm);
    margin-bottom: 0.35rem;
    transition: all 0.3s ease;
}
.demo-suggestion svg {
    flex-shrink: 0;
    margin-top: 1px;
}

.demo-suggestion--active {
    color: var(--white);
    background: rgba(69, 80, 230, 0.3);
    border: 1px solid rgba(69, 80, 230, 0.5);
}

.demo-card__waveform {
    padding: 0.8rem 1.2rem;
}

.waveform {
    display: flex;
    align-items: center;
    gap: 3px;
    height: 32px;
}

.waveform-bar {
    width: 3px;
    background: rgba(69, 80, 230, 0.5);
    border-radius: 2px;
    animation: waveAnim 1.2s ease-in-out infinite;
}

@keyframes waveAnim {
    0%,
    100% {
        transform: scaleY(0.3);
    }
    50% {
        transform: scaleY(1);
    }
}

/* ── Client Logos ─────────────────────────────────────── */
.logos {
    padding: 2.5rem 0;
    border-top: 1px solid var(--border-ui);
    border-bottom: 1px solid var(--border-ui);
    background: var(--bg-page);
}

.logos__label {
    text-align: center;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--gray-mid);
    margin-bottom: 1.6rem;
}

.logos__grid {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2.5rem 3.5rem;
}

.logos__item {
    opacity: 0.55;
    transition: opacity 0.2s;
    filter: grayscale(100%);
}
.logos__item img {
    display: block;
    height: 28px;
    width: auto;
    max-width: 160px;
    object-fit: contain;
}
.logos__item:hover {
    opacity: 0.8;
    filter: grayscale(0%);
}

/* ── Stats ────────────────────────────────────────────── */
.stats {
    padding: 4.5rem 0;
    background: var(--bg-page-alt);
}

.stats__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.stat-card {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 2rem 1.5rem;
    text-align: center;
}

.stat-card__num {
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 800;
    color: var(--brand);
    line-height: 1;
    margin-bottom: 0.5rem;
    letter-spacing: -0.03em;
}

.stat-card__label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: 0.4rem;
}

.stat-card__note {
    font-size: 0.72rem;
    color: var(--gray-mid);
    line-height: 1.5;
}

/* ── Features ─────────────────────────────────────────── */
.features {
    padding: 6rem 0;
    background: var(--bg-page);
}

.features__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.feature-card {
    background: var(--bg-page-alt);
    border-radius: var(--radius-md);
    padding: 2.5rem 2rem;
}

.feature-card__icon {
    width: 52px;
    height: 52px;
    background: var(--brand-icon-bg);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.2rem;
}

.feature-card h3 {
    margin-bottom: 0.75rem;
}
.feature-card p {
    font-size: 0.92rem;
    margin-bottom: 1.5rem;
}

.feature-card__list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.feature-card__list li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--color-text-body);
}
.feature-card__list li svg {
    flex-shrink: 0;
    margin-top: 2px;
}

/* ── How It Works ─────────────────────────────────────── */
.how {
    padding: 6rem 0;
    background: var(--bg-page-alt);
}

.how__steps {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 0;
}

.how__step {
    flex: 1;
    max-width: 300px;
    text-align: center;
    padding: 2rem 1.5rem;
}

.how__step-num {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    color: var(--brand);
    margin-bottom: 1rem;
}

.how__step-icon {
    width: 64px;
    height: 64px;
    background: var(--brand-icon-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.2rem;
}

.how__step h3 {
    margin-bottom: 0.6rem;
}
.how__step p {
    font-size: 0.9rem;
}

.how__connector {
    display: flex;
    align-items: center;
    padding-top: 80px;
    opacity: 0.4;
}

/* ── Roles ────────────────────────────────────────────── */
.roles {
    padding: 6rem 0;
    background: var(--bg-page);
}

.roles__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.role-card {
    padding: 2rem;
    border-radius: var(--radius-md);
}

.role-card__icon {
    width: 48px;
    height: 48px;
    background: var(--brand-icon-bg);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.role-card h3 {
    margin-bottom: 0.6rem;
}
.role-card p {
    font-size: 0.9rem;
}

/* ── Trust ────────────────────────────────────────────── */
.trust {
    padding: 6rem 0;
    background: var(--bg-page-alt);
}

.trust__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.trust-item {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 2rem 1.75rem;
}

.trust-item__icon {
    width: 48px;
    height: 48px;
    background: var(--brand-icon-bg);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.trust-item h3 {
    margin-bottom: 0.5rem;
    font-size: 1rem;
}
.trust-item p {
    font-size: 0.875rem;
}

/* ── Contact ──────────────────────────────────────────── */
.contact {
    padding: 6rem 0;
    background: var(--bg-contact);
    color: var(--contact-heading);
}

.contact__inner {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 5rem;
    align-items: start;
}

.contact__info h2 {
    color: var(--contact-heading);
    margin-bottom: 1rem;
}
.contact__info p {
    color: var(--contact-sub);
    font-size: 1.05rem;
    margin-bottom: 2rem;
}

.contact__details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact__detail {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9rem;
    color: var(--contact-detail);
}
.contact__detail svg {
    flex-shrink: 0;
    opacity: 0.5;
}
.contact__detail a {
    color: var(--contact-detail-link);
    transition: color 0.15s;
}
.contact__detail a:hover {
    color: var(--contact-heading);
}

/* Contact Form */
.contact__form-wrap {
    background: var(--contact-form-bg);
    border: 1px solid var(--contact-form-border);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.contact__form {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.2rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-group label {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--contact-label);
}
.form-group label span {
    color: var(--brand);
}

.form-group input,
.form-group select,
.form-group textarea {
    background: var(--contact-input-bg);
    border: 1px solid var(--contact-input-border);
    border-radius: var(--radius-sm);
    padding: 0.75rem 1rem;
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--contact-input-color);
    outline: none;
    transition:
        border-color 0.15s,
        box-shadow 0.15s;
    width: 100%;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--contact-placeholder);
}

.form-group select {
    appearance: none;
    background-image: var(--contact-select-arrow);
    background-repeat: no-repeat;
    background-position: right 1rem center;
    cursor: pointer;
}

.form-group select option {
    background: var(--contact-select-option-bg);
    color: var(--contact-input-color);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(69, 80, 230, 0.25);
}

.form-group input.is-invalid,
.form-group select.is-invalid,
.form-group textarea.is-invalid {
    border-color: #ef4444;
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-privacy {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
}

.form-privacy input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin-top: 2px;
    flex-shrink: 0;
    accent-color: var(--brand);
    cursor: pointer;
}

.form-privacy label {
    font-size: 0.78rem;
    color: var(--contact-privacy);
    line-height: 1.5;
    cursor: pointer;
}

.form-privacy label a {
    color: var(--contact-privacy-link);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.form-error {
    font-size: 0.72rem;
    color: #ef4444;
    min-height: 1em;
}

.form-success {
    align-items: center;
    gap: 0.6rem;
    padding: 1rem;
    background: rgba(34, 197, 94, 0.12);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    color: #4ade80;
}

.form-success:not([hidden]) {
    display: flex;
}

.form-error-global {
    padding: 0.75rem 1rem;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    color: #fca5a5;
}

/* ── Footer ───────────────────────────────────────────── */
.footer {
    background: var(--bg-footer);
    padding: 3rem 0;
    color: var(--footer-text);
}

.footer__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    text-align: center;
}

.footer__brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.footer__brand p {
    font-size: 0.85rem;
    color: var(--footer-brand-p);
    line-height: 1.6;
}

/* Footer logo: white fills on dark bg; brand colour on light bg */
[data-theme="light"] .footer__brand svg * {
    fill: var(--brand);
}
@media (prefers-color-scheme: light) {
    :root:not([data-theme="dark"]) .footer__brand svg * {
        fill: var(--brand);
    }
}

.footer__links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem 2rem;
}

.footer__links a {
    font-size: 0.8rem;
    color: var(--footer-link);
    transition: color 0.15s;
}
.footer__links a:hover {
    color: var(--footer-text);
}

.footer__copy {
    font-size: 0.75rem;
    color: var(--footer-copy);
}

/* ── Scroll Animations ────────────────────────────────── */
.fade-up {
    opacity: 0;
    transform: translateY(28px);
    transition:
        opacity 0.55s ease,
        transform 0.55s ease;
}
.fade-up.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-up--delay {
    transition-delay: 0.12s;
}
.fade-up--d1 {
    transition-delay: 0.15s;
}
.fade-up--d2 {
    transition-delay: 0.3s;
}
.fade-up--d3 {
    transition-delay: 0.45s;
}

/* ── Responsive ───────────────────────────────────────── */
@media (max-width: 1024px) {
    .stats__grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .trust__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .hero__inner {
        grid-template-columns: 1fr;
        padding-block: 4rem;
        gap: 3rem;
    }

    .features__grid,
    .roles__grid {
        grid-template-columns: 1fr;
    }

    .contact__inner {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .how__connector {
        display: none;
    }

    .how__steps {
        flex-direction: column;
        align-items: center;
    }

    .how__step {
        max-width: 100%;
        width: 100%;
    }
}

@media (max-width: 768px) {
    .nav__links,
    .nav__actions .btn {
        display: none;
    }
    .nav__hamburger {
        display: flex;
    }

    .stats__grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .trust__grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    h1 {
        font-size: 1.9rem;
    }
    h2 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .stats__grid {
        grid-template-columns: 1fr 1fr;
        gap: 1rem;
    }
    .stat-card {
        padding: 1.25rem 1rem;
    }
    .hero__ctas {
        flex-direction: column;
    }
    .btn--lg {
        width: 100%;
        justify-content: center;
    }
}

/* ── Reduced Motion ───────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    .fade-up {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .waveform-bar {
        animation: none;
    }
    .hero__bg {
        animation: none;
    }
    html {
        scroll-behavior: auto;
    }
}

/* ═══════════════════════════════════════════════════════
   MOUSE-REACTIVE SPOTLIGHT  (Task 5)
   Tracks cursor over .hero / .trust / .contact.
   JS sets --spotlight-x / --spotlight-y via mousemove.
   NOT gated by prefers-reduced-motion — it is a subtle,
   static-position-based glow with no vestibular motion.
   Only heavier continuous animations (waveform, heroBgPulse,
   fade-up transitions) respect prefers-reduced-motion.
═══════════════════════════════════════════════════════ */

.hero,
.trust,
.contact {
    --spotlight-x: 50%;
    --spotlight-y: 50%;
    --spotlight-opacity: 0;
}

.hero::after,
.trust::after,
.contact::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background: radial-gradient(
        600px circle at var(--spotlight-x) var(--spotlight-y),
        rgba(69, 80, 230, 0.18) 0%,
        transparent 70%
    );
    opacity: var(--spotlight-opacity);
    /* opacity fade only — no position animation, safe for vestibular */
    transition: opacity 0.4s ease;
}

.hero > *,
.trust > *,
.contact > * {
    position: relative;
    z-index: 1;
}

/* ═══════════════════════════════════════════════════════
   CARD HOVER EFFECT  (Task 6)
   Technique: the card border transitions from a flat gray
   to a gradient (brand blue bottom → transparent top) on
   hover. A box-shadow glow reinforces the laser feel.

   How it works:
   - Cards start with border: 1px solid transparent (over
     a background-clip: padding-box background, so the
     1px gap shows through to the ::before gradient behind)
   - ::before is inset -1px on all sides, sits behind the
     card content, and carries the gradient border color
   - On hover the gradient shifts from gray → brand blue
     bottom-to-top, and a box-shadow bloom appears
   NOT gated by prefers-reduced-motion (no motion).
═══════════════════════════════════════════════════════ */

.feature-card,
.stat-card,
.role-card,
.trust-item {
    position: relative;
    overflow: visible;
    transition:
        box-shadow 0.35s ease,
        transform  0.2s ease;
}

/* Gradient border layer.
   The mask trick cuts a hole in the centre so only the 1px
   border ring is painted — card interior stays untouched.
   At rest: flat gray. On hover: brand blue bottom → transparent top. */
.feature-card::before,
.stat-card::before,
.role-card::before,
.trust-item::before {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    padding: 1px; /* ring thickness */
    background: var(--card-border-base); /* rest = subtle border */
    /* punch interior hole — only the 1px ring shows */
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    transition: background 0.35s ease;
    pointer-events: none;
    z-index: 0;
}

.feature-card:hover::before,
.stat-card:hover::before,
.role-card:hover::before,
.trust-item:hover::before {
    background: linear-gradient(
        to top,
        rgba(69, 80, 230, 1.0)  0%,
        rgba(69, 80, 230, 0.5) 35%,
        rgba(69, 80, 230, 0.0) 100%
    );
}

.feature-card:hover,
.stat-card:hover,
.role-card:hover,
.trust-item:hover {
    box-shadow:
        0 0 16px 3px rgba(69, 80, 230, 0.15),
        0 0 36px 8px rgba(69, 80, 230, 0.07);
}

/* Logos section stays on white/gray-light in both themes —
   no filter inversion needed. */

/* ═══════════════════════════════════════════════════════
   THEME TOGGLE BUTTON  (nav)
═══════════════════════════════════════════════════════ */
.nav__theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-text-nav);
    padding: 0.3rem;
    display: flex;
    align-items: center;
    border-radius: 4px;
    transition: color 0.15s, background 0.15s;
    flex-shrink: 0;
}

.nav__theme-toggle:hover {
    color: var(--brand);
    background: var(--brand-icon-bg);
}

/* Default = dark mode: show sun (click to go light) */
.theme-icon--sun  { display: block; }
.theme-icon--moon { display: none; }

/* Light mode: show moon (click to go dark) */
[data-theme="light"] .theme-icon--sun  { display: none; }
[data-theme="light"] .theme-icon--moon { display: block; }

@media (prefers-color-scheme: light) {
    :root:not([data-theme="dark"]) .theme-icon--sun  { display: none; }
    :root:not([data-theme="dark"]) .theme-icon--moon { display: block; }
}
