/* Nexora IMS admin - design system (palette taken from the logo: navy / blue / orange / gold) */
:root {
  --navy-900: #061538; --navy-800: #0A2057; --navy-700: #0B2A6B; --navy-600: #123a8c;
  --blue-600: #1E6FD9; --blue-500: #3B86EA; --blue-100: #E3EEFD; --blue-50: #F1F6FE;
  --orange-600: #FF6A00; --orange-500: #F7931E; --orange-100: #FFEFD9; --gold: #FDB515;
  --ink: #0F1B3D; --ink-2: #3A4766; --muted: #6B7794; --line: #E2E8F3; --line-2: #EEF2F9;
  --bg: #F4F7FC; --card: #FFFFFF;
  --green: #12A150; --green-bg: #E4F7EC; --red: #E5484D; --red-bg: #FDECEC; --amber: #D98200; --amber-bg: #FFF3DC; --violet: #7C3AED; --violet-bg: #F0E9FE;
  --radius: 14px; --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(15,27,61,.06), 0 1px 3px rgba(15,27,61,.04);
  --shadow: 0 6px 24px rgba(15,27,61,.08), 0 2px 6px rgba(15,27,61,.04);
  --shadow-lg: 0 24px 60px rgba(6,21,56,.22);
  --font: "Inter", "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
  --grad-accent: linear-gradient(135deg, #FFA43A 0%, #FF6A00 100%);
  --grad-navy: linear-gradient(145deg, #061538 0%, #0B2A6B 58%, #14489f 100%);
  --side-w: 264px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 14px/1.5 var(--font); color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4, p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--blue-600); text-decoration: none; }
img { max-width: 100%; }
[hidden] { display: none !important; }
svg.i { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; flex: none; }
::selection { background: rgba(30,111,217,.2); }
:focus-visible { outline: 2px solid var(--blue-500); outline-offset: 2px; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #CBD5E6; border-radius: 8px; border: 2px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: #AEBBD4; background-clip: content-box; border: 2px solid transparent; }

/* ---------- boot splash ---------- */
.splash { position: fixed; inset: 0; z-index: 200; display: none; place-items: center; align-content: center; gap: 20px; background: #fff; }
body.booting .splash { display: grid; }
.splash img { width: 150px; animation: pop .9s ease-in-out infinite alternate; }
.splash-bar { width: 120px; height: 4px; border-radius: 4px; background: var(--line); overflow: hidden; }
.splash-bar i { display: block; height: 100%; width: 40%; border-radius: 4px; background: var(--grad-accent); animation: slide 1s ease-in-out infinite; }
@keyframes pop { from { transform: scale(.96); opacity: .85 } to { transform: scale(1.02); opacity: 1 } }
@keyframes slide { from { margin-left: -40% } to { margin-left: 100% } }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 11px; border: 1px solid transparent; font-weight: 600; font-size: 13.5px; white-space: nowrap; transition: transform .12s, box-shadow .15s, background .15s, border-color .15s; user-select: none; }
.btn:active { transform: translateY(1px); }
.btn[disabled] { opacity: .55; pointer-events: none; }
.btn-accent { color: #fff; background: var(--grad-accent); box-shadow: 0 6px 16px rgba(255,106,0,.28); }
.btn-accent:hover { box-shadow: 0 8px 22px rgba(255,106,0,.38); filter: brightness(1.03); }
.btn-navy { color: #fff; background: var(--navy-700); }
.btn-navy:hover { background: var(--navy-600); }
.btn-ghost { color: var(--ink-2); background: #fff; border-color: var(--line); }
.btn-ghost:hover { border-color: #C5D1E6; background: var(--blue-50); }
.btn-soft { color: var(--blue-600); background: var(--blue-100); }
.btn-soft:hover { background: #D5E5FB; }
.btn-danger { color: #fff; background: var(--red); }
.btn-danger:hover { filter: brightness(1.06); }
.btn-danger-ghost { color: var(--red); background: #fff; border-color: #F6CFD1; }
.btn-danger-ghost:hover { background: var(--red-bg); }
.btn-sm { height: 32px; padding: 0 11px; font-size: 12.5px; border-radius: 9px; }
.btn-lg { height: 46px; padding: 0 22px; font-size: 14.5px; }
/* a button that is working shows a spinner and "Please wait..." in place of its label */
.btn.is-busy { position: relative; pointer-events: none; font-size: 0 !important; display: inline-flex; align-items: center; justify-content: center; gap: 9px; }
.btn.is-busy > * { display: none !important; }
.btn.is-busy::before, .spin { content: ""; flex: none; width: 16px; height: 16px; border-radius: 50%; border: 2.5px solid rgba(255,255,255,.4); border-top-color: #fff; animation: rot .7s linear infinite; }
.btn.is-busy::after { content: "Please wait..."; font-size: 14px; font-weight: 600; color: #fff; white-space: nowrap; }
.btn-ghost.is-busy::before, .btn-soft.is-busy::before { border-color: rgba(11,42,107,.2); border-top-color: var(--navy-700); }
.btn-ghost.is-busy::after, .btn-soft.is-busy::after { color: var(--navy-700); }
@keyframes rot { to { transform: rotate(360deg) } }
.icon-btn { width: 36px; height: 36px; display: inline-grid; place-items: center; border-radius: 10px; border: 1px solid transparent; background: transparent; color: var(--ink-2); transition: background .15s, color .15s; }
.icon-btn:hover { background: var(--blue-100); color: var(--blue-600); }
.icon-btn.danger:hover { background: var(--red-bg); color: var(--red); }
.icon-btn.sm { width: 30px; height: 30px; border-radius: 8px; }
.icon-btn[disabled] { opacity: .35; pointer-events: none; }

/* ---------- forms ---------- */
.field { display: grid; gap: 6px; align-content: start; min-width: 0; }
.field > label, .lab { font-size: 12.5px; font-weight: 600; color: var(--ink-2); display: flex; align-items: center; gap: 6px; }
.field .req { color: var(--orange-600); }
.hint { font-size: 12px; color: var(--muted); line-height: 1.45; }
.input, .select, .textarea { width: 100%; height: 42px; padding: 0 13px; background: #fff; border: 1.5px solid var(--line); border-radius: 11px; transition: border-color .15s, box-shadow .15s; outline: none; min-width: 0; }
.textarea { height: auto; min-height: 84px; padding: 11px 13px; resize: vertical; line-height: 1.5; }
.select { appearance: none; padding-right: 34px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236B7794' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 11px center; }
.input:hover, .select:hover, .textarea:hover { border-color: #C5D1E6; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--blue-500); box-shadow: 0 0 0 4px rgba(59,134,234,.16); }
/* searchable dropdown (js/select2.js) */
.s2-btn { display: block; text-align: left; cursor: pointer; line-height: 1; white-space: nowrap; overflow: hidden; }
.s2-btn .s2-label { display: block; overflow: hidden; text-overflow: ellipsis; line-height: 39px; }
.filters .s2-btn .s2-label { line-height: 35px; }
#pgSize + .s2-btn .s2-label { line-height: 31px; }
.s2-btn .s2-ph { color: #9AA6C0; }
.s2-btn:disabled { background-color: #F4F7FC; color: #9AA6C0; cursor: not-allowed; }
.s2-btn.s2-open { border-color: var(--blue-500); box-shadow: 0 0 0 4px rgba(59,134,234,.16); }
.s2-panel { position: fixed; z-index: 1000; background: #fff; border: 1.5px solid var(--line); border-radius: 13px; box-shadow: var(--shadow-lg); overflow: hidden; animation: s2in .12s ease both; transform-origin: top center; }
.s2-panel.up { transform-origin: bottom center; }
@keyframes s2in { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }
.s2-search { position: relative; padding: 8px; border-bottom: 1px solid var(--line-2); background: #F8FAFE; }
.s2-search .s2-sic { position: absolute; left: 19px; top: 50%; transform: translateY(-50%); color: var(--muted); display: grid; pointer-events: none; }
.s2-search input { width: 100%; height: 36px; padding: 0 12px 0 36px; border: 1.5px solid var(--line); border-radius: 9px; background: #fff; outline: none; font-size: 13.5px; }
.s2-search input:focus { border-color: var(--blue-500); box-shadow: 0 0 0 3px rgba(59,134,234,.14); }
.s2-list { overflow-y: auto; padding: 5px; overscroll-behavior: contain; }
.s2-opt { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 11px; border-radius: 9px; font-size: 13.5px; font-weight: 500; color: var(--ink); cursor: pointer; }
.s2-opt .s2-t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.s2-opt mark { background: rgba(253,181,21,.38); color: inherit; border-radius: 3px; padding: 0 1px; }
.s2-opt.act { background: #EAF2FE; }
.s2-opt.sel { color: var(--navy-700); font-weight: 700; }
.s2-opt .s2-ck { color: var(--blue-500); display: grid; flex: none; }
.s2-opt.dis { color: #B3BDD3; cursor: not-allowed; }
.s2-empty { padding: 18px 12px; text-align: center; color: var(--muted); font-size: 13px; }
.input.bad, .select.bad, .rte.bad { border-color: var(--red); box-shadow: 0 0 0 4px rgba(229,72,77,.12); }
.input::placeholder, .textarea::placeholder { color: #9AA6C0; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.span2 { grid-column: span 2; }
.seg { display: inline-flex; padding: 3px; background: var(--line-2); border-radius: 12px; gap: 2px; border: 1px solid var(--line); }
.seg button { border: 0; background: transparent; height: 34px; padding: 0 14px; border-radius: 9px; font-weight: 600; font-size: 13px; color: var(--ink-2); display: inline-flex; align-items: center; gap: 7px; transition: all .15s; }
.seg button:hover { color: var(--ink); }
.seg button.on { background: #fff; color: var(--navy-700); box-shadow: var(--shadow-sm); }
.seg button.on.easy { color: var(--green); } .seg button.on.medium { color: var(--amber); } .seg button.on.hard { color: var(--red); }
.seg.full { display: flex; } .seg.full button { flex: 1; justify-content: center; }
.switch { display: flex; align-items: center; gap: 12px; cursor: pointer; padding: 10px 0; }
.switch input { display: none; }
.switch .tr { width: 40px; height: 23px; border-radius: 20px; background: #CBD5E6; position: relative; flex: none; transition: background .2s; }
.switch .tr::after { content: ""; position: absolute; top: 3px; left: 3px; width: 17px; height: 17px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
.switch input:checked + .tr { background: var(--blue-600); }
.switch input:checked + .tr::after { transform: translateX(17px); }
.switch b { display: block; font-size: 13.5px; font-weight: 600; } .switch small { color: var(--muted); font-size: 12px; }
.chk { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; }
.chk input { appearance: none; width: 18px; height: 18px; border: 1.8px solid #B9C5DC; border-radius: 5px; background: #fff; display: inline-grid; place-items: center; cursor: pointer; transition: all .12s; margin: 0; flex: none; }
.chk input:checked, .chk input:indeterminate { background: var(--blue-600); border-color: var(--blue-600); }
.chk input:checked::after { content: ""; width: 9px; height: 5px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translate(1px,-1px); }
.chk input:indeterminate::after { content: ""; width: 8px; height: 2px; background: #fff; }

/* ---------- login gate ---------- */
.gate { position: fixed; inset: 0; z-index: 100; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(420px, .85fr); background: #fff; }
.gate-art { position: relative; overflow: hidden; background: var(--grad-navy); color: #fff; }
.gate-art::before { content: ""; position: absolute; inset: 0; background: radial-gradient(900px 500px at 15% 0%, rgba(59,134,234,.35), transparent 60%), radial-gradient(700px 500px at 100% 100%, rgba(247,147,30,.22), transparent 60%); }
.orb { position: absolute; border-radius: 50%; filter: blur(2px); }
.orb.o1 { width: 420px; height: 420px; right: -140px; top: -120px; background: radial-gradient(circle at 30% 30%, rgba(255,255,255,.14), rgba(255,255,255,0) 70%); animation: float 9s ease-in-out infinite; }
.orb.o2 { width: 260px; height: 260px; left: -80px; bottom: 120px; background: radial-gradient(circle at 40% 40%, rgba(247,147,30,.35), rgba(247,147,30,0) 70%); animation: float 11s ease-in-out infinite reverse; }
.orb.o3 { width: 120px; height: 120px; left: 46%; top: 12%; background: radial-gradient(circle, rgba(253,181,21,.35), transparent 70%); animation: float 7s ease-in-out infinite; }
@keyframes float { 0%,100% { transform: translateY(0) } 50% { transform: translateY(-18px) } }
.gate-dots { position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.14) 1.2px, transparent 1.2px); background-size: 26px 26px; mask-image: linear-gradient(120deg, #000 0%, transparent 65%); -webkit-mask-image: linear-gradient(120deg, #000 0%, transparent 65%); }
.gate-swoosh { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 36%; }
.gate-art-inner { position: relative; z-index: 2; height: 100%; padding: clamp(32px, 5vw, 64px); display: flex; flex-direction: column; justify-content: center; max-width: 720px; margin: 0 auto; }
.gate-brand { display: flex; align-items: center; gap: 12px; position: absolute; top: clamp(28px, 4vw, 48px); left: clamp(32px, 5vw, 64px); }
.gate-brand b, .side-brand b { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.gate-brand b em, .side-brand b em { font-style: normal; color: var(--orange-500); }
.brand-chip { width: 46px; height: 46px; border-radius: 13px; background: #fff; display: grid; place-items: center; box-shadow: 0 6px 18px rgba(0,0,0,.2); flex: none; }
.brand-chip img { width: 36px; height: auto; }
.gate-kicker { font-size: 12px; letter-spacing: .22em; text-transform: uppercase; font-weight: 700; color: var(--orange-500); margin-bottom: 14px; }
.gate-art h2 { font-size: clamp(32px, 3.6vw, 52px); line-height: 1.08; font-weight: 800; letter-spacing: -.03em; }
.gate-art h2 em { font-style: normal; background: linear-gradient(90deg, #FFB547, #FF6A00); -webkit-background-clip: text; background-clip: text; color: transparent; }
.gate-lead { margin-top: 18px; max-width: 480px; font-size: 16px; line-height: 1.6; color: rgba(255,255,255,.78); }
.gate-points { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 12px; }
.gate-points li { display: flex; align-items: center; gap: 12px; color: rgba(255,255,255,.9); font-weight: 500; }
.gate-points li span { width: 24px; height: 24px; border-radius: 50%; background: rgba(247,147,30,.2); border: 1px solid rgba(247,147,30,.6); display: grid; place-items: center; flex: none; }
.gate-points svg, .fc-opts svg { width: 13px; height: 13px; fill: none; stroke: var(--orange-500); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.gate-tag { position: absolute; left: clamp(32px, 5vw, 64px); bottom: clamp(26px, 4vw, 44px); font-weight: 700; font-style: italic; letter-spacing: .02em; color: rgba(255,255,255,.88); display: flex; align-items: center; gap: 10px; }
.gate-tag i { width: 6px; height: 6px; border-radius: 50%; background: var(--orange-500); }
.float-card { position: absolute; background: rgba(255,255,255,.96); color: var(--ink); border-radius: 16px; box-shadow: 0 24px 50px rgba(0,0,0,.28); }
.fc-q { right: clamp(24px, 4vw, 56px); top: 9%; width: 290px; padding: 16px 18px; animation: float 8s ease-in-out infinite; }
.fc-head { display: flex; align-items: center; gap: 6px; margin-bottom: 10px; font-size: 12px; }
.fc-head b { color: var(--navy-700); margin-right: 2px; }
.fc-tag { padding: 2px 8px; border-radius: 20px; background: var(--blue-100); color: var(--blue-600); font-weight: 600; font-size: 11px; }
.fc-tag.fc-easy { background: var(--green-bg); color: var(--green); }
.fc-marks { margin-left: auto; font-weight: 800; color: var(--orange-600); }
.fc-q p { font-weight: 600; font-size: 15px; margin-bottom: 12px; }
.fc-opts { display: grid; gap: 6px; }
.fc-opts span { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; border: 1.5px solid var(--line); border-radius: 10px; font-size: 13px; font-weight: 500; }
.fc-opts span.on { border-color: var(--green); background: var(--green-bg); color: var(--green); font-weight: 700; }
.fc-opts span.on svg { stroke: var(--green); }
.fc-pub { right: clamp(40px, 6vw, 110px); bottom: 15%; padding: 12px 16px; display: flex; align-items: center; gap: 12px; animation: float 10s ease-in-out infinite reverse; }
.fc-pub b { display: block; font-size: 13.5px; } .fc-pub small { color: var(--muted); font-size: 12px; }
.fc-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 5px rgba(18,161,80,.18); }
.gate-panel { display: grid; place-items: center; padding: 32px; background: #fff; overflow-y: auto; }
.gate-box { width: 100%; max-width: 400px; animation: rise .5s ease both; }
@keyframes rise { from { opacity: 0; transform: translateY(14px) } to { opacity: 1; transform: none } }
.gate-logo { display: block; width: 250px; max-width: 80%; margin: 0 auto 26px; }
.gate-box h1 { font-size: 28px; font-weight: 800; letter-spacing: -.025em; color: var(--navy-800); text-align: center; }
.gate-sub { text-align: center; color: var(--muted); margin: 6px 0 26px; }
.gl { display: block; font-size: 12.5px; font-weight: 700; color: var(--ink-2); margin: 16px 0 7px; }
.gf { position: relative; display: flex; align-items: center; }
.gf > svg { position: absolute; left: 14px; width: 18px; height: 18px; fill: none; stroke: #8794B2; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; transition: stroke .15s; }
.gf input { width: 100%; height: 50px; padding: 0 46px 0 44px; border: 1.5px solid var(--line); border-radius: 13px; background: #F8FAFE; outline: none; font-size: 15px; transition: all .15s; }
.gf input:hover { border-color: #C5D1E6; }
.gf input:focus { border-color: var(--blue-500); background: #fff; box-shadow: 0 0 0 4px rgba(59,134,234,.16); }
.gf:focus-within > svg { stroke: var(--blue-600); }
.gf-eye { position: absolute; right: 6px; width: 38px; height: 38px; border: 0; background: transparent; border-radius: 10px; display: grid; place-items: center; }
.gf-eye svg { width: 19px; height: 19px; fill: none; stroke: #8794B2; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.gf-eye:hover { background: var(--blue-100); } .gf-eye.on svg { stroke: var(--blue-600); }
.gl-caps { margin-top: 8px; font-size: 12px; font-weight: 600; color: var(--amber); }
.gate-row { margin: 16px 0 4px; display: flex; justify-content: space-between; align-items: center; }
.gcheck { display: inline-flex; align-items: center; gap: 9px; font-size: 13.5px; font-weight: 500; color: var(--ink-2); cursor: pointer; }
.gcheck input { display: none; }
.gcheck span { width: 19px; height: 19px; border-radius: 6px; border: 1.8px solid #B9C5DC; display: grid; place-items: center; transition: all .12s; }
.gcheck input:checked + span { background: var(--blue-600); border-color: var(--blue-600); }
.gcheck input:checked + span::after { content: ""; width: 9px; height: 5px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translate(1px,-1px); }
.gate-err { margin: 14px 0 0; padding: 11px 14px; border-radius: 11px; background: var(--red-bg); color: #B42328; font-weight: 600; font-size: 13px; border: 1px solid #F6CFD1; }
.gate-err.shake { animation: shake .4s; }
.gate-forgot { font-size: 13px; font-weight: 700; color: var(--blue-600); text-decoration: none; padding: 6px 0 6px 10px; }
.gate-forgot:hover { text-decoration: underline; }
#fpForm[hidden] { display: none; }
.fp-ok { margin: 8px 0 0; padding: 10px 12px; border-radius: 12px; background: #EAF8F1; border: 1px solid #BFE6D2; color: #0E6B45; font-size: 12.5px; line-height: 1.45; }
.fp-links { display: flex; justify-content: space-between; gap: 12px; margin-top: 14px; }
.fp-links a { font-size: 13px; font-weight: 700; color: var(--blue-600); text-decoration: none; padding: 4px 0; }
.fp-links a:hover { text-decoration: underline; }
@keyframes shake { 20%,60% { transform: translateX(-6px) } 40%,80% { transform: translateX(6px) } }
.gate-go { position: relative; width: 100%; height: 52px; margin-top: 20px; border: 0; border-radius: 14px; background: var(--grad-accent); color: #fff; font-weight: 700; font-size: 15.5px; letter-spacing: .01em; display: grid; place-items: center; box-shadow: 0 10px 26px rgba(255,106,0,.34); transition: transform .12s, box-shadow .15s, filter .15s; }
.gate-go:hover { box-shadow: 0 14px 32px rgba(255,106,0,.45); filter: brightness(1.04); }
.gate-go:active { transform: translateY(1px); }
.gate-go .spin { display: none; }
.gate-go.is-busy { pointer-events: none; display: flex; align-items: center; justify-content: center; gap: 10px; }
.gate-go.is-busy .spin { display: block; order: -1; position: static; }
.gate-go.is-busy span { font-size: 0; }
.gate-go.is-busy span::before { content: "Please wait..."; font-size: 15.5px; }
.ag-sheet .gate-go.is-busy span::after { content: none; }
.gate-foot { margin-top: 26px; display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--muted); font-size: 12.5px; }
.gate-foot svg { width: 16px; height: 16px; fill: none; stroke: var(--green); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- app shell ---------- */
.app { min-height: 100vh; }
.side { position: fixed; inset: 0 auto 0 0; width: var(--side-w); z-index: 50; display: flex; flex-direction: column; background: linear-gradient(180deg, #071A45 0%, #0A2057 100%); color: #fff; transition: transform .25s ease; }
.side::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 220px; pointer-events: none; background: radial-gradient(240px 160px at 20% 100%, rgba(247,147,30,.18), transparent 70%); }
.side-brand { display: flex; align-items: center; gap: 12px; padding: 22px 20px 18px; color: #fff; }
.side-brand small { display: block; margin-top: 1px; font-size: 11px; color: rgba(255,255,255,.55); letter-spacing: .12em; text-transform: uppercase; font-weight: 600; }
.side-nav { flex: 1; overflow-y: auto; padding: 6px 12px 12px; position: relative; z-index: 1; }
.nav-group { margin: 18px 10px 8px; font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; font-weight: 700; color: rgba(255,255,255,.4); }
.nav-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; margin-bottom: 2px; border: 0; background: transparent; border-radius: 11px; color: rgba(255,255,255,.72); font-weight: 600; font-size: 13.5px; text-align: left; position: relative; transition: background .15s, color .15s; }
.nav-item:hover { background: rgba(255,255,255,.07); color: #fff; }
.nav-item.on { background: rgba(255,255,255,.12); color: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.08); }
.nav-item.on::before { content: ""; position: absolute; left: -12px; top: 9px; bottom: 9px; width: 4px; border-radius: 0 4px 4px 0; background: var(--grad-accent); }
.nav-item.on .i { color: var(--orange-500); }
.nav-item .count { margin-left: auto; font-size: 11px; font-weight: 700; padding: 1px 8px; border-radius: 20px; background: rgba(255,255,255,.12); color: rgba(255,255,255,.85); }
.side-foot { position: relative; z-index: 1; display: flex; align-items: center; gap: 6px; padding: 14px; border-top: 1px solid rgba(255,255,255,.09); }
.side-user { flex: 1; min-width: 0; display: flex; align-items: center; gap: 11px; padding: 6px; border-radius: 12px; color: #fff; }
.side-user:hover { background: rgba(255,255,255,.07); }
.side-user strong { display: block; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 130px; }
.side-user small { color: rgba(255,255,255,.5); font-size: 11.5px; }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--grad-accent); display: grid; place-items: center; font-weight: 800; color: #fff; flex: none; font-size: 15px; box-shadow: 0 0 0 3px rgba(255,255,255,.12); }
.side-out { width: 38px; height: 38px; border-radius: 11px; border: 0; background: rgba(255,255,255,.07); color: rgba(255,255,255,.8); display: grid; place-items: center; }
.side-out:hover { background: rgba(229,72,77,.25); color: #fff; }
.scrim { position: fixed; inset: 0; background: rgba(6,21,56,.5); backdrop-filter: blur(2px); z-index: 45; }
.main { margin-left: var(--side-w); min-height: 100vh; display: flex; flex-direction: column; min-width: 0; }
.top { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 16px; padding: 14px 28px; background: rgba(244,247,252,.86); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.menu-btn { display: none; border: 1px solid var(--line); background: #fff; }
.top-copy { min-width: 0; }
.top-kicker { font-size: 11.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--orange-600); }
.top h1 { font-size: 21px; font-weight: 800; letter-spacing: -.02em; color: var(--navy-800); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-search { position: relative; margin-left: auto; width: min(340px, 30vw); }
.top-search input { width: 100%; height: 40px; padding: 0 14px 0 40px; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; outline: none; }
.top-search input:focus { border-color: var(--blue-500); box-shadow: 0 0 0 4px rgba(59,134,234,.14); }
.ts-ic { position: absolute; left: 12px; top: 11px; color: #8794B2; pointer-events: none; }
.top-clock { text-align: right; line-height: 1.15; padding: 0 4px; }
.top-clock span { display: block; font-size: 11.5px; color: var(--muted); font-weight: 500; }
.top-clock b { font-size: 16px; font-weight: 800; color: var(--navy-700); font-variant-numeric: tabular-nums; }
.view { padding: 26px 28px 60px; max-width: 1480px; width: 100%; outline: none; animation: rise .35s ease both; }

/* ---------- cards / layout ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.card-pad { padding: 20px 22px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 22px 16px; }
.card-head h2, .card-title { font-size: 15.5px; font-weight: 800; letter-spacing: -.01em; color: var(--navy-800); }
.card-sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.card-body { padding: 16px 22px 22px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head h2 { font-size: 24px; font-weight: 800; letter-spacing: -.025em; color: var(--navy-800); }
.page-head p { color: var(--muted); margin-top: 3px; }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.spacer { flex: 1; }
.stack { display: grid; gap: 18px; }

/* ---------- dashboard ---------- */
.hero { position: relative; overflow: hidden; border-radius: 18px; padding: 26px 30px; color: #fff; background: var(--grad-navy); box-shadow: var(--shadow); display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 20px; }
.hero::before { content: ""; position: absolute; right: -60px; top: -90px; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(circle, rgba(247,147,30,.35), transparent 65%); }
.hero::after { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.1) 1px, transparent 1px); background-size: 22px 22px; mask-image: linear-gradient(100deg, transparent 30%, #000); -webkit-mask-image: linear-gradient(100deg, transparent 30%, #000); }
.hero > * { position: relative; z-index: 1; }
.hero h2 { font-size: 26px; font-weight: 800; letter-spacing: -.025em; }
.hero p { color: rgba(255,255,255,.75); margin-top: 4px; max-width: 520px; }
.hero .btn-ghost { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.22); }
.hero .btn-ghost:hover { background: rgba(255,255,255,.2); }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(188px, 1fr)); gap: 12px; margin-bottom: 16px; }
.kpi { position: relative; padding: 18px 20px; display: flex; flex-direction: column; gap: 4px; overflow: hidden; transition: transform .15s, box-shadow .15s; }
.kpi:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.kpi-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 10px; }
.kpi-ic .i { width: 21px; height: 21px; }
.kpi b { font-size: 30px; font-weight: 800; letter-spacing: -.03em; color: var(--navy-800); line-height: 1.1; font-variant-numeric: tabular-nums; }
.kpi span { font-size: 13px; color: var(--muted); font-weight: 500; }
.kpi em { font-style: normal; font-size: 12px; font-weight: 700; margin-top: 4px; }
.t-blue { background: var(--blue-100); color: var(--blue-600); } .t-orange { background: var(--orange-100); color: var(--orange-600); }
.t-green { background: var(--green-bg); color: var(--green); } .t-violet { background: var(--violet-bg); color: var(--violet); }
.t-amber { background: var(--amber-bg); color: var(--amber); } .t-red { background: var(--red-bg); color: var(--red); }
.dash-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 18px; }
.c-8 { grid-column: span 8; } .c-7 { grid-column: span 7; } .c-6 { grid-column: span 6; } .c-5 { grid-column: span 5; } .c-4 { grid-column: span 4; } .c-12 { grid-column: span 12; }
.chart { padding: 8px 14px 16px; }
.chart svg { width: 100%; height: auto; display: block; overflow: visible; }
.chart .gridl { stroke: var(--line-2); stroke-width: 1; } .chart .axis { fill: var(--muted); font-size: 10.5px; font-family: var(--font); }
.chart .pt { fill: #fff; stroke: var(--blue-600); stroke-width: 2.4; transition: r .15s; } .chart .pt:hover { r: 6; }
.donut-wrap { display: flex; align-items: center; gap: 22px; padding: 14px 22px 22px; flex-wrap: wrap; justify-content: center; }
.donut { position: relative; width: 150px; height: 150px; flex: none; }
.donut svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.donut .ctr { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.donut .ctr b { font-size: 26px; font-weight: 800; color: var(--navy-800); line-height: 1; } .donut .ctr span { font-size: 11.5px; color: var(--muted); }
.legend { display: grid; gap: 9px; flex: 1; min-width: 130px; }
.legend div { display: flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 500; }
.legend i { width: 10px; height: 10px; border-radius: 3px; flex: none; } .legend b { margin-left: auto; font-variant-numeric: tabular-nums; }
.bars { display: grid; gap: 13px; padding: 16px 22px 22px; }
.bar-row { display: grid; grid-template-columns: 120px 1fr 38px; align-items: center; gap: 12px; font-size: 13px; }
.bar-row > span:first-child { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-track { height: 10px; background: var(--line-2); border-radius: 10px; overflow: hidden; }
.bar-fill { height: 100%; border-radius: 10px; transition: width .8s cubic-bezier(.2,.8,.2,1); width: 0; }
.bar-row b { text-align: right; font-variant-numeric: tabular-nums; }
.list { display: grid; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 22px; border-top: 1px solid var(--line-2); transition: background .12s; color: inherit; }
.list-item:first-child { border-top: 0; }
a.list-item:hover { background: var(--blue-50); }
.list-item .grow { flex: 1; min-width: 0; }
.list-item .ttl { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--ink); }
.list-item .sub { font-size: 12px; color: var(--muted); }
.dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.tl-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; }
.tl-ic .i { width: 16px; height: 16px; }
.quick { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-bottom: 20px; }
.qa { display: flex; align-items: center; gap: 14px; padding: 16px 18px; color: var(--ink); transition: all .15s; }
.qa:hover { border-color: var(--blue-500); box-shadow: var(--shadow); transform: translateY(-2px); }
.qa .kpi-ic { margin: 0; flex: none; } .qa b { display: block; font-size: 14px; } .qa small { color: var(--muted); font-size: 12px; }

/* ---------- table, badges, filters ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 14px 16px; }
.filters .input, .filters .select { height: 38px; width: auto; min-width: 140px; font-size: 13.5px; }
.filters .search { position: relative; flex: 1 1 240px; }
.filters .search .input { width: 100%; padding-left: 38px; }
.filters .search .i { position: absolute; left: 12px; top: 10px; color: #8794B2; pointer-events: none; }
.tbl-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13.5px; }
.tbl th { text-align: left; font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; font-weight: 700; color: var(--muted); padding: 11px 14px; background: #F8FAFE; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 13px 14px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.tbl tbody tr { transition: background .1s; }
.tbl tbody tr:hover { background: var(--blue-50); }
.tbl tbody tr.sel { background: #EAF2FE; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl .num { text-align: right; font-variant-numeric: tabular-nums; }
.tbl .qtxt { font-weight: 600; color: var(--ink); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 520px; cursor: pointer; }
.tbl .qtxt:hover { color: var(--blue-600); }
.tbl .qmeta { font-size: 12px; color: var(--muted); margin-top: 3px; display: flex; gap: 10px; align-items: center; }
.tbl .acts { display: flex; gap: 2px; justify-content: flex-end; opacity: .55; transition: opacity .15s; }
.tbl tr:hover .acts { opacity: 1; }
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 20px; font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.plain::before { display: none; }
.b-easy { background: var(--green-bg); color: var(--green); } .b-medium { background: var(--amber-bg); color: var(--amber); } .b-hard { background: var(--red-bg); color: var(--red); }
.b-Published, .b-live { background: var(--green-bg); color: var(--green); } .b-Draft { background: #EDF0F7; color: #5A6783; } .b-Archived, .b-Closed { background: var(--violet-bg); color: var(--violet); }
.b-type { background: var(--blue-100); color: var(--blue-600); }
.pill { display: inline-flex; align-items: center; gap: 7px; padding: 3px 10px 3px 8px; border-radius: 8px; background: #F2F5FB; font-size: 12.5px; font-weight: 600; color: var(--ink-2); max-width: 170px; }
.pill i { width: 8px; height: 8px; border-radius: 50%; flex: none; } .pill span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bulk { position: sticky; bottom: 18px; z-index: 20; margin: 16px auto 0; width: fit-content; max-width: 100%; display: flex; align-items: center; gap: 8px; padding: 10px 12px 10px 18px; border-radius: 16px; background: var(--navy-800); color: #fff; box-shadow: var(--shadow-lg); flex-wrap: wrap; animation: rise .25s ease both; }
.bulk b { margin-right: 6px; }
.bulk .btn-ghost { background: rgba(255,255,255,.1); color: #fff; border-color: rgba(255,255,255,.18); } .bulk .btn-ghost:hover { background: rgba(255,255,255,.2); }
.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; flex-wrap: wrap; border-top: 1px solid var(--line-2); }
.pager .pg { display: flex; gap: 4px; }
.pager .pg button { min-width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line); background: #fff; font-weight: 600; color: var(--ink-2); padding: 0 8px; }
.pager .pg button:hover { border-color: var(--blue-500); color: var(--blue-600); } .pager .pg button.on { background: var(--navy-700); border-color: var(--navy-700); color: #fff; } .pager .pg button[disabled] { opacity: .4; pointer-events: none; }
.empty { text-align: center; padding: 56px 24px; }
.empty .em-ic { width: 76px; height: 76px; border-radius: 22px; margin: 0 auto 16px; display: grid; place-items: center; background: var(--blue-100); color: var(--blue-600); }
.empty .em-ic .i { width: 34px; height: 34px; }
.empty h3 { font-size: 18px; font-weight: 800; color: var(--navy-800); } .empty p { color: var(--muted); margin: 6px auto 18px; max-width: 380px; }
.skel { background: linear-gradient(90deg, #EEF2F9 25%, #F7F9FD 37%, #EEF2F9 63%); background-size: 400% 100%; animation: shimmer 1.3s infinite; border-radius: 10px; }
@keyframes shimmer { 0% { background-position: 100% 0 } 100% { background-position: 0 0 } }

/* ---------- question editor ---------- */
.ed { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 22px; align-items: start; }
.ed-main { display: grid; gap: 18px; min-width: 0; }
.ed-side { position: sticky; top: 92px; display: grid; gap: 18px; }
.sec-num { width: 26px; height: 26px; border-radius: 8px; background: var(--navy-700); color: #fff; font-size: 12.5px; font-weight: 800; display: grid; place-items: center; flex: none; }
.card-head .row { gap: 10px; }
.type-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.type-card { border: 1.5px solid var(--line); background: #fff; border-radius: 13px; padding: 12px 10px 11px; text-align: center; transition: all .15s; display: grid; gap: 6px; justify-items: center; }
.type-card .tc-ic { width: 36px; height: 36px; border-radius: 11px; background: var(--blue-50); color: var(--blue-600); display: grid; place-items: center; transition: all .15s; }
.type-card b { font-size: 12.5px; line-height: 1.2; } .type-card small { font-size: 11px; color: var(--muted); line-height: 1.25; }
.type-card:hover { border-color: #AFC4E6; transform: translateY(-1px); }
.type-card.on { border-color: var(--blue-600); background: var(--blue-50); box-shadow: 0 0 0 3px rgba(30,111,217,.12); }
.type-card.on .tc-ic { background: var(--blue-600); color: #fff; }
.rte-wrap { border: 1.5px solid var(--line); border-radius: 12px; overflow: hidden; background: #fff; transition: border-color .15s, box-shadow .15s; }
.rte-wrap:focus-within { border-color: var(--blue-500); box-shadow: 0 0 0 4px rgba(59,134,234,.16); }
.rte-wrap.bad { border-color: var(--red); box-shadow: 0 0 0 4px rgba(229,72,77,.12); }
.rte-bar { display: flex; flex-wrap: wrap; gap: 2px; padding: 6px; background: #F8FAFE; border-bottom: 1px solid var(--line); align-items: center; }
.rte-bar button { width: 32px; height: 32px; border-radius: 8px; border: 0; background: transparent; color: var(--ink-2); display: grid; place-items: center; font-weight: 700; }
.rte-bar button:hover { background: var(--blue-100); color: var(--blue-600); } .rte-bar button.on { background: var(--blue-100); color: var(--blue-600); }
.rte-bar .sep { width: 1px; height: 20px; background: var(--line); margin: 0 5px; }
.rte-bar .grow { flex: 1; } .rte-bar small { color: var(--muted); padding-right: 8px; font-size: 11.5px; font-variant-numeric: tabular-nums; }
.rte { min-height: 120px; max-height: 360px; overflow-y: auto; padding: 13px 15px; outline: none; font-size: 15px; line-height: 1.6; }
.rte.sm { min-height: 76px; font-size: 14px; }
.rte:empty::before { content: attr(data-ph); color: #9AA6C0; pointer-events: none; }
.rte code, .prev-q code { font-family: Consolas, "Cascadia Mono", monospace; background: #EEF2FA; padding: 1px 6px; border-radius: 5px; font-size: .92em; }
.rte pre, .prev-q pre { background: #0F1B3D; color: #E6EDFF; padding: 10px 14px; border-radius: 10px; overflow-x: auto; }
.rte ul, .rte ol, .prev-q ul, .prev-q ol { margin: 6px 0; padding-left: 24px; }
.img-up { margin-top: 12px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.img-drop { flex: 1; min-width: 220px; border: 1.8px dashed #BFCCE3; border-radius: 12px; padding: 14px 16px; display: flex; align-items: center; gap: 12px; color: var(--ink-2); background: #FAFCFF; transition: all .15s; cursor: pointer; }
.img-drop:hover, .img-drop.drag { border-color: var(--blue-500); background: var(--blue-50); }
.img-drop .kpi-ic { margin: 0; width: 38px; height: 38px; } .img-drop b { display: block; font-size: 13px; } .img-drop small { color: var(--muted); font-size: 12px; }
.img-thumb { position: relative; width: 150px; height: 96px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: #F2F5FB; }
.img-thumb img { width: 100%; height: 100%; object-fit: cover; }
.img-thumb button { position: absolute; top: 5px; right: 5px; width: 26px; height: 26px; border-radius: 50%; border: 0; background: rgba(6,21,56,.75); color: #fff; display: grid; place-items: center; }
.opts { display: grid; gap: 10px; }
.opt { display: grid; grid-template-columns: 34px 1fr auto auto; gap: 10px; align-items: center; padding: 8px 8px 8px 10px; border: 1.5px solid var(--line); border-radius: 13px; background: #fff; transition: all .15s; }
.opt:focus-within { border-color: var(--blue-500); box-shadow: 0 0 0 4px rgba(59,134,234,.12); }
.opt.ok { border-color: #8AD9AB; background: #F4FCF7; }
.opt.bad { border-color: var(--red); }
.opt-l { width: 32px; height: 32px; border-radius: 9px; background: var(--blue-100); color: var(--navy-700); display: grid; place-items: center; font-weight: 800; font-size: 13px; }
.opt.ok .opt-l { background: var(--green); color: #fff; }
.opt input.opt-t { border: 0; outline: none; background: transparent; height: 34px; min-width: 0; font-size: 14.5px; }
.opt-ok { display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 12px; border-radius: 9px; border: 1.5px solid var(--line); background: #fff; font-weight: 700; font-size: 12.5px; color: var(--muted); transition: all .15s; }
.opt-ok:hover { border-color: var(--green); color: var(--green); }
.opt.ok .opt-ok { background: var(--green); border-color: var(--green); color: #fff; }
.tf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.tf-btn { display: flex; align-items: center; justify-content: center; gap: 10px; height: 74px; border-radius: 14px; border: 2px solid var(--line); background: #fff; font-size: 18px; font-weight: 800; color: var(--ink-2); transition: all .15s; }
.tf-btn:hover { border-color: #AFC4E6; }
.tf-btn.on { border-color: var(--green); background: var(--green-bg); color: var(--green); box-shadow: 0 0 0 4px rgba(18,161,80,.12); }
.tf-btn.on.f { border-color: var(--red); background: var(--red-bg); color: var(--red); box-shadow: 0 0 0 4px rgba(229,72,77,.1); }
.presets { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 7px; }
.chip { border: 1px solid var(--line); background: #fff; border-radius: 20px; padding: 3px 11px; font-size: 12px; font-weight: 600; color: var(--ink-2); }
.chip:hover { border-color: var(--blue-500); color: var(--blue-600); } .chip.on { background: var(--blue-100); border-color: var(--blue-100); color: var(--blue-600); }
.prev { overflow: hidden; }
.prev-top { display: flex; align-items: center; gap: 8px; padding: 14px 18px; background: var(--grad-navy); color: #fff; font-size: 12.5px; }
.prev-top b { font-weight: 700; } .prev-top .spacer { flex: 1; }
.prev-top .pm { background: rgba(255,255,255,.14); padding: 3px 10px; border-radius: 20px; font-weight: 700; font-size: 11.5px; }
.prev-top .pm.pos { background: rgba(18,161,80,.35); } .prev-top .pm.neg { background: rgba(229,72,77,.38); }
.prev-body { padding: 18px; }
.prev-q { font-size: 15.5px; font-weight: 600; line-height: 1.55; word-break: break-word; }
.prev-q:empty::before { content: "Your question will appear here..."; color: #A8B3CB; font-weight: 500; }
.prev-img { margin: 12px 0 0; border-radius: 12px; max-height: 190px; object-fit: contain; background: #F2F5FB; width: 100%; border: 1px solid var(--line); }
.prev-opts { display: grid; gap: 9px; margin-top: 16px; }
.prev-opt { display: flex; align-items: center; gap: 12px; padding: 11px 13px; border: 1.5px solid var(--line); border-radius: 12px; font-weight: 500; word-break: break-word; transition: all .2s; }
.prev-opt .mk { width: 20px; height: 20px; border: 2px solid #B9C5DC; flex: none; display: grid; place-items: center; }
.prev-opt .mk.r { border-radius: 50%; } .prev-opt .mk.s { border-radius: 6px; }
.prev-opt.ok { border-color: var(--green); background: var(--green-bg); }
.prev-opt.ok .mk { background: var(--green); border-color: var(--green); }
.prev-opt.ok .mk::after { content: ""; width: 9px; height: 5px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translate(1px,-1px); }
.prev-opt .ltr { color: var(--muted); font-weight: 700; width: 16px; }
.prev-ans { margin-top: 14px; padding: 12px 14px; border-radius: 12px; background: #F6F9FF; border: 1px dashed #BFD1F0; font-size: 13px; }
.prev-ans b { color: var(--green); }
.prev-input { margin-top: 16px; height: 44px; border: 1.5px dashed #BFCCE3; border-radius: 12px; padding: 0 14px; display: flex; align-items: center; color: #9AA6C0; background: #FAFCFF; }
.prev-expl { margin-top: 14px; padding: 12px 14px; border-radius: 12px; background: var(--amber-bg); font-size: 13px; color: #6B4700; }
.prev-foot { display: flex; align-items: center; justify-content: space-between; padding: 10px 18px 14px; color: var(--muted); font-size: 12.5px; }
.check-list { display: grid; gap: 9px; padding: 4px 22px 20px; }
.check-list div { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 500; color: var(--muted); }
.check-list .ck { width: 20px; height: 20px; border-radius: 50%; border: 2px solid #CBD5E6; display: grid; place-items: center; flex: none; transition: all .2s; }
.check-list .ck .i { width: 12px; height: 12px; stroke-width: 3.2; opacity: 0; color: #fff; }
.check-list div.ok { color: var(--ink); } .check-list div.ok .ck { background: var(--green); border-color: var(--green); } .check-list div.ok .ck .i { opacity: 1; }
.save-card .btn { width: 100%; } .save-card .grid2 { gap: 10px; }
.progress { height: 6px; background: var(--line-2); border-radius: 6px; overflow: hidden; margin: 0 22px 16px; }
.progress i { display: block; height: 100%; background: var(--grad-accent); border-radius: 6px; transition: width .4s; }
.banner { padding: 12px 16px; border-radius: 12px; font-weight: 600; font-size: 13.5px; display: flex; gap: 10px; align-items: flex-start; }
.banner.err { background: var(--red-bg); color: #B42328; border: 1px solid #F6CFD1; } .banner.info { background: var(--blue-50); color: var(--navy-700); border: 1px solid #CFE0FA; } .banner.warn { background: var(--amber-bg); color: #8A5300; border: 1px solid #F5DFAE; }
.tagbox { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; min-height: 42px; padding: 5px 8px; border: 1.5px solid var(--line); border-radius: 11px; background: #fff; }
.tagbox:focus-within { border-color: var(--blue-500); box-shadow: 0 0 0 4px rgba(59,134,234,.16); }
.tagbox .tg { display: inline-flex; align-items: center; gap: 4px; padding: 3px 4px 3px 10px; background: var(--blue-100); color: var(--blue-600); border-radius: 20px; font-size: 12.5px; font-weight: 600; }
.tagbox .tg button { width: 18px; height: 18px; border: 0; border-radius: 50%; background: transparent; color: inherit; display: grid; place-items: center; padding: 0; } .tagbox .tg button:hover { background: rgba(30,111,217,.18); }
.tagbox input { flex: 1; min-width: 100px; border: 0; outline: none; height: 30px; background: transparent; }

/* ---------- subjects ---------- */
.subj-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 18px; }
.subj { overflow: hidden; display: flex; flex-direction: column; }
.subj-bar { height: 6px; }
.subj-head { display: flex; align-items: center; gap: 12px; padding: 16px 18px 6px; }
.subj-ic { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 13px; flex: none; }
.subj-head h3 { font-size: 16px; font-weight: 800; color: var(--navy-800); } .subj-head small { color: var(--muted); font-size: 12.5px; }
.subj-topics { padding: 8px 18px 6px; display: flex; flex-wrap: wrap; gap: 7px; flex: 1; align-content: flex-start; }
.topic { display: inline-flex; align-items: center; gap: 4px; padding: 4px 5px 4px 11px; background: #F2F5FB; border-radius: 20px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.topic em { font-style: normal; color: var(--muted); font-weight: 500; font-size: 11.5px; margin-left: 3px; }
.topic button { width: 20px; height: 20px; border: 0; background: transparent; border-radius: 50%; display: grid; place-items: center; color: #8794B2; padding: 0; } .topic button:hover { background: var(--red-bg); color: var(--red); }
.subj-add { display: flex; gap: 8px; padding: 10px 18px 14px; } .subj-add .input { height: 36px; font-size: 13px; }
.subj-foot { display: flex; align-items: center; gap: 6px; padding: 10px 14px 12px 18px; border-top: 1px solid var(--line-2); background: #FAFCFF; }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; }
.swatch { width: 30px; height: 30px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1.5px var(--line); }
.swatch.on { box-shadow: 0 0 0 2.5px var(--navy-700); }

/* ---------- exams ---------- */
.ex { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 22px; align-items: start; }
.ex-q { display: grid; grid-template-columns: 28px 1fr auto; gap: 10px; align-items: center; padding: 11px 14px; border-top: 1px solid var(--line-2); }
.ex-q:first-child { border-top: 0; }
.ex-q .no { width: 26px; height: 26px; border-radius: 8px; background: var(--blue-100); color: var(--blue-600); font-weight: 800; font-size: 12px; display: grid; place-items: center; }
.ex-q .t { font-weight: 600; font-size: 13.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ex-q .m { display: flex; gap: 6px; align-items: center; margin-top: 4px; flex-wrap: wrap; }
.ex-q .mk { width: 64px; height: 30px; padding: 0 6px; text-align: center; font-size: 13px; font-weight: 700; border-radius: 8px; }
.ex-q .ctrl { display: flex; align-items: center; gap: 2px; }
.summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 16px 22px; }
.summary div { background: var(--blue-50); border-radius: 12px; padding: 12px; text-align: center; }
.summary b { display: block; font-size: 22px; font-weight: 800; color: var(--navy-800); } .summary span { font-size: 11.5px; color: var(--muted); font-weight: 600; }
.pick-row { display: grid; grid-template-columns: 22px 1fr auto; gap: 12px; align-items: center; padding: 12px 18px; border-top: 1px solid var(--line-2); cursor: pointer; }
.pick-row:hover { background: var(--blue-50); } .pick-row.off { opacity: .45; pointer-events: none; }
.pick-row .t { font-weight: 600; font-size: 13.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------- import ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 18px; }
.step { display: flex; gap: 12px; align-items: center; padding: 14px 16px; border-radius: 14px; background: #fff; border: 1px solid var(--line); }
.step .sn { width: 32px; height: 32px; border-radius: 50%; background: var(--blue-100); color: var(--blue-600); font-weight: 800; display: grid; place-items: center; flex: none; }
.step.on { border-color: var(--blue-500); box-shadow: 0 0 0 3px rgba(59,134,234,.12); } .step.on .sn { background: var(--blue-600); color: #fff; }
.step.done .sn { background: var(--green); color: #fff; } .step b { display: block; font-size: 13.5px; } .step small { color: var(--muted); font-size: 12px; }
.dropzone { border: 2px dashed #BFCCE3; border-radius: 16px; padding: 44px 20px; text-align: center; background: #FAFCFF; cursor: pointer; transition: all .15s; }
.dropzone:hover, .dropzone.drag { border-color: var(--blue-500); background: var(--blue-50); }
.dropzone .em-ic { width: 64px; height: 64px; border-radius: 18px; margin: 0 auto 12px; display: grid; place-items: center; background: var(--blue-100); color: var(--blue-600); }
.dropzone b { font-size: 16px; display: block; color: var(--navy-800); } .dropzone p { color: var(--muted); margin-top: 4px; }
.cols-help { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; } .cols-help code { background: #EEF2FA; padding: 2px 8px; border-radius: 6px; font-size: 12px; color: var(--navy-700); }
.row-ok, .row-bad { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: #fff; }
.row-ok { background: var(--green); } .row-bad { background: var(--red); } .row-ok .i, .row-bad .i { width: 12px; height: 12px; stroke-width: 3.2; }

/* ---------- modal + toast ---------- */
.modal-back { position: fixed; inset: 0; z-index: 120; background: rgba(6,21,56,.55); backdrop-filter: blur(3px); display: grid; place-items: center; padding: 20px; animation: fade .15s ease both; }
@keyframes fade { from { opacity: 0 } to { opacity: 1 } }
.modal { background: #fff; border-radius: 20px; width: 100%; max-width: 480px; max-height: calc(100vh - 40px); display: flex; flex-direction: column; box-shadow: var(--shadow-lg); animation: pop-in .22s cubic-bezier(.2,.9,.3,1.2) both; overflow: hidden; }
.modal.lg { max-width: 780px; } .modal.xl { max-width: 920px; }
@keyframes pop-in { from { opacity: 0; transform: translateY(16px) scale(.97) } to { opacity: 1; transform: none } }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 20px 24px 8px; }
.modal-head h3 { font-size: 18px; font-weight: 800; letter-spacing: -.01em; color: var(--navy-800); }
.modal-body { padding: 8px 24px 20px; overflow-y: auto; }
.modal-body.flush { padding: 0; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 24px 20px; border-top: 1px solid var(--line-2); align-items: center; }
.modal .ic-big { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; margin-bottom: 12px; } .modal .ic-big .i { width: 28px; height: 28px; }
.toasts { position: fixed; right: 20px; bottom: 20px; z-index: 300; display: grid; gap: 10px; width: min(380px, calc(100vw - 40px)); pointer-events: none; }
.toast { pointer-events: auto; display: flex; align-items: flex-start; gap: 12px; padding: 13px 14px; border-radius: 14px; background: var(--navy-800); color: #fff; box-shadow: var(--shadow-lg); animation: toast-in .3s cubic-bezier(.2,.9,.3,1.1) both; font-size: 13.5px; font-weight: 500; }
.toast .ti { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; flex: none; }
.toast .ti .i { width: 15px; height: 15px; stroke-width: 3; }
.toast.ok .ti { background: var(--green); } .toast.err .ti { background: var(--red); } .toast.info .ti { background: var(--blue-500); }
.toast.out { animation: toast-out .25s ease both; } .toast b { display: block; font-weight: 700; margin-bottom: 1px; }
@keyframes toast-in { from { opacity: 0; transform: translateX(30px) } to { opacity: 1; transform: none } }
@keyframes toast-out { to { opacity: 0; transform: translateX(30px) } }

/* ---------- responsive ---------- */
@media (max-width: 1240px) { .float-card { display: none; } }
@media (max-width: 1200px) { .top-clock { display: none; } .top-search { width: clamp(160px, 24vw, 300px); } .top { padding-left: 20px; padding-right: 20px; } }
@media (max-width: 1280px) {
  .ed { grid-template-columns: minmax(0, 1fr) 340px; } .ex { grid-template-columns: minmax(0, 1fr) 360px; }
  .c-8, .c-7 { grid-column: span 12; } .c-5, .c-4 { grid-column: span 6; }
}
@media (max-width: 1080px) {
  .ed, .ex { grid-template-columns: 1fr; } .ed-side { position: static; }
  .top-search { display: none; } .top-clock { margin-left: auto; }
}
@media (max-width: 960px) {
  .side { transform: translateX(-100%); box-shadow: var(--shadow-lg); } .side.open { transform: none; }
  .main { margin-left: 0; } .menu-btn { display: inline-grid; } .top { padding: 12px 16px; } .view { padding: 18px 16px 60px; }
  .gate { grid-template-columns: 1fr; grid-template-rows: auto 1fr; overflow-y: auto; }
  .gate-art { min-height: 0; } .gate-art-inner { padding: 22px 22px 24px; } .gate-brand { position: static; margin-bottom: 14px; }
  .gate-art h2 { font-size: 26px; } .gate-lead, .gate-points, .float-card, .gate-tag, .gate-swoosh { display: none; } .gate-kicker { margin-bottom: 8px; }
  .gate-panel { padding: 28px 20px 40px; align-items: start; } .gate-logo { width: 170px; margin-bottom: 18px; }
}
@media (max-width: 700px) {
  .grid2, .grid3, .grid4 { grid-template-columns: 1fr; } .span2 { grid-column: auto; }
  .type-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .type-grid .type-card:last-child { grid-column: span 2; }
  .c-5, .c-4, .c-6 { grid-column: span 12; } .top-clock, .top-new span { display: none; } .top-new { width: 40px; padding: 0; }
  .opt { grid-template-columns: 30px 1fr auto; } .opt-ok span { display: none; } .opt-ok { padding: 0 9px; }
  .steps { grid-template-columns: 1fr; } .hero { padding: 20px; } .hero h2 { font-size: 21px; }
  .tbl .hide-sm { display: none; } .bar-row { grid-template-columns: 90px 1fr 32px; } .summary { grid-template-columns: repeat(3, 1fr); padding: 14px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; } }
@media print { .side, .top, .toasts { display: none; } .main { margin: 0; } }

/* ===== centre / organisation profile ===== */
.cp { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 18px; align-items: start; max-width: 1100px; }
.cp-side { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; position: sticky; top: 84px; min-width: 0; }
.cp-side .card, .cp-prev, .cp-idc, .cp-bar { min-width: 0; max-width: 100%; }
.cp-form { display: grid; gap: 16px; }
.cp-logo { width: 148px; height: 148px; margin: 4px auto 14px; border-radius: 28px; display: grid; place-items: center; overflow: hidden; background: repeating-conic-gradient(#EEF2FA 0 25%, #fff 0 50%) 0 0 / 16px 16px; border: 1px solid var(--line); box-shadow: 0 10px 28px rgba(11,42,107,.12); }
.cp-logo img { width: 100%; height: 100%; object-fit: contain; }
.cp-logo:not(.has) { background: none; border: 0; box-shadow: none; }
.cp-mono { width: 100%; height: 100%; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 54px; letter-spacing: -.03em; background: linear-gradient(135deg, hsl(var(--h) 82% 56%), hsl(calc(var(--h) + 40) 80% 42%)); border-radius: 28px; box-shadow: 0 10px 28px hsla(var(--h) 80% 30% / .35), inset 0 1px 0 rgba(255,255,255,.35); }
.cp-mono.sm { width: 34px; height: 34px; flex: none; font-size: 13px; border-radius: 11px; box-shadow: none; }
.cp-btns { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.cp-btns label { cursor: pointer; }
.cp-cap { font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.cp-prev { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.cp-bar { display: flex; align-items: center; gap: 10px; padding: 8px 12px 8px 8px; border-radius: 16px; background: #fff; border: 1px solid var(--line); box-shadow: 0 4px 14px rgba(11,42,107,.07); min-width: 0; }
.cp-bar > span:last-child { min-width: 0; } .cp-bar b { display: block; font-size: 14px; color: var(--navy-800, #0B2A6B); line-height: 1.2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-bar small { display: block; font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-pimg { width: 34px; height: 34px; flex: none; object-fit: contain; border-radius: 10px; background: #fff; }
.cp-idc { border-radius: 18px; padding: 12px; color: #fff; background: linear-gradient(135deg, #061538, #0B2A6B 60%, #1B4CA8); box-shadow: 0 10px 24px rgba(6,21,56,.25); }
.cp-idc-top { display: flex; align-items: center; gap: 8px; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; } .cp-idc-top i { font-style: normal; font-weight: 800; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .cp-idc-top em { font-style: normal; opacity: .7; flex: none; }
.cp-idc .cp-pimg { background: #fff; padding: 2px; }
.cp-idc-body { display: flex; align-items: center; gap: 10px; margin-top: 12px; } .cp-idc-body b { display: block; font-size: 14px; } .cp-idc-body small { letter-spacing: .12em; opacity: .75; font-size: 11px; }
.cp-av { width: 40px; height: 40px; border-radius: 14px; background: rgba(255,255,255,.18); border: 2px solid rgba(255,255,255,.7); }
.cp-idc-foot { margin-top: 10px; padding-top: 8px; border-top: 1px dashed rgba(255,255,255,.25); font-size: 11px; opacity: .8; }
.cp-fe { display: block; margin-top: 5px; color: var(--red) !important; font-weight: 600; }
.cp-fe[hidden] { display: none; }
.cp-save { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 4px 2px 20px; }
@media (max-width: 900px) { .cp { grid-template-columns: minmax(0, 1fr); } .cp-side { position: static; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); } }
@media (max-width: 600px) { .cp .grid2 { grid-template-columns: 1fr; } }

/* inline field error (add/edit student and other forms) */
.fe { display: block; margin-top: 5px; color: var(--red); font-weight: 600; font-size: 12.5px; }
.fe[hidden] { display: none; }

/* centre branding: the organisation's name and logo replace Nexora IMS in the portals (see EP.applyOrg / paintOrg) */
.bc-name { display: block; min-width: 0; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 22px; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; }
.side-brand .sb-txt { min-width: 0; flex: 1; }
.side-brand .bc-name { font-size: 17px; }
.gate-brand { max-width: 70%; }
.gate-brand > .bc-name { display: block; }
.brand-chip .bc-img { width: 100%; height: 100%; padding: 5px; box-sizing: border-box; object-fit: contain; border-radius: 13px; }
.brand-chip .bc-mono { width: 100%; height: 100%; display: grid; place-items: center; border-radius: 13px; background: linear-gradient(135deg, #FFB13B, #FF6B3D); color: #fff; font-weight: 800; font-size: 16px; letter-spacing: -.02em; }
.gate-org { display: flex; flex-direction: column; align-items: center; text-align: center; margin: 0 auto 26px; max-width: 80%; }
.gate-org[hidden] { display: none; }
.gate-org .brand-chip { width: 84px; height: 84px; border-radius: 24px; margin-bottom: 14px; }
.gate-org .brand-chip .bc-mono { font-size: 28px; border-radius: 24px; }
.gate-org .bc-name { white-space: normal; overflow: visible; font-size: 22px; }
.gate-org small { margin-top: 6px; color: var(--muted); font-size: 13.5px; }

/* branch sign-in: no question bank, so no question search or "New question" shortcut */

/* ---------- super admin: organisations, and the strip shown while one is open ---------- */
body.is-branch .top-search, body.is-branch .top-new { display: none !important; }
body.is-super .top-search, body.is-super .top-new { display: none !important; }
.org-code-pill { display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: .06em; padding: 2px 8px; border-radius: 6px; background: var(--blue-100); color: var(--blue-600); }
.act-bar { display: flex; align-items: center; gap: 12px; padding: 9px 22px; background: linear-gradient(90deg, #0B2A6B, #1E4FA8); color: #fff; font-size: 13.5px; position: sticky; top: 0; z-index: 30; }
.act-bar .ab-ic { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: rgba(255,255,255,.16); flex: none; }
.act-bar .ab-ic .i { width: 16px; height: 16px; }
.act-bar .ab-t { flex: 1; min-width: 0; }
.act-bar .ab-t b { font-weight: 800; }
.act-bar .btn { background: #fff; color: var(--navy-800); border-color: #fff; flex: none; }
.act-bar .btn:hover { background: #EAF1FF; }
.of-h { margin: 12px 0 2px; font-size: 14px; font-weight: 800; color: var(--navy-800); padding-top: 8px; border-top: 1px solid var(--line); }
.of-h:first-child { border-top: 0; margin-top: 0; padding-top: 0; }
.org-form .hint { display: block; margin-top: 4px; }
.cred { display: grid; gap: 8px; background: var(--bg, #F5F8FD); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.cred > div { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.cred span { font-size: 11.5px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.cred b { font-size: 13.5px; color: var(--navy-800); word-break: break-all; user-select: all; }
@media (max-width: 640px) { .act-bar { padding: 8px 14px; flex-wrap: wrap; } }
/* ---------- enquiries, follow-ups and admissions ---------- */
.seg.scroll { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg.scroll::-webkit-scrollbar { display: none; }
.seg.scroll button { flex: none; white-space: nowrap; }
.seg button small { font-size: 11.5px; font-weight: 700; }
.kvgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px 16px; background: var(--bg, #F5F8FD); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.kvgrid > div { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.kvgrid span { font-size: 11.5px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.kvgrid b { font-size: 13.5px; color: var(--navy-800); font-weight: 600; word-break: break-word; }
.note-box { margin-top: 10px; padding: 10px 14px; border-radius: 12px; background: var(--amber-bg); color: #6B4500; font-size: 13.5px; line-height: 1.5; }
.fu-list { display: grid; gap: 0; position: relative; }
.fu { display: flex; gap: 12px; padding-bottom: 14px; position: relative; }
.fu:not(:last-child)::before { content: ""; position: absolute; left: 15px; top: 34px; bottom: 0; width: 2px; background: var(--line); }
.fu-dot { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; background: var(--blue-100); color: var(--blue-600); }
.fu-dot.ok { background: var(--green-bg); color: var(--green); }
.fu-dot .i { width: 16px; height: 16px; }
.fu-main { min-width: 0; flex: 1; }
.fu-top { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.fu-top b { font-size: 13.5px; color: var(--navy-800); }
.fu-top span { font-size: 12.5px; color: var(--muted); }
.fu-main p { margin: 3px 0 6px; font-size: 13.5px; color: var(--ink-2); line-height: 1.5; word-break: break-word; }
.fu-meta { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); }
.chips .chip { cursor: pointer; }
@media (max-width: 640px) { .grid3 { grid-template-columns: 1fr; } }
.select[hidden], .input[hidden] { display: none !important; }

.select[hidden], .input[hidden] { display: none !important; }
/* admission slip format (Admissions > Slip format, enquiry.js) */
.modal.sl-wide { max-width: 1100px; }
.sl { display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 22px; align-items: start; }
.sl-h { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; font-weight: 800; color: var(--muted); margin: 16px 0 6px; padding-top: 12px; border-top: 1px solid var(--line-2); }
.sl-h:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.sl-prev { position: sticky; top: 0; }
.sl-cap { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; font-weight: 800; color: var(--muted); margin-bottom: 8px; }
.sl-frame { position: relative; overflow: hidden; width: 100%; background: #E9EDF5; border: 1px solid var(--line); border-radius: 12px; }
.sl-frame iframe { position: absolute; left: 0; top: 0; width: 794px; height: 1123px; border: 0; transform-origin: 0 0; background: #fff; }
.switch.slim { padding: 6px 0; }
.switch.is-dis, .field.is-dis { opacity: .45; }
.field.is-dis .input { cursor: not-allowed; }
@media (max-width: 860px) { .sl { grid-template-columns: 1fr; } .sl-prev { position: static; } }
/* ---- Fees and reports ---- */
.card-head h3 { font-size: 15.5px; font-weight: 800; letter-spacing: -.01em; color: var(--navy-800); margin: 0; }
.fp { height: 5px; width: 100%; min-width: 90px; background: var(--line-2); border-radius: 4px; overflow: hidden; margin-top: 5px; }
.fp i { display: block; height: 100%; background: var(--green); border-radius: 4px; }
.fp-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.fh-k { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 4px; }
.fh-k .nxk { padding: 12px; gap: 9px; min-height: 74px; } .fh-k .nxk-ic { width: 34px; height: 34px; } .fh-k .nxk-ic .i { width: 18px; height: 18px; } .fh-k .nxk b { font-size: 18px; }
@media (max-width: 720px) { .fh-k { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.rp-filter { margin-bottom: 16px; }
.rp-filter .filters { gap: 10px; align-items: center; flex-wrap: wrap; }
.rp-dates { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; }
.rp-dates .input { width: 150px; }
.rp-asof { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--ink-2); font-weight: 600; }
.rp-asof .i { width: 16px; height: 16px; }
.rp-when { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; color: var(--ink-2); font-size: 13.5px; }
.rp-when .i { width: 17px; height: 17px; color: var(--blue-600); }
.rp-when span { color: var(--muted); }
.rp-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 16px 0; }
.rp-card { padding-bottom: 16px; }
.rp-wide { grid-column: 1 / -1; }
.rp-bars { padding: 10px 22px 0; display: grid; gap: 4px; }
.rp-bar { display: grid; grid-template-columns: minmax(80px, 34%) 1fr auto; align-items: center; gap: 4px 12px; padding: 4px 0; font-size: 13px; }
.rp-l { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; color: var(--ink-2); }
.rp-t { height: 10px; background: var(--line-2); border-radius: 6px; overflow: hidden; }
.rp-t i { display: block; height: 100%; background: linear-gradient(90deg, var(--blue-500), var(--blue-600)); border-radius: 6px; }
.rp-bar b { font-variant-numeric: tabular-nums; color: var(--navy-800); }
.rp-bar small { grid-column: 2 / 4; color: var(--muted); font-size: 11.5px; margin-top: -2px; }
.rp-cols { display: flex; align-items: flex-end; gap: 5px; height: 190px; padding: 12px 22px 0; }
.rp-col { flex: 1; min-width: 0; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; }
.rp-col i { display: block; width: 100%; max-width: 38px; min-height: 2px; background: linear-gradient(180deg, var(--blue-500), var(--blue-600)); border-radius: 6px 6px 0 0; }
.rp-col em { font-style: normal; font-size: 10.5px; color: var(--ink-2); font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.rp-col span { font-size: 10.5px; color: var(--muted); white-space: nowrap; }
.rp-cols.dense .rp-col span { display: none; }
.rp-s { font-size: 12.5px; color: var(--muted); }
.rp-tbl tfoot td { background: var(--blue-50); border-top: 2px solid var(--line); }
@media (max-width: 860px) { .rp-grid { grid-template-columns: minmax(0, 1fr); } .rp-bars, .rp-cols { padding-left: 16px; padding-right: 16px; } .rp-dates .input { width: 135px; } }

/* ---------- messaging (Settings > Messaging, and the send bar in dialogs) ---------- */
.textarea.bad { border-color: var(--red); box-shadow: 0 0 0 4px rgba(229,72,77,.12); }
.mg-page .card-head { gap: 14px; flex-wrap: wrap; }
.mg-page .card.mg-off .card-body { opacity: .62; }
.mg-page code { background: var(--line-2); border-radius: 5px; padding: 1px 5px; font-size: 11.5px; color: var(--navy-700); }
.mg-test { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; padding-top: 14px; border-top: 1px dashed var(--line); }
.mg-test .field { flex: 1 1 240px; max-width: 360px; }
.mg-saved { font-weight: 500; color: var(--green); font-size: 12px; }
.mg-saved a { color: var(--red); margin-left: 4px; }
.mg-c { text-align: center; width: 110px; }
.mg-auto td, .mg-auto th { vertical-align: middle; }
.mg-vars { display: flex; flex-wrap: wrap; gap: 6px; }
.mg-var { border: 1px solid var(--line); background: #fff; border-radius: 999px; height: 28px; padding: 0 11px; font-size: 12px; font-weight: 600; color: var(--navy-700); cursor: pointer; font-family: ui-monospace, Consolas, monospace; }
.mg-var:hover { background: var(--blue-50); border-color: #B9D1F5; }
.mg-tpl { display: grid; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg, #F5F8FD); }
.mg-tpl h3 { margin: 0; font-size: 14.5px; color: var(--navy-800); }
.mg-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 14px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.mg-lab { font-size: 11.5px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.mg-bar .btn.mg-ok { color: var(--green); border-color: #BFE5CF; background: var(--green-bg); }
.mg-bar .btn.mg-bad { color: #B42328; border-color: #F6CFD1; background: var(--red-bg); }
.mg-none { display: flex; gap: 8px; align-items: flex-start; margin: 12px 0 0; }
.mg-none .i { flex: none; margin-top: 2px; }

/* ---------- messaging preview ---------- */
.mg-kind { flex: 0 1 230px; }
.mg-pv-top { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.mg-pv-top .field { flex: 1 1 220px; max-width: 280px; }
.mg-pv { background: var(--bg, #F5F8FD); border: 1px solid var(--line); border-radius: 14px; padding: 16px; min-height: 160px; }
.pv-mail { background: #fff; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.pv-mh { display: grid; gap: 6px; padding: 12px 16px; border-bottom: 1px solid var(--line-2); font-size: 13px; color: var(--ink-2); }
.pv-mh span { display: inline-block; width: 62px; color: var(--muted); font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.pv-mh b { color: var(--navy-800); }
.pv-mb { padding: 16px; font-size: 14px; line-height: 1.65; color: #1B2540; word-break: break-word; }
.pv-wa { background: #E7DFD4; border-radius: 12px; padding: 16px; }
.pv-sms { background: #fff; border-radius: 12px; padding: 16px; border: 1px solid var(--line); }
.pv-bub { position: relative; max-width: 420px; padding: 9px 12px 7px; border-radius: 4px 12px 12px 12px; background: #fff; box-shadow: 0 1px 1px rgba(0,0,0,.12); font-size: 13.5px; line-height: 1.5; color: #1B2540; word-break: break-word; }
.pv-wa .pv-bub { margin-left: auto; background: #DCF8C6; border-radius: 12px 4px 12px 12px; }
.pv-sms .pv-bub { background: #EDF0F7; box-shadow: none; }
.pv-bub small { display: block; text-align: right; margin-top: 3px; font-size: 10.5px; color: #7A849C; }
.mg-pv-send { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line); }
.mg-pv-send .field { flex: 1 1 240px; max-width: 360px; }

/* fee payment plan */
.fh-h { margin: 16px 0 8px; font-size: 14px; font-weight: 800; color: var(--navy-700); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.fh-h small { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.fh-plan { margin: 8px 0; }
.fh-pt { margin-bottom: 4px; }
.fh-pt .tbl td, .fh-pt .tbl th { padding-top: 9px; padding-bottom: 9px; }
/* certificates and marksheets */
.dc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; padding: 18px; }
.dc-card { border: 1px solid var(--line); border-radius: 16px; background: #fff; overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow-sm); }
.dc-card.off { opacity: .65; }
.dc-thumb { background: repeating-conic-gradient(#EEF1F7 0 25%, #F7F9FC 0 50%) 0 0/16px 16px; display: flex; align-items: center; justify-content: center; min-height: 150px; max-height: 170px; overflow: hidden; padding: 10px; border-bottom: 1px solid var(--line-2); }
.dc-th-ph { color: var(--muted); } .dc-th-ph svg { width: 34px; height: 34px; }
.dc-sc { position: relative; overflow: hidden; background: #fff; box-shadow: 0 1px 8px rgba(20, 30, 60, .2); flex: none; }
.dc-meta { padding: 12px 14px 4px; display: flex; flex-direction: column; gap: 3px; }
.dc-meta small { color: var(--muted); font-size: 12.5px; line-height: 1.4; }
.dc-acts { display: flex; gap: 6px; padding: 10px 14px 14px; align-items: center; flex-wrap: wrap; }
.dc-exams { padding: 14px 18px; border-top: 1px solid var(--line-2); display: flex; flex-direction: column; gap: 10px; }
.dc-exlist { display: flex; flex-wrap: wrap; gap: 8px; }
.dc-ex { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 10px; padding: 7px 11px; font-size: 13px; cursor: pointer; background: #fff; }
.dc-ex:has(input:checked) { border-color: var(--accent, #F97316); background: #FFF6EE; }
.dc-ex small { color: var(--muted); }
.dc-extras { padding: 14px 18px 4px; border-top: 1px solid var(--line-2); display: flex; flex-direction: column; gap: 12px; }
.dc-bar { position: sticky; bottom: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 18px; background: #fff; border-top: 1px solid var(--line); border-radius: 0 0 16px 16px; }
.dc-bar .sel-n { font-weight: 700; color: var(--ink-2); font-size: 13.5px; }
.dc-pv { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 18px; }
.dc-pv-main { min-width: 0; }
.dc-pv-nav { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; min-height: 30px; }
.dc-pv-stage { background: #E9EDF5; border-radius: 12px; padding: 12px; display: flex; justify-content: center; align-items: flex-start; min-height: 220px; max-height: 46vh; overflow: auto; }
.dc-pv-side { min-width: 0; }
@media (max-width: 860px) { .dc-pv { grid-template-columns: 1fr; } }

/* designer */
.dg { display: flex; flex-direction: column; height: calc(100vh - 118px); min-height: 520px; margin: -4px -4px 0; }
.dg-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 8px 10px; background: #fff; border: 1px solid var(--line); border-radius: 14px 14px 0 0; }
.dg-name { max-width: 280px; height: 34px; font-weight: 700; }
.dg-sp { flex: 1; }
.dg-sel-s { height: 34px; width: auto; min-width: 96px; padding-top: 0; padding-bottom: 0; font-size: 13px; }
.dg-tg { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); cursor: pointer; }
.dg-main { display: grid; grid-template-columns: 250px minmax(0, 1fr) 300px; flex: 1; min-height: 0; border: 1px solid var(--line); border-top: 0; border-radius: 0 0 14px 14px; overflow: hidden; background: #fff; }
.dg-left, .dg-right { overflow: auto; padding: 12px; background: #fff; }
.dg-left { border-right: 1px solid var(--line); } .dg-right { border-left: 1px solid var(--line); }
.dg-tabs { display: flex; width: 100%; margin-bottom: 10px; } .dg-tabs button { flex: 1; justify-content: center; padding: 0 6px; }
.dg-sec { margin-bottom: 18px; } .dg-sec h4 { margin: 0 0 8px; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 800; } .dg-sec h4 small { text-transform: none; letter-spacing: 0; font-weight: 600; }
.dg-add { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.dg-add button { display: flex; align-items: center; gap: 7px; padding: 9px 10px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font-size: 12.5px; font-weight: 600; color: var(--ink-2); text-align: left; cursor: pointer; }
.dg-add button:hover { border-color: var(--accent, #F97316); background: #FFF6EE; color: var(--ink); }
.dg-add button svg { width: 16px; height: 16px; flex: none; }
.dg-grp { margin-bottom: 10px; } .dg-grp > b { display: block; font-size: 12px; margin-bottom: 5px; color: var(--ink-2); }
.dg-chips { display: flex; flex-wrap: wrap; gap: 5px; }
.dg-chip { border: 1px solid var(--line); background: #F7F9FC; border-radius: 999px; padding: 4px 10px; font-size: 12px; font-weight: 600; color: var(--ink-2); cursor: pointer; }
.dg-chip:hover { border-color: var(--accent, #F97316); background: #FFF6EE; color: var(--ink); }
.dg-layers { display: flex; flex-direction: column; gap: 4px; }
.dg-ly { display: flex; align-items: center; gap: 6px; padding: 5px 6px; border: 1px solid transparent; border-radius: 9px; cursor: pointer; font-size: 12.5px; }
.dg-ly:hover { background: #F3F6FB; } .dg-ly.on { background: #FFF1E3; border-color: #FBC896; }
.dg-ly .lyi { color: var(--muted); display: inline-flex; } .dg-ly .lyi svg { width: 14px; height: 14px; }
.dg-ly .lyn { flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-weight: 600; }
.icon-btn.xs { width: 22px; height: 22px; font-size: 12px; border-radius: 6px; } .icon-btn.xs svg { width: 12px; height: 12px; }
.dg-bgp { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; margin-bottom: 8px; background: #F3F6FB; } .dg-bgp img { display: block; width: 100%; max-height: 130px; object-fit: contain; }
.dg-stage { overflow: auto; background: #DDE3EE; position: relative; min-width: 0; }
.dg-holder { margin: 18px auto; position: relative; background: #fff; box-shadow: 0 4px 24px rgba(20, 30, 60, .28); }
.dg-scale { transform-origin: 0 0; position: absolute; left: 0; top: 0; }
.dg-el { cursor: move; user-select: none; -webkit-user-select: none; }
.dg-el img { pointer-events: none; }
.dg-el:before { content: ""; position: absolute; left: -.8mm; right: -.8mm; top: -.8mm; bottom: -.8mm; }
.dg-el:hover { outline: calc(1px * 1.3) dashed rgba(249, 115, 22, .65); outline-offset: 0; }
.dg-ph { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2mm; background: repeating-linear-gradient(45deg, #EEF1F7 0 2mm, #F7F9FC 2mm 4mm); color: #7A849C; font: 600 3.2mm Arial, sans-serif; }
.dg-ph svg { width: 8mm; height: 8mm; }
.dg-frame { position: absolute; pointer-events: none; outline: calc(2 * var(--px)) solid #F97316; outline-offset: 0; z-index: 50; }
.dg-frame.lock { outline-style: dashed; outline-color: #8896B3; }
.dg-h { position: absolute; width: calc(10 * var(--px)); height: calc(10 * var(--px)); background: #fff; border: calc(2 * var(--px)) solid #F97316; border-radius: calc(2 * var(--px)); pointer-events: auto; margin: calc(-5 * var(--px)); }
.dg-frame.lock .dg-h { display: none; }
.dg-h.nw { left: 0; top: 0; cursor: nwse-resize; } .dg-h.n { left: 50%; top: 0; cursor: ns-resize; } .dg-h.ne { left: 100%; top: 0; cursor: nesw-resize; } .dg-h.e { left: 100%; top: 50%; cursor: ew-resize; }
.dg-h.se { left: 100%; top: 100%; cursor: nwse-resize; } .dg-h.s { left: 50%; top: 100%; cursor: ns-resize; } .dg-h.sw { left: 0; top: 100%; cursor: nesw-resize; } .dg-h.w { left: 0; top: 50%; cursor: ew-resize; }
.dg-guide { position: absolute; background: #EC4899; z-index: 40; pointer-events: none; }
.dg-guide.v { top: 0; bottom: 0; width: calc(1px * 1.2); } .dg-guide.h { left: 0; right: 0; height: calc(1px * 1.2); }
.dg-tgs { display: flex; gap: 5px; margin-top: 10px; align-items: center; flex-wrap: wrap; }
.dg-tgb { min-width: 32px; height: 32px; padding: 0 8px; border: 1px solid var(--line); border-radius: 8px; background: #fff; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.dg-tgb.on { background: #FFF1E3; border-color: #F97316; color: #C2410C; }
.dg-gap { width: 8px; }
.dg-color { height: 38px; padding: 3px 6px; cursor: pointer; }
.dg-col { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; padding: 8px; border: 1px solid var(--line-2); border-radius: 10px; margin-bottom: 6px; position: relative; }
.dg-col .select, .dg-col .input { height: 32px; font-size: 12.5px; padding: 0 8px; }
.dg-col .icon-btn { position: absolute; right: 6px; top: 6px; display: none; }
.dg-col:hover .icon-btn { display: inline-flex; }
@media (max-width: 1100px) { .dg-main { grid-template-columns: 210px minmax(0, 1fr) 260px; } }
@media (max-width: 860px) { .dg { height: auto; } .dg-main { grid-template-columns: 1fr; } .dg-stage { min-height: 360px; } .dg-left, .dg-right { border: 0; border-top: 1px solid var(--line); max-height: 360px; } }.dc-thumb.lg { min-height: 220px; max-height: 240px; }

/* ---- crop dialog (certificates, slips and receipts: picture or PDF page) ---- */
.cr-stage{display:grid;place-items:center;background:#E9EDF5;border-radius:12px;padding:12px;overflow:auto;max-height:52vh}
.cr-wrap{position:relative;overflow:hidden;line-height:0;box-shadow:0 2px 14px rgba(20,30,60,.25);touch-action:none;user-select:none;background:#fff}
.cr-wrap canvas{display:block}
.cr-box{position:absolute;border:2px solid #FF7A00;box-shadow:0 0 0 9999px rgba(10,20,45,.55);cursor:move;touch-action:none;outline:none}
.cr-box:focus-visible{outline:2px solid #fff;outline-offset:1px}
.cr-h{position:absolute;width:14px;height:14px;background:#fff;border:2px solid #FF7A00;border-radius:3px;touch-action:none}
.cr-nw{left:-8px;top:-8px;cursor:nwse-resize}.cr-ne{right:-8px;top:-8px;cursor:nesw-resize}.cr-se{right:-8px;bottom:-8px;cursor:nwse-resize}.cr-sw{left:-8px;bottom:-8px;cursor:nesw-resize}
.cr-n{left:calc(50% - 7px);top:-8px;cursor:ns-resize}.cr-s{left:calc(50% - 7px);bottom:-8px;cursor:ns-resize}.cr-e{right:-8px;top:calc(50% - 7px);cursor:ew-resize}.cr-w{left:-8px;top:calc(50% - 7px);cursor:ew-resize}
.cr-box.lock .cr-n,.cr-box.lock .cr-s,.cr-box.lock .cr-e,.cr-box.lock .cr-w{display:none}
.cr-bar{display:flex;gap:14px;align-items:flex-end;flex-wrap:wrap;margin-top:12px}
.cr-bar .field{flex:1;min-width:220px;margin:0}
.cr-info{flex-basis:100%;font-size:12px;color:var(--muted,#6B7690);font-weight:600}
/* number formats page */
.nf-list { display: grid; gap: 16px; margin-bottom: 8px; }
.nf-off { padding: 12px 14px; border-radius: 12px; background: var(--line-2); color: var(--ink-2); font-size: 14px; line-height: 1.5; }
.nf-off[hidden], .nf-main[hidden], .nf-fill[hidden], [data-nextbox][hidden] { display: none !important; }
.nf-pat { font-family: ui-monospace, Consolas, monospace; font-weight: 700; letter-spacing: .02em; }
.nf-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 4px 0 10px; }
.nf-lab { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; width: 38px; }
.nf-chip, .nf-ex-b { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 4px 11px; font-size: 12.5px; color: var(--ink-2); display: inline-flex; gap: 6px; align-items: center; cursor: pointer; transition: all .15s; }
.nf-chip b { color: var(--navy-700); font-family: ui-monospace, Consolas, monospace; font-size: 12px; }
.nf-chip:hover, .nf-ex-b:hover { border-color: var(--orange, #F26B1D); background: #FFF6EE; }
.nf-ex-b { font-family: ui-monospace, Consolas, monospace; font-weight: 700; color: var(--navy-700); }
.nf-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 6px; }
@media (max-width: 720px) { .nf-grid { grid-template-columns: 1fr; } }
.nf-show { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; margin-top: 12px; padding: 12px 14px; border-radius: 12px; background: var(--line-2); }
.nf-show span { display: block; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.nf-show b { font-family: ui-monospace, Consolas, monospace; font-size: 17px; color: var(--navy-700); }
.nf-reset { margin-left: auto; }
.nf-fill { margin-top: 12px; }
.gf select { width: 100%; height: 50px; padding: 0 40px 0 44px; border: 1.5px solid var(--line); border-radius: 13px; background: #F8FAFE; outline: none; font-size: 15px; transition: all .15s; }
.gf select:focus { border-color: var(--blue-500); background: #fff; box-shadow: 0 0 0 4px rgba(59,134,234,.16); }

/* ---------- Nexora IMS brand: login logo lock-up, product credit ---------- */
.gate-logo.nx-lock, .gate-panel .gate-logo.nx-lock { display: flex; flex-direction: column; align-items: center; width: auto; max-width: none; margin: 0 auto 22px; text-align: center; }
.nx-lock .nx-mark { width: 76px; height: 76px; display: block; filter: drop-shadow(0 10px 18px rgba(11,42,107,.28)); }
.nx-lock .nx-word { font-size: 29px; font-weight: 800; letter-spacing: .07em; line-height: 1; margin-top: 12px; color: var(--navy-700); }
.nx-lock .nx-word em { font-style: normal; color: var(--orange-500); }
.nx-lock .nx-tag { margin-top: 7px; font-size: 12.5px; font-weight: 600; letter-spacing: .02em; color: var(--ink-2); }
.brand-chip > img[src*="logo-mark"] { width: 100%; height: 100%; border-radius: 13px; display: block; }
.gate-tag.gate-by { font-style: normal; font-weight: 600; font-size: 13px; letter-spacing: .05em; color: rgba(255,255,255,.75); }
.gate-tag.gate-by b { color: #fff; font-weight: 800; }
.gate-by-line { margin-top: 8px; text-align: center; font-size: 11.5px; color: var(--muted); letter-spacing: .02em; }
.gate-by-line b { color: var(--navy-700); font-weight: 700; }
@media (max-height: 820px) { .gate-panel .gate-logo.nx-lock { margin-bottom: 14px; } .nx-lock .nx-mark { width: 60px; height: 60px; } .nx-lock .nx-word { font-size: 24px; margin-top: 8px; } }
@media (max-width: 900px) { .gate-tag.gate-by { display: flex; position: static; margin-top: 8px; } }.gate-tag.gate-by { display: block; }
@media (max-width: 1500px), (max-height: 820px) { .fc-q { display: none; } }

/* ---- Reports: compact toolbar, KPI strip, chart cards, filterable table (charts.js draws the charts) */
.rp-filter { margin-bottom: 12px; }
.rp-fbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 10px 14px; }
.rp-fbar .input, .rp-fbar .select { height: 36px; font-size: 13px; border-radius: 10px; }
.rp-fbar .select { width: auto; min-width: 130px; max-width: 220px; }
.rp-pick { position: relative; display: inline-flex; align-items: center; }
.rp-pick .i { position: absolute; left: 11px; width: 16px; height: 16px; color: var(--blue-600); pointer-events: none; }
.rp-pick .select { padding-left: 34px; min-width: 210px; font-weight: 700; color: var(--navy-800); background-color: var(--blue-50); border-color: #CFE0F8; }
.rp-div { width: 1px; align-self: stretch; margin: 4px 2px; background: var(--line); }
.rp-pre button { height: 30px; padding: 0 11px; font-size: 12.5px; }
.rp-pre { padding: 2px; }
.rp-dates .input { width: 138px; padding: 0 9px; }
.rp-when { margin: 0 0 10px; font-size: 13px; }
.rp-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(188px, 1fr)); gap: 12px; margin-bottom: 12px; }
.rp-kpis .nxk b { font-size: 22px; }
.rp-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-flow: dense; gap: 12px; margin: 0 0 12px; }
.rp-ch { padding: 0; overflow: hidden; display: flex; flex-direction: column; min-width: 0; }
.rp-ch.rp-first { grid-column: span 2; }
.rp-ch-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 11px 14px 0; }
.rp-ch-h h3 { font-size: 13.5px; font-weight: 800; color: var(--navy-800); letter-spacing: -.01em; }
.rp-ch-b { position: relative; padding: 6px 12px 12px; min-height: 60px; }
.rp-k-trend .rp-ch-b { padding: 4px 6px 8px; }
.rp-ty { display: inline-flex; background: var(--line-2); border-radius: 8px; padding: 2px; }
.rp-ty button { border: 0; background: transparent; font-size: 11.5px; font-weight: 700; color: var(--muted); height: 22px; padding: 0 9px; border-radius: 6px; cursor: pointer; }
.rp-ty button.on { background: #fff; color: var(--navy-700); box-shadow: var(--shadow-sm); }
.nx-svg { display: block; max-width: 100%; overflow: visible; }
.nx-grid { stroke: var(--line-2); stroke-width: 1; }
.nx-grid:first-of-type { stroke: var(--line); }
.nx-ax { font-size: 10.5px; fill: var(--muted); font-weight: 600; }
.nx-val { font-size: 10px; fill: var(--ink-2); font-weight: 700; }
.nx-bar { transform-box: fill-box; transform-origin: bottom; animation: nxRise .5s cubic-bezier(.2, .7, .2, 1) both; transition: opacity .15s, filter .15s; }
.nx-bar.nx-on { filter: brightness(1.12) saturate(1.1); }
@keyframes nxRise { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.nx-line { fill: none; stroke: #1E6FD9; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.nx-fill { animation: nxFade .6s ease both; }
@keyframes nxFade { from { opacity: 0; } to { opacity: 1; } }
.nx-pt { fill: #fff; stroke: #1E6FD9; stroke-width: 2; transition: r .12s; }
.nx-pt.nx-on { r: 5.5; fill: #1E6FD9; }
.nx-guide { stroke: #9AA6C0; stroke-width: 1; stroke-dasharray: 3 3; }
.nx-tip { position: absolute; z-index: 5; pointer-events: none; background: var(--navy-800, #0B1F4D); color: #fff; border-radius: 9px; padding: 6px 10px; font-size: 12px; line-height: 1.35; white-space: nowrap; box-shadow: 0 6px 18px rgba(11, 31, 77, .28); display: flex; flex-direction: column; }
.nx-tip[hidden] { display: none; }
.nx-tip b { font-size: 11px; opacity: .75; font-weight: 600; }
.nx-tip span { font-size: 14px; font-weight: 800; }
.nx-tip small { opacity: .75; font-size: 11px; }
.nx-donut { display: flex; align-items: center; gap: 14px; }
.nx-donut svg { flex: none; }
.nx-arc { cursor: pointer; transition: stroke-width .15s, opacity .15s; animation: nxFade .5s ease both; }
.nx-donut svg.hov .nx-arc:not(.hi) { opacity: .4; }
.nx-arc.hi, .nx-arc.on { stroke-width: 24; }
.nx-arc.dim { opacity: .35; }
.nx-mid { font-size: 17px; font-weight: 800; fill: var(--navy-800); }
.nx-mid-s { font-size: 10px; fill: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .06em; }
.nx-legend { flex: 1; min-width: 0; display: grid; gap: 1px; }
.nx-lg { display: grid; grid-template-columns: 10px minmax(0, 1fr) auto 38px; align-items: center; gap: 7px; border: 0; background: transparent; padding: 5px 6px; border-radius: 8px; font-size: 12.5px; text-align: left; cursor: pointer; color: var(--ink-2); }
.nx-lg:hover, .nx-lg.on { background: var(--blue-50); }
.nx-lg[data-nf] { cursor: default; }
.nx-lg i { width: 10px; height: 10px; border-radius: 3px; }
.nx-lg span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.nx-lg b { font-variant-numeric: tabular-nums; color: var(--navy-800); font-weight: 800; }
.nx-lg em { font-style: normal; color: var(--muted); font-size: 11.5px; text-align: right; font-variant-numeric: tabular-nums; }
.nx-hb-list { display: grid; gap: 1px; }
.nx-hb { display: grid; grid-template-columns: minmax(70px, 36%) minmax(0, 1fr) auto; align-items: center; gap: 1px 10px; border: 0; background: transparent; padding: 5px 6px; border-radius: 8px; font-size: 12.5px; text-align: left; cursor: pointer; color: var(--ink-2); }
.nx-hb:hover, .nx-hb.on { background: var(--blue-50); }
.nx-hb[data-nf] { cursor: default; }
.nx-hb.dim { opacity: .45; }
.nx-hl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.nx-ht { height: 8px; background: var(--line-2); border-radius: 6px; overflow: hidden; }
.nx-ht i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, #3B86EA, #1E6FD9); }
.nx-hb.on .nx-ht i { background: linear-gradient(90deg, #FFA94D, #F7931E); }
.nx-hb b { font-variant-numeric: tabular-nums; color: var(--navy-800); font-weight: 800; }
.nx-hb small { grid-column: 2 / 4; color: var(--muted); font-size: 11px; margin-top: -1px; }
.nx-more { margin: 4px 6px 0; border: 0; background: transparent; color: var(--blue-600); font-weight: 700; font-size: 12px; cursor: pointer; padding: 3px 4px; }
.nx-more:hover { text-decoration: underline; }
.rp-detail { margin-bottom: 20px; }
.rp-th { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 14px; padding: 12px 14px; }
.rp-tt { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; }
.rp-tt h3 { font-size: 15px; }
.rp-tools { display: flex; align-items: center; gap: 8px; }
.rp-tools .input { width: 220px; height: 34px; font-size: 13px; }
.rp-tools .select { width: auto; height: 34px; font-size: 13px; min-width: 118px; }
.rp-chip { display: inline-flex; align-items: center; gap: 6px; background: var(--orange-100); color: var(--orange-600); border-radius: 999px; padding: 3px 4px 3px 11px; font-size: 12px; font-weight: 600; }
.rp-chip b { font-weight: 800; }
.rp-chip button { border: 0; background: rgba(247, 147, 30, .22); color: inherit; width: 20px; height: 20px; border-radius: 50%; font-size: 14px; line-height: 1; cursor: pointer; }
.rp-chip button:hover { background: rgba(247, 147, 30, .4); }
.rp-tbl th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
.rp-tbl th.sortable i { font-style: normal; font-size: 9px; margin-left: 5px; color: #B3BDD3; }
.rp-tbl th.sortable.sorted i, .rp-tbl th.sortable:hover i { color: var(--blue-600); }
.rp-tbl th.sortable.num { text-align: right; }
.rp-none { padding: 30px 16px; text-align: center; color: var(--muted); font-size: 13.5px; }
.rp-pg { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; border-top: 1px solid var(--line-2); font-size: 12.5px; color: var(--muted); flex-wrap: wrap; }
.rp-pg > div { display: flex; align-items: center; gap: 10px; }
.rp-pg b { color: var(--ink-2); }
.rp-pg .btn { height: 32px; padding: 0 12px; font-size: 12.5px; }
@media (max-width: 1100px) { .rp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) {
  .rp-grid { grid-template-columns: minmax(0, 1fr); } .rp-ch.rp-first { grid-column: auto; }
  .rp-div { display: none; } .rp-pick, .rp-pick .select { width: 100%; }
  .rp-tools, .rp-tools .input { width: 100%; } .nx-donut { flex-direction: column; align-items: stretch; }
}

/* ---- Shell refresh: slimmer sidebar (folds to icons), white header with date, full screen and account menu */
:root { --side-w: 232px; }
.side, .main { transition: width .25s ease, margin-left .25s ease, transform .25s ease; }
.side-brand { padding: 15px 16px 11px; gap: 10px; }
.side-brand b { font-size: 19px; }
.side-brand small { font-size: 10px; letter-spacing: .1em; }
.side-nav { padding: 2px 10px 10px; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.2) transparent; }
.nav-group { margin: 13px 8px 5px; font-size: 10px; letter-spacing: .14em; }
.nav-item { padding: 8px 11px; gap: 11px; font-size: 13px; border-radius: 10px; margin-bottom: 1px; }
.nav-item .i { width: 18px; height: 18px; flex: none; }
.nav-item.on { background: linear-gradient(90deg, #1E6FD9, #3B86EA); box-shadow: 0 6px 16px rgba(30,111,217,.38); }
.nav-item.on::before { display: none; }
.nav-item.on .i { color: #fff; }
.side-foot { padding: 10px; }
.side-user { padding: 4px; gap: 9px; }
.side-user .avatar { width: 34px; height: 34px; font-size: 14px; }
.side-user strong { max-width: 106px; font-size: 13px; }
.side-out { width: 34px; height: 34px; }
@media (min-width: 961px) {
  .app.min { --side-w: 72px; }
  .app.min .side-brand { justify-content: center; padding: 14px 8px 10px; }
  .app.min .side-brand > span:not(.brand-chip) { display: none; }
  .app.min .side-nav { padding: 2px 10px 10px; overflow-x: hidden; }
  .app.min .nav-item { justify-content: center; padding: 10px 0; }
  .app.min .nav-item > span { display: none; }
  .app.min .nav-group { font-size: 0; height: 1px; margin: 10px 12px; padding: 0; background: rgba(255,255,255,.12); }
  .app.min .side-foot { flex-direction: column; gap: 8px; }
  .app.min .side-user > span:last-child { display: none; }
  .app.min .side-user { flex: none; padding: 2px; }
}

.top { gap: 12px; padding: 9px 22px; background: #fff; backdrop-filter: none; box-shadow: 0 6px 22px rgba(15,27,61,.05); }
.menu-btn { display: inline-grid; width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: #fff; color: var(--navy-700); }
.menu-btn:hover { background: var(--blue-50); border-color: #CFE0F8; }
.top-copy { flex: 1 1 auto; line-height: 1.15; }
.top-kicker { font-size: 10.5px; letter-spacing: .12em; }
.top h1 { font-size: 18px; }
.top-search { margin-left: 0; width: min(280px, 24vw); }
.top-search input { height: 38px; background: var(--bg); border-color: transparent; }
.top-search input:focus { background: #fff; }
.ts-ic { top: 10px; }
.top-new { height: 38px; padding: 0 14px; font-size: 13px; }
.top-date { display: flex; align-items: center; gap: 8px; height: 38px; padding: 0 12px; border-radius: 12px; background: var(--blue-50); border: 1px solid #D5E4FA; color: var(--navy-700); font-size: 13px; font-weight: 700; white-space: nowrap; }
.top-date .i { width: 16px; height: 16px; color: var(--blue-600); }
.top-date b { font-weight: 600; font-size: 12.5px; color: var(--muted); padding-left: 8px; border-left: 1px solid #C5D8F2; font-variant-numeric: tabular-nums; }
.top-ib { width: 38px; height: 38px; border: 1px solid var(--line); background: #fff; border-radius: 12px; color: var(--navy-700); }
.top-ib[hidden] { display: none; }
.top-ib:hover { background: var(--blue-50); border-color: #CFE0F8; }
.top-user { position: relative; }
.tu-btn { display: flex; align-items: center; gap: 8px; padding: 3px 10px 3px 3px; border: 1px solid var(--line); border-radius: 999px; background: #fff; cursor: pointer; font-size: 13px; color: var(--ink-2); font-weight: 600; transition: background .15s, border-color .15s; }
.tu-btn:hover, .tu-btn[aria-expanded="true"] { background: var(--blue-50); border-color: #CFE0F8; }
.tu-btn .avatar { width: 32px; height: 32px; font-size: 13px; box-shadow: none; }
.tu-btn b { color: var(--navy-800); font-weight: 800; }
.tu-ch .i { width: 15px; height: 15px; color: var(--muted); display: block; }
.tu-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 224px; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); padding: 6px; z-index: 60; animation: rise .15s ease both; }
.tu-menu[hidden] { display: none; }
.tu-head { padding: 9px 12px 9px; margin-bottom: 4px; border-bottom: 1px solid var(--line-2); }
.tu-head b { display: block; font-size: 14px; color: var(--navy-800); }
.tu-head small { color: var(--muted); font-size: 12px; }
.tu-menu a, .tu-menu button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 12px; border: 0; background: transparent; border-radius: 9px; font: inherit; font-size: 13.5px; font-weight: 600; color: var(--ink-2); cursor: pointer; text-align: left; }
.tu-menu a:hover, .tu-menu button:hover { background: var(--blue-50); color: var(--navy-800); }
.tu-menu .i { width: 17px; height: 17px; }
.tu-menu .tu-out { color: var(--red); }
.tu-menu .tu-out:hover { background: var(--red-bg); color: var(--red); }
.tu-menu [hidden] { display: none; }
.view { padding-top: 20px; }
@media (max-width: 1200px) { .top-date b { display: none; } .top-search { width: clamp(150px, 20vw, 240px); } }
@media (max-width: 1080px) { .top-search { display: none; } }
@media (max-width: 760px) { .top-date { display: none; } .tu-txt, .tu-ch { display: none; } .tu-btn { padding: 3px; } .top { padding: 9px 12px; gap: 8px; } }
body.is-fs .view { max-width: none; }

/* ---- Dashboard */
.hero.hero-sm { padding: 16px 24px; margin-bottom: 14px; border-radius: 16px; }
.hero.hero-sm h2 { font-size: 22px; }
.hero.hero-sm p { margin-top: 2px; font-size: 13.5px; }
.nxk-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(188px, 1fr)); gap: 12px; margin-bottom: 14px; }
.nxk { position: relative; overflow: hidden; display: flex; align-items: center; gap: 12px; padding: 16px 16px 14px; border-radius: 16px; color: #fff; box-shadow: 0 10px 24px rgba(15,27,61,.14); transition: transform .15s, box-shadow .15s; }
.nxk:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(15,27,61,.2); }
.nxk.g1 { background: linear-gradient(135deg, #1E6FD9, #3E8CF0); }
.nxk.g2 { background: linear-gradient(135deg, #0C9F94, #25C7A8); }
.nxk.g3 { background: linear-gradient(135deg, #F28A12, #FF6B3A); }
.nxk.g4 { background: linear-gradient(135deg, #6A45F0, #9A72FF); }
.nxk.g5 { background: linear-gradient(135deg, #0B2A6B, #2D56B3); }
.nxk.g6 { background: linear-gradient(135deg, #D92D3A, #F2645A); }
.nxk { min-height: 84px; }
.nxk.wrap .nxk-l { white-space: normal; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.nxk b { overflow-wrap: anywhere; }
.nxk-ic { width: 44px; height: 44px; border-radius: 50%; background: rgba(255,255,255,.2); display: grid; place-items: center; flex: none; position: relative; z-index: 1; }
.nxk-ic .i { width: 22px; height: 22px; }
.nxk > div { position: relative; z-index: 1; min-width: 0; }
.nxk b { display: block; font-size: 26px; font-weight: 800; letter-spacing: -.02em; line-height: 1.05; font-variant-numeric: tabular-nums; }
.nxk-l { display: block; margin-top: 3px; font-size: 12.5px; font-weight: 600; opacity: .92; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nxk-chip { position: absolute; z-index: 1; right: 10px; top: 10px; font-size: 10.5px; font-weight: 800; padding: 2px 8px; border-radius: 20px; background: rgba(255,255,255,.22); white-space: nowrap; }
.nxk-bg { position: absolute; right: -8px; bottom: -14px; width: 84px; height: 84px; opacity: .14; }
.nxk-bg .i { width: 100%; height: 100%; stroke-width: 1.6; }
.nxg { gap: 12px; margin-bottom: 12px; }
.nxc { padding-bottom: 8px; min-width: 0; overflow: hidden; }
.nxc-h { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 14px 18px 0; }
.nxc-h h2 { font-size: 15px; font-weight: 800; color: var(--navy-800); letter-spacing: -.01em; }
.nxc-b { position: relative; padding: 4px 10px 8px; min-height: 40px; }
.nxc-key { display: flex; align-items: center; gap: 12px; font-size: 12px; font-weight: 700; color: var(--ink-2); }
.nxc-key i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 5px; }
#dcDiff { padding: 12px 14px 8px; }
#dcTypes { padding: 4px 12px 8px; }
.nx-badge rect { fill: #1E6FD9; }
.nx-badge text { fill: #fff; font-size: 11px; font-weight: 800; }
.nx-tip .nx-r { font-size: 12px; font-weight: 600; display: flex; align-items: center; }
.nx-tip .nx-r i { width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; display: inline-block; }
.nxq { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; padding: 12px 16px 10px; }
.nxq a { display: flex; flex-direction: column; align-items: center; gap: 7px; padding: 13px 4px 11px; border: 1px solid var(--line); border-radius: 14px; font-size: 12px; font-weight: 700; color: var(--ink-2); background: #fff; text-align: center; transition: transform .15s, box-shadow .15s, border-color .15s; }
.nxq a:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: #CFE0F8; color: var(--navy-800); }
.nxq-ic { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; }
.nxq-ic .i { width: 20px; height: 20px; }
.list.nxa .list-item { padding: 9px 18px; gap: 10px; }
.nxa-dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.a-blue { background: #1E6FD9; } .a-green { background: #12A150; } .a-red { background: #E5484D; } .a-violet { background: #7C5CFC; } .a-orange { background: #F7931E; }
.nxa-t { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
@media (max-width: 1280px) { .nxg .c-12 { grid-column: span 12; } }
@media (max-width: 700px) { .nxg > .nxc { grid-column: span 12; } .nxk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .nxk { padding: 13px 12px; gap: 9px; } .nxk-ic { width: 38px; height: 38px; } .nxk b { font-size: 22px; } .nxk-chip { display: none; } }

/* ---- Reports: Graphical / Tabular tabs */
.rp-vrow { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px 14px; margin-bottom: 10px; }
.rp-vrow .rp-when { margin: 0; flex: 1 1 260px; min-width: 0; }
.rp-view { flex: none; padding: 3px; }
.rp-view button { height: 32px; padding: 0 14px 0 11px; gap: 7px; font-size: 13px; }
.rp-view button .i { width: 16px; height: 16px; }
.rp-view button.on { color: var(--blue-600); }
#rpGraph[hidden], #rpTable[hidden] { display: none; }
.rp-cfbar { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; margin-bottom: 12px; padding: 8px 12px; border-radius: 12px; background: var(--orange-100); border: 1px solid #FBD9AE; }
.rp-cfbar .hint { color: var(--orange-600); font-weight: 600; }
.rp-cfbar .btn { margin-left: auto; }
.rp-cfbar .rp-chip { background: #fff; }
@media (max-width: 560px) { .rp-view { width: 100%; } .rp-view button { flex: 1; justify-content: center; padding: 0 8px; } }

/* ---- Dashboard: business view (filters, section heading, small KPI line) ---- */
.dbf { margin-bottom: 14px; }
.dbf .rp-fbar { padding: 10px 12px; }
#dbBiz.dim { opacity: .55; transition: opacity .15s; pointer-events: none; }
.nxk .nxk-s { display: block; margin-top: 4px; font-size: 11px; font-weight: 600; opacity: .8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 150px; }
.nxk b[data-k="m"] { font-size: 21px; letter-spacing: -.03em; }
.dsec { margin: 22px 2px 12px; padding-top: 18px; border-top: 1px solid var(--line); }
.dsec h2 { margin: 0; font-size: 18px; font-weight: 800; color: var(--navy-800); letter-spacing: -.01em; }
.dsec p { margin: 3px 0 0; font-size: 13px; color: var(--muted); }
.nxq.nxq-row { grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); }
.nxa .list-item b { font-variant-numeric: tabular-nums; }
@media (max-width: 700px) { .nxk .nxk-s { display: none; } .dbf .rp-fbar { gap: 8px; } }

/* super admin: choosing the modules of an organisation */
.modchips { display: flex; flex-wrap: wrap; gap: 4px; max-width: 220px; }
.modchips span { padding: 2px 8px; border-radius: 20px; font-size: 11.5px; font-weight: 700; background: #EEF3FC; color: var(--navy-700); }
.modlist { border: 1.5px solid var(--line); border-radius: 14px; overflow: hidden; background: #fff; margin-bottom: 4px; }
.modgrp { padding: 8px 14px; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: #F4F7FC; border-top: 1px solid var(--line); }
.modgrp:first-child { border-top: 0; }
.modrow { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-top: 1px solid #EDF1F8; cursor: pointer; transition: background .12s; }
.modgrp + .modrow { border-top: 0; }
.modrow:hover { background: #F8FAFE; }
.modrow .modic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: #EEF3FB; flex: none; transition: background .15s; }
.modrow .modic svg { width: 18px; height: 18px; fill: none; stroke: #6B7A99; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.modrow:has(input:checked) .modic { background: linear-gradient(135deg, #3B86EA, #1E6FD9); }
.modrow:has(input:checked) .modic svg { stroke: #fff; }
.modrow .modtx { flex: 1; min-width: 0; }
.modrow .modtx b { display: block; font-size: 13.5px; font-weight: 700; color: var(--ink); }
.modrow .modtx small { display: block; color: var(--muted); font-size: 12px; line-height: 1.35; margin-top: 1px; }
.mtog { flex: none; position: relative; }
.mtog input { position: absolute; opacity: 0; pointer-events: none; }
.mtog .tr { display: block; width: 42px; height: 24px; border-radius: 20px; background: #CBD5E6; position: relative; transition: background .2s; }
.mtog .tr::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
.mtog input:checked + .tr { background: var(--green, #1FA36B); }
.mtog input:checked + .tr::after { transform: translateX(18px); }
.mtog input:focus-visible + .tr { outline: 2px solid var(--blue-500); outline-offset: 2px; }

/* super admin: one organisation in detail */
.kvs .kv { display: flex; justify-content: space-between; gap: 14px; padding: 9px 0; border-bottom: 1px solid #EDF1F8; font-size: 13px; }
.kvs .kv:last-child { border-bottom: 0; }
.kvs .kv > span { color: var(--muted); flex: none; }
.kvs .kv > b { font-weight: 600; text-align: right; min-width: 0; overflow-wrap: anywhere; }
/* Organisations (super admin): the list page */
.org-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 10px; margin-bottom: 12px; }
.org-seg { max-width: 100%; }
.org-seg small { font-size: 11px; font-weight: 800; color: var(--muted); background: var(--line-2); border-radius: 10px; padding: 1px 7px; margin-left: 3px; }
.org-seg button.on small { background: var(--blue-100); color: var(--blue-600); }
.org-search { position: relative; flex: 0 1 300px; min-width: 220px; }
.org-search .i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 17px; height: 17px; color: #8794B2; pointer-events: none; }
.org-search .input { width: 100%; padding-left: 38px; }
.org-card { padding: 0; overflow: hidden; }
.org-card .tbl th:first-child, .org-card .tbl td:first-child { padding-left: 18px; }
.org-card .tbl th:last-child, .org-card .tbl td:last-child { padding-right: 14px; }
.org-id { display: flex; align-items: center; gap: 12px; min-width: 0; }
.org-av { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex: none; color: #fff; font-size: 14px; font-weight: 800; letter-spacing: .03em; box-shadow: 0 6px 14px rgba(15,27,61,.16); }
.org-av.a0 { background: linear-gradient(135deg, #1E6FD9, #3E8CF0); }
.org-av.a1 { background: linear-gradient(135deg, #0C9F94, #25C7A8); }
.org-av.a2 { background: linear-gradient(135deg, #F28A12, #FF6B3A); }
.org-av.a3 { background: linear-gradient(135deg, #6A45F0, #9A72FF); }
.org-av.a4 { background: linear-gradient(135deg, #0B2A6B, #2D56B3); }
.org-card tr.off .org-av { filter: grayscale(.85); opacity: .6; }
.org-name { display: block; max-width: 280px; font-weight: 700; font-size: 14px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.org-name:hover { color: var(--blue-600); }
.org-card tr.off .org-name { color: var(--ink-2); }
.org-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 3px; font-size: 12px; color: var(--muted); }
.org-sub { font-size: 12px; color: var(--muted); margin-top: 3px; }
.modbar { display: flex; align-items: flex-end; gap: 3px; height: 18px; }
.modbar i { width: 4px; height: 100%; border-radius: 2px; background: #DCE3F0; }
.modbar i.on { background: var(--blue-500); }
.rbar { width: 124px; height: 6px; margin-top: 8px; border-radius: 6px; background: var(--line-2); overflow: hidden; }
.rbar i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, #12A150, #34C27A); }
.rbar.soon i { background: linear-gradient(90deg, #D98200, #F5A524); }
.rbar.expired i { background: var(--red); }
.rbar.off i { background: #B8C2D6; }
.org-acts { display: flex; align-items: center; justify-content: flex-end; gap: 6px; white-space: nowrap; }
.org-card .org-td-act .org-acts { justify-content: flex-start; }
.org-card .org-th-act, .org-card .org-td-act { width: 1%; white-space: nowrap; }
.org-acts .icon-btn .dots { width: 18px; height: 18px; fill: currentColor; stroke: none; }
.org-more { position: fixed; z-index: 400; min-width: 230px; padding: 6px; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 18px 40px rgba(15,27,61,.18); animation: orgMenuIn .14s ease-out; }
@keyframes orgMenuIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.org-more button { display: flex; width: 100%; align-items: center; gap: 10px; padding: 9px 10px; border: 0; background: transparent; border-radius: 9px; font-size: 13.5px; font-weight: 600; color: var(--ink-2); text-align: left; }
.org-more button .i { width: 16px; height: 16px; color: var(--muted); flex: none; }
.org-more button:hover { background: var(--blue-50); color: var(--ink); }
.org-more button.danger { color: var(--red); }
.org-more button.danger .i { color: var(--red); }
.org-more button.danger:hover { background: var(--red-bg); }
.org-more hr { border: 0; border-top: 1px solid var(--line-2); margin: 5px 4px; }
@media (max-width: 700px) { .org-search { flex: 1 1 100%; min-width: 0; } .rbar { width: 96px; } .org-name { max-width: 190px; } }
/* ID cards (Certificates, marksheets & ID cards) */
.dc-who { display: flex; align-items: center; gap: 10px; }
.dc-ph { width: 32px; height: 40px; border-radius: 6px; object-fit: cover; flex: none; background: #E6EBF5; box-shadow: 0 0 0 1px rgba(20, 30, 60, .12); }
.dc-ph.none { display: inline-flex; align-items: center; justify-content: center; color: #9AA6C0; background: repeating-linear-gradient(45deg, #F1F4FA, #F1F4FA 5px, #E8ECF5 5px, #E8ECF5 10px); }
.dc-ph.none svg { width: 16px; height: 16px; }
.dc-idsec { display: flex; flex-direction: column; gap: 2px; margin-top: 8px; padding-top: 12px; border-top: 1px solid var(--line-2, #E5E9F2); }
.dc-idsec b { font-size: 13px; }
.dg-safe { position: absolute; left: 3mm; top: 3mm; right: 3mm; bottom: 3mm; border: 0.3mm dashed rgba(220, 38, 38, .75); border-radius: 1.5mm; pointer-events: none; z-index: 39; }
.dg-pulse { animation: dgPulse 1.1s ease-in-out 6; }
@keyframes dgPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(37, 99, 235, .55); } 50% { box-shadow: 0 0 0 7px rgba(37, 99, 235, 0); } }
/* ---- renewal history (renewals.js) ---- */
.rh-sum { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 14px 18px 4px; }
.rh-sum > div { background: #F6F8FD; border: 1px solid #E6ECF7; border-radius: 12px; padding: 10px 14px; display: grid; gap: 2px; }
.rh-sum b { font-size: 18px; color: var(--ink); }
.rh-sum span { font-size: 12px; color: var(--muted); }
.rh-list { padding: 6px 18px 14px; }
.rh-item { display: flex; gap: 12px; align-items: flex-start; padding: 13px 0; border-bottom: 1px solid #EDF1F8; }
.rh-item:last-child { border-bottom: 0; }
.rh-main { flex: 1; min-width: 0; display: grid; gap: 5px; }
.rh-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 14px; color: var(--ink); }
.rh-dates { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12.5px; color: var(--ink-2); }
.rh-d { background: #F3F5FA; border-radius: 8px; padding: 3px 9px; }
.rh-d.now { background: #E8F7EF; color: #0F7A4B; }
.rh-ar { font-style: normal; color: var(--muted); }
.rh-pay { display: flex; align-items: center; gap: 7px; font-size: 13px; color: var(--ink-2); }
.rh-pay .i { width: 15px; height: 15px; color: var(--muted); flex: none; }
.rh-note { font-size: 12.5px; color: var(--ink-2); background: #FFF8EC; border-radius: 8px; padding: 5px 9px; width: fit-content; max-width: 100%; overflow-wrap: anywhere; }
.rh-meta { font-size: 11.5px; color: var(--muted); }
.rh-sec { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin: 6px 0 8px; }
@media (max-width: 640px) { .rh-sum { grid-template-columns: 1fr; } .rh-item { flex-wrap: wrap; } }

/* ---- students: fees column, profile, reset password ---- */
.st-name { cursor: pointer; font-weight: 700; } .st-name:hover { color: var(--blue-600); text-decoration: underline; }
.st-fee { font-size: 13px; color: var(--muted); } .st-fee b { color: var(--navy-800); font-size: 14px; }
.st-over { color: var(--red) !important; }
.st-fs { font-size: 12px; color: var(--muted); margin-top: 3px; }
.st-bar { height: 5px; border-radius: 4px; background: #E7ECF6; margin-top: 5px; overflow: hidden; min-width: 90px; max-width: 130px; }
.st-bar i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, #1E6FD9, #3E8CF0); }
.st-bar i.over { background: linear-gradient(90deg, #D92D3A, #F2645A); }
.st-bar.big { height: 8px; max-width: none; margin: 12px 0 14px; }
.rp-done { text-align: center; padding: 4px 0 0; } .rp-done .em-ic { margin: 0 auto 10px; }
.rp-done h3 { margin: 0 0 6px; font-size: 18px; color: var(--navy-800); } .rp-done p { margin: 0 auto; max-width: 380px; color: var(--ink-2); line-height: 1.5; }
.rp-pw { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 16px auto 0; padding: 12px 14px; max-width: 360px; border: 1.5px dashed #9CB9E8; border-radius: 12px; background: #F3F8FF; }
.rp-pw code { font: 700 19px/1.2 Consolas, "Courier New", monospace; letter-spacing: .06em; color: var(--navy-800); user-select: all; word-break: break-all; }
.pf-top { display: flex; gap: 16px; align-items: center; padding: 4px 0 16px; border-bottom: 1px solid var(--line); }
.pf-top h3 { margin: 0; font-size: 20px; letter-spacing: -.01em; color: var(--navy-800); } .pf-sub { color: var(--muted); font-size: 13px; margin-top: 2px; }
.pf-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 16px 0; }
.pf-stats > div { padding: 12px 14px; border-radius: 12px; background: #F3F6FC; } .pf-stats b { display: block; font-size: 20px; color: var(--navy-800); letter-spacing: -.02em; } .pf-stats span { font-size: 12px; color: var(--muted); font-weight: 600; }
.pf-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; align-items: start; }
.pf-card { border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; background: #fff; } .pf-card h4 { margin: 0 0 8px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.pf-kv { display: flex; justify-content: space-between; gap: 14px; padding: 7px 0; border-bottom: 1px dashed var(--line); font-size: 13.5px; } .pf-kv:last-child { border-bottom: 0; }
.pf-kv span { color: var(--muted); flex: none; } .pf-kv b { font-weight: 600; text-align: right; overflow-wrap: anywhere; }
.pf-fee3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; } .pf-fee3 span { display: block; font-size: 12px; color: var(--muted); } .pf-fee3 b { font-size: 15px; }
@media (max-width: 720px) { .pf-grid { grid-template-columns: 1fr; } }

/* ---------- import questions from a PDF ---------- */
.modal.xl:has(.pq) { max-width: 1060px; }
.pq { display: grid; grid-template-columns: 270px minmax(0, 1fr); height: min(68vh, 660px); min-height: 420px; }
.pq-side { padding: 18px 18px 20px; border-right: 1px solid var(--line-2); background: #F8FAFD; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; }
.pq-side h4 { margin: 0; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.pq-side .field { margin: 0; } .pq-side .seg { display: flex; } .pq-side .seg button { flex: 1; justify-content: center; padding: 0 6px; }
.pq-g3 { gap: 8px; } .pq-g3 .input { padding-left: 8px; padding-right: 6px; }
.pq-link { border: 0; background: none; color: var(--blue-600); font-weight: 700; font-size: 13px; display: inline-flex; align-items: center; gap: 7px; cursor: pointer; padding: 4px 0; text-align: left; margin-top: 4px; }
.pq-link:hover { text-decoration: underline; }
.pq-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.pq-foot { display: flex; gap: 10px; align-items: center; width: 100%; flex-wrap: wrap; }
.pq-sp { flex: 1; }
.pq-pickwrap { padding: 24px; overflow-y: auto; display: flex; flex-direction: column; gap: 18px; }
.pq-how { background: #F8FAFD; border: 1px solid var(--line-2); border-radius: 14px; padding: 14px 18px; }
.pq-how h4 { margin: 0 0 8px; font-size: 14px; color: var(--navy-800); }
.pq-how ul { margin: 0; padding-left: 18px; color: var(--ink-2); font-size: 13px; line-height: 1.7; }
.pq-how code { background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 0 5px; font-size: 12px; }
.pq-wait, .pq-empty { margin: auto; text-align: center; padding: 30px; max-width: 420px; }
.pq-wait h3, .pq-empty h3 { margin: 12px 0 4px; color: var(--navy-800); } .pq-wait p, .pq-empty p { color: var(--muted); line-height: 1.55; }
.pq-spin { width: 38px; height: 38px; border-radius: 50%; border: 4px solid var(--blue-100); border-top-color: var(--blue-500); margin: 0 auto; animation: pqspin .8s linear infinite; }
@keyframes pqspin { to { transform: rotate(360deg); } }
.pq-empty-ic { width: 64px; height: 64px; border-radius: 18px; margin: 0 auto; display: grid; place-items: center; background: var(--blue-100); color: var(--blue-600); }
.pq-bar { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--line-2); flex-wrap: wrap; }
.pq-sum { display: inline-flex; gap: 8px; font-size: 12.5px; font-weight: 700; } .pq-sum .ok { color: var(--green); } .pq-sum .bad { color: var(--amber); }
.pq-flt button { height: 30px; padding: 0 10px; font-size: 12.5px; }
.pq-list { padding: 14px 16px 20px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; flex: 1; min-height: 0; }
.pq-card { display: flex; gap: 12px; border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; background: #fff; transition: border-color .15s, box-shadow .15s; }
.pq-card.on { border-color: var(--blue-500); box-shadow: 0 0 0 3px rgba(30, 111, 217, .1); }
.pq-card.bad { border-color: #F2D9A6; background: #FFFCF5; }
.pq-card.done { opacity: .62; background: #F6FBF7; }
.pq-pick { padding-top: 2px; } .pq-pick input { width: 18px; height: 18px; accent-color: var(--blue-600); cursor: pointer; } .pq-pick input:disabled { cursor: not-allowed; }
.pq-body { flex: 1; min-width: 0; }
.pq-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.pq-no { font-weight: 800; font-size: 12.5px; color: var(--navy-700); background: var(--blue-100); border-radius: 7px; padding: 2px 8px; }
.pq-mk { font-size: 12px; font-weight: 700; color: var(--muted); }
.pq-issue { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; color: #B26A00; } .pq-issue svg { width: 14px; height: 14px; }
.pq-q { font-size: 14.5px; line-height: 1.55; color: var(--ink); font-weight: 600; word-break: break-word; }
.pq-opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; margin-top: 9px; }
.pq-opts button { display: flex; align-items: center; gap: 9px; text-align: left; border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 7px 10px; font-size: 13.5px; color: var(--ink-2); cursor: pointer; line-height: 1.4; }
.pq-opts button:hover:not(:disabled) { border-color: var(--blue-500); background: var(--blue-50); }
.pq-opts button span { flex: none; width: 22px; height: 22px; border-radius: 7px; background: var(--line-2); display: grid; place-items: center; font-weight: 800; font-size: 11.5px; color: var(--navy-700); }
.pq-opts button span:empty { display: none; }
.pq-opts button svg { margin-left: auto; flex: none; width: 16px; height: 16px; }
.pq-opts button.ok { border-color: #8AD3A0; background: #EEFAF1; color: #14663A; font-weight: 700; } .pq-opts button.ok span { background: #14803E; color: #fff; }
.pq-ansrow { margin-top: 9px; max-width: 420px; } .pq-ansrow label { display: block; font-size: 12px; font-weight: 700; color: var(--muted); margin-bottom: 4px; }
.pq-ex { margin-top: 8px; font-size: 12.5px; color: var(--muted); line-height: 1.5; } .pq-ex b { color: var(--ink-2); }
.pq-acts { display: flex; gap: 6px; margin-top: 8px; }
.pq-edit { display: flex; flex-direction: column; gap: 10px; }
.pq-edit .field { margin: 0; }
.pq-eo { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; } .pq-eo b { width: 18px; color: var(--navy-700); } .pq-eo .input { flex: 1; }
.pq-pre { margin: 0; max-height: 52vh; overflow: auto; background: #0F1B33; color: #D9E4F7; border-radius: 12px; padding: 14px; font-size: 12px; line-height: 1.6; white-space: pre-wrap; word-break: break-word; }
@media (max-width: 760px) { .pq { grid-template-columns: 1fr; height: 74vh; } .pq-side { border-right: 0; border-bottom: 1px solid var(--line-2); max-height: 38%; } .pq-opts { grid-template-columns: 1fr; } }
.pq-lock { pointer-events: none; opacity: .7; }
.pq-prog { width: 100%; }
.pq-prog-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 8px; font-size: 13.5px; color: var(--navy-800); } .pq-prog-top span { font-weight: 800; color: var(--blue-600); }
.pq-prog-bar { height: 12px; border-radius: 99px; background: var(--line-2); overflow: hidden; } .pq-prog-bar i { display: block; height: 100%; width: 0; border-radius: 99px; background: linear-gradient(90deg, var(--blue-500), #19A974); transition: width .25s ease; }
.pq-prog-sub { display: flex; gap: 14px; margin-top: 8px; font-size: 12.5px; font-weight: 700; color: var(--muted); align-items: center; flex-wrap: wrap; } .pq-prog-sub .ok { color: var(--green); } .pq-prog-sub .bad { color: var(--red); } .pq-prog-sub small { font-weight: 500; }
.pq-sum .done { color: var(--blue-600); }
/* status bar above the question table */
.stbar { padding: 12px 16px; border-bottom: 1px solid var(--line-2); background: #F8FAFD; }
.stbar:empty { display: none; }
.stbar-in { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.stbar-txt { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ink-2); font-weight: 600; }
.stbar-txt svg { width: 18px; height: 18px; color: var(--blue-600); flex: none; }
.stbar-txt b { color: var(--navy-800); }
.stbar-btns { display: inline-flex; gap: 8px; flex-wrap: wrap; }
.stbar-note { margin-left: auto; font-size: 12.5px; color: var(--muted); }
@media (max-width: 760px) { .stbar-note { margin-left: 0; } }

/* ---------- student photo block + crop dialog ---------- */
.ph-field { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 18px; align-items: center; padding: 16px; margin-bottom: 8px; border: 1px solid var(--line); border-radius: 18px; background: linear-gradient(135deg, #F2F7FF 0%, #FFFFFF 70%); }
.ph-drop { position: relative; width: 112px; height: 112px; border-radius: 26px; cursor: pointer; border: 2px dashed #B8C9E6; background: #FAFCFF; transition: transform .15s, border-color .15s, box-shadow .15s; outline: none; }
.ph-drop:hover, .ph-drop:focus-visible, .ph-drop.drag { border-color: var(--blue-500); box-shadow: 0 0 0 4px rgba(30, 111, 217, .12); }
.ph-drop.has { border: 3px solid #fff; box-shadow: 0 8px 22px rgba(10, 32, 87, .22); }
.ph-drop.has:hover { transform: translateY(-1px); }
.ph-img { position: absolute; inset: 0; border-radius: inherit; overflow: hidden; display: grid; place-items: center; }
.ph-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ph-empty { display: flex; flex-direction: column; align-items: center; gap: 4px; color: #7C93B8; }
.ph-empty svg { width: 38px; height: 38px; } .ph-empty small { font-weight: 700; font-size: 11.5px; }
.ph-cam { position: absolute; right: -8px; bottom: -8px; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--grad-accent, linear-gradient(135deg, #FF9A3D, #F26A1B)); box-shadow: 0 4px 12px rgba(242, 106, 27, .45); border: 3px solid #fff; }
.ph-cam svg { width: 16px; height: 16px; }
.ph-over { position: absolute; inset: 0; border-radius: inherit; display: none; place-items: center; background: rgba(30, 111, 217, .88); color: #fff; font-weight: 700; font-size: 13px; }
.ph-drop.drag .ph-over { display: grid; }
.ph-info { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ph-info b { font-size: 15px; color: var(--navy-800); }
.ph-sub { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.ph-btns { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; } .ph-btns .btn[hidden] { display: none; } .ph-btns svg { width: 16px; height: 16px; }
.ph-rm:hover { color: var(--red); border-color: #F2B8BA; background: #FFF5F5; }
.ph-note { color: var(--muted); font-size: 11.5px; margin-top: 4px; }
@media (max-width: 520px) { .ph-field { grid-template-columns: 1fr; justify-items: center; text-align: center; } .ph-btns { justify-content: center; } }

.pc { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 22px; align-items: start; }
.pc-stage { position: relative; width: 320px; height: 320px; border-radius: 20px; overflow: hidden; background: #0F1B33; cursor: grab; touch-action: none; outline: none; box-shadow: 0 10px 28px rgba(10, 32, 87, .3); user-select: none; }
.pc-stage.drag { cursor: grabbing; } .pc-stage:focus-visible { box-shadow: 0 0 0 3px var(--blue-500), 0 10px 28px rgba(10, 32, 87, .3); }
.pc-stage canvas { display: block; }
.pc-grid { position: absolute; inset: 0; pointer-events: none; background:
  linear-gradient(to right, transparent calc(33.33% - .5px), rgba(255,255,255,.4) calc(33.33% - .5px), rgba(255,255,255,.4) calc(33.33% + .5px), transparent calc(33.33% + .5px), transparent calc(66.66% - .5px), rgba(255,255,255,.4) calc(66.66% - .5px), rgba(255,255,255,.4) calc(66.66% + .5px), transparent calc(66.66% + .5px)),
  linear-gradient(to bottom, transparent calc(33.33% - .5px), rgba(255,255,255,.4) calc(33.33% - .5px), rgba(255,255,255,.4) calc(33.33% + .5px), transparent calc(33.33% + .5px), transparent calc(66.66% - .5px), rgba(255,255,255,.4) calc(66.66% - .5px), rgba(255,255,255,.4) calc(66.66% + .5px), transparent calc(66.66% + .5px)); box-shadow: inset 0 0 0 1px rgba(255,255,255,.55); border-radius: inherit; }
.pc-c { position: absolute; width: 22px; height: 22px; pointer-events: none; border: 0 solid #fff; }
.pc-c.a { left: 8px; top: 8px; border-left-width: 3px; border-top-width: 3px; border-top-left-radius: 8px; } .pc-c.b { right: 8px; top: 8px; border-right-width: 3px; border-top-width: 3px; border-top-right-radius: 8px; }
.pc-c.c { left: 8px; bottom: 8px; border-left-width: 3px; border-bottom-width: 3px; border-bottom-left-radius: 8px; } .pc-c.d { right: 8px; bottom: 8px; border-right-width: 3px; border-bottom-width: 3px; border-bottom-right-radius: 8px; }
.pc-tip { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); padding: 5px 12px; border-radius: 99px; background: rgba(10, 20, 45, .78); color: #fff; font-size: 12px; font-weight: 600; white-space: nowrap; pointer-events: none; transition: opacity .3s; }
.pc-tip.off { opacity: 0; }
.pc-warn { margin: 10px 0 0; padding: 8px 12px; border-radius: 10px; background: #FFF6E5; color: #9A5B00; font-size: 12.5px; line-height: 1.45; } .pc-warn[hidden] { display: none; }
.pc-right { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.pc-sec label { display: block; font-size: 11.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.pc-zoom { display: flex; align-items: center; gap: 10px; } .pc-zoom input[type=range] { flex: 1; accent-color: var(--blue-600); height: 6px; cursor: pointer; }
.pc-btns { display: flex; gap: 8px; flex-wrap: wrap; } .pc-btns svg { width: 16px; height: 16px; }
.pc-prev { display: flex; gap: 22px; align-items: flex-end; padding: 14px 16px; border: 1px solid var(--line-2); border-radius: 14px; background: #F8FAFD; }
.pc-prev div { display: flex; flex-direction: column; align-items: center; gap: 6px; } .pc-prev small { font-size: 11px; color: var(--muted); font-weight: 600; }
.pc-prev canvas { display: block; background: #fff; box-shadow: 0 2px 8px rgba(10, 32, 87, .18); }
.pc-prev div:first-child canvas { border-radius: 13px; } .pc-prev div:last-child canvas { border-radius: 16px; border: 3px solid #fff; }
.pc-note { margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.5; }
@media (max-width: 720px) { .pc { grid-template-columns: 1fr; justify-items: center; } .pc-stage { width: min(320px, 100%); } }

/* ---------- students table: action buttons on the left, kept in view while the table scrolls sideways ---------- */
.tbl .st-s1 { width: 158px; min-width: 158px; max-width: 158px; padding-left: 16px; padding-right: 8px; }
.tbl th.st-s1, .tbl th.st-s2 { background: #F8FAFE; }
.tbl td.st-s1, .tbl td.st-s2 { background: #fff; transition: background .1s; }
.tbl tbody tr:hover td.st-s1, .tbl tbody tr:hover td.st-s2 { background: var(--blue-50); }
.st-acts { display: inline-flex; align-items: center; gap: 4px; padding: 4px; border-radius: 16px; background: #F1F5FC; box-shadow: inset 0 0 0 1px #E3EAF6; }
.st-act { position: relative; width: 30px; height: 30px; border: 0; border-radius: 50%; display: grid; place-items: center; cursor: pointer; flex: none; background: #fff; color: var(--c, #1E6FD9); box-shadow: 0 1px 2px rgba(10, 32, 87, .12); transition: transform .12s, background .12s, color .12s, box-shadow .12s; }
.st-act svg { width: 16px; height: 16px; }
.st-act:hover, .st-act:focus-visible { background: var(--c, #1E6FD9); color: #fff; transform: translateY(-2px); box-shadow: 0 6px 12px rgba(10, 32, 87, .22); outline: none; }
.st-act.a-res { --c: #1E6FD9; } .st-act.a-fee { --c: #14934F; } .st-act.a-key { --c: #E08A00; } .st-act.a-edit { --c: #7A4CE0; } .st-act.a-off { --c: #E5484D; } .st-act.a-on { --c: #14934F; }
.st-act[data-tip]:hover::after, .st-act[data-tip]:focus-visible::after { content: attr(data-tip); position: absolute; left: 0; bottom: calc(100% + 8px); transform: none; padding: 4px 9px; border-radius: 7px; background: #0F1B33; color: #fff; font-size: 11.5px; font-weight: 600; white-space: nowrap; pointer-events: none; z-index: 9; }
.tbl td.st-s1:hover, .tbl td.st-s1:focus-within { z-index: 6; }
@media (min-width: 761px) {
  .tbl th.st-s1, .tbl td.st-s1 { position: sticky; left: 0; z-index: 3; }
  .tbl th.st-s2, .tbl td.st-s2 { position: sticky; left: 158px; z-index: 3; min-width: 250px; box-shadow: 6px 0 10px -8px rgba(10, 32, 87, .25); }
}
@media (max-width: 760px) { .tbl .st-s1 { width: auto; min-width: 0; max-width: none; } .st-act { width: 28px; height: 28px; } }

/* students table: scrolls inside its own box so the sideways scroll bar and the heading stay in view */
.st-scroll { position: relative; }
.st-wrap { max-height: max(300px, calc(100vh - 150px)); overflow: auto; overscroll-behavior: contain; outline: none; scrollbar-width: thin; scrollbar-color: #B8C9E6 transparent; }
.st-wrap:focus-visible { box-shadow: inset 0 0 0 2px rgba(30, 111, 217, .35); }
.st-wrap thead th { position: sticky; top: 0; z-index: 4; }
.st-wrap::-webkit-scrollbar { height: 12px; width: 12px; } .st-wrap::-webkit-scrollbar-thumb { background: #B8C9E6; border-radius: 10px; border: 3px solid #fff; } .st-wrap::-webkit-scrollbar-thumb:hover { background: #8FA9D6; }
.st-arrows { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; padding: 3px 4px 3px 12px; border-radius: 99px; background: #F1F5FC; box-shadow: inset 0 0 0 1px #E3EAF6; }
.st-arrows[hidden] { display: none; }
.st-arrows span { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-right: 4px; }
.st-arrows button { width: 32px; height: 32px; border: 0; border-radius: 50%; display: grid; place-items: center; background: #fff; color: var(--blue-600); cursor: pointer; box-shadow: 0 1px 2px rgba(10, 32, 87, .15); transition: background .12s, color .12s, opacity .12s; }
.st-arrows button:hover:not(:disabled) { background: var(--blue-600); color: #fff; } .st-arrows button:disabled { opacity: .35; cursor: default; }
.st-arrows svg { width: 17px; height: 17px; }
@media (min-width: 761px) { .tbl th.st-s1, .tbl th.st-s2 { z-index: 6; top: 0; } }
.st-rowacts { justify-content: flex-start; }

/* question bank: a ticked row keeps its highlight in the sticky columns */
.tbl tbody tr.sel td.st-s1, .tbl tbody tr.sel td.st-s2 { background: #EAF2FE; }

/* reports: the details table (sticky header and total row, sticky first column, scroll box, name badges) */
.rp-search { position: relative; display: inline-flex; align-items: center; }
.rp-search .i, .rp-search svg { position: absolute; left: 11px; width: 16px; height: 16px; color: var(--muted); pointer-events: none; }
.rp-search .input { padding-left: 34px; }
.rp-detail .rp-tt .hint { margin: 0; padding: 3px 10px; border-radius: 99px; background: #EEF3FB; color: var(--ink-2); font-weight: 700; font-size: 12px; }
.rp-detail .rp-chip { margin-left: 2px; }
.rp-scroll { position: relative; max-height: max(360px, calc(100vh - 300px)); overflow: auto; overscroll-behavior: contain; border-top: 1px solid var(--line-2); scrollbar-width: thin; scrollbar-color: #B8C9E6 transparent; }
.rp-scroll::-webkit-scrollbar { width: 12px; height: 12px; }
.rp-scroll::-webkit-scrollbar-thumb { background: #B8C9E6; border-radius: 10px; border: 3px solid #fff; }
.rp-detail .rp-tbl { border-collapse: separate; border-spacing: 0; width: 100%; }
.rp-detail .rp-tbl thead th { position: sticky; top: 0; z-index: 3; background: #F3F7FD; color: #5B6786; font-size: 11px; letter-spacing: .06em; padding: 11px 14px; border-top: 0; border-bottom: 1px solid #D9E3F2; white-space: nowrap; }
.rp-detail .rp-tbl th.num, .rp-detail .rp-tbl td.num { text-align: right; font-variant-numeric: tabular-nums; }
.rp-detail .rp-tbl td { padding: 11px 14px; white-space: nowrap; color: var(--ink-2); border-bottom: 1px solid #EEF2F8; background: #fff; transition: background .12s; }
.rp-detail .rp-tbl td b { color: var(--navy-800); }
.rp-detail .rp-tbl tbody tr:hover td { background: #F5F9FF; }
.rp-detail .rp-tbl tbody tr:last-child td { border-bottom: 0; }
.rp-detail .rp-tbl th.sortable { cursor: pointer; user-select: none; }
.rp-detail .rp-tbl th.sortable span { vertical-align: middle; }
.rp-detail .rp-tbl th.sortable i { display: inline-grid; place-items: center; width: 18px; height: 18px; margin-left: 6px; border-radius: 50%; font-style: normal; font-size: 8.5px; vertical-align: middle; background: #E4ECF8; color: #9AA8C4; transition: background .12s, color .12s; }
.rp-detail .rp-tbl th.sortable:hover i { background: #DCE8FA; color: var(--blue-600); }
.rp-detail .rp-tbl th.sorted { color: var(--blue-600); }
.rp-detail .rp-tbl th.sorted i { background: var(--blue-600); color: #fff; }
.rp-detail .rp-tbl tfoot td { position: sticky; bottom: 0; z-index: 2; background: #EDF4FE; border-top: 2px solid #C7DAF6; color: var(--navy-800); font-weight: 700; padding: 11px 14px; }
.rp-detail .rp-tbl tfoot td b { color: var(--navy-800); }
/* first column stays visible when the table is wider than the box */
.rp-detail .rp-tbl th:first-child, .rp-detail .rp-tbl td:first-child { position: sticky; left: 0; }
.rp-detail .rp-tbl th:first-child { z-index: 5; }
.rp-detail .rp-tbl td:first-child { z-index: 1; }
.rp-detail .rp-tbl tfoot td:first-child { z-index: 6; }
.rp-detail .rp-tbl td:first-child, .rp-detail .rp-tbl tfoot td:first-child { box-shadow: 8px 0 10px -10px rgba(10, 32, 87, .28); }
.rp-detail .rp-tbl tbody tr:hover td:first-child { background: #F5F9FF; }
.rp-who { display: flex; align-items: center; gap: 11px; }
.rp-who > div { min-width: 0; }
.rp-av { width: 34px; height: 34px; border-radius: 11px; flex: none; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 12.5px; letter-spacing: .02em; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .25); }
.rp-detail .rp-s { font-size: 12px; color: var(--muted); margin-top: 2px; }
.rp-detail .rp-none { padding: 40px 16px; }
.rp-detail .rp-pg { padding: 12px 16px; background: #FAFCFF; border-top: 1px solid #E4EBF5; }
.rp-detail .rp-pg > div { gap: 8px; }
.rp-detail .rp-pg b { background: #EEF3FB; padding: 5px 12px; border-radius: 99px; color: var(--navy-700); font-size: 12.5px; font-weight: 700; }
.rp-detail .rp-pg .btn { height: 32px; padding: 0 14px; }
.rp-detail .rp-pg .btn:disabled { opacity: .45; }
@media (max-width: 760px) { .rp-detail .rp-tbl td:first-child, .rp-detail .rp-tbl th:first-child { position: static; box-shadow: none; } .rp-scroll { max-height: none; } .rp-detail .rp-tbl tfoot td { position: static; } }

/* ---- Permissions card (Settings) ---- */
.pm-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.pm-tab { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; border: 1.5px solid var(--line); border-radius: 11px; background: #fff; color: var(--ink-2); font-weight: 600; font-size: 13.5px; cursor: pointer; transition: background .15s, border-color .15s; }
.pm-tab svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.pm-tab:hover { border-color: var(--blue-500); }
.pm-tab.on { background: var(--blue-600); border-color: var(--blue-600); color: #fff; }
.pm-n { font-style: normal; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 20px; background: #FDECEC; color: #C23A3F; }
.pm-tab.on .pm-n { background: rgba(255,255,255,.22); color: #fff; }
.pm-info { margin: 12px 0 2px; }
.pm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 14px; margin-top: 12px; }
.pm-grp { border: 1px solid var(--line); border-radius: 13px; padding: 12px 16px 8px; background: #fff; }
.pm-gh { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-bottom: 6px; margin-bottom: 2px; border-bottom: 1px solid var(--line-2); }
.pm-gh h3 { margin: 0; font-size: 14px; font-weight: 700; color: var(--ink); }
.pm-all { display: inline-flex; gap: 4px; }
.pm-all button { border: 0; background: transparent; color: var(--blue-600); font-size: 12px; font-weight: 600; padding: 3px 7px; border-radius: 7px; cursor: pointer; }
.pm-all button:hover { background: var(--blue-50); }
.pm-grp .switch { padding: 8px 0; align-items: flex-start; }
.pm-grp .switch .tr { margin-top: 2px; }
.pm-grp .switch small { display: block; margin-top: 1px; line-height: 1.35; }
.pm-foot { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line-2); }
.pm-foot .hint { flex: 1; min-width: 180px; }

/* ===== Attendance (admin): register and places ===== */
.at-filters { align-items: flex-end; }
.at-dates { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.at-l { display: grid; gap: 4px; font-size: 12px; font-weight: 700; color: var(--muted); }
.at-l .input { min-width: 150px; }
.at-quick { display: flex; gap: 6px; flex-wrap: wrap; padding-bottom: 2px; }
.at-tbl td { vertical-align: top; }
.at-t { font-weight: 700; font-variant-numeric: tabular-nums; }
.at-pl { display: grid; gap: 1px; margin-top: 2px; font-size: 12.5px; color: var(--muted); }
.at-pl b { color: var(--ink-2); font-weight: 600; }
.at-pl a { color: var(--blue-600); font-weight: 600; } .at-pl a:hover { text-decoration: underline; }
.at-act { width: 44px; text-align: right; }
.at-places { padding: 18px; display: grid; gap: 22px; }
.at-ph { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.at-ph h3 { font-size: 17px; } .at-ph p { max-width: 640px; margin-top: 4px; }
.at-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.at-card { display: grid; gap: 12px; padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.at-card.off { opacity: .65; }
.at-ch { display: flex; align-items: center; gap: 12px; }
.at-ch > div { flex: 1; } .at-ch b { display: block; font-size: 15px; } .at-ch small { color: var(--muted); font-size: 12.5px; }
.at-ic { flex: none; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--blue-50, #EEF4FC); color: var(--blue-600); }
.at-ic .i { width: 20px; height: 20px; }
.at-ad { color: var(--ink-2); font-size: 13.5px; }
.at-dl { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0; }
.at-dl div { padding: 9px 11px; border-radius: 10px; background: var(--bg, #F6F8FB); border: 1px solid var(--line-2, #EDF1F6); }
.at-dl dt { font-size: 10.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.at-dl dd { margin: 2px 0 0; font-weight: 700; font-variant-numeric: tabular-nums; }
.at-cf { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.at-rules { padding-top: 18px; border-top: 1px solid var(--line); } .at-rules h3 { font-size: 17px; margin-bottom: 12px; }
.at-locrow { display: grid; gap: 6px; justify-items: start; padding: 4px 0 2px; }
.at-map { margin-top: 6px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); height: 190px; }
.at-map iframe { width: 100%; height: 100%; border: 0; display: block; }
@media (max-width: 640px) { .at-dates, .at-l .input { width: 100%; } .at-l { flex: 1; } }

/* ===== Faculty (admin portal): people, register and "My attendance" ===== */
.fa-av { flex: none; width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--blue-100); color: var(--blue-600); font-weight: 800; font-size: 13px; letter-spacing: .02em; position: relative; overflow: hidden; }
.fa-av img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: var(--blue-100); }
.fa-cred { display: grid; gap: 10px; }
.fa-cred > div { padding: 12px 14px; border-radius: 12px; background: var(--bg); border: 1px solid var(--line); }
.fa-cred small { display: block; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.fa-cred b { display: block; margin-top: 3px; font-size: 17px; font-family: ui-monospace, Consolas, monospace; letter-spacing: .04em; word-break: break-all; }
.fa-wrap { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.fa-side { display: grid; gap: 16px; min-width: 0; }
.fa-month, .fa-hist { padding: 18px; }
.fa-month h4, .fa-hist h4 { margin: 0 0 12px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.fa-wrap .att-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(92px, 1fr)); gap: 10px; }
.fa-wrap .att-stats > div { padding: 10px 12px; border-radius: 10px; background: var(--bg); border: 1px solid var(--line-2); }
.fa-wrap .att-stats b { display: block; font-size: 20px; color: var(--navy-800); font-variant-numeric: tabular-nums; } .fa-wrap .att-stats b em { font-style: normal; font-size: 13px; font-weight: 600; color: var(--muted); }
.fa-wrap .att-stats small { color: var(--muted); font-size: 12px; font-weight: 600; }
.fa-wrap .att-bar { height: 6px; margin-top: 14px; border-radius: 6px; background: var(--line-2); overflow: hidden; } .fa-wrap .att-bar i { display: block; height: 100%; border-radius: 6px; background: #0E8A5F; }
.fa-wrap .att-list { list-style: none; margin: 0; padding: 0; }
.fa-wrap .att-list li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-2); } .fa-wrap .att-list li:first-child { border-top: 0; padding-top: 0; }
.fa-wrap .att-dt { flex: none; width: 44px; padding: 6px 0; text-align: center; border-radius: 10px; background: var(--bg); border: 1px solid var(--line-2); }
.fa-wrap .att-dt b { display: block; font-size: 17px; line-height: 1.1; color: var(--navy-800); } .fa-wrap .att-dt small { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.fa-wrap .att-lt { flex: 1; min-width: 0; } .fa-wrap .att-lt b { display: block; font-size: 14px; font-variant-numeric: tabular-nums; }
.fa-wrap .att-lt small { display: block; font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fa-wrap .att-rt { display: grid; justify-items: end; gap: 3px; } .fa-wrap .att-rt small { font-size: 12px; color: var(--muted); }
.fa-wrap .att-empty { margin: 0; color: var(--muted); font-size: 13.5px; }
@media (max-width: 899px) { .fa-wrap { grid-template-columns: 1fr; } }


/* ===== attendance experience (student portal "Attendance" and the faculty "My attendance"): hero clock, rules, steps ===== */
.ax { padding: 0; overflow: hidden; min-width: 0; }
.ax svg.i { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.ax-hero { display: grid; gap: 16px; padding: 22px 22px 20px; background: var(--navy-800); color: #fff; }
.ax-hrow { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px 12px; flex-wrap: wrap; }
.ax-clock { display: block; font-size: clamp(30px, 9.5vw, 42px); line-height: 1.05; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; white-space: nowrap; color: #fff; }
.ax-date { display: block; margin-top: 6px; font-size: 13px; font-weight: 600; color: rgba(255, 255, 255, .72); }
.ax-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 700; white-space: nowrap; background: rgba(255, 255, 255, .13); color: #fff; border: 1px solid rgba(255, 255, 255, .2); }
.ax-chip.in { background: #19A874; border-color: #19A874; } .ax-chip.late { background: #F2B03D; border-color: #F2B03D; color: #3A2600; }
.ax-chip.done { background: #fff; border-color: #fff; color: var(--navy-800); } .ax-chip.short { background: #E5736A; border-color: #E5736A; }
.ax-pills { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.ax-pills li { display: inline-flex; align-items: center; gap: 6px; padding: 6px 11px; border-radius: 999px; font-size: 12px; font-weight: 600; background: rgba(255, 255, 255, .09); border: 1px solid rgba(255, 255, 255, .16); color: rgba(255, 255, 255, .92); }
.ax-pills .i { width: 14px; height: 14px; flex: none; }
.ax-stay { display: grid; gap: 8px; }
.ax-sl { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; font-size: 12.5px; font-weight: 600; color: rgba(255, 255, 255, .78); }
.ax-sl b { font-size: 15px; color: #fff; font-variant-numeric: tabular-nums; }
.ax-sb { height: 8px; border-radius: 8px; background: rgba(255, 255, 255, .16); overflow: hidden; }
.ax-sb i { display: block; height: 100%; border-radius: 8px; background: #F2B03D; transition: width .6s ease; }
.ax-stay.ok .ax-sb i { background: #3FD39B; }
.ax-body { display: grid; gap: 14px; padding: 18px 22px 22px; }
.ax-geo { display: flex; gap: 12px; padding: 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); }
.ax-geo > div { min-width: 0; } .ax-geo b { display: block; font-size: 14.5px; color: var(--ink); } .ax-geo small { display: block; margin-top: 2px; font-size: 13px; line-height: 1.5; color: var(--muted); } .ax-geo .btn { margin-top: 10px; }
.ax-gi { flex: none; width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: #fff; border: 1px solid var(--line); color: var(--muted); }
.ax-gi .i { width: 19px; height: 19px; }
.ax-geo.ok { background: #EAF7F1; border-color: #BFE5D3; } .ax-geo.ok .ax-gi { background: #0E8A5F; border-color: #0E8A5F; color: #fff; }
.ax-geo.warn { background: #FEF6E4; border-color: #F3DCA6; } .ax-geo.warn .ax-gi { background: #C98A10; border-color: #C98A10; color: #fff; }
.ax-geo.bad { background: #FDF0EE; border-color: #F3C7C1; } .ax-geo.bad .ax-gi { background: #C0392B; border-color: #C0392B; color: #fff; }
.ax-geo.ask .ax-gi, .ax-geo.wait .ax-gi { color: var(--blue-600); }
.ax-geo.wait .ax-gi { animation: axpulse 1.4s ease-in-out infinite; }
@keyframes axpulse { 50% { opacity: .45; } }
.ax-err { margin: 0; padding: 10px 12px; border-radius: 10px; background: #FDECEA; color: #B42318; font-size: 13.5px; font-weight: 600; }
.ax-note { margin: 0; padding: 10px 12px; border-radius: 10px; background: #FEF6E4; color: #7A4B05; font-size: 13px; font-weight: 600; line-height: 1.5; }
.ax-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.ax-step { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); background: #fff; }
.ax-step.next { border-color: #BCD3F3; background: var(--blue-50); } .ax-step.done { background: #F4FAF7; border-color: #CDEBDC; } .ax-step.wait { opacity: .65; }
.ax-n { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 14px; background: var(--line-2); color: var(--ink-2); }
.ax-step.next .ax-n { background: var(--blue-600); color: #fff; } .ax-step.done .ax-n { background: #0E8A5F; color: #fff; } .ax-n .i { width: 17px; height: 17px; stroke-width: 2.6; }
.ax-t { flex: 1; min-width: 0; } .ax-t b { display: block; font-size: 15px; color: var(--ink); }
.ax-t small { display: block; margin-top: 1px; font-size: 12.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ax-tm { font-weight: 800; font-size: 15px; font-variant-numeric: tabular-nums; color: #0B6B4D; }
.ax-lock { color: var(--muted); display: inline-flex; } .ax-lock .i { width: 17px; height: 17px; }
.ax-go { flex: none; min-height: 44px; justify-content: center; white-space: nowrap; }
.ax-go:disabled { opacity: .55; cursor: not-allowed; filter: none; }
.ax-hint { margin: 2px 0 0; font-size: 12.5px; font-weight: 600; color: #92580A; }
.ax-rl { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.ax-rl li { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-top: 1px solid var(--line-2); font-size: 14px; color: var(--ink); } .ax-rl li:first-child { border-top: 0; padding-top: 0; }
.ax-rl .i { flex: none; width: 34px; height: 34px; padding: 8px; border-radius: 10px; background: var(--blue-50); color: var(--blue-600); }
.ax-rl span { flex: 1; min-width: 0; color: var(--ink-2); } .ax-rl b { font-variant-numeric: tabular-nums; color: var(--navy-800); white-space: nowrap; }
.ax-chip2 { display: inline-flex; align-items: center; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; white-space: nowrap; background: var(--line-2); color: var(--ink-2); }
.ax-chip2.in { background: #E3F4EC; color: #0B6B4D; } .ax-chip2.late { background: #FDF1DC; color: #92580A; } .ax-chip2.short { background: #F1E7FB; color: #6B2FB0; } .ax-chip2.hold { background: #E3EEFC; color: #1558B0; } .ax-chip2.absent { background: #FDE8E8; color: #B42318; }
@media (max-width: 560px) {
  .ax-hero { padding: 18px 16px; } .ax-body { padding: 16px; }
  .ax-step { flex-wrap: wrap; row-gap: 10px; } .ax-go { width: 100%; order: 5; }
}

/* ===== attendance rules tab (admin) ===== */
.at-rules { padding: 18px; display: grid; gap: 18px; border-top: 0; }
.at-rtop { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg); }
.at-rcs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
.at-rc { border: 1px solid var(--line); border-radius: 16px; background: #fff; padding: 18px; display: grid; gap: 16px; min-width: 0; }
.at-rh { display: flex; align-items: center; gap: 12px; } .at-rh > div { flex: 1; min-width: 0; } .at-rh b { display: block; font-size: 16px; color: var(--navy-800); } .at-rh small { display: block; color: var(--muted); font-size: 12.5px; margin-top: 1px; }
.at-ric { flex: none; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--blue-100); color: var(--blue-600); } .at-ric .i { width: 20px; height: 20px; }
.at-rg { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; } .at-rg .field { margin: 0; }
.at-sum { list-style: none; margin: 0; padding: 12px 14px; display: grid; gap: 8px; border-radius: 12px; background: var(--blue-50); }
.at-sum li { display: flex; gap: 9px; align-items: flex-start; font-size: 13px; line-height: 1.45; color: var(--ink-2); } .at-sum .i { flex: none; width: 15px; height: 15px; margin-top: 2px; color: #0E8A5F; stroke-width: 2.6; }
.at-rsave { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; } .at-rsave .hint { margin: 0; flex: 1; min-width: 220px; }
@media (max-width: 899px) { .at-rtop, .at-rcs { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .at-rg { grid-template-columns: 1fr; } .at-rules { padding: 14px; } }
.ax-t .ax-hint { white-space: normal; color: #92580A; font-weight: 600; }

/* ===== loader (shown while data is being fetched) and the request progress bar ===== */
.ld { min-height: 52vh; display: grid; place-content: center; justify-items: center; gap: 4px; padding: 24px 16px; text-align: center; opacity: 0; animation: ldIn .35s ease .15s both; }
.ld.sm { min-height: 140px; padding: 16px; }
@keyframes ldIn { from { opacity: 0; transform: translateY(8px) scale(.97); } to { opacity: 1; transform: none; } }
.ld-orb { position: relative; width: 88px; height: 88px; margin-bottom: 14px; display: grid; place-items: center; }
.ld.sm .ld-orb { width: 60px; height: 60px; margin-bottom: 10px; }
.ld-orb::before, .ld-orb::after { content: ""; position: absolute; border-radius: 50%; border: 4px solid var(--line-2, #EEF2F9); }
.ld-orb::before { inset: 0; } .ld-orb::after { inset: 11px; }
.ld.sm .ld-orb::before, .ld.sm .ld-orb::after { border-width: 3px; } .ld.sm .ld-orb::after { inset: 8px; }
.ld-ring { position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(from 0deg, transparent 0 50%, var(--ld-a, var(--blue-600, #1E6FD9)) 100%);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 3px)); mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 calc(100% - 3px)); animation: ldSpin 1.1s linear infinite; }
.ld-ring.r2 { inset: 11px; background: conic-gradient(from 180deg, transparent 0 50%, var(--ld-b, #F7931E) 100%); animation-duration: 1.7s; animation-direction: reverse; }
.ld.sm .ld-ring.r2 { inset: 8px; }
.ld.sm .ld-ring { -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 2px)); mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 2px)); }
@keyframes ldSpin { to { transform: rotate(360deg); } }
.ld-core { position: relative; display: flex; align-items: flex-end; gap: 3px; height: 22px; }
.ld.sm .ld-core { height: 16px; gap: 2px; }
.ld-core i { display: block; width: 5px; height: 8px; border-radius: 3px; background: var(--ld-a, var(--blue-600, #1E6FD9)); animation: ldBar 1s ease-in-out infinite; }
.ld.sm .ld-core i { width: 4px; }
.ld-core i:nth-child(2) { background: var(--ld-b, #F7931E); animation-delay: .15s; } .ld-core i:nth-child(3) { animation-delay: .3s; }
@keyframes ldBar { 0%, 100% { height: 7px; } 50% { height: 22px; } }
.ld.sm .ld-core i { animation-name: ldBarS; } @keyframes ldBarS { 0%, 100% { height: 5px; } 50% { height: 16px; } }
.ld-t { display: inline-flex; align-items: baseline; font-size: 17px; font-weight: 700; color: var(--navy-800, #0A2057); }
.ld.sm .ld-t { font-size: 15px; }
.ld-dots { display: inline-flex; gap: 3px; margin-left: 4px; }
.ld-dots i { display: block; width: 4px; height: 4px; border-radius: 50%; background: currentColor; animation: ldDot 1.2s ease-in-out infinite both; }
.ld-dots i:nth-child(2) { animation-delay: .15s; } .ld-dots i:nth-child(3) { animation-delay: .3s; }
@keyframes ldDot { 0%, 80%, 100% { transform: translateY(0); opacity: .3; } 40% { transform: translateY(-4px); opacity: 1; } }
.ld small { color: var(--muted, #6B7794); font-size: 13px; }
td > .ld { width: 100%; }
#netBar { position: fixed; z-index: 9999; top: 0; left: 0; height: 3px; width: 0; opacity: 0; pointer-events: none; border-radius: 0 3px 3px 0; background: linear-gradient(90deg, var(--ld-a, var(--blue-600, #1E6FD9)), var(--ld-b, #F7931E)); box-shadow: 0 0 10px rgba(30, 111, 217, .45); }
#netBar.on { animation: netGrow 10s cubic-bezier(.1, .6, .2, 1) .2s forwards; }
@keyframes netGrow { 0% { width: 0; opacity: 1; } 12% { opacity: 1; } 100% { width: 92%; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .ld-ring { animation-duration: 3s; } .ld-core i, .ld-dots i { animation-duration: 2.4s; } }
/* ===== Month sheet (attendance + faculty): one row per person, one column per date ===== */
.am-nav { display: inline-flex; align-items: center; gap: 6px; }
.am-nav .input { width: 170px; }
.am-nav .icon-btn:disabled { opacity: .4; cursor: not-allowed; }
.am-leg { display: flex; flex-wrap: wrap; gap: 8px 16px; padding: 4px 16px 12px; font-size: 12.5px; color: var(--ink-2); }
.am-leg span { display: inline-flex; align-items: center; gap: 7px; }
.am-wrap { overflow: auto; max-height: 70vh; }
.am-tbl { border-collapse: separate; border-spacing: 0; width: max-content; min-width: 100%; }
.am-tbl th, .am-tbl td { padding: 0; border-bottom: 1px solid var(--line-2); text-align: center; }
.am-tbl thead th { position: sticky; top: 0; z-index: 2; background: #F6F8FC; padding: 7px 0; }
.am-who { position: sticky; left: 0; z-index: 3; min-width: 190px; max-width: 230px; padding: 8px 12px !important; text-align: left !important; background: #fff; border-right: 1px solid var(--line); }
.am-tbl thead .am-who { z-index: 4; background: #F6F8FC; }
.am-who b { display: block; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.am-who small { display: block; margin-top: 1px; font-size: 11.5px; font-weight: 500; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.am-d { min-width: 34px; font-weight: 700; } .am-d b { display: block; font-size: 12.5px; color: var(--ink); } .am-d small { display: block; font-size: 10px; color: var(--muted); font-weight: 700; }
.am-d.sun { background: #FCEFEF; } .am-d.sun b { color: #B42318; }
.am-d.now { background: #E3EEFC; box-shadow: inset 0 -3px 0 #1E6BD1; }
.am-x { height: 40px; min-width: 34px; }
.am-tbl tbody tr:hover td { background: #F8FAFD; } .am-tbl tbody tr:hover .am-who { background: #F8FAFD; }
.am-c { display: inline-grid; place-items: center; min-width: 26px; height: 24px; padding: 0 4px; border-radius: 7px; font-style: normal; font-size: 11.5px; font-weight: 800; letter-spacing: .01em; background: #EEF1F6; color: #64748B; }
.am-c.p { background: #DDF3E8; color: #0B6B4D; } .am-c.l { background: #FDEBC8; color: #92580A; } .am-c.s { background: #EFE3FB; color: #6B2FB0; }
.am-c.lv { background: #D6F1F4; color: #0F7A8A; } .am-t.lv { color: #0F7A8A; }
.am-c.hd { background: #DCE9FA; color: #1558B0; } .am-c.a { background: #FBDADA; color: #B42318; } .am-c.wo { background: #F1F3F7; color: #98A2B3; font-weight: 700; }
.am-t { min-width: 54px; padding: 0 8px !important; font-size: 13px; font-weight: 800; background: #FAFBFD; }
.am-t.p { color: #0B6B4D; } .am-t.hd { color: #1558B0; } .am-t.a { color: #B42318; border-right: 1px solid var(--line); }
.am-t small { display: block; font-size: 10px; font-weight: 700; color: #6B2FB0; }
.am-tbl thead .am-t { font-size: 11px; letter-spacing: .04em; text-transform: uppercase; }
/* attendance sheets: pick-lists beside the search, and the count in the legend */
.at-filters .select { max-width: 220px; text-overflow: ellipsis; }
.at-filters .select[hidden], .at-filters .btn[hidden] { display: none; }
.am-cnt { margin-left: auto; font-size: 12.5px; font-weight: 800; color: var(--navy-800, #10294A); }

/* ---- income & expenses: heads and subheads, entries */
.ah-subs { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.ah-chip { display: inline-flex; align-items: stretch; border: 1px solid var(--line); border-radius: 999px; background: var(--blue-100); overflow: hidden; }
.ah-chip button { border: 0; background: transparent; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--blue-600); padding: 3px 10px; cursor: pointer; }
.ah-chip button:hover { background: #D5E5FB; }
.ah-chip button + button { padding: 3px 8px 3px 6px; color: var(--muted); font-size: 15px; line-height: 1; border-left: 1px solid rgba(0, 0, 0, .06); }
.ah-chip button + button:hover { color: var(--red); background: var(--red-bg); }
.ah-chip small { margin-left: 4px; padding: 0 6px; border-radius: 999px; background: #fff; color: var(--muted); font-weight: 700; font-size: 11px; }
.ah-chip.off { opacity: .6; background: var(--line-2); }
.ah-add { display: inline-flex; align-items: center; gap: 4px; border: 1px dashed var(--line); background: transparent; border-radius: 999px; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--muted); padding: 3px 10px 3px 7px; cursor: pointer; }
.ah-add .i { width: 13px; height: 13px; }
.ah-add:hover { color: var(--blue-600); border-color: var(--blue-600); }
.ac-dot { flex: none; width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; }
.ac-dot .i { width: 16px; height: 16px; }
.ac-dot.in { background: var(--green-bg); color: var(--green); }
.ac-dot.out { background: var(--red-bg); color: var(--red); }

/* ===== Users & roles ===== */
.rl-chip { display: inline-flex; align-items: center; padding: 4px 11px; border-radius: 999px; font-size: 12.5px; font-weight: 700; background: #E6EEFB; color: #1558B0; white-space: nowrap; }
.rl-pages { display: flex; flex-wrap: wrap; gap: 5px; }
.rl-pages span { padding: 3px 9px; border-radius: 8px; font-size: 12px; font-weight: 600; background: var(--line-2); color: var(--ink-2); white-space: nowrap; }
.rl-pages .more { background: transparent; color: var(--muted); border: 1px dashed var(--line); }
.rl-h { font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin-bottom: 5px; }
.rl-full { min-width: 260px; }
.rl-presets { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; width: 100%; max-width: 720px; margin: 8px auto 16px; }
.rl-preset { text-align: left; padding: 14px 16px; border-radius: 14px; border: 1.5px solid var(--line); background: #fff; font: inherit; cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.rl-preset:hover { border-color: var(--blue-600); box-shadow: var(--shadow-sm); }
.rl-preset b { display: block; font-size: 15px; color: var(--navy-800); } .rl-preset small { display: block; margin-top: 4px; font-size: 12.5px; line-height: 1.45; color: var(--muted); }
.rl-start { display: flex; flex-wrap: wrap; gap: 8px; }
.rl-sbtn { padding: 7px 14px; border-radius: 999px; border: 1.5px solid var(--line); background: #fff; font: inherit; font-size: 13px; font-weight: 700; color: var(--ink-2); cursor: pointer; }
.rl-sbtn:hover { border-color: var(--blue-600); color: var(--blue-600); } .rl-sbtn.on { background: var(--blue-600); border-color: var(--blue-600); color: #fff; }
.rl-mx { margin-top: 10px; }
.rl-tools { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.rl-grid { max-height: 44vh; overflow: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.rl-row { display: grid; grid-template-columns: minmax(0, 1fr) 76px 76px 76px; align-items: center; padding: 8px 14px; border-top: 1px solid var(--line-2); }
.rl-hd { position: sticky; top: 0; z-index: 1; border-top: 0; background: var(--bg); font-size: 11.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); } .rl-hd span:not(:first-child) { text-align: center; }
.rl-gname { padding: 7px 14px; background: var(--blue-50); font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--navy-700); border-top: 1px solid var(--line-2); }
.rl-pg b { font-size: 14px; color: var(--ink); } .rl-na { text-align: center; color: var(--line); }
.rl-cb { display: flex; justify-content: center; cursor: pointer; }
.rl-cb input { position: absolute; opacity: 0; width: 0; height: 0; }
.rl-cb span { width: 22px; height: 22px; border-radius: 7px; border: 2px solid #B8C4DA; background: #fff; display: grid; place-items: center; transition: all .12s; }
.rl-cb input:checked + span { background: var(--blue-600); border-color: var(--blue-600); }
.rl-cb input:checked + span::after { content: ""; width: 5px; height: 10px; margin-top: -2px; border: solid #fff; border-width: 0 2.4px 2.4px 0; transform: rotate(45deg); }
.rl-cb input:focus-visible + span { box-shadow: 0 0 0 3px rgba(26, 91, 216, .3); }
@media (max-width: 560px) { .rl-row { grid-template-columns: minmax(0, 1fr) 54px 54px 54px; padding: 8px 8px; } }
.su-scopes { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.su-scope { display: flex; align-items: flex-start; gap: 10px; text-align: left; padding: 12px; border-radius: 14px; border: 1.5px solid var(--line); background: #fff; font: inherit; cursor: pointer; transition: border-color .15s, background .15s; }
.su-scope:hover:not(:disabled) { border-color: var(--blue-600); }
.su-scope.on { border-color: var(--blue-600); background: var(--blue-50); box-shadow: 0 0 0 3px rgba(26, 91, 216, .12); }
.su-scope:disabled { opacity: .55; cursor: not-allowed; }
.su-ic { flex: none; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: #E6EEFB; color: var(--blue-600); }
.su-ic .i, .su-ic svg { width: 18px; height: 18px; }
.su-scope b { display: block; font-size: 14px; color: var(--navy-800); } .su-scope small { display: block; margin-top: 2px; font-size: 12px; line-height: 1.4; color: var(--muted); }
.su-brpick { margin-top: 10px; }
.rl-chip.su-br, .rl-chip.su-ho { gap: 6px; background: var(--line-2); color: var(--ink-2); } .rl-chip.su-br { background: #FFF1E0; color: #B35A00; }
.rl-chip .i, .rl-chip svg { width: 14px; height: 14px; }
@media (max-width: 560px) { .su-scopes { grid-template-columns: 1fr; } }

/* website chat, read by the super admin */
.schat { display: grid; grid-template-columns: 340px 1fr; gap: 16px; align-items: start; }
.sch-row { width: 100%; text-align: left; border: 0; background: transparent; cursor: pointer; font: inherit; color: inherit; }
.sch-row.on { background: #eef5ff; }
.sch-thread { min-height: 360px; }
.sch-h { padding: 16px 18px 8px; }
.sch-h b { display: block; font-size: 16px; }
.sch-h span { color: var(--muted); font-size: 13px; }
.sch-log { display: flex; flex-direction: column; gap: 8px; padding: 8px 18px 18px; max-height: 62vh; overflow: auto; }
.sch-m { max-width: 80%; padding: 10px 12px; border-radius: 14px; }
.sch-m p { margin: 0; }
.sch-m small { display: block; margin-top: 4px; color: var(--muted); font-size: 11px; }
.sch-m.bot { align-self: flex-start; background: #eef5ff; }
.sch-m.vis { align-self: flex-end; background: #fff4e8; }
.sch-m img { display: block; width: min(100%, 420px); margin-top: 8px; border-radius: 10px; border: 1px solid var(--line); }
@media (max-width: 800px) { .schat { grid-template-columns: 1fr; } }