/* ============================================================
   NEST — Brand tokens & base styles
   Source of truth: NEST Style Guide
   Primary: Turquoise Green #009991 · Living Lilac #D9B5FF
   Secondary: Green #69CF63 · Yellow #FFF770 · Deep Purple #3D215C · Forest #053B38
   Type: Inter (headings, bold, uppercase) · Mulish (body, ~Proxima Nova)
   ============================================================ */

:root {
  /* Brand colours (exact from style guide) */
  --turquoise: #009991;
  --turquoise-deep: #00665F;
  --lilac: #D9B5FF;
  --green: #69CF63;
  --yellow: #FFF770;
  --deep-purple: #3D215C;
  --forest: #053B38;

  /* Working surfaces */
  --surface: #F4F7F4;
  --surface-2: #EBF1ED;
  --white: #FFFFFF;
  --card: #FFFFFF;

  /* Text */
  --ink: #0C2723;          /* near-forest, headings on light */
  --ink-soft: #44574F;     /* body */
  --ink-faint: #748079;    /* captions */
  --on-dark: #FFFFFF;
  --on-dark-soft: #B7D4CC;

  /* Lines */
  --line: #DDE6E0;
  --line-strong: #C5D3CB;

  /* ICOP theme colours */
  --t-sbd: #009991;        /* social business development */
  --t-ecs: #46B83F;        /* engaged community science (deepened green for contrast) */
  --t-rm:  #9B6FD4;        /* reflexive monitoring (usable lilac) */
  --t-kc:  #E0A800;        /* knowledge creation (deepened yellow for contrast) */
  --t-sbd-tint: #E2F2F0;
  --t-ecs-tint: #E9F6E8;
  --t-rm-tint:  #F1E9FB;
  --t-kc-tint:  #FBF3D6;

  /* Radii */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
  --r-xl: 26px;
  --r-pill: 999px;

  /* Shadows — soft, green-tinted */
  --sh-sm: 0 1px 2px rgba(12,39,35,.06), 0 1px 3px rgba(12,39,35,.05);
  --sh-card: 0 2px 4px rgba(12,39,35,.04), 0 8px 24px rgba(12,39,35,.07);
  --sh-pop: 0 8px 20px rgba(12,39,35,.10), 0 24px 60px rgba(12,39,35,.16);

  --font-display: 'Inter', system-ui, sans-serif;
  --font-body: 'Mulish', system-ui, sans-serif;

  --maxw: 1240px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink-soft);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  color: var(--ink);
  margin: 0;
  line-height: 1.04;
  letter-spacing: -0.01em;
}

p { margin: 0; text-wrap: pretty; }

/* Display headings — uppercase bold per brand */
.display {
  font-family: var(--font-display);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.015em;
  line-height: 0.98;
  color: var(--ink);
}

/* Eyebrow — small uppercase label above headings */
.eyebrow {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12.5px;
  color: var(--turquoise);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}
.eyebrow.on-dark { color: var(--green); }
.eyebrow::before {
  content: "";
  width: 22px; height: 2px;
  background: currentColor;
  display: inline-block;
}
.eyebrow.no-rule::before { display: none; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 40px;
}
@media (max-width: 720px) { .container { padding: 0 20px; } }

/* ---- Buttons ---- */
.btn {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.02em;
  border: none;
  border-radius: var(--r-pill);
  padding: 12px 22px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: transform .12s ease, background .15s ease, box-shadow .15s ease, color .15s ease, border-color .15s ease;
  text-decoration: none;
  line-height: 1;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--turquoise); color: #fff; }
.btn-primary:hover { background: var(--turquoise-deep); }
.btn-ghost { background: transparent; color: var(--turquoise); border: 1.5px solid var(--line-strong); }
.btn-ghost:hover { border-color: var(--turquoise); background: #fff; }
.btn-dark { background: var(--forest); color: #fff; }
.btn-dark:hover { background: #0a4a44; }
.btn-on-dark { background: var(--green); color: var(--forest); }
.btn-on-dark:hover { background: #7adb74; }
.btn-on-dark-ghost { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.35); }
.btn-on-dark-ghost:hover { border-color: #fff; background: rgba(255,255,255,.08); }
.btn-sm { padding: 9px 16px; font-size: 13px; }

/* focus ring */
:focus-visible {
  outline: 3px solid var(--turquoise);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---- Card ---- */
.card {
  background: var(--card);
  border-radius: var(--r-md);
  box-shadow: var(--sh-card);
  overflow: hidden;
  position: relative;
}
.card-accent { height: 6px; width: 100%; display: block; }

/* ---- Inputs ---- */
.field {
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--ink);
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: var(--r-sm);
  padding: 11px 13px;
  width: 100%;
  transition: border-color .15s ease, box-shadow .15s ease;
  resize: vertical;
}
.field::placeholder { color: var(--ink-faint); }
.field:focus { outline: none; border-color: var(--turquoise); box-shadow: 0 0 0 3px rgba(0,153,145,.15); }
label.flabel {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-faint);
  display: block;
  margin-bottom: 6px;
}

/* ---- Theme tag ---- */
.theme-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 11.5px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink);
  padding: 5px 11px 5px 9px;
  border-radius: var(--r-pill);
  background: var(--surface-2);
  white-space: nowrap;
}
.theme-tag .dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }

/* scrollbars */
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-thumb { background: #cdd9d2; border-radius: 999px; border: 3px solid var(--surface); }
::-webkit-scrollbar-thumb:hover { background: #b3c4ba; }

/* utility */
.muted { color: var(--ink-faint); }
.hidden { display: none !important; }

/* reveal-on-scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* print */
@media print {
  .no-print { display: none !important; }
  body { background: #fff; }
}
