:root {
  color-scheme: light;
  --ink: #27201d;
  --muted: #6f625c;
  --paper: #fff8f1;
  --rose: #b9475c;
  --rose-dark: #7f2437;
  --moss: #47624f;
  --gold: #c1944c;
  --good: #2f9b66;
  --bad: #d9414e;
  --shadow: 0 22px 80px rgba(88, 42, 45, 0.18);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 20% 15%, rgba(185, 71, 92, 0.18), transparent 28rem),
    linear-gradient(135deg, #fff8f1 0%, #f7ded6 48%, #dbe7d8 100%);
  overflow: hidden;
}

button {
  border: 0;
  font: inherit;
  cursor: pointer;
}

.app {
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
  isolation: isolate;
}

.app::before,
.app::after {
  content: "";
  position: fixed;
  inset: auto;
  z-index: -1;
  pointer-events: none;
}

.app::before {
  width: 44vw;
  height: 44vw;
  left: -15vw;
  bottom: -18vw;
  background: rgba(193, 148, 76, 0.28);
  transform: rotate(18deg);
  clip-path: polygon(50% 0, 100% 45%, 78% 100%, 22% 100%, 0 45%);
}

.app::after {
  width: 36vw;
  height: 36vw;
  right: -14vw;
  top: -11vw;
  border: 3px solid rgba(71, 98, 79, 0.22);
  border-radius: 999px;
}

.screen {
  min-height: 100vh;
  min-height: 100dvh;
  width: 100%;
  display: none;
  align-items: center;
  justify-content: center;
  padding: clamp(20px, 4vw, 56px);
}

.screen-active {
  display: flex;
  animation: fadeIn 460ms ease both;
}

.quiz-shell {
  width: min(1080px, 100%);
  display: grid;
  grid-template-columns: minmax(280px, 0.86fr) minmax(420px, 1fr);
  align-items: center;
  gap: clamp(24px, 5vw, 72px);
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--rose-dark);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: 0;
}

h1 {
  max-width: 560px;
  font-size: clamp(2.6rem, 8vw, 5.4rem);
}

.question-card {
  margin-top: 0;
  padding: clamp(20px, 3vw, 32px);
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(127, 36, 55, 0.12);
  border-radius: 8px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  transition:
    background 180ms ease,
    border-color 180ms ease,
    transform 180ms ease;
}

.question-card.is-good {
  background: rgba(235, 252, 241, 0.92);
  border-color: rgba(47, 155, 102, 0.55);
  transform: translateY(-2px);
}

.question-card.is-bad {
  background: rgba(255, 235, 237, 0.94);
  border-color: rgba(217, 65, 78, 0.58);
  animation: shake 260ms ease;
}

.question-count {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.question-card h2 {
  font-size: clamp(1.7rem, 3.8vw, 3rem);
}

.answers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 22px;
}

.answer-button {
  min-height: 64px;
  padding: 16px 18px;
  color: var(--ink);
  background: #ffffff;
  border: 1px solid rgba(39, 32, 29, 0.14);
  border-radius: 8px;
  font-weight: 800;
  text-align: left;
  box-shadow: 0 10px 22px rgba(39, 32, 29, 0.08);
  transition:
    transform 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease;
}

.answer-button:hover,
.answer-button:focus-visible {
  border-color: rgba(185, 71, 92, 0.52);
  box-shadow: 0 14px 28px rgba(185, 71, 92, 0.16);
  transform: translateY(-2px);
  outline: none;
}

.progress {
  display: flex;
  gap: 10px;
  margin-top: 22px;
}

.progress-dot {
  width: 48px;
  height: 6px;
  border-radius: 999px;
  background: rgba(39, 32, 29, 0.18);
}

.progress-dot.is-active,
.progress-dot.is-done {
  background: var(--rose);
}

#video-screen {
  flex-direction: column;
  gap: clamp(12px, 2vh, 18px);
}

.video-intro {
  width: min(860px, 100%);
  text-align: center;
}

.video-intro h2 {
  font-size: clamp(2rem, 5vw, 3.9rem);
}

.video-frame {
  width: min(760px, 100%);
  aspect-ratio: 16 / 9;
  position: relative;
  overflow: hidden;
  background: #1c1716;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.video-frame video,
.video-placeholder {
  width: 100%;
  height: 100%;
}

.video-frame video {
  display: block;
  object-fit: cover;
}

.video-placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  gap: 8px;
  color: #fff7ef;
  text-align: center;
  background:
    linear-gradient(rgba(28, 23, 22, 0.2), rgba(28, 23, 22, 0.48)),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, 0.05) 0 2px, transparent 2px 18px);
}

.video-placeholder.is-hidden {
  display: none;
}

.continue-button {
  min-height: 56px;
  padding: 0 24px;
  color: #fffaf4;
  background: var(--rose-dark);
  border-radius: 999px;
  font-weight: 900;
  box-shadow: 0 18px 34px rgba(127, 36, 55, 0.25);
  opacity: 0;
  transform: translateY(18px) scale(0.92);
  pointer-events: none;
  transition:
    opacity 260ms ease,
    transform 320ms cubic-bezier(0.2, 1.4, 0.36, 1);
}

.continue-button.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

#proposal-screen {
  position: relative;
  overflow: hidden;
}

.proposal-copy {
  width: min(1040px, 100%);
  padding-bottom: 108px;
  text-align: center;
}

.proposal-copy h2 {
  font-size: clamp(1.9rem, 4vw, 3.8rem);
  line-height: 1.08;
}

.proposal-actions {
  position: fixed;
  left: 50%;
  bottom: clamp(22px, 6vh, 54px);
  width: min(340px, calc(100vw - 32px));
  height: 70px;
  transform: translateX(-50%);
}

.yes-button,
.no-button {
  position: absolute;
  min-width: 132px;
  min-height: 58px;
  padding: 0 26px;
  border-radius: 999px;
  color: #fffaf4;
  font-weight: 950;
  box-shadow: 0 18px 34px rgba(39, 32, 29, 0.2);
  transition:
    transform 160ms ease,
    background 160ms ease;
}

.yes-button {
  left: 0;
  top: 6px;
  background: var(--moss);
}

.yes-button:hover,
.yes-button:focus-visible {
  transform: translateY(-2px) scale(1.04);
  outline: none;
}

.no-button {
  right: 0;
  top: 6px;
  background: var(--rose);
  transition:
    left 230ms cubic-bezier(0.2, 0.92, 0.28, 1),
    top 230ms cubic-bezier(0.2, 0.92, 0.28, 1),
    opacity 160ms ease,
    transform 160ms ease;
}

.celebration {
  width: min(780px, 100%);
  text-align: center;
}

.celebration h2 {
  font-size: clamp(3rem, 9vw, 7rem);
  line-height: 1;
}

.celebration p:last-child {
  margin: 20px auto 0;
  max-width: 520px;
  color: var(--muted);
  font-size: clamp(1.15rem, 2.5vw, 1.55rem);
  font-weight: 700;
}

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

@keyframes shake {
  20% {
    transform: translateX(-8px);
  }
  40% {
    transform: translateX(7px);
  }
  60% {
    transform: translateX(-5px);
  }
  80% {
    transform: translateX(3px);
  }
}

@media (max-width: 680px) {
  body {
    overflow: auto;
  }

  .screen {
    min-height: 100svh;
    padding: 18px;
  }

  .quiz-shell {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  h1 {
    font-size: clamp(2.65rem, 14vw, 4.6rem);
  }

  .question-card {
    margin-top: 0;
  }

  .answers {
    grid-template-columns: 1fr;
  }

  .answer-button {
    min-height: 56px;
  }

  .proposal-copy {
    padding-bottom: 120px;
  }

  .proposal-actions {
    width: min(292px, calc(100vw - 32px));
    height: 70px;
  }

  .yes-button,
  .no-button {
    min-width: 116px;
  }

  .yes-button {
    left: 0;
  }

  .no-button {
    right: 0;
  }
}
