:root {
  --ink: #151515;
  --ink-2: #2b2b2b;
  --muted: #5f5953;
  --faint: #8d8680;
  --bg: #ffffff;
  --sand: #f4f2ef;
  --line: #e2ded9;
  --red: #c8383a;
  --red-ink: #a52b2d;
  --red-soft: #f2a49a;
  --pink: #f7e3e1;
  --green-bg: #e2f0e1;
  --green-ink: #2e6a33;
  --amber-bg: #fbecd0;
  --amber-ink: #7d5200;
  --gray-bg: #ececea;

  --f-display: "Oswald", "Arial Narrow", sans-serif;
  --f-head: "Montserrat", system-ui, sans-serif;
  --f-body: "Be Vietnam Pro", system-ui, sans-serif;

  --radius: 10px;
  --radius-lg: 14px;
  --gutter: 16px;
  --maxw: 1180px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
}
img, svg { display: block; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, p { margin: 0; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff; padding: 8px 12px; z-index: 100; }
.skip:focus { left: 8px; top: 8px; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }

/* ---------- Top bar ---------- */
.topbar { background: var(--ink); color: #fff; position: sticky; top: 0; z-index: 30; }
.topbar__inner { display: flex; align-items: center; gap: 14px; min-height: 62px; padding-top: 10px; padding-bottom: 10px; }
.brand { display: flex; flex-direction: column; text-decoration: none; line-height: 1.1; margin-right: auto; }
.brand__logo { font-family: var(--f-display); font-weight: 700; font-size: 22px; letter-spacing: .08em; }
.brand__tag { font-size: 12.5px; color: var(--red-soft); margin-top: 3px; }
.back-btn, .menu-btn {
  width: 42px; height: 42px; flex: none; display: none; place-items: center;
  border: 1px solid #4a4a4a; border-radius: 10px; background: transparent; cursor: pointer; color: #fff;
}
.back-btn svg, .menu-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
body.is-sub .back-btn { display: grid; }
.menu-btn { display: grid; }
body.is-sub .menu-btn { display: none; }

.mainnav { display: none; align-items: center; gap: 4px; }
.mainnav a { text-decoration: none; font-family: var(--f-head); font-weight: 600; font-size: 14px; padding: 9px 12px; border-radius: 8px; color: #e9e6e2; }
.mainnav a:hover { background: #262626; }
.mainnav a.is-active { background: #2e2e2e; color: #fff; }
.mainnav .mainnav__cta { background: var(--red); color: #fff; margin-left: 6px; padding: 9px 16px; }
.mainnav .mainnav__cta:hover, .mainnav .mainnav__cta.is-active { background: var(--red-ink); }

/* Mobile pill shortcuts (home only) */
.pills { display: flex; gap: 8px; overflow-x: auto; padding: 12px var(--gutter) 4px; scrollbar-width: none; }
.pills::-webkit-scrollbar { display: none; }
body.is-sub .pills { display: none; }
.pills a {
  flex: none; text-decoration: none; font-family: var(--f-head); font-weight: 600; font-size: 13px;
  padding: 7px 14px; border: 1px solid var(--line); border-radius: 999px; background: #fff;
}
.pills a:first-child { background: var(--ink); color: #fff; border-color: var(--ink); }

.drawer { position: fixed; inset: 62px 0 0 0; background: rgba(0,0,0,.45); z-index: 25; }
.drawer__panel { background: #fff; padding: 12px var(--gutter) 20px; display: flex; flex-direction: column; }
.drawer__panel a:not(.btn) { padding: 14px 4px; border-bottom: 1px solid var(--line); text-decoration: none; font-family: var(--f-head); font-weight: 600; }
.drawer__panel .btn { margin-top: 16px; }

/* ---------- Type ---------- */
.eyebrow { font-family: var(--f-head); font-weight: 700; font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--red-ink); }
.display {
  font-family: var(--f-display); font-weight: 700; text-transform: uppercase;
  font-size: clamp(30px, 7.5vw, 54px); line-height: 1.14; letter-spacing: .005em; margin-top: 8px;
}
.lead { color: var(--ink-2); font-size: 16px; margin-top: 12px; max-width: 34em; }
.h2 { font-family: var(--f-head); font-weight: 700; font-size: 20px; line-height: 1.3; }
.h3 { font-family: var(--f-head); font-weight: 700; font-size: 16px; line-height: 1.35; }
.muted { color: var(--muted); }
.small { font-size: 13.5px; }

/* ---------- Sections ---------- */
.section { padding-block: 28px; }
.section--sand { background: var(--sand); }
.section + .section--sand, .section--sand + .section { border-top: 0; }
.stack > * + * { margin-top: 12px; }
.desktop-only { display: none !important; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--f-head); font-weight: 700; font-size: 15px; text-decoration: none;
  min-height: 48px; padding: 12px 20px; border-radius: var(--radius);
  border: 1.5px solid var(--ink); background: #fff; color: var(--ink); cursor: pointer;
}
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: #000; }
.btn--red { background: var(--red); border-color: var(--red); color: #fff; }
.btn--red:hover { background: var(--red-ink); border-color: var(--red-ink); }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.link-red { color: var(--red-ink); font-weight: 600; text-underline-offset: 3px; }

/* ---------- Hero ---------- */
.hero { padding-block: 24px 8px; }
.hero__grid { display: grid; gap: 24px; }
.next-box { background: var(--sand); border-radius: var(--radius); padding: 10px 12px; margin-top: 16px; font-size: 14px; }
.next-box strong { display: block; font-family: var(--f-head); }
.next-line { margin-top: 18px; font-size: 14px; color: var(--muted); }

/* ---------- Update card ---------- */
.update { background: var(--sand); border-radius: var(--radius-lg); padding: 20px 16px; }
.update__head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.update__time { font-size: 13px; color: var(--muted); white-space: nowrap; }
.status { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.status + .status { margin-top: 10px; }
.status p + p { margin-top: 8px; }
.tag {
  display: inline-block; font-family: var(--f-head); font-weight: 700; font-size: 11.5px; letter-spacing: .04em;
  text-transform: uppercase; padding: 3px 9px; border-radius: 999px; margin-bottom: 8px;
}
.tag--done { background: var(--green-bg); color: var(--green-ink); }
.tag--doing { background: var(--amber-bg); color: var(--amber-ink); }
.tag--todo { background: var(--gray-bg); color: #4a4a4a; }
.tag--red { background: var(--pink); color: var(--red-ink); }
.update__more { display: inline-block; margin-top: 16px; }

/* ---------- Tiers ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  font-family: var(--f-head); font-weight: 600; font-size: 14px; line-height: 1.3;
  padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; cursor: pointer; text-align: left;
}
.chip:hover { border-color: #bdb6ae; }
.chip[aria-pressed="true"], .chip[aria-checked="true"], .chip.is-on { background: var(--ink); border-color: var(--ink); color: #fff; }
.tier-table { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-top: 14px; }
.tier-table__row { display: grid; grid-template-columns: 1fr 1.15fr; gap: 10px; padding: 12px 13px; border-top: 1px solid var(--line); font-size: 14px; align-items: center; }
.tier-table__row:first-child { border-top: 0; background: var(--sand); color: var(--muted); }
.tier-table__row b { font-family: var(--f-head); color: var(--ink); text-align: right; }

/* ---------- Action cards ---------- */
.cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.card {
  display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 16px 14px; text-decoration: none; min-height: 112px; transition: border-color .15s, transform .15s;
}
.card:hover { border-color: var(--ink); transform: translateY(-1px); }
.card__icon { width: 20px; height: 20px; color: var(--red); margin-bottom: 10px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.card .h3 { font-size: 15px; }
.card p { font-size: 13.5px; color: var(--muted); margin-top: 6px; }

/* ---------- CTA band ---------- */
.cta { background: var(--ink); color: #fff; border-radius: var(--radius-lg); padding: 22px 16px; display: grid; gap: 18px; }
.cta .eyebrow { color: var(--red-soft); }
.cta .display { font-size: clamp(26px, 6.2vw, 38px); }
.cta p { color: #e6e2de; margin-top: 10px; }

/* ---------- Upcoming ---------- */
.upcoming { display: grid; gap: 10px; margin-top: 14px; }
.upcoming__item { display: flex; justify-content: space-between; align-items: center; gap: 12px; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; background: #fff; }
.upcoming__item b { font-family: var(--f-head); font-weight: 600; }
.upcoming__item span { font-family: var(--f-head); font-weight: 700; font-size: 13.5px; color: var(--red-ink); white-space: nowrap; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 10px; margin-top: 14px; }
.faq details { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 12px; padding: 14px; font-family: var(--f-head); font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--red); font-size: 20px; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 0 14px 14px; color: var(--ink-2); font-size: 15px; }

/* ---------- Forms ---------- */
.page-head { padding-block: 24px 20px; }
.page-head .display { margin-top: 0; }
.form-sec { padding-block: 22px; }
.form-sec .h2 { font-size: 18px; margin-bottom: 12px; }
.form-sec .hint { font-size: 13.5px; color: var(--muted); margin: -6px 0 12px; }
.field { display: block; margin-top: 14px; }
.field:first-of-type { margin-top: 0; }
.field > span { display: block; font-family: var(--f-head); font-weight: 600; font-size: 14px; margin-bottom: 6px; }
.input, .select, .textarea {
  width: 100%; border: 1px solid #d6d1cb; border-radius: var(--radius); background: #fff;
  padding: 12px 12px; min-height: 48px; font-size: 16px;
}
.textarea { min-height: 96px; resize: vertical; }
.input::placeholder, .textarea::placeholder { color: #9a938c; }
.input.is-invalid, .select.is-invalid, .textarea.is-invalid { border-color: var(--red); background: #fff7f6; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.upload {
  display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 14px;
  border: 1.5px dashed #bdb6ae; border-radius: var(--radius); padding: 13px; cursor: pointer;
  font-family: var(--f-head); font-weight: 600; font-size: 14.5px; background: transparent;
}
.upload svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.upload input { display: none; }
.upload-list { font-size: 13px; color: var(--muted); margin-top: 6px; }
.check { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; font-size: 14.5px; }
.check input { width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--ink); flex: none; }
.check.is-invalid { color: var(--red-ink); }
.submit-wrap { padding-block: 18px 8px; }
.note { font-size: 13.5px; color: var(--muted); margin-top: 12px; }
.error-msg { color: var(--red-ink); font-size: 14px; margin-top: 10px; font-weight: 600; }

/* Option cards (radio / checkbox) */
.opts { display: grid; gap: 10px; }
.opt {
  display: flex; gap: 14px; align-items: flex-start; text-align: left; width: 100%;
  border: 1px solid var(--line); border-radius: var(--radius); background: #fff; padding: 13px 14px; cursor: pointer;
}
.opt b { display: block; font-family: var(--f-head); font-weight: 700; font-size: 15px; }
.opt small { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }
.opt__mark { width: 20px; height: 20px; flex: none; margin-top: 2px; border: 2px solid #8b847d; border-radius: 50%; display: grid; place-items: center; }
.opt--check .opt__mark { border-radius: 5px; }
.opt[aria-checked="true"] { border: 1.5px solid var(--ink); }
.opt[aria-checked="true"] .opt__mark { border-color: var(--ink); }
.opt[aria-checked="true"] .opt__mark::after { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--ink); }
.opt--check[aria-checked="true"] .opt__mark { background: var(--ink); }
.opt--check[aria-checked="true"] .opt__mark::after {
  width: 10px; height: 6px; border-radius: 0; background: none;
  border-left: 2.5px solid #fff; border-bottom: 2.5px solid #fff; transform: rotate(-45deg) translate(1px, -1px);
}

.seg { display: grid; grid-template-columns: 1fr 1fr; background: var(--sand); border-radius: 12px; padding: 4px; margin-top: 18px; }
.seg button { border: 0; background: transparent; border-radius: 9px; padding: 11px; font-family: var(--f-head); font-weight: 700; cursor: pointer; }
.seg button[aria-selected="true"] { background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.08); }

.progress { margin-top: 18px; }
.progress__meta { display: flex; justify-content: space-between; font-size: 13.5px; color: var(--muted); }
.progress__bar { height: 6px; background: var(--gray-bg); border-radius: 99px; margin-top: 6px; overflow: hidden; }
.progress__bar i { display: block; height: 100%; background: var(--red); border-radius: 99px; transition: width .25s; }

.scale { display: flex; gap: 8px; }
.scale .chip { width: 44px; text-align: center; padding-block: 10px; }
.yesno { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.yesno .chip { text-align: center; padding: 14px; }

.notice { background: var(--pink); border-radius: var(--radius); padding: 14px; margin-top: 14px; }
.notice .h3 { font-size: 15px; margin-bottom: 6px; }
.notice p { font-size: 14.5px; color: var(--ink-2); }

.dark-head { background: var(--ink); color: #fff; padding-block: 24px 26px; }
.dark-head .eyebrow { color: var(--red-soft); }
.dark-head p { color: #e6e2de; margin-top: 12px; }

.council { border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 18px 16px; margin: 20px 0 8px; }
.council .h2 { margin: 4px 0 8px; }
.council p { color: var(--ink-2); font-size: 15px; }
.council .btn { margin-top: 16px; width: 100%; }

/* Success + lookup */
.success { text-align: left; padding-block: 32px 40px; }
.success__code { display: inline-block; font-family: var(--f-display); font-size: 30px; letter-spacing: .06em; background: var(--sand); padding: 6px 14px; border-radius: 8px; margin: 14px 0; }
.result { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; margin-top: 16px; }
.result dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 10px 0 0; font-size: 14.5px; }
.result dt { color: var(--muted); }
.result dd { margin: 0; font-weight: 500; }

/* ---------- Footer ---------- */
.footer { background: var(--ink); color: #fff; padding-block: 26px 30px; margin-top: 0; }
.footer__inner { display: grid; gap: 14px; }
.footer p { font-size: 14.5px; margin-top: 8px; color: #e6e2de; }
.footer__links { display: flex; flex-direction: column; gap: 6px; }
.footer__links a { color: var(--red-soft); font-size: 14.5px; text-underline-offset: 3px; }
.footer__links .footer__admin { color: #8d8680; }

.toast {
  position: fixed; left: 50%; bottom: 20px; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 10px; font-size: 14.5px; transition: .2s; z-index: 50;
  max-width: calc(100% - 32px);
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* Narrow form column even on desktop */
.narrow { max-width: 640px; }

/* ---------- Desktop ---------- */
@media (min-width: 960px) {
  :root { --gutter: 24px; }
  .menu-btn, body.is-sub .back-btn { display: none; }
  .mainnav { display: flex; }
  .pills { display: none; }
  .drawer { display: none !important; }
  .brand { flex-direction: row; align-items: baseline; gap: 14px; }
  .brand__logo { font-size: 26px; }
  .brand__tag { font-size: 14px; }
  .topbar__inner { min-height: 72px; }
  .mobile-only { display: none !important; }
  .desktop-only { display: block !important; }

  .hero { padding-block: 48px 40px; }
  .hero__grid { grid-template-columns: 1.05fr 1fr; gap: 40px; align-items: start; }
  .lead { font-size: 17px; }
  .update { padding: 22px 20px; }
  .update .status { display: grid; grid-template-columns: 110px 1fr; gap: 14px; }
  .update .status .tag { background: none; padding: 0; margin: 2px 0 0; align-self: start; }
  .update .status .tag--done { color: var(--green-ink); }
  .update .status .tag--doing { color: var(--amber-ink); }
  .update .status p + p { margin-top: 4px; }

  .section { padding-block: 44px; }
  .h2 { font-size: 24px; }
  .cards { grid-template-columns: repeat(4, 1fr); gap: 14px; }
  .card { padding: 20px 18px; }
  .card__icon { display: none; }
  .card .h3 { font-size: 17px; }
  .card p { font-size: 14.5px; }
  .cta { grid-template-columns: 1fr auto; align-items: center; padding: 30px 32px; gap: 32px; }
  .cta p { max-width: 40em; }
  .upcoming { grid-template-columns: repeat(3, 1fr); gap: 14px; }
  .upcoming__item { padding: 18px 16px; }

  .footer__inner { grid-template-columns: 1fr auto; align-items: start; }
  .footer__links { flex-direction: row; gap: 20px; }

  .page-head { padding-block: 44px 28px; }
  .tier-table { max-width: 640px; }
  .faq { max-width: 760px; }
}
