/* =========================================================
   Design tokens
   ========================================================= */
:root {
  --bg: #07080b;
  --surface: rgba(20, 23, 30, 0.72);
  --surface-solid: #12151b;
  --surface-2: rgba(255, 255, 255, 0.04);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.16);
  --text: #eef1f6;
  --text-muted: #a1a9b6;
  --text-faint: #6c7584;

  --a1: #5eead4;            /* mint   */
  --a2: #a78bfa;            /* violet */
  --a3: #f9a8d4;            /* pink   */
  --a4: #fbbf24;            /* amber  */
  --a5: #60a5fa;            /* sky    */
  --a1-soft: rgba(94, 234, 212, 0.14);
  --a2-soft: rgba(167, 139, 250, 0.14);
  --grad: linear-gradient(110deg, var(--a1) 0%, var(--a2) 55%, var(--a3) 100%);
  --on-grad: #070a10;

  --aurora-1: rgba(94, 234, 212, 0.22);
  --aurora-2: rgba(167, 139, 250, 0.26);
  --aurora-3: rgba(249, 168, 212, 0.14);
  --grid-line: rgba(255, 255, 255, 0.035);
  --grain-opacity: 0.06;

  --shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.7);
  --radius: 22px;
  --radius-sm: 12px;

  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --display: 'Space Grotesk', var(--font);
  --serif: 'Instrument Serif', Georgia, serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --container: 1180px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  color-scheme: dark;
}

:root[data-theme='light'] {
  --bg: #f7f6f2;
  --surface: rgba(255, 255, 255, 0.75);
  --surface-solid: #ffffff;
  --surface-2: rgba(15, 20, 30, 0.035);
  --border: rgba(15, 20, 30, 0.09);
  --border-strong: rgba(15, 20, 30, 0.18);
  --text: #0e1218;
  --text-muted: #4d5663;
  --text-faint: #8a929d;

  --a1: #0d9488;
  --a2: #7c3aed;
  --a3: #db2777;
  --a4: #d97706;
  --a5: #2563eb;
  --a1-soft: rgba(13, 148, 136, 0.1);
  --a2-soft: rgba(124, 58, 237, 0.1);
  --on-grad: #ffffff;

  --aurora-1: rgba(45, 212, 191, 0.22);
  --aurora-2: rgba(167, 139, 250, 0.25);
  --aurora-3: rgba(251, 191, 36, 0.14);
  --grid-line: rgba(15, 20, 30, 0.045);
  --grain-opacity: 0.04;
  --shadow: 0 30px 60px -34px rgba(30, 30, 60, 0.28);
  color-scheme: light;
}

/* =========================================================
   Base
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; overflow-x: clip; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  transition: background-color .4s, color .4s;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
strong { color: var(--text); font-weight: 600; }

:focus-visible { outline: 2px solid var(--a1); outline-offset: 3px; border-radius: 8px; }
::selection { background: var(--a2); color: #fff; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 16px; }
@media (min-width: 640px) { .container { padding: 0 28px; } }

.mono { font-family: var(--mono); }

.gradient-text, h2 em, .rotator__word {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

h2 em, .contact__title em {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.01em;
  padding-right: .06em;
}

.skip-link {
  position: absolute; left: 16px; top: -48px; z-index: 200;
  background: var(--a1); color: var(--on-grad);
  padding: 8px 14px; border-radius: 8px; font-weight: 600;
}
.skip-link:focus { top: 12px; }

/* =========================================================
   Background: aurora + grid + grain
   ========================================================= */
.bg { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.bg__aurora {
  position: absolute; border-radius: 50%;
  filter: blur(90px);
  will-change: transform;
}
.bg__aurora--1 { width: 55vw; height: 55vw; left: -12vw; top: -20vw; background: var(--aurora-1); animation: drift1 22s ease-in-out infinite alternate; }
.bg__aurora--2 { width: 50vw; height: 50vw; right: -14vw; top: -8vw; background: var(--aurora-2); animation: drift2 26s ease-in-out infinite alternate; }
.bg__aurora--3 { width: 40vw; height: 40vw; left: 30vw; top: 35vh; background: var(--aurora-3); animation: drift3 30s ease-in-out infinite alternate; }
@keyframes drift1 { to { transform: translate(10vw, 12vh) scale(1.15); } }
@keyframes drift2 { to { transform: translate(-12vw, 18vh) scale(.9); } }
@keyframes drift3 { to { transform: translate(-16vw, -10vh) scale(1.2); } }

.bg__grid {
  position: absolute; inset: 0;
  background:
    linear-gradient(var(--grid-line) 1px, transparent 1px) 0 0 / 64px 64px,
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px) 0 0 / 64px 64px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 75%);
}
.bg__grain {
  position: absolute; inset: -50%;
  opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

.progress {
  position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 120;
  background: var(--grad);
  transform: scaleX(0); transform-origin: 0 50%;
}

/* =========================================================
   Buttons & small components
   ========================================================= */
.btn {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 46px; padding: 0 22px;
  border-radius: 999px;
  font-weight: 600; font-size: 15px;
  border: 1px solid transparent;
  overflow: hidden; isolation: isolate;
  transition: transform .25s var(--ease), border-color .25s, box-shadow .3s, background-color .25s;
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .3s var(--ease); }
.btn:hover svg { transform: translate(2px, -2px); }

.btn--primary { background: var(--grad); color: var(--on-grad); box-shadow: 0 10px 30px -12px var(--a2); }
.btn--primary::after {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,.45) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform .7s var(--ease);
}
.btn--primary:hover::after { transform: translateX(120%); }
.btn--primary:hover { box-shadow: 0 16px 40px -12px var(--a2); }

.btn--ghost { background: var(--surface); border-color: var(--border-strong); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.btn--ghost:hover { border-color: var(--a1); }

.btn--sm { height: 38px; padding: 0 18px; font-size: 14px; }
.btn--lg { height: 52px; padding: 0 26px; }
.btn--xl { height: 60px; padding: 0 30px; font-size: 17px; }

.icon-btn {
  width: 40px; height: 40px;
  display: inline-grid; place-items: center;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  transition: border-color .2s, transform .3s var(--ease);
}
.icon-btn:hover { border-color: var(--border-strong); }
#theme-toggle:hover { transform: rotate(20deg); }
.icon-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }

.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px;
  color: var(--text-muted); background: var(--surface-2); border: 1px solid var(--border);
}
.badge--live { color: var(--a1); background: var(--a1-soft); border-color: transparent; }
.badge--live::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 0 currentColor; animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, currentColor 60%, transparent); } 70%, 100% { box-shadow: 0 0 0 7px transparent; } }

.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; }
.tags span {
  font-family: var(--mono); font-size: 12px;
  padding: 4px 10px; border-radius: 8px;
  background: var(--surface-2); color: var(--text-muted); border: 1px solid var(--border);
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: 13px; color: var(--a1);
  letter-spacing: .08em; text-transform: uppercase; margin-bottom: 16px;
}
.eyebrow::before { content: ''; width: 28px; height: 1px; background: var(--grad); }

/* Card with cursor spotlight + glowing border */
.glow-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  transition: transform .4s var(--ease), border-color .3s, box-shadow .4s;
}
.glow-card::before, .glow-card::after {
  content: ''; position: absolute; border-radius: inherit; pointer-events: none;
  opacity: 0; transition: opacity .4s;
}
.glow-card::before {
  inset: -1px; padding: 1px;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 0%), var(--a1), var(--a2) 40%, transparent 70%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}
.glow-card::after {
  inset: 0;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), var(--a2-soft), transparent 45%);
}
.glow-card:hover::before, .glow-card:hover::after { opacity: 1; }
.glow-card:hover { box-shadow: var(--shadow); }

/* =========================================================
   Navigation
   ========================================================= */
.nav { position: sticky; top: 0; z-index: 100; padding: 12px 0; transition: padding .3s var(--ease); }
.nav__inner {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  height: 60px; border-radius: 999px;
  border: 1px solid transparent;
  transition: background-color .3s, border-color .3s, padding .3s var(--ease), box-shadow .3s;
}
.nav.scrolled { padding: 10px 0; }
.nav.scrolled .nav__inner {
  max-width: calc(var(--container) - 40px);
  padding: 0 10px 0 14px;
  background: color-mix(in srgb, var(--surface-solid) 72%, transparent);
  backdrop-filter: saturate(160%) blur(18px); -webkit-backdrop-filter: saturate(160%) blur(18px);
  border-color: var(--border);
  box-shadow: var(--shadow);
}

.logo { display: flex; align-items: center; gap: 12px; font-weight: 700; }
.logo__mark {
  display: inline-flex; align-items: baseline;
  font-family: var(--mono); font-size: 21px; font-weight: 700; letter-spacing: -.04em; line-height: 1;
}
.logo__br {
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  transition: transform .45s var(--ease);
}
.logo__init { text-transform: lowercase; color: var(--text); padding: 0 1px; }
.logo__sl { display: inline-block; color: var(--a2); transition: transform .45s var(--ease), color .3s; }
.logo:hover .logo__br:first-child { transform: translateX(-3px); }
.logo:hover .logo__br:last-child { transform: translateX(3px); }
.logo:hover .logo__sl { transform: rotateY(180deg); color: var(--a1); }
.logo__text { font-family: var(--mono); font-size: 15px; font-weight: 500; }
.logo__caret { color: var(--a1); margin-left: 1px; opacity: 0; }
.logo:hover .logo__caret, .logo:focus-visible .logo__caret { opacity: 1; animation: blink 1.1s steps(1) infinite; }

.nav__links { display: flex; gap: 2px; }
.nav__links a {
  position: relative;
  padding: 8px 14px; border-radius: 999px;
  font-size: 14px; font-weight: 500; color: var(--text-muted);
  transition: color .2s, background-color .2s;
}
.nav__links a:hover { color: var(--text); }
.nav__links a.active { color: var(--text); background: var(--surface-2); }
.nav__links a.active::after {
  content: ''; position: absolute; left: 50%; bottom: 3px; width: 4px; height: 4px; margin-left: -2px;
  border-radius: 50%; background: var(--a1);
}

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

[data-theme='dark'] .i-moon, [data-theme='light'] .i-sun { display: none; }

.menu-btn { display: none; }

@media (max-width: 900px) {
  .menu-btn { display: inline-grid; }
  .nav__links {
    position: absolute; top: 78px; left: 16px; right: 16px;
    flex-direction: column; gap: 2px; padding: 10px;
    background: var(--surface-solid); border: 1px solid var(--border); border-radius: var(--radius);
    box-shadow: var(--shadow);
    opacity: 0; transform: translateY(-10px) scale(.98); pointer-events: none;
    transition: opacity .25s, transform .25s var(--ease);
  }
  .nav__links.open { opacity: 1; transform: none; pointer-events: auto; }
  .nav__links a { padding: 14px 16px; border-radius: 12px; font-size: 16px; }
  .nav__links a.active::after { display: none; }
}

@media (max-width: 520px) { .hide-sm { display: none !important; } }

/* =========================================================
   Hero
   ========================================================= */
.hero { padding: 40px 0 32px; }
@media (min-width: 960px) { .hero { padding: 72px 0 40px; } }

.hero__grid { display: grid; gap: 56px; align-items: center; }
@media (min-width: 1020px) { .hero__grid { grid-template-columns: 1.25fr 1fr; gap: 40px; } }

.status {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 6px 16px 6px 10px; border-radius: 999px;
  font-size: 13px; font-weight: 500; color: var(--text-muted);
  background: var(--surface); border: 1px solid var(--border);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  margin-bottom: 28px;
}
.status__dot { width: 8px; height: 8px; border-radius: 50%; background: var(--a1); position: relative; }
.status__dot::after {
  content: ''; position: absolute; inset: -4px; border-radius: 50%;
  border: 2px solid var(--a1); opacity: .5;
  animation: ping 1.8s cubic-bezier(0, 0, .2, 1) infinite;
}
@keyframes ping { 75%, 100% { transform: scale(1.9); opacity: 0; } }

.hero__hello { font-family: var(--display); font-size: clamp(1.05rem, 2vw, 1.3rem); color: var(--text-muted); margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.wave { display: inline-block; transform-origin: 70% 70%; animation: wave 2.6s ease-in-out infinite; }
@keyframes wave { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(14deg); } 20% { transform: rotate(-8deg); } 40% { transform: rotate(-4deg); } 50% { transform: rotate(10deg); } }

.hero__title {
  font-family: var(--display);
  font-size: clamp(2.6rem, 6.4vw, 5.2rem);
  line-height: 1.02;
  letter-spacing: -0.045em;
  font-weight: 700;
  margin-bottom: 26px;
}
.hero__title > span { display: block; }
.rotator { min-height: 1.04em; }
.rotator__word { font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: -0.02em; padding-right: .04em; }
.rotator__caret {
  display: inline-block; width: 3px; height: .82em; margin-left: 4px; vertical-align: -0.06em;
  background: var(--a1); border-radius: 2px; animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.hero__suffix { color: var(--text); }

.hero__lead { font-size: clamp(1.02rem, 2vw, 1.18rem); color: var(--text-muted); max-width: 560px; margin-bottom: 34px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 34px; }

.socials { display: flex; gap: 10px; }
.socials a {
  width: 44px; height: 44px; display: grid; place-items: center;
  border-radius: 14px; border: 1px solid var(--border); background: var(--surface);
  color: var(--text-muted); transition: color .2s, border-color .2s, transform .3s var(--ease), background-color .2s;
}
.socials a:hover { color: var(--on-grad); background: var(--a1); border-color: var(--a1); transform: translateY(-3px) rotate(-6deg); }
.socials svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* Hero visual: orbit + tilt card */
.hero__visual {
  position: relative;
  display: grid; place-items: center;
  min-height: 440px;
  perspective: 1200px;
}
.orbit { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; }
.orbit__ring {
  position: absolute; border-radius: 50%;
  border: 1px dashed var(--border-strong);
}
.orbit__ring--1 { width: min(520px, 112%); aspect-ratio: 1; animation: spin 80s linear infinite; }
.orbit__ring--2 { width: min(380px, 84%); aspect-ratio: 1; border-style: solid; border-color: var(--border); }
.orbit__chips { position: absolute; z-index: 2; width: 0; height: 0; left: 50%; top: 50%; animation: spin 50s linear infinite; }
.chip-orbit {
  --r: 250px;
  position: absolute; left: 0; top: 0;
  transform: rotate(calc(var(--i) * 360deg / var(--n))) translateX(var(--r)) rotate(calc(var(--i) * -360deg / var(--n)));
}
.chip-orbit > span {
  display: inline-block; translate: -50% -50%;
  animation: spin 50s linear infinite reverse;
  padding: 7px 14px; border-radius: 999px; white-space: nowrap;
  font-family: var(--mono); font-size: 12px; font-weight: 500;
  background: var(--surface-solid); border: 1px solid var(--border-strong);
  box-shadow: 0 10px 30px -14px rgba(0,0,0,.5);
}
.chip-orbit:nth-child(3n+1) > span { color: var(--a1); }
.chip-orbit:nth-child(3n+2) > span { color: var(--a2); }
.chip-orbit:nth-child(3n) > span { color: var(--a3); }
@keyframes spin { to { rotate: 360deg; } }
@media (max-width: 1019px) { .orbit__chips { display: none; } .hero__visual { min-height: 0; } .orbit__ring--1 { width: 120%; } }

.tilt {
  position: relative; z-index: 1;
  width: 100%; max-width: 380px;
  padding: 24px; border-radius: 26px;
  background: color-mix(in srgb, var(--surface-solid) 78%, transparent);
  border: 1px solid var(--border-strong);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow), 0 0 0 1px rgba(255,255,255,.02) inset;
  transform-style: preserve-3d;
  transition: transform .5s var(--ease);
  overflow: hidden;
}
.tilt::before {
  content: ''; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--grad);
}
.tilt__shine {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(300px circle at var(--sx, 30%) var(--sy, 0%), rgba(255,255,255,.09), transparent 60%);
}
.profile { display: flex; align-items: center; gap: 14px; padding-bottom: 18px; margin-bottom: 18px; border-bottom: 1px dashed var(--border-strong); }
.avatar-wrap { position: relative; flex: none; }
.avatar {
  width: 64px; height: 64px; border-radius: 18px;
  display: grid; place-items: center;
  font-family: var(--display); font-weight: 700; font-size: 22px; color: var(--on-grad);
  background: var(--grad);
}
.avatar--img { object-fit: cover; background: var(--surface-2); }
.avatar--mark {
  position: relative; overflow: hidden; isolation: isolate;
  background: var(--surface-solid); border: 1px solid var(--border-strong);
}
.avatar--mark::before {
  content: ''; position: absolute; z-index: -1; inset: 0;
  background: radial-gradient(circle at 30% 20%, var(--a1-soft), transparent 60%), radial-gradient(circle at 80% 90%, var(--a2-soft), transparent 60%);
}
.avatar--mark .logo__mark { font-size: 17px; }
.profile:hover .avatar--mark .logo__sl { transform: rotateY(180deg); color: var(--a1); }
.avatar__online {
  position: absolute; right: -3px; bottom: -3px; width: 16px; height: 16px; border-radius: 50%;
  background: #22c55e; border: 3px solid var(--surface-solid);
}
.profile__name { font-family: var(--display); font-weight: 700; font-size: 19px; letter-spacing: -.01em; }
.profile__role { color: var(--text-muted); font-size: 14px; }

.code {
  font-family: var(--mono); font-size: 13px; line-height: 1.8;
  color: var(--text-muted);
  white-space: pre-wrap; overflow-wrap: anywhere; word-break: normal;
}
.c-k { color: var(--a2); }
.c-v { color: var(--a3); }
.c-p { color: var(--text); }
.c-s { color: var(--a1); }
.tilt__foot {
  margin-top: 18px; padding-top: 14px; border-top: 1px dashed var(--border-strong);
  font-size: 12px; color: var(--text-faint);
}

/* Stats */
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-top: 64px; }
@media (min-width: 820px) { .stats { grid-template-columns: repeat(4, 1fr); gap: 16px; } }
.stat {
  padding: 22px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--border);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
}
.stat dt { font-size: 13px; color: var(--text-faint); margin-bottom: 6px; }
.stat dd {
  font-family: var(--display);
  font-size: clamp(1.5rem, 3.4vw, 2.2rem); font-weight: 700; letter-spacing: -.03em; line-height: 1.1;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* =========================================================
   Marquee
   ========================================================= */
.marquee { position: relative; padding: 48px 0 16px; overflow: hidden; }
.marquee__track {
  display: flex; width: max-content;
  animation: scroll 40s linear infinite;
}
.marquee__track--rev { animation-direction: reverse; animation-duration: 46s; margin-top: 6px; }
.marquee__item {
  display: inline-flex; align-items: center; gap: 28px; padding-right: 28px;
  font-family: var(--display); font-weight: 700; letter-spacing: -.03em;
  font-size: clamp(2rem, 5vw, 3.6rem); line-height: 1.2; white-space: nowrap;
  color: var(--text);
}
.marquee__track--rev .marquee__item { color: transparent; -webkit-text-stroke: 1px var(--border-strong); }
.marquee__item i { font-style: normal; font-size: .45em; color: var(--a1); -webkit-text-stroke: 0; }
.marquee::before, .marquee::after {
  content: ''; position: absolute; top: 0; bottom: 0; width: 12vw; z-index: 1; pointer-events: none;
}
.marquee::before { left: 0; background: linear-gradient(90deg, var(--bg), transparent); }
.marquee::after { right: 0; background: linear-gradient(-90deg, var(--bg), transparent); }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes scroll { to { transform: translateX(-50%); } }

/* =========================================================
   Sections
   ========================================================= */
.section { padding: 80px 0; position: relative; }
@media (min-width: 900px) { .section { padding: 120px 0; } }

.section__head { position: relative; margin-bottom: 48px; max-width: 760px; }
.section__head::before {
  content: attr(data-num);
  position: absolute; z-index: -1; right: 0; top: -0.45em;
  font-family: var(--display); font-weight: 700; line-height: 1;
  font-size: clamp(6rem, 16vw, 11rem); letter-spacing: -.06em;
  color: transparent; -webkit-text-stroke: 1px var(--border-strong);
  opacity: .7;
}
@media (min-width: 900px) { .section__head::before { right: auto; left: -0.08em; top: -0.55em; opacity: .5; } }
.section__head h2, .contact__title {
  font-family: var(--display);
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.06; letter-spacing: -0.04em; font-weight: 700;
}
.section__head h2 em { font-size: 1.08em; }

/* About */
.about { display: grid; gap: 40px; }
@media (min-width: 980px) {
  .about { grid-template-columns: minmax(0, .95fr) minmax(0, 1.3fr); gap: 72px; align-items: start; }
  .about__aside { position: sticky; top: 104px; }
}
.about .section__head { margin-bottom: 32px; }

/* Quick facts card */
.facts { padding: 8px 8px 16px; border-radius: 24px; }
.facts > * { position: relative; z-index: 1; }
.facts__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 14px 12px;
}
.facts__title { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--text-faint); }
.facts__list { display: grid; }
.fact {
  display: grid; grid-template-columns: 40px 1fr; column-gap: 14px; align-items: center;
  padding: 12px 14px; border-radius: 14px;
  transition: background-color .2s;
}
.fact:hover { background: var(--surface-2); }
.fact + .fact { border-top: 1px dashed var(--border); }
.fact:hover, .fact:hover + .fact { border-top-color: transparent; }
.fact__icon {
  grid-row: span 2;
  width: 40px; height: 40px; display: grid; place-items: center;
  border-radius: 12px; font-size: 18px;
  background: var(--surface-2); border: 1px solid var(--border);
}
.fact dt { font-size: 12px; color: var(--text-faint); line-height: 1.3; }
.fact dd { font-weight: 600; font-size: 15px; line-height: 1.4; }
.fact dd small { font-weight: 400; font-size: 12px; color: var(--text-faint); margin-left: 4px; font-family: var(--mono); }
.facts__cta { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px 14px 0; }
.facts__cta .btn { flex: 1 1 auto; }

/* Story text */
.about__text p { color: var(--text-muted); font-size: 17px; line-height: 1.75; margin-bottom: 20px; }
.about__text p.lead {
  font-family: var(--display);
  font-size: clamp(1.3rem, 2.6vw, 1.75rem); line-height: 1.45; letter-spacing: -.02em;
  color: var(--text); font-weight: 500;
  padding-left: 22px; border-left: 3px solid; border-image: var(--grad) 1;
  margin-bottom: 28px;
}
.about__text .hl {
  color: var(--text); font-weight: 600;
  background: linear-gradient(transparent 62%, var(--a2-soft) 62%, var(--a1-soft));
  padding: 0 2px; border-radius: 2px;
}
.about__text p.lead .hl {
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* "What I bring" cards */
.about__sub {
  display: flex; align-items: center; gap: 14px;
  font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase;
  color: var(--text-faint); margin: 40px 0 16px;
}
.about__sub::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.highlights { display: grid; gap: 14px; }
@media (min-width: 560px) { .highlights { grid-template-columns: repeat(2, 1fr); } }
.highlight { padding: 22px; border-radius: 20px; }
.highlight > * { position: relative; z-index: 1; }
.highlight:hover { transform: translateY(-4px); }
.highlight__icon {
  width: 46px; height: 46px; display: grid; place-items: center;
  border-radius: 14px; font-size: 21px; margin-bottom: 16px;
  background: linear-gradient(135deg, var(--a1-soft), var(--a2-soft));
  border: 1px solid var(--border);
  transition: transform .4s var(--ease);
}
.highlight:hover .highlight__icon { transform: rotate(-8deg) scale(1.08); }
.highlight h4 { font-family: var(--display); font-size: 1.08rem; font-weight: 600; letter-spacing: -.01em; margin-bottom: 6px; }
.highlight p { color: var(--text-muted); font-size: 14.5px; line-height: 1.6; }

/* Experience timeline */
.timeline-wrap { position: relative; padding-left: 36px; }
@media (min-width: 760px) { .timeline-wrap { padding-left: 56px; } }
.timeline-rail {
  position: absolute; left: 9px; top: 8px; bottom: 8px; width: 2px;
  background: var(--border); border-radius: 2px; overflow: hidden;
}
@media (min-width: 760px) { .timeline-rail { left: 19px; } }
.timeline-rail__fill {
  position: absolute; inset: 0; background: linear-gradient(var(--a1), var(--a2), var(--a3));
  transform: scaleY(0); transform-origin: top;
}
.timeline { display: grid; gap: 20px; }
.job { position: relative; }
.job__dot {
  position: absolute; left: -36px; top: 28px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--border-strong);
  display: grid; place-items: center;
}
@media (min-width: 760px) { .job__dot { left: -46px; } }
.job__dot::after { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--text-faint); }
.job--current .job__dot { border-color: var(--a1); box-shadow: 0 0 0 6px var(--a1-soft), 0 0 24px var(--a1); }
.job--current .job__dot::after { background: var(--a1); }

.job__card { padding: 24px; }
@media (min-width: 760px) { .job__card { padding: 30px 34px; } }
.job__card:hover { transform: translateY(-3px); }
.job__meta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.job__date { font-family: var(--mono); font-size: 13px; color: var(--text-faint); }
.job h3 { font-family: var(--display); font-size: clamp(1.2rem, 2.4vw, 1.5rem); letter-spacing: -.02em; }
.job__company { color: var(--a1); font-weight: 500; font-size: 15px; margin-top: 2px; }
.job ul { margin-top: 16px; display: grid; gap: 10px; }
.job ul li { position: relative; padding-left: 22px; color: var(--text-muted); font-size: 15px; }
.job ul li::before {
  content: ''; position: absolute; left: 0; top: .62em;
  width: 10px; height: 2px; background: var(--grad); border-radius: 2px;
}

/* Projects bento */
.section__note {
  display: flex; align-items: flex-start; gap: 10px;
  max-width: 680px; margin: -24px 0 32px;
  padding: 12px 16px; border-radius: 14px;
  font-size: 14px; color: var(--text-muted);
  background: var(--surface); border: 1px dashed var(--border-strong);
}
.badge--nda { color: var(--a2); background: var(--a2-soft); border-color: transparent; }
.badge--nda::before { content: '🔒'; font-size: 10px; }

.bento { display: grid; gap: 18px; grid-template-columns: 1fr; grid-auto-flow: dense; }
@media (min-width: 700px) { .bento { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .bento { grid-template-columns: repeat(3, 1fr); } }

.card { display: flex; flex-direction: column; padding: 26px; min-height: 240px; overflow: hidden; }
.card:hover { transform: translateY(-6px); }
.card > * { position: relative; z-index: 1; }
.card--feature {
  background:
    radial-gradient(500px circle at 110% -10%, var(--a2-soft), transparent 55%),
    radial-gradient(400px circle at -10% 110%, var(--a1-soft), transparent 55%),
    var(--surface);
}
@media (min-width: 700px) { .card--feature { grid-column: span 2; } }
@media (min-width: 1040px) { .card--feature { grid-row: span 2; } }
.card--feature h3 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
.card--feature p { font-size: 17px; max-width: 520px; }

.card__top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 22px; }
.card__top-right { display: flex; align-items: center; gap: 8px; }
.card__icon {
  width: 50px; height: 50px; display: grid; place-items: center;
  font-size: 24px; border-radius: 15px;
  background: var(--surface-2); border: 1px solid var(--border);
  transition: transform .5s var(--ease);
}
.card:hover .card__icon { transform: rotate(-10deg) scale(1.08); }
.card__index {
  position: absolute !important; right: 18px; bottom: 6px; z-index: 0 !important;
  font-family: var(--display); font-weight: 700; font-size: 5.5rem; line-height: 1; letter-spacing: -.05em;
  color: transparent; -webkit-text-stroke: 1px var(--border);
  transition: -webkit-text-stroke-color .4s;
}
.card--feature .card__index { font-size: 9rem; }
.card:hover .card__index { -webkit-text-stroke-color: var(--border-strong); }
.card h3 { font-family: var(--display); font-size: 1.3rem; letter-spacing: -.02em; margin-bottom: 8px; line-height: 1.2; }
.card p { color: var(--text-muted); font-size: 15px; }
.card__points { margin-top: 18px; display: grid; gap: 10px; }
.card__points li { position: relative; padding-left: 24px; font-size: 15px; color: var(--text-muted); }
.card__points li::before { content: '↗'; position: absolute; left: 0; color: var(--a1); font-weight: 700; }
.card .tags { margin-top: auto; padding-top: 22px; }
.card .tags span { background: var(--surface-solid); }
.card__link {
  width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%;
  border: 1px solid var(--border-strong); transition: background-color .2s, color .2s, transform .3s var(--ease);
}
.card__link svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.card__link:hover { background: var(--a1); color: var(--on-grad); transform: rotate(45deg); }

/* Skills — each group is an atom: symbol as nucleus, tools orbiting as electrons */
.atoms { display: grid; gap: 18px; }
@media (min-width: 700px) {
  .atoms { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .atom-card--feature { grid-column: 1 / -1; }
}
@media (min-width: 1040px) {
  .atoms { grid-template-columns: 1.2fr 1fr 1fr; }
  .atom-card--feature { grid-column: 1; grid-row: span 2; }
}

.atom-card {
  --hue: var(--a1);
  --size: 200px; --orb: 36px;
  position: relative; isolation: isolate; overflow: hidden;
  display: flex; flex-direction: column; padding: 22px 24px 24px;
  border-radius: var(--radius);
  background:
    radial-gradient(90% 60% at 50% 0%, color-mix(in srgb, var(--hue) 16%, transparent), transparent 70%),
    var(--surface);
  border: 1px solid color-mix(in srgb, var(--hue) 26%, var(--border));
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  transition: transform .4s var(--ease), border-color .3s, box-shadow .4s;
}
.atom-card:hover {
  transform: translateY(-5px);
  border-color: color-mix(in srgb, var(--hue) 60%, transparent);
  box-shadow: 0 30px 60px -34px var(--hue);
}
.js .atom-card.reveal.in { transition: opacity .9s var(--ease), transform .4s var(--ease), filter .9s var(--ease), border-color .3s, box-shadow .4s; }
.atom-card__head { display: flex; justify-content: space-between; font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--text-faint); }

/* The atom */
.atom { position: relative; width: var(--size); aspect-ratio: 1; margin: 14px auto 22px; flex: none; }
.atom::before {
  /* soft glow behind the nucleus */
  content: ''; position: absolute; inset: 22%; border-radius: 50%;
  background: var(--hue); opacity: .18; filter: blur(30px);
}
.atom__core {
  position: absolute; left: 50%; top: 50%; z-index: 2;
  width: calc(var(--size) * .3); aspect-ratio: 1; transform: translate(-50%, -50%);
  display: grid; place-items: center; align-content: center; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, color-mix(in srgb, var(--hue) 40%, var(--surface-solid)), var(--surface-solid) 75%);
  border: 1px solid color-mix(in srgb, var(--hue) 60%, transparent);
  box-shadow: 0 0 0 6px color-mix(in srgb, var(--hue) 8%, transparent), 0 0 34px -4px var(--hue);
  animation: pulse 3.2s ease-in-out infinite;
}
.atom__num { font-size: calc(var(--size) * .045); color: var(--text-faint); line-height: 1; }
.atom__sym {
  font-family: var(--display); font-weight: 700; letter-spacing: -.05em; line-height: 1;
  font-size: calc(var(--size) * .13); color: var(--hue);
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--hue) 8%, transparent), 0 0 34px -4px var(--hue); }
  50% { box-shadow: 0 0 0 12px color-mix(in srgb, var(--hue) 4%, transparent), 0 0 46px 0 var(--hue); }
}

.ring {
  --r: calc(var(--size) * .3); --t: 26s;
  position: absolute; left: 50%; top: 50%; width: calc(var(--r) * 2); height: calc(var(--r) * 2);
  margin: calc(var(--r) * -1) 0 0 calc(var(--r) * -1);
  border-radius: 50%; border: 1px dashed color-mix(in srgb, var(--hue) 38%, transparent);
  animation: spin var(--t) linear infinite;
}
.ring--2 { --r: calc(var(--size) * .46); --t: 40s; animation-direction: reverse; border-style: solid; border-color: color-mix(in srgb, var(--hue) 18%, transparent); }
.orb {
  position: absolute; left: 50%; top: 50%; z-index: 1;
  transform: translate(-50%, -50%) rotate(var(--a)) translateY(calc(var(--r) * -1)) rotate(calc(var(--a) * -1));
}
/* counter-spin keeps logos upright while the ring turns */
.orb__in {
  width: var(--orb); height: var(--orb); display: grid; place-items: center; border-radius: 50%;
  background: #fff; box-shadow: 0 6px 16px -6px rgba(0, 0, 0, .5), 0 0 0 2px color-mix(in srgb, var(--hue) 45%, transparent);
  animation: spin var(--t) linear infinite reverse;
  transition: scale .3s var(--ease), box-shadow .3s;
}
.ring--2 .orb__in { animation-direction: normal; }
.orb__in img { width: 58%; height: 58%; object-fit: contain; }
.orb__in .skill__glyph { font-size: calc(var(--orb) * .48); }
.orb__in .skill__glyph--sm { font-size: calc(var(--orb) * .3); }
.orb.is-hot .orb__in { scale: 1.35; box-shadow: 0 0 0 3px var(--hue), 0 0 24px var(--hue); }
.atom-card:hover .ring, .atom-card:hover .orb__in { animation-play-state: paused; }

/* Text */
.atom-card__body { display: flex; flex-direction: column; flex: 1; }
.atom-card__title { font-family: var(--display); font-size: 1.3rem; font-weight: 700; letter-spacing: -.025em; }
.atom-card__desc { color: var(--text-muted); font-size: 14.5px; line-height: 1.55; margin: 6px 0 16px; }
.atom-card__tools { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; }
.atom-card__tools li {
  display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px;
  font-size: 12.5px; font-weight: 500; color: var(--text-muted); cursor: default;
  background: var(--surface-2); border: 1px solid var(--border);
  transition: color .2s, border-color .2s, background-color .2s;
}
.atom-card__tools li::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--hue); }
.atom-card__tools li:hover { color: var(--text); border-color: var(--hue); background: color-mix(in srgb, var(--hue) 12%, transparent); }

/* Feature card (AI Agents) gets the big atom */
.atom-card--feature { --size: 300px; --orb: 44px; }
.atom-card--feature .atom-card__title { font-size: clamp(1.5rem, 2.6vw, 1.9rem); }
@media (min-width: 700px) and (max-width: 1039px) {
  .atom-card--feature { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 32px; align-items: center; }
  .atom-card--feature .atom-card__head { grid-column: 1 / -1; }
  .atom-card--feature .atom { --size: 260px; margin: 10px 0; }
}
@media (min-width: 1040px) {
  .atom-card--feature { --size: 360px; --orb: 48px; }
  .atom-card--feature .atom { margin: auto auto 40px; }
  .atom-card--feature .atom-card__body { flex: none; margin-bottom: auto; }
  .atom-card--feature .atom-card__desc { font-size: 15.5px; }
}
@media (max-width: 420px) {
  .atom-card--feature { --size: 250px; --orb: 38px; }
  .atom-card { padding: 20px 18px 20px; }
}

.skill__glyph { line-height: 1; font-weight: 700; color: #3b2a7a; font-family: var(--display); }
.skill__glyph--sm { letter-spacing: .02em; color: #a30000; }

/* Services */
.section__lede { margin-top: 16px; color: var(--text-muted); font-size: 16.5px; max-width: 560px; }
.services { display: grid; gap: 18px; }
@media (min-width: 880px) { .services { grid-template-columns: repeat(3, 1fr); } }
.service { padding: 14px 14px 24px; overflow: hidden; display: flex; flex-direction: column; }
.service > * { position: relative; z-index: 1; }
.service > :not(.service__scene) { margin-left: 12px; margin-right: 12px; }
.service:hover { transform: translateY(-6px); }

.service__scene {
  height: 168px; margin-bottom: 22px; border-radius: 16px; overflow: hidden;
  background:
    radial-gradient(circle at 1px 1px, var(--grid-line) 1px, transparent 0) 0 0 / 14px 14px,
    var(--surface-2);
  border: 1px solid var(--border);
}
.service__head { display: flex; align-items: baseline; gap: 12px; }
.service__num {
  font-family: var(--mono); font-size: 13px; font-weight: 600; color: transparent;
  background: var(--grad); -webkit-background-clip: text; background-clip: text;
}
.service h3 { font-family: var(--display); font-size: 1.35rem; margin: 0 0 10px; letter-spacing: -.02em; }
.service > p { color: var(--text-muted); font-size: 15px; }

.service__gets { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; }
.service__gets li {
  font-size: 12.5px; padding: 4px 10px; border-radius: 999px;
  border: 1px solid var(--border-strong); color: var(--text);
  background: var(--surface-2);
}
.service__gets li::before { content: '✓ '; color: var(--a1); }
.service > .service__fit { margin-top: 16px; font-size: 13.5px; }
.service__fit span {
  display: block; margin-bottom: 2px; font-family: var(--mono); font-size: 11px;
  letter-spacing: .08em; text-transform: uppercase; color: var(--text-faint);
}
.service__cta {
  margin-top: auto; padding-top: 22px; align-self: flex-start;
  font-weight: 600; font-size: 15px; color: var(--text); text-decoration: none;
}
.service__cta span { display: inline-block; transition: transform .35s var(--ease); color: var(--a1); }
.service__cta:hover, .service__cta:focus-visible { color: var(--a1); }
.service:hover .service__cta span { transform: translateX(6px); }

/* Scene: shared */
.scene { position: relative; height: 100%; padding: 16px; display: flex; flex-direction: column; justify-content: center; }

/* Scene: AI chat */
.scene--ai { display: grid; grid-template-areas: 'u' 'b'; align-content: center; gap: 8px; --loop: 7s; }
.scene--ai .bubble--user { grid-area: u; }
.scene--ai .bubble--bot, .scene--ai .bubble--typing { grid-area: b; align-self: start; justify-self: start; }
.bubble {
  max-width: 85%; padding: 8px 12px; border-radius: 14px; font-size: 12.5px; line-height: 1.4;
  animation: var(--loop) var(--ease) infinite both;
}
.bubble--user {
  justify-self: end; background: var(--grad); color: var(--on-grad); border-bottom-right-radius: 4px;
  animation-name: bubble-user;
}
.bubble--bot, .bubble--typing {
  align-self: flex-start; background: var(--surface-solid); border: 1px solid var(--border-strong);
  border-bottom-left-radius: 4px; color: var(--text);
}
.bubble--bot { animation-name: bubble-bot; }
.bubble__src {
  display: inline-block; margin-top: 6px; font-family: var(--mono); font-size: 10.5px;
  padding: 2px 7px; border-radius: 6px; color: var(--a2); background: var(--a2-soft);
}
.bubble--typing { display: flex; gap: 4px; padding: 11px 12px; animation-name: bubble-typing; opacity: 0; }
.bubble--typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--text-faint); animation: typing 1s infinite; }
.bubble--typing i:nth-child(2) { animation-delay: .15s; }
.bubble--typing i:nth-child(3) { animation-delay: .3s; }
@keyframes bubble-user { 0% { opacity: 0; transform: translateY(10px); } 8%, 92% { opacity: 1; transform: none; } 100% { opacity: 0; } }
@keyframes bubble-typing { 0%, 14% { opacity: 0; } 18%, 38% { opacity: 1; } 42%, 100% { opacity: 0; } }
@keyframes bubble-bot { 0%, 40% { opacity: 0; transform: translateY(10px); } 48%, 92% { opacity: 1; transform: none; } 100% { opacity: 0; } }
@keyframes typing { 0%, 60%, 100% { transform: none; opacity: .5; } 30% { transform: translateY(-4px); opacity: 1; } }

/* Scene: web app */
.scene--web { padding: 16px 16px 0; justify-content: flex-end; }
.browser {
  height: 100%; border-radius: 10px 10px 0 0; overflow: hidden;
  background: var(--surface-solid); border: 1px solid var(--border-strong); border-bottom: 0;
  display: flex; flex-direction: column;
  transition: transform .5s var(--ease);
}
.service:hover .browser { transform: translateY(-4px); }
.browser__bar { display: flex; align-items: center; gap: 5px; padding: 8px 10px; border-bottom: 1px solid var(--border); }
.browser__bar i { width: 7px; height: 7px; border-radius: 50%; background: var(--border-strong); }
.browser__bar i:first-child { background: #f87171; } .browser__bar i:nth-child(2) { background: #fbbf24; } .browser__bar i:nth-child(3) { background: #34d399; }
.browser__bar span {
  margin-left: 8px; flex: 1; min-width: 0; font-family: var(--mono); font-size: 10px; color: var(--text-faint);
  padding: 2px 8px; border-radius: 6px; background: var(--surface-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.browser__body { flex: 1; display: flex; gap: 10px; padding: 10px; min-height: 0; }
.browser__side { width: 22%; display: grid; align-content: start; gap: 7px; }
.browser__side b { height: 6px; border-radius: 3px; background: var(--border-strong); }
.browser__side b:first-child { background: var(--a1); width: 80%; }
.browser__main { flex: 1; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.browser__kpi { display: flex; justify-content: space-between; align-items: baseline; font-size: 10.5px; color: var(--text-faint); }
.browser__kpi strong { font-family: var(--display); font-size: 15px; color: var(--a1); }
.browser__chart { flex: 1; display: flex; align-items: flex-end; gap: 6px; border-bottom: 1px solid var(--border); }
.browser__chart b {
  flex: 1; height: var(--h); border-radius: 4px 4px 0 0; background: var(--grad); background-size: 100% 260%;
  transform-origin: bottom; animation: bar-grow 4s var(--ease) infinite both; animation-delay: calc(var(--k) * 120ms);
}
@keyframes bar-grow { 0% { transform: scaleY(.08); } 25%, 85% { transform: scaleY(1); } 100% { transform: scaleY(.08); } }

/* Scene: cloud pipeline */
.scene--cloud { gap: 18px; }
.pipe { position: relative; display: flex; justify-content: space-between; align-items: center; }
.pipe::before {
  content: ''; position: absolute; left: 20px; right: 20px; top: 50%; height: 2px; z-index: 0;
  background: repeating-linear-gradient(90deg, var(--border-strong) 0 6px, transparent 6px 11px);
}
.pipe__node {
  position: relative; z-index: 1; min-width: 44px; height: 44px; padding: 0 8px; border-radius: 12px;
  display: grid; place-items: center; font-family: var(--mono); font-size: 11.5px; font-weight: 600;
  background: var(--surface-solid); border: 1px solid var(--border-strong); color: var(--text);
  animation: node-hit 3s infinite; animation-delay: calc(var(--n, 0) * 0.75s);
}
.pipe__node:nth-child(2) { --n: 1; } .pipe__node:nth-child(3) { --n: 2; font-size: 16px; } .pipe__node:nth-child(4) { --n: 3; }
.pipe__packet {
  position: absolute; z-index: 2; top: 50%; left: 20px; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%;
  background: var(--a1); box-shadow: 0 0 12px 3px var(--a1);
  animation: packet 3s linear infinite;
}
@keyframes packet { 0% { left: 20px; opacity: 0; } 8% { opacity: 1; } 92% { opacity: 1; } 100% { left: calc(100% - 30px); opacity: 0; } }
@keyframes node-hit { 0%, 12%, 100% { border-color: var(--border-strong); box-shadow: none; } 4% { border-color: var(--a1); box-shadow: 0 0 0 4px var(--a1-soft); } }
.pipe__log {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-family: var(--mono); font-size: 11px; color: var(--text-muted);
  padding: 8px 10px; border-radius: 10px; background: var(--surface-solid); border: 1px solid var(--border);
}
.pipe__ok { color: var(--a1); font-weight: 600; }
.pipe__deploy { margin-left: auto; color: var(--a1); }

/* Process strip */
.process {
  list-style: none; position: relative; margin-top: 56px;
  display: grid; gap: 22px; grid-template-columns: 1fr;
}
@media (min-width: 720px) { .process { grid-template-columns: repeat(4, 1fr); gap: 24px; } }
.process::before {
  content: ''; position: absolute; left: 17px; top: 18px; bottom: 18px; width: 2px;
  background: var(--grad); opacity: .45; border-radius: 2px;
}
@media (min-width: 720px) { .process::before { left: 18px; right: 18px; top: 17px; bottom: auto; width: auto; height: 2px; } }
.process__step { position: relative; padding-left: 54px; }
@media (min-width: 720px) { .process__step { padding-left: 0; padding-top: 52px; } }
.process__dot {
  position: absolute; left: 0; top: 0; width: 36px; height: 36px; border-radius: 50%;
  display: grid; place-items: center; font-family: var(--mono); font-size: 13px; font-weight: 600;
  background: var(--bg); border: 1px solid var(--border-strong); color: var(--text);
  transition: background .3s, color .3s, border-color .3s;
}
.process__step:hover .process__dot { background: var(--grad); color: var(--on-grad); border-color: transparent; }
.process__step h4 { font-family: var(--display); font-size: 1.05rem; letter-spacing: -.01em; margin-bottom: 4px; }
.process__step p { color: var(--text-muted); font-size: 14px; }

/* Contact */
.contact {
  position: relative; overflow: hidden; isolation: isolate;
  display: grid; gap: 40px; align-items: center;
  padding: 48px 20px 20px; border-radius: 32px;
  background: var(--surface-solid);
  border: 1px solid var(--border);
}
@media (min-width: 760px) { .contact { padding: 64px 48px; } }
@media (min-width: 1000px) { .contact { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 56px; padding: 72px 56px; } }
.contact::before {
  content: ''; position: absolute; z-index: -2; inset: -60%;
  background: conic-gradient(from 0deg, transparent 0 70%, var(--a1), var(--a2), var(--a3), transparent);
  animation: spin 9s linear infinite;
  opacity: .5; filter: blur(50px);
}
.contact::after {
  content: ''; position: absolute; z-index: -1; inset: 1px; border-radius: 31px;
  background:
    radial-gradient(500px circle at var(--mx, 30%) var(--my, 0%), var(--a2-soft), transparent 60%),
    var(--surface-solid);
}
.contact__title { font-size: clamp(2.4rem, 6vw, 4.6rem); line-height: 1; letter-spacing: -.05em; }
.contact__title em {
  display: block;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.contact__intro > p { color: var(--text-muted); max-width: 480px; margin: 22px 0 28px; font-size: 17px; }

.contact__meta { list-style: none; display: grid; gap: 0; border-top: 1px solid var(--border); }
.contact__meta li {
  display: grid; grid-template-columns: 92px 1fr; gap: 12px; align-items: baseline;
  padding: 12px 0; border-bottom: 1px solid var(--border); font-size: 15px; color: var(--text);
}
.contact__key { font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--text-faint); }
.contact__live { display: inline-flex; align-items: center; gap: 8px; color: var(--a1); }
.contact__live::before {
  content: ''; flex: none; width: 7px; height: 7px; border-radius: 50%; background: currentColor;
  animation: pulse 2s infinite;
}
#contact-clock { font-family: var(--mono); font-weight: 600; }
#contact-mood { color: var(--text-muted); }

.contact__links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.contact__links a {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: 999px; border: 1px solid var(--border);
  color: var(--text-muted); font-weight: 500; font-size: 15px;
  transition: color .2s, border-color .2s;
}
.contact__links svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform .3s var(--ease); }
.contact__links a:hover { color: var(--text); border-color: var(--a1); }
.contact__links a:hover svg { transform: translate(2px, -2px); }

.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; }

/* Composer */
.composer {
  position: relative; min-width: 0;
  border-radius: 20px; overflow: hidden;
  background: var(--surface); border: 1px solid var(--border-strong);
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  transform: rotate(1.2deg);
  transition: transform .5s var(--ease);
}
.composer:hover, .composer:focus-within { transform: none; }
@media (max-width: 999px) { .composer { transform: none; } }
.composer__bar {
  display: flex; align-items: center; gap: 6px; padding: 12px 16px;
  border-bottom: 1px solid var(--border); background: var(--surface-2);
}
.composer__bar i { width: 10px; height: 10px; border-radius: 50%; }
.composer__bar i:nth-child(1) { background: #f87171; } .composer__bar i:nth-child(2) { background: #fbbf24; } .composer__bar i:nth-child(3) { background: #34d399; }
.composer__bar span { margin-left: 10px; font-size: 13px; font-weight: 600; color: var(--text-muted); }

.composer__row {
  display: flex; align-items: center; gap: 12px; min-width: 0;
  padding: 11px 20px; border-bottom: 1px solid var(--border); font-size: 14.5px;
}
.composer__label { flex: none; width: 58px; color: var(--text-faint); font-size: 13px; }
.composer__to {
  display: inline-flex; align-items: center; gap: 8px; min-width: 0;
  padding: 3px 4px 3px 10px; border-radius: 999px; border: 1px solid var(--border-strong);
  background: var(--a1-soft); color: var(--text); font: inherit; font-size: 14px; cursor: pointer;
  transition: border-color .2s;
}
.composer__to > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.composer__to small {
  flex: none; font-family: var(--mono); font-size: 10.5px; text-transform: uppercase; letter-spacing: .06em;
  padding: 2px 8px; border-radius: 999px; background: var(--surface-solid); color: var(--text-muted);
}
.composer__to:hover { border-color: var(--a1); }
.composer__body { padding: 16px 20px 0; }
.composer textarea {
  display: block; width: 100%; resize: vertical; min-height: 150px; padding: 14px 16px; border-radius: 14px;
  border: 1px solid var(--border-strong); background: var(--surface-2); color: var(--text);
  font: inherit; font-size: 16px; line-height: 1.6;
  transition: border-color .2s, box-shadow .2s;
}
.composer textarea::placeholder { color: var(--text-faint); }
.composer textarea:focus { outline: none; border-color: var(--a1); box-shadow: 0 0 0 4px var(--a1-soft); }

.composer__starters {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 14px;
  transition: opacity .3s;
}
.composer__starters > span { font-size: 13px; color: var(--text-faint); margin-right: 2px; }
.composer__starters.is-muted { opacity: .35; pointer-events: none; }
.starter {
  padding: 6px 12px; border-radius: 999px; font: inherit; font-size: 13px; cursor: pointer;
  border: 1px dashed var(--border-strong); background: transparent; color: var(--text-muted);
  transition: color .2s, border-color .2s, background .2s;
}
.starter:hover { color: var(--text); border-color: var(--a1); border-style: solid; }
.starter.is-on { color: var(--a1); border-color: var(--a1); border-style: solid; background: var(--a1-soft); }
.starter:focus-visible { outline: 2px solid var(--a1); outline-offset: 2px; }

.composer__foot {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px;
  padding: 18px 20px 20px;
}
.composer__hint { font-size: 12.5px; color: var(--text-faint); }
.composer__send { flex: none; }
.composer__send svg { transition: transform .4s var(--ease); }
.composer:not(.is-ready) .composer__send { filter: saturate(.6); }
.composer.is-ready .composer__send svg { animation: nudge 1.6s var(--ease) infinite; }
.composer.is-sent .composer__send svg { animation: fly .9s var(--ease) both; }
@keyframes nudge { 0%, 60%, 100% { transform: none; } 30% { transform: translate(3px, -3px); } }
@keyframes fly { 0% { transform: none; opacity: 1; } 60% { transform: translate(40px, -40px) rotate(12deg); opacity: 0; } 61% { transform: translate(-24px, 24px); opacity: 0; } 100% { transform: none; opacity: 1; } }
@media (max-width: 480px) {
  .composer__send { width: 100%; }
  .composer__row, .composer__body, .composer__foot { padding-left: 16px; padding-right: 16px; }
}

/* Footer */
.footer { padding: 40px 0 28px; overflow: hidden; }
.footer__big {
  font-family: var(--display); font-weight: 700; letter-spacing: -.06em; line-height: .85;
  font-size: clamp(3.4rem, 15vw, 13rem); white-space: nowrap; text-align: center;
  background: linear-gradient(180deg, var(--border-strong), transparent 90%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  user-select: none; margin-bottom: 28px;
}
.footer__inner {
  display: flex; flex-wrap: wrap; gap: 12px 24px; justify-content: space-between; align-items: center;
  padding-top: 22px; border-top: 1px solid var(--border);
  font-size: 14px; color: var(--text-faint);
}
.footer a:hover { color: var(--text); }

/* Toast */
.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 150;
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  padding: 12px 20px; border-radius: 999px;
  background: var(--grad); color: var(--on-grad); font-size: 14px; font-weight: 600;
  box-shadow: var(--shadow);
  transition: opacity .3s, transform .3s var(--ease);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* =========================================================
   Reveal animation
   ========================================================= */
.js .reveal {
  opacity: 0; transform: translateY(26px); filter: blur(6px);
  transition: opacity .9s var(--ease), transform .9s var(--ease), filter .9s var(--ease);
  transition-delay: var(--d, 0ms);
}
.js .reveal.in { opacity: 1; transform: none; filter: none; }
/* Cards keep their own hover transitions once revealed */
.js .glow-card.reveal.in { transition: opacity .9s var(--ease), transform .4s var(--ease), filter .9s var(--ease), border-color .3s, box-shadow .4s; transition-delay: 0ms; }

/* Let grid/flex children shrink on narrow screens */
.hero__grid > *, .about > *, .highlights > *, .bento > *, .atoms > *, .services > *, .timeline > * { min-width: 0; }
.hero__title, .section__head h2, .contact__title { overflow-wrap: anywhere; }

/* Sections scrolled out of view stop their looping animations (toggled from main.js) */
.is-idle *, .is-idle *::before, .is-idle *::after { animation-play-state: paused !important; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; filter: none; }
}
