:root {
  /* Measured from Google Search Console (Material You): computed styles read on the live page. */
  --bg: #f0f4f9; --surface: #ffffff; --surface-2: #f8fafd; --border: #e1e3e1; --border-strong: #c4c7c5;
  --text: #1f1f1f; --muted: #444746; --faint: #747775;
  --accent: #0b57d0; --accent-strong: #0b57d0; --accent-soft: #d3e3fd; --on-accent: #ffffff; --nav-active: #c2e7ff; --on-nav-active: #001d35;
  --good: #146c2e; --bad: #b3261e; --warn: #b06000; --info: #0b57d0;
  --good-bg: #c4eed0; --bad-bg: #f9dedc; --warn-bg: #fff0c2; --info-bg: #d3e3fd;
  --c-clicks: #4285f4; --c-impr: #5e35b1; --c-ctr: #00796b; --c-pos: #e8710a;
  --g-product: #1a73e8; --g-article: #188038; --g-gold: #b06000; --g-job: #8430ce; --g-listing: #00796b; --g-collection: #c2185b; --g-other: #5f6368;
  --shadow: 0 1px 2px rgba(60, 64, 67, .3), 0 1px 3px 1px rgba(60, 64, 67, .15);
  --radius: 12px; --rail-w: 72px; --sidebar-w: 208px;
  --font: "Google Sans", "Google Sans Text", Roboto, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #131314; --surface: #1e1f20; --surface-2: #282a2c; --border: #37393b; --border-strong: #5e5e5e;
    --text: #e3e3e3; --muted: #c4c7c5; --faint: #8e918f;
    --accent: #a8c7fa; --accent-strong: #a8c7fa; --accent-soft: #0842a0; --on-accent: #062e6f; --nav-active: #004a77; --on-nav-active: #c2e7ff;
    --good: #6dd58c; --bad: #f2b8b5; --warn: #fdd663; --info: #a8c7fa;
    --good-bg: #0f5223; --bad-bg: #601410; --warn-bg: #4a3b00; --info-bg: #0842a0;
    --c-clicks: #8ab4f8; --c-impr: #b39ddb; --c-ctr: #4db6ac; --c-pos: #ffa352;
    --g-product: #8ab4f8; --g-article: #81c995; --g-gold: #fdd663; --g-job: #d7aefb; --g-listing: #4db6ac; --g-collection: #ff8bcb; --g-other: #9aa0a6;
    --shadow: 0 1px 2px rgba(0, 0, 0, .6), 0 1px 3px 1px rgba(0, 0, 0, .35);
  }
}
:root[data-theme="dark"] {
    --bg: #131314; --surface: #1e1f20; --surface-2: #282a2c; --border: #37393b; --border-strong: #5e5e5e;
    --text: #e3e3e3; --muted: #c4c7c5; --faint: #8e918f;
    --accent: #a8c7fa; --accent-strong: #a8c7fa; --accent-soft: #0842a0; --on-accent: #062e6f; --nav-active: #004a77; --on-nav-active: #c2e7ff;
    --good: #6dd58c; --bad: #f2b8b5; --warn: #fdd663; --info: #a8c7fa;
    --good-bg: #0f5223; --bad-bg: #601410; --warn-bg: #4a3b00; --info-bg: #0842a0;
    --c-clicks: #8ab4f8; --c-impr: #b39ddb; --c-ctr: #4db6ac; --c-pos: #ffa352;
    --g-product: #8ab4f8; --g-article: #81c995; --g-gold: #fdd663; --g-job: #d7aefb; --g-listing: #4db6ac; --g-collection: #ff8bcb; --g-other: #9aa0a6;
    --shadow: 0 1px 2px rgba(0, 0, 0, .6), 0 1px 3px 1px rgba(0, 0, 0, .35);
  }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { color-scheme: light dark; }
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }
body { margin: 0; background: var(--bg); color: var(--text); font: 14px/1.5 var(--font); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button, select, input { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 400; letter-spacing: 0; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.ic { width: 18px; height: 18px; flex: none; }
.grow { flex: 1 1 auto; }
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); font-size: 12px; }

/* layout */
.app { display: grid; grid-template-columns: var(--rail-w) var(--sidebar-w) minmax(0, 1fr); min-height: 100vh; transition: grid-template-columns .15s ease; }
.sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; background: var(--bg); padding: 16px 0 16px 0; z-index: 30; }
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 24px 18px; }
.brand-mark { width: 30px; height: 30px; color: var(--text); fill: currentColor; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 20px; font-weight: 400; letter-spacing: 0; }
.brand-text small { color: var(--muted); font-size: 11px; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a { display: flex; align-items: center; gap: 12px; height: 40px; padding: 0 14px; border-radius: 20px; margin: 0 8px; color: var(--text); font-weight: 500; }
.nav .ic { width: 22px; height: 22px; }
.nav a:hover { background: var(--surface-2); }
.nav a.active { background: var(--nav-active); color: var(--on-nav-active); }
.sidebar-foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; }
.coverage { font-size: 12px; color: var(--muted); padding: 0 8px; line-height: 1.6; }
.coverage b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
.scrim { display: none; }
.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { position: sticky; top: 0; z-index: 20; background: var(--bg); border-bottom: 1px solid var(--border); padding: 12px 24px; display: flex; flex-direction: column; gap: 10px; }
.tb-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tb-row h1 { font-size: 20px; font-weight: 500; color: var(--muted); }

.sync-info { font-size: 12px; color: var(--muted); text-align: right; line-height: 1.35; }
.range-label { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.view { padding: 20px 24px 48px; display: flex; flex-direction: column; gap: 16px; max-width: 1480px; width: 100%; }

/* controls */
.btn { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 16px; border-radius: 4px; color: var(--accent-strong); border: 1px solid var(--border-strong); background: var(--surface); cursor: pointer; font-weight: 500; white-space: nowrap; }
.btn:hover { background: var(--surface-2); }
.btn:focus-visible, .seg button:focus-visible, select:focus-visible, input:focus-visible, .chip:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn.primary:hover { background: var(--accent-strong); border-color: var(--accent-strong); }
.btn.primary[disabled] { opacity: .75; cursor: progress; }
.btn.ghost { border-color: transparent; background: transparent; color: var(--muted); }
.btn.ghost:hover { background: var(--surface-2); color: var(--text); }
.btn.icon { width: 32px; padding: 0; justify-content: center; }
.btn.sm { height: 28px; padding: 0 10px; font-size: 13px; }
.spin { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
select, input[type="date"], input[type="search"] { height: 36px; border-radius: 4px; border: 1px solid var(--border-strong); background: var(--surface); padding: 0 10px; }
select { appearance: none; -webkit-appearance: none; padding: 0 36px 0 12px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%235f6368' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; background-size: 12px 8px; }
:root[data-theme="dark"] select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23c4c7c5' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23c4c7c5' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); } }
select[disabled] { opacity: .5; }
input[type="search"] { min-width: 240px; }
.seg { display: inline-flex; border: 1px solid var(--border-strong); border-radius: 8px; overflow: hidden; background: var(--surface); }
.seg button { border: 0; background: transparent; padding: 0 12px; height: 30px; cursor: pointer; color: var(--muted); font-weight: 500; }
.seg button + button { border-left: 1px solid var(--border); }
.seg button:hover { color: var(--text); background: var(--surface-2); }
.seg button.on { background: var(--accent-soft); color: var(--accent-strong); }
.custom-range { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.cr-lab { font-size: 12px; font-weight: 500; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.chip { border: 1px solid var(--border-strong); background: var(--surface); border-radius: 16px; padding: 2px 12px; height: 32px; cursor: pointer; font-size: 13px; color: var(--muted); }
.chip:hover { color: var(--text); background: var(--surface-2); }
.chip.on { background: var(--accent-soft); border-color: var(--accent-soft); color: var(--accent-strong); }
.chip .cnt { opacity: .7; margin-left: 4px; font-variant-numeric: tabular-nums; }
.chip-label { font-size: 12px; color: var(--muted); margin-right: 2px; }
.toolbar { display: flex; align-items: center; gap: 12px 16px; flex-wrap: wrap; }

/* feedback */
.banner { margin: 12px 24px 0; padding: 10px 14px; border-radius: 8px; background: var(--bad-bg); color: var(--bad); border: 1px solid color-mix(in srgb, var(--bad) 35%, transparent); display: flex; align-items: center; gap: 10px; }
.banner.info { background: var(--info-bg); color: var(--info); border-color: color-mix(in srgb, var(--info) 35%, transparent); }
.banner .grow { color: var(--text); }
.toast { position: fixed; right: 20px; bottom: 20px; z-index: 60; background: var(--text); color: var(--bg); padding: 10px 14px; border-radius: 8px; box-shadow: var(--shadow); max-width: 360px; }
.empty { text-align: center; padding: 56px 20px; color: var(--muted); background: var(--surface); border: 1px dashed var(--border-strong); border-radius: var(--radius); }
.empty p { margin: 0 0 14px; font-size: 15px; }
.empty.compact { padding: 22px 16px; }
.empty.compact p { margin: 0; font-size: 13px; }
.skel { background: linear-gradient(90deg, var(--surface-2), var(--border), var(--surface-2)); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; border-radius: 6px; }
@keyframes shimmer { to { background-position: -200% 0; } }
.skel.kpi { height: 92px; border-radius: var(--radius); }
.skel.chart { height: 300px; border-radius: var(--radius); }
.skel.line { height: 18px; margin: 12px 0; }
.skel.block { height: 220px; border-radius: var(--radius); }
.tip { position: fixed; z-index: 50; pointer-events: none; background: var(--surface); color: var(--text); border: 1px solid var(--border-strong); border-radius: 8px; box-shadow: var(--shadow); padding: 8px 10px; font-size: 12px; max-width: 320px; line-height: 1.5; }
.tip b { font-weight: 600; }
.tip .tip-ev { margin-top: 6px; padding-top: 6px; border-top: 1px solid var(--border); color: var(--muted); }
.tip .sw { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; }

/* cards */
.card { background: var(--surface); border: 0; border-radius: var(--radius); overflow: hidden; }
.card-h { display: flex; align-items: center; gap: 10px; padding: 18px 20px 12px; flex-wrap: wrap; }
.card-h h2 { font-size: 22px; font-weight: 400; }
.card-h .sub { color: var(--muted); font-size: 12px; }
.card-b { padding: 8px 20px 18px; }
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.kpi { padding: 14px 16px; }
.kpi .label { font-size: 14px; font-weight: 500; }
.kpi .value { font-size: 32px; font-weight: 400; margin: 4px 0 6px; font-variant-numeric: tabular-nums; }
.kpi .prev { font-size: 12px; opacity: .85; }
.kpis .kpi { position: relative; width: 100%; text-align: left; font: inherit; border: 0; cursor: pointer; background: var(--surface); color: var(--muted); border-radius: var(--radius); }
.kpis .kpi:hover { background: var(--surface-2); }
.kpis .kpi:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.kpi .chk { position: absolute; top: 14px; right: 14px; width: 18px; height: 18px; border: 2px solid var(--faint); border-radius: 3px; }
.kpis .kpi.on { color: #fff; }
.kpis .kpi.on .chk { border-color: #fff; background: #fff; }
.kpis .kpi.on .chk::after { content: ""; position: absolute; left: 4px; top: 0; width: 5px; height: 10px; border: solid var(--c-clicks); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.kpis .kpi.k-clicks.on { background: var(--c-clicks); }
.kpis .kpi.k-impr.on { background: var(--c-impr); }
.kpis .kpi.k-ctr.on { background: var(--c-ctr); }
.kpis .kpi.k-pos.on { background: var(--c-pos); }
.kpis .kpi.k-impr.on .chk::after { border-color: var(--c-impr); }
.kpis .kpi.k-ctr.on .chk::after { border-color: var(--c-ctr); }
.kpis .kpi.k-pos.on .chk::after { border-color: var(--c-pos); }
.kpis .kpi.on .delta { background: rgba(255, 255, 255, .22); color: #fff; }
:root[data-theme="dark"] .kpis .kpi.on, :root[data-theme="dark"] .kpis .kpi.on .delta { color: #202124; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .kpis .kpi.on, :root:not([data-theme="light"]) .kpis .kpi.on .delta { color: #202124; } }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }

.delta { display: inline-block; font-size: 12px; font-weight: 600; padding: 0 6px; border-radius: 5px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.delta.good { color: var(--good); background: var(--good-bg); }
.delta.bad { color: var(--bad); background: var(--bad-bg); }
.delta.flat { color: var(--muted); background: var(--surface-2); }
.txt-good { color: var(--good); } .txt-bad { color: var(--bad); }

/* badges */
.badge { display: inline-block; font-size: 11px; font-weight: 600; line-height: 18px; padding: 0 7px; border-radius: 999px; background: var(--surface-2); color: var(--muted); white-space: nowrap; border: 1px solid var(--border); }
.badge.warn { background: var(--warn-bg); color: var(--warn); border-color: transparent; }
.badge.bad { background: var(--bad-bg); color: var(--bad); border-color: transparent; }
.badge.info { background: var(--info-bg); color: var(--info); border-color: transparent; }
.badge.accent { background: var(--accent-soft); color: var(--accent-strong); border-color: transparent; }
.badge.good { background: var(--good-bg); color: var(--good); border-color: transparent; }
.badge.count { background: var(--accent); color: var(--on-accent); border-color: transparent; }

/* tables */
.tbl-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { padding: 8px 12px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }
th { position: sticky; top: 0; background: var(--surface); border-bottom: 1px solid var(--border-strong); color: var(--muted); font-size: 12px; font-weight: 500; white-space: nowrap; user-select: none; }
th.num { text-align: right; }
th[data-sort] { cursor: pointer; }
th[data-sort]:hover { color: var(--text); }
th .arr { color: var(--accent-strong); margin-left: 4px; }
tbody tr:hover { background: color-mix(in srgb, var(--accent-soft) 55%, transparent); }
tr[data-href] { cursor: pointer; }
tbody tr:last-child td { border-bottom: 0; }
td.cell-main { min-width: 260px; max-width: 420px; }
.t-title { font-weight: 500; display: block; overflow: hidden; text-overflow: ellipsis; }
a.t-title:hover { color: var(--accent-strong); text-decoration: underline; }
.t-sub { color: var(--muted); font-size: 12px; font-family: var(--mono); word-break: break-all; }
.badges { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 3px; }
.date-cell { white-space: nowrap; }
.date-cell small { display: block; color: var(--muted); font-size: 12px; }
.ellipsis { max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: inline-block; vertical-align: bottom; }
.tbl-foot { padding: 8px 14px; font-size: 12px; color: var(--muted); border-top: 1px solid var(--border); }

/* bars */
.bars { display: flex; flex-direction: column; gap: 10px; }
.bar-row { display: grid; grid-template-columns: minmax(70px, 130px) 1fr auto; gap: 10px; align-items: center; font-size: 13px; }
.bar-row .bl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-row .bv { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.bar-row .bv small { color: var(--muted); margin-left: 6px; }
.bar { width: 100%; height: 8px; display: block; }
.bar .bg { fill: var(--surface-2); }
.bar .fg { fill: var(--accent); }

/* chart */
.chart-legend { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.lg { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--border-strong); background: var(--surface); border-radius: 999px; padding: 1px 10px; height: 26px; cursor: pointer; font-size: 12px; color: var(--text); }
.lg .sw { width: 10px; height: 10px; border-radius: 3px; }
.lg.off { opacity: .45; }
.lg-clicks .sw { background: var(--c-clicks); }
.lg-impr .sw { background: var(--c-impr); }
.lg-ev { color: var(--muted); cursor: default; }
.lg-ev .sw { background: transparent; border: 2px solid var(--muted); transform: rotate(45deg) scale(.7); border-radius: 1px; }
.chart-body { width: 100%; min-height: 260px; }
.chart-body svg { display: block; overflow: visible; }
.c-grid { stroke: var(--border); stroke-width: 1; }
.c-axis { fill: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.c-ev { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 3 3; opacity: .8; }
.c-ev-dot { fill: var(--muted); }
.c-cross { stroke: var(--muted); stroke-width: 1; }

/* detail */
.back { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-size: 13px; }
.back:hover { color: var(--text); }
.detail-head h2 { font-size: 20px; margin: 4px 0; }
.detail-head .url { display: inline-flex; align-items: center; gap: 6px; color: var(--accent-strong); word-break: break-all; font-family: var(--mono); font-size: 12px; }
.detail-head .url:hover { text-decoration: underline; }
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px 20px; margin: 0; }
.facts dt { font-size: 12px; color: var(--muted); }
.facts dd { margin: 2px 0 0; font-weight: 500; word-break: break-word; }
.facts dd small { color: var(--muted); font-weight: 400; display: block; }
.alias-list { margin: 0; padding: 0; list-style: none; font-size: 12px; font-family: var(--mono); display: flex; flex-direction: column; gap: 4px; }
.alias-list li span { font-family: var(--font); color: var(--muted); margin-left: 8px; }

/* timeline */
.tl-day { display: grid; grid-template-columns: 110px 1fr; gap: 12px; }
.tl-date { color: var(--muted); font-size: 13px; font-weight: 600; padding-top: 12px; font-variant-numeric: tabular-nums; }
.tl-items { border-left: 2px solid var(--border); padding-left: 16px; display: flex; flex-direction: column; gap: 8px; padding-bottom: 14px; }
.tl-item { position: relative; padding: 10px 14px; }
.tl-item::before { content: ""; position: absolute; left: -23px; top: 18px; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); border: 2px solid var(--bg); }
.tl-item.pub::before { background: var(--good); }
.tl-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tl-metrics { display: flex; gap: 22px; flex-wrap: wrap; margin-top: 8px; font-size: 13px; }
.tl-metrics .m span { color: var(--muted); font-size: 12px; display: block; }
.tl-metrics .m b { font-weight: 600; font-variant-numeric: tabular-nums; }

/* insights */
details.sec { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
details.sec > summary { list-style: none; cursor: pointer; padding: 12px 16px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
details.sec > summary::-webkit-details-marker { display: none; }
details.sec > summary::before { content: ""; width: 7px; height: 7px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(-45deg); transition: transform .15s; }
details.sec[open] > summary::before { transform: rotate(45deg); }
details.sec h2 { font-size: 15px; }
.rule { padding: 0 16px 12px 33px; margin: 0; color: var(--muted); font-size: 13px; }
details.sec .tbl-wrap { border-top: 1px solid var(--border); }
.pg-list { display: flex; flex-direction: column; gap: 4px; }
.pg-list a:hover { color: var(--accent-strong); text-decoration: underline; }
.pg-list small { color: var(--muted); margin-left: 6px; font-variant-numeric: tabular-nums; }

@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid3 { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .app { grid-template-columns: minmax(0, 1fr); }
  .sidebar { position: fixed; inset: 0 auto 0 0; width: 250px; transform: translateX(-100%); transition: transform .2s; }
  body.nav-open .sidebar { transform: none; box-shadow: var(--shadow); }
  body.nav-open .scrim { display: block; position: fixed; inset: 0; background: rgba(0, 0, 0, .35); z-index: 25; }
  .topbar { padding: 10px 14px; }
  .view { padding: 14px 14px 40px; }
  .banner { margin: 10px 14px 0; }
  .sync-info { display: none; }
  .grid2 { grid-template-columns: 1fr; }
  .kpi .value { font-size: 22px; }
  input[type="search"] { min-width: 0; width: 100%; }
  .tl-day { grid-template-columns: 1fr; gap: 0; }
  .tl-date { padding-top: 0; }
}
@media (max-width: 480px) {
  .kpis { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .skel, .spin { animation: none; }
}

/* chart series (any combination of the four metrics) */
.c-line { fill: none; stroke-width: 2; stroke-linejoin: round; }
.c-line-clicks { stroke: var(--c-clicks); } .c-line-impr { stroke: var(--c-impr); } .c-line-ctr { stroke: var(--c-ctr); } .c-line-pos { stroke: var(--c-pos); }
.c-dot { stroke: var(--surface); stroke-width: 2; }
.c-dot-clicks { fill: var(--c-clicks); } .c-dot-impr { fill: var(--c-impr); } .c-dot-ctr { fill: var(--c-ctr); } .c-dot-pos { fill: var(--c-pos); }
.lg-ctr .sw, .tip .sw.lg-ctr { background: var(--c-ctr); } .lg-pos .sw, .tip .sw.lg-pos { background: var(--c-pos); }
.tip .sw.lg-clicks { background: var(--c-clicks); } .tip .sw.lg-impr { background: var(--c-impr); }
.c-axis-title { font-weight: 500; }

/* page-type groups: one colour each, shared by badges, filter chips and bars */
.g-product { --gc: var(--g-product); }
.g-article { --gc: var(--g-article); }
.g-gold { --gc: var(--g-gold); }
.g-job { --gc: var(--g-job); }
.g-listing { --gc: var(--g-listing); }
.g-collection { --gc: var(--g-collection); }
.g-other { --gc: var(--g-other); }
.badge[class*="g-"] { background: color-mix(in srgb, var(--gc) 14%, var(--surface)); color: var(--gc); border-color: transparent; }
.chip[class*="g-"]::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--gc); margin-right: 7px; }
.bar[class*="g-"] .fg { fill: var(--gc); }

/* E-health */
.hl-note { margin: 0; font-size: 13px; }
.hl-tiles { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.hl-tile { padding: 14px 16px; --tc: var(--accent); }
.hl-tile .label { font-size: 14px; font-weight: 500; color: var(--muted); }
.hl-tile .value { font-size: 28px; font-weight: 400; margin: 2px 0 8px; font-variant-numeric: tabular-nums; }
.hl-tile .value small { font-size: 14px; color: var(--muted); }
.hl-tile .prev { font-size: 12px; color: var(--muted); margin-top: 6px; }
.hl-bar { height: 4px; border-radius: 2px; background: var(--border); overflow: hidden; }
.hl-bar span { display: block; height: 100%; border-radius: 2px; background: var(--tc); }
.hl-stackcard { padding-top: 16px; }
.hl-stack { display: flex; gap: 2px; height: 12px; border-radius: 6px; overflow: hidden; background: var(--border); }
.hl-stack span { min-width: 3px; }
.hl-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; font-size: 12px; color: var(--muted); }
.hl-legend .lgd { display: inline-flex; align-items: center; gap: 6px; }
.hl-legend b { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
.hl-legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.st-top10 { background: var(--good); } .st-ranking { background: var(--info); } .st-no_impressions { background: var(--warn); }
.st-not_published { background: var(--bad); } .st-not_matched { background: var(--faint); }
.hl-filters { display: flex; flex-direction: column; gap: 8px; }
.t-sub.kw { font-family: var(--font); word-break: normal; display: block; }
.sub-num, td small { color: var(--muted); }
td.num .sub-num { display: block; font-size: 12px; }
td > .badge + small { margin-left: 6px; font-size: 12px; font-variant-numeric: tabular-nums; }
.row-act { display: flex; gap: 6px; white-space: nowrap; }
.code { margin: 0 auto 14px; display: inline-block; text-align: left; background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; padding: 10px 14px; font: 13px var(--mono); color: var(--text); max-width: 100%; overflow-x: auto; }
.modal-back { position: fixed; inset: 0; z-index: 70; background: rgba(0, 0, 0, .4); display: flex; align-items: flex-start; justify-content: center; padding: 6vh 16px 16px; overflow-y: auto; }
.modal { width: 100%; max-width: 680px; box-shadow: var(--shadow); border: 1px solid var(--border); }
.hm-topic { display: flex; flex-direction: column; gap: 2px; margin-bottom: 8px; }
.hm-cur { font-size: 13px; margin-bottom: 8px; }
.hm-cur a { color: var(--accent-strong); font-family: var(--mono); font-size: 12px; }
.hm-cur small { margin-left: 4px; }
.hm-err { margin: 8px 0; padding: 8px 12px; border-radius: 8px; background: var(--bad-bg); color: var(--bad); font-size: 13px; }
.hm-h { font-size: 14px; font-weight: 500; color: var(--muted); margin: 14px 0 6px; }
.hm-cands { list-style: none; margin: 0; padding: 0; border: 1px solid var(--border); border-radius: 8px; max-height: 40vh; overflow-y: auto; }
.hm-cands li { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-bottom: 1px solid var(--border); }
.hm-cands li:last-child { border-bottom: 0; }
.hm-cands li.cur { background: var(--accent-soft); }
.hm-c-main { flex: 1 1 auto; min-width: 0; }
.hm-score { font-variant-numeric: tabular-nums; font-weight: 600; width: 40px; text-align: right; color: var(--muted); }
.hm-paste { display: flex; gap: 8px; }
.hm-paste input { flex: 1 1 auto; min-width: 0; height: 36px; border-radius: 4px; border: 1px solid var(--border-strong); background: var(--surface); padding: 0 10px; }
.hm-hint { margin: 6px 0 0; font-size: 12px; }
.hm-foot { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border); }
@media (max-width: 1100px) { .hl-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 768px) { .hl-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } .hl-tile .value { font-size: 22px; } .hm-cands li { flex-wrap: wrap; } .modal-back { padding-top: 3vh; } }
td.cell-main.hl-m { min-width: 190px; max-width: 280px; }

/* ---------- accounts: sign-in, avatar menu, dialogs, users ---------- */
.auth { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px 16px; background: var(--bg); }
.auth-card { width: 100%; max-width: 440px; background: var(--surface); border: 1px solid var(--border); border-radius: 28px; padding: 44px 40px 32px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.auth-card form { width: 100%; text-align: left; margin-top: 8px; }
.auth-mark { width: 52px; height: 52px; color: var(--text); fill: currentColor; }
.auth-card h1 { font-size: 24px; margin-top: 12px; color: var(--text); }
.auth-sub { margin: 8px 0 24px; font-size: 16px; color: var(--text); }
.auth-notice { align-self: stretch; margin: -8px 0 16px; padding: 8px 12px; border-radius: 8px; font-size: 13px; background: var(--info-bg); color: var(--info); }
.auth-notice.error { background: var(--bad-bg); color: var(--bad); }
.auth-err { margin: -4px 0 12px; font-size: 13px; color: var(--bad); }
.auth-help { margin: 12px 0 28px; font-size: 13px; color: var(--muted); }
.auth-actions { display: flex; justify-content: flex-end; }
.auth-actions .btn { height: 40px; padding: 0 24px; border-radius: 20px; }
.auth-actions .btn:disabled { cursor: progress; }
@media (max-width: 480px) { .auth { padding: 0; align-items: flex-start; } .auth-card { border: 0; border-radius: 0; min-height: 100vh; padding: 56px 24px 24px; max-width: none; } }

/* outlined field with floating label */
.field { position: relative; margin: 0 0 18px; }
.field input, .field select { width: 100%; height: 56px; padding: 0 14px; border: 1px solid var(--border-strong); border-radius: 4px; background-color: var(--surface); color: var(--text); font-size: 16px; }
.field select { padding-right: 40px; }
.field input:focus, .field select:focus { outline: 0; border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.field.has-act input { padding-right: 52px; }
.field label { position: absolute; left: 10px; top: 28px; transform: translateY(-50%); padding: 0 4px; background: var(--surface); color: var(--muted); font-size: 16px; line-height: 1; pointer-events: none; transition: top .12s, font-size .12s, color .12s; }
.field input:focus + label, .field input:not(:placeholder-shown) + label, .field input:-webkit-autofill + label, .field.sel label { top: 0; font-size: 12px; }
.field input:focus + label, .field select:focus + label { color: var(--accent); }
.field.err input { border-color: var(--bad); box-shadow: 0 0 0 1px var(--bad); }
.field.err label { color: var(--bad); }
.field .fld-act { position: absolute; right: 8px; top: 12px; }
.gen-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: -6px 0 18px; font-size: 12px; }
.field input[autocomplete="off"][name="password"] { font-family: var(--mono); font-size: 14px; }

/* avatar + account menu */
.acct { position: relative; }
.avatar { width: 36px; height: 36px; border-radius: 50%; border: 0; padding: 0; display: inline-flex; align-items: center; justify-content: center; font: 500 16px var(--font); color: #fff; background: var(--g-other); flex: none; }
button.avatar { cursor: pointer; }
button.avatar:hover { box-shadow: 0 0 0 4px color-mix(in srgb, var(--text) 10%, transparent); }
button.avatar:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.avatar.big { width: 64px; height: 64px; font-size: 28px; }
.av-0 { background: #1a73e8; } .av-1 { background: #188038; } .av-2 { background: #c26401; } .av-3 { background: #8430ce; }
.av-4 { background: #c2185b; } .av-5 { background: #00796b; } .av-6 { background: #d93025; } .av-7 { background: #5f6368; }
.acct-menu { position: absolute; right: 0; top: calc(100% + 8px); z-index: 40; width: 320px; max-width: calc(100vw - 28px); background: var(--surface); border: 1px solid var(--border); border-radius: 24px; box-shadow: var(--shadow); padding: 20px 12px 12px; }
.acct-head { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 0 12px 14px; text-align: center; }
.acct-head .avatar { margin-bottom: 8px; }
.acct-head .badge { margin-top: 8px; }
.acct-name { font-size: 16px; font-weight: 500; word-break: break-word; }
.acct-mail { font-size: 13px; color: var(--muted); word-break: break-all; }
.acct-list { display: flex; flex-direction: column; gap: 2px; border-top: 1px solid var(--border); padding-top: 8px; }
.acct-list > * { display: flex; align-items: center; gap: 14px; height: 44px; padding: 0 14px; border: 0; border-radius: 22px; background: transparent; color: var(--text); cursor: pointer; text-align: left; font-weight: 500; }
.acct-list > *:hover, .acct-list > *:focus-visible { background: var(--surface-2); outline: 0; }
.acct-list .ic { color: var(--muted); }

/* dialogs + buttons */
.modal.sm { max-width: 440px; }
.dlg-intro { margin: 0 0 16px; word-break: break-word; }
.dlg-hint { margin: -6px 0 12px; font-size: 12px; }
.dlg-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; }
.btn.danger { background: var(--bad); border-color: var(--bad); color: var(--surface); }
.btn.danger:hover { filter: brightness(.92); }
.btn.locked, .btn[disabled].locked { cursor: not-allowed; opacity: .5; }
.btn[disabled] { cursor: not-allowed; }
.btn.primary[disabled]:not(.locked) { cursor: progress; }
body[data-role="viewer"] .empty [data-action="sync"] { display: none; }

/* users */
.u-id { display: inline-flex; align-items: center; gap: 12px; }
.u-id .avatar { width: 28px; height: 28px; font-size: 13px; }
body[data-view="users"] .tb-row.filters { display: none; }
@media (max-width: 480px) { .acct-menu { position: fixed; right: 14px; top: 56px; } }

/* module rail (far left): Dashboard / Technical Health / Publish / Create */
.rail { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 12px 0; background: var(--bg); z-index: 31; }
.rail-brand { display: grid; place-items: center; width: 48px; height: 48px; margin-bottom: 8px; }
.rail-brand .brand-mark { width: 30px; height: 30px; color: var(--text); fill: currentColor; }
.rail-item { display: flex; flex-direction: column; align-items: center; gap: 4px; width: 68px; padding: 4px 0; color: var(--muted); font-size: 11px; font-weight: 500; text-align: center; line-height: 1.2; }
.rail-item .ri { display: grid; place-items: center; width: 52px; height: 32px; border-radius: 16px; transition: background .12s; }
.rail-item .ic { width: 24px; height: 24px; }
.rail-item:hover .ri { background: var(--surface-2); }
.rail-item.active { color: var(--text); }
.rail-item.active .ri { background: var(--nav-active); color: var(--on-nav-active); }
.rail-foot { margin-top: auto; }
.rail-btn { display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%; background: transparent; color: var(--muted); cursor: pointer; }
.rail-btn:hover { background: var(--surface-2); color: var(--text); }
.rail-btn .ic { width: 22px; height: 22px; }
.rail a:focus-visible, .rail-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 12px; }

/* module side menu: title + that module's pages */
.side-title { padding: 10px 22px 14px; font-size: 18px; color: var(--text); }
.sidebar { overflow: hidden; }
.coverage { padding: 0 22px; }

/* the burger hides the side menu on desktop (remembered); the rail stays */
body.sidebar-collapsed { --sidebar-w: 0px; }
body.sidebar-collapsed .sidebar { visibility: hidden; padding-left: 0; padding-right: 0; }

/* modules without a side menu yet */
body[data-module="tech"] .tb-row.filters, body[data-module="publish"] .tb-row.filters, body[data-module="create"] .tb-row.filters,
body[data-module="tech"] #syncBtn, body[data-module="publish"] #syncBtn, body[data-module="create"] #syncBtn,
body[data-module="tech"] .sync-info, body[data-module="publish"] .sync-info, body[data-module="create"] .sync-info { display: none; }

/* planned-module page */
.planned .card-b { padding: 24px 28px 28px; max-width: 760px; }
.planned h2 { font-size: 26px; margin: 10px 0 6px; }
.planned h3 { font-size: 14px; font-weight: 500; color: var(--muted); margin: 22px 0 6px; }
.planned .lead { font-size: 16px; margin: 0; color: var(--text); }
.planned ul { margin: 0; padding-left: 20px; line-height: 1.8; }
.planned .have { margin: 22px 0 8px; padding: 12px 14px; border-radius: 8px; background: var(--surface-2); }

@media (max-width: 768px) {
  /* phones: the rail becomes a bottom tab bar, the side menu a drawer behind the burger */
  .app { grid-template-columns: minmax(0, 1fr); padding-bottom: 64px; }
  .rail { position: fixed; inset: auto 0 0 0; top: auto; height: 64px; flex-direction: row; justify-content: space-around; padding: 4px 8px; background: var(--surface); border-top: 1px solid var(--border); z-index: 40; }
  .rail-brand, .rail-foot { display: none; }
  .rail-item { width: auto; flex: 1; }
  body.sidebar-collapsed { --sidebar-w: 208px; }
  body.sidebar-collapsed .sidebar { visibility: visible; }
}

/* Technical Health */
.tech-kpis { margin-bottom: 16px; }
.tech-kpis .kpi.tk { cursor: pointer; border: 0; }
.tech-kpis .kpi.s-critical .value { color: var(--bad); }
.tech-kpis .kpi.s-warning .value { color: var(--warn); }
.tech-kpis .kpi.s-notice .value { color: var(--info); }
.tech-kpis .kpi.tk.on { outline: 2px solid var(--accent); outline-offset: -2px; }
.tech-site { margin-bottom: 20px; }
.checks { list-style: none; margin: 0; padding: 0 0 8px; }
.checks li { display: flex; align-items: center; gap: 12px; padding: 9px 20px; border-top: 1px solid var(--border); }
.checks li small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; word-break: break-all; }
.checks .ck { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700; flex: none; }
.checks .pass .ck { background: var(--good-bg); color: var(--good); }
.checks .fail .ck { background: var(--bad-bg); color: var(--bad); }
.tech-h { font-size: 18px; font-weight: 400; margin: 8px 0 12px; }
#view details.sec + details.sec { margin-top: 10px; }
.rule .src { display: inline-block; margin-left: 6px; font-size: 12px; opacity: .8; }
.t-ev { font-size: 12px; color: var(--muted); word-break: break-word; }
.tech-foot { margin-top: 18px; font-size: 12px; }
@media (max-width: 768px) { .tech-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* E-health: the page column shows the URL path, with how it was matched under it */
.hl-path { word-break: break-all; }
.t-sub.hl-match { display: flex; align-items: center; gap: 6px; margin-top: 4px; font-family: var(--font); word-break: normal; }
.t-sub.hl-match small { color: var(--muted); }

/* Technical Health tabs + AI crawlers */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin: -4px 0 16px; }
.tabs .tab { padding: 10px 16px; color: var(--muted); font-weight: 500; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.tabs .tab:hover { color: var(--text); }
.tabs .tab.on { color: var(--accent-strong, var(--accent)); border-bottom-color: var(--accent); }
.ai-kpis { margin: 8px 0 16px; }
.ai-days { margin-bottom: 16px; }
.daycols { width: 100%; height: 160px; display: block; }
.daycols .col-all { fill: var(--border-strong); }
.daycols .col-ai { fill: var(--accent); }
.daycols-x { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); margin-top: 4px; }
.ai-days .legend { display: flex; gap: 16px; font-size: 12px; color: var(--muted); margin-top: 6px; }
.ai-days .legend .sw { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; }
.ai-days .legend .sw.col-ai { background: var(--accent); }
.ai-days .legend .sw.col-all { background: var(--border-strong); }
.ai-special li { gap: 8px; }
.ai-note { margin-top: 18px; font-size: 12px; }
#aiImport { max-width: 420px; }
@media (max-width: 768px) { .ai-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* per-module side menus; the coverage footer belongs to the Dashboard */
body:not([data-module="report"]) .nav[data-for="report"], body:not([data-module="create"]) .nav[data-for="create"], body:not([data-module="tech"]) .nav[data-for="tech"], body:not([data-module="publish"]) .nav[data-for="publish"], body:not([data-module="admin"]) .nav[data-for="admin"] { display: none; }
body:not([data-module="report"]) .sidebar-foot { display: none; }

/* content creation */
.c-cost { margin-top: 12px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.c-note { color: var(--muted); font-size: 13px; margin: 10px 2px 16px; }
.c-docs { display: inline-flex; gap: 3px; }
.c-docs a, .c-docs span { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 4px; font-size: 11px; font-weight: 600; }
.c-docs a { background: var(--accent-soft); color: var(--accent-strong); }
.c-docs span { background: var(--surface-2); color: var(--faint); }
.hl-tile.good .value { color: var(--good); }
.hl-tile.bad .value { color: var(--bad); }
@media (max-width: 900px) { .c-cost { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.c-sub { display: block; font-size: 12px; color: var(--muted); line-height: 1.4; margin-top: 2px; }

/* Publishing: environments, internal-link pass */
.pub-envs { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.pub-env { padding: 12px 14px; border: 1px solid var(--border); border-radius: 8px; display: grid; gap: 4px; }
.lk-env { margin-bottom: 14px; }
.lk-rule { display: grid; grid-template-columns: minmax(200px, 1.2fr) minmax(180px, 1fr) minmax(200px, 1.2fr) minmax(150px, .8fr) auto; gap: 12px; align-items: end; padding: 12px 0; border-top: 1px solid var(--border); }
.lk-rule label, .lk-env label { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
.lk-rule input, .lk-rule textarea { padding: 8px 10px; border: 1px solid var(--border-strong); border-radius: 4px; background: var(--surface); color: var(--text); font: inherit; width: 100%; box-sizing: border-box; }
.lk-bar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 14px; }
.lk-rules { margin: 12px 0 0; font-size: 13px; }
.lk-sum { margin-bottom: 10px; }
.lk-tg { padding: 4px 0; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.lk-post { border-top: 1px solid var(--border); padding: 10px 0; }
.lk-post.skipped { opacity: .5; }
.lk-ph { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.lk-l { margin: 6px 0 0 24px; font-size: 13px; }
.lk-ctx { color: var(--muted); margin-top: 2px; }
.lk-ctx mark { background: var(--accent-soft); color: var(--text); padding: 0 2px; border-radius: 3px; }
.lk-err { color: var(--bad); margin: 4px 0 0 24px; font-size: 13px; }
@media (max-width: 768px) { .lk-rule { grid-template-columns: 1fr; } }

/* Publishing: Word import */
.im-row { display: flex; gap: 12px; align-items: end; flex-wrap: wrap; }
.im-row label, .im-col { display: grid; gap: 4px; font-size: 13px; color: var(--muted); }
.im-col { margin-top: 10px; }
.im-row input, .im-row select, .im-col input, .im-col textarea { padding: 8px 10px; border: 1px solid var(--border-strong); border-radius: 4px; background: var(--surface); color: var(--text); font: inherit; min-width: 170px; }
.im-col input, .im-col textarea { width: 100%; box-sizing: border-box; }
.im-row select { height: 38px; }
.im-drop { margin-top: 12px; padding: 22px; border: 2px dashed var(--border-strong); border-radius: 8px; text-align: center; color: var(--muted); cursor: pointer; }
.im-drop.on, .im-drop:hover { border-color: var(--accent); color: var(--text); }
.im-grid tr { cursor: pointer; } .im-grid tr.on { background: var(--accent-soft); }
.mk.ok { color: var(--ok, #1e8e3e); } .mk.warn { color: var(--warn); } .mk.err { color: var(--bad); } .mk.na { color: var(--muted); }
.im-imgs { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.im-img { border: 1px solid var(--border); border-radius: 8px; padding: 8px; font-size: 12px; display: grid; gap: 4px; }
.im-img.cover { border-color: var(--accent); }
.im-img img { width: 100%; height: 100px; object-fit: contain; background: var(--surface-2); }
.im-seg { display: grid; grid-template-columns: 200px 1fr; gap: 10px; padding: 6px 0; border-top: 1px solid var(--border); align-items: start; }
.im-seg select { padding: 6px; border: 1px solid var(--border-strong); border-radius: 4px; background: var(--surface); color: var(--text); }
.im-t { font-size: 13px; } .im-t.skip, .im-t.meta { color: var(--muted); }
.im-note { margin-top: 6px; padding: 6px 10px; border-radius: 6px; font-size: 13px; }
.im-note.warn { background: var(--warn-bg); color: var(--warn); } .im-note.bad { background: var(--bad-bg); color: var(--bad); } .im-note.ok { background: var(--surface-2); }
.im-log { white-space: pre-wrap; background: var(--surface-2); padding: 10px; border-radius: 6px; font-size: 12px; margin-top: 10px; }
@media (max-width: 768px) { .im-seg { grid-template-columns: 1fr; } }

.lk-file { cursor: pointer; }
.lk-new { color: var(--accent-strong); }
@media (max-width: 1100px) { .lk-rule { grid-template-columns: 1fr 1fr; } }
.lm-sum { margin-bottom: 12px; }
.lm-bar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; }
.lm-bar input { padding: 8px 10px; border: 1px solid var(--border-strong); border-radius: 4px; background: var(--surface); color: var(--text); min-width: 260px; }
.lm-page { display: flex; gap: 8px; align-items: flex-start; }
.lm-dot { width: 10px; height: 10px; border-radius: 50%; margin-top: 5px; flex: none; }
.lm-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12px; margin-bottom: 8px; align-items: center; }
.lm-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 5px; vertical-align: -1px; }
.lm-map { border: 1px solid var(--border); border-radius: 8px; overflow: hidden; background: var(--surface); }
.lm-svg { width: 100%; height: auto; display: block; cursor: grab; }
.lm-link { stroke: var(--border-strong); stroke-opacity: .55; stroke-width: 1; }
.lm-link.out { stroke: var(--accent); stroke-opacity: 1; stroke-width: 1.6; }
.lm-link.in { stroke: #2ca02c; stroke-opacity: 1; stroke-width: 1.6; }
.lm-link.dim, .lm-node.dim { opacity: .12; }
.lm-arrowhead { fill: var(--border-strong); }
.lm-node { cursor: pointer; }
.lm-node circle, .lm-node rect { stroke: var(--surface); stroke-width: 1.5; }
.lm-node text { font-size: 9px; fill: var(--muted); pointer-events: none; }
.lm-side { margin-top: 12px; font-size: 13px; }
.lm-side h3 { font-size: 15px; margin: 0 0 2px; } .lm-side h4 { margin: 12px 0 4px; font-size: 13px; }
.lm-side ul { margin: 0; padding-left: 18px; } .lm-side li { margin: 3px 0; }
.lm-cluster { font-size: 12px; font-weight: 600; fill: var(--text); opacity: .55; pointer-events: none; }
.op-rules { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; font-size: 13px; }
.op-row { display: grid; gap: 4px; padding: 8px 0; border-top: 1px dashed var(--border); }
.op-act { display: flex; gap: 6px; } .op-act .btn { height: 28px; padding: 0 12px; }
.op-act .btn.on { background: var(--surface-2); }
.op-foot { position: sticky; bottom: 0; display: flex; gap: 12px; align-items: center; padding: 12px; margin-top: 12px; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 8px; box-shadow: var(--shadow); }
.op-rc { margin: 12px 0; }
