/* St. Albans Lodge No. 28 — site styles, revision 2
   Layout: a centered masthead like a lodge notice (emblem over name, nav on a ruled line),
   then a quiet single reading column. Each page opens beside the pencil sketch of the hall. */
:root {
  --paper: #FBFBF9;
  --card: #FFFFFF;
  --ink: #1C232B;
  --muted: #55606B;
  --rule: #D7DDE2;
  --lodge: #1E3A5F;
  --haint: #E4EFF1;
  --haint-ink: #1E3A5F;
  --gilt: #8F6E25;
  --btn-bg: #1E3A5F;
  --btn-fg: #FFFFFF;
  --btn-hover: #2A4C78;
  --field: #FFFFFF;
  --focus: #2F6FB3;

  --display: "IM Fell English", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --display-sc: "IM Fell English SC", "IM Fell English", Georgia, serif;
  --body: "Source Sans 3", "Segoe UI", "Helvetica Neue", Arial, sans-serif;

  --step-0: 1.125rem;
  --step-2: 1.75rem;
  --step-3: 2.3rem;
  --step-4: clamp(2.2rem, 4.6vw, 3.25rem);
  --measure: 66ch;
  --gutter-l: max(16px, env(safe-area-inset-left, 0px));
  --gutter-r: max(16px, env(safe-area-inset-right, 0px));
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #11171D; --card: #172029; --ink: #E7ECF0; --muted: #A3AEB9; --rule: #2A343E;
    --lodge: #A9C3E3; --haint: #18252E; --haint-ink: #CFE0EE; --gilt: #D1AE5E;
    --btn-bg: #A9C3E3; --btn-fg: #10161C; --btn-hover: #C3D6EE; --field: #0F151B; --focus: #8DB8F0;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #11171D; --card: #172029; --ink: #E7ECF0; --muted: #A3AEB9; --rule: #2A343E;
  --lodge: #A9C3E3; --haint: #18252E; --haint-ink: #CFE0EE; --gilt: #D1AE5E;
  --btn-bg: #A9C3E3; --btn-fg: #10161C; --btn-hover: #C3D6EE; --field: #0F151B; --focus: #8DB8F0;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); font-size: var(--step-0); line-height: 1.6; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--lodge); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; color: var(--lodge); line-height: 1.15; text-wrap: balance; margin: 0; }
h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-2); }
p { margin: 0; }
.skip { position: absolute; left: -999px; top: 0; background: var(--card); padding: 8px 12px; z-index: 50; }
.skip:focus { left: 16px; top: 16px; }

.wrap { max-width: 1120px; margin: 0 auto; padding-left: var(--gutter-l); padding-right: var(--gutter-r); }
.read { max-width: var(--measure); }
.stack { display: grid; gap: 1.1rem; align-content: start; }
.stack-lg { display: grid; gap: 2.6rem; align-content: start; }
.label { font-family: var(--display-sc); letter-spacing: 0.08em; color: var(--gilt); font-size: 1.08rem; }
.muted { color: var(--muted); }

/* ---------- emblem ---------- */
.emblem { display: block; color: var(--lodge); }
.emblem .sq, .emblem .cp { fill: currentColor; stroke: var(--paper); stroke-width: 2.2; paint-order: stroke; stroke-linejoin: round; }
.emblem .g { fill: currentColor; font-family: Georgia, "Times New Roman", serif; font-weight: 700; }
.band .emblem .sq, .band .emblem .cp { stroke: var(--haint); }

/* ---------- masthead ---------- */
.masthead { border-bottom: 1px solid var(--rule); }
.masthead .wrap { display: grid; justify-items: center; gap: 10px; padding-block: 22px 0; text-align: center; }
.brand { display: grid; justify-items: center; gap: 6px; text-decoration: none; color: inherit; }
.brand .emblem { width: 58px; height: 58px; }
.brand-name { font-family: var(--display); font-size: clamp(1.7rem, 3.4vw, 2.25rem); color: var(--lodge); line-height: 1.1; }
.brand-sub { font-family: var(--display-sc); letter-spacing: 0.08em; color: var(--muted); font-size: 1rem; }
.nav-toggle { display: none; font: inherit; font-size: 1rem; background: none; border: 1px solid var(--rule); color: var(--ink); border-radius: 6px; padding: 8px 16px; cursor: pointer; margin-bottom: 14px; }
.site-nav { width: 100%; border-top: 1px solid var(--rule); margin-top: 8px; }
.site-nav ul { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 0 30px; margin: 0; padding: 0; }
.site-nav a { display: block; color: var(--ink); text-decoration: none; font-size: 1.02rem; padding: 12px 2px 10px; border-bottom: 2px solid transparent; }
.site-nav a:hover { border-bottom-color: var(--rule); }
.site-nav a[aria-current="page"] { color: var(--lodge); border-bottom-color: var(--gilt); }
@media (max-width: 760px) {
  .nav-toggle { display: inline-block; }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav li a { padding: 12px 2px; border-bottom: 1px solid var(--rule); }
  .js .site-nav[data-open="false"] { display: none; }
}

/* ---------- buttons ---------- */
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn { display: inline-block; font: inherit; font-size: 1.02rem; font-weight: 600; text-decoration: none; border-radius: 6px; padding: 12px 20px; border: 2px solid var(--btn-bg); cursor: pointer; line-height: 1.2; }
.btn-primary { background: var(--btn-bg); color: var(--btn-fg); }
.btn-primary:hover { background: var(--btn-hover); border-color: var(--btn-hover); }
.btn-quiet { background: transparent; color: var(--lodge); }
.btn-quiet:hover { background: var(--haint); }

/* ---------- gathering banner ---------- */
.banner { background: var(--haint); color: var(--haint-ink); border-bottom: 1px solid var(--rule); }
.banner .wrap { display: flex; flex-wrap: wrap; gap: 4px 18px; align-items: baseline; justify-content: center; padding-block: 11px; text-align: center; }
.banner strong { font-family: var(--display); font-weight: 400; font-size: 1.15rem; }
.banner a { color: var(--haint-ink); font-weight: 600; }

/* ---------- page openers (every page) ---------- */
.opener .wrap { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: 44px; align-items: center; padding-block: 44px 40px; }
.opener-text { display: grid; gap: 16px; min-width: 0; }
.opener .lede { font-size: 1.22rem; color: var(--muted); max-width: 46ch; }
.opener-art { justify-self: end; width: 100%; max-width: 340px; }
.home .opener .wrap { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.home .opener-art { max-width: 520px; }
.plate { margin: 0; background: #FFFFFF; border: 1px solid var(--rule); border-radius: 4px; padding: 10px; }
.plate img { width: 100%; }
.plate figcaption { font-size: 0.9rem; color: #55606B; padding: 8px 4px 2px; text-align: center; }
.chartered { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; font-family: var(--display-sc); letter-spacing: 0.06em; font-size: 1.08rem; }
@media (max-width: 820px) {
  .opener .wrap, .home .opener .wrap { grid-template-columns: 1fr; gap: 26px; padding-block: 28px; }
  .opener-art { justify-self: start; max-width: 300px; }
  .home .opener-art { max-width: 460px; }
}

/* ---------- sections ---------- */
.section .wrap { padding-block: 52px; }
.section + .section .wrap { border-top: 1px solid var(--rule); }
.band { background: var(--haint); color: var(--haint-ink); }
.band h2, .band h3 { color: var(--haint-ink); }
.band + .section .wrap, .section + .band .wrap { border-top: 0; }
.two-col { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; }
@media (max-width: 820px) { .two-col { grid-template-columns: 1fr; gap: 32px; } }

ul.plain { margin: 0; padding-left: 1.2em; display: grid; gap: 6px; }
ul.plain li::marker { color: var(--gilt); }
ol.steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; gap: 18px; }
ol.steps li { counter-increment: step; display: grid; grid-template-columns: 2.6rem minmax(0, 1fr); gap: 14px; }
ol.steps li::before { content: counter(step); font-family: var(--display); font-size: 1.45rem; color: var(--btn-fg); background: var(--btn-bg); width: 2.4rem; height: 2.4rem; border-radius: 50%; display: grid; place-items: center; line-height: 1; }
ol.steps strong { color: var(--lodge); }
blockquote { margin: 0; padding: 4px 0 4px 22px; border-left: 2px solid var(--gilt); font-family: var(--display); font-size: 1.3rem; line-height: 1.45; }
blockquote cite { display: block; margin-top: 8px; font-family: var(--body); font-style: normal; font-size: 0.95rem; color: var(--muted); }

/* ---------- history ---------- */
.era { display: grid; grid-template-columns: 9rem minmax(0, 1fr); gap: 28px; padding-block: 30px; border-top: 1px solid var(--rule); }
.era:first-child { border-top: 0; padding-top: 0; }
.era-date { font-family: var(--display-sc); color: var(--gilt); font-size: 1.35rem; letter-spacing: 0.04em; line-height: 1.2; padding-top: 6px; }
.era-body { display: grid; gap: 14px; max-width: var(--measure); min-width: 0; }
.era-body h2 { font-size: var(--step-2); }
@media (max-width: 680px) { .era { grid-template-columns: 1fr; gap: 8px; } }

/* ---------- gathering ---------- */
.day { display: grid; grid-template-columns: 10rem minmax(0, 1fr); gap: 24px; padding-block: 20px; border-top: 1px solid var(--rule); }
.day:first-child { border-top: 0; }
.day-name { font-family: var(--display-sc); color: var(--lodge); font-size: 1.2rem; letter-spacing: 0.04em; }
.day-name small { display: block; font-family: var(--body); letter-spacing: 0; font-size: 0.95rem; color: var(--muted); }
.day h3 { font-size: 1.4rem; margin-bottom: 6px; }
@media (max-width: 680px) { .day { grid-template-columns: 1fr; gap: 4px; } }

/* ---------- forms ---------- */
.form { display: grid; gap: 18px; max-width: 44rem; }
.form fieldset { border: 1px solid var(--rule); border-radius: 6px; padding: 16px 18px 18px; margin: 0; display: grid; gap: 16px; background: var(--card); color: var(--ink); }
.form legend { font-family: var(--display); font-size: 1.3rem; color: var(--lodge); padding: 0 6px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field label, .field .q { font-weight: 600; font-size: 1rem; }
.field .hint { font-size: 0.92rem; color: var(--muted); font-weight: 400; }
.field input, .field select, .field textarea { font: inherit; font-size: 1.05rem; color: var(--ink); background: var(--field); border: 1px solid var(--rule); border-radius: 6px; padding: 11px 12px; width: 100%; }
.field textarea { min-height: 7rem; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 3px solid var(--focus); outline-offset: 1px; border-color: transparent; }
.checks { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.check { display: flex; gap: 8px; align-items: flex-start; font-weight: 400; }
.check input { width: 1.15rem; height: 1.15rem; margin-top: 0.3rem; accent-color: var(--btn-bg); flex: none; }
.row-2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
@media (max-width: 600px) { .row-2 { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }
.form-note { font-size: 0.98rem; color: var(--muted); }
.form-status { border: 1px solid var(--rule); background: var(--haint); color: var(--haint-ink); border-radius: 6px; padding: 12px 14px; }

/* ---------- facebook ---------- */
.social .wrap { display: flex; flex-wrap: wrap; gap: 16px 32px; align-items: center; justify-content: space-between; padding-block: 34px; }
.social p { max-width: 46ch; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--rule); color: var(--muted); font-size: 0.98rem; }
.site-footer .wrap { display: grid; justify-items: center; text-align: center; gap: 14px; padding-block: 34px 44px; }
.site-footer .emblem { width: 40px; height: 40px; }
.foot-name { font-family: var(--display); color: var(--lodge); font-size: 1.3rem; }
.foot-links { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 20px; }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--lodge); }

@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }
/* reading columns that are also the page wrapper stay aligned with the other sections */
.wrap.read { max-width: calc(var(--measure) + 32px); margin-left: max(0px, calc((100% - 1120px) / 2)); margin-right: 0; }
