:root {
  color-scheme: light;
  /* Same palette and type as wgcps.org */
  --brand: #2d5c3f;
  --brand-dark: #234a32;
  --brand-soft: #e9f0ea;
  --bg: #f7f8f4;
  --card: #ffffff;
  --border: #e2e7dd;
  --ink: #1f2a24;
  --muted: #5c6b60;
  --danger: #b0413e;
  --danger-soft: #fbe9e8;
  --warn: #8a5a00;
  --warn-soft: #fdf3e2;
  --info-soft: #e8f0f8;
  --serif: Georgia, "Times New Roman", "Palatino Linotype", serif;
  --sans: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --radius: 10px;
  /* legacy names used below */
  --green: var(--brand); --green-dark: var(--brand-dark); --green-light: var(--brand-soft);
  --line: var(--border); --red: var(--danger); --red-bg: var(--danger-soft);
  --amber: var(--warn); --amber-bg: var(--warn-soft); --blue-bg: var(--info-soft);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { margin: 0; padding: 0; }
body {
  min-height: 100vh; display: flex; flex-direction: column;
  background: var(--bg); color: var(--ink); font: 16px/1.55 var(--sans);
}
body > main { flex: 1 0 auto; width: 100%; }
img { max-width: 100%; height: auto; }
a { color: var(--brand); }
a:hover { color: var(--brand-dark); }

/* Header & nav — same pattern as wgcps.org */
.site-header {
  position: sticky; top: 0; z-index: 200;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: .7rem 1.5rem;
  background: color-mix(in srgb, var(--card) 88%, transparent);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--ink); }
.brand-logo {
  width: 44px; height: 44px; flex: none; background-color: var(--brand);
  -webkit-mask: url(/img/wgc-logo.png) center / contain no-repeat;
  mask: url(/img/wgc-logo.png) center / contain no-repeat;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.12; }
.brand-name { white-space: nowrap; font-family: var(--serif); font-weight: 700; font-size: 1.05rem; color: var(--brand); letter-spacing: .01em; }
.brand-sub { font-size: .7rem; text-transform: uppercase; letter-spacing: .13em; color: var(--muted); }

.nav-shell { display: contents; }
.site-nav { display: flex; align-items: center; gap: .3rem; flex-wrap: wrap; justify-content: flex-end; }
.site-nav a {
  font: 600 .78rem var(--sans); letter-spacing: .1em; text-transform: uppercase;
  text-decoration: none; color: var(--muted); padding: .4rem .75rem; border-radius: 6px;
  transition: color .2s, background .2s; display: block; white-space: nowrap;
}
.site-nav a.active, .site-nav a:hover {
  color: var(--brand); background: color-mix(in srgb, var(--brand) 10%, transparent);
}
.nav-group { position: relative; }
.nav-sub {
  display: none; position: absolute; top: 100%; left: 0; z-index: 10; min-width: 230px;
  padding: .35rem; background: var(--card); border: 1px solid var(--border); border-radius: 10px;
  box-shadow: 0 10px 28px rgba(0,0,0,.14);
}
.nav-sub a { letter-spacing: .06em; padding: .5rem .7rem; }
.nav-group:hover > .nav-sub, .nav-group:focus-within > .nav-sub { display: block; }

.nav-toggle {
  display: none; flex: none; width: 44px; height: 44px; align-items: center; justify-content: center;
  color: var(--ink); background: none; border: 1px solid var(--border); border-radius: 10px;
  cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.nav-toggle:hover { border-color: var(--brand); color: var(--brand); }
.nav-bars { position: relative; }
.nav-bars, .nav-bars::before, .nav-bars::after {
  display: block; width: 20px; height: 2px; border-radius: 2px; background: currentColor;
  transition: transform .2s ease, background-color .2s ease;
}
.nav-bars::before, .nav-bars::after { content: ""; position: absolute; left: 0; }
.nav-bars::before { transform: translateY(-6px); }
.nav-bars::after { transform: translateY(6px); }
.nav-toggle.open .nav-bars { background: transparent; }
.nav-toggle.open .nav-bars::before { transform: rotate(45deg); }
.nav-toggle.open .nav-bars::after { transform: rotate(-45deg); }

@media (max-width: 1180px) {
  .site-header { flex-wrap: nowrap; }
  .brand, .brand-text { min-width: 0; }
  .brand-name, .brand-sub { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .nav-toggle { display: inline-flex; }
  .nav-shell .site-nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: .1rem; padding: .5rem .9rem .8rem;
    background: var(--card); border-bottom: 1px solid var(--border);
    box-shadow: 0 14px 26px color-mix(in srgb, var(--ink) 12%, transparent);
    max-height: calc(100dvh - 100%); overflow-y: auto;
  }
  .nav-shell .site-nav.open { display: flex; }
  .nav-shell .site-nav a { padding: .7rem; border-radius: 8px; }
  .nav-sub {
    display: block; position: static; min-width: 0; padding: 0 0 .2rem 1rem;
    border: 0; box-shadow: none; background: none;
  }
  .nav-sub a { text-transform: none; letter-spacing: 0; font-size: .9rem; font-weight: 500; }
}
@media (max-width: 700px) {
  .site-header { padding: .6rem 1rem; gap: .6rem; }
  .nav-shell .site-nav { padding-left: .7rem; padding-right: .7rem; }
}

/* Content */
main { max-width: 980px; margin: 0 auto; padding: 16px 16px 40px; }
.crumbs { font-size: 14px; color: var(--muted); margin-bottom: 8px; }
h1 { font-family: var(--serif); font-weight: 700; font-size: 1.75rem; line-height: 1.25; margin: .4rem 0 .3rem; color: var(--ink); }
h2 { font-family: var(--serif); font-size: 1.25rem; margin: 2rem 0 .6rem; padding-top: .9rem; border-top: 1px solid var(--border); color: var(--brand); }
h3 { font-size: 1.1rem; margin: 1.3em 0 .4em; }
.lede { font-size: 1.1rem; color: var(--muted); margin-top: 0; }

table { width: 100%; border-collapse: collapse; margin: .8em 0 1.2em; font-size: 15px; }
th, td { text-align: left; vertical-align: top; padding: 7px 9px; border-bottom: 1px solid var(--line); }
th { background: var(--green-light); }
.table-wrap { overflow-x: auto; }

dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 4px 16px; margin: .8em 0; }
dl.facts dt { font-weight: 600; color: var(--muted); }
dl.facts dd { margin: 0; }

.callout { border-left: 5px solid var(--green); background: var(--green-light); padding: 10px 14px; border-radius: 0 var(--radius) var(--radius) 0; margin: 1em 0; }
.callout.warn { border-color: var(--amber); background: var(--amber-bg); }
.callout.danger { border-color: var(--red); background: var(--red-bg); }
.callout.info { border-color: #3b6ea5; background: var(--blue-bg); }
.callout > :first-child { margin-top: 0; }
.callout > :last-child { margin-bottom: 0; }

.tag { display: inline-block; font-size: 12px; font-weight: 700; padding: 1px 8px; border-radius: 999px; vertical-align: middle; }
.tag.open { background: var(--red-bg); color: var(--red); }
.tag.watch { background: var(--amber-bg); color: var(--amber); }
.tag.ok { background: var(--green-light); color: var(--green-dark); }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(230px, 100%), 1fr)); gap: 12px; margin: 1em 0; }
.card {
  display: block; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 12px 14px; text-decoration: none; color: var(--ink);
}
.card:hover { border-color: var(--green); box-shadow: 0 2px 10px rgba(61,107,42,.12); }
.card h3 { margin: 0 0 4px; color: var(--green-dark); }
.card p { margin: 0; color: var(--muted); font-size: 14px; }

.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(160px, 100%), 1fr)); gap: 12px; margin: 1em 0; }
figure { margin: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
figure img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
figure a { display: block; }
figcaption { font-size: 13px; color: var(--muted); padding: 6px 10px; }

ul.checklist { list-style: none; padding-left: 0; }
ul.checklist li { padding-left: 1.6em; position: relative; margin: .3em 0; }
ul.checklist li::before { content: "☐"; position: absolute; left: 0; color: var(--green); }

[data-blurb] { display: none; }

/* Buttons (sign-in, committee) — same feel as wgcps.org */
.btn-primary, .btn-ghost {
  font: 600 .95rem var(--sans); border-radius: 8px; padding: .6rem 1.1rem; cursor: pointer;
  border: 1px solid var(--brand); transition: background .15s, color .15s;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); }
.btn-ghost { background: none; color: var(--brand); padding: .4rem .9rem; font-size: .85rem; }
.btn-ghost:hover { background: var(--brand-soft); }
.signin-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.4rem; max-width: 460px; margin: 1.2rem 0; }
.signin-card .small { margin: .8rem 0 0; }
.small { font-size: .85rem; color: var(--muted); }
.site-nav a.nav-signout { border: 1px solid color-mix(in srgb, var(--brand) 35%, transparent); color: var(--brand); }

/* Committee roster */
.roster-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .6rem; margin: 1rem 0 .4rem; }
.roster-actions { display: flex; gap: .5rem; }
.roster-msg { flex-basis: 100%; }
.roster td.contact div { white-space: nowrap; }
@media (max-width: 640px) { .roster td.contact div { white-space: normal; } }
.roster tr.row-edit { cursor: pointer; }
.roster tr.row-edit:hover td, .roster tr.row-edit:focus td { background: var(--brand-soft); }
.roster tr.row-edit:focus { outline: none; }

pre.stack { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 14px; font-size: 14px; line-height: 1.5; overflow-x: auto; }
h5 { font-size: 1rem; margin: 1.1em 0 .3em; color: var(--brand-dark); }

/* Photo lightbox */
.lightbox { position: fixed; inset: 0; z-index: 400; background: rgba(10,14,10,.92); display: flex; align-items: center; justify-content: center; padding: 56px 56px 72px; }
.lb-fig { margin: 0; background: none; border: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; }
.lb-fig img { max-width: 100%; max-height: calc(100dvh - 150px); width: auto; height: auto; aspect-ratio: auto; object-fit: contain; border-radius: 6px; background: #fff; }
.lb-fig figcaption { color: #e8ece4; text-align: center; padding: 10px 4px 0; font-size: .95rem; }
.lb-count { opacity: .7; margin-left: .4rem; }
.lb-close { position: absolute; top: 12px; right: 14px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255,255,255,.15); color: #fff; font-size: 2rem; line-height: 44px; cursor: pointer; }
.lb-close:hover, .lb-nav:hover { background: rgba(255,255,255,.3); }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 64px; border: 0; border-radius: 8px; background: rgba(255,255,255,.12); color: #fff; font-size: 2.2rem; cursor: pointer; }
.lb-prev { left: 8px; } .lb-next { right: 8px; }
.lb-full { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); color: #cfe0c4; font-size: .85rem; }
@media (max-width: 640px) { .lightbox { padding: 56px 8px 64px; } .lb-nav { top: auto; bottom: 8px; transform: none; height: 44px; } }

/* Modal (edit member) — wgcps.org style */
.modal-backdrop { position: fixed; inset: 0; z-index: 300; background: rgba(20,30,20,.45); display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal { background: var(--card); border-radius: 14px; width: 100%; max-width: 30rem; max-height: calc(100dvh - 32px); overflow: auto; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--border); font-family: var(--serif); font-size: 1.1rem; }
.modal-x { background: none; border: none; font-size: 1.6rem; line-height: 1; color: var(--muted); cursor: pointer; }
.modal-body { padding: 14px 18px; display: flex; flex-direction: column; gap: 12px; }
.modal-body label { display: flex; flex-direction: column; gap: 4px; font-weight: 600; font-size: .9rem; }
.modal-body input { font: 16px var(--sans); padding: .55rem .7rem; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.modal-body input:focus { outline: 2px solid var(--brand); outline-offset: 1px; }
.modal-body .callout { margin: 0; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--border); }
.doc-pages figure img { aspect-ratio: 8.5 / 11; object-fit: contain; background: #fff; }

/* Toggle switch */
.switch { display: inline-flex; align-items: center; gap: .6rem; cursor: pointer; font-size: 15px; margin: .2rem 0 .4rem; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch-track { position: relative; width: 42px; height: 24px; border-radius: 999px; background: var(--border); transition: background .2s; flex: none; }
.switch-track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
.switch input:checked + .switch-track { background: var(--brand); }
.switch input:checked + .switch-track::after { transform: translateX(18px); }
.switch input:focus-visible + .switch-track { outline: 2px solid var(--brand); outline-offset: 2px; }
tr[hidden] { display: none; }

.site-footer { border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; text-align: center; padding: 16px; }
.site-footer p { margin: 4px 0; }

@media print {
  .site-header, .site-footer, .crumbs { display: none; }
  main { max-width: none; padding: 0; }
  .gallery { display: none; }
  a { color: inherit; text-decoration: none; }
}
