/* ==========================================================================
   Meridian Investor Portal — foundations
   Palette and type sampled directly from the source documents:
   ground #07150E · ivory #FBFBF7 · orange #D9822F · green #63A883
   Barlow · Spectral · IBM Plex Mono

   Shared by the story page (story.css) and the reader (reader.css).
   ========================================================================== */

:root {
  /* Ground */
  --ink:        #07150E;
  --ink-room:   #04120F;   /* sampled from the Deep Culture pages */
  --ink-2:      #050F0A;   /* reader canvas — deeper than the page */
  --panel:      #0B1C13;

  /* Type */
  --ivory:      #FBFBF7;
  --ivory-warm: #F2E9D6;
  --dim:        #A2ABA3;
  --dimmer:     #79837B;

  /* Accents */
  --orange:     #D9822F;
  --green:      #63A883;

  /* Structure */
  --rule:       rgba(251, 251, 247, 0.11);
  --rule-soft:  rgba(251, 251, 247, 0.06);
  --rule-firm:  rgba(251, 251, 247, 0.2);

  --sans:  "Barlow", "Helvetica Neue", Arial, sans-serif;
  --serif: "Spectral", Georgia, serif;
  --mono:  "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);

  /* Inset for text that sits alongside full-bleed pages */
  --edge: clamp(20px, 4vw, 72px);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

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

a { color: inherit; text-decoration: none; }

::selection { background: rgba(217, 130, 47, 0.3); }

:focus-visible { outline: 1px solid var(--orange); outline-offset: 3px; }

/* ---- Primitives --------------------------------------------------------- */


/* The Meridian mark */
.mark {
  width: 20px;
  height: 20px;
  flex: none;
  fill: none;
  stroke: var(--green);
  stroke-width: 2.1;
}
.mark .pupil { fill: var(--green); stroke: none; }

/* Icon toolbar button — reader chrome and the full-screen page view */
.tb {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  padding: 0;
  background: none;
  border: 0;
  color: var(--dim);
  cursor: pointer;
  flex: none;
  transition: color 0.15s var(--ease), background 0.15s var(--ease);
}
.tb:hover { color: var(--ivory); background: rgba(251, 251, 247, 0.07); }
.tb:disabled { opacity: 0.26; cursor: default; background: none; color: var(--dim); }
.tb svg { width: 17px; height: 17px; stroke: currentColor; fill: none; stroke-width: 1.7; }
.tb.is-on { color: var(--orange); }

.tb--text {
  width: auto;
  padding: 0 11px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 16px 26px;
  border: 1px solid transparent;
  background: var(--orange);
  color: #150B02;
  cursor: pointer;
  transition: background 0.2s var(--ease);
}
.btn:hover { background: #E8913B; }
.btn svg { width: 15px; height: 15px; stroke: currentColor; fill: none; stroke-width: 1.8; }

.btn--quiet {
  background: none;
  border: 0;
  padding: 8px 0;
  color: var(--dim);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  border-bottom: 1px solid var(--rule);
}
.btn--quiet:hover { color: var(--ivory); border-bottom-color: var(--orange); background: none; }

/* ---- Footer ------------------------------------------------------------ */

.ftr {
  background: var(--ink-room);
  margin-top: clamp(20px, 3vh, 36px);
  border-top: 1px solid var(--rule-soft);
  padding: 40px 0 60px;
}
.ftr__in {
  padding: 0 var(--edge);
  display: flex;
  flex-wrap: wrap;
  gap: 24px 40px;
  align-items: flex-start;
}
.ftr__disc {
  flex: 1 1 460px;
  font-size: 11.5px;
  line-height: 1.65;
  color: var(--dimmer);
  max-width: 78ch;
}
