/* US Robot Vacuum — buying page
   Palette: navy 27,42,74 / teal 13,115,119 / dark 20,32,56 */

:root {
  --navy: #1b2a4a;
  --teal: #0d7377;
  --teal-hover: #0a5e61;
  --teal-soft: #9fe0de;
  --dark: #142038;
  --ink: #142038;
  --muted: #5a6577;
  --line: #d0d7e2;
  --paper: #f4f7fa;
  --white: #ffffff;
  --warn: #8b2e3b;
  --warn-bg: #f8edea;
  --sub: #c8d4e8;
  --hero-muted: #b7c3d6;
  --shadow: 0 1px 2px rgba(20, 32, 56, 0.04), 0 16px 40px rgba(20, 32, 56, 0.07);
  --radius: 16px;
  --font-serif: "Newsreader", "Source Serif 4", "Georgia", serif;
  --font-sans: "Source Sans 3", "Segoe UI", "Helvetica Neue", sans-serif;
  --font-mono: "IBM Plex Mono", "ui-monospace", "SFMono-Regular", Menlo, monospace;
  --max: 1120px;
  --narrow: 760px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }
button, input { font: inherit; }

a { color: var(--teal); }
a:hover { color: var(--teal-hover); }

:focus-visible {
  outline: 2px solid var(--teal-soft);
  outline-offset: 3px;
}

body.light-focus :focus-visible,
.card :focus-visible,
.jump-bar :focus-visible {
  outline-color: var(--teal);
}

::selection {
  background: var(--teal-soft);
  color: var(--dark);
}

.skip {
  position: absolute;
  left: 16px;
  top: -48px;
  z-index: 200;
  background: var(--white);
  color: var(--dark);
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 6px;
}
.skip:focus { top: 12px; }

/* —— Draft notice (remove before publish) —— */
.draft-banner {
  background: #f3e3c4;
  color: #4a3a18;
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 8px 16px;
}
.draft-banner span { font-weight: 500; color: #6a5630; }

/* —— Hero (continuous dark field) —— */
.hero {
  background:
    linear-gradient(180deg, rgba(13, 115, 119, 0.16) 0%, rgba(20, 32, 56, 0) 220px),
    var(--dark);
  color: var(--white);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 8px;
  background: var(--teal);
}

.wrap {
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px 32px;
  padding: 16px 0 10px;
  border-bottom: 1px solid rgba(200, 212, 232, 0.14);
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}

.kicker {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal-soft);
}

.brand-name {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--white);
}

.header-meta {
  text-align: right;
  font-size: 13px;
  line-height: 1.45;
  color: var(--hero-muted);
  max-width: 28em;
}

.header-meta time {
  display: block;
  color: var(--sub);
  font-weight: 600;
  margin-bottom: 4px;
}

.disclose-line {
  font-size: 12.5px;
  line-height: 1.4;
  color: var(--sub);
}

.hero-grid {
  display: grid;
  grid-template-areas:
    "copy"
    "path"
    "proof";
  gap: 24px;
  padding: 28px 0 32px;
}
.hero-copy { grid-area: copy; }
.path { grid-area: path; }
.proof { grid-area: proof; }

.hero-copy h1 {
  font-family: var(--font-serif);
  font-size: clamp(28px, 6.4vw, 52px);
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.025em;
  max-width: 16ch;
  text-wrap: balance;
}

.hero-rule {
  width: 56px;
  height: 4px;
  background: var(--teal);
  margin: 20px 0 18px;
  border: 0;
}

.lead {
  font-size: clamp(16px, 2vw, 19px);
  line-height: 1.5;
  color: var(--sub);
  max-width: 38em;
}

.proof {
  margin-top: 0;
}

.proof-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal-soft);
  margin-bottom: 10px;
}

.proof-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
}

.proof-chips li {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--teal-soft);
  border: 1px solid rgba(159, 224, 222, 0.35);
  background: rgba(13, 115, 119, 0.15);
  padding: 7px 10px;
  border-radius: 999px;
  white-space: nowrap;
}

.path {
  background: var(--navy);
  border: 1px solid rgba(200, 212, 232, 0.12);
  border-radius: var(--radius);
  padding: 18px 18px 16px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.22);
}

.path h2 {
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-soft);
  margin-bottom: 14px;
}

.steps {
  list-style: none;
  display: grid;
  gap: 12px;
  margin-bottom: 20px;
}

.steps li {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 12px;
  align-items: start;
  font-size: 15.5px;
  line-height: 1.4;
  color: var(--sub);
}

.steps strong { color: var(--white); font-weight: 600; }

.num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--teal);
  color: var(--white);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  display: grid;
  place-items: center;
  margin-top: 1px;
}

.family-jumps {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.family-jumps a {
  display: block;
  text-align: center;
  text-decoration: none;
  color: var(--white);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  padding: 11px 10px;
  min-height: 44px;
  border-radius: 10px;
  border: 1px solid rgba(159, 224, 222, 0.4);
  background: rgba(20, 32, 56, 0.35);
}
.family-jumps a:hover,
.family-jumps a:focus-visible {
  background: var(--teal);
  border-color: var(--teal);
  color: var(--white);
}

/* —— Sticky jump bar —— */
.jump-bar {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(244, 247, 250, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.jump-bar-inner {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(var(--max), 100%);
  margin: 0 auto;
  padding: 10px 20px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.jump-bar-inner::-webkit-scrollbar { display: none; }

.jump-label {
  flex: 0 0 auto;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  padding-right: 4px;
}

.jump-bar a {
  flex: 0 0 auto;
  text-decoration: none;
  color: var(--navy);
  font-size: 14px;
  font-weight: 600;
  padding: 8px 12px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--white);
}
.jump-bar a:hover,
.jump-bar a:focus-visible {
  border-color: var(--teal);
  color: var(--teal);
}

/* —— Before-you-buy strip —— */
.note-strip {
  padding: 22px 0 8px;
  color: var(--muted);
  font-size: 14.5px;
  line-height: 1.55;
}

.note-strip p { max-width: 62em; }
.note-strip a { font-weight: 600; }

/* —— Sections & cards —— */
main { padding-bottom: 80px; }

.family {
  padding-top: 56px;
}

.family-head {
  margin-bottom: 22px;
  max-width: 40em;
}

.family-head h2 {
  font-family: var(--font-serif);
  font-size: clamp(26px, 3.2vw, 34px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--navy);
}

.family-head p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 16.5px;
}

.cards {
  display: grid;
  gap: 18px;
}

.card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px 24px 22px;
  box-shadow: var(--shadow);
}

.card-buy {
  border-top: 3px solid var(--teal);
  display: grid;
  gap: 0;
  padding: 0;
  overflow: hidden;
}

.card-media {
  background: linear-gradient(180deg, #eef3f7 0%, #f7f9fb 100%);
  padding: 24px 20px 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 300px;
}

.card-media picture {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 100%;
}

.card-media img {
  display: block;
  max-width: 100%;
  width: auto;
  height: auto;
  max-height: 380px;
  object-fit: contain;
  margin: 0 auto;
}

.card-body {
  padding: 12px 24px 24px;
  min-width: 0; /* prevent long titles from overflowing the grid */
}

.card-body .product {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.card-search {
  background: #eef2f7;
  box-shadow: none;
  border-style: dashed;
  border-top: 3px solid var(--navy);
}

.card-flag {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 10px;
  color: var(--teal);
}

.card-search .card-flag { color: var(--navy); }

.oem {
  font-family: var(--font-mono);
  font-size: clamp(22px, 3.4vw, 30px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--navy);
  user-select: all;
}

.aliases {
  margin-top: 6px;
  font-size: 14.5px;
  color: var(--muted);
}

.aliases code,
.fallback code,
.search-code code,
.copy-row code {
  font-family: var(--font-mono);
  font-size: 0.95em;
  font-weight: 500;
  color: var(--navy);
  background: var(--paper);
  padding: 1px 6px;
  border-radius: 4px;
  user-select: all;
}

.card-search .search-code code {
  background: var(--white);
}

.product {
  margin: 14px 0 0;
  font-size: 16px;
  color: var(--ink);
}

.product .brand-line {
  display: block;
  margin-top: 2px;
  font-size: 14.5px;
  color: var(--muted);
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 12px;
  font-size: 14px;
  color: var(--muted);
}

.meta-row dt {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.meta-row dl {
  display: contents;
}

.warn {
  margin-top: 16px;
  background: var(--warn-bg);
  color: var(--warn);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.45;
}

.caveat {
  margin-top: 12px;
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--ink);
  background: #e8f3f3;
  border-radius: 10px;
  padding: 10px 14px;
}

.caveat-restrict {
  background: var(--warn-bg);
  color: var(--ink);
  border-left: 3px solid var(--warn);
}

.buy-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 24px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.price-block { min-width: 12em; }

.price {
  font-family: var(--font-serif);
  font-size: 34px;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--navy);
}

.price-note {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted);
  max-width: 28em;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 650;
  letter-spacing: 0.01em;
  text-decoration: none;
  border: 0;
  cursor: pointer;
}

.btn-amazon {
  background: var(--teal);
  color: var(--white);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.12) inset, 0 8px 20px rgba(13, 115, 119, 0.25);
}
.btn-amazon:hover,
.btn-amazon:focus-visible {
  background: var(--teal-hover);
  color: var(--white);
}

.btn svg {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
}

.btn-copy {
  background: var(--white);
  color: var(--navy);
  border: 1px solid var(--line);
  min-height: 44px;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 600;
}
.btn-copy:hover { border-color: var(--teal); color: var(--teal); }
.btn-copy[data-copied="true"] {
  border-color: var(--teal);
  color: var(--teal);
}

.copy-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  margin-top: 16px;
}

.search-code {
  font-size: 14.5px;
  color: var(--muted);
}

.fallback {
  margin-top: 12px;
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.45;
}

.fine {
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
}

/* —— Footer —— */
footer {
  background: var(--dark);
  color: var(--sub);
  padding: 48px 0 36px;
  margin-top: 8px;
}

footer .wrap { max-width: var(--max); }

.footer-title {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 600;
  color: var(--white);
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

footer p { max-width: 48em; font-size: 15px; line-height: 1.55; margin-bottom: 10px; }
footer a { color: var(--teal-soft); }
footer a:hover { color: var(--white); }

.footer-meta {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid rgba(200, 212, 232, 0.14);
  font-size: 13px;
  color: var(--hero-muted);
}

/* —— Responsive —— */
@media (min-width: 800px) {
  .hero::before { width: 10px; }
  .hero-grid {
    grid-template-areas:
      "copy path"
      "proof path";
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
    gap: 28px 56px;
    align-items: start;
    padding: 48px 0 56px;
  }
  .path { align-self: stretch; }
  .path { padding: 26px 26px 22px; }
  .family-jumps { grid-template-columns: 1fr 1fr; }
  .card { padding: 28px 30px 26px; }
  .card.card-buy { padding: 0; }
  .card-buy {
    grid-template-columns: minmax(240px, 32%) 1fr;
    align-items: stretch;
  }
  .card-media {
    padding: 32px 22px;
    min-height: 440px;
    border-right: 1px solid var(--line);
  }
  .card-media img { max-height: 500px; }
  .card-body { padding: 24px 28px 26px 24px; }
  .buy-row { flex-wrap: nowrap; }
  .btn-amazon { min-width: 200px; }
}

@media (min-width: 1040px) {
  .wrap { width: min(var(--max), calc(100% - 64px)); }
  .family-jumps { grid-template-columns: 1fr 1fr; }
  .header-meta { max-width: 28em; }
}

@media (max-width: 640px) {
  .site-header { flex-direction: column; align-items: stretch; }
  .header-meta { text-align: left; max-width: none; }
}
@media (max-width: 479px) {
  .wrap { width: min(var(--max), calc(100% - 28px)); }
  .proof-chips li { font-size: 11.5px; padding: 6px 8px; }
  .price { font-size: 30px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn-amazon { box-shadow: none; }
}

@media print {
  .draft-banner, .jump-bar, .btn-amazon, .btn-copy { display: none !important; }
  .hero { background: #fff; color: #000; }
  .hero::before { display: none; }
  .card { box-shadow: none; break-inside: avoid; }
  .card-media img { max-height: 280px; }
  a[href]::after { content: " (" attr(href) ")"; font-size: 11px; word-break: break-all; }
}


/* —— Hero recommended pick —— */
.hero-pick {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid rgba(200, 212, 232, 0.14);
}

.hero-pick-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-soft);
  margin-bottom: 6px;
}

.hero-pick-name {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--white);
  line-height: 1.2;
}

.hero-pick-meta {
  margin-top: 4px;
  font-size: 14px;
  color: var(--sub);
}

.hero-pick-price {
  margin-top: 10px;
  font-family: var(--font-serif);
  font-size: 30px;
  font-weight: 600;
  letter-spacing: -0.03em;
  color: var(--white);
  line-height: 1;
}

.hero-pick .btn-amazon {
  margin-top: 14px;
  width: 100%;
}

.hero-pick-fine {
  margin-top: 10px;
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--hero-muted);
}

/* —— Ratings & flags —— */
.rating {
  margin-top: 8px;
  font-size: 14.5px;
  color: var(--ink);
  font-weight: 600;
}

.rating span {
  font-weight: 500;
  color: var(--muted);
}

.card-flag-recommend { color: var(--teal); }
.card-flag-compare { color: var(--navy); }

.card-recommend {
  border-top-color: var(--teal);
}

.card-compare {
  border-top-color: var(--navy);
}

.fit {
  margin-top: 14px;
  font-size: 16px;
  color: var(--ink);
  line-height: 1.55;
}

.fit strong { font-weight: 650; }

.spec-list {
  margin-top: 14px;
  display: grid;
  gap: 8px;
  list-style: none;
}

.spec-list li {
  display: grid;
  grid-template-columns: 9.5em 1fr;
  gap: 10px 16px;
  font-size: 14.5px;
  line-height: 1.45;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.spec-list li:last-child { border-bottom: 0; padding-bottom: 0; }

.spec-list .k {
  font-weight: 650;
  color: var(--navy);
}

.spec-list .v { color: var(--ink); }

@media (max-width: 479px) {
  .spec-list li { grid-template-columns: 1fr; gap: 2px; }
}

.btn-secondary {
  background: var(--white);
  color: var(--navy);
  border: 1px solid var(--line);
  box-shadow: none;
}
.btn-secondary:hover,
.btn-secondary:focus-visible {
  border-color: var(--teal);
  color: var(--teal);
  background: var(--white);
}

.list-price {
  margin-top: 4px;
  font-size: 13px;
  color: var(--muted);
}

/* —— Decision section —— */
.decide {
  display: grid;
  gap: 14px;
}

.decide article {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 22px 18px;
  box-shadow: var(--shadow);
}

.decide h3 {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--navy);
  margin-bottom: 8px;
}

.decide p {
  font-size: 16px;
  color: var(--ink);
  line-height: 1.55;
}

@media (min-width: 800px) {
  .decide {
    grid-template-columns: 1fr 1fr 1fr;
    gap: 16px;
  }
  .decide article { padding: 22px 22px 20px; }
}

/* —— Comparison table —— */
.compare-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.compare-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 720px;
  font-size: 14.5px;
}

.compare-table th,
.compare-table td {
  text-align: left;
  vertical-align: top;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  line-height: 1.45;
}

.compare-table th {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  background: #eef3f7;
}

.compare-table tbody th {
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 650;
  letter-spacing: 0;
  text-transform: none;
  color: var(--navy);
  background: transparent;
  min-width: 9em;
}

.compare-table tr:last-child th,
.compare-table tr:last-child td { border-bottom: 0; }

.compare-table .rec-row th,
.compare-table .rec-row td {
  background: #eef8f8;
}

.compare-table .role {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--teal);
  display: block;
  margin-bottom: 4px;
}

.compare-table .role-compare {
  color: var(--muted);
}

.compare-table a { font-weight: 600; }

.caveat-block {
  margin-top: 22px;
  max-width: 48em;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.caveat-block p + p { margin-top: 10px; }
