:root {
  --rose: #e87987;
  --rose-deep: #bd5864;
  --rose-soft: #f8d6d9;
  --blush: #fff2ef;
  --cream: #fffaf6;
  --paper: #fffdf9;
  --ink: #5f4d49;
  --muted: #5f4d49;
  --quiet: #a58d88;
  --sage: #6e8878;
  --honey: #b89058;
  --line: rgba(99, 61, 56, 0.13);
  --line-strong: rgba(189, 88, 100, 0.36);
  --shadow: 0 22px 70px rgba(116, 72, 68, 0.13);
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: Georgia, "Times New Roman", serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: #fcf5f0;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--font-body);
  font-kerning: normal;
  text-rendering: optimizeLegibility;
  background: #fcf5f0;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
.result-title {
  font-family: var(--font-display);
  letter-spacing: 0;
}

.app-shell {
  display: grid;
  grid-template-columns: minmax(12rem, 0.42fr) minmax(24rem, 1fr);
  gap: clamp(1rem, 3vw, 3rem);
  align-items: center;
  width: min(100%, 1120px);
  min-height: 100vh;
  margin: 0 auto;
  padding: clamp(1rem, 3vw, 2.25rem);
}

.brand-panel {
  position: relative;
  display: grid;
  align-content: center;
  justify-items: start;
  min-height: calc(100vh - clamp(2rem, 6vw, 4.5rem));
  padding: clamp(0.5rem, 1.6vw, 1.25rem) 0;
}

.brand-logo {
  width: clamp(8rem, 15vw, 11.5rem);
  height: auto;
  margin-bottom: clamp(1.8rem, 6vh, 3rem);
}

.brand-panel__copy {
  max-width: 31rem;
}

.eyebrow {
  margin: 0 0 0.85rem;
  color: var(--rose-deep);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1 {
  max-width: 15ch;
  margin-bottom: 1.15rem;
  font-size: clamp(2.45rem, 4vw, 4.1rem);
  line-height: 1.03;
}

.brand-panel__copy p:last-child {
  max-width: 29rem;
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(0.98rem, 1.25vw, 1.08rem);
  line-height: 1.75;
}

.brand-envelope {
  width: min(100%, 22rem);
  height: auto;
  margin-top: 0;
  opacity: 1;
}

.quiz-panel {
  display: grid;
  align-items: center;
  min-height: calc(100vh - clamp(2rem, 6vw, 4.5rem));
}

#screen {
  width: min(100%, 640px);
  margin: 0 auto;
}

.surface {
  width: 100%;
  padding: clamp(1.25rem, 3.3vw, 2.25rem);
  background:
    linear-gradient(180deg, rgba(255, 253, 249, 0.97), rgba(255, 250, 246, 0.94)),
    var(--paper);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 18px;
  box-shadow: var(--shadow);
}

.landing-card {
  display: grid;
  gap: 1.25rem;
}

.landing-card h2,
.gate-title {
  margin-bottom: 0.82rem;
  font-size: clamp(1.85rem, 2.8vw, 2.45rem);
  font-weight: 700;
  line-height: 1.08;
  word-spacing: normal;
}

.landing-card h2 {
  max-width: none;
  white-space: nowrap;
}

.landing-card p,
.question-kicker,
.gate-copy,
.result-description {
  color: var(--muted);
  font-size: 1.14rem;
  font-weight: 400;
  line-height: 1.52;
}

.audience-list {
  display: grid;
  gap: 0.48rem;
  padding: 0;
  margin: 0.15rem 0 0.25rem;
  list-style: none;
}

.audience-list li {
  display: grid;
  grid-template-columns: 1.1rem 1fr;
  gap: 0.65rem;
  align-items: start;
  color: #5f4d49;
  font-size: 1.1rem;
  font-weight: 400;
  line-height: 1.32;
}

.audience-list li::before {
  content: "";
  width: 0.42rem;
  height: 0.42rem;
  margin-top: 0.48rem;
  background: var(--rose);
  border-radius: 999px;
  box-shadow: 0 0 0 0.28rem rgba(232, 121, 135, 0.13);
}

.topbar {
  display: grid;
  gap: 0.65rem;
  margin-bottom: clamp(1.2rem, 4vw, 2.1rem);
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  color: var(--quiet);
  font-size: 0.92rem;
  font-weight: 400;
}

.progress-track {
  overflow: hidden;
  height: 0.34rem;
  background: rgba(189, 88, 100, 0.12);
  border-radius: 999px;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--rose), var(--honey));
  border-radius: inherit;
  transition: width 220ms ease;
}

.question-title {
  max-width: 32rem;
  margin-bottom: 0.68rem;
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 1.85vw, 1.85rem);
  font-weight: 700;
  line-height: 1.16;
  letter-spacing: 0;
  word-spacing: normal;
}

.question-kicker {
  max-width: 38rem;
  margin-bottom: 1.05rem;
  font-size: 1.08rem;
  line-height: 1.42;
}

.options {
  display: grid;
  gap: 0.55rem;
  margin: 0.85rem 0 1rem;
}

.option {
  display: grid;
  grid-template-columns: 1.6rem 1fr;
  gap: 0.72rem;
  align-items: center;
  width: 100%;
  min-height: 3.35rem;
  padding: 0.74rem 0.85rem;
  color: var(--ink);
  font-size: 1.06rem;
  font-weight: 400;
  line-height: 1.24;
  word-spacing: normal;
  text-align: left;
  background: rgba(255, 255, 255, 0.68);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 8px 22px rgba(116, 72, 68, 0.04);
  transition: border-color 160ms ease, transform 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.option:hover,
.option:focus-visible {
  border-color: var(--line-strong);
  outline: none;
  transform: translateY(-1px);
  box-shadow: 0 12px 30px rgba(116, 72, 68, 0.09);
}

.option.is-selected {
  background: #fff5f2;
  border-color: rgba(189, 88, 100, 0.66);
  box-shadow: 0 12px 34px rgba(189, 88, 100, 0.12);
}

.option-marker {
  display: grid;
  place-items: center;
  width: 1.6rem;
  height: 1.6rem;
  color: var(--rose-deep);
  font-size: 0.78rem;
  font-weight: 900;
  background: rgba(248, 214, 217, 0.32);
  border: 1px solid rgba(232, 121, 135, 0.38);
  border-radius: 50%;
}

.rating-options {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.rating-options .option {
  display: grid;
  min-height: 3.75rem;
  grid-template-columns: 1fr;
  place-items: center;
  padding: 0.75rem 0.35rem;
  text-align: center;
}

.rating-options .option-marker {
  border: 0;
  background: transparent;
  font-size: 1rem;
}

.rating-labels {
  display: flex;
  justify-content: space-between;
  margin-top: -0.25rem;
  color: var(--quiet);
  font-size: 0.78rem;
}

.actions {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 1.2rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.12rem;
  padding: 0.82rem 1.2rem;
  color: var(--ink);
  font-weight: 400;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid var(--line);
  border-radius: 999px;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover,
.button:focus-visible {
  outline: none;
  transform: translateY(-1px);
}

.button-primary {
  color: white;
  background: linear-gradient(135deg, var(--rose-deep), #d9707b);
  border-color: transparent;
  box-shadow: 0 14px 30px rgba(189, 88, 100, 0.23);
}

.button-primary:disabled {
  cursor: not-allowed;
  opacity: 0.44;
  box-shadow: none;
  transform: none;
}

.button-secondary {
  color: var(--rose-deep);
}

.button-full {
  width: 100%;
}

.gate-form {
  display: grid;
  gap: 0.78rem;
  margin-top: 1.35rem;
}

.input {
  width: 100%;
  min-height: 3.35rem;
  padding: 0.9rem 1rem;
  color: var(--ink);
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
}

.input:focus {
  border-color: var(--rose);
  outline: 3px solid rgba(232, 121, 135, 0.15);
}

.fine-print {
  margin: 0.7rem 0 0;
  color: var(--quiet);
  font-size: 0.78rem;
  line-height: 1.5;
}

.result-hero {
  display: grid;
  grid-template-columns: 9.5rem 1fr;
  gap: 1rem;
  align-items: center;
  margin-bottom: 1.15rem;
}

.persona-card {
  display: grid;
  place-items: center;
  width: 9.5rem;
  aspect-ratio: 1;
  background: linear-gradient(180deg, rgba(255, 245, 242, 0.88), rgba(255, 253, 249, 0.72));
  border: 1px solid rgba(232, 121, 135, 0.2);
  border-radius: 18px;
  overflow: hidden;
}

.persona-figure {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0.18rem;
}

.persona-shadow {
  fill: rgba(189, 88, 100, 0.09);
}

.persona-body {
  fill: #e87987;
  opacity: 0.9;
}

.persona-head {
  fill: #f8d6d9;
}

.persona-hair {
  fill: #bd5864;
  opacity: 0.9;
}

.persona-arm,
.persona-line {
  fill: none;
  stroke: #5f4d49;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.82;
}

.persona-accent {
  fill: #bd5864;
  opacity: 0.88;
}

.persona-paper {
  fill: #fffdf9;
  stroke: rgba(189, 88, 100, 0.34);
  stroke-width: 2;
}

.persona-dot {
  fill: #b89058;
}

.persona-orbit {
  fill: #fffdf9;
  stroke: #bd5864;
  stroke-width: 3;
}

.persona-soft {
  fill: rgba(248, 214, 217, 0.58);
}

.result-label {
  color: var(--rose-deep);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.result-title {
  margin: 0;
  font-size: clamp(2.35rem, 6vw, 4.2rem);
  line-height: 0.98;
}

.result-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
  margin: 1.35rem 0;
}

.result-box {
  padding: 1rem;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--line);
  border-radius: 14px;
}

.result-box h3 {
  margin-bottom: 0.55rem;
  color: var(--ink);
  font-size: 0.84rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.result-box ul {
  display: grid;
  gap: 0.45rem;
  padding-left: 1rem;
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
}

.next-step {
  padding: 1rem;
  margin-bottom: 1rem;
  color: #4d453e;
  background: rgba(110, 136, 120, 0.13);
  border: 1px solid rgba(110, 136, 120, 0.22);
  border-radius: 14px;
  line-height: 1.6;
}

.membership {
  display: grid;
  gap: 0.65rem;
  padding: 1rem;
  margin-top: 1rem;
  background: linear-gradient(135deg, #fff3f0, #fff9f2);
  border: 1px solid rgba(232, 121, 135, 0.28);
  border-radius: 14px;
}

.membership p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.share-result {
  display: grid;
  gap: 0.65rem;
  padding: 1rem;
  margin-top: 0.85rem;
  background: rgba(255, 255, 255, 0.42);
  border: 1px solid var(--line);
  border-radius: 14px;
}

.share-result p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.error {
  min-height: 1.2rem;
  margin: 0;
  color: #a33d48;
  font-size: 0.86rem;
  font-weight: 700;
}

@media (max-width: 880px) {
  body {
    background: #fcf5f0;
  }

  .app-shell {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 1rem;
    min-height: 100vh;
    padding: 1rem;
  }

  .brand-panel {
    min-height: auto;
    padding: 0.6rem 0 0;
  }

  .brand-logo {
    width: 10.25rem;
    margin-bottom: 1.7rem;
  }

  .brand-panel__copy {
    max-width: 44rem;
  }

  h1 {
    max-width: 15ch;
    font-size: clamp(2.65rem, 10vw, 4.6rem);
  }

  .brand-envelope {
    display: none;
  }

  .quiz-panel {
    min-height: auto;
    padding-bottom: 1rem;
  }
}

@media (max-width: 560px) {
  .app-shell {
    gap: 0.7rem;
    padding: 0.8rem;
  }

  .brand-logo {
    width: 7.6rem;
    margin-bottom: 0.85rem;
  }

  h1 {
    max-width: 18ch;
    margin-bottom: 0.7rem;
    font-size: clamp(2rem, 9vw, 2.55rem);
    line-height: 1.07;
  }

  .brand-panel__copy p:last-child {
    max-width: 21rem;
    font-size: 0.9rem;
    line-height: 1.5;
  }

  .surface {
    padding: 0.9rem;
    border-radius: 16px;
  }

  .landing-card {
    gap: 0.82rem;
  }

  .landing-card h2,
  .gate-title {
    font-size: 1.78rem;
  }

  .landing-card h2 {
    white-space: normal;
  }

  .question-title {
    font-size: 1.22rem;
    font-weight: 700;
    line-height: 1.16;
  }

  .landing-card p,
  .gate-copy,
  .result-description {
    font-size: 0.92rem;
    line-height: 1.55;
  }

  .question-kicker {
    font-size: 0.86rem;
    line-height: 1.45;
  }

  .audience-list {
    gap: 0.3rem;
  }

  .audience-list li {
    grid-template-columns: 0.85rem 1fr;
    gap: 0.48rem;
    font-size: 0.86rem;
    line-height: 1.3;
  }

  .audience-list li::before {
    width: 0.34rem;
    height: 0.34rem;
    margin-top: 0.4rem;
    box-shadow: 0 0 0 0.22rem rgba(232, 121, 135, 0.12);
  }

  .button {
    min-height: 2.95rem;
  }

  .rating-options {
    gap: 0.45rem;
  }

  .rating-options .option {
    min-height: 3.45rem;
    padding: 0.5rem 0.2rem;
  }

  .option {
    min-height: 3.15rem;
    padding: 0.68rem 0.75rem;
    font-size: 0.86rem;
  }

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

  .result-hero {
    grid-template-columns: 5.7rem 1fr;
    gap: 0.75rem;
  }

  .persona-card {
    width: 5.7rem;
    border-radius: 14px;
  }

  .actions {
    position: sticky;
    bottom: 0;
    padding-top: 0.75rem;
    background: linear-gradient(rgba(255, 250, 246, 0), rgba(255, 250, 246, 0.98) 28%);
  }
}
