/* ==========================================================================
   Shubhangi Jain — Portfolio
   Layout: dev-console HUD. Asymmetric, left-aligned sections on an ink canvas,
   mono "~/path" eyebrows, fixed corner brackets, one orchestrated hero moment.
   Dark-first; light theme mirrors every token.
   ========================================================================== */

:root {
  /* Color */
  --bg: #0c0b12;
  --bg-2: #121119;
  --surface: #17161f;
  --surface-2: #1f1d2a;
  --line: rgba(232, 228, 255, 0.09);
  --line-2: rgba(232, 228, 255, 0.17);
  --fg: #eeebf7;
  --fg-2: #aba7bd;
  --fg-3: #7a768e;
  --accent: #f5b342;          /* saffron */
  --accent-2: #ee7e2e;        /* ember */
  --accent-rgb: 245, 179, 66;
  --violet: #a797ff;
  --violet-rgb: 167, 151, 255;
  --sky: #7dd3fc;
  --ok: #5fe3a1;
  --on-accent: #1a1206;
  --glass: rgba(18, 17, 26, 0.66);
  --scrim: rgba(8, 7, 12, 0.78);
  --shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.7);
  --mono-filter: invert(1) brightness(1.7);
  --grain-opacity: 0.06;
  --dot-r: #ff5f57;
  --dot-y: #febc2e;
  --dot-g: #28c840;

  /* Type */
  --f-display: "Bricolage Grotesque", "Segoe UI", system-ui, -apple-system, sans-serif;
  --f-body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --t-xs: 0.75rem;
  --t-sm: 0.875rem;
  --t-base: 1.0625rem;
  --t-md: 1.1875rem;
  --t-lg: clamp(1.35rem, 1.1rem + 1vw, 1.85rem);
  --t-xl: clamp(2.1rem, 1.4rem + 2.8vw, 3.6rem);
  --t-2xl: clamp(3rem, 1.6rem + 6vw, 6.4rem);

  /* Shape & motion */
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 22px;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --gutter: clamp(16px, 4vw, 40px);
  --maxw: 1200px;
  color-scheme: dark;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f5f4f9;
    --bg-2: #edecf3;
    --surface: #ffffff;
    --surface-2: #f6f5fa;
    --line: rgba(24, 20, 48, 0.1);
    --line-2: rgba(24, 20, 48, 0.18);
    --fg: #16141f;
    --fg-2: #4a465c;
    --fg-3: #77738a;
    --accent: #b46600;
    --accent-2: #c2410c;
    --accent-rgb: 180, 102, 0;
    --violet: #5a46d4;
    --violet-rgb: 90, 70, 212;
    --sky: #0369a1;
    --ok: #12804b;
    --on-accent: #ffffff;
    --glass: rgba(255, 255, 255, 0.74);
    --scrim: rgba(22, 20, 31, 0.55);
    --shadow: 0 24px 50px -26px rgba(30, 20, 60, 0.28);
    --mono-filter: none;
    --grain-opacity: 0.035;
    color-scheme: light;
  }
}

:root[data-theme="light"] {
  --bg: #f5f4f9;
  --bg-2: #edecf3;
  --surface: #ffffff;
  --surface-2: #f6f5fa;
  --line: rgba(24, 20, 48, 0.1);
  --line-2: rgba(24, 20, 48, 0.18);
  --fg: #16141f;
  --fg-2: #4a465c;
  --fg-3: #77738a;
  --accent: #b46600;
  --accent-2: #c2410c;
  --accent-rgb: 180, 102, 0;
  --violet: #5a46d4;
  --violet-rgb: 90, 70, 212;
  --sky: #0369a1;
  --ok: #12804b;
  --on-accent: #ffffff;
  --glass: rgba(255, 255, 255, 0.74);
  --scrim: rgba(22, 20, 31, 0.55);
  --shadow: 0 24px 50px -26px rgba(30, 20, 60, 0.28);
  --mono-filter: none;
  --grain-opacity: 0.035;
  color-scheme: light;
}

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

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

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

[hidden] { display: none !important; }
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; }
::selection { background: rgba(var(--accent-rgb), 0.35); color: var(--fg); }

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

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 300;
  padding: 10px 16px;
  border-radius: var(--r-sm);
  background: var(--accent);
  color: var(--on-accent);
  font-family: var(--f-mono);
  font-size: var(--t-sm);
  text-decoration: none;
  transition: top 0.2s;
}
.skip-link:focus { top: 16px; }

.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0);
  white-space: nowrap; border: 0;
}

.wrap {
  width: 100%;
  max-width: calc(var(--maxw) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  position: relative;
  padding-block: clamp(80px, 11vw, 150px);
}

.section--alt {
  background: var(--bg-2);
  border-block: 1px solid var(--line);
}

.section--grid::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 20%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 20%, transparent 75%);
  opacity: 0.55;
}

.section > .wrap { position: relative; }

/* ---------- Type helpers ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--f-mono);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  width: 32px;
  height: 1px;
  background: currentColor;
  opacity: 0.7;
}

.title {
  font-family: var(--f-display);
  font-size: var(--t-xl);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.035em;
  margin: 18px 0 18px;
  max-width: 20ch;
  text-wrap: balance;
}

.lead {
  color: var(--fg-2);
  font-size: var(--t-md);
  line-height: 1.6;
  max-width: 60ch;
  margin: 0;
}

.grad {
  background: linear-gradient(100deg, var(--accent) 10%, var(--accent-2) 90%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

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

.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 24px 48px;
  margin-bottom: clamp(36px, 5vw, 56px);
}
.section-head .lead { max-width: 52ch; }

/* ---------- Buttons ---------- */
.btn {
  --mx: 0px;
  --my: 0px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 22px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-family: var(--f-mono);
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
  transform: translate(var(--mx), var(--my));
  transition: transform 0.3s var(--ease), box-shadow 0.3s, border-color 0.3s, background-color 0.3s, color 0.3s;
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; flex: none; transition: transform 0.3s var(--ease); }
.btn:hover svg.arrow { transform: translateX(4px); }

.btn--primary {
  background: linear-gradient(110deg, var(--accent), var(--accent-2));
  color: var(--on-accent);
  box-shadow: 0 12px 30px -12px rgba(var(--accent-rgb), 0.7);
}
.btn--primary:hover { box-shadow: 0 18px 44px -14px rgba(var(--accent-rgb), 0.9); }

.btn--ghost {
  border-color: var(--line-2);
  background: rgba(var(--violet-rgb), 0.05);
  color: var(--fg);
}
.btn--ghost:hover { border-color: rgba(var(--accent-rgb), 0.65); background: rgba(var(--accent-rgb), 0.08); }

.btn--sm { padding: 10px 16px; font-size: 0.8rem; border-radius: 10px; }

/* ---------- Fixed chrome: progress, HUD, grain, cursor ---------- */
.progress {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: 2px;
  z-index: 70;
  transform-origin: 0 50%;
  transform: scaleX(var(--p, 0));
  background: linear-gradient(90deg, var(--accent), var(--accent-2), var(--violet));
  pointer-events: none;
}

.hud {
  position: fixed;
  inset: calc(env(safe-area-inset-top, 0px) + 12px) 12px calc(env(safe-area-inset-bottom, 0px) + 12px) 12px;
  pointer-events: none;
  z-index: 45;
}
.hud i {
  position: absolute;
  width: 26px;
  height: 26px;
  border: 0 solid var(--line-2);
}
.hud .c-tl { top: 0; left: 0; border-width: 1px 0 0 1px; }
.hud .c-tr { top: 0; right: 0; border-width: 1px 1px 0 0; }
.hud .c-bl { bottom: 0; left: 0; border-width: 0 0 1px 1px; }
.hud .c-br { bottom: 0; right: 0; border-width: 0 1px 1px 0; }

.hud-status {
  position: absolute;
  left: -2px;
  bottom: 44px;
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--f-mono);
  font-size: 0.7rem;
  color: var(--fg-3);
  letter-spacing: 0.04em;
  padding: 10px 4px;
}
.hud-status .pulse { margin-bottom: 2px; }

.grain {
  position: fixed;
  inset: -50%;
  z-index: 44;
  pointer-events: none;
  opacity: var(--grain-opacity);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 9s steps(9) infinite;
}

.cursor-ring {
  position: fixed;
  top: 0; left: 0;
  width: 38px; height: 38px;
  margin: -19px 0 0 -19px;
  border-radius: 50%;
  border: 1px solid rgba(var(--accent-rgb), 0.7);
  pointer-events: none;
  z-index: 250;
  opacity: 0;
  transform: translate3d(-100px, -100px, 0);
  transition: width 0.3s var(--ease), height 0.3s var(--ease), margin 0.3s var(--ease), background-color 0.3s, opacity 0.3s, border-color 0.3s;
}
.cursor-ring.is-on { opacity: 1; }
.cursor-ring.is-hover {
  width: 70px; height: 70px;
  margin: -35px 0 0 -35px;
  background: rgba(var(--accent-rgb), 0.08);
  border-color: rgba(var(--accent-rgb), 0.35);
}
.cursor-ring.is-down { width: 26px; height: 26px; margin: -13px 0 0 -13px; }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 60;
  padding: calc(env(safe-area-inset-top, 0px) + 14px) var(--gutter) 0;
  transition: transform 0.45s var(--ease);
}
.site-header.is-hidden { transform: none; } /* header always visible */

.nav-shell {
  max-width: var(--maxw);
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 8px 8px 8px 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--glass);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  transition: border-color 0.3s, box-shadow 0.3s;
}
.site-header.is-scrolled .nav-shell { border-color: var(--line-2); box-shadow: var(--shadow); }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--fg);
  min-width: 0;
}
.brand-mark {
  width: 36px; height: 36px;
  flex: none;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--on-accent);
  font-family: var(--f-mono);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: -0.02em;
}
.brand-text {
  display: grid;
  line-height: 1.15;
}
.brand-text b { font-family: var(--f-display); font-size: 1rem; letter-spacing: -0.02em; }
.brand-text small { font-family: var(--f-mono); font-size: 0.66rem; color: var(--fg-3); }

.nav-links {
  display: flex;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  position: relative;
  display: block;
  padding: 8px 12px;
  border-radius: 10px;
  font-family: var(--f-mono);
  font-size: 0.8rem;
  color: var(--fg-2);
  text-decoration: none;
  transition: color 0.2s, background-color 0.2s;
}
.nav-links a:hover { color: var(--fg); background: rgba(var(--accent-rgb), 0.08); }
.nav-links a.is-active { color: var(--fg); }
.nav-links a.is-active::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 2px;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: var(--accent);
  transform: translateX(-50%);
}

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

.icon-btn {
  width: 42px; height: 42px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--fg);
  cursor: pointer;
  transition: border-color 0.2s, background-color 0.2s, transform 0.2s;
}
.icon-btn:hover { border-color: rgba(var(--accent-rgb), 0.6); background: rgba(var(--accent-rgb), 0.08); }
.icon-btn svg { width: 18px; height: 18px; }

.theme-toggle .i-sun { display: none; }
.theme-toggle .i-moon { display: block; }
.theme-toggle[data-mode="dark"] .i-sun { display: block; }
.theme-toggle[data-mode="dark"] .i-moon { display: none; }

.menu-btn { display: none; }
.menu-btn .bars { display: grid; gap: 5px; width: 18px; }
.menu-btn .bars > span {
  display: block;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.3s var(--ease);
}
.menu-btn[aria-expanded="true"] .bars > span:first-child { transform: translateY(3.5px) rotate(45deg); }
.menu-btn[aria-expanded="true"] .bars > span:last-child { transform: translateY(-3.5px) rotate(-45deg); }

.mobile-nav {
  max-width: var(--maxw);
  margin: 8px auto 0;
  padding: 10px;
  border: 1px solid var(--line-2);
  border-radius: 16px;
  background: var(--glass);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}
.mobile-nav ul { list-style: none; margin: 0; padding: 0; display: grid; }
.mobile-nav a {
  display: flex;
  justify-content: space-between;
  padding: 14px 12px;
  border-radius: 10px;
  font-family: var(--f-display);
  font-size: 1.15rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--fg);
}
.mobile-nav a:hover { background: rgba(var(--accent-rgb), 0.08); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding-top: calc(env(safe-area-inset-top, 0px) + clamp(120px, 14vw, 170px));
  padding-bottom: clamp(56px, 7vw, 90px);
  overflow: clip;
  isolation: isolate;
}
.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 160px;
  z-index: -1;
  background: linear-gradient(to bottom, transparent, var(--bg));
  pointer-events: none;
}
.hero-glow {
  position: absolute;
  z-index: -1;
  width: 60vw;
  max-width: 820px;
  aspect-ratio: 1;
  right: -10vw;
  top: -10%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--accent-rgb), 0.16), rgba(var(--violet-rgb), 0.08) 40%, transparent 68%);
  filter: blur(10px);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}

.hero-copy { min-width: 0; }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px 7px 11px;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  background: var(--glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-family: var(--f-mono);
  font-size: 0.76rem;
  color: var(--fg-2);
}
.pulse {
  position: relative;
  width: 8px; height: 8px;
  flex: none;
  border-radius: 50%;
  background: var(--ok);
}
.pulse::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--ok);
  animation: ping 1.8s var(--ease) infinite;
}

.caret {
  display: inline-block;
  width: 0.55em;
  height: 1.1em;
  margin-left: 2px;
  vertical-align: -0.18em;
  background: var(--accent);
  animation: blink 1.05s steps(1) infinite;
}

.hero-name {
  font-family: var(--f-display);
  font-size: var(--t-2xl);
  font-weight: 800;
  line-height: 0.92;
  letter-spacing: -0.05em;
  margin: 14px 0 18px;
  font-variation-settings: "opsz" 96;
}
.hero-name .word {
  display: inline-block;
  overflow: hidden;
  padding-bottom: 0.08em;
  margin-bottom: -0.08em;
  vertical-align: top;
}
.hero-name .line2 { display: block; }
.hero-name .char { display: inline-block; }
.js-motion .hero-name .char {
  transform: translateY(105%);
  animation: rise 0.95s var(--ease) forwards;
  animation-delay: calc(var(--i) * 32ms + 120ms);
}
.hero-name .surname { color: transparent; -webkit-text-stroke: 1.5px var(--fg); }
.hero-name .surname .char:hover { color: var(--accent); -webkit-text-stroke-color: var(--accent); }

.hero-role {
  font-family: var(--f-display);
  font-size: var(--t-lg);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.3;
  margin: 0 0 18px;
  min-height: 2.6em;
}
.hero-role .typed { color: var(--accent); }

.hero-text {
  color: var(--fg-2);
  max-width: 56ch;
  margin: 0;
  font-size: 1.07rem;
}
.hero-text strong { color: var(--fg); font-weight: 600; }

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.socials {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 28px;
}
.socials .label {
  font-family: var(--f-mono);
  font-size: 0.72rem;
  color: var(--fg-3);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-right: 6px;
}
.social {
  width: 42px; height: 42px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  border: 1px solid var(--line);
  color: var(--fg-2);
  background: var(--glass);
  transition: color 0.2s, border-color 0.2s, transform 0.3s var(--ease);
}
.social:hover { color: var(--accent); border-color: rgba(var(--accent-rgb), 0.55); transform: translateY(-3px); }
.social svg { width: 18px; height: 18px; }

/* Portrait stage */
.portrait-stage {
  position: relative;
  width: min(460px, 100%);
  aspect-ratio: 1;
  margin-inline: auto;
}
.orbit {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px dashed var(--line-2);
  animation: spin 46s linear infinite;
}
.orbit--inner {
  inset: 13%;
  border-style: solid;
  border-color: var(--line);
  animation-duration: 32s;
  animation-direction: reverse;
}
.planet {
  position: absolute;
  width: 48px; height: 48px;
  margin: -24px 0 0 -24px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: var(--surface);
  border: 1px solid var(--line-2);
  box-shadow: var(--shadow);
  animation: spin 46s linear infinite reverse;
}
.orbit--inner .planet { width: 40px; height: 40px; margin: -20px 0 0 -20px; border-radius: 12px; animation-duration: 32s; animation-direction: normal; }
.planet img { width: 26px; height: 26px; }
.orbit--inner .planet img { width: 21px; height: 21px; }

.photo-ring {
  position: absolute;
  inset: 23%;
  border-radius: 50%;
  overflow: hidden;
  isolation: isolate;
  box-shadow: 0 30px 80px -20px rgba(var(--accent-rgb), 0.35);
}
.photo-ring::before {
  content: "";
  position: absolute;
  inset: -40%;
  background: conic-gradient(from 0deg, var(--accent), var(--violet), transparent 38%, transparent 55%, var(--accent-2), var(--accent));
  animation: spin 5.5s linear infinite;
  z-index: -1;
}
.photo-ring img {
  position: absolute;
  inset: 4px;
  width: calc(100% - 8px);
  height: calc(100% - 8px);
  max-width: none;
  border-radius: 50%;
  object-fit: cover;
  background: var(--surface);
}

.float-chip {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 14px;
  background: var(--glass);
  border: 1px solid var(--line-2);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
  font-size: 0.8rem;
  line-height: 1.25;
  white-space: nowrap;
  animation: bob 6s ease-in-out infinite;
  z-index: 2;
}
.float-chip b { display: block; font-family: var(--f-display); font-size: 1rem; letter-spacing: -0.01em; }
.float-chip small { color: var(--fg-3); font-family: var(--f-mono); font-size: 0.66rem; letter-spacing: 0.04em; }
.float-chip .chip-ico {
  width: 34px; height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: rgba(var(--accent-rgb), 0.14);
  color: var(--accent);
  flex: none;
}
.float-chip .chip-ico svg { width: 18px; height: 18px; }
.float-chip--a { top: 7%; left: -2%; }
.float-chip--b { top: 44%; right: -5%; animation-delay: -2s; }
.float-chip--c { bottom: 6%; left: 4%; animation-delay: -4s; }

/* Hero stats */
.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: clamp(48px, 6vw, 80px);
}
.stat {
  --x: 50%;
  --y: 0%;
  --rx: 0deg;
  --ry: 0deg;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 22px 22px 20px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--glass);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  overflow: hidden;
  min-width: 0;
  transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry));
  transition: border-color 0.3s, transform 0.25s ease-out, box-shadow 0.3s;
}
.stat::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(320px circle at var(--x) var(--y), rgba(var(--accent-rgb), 0.16), transparent 50%);
  opacity: 0;
  transition: opacity 0.35s;
  pointer-events: none;
}
.stat::after {
  content: "";
  position: absolute;
  left: 22px; right: 22px; top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(var(--accent-rgb), 0.7), transparent);
  opacity: 0.55;
}
.stat:hover { border-color: rgba(var(--accent-rgb), 0.4); box-shadow: var(--shadow); }
.stat:hover::before { opacity: 1; }
.stat-ico {
  width: 40px; height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(var(--accent-rgb), 0.12);
  color: var(--accent);
  margin-bottom: 12px;
}
.stat-ico svg { width: 20px; height: 20px; }
.stat-num {
  display: flex;
  align-items: baseline;
  font-family: var(--f-display);
  font-size: clamp(2.1rem, 1.4rem + 2vw, 3rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  color: var(--fg);
  white-space: nowrap;
}
.stat-num .affix {
  background: linear-gradient(110deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.stat-label { font-size: 0.95rem; font-weight: 500; color: var(--fg-2); line-height: 1.35; }
.stat-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 10px;
  padding-top: 12px;
  border-top: 1px dashed var(--line-2);
  font-family: var(--f-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.stat-tag::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 10px currentColor;
}

.scroll-cue {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-3);
  text-decoration: none;
}
.mouse {
  width: 22px; height: 34px;
  border: 1.5px solid var(--line-2);
  border-radius: 12px;
  position: relative;
}
.mouse::after {
  content: "";
  position: absolute;
  left: 50%; top: 7px;
  width: 3px; height: 7px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: var(--accent);
  animation: wheel 1.8s var(--ease) infinite;
}

/* ---------- Marquee ---------- */
.marquee-band {
  padding-block: 26px;
  border-block: 1px solid var(--line);
  background: var(--bg-2);
  display: grid;
  gap: 12px;
}
.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track {
  display: flex;
  gap: 12px;
  width: max-content;
  animation: marquee var(--dur, 48s) linear infinite;
}
.marquee--rev .marquee-track { animation-direction: reverse; }
.marquee:hover .marquee-track { animation-play-state: paused; }

.tech-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px 10px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  font-family: var(--f-mono);
  font-size: 0.84rem;
  color: var(--fg-2);
  white-space: nowrap;
}
.tech-pill img { width: 20px; height: 20px; }
.tech-pill .glyph {
  width: 20px; height: 20px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: rgba(var(--accent-rgb), 0.15);
  color: var(--accent);
  font-size: 0.7rem;
  font-weight: 700;
}
img.mono-ico { filter: var(--mono-filter); }

/* ---------- About ---------- */
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(36px, 6vw, 80px);
  align-items: start;
}
.about-copy p { color: var(--fg-2); margin: 0 0 16px; max-width: 60ch; }
.about-copy p strong { color: var(--fg); font-weight: 600; }

.facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin: 30px 0 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--line);
  overflow: hidden;
}
.fact { background: var(--bg); padding: 16px 18px; min-width: 0; }
.section--alt .fact { background: var(--bg-2); }
.fact dt {
  font-family: var(--f-mono);
  font-size: 0.68rem;
  color: var(--fg-3);
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.fact dd { margin: 5px 0 0; font-weight: 600; font-size: 0.97rem; }

.industries {
  position: relative;
  padding: clamp(22px, 3vw, 30px);
  border: 1px solid var(--line-2);
  border-radius: var(--r-lg);
  background:
    radial-gradient(520px circle at 100% 0%, rgba(var(--accent-rgb), 0.11), transparent 55%),
    var(--surface);
  box-shadow: var(--shadow);
  min-width: 0;
}
.ind-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 18px;
}
.ind-head h3 {
  margin: 0;
  font-family: var(--f-display);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.ind-head span { font-family: var(--f-mono); font-size: 0.72rem; color: var(--fg-3); white-space: nowrap; }
.ind-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.ind {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--bg-2);
  min-width: 0;
  transition: border-color 0.3s, transform 0.35s var(--ease), background-color 0.3s;
}
.ind:hover { border-color: rgba(var(--accent-rgb), 0.45); background: rgba(var(--accent-rgb), 0.06); transform: translateY(-3px); }
.ind-ico {
  width: 38px; height: 38px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: rgba(var(--accent-rgb), 0.12);
  color: var(--accent);
  transition: transform 0.4s var(--ease);
}
.ind:hover .ind-ico { transform: rotate(-8deg) scale(1.08); }
.ind-ico svg { width: 19px; height: 19px; }
.ind b { display: block; font-size: 0.93rem; font-weight: 600; line-height: 1.3; }
.ind small { display: block; margin-top: 3px; font-family: var(--f-mono); font-size: 0.7rem; color: var(--fg-3); line-height: 1.45; }
.ind-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}
.ind-foot > span { font-family: var(--f-mono); font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--fg-3); margin-right: 4px; }
.country {
  padding: 5px 11px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  font-size: 0.8rem;
  color: var(--fg-2);
}

.principles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.principle {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
}
.principle svg { width: 20px; height: 20px; color: var(--accent); flex: none; margin-top: 2px; }
.principle b { display: block; font-size: 0.95rem; }
.principle span { color: var(--fg-3); font-size: 0.85rem; line-height: 1.45; display: block; margin-top: 2px; }

/* ---------- Services ---------- */
.svc-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.svc {
  --x: 50%;
  --y: 0%;
  --rx: 0deg;
  --ry: 0deg;
  position: relative;
  padding: 28px 26px 26px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  overflow: hidden;
  transform: perspective(900px) rotateX(var(--rx)) rotateY(var(--ry));
  transition: border-color 0.3s, transform 0.25s ease-out;
  min-width: 0;
}
.svc::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(420px circle at var(--x) var(--y), rgba(var(--accent-rgb), 0.14), transparent 45%);
  opacity: 0;
  transition: opacity 0.35s;
  pointer-events: none;
}
.svc:hover::before { opacity: 1; }
.svc:hover { border-color: rgba(var(--accent-rgb), 0.38); }
.svc-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 22px; }
.svc-icon {
  width: 50px; height: 50px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: rgba(var(--accent-rgb), 0.12);
  color: var(--accent);
}
.svc-icon svg { width: 24px; height: 24px; }
.svc-logos { display: flex; gap: 6px; }
.svc-logos img { width: 22px; height: 22px; opacity: 0.85; }
.svc h3 {
  font-family: var(--f-display);
  font-size: 1.32rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin: 0 0 10px;
}
.svc p { color: var(--fg-2); font-size: 0.95rem; margin: 0 0 18px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0; padding: 0; }
.tag {
  font-family: var(--f-mono);
  font-size: 0.7rem;
  padding: 4px 9px;
  border-radius: 7px;
  border: 1px solid var(--line);
  color: var(--fg-3);
  background: var(--bg-2);
  white-space: nowrap;
}

.results {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: clamp(48px, 6vw, 72px);
  border-top: 1px solid var(--line);
}
.result {
  padding: 28px 24px 0 0;
  min-width: 0;
}
.result + .result { padding-left: 24px; border-left: 1px solid var(--line); }
.result b {
  display: block;
  font-family: var(--f-display);
  font-size: clamp(2.2rem, 1.5rem + 2vw, 3.1rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}
.result p { color: var(--fg-2); font-size: 0.92rem; margin: 10px 0 0; max-width: 30ch; }
.result small { display: block; margin-top: 8px; font-family: var(--f-mono); font-size: 0.68rem; color: var(--fg-3); letter-spacing: 0.06em; text-transform: uppercase; }

/* ---------- Experience timeline ---------- */
.timeline {
  position: relative;
  padding-left: 44px;
}
.timeline::before,
.tl-fill {
  content: "";
  position: absolute;
  left: 12px;
  top: 10px;
  width: 2px;
}
.timeline::before { bottom: 10px; background: var(--line); }
.tl-fill {
  height: var(--fill, 0px);
  max-height: calc(100% - 20px);
  background: linear-gradient(var(--accent), var(--accent-2));
  box-shadow: 0 0 18px rgba(var(--accent-rgb), 0.7);
  border-radius: 2px;
}
.tl-item {
  position: relative;
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 12px 36px;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}
.tl-item:first-of-type { padding-top: 0; }
.tl-item:last-of-type { border-bottom: 0; }
.tl-dot {
  position: absolute;
  left: -39px;
  top: 34px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--line-2);
  transition: border-color 0.4s, box-shadow 0.4s, background-color 0.4s;
}
.tl-item:first-of-type .tl-dot { top: 6px; }
.tl-item.is-lit .tl-dot {
  border-color: var(--accent);
  background: var(--accent);
  box-shadow: 0 0 0 6px rgba(var(--accent-rgb), 0.16), 0 0 18px rgba(var(--accent-rgb), 0.6);
}
.tl-meta { font-family: var(--f-mono); font-size: 0.8rem; color: var(--fg-3); display: grid; gap: 6px; align-content: start; }
.tl-meta .when { color: var(--fg); font-weight: 600; }
.tl-meta .dur { color: var(--accent); }
.tl-main h3 {
  font-family: var(--f-display);
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: 999px;
  font-family: var(--f-mono);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.12);
  border: 1px solid rgba(var(--accent-rgb), 0.3);
}
.badge--ok { color: var(--ok); background: transparent; border-color: currentColor; }
.tl-company { margin: 6px 0 14px; color: var(--accent); font-weight: 600; }
.tl-company span { color: var(--fg-3); font-weight: 400; }
.tl-main ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.tl-main li { position: relative; padding-left: 20px; color: var(--fg-2); font-size: 0.95rem; max-width: 70ch; }
.tl-main li::before {
  content: "";
  position: absolute;
  left: 2px; top: 0.7em;
  width: 8px; height: 1.5px;
  background: var(--accent);
}

.creds {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: clamp(40px, 5vw, 60px);
}
.cred {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.3s, transform 0.3s var(--ease);
  min-width: 0;
}
a.cred:hover { border-color: rgba(var(--accent-rgb), 0.5); transform: translateY(-4px); }
.cred .kind { font-family: var(--f-mono); font-size: 0.68rem; letter-spacing: 0.09em; text-transform: uppercase; color: var(--accent); }
.cred b { font-family: var(--f-display); font-size: 1.08rem; line-height: 1.3; letter-spacing: -0.01em; }
.cred span { color: var(--fg-3); font-size: 0.85rem; }
.cred .go { margin-top: auto; padding-top: 8px; font-family: var(--f-mono); font-size: 0.74rem; color: var(--fg-2); }

/* ---------- Work ---------- */
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 28px;
}
.chip-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  background: transparent;
  color: var(--fg-2);
  font-family: var(--f-mono);
  font-size: 0.8rem;
  cursor: pointer;
  transition: color 0.2s, background-color 0.2s, border-color 0.2s;
}
.chip-btn sup { font-size: 0.66rem; color: var(--fg-3); }
.chip-btn:hover { border-color: rgba(var(--accent-rgb), 0.6); color: var(--fg); }
.chip-btn[aria-pressed="true"] { background: var(--fg); border-color: var(--fg); color: var(--bg); }
.chip-btn[aria-pressed="true"] sup { color: var(--bg); opacity: 0.7; }

.work-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.proj {
  --rx: 0deg;
  --ry: 0deg;
  position: relative;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  overflow: hidden;
  transform: perspective(1000px) rotateX(var(--rx)) rotateY(var(--ry));
  transition: border-color 0.3s, transform 0.25s ease-out, box-shadow 0.3s;
  min-width: 0;
}
.proj:hover { border-color: rgba(var(--accent-rgb), 0.4); box-shadow: var(--shadow); }
.proj.is-entering { animation: cardIn 0.55s var(--ease) both; }
.proj-media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--bg-2);
}
.proj-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  transition: transform 0.9s var(--ease);
}
.proj:hover .proj-media img { transform: scale(1.06); }
.proj-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(var(--accent-rgb), 0.25), transparent 55%);
  opacity: 0;
  transition: opacity 0.4s;
}
.proj:hover .proj-media::after { opacity: 1; }
.proj-view {
  position: absolute;
  left: 16px; bottom: 16px;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 10px;
  background: var(--glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--line-2);
  font-family: var(--f-mono);
  font-size: 0.74rem;
  color: var(--fg);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.35s, transform 0.35s var(--ease);
}
.proj-view svg { width: 14px; height: 14px; flex: none; }
.proj-view { white-space: nowrap; }
.proj:hover .proj-view,
.proj:focus-within .proj-view { opacity: 1; transform: none; }
.proj-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  padding: 20px 22px 22px;
}
.proj-kicker {
  font-family: var(--f-mono);
  font-size: 0.7rem;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.proj h3 {
  font-family: var(--f-display);
  font-size: 1.28rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin: 0;
}
.proj-open {
  all: unset;
  cursor: pointer;
}
.proj-open::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}
.proj-open:focus-visible { outline: none; }
.proj:has(.proj-open:focus-visible) { outline: 2px solid var(--accent); outline-offset: 3px; }
.proj p { margin: 0; color: var(--fg-2); font-size: 0.93rem; }
.proj-foot {
  margin-top: auto;
  padding-top: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
.proj-foot .tags { min-width: 0; }
.live-link {
  position: relative;
  z-index: 2;
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid var(--line-2);
  font-family: var(--f-mono);
  font-size: 0.72rem;
  color: var(--fg-2);
  text-decoration: none;
  transition: color 0.2s, border-color 0.2s;
}
.live-link:hover { color: var(--accent); border-color: rgba(var(--accent-rgb), 0.6); }
.live-link svg { width: 13px; height: 13px; }

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: calc(env(safe-area-inset-top, 0px) + 16px) 16px calc(env(safe-area-inset-bottom, 0px) + 16px);
  background: var(--scrim);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: fadeIn 0.3s ease both;
}
.modal-card {
  position: relative;
  width: min(1040px, 100%);
  max-height: 100%;
  overflow: auto;
  overscroll-behavior: contain;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  border: 1px solid var(--line-2);
  border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: 0 40px 120px -30px rgba(0, 0, 0, 0.6);
  animation: popIn 0.45s var(--ease) both;
}
.modal-media {
  position: relative;
  display: flex;
  align-items: center;
  background: var(--bg-2);
  border-right: 1px solid var(--line);
}
.modal-media img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; object-position: top; }
.modal-body { padding: clamp(24px, 3.5vw, 40px); display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.modal-body h3 {
  font-family: var(--f-display);
  font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.2rem);
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin: 0;
}
.modal-role { font-family: var(--f-mono); font-size: 0.78rem; color: var(--fg-3); }
.modal-desc { color: var(--fg-2); font-size: 0.97rem; display: grid; gap: 10px; }
.modal-desc p { margin: 0; }
.modal-desc ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.modal-desc li { position: relative; padding-left: 18px; }
.modal-desc li::before { content: ""; position: absolute; left: 0; top: 0.72em; width: 8px; height: 1.5px; background: var(--accent); }
.modal-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: auto; padding-top: 10px; }
.modal-close {
  position: absolute;
  top: 12px; right: 12px;
  z-index: 3;
  background: var(--glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.modal-nav { display: flex; gap: 8px; margin-left: auto; }

/* ---------- Live sites wall ---------- */
.live-wall { display: grid; gap: 18px; margin-top: clamp(36px, 5vw, 56px); }
.live-wall .marquee-track { gap: 18px; padding-block: 10px; }
.browser {
  flex: none;
  width: clamp(260px, 28vw, 360px);
  border: 1px solid var(--line-2);
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  transition: transform 0.4s var(--ease), border-color 0.3s, box-shadow 0.3s;
}
.browser:hover { transform: translateY(-6px) rotate(-0.4deg); border-color: rgba(var(--accent-rgb), 0.55); box-shadow: var(--shadow); }
.browser-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
}
.browser-bar i { width: 8px; height: 8px; border-radius: 50%; display: block; flex: none; }
.browser-bar i:nth-child(1) { background: var(--dot-r); }
.browser-bar i:nth-child(2) { background: var(--dot-y); }
.browser-bar i:nth-child(3) { background: var(--dot-g); }
.browser-bar .url {
  flex: 1;
  min-width: 0;
  margin-left: 8px;
  padding: 3px 10px;
  border-radius: 6px;
  background: var(--bg);
  font-family: var(--f-mono);
  font-size: 0.68rem;
  color: var(--fg-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.browser img { width: 100%; height: auto; aspect-ratio: 2 / 1; object-fit: cover; object-position: top; }
.browser figcaption {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  font-size: 0.82rem;
  color: var(--fg-2);
  border-top: 1px solid var(--line);
}
.browser figcaption span { font-family: var(--f-mono); font-size: 0.68rem; color: var(--fg-3); }
.browser figure { margin: 0; }

/* ---------- Reviews ---------- */
.rev-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  gap: clamp(24px, 4vw, 48px);
  align-items: stretch;
}
.rev-summary {
  padding: clamp(24px, 3vw, 34px);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--surface);
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
}
.jss { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.jss b {
  font-family: var(--f-display);
  font-size: clamp(3.4rem, 2.4rem + 3vw, 4.8rem);
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.05em;
  font-variant-numeric: tabular-nums;
}
.jss > span { font-family: var(--f-mono); font-size: 0.74rem; color: var(--fg-3); letter-spacing: 0.08em; text-transform: uppercase; padding-bottom: 6px; line-height: 1.5; }
.trp {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  align-self: flex-start;
  padding: 8px 14px 8px 8px;
  border-radius: 999px;
  border: 1px solid rgba(var(--accent-rgb), 0.35);
  background: rgba(var(--accent-rgb), 0.1);
  font-weight: 600;
  font-size: 0.9rem;
}
.trp i {
  width: 28px; height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--on-accent);
}
.trp i svg { width: 15px; height: 15px; }
.insights h3 { font-family: var(--f-mono); font-size: 0.72rem; font-weight: 500; letter-spacing: 0.09em; text-transform: uppercase; color: var(--fg-3); margin: 0 0 12px; }
.bars { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.bar-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; font-size: 0.86rem; }
.bar-row .n { font-family: var(--f-mono); color: var(--fg-3); font-variant-numeric: tabular-nums; }
.bar-track { grid-column: 1 / -1; height: 6px; border-radius: 6px; background: var(--bg-2); overflow: hidden; }
.bar-track i {
  display: block;
  height: 100%;
  width: var(--w);
  border-radius: 6px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform-origin: 0 50%;
  transition: transform 1.2s var(--ease);
  transition-delay: calc(var(--k, 0) * 80ms);
}
.js-motion .rev-summary:not(.in) .bar-track i { transform: scaleX(0); }

.rev-feature {
  position: relative;
  padding: clamp(26px, 3.5vw, 44px);
  border: 1px solid var(--line-2);
  border-radius: var(--r-lg);
  background:
    radial-gradient(600px circle at 100% 0%, rgba(var(--accent-rgb), 0.12), transparent 50%),
    var(--surface);
  display: flex;
  flex-direction: column;
  gap: 22px;
  overflow: hidden;
  min-width: 0;
}
.quote-mark {
  font-family: var(--f-display);
  font-size: 5.5rem;
  line-height: 0.7;
  height: 0.42em;
  color: var(--accent);
  opacity: 0.9;
}
.slides { position: relative; display: grid; flex: 1; }
.slide {
  grid-area: 1 / 1;
  display: flex;
  flex-direction: column;
  gap: 18px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease), visibility 0.6s;
}
.slide.is-active { opacity: 1; visibility: visible; transform: none; }
.slide blockquote {
  margin: 0;
  font-family: var(--f-display);
  font-size: clamp(1.15rem, 0.95rem + 0.9vw, 1.55rem);
  font-weight: 500;
  line-height: 1.45;
  letter-spacing: -0.01em;
  text-wrap: pretty;
}
.rev-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; font-size: 0.85rem; color: var(--fg-3); }
.rev-meta b { color: var(--fg); font-weight: 600; }
.verified { display: inline-flex; align-items: center; gap: 6px; font-family: var(--f-mono); font-size: 0.68rem; color: var(--ok); letter-spacing: 0.04em; }
.verified svg { width: 13px; height: 13px; }
.rev-controls { display: flex; align-items: center; gap: 12px; }
.rev-progress { flex: 1; height: 2px; background: var(--line); border-radius: 2px; overflow: hidden; }
.rev-progress i { display: block; height: 100%; width: 100%; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }
.rev-count { font-family: var(--f-mono); font-size: 0.78rem; color: var(--fg-3); font-variant-numeric: tabular-nums; min-width: 5ch; text-align: right; }

.stars {
  --s: 5;
  position: relative;
  display: inline-block;
  font-size: 0.95rem;
  letter-spacing: 2px;
  line-height: 1;
  color: var(--line-2);
}
.stars::before { content: "★★★★★"; }
.stars::after {
  content: "★★★★★";
  position: absolute;
  left: 0; top: 0;
  width: calc(var(--s) / 5 * 100%);
  overflow: hidden;
  white-space: nowrap;
  color: var(--accent);
}

.rev-wall { display: grid; gap: 16px; margin-top: clamp(32px, 4vw, 48px); }
.rev-wall .marquee-track { gap: 16px; }
.rev-card {
  flex: none;
  width: clamp(280px, 30vw, 380px);
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface);
  white-space: normal;
}
.rev-card p { margin: 0; color: var(--fg-2); font-size: 0.93rem; line-height: 1.6; }
.rev-card .rev-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.rev-card .score { font-family: var(--f-mono); font-size: 0.74rem; color: var(--fg-3); }
.rev-card footer { margin-top: auto; font-size: 0.8rem; color: var(--fg-3); display: grid; gap: 2px; }
.rev-card footer b { color: var(--fg); font-weight: 600; font-size: 0.84rem; line-height: 1.35; }

/* ---------- Skills ---------- */
.skill-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.skill-card {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  min-width: 0;
  transition: border-color 0.3s;
}
.skill-card:hover { border-color: var(--line-2); }
.skill-card h3 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 0 16px;
  font-family: var(--f-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-2);
}
.skill-card h3 span { color: var(--fg-3); font-weight: 400; }
.skill-list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.skill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px 8px 9px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--bg-2);
  font-size: 0.86rem;
  transition: border-color 0.25s, transform 0.25s var(--ease), background-color 0.25s;
}
.skill:hover { border-color: rgba(var(--accent-rgb), 0.55); transform: translateY(-2px); background: rgba(var(--accent-rgb), 0.06); }
.skill img { width: 20px; height: 20px; }
.skill .glyph {
  width: 20px; height: 20px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  background: rgba(var(--accent-rgb), 0.14);
}
.glyph::before {
  content: "";
  width: 6px; height: 6px;
  border-radius: 2px;
  background: var(--accent);
  transform: rotate(45deg);
}

/* ---------- Process ---------- */
.steps {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}
.steps::before,
.steps-fill {
  content: "";
  position: absolute;
  left: 28px;
  right: 28px;
  top: 28px;
  height: 1px;
}
.steps::before { background: var(--line-2); }
.steps-fill {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  box-shadow: 0 0 12px rgba(var(--accent-rgb), 0.7);
  transform-origin: 0 50%;
  transform: scaleX(1);
  transition: transform 1.6s var(--ease);
}
.js-motion .steps:not(.in) .steps-fill { transform: scaleX(0); }
.step { position: relative; padding-top: 80px; min-width: 0; }
.step-num {
  position: absolute;
  top: 0; left: 0;
  width: 56px; height: 56px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  border: 1px solid var(--line-2);
  background: var(--surface);
  font-family: var(--f-mono);
  font-weight: 700;
  color: var(--accent);
  z-index: 1;
}
.step h3 { font-family: var(--f-display); font-size: 1.2rem; letter-spacing: -0.02em; margin: 0 0 8px; }
.step p { margin: 0; color: var(--fg-2); font-size: 0.93rem; }

/* ---------- Contact ---------- */
.contact { overflow: clip; }
.contact-title {
  font-family: var(--f-display);
  font-size: clamp(2.6rem, 1.4rem + 5vw, 5.6rem);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.05em;
  margin: 18px 0 18px;
  max-width: 14ch;
  text-wrap: balance;
}
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(24px, 4vw, 48px);
  margin-top: clamp(36px, 5vw, 56px);
  align-items: start;
}
.c-list { display: grid; gap: 12px; }
.c-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface);
  color: inherit;
  text-decoration: none;
  transition: border-color 0.3s, transform 0.3s var(--ease);
  min-width: 0;
}
a.c-item:hover { border-color: rgba(var(--accent-rgb), 0.55); transform: translateX(4px); }
.c-icon {
  width: 46px; height: 46px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(var(--accent-rgb), 0.12);
  color: var(--accent);
}
.c-icon svg { width: 21px; height: 21px; }
.c-text { min-width: 0; flex: 1; }
.c-text small {
  display: block;
  font-family: var(--f-mono);
  font-size: 0.68rem;
  color: var(--fg-3);
  letter-spacing: 0.09em;
  text-transform: uppercase;
}
.c-text strong { display: block; font-weight: 600; overflow-wrap: anywhere; user-select: all; -webkit-user-select: all; }
.c-item .arrow-out { width: 18px; height: 18px; color: var(--fg-3); flex: none; }
.copy-btn {
  position: relative;
  z-index: 1;
  flex: none;
  padding: 8px 12px;
  border-radius: 9px;
  border: 1px solid var(--line-2);
  background: transparent;
  color: var(--fg-2);
  font-family: var(--f-mono);
  font-size: 0.74rem;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.copy-btn:hover { color: var(--accent); border-color: rgba(var(--accent-rgb), 0.6); }

.form {
  display: grid;
  gap: 16px;
  padding: clamp(22px, 3vw, 32px);
  border: 1px solid var(--line-2);
  border-radius: var(--r-lg);
  background: var(--surface);
  box-shadow: var(--shadow);
  min-width: 0;
}
.form h3 { font-family: var(--f-display); font-size: 1.35rem; letter-spacing: -0.02em; margin: 0; }
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.field { display: grid; gap: 8px; min-width: 0; }
.field label {
  font-family: var(--f-mono);
  font-size: 0.7rem;
  color: var(--fg-3);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 13px 14px;
  border-radius: 12px;
  border: 1px solid var(--line-2);
  background: var(--bg-2);
  color: var(--fg);
  font: inherit;
  font-size: 0.97rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input::placeholder,
.field textarea::placeholder { color: var(--fg-3); }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(var(--accent-rgb), 0.15);
}
.form-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.form-note { margin: 0; font-size: 0.82rem; color: var(--fg-3); }
.form-status { margin: 0; font-family: var(--f-mono); font-size: 0.8rem; color: var(--ok); min-height: 1.2em; }
.form-status.is-error { color: var(--accent-2); }

/* ---------- Footer ---------- */
.footer {
  padding-block: clamp(48px, 6vw, 72px) calc(env(safe-area-inset-bottom, 0px) + 36px);
  border-top: 1px solid var(--line);
  overflow: clip;
}
.footer-big {
  font-family: var(--f-display);
  font-size: clamp(3rem, 11.5vw, 10.5rem);
  font-weight: 800;
  line-height: 0.88;
  letter-spacing: -0.055em;
  color: transparent;
  -webkit-text-stroke: 1px var(--line-2);
  white-space: nowrap;
  margin: 0 0 36px;
  user-select: none;
  transition: -webkit-text-stroke-color 0.4s;
}
.footer-big:hover { -webkit-text-stroke-color: rgba(var(--accent-rgb), 0.7); }
.footer-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px 32px;
  font-family: var(--f-mono);
  font-size: 0.78rem;
  color: var(--fg-3);
}
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 20px; list-style: none; margin: 0; padding: 0; }
.footer-links a { text-decoration: none; color: var(--fg-2); }
.footer-links a:hover { color: var(--accent); }

.to-top {
  position: fixed;
  right: calc(16px + env(safe-area-inset-right, 0px));
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 55;
  width: 50px; height: 50px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 0;
  background: var(--glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--fg);
  cursor: pointer;
  opacity: 0;
  transform: translateY(16px) scale(0.9);
  pointer-events: none;
  transition: opacity 0.35s, transform 0.35s var(--ease);
}
.to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.to-top svg.ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.to-top .ring circle { fill: none; stroke-width: 2; }
.to-top .ring .bg { stroke: var(--line-2); }
.to-top .ring .fg { stroke: var(--accent); stroke-linecap: round; stroke-dasharray: 144.5; stroke-dashoffset: calc(144.5 * (1 - var(--p, 0))); }
.to-top .arrow-up { width: 18px; height: 18px; }

/* ---------- Reveal ---------- */
.js-motion .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  transition-delay: var(--d, 0ms);
}
.js-motion .reveal.in { opacity: 1; transform: none; }

/* ---------- Hero load sequence ---------- */
.js-motion .hero-name:not(.is-split) { visibility: hidden; animation: showLate 0s 2.5s forwards; }
.js-motion .hero-copy > :not(.hero-name),
.js-motion .hero-stats,
.js-motion .scroll-cue { animation: fadeUp 0.9s var(--ease) both; }
.js-motion .hero-copy > .status-pill { animation-delay: 0.05s; }
.js-motion .hero-copy > .hero-role { animation-delay: 0.55s; }
.js-motion .hero-copy > .hero-text { animation-delay: 0.68s; }
.js-motion .hero-copy > .hero-cta { animation-delay: 0.8s; }
.js-motion .hero-copy > .socials { animation-delay: 0.92s; }
.js-motion .hero-stats { animation-delay: 1.05s; }
.js-motion .scroll-cue { animation-delay: 1.2s; }
.js-motion .hero-visual { animation: zoomIn 1.2s var(--ease) 0.2s both; }

/* ---------- Keyframes ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(22px); } }
@keyframes zoomIn { from { opacity: 0; transform: scale(0.92); } }
@keyframes showLate { to { visibility: visible; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes rise { to { transform: translateY(0); } }
@keyframes blink { 50% { opacity: 0; } }
@keyframes ping { 0% { transform: scale(1); opacity: 0.7; } 80%, 100% { transform: scale(2.8); opacity: 0; } }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(9px); opacity: 0; } 100% { opacity: 0; } }
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  20% { transform: translate(-6%, 4%); }
  40% { transform: translate(5%, -6%); }
  60% { transform: translate(-3%, 7%); }
  80% { transform: translate(7%, -2%); }
}
@keyframes fadeIn { from { opacity: 0; } }
@keyframes popIn { from { opacity: 0; transform: translateY(24px) scale(0.97); } }
@keyframes cardIn { from { opacity: 0; transform: translateY(18px) scale(0.98); } }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .hud-status { display: none; }
}

@media (max-width: 1080px) {
  .nav-links a { padding: 8px 9px; }
  .hero-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .svc-grid, .work-grid, .skill-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .creds { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .results { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .result:nth-child(3) { padding-left: 0; border-left: 0; }
  .float-chip--b { right: -2%; }
}

@media (max-width: 960px) {
  .nav-links, .nav-cta { display: none; }
  .menu-btn { display: grid; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .hero-visual { order: -1; }
  .portrait-stage { width: min(360px, 88%); }
  .about-grid, .rev-layout, .contact-grid { grid-template-columns: minmax(0, 1fr); }
  .section-head { grid-template-columns: minmax(0, 1fr); }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 36px; }
  .steps::before, .steps-fill { display: none; }
  .modal-card { grid-template-columns: minmax(0, 1fr); }
  .modal-media { border-right: 0; border-bottom: 1px solid var(--line); }
  .tl-item { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .tl-meta { grid-auto-flow: column; justify-content: start; gap: 14px; }
  .tl-dot, .tl-item:first-of-type .tl-dot { top: 4px; }
  .tl-item { padding: 24px 0; }
}

@media (max-width: 720px) {
  .hud { display: none; }
  .hero-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .stat { padding: 18px 16px 16px; border-radius: 16px; }
  .stat-ico { width: 34px; height: 34px; margin-bottom: 8px; }
  .stat-label { font-size: 0.86rem; }
  .stat-tag { font-size: 0.6rem; letter-spacing: 0.05em; }
  .svc-grid, .work-grid, .skill-grid, .creds, .principles { grid-template-columns: minmax(0, 1fr); }
  .facts { grid-template-columns: minmax(0, 1fr); }
  .form-row { grid-template-columns: minmax(0, 1fr); }
  .portrait-stage { width: min(300px, 78%); }
  .float-chip { font-size: 0.72rem; padding: 8px 10px; gap: 8px; }
  .float-chip b { font-size: 0.88rem; }
  .float-chip .chip-ico { width: 28px; height: 28px; }
  .float-chip--a { left: -4%; top: 2%; }
  .float-chip--b { display: none; }
  .float-chip--c { left: 0; bottom: 2%; }
  .planet { width: 38px; height: 38px; margin: -19px 0 0 -19px; border-radius: 11px; }
  .planet img { width: 20px; height: 20px; }
  .orbit--inner .planet { width: 32px; height: 32px; margin: -16px 0 0 -16px; }
  .orbit--inner .planet img { width: 17px; height: 17px; }
  .brand-text small { display: none; }
  .timeline { padding-left: 32px; }
  .timeline::before, .tl-fill { left: 6px; }
  .tl-dot { left: -33px; }
  .tl-meta { grid-auto-flow: row; gap: 4px; }
}

@media (max-width: 520px) {
  .ind-grid { grid-template-columns: minmax(0, 1fr); }
  .results { grid-template-columns: minmax(0, 1fr); }
  .result + .result { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
  .result { padding: 22px 0; }
  .steps { grid-template-columns: minmax(0, 1fr); }
  .hero-cta .btn { flex: 1 1 100%; }
  .scroll-cue { display: none; }
}

@media (hover: none), (pointer: coarse) {
  .cursor-ring { display: none; }
  .proj-view { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  html { scroll-behavior: auto; }
  .marquee { overflow-x: auto; }
  .grain { display: none; }
}

/* ---------- Testimonials: each review links to the Upwork profile ---------- */
.slide { position: relative; }
.slide-link {
  position: absolute;
  inset: -8px;
  z-index: 2;
  border-radius: var(--r-md);
}
.slide-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.slide:hover .verified { text-decoration: underline; text-underline-offset: 3px; }

.rev-card { position: relative; transition: border-color 0.3s; }
.rev-card:hover { border-color: var(--line-2); }
.rev-card-link {
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: inherit;
}
.rev-card-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- Header: larger size on all screens ---------- */
html { scroll-padding-top: 24px; }
.nav-shell { padding: 12px 12px 12px 16px; border-radius: 20px; gap: 20px; }
.brand { gap: 12px; }
.brand-mark { width: 46px; height: 46px; border-radius: 13px; font-size: 1rem; }
.brand-text { line-height: 1.2; }
.brand-text b { font-size: 1.2rem; }
.brand-text small { font-size: 0.74rem; }
.nav-links a { padding: 10px 14px; font-size: 0.92rem; }
.nav-actions { gap: 10px; }
.site-header .icon-btn { width: 48px; height: 48px; border-radius: 13px; }
.site-header .icon-btn svg { width: 20px; height: 20px; }
.site-header .menu-btn .bars { width: 20px; }
.site-header .nav-cta { padding: 14px 22px; font-size: 0.9rem; border-radius: 12px; }

@media (max-width: 1240px) {
  .nav-links a { padding: 10px 10px; font-size: 0.86rem; }
  .site-header .nav-cta { padding: 13px 18px; }
}
@media (max-width: 1100px) {
  .nav-shell { gap: 14px; }
  .brand-mark { width: 42px; height: 42px; }
  .brand-text b { font-size: 1.08rem; }
  .brand-text small { font-size: 0.68rem; }
  .nav-links a { padding: 8px 8px; font-size: 0.8rem; }
  .site-header .icon-btn { width: 44px; height: 44px; }
  .site-header .nav-cta { padding: 12px 15px; font-size: 0.84rem; }
}
@media (max-width: 960px) {
  .nav-shell { padding: 11px 11px 11px 14px; }
  .brand-mark { width: 46px; height: 46px; }
  .brand-text b { font-size: 1.2rem; }
  .brand-text small { font-size: 0.72rem; }
  .site-header .icon-btn { width: 48px; height: 48px; }
}
@media (max-width: 480px) {
  .nav-shell { padding: 10px 10px 10px 12px; border-radius: 18px; }
  .brand-mark { width: 44px; height: 44px; }
  .brand-text b { font-size: 1.15rem; }
  .site-header .icon-btn { width: 46px; height: 46px; }
}

/* ---------- Header: transparent at the top, solid once the page is scrolled ---------- */
.nav-shell { transition: background-color 0.35s, border-color 0.35s, box-shadow 0.35s; }
.site-header:not(.is-scrolled) .nav-shell {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
.site-header.is-scrolled .nav-shell {
  background: var(--surface);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}
/* keep it solid while the mobile menu is open, even at the top */
.site-header:has(.menu-btn[aria-expanded="true"]) .nav-shell { background: var(--surface); border-color: var(--line-2); }
.mobile-nav { background: var(--surface); backdrop-filter: none; -webkit-backdrop-filter: none; }
