/* ==========================================================================
   Design Tokens — Warm Editorial Paper (Light) & Obsidian Slate (Dark)
   4px/8px grid, concentric border radii, WCAG contrast, reduced-motion ready
   ========================================================================== */

:root {
  --bg: #FAF9F6;
  --surface: #FFFFFF;
  --surface-subtle: #F3F1EC;
  --ink: #161614;
  --ink-muted: #57554E;
  --border: rgba(22, 22, 20, 0.11);
  --border-strong: rgba(22, 22, 20, 0.22);
  --accent: #0F6E5C;
  --accent-ink: #FFFFFF;
  --accent-soft: rgba(15, 110, 92, 0.09);
  --header-bg: rgba(250, 249, 246, 0.84);
  --shadow-sm: 0 1px 2px rgba(22, 22, 20, 0.04), 0 2px 8px rgba(22, 22, 20, 0.04);
  --shadow-md: 0 4px 12px rgba(22, 22, 20, 0.06), 0 14px 32px rgba(22, 22, 20, 0.08);
  --shadow-lg: 0 16px 48px rgba(22, 22, 20, 0.16);

  --font-serif: 'Instrument Serif', Georgia, 'Times New Roman', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --space-12: 48px;
  --space-16: 64px;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  --ease-out: cubic-bezier(0.0, 0.0, 0.2, 1);
  --duration-in: 220ms;
  --duration-out: 140ms;
  --duration-press: 90ms;
}

[data-theme="dark"] {
  --bg: #121413;
  --surface: #1A1D1B;
  --surface-subtle: #222624;
  --ink: #ECEAE4;
  --ink-muted: #9E9B91;
  --border: rgba(236, 234, 228, 0.11);
  --border-strong: rgba(236, 234, 228, 0.22);
  --accent: #45B39D;
  --accent-ink: #0F1412;
  --accent-soft: rgba(69, 179, 157, 0.13);
  --header-bg: rgba(18, 20, 19, 0.84);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.22), 0 2px 8px rgba(0, 0, 0, 0.18);
  --shadow-md: 0 6px 16px rgba(0, 0, 0, 0.28), 0 16px 36px rgba(0, 0, 0, 0.34);
  --shadow-lg: 0 20px 56px rgba(0, 0, 0, 0.55);
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: 84px;
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color var(--duration-in) var(--ease-out), color var(--duration-in) var(--ease-out);
  overflow-x: hidden;
}

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

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

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

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

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

.skip-link {
  position: absolute;
  top: -100px;
  left: var(--space-4);
  z-index: 200;
  background: var(--accent);
  color: var(--accent-ink);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
}

.skip-link:focus {
  top: var(--space-4);
}

.tabular {
  font-variant-numeric: tabular-nums;
}

.container {
  width: 100%;
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 var(--space-6);
}

.section {
  padding: var(--space-16) 0;
}

.section + .section {
  border-top: 1px solid var(--border);
}

.eyebrow {
  margin: 0 0 var(--space-2);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.section-head {
  margin-bottom: var(--space-8);
}

.section-title {
  margin: 0;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.015em;
}

/* ==========================================================================
   Sticky Header
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  height: 64px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.wordmark-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

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

.primary-nav a {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-muted);
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
  transition: color var(--duration-in) var(--ease-out), background-color var(--duration-in) var(--ease-out);
}

.primary-nav a:hover {
  color: var(--ink);
  background: var(--surface-subtle);
}

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

.lang-toggle {
  display: inline-flex;
  padding: 2px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-subtle);
}

.lang-btn {
  padding: 4px 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-muted);
  border-radius: 6px;
  transition: background-color var(--duration-press) var(--ease-out), color var(--duration-press) var(--ease-out);
}

.lang-btn[aria-pressed="true"] {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 32px;
  padding: 0 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--ink-muted);
  font-size: 12px;
  transition: border-color var(--duration-press) var(--ease-out), color var(--duration-press) var(--ease-out), transform var(--duration-press) var(--ease-out);
}

.icon-btn:hover {
  border-color: var(--border-strong);
  color: var(--ink);
}

.icon-btn:active {
  transform: scale(0.97);
}

.icon-btn kbd {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-muted);
}

.theme-toggle {
  width: 32px;
  padding: 0;
  justify-content: center;
}

.icon-moon {
  display: none;
}

[data-theme="dark"] .icon-sun {
  display: none;
}

[data-theme="dark"] .icon-moon {
  display: block;
}

/* ==========================================================================
   Hero & Proof Strip
   ========================================================================== */

.hero {
  padding-top: var(--space-12);
  padding-bottom: var(--space-12);
}

.hero-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-4);
  margin-bottom: var(--space-6);
}

.avatar-wrap {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  padding: 2px;
  border: 1px solid var(--border-strong);
  background: var(--surface);
  flex-shrink: 0;
}

.avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.status-pill {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-2);
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 13px;
  color: var(--ink-muted);
  box-shadow: var(--shadow-sm);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.status-pill .sep {
  opacity: 0.45;
}

.hero-title {
  margin: 0 0 var(--space-5);
  max-width: 820px;
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(38px, 6vw, 62px);
  line-height: 1.06;
  letter-spacing: -0.02em;
}

.hero-title em {
  font-style: italic;
  color: var(--accent);
}

.hero-lead {
  margin: 0 0 var(--space-8);
  max-width: 680px;
  font-size: 18px;
  line-height: 1.65;
  color: var(--ink-muted);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-12);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 44px;
  padding: 0 18px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  transition: background-color var(--duration-press) var(--ease-out), border-color var(--duration-press) var(--ease-out), transform var(--duration-press) var(--ease-out), box-shadow var(--duration-in) var(--ease-out);
}

.btn:active {
  transform: translateY(1px) scale(0.99);
}

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

.btn-primary:hover {
  filter: brightness(1.06);
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--border-strong);
}

.btn-secondary:hover {
  background: var(--surface-subtle);
}

.btn-ghost {
  color: var(--ink-muted);
  padding: 0 12px;
}

.btn-ghost:hover {
  color: var(--ink);
  background: var(--surface-subtle);
}

/* Resume Dropdown */
.resume-menu {
  position: relative;
}

.resume-menu .chevron {
  transition: transform var(--duration-in) var(--ease-out);
}

.resume-menu.is-open .chevron {
  transform: rotate(180deg);
}

.resume-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 220px;
  padding: var(--space-1);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity var(--duration-out) var(--ease-out), transform var(--duration-out) var(--ease-out), visibility var(--duration-out);
  z-index: 30;
}

.resume-menu.is-open .resume-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition: opacity var(--duration-in) var(--ease-out), transform var(--duration-in) var(--ease-out), visibility 0s;
}

.resume-dropdown a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  transition: background-color var(--duration-press) var(--ease-out);
}

.resume-dropdown a:hover {
  background: var(--surface-subtle);
}

.ext-arrow {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-muted);
}

/* Proof Strip */
.proof-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-4);
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.proof-cell {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.proof-cell + .proof-cell {
  border-left: 1px solid var(--border);
  padding-left: var(--space-4);
}

.proof-value {
  font-family: var(--font-serif);
  font-size: 32px;
  line-height: 1.1;
  color: var(--ink);
}

.proof-label {
  font-size: 13px;
  line-height: 1.45;
  color: var(--ink-muted);
}

/* ==========================================================================
   Selected Work Grid
   ========================================================================== */

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

.work-card {
  display: flex;
  flex-direction: column;
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: transform var(--duration-in) var(--ease-out), box-shadow var(--duration-in) var(--ease-out), border-color var(--duration-in) var(--ease-out);
}

.work-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}

.work-card-featured {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: var(--space-8);
  align-items: center;
  border-color: var(--border-strong);
}

.work-card-content {
  display: flex;
  flex-direction: column;
}

.work-motif {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
  border-radius: var(--radius-sm);
  background: var(--surface-subtle);
  color: var(--ink);
}

.work-motif svg {
  width: 100%;
  height: auto;
}

.work-motif-compact {
  margin-bottom: var(--space-4);
  border-radius: var(--radius-sm);
  background: var(--surface-subtle);
  padding: var(--space-2);
  color: var(--ink);
  overflow: hidden;
}

.work-motif-compact svg {
  width: 100%;
  height: auto;
  transition: transform 260ms var(--ease-out);
}

.work-card:hover .work-motif-compact svg {
  transform: scale(1.03);
}

.work-meta {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
}

.badge-accent {
  background: var(--accent-soft);
  color: var(--accent);
}

.meta-text {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-muted);
}

.work-title {
  margin: 0 0 var(--space-3);
  font-size: 20px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.015em;
}

.work-card-featured .work-title {
  font-size: 24px;
}

.work-desc {
  margin: 0 0 var(--space-5);
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--ink-muted);
  flex-grow: 1;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.tag-list li {
  padding: 3px 9px;
  border-radius: 6px;
  background: var(--surface-subtle);
  border: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-muted);
}

/* ==========================================================================
   Experience Accordions & Education
   ========================================================================== */

.exp-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  margin-bottom: var(--space-8);
}

.exp-item {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.exp-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-5) var(--space-6);
  text-align: left;
  transition: background-color var(--duration-press) var(--ease-out);
}

.exp-trigger:hover {
  background: var(--surface-subtle);
}

.exp-role-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-2) var(--space-3);
}

.exp-role {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.exp-company {
  font-size: 14px;
  font-weight: 500;
  color: var(--accent);
}

.exp-meta {
  margin: 4px 0 0;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--ink-muted);
}

.exp-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  color: var(--ink-muted);
  flex-shrink: 0;
  transition: transform var(--duration-in) var(--ease-out);
}

.exp-item[data-open="true"] .exp-chevron {
  transform: rotate(180deg);
}

/* Grid-row accordion animation */
.exp-panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 240ms var(--ease-out);
}

.exp-item[data-open="true"] .exp-panel {
  grid-template-rows: 1fr;
}

.exp-panel-inner {
  overflow: hidden;
}

.exp-bullets {
  margin: 0;
  padding: 0 var(--space-6) var(--space-6) 40px;
  border-top: 1px solid var(--border);
  padding-top: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  color: var(--ink-muted);
  font-size: 14.5px;
}

.exp-bullets li::marker {
  color: var(--accent);
}

/* Education & Distinctions Grid */
.edu-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-6);
}

.edu-card {
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
}

.edu-heading {
  margin: 0 0 var(--space-4);
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
}

.edu-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.edu-list li {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: var(--space-3);
  align-items: baseline;
  font-size: 14px;
}

.edu-year {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent);
  white-space: nowrap;
}

.edu-list strong {
  display: block;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 2px;
}

.edu-inst {
  display: block;
  font-size: 13px;
  color: var(--ink-muted);
}

/* ==========================================================================
   Capabilities Grid
   ========================================================================== */

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

.cap-card {
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
}

.cap-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: var(--space-4);
}

.cap-title {
  margin: 0 0 var(--space-2);
  font-size: 17px;
  font-weight: 600;
}

.cap-text {
  margin: 0 0 var(--space-4);
  font-size: 14px;
  color: var(--ink-muted);
}

.cap-items {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.7;
  color: var(--ink-muted);
}

/* ==========================================================================
   Contact Card & Footer
   ========================================================================== */

.contact-card {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: var(--space-8);
  padding: var(--space-8);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.contact-title {
  margin: 0 0 var(--space-3);
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(28px, 3.8vw, 38px);
  line-height: 1.15;
}

.contact-desc {
  margin: 0 0 var(--space-6);
  font-size: 15px;
  color: var(--ink-muted);
  max-width: 520px;
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.mono-inline {
  font-family: var(--font-mono);
  font-size: 12px;
  opacity: 0.88;
}

.contact-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-left: 1px solid var(--border);
  padding-left: var(--space-6);
}

.contact-links li + li {
  border-top: 1px solid var(--border);
}

.contact-links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  min-height: 44px;
  padding: var(--space-2) var(--space-2);
  border-radius: var(--radius-sm);
  font-size: 14px;
  transition: background-color var(--duration-press) var(--ease-out);
}

.contact-links a:hover {
  background: var(--surface-subtle);
}

.link-label {
  font-weight: 500;
  color: var(--ink);
}

.link-val {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--ink-muted);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: var(--space-6) 0;
  font-size: 13px;
  color: var(--ink-muted);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
}

.footer-cmd {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 12.5px;
  color: var(--ink-muted);
}

.footer-cmd:hover {
  color: var(--ink);
  border-color: var(--border-strong);
}

.footer-cmd kbd {
  font-family: var(--font-mono);
  font-size: 11px;
}

/* ==========================================================================
   Command Palette & Toast
   ========================================================================== */

.cmd-backdrop {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 12vh var(--space-4) var(--space-4);
  background: rgba(15, 16, 15, 0.54);
  backdrop-filter: blur(4px);
}

.cmd-backdrop[hidden] {
  display: none;
}

.cmd-modal {
  width: 100%;
  max-width: 540px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-strong);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  animation: cmdIn 180ms var(--ease-out);
}

@keyframes cmdIn {
  from {
    opacity: 0;
    transform: translateY(-8px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.cmd-header {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
  color: var(--ink-muted);
}

.cmd-input {
  flex: 1;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  outline: none;
}

.cmd-input::placeholder {
  color: var(--ink-muted);
}

.cmd-esc {
  padding: 3px 7px;
  border-radius: 6px;
  border: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-muted);
}

.cmd-list {
  list-style: none;
  margin: 0;
  padding: var(--space-2);
  max-height: 320px;
  overflow-y: auto;
}

.cmd-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  cursor: pointer;
}

.cmd-item[aria-selected="true"],
.cmd-item:hover {
  background: var(--surface-subtle);
}

.cmd-item-hint {
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--ink-muted);
}

.cmd-empty {
  padding: var(--space-4);
  font-size: 13.5px;
  color: var(--ink-muted);
  text-align: center;
}

.toast {
  position: fixed;
  right: var(--space-6);
  bottom: var(--space-6);
  z-index: 150;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--ink);
  color: var(--bg);
  font-size: 13.5px;
  font-weight: 500;
  box-shadow: var(--shadow-lg);
}

.toast[hidden] {
  display: none;
}

/* Scroll Reveal */
.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 260ms var(--ease-out), transform 260ms var(--ease-out);
}

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

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */

@media (max-width: 900px) {
  .work-grid,
  .cap-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .work-card-featured {
    grid-template-columns: 1fr;
  }

  .proof-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .proof-cell:nth-child(3) {
    border-left: 0;
    padding-left: 0;
  }

  .contact-card {
    grid-template-columns: 1fr;
  }

  .contact-links {
    border-left: 0;
    border-top: 1px solid var(--border);
    padding-left: 0;
    padding-top: var(--space-4);
  }
}

@media (max-width: 680px) {
  .primary-nav {
    display: none;
  }

  .section {
    padding: var(--space-12) 0;
  }

  .work-grid,
  .cap-grid,
  .edu-grid,
  .proof-strip {
    grid-template-columns: 1fr;
  }

  .proof-cell + .proof-cell {
    border-left: 0;
    border-top: 1px solid var(--border);
    padding-left: 0;
    padding-top: var(--space-3);
  }

  .edu-list li {
    grid-template-columns: 1fr;
    gap: 2px;
  }

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

  .icon-btn kbd {
    display: none;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
