:root {
  --bg: #f6f7f9;
  --surface: #ffffff;
  --text: #16202b;
  --muted: #5c6773;
  --line: #dfe4ea;
  --accent: #e4572e;
  --accent-soft: #fdeee7;
  --teal: #0f766e;
  --teal-soft: #e6f4f2;
  --danger: #b42318;
  --warning: #b54708;
  --green: #15803d;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, sans-serif;
  font-size: 15px;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  color: var(--accent);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
}

.header-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: 8px;
}

.brand strong {
  color: var(--accent);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  font-size: 14px;
}

.site-nav a {
  color: var(--muted);
  white-space: nowrap;
}

.site-nav a.is-active,
.site-nav a:hover {
  color: var(--text);
}

.page {
  max-width: 1120px;
  margin: 0 auto;
  padding: 26px 18px 48px;
}

.hero {
  padding: 34px 0 26px;
}

.hero h1 {
  margin: 0 0 8px;
  font-size: 34px;
  line-height: 1.25;
  letter-spacing: 0;
}

.hero p {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
}

.home-hero {
  padding: 16px 0 8px;
}

.home-hero-heading {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}

.home-hero h1 {
  margin: 0;
}

.home-hero .eyebrow {
  margin: 0;
  padding-left: 14px;
  border-left: 1px solid var(--line);
  line-height: 1.25;
}

.home-hero p {
  margin-top: 6px;
  font-size: 15px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 10px;
  color: var(--teal);
  font-size: 13px;
  font-weight: 700;
}

.mode-tabs {
  display: flex;
  gap: 8px;
  margin: 22px 0 14px;
}

.home-hero + .mode-tabs {
  margin-top: 14px;
}

.mode-tab,
.plain-button {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.mode-tab.is-active,
.plain-button:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-soft);
}

.panel {
  display: none;
}

.panel.is-active {
  display: block;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin: 18px 0 10px;
}

.section-head h2 {
  margin: 0;
  font-size: 21px;
  letter-spacing: 0;
}

.section-head span {
  color: var(--muted);
  font-size: 13px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}

.product-card,
.info-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
}

a.info-card {
  transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

a.info-card:hover {
  color: inherit;
  border-color: rgba(15, 118, 110, 0.45);
  box-shadow: 0 8px 24px rgba(22, 32, 43, 0.08);
  transform: translateY(-1px);
}

.plan-card-action {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 10px;
  color: var(--teal);
  font-size: 13px;
  font-weight: 700;
}

.product-card h3 {
  margin: 0 0 4px;
  font-size: 17px;
  letter-spacing: 0;
}

.product-card p {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 13px;
  min-height: 40px;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-top: 1px solid var(--line);
  padding-top: 10px;
  font-size: 13px;
}

.price {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 14px 0;
}

.toolbar input[type="search"],
.toolbar input[type="number"] {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  padding: 8px 12px;
  font-size: 14px;
  min-width: 0;
}

.toolbar input[type="search"] {
  flex: 1 1 220px;
}

.toolbar label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
}

.filter-status {
  margin: 10px 2px;
  color: var(--muted);
  font-size: 13px;
}

.filter-status strong {
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.filter-empty {
  margin: 10px 0;
  padding: 18px;
  color: var(--muted);
  text-align: center;
  background: var(--surface);
  border: 1px dashed var(--line);
  border-radius: 8px;
}

.offer-table-wrap {
  overflow-x: auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.offer-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  min-width: 720px;
}

.offer-table th,
.offer-table td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.offer-table th {
  background: #fafbfc;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.offer-table tr:last-child td {
  border-bottom: 0;
}

.offer-table a {
  color: var(--teal);
  font-weight: 700;
}

.offer-table a:hover {
  color: var(--accent);
}

.offer-title {
  max-width: 360px;
}

.offer-meta {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.offer-store {
  display: flex;
  align-items: center;
  gap: 4px;
}

.store-badge {
  display: inline-flex;
  flex: 0 0 auto;
  width: 14px;
  height: 14px;
  align-items: center;
  justify-content: center;
}

.store-badge-group {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 3px;
}

.store-badge svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
  stroke: #fff;
  stroke-width: 1.2;
}

.store-badge-silver {
  color: #98a2ad;
}

.store-badge-active {
  color: var(--teal);
}

.store-badge-text {
  color: var(--teal);
  font-size: 11px;
  font-weight: 700;
}

.store-badge-gold {
  color: #d29a16;
  filter: drop-shadow(0 1px 1px rgba(139, 92, 8, 0.22));
}

.category-label {
  display: inline-flex;
  color: #17665f;
  background: #e8f5f2;
  border: 1px solid #b9ddd7;
  border-radius: 6px;
  padding: 5px 8px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.category-tone-0 { color: #17665f; background: #e8f5f2; border-color: #b9ddd7; }
.category-tone-1 { color: #315c91; background: #edf4fd; border-color: #c7daf2; }
.category-tone-2 { color: #76521b; background: #fff5df; border-color: #ecd49c; }
.category-tone-3 { color: #74458a; background: #f6eef9; border-color: #dcc5e7; }
.category-tone-4 { color: #984d45; background: #fff0ed; border-color: #efc8c1; }
.category-tone-5 { color: #45672b; background: #eff7e8; border-color: #cbe0ba; }
.category-tone-6 { color: #315f73; background: #eaf5f8; border-color: #bddae3; }
.category-tone-7 { color: #5b5f6b; background: #f1f2f5; border-color: #d3d6dd; }

.classification-filters {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.filter-group {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.filter-label {
  flex: 0 0 58px;
  padding-top: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.filter-chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 11px;
  color: var(--muted);
  background: #fff;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.filter-chip:hover,
.filter-chip.is-active {
  color: #fff;
  border-color: var(--teal);
  background: var(--teal);
}

.tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 700;
}

.tag-stock {
  color: var(--green);
  background: #e8f6ee;
}

.tag-low {
  color: var(--warning);
  background: #fdf1e2;
}

.tag-out {
  color: var(--muted);
  background: #eef0f2;
}

.tag-muted {
  color: var(--muted);
  background: #eef0f2;
}

.tag-teal {
  color: var(--teal);
  background: var(--teal-soft);
}

.official-lowest td {
  background: #f1fbf8;
}

.breadcrumb {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 12px;
}

.breadcrumb a:hover {
  color: var(--accent);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px;
  margin: 16px 0;
}

.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}

.stat .label {
  color: var(--muted);
  font-size: 12px;
}

.stat .value {
  font-size: 20px;
  font-weight: 800;
  margin-top: 2px;
}

.copy-block {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px 18px;
  margin-top: 18px;
}

.copy-block h2 {
  font-size: 18px;
  margin: 0 0 8px;
  letter-spacing: 0;
}

.copy-block p {
  margin: 8px 0;
  color: var(--muted);
}

.seo-article {
  max-width: 920px;
}

.article-hero {
  padding: 24px 0 8px;
}

.article-hero h1 {
  max-width: 820px;
  margin: 8px 0 12px;
  font-size: clamp(30px, 5vw, 46px);
  line-height: 1.14;
  letter-spacing: -0.035em;
}

.article-hero > p {
  max-width: 780px;
  margin: 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

.article-meta,
.data-disclaimer {
  margin-top: 12px;
  color: var(--muted);
  font-size: 12px;
}

.answer-callout {
  display: flex;
  gap: 12px;
  margin: 20px 0;
  padding: 14px 16px;
  border: 1px solid #cfe8e2;
  border-left: 4px solid var(--teal);
  border-radius: 8px;
  background: var(--teal-soft);
  line-height: 1.65;
}

.answer-callout strong {
  flex: 0 0 auto;
}

.article-section {
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}

.article-section h2,
.related-reading h2,
.live-offers h2 {
  margin: 0 0 12px;
  font-size: 23px;
  letter-spacing: -0.02em;
}

.article-section p,
.article-section li {
  color: #3d4650;
  font-size: 15px;
  line-height: 1.85;
}

.article-section ul {
  margin: 10px 0 0;
  padding-left: 22px;
}

.article-section li + li {
  margin-top: 7px;
}

.article-faq details {
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.article-faq summary {
  cursor: pointer;
  color: var(--ink);
  font-weight: 700;
  line-height: 1.55;
}

.article-faq details p {
  margin: 10px 0 0;
}

.guide-table-wrap {
  overflow-x: auto;
  margin-top: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.guide-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
}

.guide-table th,
.guide-table td {
  min-width: 150px;
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 14px;
  line-height: 1.65;
}

.guide-table th {
  background: #f7f8f9;
  font-size: 13px;
}

.guide-table tr:last-child td {
  border-bottom: 0;
}

.live-offers,
.related-reading {
  margin-top: 28px;
}

.text-link,
.article-sources a {
  color: var(--teal);
  font-weight: 700;
}

.tag-link {
  text-decoration: underline;
  text-decoration-color: #aab7b3;
  text-underline-offset: 3px;
}

.home-guides {
  margin-top: 38px;
}

.guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
}

.guide-card,
.guide-index-card {
  display: flex;
  gap: 14px;
  justify-content: space-between;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  transition: border-color .15s ease, transform .15s ease;
}

.guide-card:hover,
.guide-index-card:hover {
  border-color: #9ecfc5;
  transform: translateY(-1px);
}

.guide-index-card {
  display: block;
  padding: 20px;
}

.guide-index-card h2 {
  margin: 8px 0;
  font-size: 19px;
  line-height: 1.35;
}

.guide-index-card h3 {
  margin: 4px 0 8px;
  font-size: 19px;
}

.guide-index-card p {
  min-height: 68px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.form-card {
  max-width: 560px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 20px;
}

.form-card label {
  display: block;
  margin: 12px 0 6px;
  font-weight: 700;
  font-size: 14px;
}

.form-card input,
.form-card textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 14px;
  font-family: inherit;
}

.form-card textarea {
  min-height: 100px;
  resize: vertical;
}

.form-card button {
  margin-top: 14px;
  border: 0;
  background: var(--text);
  color: #fff;
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.honeypot {
  position: absolute;
  left: -9999px;
  opacity: 0;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: var(--surface);
  margin-top: 30px;
}

.footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 18px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  color: var(--muted);
  font-size: 13px;
}

.footer-inner a {
  color: var(--muted);
  margin-right: 12px;
}

@media (max-width: 720px) {
  .header-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .site-nav {
    gap: 12px;
  }

  .hero h1 {
    font-size: 27px;
  }

  .home-hero-heading {
    gap: 8px;
  }

  .home-hero .eyebrow {
    padding-left: 0;
    border-left: 0;
  }

  .section-head {
    flex-direction: column;
    gap: 4px;
  }

  .product-grid {
    grid-template-columns: 1fr;
  }

  .answer-callout {
    display: block;
  }

  .article-hero h1 {
    font-size: 30px;
  }
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 12px;
}

.pager-btn {
  appearance: none;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  padding: 6px 14px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.pager-btn:hover:not(:disabled) {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-soft);
}

.pager-btn:disabled {
  opacity: 0.45;
  cursor: default;
}

.pager-info {
  font-size: 13px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.analytics-admin { max-width: none; }
.analytics-login { display: flex; gap: 10px; max-width: 620px; margin-top: 20px; }
.analytics-login input { flex: 1; min-width: 220px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); }
.analytics-toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 8px; }
.analytics-toolbar button { padding: 8px 15px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--muted); cursor: pointer; }
.analytics-toolbar button.is-active { border-color: var(--teal); background: var(--teal-soft); color: var(--teal); }
.analytics-status { min-height: 24px; color: var(--muted); }
.analytics-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: 24px 0; }
.analytics-cards > div, .analytics-panel { border: 1px solid var(--line); border-radius: 14px; background: #fff; padding: 18px; }
.analytics-cards span { display: block; color: var(--muted); font-size: 14px; }
.analytics-cards strong { display: block; margin-top: 8px; font-size: 28px; font-variant-numeric: tabular-nums; }
.analytics-panel { margin: 14px 0; }
.analytics-panel h2 { margin: 0 0 14px; font-size: 18px; }
.analytics-panel table { width: 100%; border-collapse: collapse; }
.analytics-panel th, .analytics-panel td { padding: 10px 8px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.analytics-panel th { color: var(--muted); font-size: 13px; }
.analytics-chart { height: 180px; display: flex; align-items: flex-end; gap: 3px; border-bottom: 1px solid var(--line); }
.analytics-bar { flex: 1; min-width: 2px; border-radius: 3px 3px 0 0; background: var(--teal); opacity: .78; }

@media (max-width: 720px) {
  .analytics-login { flex-direction: column; }
  .analytics-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
