:root {
	--ink: #172f38;
	--muted: #647981;
	--green: #116b56;
	--line: #dde6e6;
	--paper: #f4f7f7;
}
* { box-sizing: border-box; }
body.school-workspace { margin: 0; background: var(--paper); color: var(--ink); font-family: 'Segoe UI', Arial, sans-serif; font-size: 14px; line-height: 1.6; }
a { color: var(--green); text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid #ca9b38; outline-offset: 4px; }
[hidden] { display: none !important; }
.skip-link { position: fixed; top: -100px; left: 20px; z-index: 100; padding: 12px; background: white; }
.skip-link:focus { top: 10px; }
.workspace-sidebar { width: 258px; position: fixed; inset: 0 auto 0 0; background: #fff; border-right: 1px solid var(--line); overflow-y: auto; padding: 28px 18px; z-index: 20; }
.workspace-brand { display: flex; gap: 12px; align-items: center; color: var(--ink); font-weight: 700; font-size: 16px; padding: 0 10px 25px; }
.workspace-brand small { display: block; font-size: 11px; color: var(--muted); font-weight: 500; letter-spacing: 1.5px; text-transform: uppercase; }
.brand-mark { display: grid; place-items: center; width: 38px; height: 42px; border-radius: 12px 12px 12px 3px; background: var(--green); color: white; font-size: 24px; }
.nav-label { margin: 22px 12px 8px; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 1.8px; color: #71868a; }
.workspace-link { display: flex; align-items: center; gap: 11px; padding: 10px 12px; margin: 3px 0; border-radius: 8px; color: #4b626b; font-size: 12px; font-weight: 600; }
.workspace-link:hover { background: #f2f6f5; }
.workspace-link.active { background: #e5f2ed; color: #0c624a; }
.nav-icon { font-size: 10px; letter-spacing: -.5px; width: 24px; height: 24px; display: grid; place-items: center; border: 1px solid #ccdcd6; border-radius: 6px; }
.signout { margin-top: 25px; border-top: 1px solid var(--line); padding-top: 18px; }
.workspace-main { margin-left: 258px; }
.workspace-topbar { height: 78px; background: #fff; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 40px; gap: 20px; }
.school-name { font-weight: 600; }
.account-pill { font-size: 11px; color: #526970; white-space: nowrap; display: flex; gap: 8px; align-items: center; }
.status-dot { background: #2a9674; width: 7px; height: 7px; border-radius: 50%; }
.workspace-content { max-width: 1500px; margin: 0 auto; padding: 35px 40px 55px; }
.page-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 26px; }
.eyebrow { color: var(--green); font-size: 10px; font-weight: 700; letter-spacing: 2px; margin: 0 0 6px; }
h1 { font-size: clamp(25px, 3vw, 34px); line-height: 1.25; margin: 0; font-weight: 650; letter-spacing: -.9px; }
h2 { margin: 0 0 8px; font-size: 19px; letter-spacing: -.3px; }
h3 { margin: 0; font-size: 15px; }
.today { font-size: 12px; color: var(--muted); }
.welcome-banner { background: #123f3b; color: white; padding: 32px 34px; border-radius: 15px; display: flex; justify-content: space-between; gap: 30px; align-items: center; position: relative; overflow: hidden; }
.welcome-banner .eyebrow { color: #acdbcc; }
.welcome-banner h2 { font-size: 27px; font-weight: 500; }
.welcome-banner p { color: #c0d7d2; margin: 10px 0 0; max-width: 510px; }
.welcome-banner .button { background: #e0bc6f; color: #163b36; white-space: nowrap; border-color: #e0bc6f; }
.term-pill { display: inline-block; margin-top: 18px; font-size: 11px; color: #d1e4df; border: 1px solid #47706a; border-radius: 20px; padding: 4px 12px; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 24px 0 32px; }
.stat-card { background: white; border: 1px solid var(--line); border-radius: 12px; padding: 21px 23px; }
.stat-card p { margin: 0; font-size: 12px; color: var(--muted); }
.stat-card strong { display: block; font-size: 31px; font-weight: 600; letter-spacing: -1px; margin: 7px 0 0; }
.stat-card small { font-size: 10px; color: var(--green); }
.section-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; gap: 20px; }
.section-heading p { color: var(--muted); margin: 0; font-size: 12px; }
.search-box { max-width: 310px; width: 100%; }
.search-box input { margin: 0; }
.tool-section { margin: 26px 0; }
.tool-section > h2 { font-size: 13px; color: #576e76; margin-bottom: 13px; }
.tool-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.tool-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 22px; color: var(--ink); display: flex; gap: 16px; align-items: flex-start; transition: border-color .15s, transform .15s; }
.tool-card:hover { border-color: #92b7a9; transform: translateY(-2px); }
.tool-icon { flex-shrink: 0; width: 38px; height: 40px; border-radius: 10px; background: #eaf3ee; display: grid; place-items: center; font-size: 11px; font-weight: 700; color: var(--green); }
.tool-section:nth-child(2n) .tool-icon { background: #f6f0e4; color: #89642a; }
.tool-card h3 { font-size: 13px; margin-bottom: 5px; }
.tool-card p { color: var(--muted); font-size: 11px; margin: 0; line-height: 1.7; }
.panel { padding: 26px; background: #fff; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 22px; }
.muted { color: var(--muted); }
.button, button.button { display: inline-flex; justify-content: center; align-items: center; gap: 8px; background: var(--green); color: white; border: 1px solid var(--green); padding: 10px 17px; border-radius: 7px; font-size: 12px; font-weight: 600; cursor: pointer; }
.button:hover { filter: brightness(.94); }
.button.secondary { background: white; color: var(--green); border-color: #c5d8cf; }
.button.danger { background: #fff4f1; color: #a03f34; border-color: #ebc8c0; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 24px; margin: 22px 0; }
label { display: block; font-size: 12px; font-weight: 600; color: #455c65; }
input:not([type=hidden]), select, textarea { display: block; width: 100%; border: 1px solid #cddbdd; border-radius: 7px; padding: 10px 12px; background: #fff; color: var(--ink); margin-top: 6px; min-height: 43px; }
input[type=file] { font-size: 12px; }
input[type=checkbox] { width: auto; display: inline-block; min-height: 0; }
.form-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 12px; }
th { text-align: left; font-size: 10px; letter-spacing: .7px; text-transform: uppercase; color: var(--muted); background: #f7f9f8; }
td, th { padding: 14px 16px; border-bottom: 1px solid #e5eceb; vertical-align: middle; }
td .button { padding: 6px 10px; font-size: 11px; }
.row-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.row-actions form { margin: 0; }
.badge { display: inline-block; padding: 3px 9px; background: #eaf3ee; color: #17634c; border-radius: 20px; font-size: 10px; }
.notice { padding: 14px 18px; border-radius: 8px; margin-bottom: 20px; }
.success { background: #e6f3e9; color: #205937; }
.error { background: #fff0eb; color: #90372b; }
.empty-state { text-align: center; padding: 35px 20px; color: var(--muted); }
.workspace-footer { padding: 20px 40px; border-top: 1px solid var(--line); font-size: 10px; color: var(--muted); display: flex; justify-content: space-between; }
.menu-toggle { display: none; }
.login-layout { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.login-story { padding: 12vw 8vw; color: white; background: #123f3b; display: flex; flex-direction: column; justify-content: center; }
.login-story h1 { font-size: clamp(32px, 4vw, 54px); letter-spacing: -1.8px; margin: 30px 0 20px; }
.login-story p { color: #b7d5ca; max-width: 360px; }
.login-form { display: grid; place-items: center; padding: 50px 24px; }
.login-form > div { width: 100%; max-width: 390px; }
.login-form label { margin: 20px 0; }
.login-form .button { width: 100%; }
.login-switch { text-align: center; font-size: 12px; margin-top: 24px; }
@media(max-width: 1150px){
	.tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.workspace-content { padding: 28px; }
	.stat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media(max-width: 800px){
	.workspace-sidebar { transform: translateX(-100%); visibility: hidden; top: 65px; width: 270px; box-shadow: 12px 8px 30px #16372b18; }
	.menu-open .workspace-sidebar { transform: translateX(0); visibility: visible; }
	.workspace-main { margin-left: 0; }
	.workspace-topbar { height: 65px; padding: 0 20px; position: sticky; top: 0; z-index: 30; }
	.menu-toggle { display: block; background: none; border: 0; color: var(--green); font-size: 19px; padding: 8px 0; }
	.menu-toggle span { font-size: 12px; }
	.account-pill { display: none; }
	.school-name { font-size: 12px; text-align: right; }
	.welcome-banner { padding: 25px; flex-direction: column; align-items: flex-start; }
	.page-heading { align-items: flex-start; }
	.today { display: none; }
	.login-layout { grid-template-columns: 1fr; }
	.login-story { padding: 35px; }
	.login-story h1 { margin: 15px 0 0; font-size: 30px; }
	.login-story p { display: none; }
}
@media(max-width: 520px){
	.workspace-content { padding: 24px 16px; }
	.tool-grid, .form-grid { grid-template-columns: 1fr; }
	.section-heading { flex-direction: column; align-items: flex-start; }
	.search-box { max-width: none; }
	.stat-card { padding: 16px; }
	.stat-grid { gap: 10px; }
	.welcome-banner h2 { font-size: 23px; }
	.panel { padding: 19px; }
	.workspace-footer { padding: 20px; }
}
@media print {
	.dashboard-whatsapp { display: none !important; }
	.workspace-sidebar, .workspace-topbar, .workspace-footer, .form-actions, .row-actions { display: none; }
	.workspace-main { margin: 0; }
	.workspace-content { padding: 0; }
}
@media (min-width: 1000px) { .stat-grid.teacher-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.dashboard-whatsapp { position: fixed; right: 24px; bottom: 24px; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); z-index: 90; display: flex; align-items: center; justify-content: center; width: 56px; height: 56px; border-radius: 50%; color: #fff; background: #128c48; box-shadow: 0 6px 20px rgba(0,0,0,.22); text-decoration: none; }
.dashboard-whatsapp svg { width: 30px; height: 30px; }
.dashboard-whatsapp:hover { background: #0e743b; color: #fff; }
.dashboard-whatsapp:focus-visible { outline: 3px solid #172e24; outline-offset: 4px; }
@media(max-width: 520px){ .dashboard-whatsapp { right: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); } }
