/* ============================================================
   Star IPTV — Design System
   Tema escuro premium (streaming). Violeta + Ciano + estrela dourada.
   ============================================================ */

:root {
  /* Cores base */
  --bg: #0b0b12;
  --bg-2: #10101c;
  --surface: #16162490;
  --surface-solid: #171728;
  --border: #262637;
  --text: #edeef4;
  --muted: #a2a3ba;
  --muted-2: #74758c;

  /* Marca */
  --primary: #7c5cff;
  --primary-2: #9d86ff;
  --cyan: #22d3ee;
  --gold: #ffd166;
  --danger: #ff5d6c;
  --green: #34d399;

  --grad: linear-gradient(135deg, #7c5cff 0%, #22d3ee 100%);
  --grad-soft: linear-gradient(135deg, rgba(124,92,255,.18), rgba(34,211,238,.10));

  /* Tipografia */
  --font: "Inter", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;

  /* Layout */
  --max: 1160px;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 20px 60px -20px rgba(0, 0, 0, .6);
  --shadow-glow: 0 10px 40px -10px rgba(124, 92, 255, .5);
}

/* ---------- Reset / base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  font-size: 17px;
  overflow-x: hidden;
  background-image:
    radial-gradient(900px 500px at 15% -5%, rgba(124,92,255,.16), transparent 60%),
    radial-gradient(800px 500px at 100% 0%, rgba(34,211,238,.10), transparent 55%);
  background-attachment: fixed;
}
img { max-width: 100%; display: block; }
a { color: var(--primary-2); text-decoration: none; transition: color .2s; }
a:hover { color: var(--cyan); }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; font-weight: 800; letter-spacing: -.02em; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.3rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1rem; color: var(--muted); }
ul, ol { color: var(--muted); }
strong { color: var(--text); }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 22px; }
.section { padding: 84px 0; }
.center { text-align: center; }
.muted { color: var(--muted); }
.gradient-text {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--cyan); margin-bottom: 14px;
}
.eyebrow::before { content: "★"; color: var(--gold); }
.lead { font-size: 1.15rem; max-width: 640px; }
.section-head { max-width: 680px; margin: 0 auto 52px; text-align: center; }

/* ---------- Botões ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 14px 26px; border-radius: 999px; font-weight: 700; font-size: 1rem;
  cursor: pointer; border: 1px solid transparent; transition: transform .18s, box-shadow .2s, background .2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--grad); color: #0b0b12; box-shadow: var(--shadow-glow); }
.btn-primary:hover { color: #0b0b12; box-shadow: 0 14px 46px -8px rgba(124,92,255,.65); }
.btn-ghost { background: rgba(255,255,255,.04); color: var(--text); border-color: var(--border); }
.btn-ghost:hover { color: var(--text); border-color: var(--primary); background: rgba(124,92,255,.10); }
.btn-wa { background: #25d366; color: #06301a; }
.btn-wa:hover { color: #06301a; box-shadow: 0 14px 40px -10px rgba(37,211,102,.6); }
.btn-lg { padding: 17px 34px; font-size: 1.08rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(11,11,18,.72);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 900; font-size: 1.25rem; letter-spacing: -.02em; color: var(--text); }
.brand:hover { color: var(--text); }
.brand .star {
  width: 34px; height: 34px; border-radius: 9px;
  background: url("../images/star-mark.svg") center/cover no-repeat;
  color: transparent; font-size: 0; box-shadow: var(--shadow-glow);
}
.brand b { color: var(--primary-2); }
.nav-links { display: flex; align-items: center; gap: 28px; list-style: none; margin: 0; padding: 0; }
.nav-links a { color: var(--muted); font-weight: 600; font-size: .96rem; }
.nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-toggle { display: none; background: none; border: 0; color: var(--text); cursor: pointer; padding: 6px; }
.nav-toggle svg { width: 28px; height: 28px; }

/* ---------- Hero ---------- */
.hero { position: relative; padding: 76px 0 70px; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 54px; align-items: center; }
.hero h1 { margin-bottom: 18px; }
.hero .lead { margin-bottom: 30px; font-size: 1.2rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 26px; }
.hero-stats { display: flex; gap: 30px; flex-wrap: wrap; }
.hero-stats .stat b { display: block; font-size: 1.7rem; font-weight: 900; color: var(--text); }
.hero-stats .stat span { font-size: .85rem; color: var(--muted-2); }
.hero-visual {
  position: relative; border-radius: 22px; padding: 22px;
  background: var(--grad-soft); border: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.hero-visual .screen {
  border-radius: 14px; background: var(--surface-solid); border: 1px solid var(--border);
  padding: 18px; aspect-ratio: 16/10; display: flex; flex-direction: column; gap: 12px;
}
.hero-visual .row { display: flex; gap: 10px; }
.hero-visual .tile { flex: 1; border-radius: 8px; height: 54px; background: linear-gradient(135deg, rgba(124,92,255,.35), rgba(34,211,238,.2)); }
.hero-visual .tile:nth-child(2) { background: linear-gradient(135deg, rgba(255,209,102,.3), rgba(124,92,255,.25)); }
.hero-visual .tile.big { height: 120px; }
.badge-float {
  position: absolute; right: -14px; top: -14px; background: var(--surface-solid);
  border: 1px solid var(--border); border-radius: 12px; padding: 10px 14px; font-size: .82rem;
  font-weight: 700; box-shadow: var(--shadow); display: flex; align-items: center; gap: 8px;
}
.badge-float .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); }

/* ---------- Cards / grid ---------- */
.grid { display: grid; gap: 22px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px; transition: transform .2s, border-color .2s, box-shadow .2s; backdrop-filter: blur(6px);
}
.card:hover { transform: translateY(-4px); border-color: var(--primary); box-shadow: var(--shadow); }
.card .ico {
  width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center;
  background: var(--grad-soft); border: 1px solid var(--border); font-size: 1.4rem; margin-bottom: 16px;
}
.card h3 { margin-bottom: 8px; }
.card p { margin: 0; font-size: .98rem; }

/* Card de artigo (blog) */
.post-card { display: flex; flex-direction: column; padding: 0; overflow: hidden; }
.post-card .thumb { aspect-ratio: 16/9; background: var(--grad-soft); display: grid; place-items: center; font-size: 2.4rem; }
.post-card .body { padding: 22px 24px 26px; }
.post-card .tag { font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--cyan); }
.post-card h3 { margin: 8px 0 8px; font-size: 1.14rem; }
.post-card h3 a { color: var(--text); }
.post-card h3 a:hover { color: var(--primary-2); }
.post-card p { font-size: .94rem; margin-bottom: 14px; }
.post-card .more { font-weight: 700; font-size: .9rem; }

/* ---------- FAQ ---------- */
.faq { max-width: 780px; margin: 0 auto; }
.faq-item { border: 1px solid var(--border); border-radius: var(--radius-sm); margin-bottom: 12px; background: var(--surface); overflow: hidden; }
.faq-q {
  width: 100%; text-align: left; background: none; border: 0; color: var(--text);
  font-size: 1.05rem; font-weight: 700; padding: 20px 22px; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq-q .chev { transition: transform .25s; color: var(--primary-2); flex-shrink: 0; }
.faq-item.open .chev { transform: rotate(180deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .3s ease; }
.faq-a p { padding: 0 22px 20px; margin: 0; }

/* ---------- CTA band ---------- */
.cta-band {
  background: var(--grad-soft); border: 1px solid var(--border); border-radius: 24px;
  padding: 54px 40px; text-align: center; position: relative; overflow: hidden;
}
.cta-band h2 { margin-bottom: 12px; }
.cta-band p { max-width: 560px; margin: 0 auto 26px; }
.cta-band .hero-cta { justify-content: center; }

/* ---------- Article (conteúdo) ---------- */
.article-head { padding: 60px 0 30px; }
.breadcrumb { font-size: .85rem; color: var(--muted-2); margin-bottom: 18px; }
.breadcrumb a { color: var(--muted); }
.article-meta { display: flex; gap: 16px; align-items: center; color: var(--muted-2); font-size: .88rem; margin-top: 14px; }
.article-body { max-width: 760px; margin: 0 auto; padding-bottom: 40px; }
.article-body h2 { margin-top: 44px; padding-top: 8px; }
.article-body h3 { margin-top: 30px; color: var(--primary-2); }
.article-body p, .article-body li { font-size: 1.06rem; }
.article-body ul, .article-body ol { padding-left: 22px; margin-bottom: 1.2rem; }
.article-body li { margin-bottom: .5rem; }
.article-body img { border-radius: var(--radius); border: 1px solid var(--border); margin: 24px 0; }
.callout {
  background: var(--grad-soft); border: 1px solid var(--border); border-left: 3px solid var(--primary);
  border-radius: var(--radius-sm); padding: 18px 22px; margin: 26px 0;
}
.callout p { margin: 0; color: var(--text); }
.callout strong { color: var(--cyan); }
.toc { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 20px 24px; margin: 26px 0; }
.toc strong { display: block; margin-bottom: 10px; }
.toc ol { margin: 0; }
.toc a { color: var(--muted); }
.toc a:hover { color: var(--cyan); }

/* Tabela responsiva */
.table-wrap { overflow-x: auto; margin: 24px 0; border-radius: var(--radius-sm); border: 1px solid var(--border); }
table { width: 100%; border-collapse: collapse; font-size: .96rem; min-width: 460px; }
th, td { padding: 13px 16px; text-align: left; border-bottom: 1px solid var(--border); }
th { background: var(--surface-solid); color: var(--text); font-weight: 700; }
td { color: var(--muted); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); background: var(--bg-2); padding: 60px 0 30px; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-grid h4 { font-size: .82rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted-2); margin-bottom: 16px; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 10px; }
.footer-grid a { color: var(--muted); font-size: .95rem; }
.footer-grid a:hover { color: var(--cyan); }
.footer-brand p { font-size: .95rem; max-width: 280px; margin-top: 14px; }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 22px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; color: var(--muted-2); font-size: .86rem; }
.footer-legal-note { font-size: .8rem; color: var(--muted-2); max-width: 760px; margin-top: 18px; line-height: 1.6; }

/* ---------- WhatsApp flutuante ---------- */
.wa-float {
  position: fixed; right: 20px; bottom: 20px; z-index: 60;
  width: 58px; height: 58px; border-radius: 50%; background: #25d366; display: grid; place-items: center;
  box-shadow: 0 10px 30px rgba(37,211,102,.5); transition: transform .2s;
}
.wa-float:hover { transform: scale(1.08); }
.wa-float svg { width: 30px; height: 30px; fill: #fff; }

/* ---------- Pills / lista de canais ---------- */
.pills { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.pill { background: var(--surface); border: 1px solid var(--border); border-radius: 999px; padding: 8px 16px; font-size: .9rem; color: var(--muted); font-weight: 600; }

/* ---------- Responsivo ---------- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-visual { order: -1; }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
  .nav-links, .nav-actions .btn-desktop { display: none; }
  .nav-toggle { display: block; }
  .nav-links.open {
    display: flex; flex-direction: column; position: absolute; top: 72px; left: 0; right: 0;
    background: var(--bg-2); border-bottom: 1px solid var(--border); padding: 18px 22px; gap: 16px;
  }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .section { padding: 60px 0; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-cta { flex-direction: column; align-items: stretch; }
  .hero-cta .btn { justify-content: center; }
  .cta-band { padding: 40px 22px; }
}

/* ============================================================
   Modal — Gerar teste grátis
   ============================================================ */
.modal-overlay {
  position: fixed; inset: 0; z-index: 100; display: none;
  align-items: center; justify-content: center; padding: 20px;
  background: rgba(4, 4, 10, .72); backdrop-filter: blur(6px);
}
.modal-overlay.open { display: flex; }
.modal {
  width: 100%; max-width: 460px; background: var(--surface-solid);
  border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 30px 28px; position: relative;
  animation: modalIn .22s ease;
}
@keyframes modalIn { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }
.modal-close {
  position: absolute; top: 14px; right: 14px; width: 34px; height: 34px;
  border: 1px solid var(--border); background: rgba(255,255,255,.03); color: var(--muted);
  border-radius: 9px; cursor: pointer; font-size: 1.1rem; line-height: 1; transition: color .2s, border-color .2s;
}
.modal-close:hover { color: var(--text); border-color: var(--primary); }
.modal .m-star {
  width: 46px; height: 46px; border-radius: 12px; margin-bottom: 14px;
  background: url("../images/star-mark.svg") center/cover no-repeat; box-shadow: var(--shadow-glow);
}
.modal h3 { font-size: 1.35rem; margin-bottom: 6px; }
.modal .m-sub { color: var(--muted); font-size: .96rem; margin-bottom: 20px; }
.modal label { display: block; font-size: .85rem; font-weight: 700; color: var(--muted); margin-bottom: 7px; }
.modal input[type="tel"] {
  width: 100%; padding: 14px 16px; border-radius: var(--radius-sm); font-size: 1.05rem;
  background: var(--bg-2); border: 1px solid var(--border); color: var(--text); outline: none; transition: border-color .2s;
}
.modal input[type="tel"]:focus { border-color: var(--primary); }
.modal .hp { position: absolute; left: -9999px; opacity: 0; height: 0; width: 0; }
.modal .btn { width: 100%; justify-content: center; margin-top: 16px; }
.modal .m-hint { font-size: .8rem; color: var(--muted-2); margin-top: 12px; text-align: center; }
.modal .m-error { color: var(--danger); font-size: .9rem; margin-top: 12px; display: none; }

/* Loading */
.modal .m-loading { display: none; text-align: center; padding: 14px 0; color: var(--muted); }
.spinner {
  width: 34px; height: 34px; margin: 0 auto 12px; border-radius: 50%;
  border: 3px solid var(--border); border-top-color: var(--primary); animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Resultado */
.modal .m-result { display: none; }
.cred {
  background: var(--bg-2); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 6px 4px; margin: 6px 0 16px;
}
.cred-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 14px; border-bottom: 1px solid var(--border); }
.cred-row:last-child { border-bottom: 0; }
.cred-row .k { font-size: .8rem; color: var(--muted-2); text-transform: uppercase; letter-spacing: .04em; }
.cred-row .v { font-weight: 700; color: var(--text); font-size: 1.02rem; word-break: break-all; text-align: right; }
.m-result .ok-badge { display: inline-flex; align-items: center; gap: 7px; color: var(--green); font-weight: 700; font-size: .95rem; margin-bottom: 10px; }
.m-result .btn-copy { width: 100%; justify-content: center; margin-top: 0; margin-bottom: 10px; }
.cred-row #r-code { color: var(--cyan); letter-spacing: .04em; }
.m-apps { background: var(--grad-soft); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px 16px; margin: 0 0 16px; }
.m-apps strong { display: block; font-size: .95rem; margin-bottom: 4px; }
.m-apps p { font-size: .85rem; color: var(--muted); margin: 0 0 8px; }
.m-apps .m-apps-list { font-size: .85rem; color: var(--text); font-weight: 600; line-height: 1.7; }

/* ---------- Botão flutuante "Gerar teste" (mobile) ---------- */
.teste-float {
  position: fixed; left: 16px; bottom: 20px; z-index: 60;
  display: none; align-items: center; gap: 8px;
  padding: 14px 20px; border: none; border-radius: 999px;
  background: var(--grad); color: #0b0b12; font-family: var(--font);
  font-weight: 800; font-size: 1rem; cursor: pointer;
  box-shadow: 0 10px 30px -6px rgba(124, 92, 255, .6);
  animation: testePulse 2.6s ease-in-out infinite;
}
.teste-float:active { transform: scale(.97); }
@keyframes testePulse {
  0%, 100% { box-shadow: 0 10px 28px -8px rgba(124, 92, 255, .55); }
  50%      { box-shadow: 0 12px 36px -6px rgba(34, 211, 238, .7); }
}
/* Aparece só no mobile/tablet (no desktop já existe o botão no topo) */
@media (max-width: 900px) { .teste-float { display: inline-flex; } }
