:root {
  --orange: #ff5a00;
  --deep-orange: #e94300;
  --yellow: #ffe600;
  --ink: #141414;
  --muted: #666;
  --line: #e8e8e8;
  --paper: #fff;
  --soft: #fff8ef;
  --blue: #0967bd;
  --pink: #e73d68;
  --purple: #7736ca;
  --green: #168f31;
  --shadow: 0 16px 40px rgba(20, 20, 20, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Yu Gothic", sans-serif;
  background:
    radial-gradient(circle at 20% 0%, rgba(255, 230, 0, 0.26), transparent 32rem),
    linear-gradient(180deg, #fffdf7 0%, #fff 45%, #fff5ea 100%);
  overflow-x: hidden;
}

button,
a {
  font: inherit;
}

button {
  cursor: pointer;
}

.text-balanced {
  word-break: keep-all;
  overflow-wrap: break-word;
  line-break: strict;
  text-wrap: pretty;
}

.text-fragment {
  display: inline;
}

.question-card__text .text-fragment,
.page-header h2 .text-fragment,
.choice__label .text-fragment {
  display: inline-block;
  max-width: 100%;
  vertical-align: baseline;
  white-space: normal;
}

.app-shell {
  width: min(100%, 980px);
  margin: 0 auto;
  background: var(--paper);
  min-height: 100vh;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.04);
  overflow-x: hidden;
}

.section {
  display: none;
  padding: 24px clamp(16px, 4vw, 36px) 40px;
  max-width: 100vw;
}

.section.is-active {
  display: block;
}

.label {
  margin: 0 0 8px;
  color: var(--deep-orange);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0;
}

.hero {
  position: relative;
  min-height: auto;
  padding: 0 0 60px;
}

.hero__media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 853 / 1844;
  background: #fff1db;
}

.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
}

.hero__content {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 40px;
  z-index: 2;
  margin: 0;
  padding: 0 clamp(18px, 4vw, 40px);
}

.hero.is-sticky-start .hero__content {
  position: fixed;
  left: 50%;
  right: auto;
  bottom: 0;
  width: min(100%, 640px);
  transform: translateX(-50%);
  padding: 18px 18px calc(24px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.94) 42%, #fff 100%);
}

.hero .hero__content > .label,
.hero .hero__content > h1,
.hero .hero__content > .hero__lead,
.hero .hero__content > .hero__types {
  display: none;
}

.hero h1 {
  display: inline-block;
  margin: 0 0 12px;
  padding: 8px 14px 10px;
  color: #fff;
  font-size: clamp(2.4rem, 12vw, 5rem);
  line-height: 0.98;
  font-weight: 800;
  background: var(--ink);
  transform: rotate(-2deg);
}

.hero__lead {
  margin: 0 0 18px;
  font-size: clamp(1.55rem, 7vw, 3.4rem);
  line-height: 1.12;
  font-weight: 800;
}

.hero__lead::first-letter {
  color: var(--deep-orange);
}

.hero__types {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
  margin: 18px 0;
}

.hero__types span {
  min-height: 56px;
  display: grid;
  place-items: center;
  padding: 8px 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--deep-orange);
  font-size: clamp(0.78rem, 3.3vw, 1rem);
  font-weight: 700;
  text-align: center;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.08);
}

.primary-button {
  width: 100%;
  min-height: 72px;
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  color: #fff;
  background: linear-gradient(90deg, var(--orange), #ff7b00);
  box-shadow: 0 10px 0 #d93600, 0 18px 32px rgba(255, 90, 0, 0.28);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-size: clamp(1.05rem, 5vw, 1.75rem);
  font-weight: 800;
  text-align: center;
  text-decoration: none;
  line-height: 1.2;
  white-space: normal;
  overflow-wrap: anywhere;
}

.primary-button:hover,
.primary-button:focus-visible {
  filter: brightness(1.04);
  outline: 3px solid rgba(255, 230, 0, 0.8);
  outline-offset: 3px;
}

.primary-button[hidden] {
  display: none;
}

.button-badge {
  flex: 0 0 auto;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--deep-orange);
  background: #fff;
  font-size: 0.95rem;
}

.button-arrow {
  flex: 0 0 auto;
  font-size: 2.4rem;
  line-height: 1;
}

.primary-button > span:not(.button-badge):not(.button-arrow) {
  min-width: 0;
}

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.page-header h2 {
  margin: 0;
  font-size: clamp(1.7rem, 7vw, 3.1rem);
  line-height: 1.08;
  font-weight: 800;
}

.complete-pill {
  flex: 0 0 auto;
  min-width: 74px;
  padding: 10px 12px;
  border-radius: 999px;
  color: #fff;
  background: var(--ink);
  font-weight: 700;
  text-align: center;
}

.progress {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 7px;
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  max-width: calc(100vw - 32px);
}

.progress li {
  aspect-ratio: 1;
  border: 2px solid #d4d4d4;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #777;
  background: #fff;
  font-size: clamp(0.65rem, 2.6vw, 0.9rem);
  font-weight: 700;
}

.progress li.is-complete {
  border-color: var(--orange);
  color: #fff;
  background: var(--orange);
}

.question-list {
  display: grid;
  gap: 14px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

#question-list {
  display: grid;
  gap: 14px;
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

.question-card {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  width: 100%;
  max-width: calc(100vw - 32px);
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.07);
  min-width: 0;
}

.question-card.is-missing {
  border-color: #e94300;
  background: #fff8f3;
  box-shadow: inset 0 0 0 2px rgba(233, 67, 0, 0.18), 0 12px 28px rgba(233, 67, 0, 0.16);
}

.question-card__title {
  margin: 0 0 6px;
  color: var(--deep-orange);
  font-size: 1.2rem;
  line-height: 1.2;
  font-weight: 800;
}

.question-card__text {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.55;
  font-weight: 600;
}

.question-card__missing {
  display: inline-flex;
  width: fit-content;
  margin: 12px 0 0;
  padding: 6px 10px;
  border-radius: 999px;
  color: #fff;
  background: #e94300;
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1.3;
}

.question-card__missing[hidden] {
  display: none;
}

.choices {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  min-width: 0;
}

.choice {
  position: relative;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 86px;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 2px solid #ffd0c0;
  border-radius: 12px;
  background: #fff;
  text-align: left;
  font-weight: 700;
  line-height: 1.45;
  white-space: normal;
  overflow-wrap: break-word;
  word-break: normal;
  line-break: strict;
}

.choice__label {
  display: block;
  min-width: 0;
}

.choice[data-choice="B"] {
  border-color: #b8d5ff;
}

.choice__mark {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  background: #e84464;
  font-weight: 800;
}

.choice[data-choice="B"] .choice__mark {
  background: var(--blue);
}

.choice.is-selected {
  border-color: var(--orange);
  background: var(--soft);
  box-shadow: inset 0 0 0 2px rgba(255, 90, 0, 0.2), 0 10px 22px rgba(255, 90, 0, 0.18);
}

.choice:focus-visible {
  outline: 3px solid rgba(255, 230, 0, 0.8);
  outline-offset: 2px;
}

.form-error {
  margin: 4px 0 0;
  padding: 12px 14px;
  border-radius: 10px;
  color: #a02100;
  background: #fff0e9;
  font-weight: 600;
}

.result-button {
  margin-top: 10px;
}

.result {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 247, 239, 0.96)),
    radial-gradient(circle at 80% 8%, rgba(255, 90, 0, 0.14), transparent 18rem);
  overflow: hidden;
}

.result__hero {
  position: relative;
  width: 100%;
  max-width: calc(100vw - 32px);
  aspect-ratio: 863 / 470;
  overflow: hidden;
  border: 2px solid #ffd8c5;
  border-radius: 22px;
  background: #fff;
}

.result__hero-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.result__headline {
  display: grid;
  gap: 8px;
  margin: 0 0 18px;
  text-align: center;
}

.result-code {
  margin: 0;
  color: var(--result-color, var(--orange));
  font-size: 0.86rem;
  font-weight: 900;
}

.result__type-label {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.15rem, 4.8vw, 1.8rem);
  line-height: 1.25;
  font-weight: 900;
}

.result h2 {
  margin: 0;
  color: var(--result-color, var(--orange));
  font-size: clamp(2.45rem, 11vw, 5rem);
  line-height: 1.05;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.result h2 .text-fragment {
  display: inline-block;
}

.result-catch {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1rem, 4.2vw, 1.45rem);
  line-height: 1.45;
  font-weight: 800;
}

.result-card {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin-top: 18px;
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.result-card h3 {
  margin: 0;
  padding: 16px 20px;
  color: #fff;
  background: var(--result-color, var(--orange));
  font-size: 1.35rem;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.result-card ul {
  list-style: none;
  margin: 0;
  padding: 16px 20px;
}

.result-card li {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 1.05rem;
  line-height: 1.65;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.result-card li > span {
  min-width: 0;
}

.result-card li:last-child {
  border-bottom: 0;
}

.result-card li::before {
  content: "✓";
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--result-color, var(--orange));
  font-weight: 800;
}

.result--preview [data-preview-locked] {
  display: none;
}

.result-locked-preview {
  display: none;
}

.result--preview .result-locked-preview {
  position: relative;
  display: grid;
  gap: 12px;
  width: 100%;
  margin-top: 18px;
  min-height: 430px;
  padding: 22px 20px 310px;
  overflow: hidden;
  border: 2px solid rgba(255, 90, 0, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 247, 239, 0.98)),
    repeating-linear-gradient(135deg, rgba(255, 90, 0, 0.08) 0, rgba(255, 90, 0, 0.08) 8px, transparent 8px, transparent 18px);
  box-shadow: var(--shadow);
}

.result--preview .result-locked-preview::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at 85% 10%, rgba(255, 90, 0, 0.18), transparent 12rem);
}

.result--preview .result-locked-preview__eyebrow {
  position: relative;
  z-index: 2;
  margin: 0;
  color: var(--result-color, var(--orange));
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.result--preview .result-locked-preview h3 {
  position: relative;
  z-index: 2;
  margin: 0;
  color: var(--ink);
  font-size: 1.35rem;
  line-height: 1.35;
  font-weight: 900;
}

.result-locked-preview__line {
  display: inline-block;
}

.result--preview .result-locked-preview__cards {
  position: absolute;
  top: 118px;
  right: 20px;
  bottom: 18px;
  left: 20px;
  z-index: 0;
  display: grid;
  gap: 12px;
  opacity: 0.76;
}

.result--preview .result-locked-preview__cards div {
  display: grid;
  gap: 8px;
  padding: 15px 14px;
  border: 1px solid rgba(40, 40, 40, 0.08);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.58);
}

.result--preview .result-locked-preview__cards span {
  display: block;
  height: 10px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(30, 30, 30, 0.16), rgba(30, 30, 30, 0.06));
}

.result--preview .result-locked-preview__cards span:nth-child(1) {
  width: 44%;
  background: linear-gradient(90deg, rgba(255, 90, 0, 0.32), rgba(255, 90, 0, 0.12));
}

.result--preview .result-locked-preview__cards span:nth-child(2) {
  width: 92%;
}

.result--preview .result-locked-preview__cards span:nth-child(3) {
  width: 74%;
}

.result--preview .result-locked-preview__cards div:nth-child(4),
.result--preview .result-locked-preview__cards div:nth-child(5) {
  opacity: 0.74;
}

.result--preview .result-locked-preview__cards::after {
  content: "";
  position: absolute;
  inset: -14px;
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 247, 239, 0.04), rgba(255, 247, 239, 0.58) 48%, rgba(255, 247, 239, 0.96)),
    radial-gradient(circle at 50% 60%, rgba(255, 255, 255, 0.8), transparent 10rem);
}

.result-pitfall h3 {
  background: var(--ink);
}

.result-pitfall p,
.result-cta p {
  margin: 0;
  padding: 18px 20px;
  font-size: 1.05rem;
  line-height: 1.8;
  font-weight: 600;
}

.result-actions {
  display: grid;
  gap: 14px;
  padding: 0 20px 20px;
}

.share-actions {
  width: 100%;
  padding: 20px 16px;
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 247, 239, 0.9)),
    radial-gradient(circle at 50% 0%, rgba(255, 90, 0, 0.14), transparent 12rem);
  text-align: center;
}

.share-actions__title {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 900;
}

.share-actions__title::before,
.share-actions__title::after {
  content: "";
  width: 28px;
  height: 2px;
  border-radius: 999px;
  background: var(--result-color, var(--orange));
}

.share-actions__grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.share-actions__button {
  appearance: none;
  position: relative;
  display: inline-flex;
  width: 50px;
  height: 50px;
  min-width: 0;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 50%;
  padding: 0;
  color: #333;
  background: #fff;
  cursor: pointer;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 900;
  line-height: 1;
  text-decoration: none;
  transition: box-shadow 0.16s ease, opacity 0.16s ease, transform 0.16s ease;
}

.share-actions__button:hover {
  opacity: 0.86;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

.share-actions__button::before,
.share-actions__button::after {
  position: absolute;
  left: 50%;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 4px);
  transition: opacity 0.12s ease, transform 0.12s ease;
  visibility: hidden;
  z-index: 2;
}

.share-actions__button::before {
  content: attr(data-share-actions-label);
  bottom: calc(100% + 8px);
  padding: 0.38rem 0.55rem;
  border-radius: 6px;
  color: #fff;
  background: #262626;
  font-size: 0.75rem;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
}

.share-actions__button::after {
  content: "";
  bottom: calc(100% + 3px);
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid #262626;
}

.share-actions__button:hover::before,
.share-actions__button:hover::after,
.share-actions__button:focus-visible::before,
.share-actions__button:focus-visible::after,
.share-actions__button--active::before,
.share-actions__button--active::after {
  opacity: 1;
  transform: translate(-50%, 0);
  visibility: visible;
}

.share-actions__button--success::before {
  background: #16a34a;
}

.share-actions__button--success::after {
  border-top-color: #16a34a;
}

.share-actions__button--error::before {
  background: #dc2626;
}

.share-actions__button--error::after {
  border-top-color: #dc2626;
}

.share-actions__button--native {
  color: #fff;
  background: #f97316;
}

.share-actions__button--line {
  color: #fff;
  background: #06c755;
}

.share-actions__button--instagram {
  background: #fff;
}

.share-actions__button--x {
  color: #fff;
  background: #111;
}

.share-actions__button--copy {
  color: #fff;
  background: #525252;
}

.share-actions__button--hidden {
  display: none;
}

.share-actions__icon {
  display: inline-flex;
  width: 100%;
  height: 100%;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  overflow: hidden;
}

.share-actions__logo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.share-actions__logo--x {
  width: 18px;
  height: 18px;
  object-fit: contain;
}

.share-actions__svg {
  width: 20px;
  height: 20px;
}

.share-actions__status {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  border: 0;
  padding: 0;
  white-space: nowrap;
}

.result-save-status {
  margin: 0 20px 16px;
  padding: 12px 14px;
  border-radius: 10px;
  color: #554000;
  background: #fff7d6;
  font-weight: 700;
  line-height: 1.6;
}

.result-save-status[data-state="saved"] {
  color: #0f5f24;
  background: #e9f8ed;
}

.result-save-status[data-state="error"] {
  color: #a02100;
  background: #fff0e9;
}

.result-login-actions {
  position: absolute;
  right: 20px;
  bottom: 34px;
  left: 20px;
  z-index: 2;
  display: grid;
  gap: 10px;
  padding: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.result-login-actions[hidden],
.result-save-status[hidden] {
  display: none;
}

.login-link {
  display: flex;
  width: 100%;
  max-width: 400px;
  min-height: 48px;
  margin-inline: auto;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--result-color, var(--orange));
  border-radius: 999px;
  padding: 10px 18px;
  color: var(--result-color, var(--orange));
  background: #fff;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
  text-decoration: none;
  white-space: normal;
}

.login-link--primary {
  color: #fff;
  background: var(--result-color, var(--orange));
}

.result-actions .primary-button {
  width: 100%;
  max-width: 400px;
  min-height: 60px;
  margin-inline: auto;
  font-size: 1rem;
  box-shadow: none;
}

.result-actions .share-actions,
.result-actions [data-meeting-cta] {
  grid-column: 1 / -1;
}

.text-button {
  display: block;
  margin: 0 auto 20px;
  border: 0;
  padding: 8px 12px;
  color: var(--muted);
  background: transparent;
  font-weight: 600;
  text-decoration: underline;
}

@media (min-width: 760px) {
  .app-shell {
    width: min(calc(100% - 48px), 980px);
    margin: 24px auto;
    border-radius: 24px;
    overflow: hidden;
  }


  .hero__media {
    width: min(100%, 640px);
    margin: 0 auto;
    aspect-ratio: 853 / 1844;
  }

  .hero__content {
    width: min(100%, 640px);
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    padding: 0 32px;
  }

  .hero.is-sticky-start .hero__content {
    padding: 18px 32px calc(24px + env(safe-area-inset-bottom));
  }

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

@media (min-width: 841px) {
  .question-card {
    grid-template-columns: 0.6fr 1.5fr;
    align-items: center;
    padding: 18px;
  }

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

@media (max-width: 840px) {
  .text-fragment {
    display: inline-block;
    max-width: 100%;
    vertical-align: baseline;
    white-space: normal;
  }
}

@media (max-width: 520px) {
  .app-shell {
    width: 100vw;
    max-width: 100vw;
  }

  .section {
    width: 100vw;
  }

  .primary-button {
    gap: 8px;
    padding: 10px 14px;
    font-size: 1rem;
  }

  .hero__content {
    bottom: 20px;
  }


  .result h2 {
    font-size: clamp(2.25rem, 10vw, 2.9rem);
  }

  .choice {
    font-size: 0.95rem;
  }

  .result-card li span {
    max-width: calc(100vw - 118px);
  }

  .result-card li {
    grid-template-columns: 30px minmax(0, 1fr);
    gap: 8px;
    font-size: 0.88rem;
    line-height: 1.55;
  }

  .result-card li::before {
    width: 30px;
    height: 30px;
  }

  .result-pitfall p,
  .result-cta p {
    max-width: calc(100vw - 40px);
    font-size: 0.9rem;
  }

  .result-card h3 {
    font-size: 1.12rem;
  }

  .button-badge {
    width: 48px;
    height: 48px;
    font-size: 0.82rem;
  }
}
