:root {
  color-scheme: light;
  --ink-950: #14201d;
  --ink-900: #1c2a26;
  --ink-800: #31423d;
  --ink-700: #4a5b55;
  --ink-600: #61716b;
  --ink-500: #7b8984;
  --ink-300: #b8c2bd;
  --ink-200: #d8dfdb;
  --ink-150: #e5eae7;
  --ink-100: #eef1ef;
  --ink-50: #f7f8f6;
  --paper: #ffffff;
  --canvas: #f3f4f0;
  --forest-950: #0a2925;
  --forest-900: #103b34;
  --forest-800: #174b42;
  --forest-700: #1f6557;
  --forest-600: #2f7d6c;
  --forest-100: #dcece7;
  --forest-50: #edf6f2;
  --blue-700: #275b93;
  --blue-100: #dce9f7;
  --blue-50: #eff6fc;
  --amber-800: #86531d;
  --amber-600: #bd7a2a;
  --amber-100: #f6e3c5;
  --amber-50: #fff8eb;
  --red-800: #8b3936;
  --red-600: #b6534e;
  --red-100: #f3d9d6;
  --red-50: #fdf2f1;
  --violet-700: #62548e;
  --violet-100: #e7e1f3;
  --shadow-sm: 0 1px 2px rgba(13, 37, 32, 0.05), 0 5px 18px rgba(13, 37, 32, 0.035);
  --shadow-md: 0 16px 42px rgba(13, 37, 32, 0.11);
  --radius-sm: 8px;
  --radius-md: 13px;
  --radius-lg: 18px;
  --sidebar-width: 248px;
  --topbar-height: 72px;
  --content-max: 1540px;
  --font-sans: Inter, Aptos, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Aptos Display", Inter, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--ink-900);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button,
select,
input,
textarea {
  color: inherit;
  font: inherit;
}

button,
select {
  -webkit-tap-highlight-color: transparent;
}

button:not(:disabled),
select:not(:disabled),
a {
  cursor: pointer;
}

button:disabled,
select:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

a {
  color: inherit;
  text-decoration: none;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

:focus-visible {
  outline: 3px solid rgba(47, 125, 108, 0.34);
  outline-offset: 2px;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  left: 16px;
  top: -80px;
  border-radius: var(--radius-sm);
  background: var(--paper);
  box-shadow: var(--shadow-md);
  color: var(--forest-900);
  font-weight: 800;
  padding: 11px 16px;
  transition: top 160ms ease;
}

.skip-link:focus {
  top: 16px;
}

.app-shell {
  min-height: 100vh;
}

.sidebar {
  position: fixed;
  z-index: 40;
  inset: 0 auto 0 0;
  width: var(--sidebar-width);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding: 21px 15px 16px;
  background: var(--forest-950);
  color: #f2f7f4;
  scrollbar-width: thin;
}

.brand-row,
.brand,
.school-context,
.sidebar-proof,
.topbar,
.topbar-start,
.topbar-end,
.role-control,
.connection-pill,
.page-title-row,
.section-head,
.work-item,
.work-meta,
.receipt-item,
.health-row,
.metric,
.kpi-card,
.student-cell,
.audit-row,
.timeline-row,
.status-badge,
.mini-badge,
.button,
.empty-state,
.access-guard,
.dialog-head,
.dialog-actions {
  display: flex;
  align-items: center;
}

.brand-row {
  justify-content: space-between;
  min-height: 42px;
  padding: 0 5px;
}

.brand {
  min-width: 0;
  gap: 11px;
}

.brand-mark {
  width: 35px;
  height: 35px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.21);
  border-radius: 10px;
  background: #e5f0ba;
  color: var(--forest-950);
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 900;
  letter-spacing: -0.05em;
}

.brand-copy {
  display: grid;
  line-height: 1.15;
}

.brand-copy strong {
  font-family: var(--font-display);
  font-size: 16px;
  letter-spacing: -0.025em;
}

.brand-copy small {
  margin-top: 4px;
  color: rgba(238, 248, 244, 0.55);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.icon-button {
  width: 38px;
  height: 38px;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--ink-150);
  border-radius: 10px;
  background: var(--paper);
  color: var(--ink-700);
  font-size: 20px;
  line-height: 1;
  transition: border-color 150ms ease, background 150ms ease, color 150ms ease, transform 150ms ease;
}

.icon-button:hover:not(:disabled) {
  border-color: var(--ink-300);
  color: var(--forest-700);
  transform: translateY(-1px);
}

.sidebar-close {
  display: none;
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: white;
}

.school-context {
  gap: 10px;
  margin: 25px 5px 17px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.045);
  padding: 11px 12px;
}

.school-context > div,
.sidebar-proof > div,
.role-copy {
  display: grid;
  min-width: 0;
}

.school-context strong,
.school-context small,
.sidebar-proof strong,
.sidebar-proof small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.school-context strong,
.sidebar-proof strong {
  font-size: 12px;
}

.school-context small,
.sidebar-proof small {
  margin-top: 2px;
  color: rgba(238, 248, 244, 0.55);
  font-size: 10px;
}

.status-dot {
  width: 8px;
  height: 8px;
  display: inline-block;
  flex: 0 0 auto;
  border-radius: 99px;
  background: var(--ink-300);
  box-shadow: 0 0 0 4px rgba(184, 194, 189, 0.15);
}

.status-dot.is-live {
  background: #72c7a8;
  box-shadow: 0 0 0 4px rgba(114, 199, 168, 0.16);
}

.status-dot.is-demo {
  background: #e9ad5e;
  box-shadow: 0 0 0 4px rgba(233, 173, 94, 0.17);
}

.status-dot.is-loading {
  animation: pulse 1.2s ease-in-out infinite;
}

@keyframes pulse {
  50% { opacity: 0.38; transform: scale(0.82); }
}

.primary-nav {
  display: grid;
  gap: 3px;
}

.nav-label {
  margin: 18px 10px 6px;
  color: rgba(238, 248, 244, 0.39);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.nav-item {
  min-height: 43px;
  display: grid;
  grid-template-columns: 29px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 7px 10px;
  color: rgba(238, 248, 244, 0.7);
  font-size: 13px;
  font-weight: 650;
  transition: background 150ms ease, color 150ms ease, border-color 150ms ease;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: white;
}

.nav-item.is-active {
  border-color: rgba(218, 235, 167, 0.12);
  background: rgba(218, 235, 167, 0.12);
  color: #f7fbdc;
}

.nav-glyph {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: rgba(238, 248, 244, 0.68);
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.nav-item.is-active .nav-glyph {
  border-color: rgba(229, 240, 186, 0.26);
  background: rgba(229, 240, 186, 0.14);
  color: #e5f0ba;
}

.nav-count {
  min-width: 20px;
  border-radius: 99px;
  background: #e5f0ba;
  color: var(--forest-950);
  font-size: 10px;
  font-weight: 900;
  padding: 2px 6px;
  text-align: center;
}

.nav-lock {
  color: rgba(238, 248, 244, 0.42);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.sidebar-proof {
  gap: 10px;
  margin: auto 5px 0;
  padding: 24px 7px 2px;
}

.proof-mark {
  width: 23px;
  height: 23px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: rgba(229, 240, 186, 0.13);
}

.proof-mark::before {
  width: 7px;
  height: 4px;
  content: "";
  border-left: 2px solid #e5f0ba;
  border-bottom: 2px solid #e5f0ba;
  transform: rotate(-45deg) translate(1px, -1px);
}

.workspace {
  min-width: 0;
  min-height: 100vh;
  margin-left: var(--sidebar-width);
}

.topbar {
  position: sticky;
  z-index: 30;
  top: 0;
  min-height: var(--topbar-height);
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid var(--ink-150);
  background: rgba(255, 255, 255, 0.94);
  padding: 9px clamp(18px, 2.7vw, 42px);
  backdrop-filter: blur(16px);
}

.topbar-start,
.topbar-end {
  min-width: 0;
  gap: 10px;
}

.topbar-end {
  justify-content: flex-end;
}

.menu-button {
  display: none;
}

.breadcrumb {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
  font-size: 12px;
}

.breadcrumb span {
  color: var(--ink-500);
}

.breadcrumb strong {
  overflow: hidden;
  color: var(--ink-800);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.connection-pill {
  gap: 8px;
  min-height: 33px;
  border: 1px solid var(--ink-150);
  border-radius: 99px;
  background: var(--ink-50);
  color: var(--ink-600);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.025em;
  padding: 6px 11px;
  text-transform: uppercase;
}

.role-control {
  position: relative;
  min-width: 205px;
  gap: 9px;
  border: 1px solid var(--ink-150);
  border-radius: 11px;
  background: var(--paper);
  padding: 6px 34px 6px 7px;
}

.role-avatar {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 9px;
  background: var(--forest-100);
  color: var(--forest-800);
  font-size: 10px;
  font-weight: 900;
}

.role-copy {
  line-height: 1.12;
}

.role-copy small {
  color: var(--ink-500);
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
}

.role-copy strong {
  max-width: 130px;
  overflow: hidden;
  margin-top: 3px;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.role-control select {
  position: absolute;
  inset: 0;
  width: 100%;
  border: 0;
  opacity: 0;
}

.role-control::after {
  position: absolute;
  right: 13px;
  content: "⌄";
  color: var(--ink-500);
  font-size: 16px;
  pointer-events: none;
}

#main-content {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: clamp(24px, 3.5vw, 48px) clamp(18px, 3.8vw, 56px) 64px;
}

.page {
  display: grid;
  gap: 22px;
  animation: enter 220ms ease both;
}

@keyframes enter {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.page-title-row {
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
}

.page-title-row h1 {
  max-width: 780px;
  margin-bottom: 7px;
  color: var(--ink-950);
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 42px);
  font-weight: 720;
  letter-spacing: -0.045em;
  line-height: 1.06;
}

.page-title-row p {
  max-width: 710px;
  margin: 0;
  color: var(--ink-600);
  font-size: 14px;
}

.eyebrow {
  display: block;
  margin-bottom: 8px;
  color: var(--forest-700);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.date-block {
  flex: 0 0 auto;
  color: var(--ink-500);
  font-size: 11px;
  font-weight: 700;
  text-align: right;
}

.date-block strong {
  display: block;
  margin-top: 3px;
  color: var(--ink-800);
  font-size: 13px;
}

.mode-banner {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--amber-100);
  border-radius: var(--radius-md);
  background: var(--amber-50);
  color: var(--amber-800);
  padding: 12px 15px;
}

.mode-banner.is-live {
  border-color: var(--forest-100);
  background: var(--forest-50);
  color: var(--forest-800);
}

.mode-banner .mode-mark {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(134, 83, 29, 0.1);
  font-size: 11px;
  font-weight: 950;
}

.mode-banner.is-live .mode-mark {
  background: rgba(31, 101, 87, 0.1);
}

.mode-banner strong {
  display: block;
  font-size: 12px;
}

.mode-banner p {
  margin: 1px 0 0;
  font-size: 11px;
}

.mode-banner button {
  border: 0;
  background: transparent;
  color: inherit;
  font-size: 11px;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.day-pulse {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) repeat(4, minmax(110px, 0.65fr));
  overflow: hidden;
  border: 1px solid var(--ink-150);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow-sm);
}

.pulse-intro {
  display: flex;
  align-items: center;
  gap: 13px;
  min-height: 93px;
  padding: 17px 20px;
}

.pulse-ring {
  position: relative;
  width: 47px;
  height: 47px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 6px solid var(--forest-100);
  border-top-color: var(--forest-600);
  border-radius: 99px;
  color: var(--forest-800);
  font-size: 9px;
  font-weight: 900;
}

.pulse-intro strong,
.metric strong {
  display: block;
}

.pulse-intro strong {
  font-size: 14px;
}

.pulse-intro small {
  display: block;
  margin-top: 3px;
  color: var(--ink-500);
  font-size: 11px;
}

.metric {
  min-height: 93px;
  justify-content: center;
  align-items: flex-start;
  flex-direction: column;
  border-left: 1px solid var(--ink-150);
  padding: 15px 17px;
}

.metric span,
.kpi-card span {
  color: var(--ink-500);
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.metric strong {
  margin: 4px 0 1px;
  color: var(--ink-950);
  font-family: var(--font-display);
  font-size: 23px;
  letter-spacing: -0.035em;
}

.metric small,
.kpi-card small {
  color: var(--ink-500);
  font-size: 10px;
}

.operational-board {
  display: grid;
  grid-template-columns: minmax(0, 1.48fr) minmax(330px, 0.82fr);
  gap: 18px;
  align-items: start;
}

.board-stack {
  display: grid;
  gap: 18px;
}

.section-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--ink-150);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow-sm);
}

.section-card.is-attention {
  border-color: #ebd4c1;
}

.section-card.is-calm {
  border-color: #cfe3db;
  background: #fcfefd;
}

.section-head {
  min-height: 76px;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--ink-150);
  padding: 15px 19px;
}

.section-head > div {
  min-width: 0;
}

.section-head h2 {
  margin: 0;
  color: var(--ink-950);
  font-family: var(--font-display);
  font-size: 18px;
  letter-spacing: -0.025em;
}

.section-head p {
  margin: 3px 0 0;
  color: var(--ink-500);
  font-size: 11px;
}

.section-count {
  min-width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 9px;
  background: var(--ink-100);
  color: var(--ink-700);
  font-size: 11px;
  font-weight: 900;
}

.is-attention .section-count {
  background: var(--red-50);
  color: var(--red-800);
}

.section-body {
  padding: 17px 19px;
}

.work-list,
.attention-list,
.receipt-list,
.health-list,
.timeline,
.compact-list,
.class-list,
.document-list,
.incident-list,
.audit-list {
  display: grid;
}

.work-list {
  gap: 0;
}

.work-item {
  position: relative;
  align-items: flex-start;
  gap: 14px;
  min-width: 0;
  padding: 16px 0;
}

.work-item + .work-item {
  border-top: 1px solid var(--ink-100);
}

.work-time {
  width: 53px;
  flex: 0 0 auto;
  color: var(--ink-700);
  font-size: 11px;
  font-weight: 850;
  text-align: center;
}

.work-time span {
  display: block;
  width: 32px;
  height: 32px;
  margin: 0 auto 5px;
  border-radius: 9px;
  background: var(--forest-50);
  color: var(--forest-700);
  font-size: 9px;
  line-height: 32px;
}

.work-copy {
  min-width: 0;
  flex: 1 1 auto;
}

.work-copy h3 {
  margin: 0;
  color: var(--ink-950);
  font-size: 13px;
}

.work-copy p {
  margin: 4px 0 8px;
  color: var(--ink-600);
  font-size: 11px;
}

.work-meta {
  flex-wrap: wrap;
  gap: 6px;
}

.mini-badge,
.status-badge {
  width: fit-content;
  gap: 6px;
  border-radius: 99px;
  font-size: 9px;
  font-weight: 800;
  white-space: nowrap;
}

.mini-badge {
  border: 1px solid var(--ink-150);
  background: var(--ink-50);
  color: var(--ink-600);
  padding: 3px 7px;
}

.mini-badge.is-owner {
  border-color: var(--blue-100);
  background: var(--blue-50);
  color: var(--blue-700);
}

.mini-badge.is-proof {
  border-color: var(--forest-100);
  background: var(--forest-50);
  color: var(--forest-700);
}

.work-action {
  flex: 0 0 auto;
  align-self: center;
}

.button {
  min-height: 38px;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--ink-200);
  border-radius: 9px;
  background: var(--paper);
  color: var(--ink-800);
  font-size: 11px;
  font-weight: 850;
  padding: 8px 13px;
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease, background 150ms ease;
}

.button:hover:not(:disabled) {
  border-color: var(--ink-300);
  box-shadow: 0 4px 12px rgba(13, 37, 32, 0.08);
  transform: translateY(-1px);
}

.button.is-primary {
  border-color: var(--forest-800);
  background: var(--forest-800);
  color: white;
}

.button.is-primary:hover:not(:disabled) {
  border-color: var(--forest-700);
  background: var(--forest-700);
}

.button.is-danger {
  border-color: var(--red-100);
  background: var(--red-50);
  color: var(--red-800);
}

.button.is-quiet {
  background: var(--ink-50);
}

.button.is-small {
  min-height: 32px;
  padding: 6px 10px;
  font-size: 10px;
}

.button .arrow {
  font-size: 15px;
  font-weight: 500;
  line-height: 0;
}

.attention-list {
  gap: 10px;
}

.attention-item {
  position: relative;
  border: 1px solid var(--red-100);
  border-radius: 12px;
  background: var(--red-50);
  padding: 13px;
}

.attention-item.is-warning {
  border-color: var(--amber-100);
  background: var(--amber-50);
}

.attention-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 7px;
}

.attention-kind {
  color: var(--red-800);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.075em;
  text-transform: uppercase;
}

.is-warning .attention-kind {
  color: var(--amber-800);
}

.attention-due {
  color: var(--ink-500);
  font-size: 9px;
  font-weight: 750;
}

.attention-item h3 {
  margin: 0;
  color: var(--ink-950);
  font-size: 12px;
}

.attention-item p {
  margin: 4px 0 11px;
  color: var(--ink-600);
  font-size: 10px;
}

.attention-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.attention-bottom small {
  max-width: 170px;
  color: var(--ink-500);
  font-size: 9px;
}

.calm-summary {
  gap: 13px;
  border-bottom: 1px solid var(--ink-100);
  padding-bottom: 14px;
}

.calm-check {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 12px;
  background: var(--forest-100);
}

.calm-check::before {
  width: 12px;
  height: 7px;
  content: "";
  border-left: 2px solid var(--forest-700);
  border-bottom: 2px solid var(--forest-700);
  transform: rotate(-45deg) translate(2px, -2px);
}

.calm-summary strong {
  display: block;
  font-size: 13px;
}

.calm-summary small {
  color: var(--ink-500);
  font-size: 10px;
}

.health-list {
  margin-top: 4px;
}

.health-row {
  justify-content: space-between;
  gap: 12px;
  padding: 11px 0;
}

.health-row + .health-row {
  border-top: 1px solid var(--ink-100);
}

.health-row > div {
  min-width: 0;
}

.health-row strong {
  display: block;
  font-size: 11px;
}

.health-row small {
  display: block;
  margin-top: 2px;
  color: var(--ink-500);
  font-size: 9px;
}

.health-value {
  color: var(--forest-700);
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 800;
  white-space: nowrap;
}

.receipt-list {
  gap: 0;
}

.receipt-item {
  position: relative;
  align-items: flex-start;
  gap: 11px;
  padding: 11px 0;
}

.receipt-item + .receipt-item {
  border-top: 1px solid var(--ink-100);
}

.receipt-mark {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 7px;
  background: var(--forest-50);
  color: var(--forest-700);
  font-size: 9px;
  font-weight: 900;
}

.receipt-copy {
  min-width: 0;
  flex: 1 1 auto;
}

.receipt-copy strong {
  display: block;
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.receipt-copy small {
  display: block;
  margin-top: 2px;
  color: var(--ink-500);
  font-size: 9px;
}

.receipt-time {
  flex: 0 0 auto;
  color: var(--ink-500);
  font-size: 9px;
}

.empty-state {
  min-height: 150px;
  justify-content: center;
  flex-direction: column;
  color: var(--ink-600);
  padding: 25px;
  text-align: center;
}

.empty-state .empty-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  margin-bottom: 10px;
  border-radius: 12px;
  background: var(--forest-50);
  color: var(--forest-700);
  font-size: 13px;
  font-weight: 900;
}

.empty-state strong {
  color: var(--ink-800);
  font-size: 12px;
}

.empty-state p {
  max-width: 360px;
  margin: 4px 0 0;
  font-size: 10px;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.kpi-card {
  min-height: 110px;
  align-items: flex-start;
  justify-content: center;
  flex-direction: column;
  border: 1px solid var(--ink-150);
  border-radius: var(--radius-md);
  background: var(--paper);
  box-shadow: var(--shadow-sm);
  padding: 16px 17px;
}

.kpi-card strong {
  margin: 6px 0 2px;
  color: var(--ink-950);
  font-family: var(--font-display);
  font-size: clamp(21px, 2.3vw, 29px);
  letter-spacing: -0.04em;
  line-height: 1;
}

.kpi-card.is-good {
  border-top: 3px solid var(--forest-600);
}

.kpi-card.is-warning {
  border-top: 3px solid var(--amber-600);
}

.kpi-card.is-danger {
  border-top: 3px solid var(--red-600);
}

.kpi-card.is-info {
  border-top: 3px solid var(--blue-700);
}

.split-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(290px, 0.75fr);
  gap: 18px;
  align-items: start;
}

.split-grid.is-even {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pipeline {
  display: grid;
  grid-template-columns: repeat(5, minmax(108px, 1fr));
  gap: 1px;
  overflow-x: auto;
  padding: 1px;
}

.pipeline-stage {
  position: relative;
  min-height: 135px;
  border: 1px solid var(--ink-150);
  background: var(--paper);
  padding: 15px;
}

.pipeline-stage:first-child {
  border-radius: 11px 0 0 11px;
}

.pipeline-stage:last-child {
  border-radius: 0 11px 11px 0;
}

.pipeline-stage span {
  color: var(--ink-500);
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.pipeline-stage strong {
  display: block;
  margin: 8px 0 2px;
  font-family: var(--font-display);
  font-size: 25px;
  letter-spacing: -0.04em;
}

.pipeline-stage small {
  color: var(--ink-500);
  font-size: 9px;
}

.pipeline-stage .stage-bar {
  position: absolute;
  inset: auto 14px 13px;
  height: 4px;
  overflow: hidden;
  border-radius: 99px;
  background: var(--ink-100);
}

.pipeline-stage .stage-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--forest-600);
}

.table-wrap {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

.data-table th {
  border-bottom: 1px solid var(--ink-150);
  color: var(--ink-500);
  font-size: 9px;
  font-weight: 850;
  letter-spacing: 0.055em;
  padding: 10px 12px;
  text-align: left;
  text-transform: uppercase;
  white-space: nowrap;
}

.data-table td {
  border-bottom: 1px solid var(--ink-100);
  color: var(--ink-700);
  padding: 12px;
  vertical-align: middle;
}

.data-table tbody tr:last-child td {
  border-bottom: 0;
}

.data-table tbody tr:hover {
  background: var(--ink-50);
}

.student-cell {
  min-width: 180px;
  gap: 9px;
}

.student-avatar {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 9px;
  background: var(--blue-50);
  color: var(--blue-700);
  font-size: 9px;
  font-weight: 900;
}

.student-cell > div {
  display: grid;
}

.student-cell strong {
  color: var(--ink-900);
  font-size: 11px;
}

.student-cell small {
  color: var(--ink-500);
  font-size: 9px;
}

.status-badge {
  padding: 4px 8px;
}

.status-badge::before {
  width: 6px;
  height: 6px;
  content: "";
  border-radius: 99px;
  background: currentColor;
  opacity: 0.7;
}

.status-badge.is-good {
  background: var(--forest-50);
  color: var(--forest-700);
}

.status-badge.is-warning {
  background: var(--amber-50);
  color: var(--amber-800);
}

.status-badge.is-danger {
  background: var(--red-50);
  color: var(--red-800);
}

.status-badge.is-info {
  background: var(--blue-50);
  color: var(--blue-700);
}

.status-badge.is-neutral {
  background: var(--ink-100);
  color: var(--ink-600);
}

.progress-track {
  width: min(150px, 100%);
  height: 6px;
  overflow: hidden;
  border-radius: 99px;
  background: var(--ink-100);
}

.progress-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--forest-600);
}

.progress-track.is-warning i {
  background: var(--amber-600);
}

.progress-track.is-danger i {
  background: var(--red-600);
}

.compact-list {
  gap: 0;
}

.compact-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 13px;
  align-items: center;
  padding: 13px 0;
}

.compact-row + .compact-row {
  border-top: 1px solid var(--ink-100);
}

.compact-row h3 {
  margin: 0;
  font-size: 11px;
}

.compact-row p {
  margin: 3px 0 0;
  color: var(--ink-500);
  font-size: 9px;
}

.compact-value {
  color: var(--ink-800);
  font-size: 11px;
  font-weight: 850;
  white-space: nowrap;
}

.matrix {
  display: grid;
  grid-template-columns: minmax(140px, 1.3fr) repeat(4, minmax(70px, 0.55fr));
  overflow-x: auto;
  font-size: 10px;
}

.matrix > div {
  min-height: 48px;
  display: flex;
  align-items: center;
  border-right: 1px solid var(--ink-100);
  border-bottom: 1px solid var(--ink-100);
  padding: 9px 11px;
}

.matrix > div:nth-child(5n) {
  border-right: 0;
}

.matrix .matrix-head {
  min-height: 38px;
  background: var(--ink-50);
  color: var(--ink-500);
  font-size: 8px;
  font-weight: 850;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.matrix-score {
  justify-content: center;
  font-weight: 850;
}

.matrix-score.is-good { background: var(--forest-50); color: var(--forest-700); }
.matrix-score.is-warning { background: var(--amber-50); color: var(--amber-800); }
.matrix-score.is-danger { background: var(--red-50); color: var(--red-800); }

.class-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
}

.class-card {
  border: 1px solid var(--ink-150);
  border-radius: 11px;
  background: var(--paper);
  padding: 14px;
}

.class-card header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.class-card h3 {
  margin: 0;
  font-size: 12px;
}

.class-card p {
  margin: 3px 0 12px;
  color: var(--ink-500);
  font-size: 9px;
}

.class-stat-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 8px;
  color: var(--ink-600);
  font-size: 9px;
}

.attendance-board {
  display: grid;
  grid-template-columns: repeat(5, minmax(125px, 1fr));
  gap: 9px;
  overflow-x: auto;
}

.attendance-day {
  min-width: 125px;
  border: 1px solid var(--ink-150);
  border-radius: 11px;
  background: var(--paper);
  padding: 12px;
}

.attendance-day.is-today {
  border-color: var(--forest-600);
  box-shadow: inset 0 3px 0 var(--forest-600);
}

.attendance-day header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 12px;
}

.attendance-day header strong {
  font-size: 11px;
}

.attendance-day header span {
  color: var(--ink-500);
  font-size: 8px;
  text-transform: uppercase;
}

.attendance-bars {
  display: grid;
  gap: 7px;
}

.attendance-bar {
  display: grid;
  grid-template-columns: 26px 1fr 26px;
  align-items: center;
  gap: 6px;
  color: var(--ink-500);
  font-size: 8px;
}

.attendance-bar i {
  height: 5px;
  overflow: hidden;
  border-radius: 99px;
  background: var(--ink-100);
}

.attendance-bar i::before {
  width: var(--bar, 90%);
  height: 100%;
  display: block;
  content: "";
  border-radius: inherit;
  background: var(--forest-600);
}

.attendance-bar.is-warning i::before { background: var(--amber-600); }
.attendance-bar.is-danger i::before { background: var(--red-600); }

.custody-command {
  display: grid;
  grid-template-columns: minmax(240px, 0.8fr) minmax(0, 1.6fr);
  overflow: hidden;
  border: 1px solid var(--forest-800);
  border-radius: var(--radius-lg);
  background: var(--forest-950);
  box-shadow: var(--shadow-md);
  color: white;
}

.custody-overview {
  display: flex;
  justify-content: center;
  flex-direction: column;
  padding: 25px;
}

.custody-overview .eyebrow {
  color: #b9dacd;
}

.custody-overview h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 23px;
  letter-spacing: -0.035em;
}

.custody-overview p {
  margin: 7px 0 0;
  color: rgba(255, 255, 255, 0.58);
  font-size: 10px;
}

.custody-counts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 20px;
}

.custody-count {
  border-left: 1px solid rgba(255, 255, 255, 0.12);
  padding: 0 13px;
}

.custody-count:first-child {
  border-left: 0;
  padding-left: 0;
}

.custody-count strong {
  display: block;
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: -0.04em;
}

.custody-count span {
  color: rgba(255, 255, 255, 0.52);
  font-size: 8px;
  font-weight: 750;
  text-transform: uppercase;
}

.exit-queue {
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.045);
  padding: 20px;
}

.exit-queue-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 11px;
}

.exit-queue-head strong {
  font-size: 11px;
}

.exit-queue-head span {
  color: rgba(255, 255, 255, 0.5);
  font-size: 9px;
}

.exit-list {
  display: grid;
  gap: 7px;
}

.exit-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.055);
  padding: 9px 10px;
}

.exit-item.is-blocked {
  border-color: rgba(241, 175, 165, 0.3);
  background: rgba(182, 83, 78, 0.16);
}

.exit-time {
  color: rgba(255, 255, 255, 0.52);
  font-size: 9px;
  font-weight: 850;
}

.exit-item strong {
  display: block;
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.exit-item small {
  display: block;
  margin-top: 2px;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.5);
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.exit-state {
  border-radius: 99px;
  background: rgba(114, 199, 168, 0.13);
  color: #9bdec5;
  font-size: 8px;
  font-weight: 850;
  padding: 4px 7px;
}

.is-blocked .exit-state {
  background: rgba(241, 175, 165, 0.13);
  color: #f1afa5;
}

.gate-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.gate-card {
  border: 1px solid var(--ink-150);
  border-radius: 11px;
  background: var(--paper);
  padding: 14px;
}

.gate-card .gate-index {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  margin-bottom: 10px;
  border-radius: 8px;
  background: var(--forest-50);
  color: var(--forest-700);
  font-size: 9px;
  font-weight: 900;
}

.gate-card strong {
  display: block;
  font-size: 11px;
}

.gate-card p {
  margin: 4px 0 0;
  color: var(--ink-500);
  font-size: 9px;
}

.money {
  font-variant-numeric: tabular-nums;
}

.aging-chart {
  display: grid;
  gap: 11px;
}

.aging-row {
  display: grid;
  grid-template-columns: 82px minmax(90px, 1fr) 86px;
  align-items: center;
  gap: 10px;
  font-size: 9px;
}

.aging-row > span {
  color: var(--ink-600);
}

.aging-row > strong {
  color: var(--ink-800);
  font-size: 10px;
  text-align: right;
}

.aging-bar {
  height: 9px;
  overflow: hidden;
  border-radius: 99px;
  background: var(--ink-100);
}

.aging-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--forest-600);
}

.aging-row.is-warning i { background: var(--amber-600); }
.aging-row.is-danger i { background: var(--red-600); }

.incident-list {
  gap: 10px;
}

.incident-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: 12px;
  border: 1px solid var(--ink-150);
  border-radius: 11px;
  padding: 13px;
}

.severity-mark {
  width: 29px;
  height: 29px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--amber-50);
  color: var(--amber-800);
  font-size: 9px;
  font-weight: 900;
}

.severity-mark.is-danger {
  background: var(--red-50);
  color: var(--red-800);
}

.incident-card h3 {
  margin: 0;
  font-size: 11px;
}

.incident-card p {
  margin: 3px 0 7px;
  color: var(--ink-500);
  font-size: 9px;
}

.incident-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.hard-stop-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.hard-stop {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border: 1px solid var(--ink-150);
  border-radius: 10px;
  background: var(--ink-50);
  padding: 11px;
}

.hard-stop > span {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 7px;
  background: var(--forest-100);
  color: var(--forest-700);
  font-size: 8px;
  font-weight: 900;
}

.hard-stop strong {
  display: block;
  font-size: 10px;
}

.hard-stop p {
  margin: 2px 0 0;
  color: var(--ink-500);
  font-size: 8px;
}

.audit-list {
  gap: 0;
}

.audit-row {
  display: grid;
  grid-template-columns: 45px minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  padding: 11px 0;
}

.audit-row + .audit-row {
  border-top: 1px solid var(--ink-100);
}

.audit-seq {
  color: var(--ink-500);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 9px;
}

.audit-row strong {
  display: block;
  font-size: 10px;
}

.audit-row small {
  display: block;
  margin-top: 2px;
  color: var(--ink-500);
  font-size: 8px;
}

.audit-hash {
  max-width: 96px;
  overflow: hidden;
  border-radius: 6px;
  background: var(--ink-50);
  color: var(--ink-500);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 8px;
  padding: 4px 6px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-guard {
  min-height: 420px;
  justify-content: center;
  flex-direction: column;
  border: 1px solid var(--ink-150);
  border-radius: var(--radius-lg);
  background: var(--paper);
  box-shadow: var(--shadow-sm);
  padding: 40px;
  text-align: center;
}

.access-mark {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
  border-radius: 15px;
  background: var(--amber-50);
  color: var(--amber-800);
  font-size: 12px;
  font-weight: 900;
}

.access-guard h2 {
  margin-bottom: 7px;
  font-family: var(--font-display);
  font-size: 22px;
  letter-spacing: -0.03em;
}

.access-guard p {
  max-width: 490px;
  margin-bottom: 17px;
  color: var(--ink-600);
  font-size: 11px;
}

.action-dialog {
  width: min(560px, calc(100vw - 28px));
  max-height: calc(100vh - 32px);
  overflow: hidden;
  border: 0;
  border-radius: 18px;
  background: var(--paper);
  box-shadow: 0 30px 100px rgba(5, 28, 23, 0.28);
  padding: 0;
}

.action-dialog::backdrop {
  background: rgba(7, 28, 24, 0.54);
  backdrop-filter: blur(4px);
}

.dialog-frame {
  display: flex;
  max-height: calc(100vh - 32px);
  flex-direction: column;
}

.dialog-head {
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid var(--ink-150);
  padding: 18px 20px;
}

.dialog-head .eyebrow {
  margin-bottom: 5px;
}

.dialog-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: -0.03em;
}

.dialog-body {
  overflow-y: auto;
  padding: 20px;
}

.dialog-context {
  display: grid;
  gap: 12px;
}

.dialog-context-card {
  border: 1px solid var(--ink-150);
  border-radius: 11px;
  background: var(--ink-50);
  padding: 13px;
}

.dialog-context-card span {
  display: block;
  margin-bottom: 4px;
  color: var(--ink-500);
  font-size: 8px;
  font-weight: 850;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.dialog-context-card strong {
  display: block;
  font-size: 11px;
}

.dialog-context-card p {
  margin: 3px 0 0;
  color: var(--ink-600);
  font-size: 10px;
}

.consequence-chain {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
}

.consequence-step {
  position: relative;
  border: 1px solid var(--forest-100);
  border-radius: 10px;
  background: var(--forest-50);
  padding: 10px;
}

.consequence-step span {
  display: block;
  margin-bottom: 5px;
  color: var(--forest-700);
  font-size: 8px;
  font-weight: 900;
  text-transform: uppercase;
}

.consequence-step strong {
  color: var(--ink-800);
  font-size: 9px;
}

.dialog-proof {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  border-left: 3px solid var(--blue-700);
  background: var(--blue-50);
  color: var(--blue-700);
  padding: 10px 12px;
}

.dialog-proof strong {
  display: block;
  font-size: 9px;
}

.dialog-proof p {
  margin: 2px 0 0;
  font-size: 9px;
}

.dialog-error {
  min-height: 0;
  margin: 0;
  color: var(--red-800);
  font-size: 10px;
  font-weight: 700;
  padding: 0 20px;
}

.dialog-error:not(:empty) {
  padding-bottom: 12px;
}

.dialog-actions {
  justify-content: flex-end;
  gap: 8px;
  border-top: 1px solid var(--ink-150);
  padding: 14px 20px;
}

.toast-stack {
  position: fixed;
  z-index: 100;
  right: 20px;
  bottom: 20px;
  width: min(390px, calc(100vw - 32px));
  display: grid;
  gap: 8px;
  pointer-events: none;
}

.toast {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  border: 1px solid var(--ink-150);
  border-radius: 12px;
  background: var(--paper);
  box-shadow: var(--shadow-md);
  padding: 12px 14px;
  animation: toast-in 180ms ease both;
  pointer-events: auto;
}

@keyframes toast-in {
  from { opacity: 0; transform: translateY(8px); }
}

.toast-mark {
  width: 23px;
  height: 23px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: var(--forest-50);
  color: var(--forest-700);
  font-size: 9px;
  font-weight: 900;
}

.toast.is-warning .toast-mark {
  background: var(--amber-50);
  color: var(--amber-800);
}

.toast.is-danger .toast-mark {
  background: var(--red-50);
  color: var(--red-800);
}

.toast strong {
  display: block;
  font-size: 11px;
}

.toast p {
  margin: 2px 0 0;
  color: var(--ink-500);
  font-size: 9px;
}

.loading-state {
  padding-top: 20px;
}

.loading-kicker {
  color: var(--ink-500);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.loading-title,
.loading-copy,
.loading-grid > div {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  background: var(--ink-100);
}

.loading-title::after,
.loading-copy::after,
.loading-grid > div::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.65), transparent);
  transform: translateX(-100%);
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  100% { transform: translateX(100%); }
}

.loading-title {
  width: min(540px, 75%);
  height: 37px;
  margin-top: 12px;
}

.loading-copy {
  width: min(650px, 90%);
  height: 14px;
  margin-top: 12px;
}

.loading-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 35px;
}

.loading-grid > div {
  height: 115px;
}

.noscript {
  position: fixed;
  z-index: 1000;
  inset: 20px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: white;
  color: var(--ink-800);
  text-align: center;
}

@media (max-width: 1180px) {
  .day-pulse {
    grid-template-columns: minmax(240px, 1.4fr) repeat(2, minmax(125px, 0.7fr));
  }

  .day-pulse .metric:nth-last-child(-n + 2) {
    border-top: 1px solid var(--ink-150);
  }

  .day-pulse .metric:nth-child(4) {
    border-left: 0;
  }

  .pulse-intro {
    grid-row: span 2;
  }

  .kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .gate-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .brand {
    min-height: 44px;
  }

  .icon-button {
    width: 44px;
    height: 44px;
  }

  .sidebar {
    width: min(290px, calc(100vw - 48px));
    box-shadow: 18px 0 55px rgba(5, 25, 20, 0.25);
    transform: translateX(-105%);
    transition: transform 190ms ease;
  }

  .sidebar.is-open {
    transform: translateX(0);
  }

  .sidebar-scrim {
    position: fixed;
    z-index: 35;
    inset: 0;
    background: rgba(6, 25, 21, 0.42);
  }

  .sidebar-scrim:not([hidden]) {
    display: block;
  }

  .sidebar-close,
  .menu-button {
    display: inline-grid;
  }

  .workspace {
    margin-left: 0;
  }

  .operational-board,
  .split-grid,
  .split-grid.is-even,
  .custody-command {
    grid-template-columns: 1fr;
  }

  .exit-queue {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-left: 0;
  }

  .connection-pill {
    display: none;
  }
}

@media (max-width: 720px) {
  :root {
    --topbar-height: 64px;
  }

  .topbar {
    padding: 8px 13px;
  }

  .breadcrumb,
  .refresh-button {
    display: none;
  }

  .topbar-end {
    min-width: 0;
    flex: 1 1 auto;
  }

  .role-control {
    min-width: 0;
    max-width: 240px;
    flex: 1 1 auto;
    margin-left: auto;
  }

  #main-content {
    padding: 24px 14px 50px;
  }

  .page {
    gap: 16px;
  }

  .page-title-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .page-title-row h1 {
    font-size: 30px;
  }

  .date-block {
    text-align: left;
  }

  .mode-banner {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .mode-banner button {
    grid-column: 2;
    justify-self: start;
  }

  .day-pulse {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pulse-intro {
    grid-column: 1 / -1;
    grid-row: auto;
    min-height: 83px;
  }

  .day-pulse .metric {
    min-height: 83px;
    border-top: 1px solid var(--ink-150);
  }

  .day-pulse .metric:nth-child(2),
  .day-pulse .metric:nth-child(4) {
    border-left: 0;
  }

  .section-head {
    min-height: 68px;
    padding: 13px 14px;
  }

  .section-body {
    padding: 14px;
  }

  .work-item {
    display: grid;
    grid-template-columns: 45px minmax(0, 1fr);
    gap: 10px;
  }

  .work-time {
    width: 45px;
  }

  .work-action {
    grid-column: 2;
    justify-self: start;
  }

  .kpi-grid {
    gap: 8px;
  }

  .kpi-card {
    min-height: 100px;
    padding: 13px;
  }

  .pipeline {
    grid-template-columns: repeat(5, minmax(124px, 1fr));
  }

  .class-list,
  .hard-stop-grid,
  .gate-grid {
    grid-template-columns: 1fr;
  }

  .custody-overview,
  .exit-queue {
    padding: 17px;
  }

  .custody-counts {
    gap: 5px;
  }

  .custody-count {
    padding: 0 8px;
  }

  .exit-item {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .exit-state {
    grid-column: 2;
    justify-self: start;
  }

  .consequence-chain {
    grid-template-columns: 1fr;
  }

  .dialog-actions .button {
    flex: 1 1 auto;
  }
}

@media (max-width: 460px) {
  .role-avatar {
    display: none;
  }

  .role-control {
    padding-left: 10px;
  }

  .page-title-row h1 {
    font-size: 27px;
  }

  .kpi-grid {
    grid-template-columns: 1fr 1fr;
  }

  .kpi-card strong {
    font-size: 22px;
  }

  .attention-bottom {
    align-items: flex-start;
    flex-direction: column;
  }

  .data-table th,
  .data-table td {
    padding-inline: 9px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

@media print {
  .sidebar,
  .topbar,
  .button,
  .toast-stack {
    display: none !important;
  }

  .workspace {
    margin: 0;
  }

  #main-content {
    max-width: none;
    padding: 0;
  }

  .section-card,
  .kpi-card {
    box-shadow: none;
    break-inside: avoid;
  }
}

/* Percentuais discretizados evitam estilos inline e permanecem compat?veis com a CSP do servidor. */
.stage-bar i[class*="pct-"],
.progress-track i[class*="pct-"],
.aging-bar i[class*="pct-"] { width: var(--pct, 0%); }
.attendance-bar[class*="pct-"] i::before { width: var(--pct, 0%); }
.pct-0 { --pct: 0%; }
.pct-5 { --pct: 5%; }
.pct-10 { --pct: 10%; }
.pct-15 { --pct: 15%; }
.pct-20 { --pct: 20%; }
.pct-25 { --pct: 25%; }
.pct-30 { --pct: 30%; }
.pct-35 { --pct: 35%; }
.pct-40 { --pct: 40%; }
.pct-45 { --pct: 45%; }
.pct-50 { --pct: 50%; }
.pct-55 { --pct: 55%; }
.pct-60 { --pct: 60%; }
.pct-65 { --pct: 65%; }
.pct-70 { --pct: 70%; }
.pct-75 { --pct: 75%; }
.pct-80 { --pct: 80%; }
.pct-85 { --pct: 85%; }
.pct-90 { --pct: 90%; }
.pct-95 { --pct: 95%; }
.pct-100 { --pct: 100%; }

.action-field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  border: 1px solid var(--ink-150);
  border-radius: 11px;
  background: #fff;
  padding: 14px;
}

.action-field-heading {
  grid-column: 1 / -1;
}

.action-field-heading span,
.action-field > span {
  color: var(--ink-700);
  font-size: 10px;
  font-weight: 800;
}

.action-field-heading p,
.action-field small {
  margin: 2px 0 0;
  color: var(--ink-500);
  font-size: 9px;
}

.action-field {
  display: grid;
  align-content: start;
  gap: 6px;
}

.action-field input,
.action-field select,
.action-field textarea {
  width: 100%;
  border: 1px solid var(--ink-200);
  border-radius: 9px;
  background: var(--ink-50);
  padding: 10px 11px;
  outline: none;
}

.action-field input:focus,
.action-field select:focus,
.action-field textarea:focus {
  border-color: var(--forest-600);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--forest-600) 14%, transparent);
}

@media (max-width: 640px) {
  .action-field-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   FABLE A/B — P4: o portão de entrar (visual da casa; nada de estilo injetado em JS)
   ============================================================ */
.es-login-gate {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  padding: 24px;
  background: #0c2621;
}

/* Escola 360 — experiência interna compacta por função. */
.primary-nav[data-navigation-mode="compact-internal"] .nav-item {
  align-items: flex-start;
  min-height: 58px;
}

.primary-nav[data-navigation-mode="compact-internal"] .nav-item > span:nth-child(2) {
  display: grid;
  min-width: 0;
}

.primary-nav[data-navigation-mode="compact-internal"] .nav-item strong {
  color: inherit;
  font-size: 0.91rem;
  font-weight: 720;
}

.primary-nav[data-navigation-mode="compact-internal"] .nav-item small {
  color: var(--ink-500);
  font-size: 0.72rem;
  font-weight: 520;
  line-height: 1.3;
  margin-top: 2px;
}

.primary-nav[data-navigation-mode="compact-internal"] .nav-item.is-active small {
  color: color-mix(in srgb, var(--forest-700) 78%, white);
}

.internal-experience-page {
  display: grid;
  gap: 18px;
  margin-inline: auto;
  max-width: 1120px;
}

.internal-role-hero {
  align-items: end;
  background:
    radial-gradient(circle at 94% 12%, rgba(255, 255, 255, 0.16), transparent 24%),
    linear-gradient(132deg, var(--forest-950), var(--forest-700));
  border-radius: 22px;
  color: white;
  display: grid;
  gap: 28px;
  grid-template-columns: minmax(0, 1fr) 170px;
  overflow: hidden;
  padding: clamp(24px, 4vw, 42px);
  position: relative;
}

.internal-role-hero .eyebrow {
  color: rgba(255, 255, 255, 0.72);
}

.internal-role-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 4vw, 3.2rem);
  letter-spacing: -0.045em;
  line-height: 1.02;
  margin: 12px 0 13px;
  max-width: 760px;
}

.internal-role-hero p {
  color: rgba(255, 255, 255, 0.84);
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  margin: 0;
  max-width: 680px;
}

.internal-role-summary {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
  display: grid;
  padding: 18px;
}

.internal-role-summary strong {
  font-family: var(--font-display);
  font-size: 2.4rem;
  line-height: 1;
}

.internal-role-summary span {
  font-size: 0.85rem;
  font-weight: 680;
  line-height: 1.25;
  margin-top: 7px;
}

.internal-role-summary small {
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.7rem;
  margin-top: 8px;
}

.internal-trust-note {
  align-items: center;
  background: var(--forest-50);
  border: 1px solid var(--forest-100);
  border-radius: 14px;
  color: var(--forest-900);
  display: grid;
  gap: 12px;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  padding: 13px 15px;
}

.internal-trust-note > span {
  align-items: center;
  background: var(--forest-700);
  border-radius: 50%;
  color: white;
  display: inline-flex;
  font-weight: 800;
  height: 28px;
  justify-content: center;
  width: 28px;
}

.internal-trust-note p {
  margin: 0;
}

.internal-context-block {
  background: var(--paper);
  border: 1px solid var(--ink-150);
  border-radius: 17px;
  box-shadow: var(--shadow-sm);
  display: grid;
  gap: 16px;
  padding: 20px 22px;
}

.internal-context-block > header {
  align-items: end;
  display: flex;
  gap: 18px;
  justify-content: space-between;
}

.internal-context-block h2 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  margin: 5px 0 3px;
}

.internal-context-block header p,
.internal-context-block header small,
.internal-context-empty {
  color: var(--ink-600);
  margin: 0;
}

.internal-context-metrics {
  display: grid;
  gap: 9px;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.internal-context-metric {
  background: var(--ink-50);
  border: 1px solid var(--ink-100);
  border-radius: 12px;
  display: grid;
  gap: 3px;
  min-height: 104px;
  padding: 13px;
}

.internal-context-metric > span {
  color: var(--ink-600);
  font-size: 0.72rem;
  font-weight: 760;
  text-transform: uppercase;
}

.internal-context-metric > strong {
  font-family: var(--font-display);
  font-size: 1.2rem;
}

.internal-context-metric > small {
  color: var(--ink-600);
  line-height: 1.35;
}

.internal-context-history > strong {
  font-size: 0.78rem;
}

.internal-context-history ul {
  display: grid;
  gap: 7px;
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
}

.internal-context-history li {
  align-items: center;
  border-top: 1px solid var(--ink-100);
  display: flex;
  gap: 12px;
  justify-content: space-between;
  padding-top: 8px;
}

.internal-context-history li span {
  display: grid;
}

.internal-context-history li small,
.internal-context-history li em {
  color: var(--ink-600);
  font-size: 0.74rem;
  font-style: normal;
}

.internal-actions-section {
  display: grid;
  gap: 12px;
}

.internal-actions-section > header {
  align-items: end;
  display: flex;
  gap: 16px;
  justify-content: space-between;
  padding: 2px 2px 0;
}

.internal-actions-section > header h2 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  margin: 5px 0 0;
}

.internal-actions-section > header small {
  color: var(--ink-600);
  font-size: 0.76rem;
  font-weight: 680;
}

.internal-distributed-note {
  align-items: start;
  background: var(--forest-50);
  border: 1px solid var(--forest-100);
  border-radius: 12px;
  color: var(--forest-900);
  display: grid;
  gap: 3px;
  padding: 12px 14px;
}

.internal-distributed-note strong {
  font-size: 0.84rem;
}

.internal-distributed-note span {
  color: var(--ink-600);
  font-size: 0.75rem;
}

.internal-work-list {
  display: grid;
  gap: 12px;
}

.internal-work-card {
  align-items: center;
  background: var(--paper);
  border: 1px solid var(--ink-150);
  border-radius: 17px;
  box-shadow: var(--shadow-sm);
  display: grid;
  gap: 24px;
  grid-template-columns: minmax(0, 1fr) auto;
  min-height: 152px;
  padding: 22px 24px;
}

.internal-work-copy {
  min-width: 0;
}

.internal-work-kind {
  color: var(--forest-700);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.internal-work-card h2 {
  font-family: var(--font-display);
  font-size: clamp(1.12rem, 2vw, 1.38rem);
  letter-spacing: -0.025em;
  line-height: 1.15;
  margin: 7px 0 7px;
}

.internal-work-card p {
  color: var(--ink-600);
  margin: 0;
  max-width: 760px;
}

.internal-work-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 14px;
}

.internal-work-meta span {
  background: var(--ink-50);
  border: 1px solid var(--ink-150);
  border-radius: 999px;
  color: var(--ink-700);
  font-size: 0.7rem;
  font-weight: 680;
  padding: 4px 8px;
}

.internal-work-card > .button {
  min-height: 46px;
  white-space: nowrap;
}

.internal-operation-state {
  align-items: center;
  background: var(--paper);
  border: 1px solid var(--ink-150);
  border-radius: 17px;
  display: grid;
  gap: 15px;
  grid-template-columns: 42px minmax(0, 1fr);
  min-height: 150px;
  padding: 24px;
}

.internal-operation-state.is-warning {
  background: var(--amber-50);
  border-color: var(--amber-100);
}

.internal-operation-state.is-good {
  background: var(--forest-50);
  border-color: var(--forest-100);
}

.internal-state-mark {
  align-items: center;
  background: var(--ink-100);
  border-radius: 50%;
  display: inline-flex;
  font-size: 1.05rem;
  font-weight: 800;
  height: 42px;
  justify-content: center;
  width: 42px;
}

.internal-operation-state strong {
  display: block;
  font-size: 1.05rem;
}

.internal-operation-state p {
  color: var(--ink-600);
  margin: 4px 0 0;
}

.internal-operation-state .button {
  margin-top: 14px;
}

.action-check.is-single {
  width: fit-content;
}

@media (max-width: 760px) {
  .internal-role-hero {
    align-items: stretch;
    grid-template-columns: 1fr;
  }

  .internal-role-summary {
    grid-template-columns: auto minmax(0, 1fr);
    max-width: 360px;
  }

  .internal-role-summary small {
    grid-column: 2;
  }

  .internal-work-card {
    align-items: stretch;
    grid-template-columns: 1fr;
  }

  .internal-work-card > .button {
    justify-content: space-between;
    width: 100%;
  }

  .internal-context-block > header,
  .internal-context-history li,
  .internal-actions-section > header {
    align-items: start;
    flex-direction: column;
  }
}

@media (max-width: 600px) {
  .internal-experience-page {
    gap: 12px;
  }

  .internal-role-hero {
    border-radius: 16px;
    gap: 20px;
    padding: 22px 18px;
  }

  .internal-role-hero h1 {
    font-size: 1.85rem;
  }

  .internal-trust-note {
    align-items: start;
    grid-template-columns: 28px minmax(0, 1fr);
  }

  .internal-trust-note .button {
    grid-column: 1 / -1;
    min-height: 44px;
    width: 100%;
  }

  .internal-work-card,
  .internal-operation-state,
  .internal-context-block {
    border-radius: 14px;
    padding: 18px;
  }

  .internal-work-card {
    min-height: 0;
  }
}
.es-login-card {
  display: grid;
  gap: 14px;
  width: min(92vw, 420px);
  padding: 34px 30px;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 24px 60px rgba(5, 24, 20, 0.45);
}
.es-login-brand {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #0f5132;
  color: #ffffff;
  font-weight: 800;
}
.es-login-card h1 { margin: 0; font-size: 22px; }
.es-login-card p { margin: 0; color: #5b6b66; font-size: 13px; line-height: 1.5; }
.es-login-card label { display: grid; gap: 6px; font-size: 12px; font-weight: 700; color: #24413a; }
.es-login-card select, .es-login-card input {
  padding: 11px 12px;
  border: 1px solid #c7d6d0;
  border-radius: 10px;
  font: inherit;
  background: #f7faf9;
}
.es-login-erro { margin: 0; min-height: 16px; color: #b3261e; font-size: 12px; }
.es-login-entrar {
  padding: 12px;
  border: 0;
  border-radius: 10px;
  background: #0f5132;
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}
.es-login-entrar:hover { background: #0b3f27; }
.es-login-selo {
  padding: 10px 12px;
  border-radius: 10px;
  background: #eef6f2;
  color: #40564f;
  font-size: 11px;
  line-height: 1.5;
}

/* ============================================================
   FABLE — A FAIXA VIVA (.fb-*): o que vivia por API, na tela de quem trabalha
   ============================================================ */
.fb-strip {
  display: grid;
  gap: 8px;
  margin: 0 0 18px;
  padding: 14px 16px;
  border: 1px solid #cfe0d8;
  border-left: 4px solid #0f5132;
  border-radius: 14px;
  background: #f4faf7;
}
.fb-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.fb-kicker { font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: #0f5132; }
.fb-badge {
  display: inline-grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: #b3261e;
  color: #fff;
  font-size: 11px;
}
.fb-chip {
  padding: 5px 10px;
  border: 1px solid #d5e3dc;
  border-radius: 999px;
  background: #ffffff;
  color: #1f3d33;
  font-size: 12px;
  cursor: default;
}
.fb-chip.is-lida { opacity: .55; }
.fb-chip.is-alerta { border-color: #ecc9b7; background: #fff3e9; color: #7c3e24; }
.fb-chip[data-fb-ler] { cursor: pointer; }
.fb-btn {
  padding: 6px 12px;
  border: 0;
  border-radius: 9px;
  background: #0f5132;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.fb-btn:hover { background: #0b3f27; }
.fb-in {
  padding: 6px 10px;
  border: 1px solid #c7d6d0;
  border-radius: 9px;
  font: inherit;
  font-size: 12px;
  background: #fff;
}
.fb-hint { font-size: 11px; color: #5b6b66; }
.fb-btn.is-doc { background: #24413a; }
.fb-btn.is-doc:hover { background: #17302a; }

/* FABLE 05/08 — a frase que substitui o indicador sem base de cálculo */
.class-stat-note { display:block; margin:-2px 0 10px; color:#5b6b66; font-size:11px; font-style:italic; }

/* FABLE 05/08 — a chamada por turma na faixa do professor */
.fb-row.is-chamada { align-items: flex-start; }
.fb-aluno { display:inline-flex; align-items:center; gap:4px; margin:2px 8px 2px 0; padding:3px 7px; border:1px solid rgba(15,81,50,.18); border-radius:999px; font-size:12px; }
.fb-aluno.is-feito { background:#eef6f1; border-color:rgba(15,81,50,.32); }
.fb-marca { color:#0f5132; font-size:11px; }
.fb-btn.is-mini { min-width:26px; padding:2px 6px; font-size:11px; line-height:1.4; }

/* FABLE 05/08 (onda L) — a tela de quem tem filho na escola: sem KPI de operação, sem fila de
   staff, sem feed técnico. Cartão por filho, avisos em cima, e as três coisas que a família faz. */
.fam-page { max-width: 720px; margin: 0 auto; }
.fam-topo { margin: 4px 0 18px; }
.fam-topo h1 { font-size: 26px; margin: 4px 0 6px; }
.fam-topo p { color: #5b6b66; font-size: 14px; margin: 0; }
.fam-avisos { margin-bottom: 18px; }
.fam-avisos h2 { font-size: 14px; text-transform: uppercase; letter-spacing: .06em; color: #0f5132; margin: 0 0 8px; }
.fam-aviso { border: 1px solid rgba(15,81,50,.16); border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; background: #fff; }
.fam-aviso.is-novo { border-color: rgba(15,81,50,.42); background: #f2f9f5; }
.fam-aviso strong { display: block; font-size: 14px; }
.fam-aviso p { margin: 2px 0 6px; font-size: 13px; color: #41564c; }
.fam-card { border: 1px solid rgba(15,81,50,.18); border-radius: 16px; padding: 16px 18px; margin-bottom: 14px; background: #fff; }
.fam-card header h2 { margin: 0; font-size: 19px; }
.fam-card header p { margin: 2px 0 12px; color: #5b6b66; font-size: 13px; }
.fam-linha { display: flex; justify-content: space-between; align-items: baseline; padding: 7px 0; border-top: 1px solid rgba(15,81,50,.1); font-size: 14px; }
.fam-linha span { color: #5b6b66; }
.fam-linha.is-atencao strong { color: #a4442a; }
.fam-nota { font-size: 12px; color: #5b6b66; font-style: italic; margin: 6px 0 0; }
.fam-acoes { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
@media (max-width: 520px) { .fam-acoes .fb-btn { flex: 1 1 auto; } }

/* ============================================================
   EXPERIÊNCIA PÚBLICA V1 — responsável e aluno
   Poucas escolhas, frases diretas, toque confortável e ausência de dado dita em voz alta.
   ============================================================ */
body.is-public-experience {
  --content-max: 1180px;
  background:
    radial-gradient(circle at 86% 8%, rgba(229, 240, 186, .28), transparent 25rem),
    #f5f6f2;
}

.is-public-experience .sidebar {
  background: #103b34;
}

.is-public-experience .school-context {
  margin-bottom: 12px;
}

.is-public-experience .primary-nav {
  gap: 6px;
}

.public-nav-item {
  min-height: 58px;
  grid-template-columns: 31px minmax(0, 1fr);
}

.public-nav-item > span:nth-child(2) {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.public-nav-item strong {
  font-size: 13px;
}

.public-nav-item small {
  overflow: hidden;
  color: rgba(238, 248, 244, .48);
  font-size: 9px;
  font-weight: 500;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.public-nav-item.is-active small {
  color: rgba(247, 251, 220, .65);
}

.is-public-experience .topbar {
  min-height: 66px;
  border-bottom-color: rgba(16, 59, 52, .08);
  box-shadow: 0 3px 18px rgba(16, 59, 52, .035);
}

.is-public-experience .connection-pill,
.is-public-experience .refresh-button {
  display: none;
}

.is-public-experience #main-content {
  padding-top: clamp(26px, 4vw, 54px);
}

.public-page {
  max-width: 1040px;
  margin: 0 auto;
  gap: 26px;
}

.public-page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.public-page-header h1 {
  max-width: 760px;
  margin: 0 0 8px;
  color: var(--forest-950);
  font-family: var(--font-display);
  font-size: clamp(30px, 4.6vw, 48px);
  font-weight: 720;
  letter-spacing: -.045em;
  line-height: 1.04;
}

.public-page-header p {
  max-width: 690px;
  margin: 0;
  color: var(--ink-600);
  font-size: clamp(14px, 1.5vw, 16px);
}

.public-signout {
  min-height: 44px;
  flex: 0 0 auto;
  border: 1px solid var(--ink-200);
  border-radius: 11px;
  background: rgba(255, 255, 255, .68);
  color: var(--ink-700);
  font-size: 12px;
  font-weight: 750;
  padding: 9px 13px;
}

.public-signout:hover {
  border-color: var(--forest-600);
  background: var(--paper);
  color: var(--forest-800);
}

.public-honesty {
  display: grid;
  gap: 2px;
  border: 1px solid var(--amber-100);
  border-radius: 12px;
  background: var(--amber-50);
  color: var(--amber-800);
  padding: 12px 14px;
}

.public-honesty strong {
  font-size: 13px;
}

.public-honesty span {
  font-size: 12px;
}

.public-welcome,
.student-now {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(320px, 1.1fr);
  gap: 24px;
  align-items: center;
  overflow: hidden;
  border: 1px solid rgba(16, 59, 52, .11);
  border-radius: 22px;
  background: linear-gradient(145deg, #eef6e1, #f8faf1 62%, #fff);
  box-shadow: var(--shadow-sm);
  padding: clamp(20px, 3.4vw, 34px);
}

.public-welcome h2,
.student-now h2 {
  margin: 0 0 7px;
  color: var(--forest-950);
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: -.035em;
  line-height: 1.08;
}

.public-welcome p,
.student-now p {
  margin: 0;
  color: var(--ink-600);
}

.public-next-steps {
  display: grid;
  gap: 8px;
}

.public-next-steps a {
  min-height: 64px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  border: 1px solid rgba(16, 59, 52, .1);
  border-radius: 14px;
  background: rgba(255, 255, 255, .84);
  padding: 10px 13px;
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
}

.public-next-steps a:hover {
  border-color: rgba(47, 125, 108, .35);
  box-shadow: 0 8px 20px rgba(13, 37, 32, .07);
  transform: translateY(-1px);
}

.public-next-steps a > span:last-child {
  color: var(--forest-700);
  font-size: 22px;
}

.public-next-steps a div {
  display: grid;
}

.public-next-steps a strong {
  font-size: 14px;
}

.public-next-steps a small {
  color: var(--ink-600);
  font-size: 11px;
}

.public-step-mark,
.public-all-good > span {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: var(--forest-100);
  color: var(--forest-800);
  font-size: 11px;
  font-weight: 900;
}

.public-all-good {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px dashed rgba(16, 59, 52, .18);
  border-radius: 14px;
  color: var(--forest-800);
}

.public-section {
  overflow: hidden;
  border: 1px solid rgba(16, 59, 52, .105);
  border-radius: 19px;
  background: rgba(255, 255, 255, .88);
  box-shadow: var(--shadow-sm);
  padding: clamp(18px, 2.5vw, 26px);
}

.public-section > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 17px;
}

.public-section > header h2 {
  margin: 0;
  color: var(--ink-950);
  font-family: var(--font-display);
  font-size: clamp(19px, 2.2vw, 25px);
  letter-spacing: -.025em;
}

.public-section > header p {
  max-width: 650px;
  margin: 5px 0 0;
  color: var(--ink-600);
  font-size: 13px;
}

.public-section > header > a {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  border-radius: 9px;
  color: var(--forest-700);
  font-size: 12px;
  font-weight: 800;
  padding: 7px 9px;
}

.public-section > header > a:hover {
  background: var(--forest-50);
}

.public-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.public-person-card {
  min-width: 0;
  border: 1px solid var(--ink-150);
  border-radius: 17px;
  background: var(--paper);
  padding: 17px;
}

.public-person-card > header {
  display: flex;
  align-items: center;
  gap: 11px;
  margin-bottom: 14px;
}

.public-person-card > header div {
  min-width: 0;
}

.public-person-card > header h2 {
  overflow: hidden;
  margin: 0;
  color: var(--ink-950);
  font-size: 18px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.public-person-card > header p {
  margin: 2px 0 0;
  color: var(--ink-600);
  font-size: 12px;
}

.public-avatar {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border-radius: 13px;
  background: #eaf2d5;
  color: var(--forest-900);
  font-size: 15px;
  font-weight: 900;
}

.public-facts {
  display: grid;
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--ink-150);
  border-radius: 12px;
  background: var(--ink-150);
}

.public-fact {
  min-width: 0;
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  align-items: baseline;
  column-gap: 9px;
  background: var(--ink-50);
  padding: 10px 11px;
}

.public-fact > span {
  color: var(--ink-500);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.public-fact > strong {
  color: var(--ink-800);
  font-size: 13px;
}

.public-fact > small {
  grid-column: 2;
  margin-top: 2px;
  color: var(--ink-500);
  font-size: 10px;
}

.public-fact.is-good > strong {
  color: var(--forest-700);
}

.public-fact.is-attention > strong {
  color: var(--red-800);
}

.public-link {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
  border-radius: 9px;
  color: var(--forest-700);
  font-size: 12px;
  font-weight: 800;
  padding: 7px 9px;
}

.public-link:hover {
  background: var(--forest-50);
}

.public-link span {
  font-size: 21px;
}

.public-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.public-button {
  min-height: 44px;
  border: 1px solid var(--ink-200);
  border-radius: 10px;
  background: var(--paper);
  color: var(--ink-800);
  font-size: 12px;
  font-weight: 800;
  padding: 9px 13px;
}

.public-button:hover:not(:disabled) {
  border-color: var(--forest-600);
  color: var(--forest-800);
}

.public-button.is-primary {
  border-color: var(--forest-800);
  background: var(--forest-800);
  color: #fff;
}

.public-button.is-primary:hover:not(:disabled) {
  border-color: var(--forest-950);
  background: var(--forest-950);
  color: #fff;
}

.public-button.is-quiet {
  background: var(--forest-50);
  color: var(--forest-800);
}

.public-action-help {
  margin: 9px 0 0;
  color: var(--ink-500);
  font-size: 11px;
  line-height: 1.45;
}

.public-notice-list {
  display: grid;
  gap: 9px;
}

.public-notice {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  border: 1px solid var(--ink-150);
  border-radius: 13px;
  background: var(--ink-50);
  padding: 13px 14px;
}

.public-notice.is-new {
  border-color: rgba(47, 125, 108, .28);
  background: var(--forest-50);
}

.public-notice > div {
  min-width: 0;
}

.public-notice > div > span {
  color: var(--forest-700);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.public-notice h3 {
  margin: 3px 0 2px;
  color: var(--ink-900);
  font-size: 14px;
}

.public-notice p {
  margin: 0;
  color: var(--ink-600);
  font-size: 12px;
}

.public-notice time {
  display: block;
  margin-top: 6px;
  color: var(--ink-500);
  font-size: 10px;
}

.public-empty {
  min-height: 150px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 5px;
  border: 1px dashed var(--ink-200);
  border-radius: 15px;
  background: rgba(247, 248, 246, .72);
  padding: 24px;
  text-align: center;
}

.public-empty > span {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: var(--forest-100);
  color: var(--forest-800);
  font-weight: 900;
}

.public-empty.is-attention > span {
  background: var(--amber-100);
  color: var(--amber-800);
}

.public-empty strong {
  color: var(--ink-800);
  font-size: 14px;
}

.public-empty p {
  max-width: 540px;
  margin: 0;
  color: var(--ink-600);
  font-size: 12px;
}

.public-empty .public-button {
  margin-top: 7px;
}

.public-form-section {
  background: linear-gradient(145deg, #fff, var(--forest-50));
}

.public-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 13px;
  align-items: end;
}

.public-form-grid label {
  display: grid;
  gap: 6px;
}

.public-form-grid label > span {
  color: var(--ink-700);
  font-size: 11px;
  font-weight: 800;
}

.public-input {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--ink-200);
  border-radius: 10px;
  background: var(--paper);
  padding: 10px 12px;
  outline: 0;
}

.public-input:focus {
  border-color: var(--forest-600);
  box-shadow: 0 0 0 3px rgba(47, 125, 108, .14);
}

.public-form-submit {
  justify-self: start;
}

.public-document-list,
.public-charge-list,
.public-rematriculation,
.student-result-list,
.student-support-list,
.student-schedule {
  display: grid;
  gap: 9px;
}

.public-document-list > article,
.public-rematriculation > article {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  border: 1px solid var(--ink-150);
  border-radius: 13px;
  background: var(--ink-50);
  padding: 11px 13px;
}

.public-document-list > article > div:first-child,
.public-rematriculation > article > div:first-child {
  display: grid;
  min-width: 0;
}

.public-document-list strong,
.public-rematriculation strong {
  color: var(--ink-900);
  font-size: 13px;
}

.public-document-list span,
.public-rematriculation span {
  color: var(--ink-600);
  font-size: 11px;
}

.public-document-list .public-actions {
  flex: 0 0 auto;
  margin: 0;
}

.public-finance-note {
  display: grid;
  gap: 2px;
  border: 1px solid var(--blue-100);
  border-radius: 13px;
  background: var(--blue-50);
  color: var(--blue-700);
  padding: 13px 15px;
}

.public-finance-note strong {
  font-size: 13px;
}

.public-finance-note span {
  font-size: 12px;
}

.public-charge {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border: 1px solid var(--ink-150);
  border-radius: 13px;
  background: var(--ink-50);
  padding: 12px 14px;
}

.public-charge > div {
  display: grid;
  gap: 2px;
}

.public-charge > div:last-child {
  flex: 0 0 auto;
  text-align: right;
}

.public-charge span,
.public-charge small {
  color: var(--ink-600);
  font-size: 10px;
}

.public-charge strong {
  color: var(--ink-900);
  font-size: 13px;
}

.public-charge.is-attention > div:last-child strong,
.public-charge.is-attention > div:last-child span {
  color: var(--red-800);
}

.public-done {
  flex: 0 0 auto;
  border-radius: 99px;
  background: var(--forest-100);
  color: var(--forest-800) !important;
  font-weight: 800;
  padding: 6px 10px;
}

.student-now {
  grid-template-columns: minmax(0, 1fr) minmax(220px, .45fr);
}

.student-presence {
  display: grid;
  gap: 3px;
  border: 1px solid rgba(16, 59, 52, .12);
  border-radius: 15px;
  background: rgba(255, 255, 255, .8);
  padding: 17px;
}

.student-presence > span {
  color: var(--ink-500);
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
}

.student-presence strong {
  color: var(--ink-800);
  font-size: 16px;
}

.student-presence small {
  color: var(--ink-600);
  font-size: 11px;
}

.student-presence.is-good strong {
  color: var(--forest-700);
}

.student-presence.is-attention strong {
  color: var(--red-800);
}

.student-schedule > article {
  min-height: 62px;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--ink-150);
  padding: 8px 4px;
}

.student-schedule > article:last-child {
  border-bottom: 0;
}

.student-schedule time {
  color: var(--forest-700);
  font-size: 13px;
  font-weight: 900;
}

.student-schedule div {
  display: grid;
}

.student-schedule div strong {
  font-size: 13px;
}

.student-schedule div span,
.student-schedule > article > span {
  color: var(--ink-600);
  font-size: 11px;
}

.student-result-list > article {
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--ink-150);
  padding: 9px 3px;
}

.student-result-list > article:last-child {
  border-bottom: 0;
}

.student-result-list > article div {
  display: grid;
}

.student-result-list > article div strong {
  color: var(--ink-900);
  font-size: 13px;
}

.student-result-list > article div span {
  color: var(--ink-600);
  font-size: 11px;
}

.student-result-list > article > strong {
  min-width: 58px;
  border-radius: 10px;
  background: var(--forest-50);
  color: var(--forest-800);
  font-size: 14px;
  padding: 9px;
  text-align: center;
}

.student-support-list article {
  border: 1px solid var(--ink-150);
  border-radius: 12px;
  background: var(--ink-50);
  padding: 12px 13px;
}

.student-support-list strong {
  color: var(--ink-900);
  font-size: 13px;
}

.student-support-list p {
  margin: 3px 0 0;
  color: var(--ink-600);
  font-size: 12px;
}

.student-service-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.student-service-grid article {
  min-height: 190px;
  display: grid;
  align-content: start;
  gap: 7px;
  border: 1px solid rgba(16, 59, 52, .11);
  border-radius: 17px;
  background: var(--paper);
  box-shadow: var(--shadow-sm);
  padding: 20px;
}

.student-service-grid article > span {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: #eaf2d5;
  color: var(--forest-800);
  font-size: 10px;
  font-weight: 900;
}

.student-service-grid h2 {
  margin: 8px 0 0;
  color: var(--ink-900);
  font-size: 17px;
}

.student-service-grid p {
  min-height: 38px;
  margin: 0;
  color: var(--ink-600);
  font-size: 12px;
}

.student-service-grid strong {
  color: var(--forest-700);
  font-size: 12px;
}

.student-library-service ul {
  display: grid;
  gap: 8px;
  list-style: none;
  margin: 6px 0 0;
  padding: 0;
}

.student-library-service li {
  border-top: 1px solid var(--ink-100);
  display: grid;
  gap: 4px;
  padding-top: 8px;
}

.student-library-service li span {
  display: flex;
  gap: 8px;
  justify-content: space-between;
}

.student-library-service li small,
.student-library-service li em,
.student-library-service > small {
  color: var(--ink-600);
  font-size: 11px;
  font-style: normal;
  line-height: 1.35;
}

@media (max-width: 820px) {
  .public-welcome,
  .student-now {
    grid-template-columns: 1fr;
  }

  .public-card-grid {
    grid-template-columns: 1fr;
  }

  .student-service-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 600px) {
  .is-public-experience .menu-button {
    width: 44px;
    height: 44px;
  }

  .is-public-experience #main-content {
    padding: 22px 12px 44px;
  }

  .public-page {
    gap: 17px;
  }

  .public-page-header {
    display: grid;
    gap: 14px;
  }

  .public-signout {
    justify-self: start;
  }

  .public-welcome,
  .student-now,
  .public-section {
    border-radius: 16px;
    padding: 17px;
  }

  .public-section > header {
    align-items: center;
  }

  .public-person-card {
    padding: 14px;
  }

  .public-fact {
    grid-template-columns: 68px minmax(0, 1fr);
  }

  .public-actions .public-button {
    width: 100%;
  }

  .public-notice,
  .public-document-list > article,
  .public-rematriculation > article,
  .public-charge {
    align-items: stretch;
    flex-direction: column;
  }

  .public-notice .public-button,
  .public-document-list .public-button,
  .public-rematriculation .public-button {
    width: 100%;
  }

  .public-document-list .public-actions {
    width: 100%;
  }

  .public-charge > div:last-child {
    text-align: left;
  }

  .public-form-grid {
    grid-template-columns: 1fr;
  }

  .public-form-submit {
    width: 100%;
  }

  .student-schedule > article {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  .student-schedule > article > span {
    grid-column: 2;
  }

  .student-service-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   IDENTIDADE ESCOLA V17
   Azul para orientar e acolher; verde fica reservado a sucesso e seguranca.
   A camada muda somente a expressao visual, sem alterar fluxos ou medidas.
   ============================================================ */
:root {
  --ink-950: #17283a;
  --ink-900: #22364b;
  --ink-800: #364b61;
  --ink-700: #4d6277;
  --ink-600: #64778a;
  --ink-500: #7c8c9c;
  --ink-300: #b9c4ce;
  --ink-200: #d5dee6;
  --ink-150: #e2e8ed;
  --ink-100: #edf1f4;
  --ink-50: #f7f9fa;
  --paper: #fffefd;
  --canvas: #f7f5ef;
  --school-950: #10243a;
  --school-900: #163b61;
  --school-800: #1e4f7d;
  --school-700: #2a6599;
  --school-600: #3f7fb0;
  --school-100: #dce9f4;
  --school-50: #eef5fa;
  --school-gold-700: #8b610d;
  --school-gold-500: #f1c75b;
  --school-gold-100: #f6e6b7;
  --school-gold-50: #fff9e8;
  --school-coral-700: #a84f43;
  --school-coral-500: #d97562;
  --school-coral-100: #f4d9d2;
  --school-coral-50: #fff3ef;
  --school-violet-700: #65558e;
  --school-violet-100: #e7e0f2;
  --school-violet-50: #f6f3fb;
  --success-800: #1d604b;
  --success-700: #28765b;
  --success-100: #d8ece3;
  --success-50: #eff8f4;
  --shadow-sm: 0 1px 2px rgba(27, 57, 83, 0.045), 0 8px 24px rgba(27, 57, 83, 0.055);
  --shadow-md: 0 20px 52px rgba(24, 54, 80, 0.16);
}

body {
  background:
    radial-gradient(circle at 96% 2%, rgba(220, 233, 244, 0.62), transparent 25rem),
    radial-gradient(circle at 8% 96%, rgba(246, 230, 183, 0.34), transparent 28rem),
    var(--canvas);
}

:focus-visible {
  outline-color: rgba(42, 101, 153, 0.42);
}

.sidebar,
.is-public-experience .sidebar {
  background:
    radial-gradient(circle at 10% 4%, rgba(241, 199, 91, 0.13), transparent 13rem),
    linear-gradient(180deg, #173f65 0%, #102e4b 68%, #0e2944 100%);
  color: #f4f8fb;
}

.brand-mark {
  border-color: rgba(255, 255, 255, 0.42);
  background: var(--school-gold-500);
  color: var(--school-950);
  box-shadow: 0 6px 16px rgba(5, 29, 50, 0.18);
}

.brand-copy small,
.school-context small,
.sidebar-proof small {
  color: rgba(235, 244, 250, 0.66);
}

.school-context {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.075);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.04);
}

.nav-label {
  color: rgba(232, 241, 248, 0.64);
}

.nav-item {
  color: rgba(235, 243, 249, 0.76);
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.085);
}

.nav-item.is-active {
  border-color: rgba(246, 230, 183, 0.28);
  background: rgba(255, 255, 255, 0.13);
  box-shadow: inset 3px 0 0 var(--school-gold-500);
  color: #ffffff;
}

.nav-glyph {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.07);
  color: rgba(237, 245, 250, 0.76);
}

.nav-item.is-active .nav-glyph {
  border-color: rgba(241, 199, 91, 0.64);
  background: var(--school-gold-500);
  color: var(--school-950);
}

.nav-count {
  background: var(--school-gold-500);
  color: var(--school-950);
}

.primary-nav[data-navigation-mode="compact-internal"] .nav-item small,
.public-nav-item small {
  color: rgba(232, 241, 248, 0.62);
}

.primary-nav[data-navigation-mode="compact-internal"] .nav-item.is-active small,
.public-nav-item.is-active small {
  color: rgba(255, 255, 255, 0.79);
}

.proof-mark {
  background: rgba(216, 236, 227, 0.13);
}

.proof-mark::before {
  border-color: #9dd4bd;
}

.topbar,
.is-public-experience .topbar {
  border-bottom-color: rgba(30, 79, 125, 0.10);
  background: rgba(255, 254, 251, 0.92);
  box-shadow: 0 5px 24px rgba(24, 54, 80, 0.045);
}

.connection-pill {
  border-color: var(--school-100);
  background: var(--school-50);
  color: var(--school-800);
}

.role-avatar {
  background: var(--school-100);
  color: var(--school-900);
}

.role-control {
  border-color: var(--school-100);
  box-shadow: 0 3px 12px rgba(24, 54, 80, 0.04);
}

.eyebrow,
.internal-work-kind,
.public-notice > div > span,
.student-schedule time {
  color: var(--school-700);
}

.button.is-primary,
.public-button.is-primary,
.es-login-entrar,
.fb-btn {
  border-color: var(--school-800);
  background: var(--school-800);
  color: #fff;
}

.button.is-primary:hover:not(:disabled),
.public-button.is-primary:hover:not(:disabled),
.es-login-entrar:hover,
.fb-btn:hover {
  border-color: var(--school-950);
  background: var(--school-950);
  color: #fff;
}

.icon-button:hover:not(:disabled),
.public-signout:hover,
.public-button:hover:not(:disabled) {
  border-color: var(--school-600);
  color: var(--school-800);
}

.internal-role-hero {
  background:
    radial-gradient(circle at 88% 12%, rgba(241, 199, 91, 0.42), transparent 18%),
    radial-gradient(circle at 76% 105%, rgba(217, 117, 98, 0.30), transparent 25%),
    linear-gradient(128deg, var(--school-950) 0%, var(--school-800) 58%, #397f9d 100%);
  box-shadow: 0 20px 46px rgba(30, 79, 125, 0.17);
}

.internal-role-hero .eyebrow {
  color: rgba(255, 247, 219, 0.82);
}

.internal-role-summary {
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.10);
}

.internal-trust-note,
.internal-distributed-note {
  border-color: var(--school-100);
  background: var(--school-50);
  color: var(--school-900);
}

.internal-trust-note > span {
  background: var(--school-700);
}

.internal-context-block,
.internal-work-card,
.section-card,
.public-section,
.public-person-card {
  border-color: #dfe6eb;
  background: rgba(255, 254, 252, 0.96);
  box-shadow: var(--shadow-sm);
}

.internal-context-metric {
  border-color: var(--school-100);
  background: var(--school-50);
}

.internal-context-metric:nth-child(4n + 2) {
  border-color: var(--success-100);
  background: var(--success-50);
}

.internal-context-metric:nth-child(4n + 3) {
  border-color: var(--school-gold-100);
  background: var(--school-gold-50);
}

.internal-context-metric:nth-child(4n + 4) {
  border-color: var(--school-violet-100);
  background: var(--school-violet-50);
}

.internal-work-card {
  border-left: 4px solid var(--school-100);
  background:
    linear-gradient(90deg, rgba(220, 233, 244, 0.38), rgba(255, 254, 252, 0.96) 20%);
}

.internal-work-meta span {
  border-color: var(--school-100);
  background: var(--school-50);
  color: var(--school-800);
}

.es-login-gate {
  background:
    radial-gradient(circle at 15% 18%, rgba(241, 199, 91, 0.48), transparent 18rem),
    radial-gradient(circle at 84% 78%, rgba(63, 127, 176, 0.28), transparent 26rem),
    linear-gradient(135deg, #e9f2f7 0%, #f8f2e7 52%, #f1f6f8 100%);
}

.es-login-card {
  border: 1px solid rgba(30, 79, 125, 0.12);
  border-radius: 24px;
  background: rgba(255, 254, 252, 0.96);
  box-shadow: 0 28px 70px rgba(22, 59, 97, 0.22);
}

.es-login-brand {
  background: var(--school-gold-500);
  color: var(--school-950);
  box-shadow: 0 7px 18px rgba(22, 59, 97, 0.14);
}

.es-login-card h1 {
  color: var(--school-950);
}

.es-login-card label {
  color: var(--ink-800);
}

.es-login-card select,
.es-login-card input {
  border-color: var(--school-100);
  background: var(--school-50);
}

.es-login-card select:focus,
.es-login-card input:focus,
.public-input:focus,
.action-field input:focus,
.action-field select:focus,
.action-field textarea:focus {
  border-color: var(--school-600);
  box-shadow: 0 0 0 3px rgba(63, 127, 176, 0.16);
}

.es-login-selo {
  background: var(--school-50);
  color: var(--school-800);
}

.fb-strip,
.fam-aviso.is-novo {
  border-color: var(--school-100);
  border-left-color: var(--school-700);
  background: var(--school-50);
}

.fb-kicker,
.fam-avisos h2,
.fb-marca {
  color: var(--school-800);
}

body.is-public-experience {
  background:
    radial-gradient(circle at 88% 7%, rgba(241, 199, 91, 0.30), transparent 25rem),
    radial-gradient(circle at 6% 90%, rgba(231, 224, 242, 0.52), transparent 30rem),
    #f8f6f0;
}

.public-page-header h1,
.public-welcome h2,
.student-now h2 {
  color: var(--school-950);
}

.public-welcome {
  border-color: rgba(42, 101, 153, 0.18);
  background:
    radial-gradient(circle at 91% 18%, rgba(241, 199, 91, 0.40), transparent 22%),
    linear-gradient(145deg, #eaf3f8, #f7f8f3 62%, #fffefd);
}

.student-now {
  border-color: rgba(101, 85, 142, 0.17);
  background:
    radial-gradient(circle at 90% 15%, rgba(217, 117, 98, 0.22), transparent 22%),
    linear-gradient(145deg, #eef4fa, var(--school-violet-50) 68%, #fffefd);
}

.public-next-steps a,
.student-presence {
  border-color: var(--school-100);
  background: rgba(255, 254, 252, 0.88);
}

.public-next-steps a:hover {
  border-color: var(--school-600);
  box-shadow: 0 10px 24px rgba(30, 79, 125, 0.09);
}

.public-next-steps a > span:last-child,
.public-link,
.public-section > header > a,
.student-service-grid strong {
  color: var(--school-700);
}

.public-next-steps a:hover,
.public-section > header > a:hover,
.public-link:hover {
  background: var(--school-50);
}

.public-step-mark,
.public-empty > span {
  background: var(--school-100);
  color: var(--school-900);
}

.public-avatar {
  background: var(--school-gold-100);
  color: var(--school-900);
}

.public-notice.is-new {
  border-color: rgba(42, 101, 153, 0.28);
  background: var(--school-50);
}

.public-form-section {
  background: linear-gradient(145deg, #fffefd, var(--school-50));
}

.student-result-list > article > strong {
  background: var(--school-50);
  color: var(--school-800);
}

.student-service-grid article {
  border-color: var(--school-100);
  background: linear-gradient(150deg, #fffefd, var(--school-50));
}

.student-service-grid article:nth-child(2) {
  border-color: var(--school-gold-100);
  background: linear-gradient(150deg, #fffefd, var(--school-gold-50));
}

.student-service-grid article:nth-child(3) {
  border-color: var(--school-violet-100);
  background: linear-gradient(150deg, #fffefd, var(--school-violet-50));
}

.student-service-grid article > span {
  background: var(--school-100);
  color: var(--school-900);
}

.student-service-grid article:nth-child(2) > span {
  background: var(--school-gold-100);
  color: var(--school-gold-700);
}

.student-service-grid article:nth-child(3) > span {
  background: var(--school-violet-100);
  color: var(--school-violet-700);
}

/* Verde semantico: bom, concluido, conectado ou comprovado. */
.status-dot.is-live {
  background: #61bd97;
  box-shadow: 0 0 0 4px rgba(97, 189, 151, 0.18);
}

.mode-banner.is-live,
.internal-operation-state.is-good {
  border-color: var(--success-100);
  background: var(--success-50);
  color: var(--success-800);
}

.mode-banner.is-live .mode-mark {
  background: rgba(40, 118, 91, 0.11);
}

.mini-badge.is-proof,
.status-badge.is-good,
.matrix-score.is-good,
.public-done {
  border-color: var(--success-100);
  background: var(--success-50);
  color: var(--success-700) !important;
}

.kpi-card.is-good {
  border-top-color: var(--success-700);
}

.public-fact.is-good > strong,
.student-presence.is-good strong {
  color: var(--success-700);
}

@media (max-width: 600px) {
  .internal-role-hero {
    background:
      radial-gradient(circle at 92% 8%, rgba(241, 199, 91, 0.34), transparent 24%),
      linear-gradient(145deg, var(--school-950), var(--school-800));
    gap: 16px;
    padding: 20px 17px;
  }

  .internal-role-summary {
    padding: 14px;
  }

  .es-login-card {
    border-radius: 19px;
  }
}
