/* layout.css */
.hidden { display: none !important; }

#landing-page, #quiz-page, #summary-page, #result-page {
  min-height: 100vh;
}

/* ── Ambient background ── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 50% at 15% 10%, rgba(79,142,247,.08) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 85% 85%, rgba(168,85,247,.07) 0%, transparent 60%),
    radial-gradient(ellipse 40% 30% at 50% 50%, rgba(45,212,191,.04) 0%, transparent 60%);
}

/* ── Site header ── */
.site-header {
  position: relative;
  z-index: 10;
  padding: 24px 40px;
  display: flex;
  align-items: center;
}

.logo {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 900;
  background: linear-gradient(135deg, var(--primary), var(--teal));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.logo-tm {
  font-size: .55em;
  vertical-align: super;
  -webkit-text-fill-color: var(--text-muted);
  font-weight: 600;
}

/* ── Landing ── */
.landing-main {
  position: relative;
  z-index: 1;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 32px 40px 80px;
  display: grid;
  grid-template-columns: 1fr 400px;
  gap: 56px;
  align-items: center;
  min-height: calc(100vh - 88px);
}

/* ── Quiz header ── */
.quiz-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(15,17,23,.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 12px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.quiz-logo {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 1.1rem;
  background: linear-gradient(135deg, var(--primary), var(--teal));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  flex-shrink: 0;
}

/* ── Clickable step dots in header ── */
.quiz-steps {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
  justify-content: center;
  flex-wrap: wrap;
  padding: 0 8px;
}
.quiz-step-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: transparent;
  font-size: .65rem;
  font-weight: 800;
  color: var(--text-light);
  cursor: pointer;
  transition: all .18s;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  flex-shrink: 0;
}
.quiz-step-dot:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}
.quiz-step-dot.answered {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary);
}
.quiz-step-dot.current {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 0 12px rgba(79,142,247,.4);
}
.quiz-step-dot.locked {
  cursor: default;
  opacity: .4;
}
.quiz-step-dot.locked:hover {
  border-color: var(--border);
  color: var(--text-light);
  background: transparent;
}

.quiz-progress-label {
  font-family: var(--font-body);
  font-size: .8rem;
  font-weight: 600;
  color: var(--text-muted);
  flex-shrink: 0;
  white-space: nowrap;
}
.quiz-back-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: .82rem;
  font-weight: 700;
  color: var(--text-muted);
  transition: color var(--transition);
  padding: 6px 0;
  flex-shrink: 0;
}
.quiz-back-btn:hover { color: var(--primary); }

/* ── Progress bar ── */
.progress-bar-wrap {
  padding: 0 28px 10px;
  background: rgba(15,17,23,.92);
  backdrop-filter: blur(16px);
}
.progress-bar-track {
  height: 4px;
  background: var(--bg-subtle);
  border-radius: 99px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--teal));
  border-radius: 99px;
  transition: width .5s cubic-bezier(.4,0,.2,1);
}

/* ── Quiz body ── */
.quiz-body {
  max-width: 620px;
  margin: 0 auto;
  padding: 36px 24px 60px;
}
.question-area { min-height: 300px; }

/* ── Summary ── */
.summary-body {
  max-width: 680px;
  margin: 0 auto;
  padding: 20px 24px 32px;
}

/* ── Result ── */
.result-header { justify-content: space-between; }
.result-body {
  max-width: 680px;
  margin: 0 auto;
  padding: 32px 24px 60px;
}
.result-actions {
  display: flex;
  gap: 14px;
  margin-top: 24px;
  justify-content: center;
  flex-wrap: wrap;
}
