/* RedCine — site do cliente. Mobile-first, sem build. */

:root {
  --bg: #0B0B0F;
  --bg-2: #0F0F15;
  --surface: #15151C;
  --surface-2: #1C1C25;
  --surface-3: #24242F;
  --line: #262632;
  --line-2: #33333F;
  --text: #EDEDF2;
  --muted: #8B8B9A;
  --muted-2: #6C6C7A;
  --red: #E11D2E;
  --red-hi: #F2394A;
  --red-lo: #B5121F;
  --red-tint: rgba(225, 29, 46, .12);
  --green: #22C55E;
  --green-tint: rgba(34, 197, 94, .12);
  --amber: #F5A524;
  --amber-tint: rgba(245, 165, 36, .12);
  --radius: 12px;
  --radius-lg: 18px;
  --gutter: 16px;
  --maxw: 1120px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "Roboto Mono", Menlo, Consolas, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  -webkit-tap-highlight-color: transparent;
}
main { flex: 1; }
[hidden] { display: none !important; }
a { color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.15; letter-spacing: -.02em; }
p { margin: 0; }
code { font-family: var(--mono); font-size: .9em; background: var(--surface-2); padding: 1px 6px; border-radius: 6px; }
strong { font-weight: 600; color: var(--text); }

svg[viewBox="0 0 24 24"] {
  width: 20px; height: 20px; flex: none;
  fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round;
}

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.muted { color: var(--muted); }
.mono { font-family: var(--mono); letter-spacing: .02em; }

.skip {
  position: absolute; left: 8px; top: -60px; z-index: 100;
  background: var(--red); color: #fff; padding: 10px 14px; border-radius: 10px; text-decoration: none; font-weight: 600;
}
.skip:focus { top: 8px; }

:focus-visible { outline: 2px solid var(--red-hi); outline-offset: 2px; }

/* ---------- Wordmark ---------- */
.wordmark { font-weight: 800; letter-spacing: -.03em; font-size: 20px; line-height: 1; }
.wordmark-sm { font-size: 17px; }
.w-red { color: #fff; }
.w-cine { color: var(--red); }

/* ---------- Topbar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(11, 11, 15, .82);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, .06);
  padding-top: env(safe-area-inset-top);
}
.topbar-in { display: flex; align-items: center; gap: 12px; height: 60px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; margin-right: auto; min-height: 44px; }
.brand-mark { width: 30px; height: 30px; border-radius: 8px; display: block; }
.topnav { display: none; gap: 4px; }
.topnav a { color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 500; padding: 8px 12px; border-radius: 8px; transition: color .15s, background-color .15s; }
.topnav a:hover { color: var(--text); background: var(--surface); }
@media (min-width: 820px) { .topnav { display: flex; margin-right: 8px; } }
body.is-manage .topnav { display: none; }

/* ---------- Buttons ---------- */
.btn {
  -webkit-appearance: none; appearance: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600; font-size: 15px; line-height: 1;
  min-height: 44px; padding: 0 16px;
  border-radius: var(--radius); border: 1px solid transparent;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .15s var(--ease), border-color .15s var(--ease), color .15s var(--ease), transform .12s var(--ease), box-shadow .15s var(--ease);
  -webkit-user-select: none; user-select: none; touch-action: manipulation;
}
.btn:active { transform: scale(.97); }
.btn[disabled] { opacity: .55; cursor: default; transform: none; }
.btn-sm { min-height: 40px; padding: 0 12px; font-size: 14px; border-radius: 10px; }
.btn-sm svg[viewBox] { width: 17px; height: 17px; }
.btn-lg { min-height: 52px; padding: 0 22px; font-size: 16px; }
.btn-block { width: 100%; }
.btn-primary { background: var(--red); color: #fff; box-shadow: 0 1px 0 rgba(255,255,255,.18) inset, 0 8px 24px -10px rgba(225, 29, 46, .7); }
.btn-primary:hover { background: var(--red-hi); }
.btn-outline { background: rgba(255,255,255,.03); color: var(--text); border-color: var(--line-2); }
.btn-outline:hover { border-color: #4a4a58; background: rgba(255,255,255,.06); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-soft { background: var(--red-tint); color: #ff8a94; border-color: rgba(225, 29, 46, .25); }
.btn-soft:hover { background: rgba(225, 29, 46, .2); color: #ffb0b7; }
.btn-soft svg[viewBox] { fill: currentColor; stroke: none; }
.btn-danger { background: var(--red); color: #fff; }
.btn-danger:hover { background: var(--red-hi); }
.btn-danger-ghost { color: #ff8a94; }
.btn.is-loading { position: relative; color: transparent !important; pointer-events: none; }
.btn.is-loading svg { visibility: hidden; }
.btn.is-loading::after {
  content: ""; position: absolute; width: 20px; height: 20px; border-radius: 50%;
  border: 2.5px solid rgba(255,255,255,.35); border-top-color: #fff; animation: spin .7s linear infinite;
}
.btn-ghost.is-loading::after, .btn-soft.is-loading::after { border-color: rgba(237,237,242,.25); border-top-color: var(--text); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 40px 0 56px; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto; height: 620px; pointer-events: none;
  background:
    radial-gradient(520px 320px at 78% 30%, rgba(225, 29, 46, .22), transparent 70%),
    radial-gradient(420px 260px at 10% 0%, rgba(225, 29, 46, .08), transparent 70%);
}
.hero-in { position: relative; display: grid; gap: 40px; align-items: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 600; color: #ffb0b7; letter-spacing: .01em;
  background: var(--red-tint); border: 1px solid rgba(225, 29, 46, .28);
  padding: 6px 12px; border-radius: 999px; margin-bottom: 20px;
}
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 4px rgba(225,29,46,.2); }
.hero h1 { font-size: clamp(34px, 9vw, 60px); font-weight: 800; letter-spacing: -.035em; }
.h1-brand { color: var(--red); }
.lead { margin-top: 18px; font-size: 17px; color: #B4B4C2; max-width: 34em; }
.hero-cta { display: flex; flex-direction: column; gap: 12px; margin-top: 28px; }
.hero-note { margin-top: 18px; font-size: 13px; color: var(--muted-2); letter-spacing: .02em; }
@media (min-width: 520px) {
  .hero-cta { flex-direction: row; flex-wrap: wrap; }
}
@media (min-width: 900px) {
  .hero { padding: 72px 0 88px; }
  .hero-in { grid-template-columns: 1.05fr .95fr; gap: 56px; }
  .lead { font-size: 18px; }
}

/* TV mockup */
.tv { width: 100%; max-width: 480px; margin: 0 auto; }
.tv-screen {
  position: relative; overflow: hidden;
  aspect-ratio: 16 / 10;
  background: linear-gradient(160deg, #191922 0%, #0d0d12 60%);
  border: 10px solid #050507; border-radius: 16px;
  box-shadow: 0 0 0 1px #2a2a35, 0 40px 80px -30px rgba(0,0,0,.9), 0 30px 90px -40px rgba(225,29,46,.45);
  padding: 6% 7%;
  display: flex; flex-direction: column;
}
.tv-glow { position: absolute; inset: auto -30% -60% auto; width: 80%; height: 120%; background: radial-gradient(closest-side, rgba(225,29,46,.18), transparent); pointer-events: none; }
.tv-top { position: relative; display: flex; align-items: center; justify-content: space-between; }
.tv-pill { font-size: 10px; font-weight: 600; color: var(--amber); background: var(--amber-tint); padding: 3px 8px; border-radius: 999px; }
.tv-msg { position: relative; margin-top: auto; font-size: clamp(11px, 2.8vw, 13px); color: var(--muted); }
.tv-creds { position: relative; display: grid; grid-template-columns: 1.6fr 1fr; gap: 8px; margin-top: 8px; }
.tv-cred {
  background: rgba(255,255,255,.04); border: 1px solid rgba(225,29,46,.55); border-radius: 10px;
  padding: 8px 10px; box-shadow: 0 0 0 4px rgba(225,29,46,.10);
  display: flex; flex-direction: column; gap: 2px; min-width: 0;
}
.tv-label { font-size: 10px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 600; }
.tv-value { font-family: var(--mono); font-weight: 600; font-size: clamp(11px, 3vw, 15px); color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tv-tag {
  grid-column: 1 / -1; justify-self: end; margin: -4px 4px -2px 0;
  font-size: 11px; font-weight: 600; color: #fff; background: var(--red);
  padding: 4px 10px; border-radius: 999px; transform: rotate(-3deg);
  box-shadow: 0 6px 18px -6px rgba(225,29,46,.8);
}
.tv-stand { width: 34%; height: 10px; margin: 0 auto; background: linear-gradient(#141419, #0a0a0d); border-radius: 0 0 10px 10px; }

/* ---------- Sections ---------- */
.section { padding: 56px 0; border-top: 1px solid rgba(255,255,255,.05); scroll-margin-top: 60px; }
.section h2 { font-size: clamp(26px, 6.5vw, 38px); font-weight: 800; }
.kicker { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .12em; color: var(--red); margin-bottom: 10px; }
@media (min-width: 900px) { .section { padding: 80px 0; } }

.steps { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 12px; counter-reset: s; }
.step { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px; }
.step-n {
  display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 10px;
  background: var(--red-tint); color: #ff8a94; font-weight: 800; font-size: 16px; margin-bottom: 14px;
  border: 1px solid rgba(225,29,46,.3);
}
.step h3 { font-size: 18px; font-weight: 700; }
.step p { margin-top: 6px; color: var(--muted); font-size: 15px; }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 16px; } .step { padding: 24px; } }

.devices { list-style: none; padding: 0; margin: 28px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.device-tile {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 18px; display: flex; flex-direction: column; gap: 4px; min-width: 0;
}
.device-tile svg[viewBox] { width: 28px; height: 28px; color: var(--red); margin-bottom: 10px; stroke-width: 1.6; }
.device-tile strong { font-size: 17px; }
.device-tile span { font-size: 14px; color: var(--muted); }
.device-tile.is-soon { background: transparent; border-style: dashed; }
.device-tile.is-soon svg[viewBox] { color: var(--muted-2); }
.soon { align-self: flex-start; font-size: 12px !important; font-weight: 600; color: var(--amber) !important; background: var(--amber-tint); padding: 2px 8px; border-radius: 999px; margin-top: 2px; }
@media (min-width: 760px) { .devices { grid-template-columns: repeat(4, 1fr); gap: 16px; } .device-tile { padding: 22px; } }

.faq { margin-top: 28px; display: grid; gap: 10px; max-width: 760px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: border-color .15s; }
.faq details[open] { border-color: var(--line-2); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 18px; min-height: 56px; font-weight: 600; font-size: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 10px; height: 10px; margin-right: 4px;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted);
  transform: rotate(45deg) translateY(-3px); transition: transform .2s var(--ease);
}
.faq details[open] summary::after { transform: rotate(-135deg) translateY(-2px); }
.faq-a { padding: 0 18px 18px; color: #B4B4C2; font-size: 15px; }

.section-cta { padding-top: 24px; border-top: 0; }
.cta-card {
  display: flex; flex-direction: column; gap: 20px;
  padding: 28px 22px; border-radius: var(--radius-lg);
  background: radial-gradient(500px 200px at 100% 0%, rgba(225,29,46,.25), transparent 70%), var(--surface);
  border: 1px solid var(--line);
}
.cta-card h2 { font-size: clamp(22px, 5.5vw, 30px); }
.cta-card p { color: var(--muted); margin-top: 8px; }
@media (min-width: 760px) { .cta-card { flex-direction: row; align-items: center; justify-content: space-between; padding: 36px 40px; } }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid rgba(255,255,255,.06); padding: 28px 0 calc(28px + env(safe-area-inset-bottom)); margin-top: 24px; }
.footer-in { display: flex; flex-direction: column; gap: 10px; }
.disclaimer { color: var(--muted); font-size: 14px; }
.copy { color: var(--muted-2); font-size: 13px; }
@media (min-width: 760px) { .footer-in { flex-direction: row; align-items: center; gap: 24px; } .copy { margin-left: auto; } }

/* ---------- Cards & forms ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 20px; }
.h-card { font-size: 26px; font-weight: 800; }
.h-block { font-size: 18px; font-weight: 700; letter-spacing: -.01em; }
.label-xs { display: block; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }

.field { margin-top: 16px; }
.field label { display: flex; align-items: baseline; gap: 8px; font-size: 14px; font-weight: 600; margin-bottom: 7px; }
.opt { font-weight: 500; font-size: 12px; color: var(--muted-2); }
input[type="text"], input[type="password"] {
  -webkit-appearance: none; appearance: none;
  width: 100%; min-height: 50px; padding: 0 14px;
  font: inherit; font-size: 16px; /* 16px evita zoom no iOS */
  color: var(--text); background: var(--bg-2);
  border: 1px solid var(--line-2); border-radius: var(--radius);
  transition: border-color .15s, box-shadow .15s, background-color .15s;
}
input::placeholder { color: #55555F; }
input:hover { border-color: #44444f; }
input:focus { outline: none; border-color: var(--red); box-shadow: 0 0 0 3px rgba(225, 29, 46, .22); background: #101017; }
input[aria-invalid="true"] { border-color: #ff5a68; }
input.mono { font-family: var(--mono); letter-spacing: .06em; font-size: 17px; }
.key-input { letter-spacing: .4em !important; }
.hint { margin-top: 6px; font-size: 13px; color: var(--muted-2); }
.form-error {
  margin-top: 16px; padding: 12px 14px; border-radius: var(--radius);
  background: rgba(225, 29, 46, .1); border: 1px solid rgba(225, 29, 46, .35); color: #ffb0b7; font-size: 14px;
}
form .btn-block { margin-top: 20px; }

.pass-wrap { position: relative; }
.pass-wrap input { padding-right: 54px; }
.pass-toggle {
  position: absolute; right: 3px; top: 3px; bottom: 3px; width: 48px;
  display: grid; place-items: center; background: transparent; border: 0; border-radius: 10px;
  color: var(--muted); cursor: pointer;
}
.pass-toggle:hover { color: var(--text); background: rgba(255,255,255,.04); }
.pass-toggle .i-eye-off { display: none; }
.pass-toggle[aria-pressed="true"] .i-eye { display: none; }
.pass-toggle[aria-pressed="true"] .i-eye-off { display: block; }

/* ---------- Manage: login ---------- */
.manage-login { padding: 24px 0 48px; }
.wrap-login { max-width: 460px; }
.back {
  display: inline-flex; align-items: center; gap: 6px; color: var(--muted); text-decoration: none;
  font-size: 14px; font-weight: 500; min-height: 44px; margin-bottom: 8px;
}
.back:hover { color: var(--text); }
.login-card { padding: 24px 20px; position: relative; overflow: hidden; }
.login-card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: linear-gradient(90deg, var(--red), transparent); }
.login-card > .muted { margin-top: 8px; font-size: 15px; }
.login-foot { margin-top: 16px; font-size: 13px; text-align: center; padding: 0 12px; }
@media (min-width: 520px) { .manage-login { padding-top: 48px; } .login-card { padding: 32px 28px; } }

/* ---------- Manage: dashboard ---------- */
.dash { padding: 20px 0 48px; }
.dash-grid { display: grid; gap: 20px; }
@media (min-width: 940px) {
  .dash { padding-top: 36px; }
  .dash-grid { grid-template-columns: minmax(0, 1fr) 400px; gap: 28px; align-items: start; }
  .dash-side { position: sticky; top: 80px; }
}

.device-card { padding: 18px; }
.device-head { display: flex; align-items: center; gap: 12px; }
.device-icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--surface-2); border: 1px solid var(--line); color: var(--text); flex: none; }
.device-id { min-width: 0; flex: 1; }
.device-mac { display: block; font-size: 17px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.device-meta { display: grid; grid-template-columns: auto 1fr; gap: 0 12px; margin: 16px 0 0; padding-top: 14px; border-top: 1px solid var(--line); }
.device-meta > div { display: contents; }
.device-meta dt { color: var(--muted); font-size: 14px; padding: 4px 0; }
.device-meta dd { margin: 0; font-size: 14px; font-weight: 500; padding: 4px 0; text-align: right; }

.badge {
  display: inline-flex; align-items: center; gap: 6px; flex: none;
  font-size: 12px; font-weight: 600; line-height: 1; padding: 6px 10px; border-radius: 999px;
  background: var(--surface-2); color: var(--muted); border: 1px solid transparent;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-trial { background: var(--amber-tint); color: var(--amber); border-color: rgba(245,165,36,.25); }
.badge-active { background: var(--green-tint); color: var(--green); border-color: rgba(34,197,94,.25); }
.badge-expired, .badge-blocked { background: var(--red-tint); color: #ff6b78; border-color: rgba(225,29,46,.3); }
.badge-live { background: var(--green-tint); color: var(--green); padding: 4px 8px; font-size: 11px; }

.notice {
  display: flex; gap: 12px; align-items: flex-start; margin-top: 14px;
  padding: 14px 16px; border-radius: var(--radius);
  background: rgba(245, 165, 36, .07); border: 1px solid rgba(245, 165, 36, .22);
  color: #d9cfb8; font-size: 14px;
}
.notice svg[viewBox] { color: var(--amber); margin-top: 1px; }
.notice strong { color: #ffdca0; }
.notice.flash { animation: flash 1.2s var(--ease); }
@keyframes flash { 0% { box-shadow: 0 0 0 0 rgba(245,165,36,.5); } 100% { box-shadow: 0 0 0 10px rgba(245,165,36,0); } }

.block-head { display: flex; align-items: baseline; gap: 10px; margin: 28px 0 12px; }
.count { color: var(--muted); font-size: 14px; }

.playlists { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.pl {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px; display: grid; gap: 12px; min-width: 0;
  transition: border-color .15s;
}
.pl.is-selected { border-color: rgba(34, 197, 94, .35); background: linear-gradient(180deg, rgba(34,197,94,.05), transparent 60%), var(--surface); }
.pl-main { min-width: 0; }
.pl-title { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pl-name { font-weight: 600; font-size: 16px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.pl-meta { display: flex; align-items: center; gap: 8px; margin-top: 6px; min-width: 0; }
.type-chip {
  flex: none; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em;
  padding: 3px 7px; border-radius: 6px; background: var(--surface-3); color: #c4c4d0;
}
.type-chip[data-type="partner"] { background: var(--red-tint); color: #ff8a94; }
.pl-detail { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.pl-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.pl-actions .btn { padding: 0 8px; }
.pl.is-selected .pl-actions { grid-template-columns: repeat(2, 1fr); }
.pl-confirm {
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
  padding: 10px 12px; border-radius: 10px; background: rgba(225,29,46,.08); border: 1px solid rgba(225,29,46,.3);
}
.pl-confirm span { flex: 1 1 100%; font-size: 14px; font-weight: 600; color: #ffb0b7; }
.pl-confirm .btn { flex: 1; }
@media (min-width: 560px) {
  .pl { grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding: 14px 16px; }
  .pl-actions, .pl.is-selected .pl-actions { display: flex; }
  .pl-confirm { grid-column: 1 / -1; }
  .pl-confirm span { flex: 1 1 auto; }
  .pl-confirm .btn { flex: none; }
}

.empty {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px;
  padding: 28px 16px; border: 1px dashed var(--line-2); border-radius: var(--radius); color: var(--muted); font-size: 14px;
}
.empty svg[viewBox] { width: 28px; height: 28px; color: var(--muted-2); }

/* Form card */
.form-card { padding: 18px; scroll-margin-top: 76px; }
.form-card.is-editing { border-color: rgba(225,29,46,.45); box-shadow: 0 0 0 3px rgba(225,29,46,.1); }
.form-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 40px; }
.tabs {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin-top: 14px;
  padding: 4px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px;
}
.tab {
  -webkit-appearance: none; appearance: none; font: inherit; font-size: 14px; font-weight: 600;
  min-height: 42px; border: 0; border-radius: 9px; background: transparent; color: var(--muted); cursor: pointer;
  transition: background-color .15s, color .15s;
}
.tab:hover { color: var(--text); }
.tab[aria-selected="true"] { background: var(--surface-3); color: #fff; box-shadow: 0 1px 0 rgba(255,255,255,.06) inset, 0 2px 8px rgba(0,0,0,.3); }
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.tab-help { margin-top: 14px; font-size: 14px; color: var(--muted); }

.partner-status { margin-top: 8px; font-size: 14px; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.partner-status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; flex: none; }
.partner-status.ok { color: var(--green); }
.partner-status.err { color: #ff6b78; }
.partner-status.wait { color: var(--muted); }

/* Toast */
.toast {
  position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); z-index: 50;
  transform: translateX(-50%); width: max-content; max-width: calc(100% - 32px); text-align: center;
  background: #fff; color: #0B0B0F; font-weight: 600; font-size: 15px;
  padding: 12px 18px; border-radius: 12px; box-shadow: 0 16px 40px -12px rgba(0,0,0,.6);
  animation: toast-in .25s var(--ease);
}
.toast.is-error { background: var(--red); color: #fff; }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 8px); } }

/* Hover só em quem tem mouse (evita hover preso no toque) */
@media (hover: none) {
  .btn-primary:hover { background: var(--red); }
  .btn-ghost:hover { background: transparent; }
  .btn-outline:hover { border-color: var(--line-2); background: rgba(255,255,255,.03); }
  .btn-soft:hover { background: var(--red-tint); color: #ff8a94; }
}

@media (max-width: 419px) {
  .device-icon { display: none; }
  .device-mac { font-size: 16px; }
}
