/* Only what is unique to the web hub. */
.hub-main { min-width: 0; display: flex; flex-direction: column; }
.hub-search { width: min(440px, 40vw); }
.topbar .userchip { margin-left: 4px; }
.sidebar .me span { line-height: 1.3; color: var(--muted); }
@media (max-width: 980px) { .hub-search { width: auto; flex: 1; } .topbar .tag { display: none; } }

/* Charts */
.chart { width: 100%; height: auto; overflow: visible; font-family: var(--font-body); }
.ch-grid { stroke: var(--line); stroke-width: 1; }
/* No grow-in: a staggered scaleY(0) entrance left bars invisible wherever the animation timeline stalls (hidden tab, capture, print). */
.ch-bar { fill: var(--c-3); }
.ch-bar.hi { fill: var(--primary-strong); }
.ch-bar.pend { fill: none; stroke: var(--line-strong); stroke-width: 2; stroke-dasharray: 2 5; stroke-linecap: round; }
.ch-val { font-size: 14px; font-weight: 600; fill: var(--ink-2); text-anchor: middle; }
.ch-lab { font-size: 14px; fill: var(--muted); text-anchor: middle; }
.ch-axis { font-size: 13px; fill: var(--muted); text-anchor: end; }
.ch-line { fill: none; stroke: var(--primary); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.ch-dot { fill: var(--bg); stroke: var(--primary); stroke-width: 2; }
.ch-dot.hi { fill: var(--accent-strong); stroke: var(--accent-strong); }
.ch-target { stroke: var(--danger); stroke-width: 1.5; stroke-dasharray: 5 5; }
.ch-tlab { font-size: 13px; fill: var(--danger-ink); text-anchor: end; font-weight: 600; }
.hbars { display: grid; gap: 10px; }
.hb { display: grid; grid-template-columns: minmax(120px, 1.2fr) 2fr 52px; gap: 12px; align-items: center; font-size: var(--t-14); }
.hb .l { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hb .t { height: 10px; border-radius: 5px; background: var(--surface-2); overflow: hidden; }
.hb .t i { display: block; height: 100%; background: var(--c-3); border-radius: 5px; }
.hb.low .t i { background: var(--warning); }
.hb .v { text-align: right; font-weight: 520; }

/* Home */
.hgrid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: var(--s-5); align-items: start; }
.kpis4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s-4); }
@media (max-width: 1100px) { .hgrid { grid-template-columns: 1fr; } .kpis4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* Greeting figures: one line, each figure a link to its panel. */
.page-head .sumline { flex-basis: 100%; margin-top: 0; font-size: var(--t-16); color: var(--ink-2); font-variant-numeric: tabular-nums lining-nums; }
.sumline > span { white-space: nowrap; }
.sumline a { font: 600 var(--t-22)/1.3 var(--font-display); font-variant-numeric: tabular-nums lining-nums; color: var(--ink); text-decoration: underline 2px var(--line-strong); text-underline-offset: 5px; }
.sumline a:hover { color: var(--primary-strong); text-decoration-color: currentColor; }
.sumline i { font-style: normal; color: var(--muted-2); margin: 0 .6em; }
.card h2[id] { scroll-margin-top: 88px; }
/* Today's registers: one small closed kolam per section, from the same code as its tablet. */
.regs { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: var(--s-4) 8px; }
.reg { display: grid; justify-items: center; gap: 2px; padding: 8px 4px; border-radius: var(--r-ctl); font-size: var(--t-12); color: var(--muted); text-decoration: none; }
.reg:hover { background: var(--surface); }
.reg .dotgrid { width: 60px; margin-bottom: 6px; }
.reg .dotgrid .kl { stroke-width: 5; }
.reg .dotgrid.offline .kl { stroke-dasharray: 1 11 !important; }
.reg .dotgrid .dot { stroke-width: 4; transform: scale(.45); transform-box: fill-box; transform-origin: center; }
.reg .dotgrid .dot.abs { stroke-dasharray: 4 5; }
.reg .dotgrid text { display: none; }
.reg b { font: 600 var(--t-15)/1.1 var(--font-display); color: var(--ink); }
.reg.live { box-shadow: inset 0 0 0 1.5px var(--primary); }
.legend { display: flex; flex-wrap: wrap; gap: var(--s-4); font-size: var(--t-13); color: var(--muted); margin-top: var(--s-4); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 18px; height: 0; border-top: 2.5px solid var(--primary); }
.legend i.wait { border-top: 3px dotted var(--offline); }
.legend i.live { width: 12px; height: 12px; border: 0; border-radius: 4px; box-shadow: inset 0 0 0 1.5px var(--primary); }
.days20 { display: grid; grid-template-columns: repeat(20, 1fr); gap: 4px; align-items: end; height: 70px; }
.days20 i { border-radius: 4px 4px 0 0; background: var(--c-3); }
.days20 i.today { background: var(--accent-strong); }

/* Setup */
.ttable { width: 100%; font-size: var(--t-14); border-collapse: separate; border-spacing: 4px; }
.ttable th { font-size: var(--t-12); color: var(--muted); font-weight: 520; text-align: left; padding: 4px 6px; }
.ttable td { padding: 0; }
.ttable button { width: 100%; min-height: 48px; padding: 6px 8px; border-radius: var(--r-ctl); background: var(--surface); text-align: left; font-size: var(--t-13); line-height: 1.25; }
.ttable button:hover { background: var(--primary-soft); }
.ttable button small { display: block; color: var(--muted); font-size: 11px; }
.ttable td.brk { text-align: center; font-size: 11px; color: var(--muted); writing-mode: vertical-rl; }
.classlist { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: var(--s-2); }
.classlist div { padding: var(--s-3); border-radius: var(--r-ctl); background: var(--surface); }
.classlist b { display: block; font: 600 var(--t-16)/1.2 var(--font-display); }
.classlist small { color: var(--muted); font-size: var(--t-12); }

/* Import */
.imp tr.bad td { background: var(--danger-soft); }
.imp td .err { color: var(--danger-ink); font-size: var(--t-12); display: flex; gap: 4px; align-items: center; }
.imp td input { width: 100%; min-height: 34px; border: 0; border-radius: 6px; padding: 0 8px; box-shadow: inset 0 0 0 1.5px var(--danger); background: var(--bg); }

/* Student profile */
.sprof { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: var(--s-5); align-items: start; }
@media (max-width: 1100px) { .sprof { grid-template-columns: 1fr; } }

/* Exam builder */
.qcard { display: grid; gap: var(--s-3); padding: var(--s-4); border-radius: var(--r-card); background: var(--bg); box-shadow: var(--elev-card); }
.qcard .opts2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-2); }
.qcard .o { display: grid; grid-template-columns: 36px 1fr; gap: 8px; align-items: center; }
.qcard .o button { width: 36px; height: 36px; border-radius: 50%; box-shadow: inset 0 0 0 2px var(--line-strong); font: 600 14px/1 var(--font-display); color: var(--ink-2); }
.qcard .o button[aria-pressed="true"] { background: var(--success); color: var(--on-primary); box-shadow: none; }
.qcard .head { display: flex; justify-content: space-between; align-items: center; gap: var(--s-3); }
@media (max-width: 760px) { .qcard .opts2 { grid-template-columns: 1fr; } }
.flagrow { display: flex; flex-wrap: wrap; gap: 6px; }
