:root {
  --bg: #f6f5fb; --surface: #fff; --surface-2: #f1eefb; --border: #e2ddf2;
  --text: #1d1838; --muted: #6b6788; --primary: #6441d0; --primary-ink: #fff;
  --brand-deep: #1b1147; --brand-light: #ad99fd;
  --ok: #2e7d32; --bad: #c62828; --warn: #b26a00; --radius: 10px;
  --shadow: 0 1px 2px rgba(0,0,0,.06), 0 2px 8px rgba(0,0,0,.04);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e0b1c; --surface: #17132b; --surface-2: #211b3d; --border: #2f2852;
    --text: #ece9f8; --muted: #a29dbd; --primary: #ad99fd; --primary-ink: #1b1147;
    --ok: #66bb6a; --bad: #ef5350; --warn: #ffb74d; color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { overflow-x: hidden; }
body { font: 14px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; background: var(--bg); color: var(--text); }
a { color: var(--primary); }
h1 { font-size: 20px; margin: 0; }
h2 { font-size: 16px; margin: 0 0 12px; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.warn { color: var(--warn); }
.hidden { display: none !important; }

/* layout */
.layout { display: grid; grid-template-columns: 220px 1fr; min-height: 100vh; }
.sidebar { background: var(--surface); border-right: 1px solid var(--border); padding: 16px 10px; position: sticky; top: 0; height: 100vh; }
.brand { display: flex; gap: 8px; align-items: center; font-weight: 700; font-size: 16px; padding: 4px 10px 16px; }
.brand img { width: 26px; height: 34px; }
.brand span { letter-spacing: -.2px; }
.nav a { display: flex; gap: 10px; align-items: center; padding: 9px 12px; border-radius: 8px; color: var(--text); text-decoration: none; margin-bottom: 2px; }
.nav a:hover { background: var(--surface-2); }
.nav a.active { background: color-mix(in srgb, var(--primary) 14%, transparent); color: var(--primary); font-weight: 600; }
.main { padding: 20px 24px 60px; min-width: 0; overflow-x: hidden; }
.topbar { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.topbar .spacer { flex: 1; }
.btn.menu-btn { display: none; }
@media (max-width: 800px) {
  .layout { grid-template-columns: 1fr; }
  .sidebar { position: fixed; z-index: 20; inset: 0 auto 0 0; width: 240px; transform: translateX(-100%); transition: transform .2s; }
  .sidebar.open { transform: none; box-shadow: var(--shadow); }
  .btn.menu-btn { display: inline-flex; }
  #userBtn .role { display: none; }
  #pageActions { order: 5; width: 100%; flex-wrap: wrap; }
  .main { padding: 14px 16px 60px; }
}

/* componentes */
.btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--border); background: var(--surface); color: var(--text);
  padding: 7px 14px; border-radius: 8px; cursor: pointer; font: inherit; text-decoration: none; white-space: nowrap; }
.btn:hover { background: var(--surface-2); }
.btn.primary { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); font-weight: 600; }
.btn.primary:hover { filter: brightness(1.08); }
.btn.danger { color: var(--bad); }
.btn.icon { padding: 6px 8px; }
.btn:disabled { opacity: .5; cursor: default; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.card.pad { padding: 16px; }
.grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.grid.media { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.badge { display: inline-block; padding: 1px 8px; border-radius: 99px; font-size: 12px; background: var(--surface-2); color: var(--muted); }
.badge.ok { background: color-mix(in srgb, var(--ok) 15%, transparent); color: var(--ok); }
.badge.bad { background: color-mix(in srgb, var(--bad) 15%, transparent); color: var(--bad); }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; background: var(--bad); flex: none; }
.dot.ok { background: var(--ok); }
.tabs { display: inline-flex; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.tabs button { border: 0; background: var(--surface); color: var(--text); padding: 7px 14px; cursor: pointer; font: inherit; }
.tabs button + button { border-left: 1px solid var(--border); }
.tabs button.on { background: var(--primary); color: var(--primary-ink); }

table.list { width: 100%; border-collapse: collapse; }
table.list th, table.list td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
table.list th { font-size: 12px; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); font-weight: 600; }
table.list tr:last-child td { border-bottom: 0; }
table.list tr.click { cursor: pointer; }
table.list tr.click:hover td { background: var(--surface-2); }
.table-wrap { overflow-x: auto; }
.actions { display: flex; gap: 4px; justify-content: flex-end; }
table.list td.actions { display: table-cell; text-align: right; white-space: nowrap; }
table.list td.actions > * + * { margin-left: 4px; }

.screen-card .head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.screen-card .head strong { flex: 1; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.btn.sm { padding: 5px 10px; font-size: 12.5px; }
.screen-cmds { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--border); }
.kv { display: grid; grid-template-columns: 96px 1fr; gap: 2px 8px; font-size: 13px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; overflow-wrap: anywhere; }

.media-card { overflow: hidden; display: flex; flex-direction: column; }
.media-card .thumb { aspect-ratio: 16/10; background: #000; display: grid; place-items: center; overflow: hidden; position: relative; }
.thumb-badge { position: absolute; right: 6px; bottom: 6px; background: rgba(0,0,0,.7); color: #fff; font-size: 11px; padding: 1px 6px; border-radius: 4px; }
.pl-items .thumb { display: grid; place-items: center; }
.pl-items .thumb svg { width: 22px; height: 22px; }
.media-card .thumb img, .media-card .thumb video { width: 100%; height: 100%; object-fit: contain; }
.media-card .body { padding: 10px 12px; display: flex; gap: 6px; align-items: flex-start; }
.media-card .body > div { flex: 1; min-width: 0; }
.media-card .title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.pl-items { list-style: none; margin: 0; padding: 0; }
.pl-items li { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-bottom: 1px solid var(--border); background: var(--surface); }
.pl-items li:last-child { border-bottom: 0; }
.pl-items li.dragging { opacity: .4; }
.pl-items li.over { box-shadow: inset 0 2px 0 var(--primary); }
.pl-items .handle { cursor: grab; color: var(--muted); user-select: none; font-size: 18px; }
.pl-items .pos { width: 22px; color: var(--muted); text-align: right; }
.pl-items .thumb { width: 64px; height: 40px; background: #000; border-radius: 4px; overflow: hidden; flex: none; }
.pl-items .thumb img, .pl-items .thumb video { width: 100%; height: 100%; object-fit: cover; }
.pl-items .info { flex: 1; min-width: 0; }
.pl-items .info .t { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-items input[type=number] { width: 80px; flex: none; }
@media (max-width: 800px) { .pl-items .thumb, .pl-items .pos { display: none; } .pl-items li { flex-wrap: wrap; } }

/* formularios */
label.f { display: block; margin-bottom: 12px; }
label.f > span { display: block; font-size: 12px; color: var(--muted); margin-bottom: 4px; font-weight: 600; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=time], input[type=date], input[type=datetime-local], input[type=tel], input[type=url], select, textarea {
  width: 100%; padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); font: inherit; }
input:focus, select:focus { outline: 2px solid color-mix(in srgb, var(--primary) 40%, transparent); border-color: var(--primary); }
.row { display: flex; gap: 12px; }
.row > * { flex: 1; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border: 1px solid var(--border); border-radius: 99px; cursor: pointer; user-select: none; }
.chip input { margin: 0; }
.chip:has(input:checked) { background: color-mix(in srgb, var(--primary) 15%, transparent); border-color: var(--primary); }
.code-input { font-size: 30px !important; letter-spacing: 10px; text-align: center; font-variant-numeric: tabular-nums; }

/* modal */
dialog#modal { border: 0; border-radius: 14px; padding: 0; width: min(560px, calc(100vw - 32px)); background: var(--surface); color: var(--text); box-shadow: 0 10px 40px rgba(0,0,0,.3); }
dialog#modal::backdrop { background: rgba(10,14,20,.5); }
.modal-h { padding: 16px 20px 0; display: flex; align-items: center; }
.modal-h h2 { margin: 0; flex: 1; }
.modal-b { padding: 16px 20px; max-height: 70vh; overflow: auto; }
.modal-f { padding: 12px 20px 16px; display: flex; gap: 8px; justify-content: flex-end; border-top: 1px solid var(--border); }
.progress { height: 8px; background: var(--surface-2); border-radius: 99px; overflow: hidden; }
.progress > div { height: 100%; background: var(--primary); width: 0; transition: width .2s; }

/* toast */
#toasts { position: fixed; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; z-index: 100; }
.toast { background: #222b36; color: #fff; padding: 10px 16px; border-radius: 8px; box-shadow: var(--shadow); max-width: 90vw; white-space: pre-line; }
.toast.err { background: var(--bad); }

/* login */
.login { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.login-art { background: radial-gradient(1200px 600px at 20% 0%, #4b2fb8 0%, transparent 60%), linear-gradient(135deg, #0e0a24, #1b1147 55%, #2e1c7a);
  color: #fff; display: flex; flex-direction: column; justify-content: center; padding: 48px 56px; gap: 18px; }
.login-art .logo-box { width: 96px; height: 96px; border-radius: 26px; background: #fff; display: grid; place-items: center; box-shadow: 0 0 60px rgba(100,65,208,.55); }
.login-art .logo-box img { height: 70px; }
.login-art h1 { font-size: 40px; letter-spacing: -1px; margin-top: 8px; }
.login-art p { color: rgba(255,255,255,.75); font-size: 16px; max-width: 420px; margin: 0; }
.login-art ul { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 10px; color: rgba(255,255,255,.85); }
.login-art li::before { content: "✓"; color: #ad99fd; font-weight: 700; margin-right: 10px; }
.login-form { display: grid; place-items: center; padding: 24px 16px; }
.login .card { width: min(380px, 100%); padding: 28px; }
.login .brand { justify-content: center; font-size: 20px; padding-bottom: 6px; }
.login .sub { text-align: center; color: var(--muted); margin: 0 0 20px; }
@media (max-width: 860px) { .login { grid-template-columns: 1fr; } .login-art { display: none; } }
.login .btn.primary { width: 100%; justify-content: center; padding: 10px; }
.empty { padding: 40px 16px; text-align: center; color: var(--muted); }
.spinner { width: 28px; height: 28px; border: 3px solid var(--border); border-top-color: var(--primary); border-radius: 50%; animation: spin .8s linear infinite; margin: 40px auto; }
@keyframes spin { to { transform: rotate(360deg); } }

/* multi-cliente */
.acc-name { margin: -8px 10px 14px; padding: 6px 10px; border-radius: 8px; background: var(--surface-2); font-size: 13px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-sep { margin: 16px 12px 6px; font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 600; }
.banner { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 10px 14px; border-radius: var(--radius); margin-bottom: 16px; border: 1px solid; }
.banner .btn { margin-left: auto; }
.banner.info { background: color-mix(in srgb, var(--primary) 10%, transparent); border-color: color-mix(in srgb, var(--primary) 40%, transparent); }
.banner.warn { background: color-mix(in srgb, var(--warn) 12%, transparent); border-color: color-mix(in srgb, var(--warn) 40%, transparent); }
.banner.bad { background: color-mix(in srgb, var(--bad) 12%, transparent); border-color: color-mix(in srgb, var(--bad) 40%, transparent); }
.badge.warn { background: color-mix(in srgb, var(--warn) 15%, transparent); color: var(--warn); }
details summary { cursor: pointer; color: var(--bad); margin-top: 8px; }

/* ---- plano na barra lateral ---- */
.sidebar { display: flex; flex-direction: column; overflow-y: auto; }
.usage { margin-top: auto; padding: 12px 10px 4px; font-size: 12.5px; }
.usage:empty { display: none; }
.usage-title { font-weight: 700; margin-bottom: 8px; color: var(--text); }
.usage-row { display: flex; justify-content: space-between; gap: 8px; color: var(--muted); margin-top: 6px; }
.usage-row b { color: var(--text); font-weight: 600; }
.usage-bar { height: 5px; border-radius: 4px; background: var(--surface-2); margin-top: 4px; overflow: hidden; }
.usage-bar i { display: block; height: 100%; background: var(--primary); border-radius: 4px; }
.usage-bar.warn i { background: var(--warn); }
.usage-bar.full i { background: var(--bad); }

/* ---- paginas de formulario (Site) ---- */
.form-page { max-width: 820px; }
.form-page h2 { margin: 22px 0 10px; font-size: 15px; }
.form-page .f small { display: block; margin-top: 4px; font-size: 12px; }
.form-actions { margin-top: 20px; display: flex; gap: 8px; }

/* ---- login por link/codigo ---- */
.login-links { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; flex-wrap: wrap; }
.login-links:has(> :only-child) { justify-content: center; }
button.link { background: none; border: 0; padding: 0; color: var(--primary); font: inherit; font-size: 13.5px; cursor: pointer; }
button.link:disabled { color: var(--muted); cursor: default; }
button.link:not(:disabled):hover { text-decoration: underline; }

/* ---- conteudos dinamicos ---- */
.widget-thumb { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 10px; color: #fff; flex: 0 0 auto; }
.widget-thumb.sm { width: 32px; height: 32px; border-radius: 8px; }
.widget-thumb.sm svg { width: 18px; height: 18px; }
.widget-thumb.t-clock { background: #3b2a8f; } .widget-thumb.t-weather { background: #1976d2; } .widget-thumb.t-news { background: #c62828; } .widget-thumb.t-sports { background: #1e7a4f; } .widget-thumb.t-message { background: #6441d0; }
.pl-items .thumb.widget-thumb { color: #fff; }
.pl-items .thumb.widget-thumb { width: 64px; height: 40px; }
.widget-card .head { display: flex; gap: 12px; align-items: center; }
.widget-card strong { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.type-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.type-opt { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; text-align: left; padding: 14px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); color: var(--text); cursor: pointer; font: inherit; }
.type-opt:hover, .type-opt:focus-visible { border-color: var(--primary); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
.geo-list { display: flex; flex-direction: column; gap: 4px; margin: -6px 0 12px; }
.geo-opt { text-align: left; padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); cursor: pointer; font: inherit; }
.geo-opt:hover { border-color: var(--primary); }
.ok-text { color: var(--ok); }
.msg-preview { border-radius: 12px; padding: 28px 24px; min-height: 120px; display: flex; flex-direction: column; justify-content: center; }
.msg-preview b { font-size: 22px; } .msg-preview p { margin: 8px 0 0; font-size: 16px; line-height: 1.4; }
.wprev { border-radius: 12px; padding: 24px; background: linear-gradient(135deg, #1b1147, #3b2a8f); color: #fff; }
.wprev .big { font-size: 64px; font-weight: 800; line-height: 1.1; }
.wprev .lbl { opacity: .85; text-transform: capitalize; }
.wprev.clock { text-align: center; }
.wprev .days { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 10px; margin-top: 18px; }
.wprev .days > div { background: rgba(255,255,255,.1); border-radius: 10px; padding: 10px; display: flex; flex-direction: column; gap: 2px; font-size: 13px; }
.wprev.news ol { margin: 12px 0 0; padding-left: 20px; display: flex; flex-direction: column; gap: 10px; }
.wprev.news li > div { display: inline; } .wprev.news li { overflow: hidden; }
.wprev.news img { float: right; width: 96px; height: 60px; object-fit: cover; border-radius: 6px; margin-left: 10px; }
.wprev.news p { margin: 4px 0 0; opacity: .8; }

/* ---- avisos ---- */
.ann-list { display: flex; flex-direction: column; gap: 10px; }
.ann-card { display: flex; gap: 16px; align-items: flex-start; border-left: 5px solid var(--ann); }
.ann-card.off { opacity: .6; }
.ann-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.ann-title { font-size: 15px; }
.ann-msg { font-size: 15px; white-space: pre-wrap; word-break: break-word; }
.ann-actions { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.dot-c { display: inline-block; width: 12px; height: 12px; border-radius: 50%; margin-right: 2px; }
.chips.tgt { margin: -4px 0 14px; max-height: 180px; overflow: auto; }
.chips.tgt .dot { margin-right: 2px; }
.ann-preview { margin: 0 0 14px; }
.ann-preview .tv-mini { position: relative; aspect-ratio: 16 / 6; border-radius: 10px; background: linear-gradient(135deg, #2b2257, #51407f); overflow: hidden; }
.ann-preview .bar { position: absolute; left: 0; right: 0; bottom: 0; padding: 10px 14px; background: var(--ann); color: #fff; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ann-preview.st-fullscreen .bar { top: 0; white-space: normal; display: flex; align-items: center; justify-content: center; text-align: center; font-size: 18px; padding: 16px 24px; }
@media (max-width: 640px) { .ann-card { flex-direction: column; } .ann-actions { justify-content: flex-start; } }

/* ---- telas em lista + filtros ---- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.filters input[type=search], .filters select, .filters input[type=date] { width: auto; min-width: 150px; padding: 7px 10px; font-size: 13.5px; }
.filters input[type=search] { flex: 1 1 220px; }
.filters .small { margin-left: auto; }
input[type=search] { width: 100%; padding: 9px 12px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); font: inherit; }
.nowrap { white-space: nowrap; }
.screens-table td { padding-top: 9px; padding-bottom: 9px; }
.screens-table td.actions { display: table-cell; text-align: right; }
.screens-table .actions .btn + .btn { margin-left: 6px; }
.det-head { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
.det-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 24px; }
.det-grid .kv { grid-template-columns: 110px 1fr; }
.screen-cmds .spacer { flex: 1; }
.hist { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; color: var(--text); }
.pager { display: flex; gap: 8px; align-items: center; justify-content: flex-end; margin-top: 10px; }
.pager .small { margin-right: auto; }
@media (max-width: 720px) { .hide-sm { display: none; } .det-grid { grid-template-columns: 1fr; } .filters .small { margin-left: 0; width: 100%; } }

/* ---- YouTube ---- */
.widget-thumb.t-youtube { background: #e62117; }
.yt-prev { display: flex; gap: 12px; align-items: center; margin: -4px 0 12px; }
.yt-prev img { width: 160px; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 8px; }
.yt-frame { position: relative; aspect-ratio: 16 / 9; background: #000; border-radius: 12px; overflow: hidden; }
.yt-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* ---- assinatura ---- */
.bill-top { display: grid; grid-template-columns: 1.2fr 1fr; gap: 14px; }
.bill-big { font-size: 22px; font-weight: 800; margin-top: 2px; }
.bill-open { border-left: 5px solid var(--primary); display: flex; flex-direction: column; align-items: flex-start; }
.bill-open.late { border-left-color: var(--bad); }
.bill-plans { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.bill-plan { display: flex; flex-direction: column; gap: 6px; }
.bill-plan .head { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 16px; }
.bill-plan.featured { border-color: var(--primary); }
.bill-plan.current { box-shadow: 0 0 0 2px var(--ok) inset; }
.bill-plan .btn { margin-top: auto; }
.bill-price { font-size: 26px; font-weight: 800; margin-top: 6px; }
.bill-price span { font-size: 14px; font-weight: 500; color: var(--muted); }
.bill-lim { margin: 6px 0 12px; padding-left: 18px; font-size: 13px; color: var(--muted); }
.billing-toggle { display: inline-flex; border: 1px solid var(--border); border-radius: 99px; padding: 3px; margin-bottom: 14px; background: var(--surface); }
.billing-toggle button { border: 0; background: none; padding: 7px 16px; border-radius: 99px; font: inherit; color: var(--text); cursor: pointer; }
.billing-toggle button.on { background: var(--primary); color: var(--primary-ink); font-weight: 600; }
.billing-toggle .save { font-size: 11px; font-weight: 700; margin-left: 4px; }
.bill-sum { background: var(--surface-2); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 12px; }
.danger-link { color: var(--bad) !important; }
@media (max-width: 720px) { .bill-top { grid-template-columns: 1fr; } }

/* ---- cobranca / cadastro ---- */
.pay-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.pay-opt { display: flex; flex-direction: column; gap: 4px; padding: 12px; border: 1px solid var(--border); border-radius: var(--radius); cursor: pointer; }
.pay-opt:has(input:checked) { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 8%, transparent); }
.pay-opt input { margin: 0 0 4px; }
.fin-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; margin-bottom: 16px; }
.bill-big.warn { color: var(--warn); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.signup .login-form form { max-width: 460px; width: 100%; }
.signup .chip.accept { display: flex; align-items: flex-start; gap: 8px; border: 0; padding: 4px 0 12px; font-size: 13px; cursor: default; }
.signup .billing-toggle { margin: -4px 0 12px; }
.signup-done { max-width: 420px; text-align: center; }
.signup-done h2 { margin: 12px 0; }
@media (max-width: 640px) { .pay-opts { grid-template-columns: 1fr; } }
.pay-opt input[type=radio] { width: auto; height: auto; padding: 0; border: 0; box-shadow: none; accent-color: var(--primary); }

/* ===================== SmartCloud Player (play.smartads.cloud) ===================== */
.hero-status { display: flex; gap: 18px; align-items: center; padding: 20px; border-radius: 14px; color: #fff;
  background: radial-gradient(800px 300px at 10% 0%, #4b2fb8 0%, transparent 60%), linear-gradient(135deg, #0e0a24, #1b1147 55%, #2e1c7a); }
.hero-status h2 { margin: 0 0 4px; font-size: 22px; }
.hero-status p { margin: 0; color: rgba(255,255,255,.8); }
.hero-status .spacer { flex: 1; }
.hero-status .btn.primary { background: #fff; color: #1b1147; border-color: #fff; }
.stats { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); margin-bottom: 16px; }
.stat { padding: 14px 16px; }
.stat b { display: block; font-size: 26px; letter-spacing: -.5px; }
.stat span { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
.plans { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.plan { padding: 20px; display: flex; flex-direction: column; gap: 8px; }
.plan .price { font-size: 28px; font-weight: 800; letter-spacing: -.5px; }
.plan .price small { font-size: 13px; color: var(--muted); font-weight: 500; }
.plan .btn { justify-content: center; margin-top: auto; }
.code-pair { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.code-pair input { font-size: 22px; letter-spacing: 8px; text-align: center; width: 190px; font-weight: 700; }
.steps { margin: 0; padding-left: 18px; color: var(--muted); }
.steps li { margin: 4px 0; }
.steps b { color: var(--text); }

/* player web */
.wp { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(280px, 1fr); gap: 16px; align-items: start; }
@media (max-width: 1000px) { .wp { grid-template-columns: 1fr; } }
.wp-video { position: sticky; top: 12px; }
.wp-video .frame { aspect-ratio: 16/9; background: #000; border-radius: 12px; overflow: hidden; display: grid; place-items: center; position: relative; }
.wp-video video { width: 100%; height: 100%; background: #000; }
.wp-video .msg { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 24px; color: #fff; background: rgba(0,0,0,.75); }
.wp-video .msg.hidden { display: none; }
.wp-video .now { margin-top: 10px; font-weight: 700; font-size: 16px; }
.wp-tools { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.wp-tools select, .wp-tools input { flex: 1; min-width: 140px; }
.wp-list { max-height: 70vh; overflow: auto; display: grid; gap: 6px; }
.wp-item { display: flex; gap: 10px; align-items: center; padding: 6px 8px; border-radius: 8px; cursor: pointer; border: 1px solid transparent; }
.wp-item:hover { background: var(--surface-2); }
.wp-item.on { border-color: var(--primary); background: color-mix(in srgb, var(--primary) 12%, transparent); }
.wp-item img, .wp-item .ph { width: 64px; height: 40px; object-fit: contain; background: var(--surface-2); border-radius: 6px; flex: none; }
.wp-item.poster img, .wp-item.poster .ph { width: 44px; height: 64px; object-fit: cover; }
.wp-item .t { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wp-item .g { font-size: 12px; color: var(--muted); }
