/* indiatrade.nz — design system
   Voices: pounamu (case for) / madder (case against) — equal weight, by design.
   Type: Newsreader (display) + Public Sans (body). */

@import url("/assets/fonts/fonts.css");

:root {
  --paper: #FCFBF8;
  --paper-raise: #FFFFFF;
  --paper-sink: #F4F2EC;
  --ink: #1C2530;
  --ink-soft: #4C5866;
  --ink-faint: #7A8494;
  --line: #E2DFD6;
  --line-strong: #C9C5B8;
  --marine: #1D4E89;
  --marine-deep: #163C6A;
  --pounamu: #14665A;
  --pounamu-wash: #EDF4F1;
  --madder: #93402E;
  --madder-wash: #F7EFEB;
  --gold: #B98A2E;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Public Sans", -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --maxw: 68rem;
  --textw: 44rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #14181E;
    --paper-raise: #1B2129;
    --paper-sink: #10141A;
    --ink: #E7E5DF;
    --ink-soft: #ADB4BE;
    --ink-faint: #79818D;
    --line: #2B323C;
    --line-strong: #3C4552;
    --marine: #7BA7DC;
    --marine-deep: #A3C3EA;
    --pounamu: #6DBCA9;
    --pounamu-wash: #18261F;
    --madder: #D98A72;
    --madder-wash: #2A1D18;
    --gold: #D3A94F;
  }
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  font-family: var(--sans);
  font-size: 1.04rem;
  line-height: 1.68;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--marine); text-decoration-thickness: 1px; text-underline-offset: 2.5px; }
a:hover { color: var(--marine-deep); }
a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--marine);
  outline-offset: 2px;
  border-radius: 2px;
}

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 1.25rem; }

/* ---------- header ---------- */
.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.site-header .wrap {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: .4rem 1.75rem;
  padding-top: 1.15rem; padding-bottom: 1.05rem;
}
.wordmark {
  font-family: var(--serif); font-weight: 700; font-size: 1.32rem;
  color: var(--ink); text-decoration: none; letter-spacing: .01em;
  white-space: nowrap;
}
.wordmark .tld { color: var(--gold); font-weight: 500; }
.site-nav { display: flex; flex-wrap: wrap; gap: .1rem .35rem; margin-left: auto; }
.site-nav a {
  font-size: .86rem; font-weight: 500; color: var(--ink-soft);
  text-decoration: none; padding: .3rem .55rem; border-radius: 4px;
}
.site-nav a:hover { color: var(--ink); background: var(--paper-sink); }
.site-nav a[aria-current="page"] { color: var(--ink); font-weight: 700; }

/* ---------- typography ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.18; letter-spacing: -0.008em; }
h1 { font-size: clamp(2.1rem, 5.4vw, 3.3rem); }
h2 { font-size: clamp(1.5rem, 3.2vw, 2rem); margin-bottom: .9rem; }
h3 { font-size: 1.22rem; margin-bottom: .5rem; }
p + p { margin-top: .9rem; }

.eyebrow {
  font-size: .74rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-faint); margin-bottom: .8rem;
}
.eyebrow .sep { color: var(--gold); padding: 0 .35rem; }
.eyebrow .devanagari { font-family: "Nirmala UI", "Kohinoor Devanagari", "Noto Sans Devanagari", "Mangal", var(--sans); }

.lede { font-size: 1.16rem; color: var(--ink-soft); max-width: var(--textw); }

section { padding: 3.2rem 0; }
section + section { border-top: 1px solid var(--line); }
.prose { max-width: var(--textw); }
.prose ul, .prose ol { padding-left: 1.35rem; margin: .8rem 0; }
.prose li + li { margin-top: .45rem; }

/* ---------- hero ---------- */
.hero { padding: 4.2rem 0 3.4rem; }
.hero h1 { max-width: 56rem; margin: .35rem 0 1.15rem; }
.hero .lede { font-size: 1.22rem; }
.status-line { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.6rem; align-items: center; }
.pill {
  display: inline-block; font-size: .82rem; font-weight: 600;
  padding: .32rem .8rem; border-radius: 999px;
  border: 1px solid var(--line-strong); color: var(--ink-soft); background: var(--paper-raise);
}
.pill.live { border-color: var(--gold); color: var(--ink); }
.pill.live::before { content: ""; display: inline-block; width: .48em; height: .48em; border-radius: 50%; background: var(--gold); margin-right: .5em; vertical-align: .08em; }

/* ---------- callout ---------- */
.callout {
  border: 1px solid var(--line-strong); border-left: 4px solid var(--gold);
  background: var(--paper-raise); border-radius: 6px;
  padding: 1.1rem 1.35rem; margin: 1.8rem 0; max-width: var(--textw);
}
.callout strong { font-weight: 700; }

/* ---------- key figures ---------- */
.figures { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; margin-top: 1.6rem; }
@media (max-width: 54rem) { .figures { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 34rem) { .figures { grid-template-columns: 1fr; } }
.figure { background: var(--paper-raise); padding: 1.15rem 1.25rem; }
.figure .n { font-family: var(--serif); font-size: 1.85rem; font-weight: 600; line-height: 1.15; }
.figure .d { font-size: .85rem; color: var(--ink-soft); margin-top: .3rem; }
.figure .s { font-size: .74rem; color: var(--ink-faint); margin-top: .35rem; }

/* ---------- timeline ---------- */
.timeline { list-style: none; margin-top: 1.4rem; max-width: 46rem; }
.timeline li { position: relative; padding: 0 0 1.5rem 2rem; border-left: 2px solid var(--line-strong); margin-left: .5rem; }
.timeline li:last-child { padding-bottom: .2rem; }
.timeline li::before {
  content: ""; position: absolute; left: -7px; top: .42em;
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--paper); border: 2.5px solid var(--line-strong);
}
.timeline li.done::before { background: var(--ink-soft); border-color: var(--ink-soft); }
.timeline li.now::before { background: var(--gold); border-color: var(--gold); }
.timeline .t-date { font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-faint); }
.timeline li.now .t-date { color: var(--gold); }
.timeline .t-title { font-weight: 700; margin: .1rem 0 .15rem; }
.timeline .t-body { font-size: .95rem; color: var(--ink-soft); }

/* ---------- the ledger (two voices) ---------- */
.ledger { display: grid; grid-template-columns: 1fr 1fr; gap: 0 3.2rem; position: relative; margin-top: 1.4rem; }
.ledger::before {
  content: ""; position: absolute; left: 50%; top: .4rem; bottom: .4rem;
  width: 1px; background: var(--line-strong);
}
.voice h3, .voice .voice-label {
  font-family: var(--serif); font-style: italic; font-weight: 500; font-size: 1.18rem;
  margin-bottom: .65rem;
}
.voice-for h3, .voice-for .voice-label { color: var(--pounamu); }
.voice-against h3, .voice-against .voice-label { color: var(--madder); }
.voice ul { list-style: none; }
.voice li { padding-left: 1.1rem; position: relative; font-size: .97rem; }
.voice li + li { margin-top: .6rem; }
.voice li::before { content: "—"; position: absolute; left: 0; }
.voice-for li::before { color: var(--pounamu); }
.voice-against li::before { color: var(--madder); }
@media (max-width: 46rem) {
  .ledger { grid-template-columns: 1fr; gap: 1.8rem; }
  .ledger::before { display: none; }
  .voice-against { border-top: 1px dashed var(--line-strong); padding-top: 1.5rem; }
}

/* balance glyph divider */
.balance-mark { text-align: center; margin: 2.4rem auto 0; color: var(--ink-faint); font-size: .85rem; }
.balance-mark svg { display: block; margin: 0 auto .45rem; width: 34px; height: 30px; stroke: var(--gold); fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- treaty extract ---------- */
.treaty-extract {
  border: 1px solid var(--line-strong); border-radius: 6px;
  background: var(--paper-raise);
  padding: 1.2rem 1.4rem 1.1rem; margin: 1.5rem 0;
  max-width: 46rem;
  box-shadow: 0 1px 0 var(--line);
}
.treaty-extract .cite {
  display: inline-block; font-family: var(--mono); font-size: .72rem; font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase;
  color: var(--madder); border: 1px solid currentColor; border-radius: 3px;
  padding: .12rem .5rem; margin-bottom: .7rem;
  transform: rotate(-.5deg);
}
.treaty-extract.neutral .cite { color: var(--ink-faint); }
.treaty-extract blockquote {
  font-family: var(--serif); font-size: 1.06rem; line-height: 1.55; color: var(--ink);
}
.treaty-extract .note { font-size: .84rem; color: var(--ink-faint); margin-top: .65rem; }

/* ---------- theme blocks on debate page ---------- */
.theme { padding: 2.6rem 0; }
.theme + .theme { border-top: 1px dashed var(--line-strong); }
.theme > h2 { max-width: var(--textw); }
.theme .context { max-width: var(--textw); color: var(--ink-soft); margin-bottom: 1.2rem; }
.where-stands {
  margin-top: 1.6rem; padding: 1rem 1.25rem; max-width: 46rem;
  background: var(--paper-sink); border-radius: 6px; font-size: .93rem; color: var(--ink-soft);
}
.where-stands strong { color: var(--ink); }

/* ---------- tables ---------- */
.table-scroll { overflow-x: auto; margin-top: 1.2rem; }
table { border-collapse: collapse; width: 100%; font-size: .93rem; }
th { font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-faint); text-align: left; font-weight: 700; }
th, td { padding: .6rem .8rem .6rem 0; border-bottom: 1px solid var(--line); vertical-align: top; }
td:first-child { font-weight: 600; white-space: nowrap; }

/* ---------- FAQ ---------- */
.faq-item { border-bottom: 1px solid var(--line); max-width: 48rem; }
.faq-item summary {
  cursor: pointer; list-style: none; display: flex; gap: .8rem; align-items: baseline;
  font-family: var(--serif); font-size: 1.18rem; font-weight: 600;
  padding: 1.05rem 0;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::before { content: "+"; font-family: var(--sans); color: var(--gold); font-weight: 400; font-size: 1.3rem; line-height: 1; flex-shrink: 0; }
.faq-item[open] summary::before { content: "–"; }
.faq-item .answer { padding: 0 0 1.4rem 2rem; }
.faq-item .answer p + p { margin-top: .75rem; }
.faq-item .answer .sides { margin-top: .9rem; }
.sides { display: grid; gap: .7rem; }
.side { padding: .7rem .95rem; border-radius: 6px; font-size: .94rem; }
.side.for { background: var(--pounamu-wash); }
.side.against { background: var(--madder-wash); }
.side .who { font-family: var(--serif); font-style: italic; font-weight: 500; }
.side.for .who { color: var(--pounamu); }
.side.against .who { color: var(--madder); }

/* ---------- documents ---------- */
.doc-list { list-style: none; max-width: 48rem; margin-top: 1.2rem; }
.doc-list li { display: flex; flex-wrap: wrap; gap: .25rem 1rem; align-items: baseline; padding: .9rem 0; border-bottom: 1px solid var(--line); }
.doc-list .doc-name { font-weight: 600; }
.doc-list .doc-meta { font-size: .82rem; color: var(--ink-faint); }
.doc-list .doc-desc { flex-basis: 100%; font-size: .92rem; color: var(--ink-soft); }

/* ---------- buttons & forms ---------- */
.btn {
  display: inline-block; font-family: var(--sans); font-size: .95rem; font-weight: 600;
  color: #fff; background: var(--marine); border: none; border-radius: 6px;
  padding: .65rem 1.3rem; cursor: pointer; text-decoration: none;
}
.btn:hover { background: var(--marine-deep); color: #fff; }
@media (prefers-color-scheme: dark) {
  .btn { color: #10141A; }
  .btn:hover { color: #10141A; }
}
.btn.secondary { background: transparent; color: var(--marine); border: 1.5px solid var(--marine); }
.btn.secondary:hover { background: var(--paper-sink); }

textarea, input[type="text"] {
  width: 100%; font-family: var(--sans); font-size: 1rem; color: var(--ink);
  background: var(--paper-raise); border: 1px solid var(--line-strong); border-radius: 6px;
  padding: .8rem .95rem; resize: vertical;
}
textarea::placeholder { color: var(--ink-faint); }

/* ---------- ask page ---------- */
.ask-box { max-width: 46rem; }
.ask-answer {
  margin-top: 1.6rem; padding: 1.35rem 1.5rem; border: 1px solid var(--line-strong);
  border-radius: 8px; background: var(--paper-raise); display: none;
}
.ask-answer.visible { display: block; }
.ask-answer h3 { font-size: .78rem; font-family: var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-faint); font-weight: 700; margin-bottom: .7rem; }
.ask-answer .body { white-space: pre-wrap; }
.ask-answer .body h4 { font-family: var(--serif); margin: .9rem 0 .3rem; }
.ask-status { margin-top: 1rem; font-size: .92rem; color: var(--ink-faint); font-style: italic; }
.share-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: .35rem .8rem; margin-top: 1.1rem; padding-top: .9rem; border-top: 1px dashed var(--line-strong); font-size: .9rem; }
.share-row a { font-family: var(--mono); font-size: .84rem; word-break: break-all; }
.copy-btn { font-family: var(--sans); font-size: .8rem; font-weight: 600; color: var(--ink-soft); background: var(--paper-sink); border: 1px solid var(--line-strong); border-radius: 4px; padding: .22rem .7rem; cursor: pointer; }
.copy-btn:hover { color: var(--ink); }
.suggested { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.suggested button {
  font-family: var(--sans); font-size: .84rem; color: var(--ink-soft);
  background: var(--paper-sink); border: 1px solid var(--line); border-radius: 999px;
  padding: .35rem .85rem; cursor: pointer;
}
.suggested button:hover { border-color: var(--line-strong); color: var(--ink); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 2.6rem 0 3.2rem; margin-top: 2rem; }
.site-footer .disclaimer { font-size: .88rem; color: var(--ink-soft); max-width: var(--textw); }
.site-footer .fine { font-size: .8rem; color: var(--ink-faint); margin-top: 1.1rem; }
.site-footer a { color: var(--ink-soft); }
.foot-row { display: flex; flex-direction: column; align-items: flex-start; gap: 1.1rem; margin-top: 1.1rem; }
.foot-row .fine { margin-top: 0; }
.site-footer .telemetry {
  display: inline-flex; align-items: center; gap: .55rem; flex: none;
  font-family: var(--mono); font-size: .7rem; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-faint); text-decoration: none;
}
.site-footer .telemetry img {
  width: 28px; height: 28px; border-radius: 50%; object-fit: cover;
  background: var(--paper-sink); border: 1px solid var(--line-strong);
}
.site-footer .telemetry:hover { color: var(--marine); }
.site-footer .telemetry:hover span { text-decoration: underline; text-underline-offset: 2px; }
.site-footer .telemetry:hover img { border-color: var(--gold); }

/* ---------- utilities ---------- */
.muted { color: var(--ink-soft); }
.small { font-size: .88rem; }
.mt { margin-top: 1.4rem; }
img { max-width: 100%; }
