:root {
  --bg: #1a2330;
  --panel: #243044;
  --ink: #e8eef6;
  --muted: #9aabc0;
  --dim: #6e7f94;
  --line: rgba(232, 238, 246, 0.1);
  --accent: #8eb6d9;
  --brand: #8eb6d9;
  --component: #5b8ec4;
  --teal: var(--accent);
  --teal-dim: rgba(142, 182, 217, 0.14);
  --on-brand: #1a2330;
  --page: 1080px;
  --gutter: clamp(16px, 4.2vw, 56px);
  --section: clamp(48px, 7vw, 80px);
}

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

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

body {
  font-family: Inter, system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
  max-width: 100%;
}

img,
svg,
video {
  max-width: 100%;
}

img {
  height: auto;
}

p,
h1,
h2,
h3,
h4,
h5,
li {
  overflow-wrap: break-word;
}

body.has-custom-cursor,
body.has-custom-cursor a,
body.has-custom-cursor button {
  cursor: none;
}

body.nav-lock {
  overflow: hidden;
}


p a {
  color: inherit;
  text-decoration: none;
}

p a:hover {
  text-decoration: underline;
}

.cursor-dot,
.cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 9999;
  border-radius: 50%;
  display: none;
}

body.has-custom-cursor .cursor-dot,
body.has-custom-cursor .cursor-ring {
  display: block;
}

.cursor-dot {
  width: 8px;
  height: 8px;
  background: var(--teal);
  mix-blend-mode: difference;
  z-index: 10000;
}

.cursor-ring {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(142, 182, 217, 0.4);
  z-index: 9998;
}

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  padding: calc(12px + env(safe-area-inset-top, 0px)) calc(var(--gutter) + env(safe-area-inset-right, 0px)) 12px calc(var(--gutter) + env(safe-area-inset-left, 0px));
  background: linear-gradient(to bottom, rgba(26, 35, 48, 0.94), transparent);
}

.header-inner {
  max-width: var(--page);
  margin: 0 auto;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  position: relative;
  min-width: 0;
}

.site-header.scrolled {
  background: rgba(26, 35, 48, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.brand {
  color: var(--ink);
  text-decoration: none;
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.brand span {
  font-weight: 700;
  font-size: 1.15rem;
}

.brand small {
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--dim);
}

.nav-toggle {
  width: 44px;
  height: 44px;
  margin-right: -10px;
  border: 0;
  background: none;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  z-index: 60;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.site-header.nav-open .nav-toggle span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.site-header.nav-open .nav-toggle span:nth-child(2) {
  opacity: 0;
}

.site-header.nav-open .nav-toggle span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.site-header nav {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: auto;
  width: min(280px, calc(100vw - 32px));
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  padding: 8px;
  background: rgba(26, 35, 48, 0.97);
  border: 1px solid var(--line);
  border-radius: 14px;
  backdrop-filter: blur(16px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
}

.site-header.nav-open nav {
  display: flex;
}

.site-header nav .nav-flip {
  display: block;
  height: auto;
  overflow: visible;
  padding: 12px 14px;
  font-size: 13px;
  letter-spacing: 0.1em;
}

.site-header nav .nav-flip span {
  height: auto;
  line-height: 1.3;
  white-space: normal;
}

.site-header nav .nav-flip span:last-child {
  display: none;
}

.site-header nav .nav-flip:hover {
  color: var(--teal);
}

.site-header nav .nav-flip:hover span {
  transform: none;
}

.nav-flip {
  position: relative;
  display: inline-block;
  height: 18px;
  line-height: 18px;
  overflow: hidden;
  color: var(--muted);
  text-decoration: none;
  font-size: 12px;
  letter-spacing: 0.08em;
  font-weight: 500;
  vertical-align: middle;
  z-index: 2;
}

.nav-flip span {
  display: block;
  height: 18px;
  line-height: 18px;
  white-space: nowrap;
  pointer-events: none;
  transition: transform 0.3s;
}

.nav-flip span:last-child {
  position: absolute;
  left: 0;
  top: 18px;
  color: var(--teal);
}

.nav-flip:hover span {
  transform: translateY(-18px);
}

.social-rail {
  position: fixed;
  left: 28px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 40;
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}

.social-rail a {
  color: var(--dim);
  width: 16px;
  height: 16px;
  transition: color 0.3s;
}

.social-rail a:hover {
  color: var(--teal);
}

.social-rail svg {
  width: 16px;
  height: 16px;
}

.rail-line {
  width: 1px;
  height: 64px;
  background: linear-gradient(to bottom, transparent, #6e7f94);
}

.rail-line.down {
  background: linear-gradient(to bottom, #6e7f94, transparent);
}

@media (min-width: 1100px) {
  .social-rail {
    display: flex;
  }
}

.hero {
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: calc(96px + env(safe-area-inset-top, 0px)) var(--gutter) 28px;
  position: relative;
}

.glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
}

.glow-a {
  width: min(500px, 80vw);
  height: min(500px, 80vw);
  background: rgba(142, 182, 217, 0.16);
  top: 18%;
  left: 18%;
}

.glow-b {
  width: min(400px, 70vw);
  height: min(400px, 70vw);
  background: rgba(91, 142, 196, 0.16);
  bottom: 18%;
  right: 18%;
}

.hero-grid,
.wide,
.narrow,
.career-wrap,
.contact-wrap,
.chat-bar-wrap {
  max-width: var(--page);
  margin: 0 auto;
  width: 100%;
}

.narrow {
  max-width: 720px;
  text-align: center;
}

.career-wrap,
.contact-wrap {
  max-width: var(--page);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: center;
  position: relative;
}

.hero-greeting {
  color: var(--muted);
  font-weight: 300;
  font-size: 1.2rem;
  margin-bottom: 16px;
}

.hero-name {
  font-size: clamp(2.5rem, 14vw, 6.5rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 0.92;
}

.hero-name span {
  color: var(--teal);
}

.hero-role {
  margin-top: 32px;
}

.hero-title {
  font-size: clamp(1.4rem, 3vw, 2.1rem);
  font-weight: 700;
}

.hero-role p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.95rem;
}

.hero-role strong {
  color: var(--teal);
  font-weight: 600;
}

.dot {
  color: var(--dim);
}

.hero-cta {
  margin-top: 32px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 24px;
}

.btn-resume {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border: 1px solid var(--brand);
  background: var(--brand);
  color: var(--on-brand);
  border-radius: 10px;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
}

.btn-resume svg {
  width: 16px;
  height: 16px;
}

.btn-resume:hover {
  background: #6a98c4;
  border-color: #6a98c4;
}

.link-touch {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
}

.link-touch:hover {
  color: var(--teal);
}

.hero-portrait {
  order: -1;
}

.portrait {
  position: relative;
  aspect-ratio: 4 / 5;
  width: 100%;
  max-width: min(280px, 70vw);
  margin: 0 auto;
  border-radius: 16px;
  overflow: hidden;
  background: #2c2c2c;
  border: 1px solid var(--line);
}

.portrait img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 28%;
}

.portrait p {
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 18px;
  z-index: 2;
  font-size: 0.9rem;
  color: #ffffff;
}

.portrait-fade {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(to top, #1a2330 8%, transparent 42%);
  pointer-events: none;
}

.chat-bar-wrap {
  padding: 8px var(--gutter) 20px;
}

.chat-bar {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--dim);
  font: inherit;
  text-align: left;
  min-width: 0;
}

.chat-bar span {
  flex: 1;
  font-size: 0.85rem;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chat-bar svg {
  width: 20px;
  height: 20px;
  color: rgba(142, 182, 217, 0.6);
  flex-shrink: 0;
}

.chat-bar em {
  font-style: normal;
  background: var(--teal-dim);
  color: var(--teal);
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 600;
  flex-shrink: 0;
}

.chat-bar:hover {
  border-color: rgba(142, 182, 217, 0.3);
}

section {
  padding: var(--section) var(--gutter);
}

#about {
  padding-top: 28px;
}

.divider {
  display: flex;
  align-items: center;
  max-width: var(--page);
  margin: 0 auto;
  width: 100%;
  padding: 4px var(--gutter);
  position: relative;
}

.div-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  color: var(--c);
  filter: drop-shadow(0 0 12px color-mix(in srgb, var(--c) 25%, transparent));
  z-index: 1;
  flex-shrink: 0;
}

.div-icon svg {
  width: 28px;
  height: 28px;
}

.div-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(232, 238, 246, 0.1), transparent);
}

.eyebrow {
  color: var(--teal);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 12px;
}

.lead {
  font-size: clamp(1.25rem, 2.2vw, 1.65rem);
  font-weight: 300;
  color: var(--ink);
  line-height: 1.55;
}

.body {
  margin-top: 18px;
  color: var(--muted);
  font-size: 1.02rem;
}

h2 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  letter-spacing: -0.03em;
  font-weight: 700;
}

.wide > .eyebrow,
.wide > h2,
.wide > .sub,
.career-wrap > h2,
.contact-wrap > .eyebrow {
  text-align: center;
}

.wide > h2,
.career-wrap > h2 {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.wide > .sub {
  margin: 8px auto 40px;
  max-width: 520px;
}

#what .split {
  align-items: start;
}

#what .display {
  text-align: center;
  margin: 0;
}

#reading .philo-grid {
  margin-top: 40px;
}

.display {
  font-size: clamp(2.2rem, 11vw, 4.6rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 0.95;
}

.dim {
  color: var(--dim);
}

.accent {
  color: var(--teal);
}

.sub {
  color: var(--dim);
  margin-top: 6px;
}

.split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: start;
}

.accordion {
  border-left: 1px dashed var(--line);
}

.acc-item {
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  border-top: 1px dashed var(--line);
  color: inherit;
  font: inherit;
  padding: 20px 0 20px 16px;
  display: grid;
  grid-template-columns: 1fr auto;
  cursor: pointer;
}

.acc-item:last-child {
  border-bottom: 1px dashed var(--line);
}

.acc-item:hover {
  background: rgba(142, 182, 217, 0.04);
}

.acc-item h3 {
  font-size: 1.1rem;
  letter-spacing: 0.04em;
}

.acc-item h4 {
  color: rgba(142, 182, 217, 0.8);
  font-size: 0.85rem;
  font-weight: 400;
  margin-top: 4px;
}

.acc-item p {
  display: none;
  grid-column: 1 / -1;
  color: var(--muted);
  font-size: 0.92rem;
  margin-top: 14px;
}

.acc-item.is-open p {
  display: block;
}

.chev {
  color: var(--dim);
  transition: transform 0.2s;
}

.acc-item.is-open .chev {
  transform: rotate(180deg);
}

.metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px 16px;
  text-align: center;
  max-width: var(--page);
  margin: 0 auto;
}

section.metrics {
  padding-top: 24px;
  padding-bottom: 24px;
}

.metric div {
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  font-weight: 800;
  color: var(--teal);
  margin-bottom: 10px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.metric-roll {
  display: inline-flex;
  align-items: flex-start;
}

.metric-roll-window {
  display: inline-block;
  height: 1em;
  overflow: hidden;
}

.metric-roll-strip {
  display: flex;
  flex-direction: column;
  will-change: transform;
  transition: transform 1.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.metric-roll-strip > span {
  display: block;
  height: 1em;
  line-height: 1;
}

.metric-roll-suffix {
  line-height: 1;
}

.metric p {
  color: var(--dim);
  font-size: 0.9rem;
}

.life-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 32px;
  align-items: start;
}

.pyramid {
  display: flex;
  flex-direction: column-reverse;
  gap: 8px;
}

.pyramid button {
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--muted);
  padding: 12px 16px;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 500;
}

.pyramid button.is-active {
  background: var(--teal-dim);
  border-color: rgba(142, 182, 217, 0.3);
  color: var(--teal);
}

.layer-card {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 12px;
  padding: 24px;
}

.layer-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--teal-dim);
  color: var(--teal);
  display: grid;
  place-items: center;
  margin-bottom: 12px;
}

.layer-card h4 {
  margin-bottom: 10px;
}

.layer-card p {
  color: var(--muted);
  font-size: 0.92rem;
}

.timeline {
  position: relative;
  margin: 32px auto 0;
  padding-left: 36px;
  max-width: 760px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, rgba(142, 182, 217, 0.6), rgba(142, 182, 217, 0.15), transparent);
}

.career-card {
  position: relative;
  margin-bottom: 48px;
}

.career-card .dot {
  position: absolute;
  left: -32px;
  top: 8px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--teal);
}

.career-card .pulse {
  box-shadow: 0 0 0 0 rgba(142, 182, 217, 0.5);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  70% {
    box-shadow: 0 0 0 10px transparent;
  }
}

.career-head {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px 16px;
}

.career-head h5 {
  color: rgba(142, 182, 217, 0.8);
  font-size: 0.9rem;
  font-weight: 500;
}

.career-head p,
.career-card > p,
time {
  color: var(--dim);
  font-size: 0.82rem;
}

.career-head time {
  font-family: "IBM Plex Mono", monospace;
}

.career-card > p {
  margin-top: 12px;
  max-width: 640px;
  font-size: 0.92rem;
  color: var(--muted);
}

.work-stage {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 32px;
  align-items: flex-start;
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
}

.work-num {
  display: none;
}

.work-kicker {
  color: rgba(142, 182, 217, 0.7);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 8px;
}

#work-content h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 16px;
}

#work-content p {
  color: var(--muted);
  max-width: 640px;
}

.work-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-top: 16px;
  font-size: 0.85rem;
}

.work-tools span {
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
}

.work-badge {
  margin-top: 16px;
  display: inline-block;
  max-width: 100%;
  padding: 12px 16px;
  border-radius: 8px;
  background: rgba(142, 182, 217, 0.05);
  border: 1px solid rgba(142, 182, 217, 0.1);
  color: var(--teal);
  font-size: 0.88rem;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.work-nav {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 40px;
}

.work-nav button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: none;
  color: var(--muted);
  font-size: 1rem;
}

.work-nav button:hover {
  color: var(--teal);
  border-color: rgba(142, 182, 217, 0.3);
}

.work-dots {
  display: flex;
  gap: 8px;
}

.work-dots button {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(232, 238, 246, 0.18);
  border: 0;
  padding: 0;
}

.work-dots button.is-active {
  width: 24px;
  background: var(--teal);
}

.stack-grid,
.build-grid,
.philo-grid {
  display: grid;
  gap: 20px;
  margin-top: 40px;
}

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

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

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

.stack-grid article,
.build-grid article,
.philo-grid article {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 12px;
  padding: 24px;
}

.build-grid article:hover,
.philo-grid article:hover,
.stack-grid article:hover {
  background: rgba(142, 182, 217, 0.06);
}

.stack-grid h3,
.build-grid h3,
.philo-grid h3 {
  margin-bottom: 16px;
}

.build-grid .tag {
  color: rgba(142, 182, 217, 0.8);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: -10px 0 16px;
}

.build-grid p,
.philo-grid p {
  color: var(--muted);
  font-size: 0.92rem;
}

.philo-grid .meta {
  color: var(--dim);
  font-size: 0.78rem;
  margin: -8px 0 12px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chips span {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 0.75rem;
  color: var(--muted);
  background: var(--panel);
}

.chips span:hover {
  border-color: rgba(142, 182, 217, 0.3);
  color: var(--teal);
}

.etl-box {
  margin-top: 32px;
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 12px;
  padding: 20px;
}

.etl-tabs {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  margin-bottom: 28px;
}

.etl-tabs button {
  text-align: left;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--bg);
  color: inherit;
  font: inherit;
  padding: 20px;
}

.etl-tabs button.is-active {
  border-color: rgba(142, 182, 217, 0.3);
  background: rgba(142, 182, 217, 0.05);
}

.etl-tabs h3 {
  font-size: 1.1rem;
}

.etl-tabs p,
.flow {
  color: var(--dim);
  font-size: 0.78rem;
  margin-top: 6px;
}

.arch {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 28px;
}

.arch-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  align-items: start;
}

.arch-label {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
}

.arch-nodes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.arch-nodes span {
  flex: 1;
  min-width: 90px;
  text-align: center;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--bg);
  font-size: 0.82rem;
}

.arch-nodes.mesh span {
  border-style: dashed;
  color: var(--muted);
}

.arch[data-mode="ptp"] [data-show="led"],
.arch[data-mode="led"] [data-show="ptp"] {
  display: none;
}

.arch[data-mode="led"] .arch-mid .arch-nodes span {
  border-color: rgba(142, 182, 217, 0.35);
  color: var(--accent);
}

.compare {
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}

.compare-head,
.compare-row {
  display: grid;
  grid-template-columns: 0.7fr 1.15fr 1.15fr;
}

.compare-head {
  display: none;
}

.compare-row {
  grid-template-columns: 1fr;
}

.compare-row span {
  border-right: 0;
}

.compare-row span:nth-child(2)::before,
.compare-row span:nth-child(3)::before {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
  margin-bottom: 4px;
}

.compare-row span:nth-child(2)::before {
  content: "Direct";
}

.compare-row span:nth-child(3)::before {
  content: "Layered";
}

.div-icon {
  width: 48px;
  height: 48px;
}

.div-icon svg {
  width: 24px;
  height: 24px;
}

.compare-head span,
.compare-row span {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  font-size: 0.85rem;
}

.compare-row span:last-child,
.compare-head span:last-child {
  border-right: 0;
}

.compare-row:last-child span {
  border-bottom: 0;
}

.compare-row span:first-child {
  color: var(--ink);
  font-weight: 500;
}

.compare[data-mode="ptp"] [data-col="ptp"],
.compare[data-mode="led"] [data-col="led"] {
  color: var(--accent);
  background: rgba(142, 182, 217, 0.06);
}

.compare[data-mode="ptp"] [data-col="led"],
.compare[data-mode="led"] [data-col="ptp"] {
  color: var(--dim);
}

.key-diff {
  margin-top: 20px;
  font-size: 0.8rem;
  color: var(--dim);
}

.key-diff strong {
  color: var(--muted);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  margin-top: 36px;
  text-align: center;
}

.contact-grid h4 {
  color: var(--dim);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.contact-grid a,
.contact-grid p {
  color: var(--ink);
  text-decoration: none;
  display: block;
  margin-bottom: 10px;
  overflow-wrap: anywhere;
}

.contact-grid a {
  transition: color 0.3s ease;
}

.contact-grid a:hover {
  color: var(--teal);
}

.contact-grid a.contact-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.contact-link svg {
  width: 14px;
  height: 14px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.contact-link:hover svg {
  opacity: 1;
}

@media (hover: none) {
  .contact-link svg {
    opacity: 0.85;
  }
}

#contact footer {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: center;
  color: var(--dim);
  font-size: 0.75rem;
  max-width: var(--page);
}

#contact footer span {
  color: var(--teal);
}

.chat-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(26, 35, 48, 0.62);
  display: grid;
  place-items: end center;
  padding: 0;
}

.chat-modal[hidden] {
  display: none;
}

.chat-panel {
  width: 100%;
  height: min(100dvh, 100%);
  max-height: 100dvh;
  background: var(--panel);
  border: 0;
  border-radius: 16px 16px 0 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

.chat-panel header {
  display: flex;
  justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
}

.chat-panel header p {
  color: var(--dim);
  font-size: 0.78rem;
}

.chat-panel header button {
  background: none;
  border: 0;
  color: var(--muted);
  font-size: 1.1rem;
}

.chat-log {
  flex: 1;
  overflow: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.bubble {
  max-width: 85%;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 0.88rem;
}

.bubble.bot {
  align-self: flex-start;
  background: rgba(142, 182, 217, 0.08);
  color: var(--ink);
}

.bubble.user {
  align-self: flex-end;
  background: rgba(142, 182, 217, 0.1);
}

.suggest {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.suggest button {
  border: 1px solid var(--line);
  background: none;
  color: var(--teal);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.72rem;
}

#chat-form {
  display: flex;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid var(--line);
}

#chat-form button {
  flex-shrink: 0;
}

#chat-form input {
  flex: 1;
  background: rgba(142, 182, 217, 0.06);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  padding: 10px 12px;
  font: inherit;
}

#chat-form button {
  background: var(--brand);
  color: var(--on-brand);
  border: 0;
  border-radius: 10px;
  padding: 0 16px;
  font-weight: 600;
}

.fade-in {
  animation: rise 0.8s ease both;
}

.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition:
    opacity 0.8s cubic-bezier(0.215, 0.61, 0.355, 1),
    transform 0.8s cubic-bezier(0.215, 0.61, 0.355, 1);
  transition-delay: var(--d, 0ms);
}

.reveal.is-in {
  opacity: 1;
  transform: none;
}

.divider.reveal-icon .div-icon {
  opacity: 0;
  transform: scale(0.5) rotate(-90deg);
}

.divider.reveal-icon.is-in .div-icon {
  opacity: 1;
  transform: none;
  transition:
    opacity 1s cubic-bezier(0.34, 1.56, 0.64, 1),
    transform 1s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@media (prefers-reduced-motion: reduce) {
  .fade-in,
  .reveal,
  .divider.reveal-icon .div-icon {
    animation: none;
    opacity: 1;
    transform: none;
    transition: none;
  }
}

.hero-name {
  animation-delay: 0.08s;
}
.hero-role {
  animation-delay: 0.16s;
}
.hero-cta,
.hero-portrait {
  animation-delay: 0.24s;
}

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

.soon {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(120px + env(safe-area-inset-top, 0px)) var(--gutter) 64px;
}

.soon h1 {
  font-size: clamp(2.2rem, 12vw, 5.5rem);
  letter-spacing: -0.04em;
  font-weight: 800;
  margin: 8px 0 16px;
}

.soon .lede {
  color: var(--muted);
  max-width: 420px;
  margin-bottom: 32px;
}

@media (min-width: 480px) {
  .metrics-grid {
    gap: 24px;
  }

  .chat-bar {
    padding: 16px 20px;
    border-radius: 999px;
  }
}

@media (min-width: 640px) {
  .stack-grid,
  .build-grid,
  .philo-grid,
  .metrics-grid {
    grid-template-columns: 1fr 1fr;
  }

  .etl-tabs {
    grid-template-columns: 1fr 1fr;
  }

  #contact footer {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }

  .div-icon {
    width: 56px;
    height: 56px;
  }

  .div-icon svg {
    width: 28px;
    height: 28px;
  }
}

@media (min-width: 768px) {
  .compare-head {
    display: grid;
    grid-template-columns: 0.7fr 1.15fr 1.15fr;
    background: var(--bg);
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--dim);
  }

  .compare-row {
    grid-template-columns: 0.7fr 1.15fr 1.15fr;
  }

  .compare-row span {
    border-right: 1px solid var(--line);
  }

  .compare-row span:nth-child(2)::before,
  .compare-row span:nth-child(3)::before {
    content: none;
  }

  .arch-row {
    grid-template-columns: 110px 1fr;
    gap: 12px;
    align-items: center;
  }

  .etl-box {
    padding: 32px;
  }

  .acc-item {
    padding: 28px 0 28px 32px;
  }

  .timeline {
    padding-left: 48px;
  }

  .career-card .dot {
    left: -44px;
  }

  .chat-modal {
    place-items: center;
    padding: 24px;
  }

  .chat-panel {
    width: min(560px, 100%);
    height: min(640px, 90vh);
    max-height: 90vh;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding-bottom: 0;
  }
}

@media (min-width: 900px) {
  .hero-grid {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
  }

  .hero-portrait {
    order: 0;
  }

  .portrait {
    margin-left: auto;
    margin-right: 0;
    max-width: 400px;
  }

  .split {
    grid-template-columns: 0.85fr 1.15fr;
    gap: 48px;
  }

  #what .split {
    align-items: center;
  }

  #what .display {
    text-align: left;
  }

  .life-grid {
    grid-template-columns: 1.3fr 1fr;
    gap: 40px;
  }

  .metrics-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .philo-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .contact-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
  }

  .work-stage {
    flex-direction: row;
    gap: 40px;
  }

  .work-num {
    display: block;
    font-size: clamp(3rem, 6vw, 4.5rem);
    font-weight: 800;
    font-family: "IBM Plex Mono", monospace;
    color: rgba(232, 238, 246, 0.1);
    line-height: 1;
    flex-shrink: 0;
  }

  .chat-bar span {
    font-size: 0.9rem;
  }
}

@media (min-width: 1024px) {
  .nav-toggle {
    display: none;
  }

  .site-header nav,
  .site-header.nav-open nav {
    display: flex;
    position: static;
    width: auto;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 16px 22px;
    padding: 0;
    background: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    backdrop-filter: none;
  }

  .site-header nav .nav-flip {
    display: inline-block;
    height: 18px;
    overflow: hidden;
    padding: 0;
    font-size: 12px;
  }

  .site-header nav .nav-flip span {
    height: 18px;
    line-height: 18px;
  }

  .site-header nav .nav-flip span:last-child {
    display: block;
  }

  .site-header nav .nav-flip:hover span {
    transform: translateY(-18px);
  }

  .stack-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (min-width: 1100px) {
  .social-rail {
    display: flex;
    left: max(16px, env(safe-area-inset-left, 0px));
  }
}

@media (max-height: 500px) and (orientation: landscape) {
  .hero {
    min-height: auto;
    padding-top: calc(88px + env(safe-area-inset-top, 0px));
    padding-bottom: 32px;
  }

  .hero-portrait {
    order: 0;
  }

  .portrait {
    max-width: 180px;
  }

  .glow-a,
  .glow-b {
    width: 220px;
    height: 220px;
  }
}
