@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,600;1,300;1,400&family=DM+Sans:wght@300;400;500&display=swap');

/* ── RESET ───────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --cream:    #FAF7F2;
  --sand:     #EDE8DF;
  --sand2:    #E0D9CE;
  --espresso: #1C1714;
  --brown:    #4A3728;
  --gold:     #B8965A;
  --gold2:    #D4AE72;
  --muted:    #8A8278;
  --radius:   8px;
}

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--cream);
  margin: 0;
  padding: 24px 16px 60px;
  color: var(--espresso);
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}

/* ── CONTAINER ───────────────────────────────────────── */
.container {
  max-width: 680px;
  width: 100%;
  margin: 0 auto;
  background: white;
  padding: 36px 32px;
  border-radius: 16px;
  border: 1px solid var(--sand2);
  box-shadow: 0 8px 40px rgba(28,23,20,0.07);
}

/* ── HEADING ─────────────────────────────────────────── */
h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.4rem, 5vw, 2.2rem);
  font-weight: 300;
  text-align: center;
  color: var(--espresso);
  letter-spacing: 0.04em;
  line-height: 1.25;
  margin-bottom: 28px;
}

/* ── INSTRUCTION ─────────────────────────────────────── */
.instruction {
  background: var(--cream);
  border: 1px solid var(--sand2);
  padding: 18px 20px;
  border-radius: var(--radius);
  margin-bottom: 32px;
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--brown);
}

.instruction strong {
  display: block;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  color: var(--gold);
  margin-bottom: 10px;
  letter-spacing: 0.03em;
  font-weight: 600;
}

.instruction ul {
  list-style: none;
  padding: 0;
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.instruction ul li::before {
  content: '—';
  color: var(--gold);
  margin-right: 8px;
}

/* ── CARD ────────────────────────────────────────────── */
.card {
  animation: fadeSlide 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

.counter {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 16px;
}

.question {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.05rem, 3.5vw, 1.35rem);
  font-style: italic;
  font-weight: 300;
  line-height: 1.65;
  color: var(--espresso);
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--sand2);
}

/* ── ANSWER BUTTONS ──────────────────────────────────── */
.answers {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.answers button {
  display: block;
  width: 100%;
  /* Min 48px tap target for phones */
  min-height: 48px;
  padding: 13px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--sand2);
  background: var(--cream);
  cursor: pointer;
  /* No translateX — causes horizontal overflow on mobile */
  transition: border-color 0.2s, background 0.2s, color 0.2s;
  text-align: left;
  color: var(--brown);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.93rem;
  font-weight: 300;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.answers button:hover,
.answers button:focus-visible {
  background: var(--sand);
  border-color: var(--gold2);
  color: var(--espresso);
  outline: none;
}

.answers button.active {
  background: linear-gradient(135deg, #f5ede0, #fdf6ec);
  border-color: var(--gold);
  color: var(--brown);
  font-style: italic;
}

/* ── NAV BUTTONS ─────────────────────────────────────── */
.nav {
  display: flex;
  gap: 10px;
  margin-top: 28px;
  flex-wrap: wrap;
}

button {
  min-height: 48px;
  padding: 12px 24px;
  border: 1px solid var(--sand2);
  border-radius: var(--radius);
  background: white;
  color: var(--muted);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.88rem;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

button:hover,
button:focus-visible {
  background: var(--espresso);
  color: var(--cream);
  border-color: var(--espresso);
  outline: none;
}

#finishBtn {
  width: 100%;
  margin-top: 10px;
  background: var(--gold);
  color: white;
  border-color: var(--gold);
  font-size: 0.9rem;
  padding: 15px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 500;
}

#finishBtn:hover,
#finishBtn:focus-visible {
  background: var(--gold2);
  border-color: var(--gold2);
  color: white;
}

/* ── RESULTS ─────────────────────────────────────────── */
#result { margin-top: 40px; }

#result h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.5rem, 5vw, 2rem);
  font-weight: 300;
  color: var(--espresso);
  margin-bottom: 28px;
  text-align: center;
}

.result-item { margin-bottom: 22px; }

.result-item strong {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  color: var(--espresso);
  letter-spacing: 0.04em;
}

.bar {
  background: var(--sand);
  height: 8px;
  border-radius: 99px;
  overflow: hidden;
  margin-top: 8px;
}

.fill {
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--gold2));
  border-radius: 99px;
  transition: width 1s cubic-bezier(0.22, 1, 0.36, 1);
}

/* ── INTERPRETATIONS ─────────────────────────────────── */
.interpretations {
  margin-top: 32px;
  padding: 24px 24px;
  background: var(--cream);
  border: 1px solid var(--sand2);
  border-radius: var(--radius);
}

.interpretations h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--gold);
  margin-bottom: 14px;
  letter-spacing: 0.04em;
}

.interpretations p {
  font-size: 0.9rem;
  line-height: 1.75;
  color: var(--muted);
  margin-bottom: 10px;
}

.interpretations p:last-child { margin-bottom: 0; }

.interpretations strong {
  color: var(--espresso);
  font-style: italic;
  font-weight: 400;
}

/* ── FINAL CTA ───────────────────────────────────────── */
.final-text {
  margin-top: 24px;
  padding: 24px;
  background: linear-gradient(135deg, #fdf6ec, #faf7f2);
  border: 1px solid rgba(184,150,90,0.3);
  border-radius: var(--radius);
  text-align: center;
}

.final-text h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.25rem;
  font-weight: 300;
  color: var(--espresso);
  margin-bottom: 10px;
}

.final-text p {
  color: var(--muted);
  font-size: 0.9rem;
  margin-bottom: 20px;
  line-height: 1.7;
}

.result-link {
  display: inline-block;
  width: 100%;
  padding: 15px 24px;
  background: var(--gold);
  color: white;
  text-decoration: none;
  border-radius: var(--radius);
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 0.88rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: background 0.2s;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.result-link:hover { background: var(--gold2); }

/* ── ANIMATION ───────────────────────────────────────── */
@keyframes fadeSlide {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── MOBILE ──────────────────────────────────────────── */
@media (max-width: 600px) {
  body { padding: 16px 12px 48px; }

  .container {
    padding: 24px 16px 28px;
    border-radius: 12px;
  }

  h1 { margin-bottom: 20px; }

  .instruction { padding: 14px 16px; margin-bottom: 24px; }

  .question { font-size: 1.05rem; margin-bottom: 20px; padding-bottom: 16px; }

  .answers { gap: 8px; }

  .answers button {
    font-size: 0.92rem;
    padding: 14px 16px;
  }

  /* Nav buttons full width and stacked */
  .nav {
    flex-direction: column;
    gap: 8px;
    margin-top: 20px;
  }

  button { width: 100%; text-align: center; }

  .interpretations { padding: 18px 16px; }
  .final-text { padding: 20px 16px; }
}
