/* BusinessRx.ai — one stylesheet, system fonts, light + dark via CSS variables */
:root {
  --bg: #f7fbfa;
  --surface: #ffffff;
  --surface-2: #eef6f3;
  --ink: #0f1f1c;
  --ink-2: #4b5f5a;
  --line: #d9e7e2;
  --brand: #0f766e;
  --brand-ink: #ffffff;
  --brand-soft: #d5f2ec;
  --pulse: #10b981;
  --focus: #2563eb;
  --live: #166534; --live-bg: #dcfce7;
  --beta: #1e40af; --beta-bg: #dbeafe;
  --dev: #92400e;  --dev-bg: #fef3c7;
  --radius: 14px;
  --shadow: 0 1px 2px rgb(0 0 0 / .05), 0 4px 16px rgb(0 0 0 / .05);
  --max: 1120px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #071311;
    --surface: #0c1d1a;
    --surface-2: #112622;
    --ink: #e8f6f2;
    --ink-2: #9db8b1;
    --line: #1d3631;
    --brand: #2dd4bf;
    --brand-ink: #032a25;
    --brand-soft: #0f302b;
    --pulse: #34d399;
    --focus: #93c5fd;
    --live: #86efac; --live-bg: #12301d;
    --beta: #93c5fd; --beta-bg: #172a4a;
    --dev: #fcd34d;  --dev-bg: #3a2c0b;
    --shadow: 0 1px 2px rgb(0 0 0 / .4);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, Roboto, "Helvetica Neue", Arial, sans-serif;
  overflow-wrap: break-word;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 .5em; }
h1 { font-size: clamp(2.1rem, 6vw, 3.6rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 760px; }
.muted { color: var(--ink-2); }
.lead { font-size: clamp(1.1rem, 2.4vw, 1.3rem); color: var(--ink-2); max-width: 46rem; }
.eyebrow { font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); margin-bottom: .6rem; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 14px; z-index: 10; }
.skip:focus { left: 8px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; flex-wrap: wrap; }
.wordmark { font-weight: 800; font-size: 1.2rem; letter-spacing: -0.02em; color: var(--ink); text-decoration: none; white-space: nowrap; }
.wordmark span { color: var(--brand); }
.nav { display: flex; gap: 4px; flex-wrap: wrap; margin: 0; padding: 0; list-style: none; }
.nav a { display: block; padding: 8px 12px; border-radius: 999px; color: var(--ink-2); text-decoration: none; font-weight: 600; font-size: .95rem; }
.nav a:hover { color: var(--ink); background: var(--surface-2); }
.nav a[aria-current="page"] { color: var(--ink); background: var(--surface-2); }
@media (max-width: 560px) {
  .site-header .wrap { padding-top: 8px; padding-bottom: 8px; min-height: 0; }
  .nav { width: 100%; justify-content: space-between; }
  .nav a { padding: 6px 8px; font-size: .9rem; }
}

/* Sections */
main { display: block; }
section { padding: clamp(48px, 8vw, 88px) 0; }
section + section { border-top: 1px solid var(--line); }
.hero { padding-top: clamp(56px, 10vw, 112px); }
.hero h1 { max-width: 15ch; }
.hero .accent { color: var(--brand); }
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 28px; }
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: 999px; font-weight: 700; text-decoration: none; border: 2px solid transparent; }
.btn-primary { background: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-ghost { border-color: var(--line); color: var(--ink); background: var(--surface); }
.btn-ghost:hover { border-color: var(--ink-2); }
.btn[aria-disabled="true"] { opacity: .65; cursor: default; }

/* What we do */
.pillars { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-top: 28px; }
.pillar { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.pillar h3 { margin-bottom: .35em; }
.pillar p { margin: 0; color: var(--ink-2); font-size: .97rem; }
.pillar .ico { width: 40px; height: 40px; border-radius: 10px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; margin-bottom: 14px; }

/* Project cards */
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.section-head h2 { margin: 0; }
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.card { position: relative; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); transition: transform .15s ease, border-color .15s ease; }
.card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; border-radius: var(--radius) var(--radius) 0 0; background: var(--accent, var(--brand)); }
.card:hover { transform: translateY(-2px); border-color: var(--accent, var(--brand)); }
.card:focus-within { border-color: var(--accent, var(--brand)); }
.card-top { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.card h3 { margin: 0; font-size: 1.15rem; }
.card h3 a { color: var(--ink); text-decoration: none; }
.card h3 a::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }
.card p { color: var(--ink-2); font-size: .97rem; flex: 1; }
.card .meta { font-size: .82rem; color: var(--ink-2); margin: 0; }
.app-icon { width: 56px; height: 56px; border-radius: 13px; flex: none; }
.monogram { width: 56px; height: 56px; border-radius: 13px; flex: none; display: grid; place-items: center; font-weight: 800; font-size: 1.2rem; color: #fff; background: var(--accent, var(--brand)); letter-spacing: -0.02em; }
.badge { display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; padding: 3px 9px; border-radius: 999px; margin-top: 4px; }
.badge-live { color: var(--live); background: var(--live-bg); }
.badge-beta { color: var(--beta); background: var(--beta-bg); }
.badge-in-development { color: var(--dev); background: var(--dev-bg); }

/* Filters */
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 24px; padding: 0; list-style: none; }
.filters button { font: inherit; font-size: .9rem; font-weight: 600; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); cursor: pointer; }
.filters button[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.card[hidden] { display: none; }

/* Detail pages */
.detail-head { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; }
.detail-head .app-icon, .detail-head .monogram { width: 84px; height: 84px; border-radius: 19px; font-size: 1.7rem; }
.facts { display: grid; gap: 10px 24px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 22px; margin: 28px 0; }
.facts dt { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-2); font-weight: 700; }
.facts dd { margin: 2px 0 0; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0; list-style: none; }
.chips li { font-size: .82rem; padding: 3px 10px; border-radius: 999px; background: var(--surface-2); color: var(--ink-2); }
.prose h2 { margin-top: 1.6em; font-size: 1.4rem; }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: .45em; }
.prose li::marker { color: var(--accent, var(--brand)); }
.note { font-size: .9rem; color: var(--ink-2); border-left: 3px solid var(--line); padding-left: 12px; }
.callout { background: var(--brand-soft); border-radius: var(--radius); padding: 18px 22px; margin: 24px 0; }
.callout p:last-child { margin: 0; }
.crumbs { font-size: .9rem; margin-bottom: 18px; }
.crumbs a { color: var(--ink-2); }

/* About / résumé */
.two-col { display: grid; gap: 40px; grid-template-columns: 1fr; }
@media (min-width: 860px) { .two-col { grid-template-columns: 1.3fr 1fr; } }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.panel h3 { font-size: 1rem; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-2); }
.panel ul { margin: 0; padding-left: 1.1em; }
.panel li { margin-bottom: .4em; }
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { padding: 0 0 22px 22px; border-left: 2px solid var(--line); position: relative; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: var(--brand); }
.timeline h3 { margin-bottom: .2em; }
.timeline p { color: var(--ink-2); margin: 0; }
.steps { counter-reset: s; list-style: none; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.steps li { counter-increment: s; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.steps li::before { content: counter(s); display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--brand); color: var(--brand-ink); font-weight: 800; margin-bottom: 10px; }
.steps p { margin: 0; color: var(--ink-2); font-size: .97rem; }

/* Contact */
.contact-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-top: 24px; }
.contact-grid .pillar a.btn { margin-top: 14px; }
.big-email { font-size: clamp(1.2rem, 4.5vw, 1.8rem); font-weight: 800; word-break: break-all; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 36px 0 48px; color: var(--ink-2); font-size: .92rem; }
.site-footer .wrap { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.site-footer ul { list-style: none; display: flex; gap: 16px; flex-wrap: wrap; margin: 0; padding: 0; }
.site-footer a { color: var(--ink-2); }

/* ---------- Sky Warden: night-sky theme ---------- */
.theme-sky { --sw-bg: #06122b; --sw-bg2: #0b1f47; --sw-ink: #e8eefc; --sw-ink2: #a9b8dc; --sw-line: #1d3466; --sw-orange: #ff9a2e; }
.theme-sky .sky-hero { background: radial-gradient(1200px 500px at 70% -10%, #1d4ed8 0%, transparent 60%), linear-gradient(180deg, var(--sw-bg2), var(--sw-bg)); color: var(--sw-ink); border-bottom: 1px solid var(--sw-line); }
.theme-sky .sky-hero .lead { color: var(--sw-ink2); }
.theme-sky .sky-hero .eyebrow { color: var(--sw-orange); }
.theme-sky .sky-hero .btn-primary { background: var(--sw-orange); color: #1a0d00; }
.theme-sky .sky-hero .btn-ghost { background: transparent; color: var(--sw-ink); border-color: var(--sw-line); }
.theme-sky .sky-hero .btn-ghost:hover { border-color: var(--sw-ink2); }
.theme-sky .sky-hero a:not(.btn) { color: #9cc0ff; }
.theme-sky .sky-hero .crumbs a { color: var(--sw-ink2); }
.sky-hero .hero-grid { display: grid; gap: 32px; align-items: center; grid-template-columns: 1fr; }
@media (min-width: 860px) { .sky-hero .hero-grid { grid-template-columns: 1.4fr 1fr; } }
.radar { position: relative; aspect-ratio: 1; max-width: 340px; width: 100%; margin: 0 auto; border-radius: 50%; background: radial-gradient(circle, transparent 0 32%, rgb(156 192 255 / .14) 32.5% 33%, transparent 33.5% 62%, rgb(156 192 255 / .14) 62.5% 63%, transparent 63.5% 95%, rgb(156 192 255 / .14) 95.5% 96%, transparent 96.5%); }
.radar img { position: absolute; inset: 27%; width: 46%; height: 46%; border-radius: 22%; box-shadow: 0 20px 60px rgb(0 0 0 / .45); }
.radar .sweep { position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(from 0deg, rgb(255 154 46 / .28), transparent 22%); animation: sweep 6s linear infinite; }
@keyframes sweep { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .radar .sweep { animation: none; } }
.plans { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-top: 24px; }
.plan { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.plan.highlight { border: 2px solid #ff9a2e; }
.plan h3 { margin-bottom: .2em; }
.plan .price { font-size: 1.5rem; font-weight: 800; margin: 4px 0 8px; }
.plan p { color: var(--ink-2); margin: 0; font-size: .97rem; }
.shots { display: grid; gap: 12px; grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 720px; }
.shot { aspect-ratio: 9 / 19.5; border-radius: clamp(14px, 4vw, 28px); border: 1px dashed var(--line); background: var(--surface-2); display: grid; place-items: center; text-align: center; color: var(--ink-2); font-size: clamp(.7rem, 2.6vw, .9rem); padding: 8px; }
.legal h1 { font-size: clamp(1.9rem, 5vw, 2.6rem); }
.legal h2 { font-size: 1.2rem; margin-top: 1.8em; }
.legal .updated { font-size: .9rem; color: var(--ink-2); }
.subnav { display: flex; gap: 8px; flex-wrap: wrap; list-style: none; padding: 0; margin: 0 0 24px; }
.subnav a { display: block; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); text-decoration: none; color: var(--ink-2); font-size: .9rem; font-weight: 600; }
.subnav a[aria-current="page"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* small utilities (no inline styles, CSP-friendly) */
.m0 { margin: 0; }
.tight { margin: .4em 0 0; }
.region { margin: .8em 0 1em; }
.small { font-size: .9rem; }
.stack { display: grid; gap: 16px; align-content: start; }
.spaced { margin-top: 24px; }
.copyright { width: 100%; margin: 0; }
.panel ul.chips { padding: 0; }
.when { font-size: .85rem; font-weight: 600; color: var(--ink-2); margin: 0 0 .3em !important; }

/* =====================================================================
   Motion layer (GSAP). Hidden "before" states apply only when JS is on
   and the visitor hasn't asked for reduced motion.
   ===================================================================== */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal], .js [data-reveal-group] > * { opacity: 0; visibility: hidden; transform: translateY(32px); }
}

/* Page-to-page cross-fade (Chrome, Edge, Safari 18.2+) */
@view-transition { navigation: auto; }
@media (prefers-reduced-motion: no-preference) {
  ::view-transition-old(root) { animation: vt-out .25s ease both; }
  ::view-transition-new(root) { animation: vt-in .35s ease both; }
}
@keyframes vt-out { to { opacity: 0; transform: translateY(-8px); } }
@keyframes vt-in { from { opacity: 0; transform: translateY(12px); } }

.scroll-progress { position: fixed; inset: 0 0 auto 0; height: 3px; background: linear-gradient(90deg, var(--brand), #6366f1, #f59e0b); transform: scaleX(0); transform-origin: 0 50%; z-index: 20; pointer-events: none; }
.site-header { transition: box-shadow .25s ease, background-color .25s ease; will-change: transform; }
.site-header.is-scrolled { box-shadow: 0 6px 24px rgb(0 0 0 / .08); }

/* Hero headline: words rise in with pure CSS so the first paint is instant */
.rise .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.rise .w > span { display: inline-block; }
@media (prefers-reduced-motion: no-preference) {
  .rise .w > span { animation: rise .75s cubic-bezier(.16, 1, .3, 1) both; animation-delay: calc(var(--d, 0) * 1ms); }
}
@keyframes rise { from { transform: translateY(105%); } }

/* Home hero */
.hero-home { position: relative; overflow: hidden; isolation: isolate; }
.hero-home::before { content: ""; position: absolute; inset: -20% -10% auto auto; width: 70vw; height: 70vw; max-width: 900px; max-height: 900px; background: radial-gradient(closest-side, color-mix(in srgb, var(--brand) 22%, transparent), transparent 70%); z-index: -2; }
.sky-lines { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; color: var(--brand); opacity: .55; pointer-events: none; }
.sky-lines .route { fill: none; stroke: currentColor; stroke-width: 1.5; stroke-dasharray: 2 7; stroke-linecap: round; }
.sky-lines .node { fill: currentColor; }
.sky-lines .plane { fill: #f59e0b; opacity: 0; }
.hero-split { display: grid; gap: 40px; align-items: center; grid-template-columns: 1fr; }
@media (min-width: 980px) { .hero-split { grid-template-columns: 1.15fr .85fr; } }
.hero-home h1 { max-width: 14ch; }

/* Terminal */
.terminal { background: #0b0f14; color: #d6dde8; border-radius: 16px; border: 1px solid #1f2937; box-shadow: 0 30px 80px rgb(0 0 0 / .25); overflow: hidden; font: 14px/1.6 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; min-width: 0; }
.term-bar { display: flex; align-items: center; gap: 8px; padding: 10px 14px; background: #111827; border-bottom: 1px solid #1f2937; }
.term-bar i { width: 11px; height: 11px; border-radius: 50%; background: #374151; }
.term-bar i:nth-child(1) { background: #ef4444; } .term-bar i:nth-child(2) { background: #f59e0b; } .term-bar i:nth-child(3) { background: #22c55e; }
.term-title { margin-left: 8px; font-size: 12px; color: #9ca3af; }
.term-body { padding: 16px 18px 20px; min-height: 13.5em; }
.term-prompt { color: #2dd4bf; }
.term-cmd { color: #f3f4f6; }
.term-cmd::after { content: "▍"; color: #2dd4bf; margin-left: 2px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.term-line { white-space: pre-wrap; overflow-wrap: anywhere; }
.term-line.ok { color: #86efac; } .term-line.wait { color: #fcd34d; } .term-line.info { color: #93c5fd; }

/* Stats band */
.stats { display: grid; gap: 1px; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.stat { background: var(--surface); padding: 22px 20px; }
.stat b { display: block; font-size: clamp(1.8rem, 4.5vw, 2.6rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1.05; font-variant-numeric: tabular-nums; background: linear-gradient(90deg, var(--brand), #6366f1); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat span { display: block; color: var(--ink-2); font-size: .92rem; margin-top: 6px; }

/* Showcase: stacked cards by default; horizontal pinned scroller on desktop */
.showcase { overflow: hidden; }
.showcase-track { display: grid; gap: 18px; }
.slide { --accent: var(--brand); }
.slide-inner { position: relative; height: 100%; border-radius: 22px; padding: clamp(22px, 3vw, 40px); background: linear-gradient(145deg, color-mix(in srgb, var(--accent) 16%, var(--surface)), var(--surface) 60%); border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--line)); display: flex; flex-direction: column; gap: 14px; overflow: hidden; transform-style: preserve-3d; }
.slide-inner::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 0%), color-mix(in srgb, var(--accent) 18%, transparent), transparent 60%); }
.slide-num { position: absolute; right: 20px; top: 6px; font-size: clamp(4rem, 10vw, 8rem); font-weight: 900; letter-spacing: -0.05em; color: color-mix(in srgb, var(--accent) 14%, transparent); line-height: 1; pointer-events: none; }
.slide .app-icon, .slide .monogram { width: 72px; height: 72px; border-radius: 17px; font-size: 1.4rem; }
.slide h3 { font-size: clamp(1.5rem, 3vw, 2.2rem); margin: 0; }
.slide h3 a { color: var(--ink); text-decoration: none; }
.slide h3 a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.slide p { color: var(--ink-2); margin: 0; }
.slide ul.hl { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.slide ul.hl li { padding-left: 22px; position: relative; }
.slide ul.hl li::before { content: ""; position: absolute; left: 0; top: .55em; width: 10px; height: 10px; border-radius: 3px; background: var(--accent); }
.slide .go { margin-top: auto; font-weight: 700; color: var(--accent); }
.showcase-progress { display: none; height: 3px; background: var(--line); border-radius: 3px; margin-top: 20px; overflow: hidden; }
.showcase-progress span { display: block; height: 100%; background: var(--brand); transform: scaleX(0); transform-origin: 0 50%; }
@media (min-width: 640px) { .showcase-track { grid-template-columns: repeat(2, 1fr); } }
.showcase.is-horizontal { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; padding: 70px 0 40px; }
.showcase.is-horizontal .showcase-track { display: flex; gap: 28px; width: max-content; padding: 0 max(20px, calc((100vw - var(--max)) / 2 + 20px)); will-change: transform; }
.showcase.is-horizontal .slide { width: min(560px, 62vw); height: min(62vh, 520px); flex: none; }
.showcase.is-horizontal .showcase-progress { display: block; }

/* Card spotlight */
.card, .pillar, .plan { transform-style: preserve-3d; }
.card::after, .pillar::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .3s; background: radial-gradient(320px circle at var(--mx, 50%) var(--my, 50%), color-mix(in srgb, var(--accent, var(--brand)) 14%, transparent), transparent 65%); }
.card:hover::after, .pillar:hover::after { opacity: 1; }
.pillar { position: relative; }

/* Flow diagram on project pages */
.flow { position: relative; margin: 32px 0 8px; padding-left: 44px; list-style: none; }
.flow-line, .flow-fill { position: absolute; left: 15px; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; }
.flow-line { background: var(--line); }
.flow-fill { background: linear-gradient(var(--accent, var(--brand)), #6366f1); transform-origin: 50% 0; }
.flow-step { position: relative; padding: 4px 0 26px; }
.flow-step::before { content: attr(data-n); position: absolute; left: -44px; top: 2px; width: 33px; height: 33px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .9rem; background: var(--surface); border: 2px solid var(--line); color: var(--ink-2); transition: background .3s, border-color .3s, color .3s, transform .3s; }
.flow-step.is-on::before { background: var(--accent, var(--brand)); border-color: var(--accent, var(--brand)); color: #fff; transform: scale(1.08); }
.flow-step h3 { margin: 4px 0 4px; font-size: 1.08rem; }
.flow-step p { margin: 0; color: var(--ink-2); }
.no-motion .flow-fill, html:not(.js) .flow-fill { display: none; }

/* Detail-page hero glow */
.detail-hero { position: relative; overflow: hidden; isolation: isolate; }
.detail-hero::before { content: ""; position: absolute; width: 700px; height: 700px; right: -220px; top: -260px; background: radial-gradient(closest-side, color-mix(in srgb, var(--accent, var(--brand)) 28%, transparent), transparent 70%); z-index: -1; }

/* Timeline progress line */
.timeline-wrap { position: relative; }
.timeline-fill { position: absolute; left: 0; top: 0; bottom: 22px; width: 2px; background: var(--brand); transform-origin: 50% 0; transform: scaleY(0); }
html:not(.js) .timeline-fill { display: none; }

/* Sky Warden radar (SVG) */
.radar-wrap { position: relative; width: 100%; max-width: 420px; margin: 0 auto; aspect-ratio: 1; }
.radar-svg { width: 100%; height: 100%; display: block; overflow: visible; }
.radar-svg .ring { fill: none; stroke: rgb(156 192 255 / .18); }
.radar-svg .ping { fill: none; stroke: #ff9a2e; stroke-width: 1.5; opacity: 0; }
.radar-svg .rpath { fill: none; stroke: none; }
.radar-svg .blip { fill: #ffd29a; }
.radar-icon { position: absolute; inset: 31%; width: 38%; height: 38%; border-radius: 22%; box-shadow: 0 20px 60px rgb(0 0 0 / .45); }

/* Big closing CTA */
.cta-band { background: linear-gradient(120deg, color-mix(in srgb, var(--brand) 18%, var(--surface)), color-mix(in srgb, #6366f1 14%, var(--surface))); border-radius: 28px; padding: clamp(28px, 6vw, 64px); text-align: center; }
.cta-band .lead { margin-left: auto; margin-right: auto; }
.cta-band .cta-row { justify-content: center; }
.rise .d0 { animation-delay: 0ms; }
.rise .d1 { animation-delay: 45ms; }
.rise .d2 { animation-delay: 90ms; }
.rise .d3 { animation-delay: 135ms; }
.rise .d4 { animation-delay: 180ms; }
.rise .d5 { animation-delay: 225ms; }
.rise .d6 { animation-delay: 270ms; }
.rise .d7 { animation-delay: 315ms; }
.rise .d8 { animation-delay: 360ms; }
.rise .d9 { animation-delay: 405ms; }
.rise .d10 { animation-delay: 450ms; }
.rise .d11 { animation-delay: 495ms; }
.rise .d12 { animation-delay: 540ms; }
.rise .d13 { animation-delay: 585ms; }
.rise .d14 { animation-delay: 630ms; }
.rise .d15 { animation-delay: 675ms; }
.showcase.is-horizontal > .wrap { width: 100%; }
.stats { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 760px) { .stats { grid-template-columns: repeat(3, 1fr); } }
.timeline li p + p { margin-top: .5em; }

@media (prefers-reduced-motion: no-preference) {
  .intro { animation: intro .8s cubic-bezier(.16, 1, .3, 1) .25s both; }
  .intro.i2 { animation-delay: .4s; } .intro.i3 { animation-delay: .55s; }
}
@keyframes intro { from { opacity: .01; transform: translateY(18px); } }
.timeline .tl-list { list-style: none; padding: 0; margin: .4em 0 0; display: grid; gap: .5em; color: var(--ink-2); }
.timeline .tl-list li { padding: 0; border: 0; }
.timeline .tl-list li::before { display: none; }
.timeline .tl-list b { color: var(--ink); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ===== Project hero visuals ===== */
.hero-visual { margin: 28px 0 8px; }
/* Sky Warden: flight routes on the night sky */
.sky-flights { position: relative; overflow: hidden; isolation: isolate; }
.sky-flights .sky-lines { color: #9cc0ff; opacity: .4; z-index: 0; }
.sky-flights .sky-lines .plane { fill: #ff9a2e; }
.sky-flights > .wrap { position: relative; z-index: 1; }

/* AU's Playground: ducks chased by a goose */
.duck-run { position: relative; height: 210px; border-radius: 22px; overflow: hidden; background: linear-gradient(#bde7ff, #e6f6ff 70%); border: 1px solid var(--line); user-select: none; }
.duck-sun { position: absolute; right: 28px; top: 20px; width: 46px; height: 46px; border-radius: 50%; background: #fde047; box-shadow: 0 0 40px #fde047; }
.duck-cloud { position: absolute; top: 26px; width: 90px; height: 28px; border-radius: 20px; background: #fff; opacity: .9; }
.duck-cloud::before, .duck-cloud::after { content: ""; position: absolute; background: #fff; border-radius: 50%; }
.duck-cloud::before { width: 40px; height: 40px; left: 14px; top: -18px; }
.duck-cloud::after { width: 30px; height: 30px; left: 46px; top: -12px; }
.duck-cloud.c2 { top: 64px; transform: scale(.7); opacity: .7; }
.duck-grass { position: absolute; left: 0; right: 0; bottom: 0; height: 52px; background: linear-gradient(#86d96b, #5cbf4a); border-top: 3px solid #4fae3f; }
.runner { position: absolute; left: 0; bottom: 34px; width: 64px; z-index: 2; cursor: pointer; }
.runner svg { display: block; width: 100%; height: auto; overflow: visible; }
.runner.duck.d1 { bottom: 26px; width: 56px; } .runner.duck.d2 { bottom: 38px; width: 52px; } .runner.duck.d3 { bottom: 22px; width: 58px; }
.goose-runner { width: 92px; bottom: 30px; cursor: default; z-index: 3; }
.bubble { position: absolute; left: 50%; top: -26px; transform: translateX(-50%); background: #fff; color: #1f2937; font: 800 .8rem/1 system-ui, sans-serif; padding: 6px 9px; border-radius: 12px; box-shadow: 0 4px 10px rgb(0 0 0 / .15); white-space: nowrap; opacity: 0; visibility: hidden; }
.goose-runner .bubble { color: #b91c1c; }
.duck-hint { position: absolute; left: 16px; top: 12px; margin: 0; font-size: .8rem; font-weight: 700; color: #0c4a6e; opacity: .7; }
html:not(.js) .runner { transform: translateX(calc(var(--i, 1) * 90px)); }
@media (prefers-reduced-motion: reduce) { .runner.duck.d0 { left: 10%; } .runner.duck.d1 { left: 28%; } .runner.duck.d2 { left: 46%; } .runner.duck.d3 { left: 62%; } .goose-runner { left: 78%; } .duck-hint { display: none; } }

/* Loan Officer Assistant: approval cards */
.approvals { background: #1e1f22; color: #dbdee1; border-radius: 16px; padding: 16px; font-size: .92rem; box-shadow: 0 20px 50px rgb(0 0 0 / .2); }
.approvals-head { font-weight: 700; color: #f2f3f5; margin-bottom: 10px; display: flex; gap: 6px; align-items: center; }
.approvals-head .hash { color: #80848e; font-size: 1.2rem; }
.approvals-time { margin-left: auto; font-weight: 500; font-size: .78rem; color: #949ba4; }
.appr-card { position: relative; display: flex; align-items: center; gap: 10px; background: #2b2d31; border: 1px solid #3f4147; border-left: 4px solid var(--accent, #5865f2); border-radius: 8px; padding: 10px 12px; margin-bottom: 8px; }
.appr-card b { display: block; color: #f2f3f5; }
.appr-card small { color: #949ba4; }
.appr-react { margin-left: auto; background: #3b3d44; border: 1px solid #5865f2; border-radius: 8px; padding: 2px 8px; font-size: .85rem; }
.appr-sent { font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; color: #052e16; background: #4ade80; border-radius: 999px; padding: 3px 8px; }
.appr-foot { font-size: .8rem; color: #949ba4; margin-top: 4px; }

/* Publisher: one post fans out */
.fanout { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 22px; text-align: center; }
.fan-post { display: inline-block; background: var(--accent, var(--brand)); color: #fff; border-radius: 14px; padding: 12px 18px; box-shadow: 0 10px 30px color-mix(in srgb, var(--accent, var(--brand)) 35%, transparent); }
.fan-post b { display: block; font-size: 1.05rem; } .fan-post small { opacity: .85; }
.fan-lines { height: 22px; margin: 6px auto 8px; width: 2px; background: linear-gradient(var(--accent, var(--brand)), transparent); }
.fan-plats { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.fan-plats li { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface-2); font-size: .85rem; font-weight: 600; transition: background .3s, color .3s, border-color .3s; }
.fan-plats li.on { background: color-mix(in srgb, var(--accent, var(--brand)) 16%, var(--surface)); border-color: var(--accent, var(--brand)); }
.fan-mode { margin-top: 14px; font: 600 .82rem ui-monospace, Menlo, monospace; color: var(--ink-2); }

/* Sensor Keeper: heartbeat panel */
.hb-panel { background: #04120e; border-radius: 16px; border: 5px solid #1f2d2a; padding: 12px 14px 14px; color: #a7f3d0; font: 13px/1.5 ui-monospace, Menlo, monospace; }
.hb-top { display: flex; justify-content: space-between; color: #6ee7b7; }
.hb-ok { color: #4ade80; }
.hb-ecg { width: 100%; height: 80px; display: block; margin: 6px 0; }
.hb-ecg .ecg-trace { stroke: #34d399; filter: drop-shadow(0 0 4px #34d399); }
.hb-rows { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; }
.hb-rows b { color: #4ade80; }

/* JobHunt: morning digest */
.jh-panel { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px; }
.jh-head { font-weight: 800; font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-2); margin-bottom: 8px; }
.jh-row { display: grid; grid-template-columns: 26px 1fr 34%; gap: 10px; align-items: center; padding: 8px 6px; border-radius: 8px; }
.jh-n { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); font-weight: 800; font-size: .8rem; }
.jh-role { font-weight: 600; font-size: .95rem; }
.jh-bar { height: 8px; border-radius: 8px; background: var(--surface-2); overflow: hidden; }
.jh-bar i { display: block; height: 100%; background: var(--accent, var(--brand)); transform-origin: 0 50%; }
.jh-bar .w0 { width: 92%; } .jh-bar .w1 { width: 74%; } .jh-bar .w2 { width: 86%; } .jh-bar .w3 { width: 68%; }
.jh-reply { margin-top: 8px; font: 600 .85rem ui-monospace, Menlo, monospace; color: var(--ink-2); }
.ecg-trace { fill: none; stroke: var(--pulse, #10b981); stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; }
