:root { --bg:#11151c; --card:#1b2230; --text:#eef2f8; --muted:#aeb9c8; --line:#2d3748; }
* { box-sizing: border-box; }
body { margin:0; font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif; background:var(--bg); color:var(--text); }
main { max-width: 1180px; margin: 0 auto; padding: 22px; }
.hero { display:flex; justify-content:space-between; align-items:center; gap:16px; padding:24px; border-radius:18px; margin-bottom:18px; background:var(--card); border:1px solid var(--line); }
h1 { margin:0 0 6px; font-size: clamp(1.7rem, 4vw, 3rem); }
h2 { margin:0 0 12px; } h3 { margin:20px 0 8px; color:#dbe6f5; }
p { color:var(--muted); line-height:1.45; }
.card { background:var(--card); border:1px solid var(--line); padding:18px; border-radius:16px; margin:16px 0; box-shadow: 0 10px 30px rgba(0,0,0,.14); }
.headline { font-size:1.25rem; color:var(--text); }
.badge { font-size:1.5rem; font-weight:800; padding:12px 18px; border-radius:999px; }
.pill { display:inline-block; font-weight:800; padding:4px 8px; border-radius:999px; font-size:.8rem; }
.green { background:#123b2a; color:#aaf2ca; }
.yellow { background:#453913; color:#ffe08a; }
.red { background:#4a1717; color:#ffabab; }
.unknown { background:#333; color:#ddd; }
.error { border-color:#884; }
.table-wrap { overflow-x:auto; }
table { width:100%; border-collapse:collapse; min-width:820px; }
th, td { border-bottom:1px solid var(--line); padding:10px; text-align:left; vertical-align:top; }
th { color:#d7e2f0; font-size:.9rem; }
td { color:#edf2f8; }
.raw, .taf { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size:.9rem; color:#cbd6e6; }
.small { font-size:.85rem; color:var(--muted); }
.taf { padding:12px; border:1px solid var(--line); border-radius:12px; margin:10px 0; background:#151b26; line-height:1.5; }
@media (max-width:680px) { .hero { align-items:flex-start; flex-direction:column; } main { padding:12px; } }
.controls label { display:block; margin-bottom:8px; color:var(--text); }
.control-row { display:flex; gap:10px; align-items:center; flex-wrap:wrap; }
select, button { background:#151b26; color:var(--text); border:1px solid var(--line); border-radius:10px; padding:10px 12px; font:inherit; }
select { min-width: min(100%, 420px); }
button { cursor:pointer; font-weight:700; }
button:hover, select:hover { border-color:#52627a; }


/* Mobile-friendly table cards */
.raw, .taf { overflow-wrap: anywhere; word-break: break-word; white-space: normal; }

@media (max-width: 760px) {
  .card { padding: 14px; border-radius: 14px; margin: 12px 0; }
  .table-wrap { overflow-x: visible; }
  table { min-width: 0; width: 100%; border-collapse: separate; border-spacing: 0 10px; }
  thead { display: none; }
  tbody, tr, td { display: block; width: 100%; }
  tr { background: #151b26; border: 1px solid var(--line); border-radius: 14px; padding: 8px 10px; margin-bottom: 10px; }
  td { border-bottom: 1px solid rgba(255,255,255,.06); padding: 8px 0; display: grid; grid-template-columns: 42% 58%; gap: 8px; align-items: start; }
  td:last-child { border-bottom: 0; }
  td::before { content: attr(data-label); color: var(--muted); font-size: .78rem; font-weight: 800; text-transform: uppercase; letter-spacing: .02em; }
  td.raw { display: block; }
  td.raw::before { display: block; margin-bottom: 6px; }
  .pill { font-size: .75rem; }
  .badge { font-size: 1.15rem; padding: 9px 14px; }
  h2 { font-size: 1.2rem; }
  h3 { position: sticky; top: 0; z-index: 2; background: var(--card); padding: 8px 0; border-bottom: 1px solid var(--line); }
}

@media (max-width: 420px) {
  td { grid-template-columns: 46% 54%; font-size: .95rem; }
  .small { font-size: .78rem; }
}
