/* Header, section bar, page rhythm and footer adapted from FrontierCS's site (MIT): see assets/vendor/frontier-cs/LICENSE. */
/* One sticky row: the brand, the sections and the theme switch. */
.topbar { position: sticky; top: 0; z-index: 40; background: var(--paper); }
.topbar-inner { max-width: calc(var(--max) + 2 * var(--gutter)); height: 76px; margin: 0 auto; padding: 0 var(--gutter); display: flex; align-items: center; justify-content: flex-start; gap: 40px; }
.brand { display: inline-flex; align-items: center; gap: 9px; font: 500 23px/1 var(--font-sans); letter-spacing: -0.01em; color: var(--ink); text-decoration: none; }
.sub { display: flex; align-self: stretch; margin-left: auto; gap: 30px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.sub::-webkit-scrollbar { display: none; }
.sub a { flex: none; display: flex; align-items: center; text-decoration: none; color: var(--ink-3); font: 400 13px/1 var(--font-mono); letter-spacing: .02em; text-transform: uppercase; white-space: nowrap; }
.sub a:hover { color: var(--ink); }
.sub a.on { color: var(--ink); }
h1 { color: var(--ink); text-wrap: balance; }
h2 { font-weight: 600; font-size: clamp(25px, 2.4vw, 30px); line-height: 1.2; color: var(--ink); margin: 0 0 22px; }
/* Questions and Notes share these columns: the heading in a margin, the text beside it, centered as one block. */
.faq, .notes-block { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 24px 40px; align-items: start; max-width: 1060px; margin-inline: auto; }
.faq { padding-top: 88px; }
.faq h2, .notes-block h3 { font-size: clamp(30px, 3.2vw, 40px); font-weight: 500; line-height: 1.1; margin: 0; }
.faq details { border-bottom: 1px solid var(--rule); }
.fqlist { border-top: 1px solid var(--ink-2); }
/* Optimistic reads heavier than FrontierCS's Hanken Grotesk at 500, so the weight is a step lighter. */
.faq summary { list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 18px; padding: 16px 0; font-size: clamp(18px, 1.7vw, 21px); font-weight: 450; line-height: 1.3; color: var(--ink); cursor: pointer; }
.faq summary:hover { color: var(--blue); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 14px; height: 14px; background: linear-gradient(currentColor, currentColor) center / 14px 1.6px no-repeat, linear-gradient(currentColor, currentColor) center / 1.6px 14px no-repeat; transition: background-size .2s; }
.faq details[open] summary::after { background-size: 14px 1.6px, 1.6px 0; }
.ans { padding: 0 0 20px; max-width: 40em; }
.ans p { margin: 0 0 10px; color: var(--ink-2); font-size: 17px; line-height: 1.5; }
.ans p:last-child { margin-bottom: 0; }
@media (max-width: 800px) { .faq, .notes-block { grid-template-columns: minmax(0, 1fr); } }
@media (prefers-reduced-motion: no-preference) {
  :root { interpolate-size: allow-keywords; }
  .faq details::details-content { block-size: 0; overflow: hidden; transition: block-size .22s ease, content-visibility .22s allow-discrete; }
  .faq details[open]::details-content { block-size: auto; }
}
footer.foot { margin-top: 120px; padding: 56px 0 28px; background: #202124; color: #e8eaed; font-size: 15px; }
.foot-inner { max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.foot .brand { color: #fff; font-size: 26px; }
.foot p { margin: 0; font-size: 14px; color: #9aa0a6; }
@media (max-width: 1000px) {
  .topbar-inner { height: 60px; gap: 22px; }
}
@media (max-width: 720px) {
  .topbar-inner { height: auto; flex-wrap: wrap; gap: 0 12px; padding-top: 10px; }
  .topbar-inner .brand { height: 36px; }
  .sub { order: 3; width: 100%; height: 40px; gap: 22px; margin-left: 0; }
  #theme-toggle { margin-left: auto; }
  .brand { font-size: 18px; }
  .faq { padding-top: 56px; }
  footer.foot { margin-top: 72px; padding: 36px 0 24px; }
  .foot .brand { font-size: 20px; }
}
/* Keeps the theme switch on the brand's row on the narrowest phones. */
@media (max-width: 360px) {
  .topbar .brand { font-size: 16px; gap: 6px; }
}
