/* ============================================================
   HANSOLU DESIGN SYSTEM — tokens
   Import once at the top of every artifact:
   <link rel="stylesheet" href="../../colors_and_type.css">

   Fonts via Google Fonts (substitution flagged in README).
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,400;12..96,500;12..96,600;12..96,700&family=Manrope:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  /* ---------- COLOR / BRAND ---------- */
  --petrol:           #006c85;   /* primary teal — the seagull color */
  --petrol-600:       #005468;   /* hover */
  --petrol-700:       #003e4d;   /* active */
  --petrol-300:       #4a9fb3;
  --petrol-100:       #cfe4e9;
  --petrol-050:       #e9f1f3;   /* tint zones */

  --ink:              #0a1f25;   /* primary text */
  --ink-700:          #1f3640;
  --ink-500:          #4a5d63;   /* slate / secondary text */
  --ink-400:          #6f7f85;
  --ink-300:          #97a4a9;

  --paper:            #f7f4ef;   /* warm off-white page bg */
  --paper-warm:       #f0ebe2;
  --surface:          #ffffff;   /* card bg */

  --border:           #e6e2dc;   /* hairline */
  --border-strong:    #cfc9c0;

  /* Semantic — muted, never neon */
  --success:          #2d8659;
  --success-bg:       #e6f1eb;
  --warning:          #b8730f;
  --warning-bg:       #f7ecd9;
  --error:            #b8362f;
  --error-bg:         #f5e0de;
  --info:             var(--petrol);
  --info-bg:          var(--petrol-050);

  /* Semantic foreground / background roles */
  --fg-1:             var(--ink);          /* primary text */
  --fg-2:             var(--ink-500);      /* secondary text */
  --fg-3:             var(--ink-400);      /* tertiary / placeholders */
  --fg-on-petrol:     #ffffff;
  --bg-1:             var(--paper);        /* page */
  --bg-2:             var(--surface);      /* card */
  --bg-3:             var(--paper-warm);   /* recessed / striped rows */

  /* ---------- TYPE ---------- */
  --font-display:     'Bricolage Grotesque', ui-serif, Georgia, serif;
  --font-body:        'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono:        'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;

  /* Scale (px, 1.250 modular, lightly hand-tuned) */
  --fs-display:       56px;
  --fs-h1:            40px;
  --fs-h2:            30px;
  --fs-h3:            22px;
  --fs-h4:            18px;
  --fs-body:          16px;
  --fs-body-sm:       14px;
  --fs-caption:       12px;
  --fs-eyebrow:       11px;   /* used ALL-CAPS for section labels only */

  /* Line heights */
  --lh-tight:         1.1;
  --lh-snug:          1.25;
  --lh-normal:        1.5;
  --lh-loose:         1.65;

  --tracking-eyebrow: 0.12em;
  --tracking-wide:    0.03em;

  /* ---------- SPACING (4-base) ---------- */
  --sp-1:  4px;
  --sp-2:  8px;
  --sp-3:  12px;
  --sp-4:  16px;
  --sp-5:  24px;
  --sp-6:  32px;
  --sp-7:  48px;
  --sp-8:  64px;
  --sp-9:  96px;

  /* ---------- RADII ---------- */
  --radius-sm: 4px;    /* inputs */
  --radius-md: 8px;    /* cards, buttons */
  --radius-lg: 14px;   /* panels, modals */
  --radius-full: 9999px;

  /* ---------- SHADOWS (used sparingly) ---------- */
  --shadow-sm: 0 1px 2px rgba(10,31,37,0.05);
  --shadow-md: 0 4px 16px -4px rgba(10,31,37,0.08), 0 2px 4px rgba(10,31,37,0.04);
  --shadow-lg: 0 16px 40px -12px rgba(10,31,37,0.16);

  /* ---------- MOTION ---------- */
  --ease-default: cubic-bezier(0.2, 0.6, 0.2, 1);
  --dur-fast: 120ms;
  --dur-base: 200ms;
  --dur-slow: 320ms;

  /* ---------- LAYOUT ---------- */
  --maxw-prose:    720px;
  --maxw-form:     960px;
  --maxw-content:  1200px;
  --nav-h:         64px;
  --progress-h:    6px;
}

/* ============================================================
   Base / semantic element styles
   ============================================================ */

html, body {
  background: var(--bg-1);
  color: var(--fg-1);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: var(--lh-normal);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, .display {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--fg-1);
  letter-spacing: -0.01em;
  line-height: var(--lh-snug);
  margin: 0;
  text-wrap: balance;
}

.display    { font-size: var(--fs-display); font-weight: 600; line-height: var(--lh-tight); letter-spacing: -0.02em; }
h1, .h1     { font-size: var(--fs-h1);      font-weight: 600; line-height: 1.15; letter-spacing: -0.015em; }
h2, .h2     { font-size: var(--fs-h2);      font-weight: 600; }
h3, .h3     { font-size: var(--fs-h3);      font-weight: 600; }
h4, .h4     { font-size: var(--fs-h4);      font-weight: 600; }

p           { margin: 0; font-size: var(--fs-body); color: var(--fg-1); line-height: var(--lh-normal); text-wrap: pretty; }
.body-sm    { font-size: var(--fs-body-sm); color: var(--fg-2); }
.caption    { font-size: var(--fs-caption); color: var(--fg-2); line-height: var(--lh-snug); }

.eyebrow {
  font-family: var(--font-body);
  font-size: var(--fs-eyebrow);
  font-weight: 600;
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
  color: var(--petrol);
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.92em;
  letter-spacing: 0;
}

a {
  color: var(--petrol);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover { color: var(--petrol-600); }

::selection {
  background: var(--petrol-100);
  color: var(--ink);
}

/* Utility focus ring — apply to any interactive element */
.focus-ring:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
a:focus-visible {
  outline: 2px solid rgba(0, 108, 133, 0.6);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}
