/* BetMich V2 — Layout & Komponenten. Alle Farben via Tokens (tokens.css). */

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 6px; border: 2px solid var(--bg); }

/* ─── Layout ─── */
.layout { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-w); flex-shrink: 0;
  background: var(--surface); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh;
}
.brand { display: flex; align-items: center; gap: 10px; padding: 20px 20px 16px; }
.brand-dot { width: 12px; height: 12px; border-radius: 4px;
  background: linear-gradient(135deg, var(--accent), #8b5cf6); box-shadow: 0 0 12px var(--accent-soft); }
.brand-name { font-weight: 800; font-size: 17px; letter-spacing: -.02em; }
.brand-name small { font-weight: 600; color: var(--accent); font-size: 11px; vertical-align: super; }

.nav { display: flex; flex-direction: column; gap: 2px; padding: 8px 12px; flex: 1; }
.nav-item {
  display: flex; align-items: center; gap: 11px; padding: 9px 12px;
  border-radius: var(--radius-sm); color: var(--text-2); font-weight: 500;
  transition: background .12s, color .12s;
}
.nav-item:hover { background: var(--surface-2); color: var(--text); }
.nav-item.active { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.nav-item .ic { display: inline-flex; width: 18px; height: 18px; }
.nav-sep { height: 1px; background: var(--border-soft); margin: 8px 12px; }
.sidebar-foot { padding: 14px 20px; font-size: 12px; color: var(--text-muted);
  border-top: 1px solid var(--border-soft); display: flex; align-items: center; gap: 8px; }
.dot-online { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 8px var(--ok); }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar {
  height: 60px; flex-shrink: 0; display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px; border-bottom: 1px solid var(--border); background: var(--surface);
  position: sticky; top: 0; z-index: 20;
}
.topbar-title { font-weight: 700; font-size: 16px; letter-spacing: -.01em; }
.topbar-actions { display: flex; align-items: center; gap: 12px; }
.user { font-size: 13px; color: var(--text-2); font-weight: 500; }
.content { padding: 24px; max-width: 1340px; width: 100%; }

/* ─── Buttons ─── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 38px; padding: 0 15px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text); font-family: inherit; font-size: 13.5px;
  font-weight: 600; cursor: pointer; transition: background .12s, border-color .12s, transform .04s;
}
.btn:hover { background: var(--surface-3); border-color: var(--border-strong); }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-ghost:hover { background: var(--surface-2); }
.btn-ok { background: var(--ok-bg); border-color: var(--ok-bd); color: var(--ok); }
.btn-warn { background: var(--warn-bg); border-color: var(--warn-bd); color: var(--warn); }
.btn-danger { background: var(--danger-bg); border-color: var(--danger-bd); color: var(--danger); }
.btn-sm { height: 32px; padding: 0 11px; font-size: 12.5px; }
.icon-btn { width: 38px; padding: 0; }

/* ─── Karten ─── */
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); padding: 18px 20px;
}
.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.card-head h2, .card-head h3 { margin: 0; font-size: 15px; font-weight: 700; }
.section-title { font-size: 13px; font-weight: 700; color: var(--text-2); text-transform: uppercase;
  letter-spacing: .04em; margin: 28px 0 12px; }

/* ─── KPI-Grid ─── */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; }
.kpi {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px 18px; box-shadow: var(--shadow-sm); transition: border-color .12s;
}
.kpi:hover { border-color: var(--border-strong); }
.kpi-label { font-size: 12px; color: var(--text-muted); font-weight: 600; letter-spacing: .01em; }
.kpi-value { font-size: 23px; font-weight: 800; margin-top: 7px; letter-spacing: -.02em;
  font-variant-numeric: tabular-nums; }
.kpi-value.pos { color: var(--money-pos); }
.kpi-value.accent { color: var(--accent); }
.kpi-value.warn { color: var(--warn); }
.kpi-sub { font-size: 12px; color: var(--text-muted); margin-top: 3px; }

/* ─── Badges ─── */
.badge {
  display: inline-flex; align-items: center; gap: 5px; height: 23px; padding: 0 9px;
  border-radius: 999px; font-size: 12px; font-weight: 600; border: 1px solid transparent;
  white-space: nowrap;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-ok      { color: var(--ok);      background: var(--ok-bg);      border-color: var(--ok-bd); }
.badge-warn    { color: var(--warn);    background: var(--warn-bg);    border-color: var(--warn-bd); }
.badge-info    { color: var(--info);    background: var(--info-bg);    border-color: var(--info-bd); }
.badge-danger  { color: var(--danger);  background: var(--danger-bg);  border-color: var(--danger-bd); }
.badge-muted   { color: var(--neutral); background: var(--neutral-bg); border-color: var(--neutral-bd); }
.badge.sm { height: 19px; font-size: 11px; padding: 0 7px; }

/* ─── Tabellen ─── */
.table-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm); }
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
thead th {
  text-align: left; padding: 11px 16px; font-size: 11.5px; font-weight: 700; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: .03em; background: var(--bg-sunken);
  border-bottom: 1px solid var(--border); white-space: nowrap;
}
tbody td { padding: 12px 16px; border-bottom: 1px solid var(--border-soft); }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: var(--surface-2); }
.num { text-align: right; font-variant-numeric: tabular-nums; font-family: var(--mono); }
.money-pos { color: var(--money-pos); font-weight: 600; }
.money-neg { color: var(--money-neg); font-weight: 600; }
.muted { color: var(--text-muted); }
.strong { font-weight: 700; }

/* ─── Flash ─── */
.flash { padding: 11px 16px; border-radius: var(--radius-sm); margin-bottom: 14px; font-weight: 500;
  border: 1px solid var(--border); }
.flash-error { color: var(--danger); background: var(--danger-bg); border-color: var(--danger-bd); }
.flash-ok    { color: var(--ok);     background: var(--ok-bg);     border-color: var(--ok-bd); }

/* ─── Leerer Zustand ─── */
.empty { text-align: center; padding: 48px 20px; color: var(--text-muted); }
.empty-big { font-size: 15px; font-weight: 600; color: var(--text-2); margin-bottom: 4px; }

/* ─── Login ─── */
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-card { width: 100%; max-width: 380px; }
.login-card .brand { justify-content: center; padding: 0 0 20px; }
.form label { display: block; font-size: 13px; font-weight: 600; color: var(--text-2); margin-bottom: 14px; }
.form input, .form select, .form textarea {
  width: 100%; margin-top: 6px; height: 40px; padding: 0 12px; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: var(--surface-2); color: var(--text);
  font-family: inherit; font-size: 14px;
}
.form input:focus, .form select:focus, .form textarea:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--ring); }

/* ─── Bars (Mini-Charts ohne Lib) ─── */
.barlist { display: flex; flex-direction: column; gap: 10px; }
.barrow { display: grid; grid-template-columns: 130px 1fr 90px; align-items: center; gap: 12px; }
.barrow .lbl { font-weight: 600; font-size: 13px; }
.bartrack { height: 8px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.barfill { height: 100%; border-radius: 999px; background: var(--accent); }

#menuToggle { display: none; }
@media (max-width: 860px) {
  .sidebar { position: fixed; left: 0; top: 0; z-index: 50; transform: translateX(-100%); transition: transform .2s; box-shadow: var(--shadow-lg); }
  .sidebar.open { transform: none; }
  #menuToggle { display: inline-flex; }
  .content { padding: 16px; }
  .barrow { grid-template-columns: 100px 1fr 80px; }
}

/* ═══════════════ V2 Komponenten (Phase 3–10) ═══════════════ */

/* ── Filter / Toolbar ── */
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 16px; }
.toolbar .spacer { flex: 1; }
.chips { display: flex; flex-wrap: wrap; gap: 7px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 13px;
  border-radius: 999px; border: 1px solid var(--border); background: var(--surface);
  color: var(--text-2); font-size: 13px; font-weight: 600; cursor: pointer;
}
.chip:hover { border-color: var(--border-strong); color: var(--text); }
.chip.active { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.search { position: relative; }
.search input { height: 38px; padding: 0 12px; min-width: 220px; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: var(--surface); color: var(--text); font-size: 14px; }
.search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--ring); }
select.filter { height: 38px; padding: 0 10px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface); color: var(--text); font-size: 13.5px; font-weight: 500; }

/* ── Account-Liste (Details/Summary, kein JS) ── */
.acc-list { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm); }
.acc-head, .acc-row {
  display: grid; align-items: center; gap: 12px; padding: 11px 18px;
}
.acc-head.admin, .acc-row.admin { grid-template-columns: 1.3fr 1.1fr .85fr .85fr .75fr .9fr 1.1fr .9fr 24px; }
.acc-head.work,  .acc-row.work  { grid-template-columns: 1.5fr 1.4fr 1fr 1.3fr 1.1fr 24px; }
.col-hint { display: inline-flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.acc-head { background: var(--bg-sunken); border-bottom: 1px solid var(--border);
  font-size: 11.5px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: .03em; }
.acc { border-bottom: 1px solid var(--border-soft); }
.acc:last-child { border-bottom: none; }
.acc-row { cursor: pointer; list-style: none; font-size: 13.5px; transition: background .1s; }
.acc-row::-webkit-details-marker { display: none; }
.acc-row:hover { background: var(--surface-2); }
.acc[open] > .acc-row { background: var(--surface-2); }
.acc-caret { color: var(--text-muted); transition: transform .15s; text-align: center; }
.acc[open] .acc-caret { transform: rotate(180deg); }
.num { text-align: right; font-variant-numeric: tabular-nums; font-family: var(--mono); }
.acc-detail { padding: 16px 18px 20px; background: var(--bg-sunken); border-top: 1px solid var(--border-soft); }

/* ── Aktionen ── */
.action-grid { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-start; }
.mini { position: relative; }
.mini > summary { list-style: none; cursor: pointer; }
.mini > summary::-webkit-details-marker { display: none; }
.mini-form { margin-top: 10px; padding: 14px; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-sm); min-width: 240px; box-shadow: var(--shadow); }
.mini-form label { display: block; font-size: 12.5px; font-weight: 600; color: var(--text-2); margin-bottom: 10px; }
.mini-form input, .mini-form select, .mini-form textarea { width: 100%; margin-top: 5px; height: 36px;
  padding: 0 10px; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--surface-2);
  color: var(--text); font-family: inherit; font-size: 13.5px; }
.mini-form textarea { height: auto; padding: 8px 10px; }

.acc-admin { margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--border); }
.inline-form { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 12px; }
.admin-forms { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 8px; }
.form-line { display: flex; gap: 6px; }
.form-line input, .form-line select { flex: 1; min-width: 0; height: 34px; padding: 0 9px;
  border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--surface);
  color: var(--text); font-size: 13px; }
.histbox { margin-top: 14px; display: flex; flex-direction: column; gap: 5px; }
.histrow { font-size: 13px; font-variant-numeric: tabular-nums; }

/* ── Charts ── */
.chart-grid { display: grid; grid-template-columns: 320px 1fr; gap: 16px; }
.donut { display: flex; align-items: center; gap: 18px; }
.donut-ring { width: 130px; height: 130px; border-radius: 50%; flex-shrink: 0; position: relative; }
.donut-ring::after { content: ""; position: absolute; inset: 22px; border-radius: 50%; background: var(--surface); }
.legend { display: flex; flex-direction: column; gap: 7px; font-size: 13px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 7px; }

/* ── Lead-Karten ── */
.lead-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.lead-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px; box-shadow: var(--shadow-sm); transition: border-color .12s, transform .08s; display: block; }
.lead-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.lead-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.lead-card-name { font-size: 16px; font-weight: 700; letter-spacing: -.01em; }
.lead-card-sub { font-size: 12.5px; color: var(--text-muted); margin-top: 2px; }
.lead-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; }
.lead-stat { display: flex; flex-direction: column; }
.lead-stat .l { font-size: 11px; color: var(--text-muted); font-weight: 600; }
.lead-stat .v { font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; margin-top: 1px; }
.progress { height: 6px; border-radius: 999px; background: var(--surface-3); overflow: hidden; margin-top: 4px; }
.progress > span { display: block; height: 100%; background: var(--accent); border-radius: 999px; }

/* ── Tabs ── */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin: 4px 0 20px; flex-wrap: wrap; }
.tab { padding: 10px 15px; font-size: 13.5px; font-weight: 600; color: var(--text-2); cursor: pointer;
  border-bottom: 2px solid transparent; background: none; border-top: none; border-left: none; border-right: none; }
.tab:hover { color: var(--text); }
.tab.active { color: var(--accent); border-bottom-color: var(--accent); }
.tabpane { display: none; }
.tabpane.active { display: block; }

/* ── Modal ── */
.modal { position: fixed; inset: 0; background: rgba(3,6,12,.6); display: none; align-items: flex-start;
  justify-content: center; padding: 60px 20px; z-index: 100; backdrop-filter: blur(2px); }
.modal.open { display: flex; }
.modal-box { width: 100%; max-width: 520px; max-height: 85vh; overflow: auto; }
.modal-box .form label { margin-bottom: 12px; }

/* ── Detailseiten ── */
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.back-link { color: var(--text-muted); font-size: 13px; font-weight: 600; }
.back-link:hover { color: var(--text); }
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 8px 14px; font-size: 13.5px; }
.kv dt { color: var(--text-muted); font-weight: 600; }
.kv dd { margin: 0; font-weight: 500; }
.row-actions { display: flex; gap: 8px; align-items: center; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.list-rows { display: flex; flex-direction: column; }
.list-rows .lr { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 0; border-bottom: 1px solid var(--border-soft); font-size: 13.5px; }
.list-rows .lr:last-child { border-bottom: none; }

@media (max-width: 980px) {
  .chart-grid, .grid-2 { grid-template-columns: 1fr; }
  /* sichtbar: Lead, Buchmacher, Guthaben, Hinweis, Status, caret — Einzahlung/CPA/Mitarbeiter aus */
  .acc-head.admin, .acc-row.admin { grid-template-columns: 1.2fr 1fr 1fr 1fr 1fr 24px; }
  .acc-head.admin > :nth-child(3), .acc-row.admin > :nth-child(3),
  .acc-head.admin > :nth-child(5), .acc-row.admin > :nth-child(5),
  .acc-head.admin > :nth-child(6), .acc-row.admin > :nth-child(6) { display: none; }
}

/* ── Notification-Badges (Zähler-Blasen in der Sidebar) ── */
.nav-label { flex: 1; }   /* schiebt das Badge nach rechts, ohne den Text zu verschieben */
.nav-badge {
  flex-shrink: 0; min-width: 20px; height: 20px; padding: 0 6px;
  display: inline-flex; align-items: center; justify-content: center;
  background: #ef4444; color: #fff; font-size: 11px; font-weight: 800;
  border-radius: 999px; line-height: 1; box-shadow: 0 0 0 2px var(--surface);
  font-variant-numeric: tabular-nums;
}
.nav-badge.tone-red    { background: #ef4444; }
.nav-badge.tone-orange { background: #f59e0b; }
.nav-badge.tone-blue   { background: #3b82f6; }
.nav-badge.tone-grey   { background: var(--neutral); }
.nav-item.active .nav-badge { box-shadow: 0 0 0 2px var(--accent-soft); }
.chip-count {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 18px; height: 18px; padding: 0 5px; margin-left: 2px;
  border-radius: 999px; font-size: 11px; font-weight: 800; line-height: 1;
  background: var(--surface-3); color: var(--text-2); font-variant-numeric: tabular-nums;
}
.chip-count.red { background: #ef4444; color: #fff; }
.chip.active .chip-count { background: rgba(255,255,255,.25); color: #fff; }

/* ═══════════════ Dashboard-Datenbalken (hochwertig, keine Skeleton-Optik) ═══════════════ */
.hbar-list { display: flex; flex-direction: column; gap: 16px; }
.hbar-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 6px; }
.hbar-label { font-size: 13.5px; font-weight: 600; }
.hbar-sub { color: var(--text-muted); font-weight: 500; font-size: 12px; }
.hbar-val { font-size: 13.5px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.hbar-pct { color: var(--text-muted); font-weight: 600; font-size: 12px; }
.hbar-track { height: 10px; border-radius: 999px; background: var(--surface-3);
  overflow: hidden; box-shadow: inset 0 1px 2px rgba(0,0,0,.18); }
.hbar-fill { display: block; height: 100%; border-radius: 999px; min-width: 0;
  background-image: linear-gradient(180deg, rgba(255,255,255,.22), rgba(255,255,255,0) 60%);
  transition: width .55s cubic-bezier(.22,.61,.36,1); }

/* Segmentierter Status-Balken */
.segbar { display: flex; gap: 2px; height: 16px; border-radius: 999px; overflow: hidden; background: var(--surface-3); }
.segbar-seg { height: 100%; min-width: 5px; }
.seglegend { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 14px; font-size: 13px; }
.seglegend-item { display: inline-flex; align-items: center; }
.dot { width: 10px; height: 10px; border-radius: 3px; margin-right: 7px; display: inline-block; }

/* Statusfarben (für hbar-fill, segbar-seg und dot) */
.tone-accent { background-color: var(--accent); }
.tone-ok     { background-color: var(--ok); }
.tone-warn   { background-color: var(--warn); }
.tone-info   { background-color: var(--info); }
.tone-danger { background-color: var(--danger); }
.tone-muted  { background-color: var(--neutral); }

/* ── To-do-Badge-Reihen (Karten + Account-Zeilen, konsistente Platzierung) ── */
.todo-row { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 6px; }
.acc-badges { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }

/* ── Dashboard To-do-Liste (konkrete, klickbare Arbeitsorte) ── */
.todo-list { display: flex; flex-direction: column; }
.todo-item { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: var(--radius-sm);
  transition: background .1s; }
.todo-item:hover { background: var(--surface-2); }
.todo-item + .todo-item { border-top: 1px solid var(--border-soft); }
.todo-dot { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; }
.todo-main { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.todo-title { font-weight: 700; font-size: 13.5px; }
.todo-desc { color: var(--text-muted); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.todo-amount { font-weight: 700; font-size: 13px; white-space: nowrap; }
.todo-action { color: var(--accent); font-weight: 600; font-size: 12.5px; white-space: nowrap; flex-shrink: 0; }
.todo-more { padding: 8px 12px 4px; }

/* Anker-Sprung öffnet die Account-/Buchmacher-Zeile (sonst scrollt der Link „ins Leere") */
.acc:target, details.card:target { scroll-margin-top: 76px; }

/* ── SearchableSelect (suchbare Combobox, Dark/Light über Tokens) ── */
.ss { position: relative; display: inline-block; vertical-align: top; max-width: 100%; }
.ss-native { display: none !important; }
.ss-control {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  width: 100%; height: 38px; padding: 0 11px; border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text); border-radius: var(--radius-sm);
  font-family: inherit; font-size: 13.5px; font-weight: 500; cursor: pointer; text-align: left;
}
.ss-control:hover { border-color: var(--border-strong); }
.ss-control:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--ring); }
.ss-value { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ss-value.ss-placeholder { color: var(--text-muted); }
.ss-caret { color: var(--text-muted); flex-shrink: 0; font-size: 10px; }

.ss-panel {
  position: fixed; z-index: 300; display: none; flex-direction: column;
  background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm); box-shadow: var(--shadow-lg); overflow: hidden;
}
.ss-panel.open { display: flex; }
.ss-search { padding: 8px; border-bottom: 1px solid var(--border-soft); flex-shrink: 0; }
.ss-search input {
  width: 100%; height: 34px; padding: 0 10px; border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text); border-radius: var(--radius-sm);
  font-family: inherit; font-size: 13.5px;
}
.ss-search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--ring); }
.ss-list { list-style: none; margin: 0; padding: 4px; overflow-y: auto; flex: 1; min-height: 0; }
.ss-opt {
  padding: 8px 10px; border-radius: 6px; font-size: 13.5px; cursor: pointer;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ss-opt.active { background: var(--surface-3); }
.ss-opt.selected { color: var(--accent); font-weight: 600; }
.ss-empty { padding: 16px 10px; text-align: center; color: var(--text-muted); font-size: 13px; }
