/* iptv.chat — technical reference.
   One stylesheet, no framework, no external fonts: every byte is served from
   this origin so the page renders even when a CDN is blocked, and there is
   nothing for a third party to track. */

:root {
  --bg: #0b0f14;
  --bg-2: #111823;
  --panel: #141d2a;
  --line: #1f2c3d;
  --ink: #e6edf5;
  --muted: #8b9cb3;
  --accent: #2ee6c5;
  --accent-2: #4aa8ff;
  --warn: #ffb347;
  --radius: 14px;
  --wrap: 1120px;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.7 var(--sans);
  -webkit-font-smoothing: antialiased;
}

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 22px; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.skip {
  position: absolute; left: -9999px; top: 0; background: var(--accent);
  color: #04121a; padding: 10px 16px; z-index: 100; border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; }

/* ---------------------------------------------------------------- header */
header.site {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 15, 20, .88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.bar { display: flex; align-items: center; gap: 26px; height: 66px; }
.logo { font-family: var(--mono); font-weight: 700; font-size: 19px; letter-spacing: -.5px; color: var(--ink); }
.logo b { color: var(--accent); }
nav.main { display: flex; gap: 22px; margin-left: auto; flex-wrap: wrap; }
nav.main a { color: var(--muted); font-size: 14.5px; }
nav.main a:hover, nav.main a[aria-current="page"] { color: var(--ink); text-decoration: none; }

/* ------------------------------------------------------------------ hero */
.hero { padding: 74px 0 54px; border-bottom: 1px solid var(--line);
        background: radial-gradient(900px 400px at 15% -10%, rgba(46,230,197,.10), transparent 65%); }
.kicker { font-family: var(--mono); font-size: 12.5px; letter-spacing: 2px;
          text-transform: uppercase; color: var(--accent); margin-bottom: 16px; }
h1 { font-size: clamp(30px, 5vw, 50px); line-height: 1.12; margin: 0 0 20px; letter-spacing: -1px; }
.lede { font-size: 18.5px; color: var(--muted); max-width: 68ch; margin: 0 0 26px; }

/* --------------------------------------------------------------- sections */
section { padding: 62px 0; border-bottom: 1px solid var(--line); }
section:last-of-type { border-bottom: 0; }
h2 { font-size: clamp(23px, 3.2vw, 31px); margin: 0 0 14px; letter-spacing: -.5px; }
h3 { font-size: 19px; margin: 30px 0 10px; }
p { margin: 0 0 16px; max-width: 74ch; }
.muted { color: var(--muted); }
.small { font-size: 14.5px; }

/* ----------------------------------------------------------------- panels */
.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(auto-fit, minmax(310px, 1fr)); }
.g3 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }

.card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px;
}
.card h3 { margin-top: 0; font-size: 17px; }
.card p:last-child { margin-bottom: 0; }
.card .tag { font-family: var(--mono); font-size: 11.5px; color: var(--accent);
             letter-spacing: 1.2px; text-transform: uppercase; display: block; margin-bottom: 8px; }

/* -------------------------------------------------------------- directory */
.site-card {
  display: block; background: var(--bg-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px; transition: border-color .16s, transform .16s;
}
.site-card:hover { border-color: var(--accent); transform: translateY(-2px); text-decoration: none; }
.site-card .brand { font-weight: 700; font-size: 16.5px; color: var(--ink); display: block; }
.site-card .host { font-family: var(--mono); font-size: 12.5px; color: var(--accent); display: block; margin: 5px 0 10px; }
.site-card .desc { color: var(--muted); font-size: 14.5px; margin: 0; }

/* ------------------------------------------------------------------ table */
.tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
table { border-collapse: collapse; width: 100%; min-width: 540px; font-size: 14.8px; }
th, td { text-align: left; padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--bg-2); font-size: 12.5px; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); }
tr:last-child td { border-bottom: 0; }
code { font-family: var(--mono); font-size: .92em; background: var(--bg-2);
       border: 1px solid var(--line); padding: 1px 6px; border-radius: 5px; color: var(--accent); }

/* ------------------------------------------------------------------- misc */
ul.clean { list-style: none; padding: 0; margin: 0 0 16px; }
ul.clean li { padding-left: 24px; position: relative; margin-bottom: 10px; color: var(--muted); }
ul.clean li::before { content: "▸"; position: absolute; left: 4px; color: var(--accent); }

.note { border-left: 3px solid var(--accent-2); background: var(--bg-2);
        padding: 16px 18px; border-radius: 0 10px 10px 0; margin: 22px 0; }
.note p:last-child { margin-bottom: 0; }
.note strong { color: var(--ink); }

.btn { display: inline-block; background: var(--accent); color: #04121a; font-weight: 700;
       padding: 13px 24px; border-radius: 10px; font-size: 15px; }
.btn:hover { text-decoration: none; opacity: .9; }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }

details { border: 1px solid var(--line); border-radius: 10px; padding: 15px 18px;
          margin-bottom: 11px; background: var(--panel); }
details summary { cursor: pointer; font-weight: 600; }
details p { margin: 12px 0 0; color: var(--muted); }

/* ---------------------------------------------------------------- footer */
footer.site { padding: 46px 0 90px; color: var(--muted); font-size: 14.5px; border-top: 1px solid var(--line); }
footer.site a { color: var(--muted); }
footer.site a:hover { color: var(--accent); }
.fgrid { display: grid; gap: 26px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); margin-bottom: 30px; }
.fgrid h4 { color: var(--ink); font-size: 13px; letter-spacing: 1.4px; text-transform: uppercase; margin: 0 0 12px; }
.fgrid ul { list-style: none; padding: 0; margin: 0; }
.fgrid li { margin-bottom: 8px; }

/* ------------------------------------------------------- whatsapp button */
.wa {
  position: fixed; right: 20px; bottom: 20px; z-index: 90;
  display: inline-flex; align-items: center; gap: 12px;
  background: #25d366; color: #06281a; border-radius: 999px;
  padding: 13px 20px 13px 15px; font-weight: 700; font-size: 15px;
  box-shadow: 0 10px 30px rgba(37, 211, 102, .34);
}
.wa:hover { text-decoration: none; }
.wa svg { width: 25px; height: 25px; flex: none; }
.wa .lab { display: flex; flex-direction: column; line-height: 1.24; }
.wa .lab i { font-style: normal; font-size: 11.5px; font-weight: 500; opacity: .82; }
.wa::before {
  content: ""; position: absolute; inset: 0; border-radius: 999px;
  border: 2px solid #25d366; animation: wa-ring 2.4s ease-out infinite;
}
@keyframes wa-ring {
  0%   { transform: scale(1);    opacity: .75; }
  70%  { transform: scale(1.32); opacity: 0; }
  100% { transform: scale(1.32); opacity: 0; }
}
@media (max-width: 560px) {
  .wa .lab { display: none; }
  .wa { padding: 15px; border-radius: 50%; }
}
@media (prefers-reduced-motion: reduce) {
  .wa::before { animation: none; }
  html { scroll-behavior: auto; }
}
