/* private-schools.css — browse all private schools (private-schools.html, js/private-schools.js). Prefix pb-. Tokens from pages.css. */
:root { --pb-tag: #0B5C66; --pb-tagbg: #DDF1F3; --pb-chip: #E3EDF8; --pb-chipfg: #1E4A72; --pb-field: #fff; }
:root[data-theme="dark"] { --pb-tag: #8FD8E0; --pb-tagbg: #12343A; --pb-chip: #1B2E44; --pb-chipfg: #9CC8F2; --pb-field: #0F1B28; }
.pb-page { overflow-x: hidden; }
.pb-main { max-width: 760px; padding-top: 18px; padding-bottom: 8px; display: flex; flex-direction: column; gap: 12px; }
.pb-main:focus { outline: none; }

.pb-head { display: flex; flex-direction: column; gap: 4px; }
.pb-kicker { margin: 0; align-self: flex-start; padding: 2px 10px; border-radius: 999px; background: var(--pb-tagbg); color: var(--pb-tag); font-size: .78rem; font-weight: 800; }
.pb-head h1 { margin: 0; font-size: clamp(1.45rem, 5.5vw, 1.9rem); line-height: 1.15; color: var(--ink); text-wrap: balance; }
.pb-lead { margin: 2px 0 0; color: var(--muted); font-size: .92rem; max-width: 62ch; }

/* search + filters */
.pb-tools { display: flex; flex-direction: column; gap: 10px; padding: 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow-sm); }
.pb-label, .pb-f label { font-weight: 700; font-size: .86rem; color: var(--ink); }
.pb-qrow { position: relative; margin-top: -4px; }
.pb-q { width: 100%; box-sizing: border-box; min-height: 48px; padding: 10px 44px 10px 14px; font: inherit; font-size: 1rem; color: var(--text);
  background: var(--pb-field); border: 1.5px solid var(--border); border-radius: 12px; }
.pb-q::placeholder { color: var(--muted); opacity: 1; }
.pb-q:focus { border-color: var(--accent); }
.pb-q::-webkit-search-cancel-button { display: none; }
.pb-qx { position: absolute; right: 2px; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border: 0; background: transparent; color: var(--muted); font-size: 1.5rem; line-height: 1; cursor: pointer; border-radius: 10px; }
.pb-qx:hover { color: var(--ink); }

.pb-bar { display: flex; align-items: flex-end; gap: 10px; }
.pb-sortf { flex: 1 1 auto; }
.pb-ftoggle { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 14px; border: 1.5px solid var(--border); border-radius: 10px;
  background: var(--surface-2); color: var(--ink); font: inherit; font-weight: 700; font-size: .92rem; cursor: pointer; flex: none; }
.pb-ftoggle:hover { border-color: var(--accent); background: var(--hover); }
.pb-ftoggle::after { content: ""; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); }
.pb-ftoggle[aria-expanded="true"]::after { transform: translateY(2px) rotate(-135deg); }
.pb-nf { min-width: 20px; padding: 0 6px; border-radius: 999px; background: var(--navy-2); color: #fff; font-size: .75rem; line-height: 20px; text-align: center; }
.pb-nf[hidden] { display: none; }
.pb-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.pb-grid[hidden] { display: none; }
.pb-f { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.pb-f select { width: 100%; min-height: 44px; padding: 8px 10px; font: inherit; font-size: .92rem; color: var(--text); background: var(--pb-field);
  border: 1.5px solid var(--border); border-radius: 10px; min-width: 0; text-overflow: ellipsis; }
.pb-f select:focus { border-color: var(--accent); }

.pb-nearrow { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.pb-near { min-height: 44px; flex: none; }
.pb-near-note { margin: 0; flex: 1 1 150px; font-size: .8rem; line-height: 1.35; color: var(--muted); }
.pb-near-status { margin: 0; font-size: .86rem; font-weight: 600; color: var(--ink); }
.pb-near-status:empty { display: none; }

/* active filter chips */
.pb-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.pb-chips[hidden] { display: none; }
.pb-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 4px 12px; border-radius: 999px; border: 1px solid transparent;
  background: var(--pb-chip); color: var(--pb-chipfg); font: inherit; font-size: .86rem; font-weight: 700; cursor: pointer; position: relative; }
.pb-chip::before { content: ""; position: absolute; inset: -4px 0; }   /* 44px tall touch area */
.pb-chip-x { font-size: 1.1rem; line-height: 1; }
.pb-chip-all { background: transparent; border-color: var(--border); color: var(--ink); }

.pb-countrow { display: flex; align-items: baseline; gap: 10px; }
.pb-count { margin: 0; font-weight: 800; color: var(--ink); font-size: 1.05rem; }

/* result cards */
.pb-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.pb-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow-sm); padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.pb-name { margin: 0; font-size: 1.06rem; line-height: 1.3; color: var(--ink); overflow-wrap: anywhere; }
.pb-name:focus { outline: none; }
.pb-name:focus-visible { outline: 2px solid var(--focus-ring, var(--accent)); outline-offset: 2px; }
.pb-meta { margin: 0; color: var(--muted); font-size: .9rem; overflow-wrap: anywhere; }
.pb-dist { color: var(--ink); }
.pb-facts { margin: 2px 0 0; display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: .88rem; }
.pb-facts > div { display: flex; gap: 6px; min-width: 0; }
.pb-facts dt { color: var(--muted); }
.pb-facts dt::after { content: ":"; }
.pb-facts dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.pb-comms { margin: 0; font-size: .88rem; }
.pb-links { margin: 2px 0 0; display: flex; flex-wrap: wrap; gap: 0 18px; }
.pb-links a { display: inline-flex; align-items: center; min-height: 44px; font-weight: 700; font-size: .92rem; }
.pb-comms a { display: inline-flex; align-items: center; min-height: 44px; }
.pb-none { color: var(--muted); padding: 12px 0; }
.pb-morerow { display: flex; justify-content: center; }
.pb-more { min-height: 44px; min-width: 200px; }
.pb-more[hidden] { display: none; }

.pb-about { margin: 10px 0 6px; padding-top: 6px; border-top: 1px solid var(--border); }
.pb-about h2 { font-size: 1rem; margin: 10px 0 6px; color: var(--ink); }
.pb-about ul { margin: 0; padding-left: 1.2em; color: var(--muted); font-size: .88rem; display: grid; gap: 6px; }
.pb-about b { color: var(--text); }
.pb-about-more { margin: 10px 0 0; font-size: .88rem; }
.pb-about-more a { display: inline-block; padding: 8px 0; }

@media (min-width: 721px) {
  .pb-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .pb-sortf { flex: 0 1 260px; }
}
@media print {
  .pb-tools, .pb-chips, .pb-morerow, .pb-links { display: none !important; }
  .pb-card { box-shadow: none; break-inside: avoid; }
}
