/* Executive overview prototype. Tokens follow the published Collective brand system. */
@font-face {
  font-family: 'Archivo';
  src: url('../assets/fonts/archivo-latin-variable.woff2') format('woff2');
  font-weight: 400 900;
  font-stretch: 62% 125%;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('../assets/fonts/ibm-plex-mono-latin-regular.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('../assets/fonts/ibm-plex-mono-latin-medium.woff2') format('woff2');
  font-weight: 500;
  font-display: swap;
}

:root {
  --paper: #F7F7F2;
  --ink: #181918;
  --grey: #EBEBE5;
  --red: #F44B32;
  --deep-red: #AD2B19;
  --muted: #676962;
  --line: #C8CAC1;
  --sage: #E3E4DC;
  --sage-track: #B4B8AD;
  --gutter: 44px;
  --gap: 2px;
  --sans: 'Archivo', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, monospace;
  --head-h: 76px;
  --hatch: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='6' height='6'%3E%3Cpath d='M-1 1l2-2M0 6l6-6M5 7l2-2' stroke='%23181918' stroke-width='1'/%3E%3C/svg%3E");
  --hatch-red: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='6' height='6'%3E%3Cpath d='M-1 1l2-2M0 6l6-6M5 7l2-2' stroke='%23AD2B19' stroke-width='1.2'/%3E%3C/svg%3E");
  color-scheme: light;
}
@media (max-width: 1150px) { :root { --gutter: 32px; } }
@media (max-width: 850px)  { :root { --gutter: 25px; } }
@media (max-width: 620px)  { :root { --gutter: 20px; --head-h: auto; } }
@media (max-width: 360px)  { :root { --gutter: 16px; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--sans); font-size: 15px; line-height: 1.45;
  font-variant-numeric: tabular-nums;
}
h1, h2, h3, p, dl, dd, ol, ul, figure { margin: 0; }
ol, ul { padding: 0; list-style: none; }
button, select, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 50; }
.skip:focus { left: 8px; }
.mono { font-family: var(--mono); font-size: 11px; letter-spacing: .025em; text-transform: uppercase; }
.muted { color: var(--muted); }

/* Masthead */
.masthead { position: sticky; top: 0; z-index: 20; background: var(--paper); border-bottom: 1px solid var(--ink); }
.masthead__inner {
  max-width: 1512px; margin: 0 auto; padding: 14px var(--gutter);
  min-height: var(--head-h); display: flex; align-items: center; justify-content: space-between; gap: 16px 32px; flex-wrap: wrap;
}
.masthead__brand { display: flex; align-items: center; gap: 28px; }
.logo { display: block; width: 150px; height: auto; }
.title { font-size: 26px; font-weight: 650; letter-spacing: -0.02em; line-height: 1; padding-left: 28px; border-left: 1px solid var(--line); }
.masthead__meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 22px; font-size: 14px; }
.masthead__meta > div { display: flex; align-items: center; gap: 8px; }
.masthead__meta dd { font-weight: 550; }
.compare dt { font-family: var(--mono); font-size: 11px; letter-spacing: .025em; text-transform: uppercase; color: var(--muted); }
select {
  appearance: none; border: 1px solid var(--ink); border-radius: 0; background: var(--paper);
  padding: 6px 30px 6px 10px; font-weight: 550; font-size: 14px; min-height: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23181918' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center;
}
.badge {
  display: inline-block; font-family: var(--mono); font-size: 11px; letter-spacing: .025em; text-transform: uppercase;
  border: 1px solid var(--ink); padding: 4px 8px; line-height: 1.2; font-weight: 500;
}
/* On small screens the masthead scrolls away, so a slim fixed label keeps the illustrative-data status visible. */
.badge-float { display: none; position: fixed; right: 10px; bottom: 10px; z-index: 30; background: var(--paper); }
.badge::before { content: '['; color: var(--red); margin-right: 3px; }
.badge::after { content: ']'; color: var(--red); margin-left: 3px; }

/* Page */
.page { max-width: 1512px; margin: 0 auto; padding: 28px var(--gutter) 40px; display: grid; gap: 28px; }
.row { display: grid; gap: 28px; }
.row--7-5 { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
@media (max-width: 1150px) { .row--7-5 { grid-template-columns: minmax(0, 1fr); } }

.panel { border-top: 1px solid var(--ink); padding-top: 14px; min-width: 0; scroll-margin-top: 110px; }
.panel__head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.panel__head h2 { font-size: 22px; font-weight: 650; letter-spacing: -0.02em; line-height: 1.1; }
.panel__meta { color: var(--muted); }
.panel:target, .panel.is-flash { animation: flash 1.2s ease-out 1; }
@keyframes flash { 0% { background: var(--sage); } 100% { background: transparent; } }
.hint { color: var(--muted); margin-top: 12px; }
.note { margin-top: 12px; font-size: 13px; color: var(--muted); }
.note::before { content: 'Note '; font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .025em; color: var(--ink); }

/* Info control */
.info {
  display: inline-grid; place-items: center; width: 22px; height: 22px; padding: 0; margin-left: 6px; flex: none;
  border: 1px solid var(--sage-track); background: transparent; border-radius: 0;
  font-family: var(--mono); font-size: 11px; font-weight: 500; line-height: 1; color: var(--muted); vertical-align: middle;
  position: relative;
}
.info::after { content: ''; position: absolute; inset: -11px; }
.info:hover, .info[aria-expanded='true'] { border-color: var(--ink); color: var(--ink); background: var(--grey); }

/* KPIs */
.kpi-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); border-top: 1px solid var(--ink); border-left: 1px solid var(--line); }
@media (max-width: 1199px) { .kpi-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 700px) { .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 340px) { .kpi-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 420px) { .kpi { padding: 12px 12px 14px; } .kpi__value { font-size: 27px; } .kpi__label { font-size: 13px; } .kpi__support, .kpi__delta { font-size: 12px; } }
.kpi { padding: 14px 16px 16px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.kpi__label { display: flex; align-items: center; justify-content: space-between; font-size: 14px; font-weight: 600; }
.kpi__value { font-size: clamp(30px, 2.6vw, 40px); font-weight: 650; letter-spacing: -0.035em; line-height: 1.05; margin-top: 4px; }
.kpi__value small { font-size: .55em; font-weight: 600; letter-spacing: -0.01em; margin-left: 2px; }
.kpi__support { font-size: 14px; }
.kpi__support strong { font-weight: 600; }
.kpi__extra { font-size: 13px; color: var(--muted); }
.kpi__delta { margin-top: auto; padding-top: 8px; border-top: 1px solid var(--grey); font-size: 13px; display: flex; flex-wrap: wrap; gap: 2px 8px; align-items: baseline; }
.delta { font-weight: 650; white-space: nowrap; }
.delta__vs { color: var(--muted); }
.flag { display: inline-flex; align-items: center; gap: 5px; font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .025em; }
.flag--ok::before { content: ''; width: 9px; height: 9px; border: 1.5px solid var(--ink); background: var(--ink); }
.flag--watch::before { content: ''; width: 9px; height: 9px; border: 1.5px solid var(--deep-red); background: var(--hatch-red); }
.flag--watch { color: var(--deep-red); }

.kpi__more { margin-top: 2px; }
.kpi__more summary { cursor: pointer; list-style: none; display: inline-flex; align-items: center; gap: 6px; font-family: var(--mono); font-size: 10px; letter-spacing: .025em; text-transform: uppercase; color: var(--muted); padding: 4px 0; min-height: 24px; }
.kpi__more summary::-webkit-details-marker { display: none; }
.kpi__more summary::before { content: '+'; display: inline-grid; place-items: center; width: 14px; height: 14px; border: 1px solid var(--sage-track); font-size: 10px; }
.kpi__more[open] summary::before { content: '\2212'; }
.kpi__more summary:hover { color: var(--ink); }
.kpi__more .kv { margin-top: 2px; font-size: 12px; }
.kpi__more .kv th { color: var(--muted); }
.kpi__more .kpi__extra { margin-top: 6px; font-size: 12px; }

/* Waterfall */
.waterfall { display: grid; gap: 0; }
.wf-row {
  display: grid; grid-template-columns: 190px minmax(0, 1fr) 104px 58px; align-items: center; gap: 0 12px;
  padding: 6px 0; border: 0; border-bottom: 1px solid var(--grey); background: transparent; text-align: left; width: 100%;
}
.wf-row:hover, .wf-row[aria-pressed='true'] { background: var(--grey); }
.wf-row__label { font-size: 14px; font-weight: 500; display: flex; align-items: baseline; }
.wf-row__label .op { font-family: var(--mono); font-size: 11px; color: var(--muted); text-transform: uppercase; margin-right: 6px; display: inline-block; width: 48px; flex: none; }
.wf-row--subtotal .wf-row__label, .wf-row--total .wf-row__label { font-weight: 650; }
.wf-row--subtotal { background: transparent; }
.wf-row__track { position: relative; height: 22px; }
.wf-bar { position: absolute; top: 0; bottom: 0; }
.wf-bar--total { background: var(--ink); }
.wf-bar--cost { background: var(--sage-track); }
.wf-bar--subtotal { background: var(--paper) var(--hatch); border: 1px solid var(--ink); }
.wf-bar--result { background: var(--red); }
.wf-row__value { text-align: right; font-weight: 600; font-size: 15px; white-space: nowrap; }
.wf-row__pct { text-align: right; font-size: 13px; color: var(--muted); white-space: nowrap; }
.wf-row--total .wf-row__value, .wf-row--result .wf-row__value { font-weight: 700; }
.wf-row__sub { grid-column: 1 / -1; font-size: 12px; color: var(--muted); padding-left: 40px; }
.wf-head { display: grid; grid-template-columns: 190px minmax(0, 1fr) 104px 58px; gap: 0 12px; padding-bottom: 6px; border-bottom: 1px solid var(--line); color: var(--muted); }
.wf-head span:nth-child(3), .wf-head span:nth-child(4) { text-align: right; }
@media (max-width: 620px) {
  .wf-row, .wf-head { grid-template-columns: minmax(0, 1fr) auto 48px; }
  .wf-row__label { grid-column: 1; grid-row: 1; }
  .wf-row__value { grid-column: 2; grid-row: 1; }
  .wf-row__pct { grid-column: 3; grid-row: 1; }
  .wf-row__track { grid-column: 1 / -1; grid-row: 2; height: 14px; margin-top: 4px; }
  .wf-head span:nth-child(2) { display: none; }
}

/* Legend and charts */
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 13px; margin-bottom: 10px; }
.legend__item { display: inline-flex; align-items: center; gap: 7px; }
.key { display: inline-block; width: 22px; height: 0; border-top: 2px solid var(--ink); }
.key--dash { border-top: 2px dashed var(--muted); }
.key--bar { width: 12px; height: 12px; border: 0; background: var(--sage-track); }
.key--reserve { border-top: 2px dashed var(--deep-red); }
.key--hatch { width: 14px; height: 12px; border: 1px solid var(--deep-red); background: var(--hatch-red); }
.key--inbound { width: 0; height: 0; border: 0; border-left: 6px solid transparent; border-right: 6px solid transparent; border-top: 9px solid var(--ink); }
.multiples { display: grid; gap: 18px; }
.multiple figcaption { font-size: 14px; font-weight: 600; margin-bottom: 2px; display: flex; justify-content: space-between; gap: 8px; }
.chart { position: relative; width: 100%; touch-action: pan-y; }
.chart:focus-visible { outline-offset: 4px; }
.chart svg { display: block; width: 100%; overflow: visible; }
.chart text { font-family: var(--sans); font-size: 12px; fill: var(--muted); }
.chart .axis-label { font-family: var(--mono); font-size: 10px; letter-spacing: .025em; }
.chart .grid { stroke: var(--grey); stroke-width: 1; }
.chart .baseline { stroke: var(--line); stroke-width: 1; }
.chart .cur { fill: none; stroke: var(--ink); stroke-width: 2; }
.chart .prior { fill: none; stroke: var(--muted); stroke-width: 2; stroke-dasharray: 5 4; }
.chart .dot-cur { fill: var(--ink); stroke: var(--paper); stroke-width: 2; }
.chart .dot-prior { fill: var(--paper); stroke: var(--muted); stroke-width: 2; }
.chart .label-strong { fill: var(--ink); font-weight: 650; font-size: 13px; }
.chart .crosshair { stroke: var(--ink); stroke-width: 1; }
.chart .reserve { stroke: var(--deep-red); stroke-width: 1.5; stroke-dasharray: 6 4; }
.chart .reserve-label { fill: var(--deep-red); font-size: 12px; font-weight: 600; }
.chart .low-ring { fill: var(--paper); stroke: var(--red); stroke-width: 2.5; }
.chart .bar { fill: var(--sage-track); }
.chart .bar.is-active { fill: var(--ink); }
.chart .headroom { stroke: var(--ink); stroke-width: 1; }
.chart .hit { fill: transparent; }
.chart--short { margin-top: 6px; }

.tooltip {
  position: fixed; z-index: 40; pointer-events: none; max-width: 280px;
  background: var(--ink); color: var(--paper); padding: 10px 12px; font-size: 13px; line-height: 1.4;
}
.tooltip h4 { margin: 0 0 4px; font-size: 13px; font-weight: 650; }
.tooltip table { border-collapse: collapse; width: 100%; }
.tooltip td { padding: 1px 0; vertical-align: top; }
.tooltip td + td { text-align: right; padding-left: 14px; font-weight: 600; white-space: nowrap; }
.tooltip .tt-note { margin-top: 6px; color: #D4D8CD; font-size: 12px; }
.tooltip .tt-k { color: #D4D8CD; }

/* Popover */
.popover {
  position: fixed; z-index: 45; width: min(340px, calc(100vw - 32px));
  background: var(--paper); border: 1px solid var(--ink); padding: 14px 16px 12px; font-size: 14px;
}
.popover h3 { font-size: 15px; font-weight: 650; margin-bottom: 2px; }
.popover .full { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .025em; color: var(--muted); margin-bottom: 8px; }
.popover .formula { margin-top: 8px; padding: 6px 8px; background: var(--grey); font-size: 13px; }
.popover .incl { margin-top: 8px; font-size: 13px; color: var(--muted); }
.popover .pop-actions { margin-top: 10px; display: flex; justify-content: space-between; }

/* Figures strip */
.figures { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.figure { padding: 10px 12px 10px 0; min-width: 0; }
.figure + .figure { padding-left: 12px; border-left: 1px solid var(--grey); }
.figure__label { display: flex; align-items: center; font-size: 13px; font-weight: 550; color: var(--muted); }
.figure__value { font-size: 26px; font-weight: 650; letter-spacing: -0.03em; line-height: 1.1; margin-top: 2px; }
.figure__sub { font-size: 13px; color: var(--muted); }
@media (max-width: 480px) { .figures { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .figure:nth-child(3) { grid-column: 1 / -1; border-left: 0; padding-left: 0; border-top: 1px solid var(--grey); } }

/* Customer economics */
.ce-block { padding: 0 0 18px; }
.ce-block + .ce-block { border-top: 1px solid var(--line); padding-top: 14px; }
.ce-block__head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.ce-block__head h3 { font-size: 15px; font-weight: 650; }
.allowance { margin: 34px 0 6px; position: relative; }
.allowance__bar { display: flex; height: 26px; gap: var(--gap); }
.allowance__seg { position: relative; min-width: 2px; }
.seg--cac { background: var(--sage-track); }
.seg--overhead { background: var(--grey); border: 1px solid var(--line); }
.seg--profit { background: var(--paper) var(--hatch); border: 1px solid var(--ink); }
.allowance__marker { position: absolute; top: -30px; bottom: 20px; width: 0; border-left: 2px solid var(--ink); }
.allowance__marker span { position: absolute; top: 0; left: 6px; white-space: nowrap; font-size: 13px; font-weight: 650; }
.allowance__marker.is-right span { left: auto; right: 6px; }
.allowance__axis { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); margin-top: 4px; }
.allowance__legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; margin-top: 10px; }
.allowance__legend .sw { display: inline-block; width: 12px; height: 12px; margin-right: 6px; vertical-align: -1px; }
.ce-figs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--grey); margin-top: 14px; }
.ce-figs .figure { padding-top: 8px; padding-bottom: 0; }
.ce-figs .figure__value { font-size: 22px; }
@media (max-width: 480px) { .ce-figs { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .ce-figs .figure:nth-child(3) { grid-column: 1 / -1; border-left: 0; padding-left: 0; } }
.ce-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 760px) { .ce-split { grid-template-columns: minmax(0, 1fr); } }
.mix__bar { display: flex; height: 26px; gap: var(--gap); margin: 8px 0; }
.mix__seg--new { background: var(--ink); }
.mix__seg--returning { background: var(--sage-track); }
.mix__rows { display: grid; grid-template-columns: auto 1fr auto auto; gap: 4px 14px; font-size: 13px; align-items: center; }
.mix__rows .num { text-align: right; font-weight: 600; }
.mix__rows .sw { display: inline-block; width: 10px; height: 10px; margin-right: 6px; }

details.more { margin-top: 12px; border-top: 1px solid var(--grey); }
details.more summary { cursor: pointer; padding: 8px 0; font-family: var(--mono); font-size: 11px; letter-spacing: .025em; text-transform: uppercase; list-style: none; display: flex; align-items: center; gap: 8px; }
details.more summary::-webkit-details-marker { display: none; }
details.more summary::before { content: '+'; display: inline-grid; place-items: center; width: 18px; height: 18px; border: 1px solid var(--ink); font-size: 12px; }
details.more[open] summary::before { content: '−'; }
.kv { width: 100%; border-collapse: collapse; font-size: 13px; }
.kv th, .kv td { padding: 5px 0; border-bottom: 1px solid var(--grey); text-align: left; font-weight: 400; vertical-align: top; }
.kv td { text-align: right; font-weight: 600; white-space: nowrap; padding-left: 12px; }
.kv thead th { font-family: var(--mono); font-size: 10px; text-transform: uppercase; letter-spacing: .025em; color: var(--muted); }

/* Tables */
.table-wrap { width: 100%; }
table.data { width: 100%; border-collapse: collapse; font-size: 14px; }
table.data th { text-align: left; font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: .025em; text-transform: uppercase; color: var(--muted); padding: 0 10px 8px 0; border-bottom: 1px solid var(--ink); vertical-align: bottom; }
table.data td { padding: 10px 10px 10px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
table.data .num { text-align: right; white-space: nowrap; }
table.data .strong { font-weight: 650; }
table.data tr.detail td { background: var(--grey); padding: 14px 16px; }
table.data tfoot td { border-bottom: 0; border-top: 1px solid var(--ink); font-weight: 600; font-size: 13px; }
.rowtoggle { display: inline-flex; align-items: center; gap: 8px; border: 0; background: transparent; padding: 0; font-weight: 650; text-align: left; }
.rowtoggle::before { content: '+'; display: inline-grid; place-items: center; width: 20px; height: 20px; border: 1px solid var(--ink); font-size: 13px; font-weight: 500; flex: none; }
.rowtoggle[aria-expanded='true']::before { content: '−'; }
.sub { display: block; font-size: 12px; color: var(--muted); font-weight: 400; }
.tag { display: inline-block; font-family: var(--mono); font-size: 10px; letter-spacing: .025em; text-transform: uppercase; border: 1px solid var(--line); padding: 1px 5px; margin-left: 6px; color: var(--muted); vertical-align: 1px; }
.na { color: var(--muted); font-weight: 400; }
.detail-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 24px; font-size: 13px; }
.detail-grid h4 { font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: .025em; text-transform: uppercase; color: var(--muted); margin: 0 0 3px; }
.detail-grid p + p { margin-top: 4px; }
@media (max-width: 760px) { .detail-grid { grid-template-columns: minmax(0, 1fr); } }

/* Channel table responsive */
@media (max-width: 760px) {
  .channel-table thead { display: none; }
  .channel-table tr.main { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .channel-table tr.main td { border: 0; padding: 0; }
  .channel-table tr.main td[data-label]::before { content: attr(data-label); display: block; font-family: var(--mono); font-size: 10px; text-transform: uppercase; letter-spacing: .025em; color: var(--muted); }
  .channel-table tr.main td:first-child { grid-column: 1 / -1; }
  .channel-table tr.main td.obs { grid-column: 1 / -1; }
  .channel-table tr.main td.num { text-align: left; }
  .channel-table tr.detail, .channel-table tr.detail td { display: block; }
  .channel-table tfoot tr { display: grid; grid-template-columns: 1fr auto; }
  .channel-table tfoot td { border: 0; padding: 8px 0 0; }
  .channel-table tfoot td.hide-sm { display: none; }
}

/* Stock */
.stock-table td.timeline { width: 28%; min-width: 160px; }
.stock-table td.interp { width: 24%; }
.stock-table td:first-child { white-space: nowrap; }
.tl { position: relative; height: 34px; margin-top: 2px; }
.tl__axis { position: absolute; left: 0; right: 0; bottom: 0; height: 10px; border-top: 1px solid var(--line); }
.tl__tick { position: absolute; top: 0; height: 4px; border-left: 1px solid var(--line); }
.tl__ticklabel { position: absolute; top: 3px; transform: translateX(-50%); font-size: 9.5px; color: var(--muted); font-family: var(--mono); }
.tl__cover { position: absolute; left: 0; top: 8px; height: 12px; background: var(--ink); }
.tl__gap { position: absolute; top: 8px; height: 12px; background: var(--hatch-red); border: 1px solid var(--deep-red); }
.tl__inbound { position: absolute; top: -1px; transform: translateX(-50%); width: 0; height: 0; border-left: 6px solid transparent; border-right: 6px solid transparent; border-top: 9px solid var(--ink); }
.tl__more { position: absolute; right: 0; top: 7px; font-size: 11px; font-weight: 650; background: var(--paper); padding-left: 4px; }
.stock-table tr.is-exception td:first-child { box-shadow: inset 3px 0 0 var(--red); padding-left: 10px; }
.stock-legend { margin-top: 10px; }
@media (max-width: 760px) {
  .stock-table thead { display: none; }
  .stock-table tr.main { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .stock-table tr.main td { border: 0; padding: 0; }
  .stock-table tr.main td:first-child, .stock-table tr.main td.timeline, .stock-table tr.main td.interp { grid-column: 1 / -1; }
  .stock-table tr.main td[data-label]::before { content: attr(data-label); display: block; font-family: var(--mono); font-size: 10px; text-transform: uppercase; letter-spacing: .025em; color: var(--muted); }
  .stock-table tr.main td.num { text-align: left; }
  .stock-table td.timeline, .stock-table td.interp { width: auto; }
  .stock-table tr.detail, .stock-table tr.detail td { display: block; }
  .stock-table tr.is-exception td:first-child { box-shadow: none; padding-left: 0; }
  .stock-table tr.main.is-exception { box-shadow: inset 3px 0 0 var(--red); padding-left: 10px; }
}

/* Funnel */
.funnel-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 150px; gap: 20px; }
@media (max-width: 560px) { .funnel-wrap { grid-template-columns: minmax(0, 1fr); } }
.fn-stage { padding: 7px 0; }
.fn-stage__top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 14px; }
.fn-stage__label { font-weight: 600; }
.fn-stage__count { font-weight: 650; }
.fn-stage__bar { height: 14px; background: var(--grey); margin-top: 4px; position: relative; }
.fn-stage__fill { position: absolute; left: 0; top: 0; bottom: 0; background: var(--ink); min-width: 2px; }
.fn-step { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); padding: 3px 0 3px 14px; border-left: 1px solid var(--line); margin-left: 6px; }
.fn-step strong { color: var(--ink); font-weight: 650; }
.fn-side { border-left: 1px solid var(--line); padding-left: 16px; display: grid; gap: 14px; align-content: start; }
@media (max-width: 560px) { .fn-side { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); padding-top: 10px; grid-template-columns: 1fr 1fr; } }
.fn-side .figure { padding: 0; border: 0; }
.fn-side .figure + .figure { padding-left: 0; border-left: 0; }

/* Attention (v1.1: compact strip beneath the headline metrics) */
.attention-strip { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 0 16px; background: var(--grey); padding: 12px 16px; margin-top: -12px; scroll-margin-top: 110px; }
.attention-strip h2 { padding-top: 2px; color: var(--ink); }
.attention-strip h2::before { content: '['; color: var(--red); margin-right: 3px; }
.attention-strip h2::after { content: ']'; color: var(--red); margin-left: 3px; }
.attention { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.attention li { padding: 0 16px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.attention li:first-child { padding-left: 0; }
.attention li + li { border-left: 1px solid var(--line); }
.att__title { font-size: 15px; font-weight: 650; line-height: 1.25; }
.att__body { font-size: 13px; line-height: 1.4; }
.att__foot { margin-top: auto; padding-top: 4px; display: flex; flex-wrap: wrap; gap: 2px 12px; align-items: baseline; }
.att__foot .mono { font-size: 10px; }
.att__foot a { color: var(--ink); font-size: 13px; font-weight: 600; text-underline-offset: 3px; }
.att__foot a::after { content: ' \2193'; }
@media (max-width: 1000px) {
  .attention-strip { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .attention { grid-template-columns: minmax(0, 1fr); }
  .attention li, .attention li:first-child { padding: 8px 0; }
  .attention li + li { border-left: 0; border-top: 1px solid var(--line); }
}

/* Footer */
.footer { border-top: 1px solid var(--ink); }
.footer__inner { max-width: 1512px; margin: 0 auto; padding: 18px var(--gutter) 28px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; align-items: center; }
.footer nav { display: flex; gap: 10px; align-items: center; font-size: 15px; }
.link { border: 0; background: none; padding: 4px 0; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.link--small { font-size: 13px; }

/* Drawers */
dialog.drawer {
  margin: 0 0 0 auto; height: 100dvh; max-height: 100dvh; width: min(560px, 100vw); max-width: 100vw;
  border: 0; border-left: 1px solid var(--ink); padding: 0 24px 32px; background: var(--paper); color: var(--ink); overflow-y: auto;
}
dialog.drawer::backdrop { background: rgba(24, 25, 24, .35); }
.drawer__head { position: sticky; top: 0; background: var(--paper); display: flex; justify-content: space-between; align-items: center; padding: 20px 0 14px; border-bottom: 1px solid var(--ink); z-index: 1; }
.drawer__head h2 { font-size: 24px; font-weight: 650; letter-spacing: -0.02em; }
.close { border: 1px solid var(--ink); background: var(--paper); padding: 6px 12px; font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .025em; }
.close:hover { background: var(--ink); color: var(--paper); }
.search { display: grid; gap: 6px; margin: 16px 0 6px; }
.search input { border: 1px solid var(--ink); border-radius: 0; padding: 10px 12px; background: var(--paper); font-size: 15px; }
.glossary { margin-top: 6px; }
.gl-entry { padding: 14px 0; border-bottom: 1px solid var(--line); }
.gl-entry dt { font-size: 16px; font-weight: 650; }
.gl-entry dt .full { display: block; font-family: var(--mono); font-size: 11px; letter-spacing: .025em; text-transform: uppercase; color: var(--muted); font-weight: 400; margin-top: 2px; }
.gl-entry dd { font-size: 14px; margin-top: 6px; }
.gl-entry .formula { background: var(--grey); padding: 6px 8px; font-size: 13px; }
.gl-entry .incl { color: var(--muted); font-size: 13px; }
.gl-entry.is-target { background: var(--sage); margin: 0 -10px; padding-left: 10px; padding-right: 10px; }
#notes-list section { padding: 16px 0; border-bottom: 1px solid var(--line); }
#notes-list h3 { font-size: 16px; font-weight: 650; margin-bottom: 8px; }
#notes-list li { font-size: 14px; padding: 3px 0 3px 16px; position: relative; }
#notes-list li::before { content: ''; position: absolute; left: 0; top: .7em; width: 7px; height: 1px; background: var(--ink); }

@media (max-width: 620px) {
  .masthead { position: static; }
  .masthead__inner { padding-top: 12px; padding-bottom: 12px; }
  .masthead__brand { gap: 16px; flex-wrap: wrap; }
  .title { font-size: 22px; padding-left: 16px; }
  .masthead__meta { gap: 8px 14px; font-size: 13px; }
  .badge-float { display: block; }
  .panel { scroll-margin-top: 56px; }
}

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
@media (forced-colors: active) { .wf-bar, .fn-stage__fill, .tl__cover, .allowance__seg, .mix__bar > * { forced-color-adjust: none; } }

tr.detail[hidden] { display: none !important; }

@media (max-width: 620px) {
  body { padding-bottom: 34px; }
  .badge-float { left: 0; right: 0; bottom: 0; border: 0; border-top: 1px solid var(--ink); text-align: center; padding: 8px 12px; font-size: 10px; }
}
