@font-face{font-family:"KV Gujarati";src:url('/assets/NotoSansGujarati-Regular.ttf') format('truetype');font-weight:400;font-style:normal;font-display:swap;unicode-range:U+0A80-0AFF,U+200C-200D}
@font-face{font-family:"KV Gujarati";src:url('/assets/NotoSansGujarati-Bold.ttf') format('truetype');font-weight:600 900;font-style:normal;font-display:swap;unicode-range:U+0A80-0AFF,U+200C-200D}
/* Kiddoverse shared visual contract. Roles retain their existing server permissions. */
:root{--kv-rail:240px;--kv-purple:#543184;--kv-deep:#30204f;--kv-ink:#30243f;--kv-muted:#6d6179;--kv-line:#e5ddec;--kv-paper:#f6f5f9;--kv-card:#fff}
body{font-family:var(--kv-font-body,system-ui);color:var(--kv-ink)}
body.portal-design,body:has(#familyPortal){background:var(--kv-paper)}
.staff-workspace-shell #staffWorkspaceRail{width:var(--kv-rail);background:var(--kv-deep);padding:24px 18px}
.staff-workspace-shell>header,.staff-workspace-shell[data-portal-page=staff]>header{margin-left:var(--kv-rail);min-height:88px;padding:20px 32px!important}
.staff-workspace-shell>main,.staff-workspace-shell #teacherWorkspace,.staff-workspace-shell[data-portal-page=staff] main{margin-left:var(--kv-rail)!important;padding:28px 32px 50px!important}
.staff-workspace-shell .teacher-task-nav{display:none}
.staff-workspace-shell .staff-dashboard-hero{border-radius:20px;padding:28px 32px}.staff-workspace-shell .staff-dashboard-hero h2{font-size:32px}
.staff-workspace-shell .staff-hero-art{height:140px}.staff-workspace-shell .staff-panel-grid>section{border-radius:18px}
.staff-workspace-shell #staffClassAttendance input,.staff-workspace-shell #staffClassAttendance select{width:100%}
.staff-workspace-shell>header .staff-actions a,.staff-workspace-shell .teacher-header button{min-height:44px;font-size:13px}
#familyPortal{font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
#familyPortal .family-header{background:white;border-bottom:1px solid var(--kv-line)}
#familyPortal :where(input,select,textarea,button){font-family:inherit}
#familyPortal :where(input:not([type=checkbox]):not([type=radio]),select,textarea){font-size:14px;border-radius:10px;min-height:46px;border-color:#cfc3df}
#familyPortal :where(button,.account-button){border-radius:10px;min-height:44px}
#familyPortal :where(button,a,input,select,textarea):focus-visible{outline:3px solid #a68acb;outline-offset:3px}
#familyPortal .family-card{border-radius:18px;border-color:var(--kv-line)}
@media(min-width:1000px){
#familyPortal{padding-left:var(--kv-rail)}
#familyPortal .family-header{max-width:none;margin:0;padding:20px 32px;min-height:88px;justify-content:space-between}
#familyPortal .family-header>a{font-size:18px;color:var(--kv-ink);text-decoration:none}
#familyPortal .family-header>a::after{content:'Family workspace';font-weight:650}
#familyPortal .family-header img{display:none}
#familyContent{max-width:1380px!important;margin:0 auto!important;padding:24px 32px 50px!important}
#familyPortal .family-nav{position:fixed;inset:0 auto 0 0;width:var(--kv-rail);max-width:none;margin:0;border:0;border-radius:0;background:var(--kv-deep);color:white;box-shadow:none;display:flex;flex-direction:column;justify-content:flex-start;gap:6px;padding:24px 18px;overflow-y:auto;backdrop-filter:none}
#familyPortal .family-nav::before{content:'';display:block;flex:none;height:112px;background:white url('/assets/kiddoverse-logo.jpeg') center/160px auto no-repeat;border-radius:18px;margin-bottom:24px}
#familyPortal .family-nav button{display:flex;flex-direction:row;justify-content:flex-start;gap:12px;flex:none;padding:12px 14px;min-height:46px;background:transparent;color:#e5daef;border:0;border-left:3px solid transparent;border-radius:10px;font-size:14px}
#familyPortal .family-nav button[aria-current]{background:#ffffff16;color:white;border-left-color:#b7e578}
#familyPortal .family-nav button:hover{background:#ffffff10;color:white}
#familyPortal .family-nav button svg{width:20px;height:20px}
}
@media(max-width:999px){#familyPortal .family-nav button[aria-current]{color:var(--kv-purple);background:#f0e9f8}#familyContent{padding-bottom:100px!important}}
@media(max-width:760px){.staff-workspace-shell #staffWorkspaceRail{width:270px}.staff-workspace-shell>header,.staff-workspace-shell[data-portal-page=staff]>header{margin-left:0;padding:16px 18px!important}.staff-workspace-shell>main,.staff-workspace-shell #teacherWorkspace,.staff-workspace-shell[data-portal-page=staff] main{margin-left:0!important;padding:22px 16px 40px!important}.staff-workspace-shell .staff-dashboard-hero{padding:24px}.staff-workspace-shell .staff-dashboard-hero h2{font-size:28px}#familyPortal .family-header{padding:14px 16px}#familyPortal .header-actions{gap:6px;flex-wrap:wrap;justify-content:flex-end}}
@media print{#familyPortal{padding-left:0}#familyPortal .family-nav{display:none}.staff-workspace-shell #staffWorkspaceRail{display:none}.staff-workspace-shell>main{margin-left:0!important}}
@media(min-width:761px) and (max-width:1100px){.staff-workspace-shell .teacher-register-controls{grid-template-columns:minmax(0,1fr)}.staff-workspace-shell .class-attendance-row{grid-template-columns:minmax(0,1fr)}.staff-workspace-shell .attendance-status-set{justify-content:flex-start!important}}
@media(min-width:761px) and (max-width:1100px){body:has(>.workspace-module-shell) .log-filters{grid-template-columns:repeat(auto-fit,minmax(180px,1fr))}body:has(>.workspace-module-shell) .learning-filters{grid-template-columns:repeat(auto-fit,minmax(160px,1fr))}}
.portal-design :where(label,fieldset){min-width:0}.portal-design .learning-panel :where(input,select,textarea){width:100%;min-width:0;box-sizing:border-box}

#staffClassAttendance .teacher-register-actions,#teacherRegister .teacher-register-actions{position:static;box-shadow:none}
#staffClassAttendance[data-scope-state=empty] .teacher-register-controls,#staffClassAttendance[data-scope-state=empty] .teacher-register-actions,#staffClassAttendance[data-scope-state=empty] #classAttendanceSummary,#teacherRegister[data-scope-state=empty] .teacher-register-controls,#teacherRegister[data-scope-state=empty] .teacher-register-actions{display:none}

.staff-workspace-shell .teacher-heading{padding:26px 30px;border-radius:20px;gap:20px}.staff-workspace-shell .teacher-heading h1{font-size:32px}.staff-workspace-shell>header .workspace-header-title{color:var(--kv-ink)}
@media(max-width:760px){.staff-workspace-shell .teacher-heading{padding:24px;flex-wrap:wrap}.staff-workspace-shell .teacher-heading h1{font-size:28px}}

.school-class-preview{background:#fff;border:1px solid var(--kv-line);border-radius:16px;padding:22px;margin:20px 0}.school-class-preview h3{margin:0 0 8px}.school-class-preview ul{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:10px;list-style:none;padding:0;margin:16px 0 0}.school-class-preview li{background:#f4eff9;border:1px solid var(--kv-line);border-radius:10px;padding:12px 14px;overflow-wrap:anywhere}.school-setup-actions{display:flex;flex-wrap:wrap;gap:12px;align-items:center;margin:18px 0}.school-setup-actions a{display:inline-flex;align-items:center;min-height:44px;padding:10px 16px;border-radius:10px;background:var(--kv-purple);color:#fff;text-decoration:none}.kps-school-catalogue .kps-metrics article{padding:20px;min-height:0}.kps-school-catalogue .kps-metrics article p{font-size:14px;line-height:1.6}

.school-setup-form{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;align-items:end;background:#fff;padding:22px;border-bottom:1px solid var(--kv-line)}.school-setup-form h3{grid-column:1/-1;margin:0 0 4px}.school-setup-form>label{display:grid!important;gap:8px;margin:0;font-size:14px}.school-setup-form :where(input,select){width:100%;margin:0;min-width:0}.school-setup-form>button{justify-self:start}.assignment-editor>fieldset{border:1px solid var(--kv-line);border-radius:12px;padding:18px}.assignment-editor>fieldset label{display:inline-flex!important;gap:10px;align-items:center;padding:10px 14px;margin:5px;border:1px solid var(--kv-line);border-radius:10px;background:#faf8fd}
@media(max-width:1000px){.school-setup-form{grid-template-columns:1fr}.school-class-preview ul{grid-template-columns:1fr}}
#management-setup>.management-module-link{display:inline-flex;align-items:center;min-height:44px;max-width:100%;box-sizing:border-box;padding:10px 14px;margin:6px 8px 6px 0;border:1px solid var(--kv-line);border-radius:10px;background:white;color:var(--kv-purple);text-decoration:none;overflow-wrap:anywhere;line-height:1.5}

/* Explicit common-grade homework choice; audience changes only on the teacher's action. */
.publishing-audience-choice{padding:18px;margin:18px 0;border:1px solid #ded1eb;border-radius:12px;background:#f5f0fa;color:var(--kv-ink)}.publishing-audience-choice strong{display:block;font-size:14px}.publishing-audience-choice p{font-size:13px;line-height:1.6;margin:6px 0 12px!important;white-space:normal}.publishing-audience-choice button{font-size:13px;margin:0;background:white;color:var(--kv-purple);border-color:#d4c5e3}

/* Hidden workflow controls stay hidden even when a component sets its display. */
.portal-design [hidden][hidden]{display:none!important}
body.kps-publishing main>header{display:block;grid-template-columns:none;background:linear-gradient(110deg,#372363,#574173);padding:28px 32px;border:0;border-radius:20px;margin-bottom:24px;color:#fff}
body.kps-publishing main>header h1{font-size:32px;color:#fff;line-height:1.2;overflow-wrap:normal;word-break:normal;margin:0 0 12px}
body.kps-publishing main>header p{color:#eee5f7;font-size:14px;max-width:720px;margin:0 0 16px}
body.kps-publishing main>header .kps-publishing-links{display:flex;flex-wrap:wrap;gap:16px;margin-top:16px}
body.kps-publishing main>header .kps-publishing-links a{color:#fff}
body.kps-publishing :where(input,select,textarea){font-weight:400}
@media(max-width:600px){body.kps-publishing main>header{padding:24px}body.kps-publishing main>header h1{font-size:28px}}
body.kps-publishing #message{position:static}

/* Shared visual foundation — development pass, 1 November 2026. */
:root{--kv-font-body:"KV Gujarati",system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;--kv-control-height:46px;--kv-radius-control:10px;--kv-radius-panel:16px;--kv-focus:#a68acb;--kv-success:#246444;--kv-success-surface:#eaf6ee;--kv-warning:#805b24;--kv-warning-surface:#fff5df;--kv-danger:#913e52;--kv-danger-surface:#fff2f5}
body.portal-design,#familyPortal{font-family:var(--kv-font-body);line-height:1.6}
.portal-design main :where(input:not([type=checkbox]):not([type=radio]):not([type=file]),select,textarea),#familyPortal :where(input:not([type=checkbox]):not([type=radio]):not([type=file]),select,textarea){box-sizing:border-box;min-width:0;max-width:100%;min-height:var(--kv-control-height);font-family:var(--kv-font-body);font-size:14px;font-weight:400;line-height:1.5;border:1px solid #cfc3df;border-radius:var(--kv-radius-control);background:#fff;color:var(--kv-ink);padding:10px 12px}
.portal-design main :where(button),#familyPortal button{box-sizing:border-box;appearance:none;min-height:44px;font-family:var(--kv-font-body);font-size:14px;font-weight:600;line-height:1.4;border:1px solid #d8cbe6;border-radius:var(--kv-radius-control);padding:11px 16px;cursor:pointer}
.portal-design main :where(button){background:#fff;color:var(--kv-purple)}
.portal-design main :where(button.primary,button[type=submit],a.teacher-primary){background:var(--kv-purple);border-color:var(--kv-purple);color:#fff}
.portal-design main :where(button.withdraw,button.review-reject){background:var(--kv-danger-surface);border-color:#e5c9d1;color:var(--kv-danger)}
.portal-design main button:disabled,#familyPortal button:disabled{cursor:default;opacity:.55}
.portal-design :where(button,a,input,select,textarea,summary):focus-visible,#familyPortal :where(button,a,input,select,textarea,summary):focus-visible{outline:3px solid var(--kv-focus);outline-offset:3px}
.portal-design main :where(input[type=checkbox],input[type=radio]),#familyPortal :where(input[type=checkbox],input[type=radio]){accent-color:var(--kv-purple);width:18px;height:18px;min-height:18px;padding:0;flex:none}
.portal-design label:has(>select),.portal-design label:has(>textarea){min-width:0;align-content:start}
@media(prefers-reduced-motion:reduce){.portal-design *,#familyPortal *{scroll-behavior:auto!important;animation-duration:.01ms!important;transition-duration:.01ms!important}}

/* Shared surfaces and focus treatment across desktop, mobile and kiosk. */
:root {
  --kv-heading-surface: linear-gradient(120deg, #fff 38%, #f1ebfa);
  --kv-panel-shadow: 0 8px 24px rgb(48 32 79 / 5%);
  --kv-surface-subtle: #f8f5fc;
}

.portal-design main :where(input,select,textarea),
#familyPortal :where(input,select,textarea) {
  accent-color: var(--kv-purple);
}

.portal-design main :where(button.primary,button[type=submit]):not(:disabled):hover {
  box-shadow: 0 3px 12px rgb(84 49 132 / 20%);
}

.portal-design :where(a,button,summary,input,select,textarea):focus-visible,
#familyPortal :where(a,button,summary,input,select,textarea):focus-visible {
  outline-color: #8964b5;
}

body.portal-design[data-portal-page=kiosk] #sharedKiosk > section {
  border: 1px solid var(--kv-line);
  border-radius: var(--kv-radius-panel);
  box-shadow: var(--kv-panel-shadow);
}

body.portal-design.management-shell .management-topbar,
body.workspace-dashboard > header,
#familyPortal .family-header {
  box-shadow: 0 4px 20px rgb(48 32 79 / 4%);
}

body.portal-design.management-shell .management-welcome,
body.workspace-dashboard .staff-dashboard-hero,
#familyPortal .family-hero {
  background: linear-gradient(120deg, var(--kv-deep) 12%, #533a78);
}

body.management-shell .kps-metric,
body.workspace-dashboard .staff-personal-metrics > article,
#familyPortal .family-card {
  box-shadow: var(--kv-panel-shadow);
}
