:root {
  --text: #111827;
  --muted: #6b7280;
  --muted-strong: rgb(75, 75, 75);
  --black: #0b0b0c;
  --white: #ffffff;
  --peach: #fdebe3;
  --radius: 16px;
  --radius-lg: 20px;
}
html,
body {
  height: 100%;
}
body {
  margin: 0;
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    "Helvetica Neue",
    Arial,
    "Noto Sans",
    "Apple Color Emoji",
    "Segoe UI Emoji";
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: var(--white);
}

.layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
}

.left {
  padding: 36px 56px 24px 56px;
  display: flex;
  flex-direction: column;
}

.brand {
  width: 130px;
  height: auto;
}

.question {
  margin-top: 28px;
  max-width: 740px;
}

.hidden {
  display: none !important;
}

.question h1 {
  margin: 0 0 14px 0;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.5rem;
  font-size: 1.25rem;
}

.question .subtitle {
  margin: 0 0 22px 0;
  color: var(--muted-strong);
  font-size: 1rem;
  line-height: 1;
}

.options {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 740px;
}

.option {
  display: grid;
  grid-template-columns: 44px 1fr; /* fixed column for perfect alignment */
  gap: 14px;
  align-items: start; /* align check with title */
  background: var(--white);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04);
  cursor: pointer;
  user-select: none;
  transition:
    box-shadow 120ms ease,
    transform 120ms ease;
}

.option:hover {
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
  transform: translateY(-1px);
}

.option[aria-checked="true"] {
  border-color: var(--black);
  border-width: 2px;
}

.option[aria-checked="false"] {
  border-color: rgba(0, 0, 0, 0.14);
  border-width: 2px;
}

.check {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border: 2px solid rgba(0, 0, 0, 0.14);
  transition:
    background 120ms ease,
    border-color 120ms ease;
}

.check .tick {
  width: 18px;
  height: 18px;
  display: none;
}

.option[aria-checked="true"] .check {
  background: var(--black);
  border: 2px solid var(--black);
}

.option[aria-checked="true"] .check .tick {
  display: block;
}

.option-title {
  font-weight: 600;
  font-size: clamp(16px, 2.4vw, 18px);
  line-height: 1.2;
}

.option-desc {
  margin-top: 4px;
  color: var(--muted-strong);
  font-size: 15px;
  line-height: 1.6;
}

/* Follow-up radio cards */
.radio-group {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 8px;
}

.radio-card {
  display: grid;
  grid-template-columns: 1fr 36px;
  align-items: center;
  background: var(--white);
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: var(--radius-lg);
  padding: 18px;
  cursor: pointer;
  user-select: none;
  transition:
    box-shadow 120ms ease,
    transform 120ms ease,
    border-color 120ms ease;
}

.radio-card:hover {
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
  transform: translateY(-1px);
}

.radio-card[aria-checked="true"] {
  border-color: var(--black);
}

.radio-title {
  font-weight: 600;
  font-size: clamp(16px, 2.4vw, 18px);
}

.indicator {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 2px solid rgba(0, 0, 0, 0.18);
  display: inline-flex;
  margin-left: 6px;
  align-items: center;
  justify-content: center;
}

.indicator::after {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--black);
  display: none;
}

.radio-card[aria-checked="true"] .indicator {
  border-color: var(--black);
}

.radio-card[aria-checked="true"] .indicator::after {
  display: block;
}

.back-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.back-btn {
  background: transparent;
  border: 0;
  color: #111827;
  font-weight: 600;
  font-size: 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.next-row {
  margin-top: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.next-btn {
  background: var(--black);
  color: var(--white);
  border: 0;
  border-radius: 999px;
  padding: 16px 28px;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  transition:
    transform 120ms ease,
    box-shadow 120ms ease,
    opacity 120ms ease;
}

.next-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.15);
  opacity: 0.98;
}

.next-btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

.hint {
  color: var(--muted);
  font-size: 14px;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 50;
}

.modal.open {
  display: flex;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
}

.modal-dialog {
  position: relative;
  background: #fff;
  border-radius: 20px;
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.25),
    0 6px 20px rgba(0, 0, 0, 0.08);
  padding: 28px 28px 24px 28px;
  width: min(720px, calc(100% - 32px));
  z-index: 1;
}

.modal-title {
  margin: 0 0 14px 0;
  font-weight: 600;
  font-size: clamp(14px, 3.2vw, 24px);
}

.modal-desc {
  color: var(--text);
  line-height: 1.6;
  margin: 12px 0 4px 0;
}

.modal-list {
  margin: 10px 0 12px 0;
  padding-left: 18px;
}

.modal-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 20px;
}

.btn {
  border: 0;
  border-radius: 14px;
  padding: 14px 22px;
  font-weight: 700;
  cursor: pointer;
}

.btn-secondary {
  background: #e9e9e9;
  color: #111;
}

.btn-primary {
  background: var(--black);
  color: #fff;
}

.modal-x {
  position: absolute;
  top: 14px;
  right: 14px;
  background: transparent;
  border: 0;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.right {
  background: var(--peach);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 24px;
}

.testimonial {
  width: min(540px, 90%);
  border-radius: 18px;
  background: linear-gradient(
    180deg,
    #ffffff 0%,
    rgba(255, 255, 255, 0.94) 100%
  );
  box-shadow:
    0 30px 60px rgba(0, 0, 0, 0.12),
    0 6px 20px rgba(0, 0, 0, 0.06);
  padding: 20px 20px 18px 20px;
}

.person {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 12px;
  align-items: center;
  margin-bottom: 8px;
}

.avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
}

.name {
  font-weight: 700;
}

.role {
  color: var(--muted);
  font-size: 14px;
}

.quote {
  color: var(--muted-strong);
  line-height: 1.6;
  font-size: 15px;
  margin-top: 6px;
}

/* Focus visibility for keyboard users */
.option:focus-visible {
  outline: 2px solid #111827;
  outline-offset: 2px;
}

.brand-link {
  position: fixed;
  top: 36px;
  left: 36px;
}

/* Mobile adjustments */
@media (max-width: 900px) {
  .layout {
    grid-template-columns: 1fr;
  }
  .modal-dialog {
    border-radius: 16px;
    padding: 22px 18px 18px 18px;
    width: min(560px, calc(100% - 48px));
  }
  .question h1 {
    margin: 0 0 14px 0;
    font-weight: 600;
    letter-spacing: -0.025em;
    line-height: 1.25rem;
    font-size: 1.125rem;
  }
  .right {
    display: none;
  }
  .left {
    padding: 22px 20px 100px 20px;
  }
  .brand {
    width: 100px;
    height: auto;
  }
  .brand-link {
    position: fixed;
    top: 24px;
    left: 24px;
  }
  .modal-title {
    font-size: 20px;
  }
  .next-row {
    display: none; /* hide the top Next on mobile */
  }
  .next-sticky {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    background: #fff;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    padding: 16px 18px 20px 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  .next-sticky .next-btn {
    padding: 16px 26px;
    font-size: 16px;
  }
  .hint {
    font-size: 13px;
  }
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
