/* Green Diplomat — Home page chart styles.
   Scoped to the interactive "Chart of the Quarter" ambition-gap LineChart
   rendered by js/home.js. Ports the design's <LineChart> look (Shell.jsx),
   premium pass: gradient area fills, smooth curves, refined tooltip. */

/* Legend swatches: line samples (solid teal / dashed gold) to match the
   design's borderTop line style rather than a filled block. */
.chart-frame .cf-legend i {
  width: 18px;
  height: 0;
  background: transparent;
  border-top: 2.5px solid currentColor;
  border-radius: 2px;
}
.chart-frame .cf-legend i.dash {
  border-top-style: dashed;
}

/* Chart mount container */
.gd-linechart {
  position: relative;
  margin: 8px 0 2px;
}
.gd-linechart svg {
  width: 100%;
  height: auto;
  display: block;
  overflow: visible;
}
.gd-linechart .gd-lc-grid {
  shape-rendering: crispEdges;
}
.gd-linechart .gd-lc-axis {
  font-family: var(--font-mono);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  fill: var(--ink-500);
}
.gd-linechart .gd-lc-unit {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  fill: var(--ink-400);
}
.gd-linechart .gd-lc-xlab {
  font-family: var(--font-mono);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  fill: var(--ink-500);
  transition: fill .15s ease;
}
.gd-linechart .gd-lc-xlab.on {
  fill: var(--ink-900);
  font-weight: 600;
}
.gd-linechart .gd-lc-cross {
  pointer-events: none;
}
.gd-linechart .gd-lc-dot {
  transition: r .14s ease, stroke-width .14s ease;
}

/* Animated line draw-in (triggered when .gd-lc-draw is added on reveal). */
.gd-linechart .gd-lc-line {
  stroke-dashoffset: var(--gd-lc-len, 0);
}
.gd-linechart.gd-lc-draw .gd-lc-line {
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1.25s cubic-bezier(.16, 1, .3, 1);
}
.gd-linechart .gd-lc-area {
  opacity: 0;
}
.gd-linechart.gd-lc-draw .gd-lc-area {
  opacity: 1;
  transition: opacity .9s ease .4s;
}

/* Tooltip — shared premium card style: navy, soft shadow, mono values */
.gd-linechart .gd-lc-tip {
  position: absolute;
  top: 4px;
  pointer-events: none;
  background: var(--navy-800);
  color: #fff;
  border: 1px solid var(--border-on-dark);
  border-radius: var(--radius-sm);
  padding: 10px 13px;
  box-shadow: 0 10px 30px -10px rgba(6, 20, 34, .55);
  min-width: 138px;
  z-index: 5;
  opacity: 0;
  visibility: hidden;
  transition: opacity .14s ease;
}
.gd-linechart .gd-lc-tip.on {
  opacity: 1;
  visibility: visible;
}
.gd-linechart .gd-lc-tip .gd-lc-tip-year {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .14em;
  color: var(--teal-300);
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-on-dark);
}
.gd-linechart .gd-lc-tip-row {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-ui);
  font-size: 12px;
  margin-top: 5px;
}
.gd-linechart .gd-lc-tip-row .sw {
  width: 14px;
  height: 0;
  border-top: 2.5px solid;
  border-radius: 2px;
  background: transparent !important;
  flex: none;
  border-top-color: currentColor;
}
.gd-linechart .gd-lc-tip-row .sw.dash {
  border-top-style: dashed;
}
.gd-linechart .gd-lc-tip-row .nm {
  flex: 1;
  white-space: nowrap;
  color: rgba(255, 255, 255, .82);
}
.gd-linechart .gd-lc-tip-row .vl {
  font-family: var(--font-mono);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: #fff;
}

/* ============================================================
   SUPPORTED BY — compact "Supported by" strip (above footer)
   Quiet editorial band: mono eyebrow label, placeholder lockup,
   one restrained line. Reuses global tokens.
   ============================================================ */
.gd-supported {
  padding: 44px 0;
  border-top: 1px solid var(--border-default);
  background: var(--paper-50);
}
.gd-supported-inner {
  display: flex;
  align-items: center;
  gap: 26px;
  flex-wrap: wrap;
}
.gd-supported-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-500);
  flex: none;
}
.gd-supported-lockup {
  height: 40px;
  width: auto;
  aspect-ratio: 360 / 96;
  display: block;
  flex: none;
}
.gd-supported-line {
  font-family: var(--font-body);
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ink-600);
  margin: 0;
  max-width: 44ch;
  flex: 1 1 300px;
}

@media (max-width: 680px) {
  .gd-supported { padding: 34px 0; }
  .gd-supported-inner { gap: 16px; }
  .gd-supported-line { flex-basis: 100%; }
}

/* prefers-reduced-motion: show everything immediately, no draw animation */
@media (prefers-reduced-motion: reduce) {
  .gd-linechart .gd-lc-line { stroke-dashoffset: 0; }
  .gd-linechart .gd-lc-area { opacity: 1; }
  .gd-linechart.gd-lc-draw .gd-lc-line,
  .gd-linechart.gd-lc-draw .gd-lc-area { transition: none; }
  .gd-linechart .gd-lc-dot { transition: none; }
}

/* ============================================================
   FROM THE RADAR — homepage wire, fed by the real tracked set
   ============================================================ */
.radar-wire { border-top: 1px solid var(--border-default); background: var(--paper-0); }
.rw-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 22px; }
.rw-head .stmt-head { margin-bottom: 0; }
.rw-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border-default); border: 1px solid var(--border-default); border-radius: 3px; overflow: hidden; }
.rw-card { display: flex; flex-direction: column; gap: 10px; background: #fff; padding: 26px 26px 22px; transition: background .25s ease; }
.rw-card:hover { background: var(--paper-0); }
.rw-card:hover .rw-inst { color: var(--teal-700); }
.rw-jur { font-family: var(--font-mono); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-500); }
.rw-inst { font-family: var(--font-display); font-size: 19px; line-height: 1.28; color: var(--ink-900); transition: color .25s ease; flex: 1; }
.rw-meta { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-ui); font-size: 12.5px; font-weight: 600; color: var(--ink-700); padding-top: 14px; border-top: 1px solid var(--border-default); }
.rw-meta i { width: 8px; height: 8px; border-radius: 50%; flex: 0 0 auto; }
.rw-meta em { font-style: normal; font-weight: 400; color: var(--ink-500); }
.rw-note { margin-top: 14px; font-size: 13px; color: var(--ink-500); }
@media (max-width: 860px) { .rw-grid { grid-template-columns: 1fr; } .rw-head { flex-direction: column; align-items: flex-start; gap: 10px; } }
