/* Curriculum, Calendar and Write to management in the section-colours look (app 0.17.0).
   The design system is the Letters module's app.css; this adds three section colours and the pieces these pages need.
   Built from the approved mockups (design canvas, page "Curriculum, Calendar, Messages"). */

/* ---- three more section colours (white on -600 and -ink on -50 are both over 4.5:1) ---- */
[data-section="curriculum"], .hue-curriculum {
  --sec-50: #f1f8e8; --sec-100: #e1f0cc; --sec-200: #c4e09b; --sec-500: #65a30d;
  --sec-600: #4d7c0f; --sec-hover: #3f6a0b; --sec-ink: #3f6212; --sec-900: #2b4309;
  --sec-on: #ffffff; --sec-icon: #4d7c0f;
}
[data-section="calendar"], .hue-calendar {
  --sec-50: #fdf6e3; --sec-100: #fbeac0; --sec-200: #f5d384; --sec-500: #ca8a04;
  --sec-600: #a16207; --sec-hover: #854d0e; --sec-ink: #854d0e; --sec-900: #4f2f06;
  --sec-on: #ffffff; --sec-icon: #a16207;
}
[data-section="voice"], .hue-voice {
  --sec-50: #fbf0fc; --sec-100: #f6dcf8; --sec-200: #edb8f1; --sec-500: #c026d3;
  --sec-600: #a21caf; --sec-hover: #86198f; --sec-ink: #86198f; --sec-900: #4a044e;
  --sec-on: #ffffff; --sec-icon: #a21caf;
}
[data-section="curriculum"], [data-section="calendar"], [data-section="voice"],
.hue-curriculum, .hue-calendar, .hue-voice { --accent: var(--sec-600); --accent-2: var(--sec-hover); --accent-soft: var(--sec-50); }

/* ---- shared ---- */
.lede-v { margin: 0 0 18px; color: var(--n-600); font-size: var(--fs-body-lg); max-width: 62ch; }
.soon { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border-radius: var(--r-full); font-size: var(--fs-caption); font-weight: 650;
  background: var(--warning-50); color: var(--warning-900); border: 1px solid var(--warning-200); white-space: nowrap; }
.soon .ic { width: 13px; height: 13px; }
.has-ideas { display: inline-flex; align-items: center; gap: 5px; height: 24px; padding: 0 9px; border-radius: var(--r-full); font-size: var(--fs-caption); font-weight: 650;
  background: var(--sec-50); color: var(--sec-ink); border: 1px solid var(--sec-200); white-space: nowrap; }
.has-ideas .ic { width: 13px; height: 13px; }
.backlink { display: inline-flex; align-items: center; gap: 6px; color: var(--n-600); font-weight: 600; margin-bottom: 14px; min-height: 32px; }

/* ---- Curriculum ---- */
.cu-banner { display: flex; gap: 16px; align-items: center; padding: 18px 20px; border-radius: var(--r-xl); background: #fff; border: 1px solid var(--line); box-shadow: var(--e-1); margin-bottom: 22px; }
.cu-banner .cu-banner-ic { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--sec-100); color: var(--sec-ink); flex: none; }
.cu-banner .cu-banner-ic .ic { width: 24px; height: 24px; }
.cu-banner b { display: block; font-size: var(--fs-body-lg); color: var(--n-900); }
.cu-banner p { margin: 2px 0 0; color: var(--n-600); }
.cu-banner .cu-progress { margin-left: auto; text-align: right; flex: none; }
.cu-banner .cu-progress b { font-size: 1.5rem; color: var(--sec-ink); }
.cu-banner .cu-progress small { display: block; color: var(--n-500); font-size: var(--fs-caption); }
.cu-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 18px; align-items: start; }
.cu-group { background: #fff; border: 1px solid var(--line); border-radius: var(--r-xl); box-shadow: var(--e-1); overflow: hidden; }
.cu-group-head { display: flex; align-items: center; gap: 12px; padding: 16px 18px 12px; }
.cu-group-head h3 { margin: 0; font-size: var(--fs-body-lg); }
.cu-group-head small { display: block; color: var(--n-500); font-size: var(--fs-caption); font-weight: 500; }
.cu-gic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--sec-50); color: var(--sec-ink); flex: none; }
.cu-part { display: flex; align-items: center; gap: 12px; padding: 12px 18px; border-top: 1px solid var(--line-soft); color: var(--n-800); text-decoration: none; min-height: 56px; }
.cu-part:hover { background: var(--n-25); text-decoration: none; }
.cu-part > span:first-child { flex: 1; min-width: 0; }
.cu-part b { display: block; font-weight: 650; color: var(--n-900); }
.cu-part small { display: block; color: var(--n-500); font-size: var(--fs-label); margin-top: 1px; }
.cu-part .cu-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.cu-part > .ic { color: var(--n-400); }
.cu-also { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 22px; color: var(--n-600); font-size: var(--fs-label); }
.cu-also .cu-also-item { display: inline-flex; align-items: center; height: 32px; padding: 0 12px; border-radius: var(--r-full); border: 1px dashed var(--line-strong); color: var(--n-600); font-weight: 600; }
.cu-also a { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px; border-radius: var(--r-full); background: #fff; border: 1px solid var(--line); color: var(--n-800); font-weight: 600; }

.cu-head { display: flex; gap: 16px; align-items: flex-start; padding: 20px 22px; }
.cu-head .cu-gic { width: 52px; height: 52px; border-radius: 14px; }
.cu-head .cu-gic .ic { width: 26px; height: 26px; }
.cu-head { flex-wrap: wrap; }
.cu-head-t { flex: 1 1 260px; min-width: 0; }
.cu-eyebrow { font-size: var(--fs-overline); text-transform: uppercase; letter-spacing: .08em; font-weight: 700; color: var(--sec-ink); }
.cu-head h2 { margin: 2px 0 4px; font-size: 1.5rem; }
.cu-head p { margin: 0; color: var(--n-600); }
.cu-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 18px; align-items: start; }
.cu-will { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.cu-will li { display: flex; gap: 10px; align-items: flex-start; }
.cu-will li .ic { color: var(--sec-icon); margin-top: 2px; }
.cu-works { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.cu-works a { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: var(--r-full); border: 1px solid var(--line); background: var(--n-25); color: var(--n-800); font-weight: 600; font-size: var(--fs-label); }
.cu-works .cu-work { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: var(--r-full); border: 1px dashed var(--line-strong); color: var(--n-600); font-weight: 600; font-size: var(--fs-label); }
.cu-works .cu-work .dotc, .cu-works a .dotc { width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
.cu-note { margin-top: 14px; padding: 10px 12px; border-radius: var(--r-md); background: var(--info-50); color: var(--info-900); font-size: var(--fs-label); display: flex; gap: 8px; }
.cu-note .ic { color: var(--info-600); margin-top: 1px; }
.ideas-box textarea { min-height: 200px; }
.ideas-foot { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 12px; }
.ideas-foot .muted { font-size: var(--fs-label); }

/* ---- Calendar ---- */
.cal-top { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.cal-top .seg a { min-width: 92px; justify-content: center; }
.cal-top .actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.yearbar { padding: 18px 20px 16px; }
.yearbar-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.yearbar-head h3 { margin: 0; }
.yb-track { position: relative; height: 40px; border-radius: var(--r-md); background: var(--n-100); margin-top: 20px; }
.yb-term { position: absolute; top: 0; bottom: 0; background: var(--sec-500); border-radius: 6px; color: #fff; font-weight: 700; font-size: var(--fs-caption); display: flex; align-items: center; padding: 0 10px; white-space: nowrap; overflow: hidden;
  box-shadow: inset 0 0 0 2px var(--sec-600); background: var(--sec-600); }
.yb-term .yb-l { overflow: hidden; text-overflow: ellipsis; }
.yb-closed { position: absolute; top: 0; bottom: 0; background: repeating-linear-gradient(135deg, rgba(255,255,255,.85) 0 3px, rgba(255,255,255,.35) 3px 6px); border-left: 1px solid #fff; border-right: 1px solid #fff; }
.yb-today { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--n-900); }
.yb-today::after { content: "Today"; position: absolute; top: -19px; left: 50%; transform: translateX(-50%); font-size: 12px; font-weight: 700; color: var(--n-900); }
.yb-months { display: grid; grid-template-columns: repeat(11, minmax(0, 1fr)); margin-top: 8px; font-size: var(--fs-caption); color: var(--n-500); font-weight: 600; }
.yb-legend { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 12px; font-size: var(--fs-label); color: var(--n-600); }
.yb-legend span { display: inline-flex; align-items: center; gap: 6px; }
.yb-key { width: 14px; height: 14px; border-radius: 4px; background: var(--sec-600); }
.yb-key.closed { background: repeating-linear-gradient(135deg, var(--n-300) 0 3px, var(--n-100) 3px 6px); }
.cal-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 18px; align-items: start; }
.cal-list { list-style: none; margin: 0; padding: 0; }
.cal-list li { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line-soft); }
.cal-list li:first-child { border-top: 0; padding-top: 4px; }
.dblock { width: 52px; flex: none; text-align: center; border-radius: var(--r-md); border: 1px solid var(--line); background: #fff; overflow: hidden; }
.dblock small { display: block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; background: var(--sec-600); color: #fff; padding: 2px 0; }
.dblock b { display: block; font-size: 1.25rem; padding: 3px 0 4px; color: var(--n-900); font-variant-numeric: tabular-nums; }
.cal-what { flex: 1; min-width: 0; }
.cal-what b { display: block; color: var(--n-900); }
.cal-what small { display: block; color: var(--n-500); font-size: var(--fs-label); }
.ctag { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; border-radius: var(--r-full); font-size: var(--fs-caption); font-weight: 650; white-space: nowrap; }
.ctag .ic { width: 13px; height: 13px; }
.ctag.term { background: var(--sec-50); color: var(--sec-ink); border: 1px solid var(--sec-200); }
.ctag.closed { background: var(--n-100); color: var(--n-800); border: 1px solid var(--n-200); }
.ctag.event { background: var(--info-50); color: var(--info-900); border: 1px solid var(--info-200); }
.rows { list-style: none; margin: 0; padding: 0; }
.rows li { display: grid; grid-template-columns: minmax(170px, 230px) minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line-soft); }
.rows li:first-child { border-top: 0; }
.rows .when { font-weight: 650; color: var(--n-800); font-variant-numeric: tabular-nums; }
.rows .what b { display: block; color: var(--n-900); }
.rows .what small { display: block; color: var(--n-500); font-size: var(--fs-label); }
.follows { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.follows > div { display: flex; gap: 10px; padding: 12px; border-radius: var(--r-lg); background: var(--n-25); border: 1px solid var(--line-soft); font-size: var(--fs-label); color: var(--n-700); }
.follows .fic { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; background: #fff; border: 1px solid var(--line); color: var(--c); flex: none; }
.follows b { display: block; color: var(--n-900); font-size: var(--fs-body); }

/* ---- Write to management ---- */
.v-cols { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.aud-cards { display: grid; gap: 10px; margin: 6px 0 18px; }
.aud { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border: 1px solid var(--line-strong); border-radius: var(--r-lg); background: #fff; cursor: pointer; }
.aud-cards label.aud { flex-direction: row; align-items: flex-start; font-weight: 400; margin: 0; font-size: var(--fs-body); color: var(--n-800); }
.aud input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--sec-600); flex: none; }
.aud b { display: block; color: var(--n-900); }
.aud small { display: block; color: var(--n-600); font-size: var(--fs-label); margin-top: 2px; }
.aud .can { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; font-size: var(--fs-caption); color: var(--n-600); }
.aud .can .ic { width: 14px; height: 14px; color: var(--n-400); }
.aud.on { border-color: var(--sec-600); box-shadow: inset 0 0 0 1px var(--sec-600); background: var(--sec-50); }
.priv { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.priv li { display: flex; gap: 12px; align-items: flex-start; }
.priv .pic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--sec-50); color: var(--sec-ink); flex: none; }
.priv b { display: block; color: var(--n-900); }
.priv span { color: var(--n-600); font-size: var(--fs-label); }
.safe-note { display: flex; gap: 10px; padding: 12px 14px; border-radius: var(--r-lg); background: var(--warning-50); border: 1px solid var(--warning-200); color: var(--warning-900); font-size: var(--fs-label); margin-top: 16px; }
.safe-note .ic { color: var(--warning-600); margin-top: 1px; }
.code-in { font-family: var(--font-mono); letter-spacing: .14em; text-transform: uppercase; font-size: 1.125rem; text-align: center; }
.code-show { text-align: center; padding: 26px 18px; }
.code-show .code { display: inline-block; margin: 14px 0 6px; padding: 14px 22px; border-radius: var(--r-lg); border: 2px dashed var(--sec-500); background: var(--sec-50); font-family: var(--font-mono); font-size: 2rem; font-weight: 700; letter-spacing: .14em; color: var(--sec-900); }
.code-show h2 { margin: 12px 0 4px; }
.code-show .ok-big { width: 56px; height: 56px; border-radius: 50%; display: inline-grid; place-items: center; background: var(--success-50); color: var(--success-600); }
.code-show .ok-big .ic { width: 28px; height: 28px; }
.steps-v { text-align: left; list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 12px; }
.steps-v li { display: flex; gap: 10px; }
.steps-v .n { width: 26px; height: 26px; border-radius: 50%; background: var(--sec-600); color: #fff; font-weight: 700; font-size: var(--fs-caption); display: grid; place-items: center; flex: none; }
.vmsg { display: flex; gap: 14px; padding: 16px 18px; border-top: 1px solid var(--line-soft); text-decoration: none; color: var(--n-800); }
.vmsg:first-child { border-top: 0; }
.vmsg:hover { background: var(--n-25); text-decoration: none; }
.vmsg .vic { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--n-100); color: var(--n-500); flex: none; position: relative; }
.vmsg.unread .vic { background: var(--sec-100); color: var(--sec-ink); }
.vmsg.unread .vic::after { content: ""; position: absolute; top: -1px; right: -1px; width: 11px; height: 11px; border-radius: 50%; background: var(--sec-600); box-shadow: 0 0 0 2px #fff; }
.vmsg .vm { flex: 1; min-width: 0; }
.vmsg .vm-top { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.vmsg .vm-top b { color: var(--n-900); }
.vmsg.unread .vm-top b { font-weight: 750; }
.vmsg .vm p { margin: 4px 0 0; color: var(--n-600); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vmsg .vm-side { text-align: right; flex: none; font-size: var(--fs-caption); color: var(--n-500); display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.aud-chip { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: var(--r-full); font-size: var(--fs-caption); font-weight: 650; background: var(--sec-50); color: var(--sec-ink); border: 1px solid var(--sec-200); }
.aud-chip .ic { width: 12px; height: 12px; }
.thread { display: grid; gap: 14px; }
.post { border-radius: var(--r-lg); padding: 14px 16px; border: 1px solid var(--line); background: #fff; max-width: 88%; }
.post .pw { display: flex; align-items: center; gap: 8px; font-size: var(--fs-caption); color: var(--n-500); margin-bottom: 6px; }
.post .pw b { color: var(--n-800); font-size: var(--fs-label); }
.post p { margin: 0 0 8px; }
.post p:last-child { margin: 0; }
.post.staff { background: var(--n-25); }
.post.staff .pav { background: var(--n-200); color: var(--n-600); }
.post.reply { margin-left: auto; background: var(--sec-50); border-color: var(--sec-200); }
.pav { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 10px; font-weight: 700; background: var(--sec-600); color: #fff; }
.pav .ic { width: 13px; height: 13px; }
.notes-v .note { padding: 12px 14px; border-radius: var(--r-md); background: #fffbea; border: 1px solid #f6e7a6; margin-bottom: 10px; }
.notes-v .note small { display: block; color: var(--n-600); font-size: var(--fs-caption); margin-bottom: 4px; }
.status-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* ---- the app's shell in this look ---- */
.hubv2 .side .brand-mark img { display: block; width: 40px; height: 40px; border-radius: var(--r-lg); }
.hubv2 .content > .flash { margin-bottom: var(--sp-4); }
.hubv2 .card-head h3 { margin: 0; }
.hubv2 .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); border: 0; }
.aud:has(input:checked) { border-color: var(--sec-600); box-shadow: inset 0 0 0 1px var(--sec-600); background: var(--sec-50); }
.aud:has(input:focus-visible) { outline: 2px solid var(--focus); outline-offset: 2px; }
.cal-edit > summary, .cal-add > summary { list-style: none; cursor: pointer; }
.cal-edit > summary::-webkit-details-marker, .cal-add > summary::-webkit-details-marker { display: none; }
.cal-edit[open] { grid-column: 1 / -1; }
.cal-edit[open] > summary { margin-bottom: var(--sp-3); }
.cal-form { padding: 14px; border-radius: var(--r-lg); background: var(--n-25); border: 1px solid var(--line-soft); }
.cal-form .fields-3 { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr)); gap: 12px; }
.cal-form .fields-4 { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: 12px; }
.cal-form .form-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 12px; }
.cal-add { margin-top: 12px; }
.cal-add[open] > summary { margin-bottom: 12px; }
.empty-line { color: var(--n-500); margin: 4px 0 0; }
.cu-other { margin-bottom: 14px; padding: 12px 14px; border-radius: var(--r-md); background: var(--n-25); border: 1px solid var(--line); }
.cu-other small { display: block; color: var(--n-600); font-size: var(--fs-caption); margin-bottom: 4px; font-weight: 650; }
.vwait { display: flex; align-items: center; gap: 12px; padding: 14px 16px; margin-bottom: 18px; border-radius: var(--r-xl); background: #fff; border: 1px solid var(--sec-200); box-shadow: var(--e-1); color: var(--n-800); text-decoration: none; }
.vwait:hover { text-decoration: none; border-color: var(--sec-500); }
.vwait .vic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--sec-100); color: var(--sec-ink); flex: none; }
.vwait b { color: var(--n-900); }
.vwait > .ic:last-child { margin-left: auto; color: var(--n-400); }
.post .pbody p { margin: 0 0 8px; }
.post .pbody p:last-child { margin: 0; }
.post .seen { display: inline-flex; align-items: center; gap: 4px; margin-left: auto; color: var(--success-600); font-weight: 650; }

@media (max-width: 1100px) {
  .cal-grid, .v-cols, .cu-cols { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .cu-grid { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .cu-banner { flex-wrap: wrap; padding: 16px; }
  .cu-banner .cu-progress { margin-left: 0; text-align: left; }
  .cu-head { flex-wrap: wrap; padding: 16px; }
  .rows li { grid-template-columns: minmax(0, 1fr) auto; }
  .rows .when { grid-column: 1 / -1; font-size: var(--fs-label); color: var(--n-600); }
  .yb-months span:nth-child(even) { visibility: hidden; }
  .yb-term { padding: 0; }
  .yb-term .yb-l { display: none; }
  .cal-top .actions { margin-left: 0; width: 100%; }
  .cal-top .actions .btn { flex: 1; }
  .cal-form .fields-3, .cal-form .fields-4 { grid-template-columns: minmax(0, 1fr); }
  .post { max-width: 100%; }
  .vmsg { padding: 14px; gap: 12px; }
  .vmsg .vm p { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  .code-show .code { font-size: 1.6rem; padding: 12px 16px; }
  .next.vnext { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .next.vnext > div { border-left: 0; border-top: 1px solid var(--line-soft); padding: 14px; }
  .next.vnext > div:nth-child(-n+2) { border-top: 0; }
}

/* ==========================================================================
   App 0.18.0: every page in the section-colours look. Home, sign in, My account, Admin (Staff & access, Roles,
   Bring data across), each section's settings pages and the console. Built from the approved mockups
   (design canvas, page "Home, account and admin").
   ========================================================================== */

/* ---- the other sections' colours (white on -600 and -ink on -50 are both over 4.5:1) ---- */
[data-section="register"], .hue-register {
  --sec-50: #f1f1f6; --sec-100: #e3e3ec; --sec-200: #c2c2d7; --sec-500: #52538e;
  --sec-600: #34357a; --sec-hover: #2c2d66; --sec-ink: #2e2f6b; --sec-900: #1a1a3d;
  --sec-on: #ffffff; --sec-icon: #34357a;
}
[data-section="concerns"], .hue-concerns {
  --sec-50: #fff4ed; --sec-100: #ffe4d0; --sec-200: #fec8a5; --sec-500: #f97316;
  --sec-600: #c2410c; --sec-hover: #9a3412; --sec-ink: #9a3412; --sec-900: #5a1e06;
  --sec-on: #ffffff; --sec-icon: #c2410c;
}
[data-section="test"], .hue-test {
  --sec-50: #eef6fc; --sec-100: #ddeefa; --sec-200: #b6daf3; --sec-500: #0b84d8;
  --sec-600: #0a77c2; --sec-hover: #0864a3; --sec-ink: #0863a3; --sec-900: #053b61;
  --sec-on: #ffffff; --sec-icon: #0a77c2;
}
[data-section="detention"], .hue-detention {
  --sec-50: #f7eff2; --sec-100: #efdfe4; --sec-200: #dcbcc5; --sec-500: #9c405c;
  --sec-600: #8b1e3f; --sec-hover: #751935; --sec-ink: #7a1a37; --sec-900: #460f20;
  --sec-on: #ffffff; --sec-icon: #8b1e3f;
}
[data-section="hifz"], .hue-hifz {
  --sec-50: #eff0f1; --sec-100: #dee1e4; --sec-200: #b9bec5; --sec-500: #39475a;
  --sec-600: #16273d; --sec-hover: #122133; --sec-ink: #132236; --sec-900: #0b141e;
  --sec-on: #ffffff; --sec-icon: #16273d;
}
[data-section="time"], .hue-time {
  --sec-50: #f0f2f2; --sec-100: #e0e5e4; --sec-200: #bdc8c6; --sec-500: #45625d;
  --sec-600: #244640; --sec-hover: #1e3b36; --sec-ink: #203e38; --sec-900: #122320;
  --sec-on: #ffffff; --sec-icon: #244640;
}
[data-section="meetings"], .hue-meetings {
  --sec-50: #eef5f4; --sec-100: #ddeae8; --sec-200: #b7d3ce; --sec-500: #338174;
  --sec-600: #0f6b5c; --sec-hover: #0d5a4d; --sec-ink: #0d5e51; --sec-900: #08362e;
  --sec-on: #ffffff; --sec-icon: #0f6b5c;
}
[data-section="updates"], .hue-updates {
  --sec-50: #f4f1f7; --sec-100: #eae3ef; --sec-200: #d2c4dc; --sec-500: #80579c;
  --sec-600: #69398a; --sec-hover: #583074; --sec-ink: #5c3279; --sec-900: #341c45;
  --sec-on: #ffffff; --sec-icon: #69398a;
}
[data-section="charts"], .hue-charts {
  --sec-50: #f1f6fb; --sec-100: #e4eef7; --sec-200: #c5daee; --sec-500: #3d85c6;
  --sec-600: #3778b2; --sec-hover: #2e6596; --sec-ink: #2e6495; --sec-900: #1b3c59;
  --sec-on: #ffffff; --sec-icon: #3778b2;
}
[data-section="register"], [data-section="concerns"], [data-section="test"], [data-section="detention"], [data-section="hifz"], [data-section="time"],
[data-section="meetings"], [data-section="updates"], [data-section="charts"],
.hue-register, .hue-concerns, .hue-test, .hue-detention, .hue-hifz, .hue-time, .hue-meetings, .hue-updates, .hue-charts { --accent: var(--sec-600); --accent-2: var(--sec-hover); --accent-soft: var(--sec-50); }

/* ---- the frame ---- */
.top .top-action { margin-left: auto; flex: none; display: flex; gap: 8px; }
.stack-v { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.stack-v > .card { margin: 0; }
.cu-cols > .card { margin: 0; }
.cu-cols { margin-bottom: 18px; }
.narrow-col { max-width: 640px; }
.plain-fs { border: 0; margin: 0; padding: 0; min-width: 0; }
.plain-fs > legend { padding: 0; margin-bottom: 8px; font-weight: 600; font-size: var(--fs-label); color: var(--n-700); }
.plain-fs > small { display: block; margin-top: 6px; }
.checkgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 2px 14px; }
.only-narrow { display: none; }
.off-tag { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: var(--r-full); background: var(--n-100); color: var(--n-700); font-size: var(--fs-caption); font-weight: 650; vertical-align: 1px; white-space: nowrap; }
.extra-tag { display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 8px; border-radius: var(--r-full); font-size: var(--fs-caption); font-weight: 650; background: var(--warning-50); color: var(--warning-900); border: 1px solid var(--warning-200); white-space: nowrap; vertical-align: 1px; }
.extra-tag .ic { width: 12px; height: 12px; }
.link-box { display: flex; gap: 8px; align-items: center; padding: 6px 6px 6px 14px; border-radius: var(--r-lg); border: 1px solid var(--line-strong); background: var(--n-25); font-family: var(--font-mono); font-size: var(--fs-label); color: var(--n-800); }
.link-box span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.link-box .btn { font-family: var(--font); }

/* ---- Home ---- */
.home-page { background: var(--n-50); min-height: 100vh; }
.home-top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 14px; padding: 12px 28px; padding-top: calc(12px + env(safe-area-inset-top, 0px)); background: #fff; border-bottom: 1px solid var(--line); }
.home-top .emb { width: 40px; height: 40px; border-radius: 12px; overflow: hidden; flex: none; box-shadow: inset 0 0 0 1px var(--line); background: #fff; }
.home-top .emb img { display: block; width: 40px; height: 40px; }
.home-top .org { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.home-top .org small { font-size: var(--fs-caption); color: var(--n-500); font-weight: 650; letter-spacing: .04em; text-transform: uppercase; }
.home-top .org b { font-size: var(--fs-body-lg); color: var(--n-900); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me-chip { margin-left: auto; display: inline-flex; align-items: center; gap: 10px; padding: 4px 14px 4px 4px; border-radius: var(--r-full); border: 1px solid var(--line); background: #fff; color: var(--n-800); font-weight: 650; min-height: 44px; flex: none; line-height: 1.25; }
.me-chip:hover { text-decoration: none; border-color: var(--line-strong); background: var(--n-25); color: var(--n-900); }
.me-chip .avatar { width: 34px; height: 34px; font-size: 12px; background: var(--indigo-100); color: var(--indigo-700); }
.me-chip .me-t { display: flex; flex-direction: column; }
.me-chip small { display: block; font-weight: 500; color: var(--n-500); font-size: var(--fs-caption); }
.home-wrap { max-width: 1180px; margin: 0 auto; padding: 28px 28px 48px; }
.hello-v { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.hello-v h1 { margin: 0; font-size: 1.875rem; letter-spacing: -.01em; }
.hello-v p { margin: 4px 0 0; color: var(--n-600); }
.today-chip { margin-left: auto; display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px 8px 10px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line); box-shadow: var(--e-1); color: var(--n-800); min-height: 52px; }
.today-chip:hover { text-decoration: none; border-color: var(--line-strong); color: var(--n-900); }
.today-chip .tic { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--success-50); color: var(--success-600); flex: none; }
.today-chip.is-closed .tic, .today-chip.is-holiday .tic { background: var(--warning-50); color: var(--warning-600); }
.today-chip.is-noclass .tic { background: var(--n-100); color: var(--n-500); }
.today-chip b { display: block; color: var(--n-900); }
.today-chip small { display: block; color: var(--n-600); font-size: var(--fs-caption); }
.notices { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 12px; margin-bottom: 26px; }
.notice { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: var(--r-xl); background: #fff; border: 1px solid var(--line); box-shadow: var(--e-1); color: var(--n-800); text-decoration: none; position: relative; overflow: hidden; min-height: 64px; }
.notice:hover { text-decoration: none; border-color: var(--line-strong); color: var(--n-900); }
.notice::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--c); }
.notice .nic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 12%, #fff); color: var(--c); flex: none; }
.notice > span:nth-child(2) { flex: 1; min-width: 0; }
.notice b { color: var(--n-900); }
.notice small { display: block; color: var(--n-600); font-size: var(--fs-label); }
.notice > .ic:last-child { color: var(--n-400); }
.app-group { margin-bottom: 26px; }
.app-group-h { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font-size: var(--fs-overline); text-transform: uppercase; letter-spacing: .08em; font-weight: 700; color: var(--n-600); }
.app-group-h::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.apps { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.app-card { display: flex; gap: 14px; align-items: flex-start; padding: 16px; border-radius: var(--r-xl); background: #fff; border: 1px solid var(--line); box-shadow: var(--e-1); color: var(--n-800); text-decoration: none; min-height: 96px; transition: border-color .15s, box-shadow .15s, transform .15s; }
.app-card:hover { text-decoration: none; color: var(--n-800); border-color: color-mix(in srgb, var(--c) 45%, #fff); box-shadow: var(--e-2); transform: translateY(-1px); }
.app-card .aic { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 12%, #fff); color: var(--c); flex: none; }
.app-card .at { flex: 1; min-width: 0; }
.app-card b { display: block; font-size: var(--fs-body-lg); color: var(--n-900); line-height: 1.3; }
.app-card small { display: block; color: var(--n-600); font-size: var(--fs-label); margin-top: 3px; line-height: 1.4; }
.app-card .abadge { flex: none; min-width: 24px; height: 24px; padding: 0 8px; border-radius: var(--r-full); background: var(--error-600); color: #fff; font-size: var(--fs-caption); font-weight: 700; display: inline-grid; place-items: center; }
.test-strip { display: flex; gap: 10px; align-items: center; padding: 12px 16px; border-radius: var(--r-lg); background: var(--warning-50); border: 1px solid var(--warning-200); color: var(--warning-900); font-size: var(--fs-label); margin-top: 8px; }
.test-strip .ic { color: var(--warning-600); }

/* ---- Sign in ---- */
.signin-page { background: var(--n-900); min-height: 100vh; }
.signin { min-height: 100vh; display: flex; flex-direction: column; align-items: center; color: #fff; padding: 0 16px; }
.signin-brand { width: 100%; max-width: 440px; padding: calc(56px + env(safe-area-inset-top, 0px)) 4px 30px; display: flex; flex-direction: column; gap: 12px; }
.signin-brand .emb { width: 64px; height: 64px; border-radius: 18px; overflow: hidden; background: #fff; box-shadow: 0 0 0 4px rgba(255, 255, 255, .12); }
.signin-brand .emb img { display: block; width: 64px; height: 64px; }
.signin-brand small { color: #f5c76b; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; font-size: var(--fs-caption); }
.signin-brand h1 { margin: 0; font-size: 1.75rem; color: #fff; line-height: 1.2; }
.signin-card { width: 100%; max-width: 440px; background: var(--n-50); color: var(--n-800); border-radius: 22px; padding: 28px 26px 26px; box-shadow: var(--e-4); margin-bottom: 40px; }
.signin-card h2 { margin: 0 0 4px; font-size: 1.375rem; }
.signin-card .si-lede { margin: 0 0 18px; }
.signin-card .flash { position: static; width: auto; box-shadow: none; animation: none; margin: 0 0 16px; }
.si-form { display: flex; flex-direction: column; gap: 14px; }
.si-form small { margin-top: -6px; }
.pin-in { font-size: 1.75rem !important; letter-spacing: .5em; text-align: center; font-family: var(--font-mono); min-height: 60px !important; -webkit-text-security: disc; padding-left: .5em !important; }
.si-alt { display: flex; align-items: center; gap: 8px; justify-content: center; min-height: 44px; margin-top: 12px; font-weight: 600; text-align: center; }
.si-alt .ic { color: var(--indigo-600); flex: none; }
.signin-card .test-strip { margin-top: 18px; }

/* ---- My account ---- */
.acc-head { display: flex; align-items: center; gap: 18px; padding: 22px 24px; flex-wrap: wrap; }
.acc-head .avatar { width: 64px; height: 64px; font-size: 1.25rem; box-shadow: 0 0 0 4px var(--sec-50); }
.acc-who { flex: 1 1 280px; min-width: 0; }
.acc-head h2 { margin: 0 0 4px; font-size: 1.5rem; }
.acc-note { margin: 0; max-width: 280px; }
.acc-dots { margin-top: 10px; }
.sec-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.sec-chip { display: inline-flex; align-items: center; gap: 7px; min-height: 32px; padding: 3px 12px 3px 6px; border-radius: var(--r-full); background: #fff; border: 1px solid var(--line); font-size: var(--fs-label); font-weight: 600; color: var(--n-800); }
.sec-chip .sic { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 14%, #fff); color: var(--c); flex: none; }
.switch-row { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line-soft); }
.card-head + .switch-row, input[type=hidden] + .switch-row { border-top: 0; }
.switch-row > span { flex: 1; min-width: 0; }
.switch-row b { display: block; color: var(--n-900); font-weight: 600; }
.switch-row small { display: block; color: var(--n-500); font-size: var(--fs-label); }
label.sw { position: relative; width: 46px; height: 28px; flex: none; display: block; margin: 0; }
.sw input { position: absolute; opacity: 0; inset: 0; margin: 0; width: 100%; height: 100%; cursor: pointer; z-index: 1; }
.sw i { position: absolute; inset: 0; border-radius: var(--r-full); background: var(--n-300); transition: background .15s; }
.sw i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .2); transition: transform .15s; }
.sw input:checked + i { background: var(--sec-600); }
.sw input:checked + i::after { transform: translateX(18px); }
.sw input:focus-visible + i { outline: 2px solid var(--focus); outline-offset: 2px; }
.sw input:disabled { cursor: not-allowed; }
.sw input:disabled + i { opacity: .6; }

/* ---- Admin ---- */
.admin-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; margin-bottom: 22px; }
.admin-tile { display: flex; gap: 14px; padding: 18px; border-radius: var(--r-xl); background: #fff; border: 1px solid var(--line); box-shadow: var(--e-1); color: var(--n-800); text-decoration: none; }
.admin-tile:hover { text-decoration: none; border-color: var(--sec-200); color: var(--n-800); box-shadow: var(--e-2); }
.admin-tile .aic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--sec-100); color: var(--sec-ink); flex: none; }
.admin-tile .at { flex: 1; min-width: 0; }
.admin-tile b { display: block; color: var(--n-900); font-size: var(--fs-body-lg); }
.admin-tile small { display: block; color: var(--n-600); font-size: var(--fs-label); margin-top: 2px; }
.admin-tile .n { flex: none; text-align: right; color: var(--n-500); font-size: var(--fs-caption); font-weight: 600; line-height: 1.2; }
.admin-tile .n b { font-size: 1.375rem; color: var(--n-900); }
.set-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px; }
.set-link { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: var(--r-lg); border: 1px solid var(--line-soft); background: var(--n-25); color: var(--n-800); text-decoration: none; min-height: 56px; }
.set-link:hover { text-decoration: none; border-color: var(--line-strong); background: #fff; color: var(--n-800); }
.set-link .sic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 13%, #fff); color: var(--c); flex: none; }
.set-link > span:nth-child(2) { flex: 1; min-width: 0; }
.set-link b { display: block; color: var(--n-900); font-weight: 650; }
.set-link small { display: block; color: var(--n-600); font-size: var(--fs-caption); }
.set-link > .ic:last-child { color: var(--n-400); }

/* staff list */
.staff-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.staff-tools .search { flex: 1 1 260px; }
.staff-tools select { width: auto; flex: 0 1 200px; }
.staff-table td { vertical-align: middle; }
.staff-table .nc-t { display: flex; flex-direction: column; min-width: 0; }
.staff-table .nc-t .off-tag { align-self: flex-start; margin-top: 2px; }
.staff-table .nc-mail { overflow-wrap: anywhere; }
.staff-table tr[hidden] { display: none; }
.staff-table .nc-t a.strong { display: inline-flex; align-items: center; min-height: 32px; align-self: flex-start; }
.role-tag { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: var(--r-full); font-size: var(--fs-caption); font-weight: 700; background: var(--sec-50); color: var(--sec-ink); border: 1px solid var(--sec-200); white-space: nowrap; }
.dots-row { display: flex; gap: 4px; flex-wrap: wrap; max-width: 250px; }
.dots-row span { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 14%, #fff); color: var(--c); }
.signin-how { display: inline-flex; align-items: center; gap: 6px; color: var(--n-700); font-size: var(--fs-label); white-space: nowrap; }
.signin-how .ic { color: var(--n-400); }
.signin-how.is-warn { color: var(--warning-900); font-weight: 650; }
.signin-how.is-warn .ic { color: var(--warning-600); }
details.extras { margin-top: 16px; border-top: 1px solid var(--line-soft); padding-top: 12px; }
details.extras > summary { cursor: pointer; display: flex; align-items: center; gap: 8px; min-height: 40px; font-weight: 650; color: var(--n-900); list-style: none; }
details.extras > summary::-webkit-details-marker { display: none; }
details.extras > summary .count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 7px; border-radius: var(--r-full); background: var(--warning-50); color: var(--warning-900); font-size: var(--fs-caption); font-weight: 700; border: 1px solid var(--warning-200); }
details.extras .perm-sec { box-shadow: none; }
.from-role { font-size: var(--fs-caption); color: var(--n-500); font-weight: 600; margin-left: 4px; }

/* roles */
.role-list { list-style: none; margin: 0; padding: 0; }
.role-list li + li { border-top: 1px solid var(--line-soft); }
.role-row { display: flex; align-items: center; gap: 14px; padding: 14px 20px; color: var(--n-800); text-decoration: none; }
.role-row:hover { background: var(--n-25); text-decoration: none; color: var(--n-800); }
.role-row .aic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--sec-100); color: var(--sec-ink); flex: none; }
.role-row .rt { flex: 1; min-width: 0; }
.role-row .rt b { display: block; color: var(--n-900); font-size: var(--fs-body-lg); }
.role-row .rt small { display: block; color: var(--n-600); font-size: var(--fs-label); }
.role-row .role-meta { display: block; color: var(--n-500); font-size: var(--fs-caption); font-weight: 600; margin-top: 2px; }
.role-row .rd { flex: 0 1 250px; }
.role-row > .ic:last-child { color: var(--n-400); }
.role-cols { display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: 18px; align-items: start; }
.role-side { position: sticky; top: 20px; }
.role-side .card { margin: 0; }
.role-locked { margin: 0 0 16px; }
.scope-cards { display: grid; gap: 8px; }
label.scope-card { display: flex; flex-direction: row; gap: 10px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: var(--r-lg); background: #fff; font-weight: 400; font-size: var(--fs-body); color: var(--n-800); cursor: pointer; }
.scope-card input { margin-top: 2px; }
.scope-card b { display: block; color: var(--n-900); font-weight: 650; }
.scope-card small { display: block; color: var(--n-500); font-size: var(--fs-label); }
.scope-card:has(input:checked) { border-color: var(--sec-600); box-shadow: inset 0 0 0 1px var(--sec-600); background: var(--sec-50); }
.scope-card:has(input:focus-visible) { outline: 2px solid var(--focus); outline-offset: 2px; }
.perm-sec { border: 1px solid var(--line); border-radius: var(--r-xl); background: #fff; box-shadow: var(--e-1); overflow: hidden; }
.perm-sec + .perm-sec { margin-top: 12px; }
.perm-sec-h { display: flex; align-items: center; gap: 12px; padding: 14px 16px; }
.perm-sec-h .sic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 13%, #fff); color: var(--c); flex: none; }
.perm-sec-h > span:nth-child(2) { flex: 1; min-width: 0; }
.perm-sec-h b { display: block; color: var(--n-900); }
.perm-sec-h small { display: block; color: var(--n-500); font-size: var(--fs-label); }
.perm-sec .sw input:checked + i { background: var(--c); }
.perm-sec.off { background: var(--n-25); box-shadow: none; }
.perm-sec.off .perm-sec-h b { color: var(--n-700); }
.perm-sec.off .perm-list { display: none; }
.perm-list { list-style: none; margin: 0; padding: 12px 16px 14px 64px; display: grid; gap: 4px; border-top: 1px solid var(--line-soft); }
.perm-list label.check { align-items: flex-start; font-size: var(--fs-body); }
.perm-list label.check input { margin-top: 3px; accent-color: var(--c); }
.perm-list select { max-width: 460px; }
.perm-list li > small { display: block; margin-top: 6px; }

/* ---- a section's settings (the Concerns settings pattern) ---- */
.type-rows { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; counter-reset: t; }
.type-rows li { display: flex; align-items: center; gap: 10px; counter-increment: t; }
.type-rows li::before { content: counter(t); width: 28px; height: 28px; border-radius: 50%; background: var(--sec-50); color: var(--sec-ink); font-weight: 700; font-size: var(--fs-caption); display: grid; place-items: center; flex: none; }
.type-rows li.new::before { content: "+"; background: var(--n-100); color: var(--n-500); }
.type-rows input { flex: 1; }
.tag-list { margin: 6px 0 12px; padding: 0; list-style: none; display: grid; gap: 4px; font-size: var(--fs-label); color: var(--n-600); }
.tag-list code { margin-right: 6px; }
.rec-list { list-style: none; margin: 0; padding: 0; }
.rec-list > li { display: flex; gap: 14px; align-items: center; padding: 14px 20px; border-top: 1px solid var(--line-soft); }
.rec-list > li:first-child { border-top: 0; }
.rec-list .rec-t { flex: 1; min-width: 0; }
.rec-list .rec-t b { color: var(--n-900); }
.rec-list .rec-t small { display: block; color: var(--n-600); font-size: var(--fs-label); margin-top: 2px; overflow-wrap: anywhere; }
.rec-list form { margin: 0; flex: none; }
.st-chip { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: var(--r-full); font-size: var(--fs-caption); font-weight: 650; background: var(--n-100); color: var(--n-700); margin-left: 6px; vertical-align: 1px; white-space: nowrap; }
.st-chip.open { background: var(--warning-50); color: var(--warning-900); border: 1px solid var(--warning-200); }
.act-list .rec-t b { font-weight: 600; }
.count-pill { display: inline-flex; align-items: center; height: 32px; padding: 0 12px; border-radius: var(--r-full); background: var(--sec-50); color: var(--sec-ink); border: 1px solid var(--sec-200); font-weight: 650; font-size: var(--fs-label); }
.rec-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.rec-tools .search { flex: 1 1 240px; }
.rec-tools select { width: auto; flex: 0 1 200px; }

.card .rec-list.compact { margin: 0 0 12px; }
.card .rec-list.compact > li { padding: 10px 0; }
.card.danger .card-ic { background: var(--error-50); color: var(--error-700); }
.cu-note a { color: inherit; font-weight: 650; text-decoration: underline; }

/* Bring data across: numbered steps */
.imp-step { display: flex; gap: 16px; align-items: flex-start; }
.imp-step .imp-n { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--c) 14%, #fff); color: var(--c); font-weight: 750; flex: none; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--c) 30%, #fff); }
.imp-step .imp-b { flex: 1; min-width: 0; }
.imp-step .imp-b h3 { margin: 6px 0 8px; }
.imp-step .imp-b > :last-child { margin-bottom: 0; }

/* ---- the app's older page pieces, in this look (pages not redrawn one by one) ---- */
.hubv2 .lede { margin: 0 0 18px; color: var(--n-600); font-size: var(--fs-body-lg); max-width: 72ch; }
.hubv2 .hint { color: var(--n-600); font-size: var(--fs-label); margin: 8px 0; }
.hubv2 ol.hint, .hubv2 ul.hint { padding-left: 22px; }
.hubv2 ol.hint li, .hubv2 ul.hint li { margin: 4px 0; }
.hubv2 .none { color: var(--n-500); }
.hubv2 label.f { display: block; margin: 16px 0 6px; }
.hubv2 .card > label.f:first-child, .hubv2 form > label.f:first-child, .hubv2 .card-head + label.f, .hubv2 input[type=hidden] + label.f { margin-top: 0; }
.hubv2 .card > h2, .hubv2 form.card > h2, .hubv2 .card > form > h2 { font-size: var(--fs-title); font-weight: 650; margin: 0 0 8px; }
.hubv2 .content > h2 { font-size: var(--fs-overline); text-transform: uppercase; letter-spacing: .08em; color: var(--n-600); margin: 26px 0 10px; }
.hubv2 .btn.primary { background: var(--sec-600); border-color: var(--sec-600); color: var(--sec-on); }
.hubv2 .btn.primary:hover { background: var(--sec-hover); border-color: var(--sec-hover); color: var(--sec-on); }
.hubv2 .btn.primary .ic { color: currentColor; }
.hubv2 .btn.small { min-height: 32px; padding: 0 var(--sp-3); font-size: var(--fs-label); border-radius: var(--r-sm); }
.hubv2 .acts, .hubv2 .suacts { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 16px; }
.hubv2 .toolbar-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin: 0 0 12px; }
.hubv2 .toolbar-row .in { flex: 1 1 200px; width: auto; }
.hubv2 .toolbar-row select.in { flex: 0 1 200px; }
.hubv2 .twocol { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.hubv2 .item { display: block; padding: 12px 16px; border: 1px solid var(--line); border-radius: var(--r-lg); background: #fff; margin-bottom: 8px; color: var(--n-800); }
.hubv2 .item b { display: block; color: var(--n-900); }
.hubv2 .item small { display: block; color: var(--n-600); font-size: var(--fs-label); }
.hubv2 .pills { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.hubv2 .pill { display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 9px; border-radius: var(--r-full); font-size: var(--fs-caption); font-weight: 650; background: var(--sec-50); color: var(--sec-ink); border: 1px solid var(--sec-200); vertical-align: 1px; white-space: nowrap; }
.hubv2 .pill.c { background: color-mix(in srgb, var(--c) 12%, #fff); color: color-mix(in srgb, var(--c) 80%, #000); border-color: color-mix(in srgb, var(--c) 25%, #fff); }
.hubv2 .pill.warn { background: var(--warning-50); color: var(--warning-900); border-color: var(--warning-200); }
.hubv2 .pill.off { background: var(--n-100); color: var(--n-700); border-color: var(--n-200); }
.hubv2 .tag { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: var(--r-full); background: var(--n-100); color: var(--n-700); font-size: var(--fs-caption); font-weight: 650; }
.hubv2 .scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.hubv2 table.grid, .hubv2 table.kv { width: 100%; border-collapse: separate; border-spacing: 0; font-size: var(--fs-label); }
.hubv2 table.grid { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: #fff; }
.hubv2 table.grid th, .hubv2 table.grid td, .hubv2 table.kv th, .hubv2 table.kv td { padding: 10px 12px; border-bottom: 1px solid var(--line-soft); text-align: left; vertical-align: top; }
.hubv2 table.grid thead th, .hubv2 table.kv thead th { font-size: var(--fs-caption); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--n-600); background: var(--n-25); }
.hubv2 table.grid tbody tr:last-child td, .hubv2 table.kv tbody tr:last-child td, .hubv2 table.kv tbody tr:last-child th { border-bottom: 0; }
.hubv2 table.kv td:first-child, .hubv2 table.kv th:first-child { padding-left: 0; }
.hubv2 table.kv tbody th { font-weight: 650; color: var(--n-900); }
.hubv2 details.card > summary { cursor: pointer; font-weight: 650; color: var(--n-900); min-height: 32px; display: flex; align-items: center; }
.hubv2 details.card[open] > summary { margin-bottom: 12px; }
.hubv2 .card.danger { border-color: var(--error-200); }
.hubv2 .card.danger h2 { color: var(--error-700); }
.hubv2 .content .flash.err, .hubv2 .content .flash.ok { position: static; width: auto; box-shadow: none; animation: none; margin: 0 0 14px; font-weight: 500; font-size: var(--fs-label); }
.hubv2 .content .flash.err { background: var(--error-50); color: var(--error-900); border-color: var(--error-200); }
.hubv2 .content .flash.err::before { background: var(--error-600); -webkit-mask-image: var(--i-alert); mask-image: var(--i-alert); }
.hubv2 .content .flash.ok { background: var(--sec-50); color: var(--sec-900); border-color: var(--sec-200); }
.hubv2 .content .flash.ok::before { background: var(--sec-600); }
.hubv2 .bad { color: var(--error-700); font-weight: 650; }
.hubv2 .ok { color: var(--success-600); font-weight: 650; }
.hubv2 .filelist { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.hubv2 .filelist li { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; }
.hubv2 .sucard h2 { font-size: var(--fs-title); margin: 0 0 10px; }
.hubv2 .sucard h2 .muted { font-weight: 500; font-size: var(--fs-body); }
.hubv2 .sufam { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; overflow-wrap: anywhere; }
.hubv2 .sufam b { color: var(--n-900); font-size: var(--fs-body-lg); }
.hubv2 .sufam .hint { margin: 2px 0 0; }
.hubv2 .sukids { list-style: none; margin: 10px 0 0; padding: 0; }
.hubv2 .sukids li { overflow-wrap: anywhere; min-height: 44px; border-top: 1px solid var(--line-soft); display: flex; flex-wrap: wrap; gap: 0 8px; align-items: center; }
.hubv2 .sumove { margin-left: auto; font-weight: 650; display: inline-flex; align-items: center; min-height: 44px; padding: 0 4px 0 16px; }
.hubv2 .sufind { display: flex; gap: 8px; margin: 0 0 14px; }
.hubv2 .sufind .in { flex: 1; min-width: 0; }
.hubv2 .suclear { color: var(--error-700); border-color: var(--error-200); }
.hubv2 .suclear:hover { background: var(--error-50); color: var(--error-700); }
.hubv2 .sutable td .hint { margin: 2px 0 0; font-size: var(--fs-caption); }
.hubv2 .vpost, .hubv2 .vlist { overflow-wrap: anywhere; }
.fam-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 14px; align-items: start; }
.fam-grid > .card { margin: 0; }
.hubv2 .card .twocol + .btn, .hubv2 .card .twocol + p, .hubv2 .card .twocol + .acts { margin-top: 16px; }

@media (max-width: 1100px) {
  .role-cols { grid-template-columns: minmax(0, 1fr); }
  .role-side { position: static; }
  .only-narrow { display: flex; }
  .role-row .rd { display: none; }
}
@media (max-width: 900px) {
  .top .top-action .btn { min-height: 40px; padding: 0 12px; }
  .top .top-action .ta-l { display: none; }
  .top .top-action + .hub-top-apps { margin-left: 0; }
  .staff-table .st-classes { display: none; }
}
@media (max-width: 760px) {
  .hubv2 .twocol { grid-template-columns: minmax(0, 1fr); }
  .fam-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .home-top { padding: 10px 14px; padding-top: calc(10px + env(safe-area-inset-top, 0px)); gap: 10px; }
  .me-chip { padding: 4px; }
  .me-chip .me-t { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .home-wrap { padding: 16px 14px 32px; }
  .hello-v h1 { font-size: 1.5rem; }
  .today-chip { margin-left: 0; width: 100%; }
  .apps { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .app-card { min-height: 0; padding: 14px; }
  .notices { grid-template-columns: minmax(0, 1fr); }
  .signin { padding: 0; }
  .signin-brand { padding: calc(40px + env(safe-area-inset-top, 0px)) 24px 30px; }
  .signin-card { flex: 1; max-width: none; border-radius: 26px 26px 0 0; margin: 0; padding: 26px 20px 30px; box-shadow: none; }
  .top:has(.top-action) .top-ic { display: none; }
  .acc-head { padding: 18px; gap: 14px; }
  .acc-head .avatar { width: 52px; height: 52px; font-size: 1.0625rem; }
  .acc-note { max-width: none; }
  .admin-tile { padding: 14px; }
  .staff-tools select { flex: 1 1 140px; }
  /* staff list: one card per person */
  .staff-table thead { display: none; }
  .staff-table, .staff-table tbody, .staff-table tr { display: block; width: 100%; }
  .staff-table tr { padding: 14px 16px; border-top: 1px solid var(--line-soft); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 10px; align-items: center; }
  .staff-table tr:first-child { border-top: 0; }
  .staff-table td { display: block; padding: 0; border: 0; }
  .staff-table tbody tr:hover td { background: none; }
  .staff-table td:first-child { grid-column: 1 / -1; }
  .staff-table .st-secs { grid-column: 1 / -1; }
  .staff-table .st-how { text-align: right; }
  .staff-table tr { position: relative; }
  .staff-table .nc-t a.strong::after { content: ""; position: absolute; inset: 0; }   /* the whole card opens the person */
  .role-row { padding: 14px 16px; }
  .perm-list { padding-left: 16px; }
  .perm-sec-h { padding: 12px 14px; }
  .rec-list > li { padding: 14px 16px; flex-wrap: wrap; }
  .hubv2 .sufind { flex-wrap: wrap; }
  .hubv2 table.grid.stack, .hubv2 table.grid.stack tbody, .hubv2 table.grid.stack tr, .hubv2 table.grid.stack td { display: block; width: 100%; }
  .hubv2 table.grid.stack thead { display: none; }
  .hubv2 table.grid.stack { border: 0; background: none; border-radius: 0; }
  .hubv2 table.grid.stack tr { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); margin-bottom: 10px; padding: 8px 12px; }
  .hubv2 table.grid.stack td { border: 0; padding: 4px 0; display: flex; gap: 10px; align-items: baseline; }
  .hubv2 table.grid.stack td[data-label]::before { content: attr(data-label); flex: 0 0 36%; font-size: var(--fs-caption); font-weight: 700; letter-spacing: .03em; text-transform: uppercase; color: var(--n-600); }
  .hubv2 .scroll.has-stack { overflow: visible; }
  .hubv2 .toolbar-row .btn { flex: 1 1 auto; justify-content: center; }
}
@media (pointer: coarse) {
  .set-link, .role-row, .notice { min-height: 56px; }
}

/* 0.26.0: the home page's "open today" chip shows the day's colour on the year calendar */
.today-sw { width: 10px; align-self: stretch; min-height: 30px; border-radius: 5px; border: 1px solid rgba(0, 0, 0, .1); flex: none; margin-left: 4px; }

/* 0.30.0: one sign-in for every department: the switch between them on the home page (board S4), and a parent's children */
.home-switch { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-left: 18px; min-width: 0; }
.fd-dept { display: inline-flex; gap: 2px; padding: 3px; border-radius: var(--r-lg); background: var(--n-100); flex-wrap: wrap; }
.fd-dept a { padding: 6px 12px; border-radius: 9px; font-size: var(--fs-label); font-weight: 600; color: var(--n-600); white-space: nowrap; min-height: 32px; display: inline-flex; align-items: center; }
.fd-dept a.on { background: #fff; color: var(--n-900); box-shadow: 0 1px 2px rgba(21,25,34,.08), 0 1px 3px rgba(21,25,34,.06); }
.fd-dept a:hover { text-decoration: none; color: var(--n-900); }
.fd-kids-link { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-label); font-weight: 600; min-height: 44px; }
@media (max-width: 720px) { .home-switch { order: 3; width: 100%; margin: 8px 0 0; } }

/* 1.0.3 (the owner, 30 Oct 2026): Staff & access, a change for several at once: a tick on each row and the bar above */
.staff-table .st-pick { width: 44px; text-align: center; }
.staff-table .st-pick input { width: 20px; height: 20px; margin: 0; vertical-align: middle; cursor: pointer; }
.staff-table .st-pick input:disabled { cursor: not-allowed; opacity: .4; }
.bulk-bar { display: grid; gap: 12px; padding: 16px 20px; margin-bottom: 16px; }
.bulk-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; }
.bulk-head b { display: inline-flex; align-items: center; gap: 8px; }
.bulk-fields { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 14px; }
.bulk-fields label { display: grid; gap: 4px; font-size: var(--fs-label); font-weight: 600; margin: 0; flex: 1 1 200px; min-width: 0; }
.bulk-fields label[hidden] { display: none; }
.bulk-fields select { width: 100%; }
.bulk-fields .btn { flex: none; }
.bulk-list { list-style: none; margin: 0; padding: 0; }
.bulk-list li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line-soft); }
.bulk-list li:last-child { border-bottom: 0; }
.bulk-list .grow { flex: 1; min-width: 0; }
.bulk-list small { display: block; color: var(--n-600); font-size: var(--fs-caption); overflow-wrap: anywhere; }
@media (max-width: 640px) {
  .bulk-bar { padding: 14px 16px; }
  .bulk-fields .btn { width: 100%; }
  .staff-table td.st-pick { position: absolute; top: 12px; right: 12px; z-index: 2; width: auto; grid-column: auto; }
  .staff-table td.st-pick input { width: 26px; height: 26px; }
  .staff-table td:nth-child(2) { grid-column: 1 / -1; padding-right: 44px; }
  .bulk-list li { flex-wrap: wrap; }
}
