@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Playfair+Display:wght@600;700&display=swap');@media(max-width:1023px){.desktop-nav{display:none}.menu-button{display:block}.mobile-nav{position:absolute;top:80px;left:0;right:0;background:#fff;border-bottom:1px solid var(--border);padding:16px;box-shadow:0 10px 30px rgb(15 23 42/.1)}.mobile-nav.open{display:grid;gap:4px}.mobile-nav>a,.mobile-nav summary{padding:12px;border-radius:6px}.mobile-nav details>a{display:block;padding:9px 12px;margin-left:12px;color:#475569}.hero-grid{grid-template-columns:1fr}.hero-card{display:none}.cards.three{grid-template-columns:1fr}.two-col{grid-template-columns:1fr}.section{padding-block:72px}.page-body{grid-template-columns:1fr}.page-nav .links{display:none}.dashboard-grid{grid-template-columns:1fr}.stats{grid-template-columns:1fr 1fr}}@media(max-width:600px){.brand-name{font-size:14px;line-height:1.15}.container{width:min(100% - 1.25rem,1180px)}.hero h1{font-size:2.9rem}.hero-text{font-size:16px;line-height:1.8}.section h2{font-size:32px}.cards.three,.stats{grid-template-columns:1fr}.dashboard-header .row{align-items:flex-start;flex-direction:column}.dashboard-shell{width:min(100% - 1.25rem,1200px)}.login-card{padding:24px}.page-nav .actions .teacher-action{display:none}}
@media(max-width:900px){.admin-sidebar{display:none}.admin-content{padding:16px;padding-bottom:88px}.admin-bottom-nav{display:flex;position:fixed;left:0;right:0;bottom:0;z-index:60;background:#fff;border-top:1px solid var(--border);overflow-x:auto;padding:6px 4px;box-shadow:0 -5px 18px rgb(15 23 42/.08)}.admin-bottom-nav .admin-tab{min-width:74px;flex:0 0 74px;justify-content:center;flex-direction:column;gap:2px;text-align:center;padding:7px 4px;margin:0;font-size:10px}.admin-bottom-nav .admin-tab span{font-size:16px}.result-filters{grid-template-columns:1fr 1fr}.report-info{grid-template-columns:1fr 1fr}.admin-card-grid{grid-template-columns:1fr 1fr}}
@media(max-width:600px){.portal-top{padding:48px 16px 76px}.portal-top h1{font-size:2.5rem}.login-card{margin:-26px auto 30px;padding:24px}.portal-head-row{align-items:flex-start;flex-direction:column}.portal-dashboard-header{padding:24px 16px}.result-filters{grid-template-columns:1fr}.report-wrap{padding:14px}.report-header{flex-direction:column}.report-header h2{font-size:18px}.report-info{grid-template-columns:1fr 1fr}.report-summary{grid-template-columns:1fr}.admin-card-grid{grid-template-columns:1fr}.inline-form{flex-direction:column}.data-table{min-width:720px}}


/* Mobile-first navigation and portal layout safeguards. */
@media(max-width:1023px){
 .desktop-nav{display:none!important}
 .menu-button{display:block;flex:0 0 auto}
 .nav-wrap{gap:10px}
 .brand{min-width:0;max-width:calc(100% - 96px)}
 .brand-name{overflow-wrap:anywhere}
 .mobile-nav{z-index:110;max-height:calc(100vh - 80px);overflow-y:auto}
 .mobile-nav a{min-height:44px;display:flex;align-items:center}
 .hero-card.school-identity-card{display:flex}
}
@media(min-width:1024px){
 .desktop-nav{display:flex}
 .menu-button{display:none}
 .mobile-nav{display:none!important}
}
@media(max-width:600px){
 html,body{max-width:100%;overflow-x:hidden}
 .portal-dashboard-header .portal-head-row{display:flex;flex-direction:row;align-items:center;flex-wrap:wrap;gap:10px}
 .portal-dashboard-header .portal-head-row>div:first-child{flex:1 1 100%;min-width:0}
 .portal-dashboard-header .portal-head-row>button{flex:1 1 auto;min-width:0;min-height:44px;padding:10px 12px}
 .portal-dashboard-header .portal-head-row h1{font-size:clamp(1.25rem,5vw,1.8rem);overflow-wrap:anywhere}
 .dashboard-shell{width:calc(100% - 16px);max-width:100%;margin-inline:auto}
 .dashboard-card,.admin-content,.portal-login-card{min-width:0;max-width:100%}
 .table-wrap{width:100%;max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch}
 .data-table{min-width:680px}
 .form-grid,.field-grid,.admission-field-grid{grid-template-columns:minmax(0,1fr)}
 input,select,textarea,button,.btn{max-width:100%}
 .contact-actions,.admission-actions{display:grid;grid-template-columns:minmax(0,1fr)}
 .contact-actions .btn,.admission-actions .btn{width:100%;min-width:0}
 .footer-grid{grid-template-columns:1fr}
}


/* Single right-aligned desktop-style navigation dropdown at every viewport size. */
@media(max-width:1023px){
 .desktop-nav{display:flex!important;align-items:center;gap:clamp(5px,1.5vw,12px);margin-left:auto;font-size:clamp(10px,1.8vw,13px);white-space:nowrap}
 .menu-button,.mobile-nav{display:none!important}
 .nav-wrap{height:80px;gap:8px}
 .brand{flex:0 1 auto;min-width:0;max-width:38%;gap:6px}
 .brand img{width:34px;height:34px;flex:0 0 auto}
 .brand-name{font-size:clamp(10px,1.8vw,14px);line-height:1.1;overflow-wrap:anywhere}
 .desktop-nav>a:not(.nav-enrol){padding:6px 0}
 .desktop-nav .nav-menu{position:relative;flex:0 0 auto}
 .desktop-nav summary{padding:7px 8px;border:1px solid var(--border);border-radius:7px;background:#fff;color:var(--navy);font-weight:700}
 .desktop-nav .dropdown{right:0;top:calc(100% + 8px);width:min(260px,calc(100vw - 16px));max-height:calc(100vh - 100px);overflow-y:auto;z-index:120}
 .desktop-nav .dropdown a{white-space:normal;min-height:40px}
}
@media(max-width:600px){
 .brand{max-width:36%}
 .brand-name{display:none}
 .desktop-nav{gap:clamp(6px,2.1vw,11px);font-size:clamp(10px,2.8vw,12px)}
 .desktop-nav summary{padding:7px 6px}
}
@media(max-width:360px){.desktop-nav{gap:5px;font-size:10px}.brand img{width:30px;height:30px}}


/* Mobile school identity and compact single-card gallery carousel. */
@media(max-width:600px){.brand-name{display:block!important;font-size:11px!important;line-height:1.05!important;max-width:128px;white-space:normal;overflow-wrap:anywhere}.brand{min-width:0;gap:7px}.brand img{width:34px;height:34px;object-fit:contain}.nav-wrap{gap:8px}.home-gallery-wrap{width:100%;max-width:560px;margin:0 auto}.home-gallery-carousel{width:100%;overflow:hidden;border:1px solid var(--border);border-radius:16px;background:#fff;box-shadow:0 8px 24px rgb(15 23 42/.09)}.home-gallery-viewport{width:100%;overflow:hidden}.home-gallery-track{display:flex;width:100%;transition:transform 1.1s cubic-bezier(.22,.7,.25,1);will-change:transform}.home-gallery-slide{flex:0 0 100%;min-width:0;background:#fff}.home-gallery-slide img{display:block;width:100%;aspect-ratio:16/9;object-fit:cover;background:#e2e8f0}.home-gallery-caption{padding:12px 15px 14px;text-align:center}.home-gallery-caption h3{margin:0;font-size:16px;line-height:1.35;color:var(--ink)}.home-gallery-actions{display:flex;justify-content:center;margin-top:14px}.home-gallery-actions .btn{min-height:40px;padding:10px 20px}}
@media(min-width:601px){.brand-name{display:block}.home-gallery-wrap{width:100%;max-width:620px;margin:0 auto}.home-gallery-carousel{overflow:hidden;border:1px solid var(--border);border-radius:18px;background:#fff;box-shadow:0 8px 24px rgb(15 23 42/.08)}.home-gallery-track{display:flex;width:100%;transition:transform 1.1s cubic-bezier(.22,.7,.25,1)}.home-gallery-slide{flex:0 0 100%;min-width:0}.home-gallery-slide img{display:block;width:100%;aspect-ratio:16/9;object-fit:cover}.home-gallery-caption{padding:13px 18px;text-align:center}.home-gallery-caption h3{margin:0;font-size:17px}.home-gallery-actions{display:flex;justify-content:center;margin-top:14px}}


/* Final public homepage mobile refinements: show the school name and keep gallery compact. */
@media(max-width:600px){
 .site-header .nav-wrap{height:auto;min-height:64px;padding-block:9px;justify-content:flex-start}
 .site-header .brand{display:flex!important;align-items:center;flex:0 1 auto;width:auto;max-width:none!important;min-width:0;gap:8px}
 .site-header .brand img{width:32px;height:32px;flex:0 0 32px}
 .site-header .brand .brand-name{display:block!important;visibility:visible!important;opacity:1!important;font-size:clamp(10px,3.2vw,12px)!important;line-height:1.15!important;max-width:calc(100vw - 58px)!important;white-space:normal!important;overflow-wrap:anywhere!important}
 .home-gallery-wrap{max-width:480px}
 .home-gallery-carousel{max-width:100%;border-radius:13px}
 .home-gallery-slide img{aspect-ratio:16/9;max-height:240px;object-fit:cover}
 .home-gallery-caption{padding:9px 12px}
 .home-gallery-caption h3{font-size:14px}
 .home-gallery-actions{margin-top:9px}
 .home-gallery-actions .btn-gallery-small{min-height:32px!important;padding:7px 13px!important;font-size:12px!important;border-radius:8px!important}
 .gallery-page-actions{display:flex;justify-content:flex-start;margin:0 0 14px}
 .gallery-page-actions .btn{min-height:36px;padding:8px 12px;font-size:12px}
}
@media(min-width:601px){
 .home-gallery-actions .btn-gallery-small{min-height:34px;padding:8px 15px;font-size:12px}
 .gallery-page-actions{display:flex;justify-content:flex-start;margin:0 0 16px}
}
@media(prefers-reduced-motion:reduce){.home-gallery-track{transition:none!important}}
