:root {
  --bg: #fbf6ee; --card: #fff; --ink: #102a43; --muted: #5d6b7c; --line: #e8dfd2; --soft: #f4ede2;
  --brand: #016fb9; --sun: #ffd166; --pink: #ff4d6d; --ok: #1e8a4c; --r: 16px; --shadow: 0 6px 22px rgba(16,42,67,.08);
  font-family: 'Nunito', system-ui, sans-serif; color: var(--ink);
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); font-size: 16px; line-height: 1.45; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--brand); }
h1, h2 { font-family: 'Bowlby One', sans-serif; font-weight: 400; line-height: 1.1; margin: 0 0 10px; }
h1 { font-size: clamp(28px, 6vw, 40px); }
h2 { font-size: 22px; }
h3 { font-size: 13px; text-transform: uppercase; letter-spacing: 1.2px; color: var(--muted); margin: 0 0 10px; font-weight: 900; }
.muted { color: var(--muted); } .center { text-align: center; } [hidden] { display: none !important; }
button { cursor: pointer; border: 1px solid var(--line); background: #fff; border-radius: 12px; padding: 10px 16px; font-weight: 800; }
button:hover { border-color: #c9bca9; }
button:disabled { opacity: .45; cursor: default; }
button.primary { background: var(--brand); color: #fff; border-color: var(--brand); }
button.primary:hover { background: #015a96; }
button.big { padding: 14px 22px; font-size: 17px; }
button.ghost { background: transparent; border-color: transparent; }
button.danger { color: #b5121b; }
button.small { padding: 5px 10px; font-size: 13px; border-radius: 9px; }
input, select, textarea { border: 1px solid #d9cfc1; border-radius: 11px; padding: 10px 12px; background: #fff; width: 100%; min-width: 0; }
input:focus, select:focus, textarea:focus, button:focus-visible { outline: 3px solid rgba(1,111,185,.35); outline-offset: 1px; border-color: var(--brand); }
label, .field { display: flex; flex-direction: column; gap: 5px; font-weight: 800; font-size: 14px; }
label .muted, .field .muted { font-weight: 600; font-size: 13px; }
.check { flex-direction: row; align-items: flex-start; gap: 10px; font-weight: 700; }
.check input { width: 20px; height: 20px; flex: none; margin-top: 2px; accent-color: var(--brand); }

.top { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px clamp(14px, 4vw, 32px); background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.brand img { width: 40px; height: 40px; }
.brand span { display: flex; flex-direction: column; font-family: 'Bowlby One'; font-size: 17px; line-height: 1.05; }
.brand small { font-family: 'Nunito'; font-weight: 900; font-size: 10px; letter-spacing: 2px; text-transform: uppercase; color: var(--muted); }
#who { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; }
#who .name { max-width: 30vw; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#testbar { background: var(--sun); text-align: center; font-weight: 800; font-size: 13px; padding: 5px 12px; }

main { max-width: 980px; margin: 0 auto; padding: 22px clamp(14px, 4vw, 32px) 80px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: clamp(16px, 3vw, 26px); box-shadow: var(--shadow); margin-bottom: 18px; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.end { justify-content: flex-end; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.pill { display: inline-block; background: var(--soft); border-radius: 999px; padding: 3px 11px; font-size: 12px; font-weight: 800; margin: 0 0 8px; }
.pill.ok { background: #e3f4ea; color: var(--ok); } .pill.warn { background: #fff1d1; color: #8a5a00; }

.hero { text-align: center; padding: clamp(24px, 6vw, 56px) clamp(16px, 4vw, 40px); background: linear-gradient(135deg, #015a96, #016fb9 60%, #1a8fd6); color: #fff; border: 0; }
.hero img.logo { width: min(260px, 70%); filter: brightness(0) invert(1); margin-bottom: 14px; }
.hero p { font-size: 18px; max-width: 560px; margin: 0 auto 20px; opacity: .95; }
.hero .row { justify-content: center; }
.hero button:not(.primary) { background: rgba(255,255,255,.14); color: #fff; border-color: rgba(255,255,255,.5); }
.hero button.primary { background: var(--sun); color: var(--ink); border-color: var(--sun); }
.steps { counter-reset: s; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; padding: 0; list-style: none; }
.steps li { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; counter-increment: s; }
.steps li::before { content: counter(s); display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--sun); font-family: 'Bowlby One'; margin-bottom: 8px; }

.school-card { display: flex; align-items: center; gap: 14px; text-align: left; width: 100%; padding: 14px; }
.school-card img, .school-card .ph { width: 54px; height: 54px; object-fit: contain; border-radius: 12px; background: var(--soft); display: grid; place-items: center; font-size: 24px; flex: none; }
.school-card b { font-size: 17px; display: block; }

.school-head { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.school-head .logo { width: 90px; height: 90px; object-fit: contain; border-radius: 16px; background: var(--soft); display: grid; place-items: center; font-size: 36px; flex: none; }
.progress { height: 12px; background: var(--soft); border-radius: 999px; overflow: hidden; margin: 8px 0 10px; }
.progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--sun), #f6a623); border-radius: 999px; }
.todo { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 6px 14px; font-size: 14px; font-weight: 700; }
.todo li::before { content: '○ '; color: var(--muted); }
.todo li.done { color: var(--muted); } .todo li.done::before { content: '✓ '; color: var(--ok); }

.logo-edit { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.logo-edit .box { width: 130px; height: 100px; border: 1px solid var(--line); border-radius: 12px; display: grid; place-items: center; padding: 8px; background: repeating-conic-gradient(#f4efe8 0 25%, #fff 0 50%) 0 0/16px 16px; }
.logo-edit .box img { max-width: 100%; max-height: 100%; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips button { min-width: 46px; padding: 8px 10px; }
.chips button.on { background: var(--ink); color: #fff; border-color: var(--ink); }

.invite { display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; }
.code { font-family: 'Bowlby One'; font-size: clamp(24px, 5vw, 34px); letter-spacing: 1px; background: var(--soft); border-radius: 14px; padding: 8px 16px; display: inline-block; margin: 4px 0 10px; user-select: all; }
.qr { width: 170px; height: 170px; image-rendering: pixelated; border-radius: 10px; }
@media (max-width: 620px) { .invite { grid-template-columns: 1fr; } }

.staff-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.staff-card { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 16px 12px; }
.avatar { width: 84px; height: 84px; border-radius: 50%; object-fit: cover; background: var(--soft); display: grid; place-items: center; font-family: 'Bowlby One'; font-size: 26px; color: var(--muted); flex: none; }
.avatar.big { width: 120px; height: 120px; font-size: 36px; }
.staff-card b { font-size: 16px; }
.staff-card small { color: var(--muted); font-weight: 700; }
.staff-card .covers { display: flex; justify-content: center; height: 46px; margin-top: 2px; }
.staff-card .covers img { height: 46px; aspect-ratio: 2/3; object-fit: cover; border-radius: 2px; margin-left: -8px; box-shadow: 0 1px 4px rgba(0,0,0,.25); }
.add-card { border: 2px dashed var(--line); background: transparent; color: var(--muted); justify-content: center; min-height: 180px; }

.members { list-style: none; padding: 0; margin: 0; }
.members li { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--soft); font-size: 14px; }

.photo-edit { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.booklist { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 12px; margin-bottom: 10px; }
.book { position: relative; display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 700; line-height: 1.2; }
.book img { width: 100%; aspect-ratio: 2/3; object-fit: cover; border-radius: 4px; box-shadow: 0 2px 8px rgba(0,0,0,.18); background: var(--soft); }
.book small { color: var(--muted); font-weight: 600; }
.book .tools { position: absolute; top: 4px; right: 4px; display: flex; gap: 3px; }
.book .tools button { padding: 1px 7px; font-size: 13px; background: rgba(255,255,255,.92); border-radius: 7px; }
.empty-list { color: var(--muted); font-weight: 700; font-size: 14px; border: 2px dashed var(--line); border-radius: 12px; padding: 14px; text-align: center; margin-bottom: 10px; }
.search { border: 1px solid var(--line); border-radius: 14px; padding: 12px; background: #fffdf9; margin-top: 8px; }
.results { display: flex; flex-direction: column; gap: 8px; max-height: 460px; overflow-y: auto; margin-top: 10px; }
.result { display: grid; grid-template-columns: 52px 1fr auto; gap: 12px; align-items: center; padding: 6px; border-radius: 10px; }
.result:hover { background: var(--soft); }
.result img { width: 52px; aspect-ratio: 2/3; object-fit: cover; border-radius: 3px; box-shadow: 0 1px 4px rgba(0,0,0,.2); }
.result b { display: block; line-height: 1.2; }
.result small { color: var(--muted); font-weight: 600; display: block; }

.back { display: inline-block; margin-bottom: 12px; font-weight: 800; text-decoration: none; }
.saved { font-size: 13px; font-weight: 800; color: var(--muted); }
#toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 12px; font-weight: 700; z-index: 50; max-width: 92vw; box-shadow: var(--shadow); }
.dev-login { position: fixed; inset: 0; background: rgba(16,42,67,.5); display: grid; place-items: center; z-index: 60; padding: 16px; }
.dev-login form { width: min(420px, 100%); display: flex; flex-direction: column; gap: 12px; margin: 0; }
.dev-recent { display: flex; flex-direction: column; gap: 6px; }
.dev-recent button { text-align: left; display: flex; flex-direction: column; }
.dev-recent small { color: var(--muted); font-weight: 600; }

.foot { text-align: center; font-size: 13px; color: var(--muted); padding: 0 16px 28px; }

/* camera */
dialog.cam { border: 0; border-radius: var(--r); padding: 14px 18px; max-height: calc(100dvh - 16px); width: min(440px, calc(100vw - 24px)); box-shadow: 0 20px 60px rgba(16,42,67,.35); background: var(--card); color: var(--ink); }
dialog.cam::backdrop { background: rgba(16,42,67,.55); }
dialog.cam h2 { margin-bottom: 12px; }
.cam-stage { position: relative; width: min(100%, calc(100dvh - 190px)); min-width: 160px; margin: 0 auto; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: #0d1b2a; }
.cam-stage video, .cam-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cam-stage video.mirror { transform: scaleX(-1); }
.cam-ring { position: absolute; inset: 10%; border-radius: 50%; box-shadow: 0 0 0 999px rgba(13,27,42,.35); border: 3px dashed rgba(255,255,255,.8); pointer-events: none; }
.cam-note { margin: 10px 0 12px; }
dialog.cam .row.end { flex-wrap: wrap; gap: 8px; }

/* finished materials from Turning Pages */
.materials { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 16px; }
.material { display: flex; flex-direction: column; gap: 4px; }
.mat-thumb { aspect-ratio: 1; background: var(--soft); border-radius: 12px; display: grid; place-items: center; padding: 8px; overflow: hidden; }
.mat-thumb img { max-width: 100%; max-height: 100%; border-radius: 4px; box-shadow: 0 3px 10px rgba(16,42,67,.18); }
.material b { font-size: 15px; line-height: 1.2; margin-top: 4px; }
.material small { font-size: 13px; }
.material .row { gap: 6px; margin-top: 4px; }

.mat-thumb { position: relative; cursor: zoom-in; }
.mat-tools { position: absolute; top: 8px; right: 8px; display: flex; gap: 6px; opacity: 0; transition: opacity .15s; }
.mat-thumb:hover .mat-tools, .mat-thumb:focus-within .mat-tools { opacity: 1; }
.mat-tools button { width: 34px; height: 34px; padding: 0; border-radius: 50%; display: grid; place-items: center; font-size: 17px; line-height: 1; background: rgba(255,255,255,.95); border: 1px solid var(--line); box-shadow: 0 2px 8px rgba(16,42,67,.2); }
.mat-tools button:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
@media (hover: none) { .mat-tools { opacity: 1; } }
/* enlarged picture */
.lightbox { position: fixed; inset: 0; z-index: 50; background: rgba(16,42,67,.82); display: grid; place-items: center; padding: 20px; }
.lightbox figure { margin: 0; display: flex; flex-direction: column; gap: 12px; max-width: min(1100px, 100%); max-height: 100%; }
.lightbox img { max-width: 100%; max-height: calc(100vh - 130px); object-fit: contain; border-radius: 6px; box-shadow: 0 12px 40px rgba(0,0,0,.4); align-self: center; background: #fff; }
.lightbox figcaption { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; color: #fff; }
.lightbox figcaption b { font-size: 17px; }
.lightbox .ghost { color: #fff; }
.lightbox figcaption button:not(.primary):not(.ghost) { color: var(--ink); }
#toast { z-index: 60; }

.renew-due { border: 2px solid var(--sun); box-shadow: 0 0 0 4px rgba(255,209,102,.35), var(--shadow); }

/* how it works */
.how { margin-top: 30px; }
.how-title { font-size: clamp(26px, 5vw, 36px); text-align: center; margin-bottom: 8px; }
.how-lead { text-align: center; max-width: 680px; margin: 0 auto 22px; font-size: 18px; }
.how-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.how-card { margin: 0; }
.how-card h3 { font-size: 15px; color: var(--ink); letter-spacing: .02em; text-transform: none; margin: 6px 0 8px; font-weight: 900; }
.how-card p { margin: 0 0 8px; font-size: 15px; line-height: 1.5; }
.how-icon { font-size: 28px; line-height: 1; }
.rewards { margin-top: 20px; }
.rewards-wrap { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 20px; align-items: start; margin-bottom: 10px; }
.rewards-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.rewards-table th, .rewards-table td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); }
.rewards-table th { font-size: 13px; color: var(--muted); font-weight: 800; }
.rewards-table td:nth-child(2), .rewards-table td:nth-child(3) { font-weight: 900; }
.rewards-table tbody tr:nth-child(even) { background: var(--soft); }
.calc { background: var(--soft); border-radius: 14px; padding: 14px 16px; }
.calc-in { display: flex; align-items: center; gap: 6px; font-size: 20px; font-weight: 900; }
.calc-in input { font-size: 20px; font-weight: 900; max-width: 160px; }
.calc-out { font-size: 17px; margin: 12px 0 6px; }
.small { font-size: 13px; }
@media (max-width: 640px) { .rewards-wrap { grid-template-columns: 1fr; } }
/* sample slideshow */
.samples { margin-top: 20px; }
.show { position: relative; display: flex; align-items: center; gap: 8px; outline: none; }
.show-stage { --sh: min(68vh, 620px); flex: 1; min-width: 0; height: var(--sh); background: var(--soft); border-radius: 16px; display: grid; place-items: center; overflow: hidden; padding: 14px; }
.show-stage img { max-width: 100%; max-height: calc(var(--sh) - 28px); object-fit: contain; border-radius: 6px; box-shadow: 0 8px 26px rgba(16,42,67,.22); background: #fff; }
.show-arrow { flex: none; width: 46px; height: 46px; border-radius: 50%; padding: 0; font-size: 30px; line-height: 1; display: grid; place-items: center; background: var(--card); box-shadow: var(--shadow); }
.show-arrow:hover { background: var(--brand); color: #fff; border-color: var(--brand); }
.show-cap { margin: 12px 0 6px; text-align: center; }
.show-cap p { margin: 4px 0 0; }
.show-dots { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; }
.show-dots button { width: 11px; height: 11px; padding: 0; border-radius: 50%; background: var(--line); border: 0; }
.show-dots button.on { background: var(--brand); }
@media (max-width: 640px) { .show-arrow { position: absolute; z-index: 1; width: 40px; height: 40px; top: 50%; margin-top: -20px; } .show-arrow.prev { left: 4px; } .show-arrow.next { right: 4px; } .show-stage { --sh: 62vh; } }

/* a staff member's lists: one block per list, the one being added to is highlighted */
.list-block { border-top: 1px solid var(--line); padding-top: 14px; }
.list-block.adding { border-top-color: transparent; background: color-mix(in srgb, var(--accent, #016fb9) 6%, transparent); border-radius: 14px; padding: 12px; }

/* fair week: a date box with the Monday-to-Sunday dates under it */
.week-pick { display: flex; flex-direction: column; gap: 4px; }
.week-range { font-weight: 800; font-size: 15px; }
.week-range.muted { font-weight: 600; }
.pill.bad { background: #fde3e5; color: #a01020; }
.cal { max-width: 460px; border: 1px solid var(--line); border-radius: 14px; padding: 10px; background: #fff; font-weight: 700; }
.cal-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; } .cal-top button { width: 38px; height: 38px; padding: 0; font-size: 20px; line-height: 1; }
.cal-week { display: grid; grid-template-columns: repeat(7, 1fr) minmax(84px, 1.9fr); align-items: center; width: 100%; padding: 8px 6px; margin: 3px 0; border: 2px solid transparent; border-radius: 10px; background: var(--soft); text-align: center; font-weight: 700; font-size: 15px; }
button.cal-week:not(:disabled):hover { border-color: var(--brand); }
.cal-week:disabled { opacity: 1; cursor: not-allowed; }
.cal-week.past { background: none; color: #a9b1ba; }
.cal-week.closed { background: repeating-linear-gradient(135deg, #eceff2 0 7px, #e2e6ea 7px 14px); color: #7b8794; }
.cal-week.requested { background: #ffe3a1; color: #5b3d00; }
.cal-week.confirmed { background: var(--brand); color: #fff; }
.cal-week.on { border-color: var(--ink); box-shadow: 0 0 0 2px var(--sun); }
.cal-names { background: none; color: var(--muted); font-size: 12px; padding-block: 0; }
.cal-day.off { opacity: .5; }
.cal-tag { font-size: 12.5px; font-weight: 800; line-height: 1.2; text-align: right; overflow-wrap: anywhere; }
.cal-key { display: flex; gap: 16px; flex-wrap: wrap; margin: 8px 4px 2px; font-size: 13px; }
.cal-key span { display: flex; align-items: center; gap: 6px; } .cal-key span::before { content: ''; width: 16px; height: 16px; border-radius: 5px; background: #ffe3a1; border: 1px solid #e3b95a; } .cal-key .confirmed::before { background: var(--brand); border-color: var(--brand); }
.week-line { display: flex; align-items: center; justify-content: space-between; gap: 10px 16px; flex-wrap: wrap; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; }
.week-who { display: flex; flex-direction: column; min-width: 0; } .week-who a { font-weight: 900; color: var(--ink); }
.week-note { color: #a01020; font-weight: 800; }

.signin .card { width: min(420px, 100%); margin: 0; }
.signin .or { text-align: center; color: var(--muted); margin: 0; font-weight: 600; }
.org-code { font-size: 18px; font-weight: 700; padding: 6px 12px; background: var(--paper, #f4f1ea); border-radius: 8px; letter-spacing: .5px; }
.colour-edit { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.colour-pick { display: flex; flex-direction: row; align-items: center; gap: 8px; font-weight: 600; margin: 0; }
.colour-pick input[type=color] { width: 52px; height: 40px; padding: 2px; border-radius: 8px; cursor: pointer; }
.merge-choice { display: flex; flex-direction: column; gap: 6px; }
.merge-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.merge-opt { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left; padding: 10px; border: 2px solid var(--line, #d9e2ec); border-radius: 12px; background: #fff; font-weight: 600; min-height: 64px; overflow-wrap: anywhere; }
.merge-opt small { color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .4px; font-size: 11px; }
.merge-opt.on { border-color: var(--blue, #016fb9); box-shadow: 0 0 0 3px rgba(1,111,185,.18); }
.merge-opt.on small::after { content: ' \2713 keep'; color: var(--blue, #016fb9); }
.merge-logo { max-width: 120px; max-height: 80px; object-fit: contain; }
.merge-photo { width: 72px; height: 72px; object-fit: cover; border-radius: 50%; }
.merge-dot { display: inline-block; width: 24px; height: 24px; border-radius: 50%; border: 1px solid rgba(0,0,0,.2); }
.mat-count { position: absolute; left: 8px; bottom: 8px; background: rgba(16,42,67,.82); color: #fff; font-size: 12px; font-weight: 800; padding: 3px 8px; border-radius: 999px; }
.mat-sizes { display: flex; flex-wrap: wrap; gap: 4px; }
.mat-sizes .chip { font-size: 12px; padding: 3px 8px; border-radius: 999px; min-height: 0; }
.lb-sizes { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.lb-sizes button { background: rgba(255,255,255,.9); color: var(--ink); }
.lb-sizes button.on { background: var(--brand); color: #fff; border-color: var(--brand); }
.lightbox img { transition: opacity .15s; }
.print-help { font-size: 13px; background: var(--soft); border-radius: 10px; padding: 6px 10px; }
.print-help summary { cursor: pointer; font-weight: 800; }
.print-help ol { margin: 6px 0; padding-left: 18px; display: grid; gap: 4px; }
.print-help p { margin: 4px 0; color: var(--muted); }
/* icons: plain line drawings, or your own SVGs from public/icons (shown in the text colour) */
.ico { display: inline-block; width: 1.15em; height: 1.15em; vertical-align: -0.2em; flex: none; }
.ico svg { width: 100%; height: 100%; display: block; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ico-file { background: currentColor; -webkit-mask: var(--ico) center / contain no-repeat; mask: var(--ico) center / contain no-repeat; }
.how-icon:has(.ico:empty:not(.ico-file)) { display: none; }
.how-icon .ico { width: 34px; height: 34px; color: var(--brand); }
.mat-tools button .ico { width: 17px; height: 17px; }
/* a school with no logo: its initials */
.initials { display: grid !important; place-items: center; background: var(--brand); color: #fff; font-family: 'Bowlby One', sans-serif; font-weight: 400; letter-spacing: .02em; border-radius: 50%; }
.logo.initials, .ph.initials { background: var(--brand) !important; color: #fff !important; font-size: 30px; }

/* what your school gets (samples.js) */
.sv-intro { margin-top: 34px; }
.sv-part { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 24px clamp(16px, 3vw, 30px) 26px; margin-top: 20px; }
.sv-part > h2 { text-align: center; font-size: clamp(22px, 4vw, 28px); margin-bottom: 6px; }
.sv-part > p { text-align: center; max-width: 620px; margin: 0 auto 20px; }
.sv-bar { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 16px; }
.sw { border-radius: 14px; overflow: hidden; border: 1px solid #cfd6dd; box-shadow: 0 14px 40px rgba(16,42,67,.2); background: #fff; }
.sw-bar { display: flex; align-items: center; gap: 7px; background: #e6eaee; padding: 9px 14px; }
.sw-bar i { width: 12px; height: 12px; border-radius: 50%; background: #ff5f57; } .sw-bar i + i { background: #febc2e; } .sw-bar i + i + i { background: #28c840; }
.sw-addr { flex: 1; min-width: 0; margin-left: 10px; background: #fff; border-radius: 999px; padding: 4px 14px; font-size: 14px; font-weight: 700; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sw-view { position: relative; overflow: hidden; height: min(78vh, 680px); }
.sw-view iframe { display: block; border: 0; transform-origin: 0 0; }
@media (max-width: 640px) { .sw { max-width: 330px; margin: 0 auto; border: 9px solid #16222e; border-radius: 34px; } .sw-bar { padding: 9px 16px; } .sw-bar i { display: none; } .sw-addr { margin: 0; text-align: center; font-size: 13px; } .sw-view { height: min(66vh, 560px); } }
/* the page-turning catalogue */
.fb { position: relative; padding: 22px 0 14px; display: flex; align-items: center; justify-content: center; gap: 10px; }
.fb-stage { --pw: min(350px, calc((100vw - 250px) / 2)); position: relative; flex: none; width: calc(var(--pw) * 2); aspect-ratio: 1056 / 816; cursor: pointer; border-radius: 8px; outline-offset: 8px; user-select: none; -webkit-user-select: none; }
.fb-stage:focus-visible { outline: 3px solid rgba(1,111,185,.35); }
.fb-book { position: absolute; inset: 0; perspective: 2400px; transition: transform .95s cubic-bezier(.45,.05,.25,1); }
.fb-stage[data-at=start] .fb-book { transform: translateX(-25%); }
.fb-stage[data-at=end] .fb-book { transform: translateX(25%); }
.fb-leaf { position: absolute; left: 50%; top: 0; width: 50%; height: 100%; transform-origin: left center; transform-style: preserve-3d; transition: transform .95s cubic-bezier(.45,.05,.25,1); }
.fb-leaf.turned { transform: rotateY(-180deg); }
.fb-face { position: absolute; inset: 0; overflow: hidden; background: #fffdf7; backface-visibility: hidden; -webkit-backface-visibility: hidden; box-shadow: 0 8px 22px rgba(16,42,67,.22); }
.fb-front { border-radius: 2px 7px 7px 2px; }
.fb-back { transform: rotateY(180deg); border-radius: 7px 2px 2px 7px; }
.fb-face img { display: block; width: 100%; height: 100%; object-fit: cover; }
.fb-face::after { content: ''; position: absolute; inset: 0; pointer-events: none; }
.fb-front::after { background: linear-gradient(to right, rgba(16,42,67,.26), rgba(16,42,67,.06) 6%, transparent 14%); }
.fb-back::after { background: linear-gradient(to left, rgba(16,42,67,.26), rgba(16,42,67,.06) 6%, transparent 14%); }
.fb-face::before { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: 0; background: linear-gradient(to right, rgba(16,42,67,.1), rgba(255,255,255,.35) 45%, rgba(16,42,67,.28)); }
.fb-leaf.turning .fb-face::before { animation: fb-bend .95s ease-in-out; }
@keyframes fb-bend { 50% { opacity: 1; } }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
/* on a phone: one page at a time */
.fb-stage.one { --pw: min(300px, calc(100vw - 90px)); width: var(--pw); aspect-ratio: 528 / 816; }
.fb-stage.one .fb-book { transform: none; overflow: hidden; border-radius: 7px; }
.fb-stage.one .fb-leaf { left: 0; width: 100%; }
.fb-stage.one .fb-leaf.turned { transform: rotateY(-115deg); opacity: 0; transition: transform .95s cubic-bezier(.45,.05,.25,1), opacity .35s ease .55s; }
.fb-stage.one .fb-face { box-shadow: none; }
.fb-stage.one { box-shadow: 0 8px 22px rgba(16,42,67,.22); border-radius: 7px; }
@media (max-width: 640px) { .fb .show-arrow.prev, .nl-box .show-arrow.prev { left: -8px; } .fb .show-arrow.next, .nl-box .show-arrow.next { right: -8px; } .nl-box .show-arrow { top: auto; bottom: 26px; margin: 0; } .nl-box .show-arrow.prev { left: 12px; } .nl-box .show-arrow.next { right: 12px; } .nl-lines { padding: 18px 64px 22px; } }
/* bookmarks, hung in a row */
.bm { display: flex; justify-content: center; gap: clamp(10px, 2.6vw, 26px); padding: 6px 0 10px; }
.bm-one { flex: 0 1 152px; min-width: 0; padding: 0; border: 0; border-radius: 12px; background: none; transform: rotate(-2deg); transform-origin: top center; transition: transform .25s; }
.bm-one:nth-child(2) { transform: rotate(1deg) translateY(10px); } .bm-one:nth-child(3) { transform: rotate(-1deg) translateY(4px); } .bm-one:nth-child(4) { transform: rotate(2deg) translateY(10px); }
.bm-one:hover, .bm-one:focus-visible { transform: rotate(0) translateY(-6px); }
.bm-one img { display: block; width: 100%; border-radius: 12px; box-shadow: 0 8px 20px rgba(16,42,67,.2); }
/* social posts */
.soc { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; align-items: center; }
.soc-col { display: grid; gap: 14px; }
.soc-one { padding: 0; border: 0; background: none; border-radius: 12px; text-align: center; font-weight: 800; font-size: 14px; }
.soc-one img { display: block; width: 100%; border-radius: 12px; box-shadow: 0 6px 16px rgba(16,42,67,.16); transition: transform .2s, box-shadow .2s; }
.soc-one:hover img, .soc-one:focus-visible img { transform: translateY(-4px); box-shadow: 0 12px 26px rgba(16,42,67,.24); }
.soc-one span { display: block; margin-top: 7px; }
/* newsletter banners */
.nl-box { position: relative; display: flex; align-items: center; justify-content: center; gap: 12px; }
.nl { flex: 1; min-width: 0; max-width: 720px; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; box-shadow: 0 8px 22px rgba(16,42,67,.12); background: #fff; }
.nl-head { display: flex; align-items: center; gap: 12px; padding: 12px 16px; background: var(--soft); border-bottom: 1px solid var(--line); line-height: 1.25; }
.nl-head small { display: block; color: var(--muted); font-size: 13px; }
.nl-dot { flex: none; width: 40px; height: 40px; border-radius: 50%; background: #2f7d5b; color: #f3bf4b; display: grid; place-items: center; font-family: 'Bowlby One', sans-serif; }
.nl-view { position: relative; aspect-ratio: 3 / 1; background: #e8f1ee; }
.nl-view img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: translateX(3%); transition: opacity .6s, transform .6s; }
.nl-view img.on { opacity: 1; transform: none; }
.nl-lines { padding: 18px 20px 22px; display: grid; gap: 10px; }
.nl-lines i { display: block; height: 10px; border-radius: 6px; background: var(--soft); }
.nl-lines i:nth-child(2) { width: 92%; } .nl-lines i:nth-child(3) { width: 64%; }
@media (max-width: 640px) {
  .soc { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .bm { display: grid; grid-template-columns: repeat(2, minmax(0, 150px)); gap: 20px; }
}
@media (prefers-reduced-motion: reduce) { .fb-book, .fb-leaf, .fb-stage.one .fb-leaf.turned, .nl-view img, .bm-one, .soc-one img { transition: none; } .fb-leaf.turning .fb-face::before { animation: none; } }
