:root {
  --prisht-navy: #053b72;
  --prisht-blue: #0799dc;
  --prisht-sky: #dff6ff;
  --prisht-ink: #052f63;
  --prisht-red: #ff1f3d;
}

body {
  background: #eaf8ff;
  color: var(--prisht-ink);
}

#appShell:not(.d-none) {
  display: grid;
  grid-template-columns: clamp(138px, 14.2vw, 220px) minmax(0, 1fr);
  grid-template-rows: 62px minmax(0, 1fr);
  height: 100dvh;
  overflow: hidden;
  background: linear-gradient(135deg, #f4fbff 0%, #e3f7ff 64%, #effbff 100%);
}

#appShell:not(.d-none) .topbar {
  grid-column: 2;
  grid-row: 1;
  display: grid;
  grid-template-columns: minmax(230px, 1fr) minmax(180px, 330px) minmax(230px, 1fr);
  align-items: center;
  height: 62px;
  padding: 0 20px;
  border: 0;
  border-bottom: 1px solid #d7edf8;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: none;
  backdrop-filter: blur(16px);
}

.topbar-leading { gap: 12px; }

.sidebar-toggle {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 12px;
  background: #e5f6ff;
  color: #068dd0;
  font-size: 18px;
  box-shadow: none;
}

.sidebar-toggle:hover { background: #d7f1ff; color: #006fb4; transform: none; }

.topbar-breadcrumb {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: #88a2bb;
  font-size: 12px;
  font-weight: 700;
  text-transform: none;
}

.topbar-breadcrumb i { color: #28baf1; font-size: 11px; }
.topbar-breadcrumb b { color: #083c70; font-size: 13px; }

.topbar-search {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  height: 36px;
  padding: 0 13px;
  border: 1px solid #e2eef5;
  border-radius: 10px;
  background: #f8fcff;
  color: #94abc0;
  box-shadow: 0 3px 12px rgba(26, 103, 145, 0.04);
}

.topbar-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: #264d70;
  font: inherit;
  font-size: 11px;
}

.topbar-search input::placeholder { color: #9cb1c5; }

.topbar-actions { justify-self: end; display: flex; align-items: center; gap: 12px; }

.notification-button {
  position: relative;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: #07539a;
  font-size: 17px;
}

.notification-button span {
  position: absolute;
  top: 7px;
  right: 8px;
  width: 7px;
  height: 7px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #ff2647;
}

.profile-trigger {
  min-width: 165px;
  height: 46px;
  padding: 5px 10px 5px 6px;
  border: 0;
  border-radius: 14px;
  background: #f4faff;
}

.profile-avatar { width: 34px; height: 34px; background: linear-gradient(135deg, #ff1e26, #ff8a00); color: #fff; }
.profile-trigger-copy b { color: #063966; font-size: 11px; }
.profile-trigger-copy small { color: #6ba1c9; font-size: 10px; }
.profile-trigger > i { color: #4c82ad; font-size: 10px; }

#appShell:not(.d-none) .app-layout {
  display: contents;
  min-height: 0;
  overflow: visible;
}

#appShell:not(.d-none) .sidebar {
  grid-column: 1;
  grid-row: 1 / 3;
  position: relative;
  top: auto;
  z-index: 20;
  display: flex;
  flex-direction: column;
  width: auto;
  height: 100dvh;
  min-height: 0;
  padding: 8px 7px 12px;
  overflow: hidden;
  border: 0;
  border-right: 1px solid #d9edf7;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 5px 0 25px rgba(19, 92, 132, 0.04);
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 68px;
  padding: 7px 12px;
  color: #043a70;
  text-decoration: none;
}

.sidebar-brand img {
  width: 68px;
  height: 48px;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.sidebar-brand span { display: none; }
.sidebar-brand b, .sidebar-brand small { display: block; }
.sidebar-brand b { font-size: 15px; line-height: 1.05; }
.sidebar-brand small { margin-top: 3px; color: #50a5ce; font-size: 8px; font-weight: 800; letter-spacing: .7px; text-transform: uppercase; }

#sidebarNav {
  min-height: 0;
  padding-right: 4px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #cde3ee transparent;
}

.nav-section {
  padding: 12px 11px 5px;
  color: #83a8c2;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .7px;
}

.side-link {
  min-height: 36px;
  gap: 10px;
  margin: 1px 0;
  padding: 7px 12px;
  border: 0;
  border-radius: 9px;
  color: #164d7d;
  font-size: 11px;
  font-weight: 750;
}

.side-link i { width: 20px; height: 20px; border-radius: 6px; color: #075b9d; font-size: 13px; }
.side-link:hover { border: 0; background: #eef9ff; color: #007ec4; transform: none; }
.side-link.active { background: #d9f1ff; color: #007fca; box-shadow: none; }
.side-link.active::before { content: ""; position: absolute; left: -7px; top: 5px; bottom: 5px; width: 3px; border-radius: 0 4px 4px 0; background: #078df4; }
.side-link.active i { background: #fff; color: #008edb; }

.sidebar-motto {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 58px;
  margin: 10px 7px 0;
  padding: 10px;
  border-radius: 14px;
  background: linear-gradient(135deg, #ddf8ff, #f4fcff);
  color: #075189;
}

.sidebar-motto > i { display: grid; place-items: center; width: 29px; height: 29px; border-radius: 9px; background: #07aee8; color: #fff; }
.sidebar-motto span { display: grid; }
.sidebar-motto b { font-size: 9px; }
.sidebar-motto small { color: #65a1be; font-size: 7px; }

#appShell:not(.d-none) .page-content {
  grid-column: 2;
  grid-row: 2;
  width: 100%;
  max-width: none;
  height: auto;
  min-height: 0;
  padding: 10px 16px 0;
  overflow-x: hidden;
  overflow-y: auto;
}

#appShell.sidebar-hidden:not(.d-none) { grid-template-columns: 0 minmax(0, 1fr); }
#appShell.sidebar-hidden:not(.d-none) .sidebar { width: 0; padding: 0; border: 0; transform: translateX(-100%); }

.prisht-dashboard {
  width: min(100%, 1390px);
  min-height: 100%;
  margin: 0 auto;
}

.prisht-hero {
  position: relative;
  height: clamp(158px, 16vw, 220px);
  overflow: hidden;
  border: 1px solid rgba(84, 190, 229, .22);
  border-radius: 20px;
  background: #e9faff;
  box-shadow: 0 9px 24px rgba(20, 111, 151, .09);
  isolation: isolate;
}

.prisht-hero-art { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.prisht-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(242,253,255,.98) 0%, rgba(239,252,255,.94) 35%, rgba(239,252,255,.22) 58%, transparent 73%); }
.prisht-hero-copy { display: flex; flex-direction: column; justify-content: center; width: 54%; height: 100%; padding: 20px 30px; }
.prisht-hero .experience-kicker { color: #125b9c; font-size: 10px; font-weight: 950; letter-spacing: 2px; }
.prisht-hero h1 { max-width: 560px; margin: 7px 0 7px; color: #06336f; font-size: clamp(25px, 2.45vw, 38px); font-weight: 950; line-height: 1.03; letter-spacing: -.9px; }
.prisht-hero p { margin: 0; color: #1d537e; font-size: 12px; font-weight: 650; line-height: 1.45; }
.prisht-hero .experience-hero-actions { display: flex; gap: 10px; margin-top: 14px; }
.prisht-hero .btn { min-height: 40px; padding: 9px 17px; border: 0; border-radius: 10px; font-size: 11px; font-weight: 850; box-shadow: 0 6px 14px rgba(15, 65, 98, .11); }
.prisht-hero .btn.primary { background: linear-gradient(135deg, #ff1438, #ff2949); color: #fff; }
.prisht-hero .btn.secondary { background: rgba(255,255,255,.94); color: #063b73; }
.hero-handwriting { position: absolute; left: 47%; top: 25%; color: #0b3f7e; font-family: "Comic Sans MS", cursive; font-size: 17px; font-weight: 700; line-height: 1.05; transform: rotate(-8deg); }
.hero-handwriting i { color: #ff2441; font-size: 24px; }

.prisht-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 10px 0; }
.prisht-metrics .experience-metric { position: relative; display: flex; align-items: center; min-height: clamp(74px, 7vw, 94px); margin: 0; padding: 11px 13px; overflow: hidden; border-radius: 16px; box-shadow: 0 7px 18px rgba(25, 116, 158, .06); }
.prisht-metrics .experience-metric.coral { border: 1px solid #ffcfd5; background: #fff4f5; }
.prisht-metrics .experience-metric.amber { border: 1px solid #ffe1a3; background: #fff9e9; }
.prisht-metrics .experience-metric.blue { border: 1px solid #bae8ff; background: #effaff; }
.prisht-metrics .experience-metric.green { border: 1px solid #b3f0d8; background: #effdf8; }
.prisht-metrics .experience-metric > span { width: 42px; height: 42px; flex: 0 0 42px; margin-right: 10px; border-radius: 12px; font-size: 20px; }
.prisht-metrics .coral > span { background: #ffe1e6; color: #ff4259; }
.prisht-metrics .amber > span { background: #fff0c9; color: #ff9200; }
.prisht-metrics .blue > span { background: #d6f3ff; color: #00a6ef; }
.prisht-metrics .green > span { background: #cff8e8; color: #00b779; }
.prisht-metrics .experience-metric > div { min-width: 0; }
.prisht-metrics strong { display: inline-block; margin-right: 5px; color: #07356c; font-size: 25px; line-height: 1; }
.prisht-metrics h3 { display: inline; color: #07356c; font-size: 10px; font-weight: 850; white-space: nowrap; }
.prisht-metrics p { margin: 5px 0 0; color: #6592b2; font-size: 9px; }
.metric-spark { position: absolute; top: 17px; right: 16px; width: 41px; height: 18px; border-top: 2px solid currentColor; border-radius: 50%; transform: rotate(-11deg); opacity: .9; }
.metric-spark::before, .metric-spark::after { content: ""; position: absolute; width: 17px; height: 8px; border-top: 2px solid currentColor; border-radius: 50%; }
.metric-spark::before { left: 8px; top: -4px; transform: rotate(22deg); }.metric-spark::after { right: -1px; top: -7px; transform: rotate(-22deg); }
.coral .metric-spark { color: #ff4563; }.amber .metric-spark { color: #ffae19; }.blue .metric-spark { color: #00aaf3; }.green .metric-spark { color: #00c584; }
.metric-arrow { position: absolute; right: 12px; bottom: 11px; display: grid; place-items: center; width: 25px; height: 25px; padding: 0; border: 0; border-radius: 50%; background: rgba(255,255,255,.9); color: #118ac8; font-size: 10px; }

.prisht-action-grid { display: grid; grid-template-columns: minmax(0, 2.25fr) minmax(260px, .85fr); gap: 10px; }
.prisht-action-grid .experience-card { margin: 0; padding: 12px 14px; border: 1px solid #d8edf6; border-radius: 17px; background: rgba(255,255,255,.94); box-shadow: 0 7px 18px rgba(24, 111, 153, .06); }
.prisht-action-grid .experience-card header { position: relative; display: flex; align-items: center; gap: 10px; margin-bottom: 9px; }
.prisht-action-grid .experience-card header > span { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 11px; background: #ffe5e9; color: #ff3552; font-size: 17px; }
.prisht-action-grid .quick-access-card header > span { background: #dff9ec; color: #00b978; }
.prisht-action-grid h2 { margin: 0; color: #07366c; font-size: 13px; font-weight: 900; }
.prisht-action-grid header p { margin: 2px 0 0; color: #77a0bb; font-size: 8px; }
.workflow-note { position: absolute; right: 10px; top: -5px; display: flex; align-items: center; gap: 7px; color: #1662a0; transform: rotate(-3deg); }
.workflow-note i { font-size: 30px; color: #ffad17; }.workflow-note small { font-family: "Comic Sans MS", cursive; font-size: 9px; font-weight: 800; line-height: 1.1; }
.workflow-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; }
.workflow-steps button { position: relative; display: grid; grid-template-columns: 28px 1fr 10px; grid-template-rows: 26px auto; gap: 3px 7px; min-height: 82px; padding: 6px 9px; border: 0; border-right: 1px dashed #beddea; border-radius: 0; background: transparent; color: #0b487e; text-align: left; box-shadow: none; }
.workflow-steps button:last-child { border-right: 0; }
.workflow-steps button:hover { background: #f2fbff; transform: none; }
.workflow-steps button > b { grid-column: 1; grid-row: 1; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: #ffdfE5; color: #ff4560; font-size: 10px; }
.workflow-steps button:nth-child(2) > b { background: #dff5ff; color: #009ee8; }.workflow-steps button:nth-child(3) > b { background: #d8faee; color: #00b984; }.workflow-steps button:nth-child(4) > b { background: #f4defe; color: #b249e8; }
.workflow-steps button > i { grid-column: 2; grid-row: 1; display: grid; place-items: center; width: 28px; height: 25px; border-radius: 9px; background: #fff0f3; color: #ff4962; font-size: 14px; }
.workflow-steps button:nth-child(2) > i { background: #edf9ff; color: #009de7; }.workflow-steps button:nth-child(3) > i { background: #e8fcf5; color: #00b889; }.workflow-steps button:nth-child(4) > i { background: #faf0ff; color: #b444e4; }
.workflow-steps button > span { grid-column: 1 / 4; grid-row: 2; display: block; }
.workflow-steps strong { display: block; color: #0a487f; font-size: 9px; }.workflow-steps small { display: block; margin-top: 3px; color: #79a0ba; font-size: 7px; line-height: 1.35; }
.workflow-steps em { position: absolute; right: 6px; top: 12px; color: #1876b0; font-size: 9px; font-style: normal; }

.quick-access-grid { display: grid; grid-template-columns: 1fr; gap: 3px; }
.quick-access-grid button { display: grid; grid-template-columns: 25px 1fr 12px; align-items: center; min-height: 29px; padding: 3px 7px; border: 0; border-bottom: 1px solid #dbeef6; border-radius: 0; background: transparent; color: #124d7d; font-size: 9px; font-weight: 800; text-align: left; box-shadow: none; }
.quick-access-grid button:last-child { border-bottom: 0; }.quick-access-grid button:hover { background: #f4fbff; transform: none; }
.quick-access-grid button i { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 7px; background: #ffe9ed; color: #ff4961; font-size: 11px; }
.quick-access-grid button:nth-child(2) i { background: #fff2d0; color: #ff9c00; }.quick-access-grid button:nth-child(3) i { background: #ddf4ff; color: #008edb; }.quick-access-grid button:nth-child(4) i { background: #f0e6ff; color: #9344df; }
.quick-access-grid button em { justify-self: end; color: #1972aa; font-size: 9px; font-style: normal; }

.prisht-footer-art { position: relative; min-height: 85px; margin: 8px -16px 0; overflow: hidden; background: radial-gradient(ellipse at 20% 110%, #6de2dd 0 20%, transparent 21%), radial-gradient(ellipse at 50% 120%, #a3edf1 0 30%, transparent 31%), radial-gradient(ellipse at 90% 115%, #52d8cf 0 25%, transparent 26%), linear-gradient(180deg, rgba(222,249,255,0), #c9f5f8); }
.prisht-footer-art blockquote { position: relative; z-index: 2; width: max-content; margin: 20px auto 0; color: #0e4f80; font-family: "Comic Sans MS", cursive; font-size: 9px; font-weight: 700; text-align: center; transform: rotate(-2deg); }
.footer-leaves { position: absolute; left: 5%; bottom: -12px; display: flex; align-items: end; gap: 1px; }.footer-leaves i { display: block; width: 28px; height: 75px; border-radius: 100% 0 100% 0; background: #00a976; transform: rotate(-26deg); }.footer-leaves i:nth-child(2) { height: 95px; background: #00c49a; transform: rotate(-3deg); }.footer-leaves i:nth-child(3) { height: 65px; background: #0eb5b4; transform: rotate(24deg); }
.footer-books { position: absolute; right: 8%; bottom: -7px; width: 105px; }.footer-books span { display: block; height: 13px; margin-top: 2px; border-radius: 4px; background: #ffbc14; transform: rotate(-3deg); }.footer-books span:nth-child(2) { width: 93px; margin-left: 7px; background: #08a4ca; transform: rotate(2deg); }.footer-books span:nth-child(3) { width: 100px; background: #ff344e; transform: rotate(-1deg); }.footer-books > i { position: absolute; right: -40px; bottom: 8px; color: #08aa78; font-size: 43px; }

@media (min-width: 1250px) {
  .sidebar-brand span { display: block; }
  .sidebar-brand img { width: 62px; }
}

@media (max-width: 900px) {
  #appShell:not(.d-none) { grid-template-columns: 78px minmax(0, 1fr); }
  .sidebar-brand { justify-content: center; padding: 6px 2px; }.sidebar-brand img { width: 62px; }.sidebar-brand span, .sidebar-motto span, .nav-section { display: none; }
  .side-link { justify-content: center; padding: 7px; }.side-link i { font-size: 16px; }.sidebar-motto { justify-content: center; padding: 7px; }
  #appShell:not(.d-none) .topbar { grid-template-columns: minmax(200px,1fr) 250px minmax(200px,1fr); padding: 0 12px; }
  .hero-handwriting { display: none; }.prisht-hero-copy { width: 58%; padding-left: 24px; }.prisht-action-grid { grid-template-columns: minmax(0, 2fr) minmax(230px, .8fr); }
}

@media (max-width: 760px) {
  #appShell:not(.d-none) { grid-template-columns: 0 minmax(0, 1fr); grid-template-rows: 58px minmax(0,1fr); }
  #appShell:not(.d-none) .sidebar { position: fixed; inset: 0 auto 0 0; width: 210px; transform: translateX(0); box-shadow: 10px 0 30px rgba(0,53,90,.18); }
  #appShell.sidebar-hidden:not(.d-none) .sidebar { width: 210px; transform: translateX(-105%); }
  #appShell:not(.d-none) .topbar { grid-column: 2; grid-template-columns: 1fr auto; height: 58px; }.topbar-search { display: none; }.topbar-breadcrumb span, .topbar-breadcrumb i { display: none; }.notification-button { display: none; }.profile-trigger { min-width: 0; }.profile-trigger-copy { display: none; }
  #appShell:not(.d-none) .page-content { padding: 10px; }.prisht-hero { height: 245px; }.prisht-hero-art { object-position: 67% center; opacity: .42; }.prisht-hero::after { background: linear-gradient(90deg, rgba(242,253,255,.98), rgba(239,252,255,.72)); }.prisht-hero-copy { width: 100%; padding: 22px; }.prisht-hero h1 { font-size: 29px; }.prisht-hero p br { display: none; }
  .prisht-metrics { grid-template-columns: repeat(2, 1fr); }.prisht-action-grid { grid-template-columns: 1fr; }.workflow-steps { grid-template-columns: repeat(2, 1fr); }.workflow-steps button:nth-child(2) { border-right: 0; }.workflow-note { display: none; }.prisht-footer-art { margin-inline: -10px; }
}

@media (max-width: 480px) {
  .prisht-hero .experience-hero-actions { align-items: stretch; flex-direction: column; width: 185px; }.prisht-metrics { grid-template-columns: 1fr; }.workflow-steps { grid-template-columns: 1fr; }.workflow-steps button { border-right: 0; border-bottom: 1px dashed #beddea; }.workflow-steps button:last-child { border-bottom: 0; }
}

body.theme-dark #appShell:not(.d-none) { background: #0d2034; }
body.theme-dark #appShell:not(.d-none) .topbar, body.theme-dark #appShell:not(.d-none) .sidebar { background: rgba(15,35,55,.98); border-color: #264963; }
body.theme-dark .sidebar-brand, body.theme-dark .side-link, body.theme-dark .topbar-breadcrumb b { color: #d8efff; }
body.theme-dark .topbar-search, body.theme-dark .profile-trigger { background: #142e45; border-color: #284b65; }
body.theme-dark .prisht-action-grid .experience-card { background: #142b40; border-color: #28516c; }
body.theme-dark .prisht-action-grid h2, body.theme-dark .workflow-steps strong, body.theme-dark .quick-access-grid button { color: #e6f5ff; }

/* Content View — Prisht Education theme */
#appShell:not(.d-none) .page-content.shared-content-page-shell {
  height: auto;
  padding: 10px 16px 0;
  background: transparent;
}

.shared-content-view {
  width: min(100%, 1390px);
  min-height: 100%;
  margin: 0 auto;
  gap: 10px;
}

.shared-content-view .learning-library-hero {
  position: relative;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, .65fr);
  min-height: 170px;
  padding: 22px 26px;
  overflow: hidden;
  border: 1px solid rgba(84, 190, 229, .28);
  border-radius: 20px;
  background:
    linear-gradient(90deg, rgba(241,253,255,.98) 0%, rgba(238,252,255,.91) 49%, rgba(235,251,255,.2) 76%),
    url("../images/prisht-dashboard-hero.png") center / cover no-repeat;
  color: #07376e;
  box-shadow: 0 9px 24px rgba(20, 111, 151, .09);
}

.shared-content-view .learning-library-hero::before {
  top: -165px;
  left: 35%;
  width: 260px;
  height: 260px;
  background: rgba(91, 220, 242, .16);
}

.shared-content-view .learning-library-hero::after {
  right: -60px;
  bottom: -115px;
  width: 180px;
  height: 180px;
  background: rgba(0, 171, 210, .11);
}

.shared-content-view .learning-library-copy {
  align-self: center;
  max-width: 650px;
}

.shared-content-view .learning-library-kicker {
  margin-bottom: 8px;
  color: #1668a4;
  font-size: 10px;
  font-weight: 950;
  letter-spacing: 1.7px;
}

.shared-content-view .learning-library-kicker i { color: #ff2949; }

.shared-content-view .learning-library-copy h1 {
  color: #07366d;
  font-size: clamp(27px, 2.65vw, 40px);
  font-weight: 950;
  line-height: 1.03;
  letter-spacing: -.8px;
}

.shared-content-view .learning-library-copy > p {
  max-width: 590px;
  margin: 7px 0 13px;
  color: #346789;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.45;
}

.shared-content-view .learning-library-stats { gap: 7px; }
.shared-content-view .learning-library-stats span {
  min-width: 92px;
  padding: 6px 10px;
  border: 1px solid rgba(115, 202, 231, .45);
  background: rgba(255,255,255,.82);
  color: #5483a5;
  box-shadow: 0 4px 12px rgba(16, 107, 146, .05);
  backdrop-filter: blur(8px);
}
.shared-content-view .learning-library-stats strong { color: #074d87; }

.shared-content-view .hero-quick-chapters {
  align-self: center;
  padding: 13px;
  border: 1px solid rgba(111, 203, 232, .4);
  border-radius: 15px;
  background: rgba(255,255,255,.84);
  box-shadow: 0 8px 22px rgba(21, 100, 137, .09);
  backdrop-filter: blur(12px);
}

.shared-content-view .hero-quick-heading > span {
  background: linear-gradient(135deg, #ff2647, #ff7a22);
  color: #fff;
  box-shadow: 0 5px 12px rgba(255, 52, 71, .2);
}

.shared-content-view .hero-quick-heading h2 { color: #07386d; }
.shared-content-view .hero-quick-heading p { color: #6d94ae; }
.shared-content-view .hero-quick-chapters .quick-chapter {
  border-color: #d7eaf3;
  background: rgba(248,253,255,.95);
  color: #18527f;
}
.shared-content-view .hero-quick-chapters .quick-chapter > i { background: #19bde6; box-shadow: 0 0 0 4px #dbf7fc; }
.shared-content-view .hero-quick-chapters .quick-chapter:hover { border-color: #75d5ed; background: #fff; color: #008ec7; }

.shared-content-view .school-chapter-browser {
  padding: 13px 15px 0;
  border: 1px solid #d5ebf5;
  border-radius: 18px;
  background: rgba(255,255,255,.94);
  box-shadow: 0 8px 22px rgba(24, 111, 153, .07);
}

.shared-content-view .library-browser-heading { padding: 0 2px 10px; }
.shared-content-view .library-browser-icon {
  background: linear-gradient(135deg, #d8f4ff, #e8fbff);
  color: #0099dc;
}
.shared-content-view .library-browser-heading h2 { color: #07366c; font-size: 14px; }
.shared-content-view .library-browser-heading p { color: #76a0ba; font-size: 10px; }
.shared-content-view .library-browser-badge { background: #e8f8ff; color: #078dca; }

.shared-content-view .school-library-selectors { gap: 9px; padding-bottom: 10px; }
.shared-content-view .content-filter-field {
  padding: 7px 9px 8px;
  border: 1px solid #d8ecf4;
  border-radius: 13px;
  background: #f8fdff;
  box-shadow: none;
}
.shared-content-view .content-filter-field:nth-child(1) { background: #f2fbff; }
.shared-content-view .content-filter-field:nth-child(2) { background: #fff9ee; border-color: #f7e7c2; }
.shared-content-view .content-filter-field:nth-child(3) { background: #f2fdf9; border-color: #d4f0e4; }
.shared-content-view .content-filter-field:focus-within { border-color: #69cfee; box-shadow: 0 0 0 3px rgba(31, 180, 225, .1); }
.shared-content-view .content-filter-field > span { color: #2c638a; font-size: 9px; font-weight: 850; }
.shared-content-view .content-filter-field > span b { background: #d7f3ff; color: #008fd2; }
.shared-content-view .content-filter-field:nth-child(2) > span b { background: #ffedc7; color: #f09100; }
.shared-content-view .content-filter-field:nth-child(3) > span b { background: #d5f7e9; color: #00a978; }
.shared-content-view .library-select-search {
  min-height: 34px;
  border: 0;
  background: rgba(255,255,255,.86);
  color: #174f7d;
  font-size: 11px;
  font-weight: 700;
  box-shadow: inset 0 0 0 1px rgba(171, 210, 226, .5);
}
.shared-content-view .library-select-search:focus { box-shadow: inset 0 0 0 1px #5ac9eb, 0 0 0 3px rgba(32,181,224,.08); }
.shared-content-view .library-select-toggle { color: #1b7ead; }
.shared-content-view .library-select-menu { border-color: #c5e2ee; box-shadow: 0 14px 30px rgba(11,73,106,.16); }
.shared-content-view .library-select-menu button { color: #174f78; font-size: 11px; }
.shared-content-view .library-select-menu button:hover,
.shared-content-view .library-select-menu button[aria-selected="true"] { background: #e9f9ff; color: #008dca; }

.shared-content-view .school-chapter-detail {
  min-height: 250px;
  padding: 0 2px;
  border: 0;
  background: transparent;
}

.shared-content-view .school-chapter-heading {
  min-height: 57px;
  padding: 9px 2px 8px;
  border-top: 1px solid #e0f0f6;
}
.shared-content-view .school-chapter-title > span {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: linear-gradient(135deg, #ff2947, #ff8142);
  color: #fff;
  box-shadow: 0 5px 13px rgba(255, 55, 72, .17);
}
.shared-content-view .school-chapter-title small { color: #6493b2; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; }
.shared-content-view .school-chapter-title h3 { color: #07396e; font-size: 16px; font-weight: 900; }
.shared-content-view .school-chapter-title em { color: #79a1ba; font-size: 9px; }
.shared-content-view .shared-flipbook-action { border: 0; border-radius: 9px; background: #078fd0; box-shadow: 0 5px 13px rgba(7,143,208,.2); }

.shared-content-view .school-resource-tabs {
  gap: 6px;
  padding: 0 0 8px;
  border-bottom-color: #dceef5;
}
.shared-content-view .school-resource-tabs button {
  min-height: 32px;
  padding: 5px 10px;
  border-radius: 9px;
  color: #487590;
  font-size: 10px;
  font-weight: 800;
}
.shared-content-view .school-resource-tabs button:hover,
.shared-content-view .school-resource-tabs button.active { border-color: #a7def0; background: #e8f9ff; color: #008dcc; }
.shared-content-view .school-resource-tabs button.active span { background: #08a9df; color: #fff; }

.shared-content-view .school-resource-grid {
  grid-template-columns: repeat(auto-fill, minmax(275px, 1fr));
  gap: 9px;
  min-height: 170px;
  padding: 10px 0 13px;
}
.shared-content-view .school-resource-card {
  min-height: 82px;
  max-width: none;
  padding: 12px;
  border: 1px solid #d9ebf3;
  border-radius: 14px;
  background: #fbfeff;
  box-shadow: 0 4px 12px rgba(25, 103, 139, .045);
}
.shared-content-view .school-resource-card:hover { border-color: #9bdcec; box-shadow: 0 8px 20px rgba(19, 108, 148, .1); transform: translateY(-2px); }
.shared-content-view .school-resource-accent { right: 13px; left: 13px; background: #00a6e5; }
.shared-content-view .resource-pdf .school-resource-accent { background: #ff3d58; }
.shared-content-view .resource-ar .school-resource-accent { background: #a74be2; }
.shared-content-view .resource-exercise .school-resource-accent { background: #00ba83; }
.shared-content-view .school-resource-card-top .school-resource-icon { width: 40px; height: 40px; border-radius: 11px; }
.shared-content-view .school-resource-card h4 { color: #0b4b7c; font-size: 12px; font-weight: 900; }
.shared-content-view .school-resource-card p { color: #7b9bb0; font-size: 9px; }
.shared-content-view .school-resource-card > .btn { min-width: 76px; min-height: 34px; border-radius: 9px; font-size: 10px; }
.shared-content-view .resource-video > .btn { border-color: #b9e9f8; background: #eafaff; color: #008dc9; }
.shared-content-view .resource-pdf > .btn { border-color: #ffc8d1; background: #fff1f3; color: #dc2944; }
.shared-content-view .resource-ar > .btn { border-color: #e5cef4; background: #faf1ff; color: #9140c7; }
.shared-content-view .resource-exercise > .btn { border-color: #bdebd9; background: #edfbf5; color: #009b70; }
.shared-content-view .resource-video:hover > .btn { border-color: #009bd6; background: #009bd6; }
.shared-content-view .resource-pdf:hover > .btn { border-color: #ee3550; background: #ee3550; }
.shared-content-view .resource-ar:hover > .btn { border-color: #9844ca; background: #9844ca; }
.shared-content-view .resource-exercise:hover > .btn { border-color: #00a978; background: #00a978; }
.shared-content-view .school-resource-empty {
  min-height: 170px;
  border: 1px dashed #b7dce9;
  border-radius: 14px;
  background: #f4fcff;
  color: #6691aa;
}

body.theme-dark .shared-content-view .learning-library-hero {
  background: linear-gradient(90deg, rgba(17,45,67,.98), rgba(17,45,67,.82)), url("../images/prisht-dashboard-hero.png") center / cover no-repeat;
  border-color: #315b72;
}
body.theme-dark .shared-content-view .learning-library-copy h1,
body.theme-dark .shared-content-view .learning-library-kicker,
body.theme-dark .shared-content-view .learning-library-copy > p { color: #e3f5ff; }
body.theme-dark .shared-content-view .hero-quick-chapters,
body.theme-dark .shared-content-view .school-chapter-browser,
body.theme-dark .shared-content-view .school-resource-card { background: #142c40; border-color: #2c5269; }

@media (max-width: 1000px) {
  .shared-content-view .learning-library-hero { grid-template-columns: 1fr; padding: 18px 21px; }
  .shared-content-view .hero-quick-chapters { max-width: 620px; }
}

@media (max-width: 700px) {
  #appShell:not(.d-none) .page-content.shared-content-page-shell { padding: 10px; }
  .shared-content-view .learning-library-hero { min-height: auto; padding: 17px; }
  .shared-content-view .learning-library-copy h1 { font-size: 26px; }
  .shared-content-view .learning-library-copy > p { display: block; }
  .shared-content-view .school-library-selectors { grid-template-columns: 1fr; }
  .shared-content-view .school-resource-grid { grid-template-columns: 1fr; }
}

/* Final responsive shell — shared by Admin, School User and Student */
#appShell:not(.d-none) .page-content {
  min-width: 0;
  min-height: 0;
  padding: 8px clamp(10px,1.15vw,18px) 16px;
  overflow-x: hidden;
  overflow-y: auto;
  scroll-padding-bottom: 16px;
}

.prisht-dashboard,
.school-dashboard,
.student-dashboard-page,
.shared-content-view {
  width: min(100%,1560px);
  max-width: 100%;
  margin-inline: auto;
  padding-bottom: 2px;
}

@media (min-width: 901px) {
  #appShell:not(.d-none) .page-content.shared-content-page-shell {
    height: 100%;
    min-height: 0;
    padding: 8px clamp(10px,1.15vw,18px) 14px;
    overflow: hidden;
  }

  .shared-content-view {
    display: grid;
    height: 100%;
    min-height: 0;
    padding: 0;
    grid-template-rows: clamp(160px,22vh,205px) minmax(0,1fr);
    gap: 10px;
  }

  .shared-content-view .learning-library-hero {
    height: 100%;
    min-height: 0;
    padding: clamp(16px,2vh,22px) clamp(20px,2vw,30px);
  }

  .shared-content-view .school-chapter-browser {
    display: flex;
    height: 100%;
    min-height: 0;
    margin: 0;
    padding: 11px 18px 12px;
    overflow: hidden;
    flex-direction: column;
  }

  .shared-content-view .school-chapter-detail {
    display: flex;
    height: 0;
    min-height: 0;
    padding-inline: 2px;
    overflow: hidden;
    flex: 1 1 0;
    flex-direction: column;
  }

  .shared-content-view .school-resource-grid {
    height: 0;
    min-height: 0;
    margin: 0;
    padding: 10px 7px 14px 0;
    overflow-x: hidden;
    overflow-y: auto;
    flex: 1 1 0;
    align-content: start;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }

  .shared-content-view .school-resource-empty {
    min-height: 100%;
  }
}

@media (max-width: 1180px) and (min-width: 901px) {
  .shared-content-view .learning-library-hero {
    grid-template-columns: minmax(0,1.4fr) minmax(235px,.65fr);
  }
  .shared-content-view .hero-quick-chapters { margin-right: 0; }
  .shared-content-view .learning-library-copy h1 { font-size: clamp(27px,3.2vw,37px); }
  .shared-content-view .school-resource-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 900px) {
  #appShell:not(.d-none) .page-content,
  #appShell:not(.d-none) .page-content.shared-content-page-shell,
  #appShell.role-school-user:not(.d-none) .page-content {
    height: auto;
    padding: 8px 10px 18px;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .shared-content-view {
    display: grid;
    height: auto;
    min-height: 0;
    padding: 0;
    grid-template-rows: auto auto;
    gap: 10px;
  }

  .shared-content-view .learning-library-hero {
    min-height: 0;
    padding: 18px 20px;
    grid-template-columns: 1fr;
    gap: 13px;
  }

  .shared-content-view .hero-quick-chapters {
    width: min(100%,620px);
    max-width: 100%;
    margin: 0;
  }

  .shared-content-view .school-chapter-browser {
    height: auto;
    min-height: 0;
    margin: 0;
    padding: 11px 12px 14px;
    overflow: visible;
  }

  .shared-content-view .school-chapter-detail {
    height: auto;
    min-height: 0;
    overflow: visible;
  }

  .shared-content-view .school-resource-grid {
    height: auto;
    min-height: 150px;
    max-height: min(46vh,420px);
    padding: 10px 6px 14px 0;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }
}

@media (max-width: 700px) {
  #appShell:not(.d-none) .page-content,
  #appShell:not(.d-none) .page-content.shared-content-page-shell,
  #appShell.role-school-user:not(.d-none) .page-content { padding: 7px 8px 16px; }

  .shared-content-view .learning-library-hero { padding: 16px; border-radius: 15px; }
  .shared-content-view .learning-library-copy h1 { font-size: clamp(25px,8vw,32px); }
  .shared-content-view .learning-library-stats { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); }
  .shared-content-view .learning-library-stats span { width: 100%; min-width: 0; padding-inline: 7px; }
  .shared-content-view .school-library-selectors { grid-template-columns: 1fr; }
  .shared-content-view .school-chapter-heading { align-items: stretch; flex-direction: column; }
  .shared-content-view .shared-flipbook-action { width: 100%; justify-content: center; }
  .shared-content-view .school-resource-tabs { overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; }
  .shared-content-view .school-resource-tabs::-webkit-scrollbar { display: none; }
  .shared-content-view .school-resource-tabs button { flex: 0 0 auto; }
  .shared-content-view .school-resource-grid { grid-template-columns: 1fr; max-height: 42vh; }
  .shared-content-view .school-resource-card { max-width: none; }
}

@media (max-width: 480px) {
  .shared-content-view .learning-library-stats { grid-template-columns: 1fr; }
  .shared-content-view .hero-quick-chapters { display: none; }
  .shared-content-view .school-resource-card { grid-template-columns: auto minmax(0,1fr); }
  .shared-content-view .school-resource-card > .btn { grid-column: 1 / -1; width: 100%; }
  .school-dashboard > .experience-metric-grid,
  .student-dashboard-page .student-dashboard-metrics,
  .prisht-dashboard .prisht-metrics { grid-template-columns: 1fr; }
}

/* Responsive overflow and bottom-spacing fixes */
#appShell:not(.d-none) .page-content,
#appShell.role-school-user:not(.d-none) .page-content {
  padding-bottom: 26px;
  scroll-padding-bottom: 26px;
}

.school-dashboard,
.student-dashboard-page,
.prisht-dashboard,
.shared-content-view {
  padding-bottom: 22px;
}

#appShell:not(.d-none) .page-content.shared-content-page-shell {
  height: auto;
  min-height: 100%;
  padding-bottom: 26px;
  overflow-x: hidden;
  overflow-y: auto;
}

.shared-content-view {
  height: auto;
  min-height: min-content;
  grid-template-rows: auto auto;
}

.shared-content-view .school-chapter-browser {
  min-height: 0;
  margin-bottom: 4px;
  overflow: visible;
}

.shared-content-view .school-chapter-detail {
  min-height: 0;
  flex: 0 0 auto;
  overflow: visible;
}

.shared-content-view .school-resource-grid {
  flex: 0 0 auto;
  min-height: 0;
  max-height: none;
  margin-right: 0;
  padding: 10px 0 18px;
  overflow: visible;
  overscroll-behavior: auto;
}

.shared-content-view .school-resource-grid::-webkit-scrollbar { display: none; }

.shared-content-view .shared-flipbook-action,
.shared-content-view .school-resource-card > .btn,
.school-dashboard .learning-start-card > .btn,
.school-dashboard .experience-hero-actions .btn,
.student-dashboard-page .student-dashboard-copy > .btn {
  flex: 0 0 auto;
  width: auto;
  max-width: 100%;
  overflow: visible;
  line-height: 1.2;
  white-space: nowrap;
}

.shared-content-view .school-resource-card {
  min-width: 0;
  overflow: visible;
}

.shared-content-view .school-resource-card-body {
  min-width: 0;
}

.shared-content-view .school-resource-card > .btn span,
.shared-content-view .shared-flipbook-action,
.school-dashboard .learning-start-card > .btn {
  text-overflow: clip;
}

.school-dashboard .learning-start-card {
  grid-template-columns: auto minmax(0,1fr) max-content;
  overflow: hidden;
}

.school-dashboard .learning-start-card > .btn {
  min-width: max-content;
  margin-left: 6px;
}

.school-dashboard .quick-access-grid button {
  min-width: 0;
  overflow: visible;
}

.school-dashboard .quick-access-grid button span {
  min-width: 0;
  white-space: normal;
  line-height: 1.25;
}

@media (max-width: 1180px) {
  .school-dashboard .learning-start-card {
    grid-template-columns: auto minmax(0,1fr);
  }

  .school-dashboard .learning-start-card > .btn {
    grid-column: 2;
    justify-self: start;
    margin: 4px 0 0;
  }
}

@media (max-width: 760px) {
  #appShell:not(.d-none) .page-content,
  #appShell.role-school-user:not(.d-none) .page-content,
  #appShell:not(.d-none) .page-content.shared-content-page-shell {
    padding-bottom: 22px;
  }

  .school-dashboard,
  .student-dashboard-page,
  .prisht-dashboard,
  .shared-content-view {
    padding-bottom: 18px;
  }

  .school-dashboard .learning-start-card {
    grid-template-columns: 1fr;
  }

  .school-dashboard .learning-start-card > .btn {
    grid-column: 1;
    width: 100%;
    min-width: 0;
    margin-left: 0;
  }

  .shared-content-view .school-chapter-heading {
    align-items: flex-start;
    gap: 10px;
    flex-wrap: wrap;
  }

  .shared-content-view .shared-flipbook-action {
    width: 100%;
  }
}

/* Desktop Content View: scroll only the active resource list */
@media (min-width: 901px) {
  #appShell:not(.d-none) .page-content.shared-content-page-shell {
    height: 100%;
    min-height: 0;
    padding-bottom: 10px;
    overflow: hidden;
  }

  .shared-content-view {
    display: grid;
    height: 100%;
    min-height: 0;
    padding-bottom: 0;
    grid-template-rows: auto minmax(0, 1fr);
  }

  .shared-content-view .school-chapter-browser {
    display: flex;
    height: 100%;
    max-height: 100%;
    min-height: 0;
    margin-bottom: 0;
    overflow: hidden;
    flex-direction: column;
    box-sizing: border-box;
  }

  .shared-content-view .school-chapter-detail {
    display: flex;
    height: 0;
    max-height: 100%;
    min-height: 0;
    flex: 1 1 0;
    overflow: hidden;
    flex-direction: column;
  }

  .shared-content-view .school-resource-grid {
    height: 0;
    flex: 1 1 0;
    min-height: 0;
    max-height: none;
    margin: 0;
    padding: 10px 7px 20px 0;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    scrollbar-color: #9ec7da transparent;
    scrollbar-width: thin;
    border-radius: 0 0 12px 12px;
    box-sizing: border-box;
    contain: layout paint;
  }

  .shared-content-view .school-resource-card {
    overflow: hidden;
  }

  .shared-content-view .school-resource-grid::-webkit-scrollbar {
    display: block;
    width: 7px;
  }

  .shared-content-view .school-resource-grid::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: #9ec7da;
  }
}

/* School User dashboard */
.school-dashboard {
  width: min(100%, 1390px);
  min-height: 100%;
  margin: 0 auto;
}

.school-dashboard .experience-hero.school {
  position: relative;
  min-height: clamp(174px, 17vw, 220px);
  padding: 23px 30px;
  overflow: hidden;
  border: 1px solid rgba(84, 190, 229, .25);
  border-radius: 20px;
  background:
    linear-gradient(90deg, rgba(241,253,255,.98) 0%, rgba(238,252,255,.93) 39%, rgba(238,252,255,.15) 68%),
    url("../images/prisht-dashboard-hero.png") center / cover no-repeat;
  color: #07376e;
  box-shadow: 0 9px 24px rgba(20, 111, 151, .09);
}

.school-dashboard .experience-hero.school::before {
  content: "Learn  •  Lead  •  Inspire";
  position: absolute;
  left: 48%;
  top: 31px;
  color: #135d99;
  font-family: "Comic Sans MS", cursive;
  font-size: 13px;
  font-weight: 800;
  transform: rotate(-6deg);
}

.school-dashboard .experience-hero.school::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 64px;
  width: 58px;
  height: 18px;
  border-bottom: 2px solid #ff3351;
  border-radius: 50%;
  transform: rotate(-11deg);
}

.school-dashboard .experience-hero-copy { width: 56%; }
.school-dashboard .experience-hero .experience-kicker { color: #15639f; font-size: 10px; font-weight: 950; letter-spacing: 1.8px; opacity: 1; }
.school-dashboard .experience-hero h1 { margin: 8px 0 7px; color: #07366d; font-size: clamp(27px, 2.5vw, 38px); font-weight: 950; line-height: 1.04; letter-spacing: -.7px; }
.school-dashboard .experience-hero p { max-width: 570px; color: #376a8d; font-size: 11px; font-weight: 650; line-height: 1.45; }
.school-dashboard .experience-hero-actions { gap: 9px; margin-top: 15px; }
.school-dashboard .experience-hero-actions .btn { min-height: 39px; padding: 8px 15px; border: 0; border-radius: 10px; font-size: 10px; font-weight: 850; box-shadow: 0 6px 14px rgba(15,65,98,.1); }
.school-dashboard .experience-hero-actions .primary { background: linear-gradient(135deg, #ff173a, #ff3853); color: #fff; }
.school-dashboard .experience-hero-actions .secondary { background: rgba(255,255,255,.94); color: #064779; }
.school-dashboard .experience-hero-visual { display: none; }

.school-dashboard > .experience-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 10px;
  margin: 10px 0;
}

.school-dashboard > .experience-metric-grid .experience-metric {
  min-height: clamp(76px, 7vw, 94px);
  margin: 0;
  padding: 12px 13px;
  border-radius: 16px;
  box-shadow: 0 7px 18px rgba(25,116,158,.055);
}
.school-dashboard > .experience-metric-grid .experience-metric::before { right: auto; bottom: 0; left: 0; top: 0; width: 4px; height: auto; border-radius: 0 5px 5px 0; }
.school-dashboard > .experience-metric-grid .blue { border-color: #bae8ff; background: #effaff; }
.school-dashboard > .experience-metric-grid .violet { border-color: #e4cff7; background: #faf3ff; }
.school-dashboard > .experience-metric-grid .amber { border-color: #ffe1a3; background: #fff9e9; }
.school-dashboard > .experience-metric-grid .green { border-color: #b3f0d8; background: #effdf8; }
.school-dashboard > .experience-metric-grid .experience-metric > span { width: 41px; height: 41px; flex: 0 0 41px; border-radius: 12px; }
.school-dashboard > .experience-metric-grid .blue > span { background: #d7f2ff; color: #009fe5; }
.school-dashboard > .experience-metric-grid .violet > span { background: #f0ddff; color: #a546da; }
.school-dashboard > .experience-metric-grid .amber > span { background: #ffedc7; color: #f39300; }
.school-dashboard > .experience-metric-grid .green > span { background: #d2f7e8; color: #00aa77; }
.school-dashboard > .experience-metric-grid strong { color: #07376c; font-size: 24px; font-weight: 950; }
.school-dashboard > .experience-metric-grid h3 { color: #174f7c; font-size: 10px; }
.school-dashboard > .experience-metric-grid p { color: #7197b1; font-size: 9px; }

.school-dashboard .school-actions-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(250px, .8fr);
  gap: 10px;
}
.school-dashboard .experience-card { border: 1px solid #d6eaf4; border-radius: 17px; background: rgba(255,255,255,.95); box-shadow: 0 7px 18px rgba(24,111,153,.06); }
.school-dashboard .learning-start-card { min-height: 157px; gap: 14px; padding: 18px; background: linear-gradient(135deg, #fff 0%, #f3fcff 58%, #effbf7 100%); }
.school-dashboard .learning-start-card:hover { border-color: #91dced; box-shadow: 0 10px 24px rgba(17,117,153,.1); }
.school-dashboard .learning-start-icon { width: 52px; height: 52px; background: linear-gradient(135deg, #d8f5ff, #d6f8eb); color: #009dd7; }
.school-dashboard .learning-start-card .experience-kicker { color: #ff3150; font-size: 9px; }
.school-dashboard .learning-start-content h2 { color: #07386c; font-size: 17px; }
.school-dashboard .learning-start-content > p { color: #6d94ae; font-size: 10px; }
.school-dashboard .learning-start-features span { border-color: #d7ebf3; background: #f7fdff; color: #2a678e; }
.school-dashboard .learning-start-content > small { color: #6191ad; }
.school-dashboard .learning-start-card > .btn { border: 0; border-radius: 10px; background: linear-gradient(135deg, #008fd1, #04b6d6); font-size: 10px; font-weight: 850; box-shadow: 0 6px 14px rgba(0,148,199,.18); }
.school-dashboard .quick-access-card > header { padding: 14px 14px 9px; }
.school-dashboard .quick-access-card > header > span { background: #fff0d2; color: #ff9a00; }
.school-dashboard .quick-access-card h2 { color: #07386c; }
.school-dashboard .quick-access-card p { color: #7ca1b9; font-size: 9px; }
.school-dashboard .quick-access-grid { grid-template-columns: 1fr; gap: 3px; padding: 0 13px 12px; }
.school-dashboard .quick-access-grid button { min-height: 34px; padding: 4px 7px; border: 0; border-bottom: 1px solid #dceef5; border-radius: 0; background: transparent; color: #18517d; font-size: 9px; box-shadow: none; }
.school-dashboard .quick-access-grid button:last-child { border-bottom: 0; }
.school-dashboard .quick-access-grid button i { width: 24px; height: 24px; border-radius: 7px; background: #e2f7ff; color: #0099d6; }
.school-dashboard .quick-access-grid button:nth-child(2) i { background: #f2e7ff; color: #a044d4; }
.school-dashboard .quick-access-grid button:nth-child(3) i { background: #dff8ed; color: #00aa77; }
.school-dashboard .quick-access-grid button::after { content: "›"; margin-left: auto; color: #1688bd; font-size: 15px; }
.school-dashboard .quick-access-grid button:hover { background: #f1fbff; color: #008ecb; transform: none; }

.school-dashboard .course-assignment-empty { min-height: 180px; margin-top: 10px; padding: 24px; border-style: dashed; background: linear-gradient(135deg,#fff,#f3fbff); }
.school-dashboard .course-assignment-icon { background: #e1f6ff; color: #0097d5; }

/* Student dashboard */
.student-dashboard-page {
  width: min(100%, 1390px);
  min-height: 100%;
  margin: 0 auto;
  gap: 10px;
}

.student-dashboard-page .student-dashboard-hero {
  min-height: clamp(185px, 18vw, 228px);
  padding: 24px 30px;
  border: 1px solid rgba(84,190,229,.25);
  border-radius: 20px;
  background:
    linear-gradient(90deg, rgba(241,253,255,.98) 0%, rgba(239,252,255,.92) 40%, rgba(238,252,255,.12) 70%),
    url("../images/prisht-dashboard-hero.png") center / cover no-repeat;
  color: #07376e;
  box-shadow: 0 9px 24px rgba(20,111,151,.09);
}

.student-dashboard-page .student-dashboard-hero::before {
  content: "Explore  •  Practise  •  Grow";
  top: 34px;
  right: 35%;
  width: auto;
  height: auto;
  border-radius: 0;
  background: transparent;
  color: #0d5b97;
  font-family: "Comic Sans MS", cursive;
  font-size: 13px;
  font-weight: 800;
  transform: rotate(-7deg);
}
.student-dashboard-page .student-dashboard-hero::after { right: -50px; bottom: -120px; background: rgba(29,193,218,.12); }
.student-dashboard-page .student-dashboard-copy { width: 58%; }
.student-dashboard-page .student-dashboard-kicker { color: #15649f; font-size: 10px; letter-spacing: 1.7px; }
.student-dashboard-page .student-dashboard-kicker i { color: #ff3150; }
.student-dashboard-page .student-dashboard-copy h1 { color: #07366d; font-size: clamp(27px,2.6vw,39px); font-weight: 950; line-height: 1.04; }
.student-dashboard-page .student-dashboard-copy > p { max-width: 540px; margin: 7px 0 12px; color: #376b8d; font-size: 11px; font-weight: 650; }
.student-dashboard-page .student-assignment-pill { border-color: #c6e6f2; background: rgba(255,255,255,.82); color: #29658d; box-shadow: 0 4px 11px rgba(15,105,145,.05); }
.student-dashboard-page .student-assignment-pill b { color: #a8cad9; }
.student-dashboard-page .student-dashboard-copy > .btn { min-height: 39px; margin-top: 13px; padding: 8px 15px; border-radius: 10px; background: linear-gradient(135deg,#ff183b,#ff3f58); color: #fff; font-size: 10px; box-shadow: 0 7px 16px rgba(255,31,61,.18); }
.student-dashboard-page .student-dashboard-copy > .btn:hover { background: linear-gradient(135deg,#ed1031,#ff304d); box-shadow: 0 9px 19px rgba(255,31,61,.24); }
.student-dashboard-page .student-dashboard-visual { display: none; }

.student-dashboard-page .student-dashboard-metrics { gap: 10px; }
.student-dashboard-page .student-metric { min-height: clamp(76px,7vw,94px); padding: 12px 13px; border-radius: 16px; box-shadow: 0 7px 18px rgba(25,116,158,.055); }
.student-dashboard-page .student-metric::before { top: 0; right: auto; bottom: 0; left: 0; width: 4px; height: auto; border-radius: 0 5px 5px 0; }
.student-dashboard-page .student-metric.blue { border-color: #bae8ff; background: #effaff; }
.student-dashboard-page .student-metric.violet { border-color: #e4cff7; background: #faf3ff; }
.student-dashboard-page .student-metric.rose { border-color: #ffcbd5; background: #fff3f5; }
.student-dashboard-page .student-metric.green { border-color: #b3f0d8; background: #effdf8; }
.student-dashboard-page .student-metric > span { width: 41px; height: 41px; border-radius: 12px; }
.student-dashboard-page .student-metric.blue > span { background: #d7f2ff; color: #009fe5; }
.student-dashboard-page .student-metric.violet > span { background: #f0ddff; color: #a546da; }
.student-dashboard-page .student-metric.rose > span { background: #ffe0e6; color: #ff405b; }
.student-dashboard-page .student-metric.green > span { background: #d2f7e8; color: #00aa77; }
.student-dashboard-page .student-metric strong { color: #07376c; font-size: 24px; }
.student-dashboard-page .student-metric h3 { color: #174f7c; font-size: 10px; }
.student-dashboard-page .student-metric p { color: #7197b1; font-size: 9px; }

.student-dashboard-page .student-dashboard-grid { grid-template-columns: minmax(0,2fr) minmax(250px,.8fr); gap: 10px; }
.student-dashboard-page .student-dashboard-card { padding: 15px; border: 1px solid #d6eaf4; border-radius: 17px; background: rgba(255,255,255,.95); box-shadow: 0 7px 18px rgba(24,111,153,.06); }
.student-dashboard-page .student-subject-panel > header { padding-bottom: 11px; border-bottom-color: #dceef5; }
.student-dashboard-page .student-card-icon { background: #dff6ff; color: #0099d7; }
.student-dashboard-page .student-subject-panel h2,
.student-dashboard-page .student-help-card h2 { color: #07386c; font-size: 13px; }
.student-dashboard-page .student-subject-panel p,
.student-dashboard-page .student-help-card p { color: #7a9fb7; font-size: 9px; }
.student-dashboard-page .link-button { color: #008fcf; }
.student-dashboard-page .student-subject-grid { gap: 8px; max-height: 220px; padding-top: 11px; }
.student-dashboard-page .student-subject-card { min-height: 61px; padding: 9px 10px; border-color: #d9ebf3; background: #f9fdff; }
.student-dashboard-page .student-subject-card:hover { border-color: #91dced; background: #f1fbff; color: #008ecb; box-shadow: 0 7px 15px rgba(15,110,150,.08); }
.student-dashboard-page .student-subject-card > span { width: 37px; height: 37px; border-radius: 10px; background: #dff6ff; color: #0098d7; }
.student-dashboard-page .student-subject-card.tone-1 > span { background: #f0e4ff; color: #a344d7; }
.student-dashboard-page .student-subject-card.tone-2 > span { background: #fff0cb; color: #ed9200; }
.student-dashboard-page .student-subject-card.tone-3 > span { background: #dff8ed; color: #00a978; }
.student-dashboard-page .student-subject-card strong { color: #174f7c; font-size: 10px; }
.student-dashboard-page .student-subject-card small { color: #80a1b6; font-size: 9px; }
.student-dashboard-page .student-help-card { background: linear-gradient(145deg,#fff 0%,#f2fcff 56%,#f0fcf8 100%); }
.student-dashboard-page .student-help-icon { margin-bottom: 9px; background: #fff0c9; color: #f09500; }
.student-dashboard-page .student-help-card ol { gap: 7px; margin: 12px 0; }
.student-dashboard-page .student-help-card li { color: #44708f; font-size: 9px; }
.student-dashboard-page .student-help-card li b { width: 22px; height: 22px; border-radius: 7px; background: #dff6ff; color: #0095d2; }
.student-dashboard-page .student-help-card > .btn { min-height: 36px; border-radius: 9px; background: linear-gradient(100deg,#008fd1,#05b7b4); box-shadow: 0 7px 16px rgba(0,143,184,.16); }

body.theme-dark .school-dashboard .experience-hero.school,
body.theme-dark .student-dashboard-page .student-dashboard-hero { background: linear-gradient(90deg,rgba(17,45,67,.98),rgba(17,45,67,.8)),url("../images/prisht-dashboard-hero.png") center/cover no-repeat; border-color: #315b72; }
body.theme-dark .school-dashboard .experience-hero :is(h1,p,.experience-kicker),
body.theme-dark .student-dashboard-page .student-dashboard-hero :is(h1,p,.student-dashboard-kicker) { color: #e4f6ff; }

@media (max-width: 980px) {
  .school-dashboard > .experience-metric-grid,
  .student-dashboard-page .student-dashboard-metrics { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .school-dashboard .school-actions-grid,
  .student-dashboard-page .student-dashboard-grid { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  .school-dashboard .experience-hero.school,
  .student-dashboard-page .student-dashboard-hero { min-height: 245px; padding: 21px; background-position: 65% center; }
  .school-dashboard .experience-hero.school::before,
  .school-dashboard .experience-hero.school::after,
  .student-dashboard-page .student-dashboard-hero::before { display: none; }
  .school-dashboard .experience-hero-copy,
  .student-dashboard-page .student-dashboard-copy { width: 100%; }
  .school-dashboard > .experience-metric-grid,
  .student-dashboard-page .student-dashboard-metrics { grid-template-columns: 1fr; }
  .school-dashboard .learning-start-card { grid-template-columns: 1fr; }
  .school-dashboard .learning-start-card > .btn { width: 100%; }
}

/* Exact School User reference shell */
#appShell.role-school-user:not(.d-none) {
  grid-template-columns: clamp(220px, 15vw, 276px) minmax(0, 1fr);
  grid-template-rows: 70px minmax(0, 1fr);
  background: linear-gradient(135deg, #f7fcff 0%, #eaf8ff 72%, #f6fcff 100%);
}

#appShell.role-school-user:not(.d-none) .topbar {
  grid-column: 2;
  height: 70px;
  padding: 0 24px;
  border-bottom: 1px solid #d9eaf4;
  background: rgba(255,255,255,.95);
  box-shadow: 0 4px 16px rgba(8,67,108,.055);
}

#appShell.role-school-user:not(.d-none) .sidebar {
  width: auto;
  padding: 9px 10px 12px;
  border: 0;
  background:
    radial-gradient(circle at 95% 72%, rgba(0,126,219,.32), transparent 29%),
    linear-gradient(180deg, #062f62 0%, #023c78 62%, #04528c 100%);
  box-shadow: 6px 0 26px rgba(2,47,98,.14);
}

#appShell.role-school-user .sidebar-brand {
  min-height: 76px;
  gap: 12px;
  padding: 6px 13px 10px;
  color: #fff;
}
#appShell.role-school-user .sidebar-brand img {
  width: 66px;
  height: 62px;
  flex: 0 0 66px;
  padding: 4px;
  border-radius: 12px;
  background: #fff;
  mix-blend-mode: normal;
  box-shadow: 0 5px 14px rgba(0,21,49,.2);
}
#appShell.role-school-user .sidebar-brand span { display: block; min-width: 0; }
#appShell.role-school-user .sidebar-brand b { overflow: hidden; color: #fff; font-size: 17px; line-height: 1.12; text-overflow: ellipsis; }
#appShell.role-school-user .sidebar-brand small { margin-top: 5px; color: #18d5ff; font-size: 8px; }

#appShell.role-school-user #sidebarNav { padding-right: 2px; scrollbar-color: rgba(255,255,255,.26) transparent; }
#appShell.role-school-user .nav-section { padding: 18px 15px 7px; color: #9fbcd8; font-size: 12px; letter-spacing: .5px; }
#appShell.role-school-user .side-link {
  min-height: 51px;
  gap: 13px;
  margin: 2px 0;
  padding: 10px 16px;
  border-radius: 12px;
  color: #eef8ff;
  font-size: 14px;
  font-weight: 750;
}
#appShell.role-school-user .side-link i { width: 28px; height: 28px; color: #fff; font-size: 20px; }
#appShell.role-school-user .side-link:hover { background: rgba(20,122,222,.34); color: #fff; }
#appShell.role-school-user .side-link.active {
  background: linear-gradient(115deg, #078ad9, #1267f1);
  color: #fff;
  box-shadow: 0 8px 18px rgba(0,38,105,.25);
}
#appShell.role-school-user .side-link.active::before { left: -10px; top: 4px; bottom: 4px; width: 4px; background: #51eaff; }
#appShell.role-school-user .side-link.active i { background: transparent; color: #fff; }

#appShell.role-school-user .sidebar-motto {
  position: relative;
  display: flex;
  align-items: flex-start;
  min-height: 255px;
  margin: 10px 0 0;
  padding: 48px 25px 12px;
  overflow: hidden;
  border-radius: 110px 0 0 0;
  background:
    linear-gradient(180deg, rgba(2,48,100,.32), rgba(3,58,111,.35)),
    url("../images/school-dashboard-hero.png") 78% bottom / auto 60% no-repeat;
  color: #fff;
}
#appShell.role-school-user .sidebar-motto::after { content: "Better\A Education\A Brighter\A Futures"; white-space: pre; color: #fff; font-family: "Comic Sans MS", cursive; font-size: 20px; font-weight: 700; line-height: 1.22; transform: rotate(-8deg); text-shadow: 0 2px 5px rgba(0,24,60,.28); }
#appShell.role-school-user .sidebar-motto::before { content: ""; position: absolute; top: 161px; left: 35px; width: 78px; border-bottom: 4px solid #ffd51b; transform: rotate(-10deg); }
#appShell.role-school-user .sidebar-motto > * { display: none; }

#appShell.role-school-user:not(.d-none) .page-content { padding: 8px 20px 0; }

#appShell.role-school-user .school-dashboard .experience-hero.school {
  height: clamp(245px, 18vw, 300px);
  min-height: 0;
  padding: 30px 34px;
  border-color: #1c7dc4;
  border-radius: 20px;
  background:
    linear-gradient(90deg, rgba(3,42,99,.96) 0%, rgba(3,63,136,.68) 40%, rgba(4,65,124,.05) 61%),
    url("../images/school-dashboard-hero.png") center / cover no-repeat;
  box-shadow: 0 11px 27px rgba(3,64,118,.14);
}
#appShell.role-school-user .school-dashboard .experience-hero.school::before { content: "Teach\A Inspire\A Grow"; white-space: pre; left: 51%; top: 40px; color: #fff; font-size: clamp(17px,1.45vw,25px); line-height: 1.25; text-shadow: 0 2px 4px rgba(0,0,0,.18); }
#appShell.role-school-user .school-dashboard .experience-hero.school::after { left: 52%; top: 139px; width: 73px; border-bottom-width: 4px; border-bottom-color: #ffd329; }
#appShell.role-school-user .school-dashboard .experience-hero-copy { display: flex; flex-direction: column; justify-content: center; width: 50%; height: 100%; }
#appShell.role-school-user .school-dashboard .experience-hero .experience-kicker { display: none; }
#appShell.role-school-user .school-dashboard .experience-hero h1 { margin: 0 0 10px; color: #fff; font-size: clamp(36px,3vw,55px); line-height: 1.02; }
#appShell.role-school-user .school-dashboard .experience-hero h1 small { display: block; margin-bottom: 8px; color: #fff; font-size: .58em; font-weight: 800; letter-spacing: 0; }
#appShell.role-school-user .school-dashboard .experience-hero h1 span { display: block; overflow: hidden; color: #17d3f3; text-overflow: ellipsis; white-space: nowrap; }
#appShell.role-school-user .school-dashboard .experience-hero p { max-width: 580px; margin: 0; color: rgba(255,255,255,.92); font-size: 14px; line-height: 1.4; }
#appShell.role-school-user .school-dashboard .experience-hero-actions { margin-top: 18px; }
#appShell.role-school-user .school-dashboard .experience-hero-actions .btn { min-height: 48px; padding: 10px 20px; border-radius: 11px; font-size: 13px; }
#appShell.role-school-user .school-dashboard .experience-hero-actions .primary { background: linear-gradient(135deg,#ff5b0a,#ff3814); box-shadow: 0 8px 17px rgba(167,41,0,.22); }
#appShell.role-school-user .school-dashboard .experience-hero-actions .secondary { color: #084888; }

#appShell.role-school-user .school-dashboard > .school-metrics {
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 12px;
  margin: 14px 0;
}
#appShell.role-school-user .school-dashboard > .school-metrics .experience-metric {
  min-height: clamp(108px, 8vw, 134px);
  padding: 18px 30px;
  gap: 20px;
  border-width: 1px 1px 1px 4px;
  border-radius: 18px;
  box-shadow: 0 8px 20px rgba(9,72,114,.07);
}
#appShell.role-school-user .school-dashboard > .school-metrics .experience-metric::before { display: none; }
#appShell.role-school-user .school-dashboard > .school-metrics .experience-metric > span { width: 58px; height: 58px; flex-basis: 58px; border-radius: 15px; font-size: 27px; box-shadow: 0 7px 15px rgba(12,87,157,.14); }
#appShell.role-school-user .school-dashboard > .school-metrics strong { font-size: 34px; }
#appShell.role-school-user .school-dashboard > .school-metrics h3 { margin-top: 4px; font-size: 13px; white-space: nowrap; }
#appShell.role-school-user .school-dashboard > .school-metrics p { margin-top: 4px; font-size: 11px; white-space: nowrap; }
#appShell.role-school-user .metric-role-arrow { position: absolute; right: 18px; display: grid; place-items: center; width: 42px; height: 42px; padding: 0; border: 0; border-radius: 50%; background: rgba(255,255,255,.92); color: #0867e9; font-size: 21px; box-shadow: 0 5px 12px rgba(10,70,116,.06); }
#appShell.role-school-user .school-metrics .violet .metric-role-arrow { color: #862feb; }
#appShell.role-school-user .school-metrics .amber .metric-role-arrow { color: #ff650e; }
#appShell.role-school-user .school-metrics .green .metric-role-arrow { color: #087c89; }

#appShell.role-school-user .school-dashboard .school-actions-grid { grid-template-columns: minmax(0,2.55fr) minmax(340px,1fr); gap: 14px; }
#appShell.role-school-user .school-dashboard .learning-start-card { position: relative; min-height: 278px; padding: 42px 32px; overflow: hidden; border-radius: 20px; background: radial-gradient(circle at 1px 1px,#c8e6f6 1.3px,transparent 1.5px) 0 0/13px 13px,linear-gradient(135deg,#fff 0%,#f2fbff 70%,#ddecff 100%); }
#appShell.role-school-user .school-dashboard .learning-start-card::after { content: ""; position: absolute; right: -40px; bottom: -80px; width: 430px; height: 210px; border-radius: 70% 0 0 0; background: radial-gradient(ellipse at center,#fff 0 35%,#cee5ff 36% 39%,#fff 40% 52%,#b7d6f9 53% 56%,transparent 57%); opacity: .85; transform: rotate(-8deg); }
#appShell.role-school-user .school-dashboard .learning-start-icon { position: relative; z-index: 1; width: 80px; height: 80px; border-radius: 18px; background: linear-gradient(135deg,#d7ecff,#edf8ff); color: #096bf0; font-size: 39px; }
#appShell.role-school-user .school-dashboard .learning-start-content { position: relative; z-index: 1; }
#appShell.role-school-user .school-dashboard .learning-start-card .experience-kicker { color: #096bf0; font-size: 12px; letter-spacing: 1.2px; }
#appShell.role-school-user .school-dashboard .learning-start-content h2 { margin-top: 6px; font-size: 24px; }
#appShell.role-school-user .school-dashboard .learning-start-content > p { font-size: 12px; }
#appShell.role-school-user .school-dashboard .learning-start-features { gap: 8px; margin-top: 15px; }
#appShell.role-school-user .school-dashboard .learning-start-features span { padding: 7px 12px; border-radius: 999px; background: #fff; font-size: 11px; box-shadow: 0 3px 9px rgba(20,90,130,.05); }
#appShell.role-school-user .school-dashboard .learning-start-content > small { margin-top: 15px; color: #497694; font-size: 11px; }
#appShell.role-school-user .school-dashboard .learning-start-content > small i { color: #ff5b0a; }
#appShell.role-school-user .school-dashboard .learning-start-card > .btn { position: relative; z-index: 2; min-width: 145px; min-height: 48px; padding: 10px 18px; background: #0868ee; font-size: 12px; }
#appShell.role-school-user .school-dashboard .quick-access-card { min-height: 278px; padding: 0 10px; border-radius: 20px; }
#appShell.role-school-user .school-dashboard .quick-access-card > header { padding: 22px 10px 13px; }
#appShell.role-school-user .school-dashboard .quick-access-card > header > span { width: 50px; height: 50px; border-radius: 14px; background: #fff1a9; color: #ff5b0a; font-size: 25px; }
#appShell.role-school-user .school-dashboard .quick-access-card h2 { font-size: 16px; }
#appShell.role-school-user .school-dashboard .quick-access-card p { font-size: 10px; }
#appShell.role-school-user .school-dashboard .quick-access-grid { gap: 8px; padding: 0 2px 15px; }
#appShell.role-school-user .school-dashboard .quick-access-grid button { min-height: 49px; padding: 7px 13px; border: 1px solid #d9e7ef; border-radius: 12px; background: #fff; font-size: 11px; box-shadow: 0 3px 9px rgba(11,76,117,.04); }
#appShell.role-school-user .school-dashboard .quick-access-grid button i { width: 34px; height: 34px; border-radius: 10px; font-size: 17px; }

@media (max-width: 1250px) {
  #appShell.role-school-user:not(.d-none) { grid-template-columns: 210px minmax(0,1fr); }
  #appShell.role-school-user .sidebar-brand img { width: 56px; height: 54px; flex-basis: 56px; }
  #appShell.role-school-user .sidebar-brand b { font-size: 14px; }
  #appShell.role-school-user .school-dashboard .experience-hero.school::before,
  #appShell.role-school-user .school-dashboard .experience-hero.school::after { display: none; }
  #appShell.role-school-user .school-dashboard > .school-metrics .experience-metric { padding: 15px; gap: 11px; }
  #appShell.role-school-user .school-dashboard > .school-metrics .experience-metric > span { width: 48px; height: 48px; flex-basis: 48px; }
  #appShell.role-school-user .metric-role-arrow { display: none; }
}

@media (max-width: 980px) {
  #appShell.role-school-user:not(.d-none) { grid-template-columns: 78px minmax(0,1fr); }
  #appShell.role-school-user .sidebar-brand span,
  #appShell.role-school-user .sidebar-motto,
  #appShell.role-school-user .nav-section { display: none; }
  #appShell.role-school-user .sidebar-brand { justify-content: center; padding-inline: 0; }
  #appShell.role-school-user .sidebar-brand img { width: 58px; height: 54px; flex-basis: 58px; }
  #appShell.role-school-user .side-link { justify-content: center; padding-inline: 8px; }
  #appShell.role-school-user .side-link .link-text { display: none; }
  #appShell.role-school-user .school-dashboard > .school-metrics { grid-template-columns: repeat(2,minmax(0,1fr)); }
  #appShell.role-school-user .school-dashboard .school-actions-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  #appShell.role-school-user:not(.d-none) { grid-template-columns: 0 minmax(0,1fr); grid-template-rows: 58px minmax(0,1fr); }
  #appShell.role-school-user:not(.d-none) .topbar { height: 58px; padding: 0 10px; }
  #appShell.role-school-user:not(.d-none) .sidebar { width: 220px; }
  #appShell.role-school-user.sidebar-hidden:not(.d-none) .sidebar { width: 220px; }
  #appShell.role-school-user .sidebar-brand span,
  #appShell.role-school-user .nav-section { display: block; }
  #appShell.role-school-user .side-link { justify-content: flex-start; padding-inline: 16px; }
  #appShell.role-school-user .side-link .link-text { display: inline; }
  #appShell.role-school-user:not(.d-none) .page-content { padding: 9px; }
  #appShell.role-school-user .school-dashboard .experience-hero.school { height: 280px; padding: 22px; background-position: 63% center; }
  #appShell.role-school-user .school-dashboard .experience-hero-copy { width: 100%; }
  #appShell.role-school-user .school-dashboard .experience-hero h1 span { white-space: normal; }
  #appShell.role-school-user .school-dashboard .experience-hero p { font-size: 11px; }
  #appShell.role-school-user .school-dashboard .experience-hero-actions { align-items: stretch; flex-direction: column; width: 210px; }
  #appShell.role-school-user .school-dashboard > .school-metrics { grid-template-columns: 1fr; }
  #appShell.role-school-user .school-dashboard .learning-start-card { grid-template-columns: 1fr; min-height: auto; padding: 25px; }
  #appShell.role-school-user .school-dashboard .learning-start-card > .btn { width: 100%; }
}

/* School User: preserve the original scale and copy; apply colors only */
#appShell.role-school-user:not(.d-none) {
  grid-template-columns: clamp(138px, 14.2vw, 220px) minmax(0, 1fr);
  grid-template-rows: 62px minmax(0, 1fr);
}
#appShell.role-school-user:not(.d-none) .topbar { height: 62px; padding: 0 20px; }
#appShell.role-school-user:not(.d-none) .sidebar { padding: 8px 7px 12px; }
#appShell.role-school-user .sidebar-brand { min-height: 68px; gap: 8px; padding: 7px 12px; }
#appShell.role-school-user .sidebar-brand img { width: 62px; height: 48px; flex: 0 0 62px; padding: 3px; border-radius: 10px; }
#appShell.role-school-user .sidebar-brand b { font-size: 15px; }
#appShell.role-school-user .sidebar-brand small { margin-top: 3px; font-size: 8px; }
#appShell.role-school-user .nav-section { padding: 12px 11px 5px; font-size: 9px; }
#appShell.role-school-user .side-link { min-height: 36px; gap: 10px; margin: 1px 0; padding: 7px 12px; border-radius: 9px; font-size: 11px; }
#appShell.role-school-user .side-link i { width: 20px; height: 20px; font-size: 13px; }
#appShell.role-school-user .sidebar-motto { min-height: 58px; margin: 10px 7px 0; padding: 10px; border-radius: 14px; background: rgba(6,112,180,.34); }
#appShell.role-school-user .sidebar-motto::before,
#appShell.role-school-user .sidebar-motto::after { display: none; }
#appShell.role-school-user .sidebar-motto > * { display: flex; }
#appShell.role-school-user .sidebar-motto span { display: grid; }
#appShell.role-school-user .sidebar-motto b { color: #fff; font-size: 9px; }
#appShell.role-school-user .sidebar-motto small { color: #8dddf5; font-size: 7px; }
#appShell.role-school-user:not(.d-none) .page-content { padding: 10px 16px 0; }

#appShell.role-school-user .school-dashboard .experience-hero.school {
  height: auto;
  min-height: clamp(174px, 17vw, 220px);
  padding: 23px 30px;
  background:
    linear-gradient(90deg, rgba(3,42,99,.95) 0%, rgba(3,63,136,.67) 41%, rgba(4,65,124,.05) 69%),
    url("../images/school-dashboard-hero.png") center / cover no-repeat;
}
#appShell.role-school-user .school-dashboard .experience-hero.school::before,
#appShell.role-school-user .school-dashboard .experience-hero.school::after { display: none; content: none; }
#appShell.role-school-user .school-dashboard .experience-hero-copy { width: 56%; height: auto; }
#appShell.role-school-user .school-dashboard .experience-hero .experience-kicker { display: inline-flex; color: #9ae8ff; font-size: 10px; }
#appShell.role-school-user .school-dashboard .experience-hero h1 { margin: 8px 0 7px; color: #fff; font-size: clamp(27px,2.5vw,38px); line-height: 1.04; }
#appShell.role-school-user .school-dashboard .experience-hero p { color: rgba(255,255,255,.9); font-size: 11px; }
#appShell.role-school-user .school-dashboard .experience-hero-actions { margin-top: 15px; }
#appShell.role-school-user .school-dashboard .experience-hero-actions .btn { min-height: 39px; padding: 8px 15px; border-radius: 10px; font-size: 10px; }

#appShell.role-school-user .school-dashboard > .experience-metric-grid { grid-template-columns: repeat(4,minmax(0,1fr)); gap: 10px; margin: 10px 0; }
#appShell.role-school-user .school-dashboard > .experience-metric-grid .experience-metric { min-height: clamp(76px,7vw,94px); padding: 12px 13px; gap: 13px; border-width: 1px; border-left-width: 4px; border-radius: 16px; }
#appShell.role-school-user .school-dashboard > .experience-metric-grid .experience-metric > span { width: 41px; height: 41px; flex-basis: 41px; border-radius: 12px; font-size: 19px; box-shadow: none; }
#appShell.role-school-user .school-dashboard > .experience-metric-grid strong { font-size: 24px; }
#appShell.role-school-user .school-dashboard > .experience-metric-grid h3 { margin-top: 4px; font-size: 10px; }
#appShell.role-school-user .school-dashboard > .experience-metric-grid p { margin-top: 2px; font-size: 9px; }

#appShell.role-school-user .school-dashboard .school-actions-grid { grid-template-columns: minmax(0,2fr) minmax(250px,.8fr); gap: 10px; }
#appShell.role-school-user .school-dashboard .learning-start-card { min-height: 157px; padding: 18px; gap: 14px; }
#appShell.role-school-user .school-dashboard .learning-start-card::after { width: 260px; height: 130px; right: -30px; bottom: -55px; }
#appShell.role-school-user .school-dashboard .learning-start-icon { width: 52px; height: 52px; border-radius: 15px; font-size: 24px; }
#appShell.role-school-user .school-dashboard .learning-start-card .experience-kicker { font-size: 9px; }
#appShell.role-school-user .school-dashboard .learning-start-content h2 { margin: 4px 0 5px; font-size: 17px; }
#appShell.role-school-user .school-dashboard .learning-start-content > p { font-size: 10px; }
#appShell.role-school-user .school-dashboard .learning-start-features { margin-top: 10px; }
#appShell.role-school-user .school-dashboard .learning-start-features span { padding: 5px 9px; font-size: 9px; }
#appShell.role-school-user .school-dashboard .learning-start-content > small { margin-top: 9px; font-size: 9px; }
#appShell.role-school-user .school-dashboard .learning-start-card > .btn { min-width: 0; min-height: 39px; padding: 8px 12px; font-size: 10px; }
#appShell.role-school-user .school-dashboard .quick-access-card { min-height: 157px; padding: 0; }
#appShell.role-school-user .school-dashboard .quick-access-card > header { padding: 14px 14px 9px; }
#appShell.role-school-user .school-dashboard .quick-access-card > header > span { width: 34px; height: 34px; border-radius: 11px; font-size: 17px; }
#appShell.role-school-user .school-dashboard .quick-access-card h2 { font-size: 13px; }
#appShell.role-school-user .school-dashboard .quick-access-card p { font-size: 9px; }
#appShell.role-school-user .school-dashboard .quick-access-grid { gap: 3px; padding: 0 13px 12px; }
#appShell.role-school-user .school-dashboard .quick-access-grid button { min-height: 34px; padding: 4px 7px; border: 0; border-bottom: 1px solid #dceef5; border-radius: 0; background: transparent; font-size: 9px; box-shadow: none; }
#appShell.role-school-user .school-dashboard .quick-access-grid button i { width: 24px; height: 24px; border-radius: 7px; font-size: 11px; }

@media (max-width: 980px) {
  #appShell.role-school-user:not(.d-none) { grid-template-columns: 78px minmax(0,1fr); }
  #appShell.role-school-user .school-dashboard > .experience-metric-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  #appShell.role-school-user .school-dashboard .school-actions-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  #appShell.role-school-user:not(.d-none) { grid-template-columns: 0 minmax(0,1fr); grid-template-rows: 58px minmax(0,1fr); }
  #appShell.role-school-user:not(.d-none) .topbar { height: 58px; }
  #appShell.role-school-user .school-dashboard .experience-hero.school { min-height: 245px; padding: 21px; }
  #appShell.role-school-user .school-dashboard .experience-hero-copy { width: 100%; }
  #appShell.role-school-user .school-dashboard > .experience-metric-grid { grid-template-columns: 1fr; }
  #appShell.role-school-user .school-dashboard .learning-start-card { grid-template-columns: 1fr; min-height: auto; padding: 18px; }
}

/* Shared Content View — Admin, School User and Student */
#appShell:not(.d-none) .page-content.shared-content-page-shell {
  padding: 10px 16px 0;
}

.shared-content-view {
  width: min(100%, 1560px);
  gap: 12px;
}

.shared-content-view .learning-library-hero {
  grid-template-columns: minmax(0,1.5fr) minmax(300px,.55fr);
  min-height: clamp(195px, 16vw, 238px);
  padding: 24px 30px;
  border: 1px solid #3179bc;
  border-radius: 18px;
  background:
    linear-gradient(90deg, rgba(3,37,88,.97) 0%, rgba(4,67,151,.76) 39%, rgba(15,76,145,.08) 67%),
    url("../images/content-library-hero.png") center / cover no-repeat;
  color: #fff;
  box-shadow: 0 10px 26px rgba(6,67,116,.14);
}

.shared-content-view .learning-library-hero::before {
  top: -176px;
  left: 31%;
  width: 300px;
  height: 300px;
  background: rgba(117,155,255,.15);
}

.shared-content-view .learning-library-hero::after {
  content: "Teach\A Inspire\A Grow";
  right: 20px;
  bottom: auto;
  top: 37px;
  width: auto;
  height: auto;
  white-space: pre;
  border-radius: 0;
  background: transparent;
  color: #fff;
  font-family: "Comic Sans MS", cursive;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
  text-shadow: 0 2px 5px rgba(2,35,66,.3);
  transform: rotate(-6deg);
}

.shared-content-view .learning-library-copy { align-self: center; max-width: 760px; }
.shared-content-view .learning-library-kicker { color: #fff; font-size: 10px; letter-spacing: 1.5px; }
.shared-content-view .learning-library-kicker i { color: #ff4b60; }
.shared-content-view .learning-library-copy h1 { color: #fff; font-size: clamp(29px,2.8vw,45px); line-height: 1.03; }
.shared-content-view .learning-library-copy h1 span { color: #18d5f3; }
.shared-content-view .learning-library-copy h1::first-letter { color: inherit; }
.shared-content-view .learning-library-copy > p { max-width: 720px; margin: 10px 0 16px; color: rgba(255,255,255,.92); font-size: 12px; }
.shared-content-view .learning-library-stats { gap: 9px; }
.shared-content-view .learning-library-stats span {
  min-width: 125px;
  padding: 7px 14px;
  border-color: rgba(255,255,255,.44);
  background: rgba(8,56,116,.28);
  color: #fff;
  font-size: 11px;
  box-shadow: none;
}
.shared-content-view .learning-library-stats strong { color: #fff; }

.shared-content-view .hero-quick-chapters {
  align-self: center;
  margin-right: 65px;
  padding: 13px 15px;
  border-color: rgba(255,255,255,.64);
  border-radius: 15px;
  background: rgba(245,251,255,.88);
  box-shadow: 0 10px 24px rgba(3,49,91,.15);
}
.shared-content-view .hero-quick-heading > span { background: linear-gradient(135deg,#ff2448,#ff680d); }
.shared-content-view .hero-quick-heading h2 { color: #07376c; font-size: 13px; }
.shared-content-view .hero-quick-heading p { color: #47748f; font-size: 9px; }
.shared-content-view .hero-quick-chapters .quick-chapter-list { gap: 7px; }
.shared-content-view .hero-quick-chapters .quick-chapter {
  min-height: 31px;
  padding: 6px 11px;
  border-color: #d2e5ef;
  border-radius: 999px;
  background: rgba(255,255,255,.94);
  color: #174c78;
  font-size: 10px;
}
.shared-content-view .hero-quick-chapters .quick-chapter > i { width: 7px; height: 7px; background: #11a7e4; box-shadow: none; }

.shared-content-view .school-chapter-browser {
  padding: 12px 18px 0;
  border: 1px solid #cfe4ef;
  border-radius: 17px;
  background: rgba(255,255,255,.96);
  box-shadow: 0 8px 22px rgba(10,75,116,.07);
}
.shared-content-view .library-browser-heading { padding: 0 2px 9px; }
.shared-content-view .library-browser-icon { width: 36px; height: 36px; border-radius: 11px; background: #dff4ff; color: #087eea; }
.shared-content-view .library-browser-heading h2 { color: #07366c; font-size: 14px; }
.shared-content-view .library-browser-heading p { color: #4f7896; font-size: 10px; }
.shared-content-view .library-browser-badge { padding: 6px 13px; background: #e5f5ff; color: #087eea; font-size: 10px; }

.shared-content-view .school-library-selectors { gap: 10px; padding-bottom: 10px; }
.shared-content-view .content-filter-field { padding: 7px 10px 9px; border-radius: 12px; }
.shared-content-view .content-filter-field:nth-child(1) { border-color: #acd9f2; background: #edf9ff; }
.shared-content-view .content-filter-field:nth-child(2) { border-color: #f5d89a; background: #fff8e9; }
.shared-content-view .content-filter-field:nth-child(3) { border-color: #aee8d5; background: #edfbf6; }
.shared-content-view .content-filter-field > span { margin-bottom: 5px; color: #174c78; font-size: 9px; }
.shared-content-view .content-filter-field > span b { width: 21px; height: 21px; border-radius: 50%; }
.shared-content-view .library-select-search { min-height: 36px; border-radius: 9px; background: #fff; font-size: 11px; }

.shared-content-view .school-chapter-heading { min-height: 66px; padding: 10px 2px 9px; border-top: 1px solid #dcecf3; }
.shared-content-view .school-chapter-title > span { width: 45px; height: 45px; border-radius: 12px; font-size: 20px; }
.shared-content-view .school-chapter-title small { color: #52748f; font-size: 9px; }
.shared-content-view .school-chapter-title h3 { margin-top: 1px; font-size: 17px; }
.shared-content-view .school-chapter-title em { color: #4f7a9b; font-size: 9px; }
.shared-content-view .shared-flipbook-action { min-height: 43px; padding: 8px 15px; border-radius: 10px; background: #0879ef; font-size: 11px; }

.shared-content-view .school-resource-tabs { gap: 5px; padding-bottom: 8px; }
.shared-content-view .school-resource-tabs button { min-height: 34px; padding: 6px 11px; border-radius: 9px; font-size: 10px; }
.shared-content-view .school-resource-tabs button:hover,
.shared-content-view .school-resource-tabs button.active { border-color: #9ed5f2; background: #e8f6ff; color: #0879df; }

.shared-content-view .school-resource-grid {
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 9px;
  min-height: 188px;
  padding: 10px 0 13px;
}
.shared-content-view .school-resource-card {
  min-height: 80px;
  padding: 12px;
  border-color: #cfe4ef;
  border-radius: 12px;
  background: linear-gradient(180deg,#fff,#f9fdff);
}
.shared-content-view .school-resource-card h4 { color: #073f75; font-size: 11px; }
.shared-content-view .school-resource-card p { color: #668ba5; font-size: 8px; }
.shared-content-view .school-resource-card > .btn { min-width: 75px; min-height: 34px; padding: 6px 9px; font-size: 10px; }
.shared-content-view .school-resource-card-top .school-resource-icon { width: 39px; height: 39px; }

body.theme-dark .shared-content-view .learning-library-hero {
  background:
    linear-gradient(90deg,rgba(2,28,65,.97),rgba(4,54,116,.78) 42%,rgba(5,38,70,.2)),
    url("../images/content-library-hero.png") center / cover no-repeat;
}

@media (max-width: 1180px) {
  .shared-content-view .learning-library-hero { grid-template-columns: minmax(0,1.25fr) minmax(260px,.75fr); }
  .shared-content-view .hero-quick-chapters { margin-right: 0; }
  .shared-content-view .learning-library-hero::after { display: none; }
  .shared-content-view .school-resource-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
}

@media (max-width: 900px) {
  .shared-content-view .learning-library-hero { grid-template-columns: 1fr; }
  .shared-content-view .hero-quick-chapters { max-width: 650px; }
  .shared-content-view .school-resource-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 700px) {
  #appShell:not(.d-none) .page-content.shared-content-page-shell { padding: 9px; }
  .shared-content-view .learning-library-hero { min-height: auto; padding: 18px; }
  .shared-content-view .learning-library-copy h1 { font-size: 27px; }
  .shared-content-view .learning-library-stats span { min-width: 0; }
  .shared-content-view .hero-quick-chapters .quick-chapter-list { grid-template-columns: 1fr; }
  .shared-content-view .school-resource-grid { grid-template-columns: 1fr; }
}

/* Final cascade guard: compact, contained and responsive on every role */
#appShell:not(.d-none) main.page-content,
#appShell.role-school-user:not(.d-none) main.page-content {
  min-width: 0;
  min-height: 0;
  padding: 8px clamp(10px,1.15vw,18px) 16px;
  overflow-x: hidden;
  overflow-y: auto;
  scroll-padding-bottom: 16px;
}

#appShell:not(.d-none) :is(.prisht-dashboard,.school-dashboard,.student-dashboard-page,.shared-content-view) {
  width: min(100%,1560px);
  max-width: 100%;
  margin-inline: auto;
}

@media (min-width: 901px) {
  #appShell:not(.d-none) main.page-content.shared-content-page-shell,
  #appShell.role-school-user:not(.d-none) main.page-content.shared-content-page-shell {
    height: 100%;
    padding: 8px clamp(10px,1.15vw,18px) 14px;
    overflow: hidden;
  }
  #appShell:not(.d-none) .shared-content-view {
    display: grid;
    height: 100%;
    min-height: 0;
    padding: 0;
    grid-template-rows: clamp(160px,22vh,205px) minmax(0,1fr);
    gap: 10px;
  }
  #appShell:not(.d-none) .shared-content-view .learning-library-hero {
    height: 100%;
    min-height: 0;
    padding: clamp(16px,2vh,22px) clamp(20px,2vw,30px);
  }
  #appShell:not(.d-none) .shared-content-view .school-chapter-browser {
    display: flex;
    height: 100%;
    min-height: 0;
    margin: 0;
    padding: 11px 18px 12px;
    overflow: hidden;
    flex-direction: column;
  }
  #appShell:not(.d-none) .shared-content-view .school-chapter-detail {
    display: flex;
    height: 0;
    min-height: 0;
    padding-inline: 2px;
    overflow: hidden;
    flex: 1 1 0;
    flex-direction: column;
  }
  #appShell:not(.d-none) .shared-content-view .school-resource-grid {
    height: 0;
    min-height: 0;
    margin: 0;
    padding: 10px 7px 14px 0;
    overflow-x: hidden;
    overflow-y: auto;
    flex: 1 1 0;
    align-content: start;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }
  #appShell:not(.d-none) .shared-content-view .school-resource-empty { min-height: 100%; }
}

@media (max-width: 1180px) and (min-width: 901px) {
  #appShell:not(.d-none) .shared-content-view .learning-library-hero { grid-template-columns: minmax(0,1.4fr) minmax(235px,.65fr); }
  #appShell:not(.d-none) .shared-content-view .hero-quick-chapters { margin-right: 0; }
  #appShell:not(.d-none) .shared-content-view .learning-library-copy h1 { font-size: clamp(27px,3.2vw,37px); }
  #appShell:not(.d-none) .shared-content-view .school-resource-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 900px) {
  #appShell:not(.d-none) main.page-content,
  #appShell.role-school-user:not(.d-none) main.page-content,
  #appShell:not(.d-none) main.page-content.shared-content-page-shell,
  #appShell.role-school-user:not(.d-none) main.page-content.shared-content-page-shell {
    height: auto;
    padding: 8px 10px 18px;
    overflow-x: hidden;
    overflow-y: auto;
  }
  #appShell:not(.d-none) .shared-content-view {
    display: grid;
    height: auto;
    min-height: 0;
    padding: 0;
    grid-template-rows: auto auto;
    gap: 10px;
  }
  #appShell:not(.d-none) .shared-content-view .learning-library-hero {
    min-height: 0;
    padding: 18px 20px;
    grid-template-columns: 1fr;
    gap: 13px;
  }
  #appShell:not(.d-none) .shared-content-view .hero-quick-chapters { width: min(100%,620px); max-width: 100%; margin: 0; }
  #appShell:not(.d-none) .shared-content-view .school-chapter-browser { height: auto; min-height: 0; margin: 0; padding: 11px 12px 14px; overflow: visible; }
  #appShell:not(.d-none) .shared-content-view .school-chapter-detail { height: auto; min-height: 0; overflow: visible; }
  #appShell:not(.d-none) .shared-content-view .school-resource-grid {
    height: auto;
    min-height: 150px;
    max-height: min(46vh,420px);
    padding: 10px 6px 14px 0;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
  }
}

@media (max-width: 700px) {
  #appShell:not(.d-none) main.page-content,
  #appShell.role-school-user:not(.d-none) main.page-content,
  #appShell:not(.d-none) main.page-content.shared-content-page-shell,
  #appShell.role-school-user:not(.d-none) main.page-content.shared-content-page-shell { padding: 7px 8px 16px; }
  #appShell:not(.d-none) .shared-content-view .learning-library-hero { padding: 16px; border-radius: 15px; }
  #appShell:not(.d-none) .shared-content-view .learning-library-copy h1 { font-size: clamp(25px,8vw,32px); }
  #appShell:not(.d-none) .shared-content-view .learning-library-stats { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); }
  #appShell:not(.d-none) .shared-content-view .learning-library-stats span { width: 100%; min-width: 0; padding-inline: 7px; }
  #appShell:not(.d-none) .shared-content-view .school-library-selectors { grid-template-columns: 1fr; }
  #appShell:not(.d-none) .shared-content-view .school-chapter-heading { align-items: stretch; flex-direction: column; }
  #appShell:not(.d-none) .shared-content-view .shared-flipbook-action { width: 100%; justify-content: center; }
  #appShell:not(.d-none) .shared-content-view .school-resource-tabs { overflow-x: auto; flex-wrap: nowrap; scrollbar-width: none; }
  #appShell:not(.d-none) .shared-content-view .school-resource-tabs::-webkit-scrollbar { display: none; }
  #appShell:not(.d-none) .shared-content-view .school-resource-tabs button { flex: 0 0 auto; }
  #appShell:not(.d-none) .shared-content-view .school-resource-grid { grid-template-columns: 1fr; max-height: 42vh; }
  #appShell:not(.d-none) .shared-content-view .school-resource-card { max-width: none; }
}

@media (max-width: 480px) {
  #appShell:not(.d-none) .shared-content-view .learning-library-stats { grid-template-columns: 1fr; }
  #appShell:not(.d-none) .shared-content-view .hero-quick-chapters { display: none; }
  #appShell:not(.d-none) .shared-content-view .school-resource-card { grid-template-columns: auto minmax(0,1fr); }
  #appShell:not(.d-none) .shared-content-view .school-resource-card > .btn { grid-column: 1 / -1; width: 100%; }
  #appShell:not(.d-none) :is(.school-dashboard>.experience-metric-grid,.student-dashboard-page .student-dashboard-metrics,.prisht-dashboard .prisht-metrics) { grid-template-columns: 1fr; }
}

/* Emerald learning theme from the approved visual reference */
:root {
  --edu-forest: #004d43;
  --edu-forest-deep: #003d37;
  --edu-emerald: #00a878;
  --edu-emerald-bright: #12c997;
  --edu-mint: #e8f8f1;
  --edu-mint-soft: #f4fbf7;
  --edu-warm: #fff8e9;
  --edu-orange: #ff6a13;
}

body,
#appShell:not(.d-none) {
  background: linear-gradient(135deg,#f8fbf7 0%,#eef8f2 58%,#f9fbf4 100%);
}

#appShell:not(.d-none) .sidebar,
#appShell.role-school-user:not(.d-none) .sidebar,
#appShell.role-student:not(.d-none) .sidebar {
  border-right-color: rgba(255,255,255,.1);
  background:
    radial-gradient(circle at 15% 92%,rgba(18,201,151,.2),transparent 27%),
    linear-gradient(180deg,var(--edu-forest-deep) 0%,#005449 58%,#00635a 100%);
  color: #fff;
  box-shadow: 7px 0 24px rgba(0,61,55,.13);
}

#appShell:not(.d-none) .sidebar-brand,
#appShell:not(.d-none) .sidebar-brand b { color: #fff; }
#appShell:not(.d-none) .sidebar-brand small { color: #65efd0; }
#appShell:not(.d-none) .sidebar-brand img {
  padding: 3px;
  border-radius: 10px;
  background: #fff;
  mix-blend-mode: normal;
}
#appShell:not(.d-none) .nav-section { color: #94cabe; }
#appShell:not(.d-none) .side-link { color: #e7fff8; }
#appShell:not(.d-none) .side-link i { color: #c8f7e9; }
#appShell:not(.d-none) .side-link:hover { background: rgba(18,201,151,.16); color: #fff; }
#appShell:not(.d-none) .side-link.active,
#appShell.role-school-user:not(.d-none) .side-link.active {
  background: linear-gradient(110deg,#00a878,#0cbd8d);
  color: #fff;
  box-shadow: 0 7px 17px rgba(0,41,36,.22);
}
#appShell:not(.d-none) .side-link.active::before { background: #8fffe2; }
#appShell:not(.d-none) .side-link.active i,
#appShell.role-school-user:not(.d-none) .side-link.active i { background: rgba(255,255,255,.12); color: #fff; }
#appShell:not(.d-none) .sidebar-motto,
#appShell.role-school-user:not(.d-none) .sidebar-motto {
  border-color: rgba(116,255,218,.18);
  background: rgba(0,126,105,.46);
}
#appShell:not(.d-none) .sidebar-motto > i { background: var(--edu-orange); }
#appShell:not(.d-none) .sidebar-motto b { color: #fff; }
#appShell:not(.d-none) .sidebar-motto small { color: #9cf5dc; }

#appShell:not(.d-none) .topbar {
  border-bottom-color: #dcebe3;
  background: rgba(255,255,255,.94);
}
#appShell:not(.d-none) .sidebar-toggle { background: #e2f7ef; color: #008b68; }
#appShell:not(.d-none) .sidebar-toggle:hover { background: #cef1e4; color: #006e55; }
#appShell:not(.d-none) .topbar-breadcrumb i { color: var(--edu-emerald); }
#appShell:not(.d-none) .topbar-breadcrumb b { color: var(--edu-forest); }
#appShell:not(.d-none) .topbar-search { border-color: #dcebe4; background: #f8fcfa; }
#appShell:not(.d-none) .notification-button { color: var(--edu-forest); }
#appShell:not(.d-none) .profile-trigger { background: #f1f8f4; }
#appShell:not(.d-none) .profile-trigger-copy b { color: var(--edu-forest); }
#appShell:not(.d-none) .profile-trigger-copy small { color: #589382; }

/* Admin dashboard */
.prisht-hero {
  border-color: #c9e8d9;
  background: #fff9ec;
  box-shadow: 0 10px 25px rgba(0,92,72,.1);
}
.prisht-hero::after {
  background: linear-gradient(90deg,rgba(255,249,234,.99) 0%,rgba(255,249,234,.94) 36%,rgba(244,250,239,.35) 62%,transparent 78%);
}
.prisht-hero .experience-kicker { color: #08765c; }
.prisht-hero h1 { color: var(--edu-forest-deep); }
.prisht-hero p { color: #356f60; }
.prisht-hero .btn.primary { background: linear-gradient(135deg,#00a878,#0bc18d); box-shadow: 0 7px 15px rgba(0,132,96,.2); }
.prisht-hero .btn.secondary { color: var(--edu-forest); }
.prisht-metrics .experience-metric { box-shadow: 0 7px 18px rgba(0,91,70,.06); }
.prisht-metrics strong,
.prisht-metrics h3 { color: var(--edu-forest-deep); }
.prisht-action-grid .experience-card { border-color: #d8ebe2; }
.prisht-action-grid h2,
.workflow-steps strong,
.quick-access-grid button { color: var(--edu-forest); }
.workflow-steps button:hover,
.quick-access-grid button:hover { background: #f0faf5; }

/* School and Student dashboards */
#appShell.role-school-user .school-dashboard .experience-hero.school,
.student-dashboard-page .student-dashboard-hero {
  border-color: #9fd9c4;
  background:
    linear-gradient(90deg,rgba(255,248,230,.98) 0%,rgba(255,249,235,.9) 36%,rgba(230,248,237,.15) 66%),
    url("../images/school-dashboard-hero.png") center / cover no-repeat;
  box-shadow: 0 10px 25px rgba(0,92,72,.11);
}
#appShell.role-school-user .school-dashboard .experience-hero :is(.experience-kicker,h1,p),
.student-dashboard-page .student-dashboard-hero :is(.student-dashboard-kicker,h1,p) { color: var(--edu-forest-deep); }
#appShell.role-school-user .school-dashboard .experience-hero h1 span,
.student-dashboard-page .student-dashboard-hero h1 span { color: var(--edu-orange); }
#appShell.role-school-user .school-dashboard .experience-hero-actions .primary,
.student-dashboard-page .student-dashboard-copy > .btn { background: linear-gradient(135deg,#00a878,#0bc18d); box-shadow: 0 7px 16px rgba(0,132,96,.2); }
#appShell.role-school-user .school-dashboard .experience-hero-actions .secondary { color: var(--edu-forest); }
#appShell.role-school-user .school-dashboard .learning-start-card,
.student-dashboard-page .student-dashboard-card { border-color: #d7eade; background-color: #fff; }
#appShell.role-school-user .school-dashboard .learning-start-card > .btn { background: linear-gradient(135deg,#008e69,#00b784); }
#appShell.role-school-user .school-dashboard .quick-access-card h2,
#appShell.role-school-user .school-dashboard .learning-start-content h2,
.student-dashboard-page .student-subject-panel h2,
.student-dashboard-page .student-help-card h2 { color: var(--edu-forest); }

/* Shared Content View */
#appShell:not(.d-none) .shared-content-view .learning-library-hero {
  border-color: #168c75;
  background:
    linear-gradient(90deg,rgba(0,61,55,.98) 0%,rgba(0,91,76,.87) 40%,rgba(0,90,74,.16) 69%),
    url("../images/content-library-hero.png") center / cover no-repeat;
  box-shadow: 0 10px 25px rgba(0,78,63,.14);
}
#appShell:not(.d-none) .shared-content-view .learning-library-copy :is(h1,p),
#appShell:not(.d-none) .shared-content-view .learning-library-kicker { color: #fff; }
#appShell:not(.d-none) .shared-content-view .learning-library-copy h1 span { color: #58f0c7; }
#appShell:not(.d-none) .shared-content-view .learning-library-stats span {
  border-color: rgba(189,255,236,.5);
  background: rgba(0,61,55,.3);
  color: #effff9;
}
#appShell:not(.d-none) .shared-content-view .learning-library-stats strong { color: #fff; }
#appShell:not(.d-none) .shared-content-view .hero-quick-chapters {
  border-color: rgba(210,239,226,.9);
  background: rgba(255,250,237,.92);
  box-shadow: 0 9px 22px rgba(0,65,52,.15);
}
#appShell:not(.d-none) .shared-content-view .hero-quick-heading h2 { color: var(--edu-forest); }
#appShell:not(.d-none) .shared-content-view .hero-quick-heading > span { background: linear-gradient(135deg,#ff6a13,#ff9d1c); }
#appShell:not(.d-none) .shared-content-view .hero-quick-chapters .quick-chapter { border-color: #cfe6dc; color: #176654; }
#appShell:not(.d-none) .shared-content-view .hero-quick-chapters .quick-chapter > i { background: var(--edu-emerald); }
#appShell:not(.d-none) .shared-content-view .school-chapter-browser { border-color: #cfe6db; box-shadow: 0 8px 22px rgba(0,91,70,.07); }
#appShell:not(.d-none) .shared-content-view .library-browser-icon { background: #ddf6ec; color: #008c68; }
#appShell:not(.d-none) .shared-content-view .library-browser-heading h2,
#appShell:not(.d-none) .shared-content-view .school-chapter-title h3 { color: var(--edu-forest); }
#appShell:not(.d-none) .shared-content-view .library-browser-badge { background: #e2f7ee; color: #008a66; }
#appShell:not(.d-none) .shared-content-view .content-filter-field:nth-child(1) { border-color: #bfe6d6; background: #edf9f4; }
#appShell:not(.d-none) .shared-content-view .content-filter-field:nth-child(2) { border-color: #f2ddb1; background: #fff8e9; }
#appShell:not(.d-none) .shared-content-view .content-filter-field:nth-child(3) { border-color: #aee3d1; background: #e9f9f2; }
#appShell:not(.d-none) .shared-content-view .content-filter-field:nth-child(1) > span b,
#appShell:not(.d-none) .shared-content-view .content-filter-field:nth-child(3) > span b { background: #cef2e3; color: #008b67; }
#appShell:not(.d-none) .shared-content-view .content-filter-field:focus-within { border-color: #38bd93; box-shadow: 0 0 0 3px rgba(0,168,120,.1); }
#appShell:not(.d-none) .shared-content-view .shared-flipbook-action { background: linear-gradient(135deg,#008f6b,#00b985); box-shadow: 0 5px 13px rgba(0,143,105,.2); }
#appShell:not(.d-none) .shared-content-view .school-resource-tabs button.active { border-color: #9ddbc4; background: #e4f8f0; color: #008a67; }
#appShell:not(.d-none) .shared-content-view .school-resource-tabs button.active span { background: var(--edu-emerald); }
#appShell:not(.d-none) .shared-content-view .school-resource-card { border-color: #d5e9df; background: linear-gradient(180deg,#fff,#f8fcfa); }
#appShell:not(.d-none) .shared-content-view .school-resource-card:hover { border-color: #82d5b7; box-shadow: 0 8px 20px rgba(0,108,80,.1); }
#appShell:not(.d-none) .shared-content-view .school-resource-empty { border-color: #abdcca; background: #f1faf6; color: #4f8878; }

@media (max-width: 760px) {
  #appShell:not(.d-none) .sidebar,
  #appShell.role-school-user:not(.d-none) .sidebar,
  #appShell.role-student:not(.d-none) .sidebar { background: linear-gradient(180deg,var(--edu-forest-deep),#006057); }
}

/* 100% browser zoom: match the compact proportions of the 90% reference */
@media (min-width: 901px) and (max-height: 850px) {
  #appShell:not(.d-none),
  #appShell.role-school-user:not(.d-none),
  #appShell.role-student:not(.d-none) {
    grid-template-columns: clamp(145px,12.5vw,198px) minmax(0,1fr);
    grid-template-rows: 56px minmax(0,1fr);
  }

  #appShell:not(.d-none) .topbar,
  #appShell.role-school-user:not(.d-none) .topbar {
    height: 56px;
    padding-inline: 16px;
  }

  #appShell:not(.d-none) .sidebar-toggle { width: 36px; height: 36px; }
  #appShell:not(.d-none) .profile-trigger { height: 42px; }
  #appShell:not(.d-none) .sidebar-brand { min-height: 61px; padding-block: 5px; }
  #appShell:not(.d-none) .sidebar-brand img { width: 58px; height: 44px; flex-basis: 58px; }
  #appShell:not(.d-none) .sidebar-brand b { font-size: 14px; }
  #appShell:not(.d-none) .side-link { min-height: 33px; padding-block: 6px; font-size: 10px; }
  #appShell:not(.d-none) .side-link i { width: 19px; height: 19px; font-size: 12px; }
  #appShell:not(.d-none) .nav-section { padding-top: 10px; font-size: 8px; }

  #appShell:not(.d-none) main.page-content,
  #appShell.role-school-user:not(.d-none) main.page-content { padding-top: 7px; }

  #appShell:not(.d-none) .shared-content-view {
    grid-template-rows: clamp(150px,22vh,180px) minmax(0,1fr);
    gap: 9px;
  }
  #appShell:not(.d-none) .shared-content-view .learning-library-hero { padding: 16px 27px; }
  #appShell:not(.d-none) .shared-content-view .learning-library-copy h1 { font-size: clamp(28px,2.55vw,41px); }
  #appShell:not(.d-none) .shared-content-view .learning-library-copy > p { margin: 8px 0 12px; font-size: 11px; }
  #appShell:not(.d-none) .shared-content-view .learning-library-stats span { min-width: 112px; padding: 6px 12px; font-size: 10px; }
  #appShell:not(.d-none) .shared-content-view .hero-quick-chapters { padding: 11px 13px; }
  #appShell:not(.d-none) .shared-content-view .school-chapter-browser { padding: 9px 16px 11px; }
  #appShell:not(.d-none) .shared-content-view .library-browser-heading { padding-bottom: 7px; }
  #appShell:not(.d-none) .shared-content-view .library-browser-icon { width: 33px; height: 33px; }
  #appShell:not(.d-none) .shared-content-view .school-library-selectors { gap: 9px; padding-bottom: 8px; }
  #appShell:not(.d-none) .shared-content-view .content-filter-field { padding: 5px 9px 7px; }
  #appShell:not(.d-none) .shared-content-view .content-filter-field > span { margin-bottom: 4px; }
  #appShell:not(.d-none) .shared-content-view .library-select-search { min-height: 33px; }
  #appShell:not(.d-none) .shared-content-view .school-chapter-heading { min-height: 58px; padding-block: 7px; }
  #appShell:not(.d-none) .shared-content-view .school-chapter-title > span { width: 41px; height: 41px; }
  #appShell:not(.d-none) .shared-content-view .shared-flipbook-action { min-height: 39px; }
  #appShell:not(.d-none) .shared-content-view .school-resource-tabs { padding-bottom: 6px; }
  #appShell:not(.d-none) .shared-content-view .school-resource-tabs button { min-height: 31px; padding: 5px 10px; }

  .prisht-hero,
  #appShell.role-school-user .school-dashboard .experience-hero.school,
  .student-dashboard-page .student-dashboard-hero { min-height: clamp(160px,21vh,195px); }
  .prisht-metrics,
  #appShell.role-school-user .school-dashboard > .experience-metric-grid,
  .student-dashboard-page .student-dashboard-metrics { margin-block: 8px; }
}

/* Collapsed navigation must reclaim the full canvas for every account type. */
#appShell.role-school-user.sidebar-hidden:not(.d-none),
#appShell.role-student.sidebar-hidden:not(.d-none),
#appShell.role-super-admin.sidebar-hidden:not(.d-none) {
  grid-template-columns: 0 minmax(0,1fr);
}

#appShell.role-school-user.sidebar-hidden:not(.d-none) .sidebar,
#appShell.role-student.sidebar-hidden:not(.d-none) .sidebar,
#appShell.role-super-admin.sidebar-hidden:not(.d-none) .sidebar {
  width: 0;
  min-width: 0;
  padding-inline: 0;
  border: 0;
  transform: translateX(-105%);
}
