:root {
  color-scheme: dark;

  /* surfaces */
  --bg: #0a0a10;
  --card: rgba(255, 255, 255, 0.045);
  --card-strong: rgba(255, 255, 255, 0.075);
  --border: rgba(255, 255, 255, 0.11);
  --border-strong: rgba(255, 255, 255, 0.2);

  /* text */
  --text: #f3f3f6;
  --text-soft: rgba(243, 243, 246, 0.74);
  --text-muted: rgba(243, 243, 246, 0.52);

  /* accent: single, disciplined use only */
  --accent: #4f62e3;
  --accent-strong: #7b8af0;
  --accent-soft: rgba(79, 98, 227, 0.14);
  --accent-border: rgba(79, 98, 227, 0.35);
  --on-accent: #ffffff;
  --positive: #35d488;

  --shadow: 0 20px 48px rgba(0, 0, 0, 0.35);
  --shadow-sm: 0 8px 22px rgba(0, 0, 0, 0.24);

  /* radius */
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 24px;
  --radius-full: 999px;

  /* spacing scale */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-2-5: 0.625rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  /* type scale */
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-md: 1.0625rem;
  --text-lg: 1.25rem;
  --text-xl: 1.5rem;
  --text-2xl: 1.875rem;
  --text-3xl: clamp(2rem, 3.4vw, 2.5rem);
  --text-4xl: clamp(2.5rem, 4.2vw, 3.25rem);
  --text-5xl: clamp(2.75rem, 5.6vw, 4.25rem);
  --text-hero: clamp(3.5rem, 9vw, 7.5rem);

  --content: 1160px;
  --theme-color: #0a0a10;
  --header-surface: rgba(10, 10, 16, 0.78);
  --grid-line: rgba(255, 255, 255, 0.035);
  --panel-value: #b9c3ff;
  --focus-ring: rgba(79, 98, 227, 0.55);
  --button-secondary-bg: rgba(255, 255, 255, 0.07);
  --button-ghost-color: rgba(243, 243, 246, 0.78);
  --theme-switch-bg: rgba(255, 255, 255, 0.06);
  --theme-switch-thumb: rgba(255, 255, 255, 0.16);
  --theme-switch-text: rgba(243, 243, 246, 0.64);
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #ffffff;
  --card: rgba(15, 15, 20, 0.025);
  --card-strong: rgba(15, 15, 20, 0.045);
  --border: rgba(15, 15, 20, 0.11);
  --border-strong: rgba(15, 15, 20, 0.2);
  --text: #111116;
  --text-soft: rgba(17, 17, 22, 0.72);
  --text-muted: rgba(17, 17, 22, 0.5);
  --accent: #3548c9;
  --accent-strong: #4f62e3;
  --accent-soft: rgba(53, 72, 201, 0.08);
  --accent-border: rgba(53, 72, 201, 0.25);
  --on-accent: #ffffff;
  --positive: #16a35f;
  --shadow: 0 20px 48px rgba(15, 23, 42, 0.08);
  --shadow-sm: 0 8px 22px rgba(15, 23, 42, 0.06);
  --theme-color: #ffffff;
  --header-surface: rgba(255, 255, 255, 0.86);
  --grid-line: rgba(15, 15, 20, 0.045);
  --panel-value: #2c3aa0;
  --focus-ring: rgba(53, 72, 201, 0.45);
  --button-secondary-bg: rgba(15, 15, 20, 0.04);
  --button-ghost-color: #3548c9;
  --theme-switch-bg: rgba(15, 15, 20, 0.04);
  --theme-switch-thumb: rgba(15, 15, 20, 0.09);
  --theme-switch-text: rgba(17, 17, 22, 0.58);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "IBM Plex Sans", sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
}

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

img {
  max-width: 100%;
  display: block;
}

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

.icon {
  width: 1.05em;
  height: 1.05em;
  flex-shrink: 0;
}

.icon-inline {
  width: 0.95em;
  height: 0.95em;
  margin-left: 0.4em;
}

.icon-inline-lead {
  width: 0.95em;
  height: 0.95em;
  margin-right: 0.4em;
}

.icon-sm {
  width: 0.9em;
  height: 0.9em;
  margin-right: 0.35em;
}

.page-background {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: -1;
}

.gradient {
  position: absolute;
  border-radius: 999px;
  filter: blur(90px);
  opacity: 0.5;
}

.gradient-a {
  width: 34rem;
  height: 34rem;
  top: -12rem;
  right: -10rem;
  background: radial-gradient(circle, var(--accent-soft), rgba(79, 98, 227, 0));
}

.gradient-b {
  width: 26rem;
  height: 26rem;
  left: -10rem;
  top: 30rem;
  background: radial-gradient(circle, var(--border), transparent);
  opacity: 0.3;
}

.grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), transparent 88%);
}

.site-header,
main,
.site-footer {
  width: min(calc(100% - 2rem), var(--content));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  margin-top: 1rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  background: var(--header-surface);
  border: 1px solid var(--border);
  backdrop-filter: blur(16px);
  border-radius: var(--radius-full);
}

.header-start {
  display: flex;
  align-items: center;
  gap: var(--space-2-5);
  justify-self: start;
}

.header-cta {
  gap: var(--space-2);
}

.header-cta-dot {
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 999px;
  background: var(--on-accent);
  opacity: 0.8;
}

.header-socials {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

.header-social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text-soft);
  transition: border-color 160ms ease, color 160ms ease;
}

.header-social-icon:hover {
  border-color: var(--border-strong);
  color: var(--text);
}

.header-social-icon .icon {
  width: 1rem;
  height: 1rem;
}

.header-end {
  display: flex;
  align-items: center;
  justify-self: end;
}

.brand-menu {
  position: relative;
  justify-self: center;
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  border-radius: var(--radius-full);
}

.brand-dropdown {
  position: absolute;
  top: 100%;
  left: 50%;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  min-width: 9rem;
  margin-top: var(--space-2-5);
  padding: var(--space-2-5);
  background: var(--header-surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  backdrop-filter: blur(16px);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 4px);
  transition: opacity 160ms ease, transform 160ms ease, visibility 160ms;
}

.brand-dropdown .nav-link {
  padding: var(--space-2) var(--space-2-5);
}

.brand-menu:hover .brand-dropdown,
.brand-menu:focus-within .brand-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.brand-mark {
  width: 2.6rem;
  height: 2.6rem;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-text strong {
  font-family: "Space Grotesk", sans-serif;
  font-size: var(--text-sm);
  font-weight: 600;
}

.brand-text span {
  color: var(--text-muted);
  font-size: var(--text-xs);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.nav-link,
.lang-switch,
.theme-switch {
  color: var(--text-soft);
  font-size: var(--text-sm);
}

.nav-link {
  padding: 0.3rem 0.1rem;
  display: inline-block;
  transition: color 160ms ease, letter-spacing 200ms ease;
}

.nav-link:hover {
  letter-spacing: 0.03em;
}

.nav-link:hover,
.lang-switch:hover,
.theme-switch:hover,
.inline-link:hover,
.footer-links a:hover {
  color: var(--text);
}

.button-compact {
  min-height: 2.4rem;
  padding: 0 1rem;
  font-size: var(--text-xs);
}

.lang-switch {
  display: inline-flex;
  gap: var(--space-2);
  align-items: center;
  padding: var(--space-2) var(--space-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  transition: border-color 160ms ease, color 160ms ease;
}

.lang-switch:hover {
  border-color: var(--border-strong);
}

.header-clock {
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-xs);
  color: var(--text-muted);
  letter-spacing: 0.1em;
}

.theme-switch {
  position: relative;
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: center;
  width: 5rem;
  padding: 0.22rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  background: var(--theme-switch-bg);
  cursor: pointer;
  overflow: hidden;
}

.theme-switch::after {
  content: "";
  position: absolute;
  top: 0.22rem;
  left: 0.22rem;
  width: calc(50% - 0.22rem);
  height: calc(100% - 0.44rem);
  border-radius: var(--radius-full);
  background: var(--theme-switch-thumb);
  transition: transform 180ms ease;
}

html[data-theme="light"] .theme-switch::after {
  transform: translateX(100%);
}

.theme-option {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.32rem 0.2rem;
  color: var(--theme-switch-text);
}

html[data-theme="dark"] .theme-option-dark,
html[data-theme="light"] .theme-option-light {
  color: var(--text);
}

.theme-icon {
  width: 1rem;
  height: 1rem;
}

.lang-current {
  color: var(--text);
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  background: transparent;
  border-radius: var(--radius-full);
  padding: 0;
  width: 2.6rem;
  height: 2.6rem;
  color: var(--text);
  transition: border-color 160ms ease;
}

.menu-toggle-icon {
  width: 1.2rem;
  height: 1.2rem;
  display: none;
}

.menu-toggle-open {
  display: block;
}

.site-header[data-open="true"] .menu-toggle-open {
  display: none;
}

.site-header[data-open="true"] .menu-toggle-close {
  display: block;
}

.hero,
.section,
.section-heading-page,
.site-footer,
.detail-hero {
  position: relative;
  z-index: 1;
}

.hero,
.site-footer {
  overflow: hidden;
}

.hero-centered {
  padding: clamp(var(--space-16), 10vw, var(--space-24)) 0 clamp(var(--space-10), 6vw, var(--space-16));
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 46rem;
  margin: 0 auto;
}

.footer-blob {
  position: absolute;
  pointer-events: none;
  bottom: -8rem;
  left: -9rem;
  width: 26rem;
  height: 26rem;
  filter: blur(4px);
  opacity: 0.45;
}

html[data-theme="light"] .footer-blob {
  opacity: 0.14;
}

.halftone {
  position: absolute;
  width: 20rem;
  height: 20rem;
  background-image: radial-gradient(circle, var(--accent) 1.4px, transparent 1.6px);
  background-size: 15px 15px;
  opacity: 0.3;
  pointer-events: none;
}

.footer-halftone {
  top: -3rem;
  right: -3rem;
  -webkit-mask-image: radial-gradient(circle at 100% 0%, rgba(0, 0, 0, 0.9), transparent 70%);
  mask-image: radial-gradient(circle at 100% 0%, rgba(0, 0, 0, 0.9), transparent 70%);
}

html[data-theme="light"] .halftone {
  opacity: 0.16;
}

.eyebrow {
  margin: 0 0 var(--space-4);
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.founder-intro {
  display: flex;
  align-items: center;
  gap: var(--space-2-5);
  margin: 0 0 var(--space-3);
}

.founder-photo {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-strong);
  object-fit: cover;
}

.founder-pill {
  display: inline-flex;
  align-items: center;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: var(--card);
  font-size: var(--text-xs);
  color: var(--text-soft);
}

@keyframes hero-name-typing {
  from {
    width: 0;
  }
  to {
    width: calc(var(--typing-chars) * 1ch);
  }
}

@keyframes hero-name-caret {
  0%, 100% {
    border-color: transparent;
  }
  50% {
    border-color: var(--accent);
  }
}

.hero-name {
  display: inline-block;
  margin: 0 0 var(--space-2);
  font-size: var(--text-hero);
  line-height: 1;
  max-width: none;
  overflow: hidden;
  white-space: nowrap;
  vertical-align: bottom;
  border-right: 0.05em solid transparent;
  width: calc(var(--typing-chars) * 1ch);
  animation:
    hero-name-typing 1.6s steps(var(--typing-chars), end) 0.3s both,
    hero-name-caret 0.85s step-end infinite;
}

.hero-role {
  margin: 0;
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-sm);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

.hero-divider {
  width: 1px;
  height: 2.5rem;
  margin: var(--space-6) 0;
  background: var(--border-strong);
}

.hero-bio {
  max-width: 46ch;
  margin: 0 0 var(--space-6);
  font-size: var(--text-lg);
  color: var(--text);
}

.hero-contact-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--space-2-5);
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

.hero-status {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
}

.hero-status-dot {
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 999px;
  background: var(--positive);
}

.hero-contact-sep {
  color: var(--border-strong);
}

.hero-contact-link {
  color: var(--accent);
  transition: color 160ms ease;
}

.hero-contact-link:hover {
  color: var(--accent-strong);
}

h1,
h2 {
  margin: 0 0 var(--space-4);
  font-family: "Fraunces", serif;
  letter-spacing: -0.01em;
  font-weight: 600;
}

h3 {
  margin: 0 0 var(--space-4);
  font-family: "Space Grotesk", sans-serif;
  letter-spacing: -0.02em;
  font-weight: 600;
  font-size: var(--text-lg);
  line-height: 1.2;
}

h1 {
  font-size: var(--text-5xl);
  line-height: 1;
  max-width: 12ch;
}

h2 {
  font-size: var(--text-4xl);
  line-height: 1.05;
}

.hero-text,
.section-heading p,
.service-card p,
.project-summary,
.project-tagline,
.detail-panel p,
.detail-card p,
.footer-copy {
  color: var(--text-soft);
  font-size: var(--text-md);
  line-height: 1.65;
}

.hero-location,
.footer-next-step,
.micro-note {
  color: var(--text-muted);
  font-size: var(--text-sm);
  margin-top: var(--space-3);
}

.hero-actions,
.project-links,
.footer-actions,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.hero-actions {
  margin-top: var(--space-6);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0 1.3rem;
  border-radius: var(--radius-full);
  border: 1px solid transparent;
  font-weight: 600;
  font-size: var(--text-sm);
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, background-color 160ms ease, box-shadow 160ms ease, color 160ms ease;
}

.button:active {
  transform: translateY(0) scale(0.98);
}

.button-primary {
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  color: var(--on-accent);
  box-shadow: 0 10px 26px rgba(79, 98, 227, 0.28);
}

.button-primary:hover {
  background: var(--accent-strong);
  box-shadow: 0 12px 32px rgba(79, 98, 227, 0.38);
  transform: translateY(-1px);
}

.button-secondary {
  background: var(--button-secondary-bg);
  border-color: var(--border);
  color: var(--text);
}

.button-secondary:hover {
  border-color: var(--border-strong);
  background: var(--card-strong);
  transform: translateY(-1px);
}

.button-ghost {
  border-color: var(--border);
  color: var(--button-ghost-color);
}

.button-ghost:hover {
  border-color: var(--accent-border);
  color: var(--accent);
}

.proof-ribbon-caption {
  margin-top: var(--space-12);
}

.proof-ribbon {
  list-style: none;
  margin: var(--space-6) 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2-5);
}

.proof-ribbon li,
.stack-list li,
.detail-chip,
.project-category {
  display: inline-flex;
  align-items: center;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text-muted);
  font-size: var(--text-xs);
}

.proof-strip-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-8);
}

.live-panel,
.status-card,
.detail-panel,
.service-card,
.process-card,
.project-card,
.detail-card,
.experience-row {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.service-card,
.process-card,
.project-card {
  transition: border-color 200ms ease, transform 200ms ease, background-color 200ms ease;
}

.service-card:hover {
  border-color: var(--accent-border);
  transform: translateY(-3px);
}

.service-card:hover .service-icon {
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  color: var(--on-accent);
}

.process-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-3px);
}

.project-card:hover {
  border-color: var(--border-strong);
  background: var(--card-strong);
  transform: translateY(-3px);
}

.status-card {
  padding: var(--space-5) var(--space-6);
}

.status-card-head {
  display: flex;
  align-items: center;
  gap: var(--space-2-5);
  margin-bottom: var(--space-4);
  font-size: var(--text-sm);
  color: var(--text-soft);
}

.status-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: var(--positive);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--positive) 18%, transparent);
}

.status-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--space-3);
}

.status-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-xs);
}

.status-list li:first-child {
  padding-top: 0;
  border-top: 0;
}

.status-job {
  color: var(--text-soft);
}

.status-ok {
  display: inline-flex;
  align-items: center;
  color: var(--positive);
}

.live-panel {
  padding: var(--space-5) var(--space-6);
  display: grid;
  gap: var(--space-5);
}

.live-panel-head {
  display: flex;
  align-items: center;
  gap: var(--space-2-5);
  font-size: var(--text-sm);
  color: var(--text-soft);
}

.live-panel-dot {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  background: var(--positive);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--positive) 18%, transparent);
}

.live-panel-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--space-3);
}

.live-panel-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-top: var(--space-3);
  border-top: 1px solid var(--border);
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-xs);
}

.live-panel-list li:first-child {
  padding-top: 0;
  border-top: 0;
}

.live-panel-label {
  color: var(--text-soft);
}

.live-panel-value {
  color: var(--panel-value);
  transition: opacity 200ms ease;
}

.live-panel-value.is-updating {
  opacity: 0;
}

.live-panel-progress {
  display: grid;
  gap: var(--space-2);
}

.live-panel-progress-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-xs);
  color: var(--text-soft);
}

.live-panel-bar {
  height: 0.4rem;
  border-radius: var(--radius-full);
  background: var(--card-strong);
  overflow: hidden;
}

.live-panel-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  transition: width 600ms ease;
}

.live-panel-metric {
  display: flex;
  align-items: baseline;
  gap: var(--space-2-5);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
}

.live-panel-metric strong {
  font-family: "Space Grotesk", sans-serif;
  font-size: var(--text-3xl);
  transition: opacity 200ms ease;
}

.live-panel-metric strong.is-updating {
  opacity: 0.4;
}

.live-panel-metric span {
  color: var(--text-muted);
  font-size: var(--text-sm);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
  margin-top: var(--space-6);
}

.stat {
  padding: var(--space-5);
  border-radius: var(--radius-md);
  background: var(--card);
  border: 1px solid var(--border);
  transition: border-color 200ms ease;
}

.stat:hover {
  border-color: var(--border-strong);
}

.stat strong {
  display: block;
  font-family: "Space Grotesk", sans-serif;
  font-size: var(--text-3xl);
  margin-bottom: 0.35rem;
}

.stat span {
  color: var(--text-muted);
  font-size: var(--text-sm);
}

.section {
  padding: clamp(var(--space-16), 10vw, var(--space-24)) 0;
  scroll-margin-top: var(--space-16);
}

.section-heading,
.section-heading-page {
  max-width: 42rem;
  margin-bottom: var(--space-10);
}

.section-actions {
  display: flex;
  justify-content: center;
  margin-top: var(--space-6);
}

.service-grid,
.process-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
}

.service-card,
.process-card,
.detail-card {
  padding: var(--space-6);
}

.service-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.6rem;
  height: 2.6rem;
  margin-bottom: var(--space-5);
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--accent-soft), rgba(79, 98, 227, 0.24));
  color: var(--accent);
  transition: background 200ms ease, color 200ms ease;
}

html[data-theme="light"] .service-icon {
  background: linear-gradient(135deg, var(--accent-soft), rgba(53, 72, 201, 0.18));
}

.service-icon .icon {
  width: 1.2rem;
  height: 1.2rem;
}

.process-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-5);
}

.process-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: var(--radius-sm);
  background: var(--card-strong);
  color: var(--text-soft);
}

.process-icon .icon {
  width: 1.2rem;
  height: 1.2rem;
}

.process-step {
  font-family: "Space Grotesk", sans-serif;
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--accent);
  opacity: 0.55;
}

.experience-timeline {
  display: grid;
  gap: var(--space-4);
}

.experience-row {
  display: grid;
  grid-template-columns: 3.5rem 1fr;
  gap: var(--space-5);
  padding: var(--space-6);
}

.experience-step {
  font-family: "Space Grotesk", sans-serif;
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--accent);
  opacity: 0.55;
}

.experience-row-body h3 {
  margin-bottom: var(--space-1);
}

.experience-company {
  color: var(--text);
  font-weight: 600;
}

.experience-period {
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-xs);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.project-grid,
.project-grid-wide {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
}

.project-card {
  padding: var(--space-6);
  min-height: 100%;
}

.project-card-detailed {
  background: var(--card-strong);
}

.project-card-compact .project-card-top {
  margin-bottom: var(--space-3);
}

.project-card-compact .project-summary {
  margin-bottom: 0;
}

.project-card-top {
  margin-bottom: var(--space-4);
}

.project-category {
  margin-bottom: var(--space-4);
  color: var(--accent);
  background: var(--accent-soft);
  border-color: var(--accent-border);
}

.project-tagline {
  margin-bottom: 0;
}

.project-summary {
  margin: 0 0 var(--space-4);
}

.stack-list,
.detail-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2-5);
}

.detail-list {
  display: grid;
  gap: var(--space-3);
}

.detail-list li {
  position: relative;
  padding-left: 1.3rem;
  color: var(--text-soft);
}

.detail-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62rem;
  width: 0.4rem;
  height: 0.4rem;
  border-radius: 999px;
  background: var(--accent);
}

.project-links {
  margin-top: var(--space-5);
}

.inline-link {
  display: inline-flex;
  align-items: center;
  font-weight: 600;
  font-size: var(--text-sm);
  color: var(--text);
  transition: color 160ms ease;
}

.inline-link .icon-inline {
  transition: transform 160ms ease;
}

.inline-link:hover .icon-inline {
  transform: translate(2px, -2px);
}

.project-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-5);
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
}

.project-thumb[data-lane="finance"] {
  filter: hue-rotate(50deg);
}

.project-thumb[data-lane="marketing"] {
  filter: hue-rotate(149deg);
}

.project-thumb[data-lane="automation"] {
  filter: hue-rotate(280deg);
}

.project-thumb-tag {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  display: inline-flex;
  align-items: center;
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-full);
  background: rgba(10, 10, 16, 0.45);
  color: #ffffff;
  font-size: var(--text-xs);
  font-weight: 600;
}

.project-thumb-tag-featured {
  left: auto;
  right: var(--space-3);
  background: rgba(255, 255, 255, 0.22);
}

.project-meta {
  margin: var(--space-4) 0 0;
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: var(--text-xs);
}

.project-card-featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
  gap: var(--space-6);
  align-items: start;
}

.project-card-featured .project-thumb {
  grid-row: 1 / -1;
  height: 100%;
  margin-bottom: 0;
}

.project-card-featured .project-card-top h3 {
  font-size: var(--text-2xl);
}

.detail-page,
.projects-index {
  padding-top: var(--space-10);
}

.detail-hero {
  padding: var(--space-12) 0 0;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--space-4);
  align-items: stretch;
}

.detail-tagline {
  max-width: 44rem;
  color: var(--text-soft);
  font-size: var(--text-md);
}

.detail-stack-preview {
  list-style: none;
  padding: 0;
  margin: var(--space-5) 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2-5);
}

.detail-stack-preview li {
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text-soft);
  font-size: var(--text-xs);
}

.detail-panel {
  padding: var(--space-6);
}

.detail-chip {
  margin-bottom: var(--space-3);
}

.detail-proof-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-4);
}

.detail-proof-card {
  padding: var(--space-5);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--card);
  box-shadow: var(--shadow-sm);
}

.detail-proof-kicker {
  margin: 0 0 var(--space-3);
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.detail-proof-card strong {
  display: block;
  font-family: "Space Grotesk", sans-serif;
  font-size: var(--text-lg);
  line-height: 1.2;
  margin-bottom: var(--space-2);
}

.detail-proof-card span {
  color: var(--text-soft);
  font-size: var(--text-sm);
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-4);
}

.detail-grid-rich {
  align-items: stretch;
}

.detail-card-emphasis {
  background: var(--accent-soft);
  border-color: var(--accent-border);
}

.site-footer {
  padding: clamp(var(--space-16), 10vw, var(--space-24)) 0 var(--space-12);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--space-6);
  padding: var(--space-8);
  border-radius: var(--radius-lg);
  background: var(--card);
  border: 1px solid var(--border);
  align-items: center;
}

.footer-meta {
  display: flex;
  justify-content: space-between;
  gap: var(--space-4);
  align-items: center;
  padding-top: var(--space-5);
  color: var(--text-muted);
  font-size: var(--text-sm);
}

.ascii-strip {
  margin-top: var(--space-8);
  height: 3.2rem;
  overflow: hidden;
  font-family: "IBM Plex Mono", monospace;
  font-size: var(--text-xs);
  line-height: 1.3;
  letter-spacing: 0.1em;
  word-break: break-all;
  color: var(--border-strong);
  opacity: 0.6;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 600ms ease, transform 600ms ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

.service-grid [data-reveal]:nth-child(2),
.process-grid [data-reveal]:nth-child(2),
.project-grid [data-reveal]:nth-child(2),
.project-grid-wide [data-reveal]:nth-child(2),
.detail-proof-grid [data-reveal]:nth-child(2) {
  transition-delay: 70ms;
}

.service-grid [data-reveal]:nth-child(3),
.process-grid [data-reveal]:nth-child(3),
.project-grid [data-reveal]:nth-child(3),
.project-grid-wide [data-reveal]:nth-child(3),
.detail-proof-grid [data-reveal]:nth-child(3) {
  transition-delay: 140ms;
}

.service-grid [data-reveal]:nth-child(4),
.process-grid [data-reveal]:nth-child(4),
.project-grid [data-reveal]:nth-child(4),
.project-grid-wide [data-reveal]:nth-child(4) {
  transition-delay: 210ms;
}

@media (min-width: 981px) {
  .site-nav .nav-link {
    display: none;
  }
}

@media (max-width: 980px) {
  .brand-dropdown {
    display: none;
  }

  .detail-hero,
  .footer-grid,
  .detail-proof-grid,
  .detail-grid,
  .service-grid,
  .process-grid,
  .project-grid,
  .project-grid-wide,
  .proof-strip-grid,
  .project-card-featured {
    grid-template-columns: 1fr;
  }

  .project-card-featured .project-thumb {
    grid-row: auto;
    height: auto;
    aspect-ratio: 16 / 9;
    margin-bottom: var(--space-5);
  }

  .lane-heading,
  .footer-meta {
    flex-direction: column;
    align-items: flex-start;
  }

  .site-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    border-radius: 28px;
    align-items: center;
  }

  .header-socials {
    display: none;
  }

  .header-end {
    display: contents;
  }

  .menu-toggle {
    display: block;
  }

  .site-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    padding-top: var(--space-2);
  }

  .theme-switch {
    width: 100%;
    max-width: 8rem;
  }

  .site-header[data-open="true"] .site-nav {
    display: flex;
  }

}

@media (max-width: 640px) {
  .site-header,
  main,
  .site-footer {
    width: min(calc(100% - 1.2rem), var(--content));
  }

  h1 {
    font-size: clamp(2.1rem, 10vw, 3.1rem);
  }

  h2 {
    font-size: clamp(1.9rem, 8vw, 2.6rem);
  }

  .brand-text span {
    display: none;
  }

  .hero-name {
    display: block;
    width: auto;
    max-width: 100%;
    white-space: normal;
    overflow: visible;
    border-right: none;
    animation: none;
  }

}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .button,
  .nav-link,
  .lang-switch,
  .theme-switch,
  .theme-switch::after {
    transition: none;
  }

  .hero-name {
    animation: none;
  }
}
