:root {
  color-scheme: dark;
  --bg: #07111f;
  --bg-soft: #0a1727;
  --panel: rgba(14, 30, 48, 0.82);
  --panel-solid: #0e1e30;
  --panel-strong: #12263c;
  --line: rgba(153, 187, 214, 0.14);
  --line-strong: rgba(153, 187, 214, 0.28);
  --text: #eff7fa;
  --muted: #8fa8b8;
  --quiet: #607b8c;
  --mint: #1ee3c2;
  --mint-soft: rgba(30, 227, 194, 0.12);
  --amber: #f6bd60;
  --amber-soft: rgba(246, 189, 96, 0.12);
  --red: #ff6b6b;
  --red-soft: rgba(255, 107, 107, 0.12);
  --blue: #64a9ff;
  --blue-soft: rgba(100, 169, 255, 0.12);
  --shadow: 0 18px 60px rgba(0, 0, 0, 0.24);
  --radius: 18px;
  --sidebar: 232px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-synthesis: none;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f3f6f3;
  --bg-soft: #edf2ef;
  --panel: rgba(255, 255, 255, 0.88);
  --panel-solid: #ffffff;
  --panel-strong: #f2f7f4;
  --line: rgba(22, 64, 68, 0.11);
  --line-strong: rgba(22, 64, 68, 0.2);
  --text: #102c31;
  --muted: #587178;
  --quiet: #7c9297;
  --mint: #008f7a;
  --mint-soft: rgba(0, 143, 122, 0.1);
  --amber: #b9750b;
  --amber-soft: rgba(185, 117, 11, 0.1);
  --red: #cc4545;
  --red-soft: rgba(204, 69, 69, 0.1);
  --blue: #2876c8;
  --blue-soft: rgba(40, 118, 200, 0.1);
  --shadow: 0 18px 60px rgba(40, 67, 62, 0.1);
}

* { box-sizing: border-box; }

html { min-height: 100%; background: var(--bg); }

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 78% -10%, rgba(30, 227, 194, 0.08), transparent 36rem),
    radial-gradient(circle at 5% 85%, rgba(100, 169, 255, 0.06), transparent 30rem),
    var(--bg);
}

button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2px solid var(--mint);
  outline-offset: 3px;
}

.app-shell { min-height: 100vh; }

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 20;
  display: flex;
  width: var(--sidebar);
  flex-direction: column;
  padding: 22px 16px;
  border-right: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 5px 7px 25px;
  text-decoration: none;
}

.brand > span:last-child { min-width: 0; }
.brand strong { display: block; font-size: 15px; letter-spacing: 0.04em; white-space: nowrap; }
.brand small { display: block; margin-top: 4px; color: var(--quiet); font-size: 8px; letter-spacing: 0.17em; }

.brand-mark {
  position: relative;
  display: inline-grid;
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgba(30, 227, 194, 0.36);
  border-radius: 12px;
  background: var(--mint-soft);
}

.brand-mark::before, .brand-mark::after {
  position: absolute;
  content: "";
  border: 1px solid var(--mint);
  border-radius: 50%;
  opacity: 0.35;
}
.brand-mark::before { width: 24px; height: 24px; }
.brand-mark::after { width: 12px; height: 12px; opacity: 0.6; }
.brand-mark i { position: absolute; width: 18px; height: 2px; transform: rotate(-36deg) translate(7px); transform-origin: left center; border-radius: 9px; background: var(--amber); }
.brand-mark b { z-index: 1; width: 5px; height: 5px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 12px var(--mint); }
.brand-mark.small { width: 32px; height: 32px; flex-basis: 32px; border-radius: 10px; }

.nav-list { display: grid; gap: 5px; }
.nav-list a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 43px;
  padding: 0 13px;
  border: 1px solid transparent;
  border-radius: 11px;
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
  transition: 160ms ease;
}
.nav-list a span { width: 18px; color: var(--quiet); font-family: ui-monospace, monospace; text-align: center; }
.nav-list a:hover { color: var(--text); background: var(--panel); }
.nav-list a.active { border-color: rgba(30, 227, 194, 0.16); color: var(--mint); background: var(--mint-soft); }
.nav-list a.active span { color: var(--mint); }

.sidebar-note {
  margin-top: auto;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--panel);
}
.sidebar-note strong { margin-left: 7px; font-size: 11px; }
.sidebar-note p { margin: 8px 0 0; color: var(--quiet); font-size: 10px; line-height: 1.6; }
.live-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 9px rgba(30, 227, 194, 0.7); }

.workspace { min-height: 100vh; margin-left: var(--sidebar); }
.topbar {
  position: sticky;
  top: 0;
  z-index: 15;
  display: flex;
  align-items: center;
  min-height: 66px;
  gap: 10px;
  padding: 0 clamp(18px, 3.5vw, 48px);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(20px);
}
.topbar-spacer { flex: 1; }
.mobile-brand { display: none; align-items: center; gap: 9px; }
.mobile-brand strong { font-size: 14px; }

.report-picker {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--quiet);
  background: var(--panel);
  font-size: 11px;
}
.report-picker select { max-width: 135px; border: 0; outline: 0; color: var(--text); background: transparent; font-size: 11px; }
.ai-badge { padding: 7px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: var(--panel); font-size: 10px; white-space: nowrap; }
.ai-badge.deepseek { border-color: rgba(30, 227, 194, 0.22); color: var(--mint); background: var(--mint-soft); }
.ai-badge.rules { border-color: rgba(246, 189, 96, 0.22); color: var(--amber); background: var(--amber-soft); }
.icon-button { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 10px; color: var(--muted); background: var(--panel); cursor: pointer; }

main { width: min(1440px, 100%); margin: 0 auto; padding: 34px clamp(18px, 3.5vw, 48px) 70px; }

.page-header { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.eyebrow { margin: 0 0 8px; color: var(--mint); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase; }
.page-header h1 { margin: 0; font-size: clamp(25px, 3.5vw, 42px); font-weight: 650; letter-spacing: -0.04em; }
.page-header p { max-width: 690px; margin: 9px 0 0; color: var(--muted); font-size: 13px; line-height: 1.7; }
.header-actions { display: flex; gap: 8px; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  gap: 7px;
  padding: 0 13px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  color: var(--text);
  background: var(--panel);
  font-size: 11px;
  text-decoration: none;
  cursor: pointer;
}
.button.primary { border-color: rgba(30, 227, 194, 0.25); color: #031915; background: var(--mint); font-weight: 700; }
.button:hover { transform: translateY(-1px); }

.notice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 18px;
  padding: 12px 14px;
  border: 1px solid rgba(246, 189, 96, 0.24);
  border-radius: 12px;
  color: var(--amber);
  background: var(--amber-soft);
  font-size: 11px;
  line-height: 1.6;
}

.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.metric-card, .panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}
.metric-card { position: relative; min-height: 118px; padding: 17px; overflow: hidden; }
.metric-card::after { position: absolute; inset: auto -22px -34px auto; width: 90px; height: 90px; content: ""; border: 1px solid var(--line); border-radius: 50%; }
.metric-label { display: flex; justify-content: space-between; color: var(--muted); font-size: 10px; letter-spacing: 0.05em; }
.metric-label i { width: 7px; height: 7px; border-radius: 50%; background: var(--blue); box-shadow: 0 0 10px currentColor; }
.metric-card.hot .metric-label i { background: var(--red); }
.metric-card.warm .metric-label i { background: var(--amber); }
.metric-card.good .metric-label i { background: var(--mint); }
.metric-value { margin-top: 14px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 29px; font-weight: 700; letter-spacing: -0.05em; }
.metric-note { margin-top: 5px; color: var(--quiet); font-size: 10px; }

.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr); gap: 16px; }
.panel { min-width: 0; padding: 20px; }
.panel-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.panel-title { margin: 0; font-size: 13px; font-weight: 650; }
.panel-kicker { color: var(--quiet); font-size: 9px; letter-spacing: 0.1em; text-transform: uppercase; }
.panel-link { border: 0; color: var(--mint); background: transparent; font-size: 10px; text-decoration: none; cursor: pointer; }

.summary-list { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.summary-list li { display: grid; grid-template-columns: 22px 1fr; gap: 9px; color: var(--muted); font-size: 12px; line-height: 1.65; }
.summary-list li::before { display: grid; width: 20px; height: 20px; place-items: center; content: attr(data-index); border-radius: 7px; color: var(--mint); background: var(--mint-soft); font-family: ui-monospace, monospace; font-size: 9px; }

.radar-panel { position: relative; min-height: 360px; overflow: hidden; }
.radar-wrap { display: grid; min-height: 290px; place-items: center; }
.radar-chart { width: min(300px, 92%); height: auto; overflow: visible; }
.radar-chart .ring { fill: none; stroke: var(--line-strong); stroke-width: 1; stroke-dasharray: 3 6; }
.radar-chart .axis { stroke: var(--line); stroke-width: 1; }
.radar-chart .sweep { transform-origin: 150px 150px; animation: sweep 7s linear infinite; fill: url(#sweepGradient); }
.radar-chart .lead-dot { cursor: pointer; stroke: var(--bg); stroke-width: 3; transition: 160ms ease; }
.radar-chart .lead-dot:hover { r: 8; }
.radar-chart .lead-dot.hot { fill: var(--red); }
.radar-chart .lead-dot.warm { fill: var(--amber); }
.radar-chart .lead-dot.watch, .radar-chart .lead-dot.low { fill: var(--mint); }
.radar-label { position: absolute; right: 16px; bottom: 12px; color: var(--quiet); font-family: ui-monospace, monospace; font-size: 9px; }
@keyframes sweep { to { transform: rotate(360deg); } }

.lead-stack { display: grid; gap: 9px; }
.lead-row {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: color-mix(in srgb, var(--panel-strong) 70%, transparent);
  cursor: pointer;
  transition: 160ms ease;
}
.lead-row:hover { border-color: var(--line-strong); transform: translateY(-1px); }
.score-ring { display: grid; width: 45px; height: 45px; place-items: center; border: 2px solid var(--mint); border-radius: 50%; color: var(--mint); font-family: ui-monospace, monospace; font-size: 12px; font-weight: 700; }
.score-ring.hot { border-color: var(--red); color: var(--red); }
.score-ring.warm { border-color: var(--amber); color: var(--amber); }
.lead-copy { min-width: 0; }
.lead-copy strong { display: block; overflow: hidden; font-size: 12px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.lead-copy small { display: block; margin-top: 6px; overflow: hidden; color: var(--quiet); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.lead-arrow { color: var(--quiet); }

.market-bars { display: grid; gap: 11px; }
.market-bar-head { display: flex; justify-content: space-between; margin-bottom: 6px; color: var(--muted); font-size: 10px; }
.market-bar-track { height: 5px; overflow: hidden; border-radius: 5px; background: var(--line); }
.market-bar-fill { height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--mint), var(--blue)); }

.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; margin-bottom: 15px; }
.search-box { position: relative; flex: 1 1 260px; }
.search-box::before { position: absolute; top: 50%; left: 12px; content: "⌕"; transform: translateY(-50%); color: var(--quiet); }
.search-box input, .toolbar select {
  width: 100%; min-height: 38px; border: 1px solid var(--line); border-radius: 11px; color: var(--text); background: var(--panel); outline: 0;
}
.search-box input { padding: 0 13px 0 34px; }
.toolbar select { width: auto; min-width: 115px; padding: 0 28px 0 11px; }
.result-count { margin: 0 0 11px; color: var(--quiet); font-size: 10px; }

.lead-card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.lead-card { position: relative; min-width: 0; padding: 17px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); box-shadow: var(--shadow); cursor: pointer; transition: 160ms ease; }
.lead-card:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.lead-card-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tags { display: flex; flex-wrap: wrap; gap: 5px; }
.tag { display: inline-flex; align-items: center; min-height: 20px; padding: 0 7px; border-radius: 999px; color: var(--muted); background: var(--panel-strong); font-size: 8px; }
.tag.hot { color: var(--red); background: var(--red-soft); }
.tag.warm { color: var(--amber); background: var(--amber-soft); }
.tag.mint { color: var(--mint); background: var(--mint-soft); }
.lead-score { color: var(--mint); font-family: ui-monospace, monospace; font-size: 15px; font-weight: 700; }
.lead-card h3 { margin: 14px 0 9px; font-size: 14px; line-height: 1.5; }
.lead-card p { display: -webkit-box; min-height: 40px; margin: 0; overflow: hidden; color: var(--muted); font-size: 11px; line-height: 1.65; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.lead-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; padding-top: 11px; border-top: 1px solid var(--line); color: var(--quiet); font-size: 9px; }

.insight-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.insight-card { padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); }
.insight-card h3 { margin: 10px 0 8px; font-size: 14px; line-height: 1.45; }
.insight-card p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.75; }
.insight-card .implication { margin-top: 12px; padding: 11px; border-left: 2px solid var(--mint); border-radius: 0 9px 9px 0; color: var(--text); background: var(--mint-soft); }

.action-list { display: grid; gap: 9px; }
.action-item { display: grid; grid-template-columns: 38px minmax(0, 1fr) auto; align-items: start; gap: 12px; padding: 13px; border: 1px solid var(--line); border-radius: 13px; background: var(--panel); }
.priority { display: grid; width: 34px; height: 27px; place-items: center; border-radius: 8px; color: var(--amber); background: var(--amber-soft); font-family: ui-monospace, monospace; font-size: 9px; font-weight: 700; }
.priority.p0 { color: var(--red); background: var(--red-soft); }
.action-item strong { display: block; font-size: 11px; line-height: 1.55; }
.action-item p { margin: 5px 0 0; color: var(--quiet); font-size: 9px; line-height: 1.55; }
.action-owner { padding: 5px 7px; border-radius: 7px; color: var(--blue); background: var(--blue-soft); font-size: 8px; }

.source-table { overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); }
.source-row { display: grid; grid-template-columns: minmax(180px, 1.2fr) 100px 100px 90px minmax(180px, 1fr); gap: 12px; align-items: center; min-height: 60px; padding: 0 16px; border-bottom: 1px solid var(--line); font-size: 10px; }
.source-row:last-child { border-bottom: 0; }
.source-row.header { min-height: 40px; color: var(--quiet); background: var(--panel-strong); font-size: 8px; letter-spacing: 0.08em; text-transform: uppercase; }
.source-name strong { display: block; font-size: 11px; }
.source-name small { display: block; margin-top: 4px; color: var(--quiet); }
.status { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.status::before { width: 7px; height: 7px; content: ""; border-radius: 50%; background: var(--quiet); }
.status.ok::before { background: var(--mint); box-shadow: 0 0 8px rgba(30, 227, 194, 0.55); }
.status.partial::before, .status.empty::before { background: var(--amber); }
.status.error::before { background: var(--red); }

.settings-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.settings-card { padding: 19px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); }
.settings-card.wide { grid-column: 1 / -1; }
.settings-card h3 { margin: 0 0 6px; font-size: 13px; }
.settings-card > p { margin: 0 0 15px; color: var(--quiet); font-size: 10px; line-height: 1.6; }
.keyword-cloud { display: flex; flex-wrap: wrap; gap: 6px; }
.keyword { padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; color: var(--muted); background: var(--bg-soft); font-size: 9px; }
.profile-list { display: grid; gap: 10px; margin: 0; }
.profile-list div { display: grid; grid-template-columns: 95px 1fr; gap: 12px; padding-bottom: 9px; border-bottom: 1px solid var(--line); }
.profile-list div:last-child { border-bottom: 0; }
.profile-list dt { color: var(--quiet); font-size: 9px; }
.profile-list dd { margin: 0; color: var(--muted); font-size: 10px; line-height: 1.55; }

.empty-state { padding: 55px 20px; border: 1px dashed var(--line-strong); border-radius: 16px; color: var(--muted); text-align: center; }
.empty-state strong { display: block; margin-bottom: 8px; color: var(--text); }
.empty-state p { margin: 0; font-size: 11px; line-height: 1.65; }

.loading-state { display: grid; min-height: 65vh; place-items: center; align-content: center; gap: 22px; color: var(--muted); font-size: 11px; }
.radar-loader { position: relative; width: 76px; height: 76px; border: 1px solid var(--line-strong); border-radius: 50%; }
.radar-loader::before { position: absolute; inset: 14px; content: ""; border: 1px solid var(--line-strong); border-radius: 50%; }
.radar-loader i { position: absolute; top: 50%; left: 50%; width: 34px; height: 2px; transform-origin: left center; background: linear-gradient(90deg, var(--mint), transparent); animation: sweep 1.4s linear infinite; }
.radar-loader b { position: absolute; top: calc(50% - 3px); left: calc(50% - 3px); width: 6px; height: 6px; border-radius: 50%; background: var(--mint); }

.lead-dialog { width: min(720px, calc(100vw - 30px)); max-height: min(86vh, 800px); padding: 0; overflow: auto; border: 1px solid var(--line-strong); border-radius: 20px; color: var(--text); background: var(--panel-solid); box-shadow: 0 30px 90px rgba(0, 0, 0, 0.5); }
.lead-dialog::backdrop { background: rgba(0, 7, 14, 0.7); backdrop-filter: blur(6px); }
.dialog-close { position: sticky; top: 14px; z-index: 2; float: right; width: 32px; height: 32px; margin: 14px 14px -46px 0; border: 1px solid var(--line); border-radius: 50%; color: var(--muted); background: var(--panel-strong); cursor: pointer; }
.dialog-body { padding: 28px; }
.dialog-score { color: var(--mint); font-family: ui-monospace, monospace; font-size: 34px; font-weight: 700; }
.dialog-body h2 { max-width: 580px; margin: 12px 0 8px; font-size: 21px; line-height: 1.45; }
.dialog-meta { color: var(--quiet); font-size: 9px; }
.detail-section { margin-top: 22px; }
.detail-section h3 { margin: 0 0 9px; color: var(--mint); font-size: 9px; letter-spacing: 0.12em; text-transform: uppercase; }
.detail-section p, .detail-section li { color: var(--muted); font-size: 11px; line-height: 1.75; }
.detail-section ul { margin: 0; padding-left: 18px; }
.evidence-box { padding: 12px; border-left: 2px solid var(--amber); background: var(--amber-soft); }
.evidence-box p { margin: 0 0 7px; }
.evidence-box p:last-child { margin-bottom: 0; }
.dialog-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }

.toast { position: fixed; right: 20px; bottom: 20px; z-index: 100; max-width: 320px; padding: 11px 14px; transform: translateY(20px); border: 1px solid var(--line-strong); border-radius: 11px; opacity: 0; color: var(--text); background: var(--panel-solid); box-shadow: var(--shadow); font-size: 10px; pointer-events: none; transition: 180ms ease; }
.toast.show { transform: translateY(0); opacity: 1; }
.mobile-nav { display: none; }

@media (max-width: 1050px) {
  :root { --sidebar: 78px; }
  .brand > span:last-child, .nav-list a:not(.active)::after, .nav-list a { font-size: 0; }
  .brand { justify-content: center; padding-inline: 0; }
  .nav-list a { justify-content: center; padding: 0; }
  .nav-list a span { font-size: 15px; }
  .sidebar-note { display: none; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .radar-panel { min-height: 320px; }
}

@media (max-width: 760px) {
  :root { --sidebar: 0px; --radius: 15px; }
  .sidebar { display: none; }
  .workspace { margin-left: 0; }
  .topbar { min-height: 58px; padding-inline: 14px; }
  .mobile-brand { display: flex; }
  .mobile-brand strong { display: none; }
  .report-picker span, .ai-badge { display: none; }
  .report-picker { padding-inline: 8px; }
  main { padding: 24px 14px 92px; }
  .page-header { align-items: flex-start; flex-direction: column; gap: 14px; }
  .page-header h1 { font-size: 28px; }
  .header-actions { width: 100%; }
  .header-actions .button { flex: 1; }
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .metric-card { min-height: 102px; padding: 14px; }
  .metric-value { font-size: 25px; }
  .panel { padding: 15px; }
  .lead-card-grid, .insight-grid, .settings-grid { grid-template-columns: 1fr; }
  .settings-card.wide { grid-column: auto; }
  .source-table { border: 0; background: transparent; }
  .source-row.header { display: none; }
  .source-row { grid-template-columns: 1fr auto; gap: 8px; margin-bottom: 8px; padding: 13px; border: 1px solid var(--line); border-radius: 13px; background: var(--panel); }
  .source-row > :nth-child(3), .source-row > :nth-child(4) { display: none; }
  .source-row > :nth-child(5) { grid-column: 1 / -1; color: var(--quiet); }
  .mobile-nav { position: fixed; inset: auto 0 0; z-index: 30; display: grid; grid-template-columns: repeat(5, 1fr); padding: 7px 6px calc(7px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(20px); }
  .mobile-nav a { display: grid; min-height: 46px; place-items: center; align-content: center; gap: 4px; border-radius: 10px; color: var(--quiet); text-decoration: none; }
  .mobile-nav a span { font-family: ui-monospace, monospace; font-size: 14px; }
  .mobile-nav a small { font-size: 8px; }
  .mobile-nav a.active { color: var(--mint); background: var(--mint-soft); }
  .lead-dialog { width: calc(100vw - 18px); max-height: 92vh; border-radius: 16px; }
  .dialog-body { padding: 22px 18px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
