:root {
  color-scheme: light;
  --ink: #0f1d2b;
  --ink-soft: #33414d;
  --paper: #fbf8f1;
  --paper-deep: #f1ebdf;
  --white: #fffefa;
  --gold: #805511;
  --gold-soft: #d8b873;
  --line: rgba(15, 29, 43, 0.16);
  --serif: "Iowan Old Style", "Baskerville", "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 82% 8%, rgba(216, 184, 115, 0.18), transparent 24rem),
    var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

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

h1,
h2 {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.045em;
}

a {
  color: var(--ink);
  text-decoration-color: var(--gold-soft);
  text-underline-offset: 0.24rem;
}

a:hover {
  text-decoration-color: var(--gold);
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.7rem 1rem;
  border-radius: 999px;
  background: var(--ink);
  color: var(--white);
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

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

.site-header {
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: 24px 0 16px;
}

.wordmark {
  color: var(--ink);
  font-size: 1.12rem;
  font-weight: 760;
  letter-spacing: -0.035em;
  text-decoration: none;
}

.wordmark span {
  color: var(--gold);
}

.questions-view {
  min-height: calc(100vh - 150px);
}

.questions-shell {
  width: min(880px, calc(100% - 48px));
  margin: 0 auto;
  padding: clamp(46px, 7vw, 84px) 0 96px;
}

.questions-header {
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 1.1rem;
  color: var(--gold);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}

.questions-header h1 {
  margin: 0 0 0.9rem;
  font-size: clamp(3.2rem, 6vw, 4.9rem);
  line-height: 0.98;
}

.questions-header > p:not(.eyebrow):not(.ranking-note) {
  max-width: 640px;
  margin-bottom: 0;
  color: var(--ink-soft);
  font-size: 1.05rem;
  line-height: 1.55;
}

.ranking-note {
  display: inline-block;
  margin: 1rem 0 0;
  padding-left: 0.75rem;
  border-left: 2px solid var(--gold);
  color: #69716f;
  font-size: 0.76rem;
  line-height: 1.45;
}

.question-library {
  margin-top: clamp(52px, 7vw, 76px);
}

.faq-group + .faq-group {
  margin-top: clamp(44px, 6vw, 58px);
}

.faq-group-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

.faq-group-heading h2 {
  margin: 0;
  font-size: clamp(1.75rem, 3.2vw, 2.25rem);
  line-height: 1.08;
}

.faq-group-heading > span {
  flex: none;
  color: #69716f;
  font-size: 0.74rem;
}

.faq-list {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 254, 250, 0.84);
  box-shadow: 0 18px 46px rgba(27, 34, 39, 0.08);
}

.faq-row + .faq-row {
  border-top: 1px solid var(--line);
}

.faq-row summary {
  display: grid;
  grid-template-columns: 3rem minmax(0, 1fr) 1.25rem;
  align-items: center;
  gap: 0.9rem;
  min-height: 70px;
  padding: 0.95rem 1.15rem;
  cursor: pointer;
  list-style: none;
}

.faq-row-unranked summary {
  grid-template-columns: minmax(0, 1fr) 1.25rem;
}

.faq-row-unranked .faq-rank {
  display: none;
}

.faq-row summary::-webkit-details-marker {
  display: none;
}

.faq-row summary:hover {
  background: rgba(241, 235, 223, 0.54);
}

.faq-row[open] summary {
  background: rgba(241, 235, 223, 0.38);
}

.faq-rank {
  color: var(--gold);
  font-size: 0.72rem;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.faq-question {
  font-size: 0.98rem;
  font-weight: 680;
  letter-spacing: -0.015em;
  line-height: 1.42;
}

.faq-toggle {
  position: relative;
  width: 1.25rem;
  height: 1.25rem;
  color: var(--gold);
}

.faq-toggle::before {
  position: absolute;
  inset: 50% auto auto 50%;
  content: "+";
  font-family: var(--serif);
  font-size: 1.4rem;
  line-height: 1;
  transform: translate(-50%, -50%);
}

.faq-row[open] .faq-toggle::before {
  content: "−";
}

.faq-answer {
  padding: 0 1.15rem 1.35rem;
}

.faq-answer-inner {
  margin-left: 3.9rem;
  padding: 0.15rem 1rem 0.1rem;
  border-left: 2px solid var(--gold);
}

.faq-row-unranked .faq-answer-inner {
  margin-left: 0;
}

.faq-answer p {
  max-width: 680px;
  margin-bottom: 0;
  color: var(--ink-soft);
  font-size: 0.96rem;
  line-height: 1.67;
}

.faq-resources {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.faq-resources a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 720;
}

.question-box {
  position: relative;
  margin-top: clamp(40px, 6vw, 58px);
  padding: clamp(1.4rem, 4vw, 2.25rem);
  overflow: hidden;
  border: 1px solid var(--line);
  border-top: 3px solid var(--gold);
  border-radius: 14px;
  background: rgba(255, 254, 250, 0.9);
  box-shadow: 0 18px 46px rgba(27, 34, 39, 0.08);
}

.question-box::after {
  position: absolute;
  z-index: 0;
  top: -7rem;
  right: -5rem;
  width: 15rem;
  height: 15rem;
  border-radius: 50%;
  background: rgba(216, 184, 115, 0.12);
  content: "";
  pointer-events: none;
}

.question-box > * {
  position: relative;
  z-index: 1;
}

.question-box .eyebrow {
  margin-bottom: 0.7rem;
}

.question-box h2 {
  margin-bottom: 0.45rem;
  font-size: clamp(2rem, 4vw, 2.8rem);
  line-height: 1.05;
}

.question-box-intro {
  margin-bottom: 1.6rem;
  color: var(--ink-soft);
  font-size: 1rem;
  line-height: 1.5;
}

#question-form {
  display: grid;
  gap: 1.1rem;
}

.form-field {
  display: grid;
  gap: 0.5rem;
}

.form-field label {
  font-size: 0.78rem;
  font-weight: 780;
  letter-spacing: 0.025em;
}

.form-field textarea {
  width: 100%;
  min-height: 118px;
  padding: 0.85rem 0.9rem;
  resize: vertical;
  border: 1px solid rgba(15, 29, 43, 0.24);
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  line-height: 1.5;
}

.form-field textarea::placeholder {
  color: #7a817f;
}

.form-helper {
  color: #69716f;
  font-size: 0.72rem;
  line-height: 1.45;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
}

#question-form button {
  min-height: 52px;
  padding: 0.8rem 1.35rem;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--white);
  cursor: pointer;
  font: inherit;
  font-size: 0.83rem;
  font-weight: 760;
  white-space: nowrap;
}

#question-form button:hover:not(:disabled) {
  background: #1b2c3d;
}

#question-form button:disabled {
  cursor: wait;
  opacity: 0.7;
}

.form-status {
  min-height: 1.25rem;
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.78rem;
  font-weight: 650;
  line-height: 1.45;
}

.form-status[data-state="success"] {
  color: #315c42;
}

.form-status[data-state="error"] {
  color: #9b2f25;
}

.form-trap {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.policy-note {
  margin: 1.3rem 0 0;
  color: #69716f;
  font-size: 0.74rem;
  line-height: 1.45;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: 24px 0 30px;
  color: #69716f;
  font-size: 0.7rem;
  letter-spacing: 0.05em;
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}

@media (max-width: 840px) {
  .site-header,
  .questions-shell,
  .site-footer {
    width: min(100% - 28px, 880px);
  }
}

@media (max-width: 580px) {
  .site-header {
    padding-top: 18px;
  }

  .questions-shell {
    padding: 40px 0 72px;
  }

  .questions-header h1 {
    font-size: clamp(2.8rem, 13vw, 3.45rem);
    line-height: 1;
  }

  .questions-header > p:not(.eyebrow):not(.ranking-note) {
    font-size: 1rem;
  }

  .question-library {
    margin-top: 48px;
  }

  .faq-group + .faq-group {
    margin-top: 42px;
  }

  .faq-group-heading {
    align-items: start;
  }

  .faq-group-heading h2 {
    font-size: 1.75rem;
  }

  .faq-list {
    border-radius: 12px;
    box-shadow: 0 12px 32px rgba(27, 34, 39, 0.06);
  }

  .faq-row summary {
    grid-template-columns: 2.25rem minmax(0, 1fr) 1.25rem;
    gap: 0.6rem;
    min-height: 58px;
    padding: 0.85rem 0.9rem;
  }

  .faq-row-unranked summary {
    grid-template-columns: minmax(0, 1fr) 1.25rem;
  }

  .faq-question {
    font-size: 0.93rem;
  }

  .faq-answer {
    padding: 0 0.9rem 1.05rem;
  }

  .faq-answer-inner {
    margin-left: 0;
    padding: 0.1rem 0.75rem 0;
  }

  .faq-answer p {
    font-size: 0.9rem;
  }

  .faq-resources {
    display: grid;
    gap: 0.25rem;
  }

  .faq-resources a {
    min-height: 44px;
  }

  .question-box {
    margin-top: 40px;
    padding: 1.25rem;
  }

  #question-form button {
    width: 100%;
  }

  .site-footer {
    flex-direction: column;
    gap: 0.45rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
