:root {
  --bg: #07090a;
  --panel: #0f1412;
  --panel-2: #141b18;
  --neon: #7cff5a;
  --neon-soft: rgba(124, 255, 90, .55);
  --yellow: #ffe21c;
  --red: #ff4d4d;
  --text: #f3f6f2;
  --muted: #8a968e;
  --radius: 18px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { min-height: 100%; overflow-x: clip; }
body {
  font-family: 'Poppins', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  background-image:
    radial-gradient(ellipse 60% 45% at 50% 30%, rgba(124,255,90,.10), transparent 70%),
    linear-gradient(rgba(124,255,90,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124,255,90,.05) 1px, transparent 1px);
  background-size: auto, 48px 48px, 48px 48px;
  background-attachment: fixed;
}
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, textarea { font: inherit; color: inherit; }
a { color: inherit; }
[hidden] { display: none !important; }

/* ---------- Topo ---------- */
.topbar {
  position: sticky; top: 14px; z-index: 50;
  margin: 14px auto 0; width: min(1240px, calc(100% - 32px));
  display: flex; align-items: center; gap: 22px;
  padding: 10px 16px;
  background: rgba(12, 16, 14, .85);
  backdrop-filter: blur(14px);
  border: 1px solid var(--neon-soft);
  border-radius: 16px;
  box-shadow: 0 0 24px rgba(124,255,90,.12);
}
.logo { font-weight: 900; font-size: 22px; letter-spacing: .5px; white-space: nowrap; display: flex; align-items: center; position: relative; text-decoration: none; }
.logo span { color: var(--yellow); }
.logo img { height: 36px; width: auto; display: block; }
.nav { display: flex; gap: 4px; flex: 1; }
.nav a {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 13px; border-radius: 10px; white-space: nowrap;
  color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 500;
  border: 1px solid transparent; transition: .2s;
}
.nav a:hover { color: var(--text); }
.nav a.active { color: var(--neon); border-color: var(--neon-soft); background: rgba(124,255,90,.08); box-shadow: 0 0 14px rgba(124,255,90,.25); }
.nav svg { width: 18px; height: 18px; }

/* Botões */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 18px; border-radius: 12px; font-weight: 600; font-size: 14px;
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.1); transition: .2s;
}
.btn:hover { border-color: var(--neon-soft); color: var(--neon); }
.btn-neon { background: var(--neon); color: #07110a; border-color: var(--neon); box-shadow: 0 0 20px rgba(124,255,90,.35); font-weight: 700; }
.btn-neon:hover { color: #07110a; box-shadow: 0 0 30px rgba(124,255,90,.6); }
.btn-neon:disabled { opacity: .6; cursor: wait; }
.btn svg { width: 17px; height: 17px; }
.btn-sm { padding: 8px 12px; font-size: 13px; border-radius: 10px; }

/* Campos */
.field { display: grid; gap: 6px; margin-bottom: 14px; }
.field label { font-size: 13px; color: var(--muted); font-weight: 500; }
.field input, .field textarea {
  width: 100%; padding: 13px 14px; border-radius: 12px;
  background: rgba(0,0,0,.35); border: 1px solid rgba(255,255,255,.12); outline: none; transition: .2s;
}
.field textarea { min-height: 130px; resize: vertical; line-height: 1.5; }
.field input:focus, .field textarea:focus { border-color: var(--neon); box-shadow: 0 0 0 3px rgba(124,255,90,.15); }
.msg { font-size: 13.5px; margin-top: 10px; min-height: 20px; }
.msg.erro { color: var(--red); }
.msg.ok { color: var(--neon); }

/* ---------- Carrossel ---------- */
.stage { position: relative; height: clamp(430px, 64vh, 620px); perspective: 1400px; user-select: none; touch-action: pan-y; }
.card {
  --w: clamp(220px, 21vw, 320px);
  position: absolute; left: 50%; top: 50%;
  width: var(--w); aspect-ratio: 941 / 1672;
  margin-left: calc(var(--w) / -2);
  border-radius: var(--radius); overflow: hidden; cursor: pointer;
  transition: transform .6s cubic-bezier(.22,.8,.24,1), opacity .5s, filter .5s, box-shadow .5s;
  border: 2px solid rgba(124,255,90,.25); background: #000;
}
.card > img { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.card .shade { position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.9) 0%, rgba(0,0,0,0) 42%); opacity: 0; transition: opacity .4s; }
.card .meta { position: absolute; left: 0; right: 0; bottom: 0; padding: 16px 16px 18px; text-align: center; opacity: 0; transform: translateY(12px); transition: .45s .1s; }
.card .play {
  width: 60px; height: 60px; margin: 0 auto 10px; border-radius: 50%;
  display: grid; place-items: center; background: rgba(0,0,0,.55); border: 3px solid var(--neon);
  animation: pulse 2s infinite;
}
.card .play svg { width: 22px; height: 22px; fill: #fff; margin-left: 4px; }
.card .meta strong { display: block; font-size: 14px; letter-spacing: .5px; text-transform: uppercase; }
.card .meta small { color: #cfd8d1; font-size: 12.5px; }
.card .prog { height: 4px; background: rgba(255,255,255,.18); border-radius: 4px; margin-top: 10px; overflow: hidden; }
.card .prog i { display: block; height: 100%; background: var(--neon); box-shadow: 0 0 6px var(--neon); }
.card.is-active { border-color: var(--neon); box-shadow: 0 0 0 1px var(--neon), 0 0 40px rgba(124,255,90,.45), 0 30px 60px rgba(0,0,0,.7); }
.card.is-active .shade, .card.is-active .meta { opacity: 1; transform: none; }
.card .lock { width: 54px; height: 54px; margin: 0 auto 10px; border-radius: 50%; display: grid; place-items: center; background: rgba(0,0,0,.6); border: 2px solid var(--yellow); color: var(--yellow); }
.card .lock svg { width: 24px; height: 24px; }
.card .edit-chip {
  position: absolute; top: 10px; right: 10px; z-index: 3;
  display: flex; align-items: center; gap: 6px; padding: 7px 11px; border-radius: 10px;
  background: var(--yellow); color: #111; font-size: 12.5px; font-weight: 700;
  box-shadow: 0 4px 14px rgba(0,0,0,.5);
}
.card .edit-chip svg { width: 14px; height: 14px; }

@keyframes pulse {
  0%,100% { box-shadow: 0 0 14px var(--neon), inset 0 0 10px rgba(124,255,90,.4); }
  50% { box-shadow: 0 0 30px var(--neon), inset 0 0 14px rgba(124,255,90,.6); }
}
.arrow {
  position: absolute; top: 50%; z-index: 40;
  width: 54px; height: 54px; margin-top: -27px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(10,14,12,.85); backdrop-filter: blur(6px);
  border: 2px solid var(--neon-soft); color: var(--neon);
  box-shadow: 0 0 18px rgba(124,255,90,.25); transition: .2s;
}
.arrow:hover { background: var(--neon); color: #07110a; box-shadow: 0 0 28px var(--neon); }
.arrow svg { width: 26px; height: 26px; }
.arrow.prev { left: max(10px, calc(50% - var(--spread, 540px))); }
.arrow.next { right: max(10px, calc(50% - var(--spread, 540px))); }
.dots { display: flex; justify-content: center; gap: 8px; margin-top: 4px; }
.dots button { width: 9px; height: 9px; border-radius: 9px; background: rgba(255,255,255,.2); transition: .3s; }
.dots button.on { width: 30px; background: var(--neon); box-shadow: 0 0 10px var(--neon); }

/* ---------- Modal ---------- */
.modal {
  position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 16px;
  background: rgba(0,0,0,.78); backdrop-filter: blur(8px);
  opacity: 0; pointer-events: none; transition: .25s;
}
.modal.open { opacity: 1; pointer-events: auto; }
.modal-box {
  width: min(560px, 100%); max-height: calc(100vh - 32px); overflow: auto;
  padding: 26px; border-radius: 20px; position: relative;
  background: var(--panel); border: 1px solid var(--neon-soft);
  box-shadow: 0 0 50px rgba(124,255,90,.2); transform: scale(.96); transition: .25s;
}
.modal.open .modal-box { transform: none; }
.modal-box h2 { font-size: 21px; margin-bottom: 16px; padding-right: 40px; }
.close { position: absolute; top: 16px; right: 16px; width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,.06); display: grid; place-items: center; }
.close:hover { background: rgba(255,255,255,.14); }

.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 300; transform: translate(-50%, 20px);
  padding: 12px 18px; border-radius: 12px; background: #111a15; border: 1px solid var(--neon-soft);
  font-size: 14px; opacity: 0; transition: .3s; pointer-events: none; max-width: calc(100% - 32px);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.erro { border-color: var(--red); }

@media (max-width: 640px) {
  .card { --w: 60vw; }
  .stage { height: 118vw; max-height: 540px; }
  .arrow { width: 44px; height: 44px; margin-top: -22px; }
  .arrow.prev { left: 6px; } .arrow.next { right: 6px; }
  .logo { font-size: 18px; }
}
