:root{
  --bg:#f2c319;
  --card:#101010;
  --muted:#f5d96f;
  --text:#f7f7f7;
  --accent:#f2c319;
  --danger:#d84b4b;
  --border:rgba(242,195,25,.55);
  --shadow:0 10px 24px rgba(0,0,0,.35);
  --radius:14px;
  --mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  background: linear-gradient(180deg, #f2c319 0%, #e4b10b 100%);
  color:var(--text);
  font: 14px/1.35 system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
}
a{color:inherit}
.container{max-width:1100px; margin:0 auto; padding:18px}
.topbar{
  position:sticky; top:0; z-index:10;
  backdrop-filter: blur(4px);
  background: rgba(0,0,0,.92);
  border-bottom:2px solid var(--border);
}
.topbar .container{display:flex; align-items:center; justify-content:space-between; gap:16px}
.topbar--center .container{justify-content:center}
.topbar--center .brand{text-align:center}
.topbar--center .brand__logo{margin-right:0; margin-bottom:6px}
.brand__title{font-weight:800; letter-spacing:.2px}
.brand__subtitle{color:var(--muted); font-size:12px; margin-top:2px}
.brand__logo{
  height:40px;
  width:auto;
  margin-right:10px;
  border-radius:8px;
  background:#000;
  border:1px solid rgba(255,255,255,.25);
  padding:5px 8px;
}
.nav{display:flex; gap:10px}
.nav__link{
  text-decoration:none;
  padding:8px 10px;
  border:1px solid var(--border);
  border-radius:10px;
  background: rgba(255,255,255,.04);
}
.nav__link--active{border-color: rgba(99,179,255,.45); box-shadow: 0 0 0 3px rgba(99,179,255,.12) inset}

.card{
  background: rgba(16,16,16,.96);
  border:2px solid var(--border);
  box-shadow: var(--shadow);
  border-radius: var(--radius);
  padding:16px;
  margin:16px 0;
}
.collapsible[open]{padding-bottom:16px}
.collapsible__summary{
  list-style:none;
  cursor:pointer;
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:10px;
  margin-bottom:12px;
}
.collapsible__summary::-webkit-details-marker{display:none}
.collapsible__summary::after{
  content:"+";
  color:var(--accent);
  font-weight:800;
}
.collapsible[open] .collapsible__summary::after{content:"−"}
.card__header{display:flex; align-items:baseline; justify-content:space-between; gap:10px; margin-bottom:12px}
.actions{display:flex; align-items:center; gap:8px; flex-wrap:wrap; justify-content:flex-end}
.yearQuick{display:flex; gap:6px; flex-wrap:wrap}
.yearQuick__btn{padding:6px 10px; font-size:12px}
.yearQuick__btn.active{
  background: linear-gradient(180deg, rgba(242,195,25,.98), rgba(222,174,0,.92));
  color:#101010;
}
h2{margin:0; font-size:16px}
.muted{color:var(--muted)}
.liveStatus{
  display:inline-flex;
  align-items:center;
  line-height:1;
}
.liveStatus__dot{
  width:8px;
  height:8px;
  border-radius:999px;
  background:#9aa0a6;
  box-shadow:0 0 0 1px rgba(255,255,255,.18);
}
.liveStatus--connected .liveStatus__dot{
  background:#2bd46c;
  box-shadow:0 0 0 1px rgba(43,212,108,.4), 0 0 8px rgba(43,212,108,.65);
}
.liveStatus--disconnected .liveStatus__dot{
  background:#ff7b63;
  box-shadow:0 0 0 1px rgba(255,123,99,.4), 0 0 8px rgba(255,123,99,.6);
}
.hint{color:var(--muted); margin-top:10px; font-size:12px}
code{font-family:var(--mono); font-size:12px}

.filters{
  display:grid;
  grid-template-columns: repeat(5, minmax(0,1fr));
  gap:12px;
}
.grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap:12px;
}
.field{display:flex; flex-direction:column; gap:6px}
.field--wide{grid-column: span 2}
.field span{color:var(--muted); font-size:12px}
input, select{
  appearance:none;
  background: rgba(255,255,255,.07);
  border:1px solid var(--border);
  color:var(--text);
  padding:10px 10px;
  border-radius:12px;
  outline:none;
}
select option{
  color:#000;
  background:#f2c319;
}
input:focus, select:focus{border-color: rgba(242,195,25,.95); box-shadow: 0 0 0 3px rgba(242,195,25,.2)}

.btn{
  cursor:pointer;
  background: linear-gradient(180deg, rgba(242,195,25,.98), rgba(222,174,0,.92));
  border:0;
  color:#101010;
  font-weight:800;
  padding:10px 12px;
  border-radius:12px;
}
.btn:active{transform: translateY(1px)}
.btn--ghost{
  background: rgba(255,255,255,.06);
  color: var(--text);
  border:1px solid var(--border);
}
.btn--danger{
  background: linear-gradient(180deg, rgba(255,90,122,.95), rgba(255,90,122,.75));
  color:#1b0910;
}
.btn--tiny{padding:4px 8px; font-size:11px}

.tableWrap{overflow:auto; border-radius:12px; border:1px solid var(--border); background:#0f0f0f}
.table{width:100%; border-collapse:separate; border-spacing:0; min-width:980px; table-layout:fixed}
.table th, .table td{
  padding:10px 10px;
  border-bottom:1px solid var(--border);
  vertical-align:top;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.table th{
  position:sticky; top:0;
  background: #000;
  text-align:left;
  font-size:12px;
  color:#f2c319;
  text-transform:uppercase;
  letter-spacing:.06em;
}
.table tr:hover td{background: rgba(242,195,25,.12)}
.table th:nth-child(1), .table td:nth-child(1){width:88px}
.table th:nth-child(2), .table td:nth-child(2){width:88px}
.table th:nth-child(3), .table td:nth-child(3){width:170px}
.table th:nth-child(4), .table td:nth-child(4){width:120px}
.table th:nth-child(5), .table td:nth-child(5){width:130px}
.table th:nth-child(6), .table td:nth-child(6){width:64px}
.table th:nth-child(7), .table td:nth-child(7){width:160px}
.table th:nth-child(8), .table td:nth-child(8){width:110px}
.table th:nth-child(9), .table td:nth-child(9){width:110px}
.table th:nth-child(10), .table td:nth-child(10){width:90px}
.table th:nth-child(11), .table td:nth-child(11){width:74px}
.pill{
  display:inline-flex; align-items:center;
  border:1px solid var(--border);
  background: rgba(242,195,25,.09);
  border-radius:999px;
  padding:3px 8px;
  font-size:12px;
}
.pillBtn{
  cursor:pointer;
  color:inherit;
}
.time{font-family:var(--mono); font-weight:800}
.log{
  background: rgba(0,0,0,.35);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px;
  color: var(--text);
  overflow:auto;
  max-height: 240px;
  font-family: var(--mono);
  font-size: 12px;
}

@media (max-width: 940px){
  .filters{grid-template-columns: repeat(2, minmax(0,1fr))}
  .grid{grid-template-columns: repeat(2, minmax(0,1fr))}
  .field--wide{grid-column: auto}
  .table{min-width:760px}
}

@media (max-width: 680px){
  .topbar .container{flex-direction:column; align-items:flex-start}
  .topbar--center .container{align-items:center}
  .container{padding:12px}
  .card{padding:12px; margin:12px 0}
  .filters, .grid{grid-template-columns: 1fr}
  .field .btn{width:100%}
  .actions{width:100%}
  .table{min-width:620px}
  .table th, .table td{padding:8px 7px; font-size:12px}
}
