:root {
    --navy-950: #060d18;
    --navy-900: #0a1628;
    --navy-800: #0f2744;
    --navy-700: #1e3a5f;
    --blue-600: #2563eb;
    --blue-500: #3b82f6;
    --blue-400: #60a5fa;
    --blue-300: #93c5fd;
    --blue-glow: rgb(37 99 235 / 0.35);
    --text-primary: #f8fafc;
    --text-secondary: #cbd5e1;
    --text-muted: #94a3b8;
    --border: rgb(255 255 255 / 0.08);
    --border-strong: rgb(255 255 255 / 0.12);
    --glass: rgb(15 23 42 / 0.55);
    --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html {
    height: 100%;
    overflow: hidden;
}

body {
    margin: 0;
    height: 100%;
    overflow: hidden;
    font-family: var(--font);
    color: var(--text-secondary);
    background: var(--navy-950);
    -webkit-font-smoothing: antialiased;
}

/* ── Background ── */
.scene {
    position: fixed;
    inset: 0;
    z-index: 0;
    background:
        radial-gradient(ellipse 80% 60% at 50% 0%, rgb(30 58 95 / 0.5) 0%, transparent 60%),
        linear-gradient(180deg, var(--navy-950) 0%, var(--navy-900) 50%, var(--navy-800) 100%);
}

.scene-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgb(255 255 255 / 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgb(255 255 255 / 0.03) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 50%, black 20%, transparent 80%);
}

.scene-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    animation: drift 18s ease-in-out infinite;
}

.scene-glow--1 {
    top: -20%;
    right: 10%;
    width: 520px;
    height: 520px;
    background: var(--blue-glow);
}

.scene-glow--2 {
    bottom: -25%;
    left: 5%;
    width: 480px;
    height: 480px;
    background: rgb(59 130 246 / 0.2);
    animation-delay: -8s;
}

@keyframes drift {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-20px, 16px); }
}

/* ── Page shell ── */
.page {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100dvh;
    padding: clamp(0.75rem, 2vh, 1.5rem) clamp(1rem, 3vw, 2.5rem);
    overflow: hidden;
}

.shell {
    width: 100%;
    max-width: 1080px;
    animation: enter 0.85s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes enter {
    from { opacity: 0; transform: translateY(20px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ── Main card ── */
.card {
    display: flex;
    flex-direction: column;
    height: min(680px, calc(100dvh - 2rem));
    border-radius: 20px;
    border: 1px solid var(--border-strong);
    background: var(--glass);
    backdrop-filter: blur(24px) saturate(1.4);
    box-shadow:
        0 0 0 1px rgb(255 255 255 / 0.04) inset,
        0 32px 64px rgb(0 0 0 / 0.45),
        0 0 80px rgb(37 99 235 / 0.08);
    overflow: hidden;
}

/* Header */
.card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-shrink: 0;
    padding: clamp(0.875rem, 2vh, 1.125rem) clamp(1.25rem, 3vw, 1.75rem);
    border-bottom: 1px solid var(--border);
    background: rgb(255 255 255 / 0.03);
}

.brand {
    display: flex;
    align-items: center;
    padding: 0.375rem 0.75rem;
    border-radius: 10px;
    background: rgb(255 255 255 / 0.96);
    text-decoration: none;
    box-shadow: 0 2px 12px rgb(0 0 0 / 0.15);
}

.brand__logo {
    display: block;
    height: clamp(1.625rem, 3.5vh, 2rem);
    width: auto;
    object-fit: contain;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.9rem;
    border-radius: 999px;
    border: 1px solid rgb(96 165 250 / 0.2);
    background: linear-gradient(135deg, rgb(37 99 235 / 0.2) 0%, rgb(37 99 235 / 0.08) 100%);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--blue-300);
    white-space: nowrap;
}

.badge__dot {
    position: relative;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--blue-400);
    box-shadow: 0 0 8px var(--blue-400);
}

.badge__dot::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    border: 1px solid var(--blue-400);
    animation: pulse 2.4s ease-out infinite;
}

@keyframes pulse {
    0% { transform: scale(0.8); opacity: 0.8; }
    100% { transform: scale(2); opacity: 0; }
}

/* Body */
.card__body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    flex: 1;
    min-height: 0;
    gap: 0;
}

.copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(1.25rem, 3vh, 2rem) clamp(1.25rem, 3vw, 2rem);
    border-right: 1px solid var(--border);
}

.copy__eyebrow {
    margin: 0;
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--blue-400);
}

.copy__title {
    margin: 0.5rem 0 0;
    font-size: clamp(1.375rem, 2.8vw, 2rem);
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.035em;
    color: var(--text-primary);
}

.copy__sub {
    margin: 0.375rem 0 0;
    font-size: clamp(0.8125rem, 1.5vw, 0.9375rem);
    font-weight: 500;
    color: var(--blue-300);
}

.copy__text {
    margin: clamp(0.75rem, 1.5vh, 1rem) 0 0;
    font-size: clamp(0.8125rem, 1.4vw, 0.875rem);
    line-height: 1.65;
    color: var(--text-secondary);
}

.copy__seo {
    margin: 0.625rem 0 0;
    font-size: clamp(0.75rem, 1.3vw, 0.8125rem);
    line-height: 1.6;
    color: var(--text-muted);
}

.copy__seo strong {
    font-weight: 600;
    color: #e2e8f0;
}

/* Features row */
.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin: clamp(0.875rem, 2vh, 1.25rem) 0 0;
    padding: 0;
    list-style: none;
}

.features__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.375rem;
    padding: 0.625rem 0.375rem;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: rgb(255 255 255 / 0.03);
    font-size: 0.6875rem;
    font-weight: 600;
    text-align: center;
    color: var(--text-primary);
    transition: background 0.2s, border-color 0.2s;
}

.features__item:hover {
    background: rgb(255 255 255 / 0.06);
    border-color: rgb(96 165 250 / 0.2);
}

.features__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 7px;
    background: rgb(37 99 235 / 0.15);
    color: var(--blue-400);
}

.features__icon svg {
    width: 0.875rem;
    height: 0.875rem;
}

/* Preview panel */
.preview {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(1rem, 2.5vh, 1.5rem);
    background:
        radial-gradient(ellipse at 30% 20%, rgb(37 99 235 / 0.12) 0%, transparent 55%),
        rgb(255 255 255 / 0.02);
}

.preview__window {
    width: 100%;
    max-width: 340px;
    padding: 0.875rem;
    border-radius: 14px;
    border: 1px solid var(--border-strong);
    background: rgb(6 13 24 / 0.6);
    box-shadow: 0 16px 40px rgb(0 0 0 / 0.3);
}

.preview__bar {
    display: flex;
    gap: 5px;
    margin-bottom: 0.875rem;
}

.preview__bar span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgb(255 255 255 / 0.12);
}

.preview__bar span:first-child { background: #ef4444; opacity: 0.7; }
.preview__bar span:nth-child(2) { background: #eab308; opacity: 0.7; }
.preview__bar span:nth-child(3) { background: #22c55e; opacity: 0.7; }

.preview__stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-bottom: 0.875rem;
}

.preview__stat {
    padding: 0.5rem 0.375rem;
    border-radius: 8px;
    border: 1px solid var(--border);
    background: rgb(255 255 255 / 0.04);
    text-align: center;
}

.preview__stat-label {
    display: block;
    font-size: 0.5625rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
}

.preview__stat-value {
    display: block;
    margin-top: 0.125rem;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--text-primary);
}

.preview__stat:first-child .preview__stat-value { color: #4ade80; }

.preview__chart {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    height: 100px;
    padding: 0.5rem 0.25rem 0;
}

.preview__bar-col {
    flex: 1;
    height: var(--h, 50%);
    border-radius: 4px 4px 0 0;
    background: linear-gradient(180deg, var(--blue-400) 0%, var(--blue-600) 100%);
    opacity: 0.85;
    animation: barGrow 1.2s cubic-bezier(0.22, 1, 0.36, 1) both;
    transform-origin: bottom;
}

.preview__bar-col:nth-child(1) { animation-delay: 0.1s; }
.preview__bar-col:nth-child(2) { animation-delay: 0.15s; }
.preview__bar-col:nth-child(3) { animation-delay: 0.2s; }
.preview__bar-col:nth-child(4) { animation-delay: 0.25s; }
.preview__bar-col:nth-child(5) { animation-delay: 0.3s; }
.preview__bar-col:nth-child(6) { animation-delay: 0.35s; }
.preview__bar-col:nth-child(7) { animation-delay: 0.4s; }

@keyframes barGrow {
    from { transform: scaleY(0); opacity: 0; }
    to { transform: scaleY(1); opacity: 0.85; }
}

.preview__line {
    height: 2px;
    margin-top: 0.75rem;
    border-radius: 999px;
    background: linear-gradient(90deg, transparent, var(--blue-500), transparent);
    background-size: 200% 100%;
    animation: shimmer 4s ease-in-out infinite;
}

@keyframes shimmer {
    0%, 100% { background-position: 200% center; }
    50% { background-position: -200% center; }
}

/* Footer */
.card__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-shrink: 0;
    padding: clamp(0.625rem, 1.5vh, 0.875rem) clamp(1.25rem, 3vw, 1.75rem);
    border-top: 1px solid var(--border);
    background: rgb(0 0 0 / 0.15);
}

.card__contact {
    margin: 0;
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.card__contact a {
    margin-left: 0.375rem;
    color: var(--blue-300);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.card__contact a:hover {
    color: var(--text-primary);
}

.card__copy {
    margin: 0;
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* ── Responsive ── */
@media (max-width: 820px) {
    .card {
        height: min(720px, calc(100dvh - 1.5rem));
    }

    .card__body {
        grid-template-columns: 1fr;
    }

    .copy {
        border-right: none;
        border-bottom: 1px solid var(--border);
        padding-bottom: 1rem;
    }

    .preview {
        padding: 0.75rem 1.25rem 1rem;
    }

    .preview__window {
        max-width: 100%;
    }

    .preview__chart {
        height: 72px;
    }
}

@media (max-width: 480px) {
    .card__head {
        flex-wrap: wrap;
    }

    .features {
        grid-template-columns: 1fr;
        gap: 0.375rem;
    }

    .features__item {
        flex-direction: row;
        justify-content: flex-start;
        padding: 0.5rem 0.75rem;
        text-align: left;
    }

    .card__foot {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
}

@media (max-height: 600px) {
    .card {
        height: calc(100dvh - 1rem);
    }

    .copy__text,
    .copy__seo {
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .preview__chart {
        height: 56px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
