:root {
  --ink: #111820;
  --navy: #213146;
  --navy-2: #162437;
  --red: #ed2632;
  --red-soft: #fff0f1;
  --blue-soft: #edf6fa;
  --mint-soft: #eff8f3;
  --paper: #fbfaf7;
  --white: #fff;
  --muted: #687383;
  --line: #dfe4e8;
  --shadow: 0 24px 64px rgba(24, 38, 57, 0.09);
  --radius: 24px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 84% 10%, rgba(224, 240, 247, 0.7), transparent 26rem),
    var(--paper);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, input, select { font: inherit; }
button, select { cursor: pointer; }
.shell { width: min(1420px, calc(100% - 64px)); margin-inline: auto; }
.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; }

.app-header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid rgba(24, 39, 56, 0.1);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
}

.header-inner {
  width: min(1500px, calc(100% - 48px));
  min-height: 92px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand-logo { width: 275px; height: 68px; object-fit: contain; object-position: left center; user-select: none; }
.header-rule { width: 1px; height: 38px; background: var(--line); }
.header-copy { display: grid; gap: 4px; }
.header-copy .eyebrow { color: var(--red); font-size: 0.66rem; letter-spacing: 0.18em; font-weight: 800; text-transform: uppercase; }
.header-copy strong { font-size: 0.98rem; font-weight: 680; }
.privacy-pill {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 15px;
  border-radius: 999px;
  color: #225f43;
  background: var(--mint-soft);
  font-size: 0.78rem;
  font-weight: 700;
}
.privacy-pill span { color: #2fb477; font-size: 0.65rem; }
.purchase-session { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.purchase-session .privacy-pill { margin-left: 0; }
.purchase-user { max-width: 230px; overflow: hidden; color: var(--muted); font-size: .72rem; text-overflow: ellipsis; white-space: nowrap; }
.logout-button { min-height: 38px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; color: var(--navy); background: white; font-size: .72rem; font-weight: 750; }
.logout-button:hover { border-color: var(--red); color: var(--red); }
.logout-button:disabled { opacity: .55; cursor: wait; }
.logout-error { max-width: 180px; color: #b42318; font-size: .72rem; line-height: 1.4; }

.hero {
  min-height: 430px;
  padding-block: 92px 72px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 72px;
  align-items: end;
}

.section-kicker, .panel-number {
  display: inline-block;
  color: var(--red);
  font-size: 0.72rem;
  line-height: 1;
  letter-spacing: 0.2em;
  font-weight: 800;
}

.hero h1 {
  max-width: 950px;
  margin: 25px 0 28px;
  font-size: clamp(3.6rem, 6.2vw, 6.9rem);
  line-height: 0.94;
  letter-spacing: -0.062em;
  font-weight: 480;
}
.hero h1 span { color: var(--red); }
.hero-copy p { max-width: 720px; margin: 0; color: var(--muted); font-size: 1.16rem; line-height: 1.75; }

.hero-metric {
  align-self: stretch;
  display: grid;
  align-content: end;
  padding: 32px;
  border-radius: var(--radius);
  background: var(--navy);
  color: var(--white);
  box-shadow: var(--shadow);
}
.hero-metric strong { margin-top: 4px; font-size: 2.9rem; line-height: 1; letter-spacing: -0.04em; }
.hero-metric span { margin-top: 7px; color: #cbd5e1; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.12em; }
.metric-divider { height: 1px; margin: 25px 0 21px; background: rgba(255,255,255,.16); }

.search-section { margin-bottom: 68px; }
.search-panel {
  padding: 34px;
  border-radius: 30px;
  color: white;
  background:
    linear-gradient(120deg, rgba(255,255,255,.045), transparent 45%),
    var(--navy);
  box-shadow: var(--shadow);
}
.search-topline, .results-heading, .summary-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; }
.search-topline > div, .results-heading > div:first-child, .summary-heading { gap: 16px; }
.search-topline > div, .results-heading > div:first-child { display: flex; align-items: center; }
.search-panel h2 { margin: 0; font-size: 1.35rem; font-weight: 650; }
.quiet-button { border: 0; padding: 8px 0; color: #cbd5e1; background: none; font-size: 0.82rem; }
.quiet-button:hover { color: white; }

.search-field {
  min-height: 86px;
  margin-top: 26px;
  padding: 0 24px;
  display: grid;
  grid-template-columns: 25px 1fr auto;
  align-items: center;
  gap: 16px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 18px;
  background: white;
  transition: box-shadow .2s, border-color .2s;
}
.search-field:focus-within { border-color: #f0737a; box-shadow: 0 0 0 4px rgba(237,38,50,.15); }
.search-field svg { width: 24px; fill: none; stroke: var(--red); stroke-width: 1.9; stroke-linecap: round; }
.search-field input { min-width: 0; border: 0; outline: none; color: var(--ink); background: transparent; font-size: clamp(1.1rem, 2vw, 1.55rem); }
.search-field input::placeholder { color: #9aa3ae; }
.search-field kbd { padding: 7px 10px; border: 1px solid var(--line); border-radius: 8px; color: #7a8490; background: #f7f8f9; font-size: .72rem; box-shadow: 0 1px 0 #d9dfe4; }
.search-help { margin: 12px 4px 0; color: #aeb9c8; font-size: .76rem; }

.filters { margin-top: 20px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; }
.filters label { display: grid; gap: 8px; }
.filters label > span { padding-left: 3px; color: #aeb9c8; font-size: .66rem; letter-spacing: .13em; text-transform: uppercase; font-weight: 750; }
.filters select {
  width: 100%;
  min-height: 54px;
  padding: 0 42px 0 15px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 12px;
  outline: none;
  color: #162235;
  background: white;
  font-size: .82rem;
}

.exact-toggle { width: fit-content; margin-top: 24px; display: flex; align-items: center; gap: 13px; cursor: pointer; }
.exact-toggle input { position: absolute; opacity: 0; pointer-events: none; }
.toggle-track { width: 42px; height: 24px; flex: 0 0 auto; padding: 3px; border-radius: 99px; background: #657489; transition: background .2s; }
.toggle-track span { display: block; width: 18px; height: 18px; border-radius: 50%; background: white; transition: transform .2s; box-shadow: 0 2px 4px #0f172a33; }
.exact-toggle input:checked + .toggle-track { background: var(--red); }
.exact-toggle input:checked + .toggle-track span { transform: translateX(18px); }
.exact-toggle > span:last-child { display: grid; gap: 2px; }
.exact-toggle strong { font-size: .83rem; }
.exact-toggle small { color: #aeb9c8; font-size: .72rem; }

.results-section { padding-bottom: 88px; }
.results-heading { padding-inline: 2px; }
.results-heading h2, .source-summary h2 { margin: 0; font-size: clamp(1.7rem, 3vw, 2.45rem); letter-spacing: -.035em; font-weight: 540; }
.result-count { display: flex; align-items: baseline; gap: 9px; color: var(--muted); }
.result-count strong { color: var(--ink); font-size: 1.7rem; letter-spacing: -.04em; }
.result-count span { font-size: .8rem; }

.manufacturer-matches { margin-top: 24px; padding: 18px 20px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; border: 1px solid #cfdee7; border-radius: 15px; background: var(--blue-soft); }
.manufacturer-matches > span { margin-right: 4px; color: #4a6070; font-size: .77rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; }
.manufacturer-match { padding: 8px 11px; border-radius: 999px; color: #244b62; background: white; font-size: .79rem; font-weight: 650; box-shadow: 0 1px 3px rgba(21,51,70,.08); }
.manufacturer-match strong { color: var(--red); }
.comparison-note { margin: 16px 0 0; padding: 12px 14px; border: 1px solid #d8e3ea; border-radius: 12px; color: #546473; background: #f6fafc; font-size: .72rem; line-height: 1.55; }
.comparison-note strong { color: var(--navy); }

.search-guide { margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); overflow: hidden; border: 1px solid rgba(255,255,255,.13); border-radius: 12px; list-style: none; }
.search-guide li { min-width: 0; padding: 11px 13px; display: grid; grid-template-columns: 26px 1fr; column-gap: 9px; border-left: 1px solid rgba(255,255,255,.12); }
.search-guide li:first-child { border-left: 0; }
.search-guide li > span { grid-row: 1 / 3; width: 24px; height: 24px; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--red); font-size: .66rem; font-weight: 800; }
.search-guide strong { font-size: .72rem; }
.search-guide small { margin-top: 2px; color: #aeb9c8; font-size: .62rem; line-height: 1.35; }

.active-filters { margin-top: 15px; display: flex; flex-wrap: wrap; gap: 8px; }
.filter-chip { padding: 7px 10px; border-radius: 999px; color: #5f6874; background: #eceff1; font-size: .72rem; }

.match-legend { margin-top: 15px; display: flex; flex-wrap: wrap; gap: 15px; color: var(--muted); font-size: .68rem; }
.match-legend span { display: inline-flex; align-items: center; gap: 6px; }
.match-legend i { width: 9px; height: 9px; display: inline-block; border-radius: 50%; }
.legend-exact { background: #2f9a64; }
.legend-family { background: #3185ad; }
.legend-review { background: #d6902f; }
.legend-upcoming { background: #8b95a2; }
.legend-blocked { background: #b42318; }

.table-wrap { position: relative; min-height: 240px; margin-top: 25px; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: white; box-shadow: 0 18px 48px rgba(30,45,65,.06); }
table { width: 100%; border-collapse: collapse; table-layout: fixed; }
th { padding: 17px 20px; text-align: left; color: #7a8491; background: #f4f6f7; font-size: .65rem; letter-spacing: .12em; text-transform: uppercase; }
th:first-child { width: 37%; }
th:nth-child(2) { width: 12%; }
th:nth-child(3) { width: 27%; }
th:nth-child(4) { width: 14%; }
th:last-child { width: 10%; text-align: right; }
td { padding: 21px 20px; border-top: 1px solid #e7eaed; vertical-align: middle; }
tbody tr { transition: background .15s; }
tbody tr:hover { background: #fffafa; }
.product-cell strong { display: block; font-size: .94rem; line-height: 1.45; font-weight: 680; }
.product-cell span { margin-top: 6px; display: -webkit-box; overflow: hidden; color: var(--muted); font-size: .77rem; line-height: 1.45; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.product-cell .match-badge { width: fit-content; margin: 0 0 9px; padding: 5px 8px; display: inline-flex; border-radius: 999px; font-size: .62rem; line-height: 1; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; -webkit-line-clamp: unset; }
.match-exact { color: #23784d !important; background: #ebf7f0; }
.match-family { color: #28617f !important; background: #eaf5fa; }
.match-review { color: #9a611c !important; background: #fff4e4; }
.match-blocked { color: #981b1b !important; background: #ffeded; }
.procurement-blocked-row { box-shadow: inset 4px 0 #b42318; }
.family-context { margin-top: 4px !important; color: #416171 !important; font-size: .67rem !important; font-weight: 680; }
.match-reason { margin: 9px 0 0; color: #667587; font-size: .67rem; line-height: 1.45; }
.match-reason b { color: #33485e; }
.strength-picker { margin-top: 13px; display: grid; gap: 6px; }
.strength-picker > span { margin: 0; color: #526477; font-size: .62rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; -webkit-line-clamp: unset; }
.strength-picker select { width: 100%; min-height: 42px; padding: 0 36px 0 11px; border: 1px solid #b9d3e1; border-radius: 9px; outline: none; color: #18364a; background: #f4fbfe; font-size: .72rem; font-weight: 650; }
.strength-picker select:focus { border-color: #3185ad; box-shadow: 0 0 0 3px rgba(49,133,173,.13); }
.form-pills { display: flex; flex-wrap: wrap; gap: 5px; }
.form-pill { display: inline-block; padding: 7px 10px; border-radius: 999px; color: #28617f; background: #eaf5fa; font-size: .73rem; font-weight: 700; }
.use-pill { display: block; width: fit-content; margin-top: 6px; padding: 5px 8px; border-radius: 999px; color: #45606f; background: #eef4f6; font-size: .64rem; font-weight: 760; }
.use-pill.use-veterinary { color: #74501e; background: #fff2d9; }
.manufacturer-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.manufacturer-tag { padding: 7px 9px; border: 1px solid #d9e2e8; border-radius: 999px; color: #29495e; background: #f5f9fb; font-size: .69rem; line-height: 1.2; font-weight: 700; }
.manufacturer-tag.manufacturer-blocked { border-color: #e3a6a1; color: #8f1d18; background: #fff0ef; }
.manufacturer-locked { padding: 12px; display: grid; gap: 4px; border: 1px dashed #bad2df; border-radius: 11px; color: #315d75; background: #f3f9fc; }
.manufacturer-locked strong { font-size: .72rem; }
.manufacturer-locked span { color: #657686; font-size: .65rem; line-height: 1.4; }
.manufacturer-guidance { flex-basis: 100%; margin: 4px 0 0; color: #586c7c; font-size: .71rem; line-height: 1.45; }
.evidence-summary { color: var(--muted); font-size: .74rem; line-height: 1.45; }
.row-status { margin-top: 8px; }
.status-badge { display: inline-flex; align-items: center; gap: 7px; padding: 7px 10px; border-radius: 999px; font-size: .7rem; font-weight: 750; }
.status-badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status-approved { color: #23784d; background: #ebf7f0; }
.status-listed { color: #315d80; background: #edf4f9; }
.status-upcoming { color: #66717d; background: #eef1f3; }
.status-neutral { color: #314e63; background: #eaf2f7; }
.status-blocked { color: #991b1b; background: #ffeded; }
.details-button { float: right; padding: 9px 11px; border: 1px solid #d8dde2; border-radius: 9px; color: var(--navy); background: white; font-size: .73rem; font-weight: 700; }
.details-button:hover { border-color: var(--red); color: var(--red); }
.details-button:disabled { cursor: not-allowed; border-color: #e2e6e9; color: #9da6af; background: #f6f7f8; }

.empty-state, .loading-state { min-height: 310px; padding: 55px 25px; display: grid; place-items: center; align-content: center; text-align: center; }
.empty-state > span { color: var(--red); font-size: 3rem; }
.empty-state h3 { margin: 8px 0; font-size: 1.25rem; }
.empty-state p { max-width: 460px; margin: 0; color: var(--muted); line-height: 1.6; }
.loading-state { grid-template-columns: repeat(3, 9px); gap: 7px; }
.loading-state span { width: 9px; height: 9px; border-radius: 50%; background: var(--red); animation: pulse 1s infinite alternate; }
.loading-state span:nth-child(2) { animation-delay: .2s; }
.loading-state span:nth-child(3) { animation-delay: .4s; }
.loading-state p { grid-column: 1 / -1; color: var(--muted); font-size: .8rem; }
@keyframes pulse { to { opacity: .25; transform: translateY(-4px); } }

.load-more { margin: 22px auto 0; min-width: 190px; padding: 13px 20px; display: block; border: 1px solid #cfd6dc; border-radius: 12px; color: var(--navy); background: white; font-weight: 700; font-size: .82rem; }
.load-more:hover { border-color: var(--navy); }

.source-summary { padding: 72px 0 100px; border-top: 1px solid var(--line); }
.summary-heading { display: grid; grid-template-columns: auto auto 1fr; justify-content: start; align-items: center; }
.summary-heading p { margin: 0 0 0 auto; color: var(--muted); font-size: .78rem; }
.manufacturer-cards { margin-top: 34px; display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: white; }
.manufacturer-card { min-height: 218px; padding: 27px; display: flex; flex-direction: column; border-left: 1px solid var(--line); }
.manufacturer-card:first-child { border-left: 0; }
.manufacturer-card > span { color: var(--red); font-size: .67rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.manufacturer-card h3 { margin: 21px 0 7px; font-size: 1.15rem; line-height: 1.35; }
.manufacturer-card p { margin: 0; color: var(--muted); font-size: .76rem; line-height: 1.5; }
.manufacturer-card div { margin-top: auto; display: flex; align-items: baseline; gap: 7px; }
.manufacturer-card strong { font-size: 1.8rem; letter-spacing: -.04em; }
.manufacturer-card small { color: var(--muted); font-size: .68rem; }

footer { padding: 31px 0; color: #c7d0dc; background: var(--navy-2); }
.footer-inner { display: flex; justify-content: space-between; gap: 30px; align-items: center; }
.footer-inner p { margin: 0; font-size: .72rem; }
.footer-inner strong { color: white; }
.footer-inner > span { color: #8e9bad; font-size: .68rem; }

.scroll-top-button {
  position: fixed;
  z-index: 18;
  right: max(24px, env(safe-area-inset-right));
  bottom: max(24px, env(safe-area-inset-bottom));
  width: 52px;
  height: 52px;
  padding: 0;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 50%;
  color: white;
  background: var(--navy);
  box-shadow: 0 14px 34px rgba(18, 32, 49, .24);
  opacity: 0;
  pointer-events: none;
  transform: translateY(14px);
  transition: opacity .2s ease, transform .2s ease, background-color .2s ease;
}
.scroll-top-button.is-visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
.scroll-top-button:hover { background: var(--red); }
.scroll-top-button:focus-visible { outline: 3px solid rgba(237, 38, 50, .3); outline-offset: 4px; }
.scroll-top-button svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

.detail-dialog { width: min(900px, calc(100% - 32px)); padding: 0; border: 0; border-radius: 25px; color: var(--ink); background: transparent; box-shadow: 0 30px 100px rgba(6,16,28,.28); }
.detail-dialog::backdrop { background: rgba(15,25,38,.66); backdrop-filter: blur(5px); }
.dialog-shell { position: relative; max-height: min(820px, calc(100vh - 40px)); padding: 38px; overflow: auto; border-radius: 25px; background: white; }
.dialog-close { position: absolute; right: 20px; top: 18px; width: 38px; height: 38px; border: 0; border-radius: 50%; color: #6c7683; background: #f0f2f4; font-size: 1.45rem; }
.detail-dialog h2 { max-width: 640px; margin: 18px 0 8px; padding-right: 25px; font-size: clamp(1.55rem, 4vw, 2.25rem); line-height: 1.18; letter-spacing: -.035em; }
.detail-manufacturer { margin: 0; color: var(--red); font-weight: 720; }
.detail-grid { margin-top: 30px; display: grid; grid-template-columns: 1.5fr 1fr; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.detail-grid section { min-height: 120px; padding: 20px; border-left: 1px solid var(--line); border-top: 1px solid var(--line); }
.detail-grid section:nth-child(odd) { border-left: 0; }
.detail-grid section:nth-child(-n+2) { border-top: 0; }
.detail-grid section > span, .source-block > span { color: #818b97; font-size: .64rem; font-weight: 780; letter-spacing: .12em; text-transform: uppercase; }
.detail-grid p { margin: 12px 0 0; white-space: pre-line; font-size: .83rem; line-height: 1.6; }
.source-block { margin-top: 25px; }
#detailSources { margin-top: 10px; display: grid; gap: 8px; }
.manufacturer-evidence { padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: #fbfcfd; }
.manufacturer-evidence-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.manufacturer-evidence-heading > div { display: grid; gap: 4px; }
.manufacturer-evidence-heading strong { color: var(--navy); font-size: .94rem; }
.manufacturer-evidence-heading small { color: var(--muted); font-size: .72rem; line-height: 1.45; }
.manufacturer-evidence dl { margin: 15px 0 13px; display: grid; grid-template-columns: 1.7fr 1fr; gap: 12px; }
.manufacturer-evidence dl > div { min-width: 0; }
.manufacturer-evidence dt { color: #818b97; font-size: .6rem; font-weight: 780; letter-spacing: .1em; text-transform: uppercase; }
.manufacturer-evidence dd { margin: 6px 0 0; white-space: pre-line; font-size: .77rem; line-height: 1.55; }
.manufacturer-source-links { display: grid; gap: 7px; }
.source-link { padding: 12px 14px; display: flex; justify-content: space-between; gap: 15px; border: 1px solid var(--line); border-radius: 10px; color: var(--navy); text-decoration: none; font-size: .77rem; }
.source-link:hover { border-color: var(--red); color: var(--red); }
.source-link small { color: var(--muted); }
.manufacturer-evidence .source-row-evidence {
  margin: 0;
  padding: 11px 13px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 16px;
  border: 1px solid #e4e9ee;
  border-radius: 10px;
  background: #fff;
}
.source-row-evidence dd { overflow-wrap: anywhere; }

.source-note {
  margin: 0.45rem 0 0;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.45;
}
.regulatory-alert {
  margin: 13px 0;
  padding: 13px 14px;
  border: 1px solid #e3a6a1;
  border-radius: 11px;
  color: #7f1d1d;
  background: #fff1f0;
}
.regulatory-alert strong { display: block; font-size: .78rem; }
.regulatory-alert p { margin: 7px 0; font-size: .72rem; line-height: 1.5; }
.regulatory-alert a { color: #8f1d18; font-size: .68rem; font-weight: 750; }
.source-confirmation { margin-top: 14px; padding: 12px 13px; display: flex; align-items: flex-start; gap: 10px; border: 1px solid #d7e2db; border-radius: 11px; background: #f4faf6; cursor: pointer; }
.source-confirmation input { width: 17px; height: 17px; margin: 1px 0 0; accent-color: #238252; }
.source-confirmation > span { display: grid; gap: 3px; }
.source-confirmation strong { color: #255f43; font-size: .74rem; }
.source-confirmation small { color: #718077; font-size: .65rem; }
.dialog-note { margin: 20px 0 0; padding: 13px 15px; border-radius: 10px; color: #81562a; background: #fff6ea; font-size: .7rem; line-height: 1.5; }

@media (max-width: 1050px) {
  .shell { width: min(100% - 40px, 920px); }
  .hero { grid-template-columns: 1fr; gap: 38px; padding-block: 70px 55px; }
  .hero-metric { grid-template-columns: auto 1fr auto auto 1fr; align-items: end; gap: 12px; }
  .hero-metric strong { font-size: 2.2rem; }
  .hero-metric span { margin: 0 0 3px; }
  .metric-divider { width: 1px; height: 42px; margin: 0 15px; }
  .filters { grid-template-columns: repeat(2, 1fr); }
  .manufacturer-cards { grid-template-columns: repeat(2, 1fr); }
  .manufacturer-card:nth-child(3) { border-left: 0; border-top: 1px solid var(--line); }
  .manufacturer-card:nth-child(4) { border-top: 1px solid var(--line); }
  th:first-child { width: 36%; }
  th:nth-child(3) { width: 24%; }
}

@media (max-width: 760px) {
  .shell { width: calc(100% - 28px); }
  .header-inner { width: calc(100% - 28px); min-height: 75px; gap: 12px; }
  .brand-logo { width: 180px; height: 52px; }
  .header-rule, .header-copy { display: none; }
  .privacy-pill { padding: 8px 10px; font-size: .65rem; }
  .purchase-session { gap: 7px; }
  .purchase-user { display: none; }
  .logout-button { padding-inline: 11px; font-size: .66rem; }
  .hero { min-height: 0; padding-block: 55px 42px; }
  .hero h1 { margin: 20px 0 23px; font-size: clamp(3rem, 13vw, 4.8rem); }
  .hero-copy p { font-size: 1rem; }
  .hero-metric { padding: 23px; }
  .hero-metric span { font-size: .58rem; }
  .search-section { margin-bottom: 36px; }
  .search-panel { padding: 17px; border-radius: 20px; }
  .search-topline { gap: 14px; }
  .search-topline > div { gap: 10px; }
  .search-panel h2 { font-size: 1.08rem; }
  .quiet-button { font-size: .72rem; }
  .search-field { min-height: 56px; margin-top: 16px; padding: 0 14px; grid-template-columns: 19px 1fr; gap: 11px; border-radius: 14px; }
  .search-field svg { width: 19px; }
  .search-field input { font-size: .94rem; }
  .search-field kbd { display: none; }
  .search-help { margin-top: 8px; font-size: .66rem; line-height: 1.45; }
  .comparison-note { margin-top: 10px; padding: 9px 11px; font-size: .64rem; line-height: 1.45; }
  .search-guide { grid-template-columns: repeat(3, 1fr); }
  .search-guide li { padding: 9px 8px; grid-template-columns: 20px 1fr; column-gap: 6px; border-top: 0; border-left: 1px solid rgba(255,255,255,.12); }
  .search-guide li:first-child { border-left: 0; }
  .search-guide li > span { width: 19px; height: 19px; font-size: .57rem; }
  .search-guide strong { font-size: .61rem; line-height: 1.2; }
  .search-guide small { display: none; }
  .filters { margin-top: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .filters label:last-child { grid-column: 1 / -1; }
  .filters label { gap: 5px; }
  .filters label > span { font-size: .57rem; }
  .filters select { min-height: 44px; padding-left: 12px; font-size: .78rem; }
  .exact-toggle { margin-top: 15px; gap: 10px; }
  .exact-toggle { align-items: flex-start; }
  .exact-toggle strong { font-size: .76rem; }
  .exact-toggle small { font-size: .64rem; line-height: 1.35; }
  .results-section { padding-bottom: 65px; }
  .results-heading { align-items: center; }
  .results-heading > div:first-child { align-items: flex-start; flex-direction: column; gap: 9px; }
  .table-wrap { border: 0; overflow: visible; background: transparent; box-shadow: none; }
  table, tbody { display: block; }
  thead { display: none; }
  tr { position: relative; margin-bottom: 12px; padding: 19px; display: grid; grid-template-columns: 1fr auto; gap: 14px; border: 1px solid var(--line); border-radius: 16px; background: white; box-shadow: 0 8px 24px rgba(30,45,65,.05); }
  td { padding: 0; border: 0; }
  td:first-child { grid-column: 1 / -1; padding: 0 0 14px; border-bottom: 1px solid var(--line); }
  td:nth-child(3) { grid-column: 1 / -1; }
  td:nth-child(4) { align-self: center; }
  td:last-child { grid-column: 2; }
  .details-button { float: none; }
  .manufacturer-cards { grid-template-columns: 1fr; }
  .manufacturer-card { min-height: 180px; border-left: 0; border-top: 1px solid var(--line); }
  .manufacturer-card:first-child { border-top: 0; }
  .summary-heading { grid-template-columns: auto 1fr; }
  .summary-heading p { grid-column: 1 / -1; margin: 10px 0 0; }
  .footer-inner { align-items: flex-start; flex-direction: column; }
  .scroll-top-button { right: max(16px, env(safe-area-inset-right)); bottom: max(16px, env(safe-area-inset-bottom)); width: 48px; height: 48px; }
  .dialog-shell { padding: 27px 20px; }
  .detail-grid { grid-template-columns: 1fr; }
  .detail-grid section, .detail-grid section:nth-child(odd), .detail-grid section:nth-child(-n+2) { border-left: 0; border-top: 1px solid var(--line); }
  .detail-grid section:first-child { border-top: 0; }
  .manufacturer-evidence-heading { align-items: flex-start; flex-direction: column; }
  .manufacturer-evidence dl { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .brand-logo { width: 152px; }
  .privacy-pill { font-size: 0; gap: 0; }
  .privacy-pill span { font-size: .7rem; }
  .hero-metric { grid-template-columns: 1fr 1fr; gap: 4px 20px; }
  .hero-metric strong:nth-of-type(2) { grid-column: 2; grid-row: 1; }
  .hero-metric span:nth-of-type(2) { grid-column: 2; grid-row: 2; }
  .metric-divider { display: none; }
  .manufacturer-matches > span { width: 100%; }
}

@media (max-width: 390px) {
  .filters { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .scroll-top-button { transition: none; }
}
