/* ═══════════════════════════════════════════════════
   MAILTON LIMA — SHARED DESIGN SYSTEM
   ═══════════════════════════════════════════════════ */

/* ── TOKENS ─────────────────────────────────────── */
:root {
  --teal:        #7ab5b5;
  --teal-d:      #5a9999;
  --teal-l:      #d4e9e9;
  --teal-xl:     #eef6f6;
  --black:       #0a0a0a;
  --gray-800:    #262626;
  --gray-600:    #525252;
  --gray-400:    #a3a3a3;
  --gray-200:    #e5e5e5;
  --gray-100:    #f5f5f5;
  --off-white:   #fafafa;
  --white:       #ffffff;
  --font:        'Inter', sans-serif;
  --nav-h:       68px;
  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  /* ── SPACING TOKENS ── */
  --space-2:   2px;
  --space-4:   4px;
  --space-8:   8px;
  --space-12:  12px;
  --space-16:  16px;
  --space-24:  24px;
  --space-32:  32px;
  --space-48:  48px;
  --space-80:  80px;
  --space-120: 120px;

  /* ── COLOR TOKENS ── */
  --purple:   #9333ea;
  --purple-l: #fdf4ff;
  --green:    #22c55e;
  --green-l:  rgba(34,197,94,0.15);
}

/* ── SKIP LINK ───────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -60px;
  left: 24px;
  background: var(--teal);
  color: var(--white);
  padding: 10px 20px;
  border-radius: 0 0 8px 8px;
  font-size: 14px;
  font-weight: 600;
  z-index: 10000;
  text-decoration: none;
  transition: top 0.2s;
}
.skip-link:focus { top: 0; }

/* ── FOCUS VISIBLE — global ──────────────────────── */
:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
  border-radius: 4px;
}
.nav-cta:focus-visible,
.btn:focus-visible,
.nav-link:focus-visible,
.lang-toggle:focus-visible,
.filter-btn:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
}
:focus:not(:focus-visible) { outline: none; }

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--white);
  color: var(--black);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  cursor: none;
}

a { text-decoration: none; color: inherit; }
img, svg { display: block; }
button { font-family: var(--font); cursor: none; border: none; background: none; }

/* ── CUSTOM CURSOR ───────────────────────────────── */
#cursor {
  position: fixed;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: difference;
}
#cursor-dot {
  position: absolute;
  width: 8px; height: 8px;
  background: var(--white);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  will-change: transform;
  transition: width 0.25s var(--ease-out),
              height 0.25s var(--ease-out),
              opacity 0.25s;
}
#cursor-ring {
  position: absolute;
  width: 36px; height: 36px;
  border: 1.5px solid rgba(255,255,255,0.5);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  will-change: transform;
  transition: width 0.4s var(--ease-out),
              height 0.4s var(--ease-out),
              border-color 0.3s,
              opacity 0.3s;
}

body.cursor-hover #cursor-dot  { width: 6px; height: 6px; opacity: 0.4; }
body.cursor-hover #cursor-ring {
  width: 56px; height: 56px;
  border-color: rgba(255,255,255,0.9);
}
body.cursor-link #cursor-dot  { width: 4px; height: 4px; opacity: 0.2; }
body.cursor-link #cursor-ring {
  width: 64px; height: 64px;
  border-color: rgba(255,255,255,1);
}

/* ── NAVIGATION ──────────────────────────────────── */
#nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  z-index: 100;
  transition: transform 0.4s var(--ease-out), background 0.4s, border-color 0.4s;
}
#nav::after {
  content: '';
  position: absolute;
  bottom: 0; left: 48px; right: 48px;
  height: 1px;
  background: var(--gray-200);
  opacity: 0;
  transition: opacity 0.4s;
}
#nav.scrolled::after { opacity: 1; }
#nav.nav-hidden { transform: translateY(-100%); }
#nav.light {
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
#nav.dark {
  background: rgba(10,10,10,0.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
#nav.dark::after { background: rgba(255,255,255,0.08); }

/* Logo */
.nav-logo {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--black);
  display: flex;
  align-items: center;
  gap: 2px;
  position: relative;
  transition: color 0.3s;
}
.nav-logo .copy { color: var(--teal); }
#nav.dark .nav-logo { color: var(--white); }

/* Footer logo mark — mirrors nav-logo at footer scale */
.footer-logo {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: rgba(255,255,255,0.45);
  display: inline-flex;
  align-items: center;
  gap: 2px;
  transition: color 0.25s;
  line-height: 1;
}
.footer-logo:hover { color: rgba(255,255,255,0.85); }
.footer-logo .copy { color: var(--teal); opacity: 0.7; transition: opacity 0.25s; }
.footer-logo:hover .copy { opacity: 1; }

/* Magnetic logo wrapper */
.nav-logo-wrap {
  position: relative;
  display: inline-flex;
}

/* Nav center links */
.nav-center {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  position: relative;
  font-size: clamp(12px, 1.2vw, 14px);
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--gray-600);
  padding: 6px 14px;
  border-radius: 100px;
  transition: color 0.25s;
  display: flex;
  align-items: center;
}
#nav.dark .nav-link { color: rgba(255,255,255,0.65); }
.nav-link:hover { color: var(--black); }
#nav.dark .nav-link:hover { color: rgba(255,255,255,1); }
.nav-link.active { color: var(--black); }
#nav.dark .nav-link.active { color: rgba(255,255,255,1); }

/* Sliding indicator behind active link */
.nav-indicator {
  position: absolute;
  background: var(--gray-100);
  border-radius: 100px;
  height: 32px;
  top: 50%;
  left: 0;
  width: 0;
  transform: translateY(-50%);
  transition: transform 0.4s var(--ease-out),
              width 0.4s var(--ease-out),
              background 0.3s;
  pointer-events: none;
  z-index: -1;
  will-change: transform, width;
}
#nav.dark .nav-indicator { background: rgba(255,255,255,0.08); }

/* CTA */
.nav-cta {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--white);
  background: var(--black);
  padding: 9px 20px;
  border-radius: 100px;
  display: flex;
  align-items: center;
  gap: 6px;
  position: relative;
  overflow: hidden;
  transition: color 0.3s;
}
.nav-cta::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--teal);
  transform: translateY(100%);
  transition: transform 0.4s var(--ease-out);
  z-index: 0;
  will-change: transform;
}
.nav-cta:hover::before { transform: translateY(0); }
.nav-cta span { position: relative; z-index: 1; }
#nav.dark .nav-cta { background: var(--white); color: var(--black); }
#nav.dark .nav-cta::before { background: var(--teal-l); }

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 14px 8px;
  min-height: 44px;
  min-width: 44px;
  align-items: center;
  justify-content: center;
}
.nav-toggle span {
  width: 22px; height: 1.5px;
  background: var(--black);
  border-radius: 2px;
  transition: transform 0.35s var(--ease-out), opacity 0.25s;
  display: block;
}
#nav.dark .nav-toggle span { background: var(--white); }
.nav-toggle.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* Mobile drawer */
.nav-drawer {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--white);
  z-index: 90;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s var(--ease-out);
}
.nav-drawer.open {
  opacity: 1;
  pointer-events: all;
}
.nav-drawer .drawer-link {
  font-size: 36px;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: rgba(0,0,0,0.4);
  transition: color 0.2s;
  transform: translateY(20px);
  opacity: 0;
  transition: transform 0.4s var(--ease-out), opacity 0.4s, color 0.2s;
}
.nav-drawer.open .drawer-link {
  transform: translateY(0);
  opacity: 1;
}
.nav-drawer.open .drawer-link:nth-child(1) { transition-delay: 0.05s; }
.nav-drawer.open .drawer-link:nth-child(2) { transition-delay: 0.10s; }
.nav-drawer.open .drawer-link:nth-child(3) { transition-delay: 0.15s; }
.nav-drawer.open .drawer-link:nth-child(4) { transition-delay: 0.20s; }
.nav-drawer.open .drawer-link:nth-child(5) { transition-delay: 0.25s; }
.nav-drawer.open .drawer-link:nth-child(6) { transition-delay: 0.30s; }
.nav-drawer .drawer-link:hover { color: var(--black); }
.nav-drawer .drawer-link.active { color: var(--black); }

/* ── CARD BTN / BENTO ARROW TOUCH TARGETS ─────────── */
.card-btn { min-height: 44px; }
.bento-arrow { width: 44px; height: 44px; }
.pr-arrow { width: 44px; height: 44px; }

/* ── PAGE TRANSITIONS ────────────────────────────── */
#page-wrap {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s var(--ease-out),
              transform 0.6s var(--ease-out);
}
#page-wrap.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── FADE-UP ─────────────────────────────────────── */
.fu {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.8s var(--ease-out),
              transform 0.8s var(--ease-out);
}
.fu.in { opacity: 1; transform: translateY(0); }
.d1 { transition-delay: 0.08s; }
.d2 { transition-delay: 0.16s; }
.d3 { transition-delay: 0.24s; }
.d4 { transition-delay: 0.32s; }
.d5 { transition-delay: 0.40s; }

/* ── SHARED TYPOGRAPHY ───────────────────────────── */
.label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal);
}

.heading-xl {
  font-size: clamp(40px, 5.5vw, 72px);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 1.1;
  color: var(--black);
}

.heading-lg {
  font-size: clamp(28px, 3.5vw, 48px);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.2;
}

.heading-md {
  font-size: clamp(20px, 2vw, 28px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.25;
}

.body-lg {
  font-size: 17px;
  line-height: 1.7;
  color: var(--gray-600);
}

.body-md {
  font-size: 14px;
  line-height: 1.65;
  color: var(--gray-600);
}

/* ── SHARED BUTTONS ──────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  border-radius: 100px;
  padding: 14px 28px;
  min-height: 44px;
  position: relative;
  overflow: hidden;
  transition: color 0.3s, transform 0.25s var(--ease-spring);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-dark {
  background: var(--black);
  color: var(--white);
}
.btn-dark::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--teal);
  transform: translateX(-101%);
  transition: transform 0.45s var(--ease-out);
  z-index: 0;
  will-change: transform;
}
.btn-dark:hover::before { transform: translateX(0); }
.btn-dark span { position: relative; z-index: 1; }

.btn-outline {
  background: transparent;
  color: var(--gray-600);
  border: 1px solid var(--gray-200);
  transition: border-color 0.25s, color 0.25s, transform 0.25s var(--ease-spring);
}
.btn-outline:hover {
  border-color: var(--black);
  color: var(--black);
  transform: translateY(-2px);
}

/* ── TAG CHIPS ───────────────────────────────────── */
.chip {
  display: inline-flex;
  align-items: center;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 100px;
  white-space: nowrap;
}
.chip-gray  { background: var(--gray-100); color: var(--gray-600); }
.chip-teal  { background: var(--teal-l);   color: var(--teal-d); }
.chip-purple{ background: #fdf4ff;          color: #9333ea; }
.chip-dark  { background: var(--gray-800); color: var(--gray-400); }

/* ── SECTION ─────────────────────────────────────── */
.section {
  padding: 120px 48px;
  max-width: 1280px;
  margin: 0 auto;
}

.section-full {
  padding: 120px 48px;
}

/* ── DIVIDER ─────────────────────────────────────── */
.hr {
  width: 100%;
  height: 1px;
  background: var(--gray-200);
}

/* ── LANG TOGGLE ─────────────────────────────────── */
.lang-toggle {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 10px 14px;
  border-radius: 100px;
  border: 1px solid var(--gray-200);
  color: var(--gray-400);
  background: transparent;
  transition: border-color 0.2s, color 0.2s;
  cursor: none;
  flex-shrink: 0;
  min-height: 44px;
  min-width: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lang-toggle:hover {
  border-color: var(--black);
  color: var(--black);
}
#nav.dark .lang-toggle {
  border-color: rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.4);
}
#nav.dark .lang-toggle:hover {
  border-color: rgba(255,255,255,0.5);
  color: white;
}

/* ── NAV RIGHT CLUSTER ───────────────────────────── */
.nav-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* ── PHOTO ───────────────────────────────────────── */
.photo-real {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ── PROJECT DETAIL ──────────────────────────────── */
.proj-hero {
  min-height: 60vh;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  padding: calc(var(--nav-h) + 80px) 48px 80px;
  position: relative;
  overflow: hidden;
}
.proj-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.proj-hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  width: 100%;
}
.proj-hero-meta {
  display: flex;
  gap: 24px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.proj-hero-meta span {
  font-size: 13px;
  font-weight: 500;
  color: rgba(255,255,255,0.6);
}
.proj-hero-meta span strong {
  color: rgba(255,255,255,0.9);
  font-weight: 600;
}
.proj-metrics-bar {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  margin-top: 32px;
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,0.12);
}
.proj-metric {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.proj-metric-val {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.05em;
  color: var(--teal-l);
  line-height: 1;
}
.proj-metric-lbl {
  font-size: 11px;
  font-weight: 500;
  color: rgba(255,255,255,0.45);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.proj-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  margin-bottom: 28px;
  transition: color 0.2s;
}
.proj-back:hover { color: rgba(255,255,255,0.9); }

.proj-section {
  padding: 100px 48px;
  max-width: 1280px;
  margin: 0 auto;
}
.proj-section-narrow {
  padding: 100px 48px;
  max-width: 900px;
  margin: 0 auto;
}

.proj-section-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 12px;
}
.proj-section-title {
  font-size: clamp(24px, 2.5vw, 36px);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.15;
  color: var(--black);
  margin-bottom: 24px;
}
.proj-section-body {
  font-size: 16px;
  line-height: 1.75;
  color: var(--gray-600);
}
.proj-section-body + .proj-section-body { margin-top: 16px; }

.proj-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}

.proj-visual {
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 4/3;
  background: var(--gray-100);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

/* Abstract UI mockup inside project visuals */
.ui-mock {
  width: 100%;
  height: 100%;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.ui-mock-bar {
  height: 10px;
  border-radius: 5px;
  background: rgba(0,0,0,0.08);
}
.ui-mock-bar-w1 { width: 70%; }
.ui-mock-bar-w2 { width: 45%; }
.ui-mock-bar-w3 { width: 85%; }
.ui-mock-bar-w4 { width: 55%; }
.ui-mock-card {
  flex: 1;
  border-radius: 10px;
  background: rgba(0,0,0,0.04);
  margin-top: 8px;
}

/* Process phases */
.proj-phases {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--gray-200);
  border-radius: 16px;
  border: 1px solid var(--gray-200);
  overflow: hidden;
  margin-top: 48px;
}
.proj-phase {
  background: var(--white);
  padding: 32px 24px;
}
.proj-phase-num {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 14px;
}
.proj-phase-icon {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--teal-xl);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}
.proj-phase-title {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--black);
  margin-bottom: 8px;
}
.proj-phase-desc {
  font-size: 13px;
  line-height: 1.6;
  color: var(--gray-600);
}

/* Outcomes grid */
.proj-outcomes-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--gray-200);
  border-radius: 16px;
  border: 1px solid var(--gray-200);
  overflow: hidden;
  margin-top: 48px;
}
.proj-outcome {
  background: var(--white);
  padding: 36px 28px;
  text-align: center;
}
.proj-outcome-val {
  font-size: 40px;
  font-weight: 700;
  letter-spacing: -0.06em;
  color: var(--black);
  line-height: 1;
}
.proj-outcome-lbl {
  font-size: 12px;
  line-height: 1.4;
  color: var(--gray-400);
  margin-top: 8px;
}

/* Outcomes big (6-col for meutudo) */
.proj-outcomes-6 {
  grid-template-columns: repeat(3, 1fr);
}

/* Learnings */
.proj-learnings {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-top: 32px;
}
.proj-learning {
  display: flex;
  gap: 20px;
  padding: 24px;
  background: var(--gray-100);
  border-radius: 12px;
  border-left: 3px solid var(--teal);
}
.proj-learning-num {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--teal);
  flex-shrink: 0;
  padding-top: 2px;
}
.proj-learning-text {
  font-size: 15px;
  line-height: 1.65;
  color: var(--gray-600);
}

/* Next project */
.proj-next {
  background: var(--black);
  padding: 80px 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.proj-next-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.3);
  margin-bottom: 12px;
}
.proj-next-title {
  font-size: clamp(22px, 2.5vw, 32px);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--white);
  transition: color 0.2s;
}
.proj-next-link:hover .proj-next-title { color: var(--teal-l); }
.proj-next-arrow {
  width: 56px; height: 56px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s, border-color 0.2s;
}
.proj-next-link:hover .proj-next-arrow {
  background: var(--teal);
  border-color: var(--teal);
}

/* Full-width accent band */
.proj-accent-band {
  background: linear-gradient(135deg, var(--teal-xl) 0%, var(--off-white) 100%);
  padding: 80px 48px;
}

/* ── EDITORIAL PROJECT TEMPLATE ─────────────────── */

/* Cover — full-width hero image/video */
.proj-cover {
  width: 100%;
  aspect-ratio: 16/9;
  max-height: 75vh;
  overflow: hidden;
  position: relative;
  background: var(--gray-100);
}
.proj-cover img,
.proj-cover video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.proj-cover-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.5) 0%, transparent 40%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 48px;
}
.proj-cover-title {
  font-size: clamp(32px, 4.5vw, 64px);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.1;
  color: var(--white);
  max-width: 720px;
}
.proj-cover-client {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  margin-bottom: 16px;
}

/* Meta bar — horizontal metadata grid */
.proj-meta-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 32px;
  padding: 40px 48px;
  max-width: 1280px;
  margin: 0 auto;
  border-bottom: 1px solid var(--gray-200);
}
.proj-meta-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.proj-meta-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gray-400);
}
.proj-meta-value {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--black);
}

/* Text block — centered narrow column */
.proj-text-narrow {
  max-width: 720px;
  margin: 0 auto;
  padding: 80px 48px;
}
.proj-text-narrow h2 {
  font-size: clamp(24px, 2.5vw, 36px);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.2;
  color: var(--black);
  margin-bottom: 20px;
}
.proj-text-narrow p {
  font-size: 17px;
  line-height: 1.8;
  color: var(--gray-600);
}
.proj-text-narrow p + p { margin-top: 16px; }

/* Full-bleed image */
.proj-img-full {
  width: 100%;
  overflow: hidden;
}
.proj-img-full img {
  width: 100%;
  display: block;
}

/* Image grids */
.proj-img-grid {
  display: grid;
  gap: 4px;
  padding: 0 48px;
  max-width: 1280px;
  margin: 0 auto;
}
.proj-img-grid-2 { grid-template-columns: 1fr 1fr; }
.proj-img-grid-3 { grid-template-columns: 1fr 1fr 1fr; }
.proj-img-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 4px;
}

/* Video embed */
.proj-video {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 48px;
}
.proj-video-wrap {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 */
  height: 0;
  overflow: hidden;
  border-radius: 8px;
  background: var(--gray-100);
}
.proj-video-wrap iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: 0;
}

/* Pull quote */
.proj-quote {
  max-width: 720px;
  margin: 0 auto;
  padding: 64px 48px;
  text-align: center;
}
.proj-quote blockquote {
  font-size: clamp(20px, 2.5vw, 28px);
  font-weight: 500;
  font-style: italic;
  line-height: 1.5;
  color: var(--black);
  letter-spacing: -0.02em;
}
.proj-quote cite {
  display: block;
  margin-top: 16px;
  font-size: 13px;
  font-style: normal;
  color: var(--gray-400);
}

/* Image caption */
.proj-img-caption {
  font-size: 12px;
  color: var(--gray-400);
  text-align: center;
  padding: 12px 48px 0;
  max-width: 720px;
  margin: 0 auto;
}

/* Spacer utility for editorial flow */
.proj-spacer-sm { height: 48px; }
.proj-spacer-md { height: 80px; }
.proj-spacer-lg { height: 120px; }

/* ── SKILL FILL PERFORMANCE ──────────────────────── */
.skill-fill { will-change: transform; }

/* ── THEME TOGGLE BUTTON ─────────────────────────── */
.theme-toggle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--gray-200);
  color: var(--gray-600);
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: none;
  flex-shrink: 0;
  min-width: 36px;
  min-height: 36px;
  transition: border-color 0.2s, color 0.2s, transform 0.2s;
}
.theme-toggle:hover {
  border-color: var(--black);
  color: var(--black);
  transform: rotate(15deg);
}
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
#nav.dark .theme-toggle {
  border-color: rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.5);
}
#nav.dark .theme-toggle:hover {
  border-color: rgba(255,255,255,0.5);
  color: #fff;
}
[data-theme="dark"] #nav.light .theme-toggle {
  border-color: rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.55);
}
[data-theme="dark"] #nav.light .theme-toggle:hover {
  border-color: rgba(255,255,255,0.45);
  color: #fff;
}

/* ── DARK MODE TOKENS ────────────────────────────── */
[data-theme="dark"] {
  color-scheme: dark;

  --black:     #f0f0ee;
  --gray-800:  #ccccca;
  --gray-600:  #8c8c8a;
  --gray-400:  #4a4a48;
  --gray-200:  #282828;
  --gray-100:  #1c1c1c;
  --off-white: #0e0e0e;
  --white:     #141414;

  --teal-l:    rgba(122,181,181,0.18);
  --teal-xl:   rgba(122,181,181,0.07);
  --purple-l:  rgba(147,51,234,0.12);
  --green-l:   rgba(34,197,94,0.12);

  --marquee-bg: #f0f0ee;
  --marquee-fg: rgba(0,0,0,0.3);
}

/* Nav: dark theme overrides */
[data-theme="dark"] #nav.light {
  background: rgba(16,16,16,0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
[data-theme="dark"] #nav.light::after {
  background: rgba(255,255,255,0.06);
}
[data-theme="dark"] #nav.light .nav-logo   { color: var(--black); }
[data-theme="dark"] #nav.light .nav-link   { color: rgba(240,240,238,0.55); }
[data-theme="dark"] #nav.light .nav-link:hover,
[data-theme="dark"] #nav.light .nav-link.active { color: var(--black); }
[data-theme="dark"] #nav.light .nav-indicator   { background: rgba(255,255,255,0.08); }
[data-theme="dark"] #nav.light .nav-cta  {
  background: var(--teal);
  color: #fff;
}
[data-theme="dark"] #nav.light .nav-cta::before { background: var(--teal-d); }
[data-theme="dark"] #nav.light .lang-toggle {
  border-color: rgba(255,255,255,0.12);
  color: rgba(255,255,255,0.4);
}
[data-theme="dark"] #nav.light .lang-toggle:hover {
  border-color: rgba(255,255,255,0.45);
  color: #fff;
}
[data-theme="dark"] #nav.light .nav-toggle span { background: var(--black); }

/* Drawer: dark theme */
[data-theme="dark"] .nav-drawer {
  background: #0e0e0e;
}
[data-theme="dark"] .nav-drawer .drawer-link {
  color: rgba(240,240,238,0.35);
}
[data-theme="dark"] .nav-drawer .drawer-link:hover,
[data-theme="dark"] .nav-drawer .drawer-link.active {
  color: var(--black);
}

/* Dark chip adjustments */
[data-theme="dark"] .chip-purple {
  background: rgba(147,51,234,0.14);
  color: #c084fc;
}
[data-theme="dark"] .chip-dark {
  background: #262626;
  color: #a0a09e;
}

/* Sections that use hardcoded dark backgrounds — keep them dark */
[data-theme="dark"] .practice-section {
  background: #0a0a0a;
}
[data-theme="dark"] .practice-section .pc-title,
[data-theme="dark"] .practice-section h2 {
  color: #f0f0ee;
}

/* Process page AI section */
[data-theme="dark"] .ai-section { background: var(--white); }
[data-theme="dark"] .ast {
  background: #1c1c1c;
  border-color: rgba(255,255,255,0.06);
}
[data-theme="dark"] .ast:hover { background: #222; }
[data-theme="dark"] .ast-name { color: #f0f0ee; }
[data-theme="dark"] .ast-desc { color: #8c8c8a; }
[data-theme="dark"] .ast-use { color: var(--teal); }

/* Bento card dark */
[data-theme="dark"] .bento-card {
  background: #1a1a1a;
  border-color: rgba(255,255,255,0.06);
}
[data-theme="dark"] .bento-card:hover {
  border-color: rgba(122,181,181,0.3);
  box-shadow: 0 16px 48px rgba(0,0,0,0.4);
}
[data-theme="dark"] .bento-title { color: var(--black); }
[data-theme="dark"] .bento-metrics { border-top-color: rgba(255,255,255,0.06); }
[data-theme="dark"] .bm-val { color: var(--black); }
[data-theme="dark"] .bento-arrow { background: #282828; }
[data-theme="dark"] .bento-card:hover .bento-arrow { background: var(--teal); }
[data-theme="dark"] .bento-card:hover .bento-arrow path { stroke: #fff; }

/* Snap stats dark */
[data-theme="dark"] .about-snap-stats {
  background: #1a1a1a;
  border-color: rgba(255,255,255,0.06);
}
[data-theme="dark"] .snap-stat { background: #1a1a1a; }
[data-theme="dark"] .snap-stat-val { color: var(--black); }
[data-theme="dark"] .snap-stat-lbl { color: #9a9a96; }

/* Principles grid dark */
[data-theme="dark"] .principle-card {
  background: #1a1a1a;
  border-color: rgba(255,255,255,0.06);
}

/* Method hero aside dark */
[data-theme="dark"] .method-aside-quote {
  border-left-color: var(--teal);
  color: rgba(240,240,238,0.55);
}
[data-theme="dark"] .method-aside-attr {
  color: rgba(240,240,238,0.3);
}

/* Project rows dark */
[data-theme="dark"] .project-row::after {
  background: rgba(255,255,255,0.03);
}

/* Contact cards dark */
[data-theme="dark"] .cc {
  background: #1a1a1a;
  border-color: rgba(255,255,255,0.06);
}

/* Blog cards dark */
[data-theme="dark"] .blog-card {
  background: #1a1a1a;
  border-color: rgba(255,255,255,0.06);
}

/* Footer dark */
[data-theme="dark"] footer {
  background: #0a0a0a !important;
}
[data-theme="dark"] footer p {
  color: rgba(240,240,238,0.22) !important;
}

/* ── PREFERS REDUCED MOTION ──────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  #cursor { display: none !important; }
  body { cursor: auto !important; }
  a, button, [data-hover] { cursor: auto !important; }
  .fu { opacity: 1 !important; transform: none !important; }
  .fu.in { opacity: 1 !important; transform: none !important; }
  #page-wrap { opacity: 1 !important; transform: none !important; }
  .marquee-track { animation: none !important; }
  .scroll-cue { animation: none !important; }
  .portrait-card img { transition: none !important; }
  .skill-fill { transition: none !important; }
}

/* ── RESPONSIVE ──────────────────────────────────── */
@media (max-width: 960px) {
  #nav { padding: 0 24px; }
  #nav::after { left: 24px; right: 24px; }
  .nav-center { display: none; }
  .nav-toggle { display: flex; }
  .nav-drawer { display: flex; }
  .section, .section-full { padding: 80px 24px; }
  .heading-xl { font-size: clamp(36px, 9vw, 56px); }

  .proj-hero { padding: calc(var(--nav-h) + 48px) 24px 60px; }
  .proj-section, .proj-section-narrow { padding: 60px 24px; }
  .proj-2col { grid-template-columns: 1fr; gap: 40px; }
  .proj-phases { grid-template-columns: 1fr 1fr; }
  .proj-outcomes-grid { grid-template-columns: 1fr 1fr; }
  .proj-outcomes-6 { grid-template-columns: 1fr 1fr; }
  .proj-metrics-bar { gap: 20px; }
  .proj-next { flex-direction: column; gap: 24px; padding: 60px 24px; }
  .proj-accent-band { padding: 60px 24px; }
  .lang-toggle { display: none; }
  .proj-cover { aspect-ratio: 4/3; }
  .proj-cover-overlay { padding: 24px; }
  .proj-meta-bar { padding: 32px 24px; gap: 24px; }
  .proj-text-narrow { padding: 60px 24px; }
  .proj-img-grid { padding: 0 24px; }
  .proj-video { padding: 0 24px; }
  .proj-quote { padding: 48px 24px; }
  .proj-img-caption { padding: 12px 24px 0; }
  .project-row::after { inset: 0 -24px; }
  .tl-item { grid-template-columns: 70px 1fr; gap: 14px; }
}

@media (max-width: 768px) {
  .section, .section-full { padding: 60px 20px; }
  .proj-section, .proj-section-narrow { padding: 48px 20px; }
  .proj-phases { grid-template-columns: 1fr; }
  .proj-outcomes-grid { grid-template-columns: 1fr 1fr; }
  .proj-outcomes-6 { grid-template-columns: 1fr 1fr; }
  .proj-2col { grid-template-columns: 1fr; gap: 32px; }
  .proj-next { padding: 48px 20px; }
  .proj-hero { padding: calc(var(--nav-h) + 40px) 20px 48px; }
  .ai-banner { padding: 32px 20px; }
  .proj-img-grid-2 { grid-template-columns: 1fr; }
  .proj-img-grid-3 { grid-template-columns: 1fr; }
  .proj-meta-bar { grid-template-columns: 1fr 1fr; }
  .proj-text-narrow { padding: 48px 20px; }
  .proj-cover-overlay { padding: 20px; }
}

@media (max-width: 480px) {
  .section, .section-full { padding: 48px 16px; }
  .heading-xl { letter-spacing: -0.04em; }
  .proj-outcomes-grid { grid-template-columns: 1fr; }
  .contact-actions { flex-direction: column; width: 100%; }
  .email-link { width: 100%; justify-content: center; font-size: 15px; }
  .btn { width: 100%; justify-content: center; }
  .bento { gap: 12px; }
  .filter-bar { padding: 0 16px 32px; gap: 6px; }
  .filter-btn { font-size: 11px; padding: 6px 12px; }
  .pr-year { display: none; }
  .project-row { grid-template-columns: 1fr; gap: 12px; }
  .pr-meta { display: none; }
  .pr-title { font-size: 17px; }
  .fp-body { padding: 24px 20px; }
  .fp-title { font-size: 20px; }
  .fp-metrics { gap: 16px; }
  .fp-metric-val { font-size: 22px; }
  .contact-cards { grid-template-columns: 1fr; }
  .cc { padding: 28px 20px; }
  .avail-chips { gap: 8px; }
  .values-grid { grid-template-columns: 1fr; }
  .project-row::after { inset: 0 -16px; }
  .tl-item { grid-template-columns: 60px 1fr; gap: 10px; }
}

/* ═══════════════════════════════════════════════════
   EXIT INTENT MODAL
   ═══════════════════════════════════════════════════ */

#exit-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  transition: opacity 0.35s var(--ease-out);
}
#exit-modal-overlay.em-visible {
  opacity: 1;
}

.exit-modal-card {
  position: relative;
  background: var(--white);
  border-radius: 20px;
  padding: 48px;
  max-width: 460px;
  width: 100%;
  border: 1px solid var(--gray-200);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.18), 0 0 0 1px rgba(0, 0, 0, 0.04);
  transform: translateY(28px) scale(0.96);
  opacity: 0;
  transition: transform 0.45s var(--ease-spring), opacity 0.35s var(--ease-out);
}
#exit-modal-overlay.em-visible .exit-modal-card {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.exit-modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--gray-100);
  color: var(--gray-600);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: none;
  transition: background 0.2s, color 0.2s, transform 0.25s var(--ease-out);
}
.exit-modal-close:hover {
  background: var(--gray-200);
  color: var(--black);
  transform: rotate(90deg);
}

.exit-modal-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.exit-modal-eyebrow::before {
  content: '';
  display: block;
  width: 20px;
  height: 1px;
  background: var(--teal);
  flex-shrink: 0;
}

.exit-modal-headline {
  font-size: clamp(26px, 3.5vw, 34px);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.05;
  color: var(--black);
  margin-bottom: 16px;
}
.exit-modal-headline em {
  font-style: italic;
  font-weight: 400;
  color: var(--gray-400);
}

.exit-modal-body {
  font-size: 14px;
  line-height: 1.75;
  color: var(--gray-600);
  margin-bottom: 28px;
}

.exit-modal-stats {
  display: flex;
  gap: 0;
  margin-bottom: 32px;
  border-radius: 12px;
  border: 1px solid var(--gray-200);
  overflow: hidden;
}
.exit-modal-stat {
  flex: 1;
  padding: 16px 20px;
  background: var(--gray-100);
  border-right: 1px solid var(--gray-200);
  position: relative;
}
.exit-modal-stat:last-child { border-right: none; }
.exit-modal-stat::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 24px;
  height: 2px;
  background: var(--teal);
}
.exit-modal-stat-val {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.05em;
  color: var(--black);
  line-height: 1;
}
.exit-modal-stat-lbl {
  font-size: 11px;
  color: var(--gray-400);
  margin-top: 4px;
  line-height: 1.3;
}

.exit-modal-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.exit-modal-btn-primary {
  display: inline-flex;
  align-items: center;
  padding: 12px 24px;
  background: var(--black);
  color: var(--white);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: -0.01em;
  min-height: 44px;
  transition: transform 0.25s var(--ease-spring), box-shadow 0.25s;
}
.exit-modal-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.exit-modal-btn-secondary {
  display: inline-flex;
  align-items: center;
  padding: 12px 22px;
  border: 1px solid var(--gray-200);
  color: var(--gray-600);
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  min-height: 44px;
  transition: border-color 0.2s, color 0.2s;
}
.exit-modal-btn-secondary:hover {
  border-color: var(--black);
  color: var(--black);
}

.exit-modal-dismiss {
  display: block;
  width: 100%;
  text-align: center;
  font-size: 12px;
  color: var(--gray-400);
  cursor: none;
  transition: color 0.2s;
  padding: 4px 0;
}
.exit-modal-dismiss:hover { color: var(--gray-600); }

/* Dark mode */
[data-theme="dark"] .exit-modal-card {
  background: #1c1c1c;
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.6);
}
[data-theme="dark"] .exit-modal-close {
  background: #282828;
  color: rgba(240, 240, 238, 0.55);
}
[data-theme="dark"] .exit-modal-close:hover {
  background: #333;
  color: #f0f0ee;
}
[data-theme="dark"] .exit-modal-stats {
  border-color: rgba(255, 255, 255, 0.06);
}
[data-theme="dark"] .exit-modal-stat {
  background: #141414;
  border-right-color: rgba(255, 255, 255, 0.06);
}
[data-theme="dark"] .exit-modal-btn-secondary {
  border-color: rgba(255, 255, 255, 0.12);
  color: rgba(240, 240, 238, 0.55);
}
[data-theme="dark"] .exit-modal-btn-secondary:hover {
  border-color: var(--black);
  color: var(--black);
}

/* Mobile */
@media (max-width: 480px) {
  .exit-modal-card { padding: 32px 24px; }
  .exit-modal-actions { flex-direction: column; }
  .exit-modal-btn-primary,
  .exit-modal-btn-secondary { justify-content: center; }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  #exit-modal-overlay,
  .exit-modal-card { transition: none !important; }
}
