/* Source Serif 4 (SIL Open Font License 1.1), latin subset, self-hosted. */
@font-face {
  font-family: 'Source Serif 4';
  font-style: normal;
  font-weight: 500 600;
  font-display: swap;
  src: url(/assets/fonts/source-serif-4-variable-latin.2a24bad4.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --brand: #123a47;
  --brand-dark: #0b2731;
  --sand: #e7b77a;
  --sand-deep: #9a6424;
  --paper: #fbfaf7;
  --mist: #eef3f3;
  --ink: #1a2327;
  --muted: #4d5b61;
  --rule: #d8e0e1;
  --rule-dark: #2b4f5b;
  --on-dark: #eef4f5;
  --on-dark-muted: #a8bec4;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --step--1: clamp(.83rem, .8rem + .13vw, .9rem);
  --step-0: clamp(1rem, .96rem + .19vw, 1.09rem);
  --step-1: clamp(1.2rem, 1.13rem + .35vw, 1.42rem);
  --step-2: clamp(1.44rem, 1.32rem + .6vw, 1.84rem);
  --step-3: clamp(1.73rem, 1.53rem + .98vw, 2.39rem);
  --step-4: clamp(2.07rem, 1.76rem + 1.55vw, 3.11rem);
  --sp-2: .5rem; --sp-3: .75rem; --sp-4: 1rem; --sp-5: 1.5rem; --sp-6: 2rem; --sp-7: 3rem; --sp-8: 4rem;
  --section-y: clamp(3rem, 1.8rem + 6vw, 6rem);
  --wrap: 1180px;
  --narrow: 760px;
  --gutter: clamp(1rem, .8rem + 1.8vw, 2.5rem);
  --radius: 4px;
  --shadow: 0 1px 2px rgba(11, 39, 49, .05), 0 8px 24px rgba(11, 39, 49, .07);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
[id] { scroll-margin-top: 80px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: var(--step-0)/1.7 var(--sans); }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.2; color: var(--brand-dark); margin: 0; text-wrap: balance; }
h1 { font-size: var(--step-4); letter-spacing: -.01em; }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); }
p, ul, ol { margin: var(--sp-4) 0 0; }
a { color: var(--brand); text-underline-offset: .18em; }
a:hover { color: var(--sand-deep); }
:focus-visible { outline: 3px solid var(--sand-deep); outline-offset: 2px; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: var(--narrow); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 1rem; top: 1rem; z-index: 99; background: #fff; padding: .5rem 1rem; }

/* Header */
.site-head { position: sticky; top: 0; z-index: 10; background: rgba(251, 250, 247, .96); border-bottom: 1px solid var(--rule); backdrop-filter: saturate(1.4) blur(6px); }
.site-head__inner { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 1rem; }
.logo { display: inline-flex; align-items: center; gap: .6rem; font-family: var(--serif); font-size: 1.2rem; color: var(--brand-dark); text-decoration: none; margin: 0; white-space: nowrap; }
.logo b { font-weight: 600; color: var(--sand-deep); }
.menu > summary { list-style: none; cursor: pointer; width: 44px; height: 44px; display: grid; place-items: center; }
.menu > summary::-webkit-details-marker { display: none; }
.menu > summary span, .menu > summary span::before, .menu > summary span::after { display: block; width: 22px; height: 2px; background: var(--brand-dark); position: relative; }
.menu > summary span::before, .menu > summary span::after { content: ""; position: absolute; }
.menu > summary span::before { top: -7px; } .menu > summary span::after { top: 7px; }
.menu nav { position: absolute; left: 0; right: 0; top: 64px; background: var(--paper); border-bottom: 1px solid var(--rule); display: flex; flex-direction: column; padding: var(--sp-4) var(--gutter) var(--sp-5); gap: .25rem; box-shadow: var(--shadow); }
.menu nav a { color: var(--ink); text-decoration: none; padding: .55rem 0; font-weight: 500; }
.menu nav a[aria-current] { color: var(--sand-deep); }
.menu nav .btn { margin-top: .5rem; color: #fff; text-align: center; }
/* Hidden by default so the page degrades sanely if the desktop rules never apply. */
.mega { display: none; }
.nav-desk { display: none; }
@media (min-width: 1100px) {
  .menu { display: none; }
  .site-head__inner { align-items: stretch; }
  .logo { align-self: center; }
  .nav-desk { display: flex; align-items: stretch; gap: 1.6rem; }
  .nav-desk ul { display: flex; align-items: stretch; gap: 1.5rem; list-style: none; margin: 0; padding: 0; }
  .nav-desk > ul > li { display: flex; align-items: center; }
  .nav-desk > ul > li > a { color: var(--ink); text-decoration: none; font-size: .95rem; font-weight: 500; white-space: nowrap; padding-block: .3rem; border-bottom: 2px solid transparent; }
  .nav-desk > ul > li > a:hover, .nav-desk > ul > li > a[aria-current] { border-color: var(--sand-deep); color: var(--brand-dark); }
  .has-mega > a::after { content: ""; display: inline-block; width: .38em; height: .38em; margin-left: .45em; border: solid currentColor; border-width: 0 1.5px 1.5px 0; transform: translateY(-.2em) rotate(45deg); opacity: .6; }
  .nav-desk .btn { align-self: center; color: #fff; }
  .mega { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-block: 1px solid var(--rule); box-shadow: 0 18px 30px rgba(11, 39, 49, .08); }
  .has-mega:hover .mega, .has-mega:focus-within .mega { display: block; }
  .mega__inner { display: grid; grid-template-columns: 240px 1fr; gap: var(--sp-7); padding-block: var(--sp-6); }
  .mega__title { font-family: var(--serif); font-size: var(--step-1); color: var(--brand-dark); margin: 0; }
  .mega__intro p:not(.mega__title) { font-size: .9rem; color: var(--muted); }
  .mega__intro a { display: inline-block; margin-top: var(--sp-4); font-weight: 700; font-size: .9rem; }
  .mega__list { display: grid !important; grid-template-columns: repeat(2, 1fr); gap: 0 var(--sp-6) !important; }
  .mega__list--plain { grid-template-columns: repeat(3, 1fr); }
  .mega__list li { border-top: 1px solid var(--rule); }
  .mega__list a { display: grid; grid-template-columns: 2.2rem 1fr; padding: .6rem 0; text-decoration: none; color: var(--ink); }
  .mega__list--plain a { grid-template-columns: 1fr; font-size: .92rem; }
  .mega__list a:hover .mega__t { color: var(--sand-deep); }
  .mega__n { font-family: var(--serif); color: var(--sand-deep); font-size: .9rem; }
  .mega__t { font-weight: 600; }
  .mega__b { grid-column: 2; font-size: .82rem; color: var(--muted); line-height: 1.45; }
}
.m-group { width: 100%; }
.m-group summary { cursor: pointer; padding: .55rem 0; font-weight: 500; list-style: none; display: flex; justify-content: space-between; }
.m-group summary::-webkit-details-marker { display: none; }
.m-group summary::after { content: "+"; color: var(--sand-deep); font-size: 1.2rem; line-height: 1; }
.m-group[open] summary::after { content: "\2212"; }
.m-group a { display: block; padding: .4rem 0 .4rem 1rem !important; font-weight: 400 !important; font-size: .95rem; border-left: 1px solid var(--rule); }
.menu nav { max-height: calc(100vh - 64px); overflow-y: auto; }

.crumbs { font-size: var(--step--1); color: var(--muted); padding-top: var(--sp-4); }
.crumbs a { color: var(--muted); }

/* Buttons */
.btn { display: inline-block; background: var(--brand); color: #fff; border: 0; border-radius: var(--radius); padding: .85rem 1.4rem; font: 600 1rem/1.2 var(--sans); text-decoration: none; cursor: pointer; transition: background .2s; }
.btn:hover { background: var(--brand-dark); color: #fff; }
.btn:disabled { opacity: .6; cursor: wait; }
.btn--sm { padding: .6rem 1rem; font-size: .92rem; }
.btn--ghost { background: transparent; color: var(--brand); box-shadow: inset 0 0 0 1.5px var(--brand); }
.btn--ghost:hover { background: var(--brand); }
.btn--light { background: var(--sand); color: var(--brand-dark); margin-top: var(--sp-4); }
.btn--light:hover { background: #f0c996; color: var(--brand-dark); }

/* Sections */
.section { padding-block: var(--section-y); }
.section--mist { background: var(--mist); border-block: 1px solid var(--rule); }
.section--dark { background: var(--brand-dark); color: var(--on-dark); }
.section--dark h2, .section--dark h3 { color: var(--on-dark); }
.eyebrow { font-size: .74rem; letter-spacing: .16em; text-transform: uppercase; font-weight: 700; color: var(--sand-deep); margin: 0 0 var(--sp-3); }
.section--dark .eyebrow { color: var(--sand); }
.lede { font-size: var(--step-1); line-height: 1.6; color: var(--muted); max-width: 60ch; }
.section-head { max-width: 64ch; margin-bottom: var(--sp-7); }
.muted { color: var(--muted); }
.small { font-size: var(--step--1); }

/* Hero */
.hero { background: var(--paper); border-bottom: 1px solid var(--rule); }
.hero__inner { display: grid; gap: var(--sp-7); padding-block: clamp(3rem, 1.8rem + 6vw, 6rem); align-items: center; }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--sp-3); margin-top: var(--sp-6); }
.hero__panel { background: #fff; border: 1px solid var(--rule); border-radius: var(--radius); padding: var(--sp-6); box-shadow: var(--shadow); }
.hero__panel h2 { font-size: var(--step-1); }
.hero__panel ul { padding-left: 1.1rem; }
.hero__panel li + li { margin-top: .4rem; }
@media (min-width: 900px) { .hero__inner { grid-template-columns: 1.25fr .75fr; gap: var(--sp-8); } }
.page-hero { padding-block: var(--sp-7) var(--sp-6); }
.page-hero .lede { margin-top: var(--sp-4); }

/* Grids and cards */
.grid { display: grid; gap: var(--sp-5); grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); list-style: none; padding: 0; margin: 0; }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.card { background: #fff; border: 1px solid var(--rule); border-radius: var(--radius); padding: var(--sp-6); display: flex; flex-direction: column; gap: var(--sp-3); }
.card p, .card ul { margin: 0; }
.card ul { padding-left: 1.1rem; }
.card .tag { font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.card a.more { margin-top: auto; font-weight: 700; text-decoration: none; }
.rule-list { display: grid; gap: var(--sp-6); grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); list-style: none; padding: 0; margin: 0; }
.rule-list li { border-top: 1px solid var(--rule); padding-top: var(--sp-4); }
.section--dark .rule-list li { border-color: var(--rule-dark); }
.rule-list h3 { font: 600 var(--step-0)/1.4 var(--sans); }
.rule-list p { font-size: .95rem; color: var(--muted); margin-top: var(--sp-2); }
.section--dark .rule-list p { color: var(--on-dark-muted); }
.steps { counter-reset: step; }
.steps li::before { counter-increment: step; content: counter(step, decimal-leading-zero); display: block; font-family: var(--serif); font-size: var(--step-3); color: var(--sand); line-height: 1; margin-bottom: var(--sp-3); }

/* Long-form content */
.prose { max-width: var(--narrow); }
.wrap.prose { max-width: var(--wrap); }
.wrap.prose > * { max-width: var(--narrow); }
.wrap.prose > .table-scroll, .wrap.prose > table { max-width: 900px; }
.prose h2 { margin-top: var(--sp-7); }
.prose h3 { margin-top: var(--sp-6); }
.prose li + li { margin-top: .35rem; }
.prose table { width: 100%; border-collapse: collapse; margin-top: var(--sp-5); font-size: .95rem; }
.prose th, .prose td { text-align: left; padding: .6rem .5rem; border-bottom: 1px solid var(--rule); vertical-align: top; }
.prose th { font-weight: 700; color: var(--brand-dark); }
.table-scroll { overflow-x: auto; }
.note { background: var(--mist); border-left: 3px solid var(--sand); padding: var(--sp-4) var(--sp-5); margin-top: var(--sp-5); border-radius: 0 var(--radius) var(--radius) 0; }
.note p:first-child { margin-top: 0; }
.verify { background: #fff4d6; color: #6b4a00; font-size: .85em; padding: 0 .3em; border-radius: 2px; font-weight: 700; }
.checklist { list-style: none; padding: 0; }
.checklist li { padding-left: 1.8rem; position: relative; }
.checklist li::before { content: ""; position: absolute; left: 0; top: .35em; width: 1rem; height: 1rem; border: 1.5px solid var(--brand); border-radius: 2px; }
.toc { display: flex; flex-wrap: wrap; gap: .5rem 1.2rem; list-style: none; padding: 0; font-size: .95rem; }

/* FAQ */
.faq { max-width: var(--narrow); border-top: 1px solid var(--rule); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary { cursor: pointer; padding: var(--sp-4) 2rem var(--sp-4) 0; font-weight: 600; position: relative; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: .25rem; top: .8rem; font-size: 1.4rem; color: var(--sand-deep); }
.faq details[open] summary::after { content: "\2212"; }
.faq__a { padding-bottom: var(--sp-4); color: var(--muted); }
.faq__a p:first-child { margin-top: 0; }

/* Lead form */
.form-section { display: grid; gap: var(--sp-7); }
@media (min-width: 900px) { .form-section { grid-template-columns: .8fr 1.2fr; align-items: start; } }
.lead-wrap { background: #fff; border: 1px solid var(--rule); border-radius: var(--radius); padding: clamp(1.25rem, 1rem + 1.5vw, 2.25rem); box-shadow: var(--shadow); }
.lead { display: grid; gap: var(--sp-4); }
.lead__grid { display: grid; gap: var(--sp-4); grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
.lead label { display: grid; gap: .35rem; font-weight: 600; font-size: .92rem; }
.lead input, .lead select, .lead textarea { font: 1rem/1.4 var(--sans); padding: .7rem .8rem; border: 1px solid #b9c6c8; border-radius: var(--radius); background: #fff; color: var(--ink); width: 100%; }
.lead input:focus, .lead select:focus, .lead textarea:focus { outline: 2px solid var(--brand); outline-offset: 0; border-color: var(--brand); }
.lead .opt { font-weight: 400; color: var(--muted); }
.lead .consent { display: flex; gap: .7rem; align-items: flex-start; font-weight: 400; font-size: .82rem; line-height: 1.55; color: var(--muted); }
.lead .consent input { width: 1.15rem; height: 1.15rem; margin-top: .15rem; flex: none; }
.lead .btn { justify-self: start; }
.lead__status { margin: 0; min-height: 1.2em; font-weight: 600; color: #8a2c1a; }
.lead__fine { margin: 0; font-size: .8rem; color: var(--muted); }
.lead__done h3 { margin-bottom: var(--sp-3); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.section--dark .lead-wrap { color: var(--ink); }

/* Footer */
.site-foot { background: var(--brand-dark); color: var(--on-dark-muted); padding-block: var(--sp-8) var(--sp-6); font-size: .95rem; }
.site-foot a { color: var(--on-dark); text-decoration: none; }
.site-foot a:hover { color: var(--sand); }
.foot__grid { display: grid; gap: var(--sp-6); grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); padding-bottom: var(--sp-6); border-bottom: 1px solid var(--rule-dark); }
.foot__grid nav { display: flex; flex-direction: column; gap: .45rem; }
.foot__grid h2 { font: 700 .74rem/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--sand); margin-bottom: .4rem; }
.logo--foot { color: var(--on-dark); }
.logo--foot b { color: var(--sand); }
.site-foot .btn--light { color: var(--brand-dark); }
.foot__legal { font-size: .8rem; line-height: 1.6; max-width: 110ch; }

/* Calculator */
.calc { display: grid; gap: var(--sp-5); grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); margin-top: var(--sp-5); }
.calc fieldset { border: 1px solid var(--rule); border-radius: var(--radius); background: #fff; padding: var(--sp-5); margin: 0; display: grid; gap: var(--sp-4); }
.calc legend { font-family: var(--serif); font-weight: 600; font-size: var(--step-1); color: var(--brand-dark); padding: 0 .4rem; }
.calc label { display: grid; gap: .3rem; font-weight: 600; font-size: .92rem; }
.calc label small { font-weight: 400; color: var(--muted); }
.calc input { font: 1rem/1.4 var(--sans); padding: .65rem .8rem; border: 1px solid #b9c6c8; border-radius: var(--radius); width: 100%; }
.calc output { display: block; background: var(--mist); border-left: 3px solid var(--sand); padding: var(--sp-3) var(--sp-4); }
.calc output p { margin: .2rem 0; }

/* Editorial index list */
.section-title { font-size: var(--step-2); margin-bottom: var(--sp-5); }
.index { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); column-gap: var(--sp-7); }
.index li { border-bottom: 1px solid var(--rule); }
.index a { display: grid; gap: .2rem; padding: var(--sp-4) 0; text-decoration: none; color: var(--ink); }
.index__t { font-family: var(--serif); font-weight: 600; font-size: var(--step-1); color: var(--brand-dark); }
.index a:hover .index__t { color: var(--sand-deep); text-decoration: underline; text-underline-offset: .2em; }
.index__b { color: var(--muted); font-size: .95rem; }

/* At a glance facts */
.glance { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 0 var(--sp-5); margin: var(--sp-6) 0 0; border-top: 1px solid var(--rule); }
.glance div { padding: var(--sp-3) 0; border-bottom: 1px solid var(--rule); }
.glance dt { font-size: .78rem; color: var(--muted); }
.glance dd { margin: .15rem 0 0; font-weight: 600; }

/* Two-column section: heading on the left, list on the right */
.split { display: grid; gap: var(--sp-5) var(--sp-8); }
.split .index { grid-template-columns: 1fr; }
@media (min-width: 900px) { .split { grid-template-columns: 280px 1fr; align-items: start; } .split > div:first-child { position: sticky; top: 90px; } }

.meta { font-size: .85rem; color: var(--muted); margin: 0 0 var(--sp-3); }

/* Hero photograph on place pages */
.hero-photo { margin: 0; }
.hero-photo img { display: block; width: 100%; height: clamp(200px, 34vw, 420px); object-fit: cover; background: var(--mist); }
.hero-photo figcaption { max-width: var(--wrap); margin-inline: auto; padding: var(--sp-3) var(--gutter) 0; display: flex; flex-wrap: wrap; gap: .3rem 1rem; justify-content: space-between; font-size: .78rem; color: var(--muted); }
.hero-photo__credit a { color: var(--muted); }
@media (min-width: 1180px) { .hero-photo img { border-radius: var(--radius); } .hero-photo { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); } .hero-photo figcaption { padding-inline: 0; } }
.hero-photo + .page-hero { padding-top: var(--sp-5); }
