/* =====================================================================
   Pothole Tracker, brand system v1.0
   Deep navy #10283C · Action blue #168CE5 · Slate #667684 · Soft #F2F6FA
   Success #00703C · Danger #D4351C · Inter
   ===================================================================== */
:root {
  --navy: #10283C;
  --navy-2: #163650;
  --navy-3: #0B1D2C;
  --blue: #168CE5;
  --blue-d: #0F74C2;
  --blue-l: #E6F2FC;
  --slate: #667684;
  --slate-l: #9AA6B1;
  --soft: #F2F6FA;
  --line: #DCE4EC;
  --white: #fff;
  --green: #00703C;
  --green-l: #E3F2EA;
  --red: #D4351C;
  --red-l: #FBE9E6;
  --amber: #B45309;
  --amber-l: #FDF1E3;
  --ink: #10283C;
  --text: #22384A;
  --radius: 12px;
  --radius-s: 8px;
  --shadow: 0 1px 2px rgba(16,40,60,.06), 0 6px 20px rgba(16,40,60,.07);
  --shadow-l: 0 20px 50px rgba(11,29,44,.25);
  --focus: 0 0 0 3px #FFDD00, 0 0 0 5px var(--navy);
  --header-h: 68px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.55; color: var(--text); background: var(--white); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue-d); text-underline-offset: 3px; }
a:hover { color: var(--navy); }
h1, h2, h3 { color: var(--ink); line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.015em; }
h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); font-weight: 800; }
h2 { font-size: 1.35rem; font-weight: 700; }
h3 { font-size: 1.05rem; font-weight: 700; }
p { margin: 0 0 1em; }
code { background: var(--soft); padding: .1em .4em; border-radius: 4px; font-size: .9em; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: #FFDD00; color: var(--navy); padding: 8px 14px; z-index: 9999; font-weight: 700; }
.skip:focus { left: 8px; }
.ic { width: 1.15em; height: 1.15em; flex: none; vertical-align: -0.2em; }
.muted { color: var(--slate); }
.small { font-size: .875rem; }
.center { text-align: center; }
.prewrap { white-space: pre-wrap; }
.row-gap { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.row-gap.center { justify-content: center; }
.hp { position: absolute; left: -9999px; }

.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.container.narrow { max-width: 820px; }

/* ---------- Buttons ---------- */
.btn { --bg: var(--white); --fg: var(--navy); --bd: var(--line);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 18px; min-height: 44px;
  font: 600 15px/1.2 var(--font); color: var(--fg); background: var(--bg); border: 1.5px solid var(--bd); border-radius: 999px;
  text-decoration: none; cursor: pointer; transition: background .15s, border-color .15s, transform .1s, box-shadow .15s; white-space: nowrap; }
.btn:hover { color: var(--fg); transform: translateY(-1px); }
.btn:active { transform: none; }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; }
.btn-primary { --bg: var(--blue); --fg: #fff; --bd: var(--blue); box-shadow: 0 4px 14px rgba(22,140,229,.3); }
.btn-primary:hover { --bg: var(--blue-d); --bd: var(--blue-d); }
.btn-outline { --bg: transparent; --fg: var(--navy); --bd: var(--navy); }
.btn-outline:hover { --bg: var(--navy); --fg: #fff; }
.btn-outline-light { --bg: transparent; --fg: #fff; --bd: rgba(255,255,255,.55); }
.btn-outline-light:hover { --bg: rgba(255,255,255,.12); --bd: #fff; }
.btn-light { --bg: #fff; --fg: var(--navy); --bd: #fff; }
.btn-ghost { --bg: transparent; --bd: transparent; --fg: var(--navy); }
.btn-ghost:hover { --bg: var(--soft); }
.btn-danger { --bg: var(--red); --fg: #fff; --bd: var(--red); }
.btn-danger-ghost { --bg: transparent; --fg: var(--red); --bd: transparent; }
.btn-danger-ghost:hover { --bg: var(--red-l); }
.btn-sm { padding: 7px 14px; min-height: 36px; font-size: 14px; }
.btn-lg { padding: 14px 24px; min-height: 52px; font-size: 16px; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 1000; background: rgba(255,255,255,.96); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); gap: 16px; }
.brand img { height: 38px; width: auto; }
.site-nav { display: flex; align-items: center; gap: 4px; }
.site-nav a:not(.btn) { padding: 8px 12px; border-radius: 8px; color: var(--navy); font-weight: 600; font-size: 15px; text-decoration: none; }
.site-nav a:not(.btn):hover { background: var(--soft); }
.site-nav a.is-active { color: var(--blue-d); }
.site-nav .btn { margin-left: 8px; }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; color: var(--navy); cursor: pointer; }
.nav-toggle .ic { width: 26px; height: 26px; }

/* ---------- Alerts / badges ---------- */
.alert { padding: 14px 16px; border-radius: var(--radius-s); border-left: 5px solid; margin: 16px 0; background: var(--soft); font-size: 15px; }
.alert ul { margin: 6px 0 0; padding-left: 20px; }
.alert-success { border-color: var(--green); background: var(--green-l); }
.alert-error { border-color: var(--red); background: var(--red-l); }
.alert-info { border-color: var(--blue); background: var(--blue-l); }
.alert-warning { border-color: var(--amber); background: var(--amber-l); }
.error-summary h2 { font-size: 1.1rem; margin-bottom: 4px; }
.error-summary a { color: var(--red); font-weight: 600; }
.badge { --c: var(--slate); display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: 13px; font-weight: 600;
  color: var(--c); background: color-mix(in srgb, var(--c) 11%, white); border: 1px solid color-mix(in srgb, var(--c) 28%, white); white-space: nowrap; line-height: 1.3; }
.badge .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c); }
.tag { display: inline-block; padding: 2px 8px; border-radius: 6px; background: var(--blue-l); color: var(--blue-d); font-size: 12px; font-weight: 700; letter-spacing: .02em; vertical-align: middle; }
.sev { display: inline-block; padding: 3px 10px; border-radius: 6px; font-size: 13px; font-weight: 700; }
.sev-1 { background: #EEF2F5; color: #4B5B68; }
.sev-2 { background: #E6F2FC; color: #0F5E9C; }
.sev-3 { background: #FDF1E3; color: #8A4006; }
.sev-4 { background: #FDE7D8; color: #9A3412; }
.sev-5 { background: var(--red-l); color: #A3240F; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #8CC8F5; margin: 0 0 14px; }
.eyebrow.dark { color: var(--blue-d); }

/* ---------- Hero ---------- */
.hero { position: relative; background: radial-gradient(1200px 500px at 85% 20%, #1B4466 0%, transparent 60%), linear-gradient(160deg, var(--navy) 0%, var(--navy-3) 100%); color: #fff; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: 0; background-image: linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px); background-size: 40px 40px; pointer-events: none; }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; padding-top: 56px; padding-bottom: 64px; }
.hero-title { font-size: clamp(2.6rem, 6.4vw, 4.6rem); font-weight: 900; line-height: .98; letter-spacing: -.03em; text-transform: uppercase; color: #fff; margin: 0 0 20px; }
.hero-title span { display: block; }
.hero-title .accent { color: var(--blue); }
.lead { font-size: 1.12rem; color: #D3E0EA; max-width: 560px; margin-bottom: 26px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 26px; }
.hero-search { display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 999px; padding: 6px 6px 6px 18px; max-width: 520px; box-shadow: var(--shadow-l); }
.hero-search .ic { color: var(--slate); }
.hero-search input { flex: 1; border: 0; font: 500 16px var(--font); color: var(--navy); min-width: 0; outline: none; background: transparent; }
.hero-visual { position: relative; }
.hero-photo { position: relative; border-radius: 22px; overflow: hidden; box-shadow: var(--shadow-l); aspect-ratio: 840/880; max-width: 460px; margin-left: auto; border: 1px solid rgba(255,255,255,.12); }
.hero-photo img { width: 100%; height: 100%; object-fit: cover; }
.hero-chip { position: absolute; display: inline-flex; align-items: center; gap: 8px; background: rgba(16,40,60,.86); color: #fff; padding: 8px 14px; border-radius: 999px; font-size: 13px; font-weight: 600; backdrop-filter: blur(6px); }
.chip-top { top: 16px; left: 16px; }
.pulse { width: 9px; height: 9px; border-radius: 50%; background: #39D98A; box-shadow: 0 0 0 0 rgba(57,217,138,.7); animation: pulse 1.8s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(57,217,138,0); } 100% { box-shadow: 0 0 0 0 rgba(57,217,138,0); } }
.hero-card { position: absolute; left: 16px; right: 16px; bottom: 16px; display: flex; gap: 12px; align-items: center; background: #fff; color: var(--navy); padding: 14px 16px; border-radius: 14px; box-shadow: var(--shadow); }
.hero-card strong { display: block; font-size: 15px; }
.hero-card small { color: var(--slate); }
.hc-icon { width: 40px; height: 40px; border-radius: 50%; background: var(--green-l); color: var(--green); display: grid; place-items: center; }

/* ---------- Stats ---------- */
.stats-band { background: var(--blue); color: #fff; padding: 26px 0 16px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat strong { display: block; font-size: clamp(1.8rem, 3.5vw, 2.4rem); font-weight: 800; line-height: 1; letter-spacing: -.02em; }
.stat span { font-size: 14px; font-weight: 500; opacity: .92; }
.freshness { display: flex; align-items: center; gap: 6px; font-size: 13px; opacity: .9; margin: 14px auto 0; }
.page-map .freshness, .ms-head .freshness { opacity: 1; color: var(--slate); margin: 4px 0 0; }

/* ---------- Sections ---------- */
.section { padding: 64px 0; }
.section-soft { background: var(--soft); }
.section-head { margin-bottom: 28px; max-width: 720px; }
.section-head.center { margin-left: auto; margin-right: auto; }
.section-head h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); font-weight: 800; }
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; counter-reset: s; }
.steps li { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; position: relative; }
.steps li:not(:last-child)::after { content: ""; position: absolute; right: -16px; top: 52px; width: 12px; height: 12px; border-top: 3px solid var(--blue); border-right: 3px solid var(--blue); transform: rotate(45deg); }
.step-icon { width: 60px; height: 60px; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; margin-bottom: 16px; box-shadow: 0 0 0 6px var(--blue-l); }
.step-icon .ic { width: 28px; height: 28px; }
.steps .num { color: var(--blue); margin-right: 4px; }
.steps p { color: var(--slate); margin: 0; font-size: 15px; }

.live-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 20px; }
.live-map-card, .recent-card, .card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card { padding: 22px; margin-bottom: 18px; }
.card h2 { font-size: 1.15rem; display: flex; align-items: center; gap: 8px; }
.live-map-card { overflow: hidden; display: flex; flex-direction: column; }
.card-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.card-head h2 { margin: 0; font-size: 1.1rem; display: flex; align-items: center; gap: 8px; }
.link-arrow { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 14px; text-decoration: none; }
.map { width: 100%; background: #E8EEF3; z-index: 1; }
.map-home { flex: 1; min-height: 420px; }
.recent-list { list-style: none; margin: 0; padding: 6px; }
.recent-list a { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 10px; text-decoration: none; color: inherit; }
.recent-list a:hover { background: var(--soft); }
.thumb { width: 58px; height: 58px; flex: none; border-radius: 10px; overflow: hidden; background: var(--soft); display: grid; place-items: center; color: var(--slate-l); }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.recent-list .meta { display: flex; flex-direction: column; gap: 3px; align-items: flex-start; min-width: 0; }
.recent-list strong { color: var(--navy); font-size: 15px; }
.recent-list small { color: var(--slate); font-size: 13px; }
.empty { text-align: center; padding: 34px 20px; color: var(--slate); }
.empty > .ic { width: 42px; height: 42px; color: var(--slate-l); margin: 0 auto 10px; display: block; }
.empty.big { padding: 60px 20px; }

.benefits { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; background: var(--navy); border-radius: 18px; padding: 10px; }
.benefit { display: flex; gap: 16px; padding: 22px; color: #D3E0EA; }
.benefit + .benefit { border-left: 1px solid rgba(255,255,255,.12); }
.benefit h3 { color: #fff; margin-bottom: 4px; }
.benefit p { margin: 0; font-size: 15px; }
.b-icon { width: 56px; height: 56px; flex: none; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; }
.b-icon .ic { width: 26px; height: 26px; }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.table { width: 100%; border-collapse: collapse; font-size: 15px; }
.table th, .table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { background: var(--soft); font-size: 13px; font-weight: 700; color: var(--slate); text-transform: uppercase; letter-spacing: .04em; white-space: nowrap; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: #FAFCFE; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }
.table a { font-weight: 600; }

.cta-band { background: linear-gradient(110deg, var(--blue) 0%, var(--blue-d) 100%); color: #fff; padding: 44px 0; }
.cta-inner { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.cta-band h2 { color: #fff; font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 800; margin: 0 0 4px; }
.cta-band p { margin: 0; letter-spacing: .18em; text-transform: uppercase; font-size: 13px; font-weight: 600; opacity: .92; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-3); color: #B9C7D3; padding: 48px 0 24px; font-size: 15px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; padding-bottom: 28px; border-bottom: 1px solid rgba(255,255,255,.1); }
.footer-logo { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.footer-logo img { width: 40px; height: auto; }
.footer-logo strong { display: block; color: #fff; font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.footer-logo strong span { color: var(--blue); }
.footer-logo small { color: var(--slate-l); }
.site-footer h3 { color: #fff; font-size: 14px; text-transform: uppercase; letter-spacing: .08em; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: #DCE6EE; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-legal { padding-top: 20px; font-size: 13px; }
.footer-legal strong { color: #fff; }
.footer-legal .muted { color: #7E8F9D; }

/* ---------- Page head ---------- */
.page-head { background: var(--soft); border-bottom: 1px solid var(--line); padding: 40px 0 30px; margin-bottom: 28px; }
.page-head h1 { margin-bottom: 8px; }
.lead-dark { font-size: 1.08rem; color: var(--slate); margin: 0; }

/* ---------- Forms ---------- */
.field { display: block; margin-bottom: 16px; }
.field > span, .label { display: block; font-weight: 600; color: var(--navy); margin-bottom: 6px; font-size: 15px; }
.opt { font-weight: 500; color: var(--slate); font-size: 13px; }
.field small { display: block; color: var(--slate); margin-top: 4px; }
input[type=text], input[type=email], input[type=password], input[type=search], input:not([type]), input[type=number], input[type=url], select, textarea {
  width: 100%; padding: 11px 14px; font: 16px var(--font); color: var(--navy); background: #fff; border: 1.5px solid #B9C6D2; border-radius: var(--radius-s); min-height: 46px; transition: border-color .15s; }
textarea { min-height: 96px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--blue); outline: none; box-shadow: 0 0 0 3px rgba(22,140,229,.2); }
select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%2310283C' stroke-width='2'%3E%3Cpath d='m1 1 5 5 5-5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px; }
.check { display: flex; gap: 10px; align-items: flex-start; margin: 10px 0; cursor: pointer; font-size: 15px; }
.check input { width: 20px; height: 20px; margin: 1px 0 0; flex: none; accent-color: var(--blue); }
.field-error { color: var(--red); font-weight: 600; font-size: 14px; margin: 4px 0 8px; display: block; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.grid-2 .full { grid-column: 1 / -1; }
.input-row { display: flex; gap: 10px; }
.input-row input { flex: 1; text-transform: uppercase; font-weight: 600; letter-spacing: .06em; }

/* ---------- Report wizard ---------- */
.wizard-steps { list-style: none; display: flex; gap: 8px; padding: 0; margin: 0 0 18px; counter-reset: w; }
.wizard-steps li { flex: 1; display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 10px; background: var(--soft); color: var(--slate); font-weight: 600; font-size: 14px; border: 1.5px solid transparent; }
.wizard-steps li span { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: #fff; border: 1.5px solid var(--line); font-size: 13px; }
.wizard-steps li.is-current { background: var(--blue-l); color: var(--navy); border-color: var(--blue); }
.wizard-steps li.is-current span { background: var(--blue); color: #fff; border-color: var(--blue); }
.wizard-steps li.is-done span { background: var(--green); color: #fff; border-color: var(--green); }
.report-form fieldset { border: 1px solid var(--line); min-width: 0; }
.report-form legend { float: left; width: 100%; padding: 0; font-size: 1.25rem; font-weight: 800; color: var(--navy); margin-bottom: 8px; display: flex; align-items: center; gap: 10px; }
.report-form legend + * { clear: both; }
.step-num { width: 30px; height: 30px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; font-size: 15px; }
.js .step[hidden] { display: none; }
.step-actions { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }

.dropzone { position: relative; border: 2px dashed #B9C6D2; border-radius: var(--radius); background: var(--soft); transition: border-color .15s, background .15s; }
.dropzone.is-over { border-color: var(--blue); background: var(--blue-l); }
.dropzone input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; }
.dropzone input[type=file]:focus-visible + .dz-label { box-shadow: var(--focus); }
.dz-label { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 38px 20px; cursor: pointer; text-align: center; border-radius: var(--radius); }
.dz-label strong { color: var(--navy); font-size: 1.05rem; }
.dz-label small { color: var(--slate); }
.dz-icon { width: 64px; height: 64px; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; margin-bottom: 6px; box-shadow: 0 0 0 7px rgba(22,140,229,.15); }
.dz-icon .ic { width: 30px; height: 30px; }
.dz-preview { padding: 12px; display: flex; flex-direction: column; align-items: center; gap: 10px; }
.dz-preview img { max-height: 340px; width: auto; border-radius: 10px; box-shadow: var(--shadow); }
.dz-progress { position: absolute; left: 12px; right: 12px; bottom: 10px; height: 5px; background: rgba(16,40,60,.1); border-radius: 4px; overflow: hidden; }
.dz-progress span { display: block; height: 100%; width: 0; background: var(--blue); transition: width .2s; }
.hint { display: flex; gap: 6px; align-items: center; color: var(--green); font-weight: 600; margin-top: 10px; }

.ai-panel { margin-top: 16px; border: 1px solid #CFE3F6; background: linear-gradient(180deg, #F4F9FE, #fff); border-radius: var(--radius); padding: 14px 16px; }
.ai-head { display: flex; align-items: center; gap: 8px; color: var(--navy); margin-bottom: 8px; }
.ai-head .ic { color: var(--blue); }
.ai-body { font-size: 15px; }
.ai-body .ai-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 10px 0; }
.ai-body .ai-grid div { background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; }
.ai-body .ai-grid small { display: block; color: var(--slate); font-size: 12px; }
.ai-body .ai-grid b { color: var(--navy); }
.ai-warn { color: var(--amber); font-weight: 600; }
.spinner { display: inline-block; width: 16px; height: 16px; border: 2.5px solid var(--blue-l); border-top-color: var(--blue); border-radius: 50%; animation: spin .7s linear infinite; vertical-align: -3px; margin-right: 6px; }
@keyframes spin { to { transform: rotate(360deg); } }

.map-tools { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; align-items: center; }
.search-box { position: relative; flex: 1; min-width: 220px; display: flex; align-items: center; }
.search-box > .ic { position: absolute; left: 12px; color: var(--slate); pointer-events: none; }
.search-box input { padding-left: 38px; border-radius: 999px; min-height: 42px; }
.search-results { position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 1200; list-style: none; margin: 0; padding: 6px; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-l); max-height: 280px; overflow: auto; }
.search-results li button { width: 100%; text-align: left; background: none; border: 0; padding: 10px 12px; border-radius: 8px; font: 14px var(--font); color: var(--navy); cursor: pointer; }
.search-results li button:hover, .search-results li button:focus { background: var(--soft); }
.search-results .none { padding: 10px 12px; color: var(--slate); font-size: 14px; }
.map-report { height: 420px; border-radius: var(--radius); border: 1px solid var(--line); }
.location-card { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; }
.loc-row { display: flex; gap: 10px; align-items: flex-start; background: var(--soft); border-radius: 10px; padding: 12px; }
.loc-row strong { display: block; color: var(--navy); font-size: 15px; }
.loc-row small { color: var(--slate); font-size: 13px; display: block; }
.loc-icon { width: 34px; height: 34px; flex: none; border-radius: 50%; background: #fff; color: var(--blue); display: grid; place-items: center; }
.dupes { margin-top: 14px; border: 1.5px solid #F5C99A; background: var(--amber-l); border-radius: var(--radius); padding: 14px 16px; }
.dupes h3 { color: #7A3A05; display: flex; gap: 8px; align-items: center; margin-bottom: 6px; }
.dupes ul { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 8px; }
.dupes li { display: flex; gap: 10px; align-items: center; background: #fff; border-radius: 10px; padding: 8px 10px; }
.dupes li .thumb { width: 46px; height: 46px; }
.dupes li .d-meta { flex: 1; min-width: 0; font-size: 14px; }
.dupes li .d-meta strong { display: block; color: var(--navy); }

.chip-group { display: flex; flex-wrap: wrap; gap: 8px; }
.chip input, .sev-opt input, .seg input { position: absolute; opacity: 0; pointer-events: none; }
.chip span { display: inline-block; padding: 9px 14px; border: 1.5px solid #B9C6D2; border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--navy); cursor: pointer; background: #fff; transition: all .12s; }
.chip input:checked + span { background: var(--navy); border-color: var(--navy); color: #fff; }
.chip input:focus-visible + span, .sev-opt input:focus-visible + span, .seg input:focus-visible + span { box-shadow: var(--focus); }
.severity-picker { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.sev-opt span { display: flex; flex-direction: column; gap: 2px; height: 100%; padding: 12px 10px; border: 1.5px solid #B9C6D2; border-radius: 12px; cursor: pointer; background: #fff; transition: all .12s; }
.sev-opt strong { font-size: 1.4rem; line-height: 1; color: var(--navy); }
.sev-opt b { font-size: 14px; color: var(--navy); }
.sev-opt small { font-size: 12px; color: var(--slate); line-height: 1.3; }
.sev-opt input:checked + span { border-color: var(--blue); background: var(--blue-l); box-shadow: inset 0 0 0 1px var(--blue); }
.sev-opt.sev-4 input:checked + span, .sev-opt.sev-5 input:checked + span { border-color: var(--red); background: var(--red-l); box-shadow: inset 0 0 0 1px var(--red); }
.sub-card { background: var(--soft); border-radius: var(--radius); padding: 16px 18px 6px; margin: 6px 0 14px; }
.sub-card h3 { display: flex; gap: 8px; align-items: center; }
.check.accept { background: #fff; border: 1.5px solid var(--line); border-radius: 10px; padding: 12px 14px; }

/* ---------- Map page ---------- */
.page-map .site-footer { display: none; }
.map-layout { display: grid; grid-template-columns: 330px 1fr; height: calc(100vh - var(--header-h)); height: calc(100dvh - var(--header-h)); }
.map-sidebar { border-right: 1px solid var(--line); background: #fff; overflow-y: auto; padding: 18px; display: flex; flex-direction: column; gap: 14px; }
.ms-head h1 { font-size: 1.5rem; margin: 0; }
.filters fieldset { border: 0; padding: 0; margin: 0 0 14px; }
.filters legend { font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--slate); margin-bottom: 6px; }
.status-check { margin: 6px 0; align-items: center; font-size: 14px; }
.status-check .swatch { width: 12px; height: 12px; border-radius: 50%; background: var(--c); flex: none; }
.status-check .count { margin-left: auto; color: var(--slate); font-size: 13px; font-variant-numeric: tabular-nums; }
.seg { display: flex; background: var(--soft); border-radius: 10px; padding: 3px; }
.seg label { flex: 1; }
.seg span { display: block; text-align: center; padding: 7px 4px; border-radius: 8px; font-size: 13px; font-weight: 600; color: var(--slate); cursor: pointer; }
.seg input:checked + span { background: #fff; color: var(--navy); box-shadow: 0 1px 3px rgba(16,40,60,.15); }
.ms-foot { margin-top: auto; display: flex; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); padding-top: 12px; }
.ms-foot p { margin: 0; }
.map-main { position: relative; display: flex; flex-direction: column; min-width: 0; }
.map-toolbar { display: flex; gap: 8px; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--line); background: #fff; }
.map-toolbar .tabs { margin-right: auto; }
.tabs { display: inline-flex; background: var(--soft); border-radius: 999px; padding: 3px; }
.tab { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; padding: 7px 14px; border-radius: 999px; font: 600 14px var(--font); color: var(--slate); cursor: pointer; }
.tab.is-active { background: #fff; color: var(--navy); box-shadow: 0 1px 3px rgba(16,40,60,.15); }
.filters-toggle { display: none; }
.map-full { flex: 1; }
.list-view { flex: 1; overflow: auto; padding: 14px; background: var(--soft); }
.map-legend { position: absolute; left: 12px; bottom: 24px; z-index: 500; background: rgba(255,255,255,.95); border-radius: 10px; padding: 8px 12px; display: flex; gap: 12px; font-size: 12px; font-weight: 600; color: var(--navy); box-shadow: var(--shadow); }
.map-legend span { display: inline-flex; align-items: center; gap: 5px; }
.lg { width: 10px; height: 10px; border-radius: 50%; background: var(--c); display: inline-block; }

/* Leaflet markers and popups */
.pt-marker { --c: var(--blue); width: 30px; height: 38px; position: relative; }
.pt-marker::before { content: ""; position: absolute; left: 1px; top: 0; width: 28px; height: 28px; border-radius: 50% 50% 50% 0; background: var(--c); transform: rotate(-45deg); box-shadow: 0 2px 6px rgba(0,0,0,.35); border: 2px solid #fff; }
.pt-marker b { position: absolute; left: 0; top: 4px; width: 30px; text-align: center; color: #fff; font: 800 12px var(--font); }
.pt-marker.is-new::after { content: ""; position: absolute; left: 3px; top: 2px; width: 24px; height: 24px; border-radius: 50%; animation: pulse 1.8s infinite; box-shadow: 0 0 0 0 rgba(22,140,229,.6); }
.pin-drop { --c: var(--red); }
.pt-cluster { background: rgba(22,140,229,.22); border-radius: 50%; }
.pt-cluster div { width: 36px; height: 36px; margin: 5px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; font: 700 13px var(--font); border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.3); }
.pt-cluster.big div { background: var(--blue); }
.leaflet-container { font-family: var(--font); }
.leaflet-popup-content-wrapper { border-radius: 12px; padding: 0; overflow: hidden; }
.leaflet-popup-content { margin: 0; width: 250px !important; }
.pop img { width: 100%; height: 130px; object-fit: cover; }
.pop-body { padding: 12px 14px; }
.pop-body strong { display: block; color: var(--navy); font-size: 15px; margin-bottom: 2px; }
.pop-body small { display: block; color: var(--slate); margin-bottom: 8px; }
.pop-body .row-gap { gap: 6px; margin-bottom: 8px; }
.pop-body a.btn { color: #fff; }
.leaflet-control-locate a { display: grid !important; place-items: center; }

/* ---------- Report view ---------- */
.crumbs { display: flex; align-items: center; gap: 6px; font-size: 14px; color: var(--slate); margin: 22px 0 14px; flex-wrap: wrap; }
.crumbs .ic { width: 14px; height: 14px; }
.view-grid { display: grid; grid-template-columns: 1fr 360px; gap: 24px; margin-bottom: 48px; align-items: start; }
.view-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; margin-bottom: 14px; }
.view-head h1 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); margin-bottom: 4px; }
.road-ref { display: inline-block; background: #00703C; color: #fff; font-size: .55em; padding: 3px 9px; border-radius: 5px; vertical-align: middle; font-weight: 800; }
.view-photo { margin: 0 0 18px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--soft); }
.view-photo img { width: 100%; max-height: 520px; object-fit: contain; background: #0B1D2C; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin: 0 0 20px; }
.facts div { background: #fff; padding: 12px 14px; }
.facts dt { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--slate); font-weight: 700; margin-bottom: 4px; }
.facts dd { margin: 0; font-weight: 600; color: var(--navy); font-size: 15px; }
.block { margin-bottom: 22px; }
.block h2 { font-size: 1.15rem; display: flex; align-items: center; gap: 8px; }
.ai-note { background: #F4F9FE; border: 1px solid #CFE3F6; border-radius: var(--radius); padding: 16px 18px; }
.ai-note .ic { color: var(--blue); }
.timeline { list-style: none; margin: 0 0 8px; padding: 0 0 0 22px; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 18px 8px; }
.timeline li::before { content: ""; position: absolute; left: -31px; top: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--c); border: 3px solid #fff; box-shadow: 0 0 0 1px var(--line); }
.timeline strong { display: block; color: var(--navy); }
.timeline time { font-size: 13px; color: var(--slate); }
.timeline p { margin: 6px 0 0; background: var(--soft); padding: 10px 12px; border-radius: 8px; font-size: 15px; }
.map-mini { height: 240px; border-radius: 10px; }
.coords { margin: 10px 0 0; }
.confirm-card { background: var(--navy); border-color: var(--navy); color: #D3E0EA; }
.confirm-card h2 { color: #fff; }
.confirm-count { margin: 10px 0 0; font-size: 14px; text-align: center; }
.confirm-count strong { color: #fff; font-size: 18px; }
.share-row { display: flex; gap: 8px; flex-wrap: wrap; }
.mini-list { list-style: none; margin: 0; padding: 0; }
.mini-list li + li { border-top: 1px solid var(--line); }
.mini-list a { display: block; padding: 10px 2px; text-decoration: none; }
.mini-list strong { display: block; color: var(--navy); font-size: 15px; }
.mini-list small { color: var(--slate); }

.success-panel { display: flex; gap: 20px; background: linear-gradient(135deg, var(--green) 0%, #00552E 100%); color: #fff; border-radius: 18px; padding: 28px; margin-top: 26px; box-shadow: var(--shadow); }
.success-panel h1 { color: #fff; margin-bottom: 6px; }
.sp-icon { width: 60px; height: 60px; flex: none; border-radius: 50%; background: #fff; color: var(--green); display: grid; place-items: center; }
.sp-icon .ic { width: 32px; height: 32px; stroke-width: 3; }
.ref-box { display: inline-flex; align-items: center; gap: 14px; background: rgba(255,255,255,.14); border: 1.5px solid rgba(255,255,255,.35); border-radius: 12px; padding: 10px 12px 10px 18px; margin-bottom: 12px; }
.ref-box strong { font-size: 1.7rem; letter-spacing: .08em; font-weight: 800; }

.status-guide { margin: 0; }
.status-guide div { display: grid; grid-template-columns: 260px 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); align-items: center; }
.status-guide div:last-child { border-bottom: 0; }
.status-guide dd { margin: 0; font-size: 15px; }
.track-form .field { margin-bottom: 6px; }
.prose h2 { margin-top: 1.4em; }
.prose h2:first-child { margin-top: 0; }
.prose li { margin-bottom: 6px; }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px); background: var(--navy); color: #fff; padding: 12px 18px; border-radius: 10px; font-weight: 600; font-size: 14px; box-shadow: var(--shadow-l); opacity: 0; transition: all .2s; z-index: 5000; pointer-events: none; }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- Installer ---------- */
.install { background: var(--soft); }
.install-wrap { max-width: 760px; margin: 0 auto; padding: 36px 20px; }
.install-head { text-align: center; margin-bottom: 20px; }
.install-head img { margin: 0 auto 14px; }
.install h2 { margin-top: 10px; font-size: 1.15rem; }
.install form h2 { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); }
.install form h2:first-of-type { margin-top: 0; padding-top: 0; border: 0; }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.checks li { display: flex; gap: 10px; align-items: flex-start; padding: 8px 10px; border-radius: 8px; background: var(--soft); font-size: 15px; }
.checks .mark { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 12px; flex: none; }
.checks .ok .mark { background: var(--green); } .checks .bad .mark { background: var(--red); } .checks .warn .mark { background: var(--amber); }
.steps-list li { margin-bottom: 8px; }
.code { background: var(--navy-3); color: #DCE6EE; padding: 14px; border-radius: 8px; overflow: auto; font-size: 13px; }
.install-foot { text-align: center; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; gap: 30px; padding-top: 40px; }
  .hero-photo { max-width: 100%; aspect-ratio: 16/10; margin: 0; }
  .live-grid, .view-grid { grid-template-columns: 1fr; }
  .benefits { grid-template-columns: 1fr; }
  .benefit + .benefit { border-left: 0; border-top: 1px solid rgba(255,255,255,.12); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .site-nav { position: absolute; top: var(--header-h); left: 0; right: 0; background: #fff; border-bottom: 1px solid var(--line); flex-direction: column; align-items: stretch; padding: 10px 16px 16px; gap: 2px; display: none; box-shadow: var(--shadow); }
  .site-nav.is-open { display: flex; }
  .site-nav .btn { margin: 8px 0 0; }
  .map-layout { grid-template-columns: 1fr; }
  .map-sidebar { position: fixed; inset: var(--header-h) 0 0 0; z-index: 1100; transform: translateX(-100%); transition: transform .2s; }
  .map-sidebar.is-open { transform: none; }
  .filters-toggle { display: inline-flex; }
  #locate-me span { display: none; }
}
@media (max-width: 700px) {
  .container { padding: 0 16px; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 18px; }
  .steps { grid-template-columns: 1fr; }
  .steps li:not(:last-child)::after { display: none; }
  .grid-2, .location-card { grid-template-columns: 1fr; }
  .severity-picker { grid-template-columns: 1fr; }
  .sev-opt span { flex-direction: row; align-items: center; gap: 10px; padding: 10px 12px; }
  .sev-opt small { margin-left: auto; text-align: right; }
  .facts { grid-template-columns: 1fr 1fr; }
  .ai-body .ai-grid { grid-template-columns: 1fr; }
  .wizard-steps li { font-size: 13px; padding: 8px; justify-content: center; }
  .success-panel { flex-direction: column; padding: 22px; }
  .status-guide div { grid-template-columns: 1fr; gap: 6px; }
  .map-report { height: 340px; }
  .section { padding: 44px 0; }
  .map-legend { display: none; }
  .hero-search { flex-wrap: nowrap; }
  .map-toolbar .btn-primary span { display: none; }
  .view-head { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }
@media print { .site-header, .site-footer, .confirm-card, .share-row { display: none !important; } }

/* Polish */
.hero-search input, .hero-search input:focus { border: 0; box-shadow: none; min-height: 40px; padding: 0; }
.sev, .badge { white-space: nowrap; }
.field > span small.opt, .field > span .opt { display: inline; margin-left: 4px; }
