:root {
  --bg: #0a0f1d;
  --bg-elev: #101828;
  --card: #0e1524;
  --muted: #1b2436;
  --border: #1f2a40;
  --text: #e7ecf5;
  --text-dim: #97a3b8;
  --gold: #d4af37;
  --gold-soft: #e6c964;
  --danger: #ef4444;
  --success: #22c55e;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background: radial-gradient(1200px 600px at 50% -10%, #13203a 0%, var(--bg) 55%);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.5;
}
.container { max-width: 1040px; margin: 0 auto; padding: 24px 20px 64px; }
.header { display: flex; align-items: center; gap: 14px; padding: 22px 0 26px; }
.logo { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--gold), #8a6d1f); color: #1a1206; font-weight: 800; font-size: 22px;
  box-shadow: 0 6px 20px rgba(212,175,55,.25); }
.brand h1 { font-size: 22px; letter-spacing: .3px; }
.brand h1 span { color: var(--gold); }
.brand p { color: var(--text-dim); font-size: 13px; }
.header .spacer { flex: 1; }
.userbox { color: var(--text-dim); font-size: 13px; display: flex; align-items: center; gap: 12px; }
.hero { text-align: center; margin: 6px 0 30px; }
.hero h2 { font-size: 30px; line-height: 1.2; }
.hero h2 span { color: var(--gold); }
.hero p { color: var(--text-dim); max-width: 640px; margin: 12px auto 0; }
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 820px) { .grid { grid-template-columns: 1fr; } }
.card { background: var(--card); border: 1px solid var(--border); border-radius: 16px; padding: 20px;
  box-shadow: 0 10px 30px rgba(0,0,0,.25); }
.card h3 { font-size: 15px; margin-bottom: 4px; display: flex; align-items: center; gap: 8px; }
.card .sub { color: var(--text-dim); font-size: 12.5px; margin-bottom: 14px; }
.badge { background: rgba(212,175,55,.14); color: var(--gold-soft); border: 1px solid rgba(212,175,55,.3);
  font-size: 11px; padding: 3px 9px; border-radius: 999px; }
.drop { border: 1.5px dashed var(--border); border-radius: 12px; padding: 26px 16px; text-align: center;
  cursor: pointer; transition: .15s; background: var(--bg-elev); }
.drop:hover { border-color: var(--gold); background: #121b2e; }
.drop .icon { font-size: 26px; }
.drop .main { margin-top: 8px; font-weight: 600; font-size: 14px; }
.drop .hint { color: var(--text-dim); font-size: 12px; margin-top: 4px; }
.drop.filled { border-color: var(--success); border-style: solid; }
.filename { color: var(--gold-soft); font-size: 13px; margin-top: 10px; word-break: break-all; }
.section-title { margin: 30px 0 14px; display: flex; align-items: center; gap: 10px; }
.section-title h3 { font-size: 16px; }
.seg { display: inline-flex; background: var(--muted); border-radius: 10px; padding: 4px; gap: 4px; }
.seg button { border: none; background: transparent; color: var(--text-dim); padding: 8px 16px; border-radius: 8px;
  cursor: pointer; font-size: 13px; font-weight: 600; }
.seg button.active { background: linear-gradient(135deg, var(--gold), #a9821f); color: #1a1206; }
.rows { display: flex; flex-direction: column; gap: 2px; margin-top: 6px; }
.row { display: flex; align-items: center; justify-content: space-between; padding: 12px 4px; border-bottom: 1px solid var(--border); }
.row:last-child { border-bottom: none; }
.row .label { font-size: 14px; }
.row .desc { color: var(--text-dim); font-size: 12px; }
.switch { position: relative; width: 44px; height: 25px; flex-shrink: 0; }
.switch input { display: none; }
.slider { position: absolute; inset: 0; background: var(--muted); border-radius: 999px; transition: .15s; border: 1px solid var(--border); }
.slider::before { content: ''; position: absolute; width: 19px; height: 19px; left: 3px; top: 2px; background: #cdd6e6;
  border-radius: 50%; transition: .15s; }
.switch input:checked + .slider { background: var(--gold); }
.switch input:checked + .slider::before { transform: translateX(19px); background: #1a1206; }
.dur { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.dur button { background: var(--muted); border: 1px solid var(--border); color: var(--text); padding: 8px 14px;
  border-radius: 8px; cursor: pointer; font-size: 13px; }
.dur button.active { border-color: var(--gold); color: var(--gold-soft); background: #14203a; }
.btn { width: 100%; padding: 15px; border: none; border-radius: 12px; font-size: 15px; font-weight: 700; cursor: pointer;
  background: linear-gradient(135deg, var(--gold), #a9821f); color: #1a1206; margin-top: 26px;
  box-shadow: 0 8px 24px rgba(212,175,55,.25); transition: .15s; }
.btn:hover { filter: brightness(1.05); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.note { color: var(--text-dim); font-size: 12px; margin-top: 14px; text-align: center; }
.result { margin-top: 22px; }
.result video { width: 100%; border-radius: 12px; border: 1px solid var(--border); background: #000; }
.msg { padding: 12px 14px; border-radius: 10px; font-size: 13.5px; margin-top: 14px; }
.msg.error { background: rgba(239,68,68,.12); color: #fca5a5; border: 1px solid rgba(239,68,68,.3); }
.msg.ok { background: rgba(34,197,94,.12); color: #86efac; border: 1px solid rgba(34,197,94,.3); }
.progress { height: 8px; background: var(--muted); border-radius: 999px; overflow: hidden; margin-top: 16px; }
.progress > div { height: 100%; width: 40%; background: linear-gradient(90deg, transparent, var(--gold), transparent);
  animation: slide 1.2s infinite; }
.progress.determinate > div { width: 0; animation: none; background: linear-gradient(90deg, var(--gold), var(--gold-soft)); transition: width .3s; }
@keyframes slide { 0% { transform: translateX(-120%);} 100% { transform: translateX(320%);} }
.footer { text-align: center; color: var(--text-dim); font-size: 12px; margin-top: 40px; }
/* Login */
.auth-wrap { min-height: 100vh; display: grid; place-items: center; padding: 20px; }
.auth-card { width: 100%; max-width: 400px; background: var(--card); border: 1px solid var(--border);
  border-radius: 18px; padding: 32px 28px; box-shadow: 0 20px 60px rgba(0,0,0,.4); }
.auth-card .logo { margin: 0 auto 16px; }
.auth-card h1 { text-align: center; font-size: 22px; }
.auth-card h1 span { color: var(--gold); }
.auth-card .sub { text-align: center; color: var(--text-dim); font-size: 13px; margin: 6px 0 22px; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; color: var(--text-dim); margin-bottom: 6px; }
.field input { width: 100%; padding: 12px 14px; background: var(--bg-elev); border: 1px solid var(--border);
  border-radius: 10px; color: var(--text); font-size: 14px; }
.field input:focus { outline: none; border-color: var(--gold); }
.tabs { display: flex; gap: 6px; background: var(--muted); border-radius: 10px; padding: 4px; margin-bottom: 20px; }
.tabs button { flex: 1; border: none; background: transparent; color: var(--text-dim); padding: 9px; border-radius: 8px;
  cursor: pointer; font-weight: 600; font-size: 13px; }
.tabs button.active { background: linear-gradient(135deg, var(--gold), #a9821f); color: #1a1206; }
.link { color: var(--gold-soft); cursor: pointer; }
/* Admin */
.addrow { display: flex; gap: 10px; align-items: stretch; }
.addrow input { flex: 1; padding: 12px 14px; background: var(--bg-elev); border: 1px solid var(--border);
  border-radius: 10px; color: var(--text); font-size: 14px; }
.addrow input:focus { outline: none; border-color: var(--gold); }
.addrow .btn { width: auto; margin-top: 0; padding: 12px 22px; }
@media (max-width: 520px) { .addrow { flex-direction: column; } }
.btn-danger { background: rgba(239,68,68,.12); color: #fca5a5; border: 1px solid rgba(239,68,68,.35);
  padding: 8px 14px; border-radius: 8px; cursor: pointer; font-size: 13px; font-weight: 600; flex-shrink: 0; }
.btn-danger:hover { background: rgba(239,68,68,.22); }
.status-ok { color: #86efac; }
.status-wait { color: var(--gold-soft); }
.userbox a.link { text-decoration: none; }
/* Opções da capa */
.row-right { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.seg-sm button { padding: 6px 10px; font-size: 12px; }
@media (max-width: 520px) { .row-right { flex-direction: column; align-items: flex-end; gap: 8px; } }
