:root{
  --bg1:#13001f;
  --bg2:#08163a;
  --accent:#FF3366;
  --text:#EAF0FF;
  --muted:rgba(234,240,255,.72);
  --border:rgba(255,255,255,.14);
  --shadow: 0 20px 60px rgba(0,0,0,.45);
  --radius:18px;
}

*{ box-sizing:border-box; }
html,body{ height:100%; }

body{
  margin:0;
  font-family:Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color:var(--text);
  background: radial-gradient(1200px 700px at 20% -10%, rgba(255,51,102,.35), transparent 55%),
              radial-gradient(900px 600px at 90% 0%, rgba(77,0,255,.25), transparent 55%),
              linear-gradient(140deg, var(--bg1), var(--bg2));
  overflow-x:hidden;
}

/* ===== TŁO WIDEO ===== */
.bg-video{
  position:fixed;
  inset:0;
  z-index:-3;
  width:100%;
  height:100%;
  object-fit:cover;
  object-position: center 20%;
  filter: saturate(1.05) contrast(1) brightness(.9);
  opacity:1;
  background: linear-gradient(140deg, var(--bg1), var(--bg2));
}

/* dodatkowy gradient i vignette dla czytelności */
.hero-bg{
  position:fixed;
  inset:0;
  z-index:-2;
  background:
    radial-gradient(1200px 700px at 20% -10%, rgba(255,51,102,.15), transparent 55%),
    radial-gradient(900px 600px at 90% 0%, rgba(124,58,237,.10), transparent 55%),
    linear-gradient(140deg, rgba(19,0,31,.08), rgba(8,22,58,.25));
  pointer-events:none;
}

.vignette{
  position:fixed;
  inset:0;
  z-index:-1;
  pointer-events:none;
  background: radial-gradient(900px 520px at 50% 20%, rgba(0,0,0,.02), rgba(0,0,0,.10) 70%, rgba(0,0,0,.20) 100%);
}

/* ===== STRUKTURA ===== */
.wrap{
  min-height:100%;
  display:flex;
  justify-content:center;
  align-items:center;
  padding:18px 14px 36px;
  position:relative;
  z-index:1;
}

.container{
  width:100%;
  max-width:980px;
  display:grid;
  gap:16px;
  align-content:center;
}

header{
  padding:16px 14px;
  border:1px solid var(--border);
  border-radius:var(--radius);
  background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.03));
  box-shadow: var(--shadow);
}

.kicker{
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding:8px 12px;
  border-radius:999px;
  background: rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.12);
  color:var(--muted);
  font-weight:600;
  font-size:12px;
  letter-spacing:.2px;
}

.dot{
  width:10px;
  height:10px;
  border-radius:50%;
  background: var(--accent);
  box-shadow: 0 0 0 6px rgba(255,51,102,.15);
}

h1{
  margin:12px 0 6px;
  font-size: clamp(30px, 5.6vw, 44px);
  line-height:1.05;
  letter-spacing:-.6px;
}

.sub{
  margin:0;
  color:var(--muted);
  font-size:15px;
  line-height:1.5;
  max-width:52ch;
}

.trust{
  margin-top:14px;
  display:flex;
  flex-wrap:wrap;
  gap:10px 14px;
  align-items:center;
  color:var(--muted);
  font-weight:600;
  font-size:13px;
}

.trust span{
  display:flex;
  align-items:center;
  gap:8px;
}

.check{
  width:18px;
  height:18px;
  border-radius:6px;
  background: rgba(255,51,102,.14);
  border:1px solid rgba(255,51,102,.28);
  display:flex;
  align-items:center;
  justify-content:center;
  color: var(--accent);
  font-weight:900;
  font-size:12px;
}

/* ===== QUIZ ===== */
.quiz-card{
  position:relative;
  padding:14px;
  border-radius:var(--radius);
  border:1px solid var(--border);
  background: linear-gradient(180deg, rgba(255,255,255,.07), rgba(255,255,255,.03));
  box-shadow: var(--shadow);
  overflow:hidden;
  z-index:1;
}

.progress-bar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:10px;
}

.progress-meta{
  display:flex;
  align-items:center;
  gap:10px;
  font-weight:800;
  letter-spacing:.2px;
}

.pill-step{
  padding:7px 10px;
  border-radius:999px;
  background: rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.12);
  font-size:12px;
  color:var(--muted);
  font-weight:700;
}

.progress-track{
  height:10px;
  border-radius:999px;
  background: rgba(255,255,255,.08);
  border:1px solid rgba(255,255,255,.12);
  overflow:hidden;
  flex:1;
}

.progress-fill{
  height:100%;
  width:0%;
  background: linear-gradient(90deg, rgba(255,51,102,.95), rgba(255,51,102,.45));
  border-right:1px solid rgba(255,255,255,.25);
  transition: width .45s ease;
}

.question-area{ padding:10px 2px 4px; }

.q-title{
  margin:10px 0 10px;
  font-size:18px;
  font-weight:800;
  letter-spacing:-.2px;
}

.options{ display:grid; gap:10px; }

.option{
  width:100%;
  text-align:left;
  padding:14px 14px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  color: var(--text);
  font-weight:800;
  font-size:15px;
  letter-spacing:.1px;
  cursor:pointer;
  transition: transform .15s ease, background .15s ease, border-color .15s ease;
  position:relative;
  overflow:hidden;
}

.option::after{
  content:"";
  position:absolute;
  inset:0;
  background: radial-gradient(600px 120px at 30% -20%, rgba(255,51,102,.20), transparent 60%);
  opacity:0;
  transition: opacity .18s ease;
  pointer-events:none;
}

.option:hover{
  transform: translateY(-1px);
  border-color: rgba(255,51,102,.55);
  background: rgba(255,51,102,.14);
}

.option:hover::after{ opacity:1; }

.option[aria-disabled="true"]{
  opacity:.6;
  cursor:not-allowed;
  transform:none;
}

.stage{ animation: stageIn .28s ease both; }

@keyframes stageIn{
  from{ opacity:0; transform: translateY(6px); }
  to{ opacity:1; transform: translateY(0); }
}

/* ===== LOADER ===== */
.loader-area{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:12px;
  min-height: 180px;
  text-align:center;
  padding:18px 10px;
}

.loader-title{
  font-size:16px;
  font-weight:900;
  letter-spacing:-.1px;
  color:rgba(255,255,255,.92);
}

.spinner{
  width:46px;
  height:46px;
  border-radius:50%;
  border:3px solid rgba(255,255,255,.18);
  border-top-color: var(--accent);
  animation: spin .9s linear infinite;
}

@keyframes spin{ to{ transform: rotate(360deg); } }

/* ===== PRZYCISK I STOPKA ===== */
.footer-cta{
  position:sticky;
  bottom:14px;
  margin-top:14px;
  z-index:5;
  display:flex;
  justify-content:center;
}

.cta{
  width:100%;
  max-width:680px;
  padding:16px 18px;
  border-radius:16px;
  border:1px solid rgba(255,51,102,.55);
  background: linear-gradient(180deg, rgba(255,51,102,.95), rgba(255,51,102,.72));
  color:#0b0013;
  font-weight:1000;
  letter-spacing:.2px;
  cursor:pointer;
  box-shadow: 0 18px 45px rgba(255,51,102,.18);
  transition: transform .15s ease, filter .15s ease;
  user-select:none;
}

.cta:hover{ transform: translateY(-1px); filter: brightness(1.03); }
.cta:active{ transform: translateY(0px); }

.cta[aria-disabled="true"]{
  opacity:.65;
  cursor:not-allowed;
  transform:none;
  filter:none;
}

.fineprint{
  margin:10px 0 0;
  color:rgba(234,240,255,.65);
  font-size:12px;
  font-weight:600;
  text-align:center;
}

/* ===== DESKTOP ===== */
@media (min-width: 820px){
  .wrap{ padding:28px 18px 44px; }
  .container{ grid-template-columns: 1.1fr .9fr; gap:18px; }
  header{ grid-column:1 / 2; height: fit-content; }
  .quiz-card{ grid-column:2 / 3; }
  .footer-cta{ grid-column: 1 / -1; }
}
