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

:root {
  /* Solid values */
  --bg:      #0A0A0B;
  --surface: rgba(13, 13, 15, 0.92);

  /* Theme-aware rgb tuples — consumed as `rgba(var(--x), ALPHA)` below */
  --gold-rgb:        184, 147, 80;
  --gold-hi-rgb:     212, 176, 104;
  --gold-bright-rgb: 255, 187, 65;
  --text-rgb:        245, 240, 232;
  --text-alt-rgb:    240, 232, 220;
  --shadow-rgb:      6, 5, 4;

  /* Compound values (recompute automatically when tuples are overridden) */
  --gold:         rgba(var(--gold-rgb),    0.90);
  --gold-hi:      rgba(var(--gold-hi-rgb), 0.90);
  --cream:        rgba(var(--text-rgb),    0.90);
  --muted:        rgba(var(--text-rgb),    0.80);
  --panel-border: rgba(255, 255, 255, 0.04);
  --terminal-bg:  rgba(12, 12, 14, 0.95);
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  background: var(--bg);
  color: var(--cream);
}

/* ── Fixed background layers ── */
#c {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.grain {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 512 512' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.72' numOctaves='5' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.042;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: radial-gradient(
    ellipse 60% 50% at 35% 60%,
    rgba(var(--shadow-rgb),0.68) 0%,
    rgba(var(--shadow-rgb),0.22) 52%,
    transparent 80%
  );
}

.scroll-body {
  position: relative;
  z-index: 3;
}

/* ═══════════════════════════════════════
   NAVIGATION
═══════════════════════════════════════ */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: clamp(1.4rem, 3vh, 2.2rem) clamp(1.5rem, 5vw, 4rem);
  transition: background 0.6s ease, backdrop-filter 0.6s ease;
}

nav.scrolled {
  background: rgba(var(--shadow-rgb), 0.78);
  backdrop-filter: blur(10px);
}

.nav-id-group {
  display: flex;
  align-items: center;
  gap: 0;
}

.nav-identity {
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.40em;
  text-transform: uppercase;
  color: var(--gold);
  white-space: nowrap;
  cursor: pointer;
  text-decoration: none;
  transition: color 0.3s ease;
}

.nav-identity::after { content: '\00a0·\00a0'; }

.nav-identity:hover { color: var(--gold-hi); }

.nav-role {
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.40em;
  text-transform: uppercase;
  color: var(--gold);
  white-space: nowrap;
}

.nav-links {
  display: flex;
  gap: clamp(1.6rem, 3vw, 2.8rem);
  list-style: none;
}

.nav-links a {
  position: relative;
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-size: 12px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.3s ease;
}

/* Underline slide-in from left */
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--gold);
  transition: width 0.35s cubic-bezier(0.16,1,0.3,1);
}

.nav-links a:hover { color: var(--gold); }
.nav-links a:hover::after { width: 100%; }

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

@media (max-width: 680px) {
  nav {
    justify-content: space-between;
    padding-left: clamp(0.8rem, 3vw, 1.2rem);
    padding-right: clamp(0.8rem, 3vw, 1.2rem);
  }
  .nav-identity,
  .nav-role {
    letter-spacing: 0.15em;
    font-size: 14px;
  }
  .article-pub { color: var(--gold); }
}

/* Burger button */
.burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.burger span {
  display: block;
  width: 22px;
  height: 1px;
  background: var(--gold);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.burger.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 1024px) { .burger { display: flex; } }

/* Mobile menu panel */
.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9;
  background: rgba(var(--shadow-rgb), 0.97);
  backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu.open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.mobile-menu ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2.2rem;
}

.mobile-menu ul a {
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-size: 13px;
  letter-spacing: 0.38em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.mobile-menu ul a:hover,
.mobile-menu ul a:active { color: var(--gold); }

@media (min-width: 1025px) { .mobile-menu { display: none; } }

/* ═══════════════════════════════════════
   HERO
═══════════════════════════════════════ */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
}

.hero-content {
  position: absolute;
  bottom: clamp(10vh, 12vh, 12vh);
  left: clamp(1.5rem, 5vw, 6rem);
  max-width: 780px;
}

.hero-label {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 400;
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0;
  transition: opacity 1.2s ease;
}

.hero-headline {
  margin-top: clamp(1.2rem, 2.5vh, 1.8rem);
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 100;
  font-size: clamp(3.8rem, 7.5vw, 7.5rem);
  line-height: 0.93;
  color: var(--cream);
  text-shadow:
    0 0 120px rgba(var(--shadow-rgb),0.9),
    0 0 40px  rgba(var(--shadow-rgb),0.7),
    0 0 8px   rgba(var(--shadow-rgb),0.5);
}

.hero-hl-1, .hero-hl-2 {
  display: block;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 1.4s ease, transform 1.4s cubic-bezier(0.16,1,0.3,1);
}

.hero-subline {
  margin-top: clamp(1.8rem, 3.5vh, 2.4rem);
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 200;
  font-size: clamp(1.1rem, 2.2vw, 1.9rem);
  color: var(--gold-hi);
  letter-spacing: 0.01em;
  text-shadow: 0 0 60px rgba(var(--shadow-rgb),0.8);
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 1.2s ease, transform 1.2s cubic-bezier(0.16,1,0.3,1);
}

.hero-cta {
  display: inline-block;
  margin-top: clamp(2.2rem, 4vh, 3rem);
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-variation-settings: "wght" 200;
  font-size: 12px;
  letter-spacing: 0.38em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  opacity: 0;
  transition: opacity 1s ease 0.2s,
              color 0.15s cubic-bezier(0,0,0.3,1),
              font-variation-settings 0.15s cubic-bezier(0,0,0.3,1);
}

.hero-cta:hover { color: var(--gold-hi); font-variation-settings: "wght" 400; }

.bottom-bar {
  position: absolute;
  bottom: clamp(1.5rem, 3.5vh, 2.4rem);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: clamp(1.2rem, 2.5vw, 2.5rem);
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.18em;
  color: rgba(var(--gold-rgb), 0.52);
  white-space: nowrap;
  opacity: 0;
  transition: opacity 1.2s ease;
}

.fib-short { display: none; }

@media (max-width: 540px) {
  .fib-full  { display: none; }
  .fib-short { display: inline; }
  .bottom-bar {
    font-size: 10px;
    gap: 0.7rem;
    letter-spacing: 0.12em;
  }
}

@media (max-width: 600px) {
  .hero-content {
    top: 10vh;
    bottom: 10vh;
    left: clamp(1.2rem, 4vw, 2rem);
    right: clamp(1.2rem, 4vw, 2rem);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
  }
  .hero-content .hero-headline { margin-top: 0; }
  .hero-content .hero-subline  { margin-top: 0; }
  .hero-content .hero-cta      { margin-top: 0; }
}

/* JS show classes */
.show   { opacity: 1 !important; transform: translateY(0) !important; }
.show-b { opacity: 1 !important; }

/* ═══════════════════════════════════════
   SHARED SECTION STYLES
═══════════════════════════════════════ */
.section-panel {
  background: var(--surface);
  backdrop-filter: blur(2px);
  border: 1px solid var(--panel-border);
}

.section-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: clamp(5rem, 10vh, 8rem) clamp(2rem, 6vw, 5rem);
  position: relative;
}

.section-label {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 400;
  font-size: 12px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ── Scroll reveal ── */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.9s cubic-bezier(0.16,1,0.3,1),
              transform 0.9s cubic-bezier(0.16,1,0.3,1);
}

.reveal[data-delay="1"] { transition-delay: 0.12s; }
.reveal[data-delay="2"] { transition-delay: 0.26s; }
.reveal[data-delay="3"] { transition-delay: 0.42s; }
.reveal[data-delay="4"] { transition-delay: 0.60s; }
.reveal[data-delay="5"] { transition-delay: 0.78s; }

.revealed { opacity: 1; transform: translateY(0); }

.article-row.revealed {
  transition: background 0.3s ease, transform 0.35s cubic-bezier(0.16,1,0.3,1);
  transition-delay: 0s;
}

/* ═══════════════════════════════════════
   ABOUT ME
═══════════════════════════════════════ */
.about-section .section-inner {
  max-width: 960px;
}

.about-header {
  margin-bottom: clamp(2.8rem, 5vh, 3.8rem);
}

.about-opening {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 100;
  font-size: clamp(1.9rem, 3.8vw, 3rem);
  color: var(--cream);
  line-height: 1.1;
  margin-top: clamp(1.4rem, 2.8vh, 2rem);
  text-shadow: 0 0 80px rgba(var(--shadow-rgb),0.7);
}

.about-body {
  margin-top: clamp(2.2rem, 4.5vh, 3.2rem);
  display: flex;
  flex-direction: column;
  gap: clamp(1.2rem, 2.5vh, 1.8rem);
}

.about-body p {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 200;
  font-size: 18px;
  color: var(--muted);
  line-height: 1.78;
}

.about-body p strong {
  font-weight: 300;
  color: rgba(var(--text-alt-rgb), 0.62);
  font-style: normal;
}

.about-rule {
  width: 100%;
  height: 1px;
  background: rgba(var(--gold-rgb), 0.12);
  margin-top: clamp(3rem, 5.5vh, 4.2rem);
}

/* ═══════════════════════════════════════
   SERVICES — 3-LAYER MODEL
═══════════════════════════════════════ */
.gold-rule-left {
  position: absolute;
  left: 0;
  top: clamp(5rem, 10vh, 8rem);
  bottom: clamp(5rem, 10vh, 8rem);
  width: 2px;
  background: rgba(var(--gold-rgb), 0.22);
}

.layers-header {
  margin-bottom: clamp(3rem, 5vh, 4rem);
}

.layer-row {
  display: grid;
  grid-template-columns: 38.2% 61.8%;
  gap: 0 clamp(2rem, 4vw, 4rem);
  padding: clamp(2.4rem, 5vh, 3.4rem) 0;
  border-top: 1px solid rgba(var(--gold-rgb), 0.10);
  align-items: start;
}

.layer-row:last-child {
  border-bottom: 1px solid rgba(var(--gold-rgb), 0.10);
}

.layer-left {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.layer-number {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 100;
  font-size: clamp(3.5rem, 6vw, 5.5rem);
  color: rgba(var(--gold-bright-rgb), 0.62);
  line-height: 1;
  letter-spacing: -0.02em;
}

.layer-name {
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-size: 14px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--cream);
}

.layer-desc {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 200;
  font-size: 18px;
  color: var(--muted);
  line-height: 1.72;
  padding-top: clamp(3.5rem, 6vw, 5.5rem);
}

@media (max-width: 700px) {
  .layer-row { grid-template-columns: 1fr; gap: 0.8rem 0; }
  .layer-desc { padding-top: 0; }
}

/* ═══════════════════════════════════════
   CLAUDE CODE DIGEST
═══════════════════════════════════════ */
.digest-section .section-inner { max-width: 960px; }

.digest-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  /* margin-bottom: clamp(2rem, 4vh, 2.8rem); */
  flex-wrap: wrap;
  gap: 1rem;
}

.digest-link, .writing-link {
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  transition: color 0.3s ease;
}

.digest-link:hover, .writing-link:hover { color: var(--gold-hi); }

.terminal {
  position: relative;
  background: var(--terminal-bg);
  border: 1px solid rgba(var(--gold-rgb), 0.14);
  padding: clamp(1.8rem, 3.5vh, 2.4rem) clamp(1.5rem, 3vw, 2.4rem);
}

.terminal-spiral {
  position: absolute;
  top: 1.2rem;
  right: 1.4rem;
  width: 48px;
  height: 48px;
  opacity: 0.07;
  pointer-events: none;
}

.log-lines { display: flex; flex-direction: column; gap: 0.1rem; }

.log-entry {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0 1.4rem;
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 300;
  font-size: 14px;
  line-height: 1.85;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.log-entry + .log-entry { margin-top: 1.1rem; }
.log-entry.visible { opacity: 1; }

.log-prompt {
  color: rgba(var(--gold-rgb), 0.55);
  user-select: none;
  padding-top: 0.02em;
}

.log-body { color: var(--muted); }
.log-timestamp {
  font-size: 12px;
  color: rgba(var(--gold-rgb), 0.48);
  margin-bottom: 0.15rem;
  display: block;
}

.log-text { display: block; }
.log-text + .log-text { color: rgba(var(--text-alt-rgb), 0.28); }

.cursor {
  display: inline-block;
  color: var(--gold);
  animation: blink 1.1s infinite;
}

@keyframes blink {
  0%, 49%  { opacity: 1; }
  50%, 100% { opacity: 0; }
}

/* ═══════════════════════════════════════
   ARTICLES
═══════════════════════════════════════ */
.articles-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Left-border slide animation on hover */
.article-row {
  position: relative;
  display: grid;
  grid-template-columns: clamp(110px, 18%, 170px) 1fr;
  gap: 0 clamp(2rem, 4vw, 4rem);
  padding: clamp(1.8rem, 3.5vh, 2.4rem) 0 clamp(1.8rem, 3.5vh, 2.4rem) 1rem;
  border-top: 1px solid rgba(var(--gold-rgb), 0.08);
  cursor: pointer;
  text-decoration: none;
  transition: background 0.3s ease, transform 0.35s cubic-bezier(0.16,1,0.3,1);
}

.article-row:last-child { border-bottom: 1px solid rgba(var(--gold-rgb), 0.08); }

.article-row::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 0.5px;
  height: 0;
  background: var(--gold);
  transition: height 0.35s cubic-bezier(0.16,1,0.3,1);
}

.article-row:hover { background: rgba(var(--gold-rgb), 0.03); transform: translateX(0.4rem); }
.article-row:hover::before { height: 100%; }

.article-meta {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding-top: 0.2rem;
}

.article-date {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.12em;
  color: var(--muted);
}

.article-pub {
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-size: 10px;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: rgba(var(--gold-bright-rgb), 0.75);
}

.article-title {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 200;
  font-size: 24px;
  color: rgba(var(--gold-bright-rgb), 0.32);
  color: var(--cream);
  line-height: 1.25;
  margin-bottom: 0.55rem;
  transition: color 0.25s ease;
}

.article-row:hover .article-title { color: var(--gold-hi); }

.article-excerpt {
  font-family: 'Fraunces', serif;
  font-style: inherit;
  font-weight: 100;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.62;
}

@media (max-width: 640px) {
  .article-row { grid-template-columns: 1fr; gap: 0.8rem 0; }
}

/* ═══════════════════════════════════════
   CTA — "THE NEXT SEQUENCE STARTS HERE"
═══════════════════════════════════════ */
.cta-section {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(5rem, 10vh, 8rem) clamp(1.5rem, 5vw, 4rem);
}

.cta-inner {
  max-width: 740px;
  text-align: center;
}

.cta-fib {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 300;
  font-size: 10px;
  letter-spacing: 0.24em;
  color: rgba(var(--gold-rgb), 0.57);
  margin-bottom: clamp(1.8rem, 3.5vh, 2.4rem);
}

.cta-headline {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 100;
  font-size: clamp(2.8rem, 6vw, 5.8rem);
  line-height: 1.02;
  color: var(--cream);
  text-shadow:
    0 0 100px rgba(var(--shadow-rgb),0.9),
    0 0 40px  rgba(var(--shadow-rgb),0.65);
  margin-bottom: clamp(2.8rem, 5.5vh, 4rem);
}

.cta-transition {
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  font-size: 14px;
  font-style: italic;
  color: rgba(var(--text-rgb), 0.35);
  margin-top: clamp(2rem, 4vh, 3rem);
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.section-desc {
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  font-size: 14px;
  color: var(--muted);
  margin-top: 0.6rem;
  margin-bottom: clamp(1.5rem, 4vh, 2.8rem);
  max-width: 520px;
}

/* Pill button — "Initiate Consultation" */
@keyframes btn-breathe {
  0%, 100% { box-shadow: 0 0 8px 1px rgba(var(--gold-rgb), 0.12); }
  50%       { box-shadow: 0 0 22px 5px rgba(var(--gold-rgb), 0.42); }
}

.btn-consultation {
  display: inline-block;
  height: 48px;
  width: 300px;
  padding: clamp(0.9rem, 1.8vh, 1.1rem);
  border: 1px solid rgba(var(--gold-rgb), 0.58);
  border-radius: 50px;
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-variation-settings: "wght" 200;
  font-size: 12px;
  letter-spacing: 0.40em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  background: rgba(var(--gold-rgb), 0.05);
  cursor: pointer;
  animation: btn-breathe 3.2s ease-in-out infinite;
  transition: background 0.2s ease-out, color 0.2s ease-out, border-color 0.2s ease-out,
              font-variation-settings 0.2s ease-out;
}

.btn-consultation:hover {
  background: var(--gold);
  color: var(--bg);
  border-color: var(--gold);
  font-variation-settings: "wght" 400;
  box-shadow: none;
  animation: none;
}

/* Micro-line under the CTA button — value prop (free / duration / follow-up) */
.cta-micro {
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  font-variation-settings: "wght" 300;
  font-size: clamp(10px, 1.1vw, 11px);
  letter-spacing: 0.18em;
  color: rgba(var(--gold-rgb), 0.55);
  text-transform: uppercase;
  margin-top: 1.4rem;
  margin-bottom: 0;
}

/* ═══════════════════════════════════════
   CONTACT SECTION
═══════════════════════════════════════ */
.contact-section .section-inner {
  max-width: 960px;
}

.contact-header {
  margin-bottom: clamp(3rem, 5.5vh, 4.2rem);
}

.contact-intro {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 200;
  font-size: 18px;
  color: var(--muted);
  line-height: 1.72;
  margin-top: clamp(1rem, 2vh, 1.4rem);
}

/* Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: clamp(1.4rem, 2.8vh, 2rem);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1rem, 2vw, 1.6rem);
}

@media (max-width: 560px) { .form-row { grid-template-columns: 1fr; } }

.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.form-field label {
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-size: 12px;
  letter-spacing: 0.30em;
  text-transform: uppercase;
  color: var(--muted);
}

.form-field .opt {
  color: rgba(var(--text-alt-rgb), 0.22);
  font-size: 10px;
  letter-spacing: 0.1em;
}

.form-field input,
.form-field textarea {
  background: rgba(var(--text-alt-rgb), 0.03);
  border: 1px solid rgba(var(--gold-rgb), 0.15);
  border-radius: 0;
  color: var(--cream);
  font-family: 'Fraunces', serif;
  font-style: normal;
  font-weight: 200;
  font-size: 16px;
  padding: 0.85rem 1.1rem;
  outline: none;
  width: 100%;
  resize: none;
  transition: border-color 0.3s ease, background 0.3s ease;
  -webkit-appearance: none;
}

.form-field input::placeholder,
.form-field textarea::placeholder {
  color: rgba(var(--text-alt-rgb), 0.16);
}

.form-field input:focus,
.form-field textarea:focus {
  border-color: rgba(var(--gold-rgb), 0.45);
  background: rgba(var(--text-alt-rgb), 0.04);
}

/* Suppress browser autofill blue wash */
.form-field input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 100px var(--bg) inset;
  -webkit-text-fill-color: var(--cream);
  caret-color: var(--cream);
}

.form-submit {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2.8rem;
  margin-top: 2rem;
}

.btn-submit {
  width: 216px;
  display: inline-block;
  padding: clamp(0.9rem, 1.8vh, 1.1rem);
  border: 1px solid rgba(var(--gold-rgb), 0.30);
  border-radius: 50px;
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-size: 12px;
  letter-spacing: 0.40em;
  text-transform: uppercase;
  color: var(--gold);
  background: transparent;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.btn-submit:hover {
  background: var(--gold);
  color: var(--bg);
  border-color: var(--gold);
  font-weight: 400;
}

.contact-email-alt {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.10em;
  color: var(--muted);
}

.contact-email-label::after { content: '\00a0'; }

.contact-email-alt a {
  color: rgba(var(--gold-rgb), 0.65);
  text-decoration: none;
  transition: color 0.3s ease;
}

.contact-email-alt a:hover { color: var(--gold-hi); }

@media (max-width: 600px) {
  .contact-email-label::after { content: ''; }
  .contact-email-alt {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
  }
  .contact-email-label,
  .contact-email-alt a {
    text-align: center;
    display: block;
    width: 100%;
  }
}

/* Form success state */
.form-success {
  display: none;
  text-align: center;
  padding: clamp(2.4rem, 5vh, 3.4rem);
  border: 1px solid rgba(var(--gold-rgb), 0.18);
}

.form-success.visible { display: block; }

.form-success p {
  font-family: 'Fraunces', serif;
  font-style: italic;
  font-weight: 200;
  font-size: 18px;
  color: var(--muted);
  line-height: 1.7;
}

.form-success strong {
  color: var(--gold-hi);
  font-weight: 300;
  font-style: normal;
}

/* ═══════════════════════════════════════
   FOOTER
═══════════════════════════════════════ */
footer {
  border-top: 1px solid rgba(var(--gold-rgb), 0.12);
  background: rgba(var(--shadow-rgb), 0.88);
  backdrop-filter: blur(4px);
  padding: clamp(2rem, 4vh, 3rem) clamp(1.5rem, 5vw, 4rem);
}

.footer-inner {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-copy {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 300;
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.footer-fib {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 300;
  font-size: 10px;
  letter-spacing: 0.18em;
  color: rgba(var(--gold-rgb), 0.30);
  text-align: center;
}

.footer-linkedin {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: rgba(var(--text-rgb), 0.55);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-linkedin:hover { color: rgba(var(--text-rgb), 0.90); }

.footer-linkedin svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  transition: fill 0.3s ease;
}

.footer-linkedin span {
  font-family: 'Jost', sans-serif;
  font-weight: 200;
  font-size: 12px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.footer-fib-short { display: none; }

@media (max-width: 520px) {
  .footer-inner { flex-direction: column; align-items: center; text-align: center; gap: 0.6rem; }
  .footer-fib-full  { display: none; }
  .footer-fib-short { display: inline; }
}

/* ═══════════════════════════════════════
   LIGHT THEME OVERRIDE
   Activates when <html data-theme="light"> is set.
   Overrides tuple vars — compound vars (--gold, --cream, --muted…) recompute
   automatically from their rgba(var(--X-rgb), α) definitions in :root.
═══════════════════════════════════════ */
[data-theme="light"] {
  --bg:      #F4EDE1;
  --surface: rgba(251, 246, 234, 0.88);

  --gold-rgb:        122, 88, 24;    /* #7A5818 — WCAG AA ~5.6:1 on cream */
  --gold-hi-rgb:     92, 66, 18;     /* #5C4212 — darker for hover */
  --gold-bright-rgb: 139, 69, 19;    /* #8B4513 — saddle brown, max-pop accent */
  --text-rgb:        26, 26, 26;     /* #1A1A1A */
  --text-alt-rgb:    26, 26, 26;     /* unified with text in light */
  --shadow-rgb:      244, 237, 225;  /* cream halo — mirrors bg for soft text edges */

  --panel-border: rgba(0, 0, 0, 0.08);
  --terminal-bg:  rgba(235, 224, 201, 0.95);  /* #EBE0C9 accent block */
}

/* ═══════════════════════════════════════
   THEME TOGGLE (sun / moon)
   Sits in <nav> between .nav-links and .burger.
═══════════════════════════════════════ */

/* Accommodate a new flex item (toggle). Auto-margin pins nav-id-group to the
   left and lets nav-links + toggle + burger cluster on the right with a gap. */
nav { gap: clamp(0.8rem, 1.6vw, 1.2rem); }
.nav-id-group { margin-right: auto; }

/* Pill toggle — dark: thumb left + moon right / light: thumb right + sun left */
.theme-toggle {
  position: relative;
  width: 50px;
  height: 26px;
  padding: 0;
  border-radius: 13px;
  border: 1px solid rgba(var(--gold-rgb), 0.45);
  background: rgba(var(--gold-rgb), 0.10);
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.3s ease, border-color 0.3s ease;
}

.theme-toggle:hover {
  border-color: rgba(var(--gold-rgb), 0.75);
  background: rgba(var(--gold-rgb), 0.18);
}

/* Sliding thumb */
.theme-toggle::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--cream);
  box-shadow: 0 1px 3px rgba(var(--shadow-rgb), 0.30);
  transition: left 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

/* Light: filled gold pill + thumb on right */
[data-theme="light"] .theme-toggle {
  background: rgba(var(--gold-rgb), 0.88);
  border-color: rgba(var(--gold-rgb), 0.95);
}
[data-theme="light"] .theme-toggle:hover {
  background: var(--gold);
  border-color: var(--gold);
}
[data-theme="light"] .theme-toggle::after {
  left: 27px;
  background: #FFFFFF;
}

/* Icons — small, on pill background, opposite the thumb */
.theme-toggle svg {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  fill: none;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

/* Dark: moon on right (thumb is left) */
.theme-toggle .icon-sun  { left: 7px;  stroke: rgba(var(--gold-rgb), 0.9); opacity: 0; }
.theme-toggle .icon-moon { right: 7px; stroke: rgba(var(--gold-rgb), 0.9); opacity: 1; }

/* Light: sun on left (thumb is right), icons white on gold pill */
[data-theme="light"] .theme-toggle .icon-sun  { left: 7px;  stroke: #FFFFFF; opacity: 1; }
[data-theme="light"] .theme-toggle .icon-moon { right: 7px; stroke: #FFFFFF; opacity: 0; }

/* Light-mode-only: headlines at weight 200 */
[data-theme="light"] .hero-headline  { font-weight: 200; }
[data-theme="light"] .about-opening  { font-weight: 200; }
[data-theme="light"] .cta-headline   { font-weight: 200; }

/* Light-mode-only: Initiate Consultation — solid gold, white text, 80% → 100% on hover */
[data-theme="light"] .btn-consultation {
  background: var(--gold);
  color: #FFFFFF;
  border-color: var(--gold);
  opacity: 0.8;
  animation: none;
  transition: opacity 0.15s cubic-bezier(0,0,0.3,1),
              font-variation-settings 0.2s ease-out;
}
[data-theme="light"] .btn-consultation:hover {
  background: var(--gold);
  color: #FFFFFF;
  border-color: var(--gold);
  font-variation-settings: "wght" 400;
  box-shadow: none;
  opacity: 1;
}
