---import ContourField from'./ContourField.astro';
interface Stat {
label:string;
value:string|number;
/** Paint the value in the banner's accent — one per banner, the number * worth reading first. */ accent?:boolean;
}
interface Props {
/** Mono lockup before the rule, e.g. `03 ^: ACTIVE DIRECTORY`. */ n:string;
label:string;
title:string;
blurb?:string;
stats?:Stat[];
accent?:'iris'|'foam'|'love'|'gold'|'rose'|'pine';
}
const { n, label, title, blurb, stats = [], accent ='foam' } = Astro.props;
---<headerclass="banner plate bleed signal-hero"style={`--acc: var(--${accent});`}>
<!-- The home hero's contour field, in the plate's night values. The
title block and the ledger are each marked `data-contour-clear`,
so the lines run round them and through the open middle. --> <ContourField />
<spanclass="banner__scrim"aria-hidden="true"></span>
<spanclass="grain grain--local"aria-hidden="true"></span>
<!-- CRT film over the contour field — the body row is already z-index 2,
so the type stays above the scanlines. --> <spanclass="scanlines"aria-hidden="true"></span>
<divclass="wrap banner__body">
<divdata-contour-clear>
<pclass="eyebrow"style={`--acc: var(--${accent});`}>
<spanclass="eyebrow__n">{n}</span>
<spanclass="eyebrow__mark">^:</span>
<span>{label}</span>
<spanclass="eyebrow__rule"aria-hidden="true"></span>
</p>
<h1class="banner__title"data-unscramble={title}>{title}</h1>
{blurb && <pclass="banner__blurb">{blurb}</p>}
</div>
{stats.length >0&& (
<dlclass="banner__ledger"data-contour-clear>
{stats.map((s) => (
<divclass={`banner__row${s.accent ?' banner__row--acc':''}`}>
<dt>{s.label}</dt>
<dd><b>{s.value}</b></dd>
</div>
))}
</dl>
)}
</div>
</header>
<style>
/* ---- Cyberdeck chrome for the banner ----------------------------------- Hairline frame + CRT film over the dark plate. The plate pins the night palette (`.plate`), so `--rule`/`--rule-hi` below resolve to the night hairlines in both modes — the frame belongs to the plate, not the page. */ .banner { border-top:1px solid var(--rule); }
/* Kept faint: the contour field and the grain already texture the plate, and the title has to win every layer stack it sits in. */ .banner > .scanlines { opacity:0.45; }
/* The ledger is terminal furniture — DM Mono, same as the segbar. */ .banner__ledger {
font-family:var(--font-term);
}
</style>