/* Kallikantzaros — hand-authored identity.
   Dark graphite control room: Barlow labels, Martian Mono for ids/logs,
   signal orange reserved for status/danger. Borders over shadows,
   squared edges, dense pipeline tables, LED status dots. */

@font-face {
  font-family: "Barlow";
  src: url("/fonts/barlow-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("/fonts/barlow-latin-500-normal.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("/fonts/barlow-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Barlow";
  src: url("/fonts/barlow-latin-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Martian Mono";
  src: url("/fonts/martian-mono-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --graphite: #17191C;
  --panel: #1D2024;
  --panel-2: #22262B;
  --line: #2C3138;
  --text: #D5D8DC;
  --muted: #8A919B;
  --signal: #FF6B1A;   /* status/danger only */
  --led-ok: #3FB96B;
  --led-idle: #5A626C;
  --radius: 1px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--graphite);
  color: var(--text);
  font-family: "Barlow", system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.45;
}

.mono, code, td.id, td.num, .stats .num {
  font-family: "Martian Mono", ui-monospace, monospace;
  font-size: 12.5px;
}

/* top rule */
header.top {
  display: flex;
  align-items: baseline;
  gap: 18px;
  padding: 12px 22px;
  border-bottom: 2px solid var(--line);
  background: var(--panel);
}
header.top .brand {
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 1.5px;
}
header.top .brand small {
  color: var(--muted);
  font-weight: 500;
  font-size: 12px;
  letter-spacing: 0.5px;
  margin-left: 8px;
}
header.top nav { display: flex; gap: 16px; font-size: 13.5px; color: var(--muted); }
header.top nav .active { color: var(--text); border-bottom: 2px solid var(--signal); padding-bottom: 2px; }
header.top .agent { margin-left: auto; color: var(--muted); font-size: 11px; }

.banner {
  border-bottom: 1px solid var(--signal);
  background: #241a12;
  color: var(--signal);
  padding: 8px 22px;
  font-size: 12.5px;
}

main { max-width: 1080px; margin: 0 auto; padding: 24px 22px 60px; }

h1 { font-weight: 600; font-size: 26px; letter-spacing: 0.3px; margin: 4px 0 4px; }
h2 {
  font-weight: 600; font-size: 15px; letter-spacing: 1px; text-transform: uppercase;
  color: var(--muted); margin: 30px 0 8px;
  border-bottom: 1px solid var(--line); padding-bottom: 4px;
}
p.lede { color: var(--muted); max-width: 74ch; margin: 4px 0 18px; }
p.lede .mono { color: var(--text); }

/* stat tiles */
.stats { display: flex; gap: 0; border: 1px solid var(--line); border-radius: var(--radius); }
.stat {
  flex: 1;
  padding: 10px 16px;
  border-right: 1px solid var(--line);
  background: var(--panel);
  display: flex; flex-direction: column; gap: 2px;
}
.stat:last-child { border-right: none; }
.stat .num { font-size: 19px; color: var(--text); }
.stat .lbl { font-size: 11.5px; letter-spacing: 0.8px; text-transform: uppercase; color: var(--muted); }

/* dense pipeline tables */
table.pipe {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}
table.pipe th {
  text-align: left;
  font-size: 11px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
  padding: 7px 12px;
  border-bottom: 1px solid var(--line);
  background: var(--panel-2);
}
table.pipe td {
  padding: 6px 12px;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
}
table.pipe tr:last-child td { border-bottom: none; }
table.pipe tr:hover td { background: var(--panel-2); }
td.id { color: var(--text); }
td.num { text-align: left; color: var(--muted); }

/* LED status dots — square, glowing */
.led {
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 0;
  margin-right: 6px;
  vertical-align: baseline;
  background: var(--led-idle);
}
.led.passed { background: var(--led-ok); box-shadow: 0 0 5px rgba(63, 185, 107, 0.7); }
.led.failed { background: var(--signal); box-shadow: 0 0 5px rgba(255, 107, 26, 0.7); }
.led.running { background: var(--signal); animation: pulse 1.2s infinite; }
@keyframes pulse { 50% { opacity: 0.35; } }

.changelog { list-style: none; margin: 0; padding: 0; color: var(--muted); font-size: 13.5px; }
.changelog li { padding: 5px 0; border-bottom: 1px solid var(--line); }
.changelog li:last-child { border-bottom: none; }
.changelog .mono { color: var(--text); }

footer.foot {
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  padding: 12px 22px;
}

/* --- polish & micro-motion (hand-tuned, no framework) --- */
:root { color-scheme: dark; }
::selection { background: #ff6b1a; color: #17191c; }
a { transition: color .15s ease; }
button { transition: background-color .15s ease, border-color .15s ease, transform .06s ease, box-shadow .15s ease; }
button:hover:not(:disabled) { box-shadow: 0 1px 0 rgba(0,0,0,.5); }
button:active:not(:disabled) { transform: translateY(1px); box-shadow: none; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid #ff6b1a; outline-offset: 2px;
}
input, textarea, select { transition: border-color .15s ease, background-color .15s ease; }
input:hover, textarea:hover, select:hover { border-color: #3a4048; }
td, th, .stat { transition: background-color .12s ease; }
header.top nav a { position: relative; }
header.top nav a::after {
  content: ""; position: absolute; left: 0; bottom: -4px; height: 2px; width: 100%;
  background: #ff6b1a; transform: scaleX(0); transform-origin: left; transition: transform .18s ease;
}
header.top nav a:hover:not(.active)::after { transform: scaleX(1); }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
