/* IPTV Primeus — 品牌色在 :root 统一改 */
:root {
  --bg: #07090d;
  --bg-alt: #0d1117;
  --card: #121822;
  --line: #1f2733;
  --text: #e8edf3;
  --muted: #8b97a8;
  --accent: #22c55e;
  --accent-2: #06b6d4;
  --accent-ink: #04130a;
  --radius: 14px;
  --container: 1160px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .6em; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 800; }
h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 800; }
h3 { font-size: 1.125rem; font-weight: 600; }
p { margin: 0 0 1em; }
ul, ol { padding: 0; margin: 0; list-style: none; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 820px; }
.center { text-align: center; justify-content: center; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.eyebrow { color: var(--accent); font-size: .8rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; margin-bottom: .75em; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 680px; }
.grad { background: linear-gradient(90deg, var(--accent), var(--accent-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: var(--accent); color: var(--accent-ink); padding: 8px 12px; border-radius: 8px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 22px; border-radius: 10px; font-weight: 600; border: 1px solid transparent; cursor: pointer; font-size: 1rem; transition: transform .15s, background .15s, border-color .15s; }
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn--primary { background: var(--accent); color: var(--accent-ink); }
.btn--primary:hover { background: #2fdc6c; }
.btn--ghost { border-color: var(--line); color: var(--text); background: transparent; }
.btn--ghost:hover { border-color: var(--accent); }
.btn--sm { padding: 8px 14px; font-size: .9rem; }
.btn--lg { padding: 15px 28px; font-size: 1.05rem; }
.btn--block { width: 100%; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(7, 9, 13, .85); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.nav-wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.nav { display: flex; align-items: center; gap: 22px; }
.nav a:not(.btn) { color: var(--text); font-size: .95rem; opacity: .85; }
.nav a:not(.btn):hover, .nav a.is-current { opacity: 1; color: var(--accent); text-decoration: none; }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--text); margin: 5px 0; transition: .2s; }

/* Hero */
.hero { position: relative; padding: 96px 0 72px; overflow: hidden; text-align: center;
  background: radial-gradient(60% 60% at 50% 0%, rgba(34, 197, 94, .18), transparent 70%), radial-gradient(40% 40% at 85% 30%, rgba(6, 182, 212, .12), transparent 70%); }
/* TODO 有真实 hero 图/视频后可在 .hero 加背景（避免版权台标） */
.hero-inner { display: flex; flex-direction: column; align-items: center; }
.hero .lead { margin: 0 auto; }
.hero .cta-row { justify-content: center; }
.trust { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 20px; margin-top: 24px; color: var(--muted); font-size: .9rem; }
.trust li::before { content: "✓ "; color: var(--accent); }
.page-hero { padding: 72px 0 40px; border-bottom: 1px solid var(--line);
  background: radial-gradient(50% 80% at 20% 0%, rgba(34, 197, 94, .12), transparent 70%); }

/* Stats */
.stats-bar { border-block: 1px solid var(--line); background: var(--bg-alt); }
.stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; padding-block: 28px; text-align: center; }
.stat strong { display: block; font-size: 1.6rem; font-weight: 800; }
.stat span { color: var(--muted); font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; }

/* Sections */
.section { padding: 80px 0; }
.section--alt { background: var(--bg-alt); }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 40px; }
.section-head p:not(.eyebrow) { color: var(--muted); }
.note { text-align: center; color: var(--muted); margin-top: 24px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.placeholder { border-style: dashed; opacity: .7; }

.intro { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.intro p:not(.eyebrow) { color: var(--muted); }
.feature-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.feature-grid--4 { grid-template-columns: repeat(4, 1fr); }
.feature-grid li, .cat-grid li, .guide-grid li { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.feature-grid p, .cat-grid p { color: var(--muted); margin: 0; font-size: .95rem; }

/* Pricing */
.tabs { display: flex; justify-content: center; gap: 4px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 4px; width: fit-content; margin: 0 auto 32px; }
.tab { background: none; border: 0; color: var(--muted); padding: 10px 22px; border-radius: 999px; font: inherit; font-weight: 600; cursor: pointer; }
.tab.is-active { background: var(--accent); color: var(--accent-ink); }
.plans { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.plan { position: relative; display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 22px; }
.plan--hot { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 20px 50px -20px rgba(34, 197, 94, .45); }
.badge { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); background: var(--accent); color: var(--accent-ink); font-size: .75rem; font-weight: 800; padding: 4px 12px; border-radius: 999px; white-space: nowrap; }
.plan h3 { margin-bottom: 2px; }
.plan-type { color: var(--muted); font-size: .85rem; margin: 0; }
.price { font-size: 2.6rem; font-weight: 800; margin: 12px 0 16px; }
.price sup { font-size: 1.1rem; vertical-align: super; color: var(--muted); }
.checks { margin-bottom: 22px; flex: 1; }
.checks li { position: relative; padding-left: 24px; margin-bottom: 8px; font-size: .92rem; color: var(--muted); }
.checks li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 800; }

/* Steps / devices / reviews */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: s; }
.steps li { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.steps span { display: inline-block; font-weight: 800; font-size: 1.6rem; color: var(--accent); margin-bottom: 8px; }
.steps p { color: var(--muted); margin: 0; }
.devices { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.devices li { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 18px 10px; text-align: center; font-weight: 500; font-size: .92rem; }
.reviews { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.review { margin: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.review blockquote { margin: 0 0 12px; }
.review figcaption { color: var(--muted); font-size: .9rem; }

/* FAQ */
.faq { margin-bottom: 32px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 18px 32px 18px 0; font-weight: 600; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; color: var(--accent); font-size: 1.3rem; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq details p { color: var(--muted); padding-bottom: 12px; }

/* CTA band */
.cta-band { padding: 64px 0; background: linear-gradient(120deg, rgba(34, 197, 94, .16), rgba(6, 182, 212, .12)); border-top: 1px solid var(--line); }
.cta-band-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.cta-band p { color: var(--muted); margin: 0; }
.cta-band .cta-row { margin: 0; }

/* Inner pages */
.split { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: start; }
.form label { display: block; font-size: .9rem; font-weight: 500; margin-bottom: 14px; }
.form input, .form select { display: block; width: 100%; margin-top: 6px; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg); color: var(--text); font: inherit; }
.form input:focus, .form select:focus { border-color: var(--accent); outline: none; }
.form-error { color: #f87171; margin: 12px 0 0; font-size: .9rem; }
.cat-grid, .guide-grid, .post-grid, .contact-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.guide-grid, .post-grid, .contact-grid { grid-template-columns: repeat(3, 1fr); }
.guide-grid ol { list-style: decimal; padding-left: 20px; color: var(--muted); font-size: .92rem; }
.guide-grid ol li { margin-bottom: 6px; }
.cat-grid + .cta-row, .guide-grid + .cta-row { margin-top: 40px; }
.contact-grid .card p { color: var(--muted); }
.table-wrap { overflow-x: auto; margin-bottom: 40px; }
.compare { width: 100%; border-collapse: collapse; }
.compare th, .compare td { padding: 14px 16px; border-bottom: 1px solid var(--line); text-align: left; }
.compare th { color: var(--accent); }
.prose h2 { font-size: 1.35rem; margin-top: 1.6em; }
.prose p { color: var(--muted); }

/* Setup guides */
.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; font-size: .85rem; color: var(--muted); margin-bottom: 20px; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--accent); }
.guide-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.guide-meta li { border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; font-size: .85rem; color: var(--muted); }
.guide-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.guide-card { display: flex; flex-direction: column; height: 100%; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; color: var(--text); transition: border-color .15s, transform .15s; }
.guide-card:hover { border-color: var(--accent); transform: translateY(-2px); text-decoration: none; }
.guide-card p { color: var(--muted); font-size: .92rem; flex: 1; }
.guide-card span { color: var(--accent); font-weight: 600; font-size: .92rem; }
.guide-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 48px; align-items: start; }
.guide h2 { scroll-margin-top: 88px; }
.guide h2:first-child { margin-top: 0; }
.guide .checks { margin-bottom: 8px; }
.step-list { list-style: none; counter-reset: step; margin-bottom: 1em; }
.step-list > li { counter-increment: step; position: relative; padding: 0 0 14px 44px; color: var(--muted); }
.step-list > li::before { content: counter(step); position: absolute; left: 0; top: -2px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(34, 197, 94, .14); color: var(--accent); font-weight: 800; font-size: .9rem; }
.step-list strong, .prose strong { color: var(--text); }
.step-list ul { list-style: disc; padding-left: 20px; margin-top: 8px; }
.step-list ul li { margin-bottom: 6px; }
.tip { border-left: 3px solid var(--accent); background: var(--card); padding: 14px 16px; border-radius: 0 10px 10px 0; font-size: .95rem; }
.prose code { background: var(--card); border: 1px solid var(--line); padding: 1px 6px; border-radius: 6px; font-size: .88em; color: var(--text); }
.guide-aside { position: sticky; top: 88px; display: grid; gap: 16px; }
.guide-aside h3 { margin-bottom: 6px; }
.guide-nav li a { display: block; padding: 8px 0; border-bottom: 1px solid var(--line); color: var(--text); font-size: .92rem; }
.guide-nav li:last-child a { border-bottom: 0; }
.guide-nav a[aria-current="page"] { color: var(--accent); font-weight: 600; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 56px 0 24px; background: var(--bg-alt); }
.footer-grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 32px; }
.footer-grid h4 { font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.footer-grid a { display: block; color: var(--text); opacity: .85; margin-bottom: 8px; font-size: .92rem; }
.footer-grid .muted { margin-top: 14px; font-size: .92rem; }
.footer-bottom { border-top: 1px solid var(--line); margin-top: 40px; padding-top: 20px; color: var(--muted); font-size: .85rem; }
.footer-bottom p { margin: 0 0 4px; }

.wa-float { position: fixed; right: 18px; bottom: 18px; z-index: 60; width: 56px; height: 56px; border-radius: 50%; background: #25d366; color: #fff; display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0, 0, 0, .4); }
.wa-float:hover { transform: scale(1.06); }

/* Responsive */
@media (max-width: 1024px) {
  .plans, .feature-grid--4, .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .devices { grid-template-columns: repeat(4, 1fr); }
  .footer-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav { position: fixed; inset: 68px 0 auto; flex-direction: column; align-items: stretch; gap: 0; background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px 16px 20px; display: none; }
  .nav.is-open { display: flex; }
  .nav a:not(.btn) { padding: 14px 0; border-bottom: 1px solid var(--line); }
  .nav .btn { margin-top: 16px; }
  .intro, .split, .steps, .reviews, .guide-grid, .post-grid, .contact-grid, .guide-layout { grid-template-columns: 1fr; }
  .guide-cards { grid-template-columns: repeat(2, 1fr); }
  .guide-aside { position: static; }
  .stats { grid-template-columns: repeat(3, 1fr); }
  .section { padding: 60px 0; }
  .hero { padding: 64px 0 52px; }
}
@media (max-width: 560px) {
  .plans, .feature-grid, .feature-grid--4, .cat-grid, .guide-cards { grid-template-columns: 1fr; }
  .devices { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > div:first-child { grid-column: 1 / -1; }
  .cta-row .btn { flex: 1 1 100%; }
}

/* Two-plan pricing */
.plans--2 { grid-template-columns: repeat(2, 1fr); max-width: 820px; margin: 0 auto; }
.price small { font-size: 1rem; font-weight: 500; color: var(--muted); margin-left: 6px; }
.plan-trial { display: block; text-align: center; margin-top: 12px; font-size: .9rem; }
@media (max-width: 560px) { .plans--2 { grid-template-columns: 1fr; } }
.checkout-note { max-width: 820px; margin: 20px auto 0; text-align: center; color: var(--muted); font-size: .88rem; }

/* Free trial */
.trial-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; align-items: stretch; }
.trial-card { display: flex; flex-direction: column; }
.trial-card h2 { font-size: 1.35rem; }
.trial-card .step-list { flex: 1; margin-top: 8px; }
.trial-card .small { margin: 12px 0 0; text-align: center; }
.trial-after { text-align: center; margin-top: 48px; }
.trial-after h2 { font-size: 1.4rem; }
.form-status { margin: 12px 0 0; }
.form-status.is-ok { color: var(--accent); }
.form-status.is-error { color: #f87171; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
@media (max-width: 860px) { .trial-grid { grid-template-columns: 1fr; } }
