:root {
  color-scheme: light;
  --bg: #efece3;
  --bg-2: #f7f2e8;
  --ink: #171511;
  --ink-soft: #3b382f;
  --muted: #777268;
  --muted-2: #9d978a;
  --line: rgba(23, 21, 17, 0.13);
  --line-strong: rgba(23, 21, 17, 0.24);
  --paper: rgba(255, 250, 239, 0.62);
  --paper-strong: rgba(255, 250, 239, 0.86);
  --teal: #2f6b73;
  --teal-2: #5d9595;
  --copper: #a86f45;
  --amber: #c8945e;
  --green: #7fb59b;
  --shadow: 0 30px 90px rgba(55, 45, 30, 0.12);
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --mono: "SF Mono", "JetBrains Mono", ui-monospace, Menlo, Consolas, "Liberation Mono", monospace;
  --mx: 50vw;
  --my: 50vh;
  --nx: 0;
  --ny: 0;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(900px 620px at var(--mx) var(--my), rgba(47, 107, 115, 0.13), transparent 62%),
    radial-gradient(820px 540px at 14% 4%, rgba(184, 121, 76, 0.12), transparent 58%),
    linear-gradient(135deg, var(--bg), #f4efe4 44%, #e9e2d4);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -2;
  background-image:
    linear-gradient(rgba(23, 21, 17, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 21, 17, 0.03) 1px, transparent 1px);
  background-size: 68px 68px;
  mask-image: radial-gradient(circle at 50% 12%, black, transparent 78%);
}
body::after {
  content: "";
  position: fixed;
  inset: auto 0 0;
  height: 36vh;
  pointer-events: none;
  background: linear-gradient(to top, rgba(239, 236, 227, 0.96), rgba(239, 236, 227, 0));
  z-index: -1;
}

#field {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: -3;
  opacity: 0.8;
}
.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 20;
  opacity: 0.14;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 160 160' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.55'/%3E%3C/svg%3E");
}

a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--teal); outline-offset: 4px; border-radius: 8px; }
button { font: inherit; }
::selection { background: rgba(47, 107, 115, 0.22); }

.shell { width: min(1180px, calc(100% - 48px)); margin: 0 auto; }
.section-pad { padding: clamp(88px, 13vw, 160px) 0; }
.mono { font-family: var(--mono); }
.nowrap { white-space: nowrap; }
.ok { color: var(--teal); }
.zh { display: none; }
html.lang-zh .en { display: none; }
html.lang-zh .zh { display: inline; }
html.lang-zh body { line-height: 1.7; }

.cursor-dot,
.cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 50;
  transform: translate3d(-100px, -100px, 0);
  display: none;
}
.cursor-dot {
  width: 6px;
  height: 6px;
  margin: -3px 0 0 -3px;
  border-radius: 50%;
  background: var(--ink);
}
.cursor-ring {
  width: 34px;
  height: 34px;
  margin: -17px 0 0 -17px;
  border-radius: 50%;
  border: 1px solid rgba(23, 21, 17, 0.42);
  transition: width .25s ease, height .25s ease, margin .25s ease, background-color .25s ease, border-color .25s ease;
}

.site-nav {
  position: fixed;
  inset: 0 0 auto 0;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(20px, 5vw, 64px);
  z-index: 30;
  color: rgba(23, 21, 17, 0.86);
  transition: height .35s ease, background-color .35s ease, border-color .35s ease, backdrop-filter .35s ease;
  border-bottom: 1px solid transparent;
  mix-blend-mode: multiply;
}
.site-nav.scrolled {
  height: 62px;
  background: rgba(239, 236, 227, 0.78);
  border-bottom-color: rgba(23, 21, 17, 0.08);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  mix-blend-mode: normal;
}
.brand, .nav-links { display: flex; align-items: center; gap: 18px; }
.brand { font-weight: 650; letter-spacing: -0.02em; }
.brand-mark {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 6px rgba(47, 107, 115, 0.12), 0 0 22px rgba(47, 107, 115, 0.36);
  animation: pulse 3.8s ease-in-out infinite;
}
.nav-links { gap: clamp(12px, 2.1vw, 28px); font-size: 13.5px; color: var(--muted); }
.nav-links a { transition: color .2s ease; }
.nav-links a:hover { color: var(--ink); }
.lang-toggle {
  border: 1px solid var(--line);
  background: rgba(255, 250, 239, 0.4);
  color: var(--ink-soft);
  border-radius: 999px;
  padding: 7px 12px;
  cursor: pointer;
  font-family: var(--mono);
  font-size: 12px;
}

.hero { min-height: 100vh; display: flex; align-items: center; padding-top: clamp(116px, 13vw, 170px); }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(360px, .98fr);
  gap: clamp(44px, 7vw, 92px);
  align-items: center;
}
.eyebrow, .section-kicker {
  margin: 0 0 18px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--copper);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.live-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 0 4px rgba(47, 107, 115, .14), 0 0 18px rgba(47, 107, 115, .34);
}
h1, h2 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.035em;
  line-height: .95;
}
h1 { font-size: clamp(58px, 9.4vw, 132px); max-width: 9.5ch; }
h1 em, h2 em { font-style: italic; color: var(--teal); }
h2 { font-size: clamp(42px, 6.2vw, 86px); max-width: 11ch; }
.lede {
  margin: 28px 0 0;
  max-width: 62ch;
  color: var(--ink-soft);
  font-size: clamp(16px, 1.45vw, 20px);
  font-weight: 320;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 34px; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 13px 21px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  font-size: 14px;
  will-change: transform;
  transition: background-color .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.btn.primary { background: var(--ink); color: var(--bg-2); box-shadow: 0 18px 42px rgba(23, 21, 17, .18); }
.btn.primary:hover { background: #2a271f; }
.btn.ghost { background: rgba(255, 250, 239, .4); color: var(--ink); }
.btn.ghost:hover { border-color: rgba(47, 107, 115, .38); background: rgba(255, 250, 239, .7); }
.micro-ledger {
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: 440px;
  margin-top: 44px;
  color: var(--muted);
  font-size: 12px;
}
.ledger-line { height: 1px; flex: 1; background: linear-gradient(90deg, transparent, rgba(47, 107, 115, .45), transparent); position: relative; overflow: hidden; }
.ledger-line::after { content: ""; position: absolute; inset: 0; width: 34%; background: linear-gradient(90deg, transparent, var(--teal), transparent); animation: scan 3.8s ease-in-out infinite; }

.hero-device {
  position: relative;
  min-height: clamp(640px, 48vw, 720px);
  transform-style: preserve-3d;
  will-change: transform;
}
.core-stage {
  position: absolute;
  top: 0;
  left: 56%;
  width: min(74vw, 500px);
  aspect-ratio: 1;
  transform: translateX(-50%);
  border-radius: 50%;
  display: grid;
  place-items: center;
}
.core-stage::before {
  content: "";
  position: absolute;
  inset: 12%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,250,239,.46), rgba(47,107,115,.08) 48%, transparent 70%);
  filter: blur(12px);
  animation: breathe 7s ease-in-out infinite;
}
.core-halo, .core-ring, .core-orbit { position: absolute; inset: 0; border-radius: 50%; }
.core-halo { border: 1px solid rgba(47, 107, 115, .12); }
.halo-a { inset: 3%; animation: breathe 9s ease-in-out infinite; }
.halo-b { inset: 17%; border-color: rgba(168, 111, 69, .18); animation: breathe 6.8s ease-in-out infinite reverse; }
.core-ring { border: 1px solid rgba(23, 21, 17, .2); }
.ring-one { inset: 23%; border-top-color: rgba(47, 107, 115, .72); animation: spin 18s linear infinite; }
.ring-two { inset: 34%; border-bottom-color: rgba(168, 111, 69, .72); animation: spin 13s linear infinite reverse; }
.core-orbit { inset: 8%; border: 1px dashed rgba(23, 21, 17, .14); animation: spin 26s linear infinite; }
.orbit-b { inset: 20%; animation-duration: 19s; animation-direction: reverse; }
.orbit-c { inset: 31%; animation-duration: 31s; }
.orbit-node {
  position: absolute;
  left: 50%;
  top: -15px;
  transform: translateX(-50%);
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(255, 250, 239, .82);
  border: 1px solid var(--line);
  color: var(--teal);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .08em;
  box-shadow: var(--shadow);
}
.core-center {
  position: relative;
  width: 132px;
  height: 132px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 2px;
  background: radial-gradient(circle at 40% 30%, #fffaf0, #dfd7c9);
  border: 1px solid rgba(23, 21, 17, .18);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.8), 0 30px 80px rgba(47,107,115,.2);
  animation: breathe 5.6s ease-in-out infinite;
}
.core-center span { color: var(--muted); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; }
.core-center strong { color: var(--teal); font-size: 24px; letter-spacing: .04em; }
.receipt-card {
  position: absolute;
  right: 3%;
  bottom: 0;
  width: min(88%, 360px);
  z-index: 2;
  padding: 20px;
  border: 1px solid rgba(23, 21, 17, .14);
  border-radius: 22px;
  background: rgba(255, 250, 239, .68);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}
.receipt-head, .receipt-row, .checksum, .card-top, .section-head, .footer-grid { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.receipt-head { margin-bottom: 18px; }
.receipt-row { padding: 10px 0; border-top: 1px solid rgba(23, 21, 17, .08); color: var(--muted); font-size: 13px; }
.receipt-row b { color: var(--ink); font-family: var(--mono); font-weight: 500; }
.receipt-seal { margin-top: 16px; padding: 14px; border-radius: 16px; background: rgba(47, 107, 115, .09); color: var(--teal); font-family: var(--serif); font-size: 20px; font-style: italic; }
.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 52px;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid rgba(47, 107, 115, .25);
  background: rgba(47, 107, 115, .09);
  color: var(--teal);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.status-pill.live { border-color: rgba(47,107,115,.28); }
.status-pill.wip { color: var(--copper); border-color: rgba(168,111,69,.28); background: rgba(168,111,69,.09); }

.trust-story { height: 380vh; position: relative; }
.story-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  background:
    radial-gradient(740px 520px at 78% 42%, rgba(47, 107, 115, .12), transparent 62%),
    linear-gradient(180deg, rgba(239,236,227,0), rgba(234,226,213,.72));
}
.story-grid {
  display: grid;
  grid-template-columns: .86fr 1fr .92fr;
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
}
.story-copy p:not(.section-kicker) { color: var(--ink-soft); max-width: 44ch; }
.story-machine { position: relative; min-height: 460px; }
.story-rail {
  position: absolute;
  left: 22px;
  top: 26px;
  bottom: 26px;
  width: 1px;
  background: rgba(23, 21, 17, .14);
  overflow: hidden;
}
.story-progress { display: block; width: 100%; height: 0%; background: linear-gradient(var(--teal), var(--copper)); transition: height .16s linear; }
.story-steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 18px; }
.story-steps li {
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 18px;
  align-items: start;
  opacity: .34;
  transform: translateY(18px);
  transition: opacity .35s ease, transform .35s ease;
}
.story-steps li.active { opacity: 1; transform: translateY(0); }
.step-index {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255,250,239,.72);
  border: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  transition: border-color .35s ease, color .35s ease, box-shadow .35s ease;
}
.story-steps li.active .step-index { color: var(--teal); border-color: rgba(47,107,115,.45); box-shadow: 0 0 0 7px rgba(47,107,115,.09); }
.story-steps b { display: block; font-size: clamp(18px, 2vw, 24px); letter-spacing: -0.02em; }
.story-steps small { color: var(--muted); font-size: 13px; }
.story-receipt {
  border: 1px solid rgba(23,21,17,.14);
  border-radius: 24px;
  background: rgba(20, 26, 25, .9);
  color: #ece7da;
  overflow: hidden;
  box-shadow: 0 38px 100px rgba(23, 21, 17, .22);
  transform: translateY(calc((1 - var(--story-p, 0)) * 30px));
}
.terminal-top {
  height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  color: rgba(236,231,218,.58);
}
.terminal-top i { width: 10px; height: 10px; border-radius: 50%; background: #766c5e; }
.terminal-top i:nth-child(1) { background: #b8794c; }
.terminal-top i:nth-child(2) { background: #d3b36e; }
.terminal-top i:nth-child(3) { background: #7fb59b; }
.story-receipt pre {
  margin: 0;
  min-height: 230px;
  padding: 22px;
  white-space: pre-wrap;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.9;
  color: rgba(236,231,218,.82);
}
.checksum { border-top: 1px solid rgba(255,255,255,.08); padding: 15px 18px; color: rgba(236,231,218,.52); font-family: var(--mono); font-size: 12px; }
.checksum b { color: #7fb59b; font-weight: 500; }

.stack { padding-top: clamp(110px, 14vw, 180px); }
.stack-flow { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: stretch; gap: 14px; margin-top: 34px; }
.stack-flow a {
  min-height: 160px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255,250,239,.48);
  box-shadow: 0 18px 52px rgba(55,45,30,.07);
  will-change: transform;
  overflow: hidden;
  position: relative;
}
.stack-flow a::after {
  content: "";
  position: absolute;
  inset: -40% -40% auto auto;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: rgba(47,107,115,.08);
  transition: transform .35s ease;
}
.stack-flow a:hover::after { transform: scale(1.6); }
.flow-verb { color: var(--copper); font-family: var(--mono); font-size: 11px; letter-spacing: .16em; }
.stack-flow b { font-family: var(--serif); font-size: 32px; font-weight: 400; letter-spacing: -0.02em; }
.stack-flow small { color: var(--muted); max-width: 22ch; }
.flow-arrow { align-self: center; color: var(--muted-2); font-family: var(--mono); }
.stack-note { margin: 22px 0 0; color: var(--ink-soft); max-width: 76ch; }
.stack-note a { color: var(--teal); border-bottom: 1px solid rgba(47,107,115,.25); }

.section-head { margin-bottom: 34px; align-items: end; }
.subtle-link { color: var(--muted); font-size: 14px; border-bottom: 1px solid rgba(23,21,17,.18); padding-bottom: 4px; }
.project-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.project-card {
  position: relative;
  min-height: 510px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(255,250,239,.55);
  box-shadow: 0 26px 70px rgba(55,45,30,.08);
  transform-style: preserve-3d;
  will-change: transform;
}
.project-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(420px 180px at var(--card-x, 50%) var(--card-y, 50%), rgba(255,255,255,.7), transparent 60%);
  transition: opacity .25s ease;
}
.project-card:hover::before { opacity: .9; }
.card-bg { position: absolute; inset: 0; opacity: .52; pointer-events: none; }
.trace-bg { background: linear-gradient(135deg, rgba(47,107,115,.1), transparent 54%), repeating-linear-gradient(0deg, transparent 0 23px, rgba(47,107,115,.08) 24px); }
.alfred-bg { background: radial-gradient(circle at 30% 20%, rgba(168,111,69,.18), transparent 34%), linear-gradient(135deg, transparent, rgba(47,107,115,.08)); }
.watch-bg { background: radial-gradient(circle at 50% 50%, transparent 0 20%, rgba(47,107,115,.1) 20% 21%, transparent 21% 36%, rgba(47,107,115,.1) 36% 37%, transparent 37%); }
.prov-bg { background: linear-gradient(135deg, rgba(168,111,69,.12), transparent), radial-gradient(circle at 74% 28%, rgba(47,107,115,.12), transparent 26%); }
.project-card > *:not(.card-bg) { position: relative; z-index: 1; }
.project-card h3 { margin: 54px 0 10px; font-family: var(--serif); font-size: clamp(31px, 3.1vw, 46px); font-weight: 400; letter-spacing: -0.03em; line-height: 1; }
.project-card p { color: var(--ink-soft); margin: 0; }
.card-note { margin-top: 22px !important; font-size: 13px; color: var(--muted) !important; }
.card-note b { color: var(--ink-soft); }
.card-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: auto; padding-top: 28px; }
.card-links a { color: var(--teal); font-family: var(--mono); font-size: 12px; border-bottom: 1px solid rgba(47,107,115,.25); }
.mini { margin: 30px 0 0; min-height: 96px; }
.timeline { display: flex; align-items: center; gap: 8px; }
.timeline i { height: 5px; flex: 1; border-radius: 999px; background: rgba(47,107,115,.18); position: relative; overflow: hidden; }
.timeline i::after { content: ""; position: absolute; inset: 0; transform: translateX(-100%); background: var(--teal); animation: fillbar 4s ease-in-out infinite; animation-delay: calc(var(--i, 0) * .2s); }
.timeline i:nth-child(2){--i:1}.timeline i:nth-child(3){--i:2}.timeline i:nth-child(4){--i:3}.timeline i:nth-child(5){--i:4}
.command { display: grid; gap: 9px; align-content: center; }
.command span { display: block; padding: 9px 11px; border-radius: 10px; background: rgba(23,21,17,.06); color: var(--muted); font-family: var(--mono); font-size: 11px; transform: translateX(0); animation: command 5s ease-in-out infinite; }
.command span:nth-child(2){animation-delay:.4s}.command span:nth-child(3){animation-delay:.8s;color:var(--teal)}
.radar { position: relative; border-radius: 50%; width: 112px; height: 112px; border: 1px solid rgba(47,107,115,.22); margin-left: auto; margin-right: auto; }
.radar::before { content: ""; position: absolute; inset: 8px; border-radius: 50%; border: 1px solid rgba(47,107,115,.18); }
.radar::after { content: ""; position: absolute; left: 50%; top: 50%; width: 50%; height: 1px; background: linear-gradient(90deg, var(--teal), transparent); transform-origin: left; animation: spin 4s linear infinite; }
.radar i { position: absolute; width: 7px; height: 7px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 5px rgba(47,107,115,.12); }
.radar i:nth-child(1){left:24px;top:30px}.radar i:nth-child(2){right:22px;top:58px}.radar i:nth-child(3){left:52px;bottom:22px}
.graph { position: relative; min-height: 112px; }
.graph::before { content: ""; position: absolute; inset: 16px 20px; background: linear-gradient(25deg, transparent 49%, rgba(47,107,115,.25) 50%, transparent 51%), linear-gradient(140deg, transparent 49%, rgba(168,111,69,.25) 50%, transparent 51%); }
.graph i { position: absolute; width: 16px; height: 16px; border-radius: 50%; background: rgba(255,250,239,.9); border: 1px solid rgba(47,107,115,.28); box-shadow: 0 0 0 6px rgba(47,107,115,.08); animation: pulse 3.4s ease-in-out infinite; }
.graph i:nth-child(1){left:22px;top:20px}.graph i:nth-child(2){right:42px;top:34px;animation-delay:.4s}.graph i:nth-child(3){left:74px;bottom:16px;animation-delay:.8s}.graph i:nth-child(4){right:18px;bottom:10px;animation-delay:1.2s}

.about-grid { display: grid; grid-template-columns: .75fr 1fr; gap: clamp(34px, 7vw, 96px); align-items: start; }
.about-copy { color: var(--ink-soft); font-size: clamp(16px, 1.35vw, 19px); }
.about-copy p { margin: 0 0 18px; max-width: 68ch; }
.availability { display: flex; align-items: center; gap: 10px; color: var(--teal); margin-top: 30px !important; font-size: 15px; }
.contact-row { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.contact-row a { padding: 11px 16px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); background: rgba(255,250,239,.42); font-size: 14px; }

.writing { padding-top: clamp(70px, 9vw, 110px); }
.writing-list { margin-top: 36px; border-top: 1px solid var(--line); }
.writing-item {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 28px;
  align-items: center;
  padding: 28px 4px;
  border-bottom: 1px solid var(--line);
  will-change: transform;
}
.writing-item b { display: block; font-family: var(--serif); font-weight: 400; font-size: clamp(24px, 3vw, 36px); letter-spacing: -0.02em; }
.writing-item small { display: block; margin-top: 7px; color: var(--muted); max-width: 72ch; }
.writing-item i { font-style: normal; color: var(--copper); font-family: var(--mono); font-size: 12px; white-space: nowrap; }

.site-footer { border-top: 1px solid var(--line); padding: 34px 0 44px; color: var(--muted); font-size: 13px; }
.footer-brand { font-family: var(--serif); color: var(--ink); font-size: 21px; }
.footer-links { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.footer-links a { color: var(--ink-soft); border-bottom: 1px solid rgba(23,21,17,.18); }
.visit-counter { display: none; align-items: center; gap: 8px; }
.visit-counter.ready { display: inline-flex; }

.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.delay-1 { transition-delay: .08s; }
.delay-2 { transition-delay: .16s; }
.delay-3 { transition-delay: .24s; }
.delay-4 { transition-delay: .32s; }

@keyframes breathe { 0%,100% { transform: scale(.985); opacity: .72; } 50% { transform: scale(1.045); opacity: 1; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 0%,100% { transform: scale(1); opacity: .76; } 50% { transform: scale(1.18); opacity: 1; } }
@keyframes scan { 0% { transform: translateX(-120%); } 54%,100% { transform: translateX(300%); } }
@keyframes fillbar { 0%, 12% { transform: translateX(-100%); } 42%, 100% { transform: translateX(0); } }
@keyframes command { 0%,100% { transform: translateX(0); opacity:.64; } 38%,64% { transform: translateX(8px); opacity:1; } }

@media (hover: hover) and (pointer: fine) {
  body:not(.reduce-motion) { cursor: none; }
  body:not(.reduce-motion) .cursor-dot,
  body:not(.reduce-motion) .cursor-ring { display: block; }
  body:not(.reduce-motion) a,
  body:not(.reduce-motion) button { cursor: none; }
}

@media (max-width: 1060px) {
  .hero-grid, .story-grid, .about-grid { grid-template-columns: 1fr; }
  .hero-device { min-height: 620px; }
  .core-stage { left: 50%; width: min(82vw, 500px); }
  .receipt-card { right: 50%; transform: translateX(50%); }
  .trust-story { height: auto; }
  .story-sticky { position: relative; height: auto; padding: 110px 0; }
  .story-grid { gap: 44px; }
  .story-machine { min-height: auto; }
  .story-receipt { max-width: 680px; }
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .shell { width: min(100% - 34px, 1180px); }
  .site-nav { height: 66px; padding: 0 17px; }
  .brand { gap: 8px; font-size: 13px; }
  .brand span:last-child { display: inline-block; max-width: 104px; overflow: hidden; text-overflow: clip; white-space: nowrap; }
  .nav-links { gap: 10px; font-size: 12px; }
  .nav-links a:nth-child(2), .nav-links a:nth-child(3) { display: none; }
  .lang-toggle { padding: 6px 9px; }
  .hero { padding-top: 104px; }
  h1 { font-size: clamp(54px, 18vw, 86px); }
  h2 { max-width: none; }
  .hero-device { min-height: 620px; }
  .core-stage { width: min(95vw, 390px); }
  .receipt-card { bottom: -8px; width: min(100%, 345px); }
  .stack-flow { grid-template-columns: 1fr; }
  .flow-arrow { transform: rotate(90deg); justify-self: start; margin-left: 28px; }
  .project-grid { grid-template-columns: 1fr; }
  .project-card { min-height: 430px; }
  .section-head, .footer-grid { align-items: start; flex-direction: column; }
  .writing-item { grid-template-columns: 1fr; gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
  #field, .cursor-dot, .cursor-ring { display: none !important; }
}
