/* Eduscape features: Support card, Teacher upgrade lock, ID Card Creator, and the
   Eduscape Assistant. Loaded after the main stylesheet, so it reuses the app's
   own design tokens (--surface, --line, --text, --gold, --navy ...). */

/* ---------- Own assessments ---------- */
/* Same look as the built-in marks cells (.mk), but a separate class so the existing "save all marks" code never touches these. */
table.marks input.cmk { width: 46px; text-align: center; border: 1px solid var(--line); border-radius: 4px; padding: 4px 2px; background: var(--bg); color: var(--text); font-variant-numeric: tabular-nums; -moz-appearance: textfield; appearance: textfield; }
table.marks input.cmk::-webkit-outer-spin-button, table.marks input.cmk::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
table.marks input.cmk:focus { outline: 2px solid var(--gold); border-color: var(--gold); }
.ca-row { display: flex; gap: 8px; align-items: center; }

/* ---------- Team: head teacher + class teacher ---------- */
.nav-badge { display: inline-block; margin-left: 6px; min-width: 18px; padding: 0 6px; border-radius: 999px; background: var(--crimson); color: #fff; font-size: 11px; font-weight: 800; text-align: center; line-height: 18px; }
.lp-login-note { margin: -4px 0 10px; font-size: 12.5px; color: #4b5570; }
.team-threads { display: flex; flex-direction: column; gap: 8px; }
.team-thread { display: flex; align-items: center; gap: 12px; text-align: left; width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--text); cursor: pointer; font: inherit; transition: border-color .15s, transform .15s; }
.team-thread:hover { border-color: var(--gold); transform: translateY(-1px); }
.team-thread .tt-dot { width: 9px; height: 9px; border-radius: 50%; background: transparent; flex-shrink: 0; }
.team-thread.unread .tt-dot { background: var(--crimson); }
.team-thread.unread b { font-weight: 800; }
.team-thread .tt-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.team-thread .tt-snip { font-size: 12.5px; color: var(--text-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.team-thread .tt-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; flex-shrink: 0; }
.team-thread .tt-meta em { font-style: normal; font-size: 11.5px; color: var(--text-soft); }
.team-conv { display: flex; flex-direction: column; gap: 10px; max-height: 46vh; overflow-y: auto; padding: 2px; }
.team-msg { max-width: 86%; padding: 10px 13px; border-radius: 12px; background: var(--parchment); align-self: flex-start; }
.team-msg.mine { align-self: flex-end; background: var(--navy, #1C3A56); color: #fff; }
.team-msg-h { font-size: 12px; margin-bottom: 3px; opacity: .85; } .team-msg-h em { font-style: normal; opacity: .7; margin-left: 4px; }
.team-msg-s { font-weight: 800; margin-bottom: 3px; }
.team-msg-b { white-space: pre-wrap; font-size: 14px; line-height: 1.5; }
.team-msg-p { margin-top: 6px; font-size: 12.5px; opacity: .85; padding-top: 6px; border-top: 1px dashed currentColor; }
.team-pick { display: flex; flex-direction: column; gap: 6px; max-height: 32vh; overflow-y: auto; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); }
.team-pick label, .team-idrow { display: flex; align-items: center; gap: 9px; font-size: 13.5px; cursor: pointer; }
.team-idrow small { display: block; font-size: 12px; color: var(--text-soft); }
.team-cred { background: var(--parchment); border-radius: 12px; padding: 12px 14px; margin: 10px 0; display: grid; gap: 8px; }
.team-cred div { display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.team-cred span { font-size: 12.5px; color: var(--text-soft); } .team-cred b { font-family: ui-monospace, monospace; font-size: 15px; word-break: break-all; }
.team-chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.team-recv-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin-top: 10px; }
.team-recv { border: 1px solid var(--line, #e5e7eb); border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 6px; }
.team-recv b { font-size: 28px; line-height: 1; }
.team-recv span { font-weight: 600; }
.team-chip { padding: 6px 13px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--text); font-weight: 700; font-size: 13px; cursor: pointer; }
.team-chip.hot { background: var(--crimson); border-color: var(--crimson); color: #fff; }
.team-ok { color: var(--teal); font-weight: 800; } .team-no { color: var(--text-soft); }
.team-inst { margin-bottom: 16px; }
.team-official { border-left: 4px solid var(--gold); }
.team-official .dash-ic { width: 18px; height: 18px; vertical-align: -3px; margin-right: 4px; }
.team-copy { max-height: 62vh; overflow: auto; background: #fff; border-radius: 10px; padding: 8px; }
.copy-page { background: #fff; color: #111; }
@media print { body.printing-copy > *:not(#printRoot) { display: none !important; } body.printing-copy #printRoot { display: block; } body.printing-copy { background: #fff; padding: 0; margin: 0; } .copy-page { page: cp; } }
@page cp { size: A4 landscape; margin: 8mm; }

/* ---------- Performance Insights ---------- */
.ins-hb { display: flex; align-items: center; gap: 10px; margin: 9px 0; font-size: 13px; }
.ins-hb .l { width: 118px; flex-shrink: 0; font-weight: 600; }
.ins-hb .t { flex: 1; height: 10px; background: var(--line); border-radius: 99px; overflow: hidden; }
.ins-hb .t i { display: block; height: 100%; background: var(--navy, #1C3A56); border-radius: 99px; }
.ins-hb b { min-width: 46px; text-align: right; }
.ins-take { margin-top: 12px; line-height: 1.6; font-size: 14.5px; border-left: 4px solid var(--gold); }
.ins-two { margin-top: 2px; }
.ins-kpis { margin-top: 2px; }
.ins-up { color: var(--teal); font-weight: 800; }
.ins-down { color: var(--crimson); font-weight: 800; }
.ins-print-head { display: none; }
@media print { .ins-print-head { display: block; margin-bottom: 10px; } .ins-print-head h2 { margin: 0 0 2px; } .ins-print-head p { margin: 0; color: #555; } }

/* ---------- Message Parents ---------- */
.comm-badge { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; background: var(--crimson); color: #fff; font-size: 11px; font-weight: 700; }
.comm-tpls { display: flex; gap: 8px; flex-wrap: wrap; }
.comm-tpls .asst-chip { font-size: 13px; padding: 7px 14px; }
.asst-chip.on { background: var(--navy, #1C3A56); color: #fff; border-color: var(--navy, #1C3A56); }
.comm-vars { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-top: 8px; font-size: 12.5px; color: var(--text-soft); }
.comm-vars .asst-chip { font-size: 11.5px; padding: 3px 9px; font-family: ui-monospace, monospace; }
.comm-preview { margin-bottom: 10px; }
.comm-bubble { background: #DCF8C6; color: #14261a; border-radius: 12px 12px 12px 3px; padding: 10px 14px; font-size: 14px; line-height: 1.5; max-width: 560px; white-space: pre-wrap; box-shadow: 0 1px 2px rgba(0,0,0,.15); }
.comm-progress { display: flex; align-items: center; gap: 12px; }
.comm-progress .asst-bar { flex: 1; margin: 0; }
.comm-progress span { font-size: 13px; font-weight: 700; white-space: nowrap; }
tr.comm-done { opacity: .6; }

/* ---------- Dashboard v2 ---------- */
.dash-ic { width: 22px; height: 22px; flex-shrink: 0; }
.dash-alert { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; padding: 12px 16px; border-radius: 12px; margin-bottom: 14px; font-size: 14px; border: 1px solid var(--gold-soft); background: var(--parchment); }
.dash-alert.bad { background: rgba(178,58,72,.1); border-color: var(--crimson); }
.dash-alert.warn { border-left: 4px solid var(--gold); }
.dash-hero { display: flex; align-items: center; justify-content: space-between; gap: 22px; padding: 26px 30px; border-radius: 20px; margin-bottom: 16px; color: #fff; background: radial-gradient(120% 140% at 0% 0%, #2a5a86 0%, #1C3A56 55%, #14283c 100%); box-shadow: 0 18px 40px -18px rgba(11,25,40,.55); position: relative; overflow: hidden; }
.dash-hero::after { content: ""; position: absolute; right: -60px; top: -60px; width: 220px; height: 220px; border-radius: 50%; background: rgba(246,179,90,.13); pointer-events: none; }
.dash-hero-txt { position: relative; z-index: 1; min-width: 0; }
.dash-hello { font-size: 13px; letter-spacing: .04em; opacity: .8; margin-bottom: 6px; }
.dash-hero h2 { margin: 0 0 6px; font-family: var(--font-display); font-size: clamp(22px, 3vw, 30px); color: #fff; }
.dash-hero p { margin: 0 0 16px; max-width: 560px; line-height: 1.55; color: rgba(255,255,255,.85); font-size: 14.5px; }
.dash-hero .btn.dash-ghost { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.35); color: #fff; }
.dash-hero .btn.dash-ghost:hover { background: rgba(255,255,255,.22); }
.dash-hero .btn { display: inline-flex; align-items: center; gap: 7px; }
.dash-hero .dash-ic { width: 16px; height: 16px; }
.dash-ring { position: relative; width: 96px; height: 96px; flex-shrink: 0; z-index: 1; }
.dash-ring svg { width: 100%; height: 100%; }
.dash-ring b { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; font-size: 24px; line-height: 1; color: #fff; }
.dash-ring b small { font-size: 12px; opacity: .7; font-weight: 600; }
.dash-stats { display: grid; grid-template-columns: repeat(4, 1fr); background: var(--surface); border: 1px solid var(--line); border-radius: 16px; margin-bottom: 4px; overflow: hidden; }
.dash-stats > div { padding: 14px 18px; border-right: 1px solid var(--line); }
.dash-stats > div:last-child { border-right: 0; }
.dash-stats b { display: block; font-family: var(--font-display); font-size: 26px; line-height: 1.1; }
.dash-stats span { font-size: 12.5px; color: var(--text-soft); }
.dash-h { font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-soft); margin: 22px 0 10px; font-weight: 700; }
.dash-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.dash-tile { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 12px; align-items: center; text-align: left; padding: 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--text); cursor: pointer; transition: transform .15s, box-shadow .15s, border-color .15s; font: inherit; }
.dash-tile:hover { transform: translateY(-2px); box-shadow: 0 10px 24px -12px rgba(22,35,63,.3); border-color: var(--gold); }
.dash-tile .dash-ic { grid-row: 1 / 3; width: 38px; height: 38px; padding: 8px; border-radius: 10px; background: rgba(28,58,86,.09); color: var(--navy, #1C3A56); }
[data-theme="dark"] .dash-tile .dash-ic { background: rgba(255,255,255,.08); color: #F6B35A; }
.dash-tile b { font-size: 14.5px; }
.dash-tile span { font-size: 12.5px; color: var(--text-soft); line-height: 1.35; }
.dash-tile.locked { opacity: .65; }
.dash-two { margin-top: 18px; }
.dash-card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.dash-card-head h2 { margin: 0; }
.dash-class { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 9px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.dash-class:last-of-type { border-bottom: 0; }
.dash-class b { display: block; font-size: 14px; }
.dash-class span { font-size: 12px; color: var(--text-soft); }
.dash-class-n { display: flex; align-items: center; gap: 8px; width: 42%; }
.dash-class-n i { display: block; height: 7px; border-radius: 99px; background: var(--teal); min-width: 4px; }
.dash-class-n em { font-style: normal; font-weight: 700; font-size: 13px; min-width: 22px; text-align: right; margin-left: auto; }
.dash-more { margin-top: 8px; border: 0; background: none; color: var(--navy, #1C3A56); font-weight: 700; cursor: pointer; padding: 4px 0; font: inherit; }
.dash-profile { display: flex; flex-direction: column; gap: 3px; font-size: 13.5px; color: var(--text-soft); }
.dash-profile b { color: var(--text); font-size: 16px; font-family: var(--font-display); }
.dash-profile i { color: var(--text-soft); margin-bottom: 6px; }
.dash-help { margin-top: 4px; }
.dash-help h2 { margin-bottom: 12px; }
.dash-help-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.dash-help-item { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; text-align: left; padding: 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); color: var(--text); text-decoration: none; cursor: pointer; font: inherit; transition: border-color .15s, transform .15s; }
button.dash-help-item:hover, a.dash-help-item:hover { border-color: var(--gold); transform: translateY(-1px); }
.dash-help-item .dash-ic { color: var(--gold); }
.dash-help-item b { font-size: 14px; }
.dash-help-item span { font-size: 12.5px; color: var(--text-soft); line-height: 1.4; }
.dash-help-item.plan { cursor: default; justify-content: space-between; background: var(--parchment); }
@media (max-width: 900px) { .dash-tiles { grid-template-columns: repeat(2, 1fr); } .dash-help-grid { grid-template-columns: repeat(2, 1fr); } .dash-stats { grid-template-columns: repeat(2, 1fr); } .dash-stats > div:nth-child(2) { border-right: 0; } .dash-stats > div:nth-child(-n+2) { border-bottom: 1px solid var(--line); } }
@media (max-width: 560px) { .dash-hero { padding: 20px 18px; flex-direction: column-reverse; align-items: flex-start; } .dash-ring { width: 72px; height: 72px; } .dash-tiles, .dash-help-grid { grid-template-columns: 1fr; } }
.modal.modal-wide { max-width: 980px !important; width: 96vw !important; max-height: 92vh; overflow-y: auto; }

/* ---------- Support card + forms ---------- */
.fx-support { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; border-left: 4px solid var(--gold); }
.fx-support .fx-support-txt { flex: 1 1 260px; }
.fx-support .fx-support-txt b { display: block; font-size: 15px; }
.fx-support .fx-support-txt span { color: var(--text-soft); font-size: 13px; }
.fx-err { color: var(--crimson); font-size: 13px; min-height: 18px; margin-top: 6px; }
.fx-ok { text-align: center; padding: 10px 0 4px; }
.fx-ok .tick { width: 54px; height: 54px; border-radius: 50%; background: rgba(30,111,92,.14); color: var(--teal); display: grid; place-items: center; font-size: 28px; margin: 0 auto 10px; }
.fx-modal-note { background: var(--parchment); border-radius: 10px; padding: 12px 14px; font-size: 13.5px; line-height: 1.5; margin-bottom: 12px; }
.fx-form .field { margin-bottom: 10px; }

/* ---------- Homepage showcase (slideshow) ---------- */
.sx { max-width: 1120px; margin: 0 auto; }
.sx-tabs { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; margin-bottom: 26px; }
.sx-tab { padding: 10px 20px; border-radius: 999px; border: 1px solid var(--sg-line, #dfe3ee); background: #fff; color: var(--sg-ink, #16233F); font: 700 14px var(--font-ui, sans-serif); cursor: pointer; transition: background .2s, color .2s, border-color .2s, transform .2s; }
.sx-tab:hover { border-color: var(--sg-blue, #1C3A56); transform: translateY(-1px); }
.sx-tab.active { background: var(--sg-ink, #16233F); color: #fff; border-color: var(--sg-ink, #16233F); }
.sx-body { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 44px; align-items: center; }
.sx-copy { min-width: 0; }
.sx-kicker { display: inline-block; font: 800 12px var(--font-ui, sans-serif); letter-spacing: .12em; text-transform: uppercase; color: #E17B3F; margin-bottom: 10px; }
.sx-copy h3 { font-size: clamp(26px, 3.2vw, 38px); line-height: 1.1; margin: 0 0 14px; color: var(--sg-ink, #16233F); }
.sx-copy p { font-size: 17px; line-height: 1.65; color: var(--sg-muted, #4b5570); margin: 0 0 18px; }
.sx-copy ul { list-style: none; margin: 0 0 26px; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.sx-copy li { position: relative; padding-left: 30px; font-size: 15px; font-weight: 600; color: var(--sg-ink, #16233F); }
.sx-copy li::before { content: "\2713"; position: absolute; left: 0; top: 0; width: 21px; height: 21px; border-radius: 50%; background: rgba(30,111,92,.14); color: #1E6F5C; font-size: 12px; display: grid; place-items: center; }
.sx-cta { display: flex; gap: 10px; flex-wrap: wrap; }
.sx .lp-btn.ghost { color: var(--sg-ink, #16233F); border: 1.5px solid var(--sg-ink, #16233F); background: transparent; }
.sx .lp-btn.ghost:hover { background: var(--sg-ink, #16233F); color: #fff; }
.sx-stage { position: relative; height: 690px; border-radius: 28px; overflow: hidden; background: radial-gradient(120% 90% at 50% 0%, #ffffff 0%, #eaf0fb 55%, #dde6f6 100%); box-shadow: inset 0 0 0 1px rgba(28,58,86,.08), 0 40px 80px -40px rgba(11,15,26,.35); }
.sx-stage::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(28,58,86,.09) 1px, transparent 1px); background-size: 22px 22px; -webkit-mask-image: radial-gradient(70% 70% at 50% 50%, #000, transparent); mask-image: radial-gradient(70% 70% at 50% 50%, #000, transparent); pointer-events: none; }
.sx-canvas { position: absolute; left: 50%; top: 12px; width: max-content; transform-origin: top center; opacity: 0; transition: opacity .5s ease; }
.sx-canvas.sx-in { opacity: 1; animation: sxDrift 9s ease-in-out infinite alternate; }
@keyframes sxDrift { from { scale: 1; } to { scale: 1.045; } }
.sx-live { position: absolute; top: 14px; left: 14px; z-index: 3; display: inline-flex; align-items: center; gap: 7px; padding: 5px 11px; border-radius: 999px; background: rgba(20,32,50,.86); color: #fff; font: 800 11px var(--font-ui, sans-serif); letter-spacing: .12em; }
.sx-live i { width: 8px; height: 8px; border-radius: 50%; background: #ff4d5e; box-shadow: 0 0 0 0 rgba(255,77,94,.7); animation: sxPulse 1.6s infinite; }
@keyframes sxPulse { 0% { box-shadow: 0 0 0 0 rgba(255,77,94,.6); } 70% { box-shadow: 0 0 0 9px rgba(255,77,94,0); } 100% { box-shadow: 0 0 0 0 rgba(255,77,94,0); } }
.sx-ticker { position: absolute; left: 14px; right: 14px; bottom: 14px; z-index: 3; padding: 10px 14px; border-radius: 12px; background: rgba(255,255,255,.93); color: #16233F; font: 700 13px var(--font-ui, sans-serif); box-shadow: 0 8px 24px -10px rgba(11,15,26,.4); opacity: 0; transform: translateY(6px); transition: opacity .35s, transform .35s; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sx-ticker.on { opacity: 1; transform: none; }
.sx-ticker .ok { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: #1E6F5C; color: #fff; font-size: 11px; margin-right: 6px; }
/* the report card / sheet markup reuses .tpl-slide-frame for its pinned light colours; strip its own frame */
.sx-canvas.tpl-slide-frame { max-height: none; overflow: visible; box-shadow: none; border-radius: 0; }
.sx-canvas.sx-type-card .paper, .sx-canvas.sx-type-sheet .assess-sheet-frame { box-shadow: 0 30px 70px -20px rgba(11,15,26,.45); border-radius: 6px; }
/* ID scenes */
.sx-ids .idc { box-shadow: 0 22px 46px -10px rgba(11,15,26,.4); }
.sx-ids.stack { position: relative; width: 500px; height: 390px; }
.sx-ids.stack .a { position: absolute; left: 0; top: 0; transform: rotate(-4deg); animation: sxFloat 6s ease-in-out infinite; }
.sx-ids.stack .b { position: absolute; right: 0; bottom: 0; transform: rotate(3deg); animation: sxFloat 6s ease-in-out -3s infinite; }
.sx-ids.grid { display: grid; grid-template-columns: repeat(2, 85.6mm); gap: 8mm; }
.sx-ids.duo { display: flex; gap: 10mm; }
.sx-ids.duo .idc:nth-child(2) { margin-top: 10mm; }
@keyframes sxFloat { 0%, 100% { translate: 0 0; } 50% { translate: 0 -8px; } }
.sx-sheet { box-shadow: 0 30px 70px -20px rgba(11,15,26,.45); border-radius: 4px; }
.sx-sheet .idc { box-shadow: 0 1px 4px rgba(0,0,0,.18); }
.sx-controls { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 26px; }
.sx-bars { display: flex; gap: 7px; flex: 0 1 460px; }
.sx-bars button { flex: 1; height: 5px; padding: 0; border: 0; border-radius: 99px; background: var(--sg-line, #dfe3ee); cursor: pointer; overflow: hidden; position: relative; }
.sx-bars button i { position: absolute; inset: 0; width: 0; background: var(--sg-blue, #1C3A56); border-radius: 99px; }
.sx-bars button.done i { width: 100%; }
.sx-bars button.active i { animation: sxFill 7s linear forwards; }
.sx-bars.paused button.active i { animation-play-state: paused; }
@keyframes sxFill { from { width: 0; } to { width: 100%; } }
.sx-pause { border: 1px solid var(--sg-line, #dfe3ee); background: #fff; color: var(--sg-ink, #16233F); border-radius: 999px; padding: 8px 16px; font: 700 13px var(--font-ui, sans-serif); cursor: pointer; }
.sx-pause:hover { border-color: var(--sg-blue, #1C3A56); }
@media (max-width: 960px) {
  .sx-body { grid-template-columns: 1fr; gap: 26px; }
  .sx-copy { text-align: center; }
  .sx-copy ul { display: inline-flex; text-align: left; }
  .sx-cta { justify-content: center; }
  .sx-stage { height: 520px; }
}
@media (max-width: 560px) { .sx-stage { height: 440px; border-radius: 20px; } .sx-tab { padding: 8px 14px; font-size: 13px; } .sx-pause { display: none; } }
@media (prefers-reduced-motion: reduce) { .sx-ids.stack .a, .sx-ids.stack .b, .sx-canvas.sx-in, .sx-live i { animation: none; } .sx-canvas { transition: none; } }

/* Card-printer export renders cards square (the printer rounds the corners) */
#pdfStage.idc-flat .idc { border-radius: 0; border-top: 0; border-right: 0; border-bottom: 0; }
#pdfStage.idc-flat .idc:not(.idc-modern) { border-left: 0; }

/* ---------- Landing page: "Send us a message" ---------- */
.lps-card { margin-top: 22px; display: grid; grid-template-columns: 1fr 1.25fr; gap: 30px; background: #fff; color: #16233F; border-radius: 26px; padding: 34px; box-shadow: 0 18px 50px rgba(22,35,63,.12); }
.lps-card h3 { margin: 0 0 8px; font-size: clamp(22px, 3vw, 30px); }
.lps-card p { margin: 0; color: #4b5570; line-height: 1.6; }
.lps-form { display: flex; flex-direction: column; gap: 12px; position: relative; }
.lps-form label { display: flex; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 700; color: #16233F; }
.lps-form input, .lps-form textarea { padding: 12px 14px; border: 1.5px solid #d9dfec; border-radius: 12px; font: inherit; font-weight: 400; color: #16233F; background: #fff; }
.lps-form input:focus, .lps-form textarea:focus { outline: none; border-color: #1C3A56; box-shadow: 0 0 0 3px rgba(28,58,86,.12); }
.lps-form textarea { resize: vertical; }
.lps-status { min-height: 20px; font-size: 14px; font-weight: 600; }
.lps-status.ok { color: #1E6F5C; }
.lps-status.err { color: #B23A48; }
@media (max-width: 760px) { .lps-card { grid-template-columns: 1fr; padding: 24px 18px; gap: 20px; } }

/* ---------- Locked items in the teacher sidebar ---------- */
.nav-item.locked { opacity: .62; }
.nav-item.locked span::after { content: "\1F512"; margin-left: 8px; font-size: 11px; }
.nav-item.locked:hover { opacity: .9; }

/* ---------- ID Card Creator: screen UI ---------- */
.idc-tabs { display: flex; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
.idc-tabs .btn.on { background: var(--ink, #16233F); color: #fff; border-color: var(--ink, #16233F); }
.idc-design { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; }
.idc-design .check { display: flex; align-items: center; gap: 8px; font-size: 13px; padding-top: 22px; }
.idc-people-tools { display: flex; gap: 8px; flex-wrap: wrap; align-items: flex-end; margin-bottom: 12px; }
.idc-people .thumb { width: 30px; height: 38px; border-radius: 4px; object-fit: cover; border: 1px solid var(--line); background: var(--bg); display: inline-block; vertical-align: middle; }
.idc-people input.idc-idno { width: 130px; padding: 5px 8px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); }
.idc-preview { display: flex; flex-wrap: wrap; gap: 14px; padding: 4px 0; }
.idc-preview .idc { box-shadow: 0 6px 18px rgba(22,35,63,.18); }
.idc-more { align-self: center; color: var(--text-soft); font-size: 13px; }

/* ---------- ID card artwork (mm units so on-screen size == printed size) ---------- */
.idc { --c: #0A0F72; --a: #E17B3F; box-sizing: border-box; width: 85.6mm; height: 54mm; position: relative; overflow: hidden; border-radius: 3.2mm; background: #fff; color: #15202B; border: .25mm solid #cfd6df; display: flex; flex-direction: column; font-family: var(--font-ui, 'Inter', sans-serif); -webkit-print-color-adjust: exact; print-color-adjust: exact; flex-shrink: 0; }
.idc.idc-portrait { width: 54mm; height: 85.6mm; }
.idc-head { display: flex; align-items: center; gap: 2mm; padding: 2mm 3mm; background: var(--c); color: #fff; }
.idc-logo { width: 9mm; height: 9mm; border-radius: 50%; background: #fff; overflow: hidden; display: flex; align-items: center; justify-content: center; font-weight: 800; color: var(--c); font-size: 4mm; flex-shrink: 0; }
.idc-logo img { width: 100%; height: 100%; object-fit: cover; }
.idc-school { min-width: 0; }
.idc-school b { display: block; font-size: 3mm; line-height: 1.1; text-transform: uppercase; letter-spacing: .1mm; }
.idc-school small { display: block; font-size: 1.9mm; opacity: .85; margin-top: .4mm; }
.idc-body { flex: 1; display: flex; gap: 3mm; padding: 2.5mm 3mm; align-items: center; min-height: 0; }
.idc-photo { width: 20mm; height: 25mm; border: .5mm solid var(--c); border-radius: 1.5mm; background: #eef1f5; overflow: hidden; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 6mm; color: var(--c); font-weight: 800; }
.idc-photo img { width: 100%; height: 100%; object-fit: cover; }
.idc-info { min-width: 0; flex: 1; }
.idc-name { font-size: 3.5mm; font-weight: 800; line-height: 1.15; text-transform: uppercase; color: var(--c); word-break: break-word; }
.idc-role { display: inline-block; margin: 1mm 0; padding: .4mm 2mm; background: var(--a); color: #fff; border-radius: 5mm; font-size: 2.1mm; font-weight: 700; text-transform: uppercase; letter-spacing: .1mm; }
.idc-row { display: flex; gap: 1.5mm; font-size: 2.5mm; line-height: 1.4; }
.idc-row span { opacity: .65; min-width: 9mm; }
.idc-row b { font-weight: 700; word-break: break-word; }
.idc-foot { display: flex; align-items: center; justify-content: space-between; gap: 2mm; padding: 0 3mm 2mm; }
.idc-bar { height: 7mm; flex: 1; min-width: 0; background: #fff; border-radius: .8mm; padding: .5mm 1mm; }
.idc-bar svg { display: block; width: 100%; height: 100%; }
.idc-valid { font-size: 2mm; text-align: right; opacity: .8; }
/* Portrait: stack head, photo, details */
.idc-portrait .idc-body { flex-direction: column; text-align: center; gap: 2mm; padding-top: 3mm; }
.idc-portrait .idc-photo { width: 27mm; height: 33mm; }
.idc-portrait .idc-row { justify-content: center; }
.idc-portrait .idc-foot { flex-direction: column; align-items: stretch; padding-bottom: 3mm; }
.idc-portrait .idc-valid { text-align: center; }
/* Style: modern (colour band down the left, light header) */
.idc-modern { border-left: 5mm solid var(--c); }
.idc-modern .idc-head { background: #fff; color: var(--c); border-bottom: .4mm solid var(--a); }
.idc-modern .idc-logo { background: var(--c); color: #fff; }
/* Style: minimal (white, thin accent line) */
.idc-minimal .idc-head { background: #fff; color: var(--c); border-bottom: .6mm solid var(--a); }
.idc-minimal .idc-logo { background: var(--c); color: #fff; }
/* Style: bold (full colour card) */
.idc-bold { background: var(--c); color: #fff; }
.idc-bold .idc-head { background: rgba(0,0,0,.18); }
.idc-bold .idc-name { color: #fff; }
.idc-bold .idc-photo { border-color: var(--a); }
.idc-bold .idc-row span { opacity: .75; }
/* Back of the card */
.idc-back .idc-backbody { flex: 1; padding: 3mm; font-size: 2.6mm; line-height: 1.45; display: flex; flex-direction: column; gap: 1.2mm; justify-content: center; text-align: center; }
.idc-back .idc-backbody .note { font-weight: 700; color: var(--c); font-size: 2.8mm; }
.idc-bold.idc-back .idc-backbody .note { color: #fff; }
.idc-back .idc-sign { padding: 0 3mm 2.5mm; text-align: center; font-size: 2.1mm; opacity: .85; }
.idc-back .idc-sign img { height: 8mm; display: block; margin: 0 auto 0.5mm; }

/* ---------- ID sheets (print + PDF): A4 pages of cards ---------- */
.idc-page { width: 210mm; height: 297mm; box-sizing: border-box; padding: 10mm 12mm; display: grid; gap: 5mm; justify-content: center; align-content: start; background: #fff; }
.idc-page.land { grid-template-columns: repeat(2, 85.6mm); }
.idc-page.port { grid-template-columns: repeat(3, 54mm); }
.idc-page.rtl { direction: rtl; }
.idc-page.rtl .idc { direction: ltr; }
@media print {
  body.printing-ids > *:not(#printRoot) { display: none !important; }
  body.printing-ids #printRoot { display: block; }
  body.printing-ids { background: #fff; padding: 0; margin: 0; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  #printRoot .idc-page { break-after: page; page-break-after: always; }
  #printRoot .idc-page:last-child { break-after: auto; page-break-after: auto; }
}

/* ---------- Eduscape Assistant ---------- */
#asstFab { position: fixed; right: 18px; bottom: 18px; z-index: 900; display: none; align-items: center; gap: 8px; padding: 12px 18px 12px 14px; border-radius: 999px; border: 0; background: var(--gold); color: #241804; font-weight: 800; font-size: 14px; cursor: pointer; box-shadow: 0 10px 26px rgba(0,0,0,.28); transition: transform .15s; }
#asstFab:hover { transform: translateY(-2px); }
#asstFab .dot { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: #241804; color: var(--gold); font-size: 14px; }
#asstFab .badge-new { position: absolute; top: -4px; right: -2px; width: 14px; height: 14px; border-radius: 50%; background: var(--crimson); border: 2px solid #fff; }
body.has-admin-bar #asstFab { bottom: 74px; }
#asstBubble { position: fixed; right: 18px; bottom: 76px; z-index: 899; max-width: 300px; display: none; background: var(--surface); color: var(--text); border: 1px solid var(--line); border-left: 4px solid var(--gold); border-radius: 12px; padding: 12px 34px 12px 14px; font-size: 13px; line-height: 1.45; box-shadow: 0 12px 30px rgba(0,0,0,.22); }
#asstBubble b { display: block; margin-bottom: 2px; }
#asstBubble .x { position: absolute; top: 4px; right: 6px; border: 0; background: none; font-size: 18px; color: var(--text-soft); cursor: pointer; }
#asstBubble .go { margin-top: 8px; }
body.has-admin-bar #asstBubble { bottom: 132px; }
#asstPanel { position: fixed; right: 18px; bottom: 76px; z-index: 950; width: 390px; max-width: calc(100vw - 24px); height: min(640px, calc(100vh - 110px)); display: none; flex-direction: column; background: var(--surface); color: var(--text); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 20px 60px rgba(0,0,0,.35); overflow: hidden; }
body.has-admin-bar #asstPanel { bottom: 132px; height: min(600px, calc(100vh - 170px)); }
#asstPanel.open { display: flex; }
.asst-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; background: var(--navy, #1C3A56); color: #fff; }
.asst-head b { font-size: 15px; }
.asst-head small { display: block; opacity: .75; font-size: 11.5px; }
.asst-head button { background: none; border: 0; color: #fff; font-size: 22px; cursor: pointer; line-height: 1; }
.asst-body { flex: 1; overflow-y: auto; padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }
.asst-card { background: var(--parchment); border-radius: 12px; padding: 11px 13px; font-size: 13px; line-height: 1.5; }
.asst-card h4 { margin: 0 0 4px; font-size: 13px; }
.asst-next { border: 1.5px solid var(--gold); background: var(--surface); }
.asst-bar { height: 7px; background: var(--line); border-radius: 99px; overflow: hidden; margin: 6px 0 8px; }
.asst-bar i { display: block; height: 100%; background: var(--teal); border-radius: 99px; transition: width .3s; }
.asst-steps { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 4px; }
.asst-steps li { display: flex; gap: 8px; align-items: center; font-size: 12.5px; cursor: pointer; padding: 3px 4px; border-radius: 6px; }
.asst-steps li:hover { background: rgba(0,0,0,.05); }
.asst-steps .tick { width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--line-dark, #bbb); display: grid; place-items: center; font-size: 11px; flex-shrink: 0; }
.asst-steps li.done .tick { background: var(--teal); border-color: var(--teal); color: #fff; }
.asst-steps li.done span { text-decoration: line-through; opacity: .6; }
.asst-msg { max-width: 92%; padding: 9px 12px; border-radius: 12px; font-size: 13px; line-height: 1.5; white-space: pre-wrap; }
.asst-msg.me { align-self: flex-end; background: var(--navy, #1C3A56); color: #fff; border-bottom-right-radius: 4px; }
.asst-msg.bot { align-self: flex-start; background: var(--parchment); border-bottom-left-radius: 4px; }
.asst-ai { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; background: #F6B35A; color: #241804; font-size: 10.5px; font-weight: 800; letter-spacing: .06em; vertical-align: 2px; }
.asst-dots { display: inline-flex; gap: 4px; padding: 4px 2px; }
.asst-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--text-soft); animation: asstBlink 1.1s infinite ease-in-out; }
.asst-dots i:nth-child(2) { animation-delay: .15s; } .asst-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes asstBlink { 0%, 80%, 100% { opacity: .25; transform: scale(.8); } 40% { opacity: 1; transform: scale(1); } }
.asst-prop { margin-top: 10px; padding: 10px 12px; border-radius: 10px; background: var(--surface); border: 1.5px solid var(--gold); }
.asst-prop.done { border-color: var(--line); }
.asst-prop ul { margin: 6px 0 2px; padding-left: 18px; font-size: 12.5px; line-height: 1.5; }
.asst-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.asst-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.asst-chip { padding: 5px 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--text); font-size: 12px; cursor: pointer; }
.asst-chip:hover { border-color: var(--gold); }
.asst-input { display: flex; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line); background: var(--surface); }
.asst-input input { flex: 1; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); color: var(--text); font-size: 14px; min-width: 0; }
@media (max-width: 560px) {
  #asstPanel { right: 8px; left: 8px; width: auto; max-width: none; bottom: 70px; }
  #asstFab span.lbl { display: none; }
  #asstFab { padding: 12px; }
}
@media print { #asstFab, #asstBubble, #asstPanel { display: none !important; } }

/* head teacher two-dashboard chooser */
.head-chooser { position: fixed; inset: 0; z-index: 9999; background: linear-gradient(160deg, #7f1d1d, #1e293b); display: flex; align-items: center; justify-content: center; padding: 20px; overflow: auto; }
.hc-box { max-width: 760px; width: 100%; text-align: center; color: #fff; }
.hc-box h1 { margin: 0 0 6px; font-size: 30px; } .hc-box p { margin: 0 0 22px; opacity: .85; }
.hc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.hc-card { background: #fff; color: #1e293b; border: 0; border-radius: 16px; padding: 24px 20px; text-align: left; cursor: pointer; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.3); transition: transform .15s; }
.hc-card:hover { transform: translateY(-3px); }
.hc-card b { font-size: 19px; color: #7f1d1d; } .hc-card span { font-size: 14px; line-height: 1.45; } .hc-card em { font-style: normal; background: #dc2626; color: #fff; border-radius: 999px; padding: 2px 10px; font-size: 12px; align-self: flex-start; }
.hc-box .hc-note { font-size: 13px; margin-top: 18px; opacity: .7; }
@media (max-width: 640px) { .hc-grid { grid-template-columns: 1fr; } }
.head-switch { margin: 4px 10px 10px; padding: 10px; border-radius: 10px; background: rgba(255,255,255,.12); display: flex; flex-direction: column; gap: 6px; font-size: 12px; }
.head-switch span { font-weight: 700; } .head-switch button { border: 0; border-radius: 8px; padding: 6px 8px; cursor: pointer; font-size: 12px; background: #fff; color: #7f1d1d; }

/* data safety chip */
.sync-chip { position: fixed; left: 14px; bottom: 14px; z-index: 40; border: 1px solid var(--line, #e5e7eb); background: #fff; color: #334155; border-radius: 999px; padding: 6px 12px; font-size: 12px; cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.sync-chip.ok::before, .sync-chip.wait::before, .sync-chip.bad::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 7px; background: #16a34a; }
.sync-chip.wait::before { background: #d97706; } .sync-chip.bad::before { background: #dc2626; }
@media (max-width: 700px) { .sync-chip { bottom: 70px; } }
/* results slips */
.slip-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.slip { border: 1px dashed #64748b; border-radius: 6px; padding: 10px 12px; font-size: 12px; break-inside: avoid; page-break-inside: avoid; background: #fff; color: #111; }
.slip-h { display: flex; justify-content: space-between; gap: 8px; border-bottom: 2px solid #7f1d1d; padding-bottom: 4px; margin-bottom: 6px; } .slip-h b { color: #7f1d1d; }
.slip-n { margin-bottom: 4px; } .slip table { width: 100%; border-collapse: collapse; } .slip td { border-bottom: 1px solid #e5e7eb; padding: 2px 4px; } .slip td:nth-child(n+2) { text-align: center; width: 15%; }
.slip-f { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 6px; } .slip-sig { margin-top: 10px; font-size: 11px; }
@media (max-width: 700px) { .slip-grid { grid-template-columns: 1fr; } }
.team-feed { list-style: none; margin: 8px 0 0; padding: 0; } .team-feed li { padding: 7px 0; border-bottom: 1px solid var(--line, #e5e7eb); font-size: 14px; } .team-feed em { font-style: normal; color: #64748b; font-size: 12px; margin-left: 6px; }

/* honour roll + certificates */
.hon-head { display: flex; justify-content: space-between; border-bottom: 2px solid #7f1d1d; padding-bottom: 6px; margin-bottom: 10px; } .hon-head b { color: #7f1d1d; } .hon-class { margin: 14px 0 6px; }
.cert { page-break-after: always; break-after: page; padding: 10mm; box-sizing: border-box; }
.cert-in { border: 6px double #7f1d1d; padding: 18mm 12mm; text-align: center; min-height: 230mm; display: flex; flex-direction: column; justify-content: center; gap: 12px; color: #1e293b; background: #fff; }
.cert-school { font-size: 26px; font-weight: 800; color: #7f1d1d; text-transform: uppercase; } .cert-motto { font-style: italic; }
.cert-title { font-size: 34px; font-weight: 800; margin: 16px 0; letter-spacing: 1px; } .cert-line { font-size: 17px; line-height: 1.6; }
.cert-name { font-size: 38px; font-weight: 800; border-bottom: 2px solid #1e293b; display: inline-block; margin: 8px auto; padding: 0 20px 4px; }
.cert-sigs { display: flex; justify-content: space-around; margin-top: 50px; font-weight: 700; } .cert-sigs span { font-weight: 400; font-size: 13px; border-top: 1px solid #1e293b; padding-top: 4px; display: inline-block; min-width: 150px; }
@media screen { .cert { padding: 0 0 14px; } .cert-in { min-height: 0; padding: 24px 14px; } }
/* head teacher management dashboard */
.hd-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; background: linear-gradient(135deg, #7f1d1d, #1e293b); color: #fff; border-radius: 16px; padding: 22px 24px; margin-bottom: 16px; }
.hd-head h2 { margin: 2px 0 6px; font-size: 26px; color: #fff; } .hd-head p { margin: 0; opacity: .85; max-width: 560px; } .hd-head .dash-hello { opacity: .8; }
.hd-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; margin-bottom: 16px; }
.hd-kpi { background: #fff; border: 1px solid var(--line, #e5e7eb); border-radius: 12px; padding: 14px; text-align: left; cursor: pointer; display: flex; flex-direction: column; gap: 4px; }
.hd-kpi:hover { border-color: #7f1d1d; } .hd-kpi b { font-size: 28px; line-height: 1.1; color: #7f1d1d; } .hd-kpi span { font-size: 13px; color: #475569; }
.hd-steps { list-style: none; margin: 8px 0 0; padding: 0; } .hd-steps li { padding: 8px 0; border-bottom: 1px solid var(--line, #e5e7eb); display: flex; align-items: center; gap: 10px; }
.hd-steps li span { width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: #e5e7eb; font-size: 12px; } .hd-steps li.ok span { background: #16a34a; color: #fff; } .hd-steps li .btn { margin-left: auto; }
.team-scope { display: flex; flex-direction: column; gap: 6px; margin-top: 4px; }

.as-types { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 10px; } .as-types-l { font-size: 12px; font-weight: 700; color: #475569; margin-right: 4px; }
.as-chip { background: #f1f5f9; border: 1px solid #e2e8f0; border-radius: 999px; padding: 3px 11px; font-size: 12px; } .as-chip.own { background: #fef3c7; border-color: #fcd34d; }

.notice-row { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--line, #e5e7eb); }

.slip-tag { background: #7f1d1d; color: #fff; font-weight: 800; font-size: 11px; letter-spacing: .6px; text-transform: uppercase; text-align: center; padding: 3px 6px; margin: -10px -12px 8px; border-radius: 5px 5px 0 0; }
