/* IT Brain Solutions — one-page site. Poster grid, flat colour, live build stage. */
:root {
    --blue: #4040f4;
    --blue-deep: #2a2ac2;
    --blue-ink: #1d1d8f;
    --ink: #12173a;
    --ink-soft: #3b4163;
    --amber: #ffb822;
    --amber-deep: #e89c00;
    --paper: #f2f3fa;
    --white: #ffffff;
    --line: rgba(18, 23, 58, 0.14);
    --on-blue: #e4e6ff;
    --ease: cubic-bezier(0.16, 1, 0.3, 1);
    --font-display: "Numans", "Segoe UI", system-ui, sans-serif;
    --font-body: "Numans", "Segoe UI", system-ui, sans-serif;
    --font-mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
    --wrap: 1240px;
    --radius: 16px;
    --radius-sm: 10px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.6;
    color: var(--ink);
    background: var(--paper);
    overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
button { font: inherit; color: inherit; cursor: pointer; }
::selection { background: var(--amber); color: var(--ink); }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 3px; border-radius: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* themed scrollbar */
html { scrollbar-color: var(--blue) var(--paper); scrollbar-width: thin; }

.wrap { width: min(var(--wrap), 100% - 3rem); margin-inline: auto; }

h1, h2, h3 { font-family: var(--font-display); letter-spacing: -0.03em; text-wrap: balance; }
h2 { font-size: clamp(2.1rem, 4.6vw, 2.9rem); font-weight: 700; line-height: 1.02; }
h3 { font-weight: 600; letter-spacing: -0.02em; }

/* ---------- progress ---------- */
.progress {
    position: fixed; inset: 0 0 auto 0; height: 4px; z-index: 60;
    background: var(--amber); transform-origin: 0 50%; transform: scaleX(var(--scroll, 0));
}

/* ---------- buttons ---------- */
.btn {
    --tx: 0px; --ty: 0px;
    position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 0.7rem;
    padding: 0.95rem 1.6rem; border-radius: 999px; border: 2px solid transparent;
    font-weight: 700; font-size: 1rem; text-decoration: none; line-height: 1.1; white-space: nowrap;
    transform: translate(var(--tx), var(--ty));
    transition: transform 0.35s var(--ease), background-color 0.25s, color 0.25s, border-color 0.25s, box-shadow 0.35s var(--ease);
    overflow: hidden; isolation: isolate;
}
.btn .arr { display: inline-block; transition: transform 0.4s var(--ease); }
.btn:hover .arr { transform: translateX(6px); }
.btn-amber { background: var(--amber); color: var(--ink); box-shadow: 0 10px 24px -10px rgba(255, 184, 34, 0.9); }
.btn-amber::before {
    content: ""; position: absolute; inset: 0; z-index: -1; background: var(--white);
    transform: translateY(101%); transition: transform 0.45s var(--ease); border-radius: inherit;
}
.btn-amber:hover::before { transform: translateY(0); }
.btn-amber:hover { box-shadow: 0 16px 30px -12px rgba(18, 23, 58, 0.5); }
.btn-ghost { color: var(--white); border-color: rgba(255, 255, 255, 0.45); }
.btn-ghost:hover { background: var(--white); color: var(--blue); border-color: var(--white); }
.btn-ink { background: var(--ink); color: var(--white); }
.btn-ink:hover { background: var(--blue); }
.btn-sm { padding: 0.65rem 1.15rem; font-size: 0.95rem; }
.btn[disabled] { opacity: 0.6; cursor: progress; }

/* ---------- nav ---------- */
.nav { position: fixed; inset: 14px 0 auto 0; z-index: 50; transition: transform 0.5s var(--ease); }
.nav.is-hidden { transform: translateY(-140%); }
.nav-inner {
    width: min(var(--wrap), 100% - 2rem); margin-inline: auto; display: flex; align-items: center; gap: 1.5rem;
    background: var(--white); border-radius: 18px; padding: 0.55rem 0.7rem 0.55rem 0.8rem;
    box-shadow: 0 12px 34px -14px rgba(18, 23, 58, 0.45);
    transition: padding 0.4s var(--ease), box-shadow 0.4s;
}
.nav.is-scrolled .nav-inner { padding-block: 0.35rem; box-shadow: 0 16px 40px -16px rgba(18, 23, 58, 0.55); }
.brand { display: inline-flex; align-items: center; gap: 0.75rem; text-decoration: none; margin-right: auto; }
.brand-mark {
    width: 78px; height: 52px; flex: none; background: url("../assets/logo-brain.png") no-repeat;
    background-size: 86px auto; background-position: -3.5px -5px;
    transition: transform 0.6s var(--ease);
}
.brand:hover .brand-mark { transform: rotate(-8deg) scale(1.12); }
.brand-name { font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; letter-spacing: -0.01em; color: var(--ink); line-height: 1; }
.brand-name small { font-weight: 600; font-size: 0.78em; margin-left: 0.3rem; color: var(--blue); }
.nav-links { display: flex; gap: 0.25rem; }
.nav-links a {
    position: relative; padding: 0.55rem 0.9rem; font-weight: 600; font-size: 0.97rem; text-decoration: none; color: var(--ink-soft);
    transition: color 0.2s;
}
.nav-links a::after {
    content: ""; position: absolute; left: 0.9rem; right: 0.9rem; bottom: 0.3rem; height: 2px; background: var(--blue);
    transform: scaleX(0); transform-origin: 0 50%; transition: transform 0.4s var(--ease);
}
.nav-links a:hover, .nav-links a.is-current { color: var(--blue); }
.nav-links a:hover::after, .nav-links a.is-current::after { transform: scaleX(1); }
.nav-toggle {
    display: none; width: 44px; height: 44px; border: 0; background: var(--paper); border-radius: 12px; position: relative;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
    content: ""; position: absolute; left: 12px; right: 12px; height: 2px; background: var(--ink); border-radius: 2px;
    transition: transform 0.35s var(--ease), opacity 0.2s;
}
.nav-toggle span { top: 21px; }
.nav-toggle span::before { top: -7px; left: 0; right: 0; }
.nav-toggle span::after { top: 7px; left: 0; right: 0; }
.nav.is-open .nav-toggle span { background: transparent; }
.nav.is-open .nav-toggle span::before { transform: translateY(7px) rotate(45deg); }
.nav.is-open .nav-toggle span::after { transform: translateY(-7px) rotate(-45deg); }

/* ---------- hero ---------- */
.hero {
    position: relative; background: var(--blue); color: var(--white); overflow: hidden;
    padding: 9.5rem 0 0; isolation: isolate;
    --mx: 70%; --my: 30%;
}
.hero::before { /* cursor-following light */
    content: ""; position: absolute; inset: 0; z-index: -1;
    background: radial-gradient(600px circle at var(--mx) var(--my), rgba(255, 255, 255, 0.14), transparent 60%);
}
.hero-net { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; opacity: 0.9; transition: transform 0.6s var(--ease); }
.hero-net line { stroke: rgba(255, 255, 255, 0.16); stroke-width: 1.5; }
.hero-net circle.n { fill: var(--blue); stroke: rgba(255, 255, 255, 0.4); stroke-width: 1.5; }
.hero-net circle.p { fill: var(--amber); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 4.7fr) minmax(0, 7.3fr); gap: clamp(1.5rem, 3.5vw, 3.5rem); align-items: center; padding-bottom: 5rem; }
.hero h1 { font-size: clamp(2.6rem, 4.9vw, 4.7rem); font-weight: 800; line-height: 0.98; letter-spacing: -0.035em; }
.hero h1 .mark { position: relative; display: inline-block; color: var(--amber); }
.hero h1 .mark::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: -0.06em; height: 0.08em; background: var(--amber);
    transform-origin: 0 50%; transform: scaleX(0); animation: draw 0.9s 1.1s var(--ease) forwards;
}
.hero .lead { margin-top: 1.6rem; font-size: 1.2rem; color: var(--on-blue); max-width: 34rem; text-wrap: pretty; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 2.2rem; }
.hero-reg { margin-top: 2.4rem; font-size: 0.9rem; color: var(--on-blue); }

/* build stage */
.stage-wrap { perspective: 1400px; }
.stage {
    background: var(--white); color: var(--ink); border-radius: 18px; overflow: hidden;
    box-shadow: 0 50px 80px -30px rgba(7, 7, 80, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.2);
    transform: rotateY(var(--ry, 0deg)) rotateX(var(--rx, 0deg)); transform-style: preserve-3d;
    transition: transform 0.5s var(--ease);
}
.stage-bar { display: flex; align-items: center; gap: 1rem; padding: 0.6rem 0.8rem; background: #e9ebf7; border-bottom: 1px solid var(--line); }
.dots { display: flex; gap: 6px; }
.dots i { width: 11px; height: 11px; border-radius: 50%; background: #c9cde6; }
.dots i:first-child { background: #ff7a6b; } .dots i:nth-child(2) { background: var(--amber); } .dots i:nth-child(3) { background: #46c985; }
.tabs { display: flex; gap: 0.3rem; margin-left: auto; }
.tab {
    position: relative; border: 0; background: transparent; padding: 0.45rem 0.8rem; border-radius: 8px; font-weight: 700; font-size: 0.85rem;
    color: var(--ink-soft); overflow: hidden; transition: background-color 0.2s, color 0.2s;
}
.tab:hover { background: rgba(64, 64, 244, 0.1); color: var(--blue); }
.tab[aria-selected="true"] { background: var(--ink); color: var(--white); }
.tab i { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: var(--amber); transform: scaleX(0); transform-origin: 0 50%; }
.tab[aria-selected="true"] i { animation: fill var(--dur, 7s) linear forwards; }
.stage-body { display: grid; grid-template-columns: 0.9fr 1.1fr; min-height: 372px; }
.code-pane { background: var(--ink); color: #d8dbff; padding: 1.2rem 1.1rem; font-family: var(--font-mono); font-size: 0.78rem; line-height: 1.75; overflow: hidden; }
.code-pane .file { color: #8e94d8; margin-bottom: 0.8rem; font-size: 0.72rem; }
.code-pane pre { margin: 0; white-space: pre-wrap; word-break: break-word; font: inherit; min-height: 12em; }
.code-pane .kw { color: #ffb822; } .code-pane .st { color: #7ee2b0; } .code-pane .cm { color: #7c82c4; } .code-pane .ty { color: #9db0ff; }
.code-pane .caret { display: inline-block; width: 0.5em; height: 1.05em; background: var(--amber); vertical-align: -0.18em; animation: blink 1s steps(1) infinite; }
.preview { position: relative; background: var(--paper); overflow: hidden; }
.scene { position: absolute; inset: 0; padding: 1.1rem; opacity: 0; visibility: hidden; transition: opacity 0.4s, visibility 0.4s; }
.scene.is-active { opacity: 1; visibility: visible; }
.scene .a { opacity: 0; }
.scene.is-active .a { animation: rise 0.65s var(--ease) both; animation-delay: calc(var(--i, 0) * 110ms + 250ms); }
.stage-note { padding: 0.5rem 1rem; font-size: 0.78rem; color: var(--ink-soft); background: #e9ebf7; border-top: 1px solid var(--line); }

.ui-head { display: flex; align-items: center; justify-content: space-between; font-weight: 700; font-family: var(--font-display); font-size: 1.05rem; }
.pill { display: inline-flex; align-items: center; gap: 0.4rem; font-family: var(--font-body); font-size: 0.72rem; font-weight: 700; padding: 0.2rem 0.6rem; border-radius: 99px; background: #dff6ea; color: #137a46; }
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #1ec26b; box-shadow: 0 0 0 3px rgba(30, 194, 107, 0.25); }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.6rem; margin-top: 0.9rem; }
.tile { background: var(--white); border-radius: 10px; padding: 0.6rem 0.7rem; border: 1px solid var(--line); }
.tile span { display: block; font-size: 0.72rem; color: var(--ink-soft); font-weight: 600; }
.tile b { font-family: var(--font-display); font-size: 1.25rem; letter-spacing: -0.02em; }
.bars { display: flex; align-items: flex-end; gap: 0.45rem; height: 96px; margin-top: 0.9rem; padding: 0.7rem; background: var(--white); border-radius: 10px; border: 1px solid var(--line); }
.bars i { flex: 1; height: var(--h); background: var(--blue); border-radius: 4px 4px 0 0; transform-origin: 50% 100%; }
.bars i:nth-child(3) { background: var(--amber); }
.scene.is-active .bars i { animation: grow 0.8s var(--ease) both; animation-delay: calc(var(--i, 0) * 70ms + 700ms); }
.rows { margin-top: 0.7rem; display: grid; gap: 0.4rem; }
.row { display: flex; justify-content: space-between; align-items: center; background: var(--white); border: 1px solid var(--line); border-radius: 8px; padding: 0.45rem 0.7rem; font-size: 0.78rem; font-weight: 600; }
.chip { font-size: 0.72rem; padding: 0.15rem 0.5rem; border-radius: 99px; font-weight: 700; background: #e3e4fd; color: var(--blue-ink); }
.chip.ok { background: #dff6ea; color: #137a46; } .chip.warn { background: #fff0cc; color: #8a5a00; }

.scene[data-scene="mobile"] { display: flex; align-items: flex-start; justify-content: center; gap: 1.4rem; }
.phone { width: 176px; flex: none; margin: 0.1rem 0 0; background: var(--ink); border-radius: 28px; padding: 9px; box-shadow: 0 24px 40px -18px rgba(18, 23, 58, 0.55); }
.phone-screen { background: var(--white); border-radius: 20px; padding: 0.85rem 0.7rem 0.7rem; height: 312px; position: relative; }
.phone-screen .ph-title { font-weight: 700; margin: 0 0 0.6rem; font-family: var(--font-display); font-size: 0.95rem; }
.job { display: flex; align-items: center; gap: 0.5rem; padding: 0.5rem; border-radius: 9px; background: var(--paper); margin-bottom: 0.4rem; font-size: 0.7rem; font-weight: 600; }
.job .box { width: 16px; height: 16px; border-radius: 5px; border: 2px solid var(--blue); flex: none; position: relative; }
.job .box::after { content: ""; position: absolute; left: 3px; top: 0px; width: 4px; height: 8px; border: solid var(--white); border-width: 0 2px 2px 0; transform: rotate(45deg) scale(0); }
.scene.is-active .job.done .box { animation: tick 0.4s calc(var(--i) * 110ms + 1100ms) forwards; }
.scene.is-active .job.done .box::after { animation: check 0.3s calc(var(--i) * 110ms + 1300ms) forwards; }
.sync { position: absolute; left: 0.7rem; right: 0.7rem; bottom: 0.7rem; text-align: center; padding: 0.45rem; border-radius: 10px; background: var(--ink); color: var(--white); font-size: 0.7rem; font-weight: 700; }
.phone-side { display: grid; gap: 0.6rem; width: 120px; padding-top: 1.4rem; }
.phone-side .tile b { font-size: 1rem; }
.chat { display: grid; gap: 0.6rem; margin-top: 0.8rem; }
.bubble { max-width: 86%; padding: 0.6rem 0.8rem; border-radius: 14px; font-size: 0.8rem; line-height: 1.45; font-weight: 500; }
.bubble.me { justify-self: end; background: var(--blue); color: var(--white); border-bottom-right-radius: 4px; }
.bubble.ai { background: var(--white); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.typing { display: inline-flex; gap: 4px; padding: 0.7rem 0.9rem; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--ink-soft); animation: dots 1s infinite; }
.typing i:nth-child(2) { animation-delay: 0.15s; } .typing i:nth-child(3) { animation-delay: 0.3s; }
.sources { display: flex; gap: 0.35rem; margin-top: 0.45rem; flex-wrap: wrap; }

/* marquee */
.marquee { border-top: 1px solid rgba(255, 255, 255, 0.22); background: var(--blue-deep); overflow: hidden; }
.marquee-track { display: flex; width: max-content; animation: marquee 38s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span { padding: 1.05rem 1.6rem; font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; white-space: nowrap; display: inline-flex; align-items: center; gap: 3.2rem; color: var(--on-blue); transition: color 0.2s; }
.marquee-track span::after { content: ""; width: 9px; height: 9px; background: var(--amber); transform: rotate(45deg); }
.marquee-track span:hover { color: var(--white); }

/* ---------- sections ---------- */
section { position: relative; }
.pad { padding: clamp(5rem, 10vw, 9rem) 0; }

/* about */
.about { background: var(--paper); }
.statement { font-size: clamp(1.9rem, 4.4vw, 3.6rem); font-weight: 600; line-height: 1.12; letter-spacing: -0.03em; max-width: 24ch; max-width: 22em; text-wrap: pretty; }
.statement .w { color: rgba(18, 23, 58, 0.18); transition: color 0.35s; }
.statement .w.on { color: var(--ink); }
.about-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(2rem, 6vw, 6rem); margin-top: 3.5rem; align-items: start; }
.about-copy { color: var(--ink-soft); display: grid; gap: 1.1rem; max-width: 38rem; text-wrap: pretty; }
.facts { border-top: 2px solid var(--ink); }
.facts div { display: flex; justify-content: space-between; gap: 1rem; padding: 0.95rem 0; border-bottom: 1px solid var(--line); transition: padding 0.35s var(--ease), background-color 0.3s; }
.facts div:hover { padding-left: 0.8rem; background: rgba(64, 64, 244, 0.06); }
.facts dt { font-size: 0.9rem; font-weight: 600; color: var(--ink-soft); }
.facts dd { font-weight: 700; text-align: right; }
.years { display: inline-flex; align-items: baseline; gap: 0.8rem; margin-top: 0.5rem; font-family: var(--font-display); }
.years b { font-size: clamp(4rem, 9vw, 7rem); line-height: 0.9; font-weight: 800; color: var(--blue); letter-spacing: -0.05em; }
.years span { font-weight: 600; max-width: 9rem; line-height: 1.2; color: var(--ink-soft); }

/* services */
.services { background: var(--white); }
.sec-head { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 2rem 4rem; align-items: end; margin-bottom: 3.5rem; }
.sec-head p { color: var(--ink-soft); text-wrap: pretty; }
.svc-list { border-top: 2px solid var(--ink); }
.svc {
    position: relative; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 5fr) minmax(0, 2fr); gap: 1.5rem 2.5rem; align-items: center;
    padding: 2rem 1.2rem; border-bottom: 1px solid var(--line); isolation: isolate; overflow: hidden;
    transition: color 0.3s, padding 0.5s var(--ease);
}
.svc::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--blue); transform: scaleY(0); transform-origin: 50% 100%; transition: transform 0.55s var(--ease); }
.svc:hover::before, .svc:focus-within::before { transform: scaleY(1); }
.svc:hover, .svc:focus-within { color: var(--white); padding-left: 2rem; }
.svc-title { display: flex; align-items: center; gap: 1.2rem; }
.svc-title h3 { font-size: clamp(1.35rem, 2.3vw, 1.9rem); line-height: 1.1; }
.svc-ico { width: 40px; height: 40px; flex: none; color: var(--blue); display: grid; place-items: center; transition: color 0.3s, transform 0.6s var(--ease); }
.svc-ico svg { width: 36px; height: 36px; stroke-width: 1.5; }
.svc:hover .svc-ico { color: var(--amber); transform: rotate(-10deg) scale(1.12); }
.svc p { color: var(--ink-soft); transition: color 0.3s; text-wrap: pretty; }
.svc:hover p { color: var(--on-blue); }
.svc-go { justify-self: end; width: 48px; height: 48px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; font-size: 1.2rem; transition: transform 0.5s var(--ease), background-color 0.3s, border-color 0.3s, color 0.3s; }
.svc:hover .svc-go { transform: rotate(-45deg); background: var(--amber); border-color: var(--amber); color: var(--ink); }
.more-link { display: inline-flex; gap: 0.6rem; margin-top: 2.2rem; font-weight: 700; color: var(--blue); text-decoration: none; border-bottom: 2px solid currentColor; padding-bottom: 2px; }
.more-link span { transition: transform 0.4s var(--ease); }
.more-link:hover span { transform: translateX(6px); }

/* process */
.process { background: var(--amber); color: var(--ink); overflow: hidden; }
.process h2 { max-width: 14ch; }
.route { position: relative; margin-top: 4.5rem; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; --p: 0; }
.route-line, .route-fill { position: absolute; top: 15px; left: 15px; right: 15px; height: 8px; border-radius: 4px; }
.route-line { background: rgba(18, 23, 58, 0.18); }
.route-fill { background: var(--ink); transform-origin: 0 50%; transform: scaleX(var(--p)); transition: transform 0.15s linear; }
.stop { position: relative; padding-top: 3.4rem; }
.stop::before {
    content: ""; position: absolute; top: 0; left: 0; width: 38px; height: 38px; border-radius: 50%; background: var(--amber); border: 7px solid rgba(18, 23, 58, 0.3);
    transition: background-color 0.4s, border-color 0.4s, transform 0.6s var(--ease);
}
.stop.on::before { background: var(--white); border-color: var(--ink); transform: scale(1.12); }
.stop h3 { font-size: 1.65rem; }
.stop p { margin-top: 0.6rem; max-width: 18rem; color: var(--ink); text-wrap: pretty; }
.stop { opacity: 0.72; transform: translateY(8px); transition: opacity 0.5s, transform 0.6s var(--ease); }
.stop.on { opacity: 1; transform: none; }

/* stack */
.stack { background: var(--ink); color: var(--white); }
.stack-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; }
.stack p.sub { margin-top: 1.4rem; color: #b7bbe3; max-width: 30rem; text-wrap: pretty; }
.stack-groups { display: grid; gap: 2.4rem; }
.stack-groups h3 { font-size: 1.15rem; color: var(--amber); font-weight: 700; margin-bottom: 1rem; }
.chips { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.chips li {
    padding: 0.7rem 1.15rem; border-radius: 999px; border: 1.5px solid rgba(255, 255, 255, 0.25); font-weight: 600; font-size: 1rem;
    transition: transform 0.4s var(--ease), background-color 0.25s, color 0.25s, border-color 0.25s; cursor: default;
}
.chips li:hover { transform: translateY(-6px) rotate(-2deg); background: var(--amber); color: var(--ink); border-color: var(--amber); }

/* work */
.work { background: var(--paper); }
.work-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1.4rem; }
.case {
    position: relative; grid-column: span 2; background: var(--white); border-radius: 22px; padding: 1.2rem 1.2rem 1.7rem; display: flex; flex-direction: column;
    border: 1px solid var(--line); transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(var(--lift, 0px));
    transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease), border-color 0.3s; will-change: transform;
}
.case:hover { --lift: -8px; box-shadow: 0 40px 50px -30px rgba(42, 42, 194, 0.55); border-color: rgba(64, 64, 244, 0.45); }
.case.big { grid-column: span 3; }
.case .glare { position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity 0.3s; background: radial-gradient(260px circle at var(--gx, 50%) var(--gy, 0%), rgba(255, 255, 255, 0.55), transparent 65%); mix-blend-mode: soft-light; }
.case:hover .glare { opacity: 1; }
.shot { position: relative; height: 210px; border-radius: 14px; margin-bottom: 1.4rem; overflow: hidden; display: grid; place-items: center; background: var(--blue); color: var(--white); }
.case.big .shot { height: 250px; }
.shot.amber { background: var(--amber); color: var(--ink); }
.shot.ink { background: var(--ink); }
.shot.deep { background: var(--blue-deep); }
.shot .mini { transition: transform 0.7s var(--ease); }
.case:hover .shot .mini { transform: scale(1.06) translateY(-4px); }
.sample { position: absolute; top: 0.7rem; right: 0.7rem; font-size: 0.75rem; font-weight: 700; padding: 0.2rem 0.55rem; border-radius: 99px; background: rgba(255, 255, 255, 0.92); color: var(--ink); z-index: 2; }
.case-tag { font-size: 0.82rem; font-weight: 700; color: var(--blue); }
.case h3 { font-size: 1.5rem; margin: 0.25rem 0 0.6rem; }
.case p { color: var(--ink-soft); font-size: 1rem; text-wrap: pretty; }
.case ul { margin-top: 1rem; display: flex; flex-wrap: wrap; gap: 0.4rem; }
.case li { font-size: 0.78rem; font-weight: 600; padding: 0.25rem 0.65rem; border-radius: 99px; background: var(--paper); }
.work-note { margin-top: 2rem; color: var(--ink-soft); font-size: 0.95rem; }

/* mini mockups in cases */
.mini-phone { width: 118px; background: var(--ink); border-radius: 22px; padding: 6px; }
.mini-phone div { background: var(--white); border-radius: 17px; height: 190px; padding: 0.6rem 0.5rem; display: grid; align-content: start; gap: 0.35rem; }
.mini-phone i { display: block; height: 22px; border-radius: 6px; background: var(--paper); position: relative; }
.mini-phone i:nth-child(1) { height: 12px; width: 60%; background: var(--ink); }
.mini-phone i::after { content: ""; position: absolute; right: 5px; top: 7px; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); }
.mini-phone i:nth-child(1)::after { display: none; }
.mini-phone b { display: block; text-align: center; font-size: 0.55rem; font-family: var(--font-body); background: var(--amber); color: var(--ink); border-radius: 6px; padding: 0.25rem; margin-top: auto; }
.flow { width: 82%; }
.flow path { fill: none; stroke: rgba(255, 255, 255, 0.35); stroke-width: 2; }
.flow rect { fill: var(--white); }
.flow text { font: 700 10px var(--font-body); fill: var(--ink); }
.flow circle { fill: var(--amber); }
.mini-browser { width: 84%; background: var(--white); color: var(--ink); border-radius: 10px; overflow: hidden; }
.mini-browser .bar { height: 18px; background: #e9ebf7; display: flex; gap: 4px; align-items: center; padding-left: 8px; }
.mini-browser .bar i { width: 6px; height: 6px; border-radius: 50%; background: #b9bddb; }
.mini-browser .body { padding: 0.6rem; display: grid; gap: 0.35rem; }
.mini-browser .ln { display: flex; justify-content: space-between; align-items: center; font-size: 0.62rem; font-weight: 700; padding: 0.3rem 0.45rem; border-radius: 5px; background: var(--paper); }
.mini-browser .ln em { font-style: normal; font-size: 0.55rem; padding: 0.1rem 0.4rem; border-radius: 9px; background: #dff6ea; color: #137a46; }
.mini-bars { display: flex; align-items: flex-end; gap: 7px; height: 120px; }
.mini-bars i { width: 20px; height: var(--h); background: var(--white); border-radius: 4px 4px 0 0; transform-origin: 50% 100%; }
.mini-bars i:nth-child(even) { background: var(--amber); }
.case:hover .mini-bars i { animation: bump 0.7s var(--ease) both; animation-delay: calc(var(--i) * 60ms); }
.mini-chat { width: 82%; display: grid; gap: 0.5rem; }
.mini-chat div { padding: 0.5rem 0.7rem; border-radius: 12px; font-size: 0.68rem; font-weight: 600; max-width: 85%; background: rgba(255, 255, 255, 0.14); }
.mini-chat div:nth-child(2) { justify-self: end; background: var(--amber); color: var(--ink); }

/* contact */
.contact { background: var(--blue); color: var(--white); overflow: hidden; }
.contact-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; }
.contact h2 { font-size: clamp(2.4rem, 5.4vw, 3.6rem); font-weight: 800; }
.contact .sub { margin-top: 1.4rem; color: var(--on-blue); max-width: 30rem; text-wrap: pretty; }
.reach { margin-top: 2.5rem; display: grid; gap: 1.3rem; }
.reach span { display: block; font-size: 0.85rem; font-weight: 600; color: var(--on-blue); }
.reach a { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.15rem, 2.2vw, 1.6rem); text-decoration: none; background: linear-gradient(var(--amber), var(--amber)) 0 100% / 0 3px no-repeat; transition: background-size 0.5s var(--ease), color 0.2s; padding-bottom: 3px; overflow-wrap: anywhere; }
.reach a:hover { background-size: 100% 3px; }
.form-card { background: var(--white); color: var(--ink); border-radius: 22px; padding: clamp(1.4rem, 3vw, 2.4rem); box-shadow: 0 40px 70px -30px rgba(7, 7, 80, 0.7); }
.form-card form { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; }
.field { display: grid; gap: 0.4rem; }
.field.full { grid-column: 1 / -1; }
.field label { font-weight: 700; font-size: 0.92rem; }
.field input, .field textarea {
    font: inherit; width: 100%; padding: 0.95rem 1rem; border-radius: 12px; border: 2px solid var(--line); background: var(--paper); color: var(--ink);
    transition: border-color 0.25s, background-color 0.25s, box-shadow 0.35s var(--ease);
}
.field textarea { resize: vertical; min-height: 140px; }
.field input::placeholder, .field textarea::placeholder { color: #596080; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--blue); background: var(--white); box-shadow: 0 0 0 5px rgba(64, 64, 244, 0.16); }
.field .err { display: none; font-size: 0.85rem; font-weight: 600; color: #b3261e; }
.field.invalid input, .field.invalid textarea { border-color: #b3261e; }
.field.invalid .err { display: block; animation: rise 0.4s var(--ease); }
.form-foot { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.form-status { font-weight: 600; font-size: 0.95rem; color: var(--ink-soft); min-height: 1.4em; }
.form-status.ok { color: #137a46; } .form-status.bad { color: #b3261e; }

/* footer */
.footer { background: var(--ink); color: #c4c8ee; padding: 4rem 0 2.2rem; }
.footer-grid { display: grid; grid-template-columns: 5fr 3fr 4fr; gap: 3rem; }
.footer .brand-name { color: var(--white); } .footer .brand-name small { color: var(--amber); }
.footer .brand-mark { background-color: var(--white); border-radius: 10px; }
.footer p { margin-top: 1rem; max-width: 30rem; font-size: 0.97rem; text-wrap: pretty; }
.footer h3 { font-size: 1rem; color: var(--white); margin-bottom: 1rem; }
.footer li + li { margin-top: 0.5rem; }
.footer a { text-decoration: none; transition: color 0.2s; }
.footer a:hover { color: var(--amber); }
.legal { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid rgba(255, 255, 255, 0.14); font-size: 0.88rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }

/* ---------- reveal system ---------- */
.js [data-r] { opacity: 0; transform: translateY(34px); transition: opacity 0.8s var(--ease), transform 0.9s var(--ease); transition-delay: calc(var(--d, 0) * 90ms); }
.js [data-r="left"] { transform: translateX(-40px); }
.js [data-r="scale"] { transform: scale(0.92) translateY(24px); }
.js [data-r].is-in { opacity: 1; transform: none; }
.js .split .wd { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: 0.12em; margin-bottom: -0.12em; }
.js .split .wd > i { display: inline-block; font-style: normal; transform: translateY(105%) rotate(4deg); transition: transform 0.9s var(--ease); transition-delay: calc(var(--k) * 45ms); }
.js .split.is-in .wd > i { transform: none; }

/* ---------- keyframes ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes grow { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes bump { 0% { transform: scaleY(0.4); } 100% { transform: scaleY(1); } }
@keyframes fill { to { transform: scaleX(1); } }
@keyframes draw { to { transform: scaleX(1); } }
@keyframes blink { 50% { opacity: 0; } }
@keyframes dots { 0%, 60%, 100% { transform: none; } 30% { transform: translateY(-5px); } }
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes tick { to { background: var(--blue); } }
@keyframes check { to { transform: rotate(45deg) scale(1); } }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
    .hero-grid { grid-template-columns: 1fr; padding-bottom: 4rem; }
    .stage-wrap { max-width: 720px; }
    .case, .case.big { grid-column: span 3; }
    .case:last-child { grid-column: span 6; }
}
@media (max-width: 900px) {
    .nav-toggle { display: block; }
    .nav-inner { flex-wrap: wrap; }
    .nav-links, .nav .btn-sm { display: none; }
    .nav.is-open .nav-links { display: grid; width: 100%; order: 3; padding: 0.5rem 0 0.8rem; }
    .nav.is-open .btn-sm { display: inline-flex; width: 100%; order: 4; }
    .about-grid, .sec-head, .stack-grid, .contact-grid { grid-template-columns: 1fr; }
    .sec-head { margin-bottom: 2.5rem; }
    .svc { grid-template-columns: 1fr auto; gap: 1rem; }
    .svc p { grid-column: 1 / -1; grid-row: 2; }
    .route { grid-template-columns: 1fr; gap: 2.2rem; padding-left: 0; }
    .route-line, .route-fill { top: 15px; bottom: 15px; left: 15px; right: auto; width: 8px; height: auto; }
    .route-fill { transform-origin: 50% 0; transform: scaleY(var(--p)); }
    .stop { padding: 0 0 0 4rem; }
    .footer-grid { grid-template-columns: 1fr; gap: 2rem; }
}
@media (max-width: 680px) {
    .brand { gap: 0.4rem; min-width: 0; }
    .brand-mark { width: 62px; height: 42px; background-size: 69px auto; background-position: -2.8px -4px; }
    .brand-name { font-size: 0.84rem; }
    .nav-inner { flex-wrap: nowrap; }
    .nav.is-open .nav-inner { flex-wrap: wrap; }
    .wrap { width: min(var(--wrap), 100% - 2rem); }
    .hero { padding-top: 7.5rem; }
    .stage-body { grid-template-columns: 1fr; }
    .code-pane { display: none; }
    .stage-body { min-height: 360px; }
    .stage-bar .dots { display: none; }
    .tabs { margin-left: 0; width: 100%; justify-content: space-between; }
    .tab { flex: 1; font-size: 0.78rem; padding-inline: 0.3rem; }
    .work-grid { grid-template-columns: 1fr; }
    .case, .case.big, .case:last-child { grid-column: auto; }
    .form-card form { grid-template-columns: 1fr; }
    .phone-side { display: none; }
    .btn { padding-inline: 1.3rem; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; transition-delay: 0ms !important; }
    .marquee-track { animation: none; }
    .js [data-r], .js .split .wd > i { opacity: 1; transform: none; }
    .statement .w { color: var(--ink); }
}

/* ---------- illustrated sections ---------- */
.fl { animation: floaty 6s ease-in-out infinite; animation-delay: var(--d, 0s); transform-box: fill-box; }
.pull { translate: var(--px, 0px) var(--py, 0px); transition: translate 0.5s var(--ease); }
[data-depth] { translate: 0 var(--par, 0px); }
@keyframes floaty { 50% { transform: translateY(-10px); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes ringout { 0% { transform: scale(0.7); opacity: 0.8; } 100% { transform: scale(1.7); opacity: 0; } }
@keyframes barloop { 0%, 100% { transform: scaleY(0.35); } 50% { transform: scaleY(1); } }
@keyframes tickdraw { 0%, 8% { stroke-dashoffset: 24; } 25%, 85% { stroke-dashoffset: 0; } 100% { stroke-dashoffset: 24; } }
@keyframes dashmove { to { stroke-dashoffset: -24; } }
@keyframes belt { 0% { transform: translateX(0); } 100% { transform: translateX(240px); } }
@keyframes bugwalk { 0% { transform: translate(262px, 150px) rotate(20deg); } 50% { transform: translate(280px, 110px) rotate(-10deg); } 100% { transform: translate(262px, 150px) rotate(20deg); } }
@keyframes cursormove { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(-60px, -34px); } }
@keyframes drawbar { 0%, 100% { transform: scaleX(0.2); } 50% { transform: scaleX(1); } }
@keyframes bracket { 50% { transform: translateX(var(--bx)); } }
@keyframes rocket { 0%, 100% { transform: translateY(2px); } 50% { transform: translateY(-6px); } }
@keyframes flame { 50% { transform: scaleY(1.5); } }
.ring { transform-box: fill-box; transform-origin: center; animation: ringout 2.6s ease-out infinite; }
.spin { transform-box: view-box; animation: spin 9s linear infinite; }
.spin.rev { animation-direction: reverse; animation-duration: 7s; }
.bar { transform-box: fill-box; transform-origin: 50% 100%; animation: barloop 3.4s ease-in-out infinite; animation-delay: var(--d); }
.tick { stroke-dasharray: 24; stroke-dashoffset: 24; animation: tickdraw 5s ease infinite; animation-delay: var(--d); stroke-linecap: round; fill: none; }
.dash { stroke-dasharray: 6 6; animation: dashmove 1.2s linear infinite; }
.pk { animation: belt 3.2s linear infinite; animation-delay: var(--d); }
.bug { animation: bugwalk 5s ease-in-out infinite; transform-box: view-box; }
.cursor { animation: cursormove 4s ease-in-out infinite; }
.dr { transform-box: fill-box; transform-origin: 0 50%; animation: drawbar 2.4s ease-in-out infinite; animation-delay: var(--d); }
.br.l { --bx: -5px; animation: bracket 1.6s ease-in-out infinite; } .br.r { --bx: 5px; animation: bracket 1.6s ease-in-out infinite; }
.rocket { animation: rocket 2s ease-in-out infinite; transform-box: fill-box; }
.flame { transform-box: fill-box; transform-origin: 50% 0; animation: flame 0.4s ease-in-out infinite; }

.about-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); align-items: center; }
.about-art svg { width: 100%; height: auto; overflow: visible; }
.about-art .slab.blue { fill: var(--blue); } .about-art .slab.amber { fill: var(--amber); } .about-art .slab.ink { fill: var(--ink); }
.about-art .shadow { fill: rgba(18, 23, 58, 0.12); }
.about-art .link { stroke: var(--ink); stroke-width: 3; stroke-dasharray: 6 6; fill: none; opacity: 0.35; }
.about-art .packet { fill: var(--blue); }
.about-side .years { margin: 0 0 2rem; }

.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
.svc-card {
    --bg: var(--blue); --fg: #fff; --ac: var(--amber);
    background: var(--paper); border-radius: 22px; padding: 0.9rem 0.9rem 1.6rem; border: 1px solid var(--line);
    transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
.svc-card:hover { transform: translateY(-8px); box-shadow: 0 34px 44px -30px rgba(42, 42, 194, 0.6); }
.svc-card .art { background: var(--bg); border-radius: 15px; height: 210px; margin-bottom: 1.3rem; overflow: hidden; display: grid; place-items: center; }
.svc-card .art svg { width: 100%; height: 100%; transition: transform 0.7s var(--ease); }
.svc-card:hover .art svg { transform: scale(1.08); }
.svc-card h3 { font-size: 1.4rem; padding-inline: 0.5rem; }
.svc-card p { padding-inline: 0.5rem; margin-top: 0.3rem; color: var(--ink-soft); }
.c-amber { --bg: var(--amber); --fg: var(--ink); --ac: #fff; }
.c-ink { --bg: var(--ink); --fg: #fff; --ac: var(--amber); }
.c-deep { --bg: var(--blue-deep); --fg: #fff; --ac: var(--amber); }
.svc-card .f1 { fill: var(--fg); } .svc-card .f2 { fill: var(--ac); } .svc-card .f3 { fill: var(--fg); opacity: 0.2; }
.svc-card .s1 { stroke: var(--fg); } .svc-card .s2 { stroke: var(--ac); }

.pico { width: 64px; height: 64px; margin-bottom: 1rem; }
.pico svg { width: 100%; height: 100%; overflow: visible; }
.stop h3 { margin-top: 0; }
.stop { padding-top: 3.4rem; }
.stop .pico { margin-top: 0.3rem; }

.orbit { margin-top: 2.5rem; max-width: 360px; }
.orbit svg { width: 100%; height: auto; overflow: visible; }
.orb-ring { fill: none; stroke: rgba(255, 255, 255, 0.18); stroke-width: 1.5; stroke-dasharray: 4 8; }
.orbit text { font: 700 14px var(--font-body); fill: #fff; }
.orbit-a, .orbit-b { transform-origin: 200px 200px; }
.orbit-a { animation: spin 26s linear infinite; } .orbit-b { animation: spin 40s linear infinite reverse; }
.orbit .sat { animation: spin 26s linear infinite reverse; transform-box: fill-box; transform-origin: center; }
.orbit-b .sat { animation-duration: 40s; animation-direction: normal; }
.orbit:hover .orbit-a, .orbit:hover .orbit-b, .orbit:hover .sat { animation-play-state: paused; }

@media (max-width: 1080px) { .svc-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; } .orbit { margin-inline: auto; } }
@media (max-width: 680px) { .svc-grid { grid-template-columns: 1fr; } .svc-card .art { height: 190px; } }
@media (prefers-reduced-motion: reduce) {
    .fl, .spin, .bar, .tick, .dash, .pk, .bug, .cursor, .dr, .br, .rocket, .flame, .ring, .orbit-a, .orbit-b, .orbit .sat { animation: none !important; }
    .tick { stroke-dashoffset: 0; }
}
.orbit text.dk { fill: #12173a; }

/* ---------- services page ---------- */
.sv-hero { padding-bottom: 5rem; }
.sv-hero-in > * { max-width: 62rem; }
.sv-hero h1 { font-size: clamp(2.4rem, 5vw, 4.4rem); font-weight: 800; line-height: 1; letter-spacing: -0.035em; }
.sv-hero .lead { margin-top: 1.4rem; font-size: 1.15rem; color: var(--on-blue); }
.jump { display: flex; flex-wrap: wrap; gap: 0.55rem; margin-top: 1.4rem; }
.jump a { padding: 0.55rem 1rem; border-radius: 999px; border: 1.5px solid rgba(255, 255, 255, 0.4); font-weight: 600; font-size: 0.95rem; text-decoration: none; transition: transform 0.4s var(--ease), background-color 0.25s, color 0.25s, border-color 0.25s; }
.jump a:hover { transform: translateY(-4px) rotate(-1.5deg); background: var(--amber); color: var(--ink); border-color: var(--amber); }
.sd { padding: clamp(4rem, 8vw, 7rem) 0; }
.sd.paper { background: var(--paper); } .sd.white { background: var(--white); }
.sd-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2rem, 6vw, 6rem); align-items: center; }
.sd.flip .sd-art { order: 2; }
.sd-art { --bg: var(--blue); --fg: #fff; --ac: var(--amber); background: var(--bg); border-radius: 26px; aspect-ratio: 16 / 10; overflow: hidden; display: grid; place-items: center; box-shadow: 0 40px 50px -34px rgba(42, 42, 194, 0.55); }
.sd-art.c-amber { --bg: var(--amber); --fg: var(--ink); --ac: #fff; }
.sd-art.c-ink { --bg: var(--ink); --fg: #fff; --ac: var(--amber); }
.sd-art.c-deep { --bg: var(--blue-deep); --fg: #fff; --ac: var(--amber); }
.sd-art svg { width: 100%; height: 100%; transition: transform 0.8s var(--ease); }
.sd-art:hover svg { transform: scale(1.07); }
.sd-art .f1 { fill: var(--fg); } .sd-art .f2 { fill: var(--ac); } .sd-art .f3 { fill: var(--fg); opacity: 0.2; }
.sd-art .s1 { stroke: var(--fg); } .sd-art .s2 { stroke: var(--ac); }
.sd-copy h2 { font-size: clamp(2rem, 3.8vw, 3.2rem); }
.sd-sum { margin-top: 1.1rem; font-size: 1.2rem; font-weight: 500; text-wrap: pretty; }
.sd-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1.3rem; }
.sd-tags li { padding: 0.4rem 0.9rem; border-radius: 999px; font-weight: 700; font-size: 0.88rem; background: var(--ink); color: #fff; transition: background-color 0.25s, transform 0.4s var(--ease); }
.sd-tags li:hover { background: var(--blue); transform: translateY(-3px); }
.sd-more { margin-top: 1.3rem; color: var(--ink-soft); font-size: 1rem; max-width: 34rem; text-wrap: pretty; }
.sv-cta { padding: clamp(5rem, 9vw, 8rem) 0; }
.sv-cta-in { display: grid; gap: 1.2rem; justify-items: start; }
.sv-cta .sub { margin-top: 0; }
@media (max-width: 900px) { .sd-grid { grid-template-columns: 1fr; } .sd.flip .sd-art { order: 0; } }

/* ---------- Numans: single regular weight, no faux bold ---------- */
html { font-synthesis: none; }
body, h1, h2, h3, h4, .btn, .tab, .brand-name, .chip, .pill, b, strong, dt, dd, label, .stop h3 { font-weight: 400 !important; }
h1, h2, h3, .statement, .years b { letter-spacing: -0.01em !important; }
.hero h1 { font-size: clamp(2.4rem, 4.4vw, 3.2rem); line-height: 1.05; }
.sv-hero h1 { font-size: clamp(2.3rem, 4.4vw, 3.9rem); line-height: 1.05; }
.statement { line-height: 1.18; }
