/* ------------------------------------------------------------------
   Sandeep Vijayarao, portfolio
   Theme: dark, locked site-wide. Emerald base + per-domain hues.
   Radius system: surfaces 20px, interactive pills, inline tokens 6px.
   Motion: strong ease-out entrances, asymmetric page transitions
   (exit 180ms, enter 460ms), hover effects gated to fine pointers.
------------------------------------------------------------------- */

@font-face {
  font-family: "Geist";
  src: url("/assets/fonts/geist-var.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Geist Mono";
  src: url("/assets/fonts/geist-mono-var.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --bg: #0b0c0f;
  --bg-2: #101218;
  --surface: #14171d;
  --line: #232830;
  --text: #e9ecf1;
  --muted: #98a2ad;
  --accent: #34d399;
  --accent-ink: #07150e;
  --accent-rgb: 52, 211, 153;
  --accent-dim: rgba(52, 211, 153, 0.13);

  /* domain hues. --accent is re-pointed per card/page via [data-hue]. */
  --hue-agent: #34d399;
  --hue-agent-rgb: 52, 211, 153;
  --hue-vision: #38bdf8;
  --hue-vision-rgb: 56, 189, 248;
  --hue-llm: #a78bfa;
  --hue-llm-rgb: 167, 139, 250;
  --hue-product: #fbbf24;
  --hue-product-rgb: 251, 191, 36;
  --hue-tools: #fb7185;
  --hue-tools-rgb: 251, 113, 133;
  --sans: "Geist", system-ui, -apple-system, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", monospace;
  --r-surface: 20px;
  --r-token: 6px;
  --ease: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-io: cubic-bezier(0.77, 0, 0.175, 1);
  --container: 1120px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-padding-top: 5rem; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ambient accent glow behind every page */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(60% 42% at 50% -12%, rgba(var(--accent-rgb), 0.055), transparent 70%);
}

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 1.5rem;
}

a { color: inherit; }

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

::selection { background: var(--accent); color: var(--accent-ink); }

.skip {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 100;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 0.5rem 1rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  transition: top 200ms var(--ease);
}
.skip:focus { top: 1rem; }

#top-sentinel { position: absolute; top: 0; height: 1px; width: 1px; }

/* ---------- cross-page view transitions ---------- */

@view-transition { navigation: auto; }

.nav { view-transition-name: site-nav; }
.footer { view-transition-name: site-footer; }

@media (prefers-reduced-motion: no-preference) {
  /* exit fast, enter slower: the page you leave gets out of the way */
  ::view-transition-old(root) {
    animation: vt-out 180ms var(--ease) both;
  }
  ::view-transition-new(root) {
    animation: vt-in 460ms var(--ease) both;
  }
}

/* nav and footer stay still while content glides */
::view-transition-old(site-nav),
::view-transition-new(site-nav),
::view-transition-old(site-footer),
::view-transition-new(site-footer) {
  animation: none;
}

@keyframes vt-out {
  to { opacity: 0; }
}
@keyframes vt-in {
  from { opacity: 0; transform: translateY(14px); }
}

@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(root),
  ::view-transition-new(root) { animation: none; }
}

/* ---------- nav ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 64px;
  display: flex;
  align-items: center;
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 300ms var(--ease);
}
.nav.scrolled { border-bottom-color: var(--line); }

.nav-inner {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-name {
  font-weight: 600;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.nav nav { display: flex; gap: 1.75rem; }

.nav nav a {
  position: relative;
  text-decoration: none;
  color: var(--muted);
  font-size: 0.92rem;
  transition: color 200ms ease;
}
.nav nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -5px;
  width: 100%;
  height: 1.5px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 280ms var(--ease);
}
.nav nav a[aria-current="page"] { color: var(--text); }
.nav nav a[aria-current="page"]::after { transform: scaleX(1); }

/* ---------- page header (sub-pages) ---------- */

.page-header { padding-block: 5.5rem 1rem; }

.page-header h1 {
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 650;
  letter-spacing: -0.04em;
  line-height: 1.05;
}

.page-header .lede {
  margin-top: 1rem;
  color: var(--muted);
  font-size: 1.08rem;
  max-width: 38rem;
}

@media (prefers-reduced-motion: no-preference) {
  .page-header h1,
  .page-header .lede {
    animation: rise 600ms var(--ease) both;
  }
  .page-header .lede { animation-delay: 70ms; }
}

/* ---------- project case studies ---------- */

.case-context {
  margin-top: 0.8rem;
  color: var(--accent);
  font-size: 0.95rem;
}

@media (prefers-reduced-motion: no-preference) {
  .page-header .case-context { animation: rise 600ms var(--ease) both 40ms; }
}

.case-strip {
  border-block: 1px solid var(--line);
  background: var(--bg-2);
  margin-top: 3rem;
}

.case-strip-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  padding-block: 2.2rem;
}

.case-strip .stat-num { font-size: clamp(1.8rem, 3.2vw, 2.4rem); }

.case-body {
  max-width: calc(46rem + 3rem);
  margin-inline: auto;
  padding-block: 1rem 4.5rem;
}

.case-body h2 {
  font-size: 1.3rem;
  margin-top: 3rem;
  margin-bottom: 1rem;
}

.case-body p {
  color: var(--muted);
  max-width: 65ch;
}
.case-body p + p { margin-top: 1rem; }

.case-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  color: var(--muted);
  max-width: 65ch;
}
.case-list li {
  padding-left: 1.3rem;
  position: relative;
}
.case-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.case-tags { margin-top: 0.4rem; }

.case-actions { margin-top: 3rem; }
.case-note { font-size: 0.92rem; }

/* ---------- hero (home) ---------- */

.hero {
  min-height: min(calc(100dvh - 64px), 53rem);
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  align-items: center;
  gap: 3.5rem;
  padding-block: 3rem;
}

.hero h1 {
  font-size: clamp(2.5rem, 5.6vw, 4.1rem);
  font-weight: 650;
  letter-spacing: -0.04em;
  line-height: 1.04;
}

.hero-sub {
  margin-top: 1.4rem;
  color: var(--muted);
  font-size: 1.08rem;
  max-width: 34rem;
}

.hero-actions {
  margin-top: 2.2rem;
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.78rem 1.5rem;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 160ms var(--ease), background 200ms ease, border-color 200ms ease;
}
.btn:active { transform: scale(0.97); }

.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
}

.btn-ghost {
  border: 1px solid var(--line);
  color: var(--text);
}

.ext { font-size: 0.85em; }

.hero-visual {
  position: relative;
  aspect-ratio: 1 / 1.04;
  border: 1px solid var(--line);
  border-radius: var(--r-surface);
  background: radial-gradient(120% 90% at 70% 20%, var(--bg-2) 0%, var(--bg) 70%);
  overflow: hidden;
}
.hero-visual canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* ---------- proof strip ---------- */

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

.proof-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  padding-block: 1.9rem;
}

.proof-item { display: flex; flex-direction: column; gap: 0.15rem; }
.proof-item strong { font-weight: 600; letter-spacing: -0.01em; }
.proof-item span { color: var(--muted); font-size: 0.92rem; }

/* ---------- sections ---------- */

section.work, section.about, section.contact, section.teaser, section.next {
  padding-block: 5.5rem;
}

h2 {
  font-size: clamp(1.7rem, 3.2vw, 2.4rem);
  font-weight: 640;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.6rem;
}

.section-head .more-link {
  color: var(--muted);
  font-size: 0.95rem;
  text-decoration: none;
  transition: color 200ms ease;
}

/* ---------- domain hues ---------- */
/* Re-point --accent on a scope and every accent-driven rule inside it
   (metric, arrow, tint, hover border, sheen) follows. */

[data-hue="agent"]   { --accent: var(--hue-agent);   --accent-rgb: var(--hue-agent-rgb); }
[data-hue="vision"]  { --accent: var(--hue-vision);  --accent-rgb: var(--hue-vision-rgb); }
[data-hue="llm"]     { --accent: var(--hue-llm);     --accent-rgb: var(--hue-llm-rgb); }
[data-hue="product"] { --accent: var(--hue-product); --accent-rgb: var(--hue-product-rgb); }
[data-hue="tools"]   { --accent: var(--hue-tools);   --accent-rgb: var(--hue-tools-rgb); }

[data-hue] { --accent-dim: rgba(var(--accent-rgb), 0.13); }

/* amber needs a darker ink than the emerald default to stay readable */
[data-hue="product"] { --accent-ink: #1a1203; }

/* ---------- work cards ---------- */

.card {
  display: block;
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-surface);
  padding: 1.75rem;
  text-decoration: none;
  transition: transform 250ms var(--ease), border-color 250ms var(--ease);
}
a.card:active { transform: translateY(-1px) scale(0.995); }

.card h3 {
  font-size: 1.12rem;
  font-weight: 620;
  letter-spacing: -0.015em;
}

.card p {
  margin-top: 0.6rem;
  color: var(--muted);
  font-size: 0.95rem;
  max-width: 56ch;
}

.card .metric {
  font-family: var(--mono);
  font-size: 0.82rem;
  color: var(--accent);
  margin-top: 0.85rem;
}

.tags {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1.1rem;
}
.tags li {
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: var(--r-token);
  padding: 0.22rem 0.55rem;
}

.card-arrow {
  position: absolute;
  top: 1.4rem;
  right: 1.5rem;
  color: var(--muted);
  transition: color 200ms ease, transform 250ms var(--ease);
}

/* featured cards */

.card-featured {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 2.5rem;
  padding: 2.4rem;
  background:
    radial-gradient(90% 130% at 100% 0%, var(--accent-dim) 0%, transparent 55%),
    var(--surface);
  margin-bottom: 1.25rem;
}

.card-featured h3 { font-size: 1.45rem; }

.card-context {
  font-size: 0.88rem;
  color: var(--accent);
  margin-top: 0.35rem !important;
}

.card-link-hint {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 1.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent);
}

.card-featured-stats {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.6rem;
  border-left: 1px solid var(--line);
  padding-left: 2.5rem;
}

.stat-num {
  display: block;
  font-family: var(--mono);
  font-size: clamp(2rem, 3.6vw, 2.8rem);
  font-weight: 560;
  letter-spacing: -0.03em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
.stat-label { color: var(--muted); font-size: 0.9rem; }

/* mirrored featured variant: stats on the left */
.card-featured-alt {
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  background:
    radial-gradient(90% 130% at 0% 100%, var(--accent-dim) 0%, transparent 55%),
    var(--surface);
}
.card-featured-alt .card-featured-stats {
  border-left: 0;
  border-right: 1px solid var(--line);
  padding-left: 0;
  padding-right: 2.5rem;
}

article.card { cursor: default; }

/* asymmetric grid */

.work-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.span-2 { grid-column: span 2; }
.span-3 { grid-column: 1 / -1; }

.card-grid-bg {
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 28px 28px;
  background-position: -1px -1px;
}

.card-tint {
  background:
    radial-gradient(120% 120% at 0% 100%, var(--accent-dim) 0%, transparent 50%),
    var(--surface);
}

.work-more {
  margin-top: 2.2rem;
  color: var(--muted);
  font-size: 0.95rem;
}
.work-more a {
  color: var(--text);
  text-decoration-color: var(--accent);
  text-underline-offset: 3px;
}

/* ---------- experience / education rows ---------- */

.block { padding-block: 3.5rem 1rem; }
.block h2 { margin-bottom: 2rem; }

.exp-row {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 2.5rem;
  padding-block: 1.8rem;
  border-top: 1px solid var(--line);
}
.exp-row:last-child { border-bottom: 1px solid var(--line); }

.exp-head h3 {
  font-size: 1.05rem;
  font-weight: 620;
  letter-spacing: -0.01em;
}
.exp-org { color: var(--text); font-size: 0.95rem; margin-top: 0.15rem; }
.exp-dates {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 0.4rem;
}
.exp-desc { color: var(--muted); font-size: 0.95rem; max-width: 58ch; }

/* ---------- about ---------- */

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: 4rem;
}

.about-bio p {
  color: var(--muted);
  max-width: 60ch;
}
.about-bio p + p { margin-top: 1.1rem; }

.about-stack { display: flex; flex-direction: column; }

.stack-group { padding-block: 1.3rem; }
.stack-group + .stack-group { border-top: 1px solid var(--line); }
.stack-group:first-child { padding-top: 0; }

.stack-group h3 {
  font-size: 0.95rem;
  font-weight: 620;
  margin-bottom: 0.35rem;
}
.stack-group .tags { margin-top: 0.6rem; }

/* ---------- contact ---------- */

.contact { padding-block: 6.5rem; }

.contact h2, .contact .page-title { max-width: 24ch; }

.contact-email {
  display: inline-block;
  margin-top: 2rem;
  font-family: var(--mono);
  font-size: clamp(1.1rem, 2.6vw, 1.7rem);
  letter-spacing: -0.02em;
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 200ms ease;
}

.contact-links {
  margin-top: 2.4rem;
  display: flex;
  gap: 1.6rem;
  flex-wrap: wrap;
}
.contact-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 200ms ease;
}

/* ---------- next-page links (home closer & page footers) ---------- */

.next { border-top: 1px solid var(--line); padding-block: 4.5rem 5.5rem; }

.next-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 1.6rem;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  transition: padding-left 250ms var(--ease);
}
.next-link:first-of-type { border-top: 1px solid var(--line); }

.next-link strong {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 630;
  letter-spacing: -0.03em;
}
.next-link span { color: var(--muted); font-size: 0.95rem; }
.next-link .ext { color: var(--muted); font-size: 1.3rem; transition: color 200ms ease, transform 250ms var(--ease); }

/* ---------- footer ---------- */

.footer {
  border-top: 1px solid var(--line);
  padding-block: 1.6rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 0.88rem;
}

.footer-links { display: flex; gap: 1.25rem; }
.footer-links a {
  color: var(--muted);
  text-decoration: none;
  transition: color 200ms ease;
}

/* ---------- entrance + reveal motion ---------- */

@media (prefers-reduced-motion: no-preference) {
  [data-reveal] {
    opacity: 0;
    transform: translateY(16px);
    transition:
      opacity 600ms var(--ease) var(--d, 0s),
      transform 600ms var(--ease) var(--d, 0s);
  }
  [data-reveal].in {
    opacity: 1;
    transform: none;
  }

  .hero-copy h1,
  .hero-sub,
  .hero-actions,
  .hero-visual {
    animation: rise 700ms var(--ease) both;
  }
  .hero-sub { animation-delay: 70ms; }
  .hero-actions { animation-delay: 140ms; }
  .hero-visual { animation-delay: 100ms; }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

/* headline word-rise: spans injected by script.js, never under reduced motion */
@media (prefers-reduced-motion: no-preference) {
  .hero h1.split,
  .page-header h1.split { animation: none; }

  .h-word {
    display: inline-block;
    opacity: 0;
    transform: translateY(0.55em);
    filter: blur(6px);
    animation: word-rise 640ms var(--ease) both;
    animation-delay: calc(var(--wi) * 60ms);
  }

  @keyframes word-rise {
    to { opacity: 1; transform: none; filter: blur(0); }
  }
}

/* ---------- hover effects: fine pointers only ---------- */

@media (hover: hover) and (pointer: fine) {
  .nav nav a:hover { color: var(--text); }
  .nav nav a:hover::after { transform: scaleX(1); }

  /* cursor-tracked spotlight sheen on linked cards */
  a.card::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    opacity: 0;
    transition: opacity 350ms ease;
    background: radial-gradient(
      260px circle at var(--mx, 50%) var(--my, 50%),
      rgba(var(--accent-rgb), 0.09),
      transparent 65%
    );
  }
  a.card:hover::after { opacity: 1; }
  .btn-primary:hover { background: #4be0a8; }
  .btn-ghost:hover { border-color: var(--muted); }
  .section-head .more-link:hover { color: var(--text); }

  a.card:hover {
    transform: translateY(-3px);
    border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  }
  a.card:hover .card-arrow {
    color: var(--accent);
    transform: translate(2px, -2px);
  }
  a.card:hover .tags li {
    border-color: color-mix(in srgb, var(--accent) 30%, var(--line));
    color: var(--text);
  }

  .contact-email:hover { border-bottom-color: var(--accent); }
  .contact-links a:hover { color: var(--text); }
  .footer-links a:hover { color: var(--text); }

  .next-link:hover { padding-left: 0.8rem; }
  .next-link:hover .ext {
    color: var(--accent);
    transform: translate(3px, -3px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .next-link { transition: none; }
}

/* ---------- mobile collapse ---------- */

@media (max-width: 880px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 2.5rem;
    min-height: 0;
    padding-block: 4rem 3rem;
  }
  .hero-visual { aspect-ratio: 16 / 10; }

  .card-featured {
    grid-template-columns: 1fr;
    gap: 1.8rem;
    padding: 1.75rem;
  }
  .card-featured-stats {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding-left: 0;
    padding-top: 1.6rem;
    flex-direction: row;
    gap: 2.5rem;
  }
  .card-featured-alt .card-featured-stats {
    border-right: 0;
    padding-right: 0;
    order: 2;
  }

  .proof-grid { grid-template-columns: 1fr 1fr; }

  .exp-row { grid-template-columns: 1fr; gap: 0.8rem; }

  .work-grid { grid-template-columns: 1fr 1fr; }
  .span-2 { grid-column: span 2; }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
}

@media (max-width: 640px) {
  .container { padding-inline: 1.1rem; }

  .nav nav { gap: 1.1rem; }
  .nav nav a { font-size: 0.88rem; }

  .page-header { padding-block: 3.5rem 0.5rem; }

  .proof-grid {
    grid-template-columns: 1fr;
    gap: 1.1rem;
    padding-block: 1.5rem;
  }

  .case-strip-grid {
    grid-template-columns: 1fr;
    gap: 1.4rem;
    padding-block: 1.6rem;
  }
  .case-strip { margin-top: 2rem; }

  section.work, section.about, section.contact, section.teaser, section.next {
    padding-block: 3.5rem;
  }
  .contact { padding-block: 4.5rem; }

  .work-grid { grid-template-columns: 1fr; }
  .span-2, .span-3 { grid-column: auto; }

  .card-featured-stats { flex-direction: column; gap: 1.2rem; }
}

/* ============================================================
   Colour pass: bring the existing domain hues forward.

   The five hues already existed and were re-pointed per [data-hue];
   they were just barely spent. Nothing new is invented here, the
   same five variables are simply used in the places that carry the
   most visual weight: the numbers, the chips, the card edges.
   ============================================================ */

/* The proof numbers are the most looked-at elements on the site and
   they were plain text. Tinting them is the single biggest change. */
.stat-num {
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}
.stat-label { color: var(--muted); }

/* Every card already declares its domain; show it, rather than
   revealing it only on hover. A hairline top edge reads as a colour
   mosaic across the grid without shouting. */
a.card {
  border-top: 2px solid color-mix(in srgb, var(--accent) 55%, var(--line));
}
a.card:hover {
  border-top-color: var(--accent);
}

/* Tag chips were uniform grey on every card. Tinting the border and
   warming the text keeps them legible at 0.74rem while letting the
   card's domain colour carry through. */
.tags li {
  color: color-mix(in srgb, var(--accent) 38%, var(--text));
  border-color: color-mix(in srgb, var(--accent) 22%, var(--line));
  background: rgba(var(--accent-rgb), 0.05);
}

/* Section headings get a short colour rule, so the eye finds the
   structure of a long case study without extra chrome. */
.case-body h2 {
  position: relative;
  padding-left: 0.85rem;
}
.case-body h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.18em;
  bottom: 0.18em;
  width: 3px;
  border-radius: 2px;
  background: var(--accent);
}

/* The case-study stat band sat on the page background. A faint wash
   in the page's own hue ties it to the project it belongs to. */
.case-strip {
  background:
    linear-gradient(180deg, rgba(var(--accent-rgb), 0.06), transparent 85%);
  border-top: 1px solid color-mix(in srgb, var(--accent) 16%, var(--line));
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 16%, var(--line));
}

/* Case-study titles pick up a tint so each project page feels like
   its own place rather than a template. */
.page-header h1 {
  background: linear-gradient(
    180deg, var(--text) 55%, color-mix(in srgb, var(--accent) 45%, var(--text)));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* script.js splits these headings into .h-word spans, and those spans are
   inline-block + transformed, so their glyphs are painted outside the h1's
   own text-clip - the title above would come out invisible. Re-apply the
   inherited gradient on each span so the clip has glyphs to bite on. The
   gradient is vertical and every word shares a baseline, so the words stay
   visually identical to one uninterrupted fill. */
.page-header h1 .h-word {
  background-image: inherit;
  -webkit-background-clip: text;
  background-clip: text;
}

/* The homepage credibility row was monochrome. Give each item its
   own hue so the strip reads as four distinct things. */
.proof-item:nth-child(1) { --accent: var(--hue-agent);   --accent-rgb: var(--hue-agent-rgb); }
.proof-item:nth-child(2) { --accent: var(--hue-llm);     --accent-rgb: var(--hue-llm-rgb); }
.proof-item:nth-child(3) { --accent: var(--hue-vision);  --accent-rgb: var(--hue-vision-rgb); }
.proof-item:nth-child(4) { --accent: var(--hue-product); --accent-rgb: var(--hue-product-rgb); }
.proof-item strong {
  color: var(--accent);
}
.proof-item {
  padding-left: 0.8rem;
  border-left: 2px solid color-mix(in srgb, var(--accent) 50%, transparent);
}

/* Footer and nav links pick up the accent on hover for consistency
   with the rest of the interaction language. */
.footer-links a:hover,
.more-link:hover { color: var(--accent); }

/* Respect the same reduced-motion / contrast contract the site
   already honours elsewhere. */
@media (prefers-contrast: more) {
  .tags li { color: var(--text); background: none; }
  .page-header h1,
  .page-header h1 .h-word { color: var(--text); background: none;
    -webkit-text-fill-color: currentColor; }
}
