/* =========================================================================
   placement.solutions — Design Tokens
   Mirror of §6 of the frontend packet. Single source of truth. When this
   ports into Next.js, the values below land verbatim in the @theme block
   in app/globals.css; class names + var() refs require no changes.
   ========================================================================= */

:root {
  /* ---------- color: ink scale ---------- */
  --color-ink:        #0B1220;
  --color-graphite:   #1E2638;
  --color-slate-700:  #2A3447;
  --color-slate-500:  #5F6B82;
  --color-slate-300:  #C9D1DE;

  /* ---------- color: paper scale ---------- */
  --color-paper:      #F7F5EE;
  --color-bone:       #EFEBE0;
  --color-ivory:      #FFFDF6;

  /* ---------- color: brand ---------- */
  --color-brand:      #6B1F2E;   /* Oxblood */
  --color-brand-700:  #8C2B3F;
  --color-brand-gold: #B89150;

  /* ---------- color: semantic ---------- */
  --color-conf-high:  #1F6B4A;
  --color-conf-med:   #B0822D;
  --color-conf-low:   #6E7585;
  --color-danger:     #B23A3A;

  /* ---------- type ---------- */
  --font-sans:  "Inter Display", "Söhne", "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-serif: "Source Serif 4", ui-serif, Georgia, "Times New Roman", serif;
  --font-mono:  "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  /* ---------- radius ---------- */
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 10px;

  /* ---------- shadow ---------- */
  --shadow-card:    0 1px 2px rgba(11,18,32,.06), 0 4px 12px rgba(11,18,32,.04);
  --shadow-elev-2:  0 4px 16px rgba(11,18,32,.08), 0 12px 32px rgba(11,18,32,.06);

  /* ---------- semantic surface mapping (light) ---------- */
  --surface-page:    var(--color-paper);
  --surface-raised:  var(--color-ivory);
  --surface-sunken:  var(--color-bone);
  --border-soft:     #E2DDCD;
  --border-strong:   #C9C3AF;
  --text-primary:    var(--color-ink);
  --text-secondary:  var(--color-slate-700);
  --text-tertiary:   var(--color-slate-500);
}

:root.dark, .dark {
  --surface-page:    var(--color-ink);
  --surface-raised:  var(--color-graphite);
  --surface-sunken:  #070C18;
  --border-soft:     var(--color-slate-700);
  --border-strong:   var(--color-slate-500);
  --text-primary:    #F2F0E8;
  --text-secondary:  var(--color-slate-300);
  --text-tertiary:   var(--color-slate-500);
  --shadow-card:     0 1px 2px rgba(0,0,0,.4), 0 4px 12px rgba(0,0,0,.25);
}

/* =========================================================================
   element resets
   ========================================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--surface-page);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 26px;
  font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, textarea, select { font: inherit; color: inherit; }
img, svg { display: block; max-width: 100%; }
hr { border: 0; border-top: 1px solid var(--border-soft); margin: 0; }

::selection { background: var(--color-brand); color: var(--color-ivory); }

/* =========================================================================
   type scale
   ========================================================================= */
.t-display { font-size: 56px; line-height: 60px; letter-spacing: -0.025em; font-weight: 600; }
.t-h1      { font-size: 40px; line-height: 48px; letter-spacing: -0.02em;  font-weight: 600; }
.t-h2      { font-size: 32px; line-height: 40px; letter-spacing: -0.018em; font-weight: 600; }
.t-h3      { font-size: 24px; line-height: 32px; letter-spacing: -0.012em; font-weight: 600; }
.t-h4      { font-size: 18px; line-height: 26px; letter-spacing: -0.005em; font-weight: 600; }
.t-body    { font-size: 16px; line-height: 26px; }
.t-small   { font-size: 14px; line-height: 22px; }
.t-micro   { font-size: 12px; line-height: 18px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-tertiary); }
.t-mono    { font-family: var(--font-mono); font-size: 13px; line-height: 22px; }
.t-serif   { font-family: var(--font-serif); }
.t-balance { text-wrap: balance; }
.t-pretty  { text-wrap: pretty; }

/* =========================================================================
   layout primitives
   ========================================================================= */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}
.container-wide { max-width: 1320px; }
.container-narrow { max-width: 760px; }

.row    { display: flex; align-items: center; gap: 12px; }
.col    { display: flex; flex-direction: column; gap: 12px; }
.grid   { display: grid; }
.gap-2  { gap: 8px; }  .gap-3  { gap: 12px; } .gap-4 { gap: 16px; }
.gap-6  { gap: 24px; } .gap-8  { gap: 32px; } .gap-12 { gap: 48px; }

/* =========================================================================
   primitive components
   ========================================================================= */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  font-size: 14px; line-height: 22px;
  font-weight: 500;
  letter-spacing: -0.005em;
  transition: background 120ms, border-color 120ms, color 120ms, transform 120ms;
  white-space: nowrap;
  cursor: pointer;
}
.btn:focus-visible {
  outline: 2px solid var(--color-brand);
  outline-offset: 2px;
}
.btn-primary {
  background: var(--color-brand);
  color: var(--color-ivory);
}
.btn-primary:hover { background: var(--color-brand-700); }

.btn-secondary {
  background: var(--surface-raised);
  border-color: var(--border-strong);
  color: var(--text-primary);
}
.btn-secondary:hover { background: var(--surface-sunken); }

.btn-ghost {
  background: transparent;
  color: var(--text-primary);
}
.btn-ghost:hover { background: var(--surface-sunken); }

.btn-sm { padding: 6px 10px; font-size: 13px; line-height: 20px; }
.btn-lg { padding: 12px 20px; font-size: 15px; line-height: 24px; }

.tag {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  background: var(--surface-sunken);
  border: 1px solid var(--border-soft);
  font-size: 12px; line-height: 18px;
  color: var(--text-secondary);
  white-space: nowrap;
}

.kbd {
  display: inline-block;
  padding: 1px 5px;
  font-family: var(--font-mono);
  font-size: 11px; line-height: 16px;
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: 3px;
  background: var(--surface-raised);
  color: var(--text-secondary);
}

.hr-section {
  height: 1px;
  background: var(--border-soft);
  width: 100%;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; line-height: 16px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-brand);
  font-weight: 500;
}
.eyebrow::before {
  content: "";
  width: 18px; height: 1px;
  background: var(--color-brand);
}

.dot {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--color-conf-high);
}

/* focus-visible hardening */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--color-brand);
  outline-offset: 2px;
  border-radius: 3px;
}

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