/* =========================================================
   UNIQUE BLUEPRINTS — "MIDNIGHT & EMERALD" THEME
   Headings: Playfair Display · Body: Lato
   ========================================================= */

/* --- 1. TOKENS --- */
:root {
    /* Midnight */
    --ink-950: #0B1120;
    --ink-900: #0F172A;     /* hero, dark sections */
    --ink-800: #1E293B;     /* cards on dark */
    --ink-700: #334155;     /* borders on dark */

    /* Emerald */
    --brand-400: #34D399;
    --brand-500: #10B981;   /* buttons, highlights */
    --brand-600: #059669;
    --brand-700: #047857;   /* links & icons on light (AA contrast) */
    --brand-800: #065F46;
    --brand-100: #D1FAE5;
    --brand-50:  #ECFDF5;
    --lime: #A3E635;

    /* Neutrals */
    --white: #FFFFFF;
    --paper: #F7F8F7;
    --text: #111827;
    --muted: #4B5563;
    --line: #E5E7EB;

    /* On dark */
    --on-dark: #F8FAFC;
    --on-dark-muted: #94A3B8;
    --grid-minor: rgba(16, 185, 129, 0.05);
    --grid-major: rgba(16, 185, 129, 0.10);

    --gradient: linear-gradient(100deg, var(--brand-500) 0%, var(--lime) 100%);

    /* Type */
    --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
    --font-body: 'Lato', 'Helvetica Neue', Helvetica, sans-serif;

    /* Shape */
    --radius: 8px;
    --radius-lg: 16px;
    --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 18px 44px -14px rgba(15, 23, 42, 0.25);
    --shadow-glow: 0 18px 50px -12px rgba(16, 185, 129, 0.45);
    --header-h: 76px;
    --ease: cubic-bezier(.2, .8, .2, 1);
}

/* --- 2. RESET & BASE --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.7;
    color: var(--text);
    background: var(--white);
    overflow-x: hidden;
}

img, svg, video, iframe { max-width: 100%; display: block; }
main { overflow-x: clip; } /* slide-in animations start off-screen; never let them widen the page */
a { color: inherit; text-decoration: none; transition: color .25s, background-color .25s, border-color .25s; }
ul { list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }

h1, h2, h3, h4 {
    font-family: var(--font-display);
    line-height: 1.15;
    letter-spacing: -0.01em;
    color: var(--ink-900);
}
h1 { font-size: clamp(2.4rem, 1.4rem + 4vw, 4.6rem); font-weight: 800; }
h2 { font-size: clamp(2rem, 1.3rem + 2.6vw, 3.1rem); font-weight: 700; }
h3 { font-size: clamp(1.25rem, 1.1rem + .5vw, 1.5rem); font-weight: 700; }
h4 { font-size: 1.15rem; font-weight: 700; }
h1 em, h2 em { font-style: italic; color: var(--brand-700); }

p { color: var(--muted); }
strong { color: var(--text); }

::selection { background: var(--brand-500); color: var(--ink-900); }
:focus-visible { outline: 3px solid var(--brand-500); outline-offset: 3px; border-radius: 4px; }

.skip-link {
    position: absolute; left: 16px; top: -60px; z-index: 2000;
    background: var(--brand-500); color: var(--ink-900); padding: 10px 18px; border-radius: var(--radius); font-weight: 700;
}
.skip-link:focus { top: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* --- 3. LAYOUT --- */
.container { width: 100%; max-width: 1240px; margin-inline: auto; padding-inline: clamp(16px, 4vw, 32px); }
.section { padding-block: clamp(64px, 9vw, 120px); position: relative; }
.section-tight { padding-block: clamp(48px, 6vw, 80px); }
.section-paper { background: var(--paper); }

.section-head { max-width: 720px; margin-bottom: clamp(36px, 5vw, 60px); }
.section-head.center { text-align: center; margin-inline: auto; }
.section-head h2 { margin: 14px 0 16px; }
.section-head p { font-size: 1.125rem; }

.section-head-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: clamp(36px, 5vw, 56px); }
.section-head-row .section-head { margin-bottom: 0; }

.eyebrow {
    display: inline-flex; align-items: center; gap: 12px;
    font-family: var(--font-body); font-weight: 700; font-size: .78rem; line-height: 1;
    letter-spacing: .18em; text-transform: uppercase; color: var(--brand-700);
}
.eyebrow::before { content: ""; width: 28px; height: 2px; background: currentColor; }
.section-head.center .eyebrow::after { content: ""; width: 28px; height: 2px; background: currentColor; }

.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(28px, 5vw, 72px); align-items: center; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

/* Dark ground with faint engineering grid */
.dark {
    background-color: var(--ink-900);
    background-image:
        linear-gradient(var(--grid-major) 1px, transparent 1px),
        linear-gradient(90deg, var(--grid-major) 1px, transparent 1px),
        linear-gradient(var(--grid-minor) 1px, transparent 1px),
        linear-gradient(90deg, var(--grid-minor) 1px, transparent 1px);
    background-size: 160px 160px, 160px 160px, 32px 32px, 32px 32px;
    background-position: -1px -1px;
    color: var(--on-dark);
}
.dark h1, .dark h2, .dark h3, .dark h4 { color: var(--white); }
.dark h1 em, .dark h2 em {
    background: var(--gradient); -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: var(--brand-500); padding-right: .08em;
}
.dark p { color: var(--on-dark-muted); }
.dark strong { color: var(--white); }
.dark .eyebrow { color: var(--brand-500); }

/* Soft animated glow */
.glow {
    position: absolute; width: 520px; height: 520px; border-radius: 50%; pointer-events: none; z-index: 0;
    background: radial-gradient(circle, rgba(16, 185, 129, .28) 0%, rgba(16, 185, 129, 0) 65%);
    filter: blur(10px); animation: drift 14s ease-in-out infinite alternate;
}
.glow-2 { background: radial-gradient(circle, rgba(163, 230, 53, .16) 0%, rgba(163, 230, 53, 0) 65%); animation-duration: 18s; animation-direction: alternate-reverse; }
@keyframes drift {
    0%   { transform: translate(0, 0) scale(1); }
    50%  { transform: translate(60px, -40px) scale(1.1); }
    100% { transform: translate(-40px, 30px) scale(.95); }
}

/* --- 4. BUTTONS --- */
.btn {
    position: relative; overflow: hidden;
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    min-height: 50px; padding: 0 26px; border-radius: var(--radius);
    font-family: var(--font-body); font-weight: 700; font-size: .95rem; letter-spacing: .02em;
    border: 2px solid transparent; cursor: pointer; white-space: nowrap;
    transition: transform .25s var(--ease), background-color .25s, border-color .25s, color .25s, box-shadow .25s;
}
.btn:hover { transform: translateY(-2px); }
.btn i { transition: transform .25s var(--ease); }
.btn:hover .fa-arrow-right { transform: translateX(4px); }

.btn-primary { background: var(--brand-500); color: var(--ink-900); }
.btn-primary:hover { background: var(--brand-400); box-shadow: var(--shadow-glow); }
.btn-primary::after {
    content: ""; position: absolute; top: 0; left: -75%; width: 50%; height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .55), transparent);
    transform: skewX(-20deg);
}
.btn-primary:hover::after { animation: shine .8s ease; }
@keyframes shine { to { left: 130%; } }

.btn-dark { background: var(--ink-900); color: var(--white); }
.btn-dark:hover { background: var(--ink-800); }
.btn-outline { border-color: var(--brand-700); color: var(--brand-700); background: transparent; }
.btn-outline:hover { background: var(--brand-50); }
.btn-light { border-color: rgba(255, 255, 255, .35); color: var(--white); background: transparent; }
.btn-light:hover { border-color: var(--brand-500); color: var(--brand-500); }
.btn-sm { min-height: 42px; padding: 0 18px; font-size: .875rem; }
.btn-block { width: 100%; }

.link-arrow { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--brand-700); }
.link-arrow i { transition: transform .25s var(--ease); }
.link-arrow:hover i { transform: translateX(4px); }
.dark .link-arrow { color: var(--brand-500); }

/* --- 5. SCROLL PROGRESS & BACK TO TOP --- */
.scroll-progress { position: fixed; top: 0; left: 0; height: 3px; width: 100%; z-index: 1100; transform-origin: left; transform: scaleX(0); background: var(--gradient); }
.to-top {
    position: fixed; right: 20px; bottom: 20px; z-index: 900; width: 48px; height: 48px; border-radius: 50%;
    border: 0; cursor: pointer; background: var(--ink-900); color: var(--brand-500); font-size: 1rem;
    box-shadow: var(--shadow-md); opacity: 0; visibility: hidden; transform: translateY(16px);
    transition: opacity .3s, visibility .3s, transform .3s var(--ease), background-color .25s;
}
.to-top.show { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--brand-500); color: var(--ink-900); }

/* --- 6. HEADER & NAV --- */
.site-header {
    position: sticky; top: 0; z-index: 1000; height: var(--header-h);
    background: rgba(255, 255, 255, .94); backdrop-filter: saturate(160%) blur(12px);
    border-bottom: 1px solid var(--line); transition: box-shadow .3s;
}
.site-header.scrolled { box-shadow: 0 8px 30px -14px rgba(15, 23, 42, .25); }
.nav { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 24px; }

.brand { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.brand img { height: 54px; width: auto; max-width: 200px; object-fit: contain; transition: transform .4s var(--ease); }
.brand:hover img { transform: scale(1.05); }
.brand-text { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; line-height: 1.1; color: var(--ink-900); }
.brand-text small { display: block; font-family: var(--font-body); font-size: .62rem; font-weight: 700; letter-spacing: .28em; color: var(--brand-700); }

.nav-menu { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 34px); }
.nav-menu a:not(.btn) { position: relative; font-weight: 700; font-size: .95rem; color: var(--text); padding: 6px 0; }
.nav-menu a:not(.btn)::after {
    content: ""; position: absolute; left: 0; bottom: -2px; width: 100%; height: 2px;
    background: var(--brand-500); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.nav-menu a:not(.btn):hover { color: var(--brand-700); }
.nav-menu a:not(.btn):hover::after, .nav-menu a.active::after { transform: scaleX(1); }
.nav-menu a.active { color: var(--brand-700); }
.nav-cta-mobile, .drawer-head, .nav-menu a i, .nav-overlay { display: none; }

.nav-toggle {
    display: none; width: 46px; height: 46px; border-radius: var(--radius);
    border: 1px solid var(--line); background: var(--white); color: var(--ink-900);
    font-size: 1.2rem; cursor: pointer; align-items: center; justify-content: center;
}

/* Currency switcher */
.nav > nav { flex: 1; display: flex; justify-content: center; }
.cur-switch { position: relative; flex-shrink: 0; }
.cur-btn {
    display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px;
    border: 1px solid var(--line); border-radius: 999px; background: var(--white);
    font: 700 .875rem var(--font-body); color: var(--ink-900); cursor: pointer; transition: border-color .25s, color .25s;
}
.cur-btn:hover, .cur-switch.open .cur-btn { border-color: var(--brand-600); color: var(--brand-700); }
.cur-btn > i:first-child { color: var(--brand-600); }
.cur-caret { font-size: .65rem; transition: transform .25s var(--ease); }
.cur-switch.open .cur-caret { transform: rotate(180deg); }
.cur-menu {
    position: absolute; right: 0; top: calc(100% + 10px); z-index: 1003; min-width: 240px; max-height: min(70vh, 420px); overflow-y: auto;
    background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); padding: 6px;
    opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .2s, transform .2s var(--ease), visibility .2s;
}
.cur-switch.open .cur-menu, .no-js .cur-switch:focus-within .cur-menu { opacity: 1; visibility: visible; transform: none; }
.cur-menu a { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 8px; font-size: .875rem; color: var(--text); }
.cur-menu a strong { width: 40px; flex-shrink: 0; }
.cur-menu a span { color: var(--muted); }
.cur-menu a:hover, .cur-menu a.active { background: var(--brand-50); color: var(--brand-800); }
.cur-menu a.active strong::after { content: "\f00c"; font-family: "Font Awesome 6 Free"; font-weight: 900; font-size: .7rem; margin-left: 6px; color: var(--brand-600); }

/* --- 7. HOME HERO --- */
.hero { position: relative; overflow: hidden; padding-block: clamp(56px, 8vw, 110px) clamp(72px, 9vw, 120px); }
.hero .glow { top: -160px; left: -160px; }
.hero .glow-2 { top: auto; bottom: -220px; left: auto; right: -120px; }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(36px, 5vw, 72px); align-items: center; }
.hero h1 { margin: 20px 0 24px; }
.hero-lead { font-size: clamp(1.05rem, 1rem + .3vw, 1.22rem); max-width: 560px; margin-bottom: 36px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-points { display: flex; flex-wrap: wrap; gap: 10px 24px; margin-top: 36px; }
.hero-points li { display: flex; align-items: center; gap: 8px; font-size: .95rem; color: var(--on-dark-muted); }
.hero-points i { color: var(--brand-500); }

/* Rotating word */
.rotator { display: inline-grid; vertical-align: bottom; }
.rotator > * { grid-area: 1 / 1; opacity: 0; transform: translateY(40%); transition: opacity .5s var(--ease), transform .5s var(--ease); white-space: nowrap; }
.rotator > .on { opacity: 1; transform: none; }
.rotator > .off { opacity: 0; transform: translateY(-40%); }
.no-js .rotator > :first-child, .rotator.static > :first-child { opacity: 1; transform: none; }

/* Hero visual */
.hero-visual { position: relative; padding: 24px 24px 40px 0; }
.hero-photo {
    position: relative; border-radius: 22px; overflow: hidden; aspect-ratio: 4 / 4.4;
    border: 1px solid rgba(16, 185, 129, .35); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .6);
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; }
.hero-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(15, 23, 42, 0) 50%, rgba(15, 23, 42, .55) 100%); }
.hero-frame { position: absolute; inset: 0 0 16px 24px; border: 1px dashed rgba(16, 185, 129, .45); border-radius: 26px; z-index: -1; }

.float-card {
    position: absolute; z-index: 2; display: flex; align-items: center; gap: 14px;
    background: rgba(255, 255, 255, .97); color: var(--text); border-radius: 14px; padding: 14px 18px;
    box-shadow: 0 20px 40px -12px rgba(0, 0, 0, .45); animation: float 6s ease-in-out infinite;
}
.float-card .icon-tile { width: 44px; height: 44px; font-size: 1.1rem; }
.dark .float-card strong { display: block; font-family: var(--font-display); font-size: 1.35rem; line-height: 1.1; color: var(--ink-900); }
.float-card span { font-size: .82rem; color: var(--muted); }
.float-card.fc-1 { left: -36px; top: 18%; }
.float-card.fc-2 { right: -12px; bottom: 6%; animation-delay: -3s; }
.code-chip {
    position: absolute; z-index: 2; top: 0; right: 40px; padding: 8px 14px; border-radius: 10px;
    font-family: Consolas, Menlo, monospace; font-size: .85rem; background: var(--ink-800); color: var(--lime);
    border: 1px solid var(--ink-700); animation: float 7s ease-in-out infinite; animation-delay: -1.5s;
}
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }

/* Load-in sequence */
.load-in { opacity: 0; transform: translateY(26px); animation: fadeUp .9s var(--ease) forwards; animation-delay: var(--d, 0s); }
@keyframes fadeUp { to { opacity: 1; transform: none; } }

/* --- 8. INNER PAGE HERO (photo background) --- */
.page-hero { position: relative; overflow: hidden; padding-block: clamp(64px, 9vw, 120px); isolation: isolate; }
.page-hero::before {
    content: ""; position: absolute; inset: 0; z-index: -2;
    background: var(--hero-img, none) center / cover no-repeat;
    animation: kenburns 24s ease-in-out infinite alternate;
}
.page-hero::after {
    content: ""; position: absolute; inset: 0; z-index: -1;
    background:
        linear-gradient(90deg, rgba(15, 23, 42, .97) 0%, rgba(15, 23, 42, .88) 50%, rgba(15, 23, 42, .65) 100%),
        linear-gradient(var(--grid-major) 1px, transparent 1px),
        linear-gradient(90deg, var(--grid-major) 1px, transparent 1px);
    background-size: auto, 32px 32px, 32px 32px;
}
@keyframes kenburns { from { transform: scale(1); } to { transform: scale(1.12) translate(-1%, -1%); } }
.page-hero h1 { font-size: clamp(2.2rem, 1.4rem + 3.2vw, 3.9rem); margin: 18px 0 16px; max-width: 820px; }
.page-hero p { font-size: 1.15rem; max-width: 640px; }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; font-size: .9rem; color: var(--on-dark-muted); margin-bottom: 26px; }
.breadcrumb a:hover { color: var(--brand-500); }
.breadcrumb span[aria-current] { color: var(--white); }

/* --- 9. STATS --- */
.stats { border-bottom: 1px solid var(--line); background: var(--white); }
.stats .grid-4 { padding-block: clamp(36px, 5vw, 56px); }
.stat { text-align: center; padding-inline: 8px; }
.stat + .stat { border-left: 1px solid var(--line); }
.stat-num { font-family: var(--font-display); font-weight: 800; font-size: clamp(2.2rem, 1.6rem + 2vw, 3.1rem); line-height: 1.1; color: var(--brand-700); }
.stat-label { font-size: .82rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-top: 6px; }

/* --- 10. TECH MARQUEE --- */
.marquee { position: relative; overflow: hidden; padding-block: 26px; background: var(--ink-950); }
.marquee::before, .marquee::after { content: ""; position: absolute; top: 0; bottom: 0; width: 12%; z-index: 1; pointer-events: none; }
.marquee::before { left: 0; background: linear-gradient(90deg, var(--ink-950), transparent); }
.marquee::after { right: 0; background: linear-gradient(-90deg, var(--ink-950), transparent); }
.marquee-track { display: flex; gap: 56px; width: max-content; animation: marquee 32s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-item { display: flex; align-items: center; gap: 12px; color: var(--on-dark-muted); font-weight: 700; font-size: 1.05rem; white-space: nowrap; }
.marquee-item i { font-size: 1.6rem; color: var(--brand-500); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* --- 11. CARDS --- */
.card {
    position: relative; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg);
    padding: clamp(26px, 3vw, 36px); transition: transform .4s var(--ease), box-shadow .4s, border-color .4s;
}
.card::before {
    content: ""; position: absolute; left: 0; top: 0; height: 3px; width: 100%; border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    background: var(--gradient); transform: scaleX(0); transform-origin: left; transition: transform .5s var(--ease);
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: transparent; }
.card:hover::before { transform: scaleX(1); }
.card h3 { margin: 22px 0 10px; }
.card-num { position: absolute; top: 26px; right: 28px; font-size: .78rem; font-weight: 700; letter-spacing: .14em; color: #9CA3AF; }
.icon-tile {
    width: 56px; height: 56px; border-radius: 14px; display: grid; place-items: center; flex-shrink: 0;
    background: var(--brand-50); color: var(--brand-700); font-size: 1.35rem;
    transition: transform .4s var(--ease), background-color .3s, color .3s;
}
.card:hover .icon-tile { background: var(--brand-500); color: var(--ink-900); transform: rotate(-8deg) scale(1.06); }
.check-list { margin-top: 18px; display: grid; gap: 8px; }
.check-list li { display: flex; gap: 10px; align-items: flex-start; font-size: .97rem; color: var(--text); }
.check-list i { color: var(--brand-600); margin-top: 6px; font-size: .8rem; }
.card .link-arrow { margin-top: 18px; }

/* --- 12. SPLIT IMAGE BLOCKS --- */
.media-frame { position: relative; }
.media-frame img { width: 100%; aspect-ratio: 5 / 4; object-fit: cover; border-radius: var(--radius-lg); box-shadow: var(--shadow-md); }
.media-frame::before {
    content: ""; position: absolute; inset: 22px -22px -22px 22px; border-radius: var(--radius-lg);
    border: 2px solid var(--brand-500); z-index: -1; opacity: .5;
}
.media-badge {
    position: absolute; left: -18px; bottom: 28px; background: var(--ink-900); color: var(--white);
    padding: 18px 22px; border-radius: 14px; box-shadow: var(--shadow-md); animation: float 6s ease-in-out infinite;
}
.media-badge strong { display: block; font-family: var(--font-display); font-size: 2rem; line-height: 1; color: var(--brand-500); }
.media-badge span { font-size: .85rem; color: var(--on-dark-muted); }
.media-quote {
    position: absolute; left: 24px; right: 24px; bottom: 24px; padding: 22px 24px; border-radius: 14px;
    background: rgba(15, 23, 42, .88); backdrop-filter: blur(6px);
}
.media-quote blockquote { font-family: var(--font-display); font-style: italic; font-size: clamp(1.1rem, 1rem + .6vw, 1.45rem); line-height: 1.35; color: var(--white); }
.media-quote cite { display: block; margin-top: 10px; font-style: normal; font-size: .8rem; color: var(--brand-500); font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }

.lead { font-size: 1.15rem; }
.stack-list { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.stack-list li { padding: 8px 16px; border-radius: 999px; background: var(--brand-50); color: var(--brand-800); font-weight: 700; font-size: .9rem; transition: transform .25s, background-color .25s; }
.stack-list li:hover { transform: translateY(-3px); background: var(--brand-100); }

/* --- 13. PROCESS --- */
.process-section { overflow: hidden; }
.process-grid { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border-top: 1px solid var(--ink-700); }
.step { padding: 36px 28px 8px 0; position: relative; }
.step + .step { padding-left: 28px; border-left: 1px solid var(--ink-700); }
.step::before { content: ""; position: absolute; top: -5px; left: 0; width: 9px; height: 9px; border-radius: 50%; background: var(--brand-500); box-shadow: 0 0 0 6px rgba(16, 185, 129, .15); }
.step + .step::before { left: -5px; }
.step-num { font-family: var(--font-display); font-style: italic; font-weight: 700; font-size: 3rem; line-height: 1; background: var(--gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: var(--brand-500); }
.step h3 { margin: 18px 0 10px; font-size: 1.35rem; }

.process-light { border-top-color: var(--line); }
.process-light .step + .step { border-left-color: var(--line); }

/* --- 14. TEMPLATE CARDS --- */
.tpl-card {
    display: flex; flex-direction: column; background: var(--white); border: 1px solid var(--line);
    border-radius: var(--radius-lg); overflow: hidden; transition: transform .4s var(--ease), box-shadow .4s;
}
.tpl-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.tpl-thumb { position: relative; display: block; aspect-ratio: 16 / 10; background: var(--brand-50); overflow: hidden; }
.tpl-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: object-position 4s ease, transform .8s var(--ease); }
.tpl-card:hover .tpl-thumb img { object-position: bottom; }
.badge {
    display: inline-block; padding: 5px 12px; border-radius: 999px; font-size: .72rem; font-weight: 700;
    letter-spacing: .1em; text-transform: uppercase; background: var(--ink-900); color: var(--brand-500);
}
.tpl-thumb .badge { position: absolute; top: 14px; left: 14px; box-shadow: var(--shadow-sm); }
.tpl-body { display: flex; flex-direction: column; flex: 1; padding: 22px 24px 24px; }
.tpl-body h3 { font-size: 1.35rem; margin-bottom: 8px; }
.tpl-body h3 a:hover { color: var(--brand-700); }
.tpl-body p { font-size: .97rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tpl-meta { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-top: auto; padding-top: 18px; }
.price { font-weight: 900; font-size: 1.2rem; color: var(--brand-700); }
.price-old { font-size: .9rem; color: var(--muted); text-decoration: line-through; margin-left: 6px; font-weight: 400; }
.stack { font-size: .82rem; color: var(--muted); text-align: right; }
.tpl-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); }
.tpl-actions .btn { flex: 1; }

/* --- 15. CATALOG --- */
.catalog-bar {
    display: grid; grid-template-columns: 1fr 220px 200px auto; gap: 12px;
    background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 14px;
    box-shadow: var(--shadow-md); margin-top: -44px; position: relative; z-index: 2;
}
.chips { display: flex; gap: 10px; margin: 32px 0 28px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
.chip {
    flex-shrink: 0; display: inline-flex; align-items: center; gap: 8px; padding: 9px 18px; border-radius: 999px;
    border: 1px solid var(--line); background: var(--white); font-weight: 700; font-size: .9rem; color: var(--text);
}
.chip span { color: var(--muted); font-weight: 400; }
.chip:hover { border-color: var(--brand-600); color: var(--brand-700); }
.chip.active { background: var(--ink-900); border-color: var(--ink-900); color: var(--white); }
.chip.active i, .chip.active span { color: var(--brand-500); }
.results-info { color: var(--muted); margin-bottom: 22px; font-size: .95rem; }

.pagination { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 48px; }
.pagination a, .pagination span {
    min-width: 44px; height: 44px; display: grid; place-items: center; padding: 0 12px;
    border-radius: var(--radius); border: 1px solid var(--line); font-weight: 700; background: var(--white);
}
.pagination a:hover { border-color: var(--brand-600); color: var(--brand-700); }
.pagination .current { background: var(--ink-900); color: var(--brand-500); border-color: var(--ink-900); }

.empty-state {
    text-align: center; padding: clamp(40px, 6vw, 72px) 24px; border: 2px dashed #A7F3D0;
    border-radius: var(--radius-lg); background: var(--white);
}
.empty-state .icon-tile { margin: 0 auto 20px; animation: float 5s ease-in-out infinite; }
.empty-state h3 { margin-bottom: 10px; }
.empty-state p { max-width: 520px; margin: 0 auto 24px; }

/* --- 16. TEMPLATE DETAIL --- */
.detail-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(28px, 4vw, 56px); align-items: start; }
.gallery-main { border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--line); background: var(--brand-50); aspect-ratio: 16 / 10; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: opacity .3s; }
.gallery-main img.fading { opacity: 0; }
.gallery-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; margin-top: 12px; }
.gallery-thumbs button {
    aspect-ratio: 16 / 10; border-radius: var(--radius); overflow: hidden; border: 2px solid transparent;
    cursor: pointer; background: var(--brand-50); padding: 0;
}
.gallery-thumbs button.active, .gallery-thumbs button:hover { border-color: var(--brand-500); }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: cover; object-position: top; }

.detail-block { margin-top: 44px; }
.detail-block h2 { font-size: clamp(1.6rem, 1.3rem + 1vw, 2rem); margin-bottom: 16px; }
.prose p, .prose li { color: var(--muted); }
.prose p + p { margin-top: 14px; }
.prose ul, .prose ol { padding-left: 22px; margin-top: 12px; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose h3, .prose h4 { margin: 20px 0 8px; }
.feature-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 24px; }
.feature-list li { display: flex; gap: 10px; align-items: flex-start; color: var(--text); }
.feature-list i { color: var(--brand-600); margin-top: 6px; font-size: .85rem; }

.prep-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: -36px; position: relative; z-index: 2; }
.prep-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 22px; box-shadow: var(--shadow-md); }
.prep-card i { font-size: 1.4rem; color: var(--brand-600); }
.prep-card h3 { font-size: 1.1rem; margin: 12px 0 6px; }
.prep-card p { font-size: .93rem; }
.guide-layout { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: clamp(28px, 4vw, 56px); align-items: start; }
.guide-side .buy-box p { font-size: .97rem; }
.guide-steps h3 i { color: var(--brand-600); margin-right: 6px; font-size: .95em; }
.guide-steps li { scroll-margin-top: calc(var(--header-h) + 20px); }
.guide-tip { margin-top: 8px; background: var(--paper); border-left: 3px solid var(--brand-500); padding: 8px 12px; border-radius: 0 6px 6px 0; font-size: .92rem; }
.guide-tip i { color: #CA8A04; margin-right: 4px; }
.faq { display: grid; gap: 12px; }
.faq-item { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 0 20px; }
.faq-item summary { list-style: none; cursor: pointer; padding: 18px 0; font-weight: 700; display: flex; justify-content: space-between; gap: 16px; align-items: center; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary i { color: var(--brand-600); transition: transform .3s; }
.faq-item[open] summary i { transform: rotate(45deg); }
.faq-item p { padding-bottom: 18px; }
@media (max-width: 960px) { .prep-grid { grid-template-columns: 1fr 1fr; } .guide-layout { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 480px) { .prep-grid { grid-template-columns: 1fr; } }
.req-box { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px 22px; margin-bottom: 26px; }
.req-box h3 { font-size: 1.1rem; margin-bottom: 12px; display: flex; gap: 10px; align-items: center; }
.req-box h3 i { color: var(--brand-600); }
.req-box ul { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px 20px; }
.req-box li { display: flex; gap: 10px; color: var(--text); font-size: .97rem; }
.req-box li i { color: var(--brand-600); margin-top: 6px; font-size: .8rem; }
.install-steps { list-style: none; padding: 0; counter-reset: none; display: grid; gap: 0; position: relative; }
.install-steps li { display: flex; gap: 18px; padding-bottom: 22px; position: relative; }
.install-steps li:not(:last-child)::before { content: ""; position: absolute; left: 19px; top: 42px; bottom: 4px; width: 2px; background: var(--brand-100); }
.is-num { width: 40px; height: 40px; flex-shrink: 0; border-radius: 50%; display: grid; place-items: center; background: var(--ink-900); color: var(--brand-500); font-weight: 900; font-family: var(--font-display); }
.install-steps h3 { font-size: 1.1rem; margin: 8px 0 4px; }
.install-steps p { font-size: .97rem; }
.help-note { display: flex; gap: 14px; align-items: flex-start; background: var(--brand-50); border: 1px solid #A7F3D0; border-radius: var(--radius-lg); padding: 16px 18px; margin-top: 6px; }
.help-note i { color: var(--brand-700); font-size: 1.3rem; margin-top: 3px; }
.help-note p { color: var(--text); font-size: .97rem; }
.help-note a { color: var(--brand-700); font-weight: 700; }
@media (max-width: 640px) { .req-box ul { grid-template-columns: 1fr; } }
.buy-box { position: sticky; top: calc(var(--header-h) + 24px); background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(24px, 3vw, 32px); box-shadow: var(--shadow-md); }
.buy-box .price { font-size: 2rem; font-family: var(--font-display); font-weight: 800; }
.license-row { display: flex; justify-content: space-between; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: .97rem; }
.license-row strong { white-space: nowrap; }
.save-note { display: inline-flex; gap: 8px; align-items: center; margin: 4px 0 6px; padding: 4px 12px; border-radius: 999px; background: var(--brand-50); color: var(--brand-800); font-weight: 700; font-size: .85rem; }
.buy-perks { display: grid; gap: 8px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.buy-perks li { display: flex; gap: 10px; align-items: flex-start; font-size: .95rem; color: var(--text); }
.buy-perks i { color: var(--brand-600); margin-top: 5px; font-size: .8rem; }
.buy-actions { display: grid; gap: 12px; margin: 22px 0; }
.pay-note { display: grid; gap: 6px; margin: 10px 0 2px; font-size: .9rem; color: var(--muted); }
.pay-note i { width: 18px; color: var(--brand-600); }
.pay-logos { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin: -6px 0 20px; font-size: 1.7rem; color: #64748B; }
.pay-logos small { flex-basis: 100%; font-size: .85rem; color: var(--muted); }
.pay-logos small i { color: var(--brand-600); margin-right: 4px; }
.pl-mpesa { font: 900 .78rem var(--font-body); letter-spacing: .04em; color: var(--white); background: #16A34A; padding: 5px 9px; border-radius: 6px; }
.demo-creds { background: var(--brand-50); border: 1px dashed #6EE7B7; border-radius: var(--radius); padding: 14px 16px; font-size: .92rem; }
.demo-creds code { font-family: Consolas, Menlo, monospace; background: var(--white); padding: 2px 6px; border-radius: 4px; color: var(--brand-800); }
.meta-list { margin-top: 20px; }
.meta-list li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); font-size: .93rem; }
.meta-list span:first-child { color: var(--muted); }
.meta-list span:last-child { font-weight: 700; text-align: right; }

/* --- 17. PROJECTS --- */
.project-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; transition: transform .4s var(--ease), box-shadow .4s; }
.project-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.project-img { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--brand-50); }
.project-img img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform .9s var(--ease); }
.project-card:hover .project-img img { transform: scale(1.06); }
.project-img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(15, 23, 42, .35)); opacity: 0; transition: opacity .4s; }
.project-card:hover .project-img::after { opacity: 1; }
.project-body { padding: 22px 24px 24px; }
.project-body .eyebrow { font-size: .7rem; }
.project-body h3 { margin: 12px 0 14px; }
.project-body .muted-note { font-size: .9rem; color: var(--muted); }

/* --- 18. COMPARE --- */
.compare { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.compare .card.featured { background: var(--ink-900); border-color: var(--ink-900); }
.compare .card.featured h3 { color: var(--white); }
.compare .card.featured p, .compare .card.featured .check-list li { color: var(--on-dark-muted); }
.compare .card.featured .check-list i { color: var(--brand-500); }
.compare .card.featured .icon-tile { background: rgba(16, 185, 129, .14); color: var(--brand-500); }
.compare .btn { margin-top: 26px; }

/* --- 19. CTA BAND --- */
.cta-box {
    position: relative; overflow: hidden; isolation: isolate;
    border-radius: 24px; padding: clamp(36px, 6vw, 72px); display: grid; grid-template-columns: 1.4fr auto;
    gap: 32px; align-items: center; color: var(--on-dark);
}
.cta-box::before { content: ""; position: absolute; inset: 0; z-index: -2; background: var(--cta-img, none) center / cover; }
.cta-box::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(100deg, rgba(15, 23, 42, .97) 35%, rgba(6, 95, 70, .85) 100%); }
.cta-box .glow { right: -180px; top: -200px; z-index: -1; }
.cta-box h2 { margin: 14px 0 12px; color: var(--white); }
.cta-box h2 em { background: var(--gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: var(--brand-500); }
.cta-box p { color: var(--on-dark-muted); }
.cta-box .eyebrow { color: var(--brand-500); }
.cta-actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* --- 20. CONTACT --- */
.contact-grid { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.info-card { display: flex; gap: 18px; align-items: center; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--white); margin-bottom: 14px; transition: transform .3s var(--ease), box-shadow .3s; }
.info-card:hover { transform: translateX(6px); box-shadow: var(--shadow-sm); }
.info-card h4 { font-family: var(--font-body); font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.info-card a, .info-card p { font-weight: 700; color: var(--text); word-break: break-word; }
.info-card a:hover { color: var(--brand-700); }
.contact-photo { margin-top: 24px; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 16 / 10; }
.contact-photo img { width: 100%; height: 100%; object-fit: cover; }

.form-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(24px, 4vw, 44px); box-shadow: var(--shadow-md); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 700; font-size: .92rem; margin-bottom: 8px; color: var(--text); }
.input, .field input, .field select, .field textarea {
    width: 100%; min-height: 52px; padding: 12px 16px; border: 1px solid #D1D5DB; border-radius: var(--radius);
    background: var(--white); color: var(--text); transition: border-color .2s, box-shadow .2s;
}
.field textarea { min-height: 150px; resize: vertical; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--brand-600); box-shadow: 0 0 0 4px rgba(16, 185, 129, .18); }
.hp-field { position: absolute; left: -9999px; }

.alert { padding: 14px 18px; border-radius: var(--radius); margin-bottom: 20px; font-weight: 700; display: flex; gap: 10px; align-items: center; }
.alert-error { background: #FEF2F2; color: #991B1B; border: 1px solid #FECACA; }
.alert-info { background: var(--brand-50); color: var(--brand-800); border: 1px solid #A7F3D0; }

/* --- 21a. CHECKOUT & ORDERS --- */
.checkout-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
.co-step { display: flex; align-items: center; gap: 12px; font-size: 1.35rem; margin: 6px 0 18px; }
.co-step:not(:first-of-type) { margin-top: 30px; }
.co-step span { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--ink-900); color: var(--brand-500); font-size: .95rem; font-family: var(--font-display); }
.co-hint { display: block; font-size: .88rem; color: var(--muted); margin-top: -4px; }
.co-hint i { color: var(--brand-600); margin-right: 4px; }
.pay-methods { display: grid; gap: 12px; margin-bottom: 18px; }
.pay-option { display: block; cursor: pointer; }
.pay-option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.po-body {
    display: flex; align-items: center; gap: 14px; padding: 16px 18px; border: 2px solid var(--line); border-radius: var(--radius-lg);
    background: var(--white); transition: border-color .2s, box-shadow .2s, background-color .2s;
}
.pay-option:hover .po-body { border-color: #A7F3D0; }
.pay-option input:checked + .po-body { border-color: var(--brand-600); background: var(--brand-50); box-shadow: 0 0 0 4px rgba(16, 185, 129, .14); }
.pay-option input:focus-visible + .po-body { outline: 3px solid var(--brand-500); outline-offset: 2px; }
.po-icon { width: 46px; height: 46px; flex-shrink: 0; border-radius: 12px; display: grid; place-items: center; font-weight: 900; font-size: 1.3rem; }
.po-mpesa { background: #16A34A; color: var(--white); font-family: var(--font-display); }
.po-paypal { background: #E0EAFF; color: #003087; }
.po-text { flex: 1; min-width: 0; }
.po-text strong { display: block; font-size: 1rem; }
.po-text small { color: var(--muted); font-size: .86rem; }
.po-amount { font-weight: 900; color: var(--ink-900); white-space: nowrap; }
.pay-option input:checked + .po-body .po-amount { color: var(--brand-800); }
.js .mpesa-field[data-hidden] { display: none; }
.mpesa-field .co-hint { margin-top: 8px; }
.co-submit { min-height: 56px; font-size: 1rem; margin-top: 8px; }
.co-submit[disabled] { opacity: .7; cursor: wait; transform: none; }
.co-secure { display: flex; gap: 10px; align-items: flex-start; font-size: .85rem; color: var(--muted); margin-top: 14px; }
.co-secure i { color: var(--brand-600); margin-top: 3px; }
.co-summary .eyebrow { margin-bottom: 16px; }
.co-item { display: flex; gap: 14px; align-items: center; }
.co-item img { width: 96px; height: 60px; object-fit: cover; object-position: top; border-radius: 8px; border: 1px solid var(--line); flex-shrink: 0; }
.co-item h3 { font-size: 1.15rem; line-height: 1.3; }
.co-item small { color: var(--muted); }
.co-total span { font-size: 1.05rem; color: var(--ink-900) !important; }
.co-total span:last-child { font-family: var(--font-display); font-size: 1.45rem; color: var(--brand-700) !important; }
.co-save { color: var(--brand-700); }
.co-fx { display: flex; gap: 10px; font-size: .85rem; color: var(--muted); background: var(--paper); border-radius: var(--radius); padding: 10px 12px; margin-top: 14px; }
.co-fx i { color: var(--brand-600); margin-top: 4px; }
.co-back { margin-top: 20px; font-size: .92rem; }
.co-back:hover i { transform: translateX(-4px); }

.order-wrap { max-width: 760px; }
.order-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(22px, 4vw, 40px); box-shadow: var(--shadow-md); margin-top: clamp(-90px, -6vw, -40px); position: relative; z-index: 2; }
.order-state { display: flex; gap: 18px; align-items: flex-start; margin-bottom: 24px; }
.order-state h2, .dl-title { font-size: clamp(1.35rem, 1.1rem + 1vw, 1.75rem); margin-bottom: 6px; }
.os-icon { width: 58px; height: 58px; flex-shrink: 0; border-radius: 50%; display: grid; place-items: center; font-size: 1.4rem; }
.state-paid .os-icon { background: var(--brand-500); color: var(--ink-900); animation: pop .6s var(--ease) both; }
.state-wait .os-icon { background: var(--brand-50); color: var(--brand-700); }
.state-fail .os-icon { background: #FEF2F2; color: #B91C1C; }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--brand-100); border-top-color: var(--brand-600); animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.wait-steps { display: grid; gap: 10px; margin-bottom: 18px; }
.wait-steps li { display: flex; gap: 12px; align-items: center; color: var(--text); }
.wait-steps span { width: 28px; height: 28px; flex-shrink: 0; border-radius: 50%; display: grid; place-items: center; background: var(--ink-900); color: var(--brand-500); font-weight: 900; font-size: .85rem; }
.live-status { font-weight: 700; color: var(--brand-700); font-size: .95rem; margin-bottom: 18px; }
.live-status::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--brand-500); margin-right: 8px; animation: blink 1.2s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .2; } }
.retry-box { border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 0 18px; margin-bottom: 18px; background: var(--paper); }
.retry-box summary { cursor: pointer; padding: 14px 0; font-weight: 700; color: var(--brand-700); }
.retry-box.open { padding: 16px 18px; }
.retry-title { font-weight: 700; color: var(--text); margin-bottom: 10px; }
.retry-form { padding-bottom: 16px; }
.retry-form label { display: block; font-weight: 700; font-size: .9rem; margin-bottom: 8px; }
.retry-row { display: flex; gap: 10px; }
.retry-row .input { flex: 1; min-width: 0; }
.retry-row .btn { flex-shrink: 0; }
.retry-form small { display: block; color: var(--muted); font-size: .84rem; margin-top: 8px; }
.retry-alt { font-size: .92rem; padding-bottom: 14px; }
.retry-alt a { color: var(--brand-700); font-weight: 700; }
.order-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 8px; }
.dl-list { display: grid; gap: 12px; margin-bottom: 22px; }
.dl-list li { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--paper); }
.dl-info { display: flex; gap: 14px; align-items: center; min-width: 0; }
.dl-info > i { font-size: 1.7rem; color: var(--brand-600); }
.dl-info strong { display: block; }
.dl-info small { color: var(--muted); font-size: .86rem; }
.pill-soft { font-size: .82rem; font-weight: 700; color: var(--brand-800); background: var(--brand-50); padding: 6px 12px; border-radius: 999px; }
.order-meta { margin-top: 26px; }
.help-note code { font-size: .9em; background: var(--white); padding: 1px 6px; border-radius: 4px; }
@media (max-width: 960px) { .checkout-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) {
    .dl-list li { flex-direction: column; align-items: stretch; }
    .dl-list .btn { width: 100%; }
    .retry-row { flex-direction: column; }
    .order-state { gap: 14px; }
    .os-icon { width: 48px; height: 48px; font-size: 1.2rem; }
    .po-body { padding: 14px; gap: 12px; }
    .po-icon { width: 40px; height: 40px; font-size: 1.1rem; }
}

/* --- 21. THANK YOU --- */
.thanks { min-height: calc(100vh - var(--header-h)); display: grid; place-items: center; padding: 64px 0; }
.thanks-card { text-align: center; max-width: 560px; margin-inline: auto; }
.thanks-card .icon-tile { margin: 0 auto 26px; width: 80px; height: 80px; font-size: 2rem; background: var(--brand-500); color: var(--ink-900); border-radius: 50%; animation: pop .7s var(--ease) both, pulse 2.4s ease-out 1s infinite; }
@keyframes pop { from { transform: scale(0); } 70% { transform: scale(1.15); } to { transform: scale(1); } }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, .5); } 100% { box-shadow: 0 0 0 26px rgba(16, 185, 129, 0); } }
.thanks-card h1 { font-size: clamp(2.2rem, 1.6rem + 2.4vw, 3.4rem); margin-bottom: 14px; }
.thanks-card p { margin-bottom: 30px; }

/* --- 22. FOOTER --- */
.site-footer { background-color: var(--ink-950); padding-top: clamp(56px, 7vw, 88px); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.3fr; gap: clamp(28px, 4vw, 48px); padding-bottom: 48px; }
.footer-brand { font-family: var(--font-display); font-weight: 800; font-size: 1.7rem; color: var(--white); display: inline-block; margin-bottom: 14px; }
.footer-brand span { color: var(--brand-500); }
.site-footer h4 { font-family: var(--font-body); font-size: .8rem; letter-spacing: .16em; text-transform: uppercase; color: var(--brand-500); margin-bottom: 18px; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: var(--on-dark-muted); font-size: .97rem; display: inline-block; transition: color .25s, transform .25s var(--ease); }
.footer-links a:hover { color: var(--white); transform: translateX(4px); }
.footer-contact li { display: flex; gap: 12px; margin-bottom: 12px; color: var(--on-dark-muted); font-size: .97rem; }
.footer-contact a:hover { color: var(--white); }
.footer-contact i { color: var(--brand-500); margin-top: 6px; width: 16px; }
.socials { display: flex; gap: 10px; margin-top: 22px; }
.socials a {
    width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center;
    border: 1px solid var(--ink-700); color: var(--on-dark-muted); transition: all .3s var(--ease);
}
.socials a:hover { color: var(--ink-900); background: var(--brand-500); border-color: var(--brand-500); transform: translateY(-4px); }
.footer-bottom { border-top: 1px solid var(--ink-800); padding-block: 22px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: .9rem; color: var(--on-dark-muted); }

/* --- 23. LIVE PREVIEW PAGE --- */
body.preview-page { overflow: hidden; height: 100vh; background: #E5E7EB; }
.pv-bar {
    height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 16px;
    padding: 0 clamp(12px, 2vw, 24px); background: var(--ink-900); color: var(--on-dark);
}
.pv-left { display: flex; align-items: center; gap: 14px; min-width: 0; }
.pv-home { font-family: var(--font-display); font-weight: 800; color: var(--white); white-space: nowrap; }
.pv-home span { color: var(--brand-500); }
.pv-title { font-weight: 700; color: var(--on-dark-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; border-left: 1px solid var(--ink-700); padding-left: 14px; }
.pv-devices { display: flex; gap: 6px; background: rgba(255, 255, 255, .06); padding: 4px; border-radius: var(--radius); }
.pv-devices button { width: 40px; height: 36px; border: 0; border-radius: 6px; background: transparent; color: var(--on-dark-muted); cursor: pointer; }
.pv-devices button.active, .pv-devices button:hover { background: var(--brand-500); color: var(--ink-900); }
.pv-right { display: flex; align-items: center; gap: 10px; }
.pv-close { width: 42px; height: 42px; display: grid; place-items: center; border-radius: var(--radius); color: var(--on-dark-muted); border: 1px solid var(--ink-700); }
.pv-close:hover { color: var(--white); border-color: var(--white); }
.pv-stage { height: calc(100vh - 64px); display: flex; justify-content: center; transition: padding .3s; }
.pv-stage.framed { padding: 20px; }
.pv-frame { width: 100%; height: 100%; border: 0; background: var(--white); transition: width .35s ease; }
.pv-stage.framed .pv-frame { border-radius: 14px; box-shadow: var(--shadow-md); }

/* --- 24. SCROLL REVEAL --- */
.js .reveal, .js .reveal-left, .js .reveal-right, .js .reveal-zoom {
    opacity: 0; transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: var(--d, 0s);
}
.js .reveal { transform: translateY(32px); }
.js .reveal-left { transform: translateX(-48px); }
.js .reveal-right { transform: translateX(48px); }
.js .reveal-zoom { transform: scale(.92); }
.js .in { opacity: 1 !important; transform: none !important; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
    .js .reveal, .js .reveal-left, .js .reveal-right, .js .reveal-zoom, .load-in { opacity: 1; transform: none; }
    .rotator > :first-child { opacity: 1; transform: none; }
}

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 1100px) {
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .catalog-bar { grid-template-columns: 1fr 1fr; }
    .catalog-bar .input:first-of-type { grid-column: 1 / -1; }
    .catalog-bar .btn { grid-column: 1 / -1; }
}

@media (max-width: 960px) {
    :root { --header-h: 68px; }
    .brand img { height: 46px; }

    .nav-toggle { display: inline-flex; position: relative; z-index: 1002; }
    .nav { gap: 10px; }
    .cur-btn { height: 46px; padding: 0 12px; }
    .nav-cta-desktop { display: none; }

    /* Off-canvas drawer: slides in from the left */
    .nav-menu {
        position: fixed; top: 0; left: 0; bottom: 0; z-index: 1001;
        width: min(82vw, 320px); flex-direction: column; align-items: stretch; gap: 0;
        background: var(--white); padding: 0 20px 28px; overflow-y: auto;
        box-shadow: 24px 0 60px -20px rgba(15, 23, 42, .45);
        transform: translateX(-105%); visibility: hidden;
        transition: transform .4s var(--ease), visibility .4s;
    }
    .nav-menu.open { transform: translateX(0); visibility: visible; }
    .drawer-head {
        display: flex; align-items: center; height: var(--header-h); margin: 0 -20px 8px; padding: 0 20px;
        border-bottom: 1px solid var(--line); background: var(--paper);
    }
    .drawer-head .brand img { height: 44px; }
    .nav-menu li:not(.drawer-head) { border-bottom: 1px solid var(--line); }
    .nav-menu a:not(.btn) {
        display: flex; align-items: center; gap: 12px; padding: 13px 4px;
        font-family: var(--font-body); font-size: .875rem; font-weight: 700; letter-spacing: .02em;
    }
    .nav-menu a:not(.btn) i { display: inline-block; width: 18px; text-align: center; color: var(--brand-600); font-size: .85rem; }
    .nav-menu a:not(.btn)::after { display: none; }
    .nav-menu a.active { color: var(--brand-700); background: var(--brand-50); border-radius: 6px; padding-left: 10px; }
    .nav-menu .btn { min-height: 44px; font-size: .875rem; }
    .nav-cta-mobile { display: block; border-bottom: 0 !important; margin-top: 22px; }
    .drawer-contact { display: grid; gap: 10px; margin-top: 18px; font-size: .8rem; }
    .drawer-contact a { display: flex; gap: 8px; align-items: center; color: var(--muted); font-weight: 700; word-break: break-all; }
    .drawer-contact i { color: var(--brand-600); }

    /* Items slide in one after another */
    .nav-menu li { opacity: 0; transform: translateX(-16px); transition: opacity .3s ease, transform .3s var(--ease); }
    .nav-menu.open li { opacity: 1; transform: none; }
    .nav-menu.open li:nth-child(2) { transition-delay: .08s; }
    .nav-menu.open li:nth-child(3) { transition-delay: .12s; }
    .nav-menu.open li:nth-child(4) { transition-delay: .16s; }
    .nav-menu.open li:nth-child(5) { transition-delay: .2s; }
    .nav-menu.open li:nth-child(6) { transition-delay: .24s; }
    .nav-menu.open li:nth-child(7) { transition-delay: .28s; }
    .nav-menu.open li:nth-child(8) { transition-delay: .32s; }

    .site-header { backdrop-filter: none; background: var(--white); } /* backdrop-filter would trap the fixed drawer inside the header */
    .nav-overlay {
        display: block; position: fixed; inset: 0; z-index: 999; background: rgba(15, 23, 42, .55); backdrop-filter: blur(2px);
        opacity: 0; visibility: hidden; transition: opacity .35s, visibility .35s;
    }
    .nav-overlay.show { opacity: 1; visibility: visible; }
    body.nav-open { overflow: hidden; }

    .hero-grid { grid-template-columns: 1fr; }
    .hero-visual { max-width: 560px; padding: 24px 12px 32px 12px; }
    .hero-photo { aspect-ratio: 4 / 3.4; }
    .float-card.fc-1 { left: -4px; }
    .float-card.fc-2 { right: -4px; }
    .grid-2, .compare, .contact-grid, .detail-grid { grid-template-columns: minmax(0, 1fr); }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .stat:nth-child(3) { border-left: 0; }
    .stats .grid-4 { row-gap: 32px; }
    .process-grid { grid-template-columns: repeat(2, 1fr); }
    .step:nth-child(3) { border-left: 0; padding-left: 0; }
    .step:nth-child(3)::before { left: 0; }
    .step { padding-bottom: 28px; }
    .cta-box { grid-template-columns: 1fr; }
    .buy-box { position: static; }
    .media-frame::before { inset: 14px -10px -14px 14px; }
    .media-badge { left: 10px; }
}

@media (max-width: 640px) {
    body { font-size: 1rem; }
    .grid-4 { grid-template-columns: 1fr 1fr; gap: 16px; }
    .process-grid { grid-template-columns: 1fr; }
    .step + .step { border-left: 0; padding-left: 0; border-top: 1px solid var(--ink-700); }
    .step + .step::before { left: 0; }
    .process-light .step + .step { border-top-color: var(--line); }
    .form-row, .feature-list { grid-template-columns: 1fr; gap: 0; }
    .feature-list { gap: 10px; }
    .footer-grid { grid-template-columns: 1fr; }
    .catalog-bar { grid-template-columns: 1fr; margin-top: -32px; }
    .hero-actions .btn, .cta-actions .btn { width: 100%; }
    .tpl-actions .btn { flex: 1 1 100%; }
    .float-card { padding: 10px 14px; gap: 10px; }
    .float-card .icon-tile { width: 36px; height: 36px; font-size: .95rem; }
    .dark .float-card strong { font-size: 1.1rem; }
    .code-chip { right: 16px; }
    .pv-title, .pv-devices { display: none; }
    .pv-right .btn-light { display: none; }
    .to-top { right: 14px; bottom: 14px; width: 44px; height: 44px; }
}

@media (max-width: 380px) {
    .cur-caret, .cur-btn > i:first-child { display: none; }
    .grid-4 { grid-template-columns: 1fr; }
    .stat + .stat { border-left: 0; }
    .brand-text { display: none; }
}
