/* ============================================================
   THRIVE CREATIVE STUDIO · DESIGN SYSTEM v2.0
   Single source of truth: tokens + base + components.
   Import once per page. Page-specific styles go inline.
   ============================================================ */

/* ============ TOKENS ============ */
:root {
  /* COLOR — paper / ink / fire */
  --bg-paper:        #EDE5D3;
  --bg-paper-deep:   #E2D8C2;
  --surface:         #F5EFE0;
  --surface-warm:    #FAF8F5;
  --ink:             #0A0A0A;
  --ink-soft:        #1A1A1A;
  --body:            #5A5650;
  --muted:           #A39E95;
  --hairline:        #D6CCB5;
  --hairline-soft:   #E2D8C2;
  --coral:           #E8521A;
  --coral-deep:      #C44012;
  --coral-soft:      #F08056;
  --night:           #0A0A0A;
  --paper-on-night:  #F5EFE0;
  --green:           #2ECC71;

  /* TYPE — Hybrid system
     - Hero only: Archivo Black
     - Everywhere else: Hanken Grotesk
     - Italic accents: Fraunces 300 italic
     - Mono: JetBrains Mono                              */
  --font-hero:  'Archivo Black', system-ui, sans-serif;
  --font-sans:  'Hanken Grotesk', system-ui, sans-serif;
  --font-serif: 'Fraunces', Georgia, serif;
  --font-mono:  'JetBrains Mono', ui-monospace, Menlo, monospace;

  /* SCALE — modular */
  --t-micro:   0.6875rem;
  --t-tiny:    0.75rem;
  --t-small:   0.875rem;
  --t-body:    1rem;
  --t-lead:    1.15rem;
  --t-h4:      1.5rem;
  --t-h3:      2.25rem;
  --t-h2:      3.25rem;
  --t-h1:      4.5rem;
  --t-display: 6rem;

  /* SPACING */
  --s-1: 0.25rem; --s-2: 0.5rem; --s-3: 0.75rem; --s-4: 1rem; --s-5: 1.5rem;
  --s-6: 2rem;    --s-7: 3rem;   --s-8: 4rem;    --s-9: 6rem;   --s-10: 8rem;

  /* RADII */
  --r-card:    14px;
  --r-card-lg: 18px;
  --r-pill:    999px;
  --r-tag:     4px;
  --r-button:  3px;

  /* SHADOW — paper, not glass */
  --shadow-card: 0 8px 24px -8px rgba(10,10,10,0.06), 0 1px 2px rgba(10,10,10,0.04);
  --shadow-lift: 0 20px 48px -16px rgba(10,10,10,0.12), 0 2px 4px rgba(10,10,10,0.04);
  --shadow-deep: 0 30px 80px -20px rgba(10,10,10,0.25);

  /* MOTION */
  --m-fast: 150ms;
  --m-base: 220ms;
  --m-slow: 380ms;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* ============ RESET ============ */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: hidden; }
body {
  background: var(--bg-paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: var(--t-body);
  line-height: 1.5;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img, svg { max-width: 100%; display: block; }
*:focus-visible { outline: 2px solid var(--coral); outline-offset: 3px; border-radius: 2px; }

/* ============ LAYOUT ============ */
.wrap { max-width: 1400px; margin: 0 auto; padding: 0 var(--s-7); }
@media (max-width: 1024px) { .wrap { padding: 0 var(--s-5); } }
@media (max-width: 640px)  { .wrap { padding: 0 var(--s-4); } }

.section { padding: var(--s-9) 0; position: relative; }
.section-dark { background: var(--night); color: var(--paper-on-night); }
.section-paper-deep { background: var(--bg-paper-deep); }

/* ============ TYPE PRIMITIVES ============ */
/* HERO — Archivo Black only here */
.h-hero {
  font-family: var(--font-hero);
  font-weight: 400; /* Archivo Black is single-weight */
  font-size: clamp(2.6rem, 5.4vw, 5.4rem);
  line-height: 0.96;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.h-hero em { font-family: var(--font-serif); font-style: italic; font-weight: 300; letter-spacing: -0.005em; }
.h-hero .dot { color: var(--coral); }

/* Section + sub-hero headings — Hanken Black */
.h-1 {
  font-family: var(--font-sans);
  font-weight: 900;
  font-size: clamp(2.5rem, 4.5vw, var(--t-h1));
  line-height: 0.95;
  letter-spacing: -0.03em;
  color: var(--ink);
}
.h-1 em { font-family: var(--font-serif); font-style: italic; font-weight: 300; }
.h-1 .dot { color: var(--coral); }

.h-2 {
  font-family: var(--font-sans);
  font-weight: 900;
  font-size: clamp(2rem, 3.4vw, var(--t-h2));
  line-height: 1.02;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.h-2 em { font-family: var(--font-serif); font-style: italic; font-weight: 300; }
.h-2 .dot { color: var(--coral); }

.h-3 {
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: var(--t-h3);
  line-height: 1.1;
  letter-spacing: -0.018em;
  color: var(--ink);
}
.h-3 em { font-family: var(--font-serif); font-style: italic; font-weight: 300; }
.h-3 .dot { color: var(--coral); }

.h-4 {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: var(--t-h4);
  line-height: 1.2;
  color: var(--ink);
}
.h-4 em { font-family: var(--font-serif); font-style: italic; font-weight: 300; }

.lead {
  font-family: var(--font-sans);
  font-size: var(--t-lead);
  line-height: 1.55;
  color: var(--body);
  font-weight: 400;
}
.lead b, .lead strong { color: var(--ink); font-weight: 700; }

.body-copy {
  font-family: var(--font-sans);
  font-size: var(--t-body);
  line-height: 1.65;
  color: var(--body);
}
.body-copy b, .body-copy strong { color: var(--ink); font-weight: 700; }
.body-copy em { font-family: var(--font-serif); font-style: italic; color: var(--ink); }

/* ============ EYEBROWS / LABELS / NUMERALS ============ */
.eyebrow {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: var(--t-micro);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--coral);
  display: inline-flex;
  align-items: center;
  gap: var(--s-3);
}
.eyebrow::before {
  content: '';
  display: block;
  width: 2rem;
  height: 1px;
  background: var(--coral);
}
.eyebrow .num {
  color: var(--muted);
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  letter-spacing: 0.02em;
  text-transform: none;
  font-size: var(--t-small);
}

.tag {
  display: inline-block;
  background: var(--surface-warm);
  border: 0.5px solid var(--hairline);
  padding: 0.45rem 0.85rem;
  border-radius: var(--r-tag);
  font-family: var(--font-sans);
  font-size: var(--t-micro);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
}
.tag.coral { background: var(--coral); color: white; border-color: var(--coral); }
.tag.ink   { background: var(--ink); color: var(--paper-on-night); border-color: var(--ink); }

.numeral {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  color: var(--coral);
  line-height: 0.9;
  letter-spacing: -0.01em;
}
.numeral.sm { font-size: var(--t-h4); }
.numeral.md { font-size: 2.4rem; }
.numeral.lg { font-size: 4rem; }

.page-num {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: var(--t-micro);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--body);
}
.page-num .sep { color: var(--coral); }

/* ============ BUTTONS ============ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: var(--t-small);
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: background var(--m-base) var(--ease), transform var(--m-base) var(--ease), color var(--m-base) var(--ease);
  border: none;
  cursor: pointer;
  min-height: 48px;
  border-radius: var(--r-button);
  padding: 0.85rem 1.4rem;
  white-space: nowrap;
}
.btn-primary { background: var(--coral); color: white; }
.btn-primary:hover { background: var(--coral-deep); transform: translateY(-1px); }
.btn-ink { background: var(--ink); color: var(--paper-on-night); }
.btn-ink:hover { background: #2a2a2a; }
.btn-ghost { background: transparent; color: var(--ink); border: 0.5px solid var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--paper-on-night); }
.btn-link {
  padding: 0; background: transparent; color: var(--ink);
  min-height: auto; border-bottom: 1px solid currentColor; border-radius: 0;
}
.btn-link:hover { color: var(--coral); }
.btn .arr { transition: transform var(--m-base) var(--ease); }
.btn:hover .arr { transform: translateX(3px); }
.btn-lg { font-size: 0.95rem; min-height: 56px; padding: 1.05rem 1.8rem; }

/* ============ CARDS (bento primitives) ============ */
.card {
  background: var(--surface);
  border-radius: var(--r-card);
  padding: var(--s-6);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  transition: transform var(--m-base) var(--ease), box-shadow var(--m-base) var(--ease);
  box-shadow: var(--shadow-card);
  border: 0.5px solid rgba(0,0,0,0.04);
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.card-num {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  color: var(--coral);
  font-size: var(--t-h4);
  line-height: 1;
}
.card-tag {
  position: absolute;
  top: var(--s-5);
  right: var(--s-5);
  font-family: var(--font-sans);
  font-size: var(--t-micro);
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}
.card-icon {
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink);
}
.card-icon svg { width: 24px; height: 24px; }
.card-h {
  font-family: var(--font-sans);
  font-weight: 900;
  font-size: var(--t-h4);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.card-h em { font-family: var(--font-serif); font-weight: 300; font-style: italic; }
.card-body {
  font-size: var(--t-small);
  line-height: 1.65;
  color: var(--body);
}
.card-arrow {
  position: absolute;
  bottom: var(--s-5);
  right: var(--s-5);
  width: 30px; height: 30px;
  border-radius: 50%;
  background: transparent;
  border: 0.5px solid var(--hairline);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--body);
  font-size: 0.78rem;
  transition: all var(--m-base) var(--ease);
}
.card:hover .card-arrow {
  background: var(--coral);
  border-color: var(--coral);
  color: white;
  transform: rotate(-45deg);
}
.card.warm { background: var(--surface-warm); }
.card.dark { background: var(--night); color: var(--paper-on-night); }
.card.dark .card-h { color: var(--paper-on-night); }
.card.dark .card-body { color: var(--muted); }
.card.dark .card-tag { color: var(--muted); }
.card.dark .card-icon { color: var(--paper-on-night); }
.card.dark .card-arrow { border-color: rgba(255,255,255,0.16); color: var(--muted); }
.card.coral { background: var(--coral); color: white; }
.card.coral .card-h { color: white; }
.card.coral .card-h em { color: rgba(255,255,255,0.88); }
.card.coral .card-body { color: rgba(255,255,255,0.92); }
.card.coral .card-tag { color: rgba(255,255,255,0.75); }
.card.coral .card-num { color: rgba(255,255,255,0.55); }
.card.coral .card-icon { color: white; }
.card.coral .card-arrow { border-color: rgba(255,255,255,0.4); color: white; }
.card.coral:hover .card-arrow { background: var(--ink); border-color: var(--ink); }

/* ============ SECTION HEADER (eyebrow + heading + kicker) ============ */
.s-header {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--s-7);
  align-items: flex-end;
  margin-bottom: var(--s-8);
  padding-bottom: var(--s-5);
  border-bottom: 0.5px solid var(--hairline);
}
.s-header-dark { border-bottom-color: rgba(255,255,255,0.08); }
.s-header > div:first-child { display: flex; flex-direction: column; gap: var(--s-4); }
.s-kicker {
  font-size: var(--t-body);
  color: var(--body);
  line-height: 1.65;
  max-width: 380px;
  flex-shrink: 0;
}
.section-dark .s-kicker { color: var(--muted); }
@media (max-width: 768px) {
  .s-header { grid-template-columns: 1fr; }
  .s-kicker { max-width: none; }
}

/* ============ ACCESSIBILITY ============ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
