/* baseline reset (auto-injected) */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body { line-height: 1.5; -webkit-font-smoothing: antialiased; min-height: 100vh; }
img, picture, video, canvas, svg { display: block; max-width: 100%; }
input, button, textarea, select { font: inherit; }
ul, ol { list-style: none; }
button { background: none; border: none; cursor: pointer; }
a { color: inherit; text-decoration: none; }

:root {
  --color-primary: #FF6B6B;
  --color-accent: #FFD93D;
  --color-background: #1A0A2E;
  --color-surface: rgba(20, 8, 40, 0.82);
  --color-text: #FFFFFF;
  --color-text-muted: rgba(255, 255, 255, 0.65);
  --color-surface-border: rgba(255, 107, 107, 0.25);
  --radius-btn: 5rem;
  --radius-card: 1.5rem;
  --shadow-card: 0 8px 40px rgba(0,0,0,0.45), 0 1px 0 rgba(255,217,61,0.10) inset;
  --shadow-btn-primary: 0 4px 20px rgba(255,107,107,0.40);
  --shadow-btn-accent: 0 4px 20px rgba(255,217,61,0.35);
  --transition-fast: 150ms ease;
  --transition-mid: 280ms ease;
  --font-display: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

/* ── Base ── */
.body {
  font-family: var(--font-display);
  background-color: var(--color-background);
  color: var(--color-text);
  overflow: hidden;
  min-height: 100dvh;
}

/* ── Hero background image ── */
.hero-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background-image: url('../images/hero-bg.webp');
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
}

.hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    160deg,
    rgba(26, 10, 46, 0.55) 0%,
    rgba(26, 10, 46, 0.30) 40%,
    rgba(26, 10, 46, 0.70) 100%
  );
  pointer-events: none;
}

/* ── Landing Header ── */
.landing-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 1.5rem;
  background: linear-gradient(to bottom, rgba(26,10,46,0.80) 0%, transparent 100%);
  pointer-events: none;
}

.landing-header__brand {
  font-size: clamp(0.85rem, 2.5vw, 1rem);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-accent);
  text-shadow: 0 2px 12px rgba(255,217,61,0.50);
  pointer-events: none;
  user-select: none;
}

/* ── Content Wrapper ── */
.content-wrapper {
  position: fixed;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}

.survey-container {
  width: 100%;
  height: 100%;
  position: relative;
  left: 0;
  top: 0;
  z-index: 2;
}

/* ── Step ── */
.step {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  max-width: 42rem;
  display: none;
  padding: clamp(1.25rem, 4vw, 2.5rem);
  color: var(--color-text);
  align-items: center;
  justify-content: center;
}

[dir=rtl] .step {
  max-width: none;
}

.step.current {
  display: flex;
}

.step__inner {
  width: 100%;
  background: var(--color-surface);
  border: 1px solid var(--color-surface-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  padding: clamp(1.5rem, 5vw, 2.5rem) clamp(1.25rem, 4vw, 2.25rem);
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  animation: stepIn var(--transition-mid) both;
}

@keyframes stepIn {
  from { opacity: 0; transform: translateY(18px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0)  scale(1); }
}

/* ── Reveal heart ── */
.reveal-heart {
  display: block;
  width: clamp(80px, 20vw, 130px);
  height: auto;
  margin: 0 auto 0.5rem;
  filter: drop-shadow(0 0 24px rgba(255,107,107,0.65));
  user-select: none;
  pointer-events: none;
  animation: heartPulse 2.2s ease-in-out infinite;
}

@keyframes heartPulse {
  0%, 100% { transform: scale(1); }
  50%       { transform: scale(1.06); }
}

/* ── Step header ── */
.step__header {
  text-align: center;
}

.step__title {
  font-size: clamp(1rem, 4vw, 1.3rem);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--color-accent);
  text-shadow: 0 2px 14px rgba(255,217,61,0.40);
  text-wrap: balance;
}

/* ── Step body ── */
.step__body {
  margin-bottom: 0.5rem;
}

.step__question {
  font-size: clamp(1.15rem, 4.5vw, 1.65rem);
  font-weight: 700;
  line-height: 1.35;
  color: var(--color-text);
  text-align: center;
  text-wrap: balance;
}

/* ── Step answers ── */
.step__footer {}

.step__answers {
  display: flex;
  justify-content: center;
  gap: 0.875rem;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 0;
}

.step .step__answers.step__answers--single {
  justify-content: center;
  width: 100%;
}

.step .step__answers.step__answers--single .btn--primary {
  margin: 0;
  width: 100%;
}

.step .step__answers.step__answers--single .btn {
  margin-left: 0;
  width: 100%;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: var(--radius-btn);
  font-size: clamp(0.9rem, 3vw, 1.05rem);
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 0.875rem 1.75rem;
  min-height: 52px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background-color var(--transition-fast), filter var(--transition-fast);
  user-select: none;
  white-space: nowrap;
  overflow-wrap: break-word;
  flex: 1 1 120px;
  max-width: 100%;
}

.btn:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 3px;
}

.btn--primary {
  background: linear-gradient(135deg, #FF6B6B 0%, #FF4757 100%);
  color: #ffffff;
  box-shadow: var(--shadow-btn-primary);
}

.btn--primary:hover {
  filter: brightness(1.10);
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(255,107,107,0.55);
}

.btn--primary:active {
  transform: translateY(0);
  filter: brightness(0.95);
  box-shadow: var(--shadow-btn-primary);
}

.btn--accent {
  background: linear-gradient(135deg, #FFD93D 0%, #FFB400 100%);
  color: #1A0A2E;
  box-shadow: var(--shadow-btn-accent);
}

.btn--accent:hover {
  filter: brightness(1.08);
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(255,217,61,0.55);
}

.btn--accent:active {
  transform: translateY(0);
  filter: brightness(0.95);
  box-shadow: var(--shadow-btn-accent);
}

.btn--round {
  border-radius: var(--radius-btn);
}

/* ── Progress bar ── */
.progress {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  width: 90%;
  max-width: 22rem;
  height: 0.5rem;
  overflow: hidden;
  background: rgba(255,255,255,0.12);
  border-radius: 5rem;
  box-shadow: 0 0 0 1px rgba(255,255,255,0.08);
}

.progress .bar {
  width: 0;
  height: 100%;
  background-image: linear-gradient(90deg, var(--color-accent), var(--color-primary));
  border-radius: 5rem;
  transition: width 0.5s ease;
}

.body .progress .bar {
  background-image: linear-gradient(90deg, #FFD93D, #FF6B6B);
}

/* ── Hidden ── */
.hidden {
  display: none !important;
}

/* ── Prefers reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  .step__inner { animation: none; }
  .btn { transition: none; }
  .reveal-heart { animation: none; }
  .progress .bar { transition: none; }
}

/* ── Desktop ── */
@media (min-width: 992px) {
  .step {
    max-width: 56rem;
    padding-left: 2rem;
  }
  [dir=rtl] .step {
    max-width: none;
  }
  .step__inner {
    padding: 3rem 3.5rem;
    gap: 1.5rem;
  }
  .step__question {
    font-size: clamp(1.4rem, 2.5vw, 1.9rem);
  }
  .step__title {
    font-size: clamp(1rem, 1.5vw, 1.25rem);
  }
  .step__answers {
    gap: 1.25rem;
  }
  .btn {
    font-size: 1.05rem;
    padding: 1rem 2.25rem;
    flex: 0 1 auto;
    min-width: 160px;
    max-width: 22rem;
  }
  .step__answers.step__answers--single .btn {
    max-width: 100%;
    width: 100%;
    margin-left: 0;
  }
  .reveal-heart {
    width: 120px;
  }
}

/* ── Tablet ── */
@media (min-width: 600px) and (max-width: 991px) {
  .step {
    max-width: 50rem;
  }
  .step__inner {
    padding: 2.25rem 2.5rem;
  }
  .btn {
    flex: 0 1 auto;
    min-width: 130px;
  }
}

/* ── Heart animation (legacy) ── */
@keyframes heartfade {
  0%   { opacity: 1; }
  50%  { opacity: 0; }
}
.heart {
  z-index: 999;
  animation: heartfade 20s linear;
  position: absolute;
  pointer-events: none;
}
.heart:before,
.heart:after {
  content: '';
  background-color: #fc2a62;
  position: absolute;
  height: 30px;
  width: 45px;
  border-radius: 15px 0px 0px 15px;
}
.heart:before { transform: rotate(45deg); }
.heart:after  { left: 10.5px; transform: rotate(135deg); }

html,
body {
  scrollbar-width: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
  width: 0;
  height: 0;
}
