/* Scoped institutional workspace; leaves global WordPress admin and theme untouched. */
.hisasi-school-admin{max-width:1200px;margin-inline:12px 20px;direction:rtl;color:#243c42}
.hisasi-school-admin h1{display:flex;align-items:baseline;gap:10px;font-weight:750}
.hisasi-school-admin h1 span{font-size:16px;color:#71868c;font-weight:500}
.hisasi-s-grid,.hisasi-s-stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(175px,1fr));gap:12px;margin:18px 0}
.hisasi-s-tile,.hisasi-s-stats>div{background:#fff;border:1px solid #dce5e7;border-radius:12px;padding:18px;color:#173f46;text-decoration:none;display:grid;gap:9px;box-shadow:0 3px 12px #123c4b0b}
.hisasi-s-tile strong{font-size:17px}.hisasi-s-tile span,.hisasi-s-stats span{font-size:12px;color:#6a8188}.hisasi-s-stats strong{font-size:28px;color:#176c71}
.hisasi-s-breadcrumb{display:flex;gap:10px;align-items:center;margin:15px 0}.hisasi-s-breadcrumb a{color:#176a75}
.hisasi-s-tabs{display:flex;gap:7px;overflow-x:auto;border-bottom:1px solid #cddadd;padding:7px 0 12px;scrollbar-width:thin}
.hisasi-s-tabs a{color:#526d76;white-space:nowrap;text-decoration:none;padding:9px 13px;border-radius:9px;background:#f3f7f7;border:1px solid #e1e9e9;font-weight:600}
.hisasi-s-tabs a[aria-current=page]{color:#fff;background:#176c71;border-color:#176c71}
.hisasi-s-panel{padding:18px;background:white;border:1px solid #dce5e7;border-radius:14px;margin:16px 0;box-shadow:0 4px 18px #0d454b0a}
.hisasi-s-panel h2{font-size:17px;margin:0 0 16px;border-bottom:1px solid #edf1f2;padding-bottom:12px}
.hisasi-s-panel h2 small{font-weight:400;color:#8aa0a2}
.hisasi-s-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:13px 17px;align-items:end}
.hisasi-s-form label{display:grid;gap:7px;font-weight:650;min-width:0}
.hisasi-s-form input,.hisasi-s-form select{width:100%;max-width:100%;min-height:40px;padding:6px 10px;border:1px solid #ccdadd;border-radius:8px}
.hisasi-s-form button{width:fit-content;min-height:39px}
.hisasi-s-inline{display:inline-block;margin:0 4px}.hisasi-s-scroll{max-width:100%;overflow-x:auto}
.hisasi-s-scroll table{min-width:530px}.hisasi-s-scroll th,.hisasi-s-scroll td{text-align:right;vertical-align:middle;padding:10px}
.hisasi-school-public .hisasi-s-schoolnav{display:flex;gap:7px;overflow-x:auto;margin:15px 6px}
.hisasi-school-public .hisasi-s-schoolnav a{white-space:nowrap;display:block;border-radius:9px;padding:9px 13px;background:#f0f6f7;border:1px solid #e0e9eb;color:#26646a;text-decoration:none;font-weight:650}
.hisasi-school-public .hisasi-s-schoolnav a[aria-current=page]{background:#166d72;border-color:#166d72;color:#fff}
.hisasi-s-public-head{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin:12px 6px}
.hisasi-s-public-head p{font-size:12px;margin:0}.hisasi-s-day>h3{margin:0 0 13px;font-size:17px;font-weight:750}.hisasi-s-day-lessons{display:grid;gap:8px}
@media(max-width:640px){.hisasi-school-admin{margin-inline:2px 10px}.hisasi-s-panel{padding:13px}.hisasi-s-form{grid-template-columns:1fr}.hisasi-s-grid,.hisasi-s-stats{gap:7px}.hisasi-s-tabs a{padding:8px 10px;font-size:12px}}
@media print{.hisasi-school-public .hisasi-s-schoolnav,.hisasi-s-public-head button{display:none!important}.hisasi-school-public .hisasi-panel{display:block!important;border:0;box-shadow:none;break-inside:avoid}.hisasi-school-public .hisasi-hero{background:none!important;color:#111}}
@media print{.hisasi-school-public .hisasi-panel:not(:first-of-type){display:block!important;visibility:visible!important}}

/* v1.3: real front-end management, deliberately scoped away from the theme. */
.hisasi-school-workspace{--hs-ink:#193a43;--hs-brand:#176c72;--hs-line:#dbe8e9;--hs-soft:#f2f8f8;direction:rtl;max-width:1260px;margin:0 auto;padding:10px 8px 30px;color:var(--hs-ink);font-family:inherit;line-height:1.65}
.hisasi-school-workspace *{box-sizing:border-box}
.hisasi-school-workspace .hisasi-school-admin{max-width:none;margin:0;padding:0;font-size:14px;color:var(--hs-ink)}
.hisasi-school-workspace .hisasi-school-admin h1{margin:0;padding:24px 25px;border-radius:18px;color:white;background:linear-gradient(120deg,#134b59,#167d81);font-size:clamp(21px,3vw,31px);box-shadow:0 8px 26px #0d435326;display:flex;flex-wrap:wrap;align-items:center}
.hisasi-school-workspace .hisasi-school-admin h1 span{color:#d7eeed;font-size:14px}
.hisasi-school-workspace .description{color:#617b81;font-size:13px;margin:12px 0}
.hisasi-school-workspace .hisasi-s-front-actions{display:flex;gap:8px;flex-wrap:wrap;margin:12px 0}
.hisasi-school-workspace .hisasi-s-quicklink{padding:8px 12px;border-radius:9px;border:1px solid var(--hs-line);color:var(--hs-brand);text-decoration:none;font-weight:600;background:white}
.hisasi-school-workspace .hisasi-s-panel{box-shadow:0 8px 30px #173e4410;margin:14px 0}
.hisasi-school-workspace .hisasi-s-panel h2{color:var(--hs-ink);font-weight:750}
.hisasi-school-workspace .hisasi-s-tabs{gap:8px;padding:6px 0 11px}
.hisasi-school-workspace .hisasi-s-tabs a{font-size:13px;background:#f6f9f9;color:#27515a;border-radius:10px;transition:background .15s}
.hisasi-school-workspace .hisasi-s-tabs a:focus-visible,.hisasi-school-workspace button:focus-visible,.hisasi-school-workspace input:focus-visible,.hisasi-school-workspace select:focus-visible{outline:3px solid #80d8d0;outline-offset:2px}
.hisasi-school-workspace .hisasi-s-tabs a[aria-current="page"]{background:var(--hs-brand);color:#fff}
.hisasi-school-workspace .hisasi-s-tile{transition:transform .15s,border-color .15s}
.hisasi-school-workspace .hisasi-s-tile:hover{transform:translateY(-2px);border-color:#78bbb6}
.hisasi-school-workspace .notice{padding:12px 16px;border-radius:10px;margin:10px 0;background:#f2f9fb;border-right:4px solid #43818c;box-shadow:0 2px 12px #173e440a}
.hisasi-school-workspace .notice p{margin:0}.hisasi-school-workspace .notice-error{border-color:#b14242;background:#fff3f3}.hisasi-school-workspace .notice-success{border-color:#21845a;background:#effaf4}
.hisasi-school-workspace .hisasi-s-scroll{border:1px solid #e3eeee;border-radius:10px}
.hisasi-school-workspace table{width:100%;border-collapse:collapse;border-spacing:0;color:var(--hs-ink);margin:0;background:#fff}
.hisasi-school-workspace table thead{background:#f1f7f7}.hisasi-school-workspace th,.hisasi-school-workspace td{padding:11px 12px;text-align:right;border-bottom:1px solid #e8eeee;font-size:13px;vertical-align:middle}
.hisasi-school-workspace .button,.hisasi-school-workspace .hisasi-s-primary{background:#f5fafa;color:#176b71;border:1px solid #b7d7d8;border-radius:8px;padding:8px 12px;display:inline-block;text-decoration:none;font-weight:650;cursor:pointer;font:inherit;font-size:13px;line-height:1.5}
.hisasi-school-workspace .button-primary,.hisasi-school-workspace .hisasi-s-primary{background:var(--hs-brand);color:white;border-color:var(--hs-brand)}
.hisasi-school-workspace .button:hover,.hisasi-school-workspace .hisasi-s-primary:hover{filter:brightness(.94)}
.hisasi-school-workspace .hisasi-s-form input,.hisasi-school-workspace .hisasi-s-form select{font:inherit;background:#fff;color:#1d4147}
.hisasi-school-workspace .hisasi-s-panel code{direction:ltr;display:inline-block;background:#edf5f6;border-radius:4px;padding:0 5px;font-size:12px}
.hisasi-school-workspace .hisasi-s-plan-form{display:contents}
.hisasi-school-workspace .hisasi-s-days{display:flex;flex-wrap:wrap;gap:9px;margin-top:17px;border:1px solid #dce8e9;border-radius:9px;padding:13px}
.hisasi-school-workspace .hisasi-s-days legend{padding:0 7px;font-weight:700}
.hisasi-school-workspace .hisasi-s-days label{display:flex;gap:5px;align-items:center;background:#f1f7f7;border-radius:8px;padding:6px 10px;white-space:nowrap}
.hisasi-school-workspace .hisasi-s-subject-table{min-width:570px}
.hisasi-school-workspace .hisasi-s-subject-table input,.hisasi-school-workspace .hisasi-s-subject-table select{width:100%;min-width:90px;max-width:260px;min-height:37px;border:1px solid #cbdfe0;border-radius:7px;padding:5px 8px;background:white;color:#20414a;font:inherit}
.hisasi-school-workspace .hisasi-s-subject-table input[type=number]{min-width:65px;max-width:82px}
.hisasi-school-workspace .hisasi-s-plan-form .hisasi-s-primary{margin-top:15px;padding:10px 19px}
.hisasi-school-workspace .hisasi-s-warning{background:#fff4e4;border-right:4px solid #d59a23;padding:12px;border-radius:8px;margin:10px 0}
.hisasi-s-public-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.hisasi-s-public-actions .hisasi-btn--primary{background:#176c72;color:white;text-decoration:none;padding:10px 14px;border-radius:9px}
@media(max-width:680px){.hisasi-school-workspace{padding:7px 8px}.hisasi-school-workspace .hisasi-school-admin h1{padding:18px 16px}.hisasi-school-workspace .hisasi-s-panel{padding:13px}.hisasi-school-workspace .hisasi-s-form{grid-template-columns:1fr}.hisasi-school-workspace .hisasi-s-tabs{scroll-snap-type:x proximity}.hisasi-school-workspace .hisasi-s-tabs a{scroll-snap-align:start}}
@media print{.hisasi-school-workspace .hisasi-s-front-actions,.hisasi-school-workspace .hisasi-s-tabs,.hisasi-school-workspace form{display:none!important}.hisasi-school-workspace .hisasi-s-panel{box-shadow:none;border:1px solid #ddd}}

/* v1.4: scoped image-import workspace, compact mobile review. */
.hisasi-school-workspace .hisasi-vision-steps{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px;margin:15px 0}
.hisasi-school-workspace .hisasi-vision-steps span{text-align:center;padding:11px 5px;background:#eff7f7;border:1px solid #d4e9e7;border-radius:10px;font-weight:650;font-size:12px}
.hisasi-school-workspace .hisasi-vision-hint{font-size:12px;color:#607e86;line-height:1.8}
.hisasi-school-workspace .hisasi-vision-details{background:#f5f9f9;border-radius:10px;padding:13px;margin:14px 0}
.hisasi-school-workspace .hisasi-vision-details summary{cursor:pointer;font-weight:700}
.hisasi-school-workspace .hisasi-vision-form{display:block;max-width:100%}
.hisasi-school-workspace .hisasi-vision-form .hisasi-s-form{margin:12px 0}
.hisasi-school-workspace .hisasi-vision-table{min-width:920px}
.hisasi-school-workspace .hisasi-vision-table input[type=time]{min-width:108px}
.hisasi-school-workspace .hisasi-vision-table td small{display:block;font-size:11px;color:#64878c;margin-top:5px}
.hisasi-school-workspace .hisasi-vision-error td{background:#fff8ec}
.hisasi-school-workspace .hisasi-vision-error-detail td{background:#fff2e6;color:#9b4c19;font-size:12px}
.hisasi-school-workspace .hisasi-vision-actions,.hisasi-school-workspace .hisasi-vision-confirm{margin-top:15px}
.hisasi-school-workspace .hisasi-vision-confirm{border-right:4px solid #168666;background:#f0faf6;border-radius:9px;padding:14px}
.hisasi-school-workspace .hisasi-vision-form>button:disabled{opacity:.5;cursor:not-allowed}
@media(max-width:540px){.hisasi-school-workspace .hisasi-vision-steps span{padding:9px 2px;font-size:10px}.hisasi-school-workspace .hisasi-vision-table{min-width:920px}}

.hisasi-school-workspace .hisasi-vision-remove{display:block;font-size:11px;white-space:nowrap;color:#a13c27;margin-top:8px}.hisasi-school-workspace .hisasi-vision-actions{display:flex;gap:8px;flex-wrap:wrap}

/* v1.5 – only inside Hisasi's scoped school interface. */
.hisasi-school-workspace .hisasi-ai-header{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;flex-wrap:wrap}
.hisasi-school-workspace .hisasi-ai-header h2{margin:0 0 4px}
.hisasi-school-workspace .hisasi-ai-header p{margin:0 0 8px;color:#597980;font-size:13px}
.hisasi-school-workspace .hisasi-ai-status,.hisasi-school-workspace .hisasi-ai-duplicate{background:#e8f7f2;color:#126d58;border:1px solid #b9e2d3;border-radius:9px;padding:8px 12px;font-size:12px;font-weight:700}
.hisasi-school-workspace .hisasi-ai-duplicate{margin:12px 0;font-weight:500}
.hisasi-school-workspace .hisasi-ai-inline{display:flex;align-items:center;gap:8px;margin:10px 0}
.hisasi-school-workspace .hisasi-ai-dirty{background:#fff1e0;color:#974f11;border-radius:9px;padding:10px;margin-top:10px}
.hisasi-school-workspace .hisasi-vision-duplicate td{background:#f0faf6}
.hisasi-school-workspace .hisasi-image-tools{background:#f7fafb;border:1px solid #dce9ed;border-radius:12px;padding:12px;margin:12px 0}
.hisasi-school-workspace .hisasi-image-preview{max-width:100%;margin:auto;text-align:center}
.hisasi-school-workspace [data-hisasi-canvas]{max-width:100%;max-height:440px;height:auto;width:auto;border-radius:8px;touch-action:none;cursor:crosshair;background:#fff}
.hisasi-school-workspace [hidden]{display:none!important}
.hisasi-school-workspace .hisasi-vision-table tr td input,.hisasi-school-workspace .hisasi-vision-table tr td select{width:100%;max-width:none}
@media(max-width:650px){
 .hisasi-school-workspace .hisasi-vision-table{min-width:0!important;width:100%;border:0}
 .hisasi-school-workspace .hisasi-vision-table thead{display:none}
 .hisasi-school-workspace .hisasi-vision-table tbody,.hisasi-school-workspace .hisasi-vision-table tr{display:block}
 .hisasi-school-workspace .hisasi-vision-table tbody>tr:not(.hisasi-vision-error-detail){display:grid;grid-template-columns:1fr 1fr;gap:7px;background:#fff;border:1px solid #dce7e9;border-radius:12px;padding:10px;margin:10px 0}
 .hisasi-school-workspace .hisasi-vision-table tbody>tr:not(.hisasi-vision-error-detail)>td{display:flex;flex-direction:column;min-width:0;padding:3px!important;border:0!important;background:transparent}
 .hisasi-school-workspace .hisasi-vision-table tbody>tr:not(.hisasi-vision-error-detail)>td:before{font-size:11px;font-weight:650;color:#648289;margin-bottom:3px}
 .hisasi-school-workspace .hisasi-vision-table tr>td:nth-child(1):before{content:'الصف/تجاهل'}
 .hisasi-school-workspace .hisasi-vision-table tr>td:nth-child(2):before{content:'اليوم'}
 .hisasi-school-workspace .hisasi-vision-table tr>td:nth-child(3):before{content:'رقم الحصة'}
 .hisasi-school-workspace .hisasi-vision-table tr>td:nth-child(4):before{content:'المادة'}
 .hisasi-school-workspace .hisasi-vision-table tr>td:nth-child(5):before{content:'بداية الحصة'}
 .hisasi-school-workspace .hisasi-vision-table tr>td:nth-child(6):before{content:'نهاية الحصة'}
 .hisasi-school-workspace .hisasi-vision-table tr>td:nth-child(7):before{content:'المعلم'}
 .hisasi-school-workspace .hisasi-vision-table tr>td:nth-child(8):before{content:'القاعة'}
 .hisasi-school-workspace .hisasi-vision-table tr.hisasi-vision-error-detail{width:100%;margin:-4px 0 8px}
 .hisasi-school-workspace .hisasi-vision-table tr.hisasi-vision-error-detail td{display:block}
}

/* v1.5.1: keep application usable within narrow mobile theme containers. */
.hisasi-school-workspace .hisasi-s-tabs{max-width:100%;overscroll-behavior-inline:contain;scrollbar-width:thin;scroll-padding-inline:10px;}
.hisasi-school-workspace .hisasi-s-tabs a{flex:0 0 auto;}
.hisasi-school-workspace .hisasi-storage-panel{border:1px solid #f0c79c;background:#fffaf3;}
.hisasi-school-workspace .hisasi-storage-panel h2{font-size:19px;}
.hisasi-school-workspace .hisasi-storage-engines{display:flex;gap:8px;flex-wrap:wrap;margin:10px 0;}
.hisasi-school-workspace .hisasi-storage-engines span{background:#fff;border:1px solid #eed7bd;border-radius:9px;padding:8px 11px;font-size:12px;}
.hisasi-school-workspace .hisasi-storage-repair-form{display:flex;gap:12px;align-items:center;flex-wrap:wrap;}
.hisasi-school-workspace .hisasi-storage-repair-form label{display:flex;gap:8px;align-items:center;font-size:13px;}
.hisasi-school-workspace .hisasi-s-diagnostic{font-size:13px;line-height:1.8;margin-top:8px;font-weight:650;}
@media(max-width:680px){
 .hisasi-school-workspace{padding:8px!important;max-width:100%;overflow-x:clip;}
 .hisasi-school-workspace .hisasi-school-admin h1{padding:15px 14px;font-size:23px;}
 .hisasi-school-workspace .hisasi-s-tabs{scrollbar-width:auto;}
 .hisasi-school-workspace .hisasi-s-tabs a{min-height:43px;display:inline-flex;align-items:center;}
 .hisasi-school-workspace .hisasi-s-form input,.hisasi-school-workspace .hisasi-s-form select{min-width:0;max-width:100%;}
 .hisasi-school-workspace .hisasi-vision-steps{grid-template-columns:repeat(2,minmax(0,1fr));}
}

/* v1.6.0 – front-end visual system. Every rule is scoped to Hisasi. */
.hisasi-school-workspace[data-hisasi-workspace]{
 --hs-ink:#19323b;--hs-brand:#126b78;--hs-line:#dfe9ed;--hs-soft:#f5f9fa;
 /* RTL full-width centering: avoid left:50% translating an already right-anchored box. */
 width:min(1460px,calc(100vw - 24px));max-width:calc(100vw - 24px);box-sizing:border-box;position:relative;
 left:auto;right:50%;transform:translateX(50%);margin:0;padding:12px 8px 40px;
 font-family:inherit;font-size:14px;min-width:0;isolation:isolate;
}
.hisasi-school-workspace[data-hisasi-workspace] .hisasi-school-admin{width:100%;max-width:100%;margin:0;}
.hisasi-school-workspace .hisasi-s-header{background:linear-gradient(120deg,#104858 0%,#126978 65%,#1d8990 100%);border-radius:19px;box-shadow:0 12px 35px #173f5421;padding:18px 24px;color:#fff;position:relative;overflow:hidden}
.hisasi-school-workspace .hisasi-s-header:after{content:'';position:absolute;border:1px solid #ffffff27;width:210px;height:210px;border-radius:50%;left:-65px;top:-130px;pointer-events:none}
.hisasi-school-workspace .hisasi-school-admin .hisasi-s-header h1{background:none;padding:0;margin:0;color:white;box-shadow:none;border:0;border-radius:0;font-size:clamp(24px,3vw,32px);gap:12px;}
.hisasi-school-workspace .hisasi-s-header h1 span{color:#c7e9e8;font-size:13px}
.hisasi-school-workspace .hisasi-s-header .description{color:#e0f3f1;margin:5px 0 0;font-size:13px}
.hisasi-school-workspace .hisasi-s-front-actions{margin:14px 0 8px}
.hisasi-school-workspace .hisasi-s-quicklink{background:#fff;border:1px solid #d9e8eb;box-shadow:0 2px 8px #14455809;min-height:40px;display:inline-flex;align-items:center;padding:8px 15px;color:#176575}
.hisasi-school-workspace .hisasi-s-tabs{display:flex;flex-wrap:nowrap;gap:8px;padding:6px 1px 12px;margin:8px 0 10px;border-bottom:1px solid #dfebed;overflow-x:auto;overflow-y:hidden;scrollbar-width:thin;-webkit-overflow-scrolling:touch;max-width:100%;scroll-snap-type:x proximity}
.hisasi-school-workspace .hisasi-s-tabs a{scroll-snap-align:start;flex-shrink:0;padding:11px 16px;min-height:44px;border:1px solid #e0ebec;border-radius:12px;background:#fff;color:#41636d;font-weight:700;text-decoration:none;font-size:13px;box-shadow:0 2px 10px #123e4a06}
.hisasi-school-workspace .hisasi-s-tabs a[aria-current="page"]{background:#126b78;color:#fff;border-color:#126b78;box-shadow:0 5px 16px #126b782b}
.hisasi-school-workspace .hisasi-s-tabs a:hover{background:#e9f6f5;color:#125561}
.hisasi-school-workspace .hisasi-s-tabs a[aria-current="page"]:hover{background:#126b78;color:#fff}
.hisasi-school-workspace .hisasi-s-panel{border:1px solid var(--hs-line);border-radius:17px;box-shadow:0 7px 26px #1844520a;padding:clamp(13px,2vw,23px);margin:14px 0;background:#fff;min-width:0}
.hisasi-school-workspace .hisasi-s-panel h2{font-size:clamp(17px,2vw,20px);line-height:1.5}
.hisasi-school-workspace .hisasi-s-panel .hisasi-s-scroll{max-width:100%;overflow:auto;overscroll-behavior-inline:contain}
.hisasi-school-workspace .hisasi-s-form input,.hisasi-school-workspace .hisasi-s-form select{min-height:45px;border-radius:11px;border:1px solid #cddfe3;background:#fff;min-width:0}
.hisasi-school-workspace .button,.hisasi-school-workspace .hisasi-s-primary{min-height:39px;display:inline-flex;align-items:center;justify-content:center;border-radius:10px;transition:box-shadow .15s,transform .15s}
.hisasi-school-workspace .button:active,.hisasi-school-workspace .hisasi-s-primary:active{transform:translateY(1px)}
.hisasi-school-workspace .hisasi-s-is-loading{position:relative}
.hisasi-school-workspace.hisasi-s-is-loading:before{content:'';position:absolute;z-index:8;inset:0;background:#f8fcfd77;pointer-events:all;border-radius:16px}
.hisasi-school-workspace.hisasi-s-is-loading:after{content:'';position:fixed;z-index:9;left:50%;top:50%;width:40px;height:40px;border-radius:50%;border:4px solid #d5e7e9;border-top-color:#126b78;animation:hs-spin .7s linear infinite;pointer-events:none}
@keyframes hs-spin{to{transform:rotate(360deg)}}
.hisasi-s-live:not([hidden]){position:fixed;bottom:25px;left:50%;transform:translateX(-50%);z-index:99999;background:#174e5b;color:white;border-radius:16px;padding:13px 22px;box-shadow:0 12px 30px #12445444;font-weight:600;font-size:14px;line-height:1.6;font-family:inherit;text-align:center;max-width:calc(100vw - 24px)}
.hisasi-school-workspace .hisasi-s-client-message{border-radius:12px;margin:10px 0;padding:14px;background:#ecf6fc;border-right:4px solid #12748a;color:#174554}
.hisasi-school-workspace .hisasi-s-client-message[data-level="error"]{background:#fff1ed;border-color:#b34c37;color:#833628}
.hisasi-school-workspace .hisasi-s-schedule{background:linear-gradient(175deg,#f7fcfc 0%,white 40%)}
.hisasi-school-workspace .hisasi-s-schedule-head{display:flex;gap:16px;align-items:center;justify-content:space-between;flex-wrap:wrap;padding-bottom:12px}
.hisasi-school-workspace .hisasi-s-schedule-head h2{border:0;padding:0;margin:0 0 4px}
.hisasi-school-workspace .hisasi-s-eyebrow{color:#108090;font-weight:800;letter-spacing:.2px;font-size:12px;margin:0 0 4px}
.hisasi-school-workspace .hisasi-s-muted{color:#607e85;margin:0;font-size:13px}
.hisasi-school-workspace .hisasi-s-view-switch{display:flex;gap:3px;background:#eaf2f4;padding:4px;border-radius:13px}
.hisasi-school-workspace .hisasi-s-view-btn{border:0;background:transparent;color:#46636e;padding:9px 16px;border-radius:10px;cursor:pointer;font-weight:700;font-size:13px;font-family:inherit;min-height:39px}
.hisasi-school-workspace .hisasi-s-view-btn[aria-pressed="true"]{background:#fff;color:#176b78;box-shadow:0 2px 7px #123c4e20}
.hisasi-school-workspace .hisasi-s-day-filter{display:flex;gap:8px;overflow-x:auto;overscroll-behavior-inline:contain;padding:7px 0 13px;margin:4px 0 12px;scrollbar-width:thin}
.hisasi-school-workspace .hisasi-s-day-filter button{border:1px solid #d9e8ed;border-radius:100px;padding:8px 13px;background:#fff;color:#527078;white-space:nowrap;min-height:41px;cursor:pointer;font:600 13px inherit}
.hisasi-school-workspace .hisasi-s-day-filter button span{background:#edf4f5;color:#386672;border-radius:100px;margin-inline-start:5px;padding:1px 6px;font-size:11px}
.hisasi-school-workspace .hisasi-s-day-filter button[aria-pressed="true"]{background:#126b78;border-color:#126b78;color:#fff}
.hisasi-school-workspace .hisasi-s-day-filter button[aria-pressed="true"] span{background:#ffffff25;color:#fff}
.hisasi-school-workspace .hisasi-s-day-boards{display:grid;gap:19px}
.hisasi-school-workspace .hisasi-s-day-board[hidden]{display:none!important}
.hisasi-school-workspace .hisasi-s-day-board h3{display:flex;align-items:center;gap:9px;color:#26414a;font-size:17px;margin:5px 0 13px;font-weight:800}
.hisasi-school-workspace .hisasi-s-day-board h3 small{font-size:11px;border-radius:20px;color:#6b8991;background:#eef4f6;padding:3px 8px;font-weight:600}
.hisasi-school-workspace .hisasi-s-day-dot{width:9px;height:9px;background:#17828c;display:inline-block;border-radius:50%}
.hisasi-school-workspace .hisasi-s-lesson-cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,245px),1fr));gap:12px}
.hisasi-school-workspace .hisasi-s-lesson-card{--lesson-accent:#1f7890;--lesson-tint:#e9f6fa;background:white;border:1px solid #e0eaee;border-right:5px solid var(--lesson-accent);border-radius:15px;padding:15px;min-width:0;box-shadow:0 3px 14px #153c4909;display:flex;flex-direction:column;gap:11px;transition:box-shadow .17s,transform .17s}
.hisasi-school-workspace .hisasi-s-lesson-card:hover{transform:translateY(-2px);box-shadow:0 8px 24px #143c5017}
.hisasi-school-workspace .hisasi-s-color-0{--lesson-accent:#197b8d;--lesson-tint:#e7f5f8}
.hisasi-school-workspace .hisasi-s-color-1{--lesson-accent:#6b62b2;--lesson-tint:#f0edfd}
.hisasi-school-workspace .hisasi-s-color-2{--lesson-accent:#288767;--lesson-tint:#eaf7ef}
.hisasi-school-workspace .hisasi-s-color-3{--lesson-accent:#c27b37;--lesson-tint:#fff3e4}
.hisasi-school-workspace .hisasi-s-color-4{--lesson-accent:#ba5272;--lesson-tint:#fdeef3}
.hisasi-school-workspace .hisasi-s-color-5{--lesson-accent:#4a78b0;--lesson-tint:#eaf2fb}
.hisasi-school-workspace .hisasi-s-card-top{display:flex;gap:6px;align-items:center;justify-content:space-between;flex-wrap:wrap}
.hisasi-school-workspace .hisasi-s-time{border-radius:8px;background:var(--lesson-tint);color:var(--lesson-accent);padding:5px 9px;font-size:12px;font-weight:750;direction:ltr;unicode-bidi:isolate}
.hisasi-school-workspace .hisasi-s-class-name{background:#f4f7f8;color:#54727a;border-radius:8px;font-size:11px;padding:5px 8px;max-width:100%;overflow-wrap:anywhere}
.hisasi-school-workspace .hisasi-s-subject{font-size:19px;line-height:1.5;color:#253e47;overflow-wrap:anywhere}
.hisasi-school-workspace .hisasi-s-card-meta{display:flex;flex-wrap:wrap;gap:7px 12px;font-size:12px;color:#6b828a;margin-top:auto}
.hisasi-school-workspace .hisasi-s-card-actions{display:flex;align-items:center;gap:7px;flex-wrap:wrap;border-top:1px solid #e9eff0;padding-top:10px}
.hisasi-school-workspace .hisasi-s-card-actions .hisasi-s-inline{margin:0}
.hisasi-school-workspace .hisasi-s-card-actions .button{font-size:12px;padding:5px 10px;min-height:34px}
.hisasi-school-workspace [data-view="cards"] .hisasi-s-table-view{display:none}
.hisasi-school-workspace [data-view="table"] .hisasi-s-day-boards{display:none}
.hisasi-school-workspace [data-hisasi-day-row][hidden]{display:none!important}
.hisasi-school-workspace .hisasi-s-table-view table{min-width:680px}
.hisasi-school-workspace .hisasi-s-table-view th{font-weight:750;background:#eef7f8;color:#345e65}
.hisasi-school-workspace .hisasi-s-table-view td{padding:12px 10px;line-height:1.7}
.hisasi-school-workspace .hisasi-s-table-view tr:nth-child(even) td{background:#f8fbfb}
.hisasi-school-workspace .hisasi-s-empty-state{text-align:center;padding:45px 15px;color:#648087;display:grid;justify-items:center;gap:7px}
.hisasi-school-workspace .hisasi-s-empty-state>span{font-size:39px;color:#1b8790}
.hisasi-school-workspace .hisasi-s-empty-state strong{font-size:18px;color:#1d4a54}
.hisasi-school-workspace .hisasi-s-editor{scroll-margin-top:24px}
.hisasi-school-workspace button:focus-visible,.hisasi-school-workspace a:focus-visible{outline:3px solid #55b8c1;outline-offset:3px}
@media(max-width:680px){
 .hisasi-school-workspace[data-hisasi-workspace]{width:calc(100vw - 16px);max-width:calc(100vw - 16px);box-sizing:border-box;padding:8px 8px 28px}
 .hisasi-school-workspace .hisasi-s-header{padding:16px 15px;border-radius:15px}
 .hisasi-school-workspace .hisasi-school-admin .hisasi-s-header h1{font-size:24px}
 .hisasi-school-workspace .hisasi-s-header .description{font-size:12px;line-height:1.6}
 .hisasi-school-workspace .hisasi-s-panel{padding:13px 11px;border-radius:13px}
 .hisasi-school-workspace .hisasi-s-schedule-head{align-items:flex-start}
 .hisasi-school-workspace .hisasi-s-view-switch{width:100%;justify-content:stretch}
 .hisasi-school-workspace .hisasi-s-view-btn{flex:1}
 .hisasi-school-workspace .hisasi-s-lesson-cards{grid-template-columns:1fr}
 .hisasi-school-workspace .hisasi-s-lesson-card{padding:14px}
 .hisasi-school-workspace .hisasi-s-tabs{margin:7px 0 8px;gap:6px}
 .hisasi-school-workspace .hisasi-s-tabs a{min-height:43px;font-size:12px;padding:9px 12px}
 .hisasi-school-workspace .hisasi-s-stats{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(prefers-reduced-motion:reduce){.hisasi-school-workspace .hisasi-s-lesson-card,.hisasi-school-workspace .button{transition:none!important}.hisasi-school-workspace.hisasi-s-is-loading:after{animation:none}}
@media print{
 .hisasi-school-workspace .hisasi-s-view-switch,.hisasi-school-workspace .hisasi-s-day-filter,.hisasi-school-workspace .hisasi-s-card-actions{display:none!important}
 .hisasi-school-workspace .hisasi-s-day-boards,.hisasi-school-workspace .hisasi-s-day-board[hidden]{display:grid!important}
 .hisasi-school-workspace .hisasi-s-lesson-card{break-inside:avoid;box-shadow:none}
 .hisasi-school-workspace .hisasi-s-table-view{display:none!important}
}
/* Accessible compact row layout for management tables on mobile. */
@media(max-width:650px){
 .hisasi-school-workspace .hisasi-s-responsive-table{display:block!important;min-width:0!important;width:100%;border:0;background:transparent}
 .hisasi-school-workspace .hisasi-s-responsive-table thead{display:none}
 .hisasi-school-workspace .hisasi-s-responsive-table tbody{display:grid;gap:9px}
 .hisasi-school-workspace .hisasi-s-responsive-table tbody tr{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px 12px;background:#fff;border:1px solid #e0e9ee;border-radius:12px;padding:11px;min-width:0}
 .hisasi-school-workspace .hisasi-s-responsive-table tbody td{display:flex;flex-direction:column;gap:3px;border:0!important;padding:2px!important;min-width:0!important;overflow-wrap:anywhere;font-size:13px;word-break:break-word}
 .hisasi-school-workspace .hisasi-s-responsive-table tbody td:before{font-size:11px;font-weight:750;color:#62838a;line-height:1.5}
 .hisasi-school-workspace .hisasi-s-responsive-table tbody td:last-child{grid-column:1 / -1;flex-direction:row;flex-wrap:wrap;align-items:center;gap:8px;padding-top:8px!important;border-top:1px solid #edf1f2!important}
 .hisasi-school-workspace .hisasi-s-responsive-table tbody td:last-child:before{content:'إجراءات';flex-basis:100%}
 .hisasi-school-workspace [data-hisasi-table="members"] td:nth-child(1):before{content:'المستخدم'}
 .hisasi-school-workspace [data-hisasi-table="members"] td:nth-child(2):before{content:'البريد'}
 .hisasi-school-workspace [data-hisasi-table="members"] td:nth-child(3):before{content:'الدور'}
 .hisasi-school-workspace [data-hisasi-table="classes"] td:nth-child(1):before{content:'الفصل'}
 .hisasi-school-workspace [data-hisasi-table="classes"] td:nth-child(2):before{content:'المرحلة / الصف'}
 .hisasi-school-workspace [data-hisasi-table="enrollments"] td:nth-child(1):before{content:'الطالب'}
 .hisasi-school-workspace [data-hisasi-table="enrollments"] td:nth-child(2):before{content:'الفصل'}
 .hisasi-school-workspace [data-hisasi-table="family"] td:nth-child(1):before{content:'ولي الأمر'}
 .hisasi-school-workspace [data-hisasi-table="family"] td:nth-child(2):before{content:'الطالب'}
 .hisasi-school-workspace .hisasi-s-responsive-table tbody tr:has(td[colspan]){display:block}
 .hisasi-school-workspace .hisasi-s-responsive-table tbody td[colspan]{display:block}
 .hisasi-school-workspace .hisasi-s-responsive-table tbody td[colspan]:before{content:none!important}
}

/* v1.6.1: contain wide controls locally, never by widening or clipping the viewport. */
.hisasi-school-workspace[data-hisasi-workspace] :is(.hisasi-school-admin,.hisasi-s-panel,.hisasi-s-schedule,.hisasi-s-day-boards,.hisasi-s-day-board,.hisasi-s-lesson-cards,.hisasi-s-editor,.hisasi-s-form,.hisasi-s-front-actions,.hisasi-s-schedule-head){min-width:0;max-width:100%;}
.hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-tabs,
.hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-day-filter,
.hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-scroll{min-width:0;width:100%;max-width:100%;overflow-x:auto;overflow-y:hidden;}
.hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-scroll{overflow-y:auto;}
.hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-lesson-card{min-width:0;max-width:100%;}
.hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-subject,
.hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-breadcrumb{overflow-wrap:anywhere;}
@media(max-width:680px){
 .hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-front-actions{gap:7px;}
 .hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-front-actions>*{max-width:100%;}
 .hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-stats{grid-template-columns:repeat(2,minmax(0,1fr));}
 .hisasi-school-workspace[data-hisasi-workspace] .hisasi-s-tabs{scroll-padding-inline:8px;}
}

/* Hisasi v1.7.0: unified front-end surfaces; all declarations remain within workspace. */
.hisasi-school-workspace[data-hisasi-workspace]{
 --hs-ink:#193442;--hs-brand:#116e75;--hs-soft:#f1f8f8;--hs-line:#d9e8e9;
 color:var(--hs-ink);color-scheme:light;
}
.hisasi-school-workspace .hisasi-school-admin{min-width:0}
.hisasi-school-workspace .hisasi-s-header{background:linear-gradient(114deg,#104553 0%,#126e77 62%,#23948d 100%);box-shadow:0 16px 38px rgba(15,69,81,.12)}
.hisasi-school-workspace .hisasi-s-header .description{max-width:65ch}
.hisasi-school-workspace .hisasi-s-panel{box-shadow:0 5px 20px rgba(17,75,88,.07)}
.hisasi-school-workspace .hisasi-s-stats>div{border-radius:16px;box-shadow:0 6px 22px rgba(15,80,91,.065);background:linear-gradient(160deg,#fff 42%,#eff8f8 100%);border:1px solid #ddebed}
.hisasi-school-workspace .hisasi-s-stats strong{color:#126d75;font-variant-numeric:tabular-nums}
.hisasi-school-workspace .hisasi-s-schedule-head{align-items:flex-start;gap:10px}
.hisasi-school-workspace .hisasi-s-schedule-head>div:first-child{flex:1 1 220px;min-width:0}
.hisasi-school-workspace .hisasi-s-view-switch{flex:0 1 auto;min-width:0;flex-wrap:wrap}
.hisasi-school-workspace .hisasi-s-view-btn{white-space:nowrap}
.hisasi-school-workspace .hisasi-s-tools{display:grid;grid-template-columns:minmax(150px,2fr) repeat(2,minmax(125px,1fr)) auto auto;gap:10px;align-items:end;padding:12px;border:1px solid #dbe9e9;background:#f4f9f9;border-radius:14px;margin:8px 0}
.hisasi-school-workspace .hisasi-s-tools label{display:grid;gap:5px;min-width:0;font-size:12px;color:#56747e;font-weight:750}
.hisasi-school-workspace .hisasi-s-tools :is(input,select){width:100%;min-width:0;max-width:100%;font-size:13px;min-height:40px;border:1px solid #cbdde0;border-radius:10px;background:#fff;padding:6px 10px;color:#243d46;font-family:inherit}
.hisasi-school-workspace .hisasi-s-tools button{min-height:40px;border:1px solid #cbdfe2;border-radius:10px;background:#fff;color:#245e6a;padding:8px 13px;cursor:pointer;white-space:nowrap;font:700 12px inherit}
.hisasi-school-workspace .hisasi-s-tools .hisasi-s-print{background:#147078;color:#fff;border-color:#147078}
.hisasi-school-workspace .hisasi-s-filter-result{font-size:12px;color:#567983;margin:7px 1px 5px}
.hisasi-school-workspace [data-hisasi-record][hidden]{display:none!important}
.hisasi-school-workspace [data-view="cards"] .hisasi-s-week-view,
.hisasi-school-workspace [data-view="table"] .hisasi-s-week-view,
.hisasi-school-workspace [data-view="week"] :is(.hisasi-s-day-boards,.hisasi-s-table-view){display:none!important}
.hisasi-school-workspace .hisasi-s-week-view{margin-top:13px;min-width:0;max-width:100%;}
.hisasi-school-workspace .hisasi-s-week-scroll{width:100%;max-width:100%;overflow-x:auto;overscroll-behavior-inline:contain;border:1px solid #dce8ec;border-radius:13px;background:#fff;scrollbar-width:thin;}
.hisasi-school-workspace .hisasi-s-week-grid{border-collapse:separate;border-spacing:0;width:100%;min-width:790px;table-layout:fixed;text-align:right;margin:0;font-size:12px}
.hisasi-school-workspace .hisasi-s-week-grid :is(th,td){padding:9px;vertical-align:top;border-inline-end:1px solid #e7eeef;border-bottom:1px solid #e7eeef;min-width:0}
.hisasi-school-workspace .hisasi-s-week-grid thead th{background:#e8f3f4;color:#245967;font-weight:800;position:sticky;top:0;z-index:1}
.hisasi-school-workspace .hisasi-s-week-grid th:first-child{width:91px;position:sticky;right:0;z-index:2;background:#f0f7f8}
.hisasi-school-workspace .hisasi-s-week-grid tbody th{font-size:12px;color:#2b6070;font-variant-numeric:tabular-nums}
.hisasi-school-workspace .hisasi-s-week-grid tbody th small{display:block;color:#77939a;font-size:11px;margin-top:5px}
.hisasi-school-workspace .hisasi-s-week-grid td{background:#fff;}
.hisasi-school-workspace .hisasi-s-week-grid tbody tr:nth-child(even) td{background:#f9fcfc}
.hisasi-school-workspace .hisasi-s-week-item{--lesson-accent:#147078;--lesson-tint:#e9f5f5;display:grid;gap:4px;min-width:0;margin:0 0 6px;padding:9px 10px;background:var(--lesson-tint);border-right:3px solid var(--lesson-accent);border-radius:9px;color:#263f49;overflow-wrap:anywhere}
.hisasi-school-workspace .hisasi-s-week-item strong{font-size:12px;line-height:1.5}
.hisasi-school-workspace .hisasi-s-week-item small{font-size:11px;color:#5f7981}
.hisasi-school-workspace .hisasi-s-week-item a{font-size:11px;font-weight:700;color:#0d6777;text-decoration:underline;text-underline-offset:2px}
.hisasi-school-workspace .hisasi-s-week-grid .hisasi-s-empty-cell{background:repeating-linear-gradient(135deg,#fff,#fff 8px,#fafdfe 8px,#fafdfe 17px)}
.hisasi-school-workspace .hisasi-s-copy{margin-top:16px}
.hisasi-school-workspace .hisasi-s-copy-filters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr)) auto;align-items:end;gap:11px;margin-top:12px}
.hisasi-school-workspace .hisasi-s-copy-filters label{display:grid;gap:6px;min-width:0;font-size:12px;color:#56747e;font-weight:750}
.hisasi-school-workspace .hisasi-s-copy-filters select{width:100%;min-height:43px;border-radius:10px;max-width:100%;min-width:0;background:#fff}
.hisasi-school-workspace .hisasi-s-copy-preview{border-radius:13px;border:1px solid #d2e6e4;background:#f5fbfa;padding:13px;margin:14px 0}
.hisasi-school-workspace .hisasi-s-copy-items{display:flex;flex-wrap:wrap;gap:6px;margin-top:10px}
.hisasi-school-workspace .hisasi-s-copy-items span{font-size:12px;padding:6px 9px;background:#fff;border:1px solid #dae7e7;border-radius:8px;color:#34545e}
.hisasi-school-workspace .hisasi-s-copy-submit{margin-top:12px}
.hisasi-school-workspace .hisasi-s-editor{background:linear-gradient(160deg,#fff,#f4fafa);border-color:#cde1e1;scroll-margin-top:28px}
.hisasi-school-workspace .hisasi-s-lesson-card:focus-within{outline:2px solid #94cdd0;outline-offset:2px}
@media(max-width:1100px){
 .hisasi-school-workspace .hisasi-s-tools{grid-template-columns:repeat(3,minmax(0,1fr))}
 .hisasi-school-workspace .hisasi-s-tools button{min-width:0}
}
@media(max-width:680px){
 .hisasi-school-workspace .hisasi-s-tools{grid-template-columns:repeat(2,minmax(0,1fr));padding:9px;gap:9px}
 .hisasi-school-workspace .hisasi-s-tools label:first-child{grid-column:1/-1}
 .hisasi-school-workspace .hisasi-s-tools button{white-space:normal;line-height:1.3;padding:8px}
 .hisasi-school-workspace .hisasi-s-week-grid{min-width:690px}
 .hisasi-school-workspace .hisasi-s-copy-filters{grid-template-columns:repeat(2,minmax(0,1fr))}
 .hisasi-school-workspace .hisasi-s-copy-filters button{grid-column:1/-1}
 .hisasi-school-workspace .hisasi-s-copy-preview{padding:10px}
 .hisasi-school-workspace .hisasi-s-view-btn{padding:9px 10px;font-size:12px}
}
@media print{
 @page{size:A4 landscape;margin:12mm}
 body.hisasi-print-mode *{visibility:hidden!important}
 body.hisasi-print-mode .hisasi-s-schedule,body.hisasi-print-mode .hisasi-s-schedule *{visibility:visible!important}
 body.hisasi-print-mode .hisasi-s-schedule{position:absolute!important;top:0!important;right:0!important;left:0!important;transform:none!important;box-shadow:none!important;border:0!important;background:#fff!important;padding:0!important;margin:0!important;width:100%!important;max-width:none!important}
 body.hisasi-print-mode .hisasi-s-schedule :is(.hisasi-s-tools,.hisasi-s-day-filter,.hisasi-s-filter-result,.hisasi-s-view-switch,.hisasi-s-card-actions,.hisasi-s-week-item a){display:none!important}
 body.hisasi-print-mode .hisasi-s-schedule .hisasi-s-week-view{display:block!important}
 body.hisasi-print-mode .hisasi-s-schedule :is(.hisasi-s-day-boards,.hisasi-s-table-view){display:none!important}
 body.hisasi-print-mode .hisasi-s-week-scroll{overflow:visible!important;border:0!important}
 body.hisasi-print-mode .hisasi-s-week-grid{min-width:0!important;width:100%!important;font-size:10px}
 body.hisasi-print-mode .hisasi-s-week-grid :is(th,td){padding:5px;break-inside:avoid}
 body.hisasi-print-mode .hisasi-s-week-item{break-inside:avoid}
}
.hisasi-school-workspace .hisasi-s-action-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
.hisasi-school-workspace .hisasi-s-action-tile{display:flex;flex-direction:column;gap:7px;min-width:0;padding:15px;border:1px solid #dbe8e9;border-radius:13px;background:linear-gradient(150deg,#fff,#f1f9f9);text-decoration:none;transition:border-color .15s,transform .15s}
.hisasi-school-workspace .hisasi-s-action-tile:hover{border-color:#77b7bc;transform:translateY(-2px)}
.hisasi-school-workspace .hisasi-s-action-tile strong{color:#1a6872;font-size:14px}
.hisasi-school-workspace .hisasi-s-action-tile span{color:#6b838b;font-size:12px;line-height:1.7}
.hisasi-school-workspace .hisasi-s-guidance summary{cursor:pointer;font-size:16px;font-weight:800;color:#24545e}
.hisasi-school-workspace .hisasi-s-guidance details[open] summary{margin-bottom:12px}
@media(max-width:900px){.hisasi-school-workspace .hisasi-s-action-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:450px){.hisasi-school-workspace .hisasi-s-action-tile{padding:11px}.hisasi-school-workspace .hisasi-s-action-tile strong{font-size:13px}}

/* v1.8 governance UI — contained within the school workspace, true RTL and mobile-safe. */
.hisasi-school-admin .hisasi-g-hero{background:linear-gradient(115deg,#124a58,#177a80);color:#fff;border:0;padding:22px 24px;display:flex;align-items:center;justify-content:space-between;gap:14px}
.hisasi-school-admin .hisasi-g-hero h2{color:#fff;margin:6px 0;font-size:clamp(18px,2vw,25px)}
.hisasi-school-admin .hisasi-g-hero p{color:#e1f4f4;margin:0;line-height:1.9;font-size:13px}
.hisasi-school-admin .hisasi-g-eyebrow{font-size:12px;font-weight:800;color:#b8ecdf}
.hisasi-school-admin .hisasi-g-status{display:inline-flex;background:#ffffff28;padding:9px 13px;border-radius:100px;color:#fff;white-space:nowrap}
.hisasi-school-admin .hisasi-g-grid{display:grid;grid-template-columns:minmax(0,1.3fr) minmax(0,1fr);gap:12px;margin-block:12px}
.hisasi-school-admin .hisasi-g-grid>*{min-width:0;margin:0}
.hisasi-school-admin .hisasi-g-term-list,.hisasi-school-admin .hisasi-g-history{display:grid;gap:8px}
.hisasi-school-admin .hisasi-g-term,.hisasi-school-admin .hisasi-g-history-item{display:flex;gap:10px;justify-content:space-between;align-items:center;border:1px solid #e0ebee;border-radius:12px;padding:12px;min-width:0}
.hisasi-school-admin .hisasi-g-term strong,.hisasi-school-admin .hisasi-g-history-item strong,.hisasi-school-admin .hisasi-g-lesson strong{display:block;color:#163c44}
.hisasi-school-admin .hisasi-g-term small,.hisasi-school-admin .hisasi-g-history-item small,.hisasi-school-admin .hisasi-g-lesson small{display:block;color:#64818b;margin-top:4px;font-size:12px}
.hisasi-school-admin .hisasi-g-term .hisasi-g-form,.hisasi-school-admin .hisasi-g-history-item .hisasi-g-form{flex:0 0 auto}
.hisasi-school-admin .hisasi-g-pill{display:inline-block;background:#f0f4f6;border-radius:50px;color:#53717d;font-size:12px;font-weight:700;padding:5px 11px;white-space:nowrap}
.hisasi-school-admin .hisasi-g-pill.is-published{background:#dcf5eb;color:#176448}
.hisasi-school-admin .hisasi-g-pill.is-draft{background:#fff2d5;color:#885e16}
.hisasi-school-admin .hisasi-g-details{margin-top:12px;border-top:1px solid #e5edf1;padding-top:10px}
.hisasi-school-admin .hisasi-g-details summary{cursor:pointer;color:#167178;font-weight:700;padding:5px 0}
.hisasi-school-admin .hisasi-g-form{max-width:100%;min-width:0}
.hisasi-school-admin .hisasi-g-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:11px;margin:14px 0}
.hisasi-school-admin .hisasi-g-fields label,.hisasi-school-admin .hisasi-g-pickers label{display:grid;min-width:0;gap:6px;color:#365b64;font-size:13px;font-weight:700}
.hisasi-school-admin .hisasi-g-fields input,.hisasi-school-admin .hisasi-g-fields select,.hisasi-school-admin .hisasi-g-pickers select,.hisasi-school-admin .hisasi-g-source select{display:block;width:100%;min-width:0;max-width:100%;box-sizing:border-box;margin:0;min-height:41px;padding:8px;background:#fff;border:1px solid #cfdee4;border-radius:10px}
.hisasi-school-admin .hisasi-g-control{margin-top:12px}
.hisasi-school-admin .hisasi-g-pickers{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:15px 0}
.hisasi-school-admin .hisasi-g-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:15px 0}
.hisasi-school-admin .hisasi-g-stats>span{min-width:0;border:1px solid #e1ebee;background:#f8fbfb;border-radius:12px;padding:14px}
.hisasi-school-admin .hisasi-g-stats strong{font-size:24px;color:#11616b;display:block}
.hisasi-school-admin .hisasi-g-stats small{font-size:12px;color:#67818b}
.hisasi-school-admin .hisasi-g-info{padding:12px 15px;border-radius:12px;background:#edf8f8;color:#235a64;margin:12px 0;font-size:13px;line-height:1.85}
.hisasi-school-admin .hisasi-g-source{display:grid;gap:6px;max-width:400px;margin:12px 0}
.hisasi-school-admin .hisasi-g-draft-heading{display:flex;gap:10px;align-items:center;font-size:17px;margin:16px 0 8px}
.hisasi-school-admin .hisasi-g-note{color:#66818b;font-size:12px;line-height:1.9}
.hisasi-school-admin .hisasi-g-lesson-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-block:14px}
.hisasi-school-admin .hisasi-g-lesson{display:flex;justify-content:space-between;align-items:center;gap:8px;background:#fff;border:1px solid #dfe9ed;border-right:4px solid #168089;border-radius:12px;padding:12px;min-width:0}
.hisasi-school-admin .hisasi-g-lesson>div:first-child{min-width:0;overflow-wrap:anywhere}
.hisasi-school-admin .hisasi-g-row-actions{display:flex;gap:5px;align-items:center;flex-wrap:wrap;flex:0 0 auto}
.hisasi-school-admin .hisasi-g-row-actions .button{margin:0}
.hisasi-school-admin .hisasi-g-row-actions button,.hisasi-school-admin .hisasi-g-history-item button,.hisasi-school-admin .hisasi-g-term button{padding:6px 9px;min-height:34px;font-size:12px;border-radius:8px}
.hisasi-school-admin .hisasi-g-editor{border:1px solid #cee6e5;border-radius:13px;padding:15px;margin-block:15px;background:#f9fdfd}
.hisasi-school-admin .hisasi-g-editor h3{margin:0}
.hisasi-school-admin .hisasi-g-publish{display:flex;flex-wrap:wrap;gap:12px;align-items:end;padding-top:16px;border-top:1px solid #e5ebee}
.hisasi-school-admin .hisasi-g-publish .hisasi-g-confirm{display:flex;align-items:flex-start;gap:8px;margin-bottom:12px;font-size:13px;line-height:1.8}
.hisasi-school-admin .hisasi-g-publish .hisasi-g-confirm input{flex:0 0 auto;margin-top:5px}
.hisasi-school-admin .hisasi-g-load{display:grid;gap:11px;margin:14px 0}
.hisasi-school-admin .hisasi-g-load-row>div:first-child{display:flex;justify-content:space-between;gap:10px;align-items:center}
.hisasi-school-admin .hisasi-g-load-row strong{font-size:13px}
.hisasi-school-admin .hisasi-g-load-row small{color:#587b84}
.hisasi-school-admin .hisasi-g-progress{height:8px;border-radius:8px;background:#e8f0f1;overflow:hidden;margin-top:7px}
.hisasi-school-admin .hisasi-g-progress span{display:block;height:100%;border-radius:8px;background:linear-gradient(90deg,#149698,#1b6978)}
@media(max-width:820px){.hisasi-school-admin .hisasi-g-grid{grid-template-columns:1fr}.hisasi-school-admin .hisasi-g-lesson-list{grid-template-columns:1fr}}
@media(max-width:540px){.hisasi-school-admin .hisasi-g-hero{align-items:flex-start;padding:15px;flex-direction:column}.hisasi-school-admin .hisasi-g-fields{grid-template-columns:repeat(2,minmax(0,1fr))}.hisasi-school-admin .hisasi-g-pickers{grid-template-columns:1fr}.hisasi-school-admin .hisasi-g-stats>span{padding:9px}.hisasi-school-admin .hisasi-g-stats strong{font-size:20px}.hisasi-school-admin .hisasi-g-lesson{flex-direction:column;align-items:stretch}.hisasi-school-admin .hisasi-g-row-actions{justify-content:flex-start}.hisasi-school-admin .hisasi-g-term,.hisasi-school-admin .hisasi-g-history-item{flex-wrap:wrap}.hisasi-school-admin .hisasi-g-grid,.hisasi-school-admin .hisasi-g-pickers,.hisasi-school-admin .hisasi-g-fields{min-width:0}.hisasi-school-admin .hisasi-g-term,.hisasi-school-admin .hisasi-g-history-item,.hisasi-school-admin .hisasi-g-lesson{max-width:100%;box-sizing:border-box}}
@media print{.hisasi-school-admin .hisasi-g-hero,.hisasi-school-admin .hisasi-g-form,.hisasi-school-admin .hisasi-g-editor,.hisasi-school-admin .hisasi-g-publish{display:none!important}}
/* v1.9 daily operations — scoped to Hisasi; no global theme rules. */
.hisasi-school-workspace .hisasi-ops-page{min-width:0;max-width:100%;overflow-wrap:anywhere}
.hisasi-school-workspace .hisasi-ops-title{display:flex;align-items:flex-start;justify-content:space-between;flex-wrap:wrap;gap:12px}
.hisasi-school-workspace .hisasi-ops-title h2{border:0;margin:0;padding:0}
.hisasi-school-workspace .hisasi-ops-title p,.hisasi-school-workspace .hisasi-ops-note{margin:6px 0 14px;color:#607981;line-height:1.85;font-size:13px}
.hisasi-school-workspace .hisasi-ops-label{color:#15727a;background:#e4f6f4;border:1px solid #c9e9e6;padding:7px 11px;border-radius:999px;font-size:12px;font-weight:700}
.hisasi-school-workspace .hisasi-ops-datebar{display:flex;align-items:end;gap:10px;flex-wrap:wrap;margin:17px 0 11px}
.hisasi-school-workspace .hisasi-ops-datebar label{display:grid;gap:5px;font-size:12px;font-weight:700}
.hisasi-school-workspace .hisasi-ops-datebar input{direction:ltr;border-radius:10px;border:1px solid #ccdade;min-height:42px;padding:6px 9px;max-width:100%;font:inherit}
.hisasi-school-workspace .hisasi-ops-datebar button{min-height:42px}
.hisasi-school-workspace .hisasi-ops-daynav{display:flex;justify-content:space-between;align-items:center;gap:8px;background:#f2f9f9;border:1px solid #e0ebec;border-radius:12px;padding:10px;margin-bottom:14px;flex-wrap:wrap}
.hisasi-school-workspace .hisasi-ops-daynav a{color:#126d79;background:#fff;border-radius:9px;border:1px solid #dcecee;padding:7px 10px;text-decoration:none;font-weight:650;font-size:12px}
.hisasi-school-workspace .hisasi-ops-daynav strong{font-size:13px;color:#214b54}
.hisasi-school-workspace .hisasi-ops-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-bottom:17px}
.hisasi-school-workspace .hisasi-ops-stats>div{border:1px solid #e0e9ec;border-radius:13px;padding:14px;background:linear-gradient(135deg,#fff,#f4fafb);display:flex;align-items:center;justify-content:space-between;gap:10px}
.hisasi-school-workspace .hisasi-ops-stats strong{font-size:25px;color:#0c6976}
.hisasi-school-workspace .hisasi-ops-stats span{font-size:12px;color:#657e85}
.hisasi-school-workspace .hisasi-ops-cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,250px),1fr));gap:12px;min-width:0}
.hisasi-school-workspace .hisasi-ops-card{background:#fff;border:1px solid #dce9e9;border-right:4px solid #168b88;border-radius:14px;padding:14px;box-shadow:0 5px 15px #194d4e0b;min-width:0;display:flex;flex-direction:column;gap:11px}
.hisasi-school-workspace .hisasi-ops-card.is-substituted{border-right-color:#9a5ac9;background:linear-gradient(160deg,#fff,#fbf8ff)}
.hisasi-school-workspace .hisasi-ops-card-top{display:flex;flex-wrap:wrap;justify-content:space-between;gap:7px;align-items:center}
.hisasi-school-workspace .hisasi-ops-time{font-size:12px;color:#0b6c75;font-weight:750;background:#eaf6f5;border-radius:8px;padding:5px 8px;direction:ltr}
.hisasi-school-workspace .hisasi-ops-chip{font-size:11px;color:#4f6570;background:#f2f5f6;padding:6px 9px;border-radius:999px}
.hisasi-school-workspace .hisasi-ops-card.is-substituted .hisasi-ops-chip{color:#7f45ae;background:#f5ecfa}
.hisasi-school-workspace .hisasi-ops-card h3{font-size:18px;line-height:1.4;margin:0;color:#173a47}
.hisasi-school-workspace .hisasi-ops-card-meta{display:flex;flex-direction:column;gap:6px;font-size:12px;color:#587079}
.hisasi-school-workspace .hisasi-ops-card-meta .hisasi-ops-soft{font-size:11px;color:#778b92}
.hisasi-school-workspace .hisasi-ops-empty{background:#f7fafb;border:1px dashed #cbdfe2;color:#53757c;border-radius:12px;padding:16px;text-align:center;font-size:13px}
.hisasi-school-workspace .hisasi-ops-create{display:grid;grid-template-columns:1fr 1fr auto;align-items:end;gap:10px;margin:12px 0}
.hisasi-school-workspace .hisasi-ops-create label{min-width:0;display:grid;gap:6px;font-weight:700;font-size:12px}
.hisasi-school-workspace .hisasi-ops-create input,.hisasi-school-workspace .hisasi-ops-create select,.hisasi-school-workspace .hisasi-ops-assign-form select{width:100%;max-width:100%;min-width:0;border:1px solid #cadfe2;border-radius:10px;min-height:43px;padding:6px 9px;background:#fff;color:#173b45;font:inherit}
.hisasi-school-workspace .hisasi-ops-form button{min-height:40px}
.hisasi-school-workspace .hisasi-ops-absences,.hisasi-school-workspace .hisasi-ops-assignments,.hisasi-school-workspace .hisasi-ops-log{display:grid;gap:8px}
.hisasi-school-workspace .hisasi-ops-absence,.hisasi-school-workspace .hisasi-ops-assignment,.hisasi-school-workspace .hisasi-ops-logitem{min-width:0;background:#fcfefe;border:1px solid #e0ebed;border-radius:11px;padding:12px;display:flex;align-items:center;justify-content:space-between;gap:12px}
.hisasi-school-workspace .hisasi-ops-absence>div,.hisasi-school-workspace .hisasi-ops-assignment>div{display:grid;gap:5px;min-width:0}
.hisasi-school-workspace .hisasi-ops-absence small,.hisasi-school-workspace .hisasi-ops-assignment small{color:#6b8289}
.hisasi-school-workspace .hisasi-ops-assign-form{display:flex;align-items:center;gap:8px;flex-wrap:wrap;max-width:100%}
.hisasi-school-workspace .hisasi-ops-assign-form select{width:min(240px,100%)}
.hisasi-school-workspace .hisasi-ops-inline{margin:0;flex:0 0 auto}
.hisasi-school-workspace .hisasi-ops-logitem{flex-direction:column;align-items:flex-start;gap:5px}
.hisasi-school-workspace .hisasi-ops-logitem strong{color:#236773}
.hisasi-school-workspace .hisasi-ops-logitem span{font-size:12px;color:#637d83}
@media(max-width:680px){
 .hisasi-school-workspace .hisasi-ops-create{grid-template-columns:1fr}
 .hisasi-school-workspace .hisasi-ops-stats{gap:7px}
 .hisasi-school-workspace .hisasi-ops-stats>div{padding:11px}
 .hisasi-school-workspace .hisasi-ops-absence,.hisasi-school-workspace .hisasi-ops-assignment{align-items:stretch;flex-direction:column}
 .hisasi-school-workspace .hisasi-ops-assign-form{width:100%}
 .hisasi-school-workspace .hisasi-ops-assign-form select{width:100%;flex:1 1 100%}
 .hisasi-school-workspace .hisasi-ops-daynav{justify-content:center;text-align:center}
 .hisasi-school-workspace .hisasi-ops-daynav strong{flex:1 1 100%;order:-1}
}
