/* ==========================================================================
   Base — foundation
   Palette, type ramp and radii follow judsondunne.com: a zinc scale on
   #FAFAFA, Bricolage Grotesque for display, Geist for UI, Geist Mono for
   labels. Product identity colours still come from src/theme/tokens.ts.
   ========================================================================== */

:root {
  /* Zinc ground */
  --bg:        #FAFAFA;
  --surface:   #FFFFFF;
  --surface-2: #F2F2F2;
  --line:      #E4E4E7;
  --line-2:    #D4D4D8;

  /* Ink */
  --ink:       #09090B;
  --ink-2:     #71717A;
  --ink-3:     #A1A1AA;

  /* Accents — muted jewel tones, same register as the reference site */
  --green:     #2F7D4B;
  --amber:     #B8801E;
  --teal:      #11938A;
  --orange:    #FF6B4A;
  --blue:      #2F6FE4;
  --violet:    #6D5BD0;

  /* Card tints */
  --tint-green:  #F1F6F2;
  --tint-amber:  #F8F5EE;
  --tint-blue:   #F0F4FB;
  --tint-violet: #F4F2FB;

  /* Radii */
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 20px;
  --r-xl: 24px;
  --r-2xl: 40px;
  --r-pill: 999px;

  /* Type */
  --font-display: 'Bricolage Grotesque', ui-sans-serif, system-ui, sans-serif;
  --font-ui: 'Geist', ui-sans-serif, -apple-system, system-ui, sans-serif;
  --font-mono: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

  /* Rhythm */
  --gutter: clamp(20px, 4vw, 56px);
  --maxw: 1180px;
  --nav-h: 64px;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 24px);
  background: var(--bg);
  color-scheme: light;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: -0.011em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; }
::selection { background: var(--ink); color: #fff; }

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

.skip-link {
  position: absolute; left: 12px; top: -80px; z-index: 999;
  background: var(--ink); color: #fff; padding: 12px 18px;
  border-radius: var(--r-pill); font-weight: 500;
  transition: top .18s ease;
}
.skip-link:focus { top: 12px; }

/* ---------------------------------------------------------------- layout -- */

.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
section { position: relative; }
.pad { padding-block: clamp(64px, 8vw, 116px); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.rule { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ------------------------------------------------------------------ type -- */

/* Display carries family and weight on the class, because these land on <p>
   and <div> as often as on a heading. */
.d1, .d2, .d3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.03;
  margin: 0;
  text-wrap: balance;
}
.d1 { font-size: clamp(38px, 4.7vw, 64px); letter-spacing: -0.038em; }
.d2 { font-size: clamp(30px, 3.6vw, 46px); letter-spacing: -0.034em; }
.d3 { font-size: clamp(21px, 2.1vw, 27px); letter-spacing: -0.028em; line-height: 1.18; }

h1, h2, h3, h4 { margin: 0; font-weight: 700; }

/* The reference's signature move: half the headline drops to the muted zinc. */
.mute { color: var(--ink-3); }

.lede { font-size: clamp(15px, 1.15vw, 17px); line-height: 1.6; color: var(--ink-2); text-wrap: pretty; }

/* Tiny bracketed mono labels — [ABOUT], [WORK] */
.tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.tag--ink { color: var(--ink-2); }

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

/* --------------------------------------------------------------- button --- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  height: 44px; padding: 0 20px;
  border-radius: var(--r-pill);
  font-size: 15px; font-weight: 500;
  letter-spacing: -0.012em;
  white-space: nowrap;
  transition: background .2s ease, border-color .2s ease, transform .18s cubic-bezier(.22,1,.36,1);
}
.btn:active { transform: scale(.975); }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: #27272A; }
.btn--plain { background: var(--surface); color: var(--ink); border: 1px solid var(--line); }
.btn--plain:hover { border-color: var(--line-2); background: #fff; }
.btn--lg { height: 52px; padding: 0 26px; font-size: 16px; }
.btn__ico { width: 15px; height: 15px; flex: none; }

/* --------------------------------------------------------------- badges --- */

.pill {
  display: inline-flex; align-items: center; gap: 9px;
  height: 30px; padding: 0 13px;
  border-radius: var(--r-pill);
  background: var(--surface);
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink-2);
  white-space: nowrap;
}
.dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--green); flex: none;
  animation: pulse 2.6s ease-out infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(47,125,75,.45); }
  70%  { box-shadow: 0 0 0 7px rgba(47,125,75,0); }
  100% { box-shadow: 0 0 0 0 rgba(47,125,75,0); }
}

/* ------------------------------------------------------------- reveal ----- */

.rv {
  opacity: 0; transform: translateY(18px);
  transition: opacity .7s cubic-bezier(.22,1,.36,1), transform .7s cubic-bezier(.22,1,.36,1);
  transition-delay: var(--d, 0ms);
}
.rv.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rv { opacity: 1 !important; transform: none !important; transition: none !important; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
