:root {
  --ink: #17384a;
  --muted: #617985;
  --blue: #2e82a8;
  --blue-dark: #1f637f;
  --pink: #e65288;
  --cream: #fffaf4;
  --paper: #ffffff;
  --line: #dce7ec;
  --soft: #eef6f8;
  --shadow: 0 14px 36px rgba(23, 56, 74, .10);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--cream); font-family: Arial, Helvetica, sans-serif; line-height: 1.6; }
a { color: var(--blue-dark); text-decoration-thickness: .08em; text-underline-offset: .16em; }
a:hover { color: var(--pink); }
img { max-width: 100%; height: auto; }
button, input, select { font: inherit; }
button, .button { cursor: pointer; }
:focus-visible { outline: 3px solid #ffbf47; outline-offset: 3px; }
.shell { width: min(1160px, calc(100% - 32px)); 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; }
.skip-link { position: fixed; left: 16px; top: 12px; z-index: 100; background: var(--ink); color: white; padding: 10px 14px; transform: translateY(-180%); }
.skip-link:focus { transform: none; }

.site-header { background: var(--paper); border-bottom: 1px solid var(--line); }
.header-inner { min-height: 88px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.logo img { display: block; width: auto; max-height: 74px; }
#site-nav { display: flex; gap: 24px; align-items: center; font-weight: 700; }
#site-nav a { text-decoration: none; }
.menu-toggle { display: none; color: white; background: var(--blue-dark); border: 0; border-radius: 6px; padding: 9px 13px; }
.archive-banner { padding: 8px 16px; color: #43310c; background: #ffedb5; text-align: center; font-size: .9rem; }
main { min-height: 68vh; padding-block: 48px 72px; }

h1, h2, h3 { line-height: 1.16; letter-spacing: -.025em; }
h1 { margin: 0 0 22px; font-size: clamp(2.25rem, 5vw, 4rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); }
.eyebrow { margin: 0 0 8px; color: var(--pink); font-size: .78rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.lede { max-width: 850px; margin: 0 0 28px; color: var(--muted); font-size: clamp(1.08rem, 2vw, 1.25rem); }
.hero { overflow: hidden; display: grid; grid-template-columns: 1.25fr .75fr; align-items: end; min-height: 430px; margin-bottom: 64px; padding: 56px 56px 0; border-radius: 30px; background: linear-gradient(135deg, #dff4fb, #f9e5ee); box-shadow: var(--shadow); }
.hero > div { align-self: center; padding-bottom: 50px; }
.hero p:not(.eyebrow) { max-width: 650px; color: var(--muted); font-size: 1.18rem; }
.hero img { justify-self: end; max-height: 360px; object-fit: contain; }
.hero-search, .search-page > div { display: flex; gap: 8px; max-width: 660px; }
.hero-search input, .search-page input { width: 100%; min-width: 0; padding: 14px 16px; border: 1px solid #a9c6d4; border-radius: 8px; background: white; }
.hero-search button, .search-page button, .button, .pagination button { padding: 12px 18px; border: 0; border-radius: 8px; color: white; background: var(--blue-dark); font-weight: 700; text-decoration: none; }
.archive-note { display: flex; gap: 14px; align-items: baseline; margin: 24px 0 34px; padding: 16px 20px; border-left: 5px solid #d59b20; background: #fff1c9; }
.archive-note strong { flex: 0 0 auto; }
.answer-grid > div:last-child { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.answer-card { height: 100%; padding: 22px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); }
.answer-card h3 { margin-top: 0; }
.answer-card p { margin-bottom: 0; color: var(--muted); }
.answer-summary { max-width: 900px; margin: 28px 0; padding: 24px 26px; border: 1px solid #b9dbe7; border-left: 6px solid var(--blue); border-radius: 14px; background: #f4fbfd; }
.answer-summary h2 { margin: 0 0 12px; font-size: clamp(1.35rem, 2.5vw, 1.8rem); }
.answer-summary p:last-child { margin-bottom: 0; }

.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin: 50px 0 20px; }
.section-heading h2 { margin: 0; }
.category-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.category-card { display: flex; flex-direction: column; min-height: 116px; padding: 20px; border: 1px solid var(--line); border-radius: 14px; background: var(--paper); text-decoration: none; box-shadow: 0 5px 14px rgba(23,56,74,.04); }
.category-card span { margin-top: auto; color: var(--muted); font-size: .9rem; }
.brand-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.brand-card { position: relative; padding: 22px; border: 1px solid var(--line); border-radius: 16px; background: var(--paper); box-shadow: 0 7px 20px rgba(23,56,74,.05); }
.brand-card > a { text-decoration: none; }
.brand-card img { width: 100%; height: 130px; object-fit: contain; background: white; }
.brand-card h3 { margin: 14px 0 8px; font-size: 1.06rem; }
.brand-card p { margin: 6px 0 0; color: var(--muted); font-size: .9rem; }
.rank { position: absolute; top: 12px; left: 12px; z-index: 1; padding: 4px 8px; border-radius: 99px; background: var(--ink); color: white; font-size: .76rem; font-weight: 700; }
.score { display: inline-flex; gap: 5px; align-items: center; color: #a65e00; font-weight: 800; white-space: nowrap; }
.score span { color: #eea51e; }
.score.no-score { color: var(--muted); font-size: .9rem; }

.breadcrumb { margin-bottom: 26px; color: var(--muted); font-size: .92rem; }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: 7px; margin: 0; padding: 0; list-style: none; }
.breadcrumb li:not(:last-child)::after { margin-left: 7px; content: "/"; color: #91a4ad; }
.brand-header { display: grid; grid-template-columns: 220px 1fr; align-items: center; gap: 36px; margin-bottom: 30px; padding: 34px; border-radius: 24px; background: var(--paper); box-shadow: var(--shadow); }
.brand-header h1 { margin-bottom: 12px; }
.brand-logo-large { width: 220px; height: 160px; object-fit: contain; }
.brand-feature { width: 100%; max-height: 420px; margin-bottom: 28px; border-radius: 20px; object-fit: cover; }
.brand-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.panel { margin-bottom: 22px; padding: 26px; border: 1px solid var(--line); border-radius: 16px; background: var(--paper); }
.panel h2 { margin-top: 0; font-size: 1.4rem; }
.pros-cons { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.positive { border-top: 4px solid #53a66c; }
.negative { border-top: 4px solid #d17878; }
.rating-summary > div { display: grid; grid-template-columns: 150px 1fr 48px; align-items: center; gap: 12px; margin: 13px 0; }
.rating-bar { overflow: hidden; height: 11px; border-radius: 99px; background: var(--soft); }
.rating-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--blue), var(--pink)); }
.review-controls { display: flex; align-items: center; gap: 10px; margin: 18px 0; }
.review-controls select { padding: 8px 10px; border: 1px solid #aac1cc; border-radius: 6px; background: white; }
.review-stack { display: grid; gap: 14px; }
.review { padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.review header { display: flex; justify-content: space-between; gap: 12px; }
.review p { white-space: pre-line; }
.review footer { color: var(--muted); font-size: .82rem; }
.compact .review { padding: 15px; }
.compact .review p { font-size: .92rem; }
.pagination { display: flex; justify-content: center; align-items: center; gap: 16px; margin-top: 20px; }
.pagination button:disabled { cursor: default; opacity: .45; }

.ranking-nav { display: flex; flex-wrap: wrap; gap: 8px; margin: 24px 0; }
.ranking-nav a { padding: 8px 12px; border: 1px solid var(--line); border-radius: 99px; background: white; text-decoration: none; }
.ranking-nav a[aria-current="page"] { color: white; background: var(--blue-dark); }
.ranking-list { display: grid; gap: 10px; padding: 0; list-style: none; counter-reset: rank; }
.ranking-list li { display: grid; grid-template-columns: 56px 86px 1fr auto; align-items: center; gap: 18px; padding: 15px 20px; border: 1px solid var(--line); border-radius: 13px; background: white; }
.ranking-list img { width: 82px; height: 60px; object-fit: contain; }
.ranking-list h2 { margin: 0; font-size: 1.08rem; }
.ranking-list p { margin: 2px 0 0; color: var(--muted); font-size: .88rem; }
.ranking-number { font-size: 1.2rem; font-weight: 800; text-align: center; }

.prose { max-width: 820px; margin-inline: auto; padding: clamp(24px, 5vw, 52px); border: 1px solid var(--line); border-radius: 18px; background: white; box-shadow: var(--shadow); }
.prose h1 { font-size: clamp(2.1rem, 4vw, 3.3rem); }
.prose h2 { margin-top: 1.7em; }
.prose h3 { margin-top: 1.4em; font-size: 1.18rem; }
.definitions { display: grid; grid-template-columns: minmax(150px, .45fr) 1fr; gap: 0 20px; }
.definitions dt, .definitions dd { margin: 0; padding: 12px 0; border-bottom: 1px solid var(--line); }
.definitions dt { font-weight: 800; }
.byline, .news-card time { color: var(--muted); font-size: .9rem; }
.intro { max-width: 850px; color: var(--muted); font-size: 1.08rem; }
.result-count { color: var(--muted); }
.notice { padding: 18px; border-left: 5px solid #d59b20; background: #fff1c9; }
.news-list { display: grid; gap: 18px; }
.news-card { display: grid; grid-template-columns: 220px 1fr; gap: 24px; padding: 20px; border: 1px solid var(--line); border-radius: 15px; background: white; }
.news-card h2 { margin-top: 0; }
.news-image { width: 100%; max-height: 430px; margin-bottom: 22px; border-radius: 12px; object-fit: cover; }
.search-page { max-width: 760px; margin-inline: auto; }
.search-page > label { display: block; margin-bottom: 10px; font-size: 1.6rem; font-weight: 800; }
#search-status { margin: 24px auto 12px; max-width: 760px; color: var(--muted); }
.search-results { display: grid; gap: 12px; max-width: 760px; margin-inline: auto; }
.search-result { position: relative; display: block; padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: white; text-decoration: none; }
.search-result > span { float: right; padding: 2px 8px; border-radius: 99px; color: var(--muted); background: var(--soft); font-size: .74rem; text-transform: uppercase; }
.search-result p { margin-bottom: 0; color: var(--muted); }
.status-page { max-width: 650px; margin: 60px auto; text-align: center; }
.status-code { margin: 0; color: var(--pink); font-size: 5rem; font-weight: 900; }

.site-footer { padding: 46px 0; color: white; background: var(--ink); }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.site-footer img { width: 170px; filter: brightness(0) invert(1); }
.site-footer nav { display: grid; grid-template-columns: 1fr 1fr; gap: 9px 24px; align-content: start; }
.site-footer a { color: white; }
.footer-small { color: #c8d7de; font-size: .82rem; }

@media (max-width: 900px) {
  .category-grid, .brand-grid { grid-template-columns: repeat(2, 1fr); }
  .answer-grid > div:last-child { grid-template-columns: 1fr; }
  .hero { grid-template-columns: 1fr; padding: 38px 32px 0; }
  .hero > div { padding-bottom: 10px; }
  .hero img { max-height: 240px; justify-self: center; }
  .brand-layout { grid-template-columns: 1fr; }
  .brand-layout aside { order: 2; }
}

@media (max-width: 650px) {
  .shell { width: min(100% - 22px, 1160px); }
  .header-inner { min-height: 72px; }
  .logo img { width: auto; max-height: 58px; }
  .menu-toggle { display: block; }
  #site-nav { display: none; position: absolute; top: 72px; left: 11px; right: 11px; z-index: 20; flex-direction: column; align-items: stretch; padding: 18px; border: 1px solid var(--line); border-radius: 12px; background: white; box-shadow: var(--shadow); }
  #site-nav.open { display: flex; }
  main { padding-block: 28px 52px; }
  .hero { min-height: 0; margin-bottom: 42px; padding: 30px 22px 0; border-radius: 18px; }
  .hero-search, .search-page > div { flex-direction: column; }
  .archive-note { align-items: flex-start; flex-direction: column; }
  .category-grid, .brand-grid, .pros-cons { grid-template-columns: 1fr; }
  .section-heading { align-items: start; flex-direction: column; }
  .brand-header { grid-template-columns: 1fr; gap: 18px; padding: 24px; text-align: center; }
  .brand-logo-large { margin-inline: auto; }
  .rating-summary > div { grid-template-columns: 1fr 42px; }
  .rating-summary > div > span { grid-column: 1 / -1; }
  .ranking-list li { grid-template-columns: 38px 64px 1fr; gap: 10px; padding: 12px; }
  .ranking-list li > strong { grid-column: 3; }
  .ranking-list img { width: 60px; }
  .news-card { grid-template-columns: 1fr; }
  .definitions { grid-template-columns: 1fr; }
  .definitions dt { padding-bottom: 2px; border-bottom: 0; }
  .definitions dd { padding-top: 2px; }
  .footer-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
}
