body.dash {
  --bg-main: #071A2B;
  --bg-secondary: #0B243B;
  --surface: #102E4A;
  --surface-hover: #153B5C;
  --border: #285D87;
  --border-light: #3977A7;
  --text: #F7FAFC;
  --text-secondary: #B8CBE0;
  --primary: #20E6B2;
  --primary-light: #53F3C2;
  --radius-sm: 10px;
  --radius-md: 13px;
  --radius-lg: 16px;
  --glow-primary: 0 0 18px rgba(32, 230, 178, 0.25);
  font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
  background:
    radial-gradient(circle at 8% 10%, rgba(83, 243, 194, 0.08), transparent 22%),
    radial-gradient(circle at 94% 6%, rgba(57, 168, 255, 0.1), transparent 18%),
    radial-gradient(circle at 90% 88%, rgba(255, 201, 40, 0.05), transparent 20%),
    var(--bg-main);
  color: var(--text);
  min-height: 100%;
}
body.dash::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(#53F3C2 1.1px, transparent 1.2px);
  background-size: 26px 26px;
  opacity: 0.12;
  z-index: 0;
}
body.dash .wrap {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: min(880px, 100%);
  padding: 20px 16px calc(100px + env(safe-area-inset-bottom, 0px));
}
body.dash .wrap.grade-wide {
  max-width: min(1520px, 100%);
  width: 100%;
  padding-left: 16px;
  padding-right: 16px;
}
body.dash a { color: var(--primary-light); }
body.dash button, body.dash select, body.dash input { font-family: inherit; }
body.dash button {
  cursor: pointer;
  border: 1px solid #3475A8;
  background: linear-gradient(180deg, #153553, #102A43);
  color: #F5F8FC;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
}
body.dash button.on,
body.dash button.primary {
  background: linear-gradient(135deg, #53F3C2, #20E6B2);
  color: #041B22;
  border-color: transparent;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08), var(--glow-primary);
  font-weight: 800;
}
body.dash button.ghost {
  background: linear-gradient(180deg, #153553, #102A43);
  border: 1px solid #3475A8;
  color: #F5F8FC;
}
body.dash select, body.dash input {
  background: #102B45;
  border: 1px solid #3974A0;
  color: #fff;
  border-radius: 12px;
  min-height: 48px;
  padding: 14px 18px;
  width: 100%;
  overflow: visible;
  line-height: 1.35;
}
body.dash input[type="checkbox"],
body.dash input[type="radio"] {
  width: 16px;
  height: 16px;
  min-width: 16px;
  min-height: 16px;
  max-width: 16px;
  padding: 0;
  margin: 0;
  border-radius: 4px;
  flex: 0 0 16px;
  appearance: auto;
  accent-color: #20E6B2;
  background: transparent;
  line-height: 1;
  overflow: hidden;
}
body.dash input[type="date"] { padding-left: 18px; padding-right: 14px; }
body.dash .muted { color: var(--text-secondary); }
body.dash .err { background: #3a1c1c; color: #f0b4b4; }

.deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}
.deco-books {
  position: absolute;
  right: 4px;
  top: -6px;
  width: 86px;
  height: 72px;
  opacity: 0.85;
}
.deco-cal {
  position: absolute;
  right: 92px;
  top: 8px;
  width: 34px;
  height: 34px;
  opacity: 0.28;
  color: var(--primary-light);
}
.deco-plane {
  position: absolute;
  left: 8px;
  bottom: 18px;
  width: 28px;
  height: 28px;
  opacity: 0.22;
  color: var(--text-secondary);
}
.dash-head {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 4px 0 16px;
}
.dash-head::before {
  content: "";
  width: 8px;
  height: 28px;
  border-radius: 99px;
  background: linear-gradient(180deg, #53F3C2, #20E6B2);
  box-shadow: 0 0 12px rgba(32, 230, 178, 0.45);
  flex: 0 0 auto;
}
.dash-head h1 {
  font-size: clamp(1.45rem, 4.5vw, 2rem);
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.15;
  margin: 0;
}

body.dash .banner {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  background: linear-gradient(90deg, #33250A 0%, #3E2D0C 55%, #49320A 100%);
  border: 2px solid #FFC928;
  box-shadow: 0 0 12px rgba(255, 201, 40, 0.25);
  border-radius: 14px;
  color: #fff6d0;
  padding: 14px 16px;
  margin-bottom: 14px;
}
.banner-ico {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #FFC928;
  color: #2a1c04;
  font-weight: 800;
  font-size: 1.1rem;
  box-shadow: 0 0 10px rgba(255, 201, 40, 0.45);
}
body.dash .banner b {
  display: block;
  margin-bottom: 4px;
  font-size: 1.02rem;
  font-weight: 800;
  color: #fff;
}
body.dash .banner span.banner-txt {
  display: block;
  color: #f3e6b8;
  font-weight: 500;
  font-size: 0.92rem;
  line-height: 1.35;
}

.seg-row,
.turno-row,
.filter-row {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 8px;
  margin: 10px 0;
}
.seg-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.turno-row {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.filter-row {
  grid-template-columns: 1fr;
}
.filter-row.hoje-filters {
  grid-template-columns: 1fr;
}
.seg-btn,
.turno-row button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  font-size: 0.95rem;
}
.seg-btn .ico,
.turno-row .ico,
.sel-ico .ico,
.print-btn .ico {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}
.sel {
  position: relative;
  margin: 10px 0 0;
}
.filter-row { margin-top: 10px; }
.filter-row .sel { margin: 0; }
.sel-ico {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  pointer-events: none;
  display: grid;
  place-items: center;
}
body.dash .sel select { padding-left: 42px; padding-right: 28px; }
.print-btn {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 48px;
  margin: 10px 0 14px;
  background: linear-gradient(90deg, #173A5C, #12324F);
  border: 1px solid #3778A9;
  color: #fff;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.day-label {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.92rem;
  margin: 4px 0 12px;
}
.day-label .ico { width: 16px; height: 16px; color: var(--primary-light); }

body.dash .list {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.aula-card {
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 0;
  min-height: 110px;
  padding: 14px 88px 14px 0;
  border-radius: 16px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  background: #16324A;
  color: #F4F7FB;
  border: 2px solid transparent;
}
.aula-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 78% 120%, rgba(255, 255, 255, 0.22), transparent 42%),
    radial-gradient(circle at 100% 0%, rgba(255, 255, 255, 0.16), transparent 36%);
  pointer-events: none;
}
.aula-card.face-ink::before { display: none; }
.aula-when,
.aula-info {
  position: relative;
  z-index: 1;
}
.aula-when {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4px 12px 4px 16px;
  border-right: 2px solid rgba(16, 36, 19, 0.18);
  font-weight: 700;
}
.aula-n { font-size: 1.15rem; line-height: 1.1; }
.aula-h {
  margin-top: 4px;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.2;
  opacity: 0.78;
}
.aula-info {
  padding: 6px 14px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}
.aula-disc {
  font-size: 1.18rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.2;
}
.aula-prof {
  margin-top: 4px;
  font-size: 0.95rem;
  font-weight: 400;
  opacity: 0.92;
}
.aula-note {
  margin-top: 3px;
  font-size: 0.82rem;
  font-weight: 700;
  opacity: 0.78;
}
.aula-ico {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 78px;
  height: 78px;
  opacity: 0.28;
  pointer-events: none;
  z-index: 0;
}
.aula-ico svg { width: 100%; height: 100%; }

.aula-card.kind-edfis {
  background: linear-gradient(100deg, #C6FF77 0%, #B4F879 60%, #8BE85D 100%);
  border: 2px solid #CFFF65;
  box-shadow: 0 0 14px rgba(184, 255, 103, 0.2);
  color: #102413;
}
.aula-card.kind-hist {
  background: linear-gradient(100deg, #FFB05E 0%, #FF9C58 58%, #FF8050 100%);
  border: 2px solid #FFB641;
  box-shadow: 0 0 14px rgba(255, 151, 67, 0.2);
  color: #251308;
}
.aula-card.kind-geo {
  background: linear-gradient(100deg, #51EBC5 0%, #3DDEA8 58%, #2BD58E 100%);
  border: 2px solid #4FF2B3;
  box-shadow: 0 0 14px rgba(48, 226, 169, 0.2);
  color: #05251D;
}
.aula-card.kind-mat {
  background: linear-gradient(100deg, #C4B5FD 0%, #A78BFA 55%, #8B5CF6 100%);
  border: 2px solid #DDD6FE;
  box-shadow: 0 0 14px rgba(139, 92, 246, 0.22);
  color: #1E1033;
}
.aula-card.kind-port {
  background: linear-gradient(100deg, #FDE68A 0%, #FBBF24 58%, #F59E0B 100%);
  border: 2px solid #FCD34D;
  box-shadow: 0 0 14px rgba(245, 158, 11, 0.22);
  color: #2A1A04;
}
.aula-card.kind-cie {
  background: linear-gradient(100deg, #F9A8D4 0%, #F472B6 55%, #EC4899 100%);
  border: 2px solid #FBCFE8;
  box-shadow: 0 0 14px rgba(236, 72, 153, 0.2);
  color: #2A1020;
}
.aula-card.kind-ing {
  background: linear-gradient(100deg, #93C5FD 0%, #60A5FA 55%, #3B82F6 100%);
  border: 2px solid #BFDBFE;
  box-shadow: 0 0 14px rgba(59, 130, 246, 0.22);
  color: #0B1E3A;
}
.aula-card.kind-artes {
  background: linear-gradient(100deg, #FCA5A5 0%, #FB7185 55%, #F43F5E 100%);
  border: 2px solid #FECDD3;
  box-shadow: 0 0 14px rgba(244, 63, 94, 0.2);
  color: #2A0B12;
}
.aula-card.kind-amb {
  background: linear-gradient(100deg, #6EE7B7 0%, #34D399 55%, #059669 100%);
  border: 2px solid #A7F3D0;
  box-shadow: 0 0 14px rgba(5, 150, 105, 0.22);
  color: #052016;
}
.aula-card.kind-relig {
  background: linear-gradient(100deg, #5EEAD4 0%, #2DD4BF 55%, #0D9488 100%);
  border: 2px solid #99F6E4;
  box-shadow: 0 0 14px rgba(13, 148, 136, 0.2);
  color: #04221F;
}
.aula-card.kind-comp {
  background: linear-gradient(100deg, #67E8F9 0%, #22D3EE 55%, #0891B2 100%);
  border: 2px solid #A5F3FC;
  box-shadow: 0 0 14px rgba(8, 145, 178, 0.22);
  color: #062026;
}
.aula-card.kind-atv {
  background: linear-gradient(100deg, #FDE047 0%, #FACC15 55%, #CA8A04 100%);
  border: 2px solid #FEF08A;
  box-shadow: 0 0 14px rgba(202, 138, 4, 0.2);
  color: #2A2104;
}
.aula-card.kind-other {
  background: linear-gradient(100deg, var(--c1, #39A8FF) 0%, color-mix(in srgb, var(--c1, #39A8FF) 72%, #1a2a40) 100%);
  border: 2px solid color-mix(in srgb, var(--c1, #39A8FF) 80%, #fff);
  box-shadow: 0 0 14px color-mix(in srgb, var(--c1, #39A8FF) 28%, transparent);
  color: #102030;
}
.aula-card.kind-cancel {
  background: linear-gradient(100deg, #D6CFC4 0%, #C5B8A4 100%);
  border: 2px solid #E4DDD2;
  color: #3d3428;
  opacity: 0.92;
}
.aula-card.kind-recover {
  background: linear-gradient(100deg, #F6E7C4 0%, #E8C98A 100%);
  border: 2px solid #C4842A;
  box-shadow: inset 7px 0 0 #7A4E00;
  color: #1A1204;
}
.aula-card.kind-lazer {
  background: linear-gradient(100deg, #D9F99D 0%, #A3E635 55%, #65A30D 100%);
  border: 2px solid #BEF264;
  color: #142006;
}

body.dash .week {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
  margin: 0 0 12px;
}
body.dash .week button {
  min-width: 0;
  width: 100%;
  min-height: 44px;
  padding: 10px 4px;
  font-size: 0.88rem;
}
body.dash .cal {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 8px;
  overflow: hidden;
}
body.dash .cal b {
  color: var(--text-secondary);
  font-size: 0.68rem;
  text-align: center;
  padding: 4px 0;
}
body.dash .cal button {
  background: var(--surface);
  border: 1px solid transparent;
  min-width: 0;
  width: 100%;
  min-height: 40px;
  padding: 4px 2px;
  border-radius: 10px;
  font-size: 0.78rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
}
body.dash .cal button.today { outline: 2px solid var(--primary); outline-offset: -1px; }
body.dash .cal button.pick {
  background: linear-gradient(135deg, #53F3C2, #20E6B2);
  color: #041B22;
  border-color: transparent;
}
body.dash .row.cal-nav {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 44px 1fr 44px;
  gap: 8px;
  align-items: center;
  margin: 10px 0 12px;
}
body.dash .row.cal-nav > * { flex: none; min-width: 0; width: 100%; }
body.dash .row.cal-nav p { margin: 0; text-align: center; }
body.dash .row.cal-nav button {
  min-height: 44px;
  padding: 8px;
}
body.dash .desk {
  position: relative;
  z-index: 1;
  margin-top: 16px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 8px;
}
body.dash table { color: var(--text); }
body.dash th, body.dash td { border-color: #1c3d5c; }
body.dash .desk th.on {
  background: linear-gradient(135deg, #53F3C2, #20E6B2);
  color: #041B22;
}
body.dash .cell { border-radius: 8px; }

body.dash .wa-fab {
  background: #25D366;
  border: 0;
}
body.dash .wa-panel {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
}

@media (hover: hover) and (pointer: fine) {
  body.dash button:hover,
  body.dash .print-btn:hover,
  body.dash .aula-card:hover {
    transform: translateY(-2px);
  }
  body.dash .aula-card:hover { box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22); }
}

@media (min-width: 640px) {
  .filter-row { grid-template-columns: 1fr 1fr; }
  body.dash .wrap { padding: 28px 24px 100px; }
}

body.dash .wrap.login-page { max-width: 320px; }
body.dash .top { align-items: center; gap: 10px; }
body.dash .top-actions { display: flex; gap: 8px; align-items: center; flex: 0 0 auto; }
body.dash #out {
  color: #f0b4b4;
  border: 1px solid #c45c5c;
  background: #3a1c1c;
}
body.dash a.site-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  border: 1px solid #3475A8;
  background: linear-gradient(180deg, #153553, #102A43);
  color: #F5F8FC;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.85rem;
  white-space: nowrap;
}
body.dash .nav-drop {
  background: var(--surface);
  border: 1px solid var(--border);
}
body.dash .ctx,
body.dash .section,
body.dash .ov-item,
body.dash .hoje-box {
  background: var(--surface);
  border-color: var(--border);
}
body.dash .ctx { border-radius: var(--radius-md); padding: 10px 12px; }
body.dash .tabs button, body.dash .subtabs button { background: transparent; color: var(--text-secondary); }
body.dash .subtabs button.on,
body.dash .tabs button.on {
  background: linear-gradient(180deg, #153553, #102A43);
  color: var(--text);
  border-color: #3475A8;
}
body.dash .flash {
  background: #10382f;
  color: var(--primary-light);
  border: 1px solid #1d6b58;
}
body.dash .ask-toast-card,
body.dash .ask-wa {
  background: #3a3014;
  border: 1px solid #c9a227;
  color: #fff6d0;
}
body.dash .ask-toast-card b { color: #fff; }
body.dash .ask-toast-acts button {
  padding: 6px 14px;
  min-height: 36px;
  height: 36px;
}
body.dash .note-toast {
  background: #10382f;
  color: var(--primary-light);
  border: 1px solid #1d6b58;
}
body.dash .dia-chip.on {
  background: linear-gradient(180deg, #153553, #102A43);
  border-color: #3475A8;
  color: #fff;
}
body.dash .wa-sending {
  background: #3a3014;
  border: 1px solid #c9a227;
  color: #fff6d0;
}
body.dash .wa-sending b { color: #fff; }
body.dash .wa-spin { border-color: #f5d76e; border-top-color: transparent; }
body.dash textarea {
  background: #102B45;
  border: 1px solid #3974A0;
  color: #fff;
}
body.dash table { width: 100%; border-collapse: collapse; overflow: visible; }
body.dash .stack-table { overflow: visible; }
body.dash th, body.dash td { padding: 8px 6px; border-bottom: 1px solid #1c3d5c; text-align: left; }
body.dash .stack-table tr,
body.dash .grade-table tr.admin-grid {
  background: var(--surface);
  border-color: var(--border);
}
body.dash .serie-chip.on,
body.dash .grade-picks button.on {
  background: linear-gradient(180deg, #153553, #102A43);
  color: var(--text);
  border-color: #3475A8;
  outline-color: #20E6B2;
}
body.dash .gcell {
  background: var(--surface);
  border-color: var(--border);
  padding: 6px 8px;
  height: auto;
  min-height: 72px;
  max-height: none;
  font-weight: 600;
  box-shadow: none;
  overflow: visible;
}
body.dash .grade-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-start; }
body.dash .site-menu { position: relative; }
body.dash .site-menu summary {
  list-style: none;
  cursor: pointer;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 12px;
  min-height: 36px;
}
body.dash .site-menu summary::-webkit-details-marker { display: none; }
body.dash .site-menu[open] {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
}
body.dash .clock-card {
  margin: 8px 0 12px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}
body.dash .notify-line {
  margin: 10px 0;
  padding: 10px 12px;
  border-radius: 10px;
  background: #14324C;
  border: 1px solid #F5C518;
}
body.dash .notify-line b { color: #F5C518; }
body.dash .notify-line p { margin: 4px 0 8px; }
body.dash .notify-prof-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 8px 0 10px;
}
body.dash .notify-prof-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 8px;
  background: #0B2236;
}
body.dash .notify-prof-row span { font-weight: 500; }
body.dash .notify-prof-row i {
  margin-left: 6px;
  font-style: normal;
  font-weight: 500;
  color: #8FBFB0;
}
body.dash .notify-prof-row button { min-height: 36px; }
body.dash.site-admin .grade-board td.aula,
body.dash.site-admin .grade-board th.aula {
  width: 76px;
  min-width: 76px;
  max-width: 88px;
  font-weight: 600;
  font-size: 0.95rem;
}
body.dash.site-admin .grade-board td.aula .hora,
body.dash.site-admin .lesson .n .hora {
  display: block;
  margin-top: 3px;
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: 0;
  color: #C5D4E4;
}
body.dash.site-admin .grade-board td.aula .hora span,
body.dash.site-admin .lesson .n .hora span {
  display: block;
  font-weight: 500;
}
body.dash.site-admin .lesson .n { font-weight: 600; }
body.dash.site-admin .gcell .disc-pill {
  font-weight: 650;
  font-size: 0.8rem;
}
body.dash.site-admin .gcell .who {
  font-weight: 450;
  font-size: 0.76rem;
  color: #D7E2EA;
}
body.dash.site-admin .gcell .disc-pill,
body.dash.site-admin .gcell .who {
  display: block;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
body.dash.site-admin .clock-card .stack-table td:first-child {
  font-weight: 600;
  font-size: 1rem;
}
body.dash.site-admin .clock-card input[type="time"] {
  font-size: 1.05rem;
  font-weight: 500;
  min-height: 44px;
  max-width: 160px;
  color: #F7FAFC;
  background: #0B2236;
}

@media (max-width: 899px) {
  body.dash .grade-tools {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  body.dash .grade-tools > button,
  body.dash .site-menu { width: 100%; min-width: 0; }
  body.dash .grade-tools > button,
  body.dash .site-menu summary {
    width: 100%;
    min-height: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  body.dash .site-menu[open] {
    grid-column: 1 / -1;
    height: auto;
  }
  body.dash .site-menu[open] > button,
  body.dash .site-menu[open] > a {
    width: 100%;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
  }
  body.dash .clock-card .row { flex-direction: column; }
  body.dash .clock-card .row > * { flex: 1 1 auto; width: 100%; min-width: 0; }
  body.dash .clock-card .grade-picks button {
    flex: 1 1 calc(50% - 6px);
    height: auto;
    min-height: 44px;
    white-space: normal;
  }
  body.dash .clock-card .stack-table td:nth-child(1) {
    font-weight: 600;
    padding-bottom: 0;
  }
  body.dash .clock-card .stack-table td:nth-child(2)::before,
  body.dash .clock-card .stack-table td:nth-child(3)::before {
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: 4px;
    color: var(--text-secondary, #9aa89f);
  }
  body.dash .clock-card .stack-table td:nth-child(2)::before { content: 'Início'; }
  body.dash .clock-card .stack-table td:nth-child(3)::before { content: 'Fim'; }
  body.dash .notify-line .ask-toast-acts { flex-wrap: wrap; justify-content: stretch; }
  body.dash .notify-line .ask-toast-acts button {
    flex: 1 1 140px;
    min-height: 44px;
    height: auto;
  }
  body.dash .lesson-row { grid-template-columns: minmax(0, 1fr) 44px 44px; }
  body.dash .lesson-shift,
  body.dash .lesson-shift-ph,
  body.dash .drag-handle {
    width: 44px;
    min-width: 44px;
    height: 44px;
    min-height: 44px;
  }
}
body.dash .notify-report-list {
  list-style: none;
  margin: 6px 0 10px;
  padding: 0;
  max-height: 46vh;
  overflow-y: auto;
}
body.dash .notify-report-list li { padding: 4px 0; border-bottom: 1px solid rgba(255, 246, 208, 0.12); }
body.dash .notify-report-list li b { color: #fff; }
body.dash .swap-hover {
  position: fixed;
  z-index: 80;
  max-width: 280px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #102C48;
  color: #F4F7FB;
  border: 1px solid #F5C518;
  font-size: 0.85rem;
  line-height: 1.35;
  white-space: pre-line;
  pointer-events: none;
}
body.dash .gcell.drop-ok {
  outline: 2px dashed #20E6B2;
  outline-offset: -2px;
}
body.dash .gcell:hover,
body.dash .gcell.dragging {
  transform: none;
}
body.dash .event-mini .event-toggle {
  border-color: var(--border);
}
body.dash .act-sub { background: #10382f; color: var(--primary-light); border: 1px solid #20E6B2; }
body.dash .act-shift { background: #3a3014; color: #f5d76e; border: 1px solid #c9a227; }
body.dash .act-cancel { background: #3a1c1c; color: #f0b4b4; border: 1px solid #c45c5c; }
body.dash .chk { color: var(--text-secondary); }
body.dash .hint-lim { color: var(--text-secondary); }
body.dash .diff-add { color: var(--primary-light); }
body.dash .diff-chg { color: #f5d76e; }
body.dash label { color: var(--text-secondary); }

@media (max-width: 420px) {
  body.dash .wrap { padding: 16px 12px 100px; overflow-x: clip; }
  .seg-row { gap: 6px; }
  .seg-btn { font-size: 0.82rem; padding: 10px 6px; gap: 5px; }
  .aula-card { grid-template-columns: 70px minmax(0, 1fr); padding-right: 72px; min-height: 96px; }
  .aula-ico { width: 64px; height: 64px; right: 6px; }
  .aula-disc { font-size: 1.05rem; }
  body.dash .cal { gap: 2px; padding: 6px; }
  body.dash .cal button { min-height: 36px; font-size: 0.72rem; padding: 2px 0; }
}

html.is-mobile body.dash .wrap {
  max-width: 100%;
  padding: 12px 10px calc(88px + env(safe-area-inset-bottom, 0px));
  overflow-x: clip;
}
html.is-pc body.dash.site-public .wrap:not(.login-page) {
  max-width: min(1180px, 100%);
  padding: 24px 24px 80px;
}
html.is-pc body.dash.site-admin .wrap:not(.login-page),
html.is-pc body.dash .wrap.grade-wide:not(.login-page) {
  max-width: none;
  width: 100%;
  padding: 16px 18px 48px;
}
html.is-pc body.dash .wrap.login-page { max-width: 320px; }

body.dash .tabs button,
body.dash .subtabs button,
body.dash .week button,
body.dash .grade-picks button,
body.dash .serie-chip,
body.dash .event-mini .event-toggle,
body.dash .ctx .turno-row button {
  min-height: 40px;
  height: 40px;
  padding: 8px 14px;
  font-size: 0.86rem;
}
body.dash .disc-pick > summary {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text);
}
body.dash .disc-list {
  background: var(--surface);
  border-color: var(--border);
}
body.dash .disc-opt:hover { background: #153553; }
body.dash .disc-list input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-width: 16px;
  min-height: 16px;
  padding: 0;
}
body.dash .gcell {
  padding: 6px 8px;
  height: auto;
  min-height: 72px;
  max-height: none;
  overflow: visible;
}
html.is-pc .grade-page .block,
html.is-pc #go-today {
  width: auto;
  max-width: 280px;
}
html.is-pc .desk {
  overflow-x: auto;
  width: 100%;
}
html.is-pc .desk table {
  width: 100%;
  table-layout: fixed;
}
html.is-pc .desk .cell {
  font-size: 0.78rem;
  overflow: hidden;
  text-overflow: ellipsis;
}
html.is-pc .site-public .list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
}
html.is-pc .filter-row { grid-template-columns: 1fr 1fr; }
html.is-pc .filter-row.hoje-filters { grid-template-columns: 1fr; }
html.is-mobile .filter-row { grid-template-columns: 1fr; }
html.is-mobile .wa-fab {
  right: max(12px, env(safe-area-inset-right, 0px));
  bottom: max(16px, env(safe-area-inset-bottom, 0px));
}
html.is-pc .cal button { min-height: 58px; }

html.is-mobile body.dash .top {
  flex-wrap: wrap;
  gap: 8px;
}
html.is-mobile body.dash .top h1 {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 1.05rem;
}
html.is-mobile body.dash .top-actions { margin-left: auto; }
html.is-mobile body.dash .tabs,
html.is-mobile body.dash .subtabs {
  flex-wrap: nowrap;
  overflow-x: auto;
}
html.is-mobile body.dash .tabs button,
html.is-mobile body.dash .subtabs button {
  flex: 0 0 auto;
  min-width: max-content;
  height: 36px;
  min-height: 36px;
  padding: 6px 12px;
  font-size: 0.8rem;
}
html.is-mobile body.dash .act {
  min-height: 40px;
  padding: 8px 10px;
  font-size: 0.84rem;
}
html.is-mobile body.dash .aula-card {
  min-height: 84px;
  padding-right: 62px;
}
html.is-mobile .aula-disc { font-size: 1.05rem; font-weight: 800; }
html.is-mobile .aula-prof { font-size: 0.92rem; }
html.is-mobile .aula-ico {
  opacity: 1;
  width: 40px;
  height: 40px;
  right: 10px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.38);
  display: flex;
  align-items: center;
  justify-content: center;
}
html.is-mobile .aula-ico .ico { width: 22px; height: 22px; }
html.eh-full.is-phone-portrait #app.wrap,
html.eh-full.is-phone-portrait .wrap {
  overflow-x: hidden !important;
  overflow-y: auto !important;
  display: block !important;
  -webkit-overflow-scrolling: touch;
}
body.dash button.lesson {
  padding: 10px 8px 10px 12px;
  min-height: 64px;
  height: auto;
  border: 0;
  box-shadow: none;
  background: transparent;
}
body.dash .lesson-shift {
  background: #3a3014;
  color: #f5d76e;
  border: 1px solid #c9a227;
  width: 32px;
  min-width: 32px;
  height: 32px;
  min-height: 32px;
  padding: 0;
  box-shadow: none;
  font-size: 0.95rem;
}
body.dash .drag-handle {
  background: transparent;
  border: 0;
  border-left: 1px solid var(--border);
  box-shadow: none;
  width: 36px;
  min-width: 36px;
  height: auto;
  min-height: 0;
  padding: 0;
  transform: none;
}
body.dash a.print-mini {
  border: 1px solid #3475A8;
  background: linear-gradient(180deg, #153553, #102A43);
  color: #F5F8FC;
  text-decoration: none;
}
body.dash .drag-handle:hover,
body.dash .drag-handle:active {
  transform: none;
  filter: none;
}

.day-board-fit {
  width: 100%;
  overflow: hidden;
  margin: 8px 0 18px;
}
.day-board {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
}
.day-board th.aula,
.day-board td.aula {
  width: 3.6rem;
  min-width: 3.2rem;
  max-width: 4.4rem;
  font-weight: 700;
  white-space: normal;
  text-align: center;
  vertical-align: middle;
  padding: 4px 2px;
}
.day-board th.aula .hora {
  display: block;
  font-size: 0.58rem;
  font-weight: 400;
  color: var(--muted);
  letter-spacing: 0;
  white-space: normal;
}
.day-board thead { position: relative; z-index: 5; }
.day-board thead th { background: #071A2B; }
.day-board th:not(.aula) {
  text-align: center;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 4px 2px;
  min-width: 0;
}
.day-board th[data-serie="6"] { background: #3B1D6E; color: #F3E8FF; box-shadow: inset 0 -4px 0 #A78BFA; }
.day-board th[data-serie="7"] { background: #7C2D12; color: #FFEDD5; box-shadow: inset 0 -4px 0 #FDBA74; }
.day-board th[data-serie="8"] { background: #1A3A12; color: #ECFCCB; box-shadow: inset 0 -4px 0 #A3E635; }
.day-board th[data-serie="9"] { background: #3F3508; color: #FEF9C3; box-shadow: inset 0 -4px 0 #F5C400; }
.day-board td[data-serie] { box-shadow: none; }
.day-board td {
  padding: 2px;
  min-width: 0;
  vertical-align: stretch;
}
.day-board td.fill {
  padding: 2px;
}
.day-board td.fill .cell {
  display: block;
  min-height: 46px;
  padding: 4px 6px;
  font-family: "Trebuchet MS", Arial, Helvetica, sans-serif;
  font-size: 16px;
  text-align: left;
  border-radius: 8px;
  overflow: hidden;
}
.day-board td.fill .cell b,
.day-board td.fill .cell i {
  display: block;
  overflow: hidden;
}
.day-board td.fill .cell b {
  font-weight: 700;
  font-size: 16px;
  line-height: 1.08;
  white-space: nowrap;
  word-break: normal;
  overflow-wrap: normal;
}
.day-board td.fill .cell i {
  font-style: normal;
  font-weight: 500;
  opacity: 1;
  font-size: 11px;
  margin-top: 1px;
  line-height: 1.1;
  white-space: nowrap;
  overflow-wrap: normal;
}
.aula-now {
  display: inline-block;
  margin-top: 3px;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0;
  color: #071A2B;
  background: #F5C518;
  border-radius: 4px;
  padding: 1px 4px;
}
.day-board tbody tr.is-now th.aula {
  background: #0b2946;
  color: #f4f7fb;
  border-radius: 8px;
  box-shadow: inset 0 0 0 3px #F5C518;
}
.day-board tbody tr.is-now th.aula .hora {
  color: #c5d4e4;
}
.day-board tbody tr.is-now td {
  background: transparent;
}
.day-board tbody tr.is-now td.fill .cell {
  box-shadow: inset 0 0 0 3px #F5C518;
}
/* Piscar só o contorno. Sem opacity: no Chrome 49 da TV o quadro inteiro escurecia. */
.day-board tbody tr.is-pulse td.fill .cell,
.day-board tbody tr.is-pulse th.aula {
  box-shadow: inset 0 0 0 2px rgba(245, 197, 24, 0.35);
}
.day-board tbody tr.is-pulse-lit td.fill .cell,
.day-board tbody tr.is-pulse-lit th.aula {
  box-shadow: inset 0 0 0 4px #F5C518;
}
body.dash.site-public .day-board tbody tr.is-now.is-pulse th.aula {
  box-shadow: inset 0 0 0 2px rgba(245, 197, 24, 0.35);
}
body.dash.site-public .day-board tbody tr.is-now.is-pulse.is-pulse-lit th.aula {
  background: #0b2946;
  color: #f4f7fb;
  box-shadow: inset 0 0 0 4px #F5C518;
}
body.dash.site-public .day-board tbody tr.is-now.is-pulse.is-pulse-lit th.aula .hora {
  color: #c5d4e4;
}
body.dash.site-public .day-board tbody tr.is-pulse.is-pulse-lit td.fill .cell {
  box-shadow: inset 0 0 0 4px #F5C518;
}
body.dash.site-public .banner.pulse-banner {
  background: #F5C518;
  border-color: #F5C518;
  color: #1A1408;
}
body.dash.site-public .banner.pulse-banner b,
body.dash.site-public .banner.pulse-banner .banner-txt {
  color: #1A1408;
}
body.dash.site-public .banner.pulse-banner .banner-ico {
  background: #1A1408;
  color: #F5C518;
}
html.eh-full body.dash.site-public .banner.pulse-banner {
  padding: 12px 16px;
}
html.eh-full body.dash.site-public .banner.pulse-banner b {
  font-size: 1.6rem;
}
html.eh-full .sound-bar { display: none; }
.nowbar {
  display: flex;
  align-items: center;
  position: relative;
  background: #F5C518;
  color: #1A1408;
  border-radius: 10px;
  padding: 4px 12px;
  margin: 0 0 8px;
  max-height: 36px;
  overflow: hidden;
}
html.eh-full .nowbar {
  flex: 0 0 auto;
  max-height: 44px;
  min-height: 40px;
  padding: 4px 14px;
  margin: 0 0 6px;
}
html.eh-full .nowbar b { font-size: 1.3rem; }
html.eh-full .nowbar em { font-size: 1.05rem; }
html.eh-full .nowbar-run { height: 1.3em; line-height: 1.3; }
html.eh-full .nowbar-run > span { font-size: 19px; }
.nowbar-now {
  display: flex;
  align-items: baseline;
  flex: none;
  position: relative;
  z-index: 2;
  align-self: stretch;
  background: #F5C518;
  padding-right: 12px;
}
.nowbar b { font-size: 1.15rem; line-height: 1; flex: none; }
.nowbar span { font-size: 0.95rem; font-weight: 700; }
.nowbar em { font-style: normal; font-weight: 700; flex: none; font-size: 0.95rem; }
.nowbar-now em { margin-left: 10px; }
.nowbar-run {
  position: relative;
  z-index: 1;
  margin-left: 10px;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  height: 1.2em;
  line-height: 1.2;
}
.nowbar-run > span {
  display: inline-block;
  white-space: nowrap;
  font-family: "Segoe UI", "Trebuchet MS", Arial, Helvetica, sans-serif;
  font-size: 16px;
  font-weight: 500;
  letter-spacing: 0.01em;
  animation: eh-ticker 60s linear infinite;
}
@keyframes eh-ticker {
  from { transform: translateX(8%); }
  to { transform: translateX(-100%); }
}
.day-board.has-now tbody tr:not(.is-now) .cell { opacity: 1; }
.day-board tbody tr.is-past th.aula,
.day-board tbody tr.is-past td.fill .cell { opacity: 0.72; }
.day-board.has-now tbody tr.is-now th.aula { font-size: 1.15rem; }
.sound-bar { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 10px; }
.sound-sw {
  border: 1px solid #3475A8;
  background: #102C48;
  color: #F4F7FB;
  border-radius: 999px;
  padding: 6px 12px;
  font-weight: 700;
  cursor: pointer;
}
.sound-sw.on { background: #20E6B2; color: #041B22; border-color: transparent; }
.aula-card.is-now {
  outline: 3px solid #F5C518;
  box-shadow: 0 0 0 2px #fff;
}

.act-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 10px 0 4px;
  position: relative;
  z-index: 1;
}
.act-row .print-btn {
  flex: 1 1 160px;
}
.full-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 16px;
  border-radius: 16px;
  font-weight: 700;
  border: 1px solid #3475A8;
  background: linear-gradient(180deg, #153553, #102A43);
  color: #F5F8FC;
  cursor: pointer;
}
.full-btn .ico {
  width: 18px;
  height: 18px;
}
.full-row {
  position: relative;
  z-index: 1;
  margin: 0 0 12px;
}
.full-row .full-btn {
  width: 100%;
  min-height: 52px;
  font-size: 1.05rem;
  font-weight: 700;
  border: 2px solid #53F3C2;
  background: linear-gradient(180deg, #1A4A3A, #0F2E3A);
  box-shadow: 0 0 14px rgba(83, 243, 194, 0.25);
}
.full-top {
  display: none;
}

html.eh-full,
html.eh-full body {
  margin: 0;
  height: 100%;
  max-height: 100%;
  overflow: hidden !important;
}
html.eh-full body.dash {
  min-height: 0;
}
html.eh-full .wrap,
html.eh-full #app.wrap {
  position: fixed !important;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  width: auto !important;
  max-width: none !important;
  height: auto !important;
  max-height: none !important;
  min-height: 0 !important;
  padding: 8px 10px 10px !important;
  display: flex;
  flex-direction: column;
  overflow: hidden !important;
  box-sizing: border-box;
}
html.eh-full .full-top {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 6px;
  flex: 0 0 auto;
}
html.eh-full .full-title {
  flex: 1;
  margin: 0;
  font-weight: 800;
  font-size: 1.05rem;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
html.eh-full .full-btn {
  min-height: 36px;
  padding: 0 14px;
  font-size: 0.92rem;
  flex: 0 0 auto;
  border: 2px solid #53F3C2;
}
html.eh-full .week {
  margin: 0 0 6px;
  flex: 0 0 auto;
}
html.eh-full .day-label {
  margin: 0 0 6px;
  font-size: 0.95rem;
  flex: 0 0 auto;
}
html.eh-full p.muted {
  display: none;
}
/* Sem quadro na tela (feriado, turno sem grade): o aviso tem de aparecer,
   senão a tela cheia fica em branco. */
html.eh-full #app.full-empty p.muted {
  display: block;
}
html.eh-full .day-board td.muted {
  display: table-cell;
}
html.eh-full .day-board-fit {
  position: relative;
  flex: 1 1 auto;
  align-self: stretch;
  width: 100%;
  margin: 0;
  min-height: 0;
  min-width: 0;
  overflow: hidden !important;
}
html.eh-full .day-board-fit.can-scroll {
  overflow: hidden !important;
}
html.eh-full .day-board {
  width: 100% !important;
  min-width: 0 !important;
  height: 100%;
  table-layout: fixed;
}
html.eh-full .day-board th,
html.eh-full .day-board td {
  overflow: hidden;
  box-sizing: border-box;
  padding: 2px 3px;
  vertical-align: middle;
}
html.eh-full .day-board thead th {
  height: auto;
}
html.eh-full .day-board tbody tr,
html.eh-full .day-board tbody tr.is-now {
  height: auto;
}
html.eh-full .day-board tbody tr.is-now td.fill .cell {
  box-shadow: inset 0 0 0 3px #F5C518;
}
html.eh-full .day-board tbody tr.is-now th.aula {
  font-size: inherit;
}
html.eh-full .day-board tbody tr.is-now th.aula .aula-now {
  margin-top: 2px;
  font-size: 0.62em;
}
html.eh-full .day-board th:not(.aula) {
  font-size: 28px;
  line-height: 1.05;
  padding: 6px 4px 10px;
  border-radius: 0;
}
html.eh-full .day-board thead th[data-serie="6"] { background: #3B1D6E; color: #F3E8FF; box-shadow: inset 0 -5px 0 #A78BFA; }
html.eh-full .day-board thead th[data-serie="7"] { background: #7C2D12; color: #FFEDD5; box-shadow: inset 0 -5px 0 #FDBA74; }
html.eh-full .day-board thead th[data-serie="8"] { background: #1A3A12; color: #ECFCCB; box-shadow: inset 0 -5px 0 #A3E635; }
html.eh-full .day-board thead th[data-serie="9"] { background: #3F3508; color: #FEF9C3; box-shadow: inset 0 -5px 0 #F5C400; }
html.eh-full .day-board td[data-serie] { box-shadow: none; }
html.eh-full .day-board th.aula {
  font-size: clamp(1rem, 2vh, 1.35rem);
  width: 5rem;
  max-width: 6rem;
  text-align: center;
  vertical-align: middle;
}
html.eh-full .day-board th.aula .hora {
  font-size: clamp(0.7rem, 1.3vh, 0.95rem);
}
html.eh-full .day-board td.fill .cell {
  min-height: 0;
  max-height: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: stretch;
  padding: 1px 6px;
  font-size: 16px;
  line-height: 1.05;
  text-align: left;
  box-sizing: border-box;
  overflow: hidden;
}
html.eh-full .day-board td.fill .cell b,
html.eh-full .day-board td.fill .cell i {
  overflow: hidden;
  max-width: 100%;
}
html.eh-full .day-board td.fill .cell b {
  font-size: 1em;
  font-weight: 700;
  white-space: nowrap;
  overflow-wrap: normal;
  line-height: 1.05;
}
html.eh-full .day-board td.fill .cell i {
  font-size: 0.72em;
  font-weight: 500;
  margin-top: 2px;
  opacity: 1;
  white-space: nowrap;
  overflow-wrap: normal;
  line-height: 1.05;
}
body.dash.site-public .dash-head {
  margin: 0 0 10px;
}
body.dash.site-public .dash-head h1 {
  font-size: clamp(1.2rem, 3.2vw, 1.55rem);
  font-weight: 700;
  letter-spacing: 0;
}
html.eh-full .week button {
  min-height: 36px;
  padding: 6px 4px;
}
body.dash.site-public .tool-row {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin: 0 0 10px;
}
body.dash.site-public .tool-row .seg-row {
  display: flex;
  flex: 1 1 auto;
  gap: 4px;
  margin: 0;
  min-width: 0;
  grid-template-columns: none;
}
body.dash.site-public .tool-row .seg-btn,
body.dash.site-public .tool-btn,
body.dash.site-public .tool-chip {
  flex: 0 0 auto;
  min-height: 34px;
  height: 34px;
  padding: 0 10px;
  font-size: 0.78rem;
  font-weight: 700;
  border-radius: 10px;
  gap: 5px;
}
body.dash.site-public .tool-row .seg-btn {
  flex: 1 1 0;
  min-width: 0;
  max-width: 140px;
}
body.dash.site-public .tool-row .seg-btn .ico,
body.dash.site-public .tool-btn .ico {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
}
body.dash.site-public .tool-chip {
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: linear-gradient(135deg, #53F3C2, #20E6B2);
  color: #041B22;
  border: 0;
}
body.dash.site-public .opts-panel {
  position: relative;
  z-index: 1;
  margin: 0 0 10px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(16, 43, 69, 0.55);
}
body.dash.site-public .opts-panel .turno-row,
body.dash.site-public .opts-panel .filter-row,
body.dash.site-public .opts-panel .sel,
body.dash.site-public .opts-panel .print-btn {
  margin: 0;
}
body.dash.site-public .opts-panel .turno-row {
  display: flex;
  gap: 6px;
  grid-template-columns: none;
  margin-bottom: 8px;
}
body.dash.site-public .opts-panel .turno-row button {
  flex: 1 1 0;
  min-height: 34px;
  height: 34px;
  padding: 0 10px;
  font-size: 0.78rem;
  border-radius: 10px;
  gap: 5px;
}
body.dash.site-public .opts-panel .filter-row {
  margin: 0 0 8px;
}
body.dash.site-public .opts-panel select {
  min-height: 34px;
  padding: 6px 12px 6px 36px;
  font-size: 0.85rem;
  border-radius: 10px;
}
body.dash.site-public .opts-panel .print-btn {
  width: auto;
  min-height: 34px;
  height: 34px;
  padding: 0 12px;
  margin: 0;
  font-size: 0.78rem;
  border-radius: 10px;
}
body.dash.site-public .opts-panel .print-btn .ico {
  width: 14px;
  height: 14px;
}
body.dash.site-public .day-label {
  margin: 0 0 8px;
}

/* TV / tela grande sem JS de tela cheia: já abre a grade maior */
@media (min-width: 1000px) {
  body.dash.site-public .wrap {
    max-width: none;
    padding: 12px 16px 18px;
  }
  body.dash.site-public .full-row .full-btn {
    min-height: 58px;
    font-size: 1.2rem;
  }
  body.dash.site-public:not(.eh-full) .day-board td.fill .cell {
    min-height: 48px;
    font-size: 17px;
    padding: 5px 6px;
  }
  body.dash.site-public:not(.eh-full) .day-board td.fill .cell b {
    font-size: 17px;
  }
  body.dash.site-public:not(.eh-full) .day-board td.fill .cell i {
    font-size: 12px;
  }
  body.dash.site-public:not(.eh-full) .day-board th:not(.aula) {
    font-size: 1.25rem;
    padding: 8px 4px 12px;
  }
  body.dash.site-public:not(.eh-full) .day-board th.aula {
    font-size: 1rem;
    width: 4.8rem;
    max-width: 5.5rem;
  }
  body.dash.site-public:not(.eh-full) .day-board th.aula .hora {
    font-size: 0.72rem;
  }
}

/* A grade rola com a página. O nome da série gruda no topo da janela. */
body.dash.site-admin .grade-board-wrap {
  overflow: visible;
  max-height: none;
}
body.dash.site-admin .grade-board {
  width: 100%;
  border-collapse: separate;
  border-spacing: 3px;
}
body.dash.site-admin .grade-board th:not(.aula),
body.dash.site-admin .grade-board td.gtd {
  width: auto;
  min-width: 0;
  max-width: none;
  height: 1px;
}
body.dash.site-admin .grade-board td.gtd .gcell {
  height: 100%;
  min-height: 52px;
}
html:has(body.site-admin),
html:has(body.site-public:not(.eh-full)),
body.dash.site-admin,
body.dash.site-public:not(.eh-full) {
  overflow-x: visible;
}
body.dash.site-admin .grade-board thead th,
body.dash.site-public:not(.eh-full) .day-board thead th {
  position: sticky;
  top: 0;
  z-index: 12;
  text-align: center;
  vertical-align: middle;
}
body.dash.site-admin .grade-board thead th.aula {
  background: #102E4A;
  box-shadow: 0 8px 0 #06172a;
}
body.dash.site-admin .grade-board thead th[data-serie="6"] { box-shadow: inset 0 -4px 0 #A78BFA, 0 8px 0 #06172a; }
body.dash.site-admin .grade-board thead th[data-serie="7"] { box-shadow: inset 0 -4px 0 #FDBA74, 0 8px 0 #06172a; }
body.dash.site-admin .grade-board thead th[data-serie="8"] { box-shadow: inset 0 -4px 0 #A3E635, 0 8px 0 #06172a; }
body.dash.site-admin .grade-board thead th[data-serie="9"] { box-shadow: inset 0 -4px 0 #F5C400, 0 8px 0 #06172a; }
body.dash.site-admin .grade-board thead th[data-serie] {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}
body.dash.site-public:not(.eh-full) .day-board-fit {
  overflow: visible;
}
body.dash.site-public .tool-stack {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0 0 10px;
}
body.dash.site-public .tool-stack .seg-row { margin: 0; }
body.dash.site-public .tool-stack .seg-btn { min-height: 44px; height: 44px; }
body.dash.site-public .tool-secondary { margin: 0; }
body.dash.site-public .tool-secondary > * {
  flex: 1 1 140px;
  min-height: 44px;
  height: auto;
}
body.dash .head-sub { margin: 2px 0 0; font-size: 0.9rem; font-weight: 600; }
body.dash .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
body.dash button:focus-visible,
body.dash a:focus-visible,
body.dash select:focus-visible,
body.dash input:focus-visible,
body.dash summary:focus-visible {
  outline: 2px solid #20E6B2;
  outline-offset: 2px;
}
@media (min-width: 900px) {
  body.dash.site-public .tool-secondary > * { flex: 0 1 auto; }
}
@media (prefers-reduced-motion: reduce) {
  .nowbar-run > span,
  body.dash button { animation: none; transition: none; }
}

/* Secretaria no formato antigo: topo, abas e a grade rolando com a página. */
body.dash.site-admin {
  --bg-main: #071F33;
  --surface: #0D2B45;
  --border: #235477;
  --text: #F1F5F9;
  --text-secondary: #AFC1D4;
  --primary: #38E5BD;
  --primary-light: #38E5BD;
  font-family: Inter, "Segoe UI", system-ui, Arial, sans-serif;
  background: #071F33;
  color: #F1F5F9;
}
body.dash.site-admin::before { opacity: 0.05; }
body.dash.site-admin .wrap,
body.dash.site-admin .wrap.grade-wide {
  max-width: none;
  width: 100%;
  padding-bottom: 28px;
}
body.dash.site-admin .admin-top {
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}
body.dash.site-admin .admin-top h1 {
  margin: 0;
  color: #F1F5F9;
  font-size: 1.15rem;
  font-weight: 700;
}
body.dash.site-admin .admin-top .site-link,
body.dash.site-admin .admin-top #out {
  width: auto;
  min-height: 36px;
  height: 36px;
  padding: 6px 12px;
  border-radius: 12px;
  box-shadow: none;
  text-decoration: none;
}
body.dash.site-admin .admin-top .site-link {
  border: 1px solid #235477;
  background: #0D2B45;
  color: #F1F5F9;
}
body.dash.site-admin .admin-top #out {
  border: 1px solid #C43A57;
  background: #3a1822;
  color: #ffd5de;
}
.admin-search-wrap { margin: 0 0 10px; }
.admin-search { position: relative; display: block; margin: 0; }
.admin-search-hits { display: flex; flex-direction: column; gap: 4px; margin-top: 6px; }
.admin-search-hits:empty { display: none; }
.admin-search-hits button { text-align: left; }
.cfg-block { margin: 0 0 22px; padding-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,.08); }
.cfg-jump { outline: 2px solid #29a0ff; outline-offset: 4px; }
.pick-tools { display: flex; gap: 10px; margin: 0 0 6px; }
.pick-tools .linkish { font-size: .85rem; width: auto; display: inline; }
.stretch-row {
  display: grid;
  grid-template-columns: minmax(88px, 0.8fr) minmax(130px, 1.1fr) minmax(120px, 0.9fr) auto;
  gap: 10px;
  align-items: end;
  margin: 10px 0 14px;
}
.stretch-row .field-lab {
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.78rem;
  font-weight: 600;
  color: #9bb8d0;
}
.stretch-row select,
.stretch-row input {
  margin-top: 6px;
  min-height: 48px;
}
.mins-field {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}
.mins-field input { margin-top: 0; width: 76px; flex: 0 0 76px; }
.mins-field > span { color: #9bb8d0; font-weight: 600; white-space: nowrap; }
.stretch-row > button {
  height: 48px;
  min-height: 48px;
  padding: 8px 18px;
  white-space: nowrap;
}
body.dash .serie-picks { align-items: center; gap: 8px; }
body.dash .serie-tools,
body.dash .serie-nums {
  display: inline-flex;
  flex: 0 0 auto;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
}
body.dash .serie-chip.serie-tool {
  background: transparent;
  border-color: #4d7ea3;
  color: #d5e8f6;
  font-weight: 600;
  box-shadow: none;
}
body.dash .stack-table td { vertical-align: middle; }
body.dash .prof-act {
  height: 48px;
  min-height: 48px;
  padding: 8px 16px;
  white-space: nowrap;
}
body.dash .chk-avisar { white-space: nowrap; }
.file-field {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  margin: 8px 0;
  padding: 6px 10px;
  border: 1px solid #3974A0;
  border-radius: 12px;
  background: #102B45;
}
.file-field input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 0;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
.file-btn {
  flex: 0 0 auto;
  border: 1px solid #235477;
  border-radius: 8px;
  background: #0D2B45;
  padding: 6px 12px;
  font-weight: 600;
}
.file-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #9bb8d0;
}
.pair-acts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 10px 0;
}
.pair-acts.one { grid-template-columns: 1fr; }
.pair-acts button { height: 48px; min-height: 48px; width: 100%; }
.admin-search .admin-ico {
  position: absolute;
  left: 13px;
  top: 50%;
  z-index: 1;
  width: 17px;
  height: 17px;
  color: #7899b8;
  transform: translateY(-50%);
}
.admin-ico { width: 20px; height: 20px; flex: 0 0 20px; }
.public-heading-icon {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: #087cf0;
  color: #fff;
}
body.dash .admin-search input {
  min-height: 40px;
  height: 40px;
  padding: 8px 14px 8px 40px;
  background: #0b2744;
  border-color: #214d74;
  border-radius: 9px;
  font-size: .78rem;
}
.admin-date {
  margin-left: auto;
  color: #c9d9e8;
  font-size: .78rem;
  font-weight: 700;
  white-space: nowrap;
}
body.dash.site-admin .tabs,
body.dash.site-admin .week,
body.dash.site-admin .grade-tools {
  display: grid;
  align-items: stretch;
  gap: 8px;
  margin: 12px 0;
}
body.dash.site-admin .tabs {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
body.dash.site-admin .week {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
body.dash.site-admin .grade-tools {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 0;
}
body.dash.site-admin .grade-tools > button.tv-pulse {
  background: transparent;
  border-color: #38E5BD;
  color: #38E5BD;
  font-weight: 700;
}
body.dash.site-admin .tabs button,
body.dash.site-admin .turno-row button,
body.dash.site-admin .grade-tools > button,
body.dash.site-admin .grade-tools > a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #0D2B45;
  border: 1px solid #235477;
  color: #F1F5F9;
  box-shadow: none;
  border-radius: 12px;
  font-weight: 600;
  text-decoration: none;
}
body.dash.site-admin .tabs button.on,
body.dash.site-admin .turno-row button.on,
body.dash.site-admin .grade-filters button.on,
body.dash.site-admin .grade-tools > button.on,
body.dash.site-admin button.primary {
  background: #38E5BD;
  color: #06281f;
  border-color: #38E5BD;
  box-shadow: none;
}
body.dash.site-admin #more-toggle.on {
  background: #3a1822;
  color: #ffd5de;
  border-color: #C43A57;
}
body.dash.site-admin .tool-sheet {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 10px;
  margin: 0 0 12px;
  padding: 12px;
  background: #0D2B45;
  border: 1px solid #235477;
  border-radius: 12px;
}
body.dash.site-admin .filter-title,
body.dash.site-admin .sheet-title {
  margin: 0;
  color: #F1F5F9;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: none;
}
body.dash.site-admin .tool-sheet > .sheet-title,
body.dash.site-admin .tool-sheet > .muted,
body.dash.site-admin .tool-sheet > .chk-pair {
  grid-column: 1 / -1;
}
body.dash.site-admin .tool-sheet > .muted {
  margin: 0;
  color: #AFC1D4;
  font-size: 0.82rem;
}
body.dash.site-admin .chk-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 16px;
}
body.dash.site-admin .chk-pair .chk {
  grid-column: auto;
  margin: 0;
  color: #F1F5F9;
}
body.dash.site-admin .chk input {
  accent-color: #38E5BD;
}
body.dash.site-admin .tool-sheet > button,
body.dash.site-admin .tool-sheet > a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  min-height: 40px;
  height: 40px;
  margin: 0;
  border-radius: 12px;
  box-shadow: none;
  text-decoration: none;
}
body.dash.site-admin .tool-sheet > .tv-pulse {
  background: transparent;
  border: 1px solid #38E5BD;
  color: #38E5BD;
  font-weight: 700;
}
body.dash.site-admin .tool-sheet > .btn-quiet {
  background: transparent;
  border-color: #1c4464;
  color: #AFC1D4;
  font-weight: 500;
}
body.dash.site-admin .tool-sheet > a.btn-print {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #0D2B45;
  border: 1px solid #235477;
  color: #F1F5F9;
  font-weight: 600;
}
body.dash.site-admin .tabs button,
body.dash.site-admin .week button,
body.dash.site-admin .grade-tools > button,
body.dash.site-admin .grade-tools > a,
body.dash.site-admin .grade-picks button,
body.dash.site-admin #go-today {
  width: 100%;
  min-width: 0;
  height: 40px;
  min-height: 40px;
  margin: 0;
  padding: 6px 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
  border-radius: 12px;
}
body.dash.site-admin .grade-tools .admin-ico,
body.dash.site-admin .tool-sheet .admin-ico {
  position: static;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  transform: none;
  color: currentColor;
}
body.dash.site-admin .grade-filters {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 12px 0;
  padding: 12px;
  background: #0D2B45;
  border: 1px solid #235477;
  border-radius: 12px;
}
body.dash.site-admin .filter-line {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
body.dash.site-admin .filter-k {
  flex: 0 0 46px;
  color: #AFC1D4;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
body.dash.site-admin .grade-filters .week,
body.dash.site-admin .grade-filters .grade-picks {
  display: flex;
  flex: 1 1 auto;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  min-width: 0;
}
body.dash.site-admin .grade-filters .week button,
body.dash.site-admin .grade-filters .grade-picks button {
  width: auto;
  flex: 1 1 0;
  min-width: 52px;
  height: 34px;
  min-height: 34px;
  padding: 4px 8px;
  border-radius: 10px;
  background: #0D2B45;
  border: 1px solid #235477;
  color: #F1F5F9;
  box-shadow: none;
}
body.dash.site-admin .grade-filters .week button.on,
body.dash.site-admin .grade-filters .grade-picks button.on {
  background: #38E5BD;
  color: #06281f;
  border-color: #38E5BD;
}
body.dash.site-admin .grade-picks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0;
}
body.dash.site-admin .grade-picks button {
  width: auto;
  min-width: 72px;
}
body.dash.site-admin #go-today {
  width: auto;
  min-width: 220px;
  justify-self: start;
}
body.dash.site-admin .ctx {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  background: #0a223b;
  border-color: #1c466c;
}
body.dash.site-admin .ctx select { margin: 0; max-width: 330px; min-height: 42px; }
body.dash.site-admin .ctx .turno-row { flex: 1; margin: 0; }
.search-dim { opacity: .18 !important; }
.search-hit { outline: 2px solid #29a0ff !important; outline-offset: 1px; }

/* Mural público inspirado no painel de referência. */
body.dash.site-public {
  font-family: Inter, Manrope, "Segoe UI", Arial, sans-serif;
  background: #06172a;
}
body.dash.site-public::before { opacity: .045; }
body.dash.site-public .deco { display: none; }
.public-heading {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 12px;
}
.public-heading h1 { margin: 0; font-size: 1.45rem; line-height: 1.12; }
.public-heading .head-sub { color: #9bb3ca; font-size: .78rem; font-weight: 500; }
.public-heading-icon { width: 42px; height: 42px; }
.public-heading-icon { display: flex; align-items: center; justify-content: center; }
.public-heading-icon .ico { width: 22px; height: 22px; }
.public-date {
  margin-left: auto;
  margin-top: 0;
  margin-right: 0;
  margin-bottom: 0;
  color: #c9d9e8;
  font-size: .78rem;
  font-weight: 700;
  white-space: nowrap;
}
body.dash.site-public .day-board-fit {
  padding: 0 6px 6px;
  overflow: visible;
  border: 1px solid #173f64;
  border-radius: 14px;
  background: #081f38;
}
body.dash.site-public .day-board {
  width: 100%;
  border-collapse: separate;
  border-spacing: 6px 5px;
  min-width: 0;
}
/* Cabeçalho da série = coluna, não card de aula. */
body.dash.site-public .day-board thead th {
  height: auto;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
body.dash.site-public .day-board thead th.aula {
  position: sticky;
  top: 0;
  z-index: 13;
  background: #081f38;
  color: #8faac3;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
body.dash.site-public .day-board thead th[data-serie] {
  font-size: 1.15rem;
  font-weight: 800;
  padding: 8px 4px 10px;
  border-radius: 0;
}
body.dash.site-public .day-board thead th[data-serie="6"] {
  background: #3B1D6E;
  color: #F3E8FF;
  box-shadow: inset 0 -4px 0 #A78BFA, 0 8px 0 #06172a;
}
body.dash.site-public .day-board thead th[data-serie="7"] {
  background: #7C2D12;
  color: #FFEDD5;
  box-shadow: inset 0 -4px 0 #FDBA74, 0 8px 0 #06172a;
}
body.dash.site-public .day-board thead th[data-serie="8"] {
  background: #1A3A12;
  color: #ECFCCB;
  box-shadow: inset 0 -4px 0 #A3E635, 0 8px 0 #06172a;
}
body.dash.site-public .day-board thead th[data-serie="9"] {
  background: #3F3508;
  color: #FEF9C3;
  box-shadow: inset 0 -4px 0 #F5C400, 0 8px 0 #06172a;
}
body.dash.site-public .day-board td[data-serie] {
  background: transparent;
  box-shadow: none;
}
body.dash.site-public .day-board td,
body.dash.site-public .day-board th.aula { padding: 0; }
body.dash.site-public .day-board tbody th.aula {
  border: 0;
  border-radius: 0;
  background: #0b2946;
}
/* Linha de agora: contorno amarelo no número e em cada card. O selo Agora
   fica amarelo sobre o fundo escuro. */
body.dash.site-public .day-board tbody tr.is-now th.aula {
  background: #0b2946;
  color: #f4f7fb;
  border-radius: 8px;
  box-shadow: inset 0 0 0 3px #F5C518;
}
body.dash.site-public .day-board tbody tr.is-now th.aula .hora {
  color: #c5d4e4;
}
body.dash.site-public .day-board tbody tr.is-now th.aula .aula-now {
  background: #F5C518;
  color: #071A2B;
}
body.dash.site-public .day-board tbody tr.is-now td.fill .cell,
html.eh-full body.dash.site-public .day-board tbody tr.is-now td.fill .cell {
  box-shadow: inset 0 0 0 3px #F5C518;
}
/* Piscar da linha inteira. Estas regras vêm depois do contorno fixo de "agora",
   senão só o número troca e os cards ficam parados. */
body.dash.site-public .day-board tbody tr.is-now.is-pulse th.aula,
body.dash.site-public .day-board tbody tr.is-now.is-pulse td.fill .cell,
body.dash.site-public .day-board tbody tr.is-now.is-pulse td.muted,
html.eh-full body.dash.site-public .day-board tbody tr.is-now.is-pulse th.aula,
html.eh-full body.dash.site-public .day-board tbody tr.is-now.is-pulse td.fill .cell,
html.eh-full body.dash.site-public .day-board tbody tr.is-now.is-pulse td.muted {
  box-shadow: none;
}
body.dash.site-public .day-board tbody tr.is-now.is-pulse.is-pulse-lit th.aula,
body.dash.site-public .day-board tbody tr.is-now.is-pulse.is-pulse-lit td.fill .cell,
body.dash.site-public .day-board tbody tr.is-now.is-pulse.is-pulse-lit td.muted,
html.eh-full body.dash.site-public .day-board tbody tr.is-now.is-pulse.is-pulse-lit th.aula,
html.eh-full body.dash.site-public .day-board tbody tr.is-now.is-pulse.is-pulse-lit td.fill .cell,
html.eh-full body.dash.site-public .day-board tbody tr.is-now.is-pulse.is-pulse-lit td.muted {
  box-shadow: inset 0 0 0 5px #F5C518;
}
body.dash.site-public .day-board td.fill .cell {
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 48px;
  padding: 5px 7px;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 8px;
  box-shadow: none;
  transition: transform .2s ease, filter .2s ease;
}
body.dash.site-public .day-board td.muted {
  border: 0;
  border-radius: 0;
  background: inherit;
  text-align: center;
  color: #6d8aa6;
}
.cell-ico {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: rgba(255,255,255,.22);
}
.cell-ico .ico { width: 14px; height: 14px; }
.cell-copy { min-width: 0; }
body.dash.site-public .break-row th,
body.dash.site-public .break-row td {
  height: 32px;
  border: 1px solid #214c72;
  border-radius: 8px;
  background: #0a2a48;
  color: #bcd2e7;
}
body.dash.site-public .break-row th .ico { width: 18px; height: 18px; }
body.dash.site-public .break-row td {
  padding: 5px 12px;
  text-align: center;
  font-weight: 700;
}
body.dash.site-public .break-row td small { margin-left: 8px; color: #7f9fbd; font-weight: 500; }
body.dash .lunch-pill {
  background: #0e4a6e;
  color: #e7f4ff;
  overflow: visible;
  text-overflow: clip;
  white-space: nowrap;
  font-size: 0.78rem;
}
body.dash.site-public .lunch-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0e4a6e;
  color: #e7f4ff;
  text-align: center;
  padding: 4px 2px;
}
body.dash.site-public .day-board td.fill .lunch-cell b {
  display: block;
  width: 100%;
  overflow: visible;
  text-overflow: clip;
  font-size: 13px;
  line-height: 1.1;
  white-space: nowrap;
  text-align: center;
}
body.dash .gcell.lunch { cursor: grab; }
@media (hover: hover) {
  body.dash.site-public .day-board td.fill .cell:hover {
    z-index: 2;
    transform: translateY(-2px);
    filter: brightness(1.06);
  }
}
html.eh-full body.dash.site-public .public-heading,
html.eh-full body.dash.site-public .tool-stack,
html.eh-full body.dash.site-public .opts-panel { display: none; }
html.eh-full body.dash.site-public .day-board-fit {
  width: 100%;
  flex: 1 1 auto;
}
html.eh-full body.dash.site-public .day-board {
  border-spacing: 3px 3px !important;
}
html.eh-full body.dash.site-public .day-board td.fill .cell {
  min-height: 0 !important;
  height: 100%;
  width: 100%;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px 8px;
  border-radius: 10px;
  border: 1px solid rgba(0, 0, 0, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28);
}
html.eh-full body.dash.site-public .day-board td.fill .cell-ico {
  flex: 0 0 26px;
  width: 26px;
  height: 26px;
  margin: 0;
  border-radius: 8px;
  background: #fff;
  color: #16324a;
  box-shadow: 0 1px 2px rgba(7, 26, 43, 0.28);
}
html.eh-full body.dash.site-public .day-board td.fill .cell-ico .ico {
  width: 16px;
  height: 16px;
  display: block;
}
html.eh-full body.dash.site-public .day-board td.fill .cell-copy {
  flex: 0 1 auto;
  width: 100%;
  min-width: 0;
  text-align: center;
}
html.eh-full body.dash.site-public .day-board td.fill .cell b,
html.eh-full body.dash.site-public .day-board td.fill .cell i {
  text-align: center;
}
html.eh-full .day-board td.fill .cell b {
  letter-spacing: -0.015em;
}
html.eh-full .day-board td.muted {
  color: #6d88a3;
  font-weight: 500;
}
html.eh-full body.dash.site-public .day-board td.fill .cell:hover {
  transform: none;
  filter: none;
}
html.eh-full body.dash.site-public .day-board td.fill .lunch-cell {
  justify-content: center;
}
html.eh-full body.dash.site-public .break-row th,
html.eh-full body.dash.site-public .break-row td,
html.eh-full body.dash.site-public .lunch-row td {
  height: auto;
  min-height: 0;
}

@media (max-width: 899px) {
  body.dash.site-admin .filter-line {
    align-items: flex-start;
  }
  body.dash.site-admin .tabs,
  body.dash.site-admin .grade-tools {
    grid-template-columns: 1fr 1fr;
  }
  body.dash.site-admin .week {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
  body.dash.site-admin .tabs button,
  body.dash.site-admin .grade-tools > button,
  body.dash.site-admin .grade-tools > a {
    white-space: normal;
    height: auto;
    min-height: 40px;
  }
  .stretch-row { grid-template-columns: 1fr 1fr; }
  .stretch-row > button { grid-column: 1 / -1; }
  body.dash.site-admin .chk-pair {
    grid-template-columns: 1fr;
  }
  .admin-date { display: none; }
  body.dash.site-admin .ctx { display: block; }
  body.dash.site-admin .ctx select { max-width: none; margin-bottom: 8px; }
  .public-heading { margin-bottom: 10px; }
  .public-heading-icon { width: 38px; height: 38px; }
  .public-heading h1 { font-size: 1.12rem; }
  .public-heading .head-sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .public-date { display: none; }
  body.dash.site-public:not(.eh-full) .day-board-fit { overflow-x: auto; }
  body.dash.site-public .day-board { min-width: 880px; }
  html.eh-full body.dash.site-public .day-board { min-width: 0 !important; }
}

/* Grade pública — visual, fundo e TV. Não altera a secretaria. */
body.dash.site-public {
  background: #071f33;
  color: #f1f5f9;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}
html.is-pc body.dash.site-public .wrap:not(.login-page),
html.is-mobile body.dash.site-public .wrap,
body.dash.site-public .wrap {
  max-width: none;
  width: 100%;
  margin: 0;
  padding: 24px 48px 28px;
}
body.dash.site-public .public-heading {
  align-items: flex-start;
  width: 100%;
  margin-bottom: 14px;
}
body.dash.site-public .public-heading h1 {
  font-size: 1.7rem;
  line-height: 1.15;
  color: #f1f5f9;
}
body.dash.site-public .public-heading .head-sub {
  color: #d5e4f2;
  font-size: 0.95rem;
  font-weight: 500;
}
body.dash.site-public .public-date {
  display: block;
  margin-top: 8px;
  margin-left: auto;
  color: #f1f5f9;
  font-size: 1rem;
  font-weight: 700;
}
body.dash.site-public::before {
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='320' height='220' viewBox='0 0 320 220'%3E%3Cg fill='none' stroke='%2338e5bd' stroke-width='2'%3E%3Crect x='18' y='24' width='28' height='36' rx='3'/%3E%3Cpath d='M32 24v36'/%3E%3Cpath d='M78 30l8 28 8-28'/%3E%3Ccircle cx='150' cy='40' r='16'/%3E%3Cpath d='M150 24v32M134 40h32'/%3E%3Cpath d='M210 22h36l-8 14h-20z'/%3E%3Cpath d='M250 58l18 8-18 8'/%3E%3Crect x='24' y='120' width='40' height='8' rx='2'/%3E%3Ccircle cx='120' cy='140' r='10'/%3E%3Cpath d='M168 128h28M168 140h20'/%3E%3Cpath d='M230 120l16 28h-32z'/%3E%3C/g%3E%3Ctext x='70' y='100' fill='%2338e5bd' font-size='18' font-family='Arial'%3EABC%3C/text%3E%3Ctext x='200' y='180' fill='%2338e5bd' font-size='18' font-family='Arial'%3E123%3C/text%3E%3Ctext x='40' y='190' fill='%2338e5bd' font-size='16' font-family='Arial'%3E+%3C/text%3E%3C/svg%3E");
  background-size: 320px 220px;
}
body.dash.site-public .public-heading > div {
  min-width: 0;
  flex: 1 1 auto;
}
body.dash.site-public .deco-books,
body.dash.site-public .deco-cal,
body.dash.site-public .deco-plane { opacity: 1; }
body.dash.site-public .banner {
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  margin-bottom: 8px;
  border-width: 1px;
  border-color: #f6c445;
  border-radius: 10px;
  background: #3a3014;
  box-shadow: none;
}
body.dash.site-public .banner-ico {
  flex-basis: 26px;
  width: 26px;
  height: 26px;
  font-size: 0.95rem;
  box-shadow: none;
}
body.dash.site-public .banner b {
  margin-bottom: 0;
  font-size: 0.95rem;
  line-height: 1.2;
}
body.dash.site-public .banner span.banner-txt {
  font-size: 0.78rem;
  line-height: 1.25;
}
body.dash.site-public .seg-btn.on,
body.dash.site-public .tool-row .seg-btn.on {
  background: #38e5bd;
  color: #06281f;
  border-color: #38e5bd;
  box-shadow: none;
}
body.dash.site-public .tool-secondary .tool-btn {
  background: #0d2b45;
  border: 1px solid #235477;
  color: #afc1d4;
  box-shadow: none;
}
body.dash.site-public button:focus,
body.dash.site-public a:focus {
  outline: 3px solid #38e5bd;
  outline-offset: 3px;
}
body.dash.site-public:not(.eh-full) .day-board th.aula {
  font-size: 1.15rem;
  font-weight: 800;
}
body.dash.site-public:not(.eh-full) .day-board th.aula .hora {
  display: block;
  margin-top: 2px;
  font-size: 0.72rem;
  font-weight: 500;
  color: #afc1d4;
}
body.dash.site-public .tool-stack {
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  width: 100%;
  gap: 12px;
}
body.dash.site-public .tool-line-split {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
}
body.dash.site-public .tool-line-split .turno-row {
  display: flex;
  width: auto;
  margin: 0;
  gap: 10px;
}
body.dash.site-public .tool-line-split .turno-row button {
  min-width: 168px;
  height: 48px;
  min-height: 48px;
  padding: 0 14px;
  border-radius: 12px;
  font-size: 1rem;
}
body.dash.site-public .tool-line-split .turno-row button.on {
  background: #38e5bd;
  color: #06281f;
  border-color: #38e5bd;
  box-shadow: none;
}
body.dash.site-public .tool-stack.tool-line-split {
  align-items: flex-start;
  justify-content: flex-start;
}
body.dash.site-public .tool-cluster {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  min-width: 0;
}
body.dash.site-public .tool-cluster .seg-row,
body.dash.site-public .tool-cluster .turno-row {
  width: auto;
  margin: 0;
  flex: 0 0 auto;
}
body.dash.site-public .tool-line-split .tool-secondary {
  margin-left: 0;
}
body.dash.site-public .both-now {
  width: 100%;
}
body.dash.site-public .both-head {
  display: flex;
  align-items: center;
  margin: 0 0 12px;
  padding: 10px 14px;
  border-radius: 12px;
  background: #f5c518;
  color: #1a1408;
  font-size: 1.15rem;
  font-weight: 700;
}
body.dash.site-public .both-head > * {
  margin: 0 16px 0 0;
}
body.dash.site-public .both-head > *:last-child {
  margin-right: 0;
}
body.dash.site-public .both-head em {
  font-style: normal;
  font-weight: 700;
}
body.dash.site-public .both-cols {
  display: flex;
  align-items: flex-start;
}
body.dash.site-public .both-col + .both-col {
  margin-left: 16px;
}
body.dash.site-public .both-col {
  flex: 1 1 0;
  min-width: 0;
}
body.dash.site-public .both-col h2 {
  margin: 0 0 8px;
  font-size: 1.05rem;
  color: #e8f2fb;
}
body.dash.site-public .both-cards {
  display: flex;
  flex-direction: column;
}
body.dash.site-public .both-card + .both-card {
  margin-top: 8px;
}
body.dash.site-public .both-card {
  display: flex;
  flex-direction: column;
  min-height: 64px;
  padding: 8px 12px;
  border-radius: 12px;
}
body.dash.site-public .both-card strong,
body.dash.site-public .both-card em {
  margin-top: 2px;
}
body.dash.site-public .both-card b {
  font-size: 0.82rem;
  font-weight: 700;
  opacity: 0.85;
}
body.dash.site-public .both-card strong {
  font-size: 1.15rem;
  line-height: 1.15;
}
body.dash.site-public .both-card em {
  font-style: normal;
  font-size: 0.95rem;
}
body.dash.site-public .both-card.empty {
  background: #0d2b45;
  color: #afc1d4;
  border: 1px solid #235477;
}
body.dash.site-public .both-now.is-pulse { box-shadow: inset 0 0 0 3px rgba(245, 197, 24, 0.35); }
body.dash.site-public .both-now.is-pulse.is-pulse-lit { box-shadow: inset 0 0 0 6px #F5C518; }
html.eh-full body.dash.site-public .both-now {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
html.eh-full body.dash.site-public .both-head {
  flex: 0 0 auto;
  margin: 0 0 6px;
  padding: 6px 12px;
  min-height: 0;
  font-size: 1.25rem;
}
html.eh-full body.dash.site-public .both-cols {
  flex: 1 1 auto;
  min-height: 0;
  align-items: stretch;
}
html.eh-full body.dash.site-public .both-col {
  display: flex;
  flex-direction: column;
  min-height: 0;
}
html.eh-full body.dash.site-public .both-col h2 {
  flex: 0 0 auto;
  margin: 0 0 4px;
  font-size: 1.05rem;
}
html.eh-full body.dash.site-public .both-cards {
  flex: 1 1 auto;
  min-height: 0;
}
html.eh-full body.dash.site-public .both-card + .both-card {
  margin-top: 6px;
}
html.eh-full body.dash.site-public .both-card {
  flex: 1 1 0;
  flex-direction: row;
  align-items: center;
  min-height: 0;
  padding: 0 12px;
  justify-content: flex-start;
  overflow: hidden;
}
html.eh-full body.dash.site-public .both-card strong,
html.eh-full body.dash.site-public .both-card em {
  margin-top: 0;
  margin-left: 12px;
}
html.eh-full body.dash.site-public .both-card b,
html.eh-full body.dash.site-public .both-card strong,
html.eh-full body.dash.site-public .both-card em {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.1;
}
html.eh-full body.dash.site-public .both-card b {
  flex: 0 0 18%;
  font-size: 0.82em;
  font-weight: 800;
}
html.eh-full body.dash.site-public .both-card strong {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 1em;
  font-weight: 800;
}
html.eh-full body.dash.site-public .both-card em {
  flex: 0 0 26%;
  font-size: 0.72em;
  font-weight: 600;
  text-align: right;
}
@media (orientation: landscape) and (max-height: 520px) {
  html.eh-full body.dash.site-public .both-cols { flex-direction: row; }
  html.eh-full body.dash.site-public .both-head {
    margin: 0 0 4px;
    padding: 4px 8px;
    font-size: 1rem;
  }
  html.eh-full body.dash.site-public .both-col h2 {
    margin: 0 0 2px;
    font-size: 0.92rem;
  }
  html.eh-full body.dash.site-public .both-card + .both-card { margin-top: 4px; }
  html.eh-full body.dash.site-public .both-card {
    padding: 0 8px;
  }
  html.eh-full body.dash.site-public .both-card strong,
  html.eh-full body.dash.site-public .both-card em {
    margin-left: 8px;
  }
  html.eh-full #app.wrap,
  html.eh-full .wrap {
    padding: 4px 6px 6px !important;
  }
}
@media (orientation: portrait) and (max-width: 767px) {
  html.eh-full #app.wrap,
  html.eh-full body.dash.site-public .wrap {
    overflow-x: hidden !important;
    overflow-y: auto !important;
    display: block !important;
    -webkit-overflow-scrolling: touch;
  }
  html.eh-full body.dash.site-public .both-now {
    display: block;
    overflow: visible;
    height: auto;
    flex: none;
  }
  html.eh-full body.dash.site-public .both-cols {
    display: flex;
    flex-direction: column;
  }
  html.eh-full body.dash.site-public .both-col + .both-col {
    margin-left: 0;
    margin-top: 12px;
  }
  html.eh-full body.dash.site-public .both-col {
    flex: 0 0 auto;
    min-height: auto;
    height: auto;
    overflow: visible;
  }
  html.eh-full body.dash.site-public .both-cards {
    flex: none;
    min-height: auto;
    height: auto;
  }
  html.eh-full body.dash.site-public .both-card {
    flex: 0 0 auto;
    min-height: 56px;
  }
}
body.dash.site-public .tool-stack .seg-row {
  display: flex;
  flex: 0 0 auto;
  gap: 10px;
  margin: 0;
}
body.dash.site-public .tool-stack .seg-btn {
  flex: 0 0 132px;
  width: 132px;
  min-width: 132px;
  max-width: none;
  height: 48px;
  min-height: 48px;
  padding: 0 12px;
  border-radius: 12px;
  font-size: 1rem;
}
body.dash.site-public .tool-stack .seg-btn:not(.on) {
  background: #0d2b45;
  border: 1px solid #235477;
  color: #f1f5f9;
  box-shadow: none;
}
body.dash.site-public .tool-secondary > .tool-btn,
body.dash.site-public .tool-secondary > .full-btn,
body.dash.site-public .tool-secondary > .tool-chip,
body.dash.site-public .tool-secondary > .print-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: auto;
  min-width: 168px;
  min-height: 48px;
  height: 48px;
  margin: 0;
  padding: 0 14px;
  flex: 0 0 auto;
  border-radius: 12px;
  font-size: 0.95rem;
  box-shadow: none;
}
body.dash.site-public .tool-row.tool-secondary {
  display: flex;
  flex: 1 1 auto;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin: 0;
}
body.dash.site-public button:focus,
body.dash.site-public a:focus,
body.dash.site-public button:focus-visible,
body.dash.site-public a:focus-visible {
  outline: 3px solid #38e5bd;
  outline-offset: 3px;
}
@media (min-width: 1200px) {
  body.dash.site-public .wrap {
    padding-left: 48px;
    padding-right: 48px;
  }
  body.dash.site-public .public-heading h1 { font-size: 2.25rem; }
  body.dash.site-public .public-heading .head-sub {
    font-size: 1.15rem;
    color: #e8f2fb;
    font-weight: 600;
  }
  body.dash.site-public .public-date { font-size: 1.25rem; margin-top: 8px; }
  body.dash.site-public .tool-stack { gap: 16px; }
  body.dash.site-public .tool-stack .seg-row,
  body.dash.site-public .tool-row.tool-secondary { gap: 14px; }
  body.dash.site-public .tool-stack .seg-btn,
  body.dash.site-public .tool-secondary > .tool-btn,
  body.dash.site-public .tool-secondary > .full-btn,
  body.dash.site-public .tool-secondary > .print-btn {
    height: 54px;
    min-height: 54px;
    font-size: 1.08rem;
  }
  body.dash.site-public .tool-stack .seg-btn { flex-basis: 148px; width: 148px; min-width: 148px; }
  body.dash.site-public .tool-secondary > .tool-btn,
  body.dash.site-public .tool-secondary > .full-btn,
  body.dash.site-public .tool-secondary > .print-btn,
  body.dash.site-public .tool-line-split .turno-row button { min-width: 188px; height: 54px; min-height: 54px; font-size: 1.08rem; }
}
@media (min-width: 768px) and (max-width: 1199px) {
  body.dash.site-public .wrap { padding-left: 24px; padding-right: 24px; }
  body.dash.site-public .tool-stack,
  body.dash.site-public .tool-row.tool-secondary { flex-wrap: wrap; }
  body.dash.site-public:not(.eh-full) .day-board-fit {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  body.dash.site-public:not(.eh-full) .day-board { min-width: 880px; }
}
@media (max-width: 767px) {
  html.is-pc body.dash.site-public .wrap:not(.login-page),
  html.is-mobile body.dash.site-public .wrap,
  body.dash.site-public .wrap { padding: 16px 12px 24px; }
  body.dash.site-public .public-heading { flex-wrap: wrap; align-items: flex-start; }
  body.dash.site-public .public-heading > div { flex: 1 1 0%; }
  body.dash.site-public .public-date {
    flex: 1 1 100%;
    margin: 6px 0 0 0;
    font-size: 0.95rem;
  }
  body.dash.site-public .public-heading h1 { font-size: 1.25rem; }
  body.dash.site-public .public-heading .head-sub {
    white-space: normal;
    font-size: 0.86rem;
  }
  body.dash.site-public .tool-stack,
  body.dash.site-public .tool-line-split {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }
  body.dash.site-public .tool-line-split .turno-row { width: 100%; }
  body.dash.site-public .tool-line-split .turno-row button {
    flex: 1 1 0;
    min-width: 0;
    height: 44px;
    min-height: 44px;
  }
  body.dash.site-public .both-cols { flex-direction: column; }
  body.dash.site-public .tool-stack .seg-row,
  body.dash.site-public .tool-row.tool-secondary {
    width: 100%;
    flex-wrap: wrap;
    justify-content: stretch;
    gap: 8px;
  }
  body.dash.site-public .tool-stack .seg-btn {
    flex: 1 1 0;
    width: auto;
    min-width: 0;
    height: 44px;
    min-height: 44px;
    padding: 0 6px;
    font-size: 0.92rem;
  }
  body.dash.site-public .tool-secondary > .tool-btn,
  body.dash.site-public .tool-secondary > .full-btn,
  body.dash.site-public .tool-secondary > .print-btn {
    flex: 1 1 calc(50% - 8px);
    width: auto;
    max-width: calc(50% - 4px);
    min-width: 0;
    height: 44px;
    min-height: 44px;
    padding: 0 8px;
    font-size: 0.88rem;
  }
  body.dash.site-public:not(.eh-full) .day-board-fit {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  body.dash.site-public:not(.eh-full) .day-board { min-width: 760px; }
  html.eh-full body.dash.site-public .day-board { min-width: 0 !important; }
}

@media (min-width: 1100px) {
  body.dash.site-public .tool-stack {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: nowrap;
  }
  body.dash.site-public .tool-cluster { flex-wrap: nowrap; }
  body.dash.site-public .tool-line-split .tool-secondary { margin-left: auto; }
  body.dash.site-public .tool-stack .seg-btn,
  body.dash.site-public .tool-line-split .turno-row button,
  body.dash.site-public .tool-secondary > .tool-btn,
  body.dash.site-public .tool-secondary > .full-btn {
    width: auto;
    min-width: 0;
    flex: 0 0 auto;
    padding: 0 16px;
  }
}

body.dash.site-admin #app.wrap { max-width: none; padding: 0 0 8px; }
.shell { min-height: 100vh; }
.topbar {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 64px;
  padding: 8px 16px;
  border-bottom: 1px solid #1c3d5c;
  background: #071A2B;
  position: sticky;
  top: 0;
  z-index: 25;
}
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand h1 { margin: 0; font-size: 1.05rem; line-height: 1.2; }
.brand span { display: block; color: #9bb8d0; font-size: 0.75rem; }
.brand .admin-ico { width: 28px; height: 28px; color: #20E6B2; }
.topbar .admin-search-wrap { position: relative; flex: 1 1 240px; margin: 0; min-width: 160px; }
.topbar .admin-search-hits {
  position: absolute;
  z-index: 30;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  background: #0D2B45;
  border: 1px solid #235477;
  border-radius: 10px;
  padding: 6px;
}
.top-meta { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.top-meta .site-link, .top-meta #out { height: 40px; min-height: 40px; padding: 8px 12px; }
.shell-body { display: flex; align-items: flex-start; }
.sidenav {
  width: 212px;
  flex: 0 0 212px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px;
  position: sticky;
  top: 64px;
  max-height: calc(100vh - 64px);
  overflow: auto;
}
.sidenav button {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  width: 100%;
  height: 42px;
  min-height: 42px;
  padding: 8px 12px;
  background: transparent;
  border-color: transparent;
  box-shadow: none;
  color: #d5e8f6;
}
.sidenav button.on {
  background: #12344e;
  border-color: #20E6B2;
  color: #20E6B2;
}
.admin-main { flex: 1; min-width: 0; padding: 16px 20px 48px; max-width: 1600px; }
body.dash.site-admin #app.grade-wide .admin-main { max-width: none; }
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin: 0 0 14px; }
.page-head h2 { margin: 0 0 4px; font-size: 1.35rem; }
.page-head .ctx { margin: 0; }
body.dash.site-admin #grade-tools.grade-bar {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  grid-template-columns: none;
  overflow-x: auto;
}
body.dash.site-admin #grade-tools .week,
body.dash.site-admin #grade-tools .filter-line,
body.dash.site-admin #grade-tools .grade-picks,
body.dash.site-admin #grade-tools .grade-acts {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  width: auto;
  min-width: 0;
  margin: 0;
  grid-template-columns: none;
}
body.dash.site-admin #grade-tools .filter-k {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  height: 40px;
  line-height: 1;
}
body.dash.site-admin #grade-tools .week button,
body.dash.site-admin #grade-tools .grade-picks button,
body.dash.site-admin #grade-tools .grade-acts > button,
body.dash.site-admin #grade-tools .grade-acts > a {
  width: auto;
  min-width: 0;
  flex: 0 0 auto;
  height: 40px;
  min-height: 40px;
  margin: 0;
  padding: 0 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  line-height: 1;
  white-space: nowrap;
  box-sizing: border-box;
}
body.dash.site-admin #grade-tools .grade-acts {
  gap: 8px;
  margin-left: auto;
}
body.dash.site-admin .page-head .ctx {
  flex: 0 0 auto;
  align-items: center;
}
body.dash.site-admin .page-head .row.turno-row {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 8px;
  width: auto;
  max-width: none;
  margin: 0;
}
body.dash.site-admin .page-head .row.turno-row > button {
  flex: 0 0 auto;
  width: auto;
  height: 40px;
  min-height: 40px;
  margin: 0;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  white-space: nowrap;
}
body.dash.site-admin #grade-tools .grade-acts > button.tv-pulse {
  background: transparent;
  border-color: #38E5BD;
  color: #38E5BD;
}
body.dash.site-admin #grade-tools .grade-acts > a {
  color: #F1F5F9;
  text-decoration: none;
  background: #0D2B45;
  border: 1px solid #235477;
  border-radius: 12px;
  font-weight: 600;
}
body.dash.site-admin #grade-tools .admin-ico {
  position: static;
  display: block;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  transform: none;
  color: currentColor;
}
.top-meta .site-link,
.top-meta #out {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  white-space: nowrap;
}
.sidenav button { line-height: 1; }
.sidenav .admin-ico {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  display: block;
}
.prof-bulk { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.prof-bulk button { flex: 0 0 auto; height: 40px; min-height: 40px; width: auto; }
.serie-pop { position: relative; display: inline-block; min-width: 140px; }
.serie-pop > summary {
  cursor: pointer;
  list-style: none;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid #3974A0;
  border-radius: 10px;
  background: #102B45;
}
.serie-pop > summary::-webkit-details-marker { display: none; }
.serie-pop-box {
  position: absolute;
  z-index: 40;
  top: calc(100% + 4px);
  left: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  width: max-content;
  max-width: 280px;
  padding: 8px;
  background: #0D2B45;
  border: 1px solid #235477;
  border-radius: 10px;
}
.switch { position: relative; display: inline-flex; width: 44px; height: 26px; }
.switch input {
  position: absolute;
  opacity: 0;
  width: 44px;
  height: 26px;
  min-height: 26px;
  margin: 0;
  cursor: pointer;
}
.switch-ui {
  width: 44px;
  height: 26px;
  border-radius: 99px;
  background: #1c3d5c;
  border: 1px solid #3974A0;
  display: block;
  position: relative;
}
.switch-ui::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #9bb8d0;
}
.switch input:checked + .switch-ui { background: #20E6B2; border-color: #20E6B2; }
.switch input:checked + .switch-ui::after { transform: translateX(18px); background: #06281f; }
@media (max-width: 899px) {
  .topbar { flex-wrap: wrap; position: static; }
  .top-meta { width: 100%; flex-wrap: wrap; }
  .shell-body { display: block; padding-bottom: 76px; }
  .sidenav {
    position: fixed;
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    width: auto;
    max-height: none;
    flex-direction: row;
    overflow-x: auto;
    gap: 4px;
    padding: 6px 8px calc(6px + env(safe-area-inset-bottom, 0px));
    border-top: 1px solid #1c3d5c;
    background: #071A2B;
    z-index: 30;
  }
  .sidenav button { flex: 0 0 auto; width: auto; }
  .page-head { flex-direction: column; }
  .admin-main { padding: 12px 12px 24px; }
}
.grade-day-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.grade-day-line .grade-day { margin: 8px 0; }
.grade-queue {
  margin: 0 0 12px;
  padding: 12px 14px;
  background: #0D2B45;
  border: 1px solid #e8c547;
  border-radius: 12px;
}
.grade-queue ul { margin: 8px 0; padding-left: 18px; }
.grade-queue li { margin: 2px 0; }
.gcell.pending,
.lesson-wrap.pending { outline: 2px solid #e8c547; outline-offset: -2px; }

.nav-short { display: none; }
.nav-more-btn { display: none; }
.nav-sheet { display: none; }
.phone-only { display: none; }
body.dash.site-admin .dia-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 14px;
}
body.dash.site-admin .dia-chip {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  width: auto;
  min-width: 132px;
  height: auto;
  min-height: 48px;
  padding: 8px 12px;
  white-space: normal;
  line-height: 1.15;
  background: #0D2B45;
  border: 1px solid #235477;
  color: #F1F5F9;
  border-radius: 12px;
}
body.dash.site-admin .dia-chip b { font-size: 0.95rem; }
body.dash.site-admin .dia-chip span { font-size: 0.78rem; font-weight: 600; color: #AFC1D4; }
body.dash.site-admin .dia-chip.on {
  background: #38E5BD;
  color: #06281f;
  border-color: #38E5BD;
}
body.dash.site-admin .dia-chip.on span { color: #06281f; }
.notify-acts { display: flex; flex-direction: column; align-items: stretch; gap: 8px; margin: 8px 0 14px; }
.notify-acts button { width: 100%; min-height: 44px; height: auto; white-space: normal; }
.quiet-days { display: flex; flex-direction: column; gap: 2px; margin: 8px 0; }
.color-pop { margin: 4px 0; }
.color-pop > summary {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  cursor: pointer;
  list-style: none;
}
.color-pop > summary::-webkit-details-marker { display: none; }
.color-pop summary i.swatch { display: inline-block; }

@media (min-width: 900px) {
  .prof-open { display: none; }
}
@media (max-width: 899px) {
  .phone-only { display: block; }
  .nav-more-btn { display: inline-flex; }
  .sidenav > .nav-extra { display: none; }
  .sidenav > button .nav-lab { display: none; }
  .sidenav > button .nav-short { display: inline; }
  .sidenav.more-open .nav-sheet {
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: fixed;
    left: 8px;
    right: 8px;
    bottom: calc(62px + env(safe-area-inset-bottom, 0px));
    z-index: 40;
    padding: 8px;
    background: #0D2B45;
    border: 1px solid #235477;
    border-radius: 12px;
  }
  .sidenav.more-open .nav-sheet button { width: 100%; justify-content: flex-start; }
  body.dash.site-admin #grade-tools.grade-bar {
    flex-wrap: wrap;
    align-items: stretch;
    overflow: visible;
  }
  body.dash.site-admin #grade-tools .week,
  body.dash.site-admin #grade-tools .filter-line,
  body.dash.site-admin #grade-tools .grade-picks,
  body.dash.site-admin #grade-tools .grade-acts {
    flex: 1 1 100%;
    flex-wrap: wrap;
    width: 100%;
  }
  body.dash.site-admin #grade-tools .grade-acts { margin-left: 0; }
  body.dash.site-admin #grade-tools .week button { flex: 1 1 0; }
  body.dash.site-admin .dia-chips { display: grid; grid-template-columns: 1fr; }
  body.dash.site-admin .dia-chip { width: 100%; min-width: 0; }
  .prof-table td[data-fold] { display: none; }
  .prof-table tr.open td[data-fold] { display: block; }
  .prof-open { margin-top: 8px; min-height: 36px; }
}




/* ── Ajustes de layout 26/10/2026 ─────────────────────────────────────── */
/* Login da secretaria: centralizado, com espaço no topo. */
body.dash.site-admin .wrap.login-page {
  max-width: none;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
}
body.dash.site-admin .wrap.login-page .login-box {
  width: 100%;
  max-width: 340px;
  margin: 0;
  padding: 28px 24px 24px;
  background: #0D2B45;
  border: 1px solid #235477;
  border-radius: 16px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
}
body.dash.site-admin .login-box h1 { margin: 0 0 4px; font-size: 1.35rem; }
body.dash.site-admin .login-box .login-sub { margin: 0 0 18px; color: #AFC1D4; font-size: 0.9rem; }
body.dash.site-admin .login-box form { display: flex; flex-direction: column; gap: 10px; }
body.dash.site-admin .login-box input,
body.dash.site-admin .login-box button { width: 100%; min-height: 46px; }

/* Celular: as 4 abas + Mais cabem na largura, ícone em cima e nome embaixo (antes "Ajustes" cortava e "Mais" sumia). */
@media (max-width: 899px) {
  body.dash.site-admin .sidenav {
    overflow-x: hidden;
    gap: 2px;
    padding: 6px 4px calc(6px + env(safe-area-inset-bottom, 0px));
  }
  body.dash.site-admin .sidenav > button:not(.nav-extra),
  body.dash.site-admin .sidenav > .nav-more-btn {
    flex: 1 1 0;
    min-width: 0;
    width: auto;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    height: 54px;
    min-height: 54px;
    padding: 4px 2px;
    font-size: 0.74rem;
  }
  body.dash.site-admin .sidenav > button .nav-short,
  body.dash.site-admin .sidenav > .nav-more-btn span {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  body.dash.site-admin .shell-body { padding-bottom: 80px; }
}

/* Computador: a barra da Grade quebra linha em vez de esconder "Piscar site" na rolagem lateral. */
@media (min-width: 900px) {
  body.dash.site-admin #grade-tools.grade-bar { flex-wrap: wrap; overflow: visible; row-gap: 8px; }
  body.dash.site-admin #grade-tools .grade-acts { flex-wrap: wrap; }
}

/* Botões em dupla com texto de duas linhas ("Ver o que muda") crescem em vez de cortar. */
body.dash.site-admin .pair-acts button { height: auto; min-height: 48px; white-space: normal; line-height: 1.2; }

/* "Desativar avisos" discreto e em vermelho, separado de "Ativar avisos" (dá para confundir os dois). */
body.dash.site-admin .prof-bulk #wa-off-all {
  order: 9;
  margin-left: auto;
  color: #f0b4b4;
  border-color: #c45c5c;
  background: transparent;
}

/* Resumo de "Séries" alinhado com os outros campos da linha. */
body.dash.site-admin .serie-pop > summary { display: flex; align-items: center; min-height: 48px; }

/* Site público no computador (fora do modo TV): nome do dia legível nos botões largos da Semana. */
html.is-pc:not(.eh-full) body.dash.site-public .week button { font-size: 1rem; font-weight: 700; }

/* Turmas do professor (28/10): uma série por linha — o número ("6º") marca/desmarca a série
   inteira; ao lado, as turmas (6º A, 6º B). */
body.dash .serie-pop-box .serie-nums { display: flex; flex-direction: column; align-items: flex-start; flex-wrap: nowrap; gap: 6px; }
body.dash .serie-pop-box .serie-group { display: inline-flex; align-items: center; gap: 6px; }
body.dash .serie-pop-box .serie-group > .serie-tool { min-width: 46px; }
.serie-pop-box { max-width: 340px; }
/* Caixa de aviso/erro sem texto não aparece (no editor de aula ficava uma barra vermelha vazia). */
body.dash .err:empty, body.dash .flash:empty { display: none; }
/* Mudanças da Grade não gravadas: a barra fica presa no topo e chama atenção (28/10). */
body.dash.site-admin .grade-queue { position: sticky; top: 72px; z-index: 30; border: 2px solid #ffca28; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35); }
@media (max-width: 899px) { body.dash.site-admin .grade-queue { top: 8px; } }

/* Computador: menu lateral completo, sem "Mais" nem gaveta (antes o "Mais" aparecia sem função). */
@media (min-width: 900px) {
  body.dash .sidenav > .nav-more-btn,
  body.dash .nav-sheet { display: none !important; }
  body.dash .sidenav > button .nav-lab { text-align: left; line-height: 1.15; }
}

/* Professores: um "Salvar alterações" só, preso no topo quando há alteração; linha alterada em destaque. */
.prof-savebar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 0 0 12px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; }
.prof-savebar > span { flex: 1 1 240px; }
.prof-savebar button { flex: 0 0 auto; width: auto; height: 40px; min-height: 40px; }
.prof-savebar.dirty { position: sticky; top: 72px; z-index: 30; background: var(--surface); border: 2px solid #ffca28; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35); }
@media (max-width: 899px) { .prof-savebar.dirty { top: 8px; } }
.prof-table tr.prof-dirty > td { background: rgba(255, 202, 40, 0.08); }
.prof-table tr.prof-dirty > td:first-child { box-shadow: inset 4px 0 0 #ffca28; }

/* Etapa 5: listas de cadastro, excluir, Avisos e Atividades. */
.cad-table .row-acts, .prof-table .row-acts { white-space: nowrap; }
.row-acts { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.row-acts button { width: auto; flex: 0 0 auto; }
.danger-ghost { color: #ff8a80; border-color: rgba(255, 138, 128, 0.45); }
.danger-ghost:hover { background: rgba(255, 82, 82, 0.12); }
.cad-table input { min-width: 0; }
.num-short { max-width: 140px; }
.atv-card h3 { margin: 0 0 4px; font-size: 1rem; }
.atv-card p { margin: 4px 0; }
@media (min-width: 900px) {
  #cad-avisar .notify-acts { flex-direction: row; flex-wrap: wrap; }
  #cad-avisar .notify-acts button { width: auto; flex: 0 0 auto; padding: 0 18px; }
}
.mic-btn { flex: 0 0 auto; }
.cfg-block .btn-row, .atv-card .btn-row { display: flex; flex-wrap: wrap; gap: 8px; }
body.dash.site-admin .danger-ghost { color: #ff8a80; border-color: rgba(255, 138, 128, 0.5); }
body.dash.site-admin .danger-ghost:hover { background: rgba(255, 82, 82, 0.14); }
body.dash.site-admin .cfg-block .btn-row button, body.dash.site-admin .row-acts button { width: auto; flex: 0 0 auto; padding: 0 16px; }
body.dash.site-admin td.row-acts { display: table-cell; vertical-align: middle; white-space: nowrap; }
body.dash.site-admin td.row-acts button { display: inline-flex; height: 40px; min-height: 40px; margin: 2px 6px 2px 0; vertical-align: middle; }
@media (max-width: 899px) { body.dash.site-admin td.row-acts { display: block; } }
body.dash.site-admin td.row-acts button { align-items: center; justify-content: center; padding: 0 16px; line-height: 1; }
