/* =========================================================
   source.af — landing page styles
   Light (default) + dark themes, LTR + RTL, motion-safe.
   ========================================================= */

/* ---------- Design tokens ---------- */
:root {
    --bg: #f7f8fc;
    --bg-tint: #eff2f9;
    --surface: #ffffff;
    --surface-2: #f2f4f9;
    --text: #0c1222;
    --text-2: #364055;
    --muted: #64708a;
    --border: rgba(12, 18, 34, .08);
    --border-strong: rgba(12, 18, 34, .15);

    --brand: #4f46e5;
    --brand-2: #0ea5e9;
    --brand-3: #14b8a6;
    --brand-soft: rgba(79, 70, 229, .08);
    --success: #16a34a;

    --ink: #0b1020;            /* always-dark panels (terminal, REV) */
    --ink-text: #e2e8f0;
    --ink-muted: #8b98b0;

    --grid-line: rgba(12, 18, 34, .055);
    --header-bg: rgba(247, 248, 252, .75);
    --blob-opacity: .26;

    --shadow-sm: 0 1px 2px rgba(12, 18, 34, .05);
    --shadow: 0 12px 32px -14px rgba(12, 18, 34, .16), 0 2px 6px rgba(12, 18, 34, .04);
    --shadow-lg: 0 32px 64px -24px rgba(30, 27, 75, .28), 0 4px 12px rgba(12, 18, 34, .05);

    --radius: 22px;
    --radius-sm: 14px;
    --header-h: 72px;
    --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    --ease: cubic-bezier(.22, 1, .36, 1);
    --tracking-tight: -.035em;
    --tracking: -.02em;

    color-scheme: light;
}

[data-theme="dark"] {
    --bg: #07090f;
    --bg-tint: #0a0d16;
    --surface: #0f131d;
    --surface-2: #161b28;
    --text: #e9ecf4;
    --text-2: #c2c9d8;
    --muted: #8e99b0;
    --border: rgba(255, 255, 255, .08);
    --border-strong: rgba(255, 255, 255, .16);

    --brand: #8b8cff;
    --brand-2: #38bdf8;
    --brand-3: #2dd4bf;
    --brand-soft: rgba(139, 140, 255, .12);
    --success: #4ade80;

    --ink: #0b0f1a;

    --grid-line: rgba(255, 255, 255, .045);
    --header-bg: rgba(7, 9, 15, .72);
    --blob-opacity: .3;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
    --shadow: 0 16px 40px -16px rgba(0, 0, 0, .6);
    --shadow-lg: 0 32px 72px -24px rgba(0, 0, 0, .75);

    color-scheme: dark;
}

/* RTL: Persian / Pashto / Arabic font, and no negative tracking (it breaks joined scripts) */
[dir="rtl"] {
    --font: "Vazirmatn", "Inter", system-ui, Tahoma, sans-serif;
    --tracking-tight: 0;
    --tracking: 0;
}
:lang(zh) {
    --font: "Inter", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
    --tracking-tight: -.01em;
}

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

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.65;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    overflow-x: clip;
}

html.theme-anim body,
html.theme-anim body *,
html.theme-anim body *::before,
html.theme-anim body *::after {
    transition: background-color .45s var(--ease), border-color .45s var(--ease), color .45s var(--ease), fill .45s, stroke .45s !important;
}

::view-transition-old(root),
::view-transition-new(root) { animation: none; mix-blend-mode: normal; }

img, svg { display: block; }
.icon { flex-shrink: 0; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; }
p { margin: 0; }

::selection { background: color-mix(in srgb, var(--brand) 25%, transparent); }

:focus-visible {
    outline: 2px solid var(--brand);
    outline-offset: 3px;
    border-radius: 8px;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin-inline: auto;
    padding-inline: 20px;
}

.skip-link {
    position: fixed;
    inset-inline-start: 16px;
    top: -60px;
    z-index: 100;
    padding: 10px 16px;
    border-radius: 999px;
    background: var(--text);
    color: var(--bg);
    font-weight: 600;
    text-decoration: none;
    transition: top .3s var(--ease);
}
.skip-link:focus { top: 12px; }

.scroll-progress {
    position: fixed;
    top: 0;
    inset-inline: 0;
    height: 2px;
    z-index: 60;
    background: linear-gradient(90deg, var(--brand), var(--brand-2), var(--brand-3));
    transform: scaleX(var(--progress, 0));
    transform-origin: left;
    pointer-events: none;
}
[dir="rtl"] .scroll-progress { transform-origin: right; }

/* ---------- Buttons & small UI ---------- */
.btn {
    --h: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    height: var(--h);
    padding-inline: 24px;
    border-radius: 999px;
    border: 1px solid transparent;
    font: inherit;
    font-size: .95rem;
    font-weight: 600;
    letter-spacing: var(--tracking);
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    transition: transform .4s var(--ease), box-shadow .4s var(--ease), background-color .3s, border-color .3s, color .3s;
}
.btn--sm { --h: 42px; padding-inline: 18px; font-size: .9rem; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0) scale(.98); }

.btn--primary {
    background: var(--text);
    color: var(--bg);
    box-shadow: 0 10px 24px -12px color-mix(in srgb, var(--text) 70%, transparent);
}
.btn--primary:hover { box-shadow: 0 16px 32px -14px color-mix(in srgb, var(--brand) 80%, transparent); }

.btn--ghost {
    background: var(--surface);
    color: var(--text);
    border-color: var(--border-strong);
}
.btn--ghost:hover { border-color: color-mix(in srgb, var(--brand) 45%, var(--border-strong)); }

.btn--light {
    background: #fff;
    color: #0b1020;
}
.btn--light:hover { box-shadow: 0 14px 36px -12px rgba(139, 140, 255, .65); }

.icon-arrow { transition: transform .4s var(--ease); }
.btn:hover .icon-arrow,
.card:hover .icon-arrow,
.text-link:hover .icon-arrow,
.badge:hover .icon-arrow { transform: translateX(4px); }
[dir="rtl"] .icon-arrow { transform: scaleX(-1); }
[dir="rtl"] .btn:hover .icon-arrow,
[dir="rtl"] .card:hover .icon-arrow,
[dir="rtl"] .text-link:hover .icon-arrow,
[dir="rtl"] .badge:hover .icon-arrow { transform: scaleX(-1) translateX(4px); }

.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 42px;
    min-width: 42px;
    padding-inline: 11px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    font: inherit;
    font-size: .8rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform .3s var(--ease), border-color .3s, background-color .3s;
}
.icon-btn:hover { border-color: var(--border-strong); transform: translateY(-1px); }

.pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 11px;
    border-radius: 999px;
    font-size: .74rem;
    font-weight: 700;
    letter-spacing: .02em;
    color: var(--brand);
    background: var(--brand-soft);
    border: 1px solid color-mix(in srgb, var(--brand) 18%, transparent);
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    text-decoration: none;
    color: var(--text);
}

.pulse {
    position: relative;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success);
    flex-shrink: 0;
}
.pulse::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: var(--success);
    animation: ping 1.8s var(--ease) infinite;
}
.pulse--sm { width: 7px; height: 7px; }

@keyframes ping {
    0% { transform: scale(1); opacity: .7; }
    80%, 100% { transform: scale(3); opacity: 0; }
}

/* ---------- Header ---------- */
.header {
    position: fixed;
    top: 0;
    inset-inline: 0;
    z-index: 50;
    border-bottom: 1px solid transparent;
    transition: background-color .35s var(--ease), border-color .35s var(--ease), backdrop-filter .35s;
}
.header.is-scrolled,
.header.is-open {
    background: var(--header-bg);
    -webkit-backdrop-filter: saturate(180%) blur(16px);
    backdrop-filter: saturate(180%) blur(16px);
    border-bottom-color: var(--border);
}

.header__inner {
    display: flex;
    align-items: center;
    gap: 20px;
    height: var(--header-h);
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text);
    font-family: "Inter", system-ui, sans-serif;
    font-weight: 800;
    font-size: 1.15rem;
    letter-spacing: -.03em;
    flex-shrink: 0;
}
.logo__mark {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    color: #fff;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    box-shadow: 0 8px 18px -8px var(--brand);
    transition: transform .5s var(--ease);
}
.logo:hover .logo__mark { transform: rotate(-8deg) scale(1.05); }
.logo__tld { color: var(--muted); font-weight: 600; }

.nav {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-inline: auto;
}
.nav a {
    position: relative;
    padding: 8px 14px;
    border-radius: 999px;
    font-size: .92rem;
    font-weight: 500;
    color: var(--text-2);
    text-decoration: none;
    transition: color .25s, background-color .25s;
}
.nav a:hover { color: var(--text); background: var(--surface-2); }
.nav a.is-active { color: var(--text); }
.nav a.is-active::after {
    content: "";
    position: absolute;
    inset-inline: 14px;
    bottom: 3px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--brand), var(--brand-2));
}
.nav .nav__cta { display: none; }

.header__actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Language menu */
.lang { position: relative; }
.lang__chev { transition: transform .3s var(--ease); opacity: .6; }
.lang.is-open .lang__chev { transform: rotate(180deg); }
.lang__menu {
    position: absolute;
    top: calc(100% + 10px);
    inset-inline-end: 0;
    min-width: 210px;
    margin: 0;
    padding: 6px;
    list-style: none;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 18px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px) scale(.97);
    transform-origin: top right;
    transition: opacity .25s var(--ease), transform .35s var(--ease), visibility .35s;
}
[dir="rtl"] .lang__menu { transform-origin: top left; }
.lang.is-open .lang__menu { opacity: 1; visibility: visible; transform: none; }
.lang__menu a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: .93rem;
    font-weight: 500;
    color: var(--text);
    text-decoration: none;
    transition: background-color .2s;
}
.lang__menu a:hover { background: var(--surface-2); }
.lang__menu a[aria-current] { background: var(--brand-soft); font-weight: 600; }
.lang__check { color: var(--brand); }
.lang__iso { font-size: .7rem; font-weight: 700; color: var(--muted); font-family: var(--font-mono); }

/* Theme toggle */
.theme-toggle { position: relative; width: 42px; padding: 0; overflow: hidden; }
.theme-toggle .icon { position: absolute; transition: transform .6s var(--ease), opacity .35s; }
.theme-toggle .icon-moon { opacity: 0; transform: rotate(-90deg) scale(.4); }
[data-theme="dark"] .theme-toggle .icon-sun { opacity: 0; transform: rotate(90deg) scale(.4); }
[data-theme="dark"] .theme-toggle .icon-moon { opacity: 1; transform: none; }

/* Mobile menu button */
.menu-btn { display: none; position: relative; width: 42px; padding: 0; }
.menu-btn .icon { position: absolute; transition: transform .4s var(--ease), opacity .25s; }
.menu-btn .icon-close { opacity: 0; transform: rotate(-90deg); }
.header.is-open .menu-btn .icon-menu { opacity: 0; transform: rotate(90deg); }
.header.is-open .menu-btn .icon-close { opacity: 1; transform: none; }

@media (max-width: 1080px) {
    .menu-btn { display: inline-flex; }
    .header__cta { display: none; }
    .header__actions { margin-inline-start: auto; }
    .header.is-open { background: var(--surface); }

    .nav {
        position: fixed;
        top: calc(var(--header-h) + 8px);
        inset-inline: 12px;
        flex-direction: column;
        align-items: stretch;
        gap: 2px;
        margin: 0;
        padding: 10px;
        background: var(--surface);
        border: 1px solid var(--border);
        border-radius: 22px;
        box-shadow: var(--shadow-lg);
        opacity: 0;
        visibility: hidden;
        transform: translateY(-12px) scale(.98);
        transform-origin: top center;
        transition: opacity .3s var(--ease), transform .45s var(--ease), visibility .45s;
    }
    .header.is-open .nav { opacity: 1; visibility: visible; transform: none; }
    .nav a { padding: 13px 16px; font-size: 1rem; border-radius: 14px; }
    .nav a.is-active { background: var(--surface-2); }
    .nav a.is-active::after { display: none; }
    .nav .nav__cta { display: inline-flex; margin-top: 8px; color: var(--bg); justify-content: center; }
    .nav .nav__cta:hover { background: var(--text); color: var(--bg); }
}

/* ---------- Sections ---------- */
.section {
    position: relative;
    padding-block: clamp(80px, 11vw, 136px);
}
.section--tint {
    background: var(--bg-tint);
    border-block: 1px solid var(--border);
}

.section__head { max-width: 680px; margin-bottom: clamp(40px, 6vw, 64px); }
.section__head--center { margin-inline: auto; text-align: center; }
.section__head--center .eyebrow { justify-content: center; }

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--brand);
}
[dir="rtl"] .eyebrow { letter-spacing: 0; font-size: .88rem; }
.eyebrow::before {
    content: "";
    width: 20px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--brand), var(--brand-2));
}
.eyebrow--light { color: #a5b4fc; }

.section__title {
    margin: 16px 0 18px;
    font-size: clamp(2rem, 4.4vw, 3rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: var(--tracking-tight);
}
[dir="rtl"] .section__title { line-height: 1.35; }
.section__lead {
    font-size: clamp(1.02rem, 1.4vw, 1.12rem);
    color: var(--muted);
    max-width: 620px;
}
.section__head--center .section__lead { margin-inline: auto; }

/* ---------- Cards ---------- */
.card {
    --accent: var(--brand);
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 28px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: transform .55s var(--ease), box-shadow .55s var(--ease), border-color .35s;
}
.card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), color-mix(in srgb, var(--accent) 13%, transparent), transparent 45%);
    opacity: 0;
    transition: opacity .45s var(--ease);
}
.card[data-spotlight]:hover::before { opacity: 1; }
.card[data-spotlight]:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
    border-color: color-mix(in srgb, var(--accent) 32%, var(--border));
}
.card--dashed {
    background: transparent;
    border-style: dashed;
    border-color: var(--border-strong);
}

.card__title {
    font-size: 1.18rem;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: var(--tracking);
    margin-bottom: 8px;
}
.card__text { color: var(--muted); font-size: .96rem; }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding-top: calc(var(--header-h) + clamp(56px, 9vw, 112px));
    padding-bottom: clamp(72px, 9vw, 120px);
}
.hero__bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hero__grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(var(--grid-line) 1px, transparent 1px),
        linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 30%, #000 25%, transparent 75%);
    mask-image: radial-gradient(ellipse 75% 65% at 50% 30%, #000 25%, transparent 75%);
}
.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(70px);
    opacity: var(--blob-opacity);
    will-change: transform;
    animation: drift 20s ease-in-out infinite alternate;
}
.blob--1 { width: 560px; height: 560px; top: -220px; inset-inline-start: -160px; background: radial-gradient(circle, var(--brand), transparent 68%); }
.blob--2 { width: 480px; height: 480px; top: 0; inset-inline-end: -180px; background: radial-gradient(circle, var(--brand-2), transparent 68%); animation-delay: -7s; animation-duration: 24s; }
.blob--3 { width: 420px; height: 420px; bottom: -220px; left: 38%; background: radial-gradient(circle, var(--brand-3), transparent 68%); animation-delay: -13s; }

@keyframes drift {
    0%   { transform: translate3d(0, 0, 0) scale(1); }
    50%  { transform: translate3d(50px, 40px, 0) scale(1.1); }
    100% { transform: translate3d(-40px, 70px, 0) scale(.94); }
}

.hero__inner {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr);
    gap: clamp(40px, 5vw, 64px);
    align-items: center;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding-block: 6px;
    padding-inline: 14px 16px;
    border-radius: 999px;
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    font-size: .86rem;
    font-weight: 500;
    color: var(--text-2);
    text-decoration: none;
    transition: border-color .3s, box-shadow .4s var(--ease);
}
.badge:hover { border-color: color-mix(in srgb, var(--brand) 40%, var(--border)); box-shadow: var(--shadow); }
.badge__tag {
    padding: 2px 8px;
    border-radius: 999px;
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .08em;
    color: #fff;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
}

.hero__title {
    margin: 26px 0 24px;
    font-size: clamp(2.5rem, 5vw, 3.6rem);
    font-weight: 800;
    line-height: 1.06;
    letter-spacing: -.045em;
}
[dir="rtl"] .hero__title { letter-spacing: 0; line-height: 1.35; font-size: clamp(2.2rem, 4.6vw, 3.3rem); }
:lang(zh) .hero__title { letter-spacing: -.02em; line-height: 1.15; }
.hero__title .line { display: block; }

.gradient-text {
    background: linear-gradient(100deg, var(--brand) 0%, var(--brand-2) 35%, var(--brand-3) 65%, var(--brand) 100%);
    background-size: 220% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    padding-bottom: .08em;
    animation: shine 9s linear infinite;
}
@keyframes shine { to { background-position: 220% center; } }

.hero__lead {
    max-width: 560px;
    margin-bottom: 36px;
    font-size: clamp(1.05rem, 1.6vw, 1.2rem);
    color: var(--muted);
}
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; }

.stats {
    display: flex;
    flex-wrap: wrap;
    margin: 52px 0 0;
}
.stat {
    display: flex;
    flex-direction: column-reverse;
    padding-inline: 32px;
    border-inline-start: 1px solid var(--border-strong);
}
.stat:first-child { padding-inline-start: 0; border-inline-start: 0; }
.stat dt { font-size: .86rem; color: var(--muted); }
.stat dd {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
}
.stat__rev {
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}
.stat__rev .pulse { -webkit-text-fill-color: initial; }

/* Hero visual: terminal */
.hero__visual { position: relative; perspective: 1400px; }
.terminal {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    background:
        radial-gradient(120% 80% at 100% 0%, rgba(99, 102, 241, .16), transparent 60%),
        var(--ink);
    border: 1px solid rgba(255, 255, 255, .08);
    box-shadow: var(--shadow-lg);
    color: var(--ink-text);
    font-family: var(--font-mono);
    font-size: .84rem;
    transform: rotateY(-7deg) rotateX(4deg);
    transition: transform 1s var(--ease);
}
[dir="rtl"] .terminal { transform: rotateY(7deg) rotateX(4deg); }
.hero__visual:hover .terminal { transform: none; }
.terminal__bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
    background: rgba(255, 255, 255, .02);
}
.terminal__dot { width: 11px; height: 11px; border-radius: 50%; }
.terminal__title { flex: 1; text-align: center; color: #64748b; font-size: .76rem; margin-inline-end: 50px; }
.terminal__body {
    min-height: 300px;
    padding: 22px 24px 26px;
    line-height: 1.95;
}
.t-line { min-height: 1.95em; white-space: pre-wrap; word-break: break-word; }
.t-line.is-new { animation: lineIn .45s var(--ease); }
@keyframes lineIn { from { opacity: 0; transform: translateY(4px); } }
.t-prompt { color: #a5b4fc; font-weight: 600; }
.t-cmd { color: #f1f5f9; }
.t-out { color: var(--ink-muted); }
.t-key { color: #67e8f9; }
.t-ok  { color: #4ade80; }
.t-cursor {
    display: inline-block;
    width: 8px;
    height: 1.15em;
    margin-inline-start: 2px;
    vertical-align: text-bottom;
    background: #a5b4fc;
    animation: blink 1.05s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.float-chip {
    position: absolute;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px 10px 10px;
    padding-inline: 10px 16px;
    border-radius: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    font-size: .85rem;
    font-weight: 600;
    white-space: nowrap;
    animation: bob 7s ease-in-out infinite;
}
.float-chip--a { top: -22px; inset-inline-start: -28px; }
.float-chip--b { bottom: -26px; inset-inline-end: -26px; animation-delay: -3.5s; }
.float-chip__icon {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    color: var(--success);
    background: color-mix(in srgb, var(--success) 12%, transparent);
}
.float-chip__icon--alt { color: var(--brand); background: var(--brand-soft); }
@keyframes bob {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@media (max-width: 960px) {
    .hero__inner { grid-template-columns: 1fr; }
    .hero__visual { max-width: 560px; }
    .terminal, [dir="rtl"] .terminal { transform: none; }
}
@media (max-width: 560px) {
    .float-chip { display: none; }
    .terminal__body { min-height: 260px; padding: 18px; font-size: .78rem; }
    .stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 40px; }
    .stat { padding-inline: 14px; }
    .stat dt { font-size: .78rem; line-height: 1.35; }
    .stat dd { font-size: 1.6rem; }
    .hero__ctas .btn { flex: 1 1 auto; }
}

/* ---------- Marquee ---------- */
.marquee {
    overflow: hidden;
    padding-block: 22px;
    border-block: 1px solid var(--border);
    background: var(--surface);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee__track {
    display: flex;
    width: max-content;
    animation: marquee 45s linear infinite;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__group {
    display: flex;
    align-items: center;
    gap: 48px;
    padding-inline-end: 48px;
}
.marquee__item {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
    font-size: 1rem;
    font-weight: 600;
    color: var(--muted);
}
.marquee__item .icon { color: var(--brand); opacity: .8; }
.marquee__item--domain { font-family: var(--font-mono); font-weight: 500; color: var(--text-2); }
.marquee__dot { width: 8px; height: 8px; border-radius: 50%; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Platforms ---------- */
.platforms {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(255px, 1fr));
    gap: 20px;
}
.platform {
    display: flex;
    flex-direction: column;
    color: inherit;
    text-decoration: none;
}
.platform__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 26px;
}
.platform__icon {
    display: grid;
    place-items: center;
    width: 52px;
    height: 52px;
    border-radius: 16px;
    color: var(--accent);
    background: color-mix(in srgb, var(--accent) 12%, transparent);
    border: 1px solid color-mix(in srgb, var(--accent) 20%, transparent);
    transition: transform .55s var(--ease);
}
.platform:hover .platform__icon { transform: scale(1.08) rotate(-5deg); }
.platform__icon--muted { color: var(--muted); background: var(--surface-2); border-color: var(--border); margin-bottom: 22px; }
.platform__domain {
    margin: -2px 0 14px;
    font-family: var(--font-mono);
    font-size: .8rem;
    color: var(--muted);
    text-align: start;
}
[dir="rtl"] .platform__domain { text-align: right; }

.status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 4px 11px;
    border-radius: 999px;
    font-size: .74rem;
    font-weight: 700;
    color: var(--success);
    background: color-mix(in srgb, var(--success) 10%, transparent);
}
.status__dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 3px color-mix(in srgb, var(--success) 20%, transparent); }

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 20px 0 26px;
    padding: 0;
    list-style: none;
}
.tags li {
    padding: 4px 10px;
    border-radius: 999px;
    font-size: .74rem;
    font-weight: 600;
    color: var(--text-2);
    background: var(--surface-2);
    border: 1px solid var(--border);
}
.platform__link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    font-size: .92rem;
    font-weight: 600;
    color: var(--text);
}
.platform__link .icon { color: var(--accent); }
.platform--more { justify-content: center; min-height: 280px; }

/* ---------- Services ---------- */
.services {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}
.service { padding: 32px; }
.service__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 26px;
}
.service__icon {
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    border-radius: 17px;
    color: var(--brand);
    background: linear-gradient(135deg, var(--brand-soft), color-mix(in srgb, var(--brand-2) 10%, transparent));
    border: 1px solid color-mix(in srgb, var(--brand) 16%, transparent);
    transition: transform .55s var(--ease);
}
.service:hover .service__icon { transform: rotate(-8deg) scale(1.08); }
.service--featured {
    background:
        linear-gradient(var(--surface), var(--surface)) padding-box,
        linear-gradient(135deg, color-mix(in srgb, var(--brand) 55%, transparent), color-mix(in srgb, var(--brand-2) 40%, transparent), var(--border)) border-box;
    border-color: transparent;
}
.service--featured .service__icon { color: #fff; background: linear-gradient(135deg, var(--brand), var(--brand-2)); border-color: transparent; }

@media (max-width: 960px) { .services { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .services { grid-template-columns: 1fr; } }

/* ---------- REV ---------- */
.rev {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, .95fr);
    gap: clamp(36px, 5vw, 64px);
    align-items: center;
    padding: clamp(32px, 6vw, 72px);
    border-radius: 32px;
    background: var(--ink);
    border: 1px solid rgba(255, 255, 255, .07);
    color: var(--ink-text);
    box-shadow: var(--shadow-lg);
}
.rev__glow {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(60% 70% at 0% 0%, rgba(99, 102, 241, .32), transparent 60%),
        radial-gradient(50% 60% at 100% 100%, rgba(20, 184, 166, .22), transparent 60%);
    animation: glow 12s ease-in-out infinite alternate;
}
@keyframes glow { to { filter: hue-rotate(25deg); opacity: .8; } }
.rev__bigtext {
    position: absolute;
    z-index: -1;
    inset-inline-end: -1.5vw;
    bottom: -5vw;
    font-family: "Inter", system-ui, sans-serif;
    font-size: clamp(9rem, 24vw, 20rem);
    font-weight: 900;
    line-height: 1;
    letter-spacing: -.06em;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 255, 255, .07);
    pointer-events: none;
    user-select: none;
}
.rev__title {
    margin: 16px 0 18px;
    font-size: clamp(2.6rem, 6vw, 4.4rem);
    font-weight: 800;
    line-height: 1.02;
    letter-spacing: -.045em;
    background: linear-gradient(100deg, #fff 30%, #a5b4fc 60%, #5eead4);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    padding-bottom: .06em;
}
[dir="rtl"] .rev__title { letter-spacing: 0; line-height: 1.3; }
.rev__lead { color: var(--ink-muted); font-size: 1.08rem; max-width: 520px; }

.checklist {
    display: grid;
    gap: 12px;
    margin: 28px 0 32px;
    padding: 0;
    list-style: none;
}
.checklist li { display: flex; align-items: center; gap: 12px; font-weight: 500; }
.checklist__icon {
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    border-radius: 8px;
    color: #5eead4;
    background: rgba(94, 234, 212, .12);
    border: 1px solid rgba(94, 234, 212, .2);
}
.rev__note {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 22px;
    font-size: .84rem;
    color: var(--ink-muted);
}
.rev__note .icon { color: #5eead4; }

.hex {
    border-radius: 20px;
    background: rgba(255, 255, 255, .03);
    border: 1px solid rgba(255, 255, 255, .08);
    font-family: var(--font-mono);
    font-size: .82rem;
    overflow: hidden;
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}
.hex__head, .hex__foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 18px;
    font-size: .74rem;
    color: var(--ink-muted);
}
.hex__head { border-bottom: 1px solid rgba(255, 255, 255, .06); }
.hex__foot { border-top: 1px solid rgba(255, 255, 255, .06); }
.hex__status { display: inline-flex; align-items: center; gap: 8px; color: #4ade80; }
.hex__status .pulse, .hex__status .pulse::after { background: #4ade80; }
.hex__body { padding: 14px 18px; }
.hex__row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 18px;
    align-items: center;
    line-height: 2;
}
.hex__off { color: #475569; }
.hex__bytes { display: flex; justify-content: space-between; gap: 6px; color: #cbd5e1; }
.hex__ascii { display: flex; color: #64748b; letter-spacing: .08em; }
.hex__b, .hex__ascii span { transition: color .6s, text-shadow .6s; }
.hex__b.is-magic { color: #a5b4fc; }
.hex .is-hot { color: #67e8f9; text-shadow: 0 0 12px rgba(103, 232, 249, .7); transition: none; }
.hex__bar {
    position: relative;
    flex: 1;
    max-width: 180px;
    height: 4px;
    border-radius: 4px;
    background: rgba(255, 255, 255, .08);
    overflow: hidden;
}
.hex__bar span {
    position: absolute;
    inset-block: 0;
    left: 0;
    width: 40%;
    border-radius: inherit;
    background: linear-gradient(90deg, #6366f1, #22d3ee);
    animation: scan 2.6s var(--ease) infinite;
}
@keyframes scan {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(260%); }
}

@media (max-width: 960px) {
    .rev { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
    .hex { font-size: .72rem; }
    .hex__row { gap: 10px; }
    .hex__ascii { display: none; }
    .hex__row { grid-template-columns: auto 1fr; }
}

/* ---------- Security ---------- */
.security {
    display: grid;
    grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
    gap: clamp(40px, 6vw, 80px);
    align-items: center;
}
.security__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}
.pillar__icon {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    margin-bottom: 20px;
    border-radius: 14px;
    color: var(--brand-3);
    background: color-mix(in srgb, var(--brand-3) 12%, transparent);
    border: 1px solid color-mix(in srgb, var(--brand-3) 20%, transparent);
}
.pillar { --accent: var(--brand-3); }
.security__grid .pillar:nth-child(even) { transform: translateY(28px); }
.security__grid .pillar:nth-child(even):hover { transform: translateY(23px); }

.orb {
    position: relative;
    display: grid;
    place-items: center;
    width: 220px;
    aspect-ratio: 1;
    margin-top: 48px;
}
.orb__ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 1px dashed color-mix(in srgb, var(--brand) 35%, transparent);
    animation: spin 30s linear infinite;
}
.orb__ring--2 { inset: 26px; border-style: solid; border-color: color-mix(in srgb, var(--brand-2) 22%, transparent); border-top-color: var(--brand-2); animation-duration: 8s; }
.orb__ring--3 { inset: 52px; border-color: color-mix(in srgb, var(--brand-3) 30%, transparent); animation-direction: reverse; animation-duration: 20s; }
.orb__wave {
    position: absolute;
    inset: 70px;
    border-radius: 50%;
    border: 1px solid color-mix(in srgb, var(--brand-3) 50%, transparent);
    animation: wave 3.2s var(--ease) infinite;
}
.orb__wave--2 { animation-delay: 1.6s; }
.orb__core {
    position: relative;
    display: grid;
    place-items: center;
    width: 80px;
    height: 80px;
    border-radius: 26px;
    color: #fff;
    background: linear-gradient(135deg, var(--brand), var(--brand-3));
    box-shadow: 0 20px 40px -14px color-mix(in srgb, var(--brand) 80%, transparent);
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes wave {
    0% { transform: scale(1); opacity: .8; }
    100% { transform: scale(2.6); opacity: 0; }
}

@media (max-width: 960px) {
    .security { grid-template-columns: 1fr; }
    .orb { display: none; }
}
@media (max-width: 620px) {
    .security__grid { grid-template-columns: 1fr; }
    .security__grid .pillar:nth-child(even),
    .security__grid .pillar:nth-child(even):hover { transform: none; }
}

/* ---------- Process ---------- */
.steps { position: relative; }
.steps__list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 28px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.steps__line {
    position: absolute;
    top: 23px;
    inset-inline: 24px calc(25% - 45px); /* first dot centre → last dot centre */
    height: 2px;
    border-radius: 2px;
    background: var(--border-strong);
    overflow: hidden;
}
.steps__line::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, var(--brand), var(--brand-2), var(--brand-3));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 1.6s var(--ease) .2s;
}
[dir="rtl"] .steps__line::after { transform-origin: right; background: linear-gradient(270deg, var(--brand), var(--brand-2), var(--brand-3)); }
.steps.is-visible .steps__line::after,
html:not(.js) .steps__line::after { transform: scaleX(1); }

.step { position: relative; }
.step__num {
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    margin-bottom: 22px;
    border-radius: 50%;
    font-family: var(--font-mono);
    font-size: .85rem;
    font-weight: 600;
    color: var(--muted);
    background: var(--bg);
    border: 1px solid var(--border-strong);
    transition: color .5s var(--d, 0s), background .5s var(--d, 0s), border-color .5s var(--d, 0s), box-shadow .5s var(--d, 0s), transform .6s var(--ease) var(--d, 0s);
}
.steps.is-visible .step__num,
html:not(.js) .step__num {
    color: #fff;
    border-color: transparent;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    box-shadow: 0 0 0 6px var(--bg), 0 10px 24px -10px var(--brand);
    transform: scale(1.04);
}
.step__title { font-size: 1.12rem; font-weight: 700; letter-spacing: var(--tracking); margin-bottom: 8px; }
.step .card__text { opacity: 0; transform: translateY(10px); transition: opacity .7s var(--ease) var(--d, 0s), transform .7s var(--ease) var(--d, 0s); }
.step__title { transition: opacity .7s var(--ease) var(--d, 0s); }
html.js .steps:not(.is-visible) .step__title { opacity: .35; }
.steps.is-visible .step .card__text,
html:not(.js) .step .card__text { opacity: 1; transform: none; }

@media (max-width: 900px) {
    .steps__list { grid-template-columns: 1fr; gap: 32px; }
    .steps__line { display: none; }
    .step { padding-inline-start: 72px; min-height: 48px; }
    .step__num { position: absolute; inset-inline-start: 0; top: -6px; margin: 0; }
    .step:not(:last-child)::after {
        content: "";
        position: absolute;
        inset-inline-start: 23px;
        top: 42px;
        bottom: -28px;
        width: 2px;
        border-radius: 2px;
        background: var(--border-strong);
        transition: background .6s var(--d, 0s);
    }
    .steps.is-visible .step:not(:last-child)::after { background: linear-gradient(180deg, var(--brand), var(--brand-2)); }
}

/* ---------- Partners ---------- */
/* Responsive grid: 1 → many partners, cards keep equal height. */
.partners {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr));
    gap: 20px;
    align-items: stretch;
}
.partner {
    display: flex;
    flex-direction: column;
    padding: 0;
}
.partner__visual {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    padding: 30px 16px;
    background:
        radial-gradient(circle at 50% 60%, var(--brand-soft), transparent 70%),
        var(--surface-2);
    border-bottom: 1px solid var(--border);
    direction: ltr;
}
.partner__body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    flex: 1;
    padding: 24px 26px 26px;
}
.partner__body .card__text { font-size: .94rem; }
.partner__body .btn { margin-top: auto; }
.partner__logo {
    display: grid;
    place-items: center;
    width: 58px;
    height: 58px;
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 18px;
    color: #fff;
    box-shadow: 0 14px 30px -12px rgba(0, 0, 0, .35);
    animation: bob 6s ease-in-out infinite;
}
.partner__logo.has-img { background: #fff; padding: 10px; }

.partner__logo--us { background: linear-gradient(135deg, var(--brand), var(--brand-2)); }
.partner__logo--them { background: linear-gradient(135deg, #10b981, #0ea5e9); animation-delay: -3s; }
.partner__link {
    position: relative;
    flex: 1;
    max-width: 120px;
    height: 2px;
    margin-inline: 10px;
    background-image: linear-gradient(90deg, var(--border-strong) 50%, transparent 50%);
    background-size: 10px 2px;
}
.partner__packet {
    position: absolute;
    top: 50%;
    left: 0;
    width: 10px;
    height: 10px;
    margin-top: -5px;
    border-radius: 50%;
    background: var(--brand-2);
    box-shadow: 0 0 14px var(--brand-2);
    animation: packet 2.8s var(--ease) infinite alternate;
}
@keyframes packet { to { left: calc(100% - 10px); background: #10b981; box-shadow: 0 0 14px #10b981; } }

.partner__body .pill { margin-bottom: 14px; }
.partner__name {
    width: 100%;
    margin-bottom: 10px;
    font-family: "Inter", system-ui, sans-serif;
    font-size: clamp(1.2rem, 1.9vw, 1.45rem);
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: -.03em;
    text-align: start;
}
[dir="rtl"] .partner__name { text-align: right; }
.partner__us { color: var(--muted); font-weight: 600; }
.partner__x { color: var(--muted); font-weight: 500; margin-inline: 2px; }
.partner .checklist { margin: 16px 0 22px; }
.checklist--compact { gap: 10px; font-size: .95rem; }
.checklist--compact .checklist__icon {
    color: var(--brand-3);
    background: color-mix(in srgb, var(--brand-3) 12%, transparent);
    border-color: color-mix(in srgb, var(--brand-3) 22%, transparent);
}
.partner-join { display: flex; flex-direction: column; justify-content: center; min-height: 260px; }
.partner-join .text-link { margin-top: 20px; }

/* ---------- Projects (our work) ---------- */
.projects {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
    gap: 20px;
}
.project {
    display: flex;
    flex-direction: column;
    padding: 0;
    color: inherit;
    text-decoration: none;
}
.project__shot {
    position: relative;
    height: 150px;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
    background:
        radial-gradient(120% 140% at 0% 0%, color-mix(in srgb, var(--accent) 26%, transparent), transparent 55%),
        radial-gradient(90% 120% at 100% 100%, color-mix(in srgb, var(--accent) 14%, transparent), transparent 60%),
        var(--surface-2);
    transition: background-size .6s var(--ease);
}
.project__shot::after {
    content: "";
    position: absolute;
    inset: 38px 0 0;
    background-image:
        linear-gradient(color-mix(in srgb, var(--accent) 14%, transparent) 1px, transparent 1px),
        linear-gradient(90deg, color-mix(in srgb, var(--accent) 14%, transparent) 1px, transparent 1px);
    background-size: 22px 22px;
    -webkit-mask-image: radial-gradient(ellipse 60% 70% at 50% 60%, #000 10%, transparent 75%);
    mask-image: radial-gradient(ellipse 60% 70% at 50% 60%, #000 10%, transparent 75%);
    pointer-events: none;
}
.project__bar {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 12px;
    direction: ltr;
}
.project__bar i { width: 8px; height: 8px; border-radius: 50%; background: var(--border-strong); }
.project__url {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    flex: 1;
    margin-inline-start: 8px;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--surface);
    border: 1px solid var(--border);
    font-family: var(--font-mono);
    font-size: .7rem;
    color: var(--muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.project__url .icon { color: var(--success); }
.project__logo {
    position: absolute;
    z-index: 1;
    left: 50%;
    top: 60%;
    display: grid;
    place-items: center;
    width: 66px;
    height: 66px;
    overflow: hidden;
    border-radius: 20px;
    background: var(--surface);
    color: var(--accent);
    border: 1px solid color-mix(in srgb, var(--accent) 25%, var(--border));
    box-shadow: 0 16px 32px -16px color-mix(in srgb, var(--accent) 80%, transparent);
    transform: translate(-50%, -50%);
    transition: transform .6s var(--ease);
}
.project__logo .logo-img { width: 42px; height: 42px; object-fit: contain; }
.project:hover .project__logo { transform: translate(-50%, -50%) scale(1.08) rotate(-4deg); }
.project__body {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    flex: 1;
    padding: 20px 24px 24px;
}
.project__body .card__title { margin-top: 12px; margin-bottom: 2px; }
.project__body .platform__domain { margin: 0 0 12px; }
.project__body .tags { margin: 16px 0 20px; }
.project__body .platform__link { margin-top: auto; }
.project__body .platform__link .icon { color: var(--accent); }

.rel {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 700;
    white-space: nowrap;
}
.rel--built    { color: var(--brand);  background: var(--brand-soft); }
.rel--collab   { color: #0d9488; background: rgba(20, 184, 166, .13); }
.rel--security { color: #b45309; background: rgba(245, 158, 11, .15); }
[data-theme="dark"] .rel--collab   { color: #2dd4bf; }
[data-theme="dark"] .rel--security { color: #fbbf24; }

.project--private {
    position: relative;
    justify-content: center;
    gap: 6px;
    padding: 32px 28px;
    min-height: 300px;
    background: var(--ink);
    color: var(--ink-text);
    border-color: rgba(255, 255, 255, .08);
}
.project--private .card__text { color: var(--ink-muted); }
.project--private .card__title { color: #fff; }
.project--private .text-link { margin-top: 18px; color: #fff; }
.project__private-glow {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(70% 60% at 0% 0%, rgba(99, 102, 241, .35), transparent 60%),
        radial-gradient(60% 60% at 100% 100%, rgba(20, 184, 166, .25), transparent 60%);
}
.project__lock {
    display: grid;
    place-items: center;
    width: 56px;
    height: 56px;
    margin-bottom: 14px;
    border-radius: 18px;
    color: #a5b4fc;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .1);
}

/* uploaded logos inside icon bubbles */
.platform__icon .logo-img { width: 30px; height: 30px; object-fit: contain; border-radius: 6px; }

/* ---------- Contact ---------- */
.contact {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr);
    gap: clamp(36px, 5vw, 64px);
    padding: clamp(28px, 5.5vw, 64px);
    border-radius: 32px;
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}
.contact__glow {
    position: absolute;
    z-index: -1;
    width: 520px;
    height: 520px;
    top: -260px;
    inset-inline-start: -200px;
    border-radius: 50%;
    background: radial-gradient(circle, color-mix(in srgb, var(--brand) 22%, transparent), transparent 65%);
    filter: blur(20px);
    animation: drift 18s ease-in-out infinite alternate;
}
.contact .section__title { margin-top: 14px; }

.channels { display: grid; gap: 10px; margin-top: 36px; }
.channels__label { font-size: .82rem; font-weight: 600; color: var(--muted); }
.channel {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: var(--bg);
    text-decoration: none;
    transition: transform .4s var(--ease), border-color .3s;
}
.channel:hover { transform: translateX(4px); border-color: color-mix(in srgb, var(--brand) 35%, var(--border)); }
[dir="rtl"] .channel:hover { transform: translateX(-4px); }
.channel__icon {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    color: var(--brand);
    background: var(--brand-soft);
}
.channel small { display: block; font-size: .75rem; color: var(--muted); }
.channel b { display: block; font-weight: 600; font-size: .95rem; }

.form { display: grid; gap: 20px; align-content: start; }
.field { display: grid; gap: 8px; margin: 0; padding: 0; border: 0; min-width: 0; }
.field label, .field legend { padding: 0; font-size: .88rem; font-weight: 600; color: var(--text-2); }
.field legend { margin-bottom: 8px; }
.field input,
.field textarea {
    width: 100%;
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid var(--border-strong);
    background: var(--bg);
    color: var(--text);
    font: inherit;
    font-size: .96rem;
    transition: border-color .25s, box-shadow .3s var(--ease), background-color .25s;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input::placeholder,
.field textarea::placeholder { color: color-mix(in srgb, var(--muted) 75%, transparent); }
.field input:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--brand);
    background: var(--surface);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 16%, transparent);
}

.choice { display: flex; flex-wrap: wrap; gap: 8px; }
.choice__item { position: relative; cursor: pointer; }
.choice__item input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}
.choice__item span {
    display: inline-flex;
    align-items: center;
    padding: 8px 15px;
    border-radius: 999px;
    border: 1px solid var(--border-strong);
    background: var(--bg);
    font-size: .88rem;
    font-weight: 500;
    color: var(--text-2);
    transition: all .3s var(--ease);
}
.choice__item:hover span { border-color: color-mix(in srgb, var(--brand) 40%, var(--border-strong)); }
.choice__item input:checked + span {
    color: #fff;
    border-color: transparent;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    box-shadow: 0 8px 18px -10px var(--brand);
}
.choice__item input:focus-visible + span { outline: 2px solid var(--brand); outline-offset: 2px; }

.form__foot { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.form__note { display: flex; align-items: center; gap: 6px; font-size: .8rem; color: var(--muted); max-width: 300px; }
.form__status { min-height: 1.4em; font-size: .9rem; font-weight: 600; color: var(--success); }
.icon-send { transition: transform .4s var(--ease); }
.btn:hover .icon-send { transform: translate(3px, -3px); }
[dir="rtl"] .icon-send { transform: scaleX(-1); }
[dir="rtl"] .btn:hover .icon-send { transform: scaleX(-1) translate(3px, -3px); }

@media (max-width: 900px) {
    .contact { grid-template-columns: 1fr; }
}

/* ---------- Footer ---------- */
.footer {
    padding-block: 64px 32px;
    border-top: 1px solid var(--border);
    background: var(--surface);
}
.footer__grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr));
    gap: 40px;
}
.footer__brand p { margin-top: 16px; max-width: 300px; color: var(--muted); font-size: .94rem; }
.footer__col h4 {
    margin-bottom: 16px;
    font-size: .82rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--text);
}
[dir="rtl"] .footer__col h4 { letter-spacing: 0; font-size: .92rem; }
.footer__col ul { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.footer__col a {
    font-size: .93rem;
    color: var(--muted);
    text-decoration: none;
    transition: color .2s;
}
.footer__col a:hover,
.footer__col a[aria-current] { color: var(--text); }
.footer__langs { grid-template-columns: repeat(2, max-content); column-gap: 24px !important; }

.footer__bottom {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-top: 56px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    font-size: .86rem;
    color: var(--muted);
}
.to-top {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--text-2);
    text-decoration: none;
    font-weight: 500;
}
.to-top__icon {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid var(--border-strong);
    transition: transform .4s var(--ease), border-color .3s;
}
.to-top__icon .icon { transform: rotate(-90deg); }
.to-top:hover .to-top__icon { transform: translateY(-3px); border-color: var(--brand); }

@media (max-width: 900px) {
    .footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .footer__brand { grid-column: 1 / -1; }
}
@media (max-width: 480px) {
    .footer__grid { grid-template-columns: 1fr; }
}

/* ---------- Scroll reveal ---------- */
html.js [data-reveal] {
    opacity: 0;
    transform: translateY(28px);
    transition:
        opacity .9s var(--ease) var(--d, 0s),
        transform .9s var(--ease) var(--d, 0s),
        box-shadow .55s var(--ease), border-color .35s;
}
html.js [data-reveal].is-visible { opacity: 1; transform: none; }
html.js [data-reveal].is-done { --d: 0s; } /* drop the stagger delay once revealed so hovers feel instant */
/* keep the staggered security layout once revealed */
html.js .security__grid .pillar:nth-child(even).is-visible { transform: translateY(28px); }
html.js .security__grid .pillar:nth-child(even).is-visible:hover { transform: translateY(23px); }
html.js .card[data-spotlight].is-visible:hover { transform: translateY(-5px); }
@media (max-width: 620px) {
    html.js .security__grid .pillar:nth-child(even).is-visible,
    html.js .security__grid .pillar:nth-child(even).is-visible:hover { transform: none; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: .001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .001ms !important;
        transition-delay: 0s !important;
    }
    html.js [data-reveal] { opacity: 1; transform: none; }
    .terminal, [dir="rtl"] .terminal { transform: none; }
}

/* =========================================================
   v2 additions: server contact form, CMS pages, 404, maintenance
   ========================================================= */
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form__row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 560px) { .form__row { grid-template-columns: 1fr; } }
.req { color: #ef4444; font-weight: 700; }
.form.is-sending .btn[type="submit"] { opacity: .7; cursor: progress; }
.form__status.is-error { color: #ef4444; }
.form__status.is-pop { animation: lineIn .5s var(--ease); }
.btn[disabled] { pointer-events: none; }

.status--soon { color: #d97706; background: color-mix(in srgb, #f59e0b 14%, transparent); }
.status--soon .status__dot { box-shadow: 0 0 0 3px color-mix(in srgb, #f59e0b 22%, transparent); }

.contact--solo { grid-template-columns: 1fr; }


.admin-pill {
    position: fixed;
    bottom: 18px;
    left: 18px;
    z-index: 70;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border-radius: 999px;
    background: var(--text);
    color: var(--bg);
    font-size: .8rem;
    font-weight: 700;
    text-decoration: none;
    box-shadow: var(--shadow-lg);
    transition: transform .3s var(--ease);
}
.admin-pill:hover { transform: translateY(-2px); }

/* CMS page */
.page {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding-top: calc(var(--header-h) + clamp(48px, 7vw, 88px));
    padding-bottom: clamp(72px, 9vw, 120px);
}
.page__bg { position: absolute; inset: 0 0 auto; height: 420px; z-index: -1; pointer-events: none; }
.page__inner { max-width: 780px; }
.page__inner--center { display: grid; justify-items: center; text-align: center; gap: 18px; }
.page--center { min-height: 72vh; display: grid; align-items: center; }
.page__back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 28px;
    color: var(--muted);
    font-size: .9rem;
    font-weight: 600;
    text-decoration: none;
    transition: color .25s;
}
.page__back:hover { color: var(--text); }
.icon-back { transform: scaleX(-1); }
[dir="rtl"] .icon-back { transform: none; }
.page__draft { display: inline-block; margin-bottom: 16px; padding: 4px 12px; border-radius: 999px; font-size: .78rem; font-weight: 700; color: #b45309; background: #fef3c7; }
.page__title {
    font-size: clamp(2.1rem, 5vw, 3.2rem);
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: var(--tracking-tight);
}
[dir="rtl"] .page__title { line-height: 1.4; }
.page__meta { margin: 14px 0 40px; color: var(--muted); font-size: .9rem; }

.prose { font-size: 1.05rem; color: var(--text-2); }
.prose > * + * { margin-top: 1.1em; }
.prose h2, .prose h3, .prose h4 { color: var(--text); font-weight: 750; letter-spacing: var(--tracking); line-height: 1.3; margin-top: 2em; }
.prose h2 { font-size: 1.5rem; }
.prose h3 { font-size: 1.22rem; }
.prose h4 { font-size: 1.05rem; }
.prose ul, .prose ol { padding-inline-start: 1.4em; }
.prose li + li { margin-top: .4em; }
.prose li::marker { color: var(--brand); }
.prose a { color: var(--brand); text-underline-offset: 3px; }
.prose strong { color: var(--text); }
.prose code { padding: .15em .45em; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--border); font-family: var(--font-mono); font-size: .88em; }
.prose blockquote { margin-inline: 0; padding: 14px 20px; border-inline-start: 3px solid var(--brand); background: var(--surface); border-radius: 12px; color: var(--muted); }
.prose hr { border: 0; height: 1px; background: var(--border-strong); margin-block: 2.2em; }

.code-404 {
    font-family: var(--font-mono);
    font-size: clamp(5rem, 16vw, 9rem);
    font-weight: 700;
    line-height: 1;
    background: linear-gradient(135deg, var(--brand), var(--brand-2), var(--brand-3));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* Maintenance */
.maintenance { min-height: calc(100vh - 0px); display: grid; align-items: center; }
.maintenance .page__inner { max-width: 620px; }
.orb--static { margin: 0 0 12px; width: 180px; }
.orb--static .orb__ring--2 { inset: 22px; }

/* Uploaded site logo (header, footer, partner cards).
   Fixed pixel sizes on purpose: percentage heights are ignored inside grid boxes,
   which made large images render at full size. Square icons → 34×34, wide logos → up to 140px wide. */
.logo__mark.has-img {
    display: inline-flex;
    align-items: center;
    width: auto;
    min-width: 0;
    height: 34px;
    padding: 0;
    overflow: hidden;
    background: none;
    box-shadow: none;
    border-radius: 0;
}
.logo__mark.has-img img {
    display: block;
    width: auto;
    height: 34px;
    max-width: 140px;
    max-height: 34px;
    object-fit: contain;
    border-radius: 8px;
}
.logo:hover .logo__mark.has-img { transform: scale(1.05); }
.partner__logo--us.has-img { background: #fff; padding: 10px; }
.partner__logo.has-img img,
.partner__logo .logo-img {
    display: block;
    width: 38px;
    height: 38px;
    max-width: 38px;
    max-height: 38px;
    object-fit: contain;
}
