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

:root {
  --bg: #f4f6f9;
  --card: #ffffff;
  --text: #1a202c;
  --muted: #64748b;
  --border: #e2e8f0;
  --primary: #1d4ed8;
  --primary-dark: #1e40af;
  --danger: #dc2626;
  --success: #059669;
  --warn: #d97706;
  --code-bg: #fef2f2;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
}

a {
  color: var(--primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.site-header {
  background: #0f172a;
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
}

.site-header .inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 56px;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  color: #fff;
  white-space: nowrap;
  text-decoration: none;
}

.brand:hover {
  text-decoration: none;
}

.brand-logo {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.brand-text span {
  color: #60a5fa;
}

.brand span {
  color: #60a5fa;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  font-size: 14px;
}

.nav a {
  color: #cbd5e1;
}

.nav a:hover,
.nav a.active {
  color: #fff;
  text-decoration: none;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 24px 16px 48px;
}

.page-hero {
  margin-bottom: 24px;
}

.page-hero h1 {
  font-size: 28px;
  line-height: 1.3;
  margin-bottom: 8px;
}

.page-hero .desc {
  color: var(--muted);
  font-size: 15px;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.card h2 {
  font-size: 20px;
  margin-bottom: 12px;
}

.card h3 {
  font-size: 16px;
  margin: 18px 0 10px;
}

.update-tag {
  display: inline-block;
  background: #eff6ff;
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 12px;
}

.alert {
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 14px;
  margin: 12px 0;
}

.alert-warn {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
}

.alert-ok {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}

.alert-muted {
  background: #f8fafc;
  border: 1px solid var(--border);
  color: var(--muted);
}

.coupon-list {
  list-style: none;
}

.coupon-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px dashed var(--border);
}

.coupon-item:last-child {
  border-bottom: none;
}

.coupon-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 18px;
  font-weight: 700;
  color: var(--danger);
  background: var(--code-bg);
  padding: 6px 12px;
  border-radius: 6px;
  letter-spacing: 0.5px;
}

.coupon-code.expired {
  color: #94a3b8;
  background: #f1f5f9;
  text-decoration: line-through;
}

.coupon-meta {
  color: var(--muted);
  font-size: 14px;
  flex: 1;
  min-width: 160px;
}

.badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 999px;
}

.badge-hot {
  background: #fee2e2;
  color: #b91c1c;
}

.badge-ok {
  background: #d1fae5;
  color: #047857;
}

.badge-off {
  background: #e2e8f0;
  color: #64748b;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 6px;
  padding: 7px 14px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
}

.btn:hover {
  text-decoration: none;
}

.btn-copy {
  background: var(--primary);
  color: #fff;
}

.btn-copy:hover {
  background: var(--primary-dark);
}

.btn-buy {
  background: var(--danger);
  color: #fff;
}

.btn-buy:hover {
  background: #b91c1c;
  color: #fff;
}

.btn-sm {
  padding: 5px 10px;
  font-size: 13px;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 4px;
}

.table-wrap {
  overflow-x: auto;
  margin-top: 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
}

table.plans {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 860px;
}

table.plans th,
table.plans td {
  border-bottom: 1px solid var(--border);
  padding: 10px 8px;
  text-align: left;
  vertical-align: top;
}

table.plans th {
  background: #f8fafc;
  font-weight: 600;
  white-space: nowrap;
}

table.plans tr:last-child td {
  border-bottom: none;
}

table.plans .group-row td {
  background: #eff6ff;
  font-weight: 700;
  color: #1e3a8a;
  padding: 12px 8px;
}

table.plans .price {
  color: var(--danger);
  font-weight: 600;
  white-space: nowrap;
}

table.plans .dc {
  color: var(--muted);
  font-size: 12px;
  max-width: 220px;
}

.recommend {
  display: grid;
  gap: 12px;
}

@media (min-width: 720px) {
  .recommend {
    grid-template-columns: 1fr 1fr;
  }
}

.rec-item {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px;
  background: #fff;
}

.rec-item h3 {
  margin: 0 0 8px;
  font-size: 15px;
}

.rec-item p {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 8px;
}

.steps ol {
  padding-left: 20px;
}

.steps li {
  margin-bottom: 18px;
}

.steps li::marker {
  font-weight: 700;
  color: var(--primary);
}

.shot {
  display: block;
  max-width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 8px;
  margin: 12px 0;
  background: #fff;
}

.toc {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px 16px;
  margin-bottom: 16px;
  font-size: 14px;
}

.toc a {
  display: inline-block;
  margin-right: 14px;
}

.toc-sticky {
  position: sticky;
  top: 56px;
  z-index: 40;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  margin: 0 0 20px;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 4px 18px rgba(15, 23, 42, 0.06);
}

.toc-sticky__label {
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  margin-right: 4px;
}

.toc-sticky__item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #f1f5f9;
  border-radius: 999px;
  padding: 2px 4px 2px 12px;
}

.toc-sticky__item a {
  margin: 0;
  color: #334155;
  font-weight: 600;
  font-size: 13px;
  text-decoration: none;
  padding: 6px 0;
}

.toc-sticky__item a.is-active {
  color: var(--primary);
}

.toc-sticky__share {
  border: none;
  background: transparent;
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 999px;
}

.toc-sticky__share:hover {
  background: #dbeafe;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.section-head h2 {
  margin-bottom: 0;
}

.btn-share {
  background: #0f172a;
  color: #fff;
}

.btn-share:hover {
  background: #1e293b;
  color: #fff;
}

#pick,
#buy,
#all-plans,
#coupons,
#plans,
#key-facts,
#recommend {
  scroll-margin-top: 130px;
}

.poster-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.poster-modal[hidden] {
  display: none !important;
}

.poster-modal__mask {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
}

.poster-modal__panel {
  position: relative;
  width: min(420px, 100%);
  max-height: min(92vh, 900px);
  overflow: auto;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
  z-index: 1;
}

.poster-modal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}

.poster-modal__head h3 {
  font-size: 16px;
  margin: 0;
}

.poster-modal__x {
  border: none;
  background: transparent;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  color: #64748b;
}

.poster-modal__body {
  padding: 14px 16px 18px;
}

.poster-modal__preview-wrap {
  position: relative;
  background: #0f172a;
  border-radius: 10px;
  min-height: 280px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.poster-modal__preview {
  display: block;
  width: 100%;
  height: auto;
  max-height: 58vh;
  object-fit: contain;
}

.poster-modal__loading {
  position: absolute;
  color: #e2e8f0;
  font-size: 14px;
}

.poster-modal__hint {
  margin: 12px 0;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

.poster-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.btn-share-native {
  background: #059669;
  color: #fff;
}

.btn-share-native:hover {
  background: #047857;
  color: #fff;
}

.geo-facts {
  border-color: #bfdbfe;
  background: linear-gradient(180deg, #eff6ff 0%, #fff 48%);
}

.geo-fact-list {
  margin: 8px 0 12px;
  padding-left: 20px;
}

.geo-fact-list li {
  margin-bottom: 8px;
  color: #334155;
  font-size: 14px;
}

.geo-fact-list strong {
  color: #0f172a;
}

.section-head .update-tag {
  margin-bottom: 0;
}

.float-share {
  position: fixed;
  right: 16px;
  bottom: 24px;
  z-index: 45;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.2);
}

.disclaimer {
  font-size: 14px;
  color: var(--muted);
}

.disclaimer strong {
  color: var(--text);
}

.site-footer {
  text-align: center;
  color: #94a3b8;
  font-size: 13px;
  padding: 8px 16px 32px;
}

.site-footer p {
  margin: 4px 0;
}

.site-footer a {
  color: #64748b;
}

.site-footer a:hover {
  color: var(--primary);
}

#contact {
  scroll-margin-top: 130px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%) translateY(20px);
  background: #0f172a;
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.2s ease;
  z-index: 100;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

@media (max-width: 640px) {
  .page-hero h1 {
    font-size: 22px;
  }

  .site-header .inner {
    flex-direction: column;
    align-items: flex-start;
    padding: 12px 16px;
  }

  .coupon-code {
    font-size: 16px;
  }

  .toc-sticky {
    top: 0;
    border-radius: 0;
    margin-left: -16px;
    margin-right: -16px;
    width: calc(100% + 32px);
    border-left: none;
    border-right: none;
  }

  #pick,
  #buy,
  #all-plans {
    scroll-margin-top: 100px;
  }
}
