@font-face {
  font-family: "Work Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/assets/fonts/work-sans-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Work Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/assets/fonts/work-sans-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --navy: #0b2e64;
  --navy-strong: #08244f;
  --green-dark: #00624b;
  --green: #00b389;
  --mint: #b0e7da;
  --mint-light: #edf9f6;
  --orange: #ff7b00;
  --ink: #15263f;
  --muted: #68768a;
  --line: #dce3eb;
  --surface: #ffffff;
  --canvas: #f5f7fa;
  --shadow: 0 14px 42px rgba(11, 46, 100, 0.12);
  --radius-sm: 0.5rem;
  --radius: 0.75rem;
  --radius-lg: 1rem;
  font-family: "Work Sans", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--canvas);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { min-width: 320px; background: var(--canvas); }
body { margin: 0; min-height: 100vh; background: var(--canvas); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, [tabindex]:focus-visible {
  outline: 3px solid rgba(255, 123, 0, 0.42);
  outline-offset: 2px;
}
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; top: 8px; left: 8px; z-index: 100; transform: translateY(-160%); background: var(--navy); color: white; padding: 10px 14px; border-radius: 8px; }
.skip-link:focus { transform: none; }

.app-header {
  height: 76px;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--navy);
  background: white;
  border-bottom: 1px solid #e7eaef;
}
.brand-lockup, .header-actions { display: flex; align-items: center; gap: 12px; }
.brand-logo { width: 106px; height: auto; display: block; }
.brand-divider { height: 26px; width: 1px; margin: 0 2px; background: #dadada; }
.product-name { color: #64748b; font-weight: 600; }
.source-chip { display: inline-flex; align-items: center; gap: 7px; padding: 8px 12px; border: 1px solid #dadada; border-radius: 8px; color: var(--navy); background: #f3f3f3; font-size: 13px; font-weight: 700; }
.chip-dot { width: 7px; height: 7px; border-radius: 50%; background: #5ae0b9; box-shadow: 0 0 0 4px rgba(90,224,185,.13); }
.avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: var(--navy); background: var(--mint); font-size: 12px; font-weight: 800; }
.icon-button { border: 1px solid var(--line); color: var(--ink); background: white; width: 36px; height: 36px; border-radius: 50%; display: inline-grid; place-items: center; font-weight: 800; }
.app-header .icon-button { color: var(--navy); border-color: #dadada; background: #f3f3f3; }

.source-banner { min-height: 48px; padding: 8px 28px; display: flex; align-items: center; justify-content: center; gap: 18px; color: #074d3d; background: var(--mint); font-size: 13px; }
.source-banner div { display: flex; align-items: center; gap: 8px; }
.text-button { padding: 0; color: var(--green-dark); background: none; border: 0; font-weight: 800; text-decoration: underline; text-decoration-color: rgba(0,98,75,.32); text-underline-offset: 3px; }

.app-shell { min-height: calc(100vh - 124px); display: grid; grid-template-columns: 320px minmax(0, 1fr); }
.filters-backdrop { position: fixed; inset: 0; z-index: 55; background: rgba(8,36,79,.32); backdrop-filter: blur(2px); }
.filters-panel { padding: 28px 24px 36px; background: white; border-right: 1px solid var(--line); }
.panel-heading { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 22px; }
.eyebrow { display: block; margin-bottom: 5px; color: var(--green-dark); text-transform: uppercase; letter-spacing: .105em; font-size: 10px; font-weight: 900; }
h1, h2, h3, p { margin-top: 0; }
.panel-heading h1 { margin: 0; font-size: 25px; color: var(--navy); letter-spacing: -.03em; }
.filter-close, .workspace-topbar .filters-trigger { display: none; }
.mode-switcher { margin: 0 0 24px; padding: 4px; display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--line); border-radius: 10px; background: var(--canvas); }
.mode-switcher legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
.mode-switcher label { position: relative; cursor: pointer; }
.mode-switcher input { position: absolute; opacity: 0; }
.mode-switcher span { min-height: 38px; padding: 8px 7px; display: grid; place-items: center; text-align: center; border-radius: 7px; color: var(--muted); font-size: 12px; font-weight: 800; }
.mode-switcher input:checked + span { color: white; background: var(--navy); box-shadow: 0 4px 10px rgba(11,46,100,.18); }
.mode-switcher input:focus-visible + span { outline: 3px solid rgba(255,123,0,.4); }
.filter-section { margin-bottom: 19px; }
.filter-section > label, .label-row label { display: block; margin-bottom: 8px; color: #43526a; font-size: 12px; font-weight: 800; }
.label-row { display: flex; align-items: center; justify-content: space-between; }
.label-row output { color: var(--navy); font-size: 13px; font-weight: 900; }
.search-control { position: relative; }
.search-control svg { position: absolute; top: 11px; left: 11px; width: 18px; height: 18px; fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
input[type="search"], input[type="text"], input[type="number"], select, textarea { width: 100%; border: 1px solid #ccd5df; border-radius: 8px; color: var(--ink); background: white; }
input[type="search"] { height: 42px; padding: 0 12px 0 38px; }
input[type="text"], input[type="number"] { height: 42px; padding: 0 11px; }
select { height: 42px; padding: 0 34px 0 11px; }
textarea { min-height: 104px; padding: 12px; resize: vertical; line-height: 1.45; }
input[type="range"] { width: 100%; accent-color: var(--green-dark); }
.range-labels { display: flex; justify-content: space-between; color: #8a96a6; font-size: 10px; }
.filter-hint { margin: 6px 0 0; color: var(--muted); font-size: 10px; line-height: 1.4; }
.ownership-filter { padding: 14px; border: 1px solid #f0d5b8; border-radius: 12px; background: #fffaf5; }
.ownership-filter > label { margin-bottom: 7px; }
.ownership-filter select { margin-bottom: 14px; }
.ownership-filter input:disabled { opacity: .45; cursor: not-allowed; }
.filter-lock { margin-top: 7px; color: #8b5a2b; font-size: 10px; line-height: 1.4; }
.filter-lock span { margin-right: 5px; padding: 3px 6px; border-radius: 5px; color: white; background: #b66b27; font-size: 8px; font-weight: 900; letter-spacing: .06em; }
.filter-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.secondary-button, .primary-button { min-height: 42px; padding: 9px 14px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 8px; font-weight: 800; }
.secondary-button { color: var(--navy); background: white; border: 1px solid #cbd5e1; }
.secondary-button:hover { border-color: var(--navy); background: #f8fafc; }
.primary-button { color: white; background: var(--green); border: 1px solid var(--green); }
.primary-button:hover { background: #029f79; }
.full-width { width: 100%; }
.source-card { margin-top: 24px; padding: 14px; display: flex; gap: 11px; border-radius: 11px; background: var(--mint-light); border: 1px solid #d5eee8; }
.source-card-icon { flex: 0 0 auto; width: 30px; height: 30px; display: grid; place-items: center; color: white; border-radius: 8px; background: var(--green-dark); font-size: 12px; font-weight: 900; }
.source-card strong, .source-card span { display: block; }
.source-card strong { color: var(--navy); font-size: 12px; }
.source-card span { margin: 4px 0 8px; color: var(--muted); font-size: 11px; line-height: 1.4; overflow-wrap: anywhere; }
.source-card .text-button { font-size: 11px; }

.workspace { min-width: 0; padding: 28px clamp(22px, 3vw, 48px) 46px; }
.workspace-topbar { display: flex; justify-content: space-between; gap: 24px; align-items: flex-start; }
.workspace-topbar h2 { margin-bottom: 5px; color: var(--navy); font-size: clamp(23px, 2.2vw, 32px); letter-spacing: -.035em; }
.workspace-topbar p { margin-bottom: 0; color: var(--muted); font-size: 13px; }
.workspace-actions svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.metrics-grid { margin: 24px 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.metric-card { min-width: 0; padding: 18px; border: 1px solid #dadada; border-radius: 16px; background: white; }
.metric-shortlist { text-align: left; }
.metric-shortlist:hover { border-color: var(--green); box-shadow: 0 6px 18px rgba(0,98,75,.09); }
.metric-shortlist[aria-pressed="true"] { border-color: var(--green-dark); background: var(--mint-light); }
.metric-card span { display: block; color: var(--muted); font-size: 11px; }
.metric-card .metric-label { color: #536177; font-weight: 800; }
.metric-card strong { display: block; margin: 6px 0 3px; color: var(--navy); font-size: 28px; letter-spacing: -.04em; }
.metric-card.metric-primary { color: white; border-color: var(--navy); background: var(--navy); }
.metric-card.metric-primary span, .metric-card.metric-primary strong { color: white; }
.metric-card.metric-primary .metric-label { color: var(--mint); }
.results-toolbar { margin-bottom: 12px; display: flex; justify-content: space-between; align-items: center; }
.view-tabs { padding: 3px; display: inline-flex; border-radius: 9px; background: #e8edf3; }
.view-tabs button { min-width: 84px; padding: 8px 14px; border: 0; border-radius: 7px; color: var(--muted); background: transparent; font-size: 12px; font-weight: 800; }
.view-tabs button[aria-selected="true"] { color: var(--navy); background: white; box-shadow: 0 2px 6px rgba(15,23,42,.1); }
.result-controls { display: flex; align-items: center; gap: 12px; }
.result-controls span { color: var(--muted); font-size: 12px; }
.result-controls select { width: auto; min-width: 180px; height: 36px; font-size: 12px; }
.pagination { display: inline-flex; align-items: center; gap: 7px; }
.pagination button { width: 32px; height: 32px; padding: 0; color: var(--navy); border: 1px solid #dadada; border-radius: 8px; background: white; font-size: 18px; line-height: 1; }
.pagination button:hover:not(:disabled) { color: white; border-color: var(--green); background: var(--green); }
.pagination button:disabled { color: #aab3bf; background: #f3f3f3; cursor: not-allowed; }
.pagination #page-label { min-width: 88px; text-align: center; color: var(--navy); font-weight: 700; }
.map-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 14px; }
.map-card, .map-results, .list-table-wrap { position: relative; border: 1px solid #dadada; border-radius: 16px; background: white; overflow: hidden; }
.map-topline { padding: 14px 17px; display: flex; justify-content: space-between; border-bottom: 1px solid var(--line); }
.map-topline strong, .map-topline span { display: block; }
.map-topline strong { color: var(--navy); font-size: 13px; }
.map-topline span { margin-top: 3px; color: var(--muted); font-size: 10px; }
.map-legend { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 10px; }
.map-legend i { width: 9px; height: 9px; border-radius: 50%; background: var(--orange); box-shadow: 0 0 0 4px rgba(255,123,0,.12); }
.opportunity-map { position: relative; display: block; width: 100%; min-height: 545px; overflow: hidden; touch-action: none; cursor: grab; background: #e7eaef; isolation: isolate; }
.opportunity-map.dragging { cursor: grabbing; }
.map-tiles, .map-markers { position: absolute; inset: 0; overflow: hidden; }
.map-tiles img { position: absolute; top: 0; left: 0; max-width: none; user-select: none; }
.map-markers { pointer-events: none; }
.map-marker { position: absolute; z-index: 2; width: 34px; height: 34px; padding: 0; transform: translate(-50%, -50%); pointer-events: auto; color: white; border: 3px solid white; border-radius: 50%; background: var(--navy); box-shadow: 0 4px 12px rgba(10,46,99,.34), 0 0 0 5px rgba(0,179,137,.13); font-size: 9px; font-weight: 800; }
.map-marker:hover, .map-marker:focus-visible { z-index: 4; background: var(--green); box-shadow: 0 6px 16px rgba(0,98,75,.32), 0 0 0 7px rgba(0,179,137,.18); }
.map-marker.large { width: 40px; height: 40px; background: var(--green-dark); }
.map-controls { position: absolute; z-index: 5; top: 14px; left: 14px; display: grid; overflow: hidden; border: 1px solid #dadada; border-radius: 8px; box-shadow: 0 4px 14px rgba(10,46,99,.14); }
.map-controls button { width: 38px; height: 38px; padding: 0; color: var(--navy); border: 0; border-bottom: 1px solid #dadada; background: white; font-size: 19px; font-weight: 700; }
.map-controls button:last-child { border-bottom: 0; font-size: 16px; }
.map-controls button:hover { color: white; background: var(--green); }
.map-attribution { position: absolute; z-index: 5; right: 8px; bottom: 7px; padding: 4px 7px; color: #4a5568; border-radius: 5px; background: rgba(255,255,255,.9); font-size: 9px; }
.map-attribution span { color: var(--green-dark); font-weight: 800; }
.map-attribution a { color: inherit; }
.map-results { padding: 17px; }
.map-results-heading { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 10px; }
.map-results-heading strong { display: block; color: var(--navy); }
.map-results-heading .text-button { font-size: 11px; }
.result-cards { display: grid; gap: 9px; }
.result-card { position: relative; width: 100%; padding: 13px; text-align: left; color: inherit; border: 1px solid var(--line); border-radius: 10px; background: white; }
.result-card:hover { border-color: var(--green); box-shadow: 0 6px 18px rgba(0,98,75,.09); }
.result-card-top { display: flex; justify-content: space-between; gap: 12px; }
.result-card h3 { margin-bottom: 4px; color: var(--navy); font-size: 13px; line-height: 1.3; }
.result-card p { margin: 0; color: var(--muted); font-size: 10px; }
.score-badge { flex: 0 0 auto; min-width: 40px; height: 40px; display: grid; place-items: center; color: var(--navy); border-radius: 50%; background: var(--mint-light); font-size: 13px; font-weight: 900; }
.result-card dl { margin: 11px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 7px; }
.result-card dt { color: var(--muted); font-size: 9px; }
.result-card dd { margin: 2px 0 0; color: var(--ink); font-size: 11px; font-weight: 800; }
.ownership-line { margin-top: 10px; padding-top: 9px; display: flex; align-items: center; gap: 7px; border-top: 1px solid #edf0f4; color: var(--muted); font-size: 10px; }
.ownership-line i { width: 7px; height: 7px; border-radius: 50%; background: #a2adba; }
.owner-units { color: #8b5a2b !important; font-weight: 700; }
.list-table-wrap { overflow-x: auto; }
.results-table { width: 100%; min-width: 760px; border-collapse: collapse; }
.results-table th { padding: 13px 15px; text-align: left; color: #718096; background: #f8fafc; border-bottom: 1px solid var(--line); font-size: 10px; text-transform: uppercase; letter-spacing: .055em; }
.results-table td { padding: 15px; border-bottom: 1px solid #edf1f5; color: #3c4b61; font-size: 12px; }
.results-table tbody tr { cursor: pointer; }
.results-table tbody tr:hover { background: #f7fbfa; }
.results-table tbody tr:last-child td { border-bottom: 0; }
.table-address strong, .table-address span { display: block; }
.table-address strong { color: var(--navy); font-size: 12px; }
.table-address span { margin-top: 3px; color: var(--muted); font-size: 10px; }
.table-score { width: 38px; height: 38px; display: grid; place-items: center; color: var(--navy); border-radius: 50%; background: var(--mint-light); font-weight: 900; }
.shortlist-mini { width: 32px; height: 32px; border: 1px solid var(--line); border-radius: 8px; color: #8190a3; background: white; }
.shortlist-mini.active { color: var(--green-dark); border-color: var(--mint); background: var(--mint-light); }
.empty-state { padding: 60px 20px; text-align: center; }
.empty-icon { width: 52px; height: 52px; margin: 0 auto 14px; display: grid; place-items: center; color: var(--muted); border-radius: 50%; background: #e9eef3; font-size: 18px; font-weight: 900; }
.empty-state h3 { color: var(--navy); }
.empty-state p { color: var(--muted); }

.drawer-backdrop { position: fixed; inset: 0; z-index: 30; background: rgba(8,36,79,.28); backdrop-filter: blur(2px); }
.detail-drawer { position: fixed; z-index: 40; top: 0; right: 0; width: min(480px, 100vw); height: 100vh; overflow-y: auto; transform: translateX(105%); transition: transform .25s ease; background: white; box-shadow: -12px 0 45px rgba(11,46,100,.2); }
.detail-drawer.open { transform: translateX(0); }
.drawer-header { position: sticky; top: 0; z-index: 2; padding: 18px 22px; display: flex; justify-content: space-between; gap: 16px; color: white; background: var(--navy); }
.drawer-header h2 { margin: 3px 0 0; font-size: 20px; line-height: 1.25; }
.drawer-header .eyebrow { color: var(--mint); }
.drawer-header .icon-button { color: white; border-color: rgba(255,255,255,.25); background: rgba(255,255,255,.08); }
.drawer-body { padding: 22px; }
.drawer-score-row { margin-bottom: 20px; display: grid; grid-template-columns: 76px 1fr; gap: 15px; align-items: center; }
.large-score { width: 76px; height: 76px; display: grid; place-items: center; color: white; border-radius: 50%; background: var(--green-dark); }
.large-score strong { display: block; font-size: 24px; line-height: 1; }
.large-score span { display: block; font-size: 9px; text-align: center; }
.drawer-score-row p { margin-bottom: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.detail-section { padding: 19px 0; border-top: 1px solid var(--line); }
.detail-section h3 { margin-bottom: 12px; color: var(--navy); font-size: 14px; }
.fact-grid { margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.fact-grid div { padding: 11px; border-radius: 8px; background: #f7f9fb; }
.fact-grid dt { color: var(--muted); font-size: 10px; }
.fact-grid dd { margin: 3px 0 0; color: var(--ink); font-size: 13px; font-weight: 800; overflow-wrap: anywhere; }
.source-note { margin: 12px 0 0; color: var(--muted); font-size: 10px; line-height: 1.45; }
.owner-gate { padding: 14px; border: 1px solid #ead8c7; border-radius: 10px; background: #fff9f3; }
.owner-gate-live, .owner-gate-ready { border-color: #bfe7dc; background: var(--mint-light); }
.owner-gate strong { display: block; color: var(--navy); }
.owner-gate p { margin: 6px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.ownership-purpose { margin-top: 12px; display: block; color: #43526a; font-size: 11px; font-weight: 800; }
.ownership-purpose span { display: block; margin-bottom: 6px; }
.ownership-facts { margin-top: 12px; }
.kn-basic-card { padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: #f7f9fb; }
.kn-basic-card.kn-basic-live { border-color: #bfe7dc; background: var(--mint-light); }
.kn-basic-card > p { margin: 8px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.kn-facts { margin-top: 11px; }
.kn-facts div { background: white; }
.compact-button { min-height: 36px; margin-top: 11px; padding: 7px 11px; font-size: 11px; }
.score-list { display: grid; gap: 8px; }
.score-line { display: grid; grid-template-columns: 1fr 90px 45px; gap: 8px; align-items: center; color: #4e5d72; font-size: 11px; }
.score-track { width: 90px; height: 6px; overflow: hidden; appearance: none; border: 0; border-radius: 99px; background: #e8edf2; }
.score-track::-webkit-progress-bar { border-radius: inherit; background: #e8edf2; }
.score-track::-webkit-progress-value { border-radius: inherit; background: var(--green); }
.score-track::-moz-progress-bar { border-radius: inherit; background: var(--green); }
.score-line b { text-align: right; color: var(--navy); }
.workflow-grid { display: grid; gap: 12px; }
.workflow-grid label { color: #43526a; font-size: 11px; font-weight: 800; }
.workflow-grid label span { display: block; margin-bottom: 6px; }
.save-state { color: var(--muted); font-size: 10px; }
.drawer-actions { padding: 17px 22px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; border-top: 1px solid var(--line); background: #f8fafc; }

.info-dialog { width: min(760px, calc(100vw - 32px)); padding: 28px; border: 0; border-radius: 16px; box-shadow: var(--shadow); }
.info-dialog::backdrop { background: rgba(8,36,79,.52); backdrop-filter: blur(4px); }
.info-dialog .dialog-close { position: absolute; top: 16px; right: 16px; }
.info-dialog h2 { color: var(--navy); font-size: 27px; }
.dialog-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.dialog-grid section { padding: 15px; border: 1px solid var(--line); border-radius: 11px; }
.dialog-grid h3 { margin: 10px 0 6px; color: var(--navy); font-size: 13px; }
.dialog-grid p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.status-pill { display: inline-block; padding: 4px 7px; border-radius: 999px; font-size: 9px; font-weight: 900; text-transform: uppercase; letter-spacing: .05em; }
.status-live { color: #075641; background: var(--mint-light); }
.status-blocked { color: #8b4500; background: #fff0df; }
.quality-detail { margin-top: 18px; padding: 15px; border-radius: 11px; background: #f5f7fa; }
.quality-detail h3 { margin-bottom: 10px; color: var(--navy); font-size: 13px; }
.quality-bars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.quality-bars div { padding: 10px; background: white; border-radius: 8px; }
.quality-bars span, .quality-bars strong { display: block; }
.quality-bars span { color: var(--muted); font-size: 9px; }
.quality-bars strong { margin-top: 4px; color: var(--navy); font-size: 17px; }
.toast { position: fixed; z-index: 90; right: 22px; bottom: 22px; max-width: min(390px, calc(100vw - 44px)); padding: 13px 16px; color: white; border-radius: 10px; background: var(--navy); box-shadow: var(--shadow); font-size: 12px; font-weight: 750; }
.toast[data-kind="error"] { background: #8e2525; }
.app-error { position: fixed; z-index: 95; left: 50%; top: 84px; width: min(620px, calc(100vw - 32px)); transform: translateX(-50%); padding: 14px 18px; color: #7a1d1d; border: 1px solid #efb7b7; border-radius: 10px; background: #fff1f1; box-shadow: var(--shadow); font-size: 12px; font-weight: 750; }

@media (max-width: 1120px) {
  .app-shell { grid-template-columns: 270px minmax(0, 1fr); }
  .map-layout { grid-template-columns: minmax(0, 1fr) 290px; }
  .metrics-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .app-shell { display: block; }
  .filters-panel { position: fixed; z-index: 60; inset: 0 auto 0 0; width: min(330px, 92vw); overflow-y: auto; transform: translateX(-105%); visibility: hidden; transition: transform .22s ease, visibility 0s linear .22s; box-shadow: var(--shadow); }
  .filters-panel.open { transform: translateX(0); visibility: visible; transition-delay: 0s; }
  .filter-close, .workspace-topbar .filters-trigger { display: inline-grid; }
  .map-layout { grid-template-columns: 1fr; }
  .map-results { padding-bottom: 20px; }
  .result-cards { grid-template-columns: repeat(2, 1fr); }
  .result-cards .result-card:nth-child(n+5) { display: none; }
}

@media (max-width: 640px) {
  .app-header { height: 62px; padding: 0 16px; }
  .product-name, .brand-divider, .source-chip { display: none; }
  .source-banner { padding: 10px 16px; align-items: flex-start; justify-content: space-between; }
  .source-banner div { display: block; }
  .source-banner span { display: block; margin-top: 3px; line-height: 1.35; }
  .source-banner .text-button { flex: 0 0 auto; font-size: 0; }
  .source-banner .text-button::after { content: "Detail"; font-size: 11px; }
  .workspace { padding: 20px 15px 32px; }
  .workspace-topbar { flex-wrap: wrap; }
  .workspace-actions { width: 100%; }
  .workspace-actions button { width: 100%; }
  .metrics-grid { grid-template-columns: 1fr 1fr; }
  .metric-card { padding: 14px; }
  .metric-card strong { font-size: 23px; }
  .results-toolbar { gap: 10px; align-items: flex-end; flex-wrap: wrap; }
  .result-controls { width: 100%; display: flex; flex-wrap: wrap; justify-content: space-between; text-align: left; }
  .result-controls > #result-count { flex: 1 0 100%; display: block; margin-bottom: 5px; }
  .result-controls select { min-width: 156px; }
  .pagination span { display: inline; margin-bottom: 0; }
  .view-tabs button { min-width: 66px; padding-inline: 10px; }
  .opportunity-map { min-height: 390px; }
  .map-topline { display: block; }
  .map-legend { margin-top: 9px; }
  .result-cards, .dialog-grid, .quality-bars { grid-template-columns: 1fr; }
  .drawer-score-row { grid-template-columns: 64px 1fr; }
  .large-score { width: 64px; height: 64px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
