/* The Bellarmine Guide: crisp and calm. Navy and Marian blue; gold only for honors;
   teal only for the Catholic Life Score and the Campus Ministry Honor Roll.
   Light is the default. Dark follows the device setting unless the reader picks one
   (the choice is stored in localStorage and applied by a tiny inline script in <head>). */
@font-face { font-family: "Manrope"; src: url("/fonts/manrope-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("/fonts/manrope-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("/fonts/manrope-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("/fonts/manrope-latin-800-normal.woff2") format("woff2"); font-weight: 800; font-display: swap; }

:root {
  color-scheme: light;
  --bg: #ffffff;
  --surface: #f6f8fb;
  --surface-2: #eef3f9;
  --ink: #0f1f36;
  --text: #22324a;
  --muted: #5b6b82;
  --subtle: #54647b;
  --line: #e2e8f0;
  --line-strong: #cbd5e1;
  --navy: #14325c;
  --blue: #1f5fae;
  --blue-600: #1b54a0;
  --blue-700: #14325c;
  --blue-50: #e8f0fb;
  --blue-100: #cfe0f6;
  --sky: #e8f0fb;
  --gold: #a8823a;
  --gold-ink: #7d5f23;
  --gold-ink: #7a5a17;
  --gold-50: #faf5e8;
  --gold-line: #ead9ac;
  --gold-fill: #c9a24a; --gold-fill-ink: #1d1606;
  --teal: #0f7c86;
  --teal-50: #e3f3f3;
  --teal-100: #c9e6e8;
  --teal-ink: #0c6870;
  --lvl-green: #1f6b3a; --lvl-green-50: #e6f4ea; --lvl-green-100: #bfe3c9;
  --lvl-amber: #7a4b00; --lvl-amber-50: #fdf1dc; --lvl-amber-100: #f1d29a;
  --ok: #15803d;
  --focus: #1f5fae;
  --btn-bg: #1f5fae;
  --btn-hover: #1b54a0;
  --btn-ink: #ffffff;
  --on-dark-surface: #ffffff;
  --scrim: rgba(255, 255, 255, .86);
  /* six-step blue scale for maps: fewer to more */
  --q0: #f1f5fb; --q1: #d6e4f7; --q2: #a9c8ef; --q3: #6fa2e0; --q4: #3b7bc9; --q5: #14325c;
  --sans: "Manrope", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --max: 74rem;
  --r-sm: 8px;
  --r: 14px;
  --r-lg: 20px;
  --shadow-sm: 0 1px 2px rgba(15, 31, 54, .05);
  --shadow: 0 1px 2px rgba(15, 31, 54, .04), 0 6px 18px rgba(15, 31, 54, .07);
  --shadow-lg: 0 2px 6px rgba(15, 31, 54, .05), 0 18px 44px rgba(15, 31, 54, .14);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #0b1422; --surface: #111e31; --surface-2: #16263d;
    --ink: #e8eef7; --text: #c9d5e6; --muted: #9aabc2; --subtle: #9aaac0;
    --line: #23354e; --line-strong: #34496a;
    --navy: #a9c9f3; --blue: #6aa5ec; --blue-600: #8dbbf1; --blue-700: #a9c9f3;
    --blue-50: #16294a; --blue-100: #1e3a62; --sky: #16294a;
    --gold: #d8b46a; --gold-ink: #d8b46a; --gold-ink: #e3c683; --gold-50: #2a2415; --gold-line: #5b4a24; --gold-fill: #d8b46a; --gold-fill-ink: #0b1422;
    --teal: #4fc3cc; --teal-50: #0f2b33; --teal-100: #173d45; --teal-ink: #6fd0d7;
  --lvl-green: #7fd39a; --lvl-green-50: #11291a; --lvl-green-100: #1d4329; --lvl-amber: #f0c06a; --lvl-amber-50: #2e2210; --lvl-amber-100: #4a3718;
    --lvl-green: #7fd39a; --lvl-green-50: #11291a; --lvl-green-100: #1d4329; --lvl-amber: #f0c06a; --lvl-amber-50: #2e2210; --lvl-amber-100: #4a3718;
    --ok: #4ade80; --focus: #6aa5ec;
    --btn-bg: #6aa5ec; --btn-hover: #8dbbf1; --btn-ink: #0b1422;
    --scrim: rgba(11, 20, 34, .86);
    --q0: #15243b; --q1: #1d3558; --q2: #2a4c7d; --q3: #3d6aa8; --q4: #6aa5ec; --q5: #a9c9f3;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 22px rgba(0, 0, 0, .35);
    --shadow-lg: 0 2px 6px rgba(0, 0, 0, .3), 0 20px 48px rgba(0, 0, 0, .5);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b1422; --surface: #111e31; --surface-2: #16263d;
  --ink: #e8eef7; --text: #c9d5e6; --muted: #9aabc2; --subtle: #9aaac0;
  --line: #23354e; --line-strong: #34496a;
  --navy: #a9c9f3; --blue: #6aa5ec; --blue-600: #8dbbf1; --blue-700: #a9c9f3;
  --blue-50: #16294a; --blue-100: #1e3a62; --sky: #16294a;
  --gold: #d8b46a; --gold-ink: #d8b46a; --gold-ink: #e3c683; --gold-50: #2a2415; --gold-line: #5b4a24; --gold-fill: #d8b46a; --gold-fill-ink: #0b1422;
  --teal: #4fc3cc; --teal-50: #0f2b33; --teal-100: #173d45; --teal-ink: #6fd0d7;
  --ok: #4ade80; --focus: #6aa5ec;
  --btn-bg: #6aa5ec; --btn-hover: #8dbbf1; --btn-ink: #0b1422;
  --scrim: rgba(11, 20, 34, .86);
  --q0: #15243b; --q1: #1d3558; --q2: #2a4c7d; --q3: #3d6aa8; --q4: #6aa5ec; --q5: #a9c9f3;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 22px rgba(0, 0, 0, .35);
  --shadow-lg: 0 2px 6px rgba(0, 0, 0, .3), 0 20px 48px rgba(0, 0, 0, .5);
}
:root[data-theme="light"] { color-scheme: light; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; background: var(--bg); }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--sans); font-size: 1rem; line-height: 1.62; font-weight: 400;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
img, svg { max-width: 100%; height: auto; }
a { color: var(--blue); text-decoration: none; text-underline-offset: .18em; }
a:hover { color: var(--blue-600); text-decoration: underline; }
main a:not(.btn):not(.card-link):not(.chip):not(.school-card):not(.state-card) { text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--blue) 35%, transparent); text-underline-offset: .18em; }
main a:not(.btn):hover { text-decoration-color: currentColor; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
.skip { position: absolute; left: -9999px; top: 0; background: var(--ink); color: var(--bg); padding: .6rem 1rem; z-index: 60; border-radius: var(--r-sm); }
.skip:focus { left: 1rem; top: 1rem; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

h1, h2, h3, h4 { font-family: var(--sans); color: var(--ink); line-height: 1.18; margin: 1.6em 0 .55em; letter-spacing: -.025em; font-weight: 800; }
h1 { font-size: clamp(2rem, 4.8vw, 2.9rem); margin-top: .25em; letter-spacing: -.035em; }
h2 { font-size: clamp(1.35rem, 3vw, 1.7rem); }
h3 { font-size: 1.12rem; font-weight: 700; letter-spacing: -.015em; }
h4 { font-size: 1rem; font-weight: 700; }
p { margin: 0 0 1em; }
.caps { text-transform: uppercase; letter-spacing: .08em; font-size: .78em; font-weight: 700; }
.eyebrow { display: inline-flex; align-items: center; gap: .45rem; font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--blue); margin: 0 0 .5rem; }
.lede { font-size: clamp(1.06rem, 2.1vw, 1.22rem); color: var(--muted); line-height: 1.55; max-width: 46rem; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
hr, .rule { border: 0; border-top: 1px solid var(--line); margin: 2.5rem 0; }
.fleuron { text-align: center; color: var(--blue); opacity: .5; margin: 2.5rem 0; }
code, pre { font-family: var(--mono); font-size: .85rem; }
pre { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-sm); padding: .85rem; overflow-x: auto; white-space: pre-wrap; word-break: break-all; }

/* ------------------------------------------------------------- layout */
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 1rem; }
@media (min-width: 48rem) { .wrap { padding: 0 1.75rem; } }
.sheet { padding: 1.5rem 0 3rem; }
@media (min-width: 48rem) { .sheet { padding: 2.5rem 0 4rem; } }
.prose { max-width: 44rem; }
.prose li { margin: .35rem 0; }
.prose h2 { margin-top: 2em; }

/* ------------------------------------------------------------- header */
.liturgical-rule { height: 3px; }
.masthead { position: sticky; top: 0; z-index: 30; background: var(--scrim); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid var(--line); }
.masthead .wrap { display: flex; align-items: center; gap: .75rem; min-height: 4.1rem; }
.brand { display: inline-flex; align-items: center; gap: .55rem; text-decoration: none; color: var(--ink); flex: 0 1 auto; min-width: 0; }
.brand:hover { text-decoration: none; color: var(--ink); }
.brand .mark { width: 2rem; height: 2rem; flex: none; color: var(--blue); display: block; }
.brand .mark svg { width: 100%; height: 100%; }
.brand-name { display: block; font-family: var(--sans); font-weight: 800; font-size: 1.12rem; letter-spacing: -.03em; line-height: 1; white-space: nowrap; color: var(--ink); }
.brand-name .guide { color: var(--blue); }
.brand-tag { display: none; }
.nav { margin-left: auto; display: flex; align-items: center; gap: .3rem; }
.nav ul { list-style: none; margin: 0; padding: 0; }
.nav .nav-wide { display: none; }
.nav .nav-wide a { display: inline-flex; align-items: center; height: 2.4rem; padding: 0 .85rem; border-radius: 999px; font-size: .95rem; font-weight: 600; color: var(--text); text-decoration: none; }
.nav .nav-wide a:hover { color: var(--ink); background: var(--surface-2); text-decoration: none; }
.nav .nav-wide a[aria-current="page"] { color: var(--blue); background: var(--blue-50); }
.nav .icon-btn { display: inline-grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: 999px; color: var(--ink); text-decoration: none; }
.nav .icon-btn:hover { background: var(--surface-2); text-decoration: none; color: var(--ink); }
.nav .account-link { display: none; align-items: center; height: 2.4rem; padding: 0 1rem; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: .9rem; font-weight: 700; text-decoration: none; white-space: nowrap; }
.nav .account-link:hover { color: var(--bg); text-decoration: none; opacity: .9; }
.nav-narrow { position: relative; }
.nav-narrow summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: .4rem; height: 2.5rem; padding: 0 .9rem; border-radius: 999px; font-size: .92rem; font-weight: 700; color: var(--ink); background: var(--surface-2); }
.nav-narrow summary::-webkit-details-marker { display: none; }
.nav-narrow summary svg { width: 1.05rem; height: 1.05rem; }
.nav-narrow[open] summary { background: var(--line); }
/* The phone menu is a full-width sheet under the header; on wider screens it becomes a popover. */
.nav-narrow[open] > .menu-sheet { position: fixed; left: 0; right: 0; top: 4.1rem; bottom: 0; background: var(--bg); overflow-y: auto; padding: 1rem 1rem 3rem; z-index: 35; animation: sheet-in .22s ease-out; }
.menu-sheet { display: block; }
.menu-sheet ul { list-style: none; margin: 0; padding: 0; }
.menu-sheet .menu-main a { display: flex; align-items: center; justify-content: space-between; min-height: 3.4rem; padding: 0 .25rem; border-bottom: 1px solid var(--line); font-size: 1.12rem; font-weight: 700; color: var(--ink); text-decoration: none; }
.menu-sheet .menu-main a[aria-current="page"] { color: var(--blue); }
.menu-sheet .menu-label { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--subtle); padding: 1.2rem .25rem .4rem; }
.menu-sheet .menu-links a { display: block; padding: .6rem .25rem; color: var(--text); font-weight: 600; text-decoration: none; }
.menu-sheet .menu-links a:hover { color: var(--blue); }
.menu-sheet .menu-account a { display: flex; justify-content: center; margin-top: 1.25rem; min-height: 3rem; align-items: center; border-radius: 999px; background: var(--ink); color: var(--bg); font-weight: 700; text-decoration: none; }
.menu-sheet .menu-theme { margin-top: 1.25rem; }
@keyframes sheet-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.more-menu { position: relative; display: none; }
.more-menu summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: .3rem; height: 2.4rem; padding: 0 .85rem; border-radius: 999px; font-size: .95rem; font-weight: 600; color: var(--text); }
.more-menu summary::-webkit-details-marker { display: none; }
.more-menu summary:hover { background: var(--surface-2); color: var(--ink); }
.more-menu[open] > ul { position: absolute; right: 0; top: calc(100% + .45rem); width: 14rem; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-lg); padding: .4rem; list-style: none; margin: 0; }
.more-menu[open] > ul a { display: block; padding: .55rem .75rem; border-radius: var(--r-sm); color: var(--ink); font-weight: 600; text-decoration: none; }
.more-menu[open] > ul a:hover { background: var(--surface-2); }
@media (min-width: 48rem) {
  .nav .nav-wide { display: flex; align-items: center; gap: .15rem; margin-right: .35rem; }
  .nav .account-link { display: inline-flex; }
  .more-menu { display: block; }
  .nav-narrow { display: none; }
  .nav .nav-wide .divider { display: none; }
}
@media (min-width: 48rem) { .brand-name { font-size: 1.2rem; } .brand .mark { width: 2.2rem; height: 2.2rem; } }

/* secondary bar inside the Colleges and High Schools sections */
.section-bar { border-bottom: 1px solid var(--line); background: var(--surface); }
.section-bar .wrap { display: flex; align-items: center; gap: .2rem; overflow-x: auto; scrollbar-width: none; min-height: 3.1rem; }
.section-bar .wrap::-webkit-scrollbar { display: none; }
.section-bar .section-name { display: inline-flex; align-items: center; gap: .45rem; font-weight: 800; color: var(--ink); margin-right: .75rem; white-space: nowrap; font-size: .92rem; }
.section-bar .section-name svg { width: 1.05rem; height: 1.05rem; color: var(--blue); }
.section-bar a.tab { white-space: nowrap; padding: .42rem .8rem; border-radius: 999px; font-size: .88rem; font-weight: 600; color: var(--muted); text-decoration: none; }
.section-bar a.tab:hover { color: var(--ink); background: var(--bg); text-decoration: none; }
.section-bar a.tab[aria-current="page"] { background: var(--ink); color: var(--bg); }
.section-bar .switch { margin-left: auto; white-space: nowrap; font-size: .86rem; font-weight: 700; color: var(--blue); padding-left: 1rem; text-decoration: none; }

.announcement { background: var(--ink); color: var(--bg); text-align: center; padding: .55rem 1rem; font-size: .9rem; }

/* ------------------------------------------------------------- footer */
.colophon { background: var(--surface); color: var(--text); margin-top: 4rem; padding: 3.25rem 0 2.5rem; font-size: .92rem; border-top: 1px solid var(--line); }
.colophon .cols { display: grid; gap: 2.25rem; grid-template-columns: 1fr; }
@media (min-width: 48rem) { .colophon .cols { grid-template-columns: 1.7fr 1fr 1fr 1fr; } }
.colophon .foot-brand { display: inline-flex; align-items: center; gap: .65rem; margin-bottom: 1.1rem; color: var(--ink); text-decoration: none; }
.colophon .foot-brand:hover { color: var(--ink); text-decoration: none; }
.colophon .foot-brand .mark { width: 2.3rem; height: 2.3rem; color: var(--blue); }
.colophon .foot-brand .mark svg { width: 100%; height: 100%; }
.colophon .foot-brand .brand-name { font-weight: 800; font-size: 1.12rem; letter-spacing: -.03em; }
.colophon .foot-brand .foot-tag { margin-top: .26rem; font-family: var(--serif); font-style: italic; font-weight: 400; font-size: .84rem; letter-spacing: .01em; line-height: 1; color: var(--gold-ink); }
.colophon .foot-brand:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
.colophon h2 { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; margin: 0 0 .8rem; color: var(--subtle); }
.colophon ul { list-style: none; margin: 0; padding: 0; }
.colophon li { margin: .45rem 0; }
.colophon a { color: var(--ink); text-decoration: none; font-weight: 500; }
.colophon a:hover { color: var(--blue); text-decoration: underline; }
.colophon p a { text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--blue) 40%, transparent); }
.colophon .small { color: var(--muted); }
.independence { color: var(--text); margin-bottom: 1rem; }
.colophon .legal { border-top: 1px solid var(--line); margin-top: 2.25rem; padding-top: 1.25rem; color: var(--muted); }
.theme-switch { display: inline-flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.theme-switch .label { font-size: .8rem; font-weight: 700; color: var(--subtle); letter-spacing: .02em; }
.seg { display: inline-flex; padding: .2rem; border-radius: 999px; background: var(--bg); border: 1px solid var(--line-strong); }
.seg button { font: inherit; font-size: .82rem; font-weight: 700; min-height: 2rem; padding: .25rem .75rem; border-radius: 999px; background: transparent; color: var(--muted); border: 0; box-shadow: none; cursor: pointer; }
.seg button:hover { background: var(--surface-2); color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
.seg button:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.footer-theme { margin-top: 1.5rem; }

/* ------------------------------------------------------------- forms & buttons */
input:not([type]), input[type="text"], input[type="datetime-local"], input[type="search"], input[type="number"], input[type="password"], input[type="url"], input[type="email"], select, textarea {
  font: inherit; font-size: 1rem; color: var(--ink); background: var(--bg); border: 1px solid var(--line-strong); border-radius: var(--r-sm);
  padding: .6rem .8rem; min-height: 2.8rem; max-width: 100%; transition: border-color .15s, box-shadow .15s;
}
select { appearance: none; -webkit-appearance: none; padding-right: 2.3rem; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%2366768d' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .8rem center; }
input:hover, select:hover, textarea:hover { border-color: var(--subtle); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 4px color-mix(in srgb, var(--blue) 16%, transparent); }
input[type="checkbox"], input[type="radio"] { accent-color: var(--blue); width: 1.05rem; height: 1.05rem; vertical-align: -.15em; }
textarea { width: 100%; min-height: 8rem; }
label { font-weight: 600; font-size: .92rem; color: var(--ink); }
.btn, button {
  font: inherit; font-weight: 700; font-size: .95rem; letter-spacing: -.01em;
  background: var(--btn-bg); color: var(--btn-ink); border: 1px solid var(--btn-bg); border-radius: 999px;
  padding: .6rem 1.25rem; min-height: 2.8rem; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  box-shadow: 0 1px 2px rgba(15, 31, 54, .12); transition: background .15s, box-shadow .15s, transform .05s, border-color .15s;
}
.btn:hover, button:hover { background: var(--btn-hover); border-color: var(--btn-hover); color: var(--btn-ink); text-decoration: none; }
.btn:active, button:active { transform: translateY(1px); }
.btn.secondary, button.secondary { background: var(--bg); color: var(--ink); border-color: var(--line-strong); box-shadow: var(--shadow-sm); }
.btn.secondary:hover, button.secondary:hover { background: var(--surface-2); color: var(--ink); border-color: var(--subtle); }
.btn.ghost, button.ghost { background: transparent; color: var(--blue); border-color: transparent; box-shadow: none; }
.btn.ghost:hover, button.ghost:hover { background: var(--blue-50); color: var(--blue-600); }
.btn.small, button.small { font-size: .84rem; padding: .32rem .85rem; min-height: 2.2rem; }
.btn.dark { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.btn.dark:hover { background: var(--navy); border-color: var(--navy); color: #fff; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn.dark:hover { color: var(--bg); } }
:root[data-theme="dark"] .btn.dark:hover { color: var(--bg); }

.searchbar { display: flex; gap: .5rem; margin: 0; align-items: stretch; }
.searchbar input, .searchbar select { flex: 1; min-width: 0; width: 100%; }
/* The search box is the home page's hero: large, soft shadow, one clear action. */
.search-hero { position: relative; display: flex; align-items: center; background: var(--bg); border: 1px solid var(--line-strong); border-radius: 999px; padding: .38rem .38rem .38rem 1.2rem; box-shadow: var(--shadow-lg); max-width: 46rem; transition: border-color .15s, box-shadow .15s; }
.search-hero:focus-within { border-color: var(--blue); box-shadow: 0 0 0 5px color-mix(in srgb, var(--blue) 16%, transparent), var(--shadow-lg); }
.search-hero svg { width: 1.2rem; height: 1.2rem; color: var(--subtle); flex: none; }
.search-hero input { border: 0; box-shadow: none !important; flex: 1; min-width: 0; font-size: 1.1rem; background: transparent; min-height: 2.9rem; padding-left: .2rem; }
.search-hero input::placeholder { color: var(--subtle); opacity: 1; }
.search-hero button { flex: none; min-height: 3rem; padding: 0 1.4rem; }

/* filters: a sticky sidebar on desktop (1024px and up); on phones and tablets a toolbar and a bottom sheet.
   Without JavaScript the panel is shown in the page and "Show results" submits the form. */
:root { --pill-h: 1.62rem; --pill-px: .62rem; --pill-fs: .78rem; --pill-ico: .82rem; --pill-gap: .35rem; --chip-h: 2.2rem; }
.search-layout { display: grid; gap: 1.25rem; grid-template-columns: minmax(0, 1fr); align-items: start; }
.results-col { min-width: 0; }
@media (min-width: 64rem) { .search-layout { grid-template-columns: 17rem minmax(0, 1fr); gap: 2rem; } }
dialog.fpanel { display: block; position: static; inset: auto; padding: 0; margin: 0; border: 0; background: transparent; color: var(--text); width: auto; max-width: none; height: auto; max-height: none; overflow: visible; }
.fpanel-head { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.fpanel-title { margin: 0; font-size: 1.1rem; letter-spacing: -.01em; }
.fpanel-close { width: 2.5rem; height: 2.5rem; min-height: 0; padding: 0; margin: 0; border: 0; border-radius: 999px; background: var(--surface-2); color: var(--ink); display: inline-grid; place-items: center; box-shadow: none; transform: none; flex: none; }
.fpanel-close:hover { background: var(--line); color: var(--ink); }
.fpanel-scroll { display: grid; gap: 0; }
.fpanel-foot { display: flex; align-items: center; gap: .6rem; }
.fpanel-foot [data-apply] { margin-left: auto; }
@media (min-width: 64rem) {
  dialog.fpanel { position: sticky; top: 5.25rem; max-height: calc(100vh - 6.5rem); display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); overflow: hidden; }
  .fpanel-head { display: none; }
  .fpanel-scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: .15rem 1rem .35rem; overscroll-behavior: contain; scrollbar-width: thin; }
  .fpanel-scroll.has-more { -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 2.6rem), transparent); mask-image: linear-gradient(to bottom, #000 calc(100% - 2.6rem), transparent); }
  .fpanel-foot { padding: .7rem 1rem; border-top: 1px solid var(--line); background: var(--surface); }
  .js .fpanel-foot [data-apply] { display: none; }
  .fpanel-foot .btn.ghost { padding-left: 0; }
}
@media (max-width: 63.99rem) {
  .js dialog.fpanel:not([open]) { display: none; }
  dialog.fpanel[open] { position: fixed; inset: auto 0 0 0; margin: 0; width: 100%; max-width: 100%; height: calc(100dvh - 2.25rem); display: flex; flex-direction: column; background: var(--bg); color: var(--text); border: 0; border-radius: 22px 22px 0 0; box-shadow: var(--shadow-lg); padding: 0; overflow: hidden; }
  dialog.fpanel[open]::backdrop { background: rgba(11, 20, 34, .45); }
  .fpanel-head { padding: 1rem 1.1rem .8rem; border-bottom: 1px solid var(--line); }
  .fpanel-scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: .1rem 1.1rem 1rem; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
  .fpanel-foot { padding: .8rem 1.1rem calc(.8rem + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--bg); }
  .fpanel-foot .btn.ghost { padding-left: .4rem; }
  .fpanel-foot [data-apply] { flex: 1 1 auto; margin-left: 0; min-height: 2.9rem; }
  html:not(.js) .fpanel-head { display: none; }
  html:not(.js) .fpanel-foot [data-apply] { margin-left: auto; }
}
html:not(.js) .mtoolbar, html:not(.js) .sortsheet { display: none; }

/* Sidebar groups (native details, so they collapse without JavaScript) */
.fgroup { border-top: 1px solid var(--line); }
.fgroup:first-child { border-top: 0; }
.fgroup > summary { list-style: none; display: flex; align-items: center; gap: .5rem; cursor: pointer; padding: .8rem .1rem; font-size: .93rem; font-weight: 800; color: var(--ink); }
.fgroup > summary::-webkit-details-marker { display: none; }
.fgroup > summary:focus-visible { outline-offset: -2px; border-radius: 8px; }
.fgroup-title { flex: 1 1 auto; min-width: 0; }
.fcount { min-width: 1.4rem; height: 1.4rem; padding: 0 .4rem; border-radius: 999px; background: var(--btn-bg); color: var(--btn-ink); font-size: .72rem; font-weight: 800; display: inline-grid; place-items: center; font-variant-numeric: tabular-nums; }
.fcount:empty { display: none; }
.fchev { color: var(--subtle); transition: transform .2s ease; flex: none; }
.fgroup[open] > summary .fchev { transform: rotate(90deg); }
.fgroup-body { display: grid; gap: .95rem; padding: .1rem 0 1.1rem; }
.fgroup-slot { border-top: 1px dashed var(--line-strong); padding: .8rem .1rem; }
.fgroup-slot-row { display: flex; align-items: center; gap: .5rem; }
.fgroup-slot .fgroup-title { font-size: .93rem; font-weight: 800; color: var(--subtle); }
.soon-pill { display: inline-flex; align-items: center; height: var(--pill-h); padding: 0 var(--pill-px); border-radius: 999px; border: 1px dashed var(--line-strong); color: var(--subtle); font-size: var(--pill-fs); font-weight: 700; }

.ffield { display: grid; gap: .35rem; min-width: 0; margin: 0; padding: 0; border: 0; }
.ffield-head { display: flex; align-items: center; gap: .25rem; min-height: 1.35rem; }
.ffield-head label, .flegend { font-size: .85rem; font-weight: 700; color: var(--text); }
.ffield select, .ffield input[type="search"], .ffield input[type="number"] { width: 100%; min-height: 2.5rem; font-size: .93rem; padding: .5rem .7rem; }
.ffield input[type="search"]::-webkit-search-cancel-button { cursor: pointer; }

/* Segmented grade choices: Any, A, B+, C+, D+ */
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); border: 1px solid var(--line-strong); border-radius: 10px; overflow: hidden; background: var(--bg); }
.seg-opt { position: relative; min-width: 0; }
.seg-opt + .seg-opt span { border-left: 1px solid var(--line-strong); }
.seg-opt input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none; }
.seg-opt span { display: flex; align-items: center; justify-content: center; height: 2.25rem; padding: 0 .2rem; font-size: .84rem; font-weight: 700; color: var(--text); cursor: pointer; white-space: nowrap; font-variant-numeric: tabular-nums; transition: background .15s, color .15s; }
.seg-opt:hover span { background: var(--surface-2); }
.seg-opt input:checked + span { background: var(--btn-bg); color: var(--btn-ink); }
.seg-opt input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: -3px; }

/* Toggle switches */
.ftoggles { display: grid; gap: .6rem; }
.ftoggle-row { display: flex; align-items: center; gap: .3rem; min-width: 0; }
.ftoggle { position: relative; display: inline-flex; align-items: center; gap: .65rem; cursor: pointer; flex: 1 1 auto; min-width: 0; font-size: .92rem; font-weight: 600; color: var(--ink); }
.ftoggle input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; }
.ftoggle .track { position: relative; flex: none; width: 2.4rem; height: 1.4rem; border-radius: 999px; background: var(--line-strong); transition: background .2s ease; }
.ftoggle .thumb { position: absolute; top: .15rem; left: .15rem; width: 1.1rem; height: 1.1rem; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .25); transition: transform .2s ease; }
.ftoggle input:checked + .track { background: var(--btn-bg); }
.ftoggle input:checked + .track .thumb { transform: translateX(1rem); }
.ftoggle input:focus-visible + .track { outline: 3px solid var(--focus); outline-offset: 2px; }
.ftoggle .ttext { line-height: 1.3; }
@media (prefers-reduced-motion: reduce) { .ftoggle .track, .ftoggle .thumb, .fchev, .seg-opt span { transition: none; } }

/* Toolbar on phones and tablets */
.mtoolbar { display: none; }
@media (max-width: 63.99rem) {
  .js .mtoolbar { display: flex; position: sticky; top: 4.1rem; z-index: 25; align-items: center; gap: .5rem; margin: 0 -1rem .75rem; padding: .6rem 1rem; background: var(--scrim); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid var(--line); }
}
.mq { flex: 1 1 auto; min-width: 0; min-height: 2.6rem; font-size: 1rem; padding: .45rem .9rem; border-radius: 999px; }
.mbtn { display: inline-flex; align-items: center; gap: .4rem; flex: none; min-height: 2.6rem; padding: 0 .8rem; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink); font-size: .9rem; font-weight: 700; box-shadow: var(--shadow-sm); transform: none; }
.mbtn:hover { background: var(--surface-2); color: var(--ink); border-color: var(--subtle); }
.mbtn svg { color: var(--blue); }
.mcount { color: var(--blue); font-variant-numeric: tabular-nums; }

/* Results */
.results-region { transition: opacity .15s ease; }
.results-region.is-loading { opacity: .55; pointer-events: none; }
@media (prefers-reduced-motion: reduce) { .results-region { transition: none; } }
.results-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .2rem .75rem; margin: .35rem 0 .7rem; }
.results-head .results-count { margin: 0; font-size: .95rem; color: var(--muted); }
.results-head .results-count b { color: var(--ink); font-variant-numeric: tabular-nums; }
.results-head .results-count:focus { outline: none; }
.results-head .note { margin: 0; }
.sortnote { color: var(--subtle); }

/* Quick filter chips: a toggle link plus an info button; the selected chip is filled with a check */
.fbar { display: flex; flex-wrap: wrap; align-items: center; gap: .45rem; margin: 0 0 .85rem; }
.fchip-host { max-width: 100%; }
.fchip { display: inline-flex; align-items: stretch; height: var(--chip-h); max-width: 100%; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink); box-shadow: var(--shadow-sm); transition: background .15s, border-color .15s; }
.fchip:hover { background: var(--blue-50); border-color: var(--blue-100); }
.fchip-link { display: inline-flex; align-items: center; gap: .4rem; padding: 0 .3rem 0 .8rem; min-width: 0; font-size: .9rem; font-weight: 600; color: inherit; text-decoration: none !important; border-radius: 999px; }
.fchip-link:hover { color: var(--blue); }
.fchip-link:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.fchip-icon { color: var(--blue); flex: none; }
.fchip .pop-i { width: 1.6rem; height: 1.6rem; margin: auto .3rem auto 0; color: var(--subtle); }
.fchip.on { background: var(--btn-bg); border-color: var(--btn-bg); color: var(--btn-ink); }
.fchip.on:hover { background: var(--btn-hover); border-color: var(--btn-hover); }
.fchip.on .fchip-link, .fchip.on:hover .fchip-link { color: var(--btn-ink); }
.fchip.on .fchip-icon { color: var(--btn-ink); }
.fchip.on .pop-i, .fchip.on .pop-i:hover { color: var(--btn-ink); background: rgba(255, 255, 255, .16); }
.fchip.on .grade.xs { background: var(--btn-ink); color: var(--btn-bg); border-color: transparent; }
.fchip .grade.xs { font-size: .72rem; }
.chip { display: inline-flex; align-items: center; gap: .4rem; height: var(--chip-h); padding: 0 .95rem; border-radius: 999px; background: var(--bg); border: 1px solid var(--line-strong); color: var(--ink); font-size: .9rem; font-weight: 600; text-decoration: none; box-shadow: var(--shadow-sm); }
.chip:hover { background: var(--blue-50); border-color: var(--blue-100); color: var(--blue); text-decoration: none; }
.chip-clear { color: var(--muted); border-style: dashed; }
.chip-clear svg { width: .8rem; height: .8rem; }

/* Active filters: each one removes itself */
.achips { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin: 0 0 .9rem; }
.achip { display: inline-flex; align-items: center; gap: .35rem; height: 1.9rem; padding: 0 .4rem 0 .75rem; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); color: var(--ink); font-size: .84rem; font-weight: 600; text-decoration: none !important; max-width: 100%; }
.achip:hover { border-color: var(--subtle); background: var(--line); }
.achip svg { color: var(--subtle); flex: none; }
.achip-clear { font-size: .84rem; font-weight: 700; color: var(--blue); padding: 0 .3rem; margin-left: .15rem; text-decoration: none; }
.achip-clear:hover { text-decoration: underline; }
@media (max-width: 63.99rem) {
  .fbar, .achips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: -1rem; margin-right: -1rem; padding: 0 1rem .3rem; }
  .fbar::-webkit-scrollbar, .achips::-webkit-scrollbar { display: none; }
  .fchip, .fchip-host, .achip { flex: none; }
}

/* Info buttons and explanation bubbles (popover.js) */
.pop-host { position: relative; display: inline-flex; align-items: center; max-width: 100%; vertical-align: middle; }
.pop-i { appearance: none; width: 1.45rem; height: 1.45rem; min-height: 0; margin: 0; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--subtle); display: inline-grid; place-items: center; box-shadow: none; transform: none; cursor: pointer; flex: none; }
.pop-i:hover { background: var(--blue-50); color: var(--blue); transform: none; }
.pop-i:focus-visible { outline: 3px solid var(--focus); outline-offset: 1px; }
.pop-i svg { width: .9rem; height: .9rem; }
.pop-trigger { cursor: help; }
.pop-body { display: none; position: fixed; inset: auto; top: 0; left: 0; z-index: 1000; margin: 0; width: max-content; max-width: min(20rem, calc(100vw - 1rem)); padding: .6rem .75rem; border: 0; border-radius: 10px; background: var(--ink); color: var(--bg); font: 500 .84rem/1.45 var(--sans); letter-spacing: normal; text-align: left; text-transform: none; white-space: normal; box-shadow: var(--shadow-lg); overflow: visible; pointer-events: auto; }
.pop-body.is-open { display: block; animation: pop-in .14s ease-out; }
.pop-body::after { content: ""; position: absolute; width: .55rem; height: .55rem; background: inherit; left: var(--ax, 50%); margin-left: -.275rem; transform: rotate(45deg); }
.pop-body[data-side="top"]::after { bottom: -.275rem; }
.pop-body[data-side="bottom"]::after { top: -.275rem; }
@keyframes pop-in { from { opacity: 0; transform: translateY(3px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .pop-body.is-open { animation: none; } }
@media (pointer: coarse) { .pop-i { width: 2rem; height: 2rem; } .fchip .pop-i { width: 2rem; height: 2rem; } }

/* ------------------------------------------------------------- grades, rings & scores */
.grade {
  position: relative; display: inline-flex; align-items: center; justify-content: center; width: 2.5rem; height: 2.5rem; border-radius: 12px;
  font-weight: 800; font-size: 1.15rem; line-height: 1; letter-spacing: -.02em; color: var(--ink); background: var(--surface-2); border: 1px solid var(--line); flex: none; font-variant-numeric: tabular-nums; cursor: help;
}
.grade.g-A { background: var(--btn-bg); border-color: var(--btn-bg); color: var(--btn-ink); }
.grade.g-B { background: var(--blue-50); border-color: var(--blue-100); color: var(--blue); }
.grade.g-C { background: var(--surface-2); border-color: var(--line-strong); color: var(--ink); }
.grade.g-D, .grade.g-F { background: var(--bg); border-color: var(--line-strong); color: var(--muted); }
.grade.g-na { background: var(--bg); border: 1px dashed var(--line-strong); color: var(--subtle); font-size: .66rem; font-weight: 700; letter-spacing: .02em; }
.grade.lg { width: 4rem; height: 4rem; font-size: 1.9rem; border-radius: 16px; }
.grade.sm { width: 1.7rem; height: 1.7rem; font-size: .86rem; border-radius: 8px; }
.grade.sm.g-na { font-size: .5rem; }
.grade.xs { width: 1.2rem; height: 1.2rem; font-size: .7rem; border-radius: 6px; }
/* short explanation on hover or focus for non-pill chart marks (admin charts); pills and grades use popover.js */
[data-tip] { position: relative; }
[data-tip]:hover::after, [data-tip]:focus-visible::after {
  content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + .5rem); transform: translateX(-50%); z-index: 20;
  width: max-content; max-width: 16rem; padding: .45rem .7rem; border-radius: var(--r-sm); background: var(--ink); color: var(--bg);
  font: 600 .8rem/1.4 var(--sans); text-align: left; white-space: normal; box-shadow: var(--shadow); pointer-events: none;
}
.grade-pair { display: inline-flex; align-items: center; gap: .45rem; font-size: .9rem; color: var(--text); font-weight: 600; white-space: nowrap; }

.ring-wrap { display: inline-flex; flex-direction: column; align-items: center; gap: .3rem; flex: none; }
.ring { position: relative; display: inline-grid; place-items: center; flex: none; }
.ring svg { display: block; transform: rotate(-90deg); }
.ring .track { stroke: var(--line); }
.ring .value { stroke: var(--blue); stroke-linecap: round; }
.ring.na .value { stroke: transparent; }
/* Catholic Life Score: an open teal ring on a light teal disc. The arc covers 90% of the circle and starts after a
   gap at 12 o'clock, where a small upright cross sits like a keystone (drawn in the SVG, so it scales with the ring). */
.ring.life .disc { fill: var(--teal-50); }
.ring.life .track { stroke: var(--teal-100); }
.ring.life .value { stroke: var(--teal); stroke-linecap: round; }
.ring.life svg { transform: none; overflow: visible; }
.ring.life .ring-cross { stroke: var(--teal); }
.ring.life .ring-label { transform: translateY(4%); }
.ring .ring-label { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; line-height: 1; }
.ring .ring-label b { display: block; font-size: 1.5rem; font-weight: 800; letter-spacing: -.04em; color: var(--ink); font-variant-numeric: tabular-nums; }
.ring.sm .ring-label b { font-size: 1rem; letter-spacing: -.03em; }
.ring.lg .ring-label b { font-size: 2.2rem; }
.ring-cap { font-size: .72rem; font-weight: 700; color: var(--muted); text-align: center; line-height: 1.25; max-width: 8.5rem; }
.ring-wrap.life .ring-cap { color: var(--teal-ink); }
.ring-wrap .ring-cap.sm { font-size: .68rem; }

.scoreboard { display: grid; gap: .75rem; grid-template-columns: 1fr; margin: 1.25rem 0 0; }
.score-card { display: flex; align-items: center; gap: 1rem; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 1rem 1.1rem; box-shadow: var(--shadow-sm); min-width: 0; }
.score-card.primary { background: var(--surface); border-color: var(--line); }
.score-card.primary.life { border-color: var(--teal-100); }
.life-note { font-size: .92rem; color: var(--muted); margin: 1rem 0 0; padding: .75rem 1rem; border-left: 3px solid var(--teal); background: var(--teal-50); border-radius: 0 var(--r-sm) var(--r-sm) 0; }
.list-divider { font-size: 1.1rem; margin: 2rem 0 .35rem; padding-top: 1rem; border-top: 2px solid var(--teal-100); color: var(--teal-ink); }
.list-divider-note { margin: 0 0 .85rem; }
.score-card .label { font-size: .72rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--subtle); }
.score-card .title { font-weight: 800; color: var(--ink); font-size: 1.05rem; line-height: 1.3; }
.score-card .sub { font-size: .84rem; color: var(--muted); margin-top: .15rem; }
.score-card a { font-size: .84rem; }

/* Pills, tags and badges: one system (same height, radius, padding, icon size and gap everywhere, admin too) */
.pill, .tag, .seal-badge, .job-pill {
  display: inline-flex; align-items: center; gap: var(--pill-gap); height: var(--pill-h); padding: 0 var(--pill-px); border-radius: 999px;
  font-size: var(--pill-fs); font-weight: 700; line-height: 1; letter-spacing: .005em; white-space: nowrap; vertical-align: middle;
  color: var(--muted); background: var(--surface-2); border: 1px solid var(--line); font-variant-numeric: tabular-nums; text-decoration: none;
}
.pill svg, .tag svg, .seal-badge svg { width: var(--pill-ico); height: var(--pill-ico); flex: none; }
/* weight pills: "35% of score" */
.pill.blue, .tag.rec, .tag.red { color: var(--blue); background: var(--blue-50); border-color: var(--blue-100); }
.pill.teal { color: var(--teal-ink); background: var(--teal-50); border-color: var(--teal-100); }
/* Honor Roll is gold: soft gold for tags, a richer gold fill for the badge (text meets AA in both themes) */
.tag.honor { color: var(--gold-ink); background: var(--gold-50); border-color: var(--gold-line); }
.seal-badge.honor { color: var(--gold-fill-ink); background: var(--gold-fill); border-color: var(--gold-fill); }
.tag.level { gap: .4rem; padding-right: .2rem; }
.tag.level .lvl { display: inline-flex; align-items: center; height: calc(var(--pill-h) - .4rem); padding: 0 .5rem; border-radius: 999px; border: 1px solid transparent; font-weight: 700; }
.lvl.l-excellent { color: var(--lvl-green); background: var(--lvl-green-50); border-color: var(--lvl-green-100); }
.lvl.l-strong { color: var(--teal-ink); background: var(--teal-50); border-color: var(--teal-100); }
.lvl.l-fair { color: var(--lvl-amber); background: var(--lvl-amber-50); border-color: var(--lvl-amber-100); }
.lvl.l-limited, .lvl.l-na { color: var(--muted); background: var(--bg); border-color: var(--line-strong); }
.tag.honor.life, .seal-badge.honor.life { color: var(--teal-ink); background: var(--teal-50); border-color: var(--teal-100); }
.seal-badge.rec { color: var(--blue); background: var(--blue-50); border-color: var(--blue-100); }
.weight-note { font-size: .86rem; color: var(--muted); margin: 0 0 .75rem; }
.honor-kicker { margin: 0 0 .4rem; }
.tags { display: inline-flex; flex-wrap: wrap; gap: .35rem; align-items: center; }
.seals { display: flex; flex-wrap: wrap; gap: .4rem; }

/* ------------------------------------------------------------- cards & lists */
.grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 40rem) { .grid.two { grid-template-columns: 1fr 1fr; } }
@media (min-width: 56rem) { .grid.three { grid-template-columns: repeat(3, 1fr); } .grid.four { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 40rem) and (max-width: 55.99rem) { .grid.three, .grid.four { grid-template-columns: 1fr 1fr; } }
.card { border: 1px solid var(--line); background: var(--bg); border-radius: var(--r-lg); padding: 1.25rem 1.3rem; position: relative; box-shadow: var(--shadow-sm); min-width: 0; }
.card h3 { margin-top: 0; }
.card.link-card { transition: box-shadow .2s, border-color .2s, transform .2s; }
.card.link-card a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.card.link-card a { text-decoration: none; color: var(--ink); }
.card.link-card:hover { border-color: var(--line-strong); box-shadow: var(--shadow); transform: translateY(-2px); }
.card.link-card:hover a { color: var(--blue); }
.card .kicker, .kicker { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--blue); margin: 0 0 .4rem; }

/* search results: one ring, at most two grades, the honor badge */
.results { list-style: none; margin: 0; padding: 0; display: grid; gap: .75rem; }
.result { display: grid; grid-template-columns: auto 1fr; gap: .4rem 1.1rem; padding: 1.1rem 1.2rem; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--bg); align-items: start; box-shadow: var(--shadow-sm); transition: box-shadow .2s, border-color .2s; position: relative; }
.result:hover { border-color: var(--line-strong); box-shadow: var(--shadow); }
.result h3 { margin: 0 0 .15rem; font-size: 1.1rem; line-height: 1.3; }
.result h3 a { color: var(--ink); text-decoration: none !important; }
.result h3 a::after { content: ""; position: absolute; inset: 0; }
.result h3 a:hover { color: var(--blue); }
.result .meta { color: var(--muted); font-size: .88rem; }
.result .pillars { display: flex; flex-wrap: wrap; gap: .4rem .85rem; margin-top: .6rem; font-size: .88rem; align-items: center; color: var(--muted); }
.result .pillars > span { display: inline-flex; gap: .4rem; align-items: center; }
.result .actions { grid-column: 2; display: flex; gap: .5rem; flex-wrap: wrap; margin-top: .5rem; position: relative; z-index: 1; }
.result .tags { display: inline-flex; flex-wrap: wrap; gap: .3rem; vertical-align: middle; }
.result .ring-col { display: flex; flex-direction: column; align-items: center; gap: .25rem; }
@media (min-width: 40rem) { .result { grid-template-columns: auto 1fr auto; padding: 1.2rem 1.4rem; } .result .actions { grid-column: 3; grid-row: 1 / span 2; margin: 0; align-self: center; } }
.result.compact { padding: .75rem .9rem; box-shadow: none; }
.result .result-icon { display: grid; place-items: center; width: 4.2rem; height: 4.2rem; border-radius: 50%; color: var(--subtle); background: var(--surface-2); }
.result .result-icon svg { width: 1.6rem; height: 1.6rem; }

.mini-list { list-style: none; margin: 0; padding: 0; }
.mini-list li { display: grid; grid-template-columns: auto 1fr auto; gap: .75rem; align-items: center; padding: .65rem 0; border-bottom: 1px solid var(--line); }
.mini-list li:last-child { border-bottom: 0; }
.mini-list a { color: var(--ink); font-weight: 700; text-decoration: none !important; }
.mini-list a:hover { color: var(--blue); }
.mini-list .meta { color: var(--subtle); font-size: .82rem; }
.mini-list .rank { color: var(--subtle); font-size: .82rem; font-weight: 700; font-variant-numeric: tabular-nums; width: 1.2rem; }

/* school cards (home and lists) */
.school-cards { display: grid; gap: .9rem; grid-template-columns: 1fr; }
.school-cards .school-card .tag { white-space: normal; }
@media (min-width: 40rem) { .school-cards { grid-template-columns: 1fr 1fr; } }
@media (min-width: 64rem) { .school-cards.three { grid-template-columns: repeat(3, 1fr); } }
.grid .stack .school-cards { grid-template-columns: 1fr; }
.school-card { position: relative; display: flex; gap: 1rem; align-items: center; padding: 1.1rem 1.15rem; border-radius: var(--r-lg); background: var(--bg); border: 1px solid var(--line); box-shadow: var(--shadow-sm); transition: box-shadow .2s, border-color .2s, transform .2s; min-width: 0; }
.school-card:hover { border-color: var(--line-strong); box-shadow: var(--shadow); transform: translateY(-2px); }
.school-card .sc-body { min-width: 0; flex: 1; }
.school-card .sc-name { font-weight: 800; font-size: 1.02rem; color: var(--ink); line-height: 1.3; margin: 0; letter-spacing: -.01em; }
.school-card .sc-name a { color: inherit; text-decoration: none; }
.school-card .sc-name a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.school-card .sc-meta { font-size: .85rem; color: var(--muted); margin-top: .15rem; }
.school-card .sc-tags { margin-top: .45rem; display: flex; gap: .3rem; flex-wrap: wrap; }
.school-card .ring { width: 4.4rem; height: 4.4rem; }

/* ------------------------------------------------------------- home */
.search-first { padding: 2.25rem 0 0; }
@media (min-width: 48rem) { .search-first { padding: 4rem 0 0; } }
.search-first h1 { font-size: clamp(2.2rem, 5.6vw, 3.6rem); line-height: 1.04; letter-spacing: -.045em; margin: 0 0 .85rem; max-width: 16ch; }
.search-first h1 em { font-style: normal; color: var(--blue); }
.search-first .lede { margin-bottom: 1.6rem; max-width: 40rem; }
.search-first .quick { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: 1rem; align-items: center; }
.search-first .quick span { font-size: .84rem; color: var(--subtle); margin-right: .2rem; font-weight: 600; }
.search-first .chips-lg a { font-size: .95rem; }
.tagline { font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--blue); margin: 0 0 .9rem; }
/* The slogan: an italic serif in gold between two thin rules. Decorative; the text is the brand line. */
.tagline.slogan { display: inline-flex; align-items: center; gap: .8rem; margin: 0 0 1rem; font-family: var(--serif); font-style: italic; font-size: 1.22rem; font-weight: 400; letter-spacing: .01em; text-transform: none; color: var(--gold-ink); }
.tagline.slogan::before, .tagline.slogan::after { content: ""; width: 2.6rem; height: 1px; background: currentColor; opacity: .55; }
.tagline.slogan span { position: relative; }
/* Logo lockup: the mark spans the wordmark and the tagline beneath it, both lines start at the wordmark's left edge. */
.lockup { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; }
.brand-slogan { display: none; margin-top: .2rem; font-family: var(--serif); font-style: italic; font-weight: 400; font-size: .8rem; letter-spacing: .01em; line-height: 1; color: var(--gold-ink); white-space: nowrap; }
@media (min-width: 64rem) { .brand-slogan { display: block; } }
.notfound-slogan { font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--gold-ink); margin: 0 0 1rem; }

.home-section { margin-top: 3.5rem; }
.home-section > h2 { margin: 0 0 1.1rem; font-size: clamp(1.3rem, 2.8vw, 1.6rem); }
.home-section .section-head { display: flex; justify-content: space-between; align-items: end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.home-section .section-head h2 { margin: 0; }
.home-section .section-head p { margin: 0; color: var(--muted); font-size: .95rem; }

.today-box { display: grid; gap: .25rem; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); padding: 1.1rem 1.25rem; margin: 0; box-shadow: none; position: relative; overflow: hidden; }
.today-box.home-section { margin-top: 3.5rem; }
.today-box .feast { font-size: 1.22rem; font-weight: 800; color: var(--ink); letter-spacing: -.02em; }
.today-box .swatch { display: inline-block; width: .7rem; height: .7rem; border-radius: 50%; vertical-align: middle; margin-right: .3rem; box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px var(--line-strong); }

.lite-grid { display: grid; gap: .9rem; grid-template-columns: 1fr; }
@media (min-width: 48rem) { .lite-grid { grid-template-columns: 1fr 1fr; } }
.lite-card { display: block; padding: 1.2rem 1.3rem; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--bg); color: var(--ink); text-decoration: none !important; transition: border-color .2s, box-shadow .2s, transform .2s; position: relative; }
.lite-card:hover { border-color: var(--line-strong); box-shadow: var(--shadow); transform: translateY(-2px); }
.lite-card b { display: block; font-size: 1.08rem; font-weight: 800; letter-spacing: -.015em; margin-bottom: .25rem; }
.lite-card span { color: var(--muted); font-size: .92rem; }

.stat-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; margin: 1.25rem 0 0; }
@media (min-width: 48rem) { .stat-row { grid-template-columns: repeat(4, 1fr); } }
.stat { border: 1px solid var(--line); background: var(--bg); border-radius: var(--r); padding: 1rem 1.1rem; box-shadow: var(--shadow-sm); }
.stat b { display: block; font-size: 1.7rem; font-weight: 800; letter-spacing: -.04em; color: var(--ink); font-variant-numeric: tabular-nums; line-height: 1.15; }
.stat span { font-size: .86rem; color: var(--muted); }
.stat .delta { display: block; color: var(--subtle); margin-top: .2rem; font-size: .78rem; }
.stat-link { text-decoration: none !important; color: inherit; transition: border-color .15s, box-shadow .15s; }
.stat-link:hover { border-color: var(--line-strong); box-shadow: var(--shadow); }

.formula { border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); padding: 1.5rem; margin: 0; display: grid; gap: 1.5rem; grid-template-columns: 1fr; align-items: center; }
@media (min-width: 56rem) { .formula { grid-template-columns: 1fr 1.1fr; padding: 2.25rem 2.5rem; } }
.formula h2 { margin-top: 0; }
.formula .eq { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: .6rem; font-weight: 700; color: var(--ink); }
.formula .eq .term { display: flex; flex-direction: column; align-items: center; justify-content: center; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r); padding: .9rem .75rem; text-align: center; box-shadow: var(--shadow-sm); min-width: 0; }
.formula .eq .op.eqs { grid-column: 1 / -1; justify-self: center; line-height: 1; }
.formula .eq .term.result { grid-column: 1 / -1; }
@media (min-width: 40rem) { .formula .eq { grid-template-columns: 1fr auto 1fr auto 1.1fr; } .formula .eq .op.eqs, .formula .eq .term.result { grid-column: auto; } }
.formula .eq .term b { display: block; white-space: nowrap; font-size: 1.55rem; letter-spacing: -.03em; color: var(--blue); }
.formula .eq .term span { display: block; font-size: .78rem; font-weight: 700; color: var(--muted); }
.formula .eq .op { color: var(--subtle); font-size: 1.3rem; }
.formula .eq .term.result { background: var(--btn-bg); border-color: var(--btn-bg); }
.formula .eq .term.result b, .formula .eq .term.result span { color: var(--btn-ink); }

blockquote.saint { font-size: clamp(1.15rem, 2.6vw, 1.5rem); font-weight: 500; font-family: var(--serif); font-style: italic; letter-spacing: -.005em; line-height: 1.45; color: var(--ink); margin: 3rem auto; padding: 0 0 0 1.25rem; border-left: 3px solid var(--blue); max-width: 46rem; }
blockquote.saint footer { font-family: var(--sans); font-style: normal; font-size: .88rem; font-weight: 600; letter-spacing: 0; color: var(--muted); margin-top: .6rem; }

/* ------------------------------------------------------------- school page */
.photo-banner { margin: 0 0 1.4rem; border-radius: var(--r-lg); overflow: hidden; background: var(--surface-2); position: relative; box-shadow: var(--shadow); }
.photo-banner img { display: block; width: 100%; height: clamp(11rem, 30vw, 19rem); object-fit: cover; }
.photo-banner .photo-credit { position: absolute; right: .6rem; bottom: .6rem; margin: 0; }
.photo-chip { display: inline-flex; align-items: center; gap: .3rem; height: 1.85rem; padding: 0 .65rem; border: 0; border-radius: 999px; background: rgba(15, 31, 54, .72); color: #fff; font: inherit; font-size: .74rem; font-weight: 600; cursor: pointer; backdrop-filter: blur(4px); box-shadow: none; min-height: 0; }
.photo-chip:hover, .photo-chip[aria-expanded="true"] { background: rgba(15, 31, 54, .9); color: #fff; }
.photo-chip:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.photo-credit-text { position: absolute; right: 0; bottom: calc(100% + .45rem); width: max-content; max-width: min(24rem, calc(100vw - 3rem)); padding: .5rem .7rem; border-radius: .6rem; background: rgba(15, 31, 54, .88); color: #fff; font-size: .74rem; line-height: 1.45; opacity: 0; transform: translateY(4px); pointer-events: none; transition: opacity .15s ease, transform .15s ease; }
.photo-credit:hover .photo-credit-text, .photo-credit:focus-within .photo-credit-text, .photo-credit.open .photo-credit-text { opacity: 1; transform: none; pointer-events: auto; }
.photo-credit-text a { color: #fff !important; text-decoration: underline; text-underline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .photo-credit-text { transition: none; } }
/* Aerial views (USGS, public domain): a soft tint, with the school name over it. */
.photo-banner.aerial::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(180deg, rgba(12, 32, 62, .12) 0%, rgba(12, 32, 62, .30) 42%, rgba(12, 32, 62, .80) 100%); }
.photo-banner .photo-credit { z-index: 2; }
.photo-title { position: absolute; left: 1.1rem; right: 5.5rem; bottom: 1rem; z-index: 2; margin: 0; color: #fff; font-weight: 800; font-size: clamp(1.05rem, 2.4vw, 1.6rem); line-height: 1.15; letter-spacing: -.01em; text-shadow: 0 1px 12px rgba(0, 0, 0, .45); }
/* Designed banner (no photo): the Bellarmine blue, the school's state outline, and the Jesuit radiance. */
:root { --banner-a: #14325c; --banner-b: #1f5fae; }
:root[data-theme="dark"] { --banner-a: #0b1f3d; --banner-b: #174a8c; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --banner-a: #0b1f3d; --banner-b: #174a8c; } }
.photo-banner.designed { height: clamp(11rem, 30vw, 19rem); background: linear-gradient(120deg, var(--banner-a) 0%, var(--banner-b) 100%); }
.photo-banner.designed .designed-art { position: absolute; inset: 0; }
.designed-state { position: absolute; top: 9%; bottom: 9%; right: 7%; width: min(44%, 22rem); background: rgba(255, 255, 255, .17); -webkit-mask: var(--state-mask, none) center / contain no-repeat; mask: var(--state-mask, none) center / contain no-repeat; }
.designed-rays { position: absolute; left: -9%; top: 50%; width: min(52%, 26rem); aspect-ratio: 1; transform: translateY(-50%); background: rgba(255, 255, 255, .13); -webkit-mask: url(/img/mark.svg) center / contain no-repeat; mask: url(/img/mark.svg) center / contain no-repeat; }
.photo-banner.designed .photo-title { right: 1.1rem; max-width: 60%; }
.school-top { display: grid; gap: 1.5rem; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 56rem) { .school-top { grid-template-columns: minmax(0, 1fr) 19rem; gap: 2.5rem; } }
.school-top .eyebrow { margin-bottom: .35rem; }
.school-top h1 { margin: 0 0 .6rem; font-size: clamp(1.85rem, 4.4vw, 2.7rem); letter-spacing: -.035em; line-height: 1.1; }
.school-head .facts { display: grid; gap: .5rem; grid-template-columns: 1fr; margin: 1rem 0 0; padding: 0; list-style: none; }
@media (min-width: 40rem) { .school-head .facts { grid-template-columns: repeat(3, auto); justify-content: start; gap: .5rem 1.6rem; } }
.school-head .facts li { background: none; border-radius: 0; padding: 0; color: var(--text); font-size: .95rem; font-weight: 600; }
.school-head .facts .fact-k { display: block; font-size: .7rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--subtle); margin-bottom: .1rem; }
.school-head .facts a { font-weight: 600; }
.facts { display: flex; flex-wrap: wrap; gap: .35rem .5rem; color: var(--muted); font-size: .92rem; margin: 0; padding: 0; list-style: none; }
.facts li { background: var(--surface-2); border-radius: 999px; padding: .15rem .65rem; }
.school-head .head-actions { margin-top: 1rem; display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.score-panel { border: 1px solid var(--line); background: var(--bg); border-radius: var(--r-lg); padding: 1.25rem 1.2rem; box-shadow: var(--shadow); display: grid; gap: 1rem; justify-items: center; text-align: center; }
.score-panel.life { border-color: var(--teal-100); }
.score-panel .ring { width: 9rem; height: 9rem; }
.score-panel .ring-cap { font-size: .85rem; color: var(--ink); max-width: none; }
.score-panel .ring-wrap.life .ring-cap { color: var(--teal-ink); }
.score-panel .grades { display: flex; gap: .6rem; flex-wrap: wrap; justify-content: center; width: 100%; }
.score-panel .grades > div { flex: 1 1 8rem; border: 1px solid var(--line); border-radius: var(--r); padding: .6rem .7rem; display: flex; gap: .6rem; align-items: center; text-align: left; min-width: 0; }
.score-panel .grades .gl { font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--subtle); }
.score-panel .grades .gv { font-size: .92rem; font-weight: 700; color: var(--ink); }
.score-panel .weights { display: flex; gap: .35rem; flex-wrap: wrap; justify-content: center; }
.score-panel .meta-line { font-size: .8rem; color: var(--muted); }
.overall { display: flex; gap: .9rem; align-items: center; border: 1px solid var(--line); background: var(--bg); border-radius: var(--r); padding: .9rem 1rem; }
.overall .label { font-size: .72rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--subtle); }
.jump { position: sticky; top: 4.1rem; z-index: 20; background: var(--scrim); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); margin: 1.5rem -1rem 0; padding: 0 1rem; }
.jump ul { list-style: none; margin: 0; padding: 0; display: flex; gap: .1rem; overflow-x: auto; scrollbar-width: none; }
.jump ul::-webkit-scrollbar { display: none; }
.jump a { display: block; white-space: nowrap; padding: .8rem .7rem; font-size: .88rem; font-weight: 700; color: var(--muted); text-decoration: none !important; border-bottom: 2px solid transparent; }
.jump a:hover { color: var(--ink); border-bottom-color: var(--line-strong); }
.jump a[aria-current="true"] { color: var(--blue); border-bottom-color: var(--blue); }
/* Back to top: slides in once the reader is well down the page; sits above the fish band and maps. */
/* "Top" button (as on the sister sites): a rounded tile with a bold arrow over a blue "Top" band; slides up once you're down a page. */
.to-top { position: fixed; right: max(1rem, env(safe-area-inset-right)); bottom: calc(1.1rem + env(safe-area-inset-bottom)); z-index: 45; width: 3.5rem; padding: 0; min-height: 0; display: flex; flex-direction: column; align-items: stretch; overflow: hidden; cursor: pointer; font: inherit;
  border: 1.5px solid var(--blue-100); border-radius: 16px; background: var(--bg); color: var(--blue-700); box-shadow: 0 4px 0 var(--blue-100), 0 10px 24px -10px rgba(15, 31, 54, .35);
  opacity: 0; visibility: hidden; transform: translateY(18px) scale(.9); transition: opacity .18s ease, transform .22s cubic-bezier(.2, .9, .25, 1.2), visibility 0s linear .22s, box-shadow .12s ease; }
.to-top.show { opacity: 1; visibility: visible; transform: none; transition: opacity .18s ease, transform .22s cubic-bezier(.2, .9, .25, 1.2), visibility 0s, box-shadow .12s ease; }
.to-top .tt-i { display: flex; align-items: center; justify-content: center; height: 2.3rem; }
.to-top .tt-l { display: block; padding: .2rem 0 .3rem; background: var(--blue-50); border-top: 1.5px solid var(--blue-100); font-size: .75rem; font-weight: 800; letter-spacing: .02em; line-height: 1.2; text-align: center; }
.to-top:hover { border-color: var(--blue); }
.to-top:hover .tt-l { background: var(--blue-100); border-top-color: var(--blue); }
.to-top:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--blue-100); }
.to-top:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .to-top, .to-top.show { transition: none; transform: none; } }
.jump { background: var(--bg); }
.jump ul.x-r { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 48px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 48px), transparent); }
.jump ul.x-l { -webkit-mask-image: linear-gradient(90deg, transparent, #000 32px); mask-image: linear-gradient(90deg, transparent, #000 32px); }
.jump ul.x-l.x-r { -webkit-mask-image: linear-gradient(90deg, transparent, #000 32px, #000 calc(100% - 48px), transparent); mask-image: linear-gradient(90deg, transparent, #000 32px, #000 calc(100% - 48px), transparent); }
.jump .jump-n { display: inline-grid; place-items: center; min-width: 1.3rem; height: 1.3rem; padding: 0 .3rem; margin-left: .2rem; border-radius: 999px; background: var(--surface-2, #eef2f7); font-size: .72rem; font-weight: 800; color: var(--muted); }
.jump a[aria-current="true"] .jump-n { background: var(--blue-50); color: var(--blue); }
.best-group[id], .best-group h2[id] { scroll-margin-top: 8rem; }
@media print { .to-top { display: none !important; } }
@media (min-width: 48rem) { .jump { margin: 1.5rem -1.75rem 0; padding: 0 1.75rem; } }
.split { display: grid; gap: 1.25rem; grid-template-columns: 1fr; margin-top: 1.5rem; }
@media (min-width: 64rem) { .split { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.panels { display: grid; gap: 1.25rem; grid-template-columns: 1fr; margin-top: 1.5rem; }
@media (min-width: 64rem) { .panels { grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); } }
.panel { border: 1px solid var(--line); background: var(--bg); border-radius: var(--r-lg); padding: 1.25rem 1.3rem; box-shadow: var(--shadow-sm); min-width: 0; scroll-margin-top: 8rem; }
@media (min-width: 48rem) { .panel { padding: 1.5rem 1.65rem; } }
.panel > h2:first-child, .panel > .panel-title:first-child { margin-top: 0; }
.stack { display: grid; gap: 1.25rem; align-content: start; min-width: 0; }
.panel-title { display: flex; align-items: center; gap: .55rem; font-size: 1.15rem; font-weight: 800; letter-spacing: -.02em; color: var(--ink); margin: 0 0 1rem; }
.panel-title svg { width: 1.2rem; height: 1.2rem; color: var(--blue); flex: none; }
.panel-note { font-size: .9rem; color: var(--muted); margin: -.5rem 0 1rem; }

/* scorecard: plain-English indicators with a status mark */
.pillar { border-top: 1px solid var(--line); padding: 1.15rem 0; }
.pillar:first-of-type { border-top: 0; padding-top: .25rem; }
.pillar-head { display: flex; gap: .9rem; align-items: center; }
.pillar-head h3 { margin: 0; font-size: 1.06rem; }
.pillar-head p { margin: .1rem 0 0; color: var(--muted); font-size: .88rem; }
.pillar-bar { height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; margin-top: .45rem; max-width: 16rem; }
.pillar-bar i { display: block; height: 100%; background: var(--blue); border-radius: inherit; }
.life .pillar-bar i { background: var(--teal); }
.checklist { list-style: none; margin: .9rem 0 0; padding: 0; }
.checklist > li { display: grid; grid-template-columns: 1.6rem 1fr; gap: .15rem .7rem; padding: .7rem 0; border-top: 1px solid var(--line); font-size: .95rem; }
.checklist > li:first-child { border-top: 0; }
.checklist .mk { width: 1.45rem; height: 1.45rem; border-radius: 50%; display: grid; place-items: center; margin-top: .05rem; }
.checklist .mk svg { width: .95rem; height: .95rem; }
.checklist .mk.yes { background: var(--blue-50); color: var(--blue); }
.checklist .mk.part { background: var(--surface-2); color: var(--ink); border: 1px dashed var(--line-strong); }
.checklist .mk.no { background: transparent; color: var(--subtle); border: 1px solid var(--line-strong); }
.checklist .mk.unk { background: transparent; color: var(--subtle); border: 1px dotted var(--line-strong); font-size: .8rem; font-weight: 700; }
.checklist .q { color: var(--ink); font-weight: 600; line-height: 1.4; }
.checklist .a { display: block; color: var(--muted); font-weight: 500; font-size: .92rem; margin-top: .1rem; }
.checklist .unknown .q { color: var(--muted); font-weight: 500; }
.checklist .pts-line { font-size: .78rem; color: var(--subtle); font-weight: 600; margin-left: .35rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.checklist .nei-line { color: var(--subtle); font-style: italic; font-size: .9rem; margin-top: .1rem; display: block; }

details.sources, details.evidence { margin-top: .4rem; }
details.sources > summary, details.evidence > summary, details.ind-toggle > summary, details.more > summary, details.research > summary {
  cursor: pointer; list-style: none; display: inline-flex; align-items: center; gap: .35rem; color: var(--blue); font-weight: 700; font-size: .86rem; padding: .3rem 0;
}
details.sources > summary::-webkit-details-marker, details.evidence > summary::-webkit-details-marker, details.ind-toggle > summary::-webkit-details-marker, details.more > summary::-webkit-details-marker, details.research > summary::-webkit-details-marker { display: none; }
details.sources > summary::before, details.evidence > summary::before, details.ind-toggle > summary::before, details.more > summary::before, details.research > summary::before { content: "›"; display: inline-block; font-size: 1.1rem; line-height: 1; transition: transform .15s; }
details.sources[open] > summary::before, details.evidence[open] > summary::before, details.ind-toggle[open] > summary::before, details.more[open] > summary::before, details.research[open] > summary::before { transform: rotate(90deg); }
details.sources > ol { margin: .5rem 0 0; padding: 0; list-style: none; display: grid; gap: .6rem; }
details.sources > ol > li { padding: .6rem .75rem; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); font-size: .88rem; }
details.sources .src-title { display: block; font-weight: 700; color: var(--ink); line-height: 1.35; }
details.sources .src-host { display: block; font-size: .78rem; color: var(--subtle); word-break: break-all; }
blockquote.quote { margin: .5rem 0 0; padding: .45rem .75rem; border-left: 3px solid var(--blue-100); font-size: .87rem; color: var(--text); }
blockquote.quote footer { font-size: .78rem; color: var(--subtle); margin-top: .25rem; }
.notes { list-style: none; padding: 0; margin: 0; }
.notes li { padding: .55rem 0 .55rem 1.8rem; position: relative; border-bottom: 1px solid var(--line); font-size: .95rem; }
.notes li:last-child { border-bottom: 0; }
.notes.strengths li::before, .notes.concerns li::before { position: absolute; left: 0; top: .72rem; width: 1.15rem; height: 1.15rem; border-radius: 50%; display: grid; place-items: center; font-size: .8rem; font-weight: 800; line-height: 1; }
.notes.strengths li::before { content: "+"; background: var(--blue-50); color: var(--blue); }
.notes.concerns li::before { content: "−"; background: var(--surface-2); color: var(--muted); }
.notes .src { font-size: .8rem; }
.research { margin-top: 1.25rem; border-top: 1px solid var(--line); padding-top: .75rem; }
.research > summary { font-size: .95rem; }
.research .research-body { font-size: .9rem; color: var(--muted); padding-top: .4rem; }
.research .research-body ul { list-style: none; padding: 0; margin: .6rem 0 0; font-size: .85rem; }
.research .research-body li { padding: .35rem 0; border-bottom: 1px solid var(--line); }

.value-table { width: 100%; border-collapse: collapse; font-size: .93rem; }
.value-table th, .value-table td { padding: .65rem .25rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.value-table tr:last-child th, .value-table tr:last-child td { border-bottom: 0; }
.value-table th { font-weight: 600; color: var(--ink); }
.value-table td { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 700; color: var(--ink); }
.value-table th { overflow-wrap: anywhere; }
.metric-rows { list-style: none; margin: 0; padding: 0; }
.metric-rows li { display: grid; grid-template-columns: 1fr auto; gap: .25rem .75rem; padding: .75rem 0; border-bottom: 1px solid var(--line); font-size: .92rem; }
.metric-rows li:last-child { border-bottom: 0; }
.metric-rows .lbl { font-weight: 600; color: var(--ink); display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
.metric-rows .val { font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; text-align: right; }
.metric-rows .bar { grid-column: 1 / -1; height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.metric-rows .bar i { display: block; height: 100%; background: var(--blue); border-radius: inherit; }
.metric-rows .na { color: var(--subtle); font-weight: 500; font-style: italic; }
.metric-rows .sr { font-size: .8rem; color: var(--muted); }
.schedule { width: 100%; border-collapse: collapse; font-size: .92rem; }
.schedule th, .schedule td { text-align: left; padding: .6rem .4rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.schedule thead th { font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--subtle); }
.schedule tbody th { font-weight: 700; color: var(--ink); }
.confirm { display: inline-flex; align-items: center; gap: .35rem; font-size: .8rem; font-weight: 700; color: var(--gold-ink); background: var(--gold-50); border: 1px solid var(--gold-line); border-radius: 999px; padding: .2rem .7rem; }
.notice { border: 1px solid var(--line); background: var(--surface); border-radius: var(--r); padding: .95rem 1.1rem; margin: 1rem 0; color: var(--text); }
.notice.nei { border-style: dashed; border-color: var(--line-strong); }
.facts-list { list-style: none; margin: 0 0 .5rem; padding: 0; }
.facts-list li { padding: .5rem 0; border-bottom: 1px solid var(--line); font-size: .93rem; }
.facts-list li:last-child { border-bottom: 0; }
.activity-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.activity-list li { padding: .75rem .9rem; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--surface); font-size: .93rem; }
.contact { padding: .7rem 0; border-bottom: 1px solid var(--line); }
.contact:last-of-type { border-bottom: 0; }
.contact.main { background: var(--blue-50); border: 1px solid var(--blue-100); border-radius: var(--r-sm); padding: .8rem .9rem; margin-bottom: .5rem; }
.social-links { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .75rem; }
.email-template { margin-top: .75rem; }
.email-template textarea { font-size: .9rem; min-height: 14rem; }

/* ------------------------------------------------------------- tables */
.table-wrap { position: relative; overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg); box-shadow: var(--shadow-sm); }
table.data { width: 100%; border-collapse: collapse; font-size: .9rem; }
table.data th, table.data td { padding: .7rem .85rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
table.data tbody tr:last-child th, table.data tbody tr:last-child td { border-bottom: 0; }
table.data thead th { font-size: .72rem; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--subtle); background: var(--surface); white-space: nowrap; }
table.data td.num, table.data th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.data tbody tr:hover { background: var(--surface); }
table.data a { font-weight: 700; }
.compare { table-layout: fixed; min-width: 40rem; }
.compare th[scope="row"] { width: 11rem; font-weight: 700; background: var(--surface); }
.compare td { vertical-align: top; }

/* ------------------------------------------------------------- maps */
.map-frame { position: relative; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface); overflow: hidden; box-shadow: var(--shadow-sm); }
.map-frame svg { display: block; width: 100%; height: auto; touch-action: manipulation; }
.map-frame circle { stroke: var(--bg); stroke-width: .8; cursor: pointer; }
.map-frame a:focus circle, .map-frame a:hover circle { stroke: var(--ink); stroke-width: 2; }
.legend { display: flex; flex-wrap: wrap; gap: .4rem 1rem; font-size: .86rem; margin: .75rem 0; align-items: center; color: var(--muted); }
.legend .dot { display: inline-block; width: .75rem; height: .75rem; border-radius: 50%; vertical-align: middle; margin-right: .35rem; box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px var(--line-strong); }
.maptip { position: absolute; pointer-events: none; background: var(--ink); color: var(--bg); font-size: .8rem; padding: .35rem .6rem; border-radius: var(--r-sm); max-width: 16rem; z-index: 2; box-shadow: var(--shadow); }

/* US choropleth and single-state outline maps (server-rendered SVG, see src/views/state-maps.tsx) */
.geomap { margin: 1.25rem 0 1.75rem; }
.geomap-frame { position: relative; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); padding: .6rem; box-shadow: var(--shadow-sm); }
.geomap svg { display: block; width: 100%; height: auto; }
.geomap .st { fill: var(--q0); stroke: var(--bg); stroke-width: .9; stroke-linejoin: round; transition: fill .2s, stroke .2s; }
.geomap .st.q1 { fill: var(--q1); } .geomap .st.q2 { fill: var(--q2); } .geomap .st.q3 { fill: var(--q3); }
.geomap .st.q4 { fill: var(--q4); } .geomap .st.q5 { fill: var(--q5); }
.geomap .st.q0 { fill: var(--q0); stroke: var(--line-strong); stroke-width: .6; }
.geomap a { outline: none; cursor: pointer; }
/* Hover and focus: the state lifts (scale about its own center, soft shadow, accent outline), the rest fade. */
.geomap .st { transform-box: fill-box; transform-origin: center; transition: transform .22s cubic-bezier(.2, .7, .2, 1), opacity .22s ease, filter .22s ease, stroke .2s ease; }
.geomap-frame.has-lift a:not(.is-lift) .st { opacity: .5; }
.geomap a.is-lift .st { transform: scale(1.045); filter: drop-shadow(0 6px 10px rgba(15, 31, 54, .28)); stroke: var(--blue); stroke-width: 2; }
/* Intro: states ripple in from the center once (JS adds .ripple, then .in, then .settled). */
.geomap-frame.ripple .st { opacity: 0; transform: scale(.94); }
.geomap-frame.ripple.in .st { opacity: 1; transform: none; transition: opacity .45s ease var(--rd, 0ms), transform .45s cubic-bezier(.2, .7, .2, 1) var(--rd, 0ms); }
.geomap-frame.ripple.settled .st { transition: transform .22s cubic-bezier(.2, .7, .2, 1), opacity .22s ease, filter .22s ease, stroke .2s ease; }
/* Tooltip card that follows the pointer or sits at the focused item. */
.geomap-frame { overflow: visible; }
.map-tip { position: absolute; left: 0; top: 0; z-index: 6; width: min(17rem, calc(100% - 1rem)); padding: .7rem .85rem .75rem; border-radius: .8rem; border: 1px solid var(--line); background: var(--bg); color: var(--ink); box-shadow: var(--shadow-lg); font-size: .84rem; line-height: 1.35; opacity: 0; pointer-events: none; transition: opacity .16s ease; }
.map-tip.show { opacity: 1; }
.map-tip.touch { pointer-events: auto; }
.map-tip .mt-title { display: block; font-size: .98rem; font-weight: 800; letter-spacing: -.01em; }
.map-tip .mt-sub { display: block; color: var(--muted); font-weight: 600; margin-top: .1rem; }
.map-tip .mt-top { display: flex; align-items: center; gap: .55rem; margin-top: .55rem; padding-top: .55rem; border-top: 1px solid var(--line); }
.geomap .map-tip .mt-top svg { flex: none; width: 26px; height: 26px; }
.map-tip .mt-track { stroke: var(--line); }
.map-tip .mt-arc { stroke: var(--blue); }
.map-tip .mt-arc.life { stroke: var(--teal); }
.map-tip .mt-words { font-size: .8rem; color: var(--muted); font-weight: 600; min-width: 0; }
.map-tip .mt-words b.mt-score { color: var(--ink); font-size: .95rem; margin-left: .15rem; }
.map-tip .mt-words b.mt-score.life { color: var(--teal-ink); }
.map-tip .mt-cta { display: inline-block; margin-top: .6rem; font-weight: 700; font-size: .84rem; color: var(--blue); text-decoration: none; }
.map-tip .mt-cta:hover { text-decoration: underline; }
.map-tip .mt-cta:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.map-tip.touch .mt-cta { padding: .35rem 0; }
/* Dots: grow with a pulse ring on hover or focus; the rest fade a little. */
.state-dots .halo { fill: var(--blue); opacity: 0; transform-box: fill-box; transform-origin: center; }
.state-dots .dot.life ~ .halo, .state-dots a:has(.dot.life) .halo { fill: var(--teal); }
.state-dots .dot, .state-dots .halo { transition: transform .2s cubic-bezier(.2, .7, .2, 1), opacity .2s ease; }
.state-dots .dot { transform-box: fill-box; transform-origin: center; }
.state-dots .geomap-frame.has-lift a:not(.is-lift) .dot { opacity: .6; }
.state-dots a.is-lift .dot { transform: scale(1.35); }
.state-dots a.is-lift .halo { animation: dot-pulse 1.6s ease-out infinite; }
@keyframes dot-pulse { 0% { opacity: .45; transform: scale(1); } 100% { opacity: 0; transform: scale(1.9); } }
@media (prefers-reduced-motion: reduce) {
  .geomap .st, .state-dots .dot, .state-dots .halo, .map-tip { transition: none !important; }
  .geomap-frame.ripple .st { opacity: 1; transform: none; }
  .geomap a.is-lift .st, .state-dots a.is-lift .dot { transform: none; }
  .state-dots a.is-lift .halo { animation: none; opacity: .35; transform: scale(1.4); }
}
.geomap a:hover .st, .geomap a:focus-visible .st { stroke: var(--ink); stroke-width: 2; paint-order: stroke; }
.geomap a:focus-visible { outline: none; }
.geomap a:focus-visible .st { stroke: var(--focus); stroke-width: 3; }
.geomap .st-label { font: 800 15px var(--sans); fill: var(--ink); pointer-events: none; text-anchor: middle; }
.geomap .st-label.light { fill: #fff; }
.geomap-readout { min-height: 1.6rem; margin: .6rem .15rem 0; font-size: .95rem; color: var(--ink); font-weight: 700; }
.geomap-readout span { color: var(--muted); font-weight: 600; }
.geomap-legend { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin: .5rem .15rem 0; font-size: .8rem; color: var(--muted); font-weight: 600; }
.geomap-legend .ramp { display: inline-flex; border-radius: 6px; overflow: hidden; border: 1px solid var(--line); }
.geomap-legend .ramp i { display: block; width: 1.9rem; height: .7rem; }
.geomap-legend .note { color: var(--subtle); font-weight: 500; }
.geomap-legend a { margin-left: auto; }
/* single-state outline with dots */
.state-dots .outline { fill: var(--surface-2); stroke: var(--line-strong); stroke-width: .8; stroke-linejoin: round; }
.state-dots .dot { fill: var(--blue); stroke: var(--bg); stroke-width: 2px; }
.state-dots .dot.life { fill: var(--teal); }
.state-dots .dot.nr { fill: var(--bg); stroke: var(--subtle); stroke-width: 1.5px; }
.state-dots a { cursor: pointer; }
.state-dots a:hover .dot, .state-dots a:focus-visible .dot { stroke: var(--ink); stroke-width: 3px; }
.state-dots a:focus-visible { outline: none; }
.state-dots a:focus-visible .dot { stroke: var(--focus); stroke-width: 3.5px; }
.state-dots .dot-label { font: 700 11px var(--sans); fill: var(--ink); pointer-events: none; }
.state-dots .outline-title { font: 800 13px var(--sans); fill: var(--muted); letter-spacing: .04em; }
.geomap .readout-dot { display: inline-block; width: .7rem; height: .7rem; border-radius: 50%; margin-right: .35rem; vertical-align: -1px; background: var(--blue); }
.geomap .readout-dot.life { background: var(--teal); }

/* ------------------------------------------------------------- misc */
.breadcrumbs { font-size: .84rem; margin: 0 0 .9rem; color: var(--subtle); }
.breadcrumbs ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .3rem; }
.breadcrumbs li + li::before { content: "/"; margin-right: .3rem; color: var(--line-strong); }
.breadcrumbs a { color: var(--muted); text-decoration: none !important; }
.breadcrumbs a:hover { color: var(--blue); }
.pagination { display: flex; gap: .75rem; justify-content: center; align-items: center; margin: 2rem 0 0; flex-wrap: wrap; }
.toc { border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); padding: 1rem 1.2rem; }
.toc ol { margin: .35rem 0 0; }
.compare-tray { position: fixed; left: 50%; bottom: 1rem; transform: translateX(-50%); width: min(44rem, calc(100% - 2rem)); background: var(--ink); color: var(--bg); padding: .6rem .75rem .6rem 1.1rem; display: none; gap: .75rem; align-items: center; justify-content: space-between; flex-wrap: wrap; z-index: 40; font-size: .9rem; border-radius: 999px; box-shadow: var(--shadow-lg); }
.compare-tray.show { display: flex; }
.compare-tray a { color: var(--bg); font-weight: 700; }
.compare-tray button { background: rgba(255, 255, 255, .14); border-color: transparent; box-shadow: none; min-height: 2rem; padding: .2rem .7rem; font-size: .8rem; color: var(--bg); }
.compare-tray .btn { background: var(--bg); color: var(--ink); border-color: var(--bg); min-height: 2.2rem; text-decoration: none; }
.badge-preview { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; }
.review { border-top: 1px solid var(--line); padding: 1rem 0; }
.review h4 { margin: 0 0 .2rem; }
.stars { color: var(--gold-ink); letter-spacing: .1em; }
.flash { border: 1px solid var(--blue-100); background: var(--blue-50); border-radius: var(--r); padding: .8rem 1rem; margin: 1rem 0; color: var(--ink); }
.flash.ok { border-color: var(--teal-100); background: var(--teal-50); color: var(--ink); }
.page-head { margin-bottom: 1.75rem; }
.page-head h1 { margin-bottom: .4rem; }
.empty { text-align: center; padding: 2.75rem 1rem; border: 1px dashed var(--line-strong); border-radius: var(--r-lg); color: var(--muted); }
.cta-band { border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--line); color: var(--text); padding: 1.75rem; display: flex; gap: 1rem; align-items: center; justify-content: space-between; flex-wrap: wrap; margin: 2.5rem 0; }
.cta-band h2 { color: var(--ink); margin: 0 0 .25rem; font-size: 1.3rem; }
.cta-band p { margin: 0; color: var(--muted); }
.count { display: inline-grid; place-items: center; min-width: 1.5rem; height: 1.3rem; padding: 0 .4rem; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: .72rem; font-weight: 700; vertical-align: middle; margin-left: .25rem; }
.sched-group h3, .act-group h3 { font-size: .98rem; margin: 1.1rem 0 .5rem; }
.sched-group:first-of-type h3 { margin-top: .5rem; }
.sched-list { list-style: none; margin: 0; padding: 0; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.sched-list li { display: grid; grid-template-columns: 1fr; gap: .15rem; padding: .7rem .9rem; border-bottom: 1px solid var(--line); font-size: .93rem; }
.sched-list li:last-child { border-bottom: 0; }
.sched-list .when { display: flex; gap: .5rem; flex-wrap: wrap; align-items: baseline; }
.sched-list .when b { color: var(--ink); font-weight: 700; }
.sched-list .when span { font-variant-numeric: tabular-nums; color: var(--blue); font-weight: 700; }
@media (min-width: 40rem) { .sched-list li { grid-template-columns: 15rem 1fr; } }
details.more { margin-top: .5rem; }
details.more[open] > ul { margin-top: .5rem; }
details.ind-toggle { margin: .4rem 0 0; }
.activity-list { grid-template-columns: 1fr; }
@media (min-width: 48rem) { .activity-list { grid-template-columns: 1fr 1fr; } }
.activity-list li { display: grid; gap: .2rem; align-content: start; }
.activity-list .act-head { display: flex; justify-content: space-between; gap: .5rem; align-items: start; }
.activity-list .act-head b { color: var(--ink); font-weight: 700; line-height: 1.35; }
.activity-list .src { color: var(--subtle); }

/* share: a compact group, "Share" · "Copy link" · "More" (networks in a disclosure) */
.share { display: flex; flex-wrap: wrap; gap: .45rem .6rem; align-items: center; margin: .9rem 0 0; }
.share-label { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--subtle); }
.share-group { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; }
.share-btn { display: inline-flex; align-items: center; gap: .35rem; height: 2.1rem; padding: 0 .75rem; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink); font: inherit; font-size: .84rem; font-weight: 600; text-decoration: none !important; cursor: pointer; box-shadow: none; min-height: 0; list-style: none; }
.share-btn:hover { border-color: var(--subtle); background: var(--surface-2); color: var(--ink); }
.share-btn svg { flex: none; }
.share-btn.primary { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.share-btn.primary:hover { color: var(--bg); opacity: .92; }
.share-btn.copied { border-color: var(--teal-100); background: var(--teal-50); color: var(--teal-ink); }
.share-more { position: relative; }
.share-more > summary { cursor: pointer; }
.share-more > summary::-webkit-details-marker { display: none; }
.share-more > summary svg { transition: transform .15s ease; }
.share-more[open] > summary svg { transform: rotate(180deg); }
.share-more[open] { flex-basis: 100%; }
.share-nets { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .5rem; }
.share-net { display: inline-flex; align-items: center; gap: .35rem; height: 2rem; padding: 0 .65rem; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink) !important; font-size: .8rem; font-weight: 600; text-decoration: none !important; }
.share-net:hover { border-color: var(--subtle); background: var(--surface-2); }
.share-net svg { flex: none; }
.share-net.mobile-only { display: none; }
@media (pointer: coarse) { .share-net.mobile-only { display: inline-flex; } }

/* landing pages */
.state-grid { display: grid; gap: .6rem; grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr)); margin: 1.5rem 0; }
.state-card { display: grid; gap: .1rem; padding: .85rem 1rem; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg); text-decoration: none !important; color: var(--ink); box-shadow: var(--shadow-sm); transition: border-color .15s, box-shadow .15s; }
.state-card:hover { border-color: var(--line-strong); box-shadow: var(--shadow); }
.state-card b { font-weight: 700; }
.state-card span { font-size: .84rem; color: var(--muted); }
.qa { max-width: 48rem; }
.qa h3 { margin: 1.25rem 0 .35rem; font-size: 1.02rem; }
.consent { position: fixed; left: 1rem; right: 1rem; bottom: 1rem; z-index: 45; max-width: 34rem; margin: 0 auto; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow-lg); padding: .9rem 1rem; display: flex; gap: .75rem; align-items: center; justify-content: space-between; flex-wrap: wrap; font-size: .9rem; color: var(--text); }
.consent p { margin: 0; flex: 1 1 16rem; }
.consent[hidden] { display: none; }

/* Nearby map (school page): MapLibre street map or the drawn fallback. Blue campus, gold center, numbered churches. */
.nearmap { margin: 0 0 1rem; }
.nm-stage { position: relative; aspect-ratio: 4 / 3; min-height: 16rem; border-radius: var(--r); box-shadow: var(--shadow-sm); overflow: hidden; border: 1px solid var(--line); }
.nearmap svg { width: 100%; height: 100%; display: block; }
.nm-stage .nm-map.maplibregl-map { position: absolute; inset: 0; width: 100%; height: 100%; background: var(--surface); }
.nm-map .maplibregl-ctrl-attrib { font-size: 10px; max-width: 100%; }
.nm-map .maplibregl-ctrl-attrib-button { width: 22px; height: 22px; }
@media (max-width: 40rem) { .nm-map .maplibregl-ctrl-attrib-inner { font-size: 9px; } }
.nm-stage .nm-mk { box-sizing: border-box; width: 1.8rem; min-width: 0; height: 1.8rem; min-height: 0; max-width: none; border-radius: 50%; border: 2px solid var(--ink); background: var(--bg); color: var(--ink); font: 800 12px/1 var(--sans); display: grid; place-items: center; padding: 0; margin: 0; cursor: pointer; box-shadow: 0 0 0 1px rgba(15, 31, 54, .25), 0 2px 6px rgba(15, 31, 54, .45); }
.nm-stage .nm-mk:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.nm-stage .nm-mk-campus { width: 1.5rem; height: 1.5rem; background: var(--blue); border: 3px solid var(--bg); }
.nm-stage .nm-mk-center { background: var(--gold); border: 3px solid var(--bg); }
.nm-stage .nm-mk-center svg { width: 60%; height: 60%; fill: none; stroke: #fff; stroke-width: 3; stroke-linecap: round; }
.nm-pop .maplibregl-popup-content { font: 14px/1.4 var(--sans); color: var(--ink); background: var(--bg); border-radius: var(--r); padding: .7rem .9rem; box-shadow: var(--shadow-lg); }
.nm-pop-title { display: block; font-size: 15px; font-weight: 700; }
.nm-pop-dist { color: var(--muted); font-weight: 600; }
.nm-pop-addr { color: var(--muted); font-size: 13px; }
.nm-pop a { font-size: 13px; }
.nm-bg { fill: var(--surface); stroke: var(--line); }
.nm-gridline { fill: none; stroke: var(--line); stroke-width: 1; opacity: .55; }
.nm-glow-in { stop-color: var(--blue-50); stop-opacity: .9; }
.nm-glow-out { stop-color: var(--surface); stop-opacity: 0; }
.nm-ring { fill: none; stroke: var(--line-strong); stroke-dasharray: 4 6; }
.nm-ringlabel { font: 700 12px var(--sans); fill: var(--subtle); }
.nm-link { stroke: var(--gold); stroke-width: 2; stroke-dasharray: 2 5; stroke-linecap: round; }
.nm-church circle { fill: var(--bg); stroke: var(--ink); stroke-width: 2; }
.nm-church text { font: 800 12px var(--sans); fill: var(--ink); text-anchor: middle; }
.nm-center circle { fill: var(--gold); stroke: var(--bg); stroke-width: 3; }
.nm-center path { stroke: #fff; stroke-width: 2.5; stroke-linecap: round; fill: none; }
.nm-campus circle { fill: var(--blue); stroke: var(--bg); stroke-width: 3; }
.nm-campus .nm-pulse { fill: var(--blue); opacity: .16; stroke: none; }
.nm-campus path { fill: none; stroke: var(--bg); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.nm-north path { fill: var(--muted); }
.nm-north text { font: 800 10px var(--sans); fill: var(--muted); text-anchor: middle; }
.nm-scale path { stroke: var(--muted); stroke-width: 2; fill: none; }
.nm-scale text { font: 700 11px var(--sans); fill: var(--muted); }
.nm-legend { display: flex; flex-wrap: wrap; gap: .4rem 1rem; align-items: center; margin-top: .65rem; color: var(--muted); font-size: .88rem; }
.nm-legend i { display: inline-block; width: .8rem; height: .8rem; border-radius: 50%; margin-right: .35rem; vertical-align: -1px; }
.nm-legend .k-campus { background: var(--blue); }
.nm-legend .k-center { background: var(--gold); }
.nm-legend .k-church { background: var(--bg); border: 2px solid var(--ink); }
.nm-legend a { margin-left: auto; }
@media (min-width: 40rem) { .nm-stage { aspect-ratio: 3 / 2; } }
.nm-list { padding-left: 1.4rem; }
@media (prefers-reduced-motion: no-preference) {
  .nm-campus .nm-pulse { animation: nm-pulse 2.4s ease-out infinite; transform-origin: center; transform-box: fill-box; }
  @keyframes nm-pulse { 0% { transform: scale(.6); opacity: .3; } 100% { transform: scale(1.6); opacity: 0; } }
}

/* auth */
.auth-card { max-width: 28rem; margin: 1rem auto 0; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 1.9rem 1.6rem; box-shadow: var(--shadow); }
.auth-card .auth-seal { display: block; margin-bottom: .75rem; color: var(--blue); }
.auth-card .auth-seal svg { width: 3.2rem; height: 3.2rem; }
.auth-card h1 { font-size: 1.75rem; margin: 0 0 .75rem; }
.auth-card .lede { font-size: 1rem; }
.auth-card button[type="submit"] { width: 100%; }

/* Easter egg and deep end (public pages only; see public/js/amdg.js and public/js/deep-end.js) */
.logo-sheen { position: fixed; left: var(--sheen-x, 2rem); top: var(--sheen-y, 2rem); width: 1px; height: 1px; pointer-events: none; z-index: 70; }
.logo-sheen::after { content: ""; position: absolute; left: -50vmax; top: -50vmax; width: 100vmax; height: 100vmax; border-radius: 50%; background: radial-gradient(circle, rgba(216, 180, 106, .0) 0%, rgba(216, 180, 106, 0) 30%, rgba(216, 180, 106, .28) 36%, rgba(216, 180, 106, 0) 46%); opacity: 0; transform: scale(.04); transform-origin: center; }
.logo-sheen.run::after { animation: sheen 1.5s cubic-bezier(.2, .7, .2, 1) forwards; }
@keyframes sheen { 0% { opacity: .95; transform: scale(.04); } 100% { opacity: 0; transform: scale(1); } }
.brand.amdg .mark { color: var(--gold); animation: amdg-spin 1.1s cubic-bezier(.3, .6, .25, 1); filter: drop-shadow(0 0 6px rgba(216, 180, 106, .55)); }
.brand.amdg .mark .rays { transform-origin: 32px 32px; }
@keyframes amdg-spin { from { transform: rotate(0); } to { transform: rotate(360deg); } }
.amdg-toast { position: fixed; left: 50%; bottom: 5.5rem; transform: translateX(-50%); width: min(30rem, calc(100% - 2rem)); background: var(--ink); color: var(--bg); border-radius: var(--r); padding: .9rem 1.1rem; box-shadow: var(--shadow-lg); z-index: 75; pointer-events: none; font-size: .92rem; line-height: 1.5; opacity: 0; transition: opacity .6s ease; }
.amdg-toast.show { opacity: 1; }
.amdg-toast b { color: var(--gold); font-weight: 800; letter-spacing: .02em; }
.amdg-toast i { font-family: var(--serif); font-size: .98rem; }
.deep-end { position: relative; overflow: hidden; height: 10rem; background: var(--surface); border-top: 1px solid var(--line); color: var(--muted); }
@media (min-width: 64rem) { .deep-end { height: 9rem; } }
.deep-end .de-words { position: absolute; left: 0; right: 0; bottom: 1.1rem; text-align: center; font-family: var(--serif); font-style: italic; font-size: 1.02rem; color: var(--muted); letter-spacing: .01em; padding: 0 1rem; z-index: 1; }
.deep-end-wrap { border-top: 0; }
/* Footer: "Designed with a heart in Colorado". The heart beats gently; the peak is a button that raises a sunrise. */
.made-with { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .4rem; margin: 1.6rem 0 0; padding-top: 1.1rem; border-top: 1px solid var(--line); font-family: var(--sans); font-size: .86rem; font-weight: 600; letter-spacing: .01em; color: var(--muted); text-align: center; }
.made-with .co-peak { display: inline-flex; align-items: center; min-height: 0; min-width: 0; margin: 0 .15rem; padding: 3px 4px; background: none; border: 0; border-radius: 8px; box-shadow: none; color: inherit; cursor: pointer; line-height: 0; -webkit-tap-highlight-color: transparent; }
.made-with .co-peak:hover, .made-with .co-peak:active { background: none; border-color: transparent; color: inherit; transform: none; }
.made-with .co-peak:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.co-mtn { display: block; overflow: visible; }
.co-range { fill: var(--blue); }
.co-sun { fill: var(--gold-fill); transform: translateY(12px); transition: transform 1.8s cubic-bezier(.2, .7, .2, 1); }
.co-cross { fill: none; stroke: var(--gold); stroke-width: 1.5; stroke-linecap: round; opacity: 0; transition: opacity .8s ease .9s; }
.co-peak.is-on .co-sun { transform: translateY(0); }
.co-peak.is-on .co-cross { opacity: 1; }
.co-heart { display: inline-block; flex: none; fill: #c8423b; transform-origin: 50% 60%; animation: co-beat 2.6s ease-in-out infinite; }
@keyframes co-beat { 0%, 60%, 100% { transform: scale(1); } 10% { transform: scale(1.2); } 20% { transform: scale(.95); } 30% { transform: scale(1.12); } }
.co-toast { position: fixed; left: 50%; bottom: 5.5rem; transform: translateX(-50%); width: min(30rem, calc(100% - 2rem)); background: #0f1f36; color: #f4f7fb; border-radius: var(--r); padding: .9rem 1.1rem; box-shadow: var(--shadow-lg); z-index: 75; pointer-events: none; font-size: .92rem; line-height: 1.5; text-align: center; opacity: 0; transition: opacity .6s ease; }
.co-toast.show { opacity: 1; }
.co-toast cite { display: block; margin-top: .25rem; font-style: normal; font-size: .8rem; font-weight: 700; letter-spacing: .04em; color: #d8b46a; }

/* ------------------------------------------------------------- print & motion */
@media print {
  .masthead, .section-bar, .jump, .colophon, .compare-tray, .actions, .fpanel, .mtoolbar, .fbar, .achips, .sortsheet, .head-actions, .deep-end, .share, .consent { display: none !important; }
  .panel, .card, .result { box-shadow: none; break-inside: avoid; }
  a { color: inherit; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .brand.amdg .mark { animation: none; }
  .logo-sheen.run::after { animation: none; opacity: 0; }
}
@media (forced-colors: active) { .grade, .ring .value { forced-color-adjust: none; } }
.result .pillar-mini { display: inline-flex; gap: .2rem; }

/* small screens */
@media (max-width: 34.99rem) {
  .brand-name { font-size: 1.02rem; }
  .masthead .wrap { gap: .5rem; }
  .search-first { padding-top: 1.5rem; }
  .search-first h1 { font-size: 2.05rem; }
  .sheet { padding-top: 1.1rem; }
}
@media (max-width: 39.99rem) {
  .scoreboard { grid-template-columns: 1fr 1fr; }
  .scoreboard .score-card.primary { grid-column: 1 / -1; }
  .scoreboard .score-card:not(.primary) { flex-direction: column; align-items: flex-start; gap: .6rem; padding: .9rem; }
  .scoreboard .score-card:not(.primary) .grade.lg { width: 3rem; height: 3rem; font-size: 1.4rem; border-radius: 12px; }
  .school-cards .school-card .ring { width: 3.8rem; height: 3.8rem; }
}
.scoreboard-sm { display: none; }
.geomap-frame { padding: .4rem; }
@media (max-width: 39.99rem) { .geomap-legend a { margin-left: 0; } .geomap .st-label { font-size: 22px; } }

/* ------------------------------------------------------------- admin (shared with the admin shell) */
/* ------------------------------------------------------------- admin */
.admin-tabs { display: flex; flex-wrap: wrap; gap: .3rem; background: var(--surface-2); border-radius: var(--r); padding: .3rem; margin: 0 0 1.5rem; }
.admin-tabs a { font-size: .84rem; font-weight: 600; text-decoration: none !important; color: var(--muted); padding: .45rem .8rem; border-radius: var(--r-sm); }
.admin-tabs a:hover { color: var(--ink); background: rgba(255, 255, 255, .6); }
.admin-tabs a[aria-current="page"] { background: #fff; color: var(--ink); box-shadow: var(--shadow-sm); }
.admin-tabs .sep { width: 1px; align-self: stretch; margin: .3rem .2rem; background: var(--line-strong); flex: none; }
@media (max-width: 48rem) {
  .admin-tabs { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
  .admin-tabs::-webkit-scrollbar { display: none; }
  .admin-tabs a { white-space: nowrap; flex: none; }
}
.chart { margin: 0 0 1.5rem; }
.chart figcaption { margin-bottom: .4rem; font-weight: 600; }
.chart svg { width: 100%; height: auto; display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--r); }
.chart .grid { stroke: var(--line); stroke-width: 1; }
.chart .baseline { stroke: var(--line-strong); stroke-width: 1; }
.chart .axis { font: 11px var(--sans); fill: var(--subtle); }
.chart .mark { fill: var(--blue); }
.chart .hit { fill: transparent; }
.chart .bar:hover .mark { fill: var(--blue-700); }
.chart .bar:hover .hit { fill: rgba(28, 25, 23, .04); }
.coverage { list-style: none; padding: 0; }
.coverage li { display: grid; grid-template-columns: 11rem 1fr auto; gap: .75rem; align-items: center; margin: .5rem 0; font-size: .9rem; }
.coverage progress { width: 100%; height: .5rem; accent-color: var(--blue); }
@media (max-width: 40rem) { .coverage li { grid-template-columns: 1fr; } }

/* admin: site care (Today, Suggestions, SEO, Quality, Backups) */
form.inline { display: inline-flex; gap: .4rem; align-items: center; flex-wrap: wrap; margin: 0; }
.btn-row { display: flex; flex-wrap: wrap; gap: .5rem; margin: .75rem 0 1.25rem; }
.btn-row svg { margin-right: .3rem; vertical-align: -3px; }
.nowrap { white-space: nowrap; }
ul.plain { list-style: none; padding: 0; margin: .3rem 0 0; }
.chip .count { font-size: .74rem; font-weight: 700; padding: 0 .4rem; border-radius: 999px; background: rgba(28, 25, 23, .08); }
.chip.on .count { background: rgba(255, 255, 255, .25); }
.stat .delta.up { color: #166534; }
.stat .delta.down { color: var(--blue-700); }
.care-hero { display: grid; gap: 1.25rem; grid-template-columns: 1fr; background: linear-gradient(135deg, #fff 0%, var(--blue-50) 100%); border: 1px solid var(--blue-100); border-radius: var(--r-lg); padding: 1.4rem 1.5rem; margin: 1rem 0 1.5rem; box-shadow: var(--shadow-sm); }
@media (min-width: 52rem) { .care-hero { grid-template-columns: 1.4fr 1fr; align-items: center; } }
.care-hero .eyebrow { margin: 0 0 .35rem; }
.care-big { font-size: 1.35rem; font-weight: 650; letter-spacing: -.02em; margin: 0 0 .4rem; color: var(--ink); }
.care-big b { font-size: 2.4rem; font-weight: 800; letter-spacing: -.05em; color: var(--blue); margin-right: .25rem; font-variant-numeric: tabular-nums; }
.job-pills { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.job-pill { display: inline-flex; align-items: center; gap: .4rem; font-size: .78rem; font-weight: 600; padding: .25rem .65rem; border-radius: 999px; background: #fff; border: 1px solid var(--line); color: var(--ink); white-space: nowrap; }
.job-pill .dot { width: .5rem; height: .5rem; border-radius: 50%; background: #16a34a; flex: none; }
.job-pill.late .dot { background: #d97706; }
.job-pill.bad { border-color: var(--blue-100); background: var(--blue-50); color: var(--blue-700); }
.job-pill.bad .dot { background: var(--blue); }
.attn { list-style: none; padding: 0; margin: 0; }
.attn li { display: grid; grid-template-columns: auto 1fr auto; gap: .7rem; align-items: start; padding: .7rem 0; border-top: 1px solid var(--line); }
.attn li:first-child { border-top: 0; padding-top: 0; }
.attn-ic, .note-ic { width: 1.9rem; height: 1.9rem; border-radius: 50%; display: grid; place-items: center; background: var(--gold-50); color: var(--gold); flex: none; }
.attn a { text-decoration: none !important; color: var(--ink); }
.attn a:hover b { color: var(--blue); }
.note-day + .note-day { margin-top: 1rem; }
.note-day h3 { margin: 0 0 .5rem; color: var(--subtle); }
.note-list { list-style: none; padding: 0; margin: 0; }
.note { display: grid; grid-template-columns: auto 1fr; gap: .7rem; padding: .45rem 0; }
.note-body { min-width: 0; font-size: .92rem; }
.note.k-fixed .note-ic { background: #ecfdf5; color: #047857; }
.note.k-improved .note-ic { background: var(--blue-50); color: var(--blue); }
.note.k-learned .note-ic { background: #eff6ff; color: #1d4ed8; }
.note.k-info .note-ic { background: var(--surface-2); color: var(--muted); }
.note-pre { white-space: pre-wrap; word-break: break-word; font-size: .8rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-sm); padding: .6rem .75rem; margin: .4rem 0 0; max-height: 16rem; overflow: auto; }
.sugg-tools { display: flex; flex-wrap: wrap; gap: .75rem; align-items: flex-start; justify-content: space-between; margin: 0 0 1.25rem; }
.sugg-tools input[name="q"] { min-width: 0; flex: 1 1 12rem; }
.add-idea > summary, .decline > summary, details > summary.btn { list-style: none; display: inline-flex; cursor: pointer; }
.add-idea > summary::-webkit-details-marker, .decline > summary::-webkit-details-marker, details > summary.btn::-webkit-details-marker { display: none; }
.add-idea[open] form, details > summary.btn + form { margin-top: .75rem; }
.sugg-card { display: grid; grid-template-columns: auto 1fr; gap: 1rem; background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); padding: 1.1rem 1.2rem; margin: 0 0 .85rem; box-shadow: var(--shadow-sm); scroll-margin-top: 7rem; }
.sugg-card:target { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-50); }
.sugg-card.st-declined, .sugg-card.st-done { opacity: .85; }
.sugg-score { width: 3.4rem; height: 3.4rem; border-radius: var(--r); background: var(--blue-50); color: var(--blue); display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1; }
.sugg-score b { font-size: 1.3rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.sugg-score span { font-size: .62rem; text-transform: uppercase; letter-spacing: .08em; margin-top: .2rem; }
.sugg-main { min-width: 0; }
.sugg-title { font-size: 1.05rem; margin: 0 0 .35rem; letter-spacing: -.01em; }
.sugg-meta { display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; margin: 0 0 .5rem; }
.sugg-text { margin: 0 0 .4rem; font-size: .93rem; }
.sugg-actions { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; margin: .7rem 0 .2rem; }
.decline[open] { flex-basis: 100%; }
.decline form { margin-top: .5rem; }
.decline input[name="reason"] { min-width: 0; flex: 1 1 14rem; }
.sugg-history ol { margin: .4rem 0 0; padding-left: 1.2rem; color: var(--muted); }
@media (max-width: 34rem) { .sugg-card { grid-template-columns: 1fr; } .sugg-score { flex-direction: row; gap: .35rem; width: auto; height: auto; padding: .3rem .6rem; justify-self: start; } .sugg-score span { margin: 0; } }
.danger-zone { border-color: var(--blue-100); }
.danger-zone h3 { font-size: 1rem; margin: 0 0 .35rem; }
.danger-fields { display: flex; flex-wrap: wrap; gap: 0 1rem; margin: .5rem 0; }
.danger-fields p { margin: .4rem 0; }
.key-box { font-size: .95rem; background: #fff; border: 1px solid var(--line-strong); border-radius: var(--r-sm); padding: .6rem .8rem; word-break: break-all; white-space: pre-wrap; user-select: all; }


/* ---- Map upgrades: single-state MapLibre maps (public/js/state-map.js) and the interactive /map page (public/js/school-map.js) ---- */
.statemap .geomap-frame.sm-frame { padding: 0; overflow: hidden; }
.sm-stage { position: relative; width: 100%; aspect-ratio: 16 / 10; max-height: 520px; background: var(--surface); }
.sm-stage > svg { display: block; width: 100%; height: 100%; }
.sm-stage .sm-map.maplibregl-map { position: absolute; inset: 0; width: 100%; height: 100%; background: var(--surface); }
.sm-stage .map-tip { z-index: 20; }
.sm-stage .maplibregl-ctrl-attrib { font-size: 10px; }
@media (max-width: 39.99rem) { .sm-stage { aspect-ratio: auto; height: 360px; max-height: none; } }
.sm-mk { display: block; box-sizing: border-box; width: 22px; height: 22px; padding: 0; border: 0; background: none; text-decoration: none; cursor: pointer; outline: none; }
.sm-dot { display: block; box-sizing: border-box; width: 14px; height: 14px; margin: 4px; border-radius: 50%; background: var(--blue); border: 2px solid var(--bg); box-shadow: 0 1px 3px rgba(15, 31, 54, .35); transition: transform .2s cubic-bezier(.2, .7, .2, 1); }
.sm-dot.life { background: var(--teal); }
.sm-dot.nr { background: var(--bg); border-color: var(--subtle); box-shadow: none; }
.sm-mk:hover .sm-dot, .sm-mk:focus-visible .sm-dot { transform: scale(1.35); }
.sm-mk:focus-visible .sm-dot { box-shadow: 0 0 0 3px var(--focus); }
.statemap .geomap-legend .note { margin-left: auto; }
@media (prefers-reduced-motion: reduce) { .sm-dot { transition: none; } .sm-mk:hover .sm-dot, .sm-mk:focus-visible .sm-dot { transform: none; } }

/* Context layers on the US choropleth: interstates (faint) and metro dots with labels. */
.geomap-roads { fill: none; stroke: var(--ink); stroke-width: .45; stroke-linecap: round; opacity: .2; pointer-events: none; }
.geomap-metros { pointer-events: none; }
.geomap-metros circle { fill: var(--ink); stroke: var(--bg); stroke-width: .8; }
.geomap-metros text { font: 700 10.5px var(--sans); fill: var(--ink); paint-order: stroke; stroke: var(--bg); stroke-width: 3px; stroke-linejoin: round; }
@media (max-width: 39.99rem) { .geomap-metros .metro.lo { display: none; } .geomap-metros text { font-size: 9px; } }

/* /map page */
.mx { margin: .25rem 0 1rem; }
.mx-bar { max-width: 32rem; margin-bottom: .75rem; }
.mx-body { display: grid; grid-template-columns: minmax(0, 1fr) 19rem; gap: 1rem; align-items: start; }
.mx-mapcol { min-width: 0; }
.mx-stage { position: relative; height: 70vh; min-height: 420px; max-height: 820px; border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow-sm); }
.mx-svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.mx-svg circle { stroke-width: .8; }
.mx-svg a:hover circle, .mx-svg a:focus-visible circle { stroke: var(--ink); stroke-width: 2; }
.mx-stage .mx-map.maplibregl-map { position: absolute; inset: 0; width: 100%; height: 100%; background: var(--surface); }
.mx-live .mx-svg { display: none; }
.mx:not(.mx-live) .mx-js { display: none !important; }
.mx.mx-live .mx-submit { display: none; }
.mx-ring-dot { background: var(--bg); border: 3px solid var(--teal); box-sizing: border-box; }
.mx-side { display: flex; flex-direction: column; gap: .6rem; max-height: 70vh; min-height: 0; overflow: auto; padding: .1rem .2rem .2rem 0; }
.mx-search label { display: block; font-weight: 700; font-size: .9rem; margin-bottom: .25rem; }
.mx-search-row { display: flex; gap: .4rem; }
.mx-search-row input { flex: 1; min-width: 0; }
.mx-grades { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .35rem; }
.mx-grades legend { font-weight: 700; font-size: .9rem; margin-bottom: .3rem; padding: 0; }
.mx-chip { font: inherit; font-size: .85rem; font-weight: 700; padding: .25rem .65rem; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--bg); color: var(--muted); cursor: pointer; }
.mx-chip[aria-pressed="true"] { background: var(--blue-50); color: var(--ink); border-color: var(--blue); }
.mx-chip:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.mx-count { margin: 0; }
.mx-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .3rem; }
.mx-row { display: block; padding: .45rem .6rem; border-radius: var(--r); border: 1px solid var(--line); background: var(--bg); color: var(--ink); text-decoration: none; }
.mx-row:hover, .mx-row:focus-visible { border-color: var(--blue); background: var(--blue-50); outline: none; }
.mx-row-name { display: block; font-weight: 700; font-size: .92rem; line-height: 1.25; }
.mx-row-meta { display: block; font-size: .8rem; color: var(--muted); font-weight: 600; }
.mx-empty { font-size: .9rem; padding: .3rem 0; }
.mx-more { align-self: flex-start; }
.mx-pop .maplibregl-popup-content { font: 14px/1.4 var(--sans); color: var(--ink); background: var(--bg); border-radius: var(--r); padding: .7rem .9rem; box-shadow: var(--shadow-lg); }
.mx-pop-name { display: block; font-size: 15px; font-weight: 800; color: var(--ink); }
.mx-pop-place { color: var(--muted); font-weight: 600; font-size: 13px; }
.mx-pop-score { display: flex; align-items: center; gap: .5rem; margin-top: .45rem; font-size: 13px; font-weight: 700; }
.mx-pop-score svg { flex: none; width: 28px; height: 28px; }
.mx-pop-score .mt-track { stroke: var(--line); }
.mx-pop-score .mt-arc { stroke: var(--blue); }
.mx-pop-score .mt-arc.life { stroke: var(--teal); }
.mx-pop-grade { margin-left: auto; font-size: 15px; }
.mx-pop-cta { display: inline-block; margin-top: .5rem; font-weight: 700; font-size: 13px; color: var(--blue); }
.mx-pop.mx-hover .maplibregl-popup-content { pointer-events: none; }
@media (max-width: 59.99rem) {
  .mx-body { grid-template-columns: minmax(0, 1fr); }
  .mx-stage { height: 60vh; min-height: 360px; }
  .mx-side { max-height: none; overflow: visible; }
}

/* Segmented switch (e.g. All / Public / Private on campus-ministry rankings). */
.seg-switch { display: inline-flex; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); margin: 0 0 1rem; }
.seg-switch a { padding: .4rem .95rem; border-radius: 999px; font-weight: 600; font-size: .9rem; color: var(--muted); text-decoration: none; }
.seg-switch a:hover { color: var(--ink); }
.seg-switch a[aria-current="page"] { background: var(--blue); color: #fff; }

/* ---- By-state views: the What and Shade toggles, the score bands, the state cards, hatching, near me ---- */
.sbs-bar { display: flex; flex-wrap: wrap; gap: .6rem 1.25rem; align-items: center; margin: .25rem 0 .75rem; }
.sbs-what, .sbs-shade, .sbs-label { font-size: .85rem; font-weight: 700; color: var(--muted); margin-right: .2rem; }
.sbs-opt { display: inline-block; padding: .32rem .8rem; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink); font-weight: 700; font-size: .88rem; text-decoration: none; white-space: nowrap; }
.sbs-opt:hover { border-color: var(--blue); }
.sbs-opt[aria-current] { background: var(--blue); border-color: var(--blue); color: #fff; }
.sbs-opt:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
@media (max-width: 39.99rem) {
  .sbs-bar { flex-direction: column; align-items: stretch; }
  .sbs-what, .sbs-shade, .sbs-area { flex-wrap: nowrap; overflow-x: auto; padding-bottom: .3rem; -webkit-overflow-scrolling: touch; }
}
.sbs-sortbar { display: flex; justify-content: space-between; align-items: center; gap: .6rem 1rem; flex-wrap: wrap; margin: .5rem 0 .6rem; }
.sbs-sortbar select { font: inherit; padding: .25rem .4rem; border-radius: var(--r-sm); border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink); }
.state-card .sc-sub { display: block; font-size: .82rem; color: var(--muted); font-weight: 600; margin-top: .1rem; }
.state-card .sc-top { display: flex; align-items: center; gap: .45rem; margin-top: .4rem; font-size: .8rem; color: var(--muted); line-height: 1.25; }
.state-card .sc-top b { color: var(--ink); }
.state-card .mini-ring { flex: none; width: 26px; height: 26px; }
.state-card .mini-ring .mt-track { stroke: var(--line); }
.state-card .mini-ring .mt-arc { stroke: var(--blue); }
.state-card .mini-ring .mt-arc.life { stroke: var(--teal); }
.state-card.hot, .state-card:hover { border-color: var(--blue); background: var(--blue-50); }
.state-card.picked { box-shadow: inset 0 0 0 2px var(--blue); }
.geomap .st.hatch { fill: url(#geo-hatch); }
.geomap .hatch-bg { fill: var(--surface-2); }
.geomap .hatch-line { stroke: var(--subtle); stroke-width: 1.4; }
.geomap a.hot .st, .geomap a.picked .st { stroke: var(--ink); stroke-width: 2; paint-order: stroke; }
.geomap-legend .bands { display: inline-flex; flex-wrap: wrap; gap: .3rem .75rem; }
.geomap-legend .band { display: inline-flex; align-items: center; gap: .3rem; }
.geomap-legend .band i { display: inline-block; width: .9rem; height: .9rem; border-radius: 3px; border: 1px solid var(--line); }
.geomap-legend .band i.q1 { background: var(--q1); } .geomap-legend .band i.q2 { background: var(--q2); }
.geomap-legend .band i.q3 { background: var(--q3); } .geomap-legend .band i.q4 { background: var(--q4); }
.geomap-legend .band i.q5 { background: var(--q5); }
.geomap-legend .hatch-sw { background: repeating-linear-gradient(45deg, var(--subtle) 0 1px, var(--surface-2) 1px 4px); }

/* Near me */
.nm { margin: .25rem 0 .75rem; padding: .7rem .8rem; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
.nm h2 { font-size: 1rem; margin: 0 0 .3rem; }
.nm-actions { margin: .35rem 0; }
.nm-form label { display: block; font-size: .85rem; font-weight: 700; margin: .4rem 0 .2rem; }
.nm-form-row { display: flex; gap: .4rem; }
.nm-form-row input { flex: 1; min-width: 0; }
.nm-msg { min-height: 1.2em; margin: .4rem 0 .2rem; }
.nm-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .3rem; }
.nm-row { display: flex; justify-content: space-between; gap: .6rem; padding: .4rem .55rem; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--bg); color: var(--ink); text-decoration: none; }
.nm-row:hover, .nm-row:focus-visible { border-color: var(--blue); outline: none; }
.nm-name { font-weight: 700; font-size: .9rem; }
.nm-meta { font-size: .8rem; color: var(--muted); font-weight: 600; white-space: nowrap; }
/* Near me needs JavaScript: hidden without it. */
html:not(.js) .nm { display: none; }

/* Top school lists (/best): hub cards, the ranked list, and the "How this list is made" box. */
.best-group { margin: 2rem 0 0; }
.best-cards { margin-top: .9rem; }
.best-card .kicker { margin-bottom: .25rem; }
.best-card h3 { font-size: 1.08rem; line-height: 1.3; margin: 0; }
.best-card.compact .best-lead { margin: .5rem 0 0; }
.best-top { list-style: none; margin: .9rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; }
.best-top li { display: flex; flex-direction: column; align-items: center; gap: .3rem; min-width: 0; text-align: center; }
.best-top-name { font-size: .74rem; line-height: 1.25; color: var(--muted); font-weight: 600; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.best-popular .best-card { padding: 1rem 1.1rem; }
.best-count { margin: 1rem 0 0; color: var(--text); }
.best-how { margin: 1.25rem 0 0; background: var(--surface); }
.best-how h2 { margin: 0 0 .5rem; font-size: 1.1rem; }
.best-how ul { margin: 0 0 .6rem; padding-left: 1.2rem; }
.best-compare { margin-top: 1.5rem; }
.best-compare td:first-child { min-width: 11rem; }
.best-how li { margin: .25rem 0; color: var(--text); font-size: .95rem; }
.best-list { list-style: none; margin: 1.25rem 0 0; padding: 0; border-top: 1px solid var(--line); }
.best-row { display: grid; grid-template-columns: 2.25rem auto minmax(0, 1fr); gap: .3rem .9rem; align-items: center; padding: .95rem 0; border-bottom: 1px solid var(--line); }
.best-rank-num { font-weight: 800; font-size: 1.15rem; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.best-body { min-width: 0; }
.best-name { margin: 0; font-size: 1.05rem; line-height: 1.3; }
.best-name a { color: var(--ink); text-decoration: none; }
.best-name a:hover { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.best-place { font-size: .88rem; color: var(--muted); margin-top: .1rem; display: flex; flex-wrap: wrap; gap: .35rem .5rem; align-items: center; }
.best-facts { list-style: none; margin: .45rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: .35rem; }
.best-facts li { font-size: .8rem; font-weight: 600; color: var(--text); background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: .18rem .6rem; }
@media (max-width: 380px) {
  .best-row { grid-template-columns: 1.9rem auto minmax(0, 1fr); gap: .3rem .6rem; }
  .best-top-name { font-size: .7rem; }
}

/* /map: view insets, score rings in the list, the dioceses overlay and its legend */
.mx-insets { position: absolute; top: .6rem; left: .6rem; z-index: 3; display: flex; flex-wrap: wrap; gap: .35rem; max-width: calc(100% - 4.4rem); }
.mx-insets button { font: inherit; font-size: .8rem; font-weight: 700; padding: .28rem .65rem; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink); box-shadow: var(--shadow-sm); cursor: pointer; transition: border-color .15s ease, background-color .15s ease; }
.mx-insets button:hover { border-color: var(--blue); background: var(--blue-50); }
.mx-insets button:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.mx-score { display: inline-flex; align-items: center; gap: .3rem; color: var(--ink); font-weight: 700; }
.mx-score svg { width: 20px; height: 20px; flex: none; }
.mx-score-num { font-variant-numeric: tabular-nums; }
.mx-score .mt-track { stroke: var(--line); }
.mx-score .mt-arc { stroke: var(--blue); }
.mx-score .mt-arc.life, .mx-score .mt-cross, .mt-cross { stroke: var(--teal); }
.mx-pop-score .mt-cross { stroke: var(--teal); }
.map-tip .mt-line { display: block; color: var(--muted); font-weight: 600; font-size: .8rem; margin-top: .15rem; }
.mx-pop-counts { margin-top: .3rem; font-size: 13px; font-weight: 600; color: var(--muted); }
.mx-overlays { margin-top: .2rem; }
.mx-dio-legend { margin-top: .4rem; }
.mx-dio-ramp { display: inline-flex; border-radius: 6px; overflow: hidden; border: 1px solid var(--line); }
.mx-dio-ramp i { display: block; width: 1.6rem; height: .7rem; }
.geomap .dio { stroke: var(--bg); stroke-width: .6; }
.sbs-area { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; min-width: 0; }
.sbs-area[hidden], .sbs-shade[hidden] { display: none; }

/* Phones: "Catholic School / Compass" on two lines so the longer name never runs into the header buttons. */
@media (max-width: 30rem) {
  .masthead .brand-name { white-space: normal; font-size: 1rem; line-height: 1.05; }
  .masthead .brand-name .guide { display: block; }
}

/* School pages: "Questions families ask" (the same answers as the page's FAQ structured data). */
.faq dl { margin: 0; display: grid; gap: .25rem; }
.faq dt { font-weight: 800; color: var(--ink); margin-top: .9rem; }
.faq dt:first-child { margin-top: 0; }
.faq dd { margin: 0; color: var(--ink-2, var(--ink)); line-height: 1.6; }

/* Top lists by state: chip rows on list pages ("By state") and state pages ("Top lists in Texas"). */
.best-states { margin-top: 2rem; }
.best-states h2 { font-size: 1.15rem; margin: 0 0 .75rem; }
.chip-row { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
