/* Blessed Trinity CSPC — stylesheet
   Colours are defined once here. Change --brand / --accent to reskin the site. */

:root {
  --brand: #16386b;
  --brand-dark: #0f2749;
  --accent: #c8952b;
  --accent-soft: #f6ecd6;
  --bg: #fbfaf8;
  --surface: #ffffff;
  --text: #1c2230;
  --muted: #5d6472;
  --line: #e3e0da;
  --radius: 10px;
  --shadow: 0 1px 2px rgba(20,30,50,.06), 0 6px 20px rgba(20,30,50,.05);
  --maxw: 940px;
}

/* extra tokens so every surface can flip cleanly in dark mode */
:root {
  --callout-bg: var(--accent-soft);
  --callout-border: #e8d9b4;
  --callout-text: #6d5311;
  --callout-head: #4a3708;
  --callout-kicker: #8a6410;
  --th-bg: #f2f0ec;
  --draft-bg: #fdecec;
  --draft-line: #f3c9c9;
  --draft-text: #a12525;
  --footer-bg: var(--brand-dark);
  --btn-text: #ffffff;
  --header-bg: #16386b;
  --header-text: #ffffff;
  --chip-bg: #16386b;
  --chip-text: #ffffff;
}

:root[data-theme="dark"] {
  --brand: #8fb4e8;
  --brand-dark: #b9d2f2;
  --accent: #e0b44f;
  --accent-soft: #33291180;
  --bg: #14171d;
  --surface: #1c2129;
  --text: #e6e8ec;
  --muted: #a3abb9;
  --line: #2e343e;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 6px 20px rgba(0,0,0,.3);
  --callout-bg: #2a2314;
  --callout-border: #4a3d1e;
  --callout-text: #e2cd9a;
  --callout-head: #f0dcae;
  --callout-kicker: #d4b264;
  --th-bg: #252b34;
  --draft-bg: #3a1f1f;
  --draft-line: #5c2e2e;
  --draft-text: #f0a8a8;
  --footer-bg: #0e1116;
  --btn-text: #10151c;
  --header-bg: #101822;
  --header-text: #e6e8ec;
  --chip-bg: #2b3a4f;
  --chip-text: #e6e8ec;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 "Segoe UI", Roboto, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--brand); }
a:hover { color: var(--brand-dark); }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* ---------- header ---------- */

.site-header {
  background: var(--header-bg);
  color: var(--header-text);
  padding: 18px 0;
}
.site-header a { color: var(--header-text); text-decoration: none; }
.site-header .brand { display: block; }
.site-header .school {
  font-size: 1.22rem;
  font-weight: 700;
  letter-spacing: .2px;
  line-height: 1.25;
}
.site-header .council {
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: 1.4px;
  opacity: .82;
  margin-top: 3px;
}

nav.main {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
nav.main a {
  padding: 7px 13px;
  border-radius: 999px;
  font-size: .93rem;
  font-weight: 600;
  background: rgba(255,255,255,.11);
}
nav.main a:hover { background: rgba(255,255,255,.2); }
nav.main a[aria-current="page"] { background: var(--header-text); color: var(--header-bg); }

/* ---------- hero ---------- */

.hero {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  padding: 40px 0 34px;
}
.hero h1 {
  margin: 0 0 10px;
  font-size: 1.85rem;
  line-height: 1.22;
  color: var(--brand);
  letter-spacing: -.3px;
}
.hero p.lede {
  margin: 0;
  font-size: 1.08rem;
  color: var(--muted);
  max-width: 60ch;
}

/* ---------- next meeting callout ---------- */

.callout {
  background: var(--callout-bg);
  border: 1px solid var(--callout-border);
  border-left: 5px solid var(--accent);
  border-radius: var(--radius);
  padding: 20px 22px;
  margin: 26px 0 0;
}
.callout .kicker {
  font-size: .76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--callout-kicker);
  margin-bottom: 6px;
}
.callout h2 { margin: 0 0 8px; font-size: 1.24rem; color: var(--callout-head); }
.callout dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 3px 12px; font-size: .97rem; }
.callout dt { font-weight: 700; color: var(--callout-text); }
.callout dd { margin: 0; }
.callout .note { margin: 12px 0 0; font-size: .95rem; color: var(--callout-text); }

/* ---------- sections ---------- */

section { padding: 38px 0; }
section + section { border-top: 1px solid var(--line); }

h2.section-title {
  margin: 0 0 4px;
  font-size: 1.4rem;
  color: var(--brand);
  letter-spacing: -.2px;
}
p.section-sub { margin: 0 0 22px; color: var(--muted); }

/* ---------- cards ---------- */

.cards { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .cards { grid-template-columns: 1fr 1fr; } }
@media (min-width: 700px) { .cards.three { grid-template-columns: repeat(3, 1fr); } }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.card .card-body { padding: 17px 19px; }
.card h3 { margin: 0 0 7px; font-size: 1.08rem; line-height: 1.3; }
.card h3 a { text-decoration: none; }
.card h3 a:hover { text-decoration: underline; }
.card p { margin: 0; color: var(--muted); font-size: .95rem; }
.card .meta {
  font-size: .82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .7px;
  color: var(--accent);
  margin-bottom: 7px;
}
.card img.thumb { border-bottom: 1px solid var(--line); aspect-ratio: 16/9; object-fit: cover; width: 100%; }

/* involvement cards use a plainer look */
.involve .card { box-shadow: none; }

/* ---------- event list ---------- */

ul.events { list-style: none; margin: 0; padding: 0; }
ul.events li {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
ul.events li:first-child { padding-top: 0; }
.datechip {
  flex: 0 0 62px;
  text-align: center;
  background: var(--chip-bg);
  color: var(--chip-text);
  border-radius: 8px;
  padding: 8px 4px;
  height: fit-content;
}
.datechip .m { display: block; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; opacity: .85; }
.datechip .d { display: block; font-size: 1.45rem; font-weight: 700; line-height: 1.1; }
.ev-body h3 { margin: 0 0 4px; font-size: 1.06rem; }
.ev-body h3 a { text-decoration: none; }
.ev-body .when { font-size: .9rem; color: var(--muted); margin: 0 0 5px; }
.ev-body p { margin: 0; font-size: .95rem; color: var(--muted); }

/* ---------- draft badge ---------- */

.draft {
  display: inline-block;
  background: var(--draft-bg);
  color: var(--draft-text);
  border: 1px solid var(--draft-line);
  border-radius: 4px;
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .8px;
  padding: 2px 7px;
  margin-left: 7px;
  vertical-align: middle;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-block;
  background: var(--brand);
  color: var(--btn-text) !important;
  text-decoration: none;
  font-weight: 600;
  padding: 11px 20px;
  border-radius: 999px;
  border: 0;
}
.btn:hover { background: var(--brand-dark); }
.btn.ghost {
  background: transparent;
  color: var(--brand) !important;
  border: 1.5px solid var(--brand);
}
.btn.ghost:hover { background: rgba(22,56,107,.06); }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.btn.tiny { padding: 5px 13px; font-size: .84rem; font-weight: 600; border-width: 1px; }
.ev-cal { margin: 9px 0 0 !important; }
.callout .btn-row { margin-top: 14px; }

/* ---------- article ---------- */

article.page { padding: 34px 0 10px; }
article.page h1 { font-size: 1.75rem; color: var(--brand); margin: 0 0 6px; line-height: 1.24; }
article.page .byline { color: var(--muted); font-size: .93rem; margin: 0 0 24px; }
article.page h2 { font-size: 1.25rem; color: var(--brand); margin: 32px 0 10px; }
article.page h3 { font-size: 1.06rem; margin: 24px 0 8px; }
article.page p, article.page li { font-size: 1.02rem; }
article.page ul, article.page ol { padding-left: 22px; }
article.page li { margin-bottom: 7px; }
article.page blockquote {
  margin: 20px 0;
  padding: 12px 18px;
  background: var(--callout-bg);
  border-left: 4px solid var(--accent);
  border-radius: 0 8px 8px 0;
  color: var(--callout-text);
}
article.page blockquote p { margin: 0; }
article.page table {
  width: 100%;
  border-collapse: collapse;
  margin: 18px 0;
  font-size: .97rem;
}
article.page th, article.page td {
  text-align: left;
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
}
article.page th { background: var(--th-bg); font-weight: 700; }
.table-scroll { overflow-x: auto; }
article.page img { border-radius: var(--radius); margin: 20px 0; }
article.page hr { border: 0; border-top: 1px solid var(--line); margin: 28px 0; }

.backlink { display: inline-block; margin: 26px 0 0; font-size: .95rem; text-decoration: none; }
.backlink:hover { text-decoration: underline; }

/* ---------- footer ---------- */

.site-footer {
  background: var(--footer-bg);
  color: rgba(255,255,255,.8);
  padding: 30px 0;
  margin-top: 46px;
  font-size: .92rem;
}
.site-footer a { color: #fff; }
.site-footer p { margin: 0 0 7px; }
.site-footer .small { font-size: .84rem; opacity: .65; margin-top: 14px; }

/* ---------- quick links hub ---------- */

.lgroup + .lgroup { margin-top: 34px; }

ul.links { list-style: none; margin: 0; padding: 0; }

.ln {
  border-bottom: 1px solid var(--line);
  padding: 13px 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.ln:first-child { padding-top: 4px; }

.ln-title {
  font-weight: 600;
  font-size: 1.04rem;
  text-decoration: none;
}
a.ln-title::after {
  content: " \2192";
  color: var(--accent);
  font-weight: 700;
}
a.ln-title:hover { text-decoration: underline; }

.ln-note { color: var(--muted); font-size: .92rem; }

.ln.missing .ln-title { color: var(--muted); font-weight: 600; }

/* ---------- footer disclaimer ---------- */

.site-footer .disclaimer {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,.16);
  font-size: .86rem;
  line-height: 1.6;
  opacity: .8;
  max-width: 68ch;
}


/* ---------- header layout + theme toggle ---------- */

.head-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.theme-toggle {
  flex: 0 0 auto;
  background: rgba(255,255,255,.13);
  color: var(--header-text);
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 999px;
  font: inherit;
  font-size: .84rem;
  font-weight: 600;
  padding: 6px 13px;
  cursor: pointer;
  line-height: 1.4;
  white-space: nowrap;
}
.theme-toggle:hover { background: rgba(255,255,255,.24); }
.theme-toggle:focus-visible { outline: 2px solid var(--header-text); outline-offset: 2px; }
.theme-toggle .icon { margin-right: 5px; }

@media (max-width: 420px) {
  .theme-toggle .label { display: none; }
  .theme-toggle .icon { margin-right: 0; }
}

/* ---------- layout blocks (the ':::' directives in build.py) ---------- */

svg.ic { display: block; color: var(--accent); flex: 0 0 auto; }
svg.ic.big { width: 30px; height: 30px; }

/* stat grid — the short factual answers, as numbers rather than table rows */
.statgrid {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr 1fr;
  margin: 22px 0 6px;
}
/* fixed columns, not auto-fit: six facts must land 3+3, never 5+1 */
@media (min-width: 700px) { .statgrid { grid-template-columns: repeat(3, 1fr); } }
.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 16px 14px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.stat svg.ic { margin-bottom: 5px; }
.stat .v {
  font-size: 1.32rem;
  font-weight: 700;
  color: var(--brand);
  line-height: 1.2;
  letter-spacing: -.2px;
}
.stat .l { font-size: .92rem; color: var(--muted); line-height: 1.45; }

/* icon cards */
.icards { display: grid; gap: 16px; grid-template-columns: 1fr; margin: 22px 0 6px; }
@media (min-width: 700px) {
  .icards.two { grid-template-columns: 1fr 1fr; }
  .icards.three { grid-template-columns: repeat(3, 1fr); }
}
.icard {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 21px;
  box-shadow: var(--shadow);
}
.icard svg.ic { margin-bottom: 11px; }
article.page .icard h3 { margin: 0 0 8px; font-size: 1.1rem; color: var(--brand); }
article.page .icard p { margin: 0 0 10px; font-size: .97rem; }
article.page .icard p:last-child { margin-bottom: 0; }

/* FAQ — native <details>, so it collapses with no JavaScript at all */
.faq { margin: 22px 0 6px; border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 15px 40px 15px 0;
  font-weight: 600;
  font-size: 1.02rem;
  color: var(--brand);
  position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  position: absolute;
  right: 8px;
  top: 50%;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: translateY(-70%) rotate(45deg);
  transition: transform .18s ease;
}
.faq details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq summary:hover { color: var(--brand-dark); }
.faq summary:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
article.page .faq .fa { padding: 0 0 16px; }
article.page .faq .fa p { margin: 0 0 10px; color: var(--muted); }
article.page .faq .fa p:last-child { margin-bottom: 0; }

/* numbered steps */
ol.steps { list-style: none; margin: 22px 0 6px; padding: 0; }
ol.steps li.step {
  display: flex;
  gap: 15px;
  padding: 0 0 20px;
  position: relative;
  margin: 0;
}
ol.steps li.step:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 34px;
  bottom: 4px;
  width: 2px;
  background: var(--line);
}
ol.steps .num {
  flex: 0 0 32px;
  height: 32px;
  border-radius: 999px;
  background: var(--brand);
  color: var(--btn-text);
  font-weight: 700;
  font-size: .95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1;
}
article.page ol.steps h3 { margin: 4px 0 5px; font-size: 1.05rem; color: var(--brand); }
article.page ol.steps p { margin: 0; color: var(--muted); font-size: .98rem; }

/* closing call to action */
.cta {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background: var(--callout-bg);
  border: 1px solid var(--callout-border);
  border-left: 5px solid var(--accent);
  border-radius: var(--radius);
  padding: 20px 22px;
  margin: 30px 0 6px;
}
.cta svg.ic { color: var(--accent); margin-top: 2px; }
article.page .cta h3 { margin: 0 0 6px; font-size: 1.12rem; color: var(--callout-head); }
article.page .cta p { margin: 0; color: var(--callout-text); font-size: 1rem; }
.cta a { color: var(--callout-head); font-weight: 600; }
