﻿/* Rubiko app — screen-level styles on top of styles.css + components.css */

body { background: var(--ink); }
#view { min-height: 60vh; }
.well { padding-bottom: 40px; }
.page-head { align-items: flex-end; }
.head-acts { display: flex; gap: 8px; flex-wrap: wrap; margin-inline-start: auto; align-items: center; }
.crumb-back { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; color: var(--muted); margin-top: 14px; padding: 4px 10px 4px 12px; border-radius: 999px; }
.crumb-back:hover { background: var(--card); color: var(--text); }
.crumb-back + .page-head { margin-top: 6px; }
.sheet-title { font-size: 18px; font-weight: 800; margin-bottom: 12px; }
.sheet .acts-row { display: flex; gap: 8px; margin-top: 16px; } .sheet .acts-row .btn { flex: 1; }
.notif-pop { width: min(360px, calc(100vw - 24px)); max-height: 70vh; overflow-y: auto; padding: 8px; }
.notif-pop .nt { color: inherit; }
.only-m { display: none; }
.gsearch .search { width: min(340px, 34vw); }
.demo-flag { position: fixed; z-index: 45; bottom: 12px; left: 12px; background: var(--lime); color: var(--ink); font-size: 11px; font-weight: 800; padding: 4px 12px; border-radius: 999px; box-shadow: var(--sh-float); pointer-events: none; }
.side-promo p { max-width: none; }

/* ---------- grids ---------- */
.g { display: grid; gap: 12px; }
/* vertical rhythm only in normal block flow; grid/stack children are spaced by gap (fixes cards not lining up) */
#view > :is(.g, .card, .tabs-line, .dash, .today, .hero-s) + :is(.g, .card, .tabs-line) { margin-top: 12px; }
:is(.g, .stack, .dash, .today, .radio-cards, .slots) > :is(.card, .g, .kpi, .hero-s, article) { margin-top: 0; }
.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-21 { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); }
.g-12 { grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); }
.g-auto { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.span-2 { grid-column: span 2; }
.card .tabs-line { margin: -4px 0 12px; }
.card > .table-wrap { margin: 0 -6px; }
.kpi .big b { font-size: 30px; }
.kpi-foot { font-size: 12px; color: var(--muted); }
.card.dark .kpi-foot, .card.dark .kpi .t { color: var(--on-dark-muted); }
.kpi[data-go] { cursor: pointer; transition: transform .35s var(--spring-soft); }
.kpi[data-go]:hover { transform: translateY(-2px); }
.section-t { font-size: 15px; font-weight: 800; margin: 22px 2px 10px; display: flex; align-items: center; gap: 8px; }
.filters { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.filters .search { background: var(--card); flex: 1; min-width: 200px; height: 42px; }
.card .filters .search { background: var(--track); }
.chips-row { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.mini-stat { display: flex; gap: 18px; flex-wrap: wrap; }
.mini-stat div { font-size: 12px; color: var(--muted); }
.mini-stat b { display: block; font-size: 20px; color: var(--text); font-weight: 800; }
.card.dark .mini-stat b { color: #fff; } .card.dark .mini-stat div { color: var(--on-dark-muted); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; font-size: 13px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; font-weight: 600; }
.lst { display: grid; }
.lst > * + * { border-top: 1px solid var(--line); }
.li { display: flex; align-items: center; gap: 12px; padding: 11px 0; min-width: 0; }
.li[data-go], a.li { cursor: pointer; }
.li .grow { flex: 1; min-width: 0; }
.li .t { font-weight: 700; font-size: 13.5px; line-height: 1.6; }
.li .s { font-size: 12px; color: var(--muted); line-height: 1.6; }
.li .end { margin-inline-start: auto; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.li time.tm { font-weight: 800; font-size: 14px; text-align: center; line-height: 1.3; min-width: 54px; }
.li time.tm small { display: block; font-size: 11px; color: var(--muted); font-weight: 500; }
.form-g { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.form-g .full { grid-column: 1 / -1; }
.hint { font-size: 11.5px; color: var(--muted); }
select.input { appearance: none; background-image: none; cursor: pointer; }

/* ---------- responsive table (cards on phone) ---------- */
.table.rt td .who-cell { min-width: 150px; }
.table.rt tbody tr[data-go]:hover { background: #f6f6f7; }

/* ---------- week & agenda ---------- */
.week .ev.cls3 { background: var(--lime); color: var(--ink); }
.week .ev.cls2 b { color: var(--ink); }
.week .dh.hol { color: var(--danger); }
.week .cell.hol { background: repeating-linear-gradient(135deg, transparent 0 6px, rgb(196 67 58 / .05) 6px 12px); }
.week .cell[data-act] { cursor: copy; }
.week .cell[data-act]:hover { background: var(--lime-soft); }
.week .ev { font-size: 10.5px; }
.week .ev b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nowcol { position: relative; pointer-events: none; z-index: 3; }
.nowcol i { position: absolute; left: 0; right: 0; height: 2px; background: var(--danger); }
.nowcol i::before { content: ""; position: absolute; right: -4px; top: -3px; width: 8px; height: 8px; border-radius: 50%; background: var(--danger); }
.agenda { display: none; }
.ag-day { margin-bottom: 14px; }
.ag-h { display: flex; gap: 8px; align-items: center; font-size: 13px; margin-bottom: 6px; flex-wrap: wrap; }
.ag-h span { font-size: 11.5px; color: var(--muted); }
.ag-day.today .ag-h b { background: var(--lime); padding: 0 10px; border-radius: 999px; }
.ag-ev { display: flex; gap: 12px; align-items: center; background: var(--card); border-radius: 16px; padding: 10px 12px; margin-bottom: 6px; box-shadow: inset 4px 0 0 var(--lavender); cursor: pointer; }
.ag-ev.cls { box-shadow: inset 4px 0 0 var(--ink); } .ag-ev.cls3 { box-shadow: inset 4px 0 0 var(--lime-2); }
.ag-ev.mtg { box-shadow: inset 4px 0 0 var(--ink), inset 0 0 0 1px var(--line-2); } .ag-ev.cancel { opacity: .6; text-decoration: line-through; box-shadow: inset 4px 0 0 var(--danger); }
.ag-ev.free { background: var(--lime-soft); box-shadow: inset 4px 0 0 var(--lime-2); } .ag-ev.busy { background: var(--track); box-shadow: none; }
.ag-ev time { font-weight: 800; font-size: 13px; text-align: center; min-width: 46px; line-height: 1.3; }
.ag-ev time small { display: block; font-size: 10.5px; color: var(--muted); font-weight: 500; }
.ag-ev b { display: block; font-size: 13px; } .ag-ev span { font-size: 11.5px; color: var(--muted); }
.week-nav { display: flex; align-items: center; gap: 8px; }
.week-nav b { font-size: 14px; min-width: 150px; text-align: center; }

/* ---------- session hero ---------- */
.hero-s { background: var(--ink); color: #fff; border-radius: var(--r-card); padding: 20px; display: grid; gap: 10px; position: relative; overflow: hidden; }
.hero-s .k { font-size: 12px; color: var(--on-dark-muted); }
.hero-s h2 { font-size: 22px; font-weight: 800; line-height: 1.5; }
.hero-s .meta { display: flex; gap: 8px; flex-wrap: wrap; }
.hero-s .meta .status { background: var(--ink-3); color: #fff; }
.hero-s .bub { position: absolute; inset-inline-end: -34px; bottom: -44px; width: 140px; height: 120px; opacity: .55; pointer-events: none; }
.hero-s > *:not(.bub) { position: relative; z-index: 1; }
.g-2x { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
.hero-s .bub i { position: absolute; border-radius: 50%; }
.hero-s .bub i:nth-child(1) { width: 90px; height: 90px; background: var(--lavender); top: 0; left: 0; }
.hero-s .bub i:nth-child(2) { width: 60px; height: 60px; background: var(--lime); top: 54px; left: 50px; }

/* attendance matrix */
.mx-wrap { overflow-x: auto; }
.mx { border-collapse: separate; border-spacing: 3px; font-size: 12px; }
.mx th { font-weight: 600; color: var(--muted); font-size: 11px; padding: 2px 4px; white-space: nowrap; }
.mx td.n { white-space: nowrap; font-weight: 600; padding-inline-end: 10px; position: sticky; right: 0; background: var(--card); }
.mx td.c { width: 24px; height: 24px; border-radius: 8px; text-align: center; font-size: 10.5px; font-weight: 800; }
.mx td.p { background: var(--lime-soft); color: #556400; } .mx td.a { background: var(--danger-bg); color: var(--danger); }
.mx td.l { background: var(--warn-bg); color: var(--warn); } .mx td.e { background: var(--lav-faint); color: var(--info); }
.mx td.f { background: var(--track); } .mx td.x { background: repeating-linear-gradient(135deg, var(--danger-bg) 0 3px, #fff 3px 6px); }

/* more sheet */
.more-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 8px; }
.more-it { display: grid; justify-items: center; gap: 6px; text-align: center; font-size: 11.5px; font-weight: 600; padding: 10px 4px; border-radius: 16px; background: var(--track); }
.more-it .icon-dot { background: var(--card); }

/* ---------- login ---------- */
#login { display: none; }
body.is-login { background: var(--backdrop); }
body.is-login .app, body.is-login .tabbar { display: none !important; }
body.is-login #login { display: block; }
.login { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.login-art { background: var(--ink); color: #fff; padding: 40px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.login-art h1 { font-size: clamp(30px, 4vw, 52px); font-weight: 900; line-height: 1.3; }
.login-art h1 em { font-style: normal; color: var(--lime); }
.login-art .bubbles { max-width: 340px; margin: 0; }
.login-art .bubbles .b2 { background: #fff; color: var(--ink); }
.login-art .bubbles .b3 { box-shadow: 0 0 0 6px var(--ink); }
.login-form { display: grid; place-items: center; padding: 30px 20px; }
.login-box { width: min(400px, 100%); background: var(--card); border-radius: 30px; padding: 28px; display: grid; gap: 14px; box-shadow: var(--sh-float); }
.login-box h2 { font-size: 24px; font-weight: 900; }
.demo-accounts { display: grid; gap: 8px; }
.demo-acc { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 18px; background: var(--track); text-align: start; }
.demo-acc:hover { background: var(--lime-soft); }
.demo-acc b { display: block; font-size: 13.5px; } .demo-acc span { font-size: 11.5px; color: var(--muted); }

/* misc */
.pill-tag { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; padding: 1px 8px; border-radius: 999px; background: var(--track); color: var(--text-2); }
.lock-note { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--muted); background: var(--track); padding: 8px 12px; border-radius: 12px; }
.class-card { display: grid; gap: 10px; cursor: pointer; transition: transform .35s var(--spring-soft), box-shadow .2s; }
.class-card:hover { transform: translateY(-2px); box-shadow: var(--sh-float); }
.class-card .top { display: flex; gap: 12px; align-items: center; }
.class-card .cc-ic { width: 46px; height: 46px; border-radius: 15px; display: grid; place-items: center; flex: none; }
.cc-ic.lav { background: var(--lavender); } .cc-ic.dark { background: var(--ink); color: var(--lime); } .cc-ic.lime { background: var(--lime); } .cc-ic.grey { background: var(--track); }
.class-card h4 { font-size: 15px; font-weight: 800; }
.cap-line { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.report-tile { cursor: pointer; display: grid; gap: 8px; transition: transform .35s var(--spring-soft), box-shadow .2s; }
.report-tile:hover { transform: translateY(-2px); box-shadow: var(--sh-float); }
.report-tile.on { box-shadow: inset 0 0 0 2px var(--ink); }
.hbars-lite .hbars { height: 120px; }
.card:not(.dark) .hbars .hb { background: repeating-linear-gradient(135deg, #d6d6da 0 2px, transparent 2px 6px); box-shadow: inset 0 0 0 1px var(--line-2); }
.card:not(.dark) .hbars .grp.on .hb:first-child { background: var(--ink); box-shadow: none; }
.card:not(.dark) .hbars-x { color: var(--muted); } .card:not(.dark) .hbars-x .on { color: var(--ink); }
.bars-h { display: grid; gap: 10px; }
.bars-h .r { display: grid; grid-template-columns: 120px 1fr 64px; gap: 10px; align-items: center; font-size: 12.5px; }
.bars-h .r b { text-align: end; font-size: 12.5px; }
.tbl-mini td, .tbl-mini th { padding: 8px 10px; }
.swatch-i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }

/* ---------- responsive ---------- */
@media (max-width: 1180px) {
  .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-21, .g-12 { grid-template-columns: 1fr; }
}
@media (max-width: 1023px) {
  .g-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gsearch .search { width: 220px; }
}
@media (max-width: 760px) {
  .g-2, .g-3 { grid-template-columns: 1fr; }
  .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .span-2 { grid-column: auto; }
  .form-g { grid-template-columns: 1fr; }
  .only-m { display: grid; }
  .gsearch { display: none !important; }
  .topbar .who .meta, .topbar .who > .pop-anchor { display: inline-flex; }
  .topbar .who .meta { display: block; }
  .topbar .who .meta span { display: none; }
  .head-acts { margin-inline-start: 0; width: 100%; }
  .head-acts .btn { flex: 1; }
  .kpi .big b { font-size: 24px; }
  .week-wrap { display: none; }
  .agenda { display: block; }
  .login { grid-template-columns: 1fr; }
  .login-art { padding: 26px 22px 30px; min-height: 0; gap: 18px; }
  .login-art .bubbles { max-width: 200px; }
  .demo-flag { display: none; }
  body.is-login .demo-flag { bottom: 8px; }
  /* tables become cards */
  .table.rt thead { display: none; }
  .table.rt, .table.rt tbody { display: block; }
  .table.rt tr { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 12px; padding: 12px 4px; border-bottom: 1px solid var(--line); }
  .table.rt td { display: flex; flex-direction: column; gap: 1px; padding: 2px 0; border: 0; white-space: normal; font-size: 12.5px; min-width: 0; }
  .table.rt td::before { content: attr(data-l); font-size: 10.5px; color: var(--muted); font-weight: 600; }
  .table.rt td.pri { grid-column: 1 / -1; order: -1; padding-bottom: 6px; }
  .table.rt td.pri::before, .table.rt td.act::before, .table.rt td.chk::before { display: none; }
  .table.rt td.act { grid-column: 1 / -1; flex-direction: row; justify-content: flex-end; }
  .table.rt tr { position: relative; }
  .table.rt td.chk { position: absolute; left: 6px; top: 12px; padding: 0; }
  .table.rt td[data-l=""]::before { display: none; }
  .bars-h .r { grid-template-columns: 90px 1fr 54px; }
  .more-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- dashboard (from the sample screen) ---------- */
.dash { display: grid; grid-template-columns: 1.08fr 1fr 1fr; grid-template-rows: auto auto 1fr; gap: 12px; }
.c-att { grid-row: 1 / span 3; display: flex; flex-direction: column; }
.c-sess { grid-column: 2; grid-row: 1; } .c-inst { grid-column: 2; grid-row: 2; }
.c-map { grid-column: 3; grid-row: 1 / span 2; } .c-fin { grid-column: 2 / span 2; grid-row: 3; }
.c-sess, .c-inst, .c-map { cursor: pointer; }
.c-att .bubbles { margin-block: 10px 14px; max-width: 300px; }
.c-att .progs { display: grid; gap: 8px; margin-top: auto; }
.c-att .progs .big b { font-size: 24px; }
.c-att .prog-row { cursor: pointer; }
.mini { display: flex; align-items: flex-end; gap: 10px; margin-top: 4px; }
.c-map .legend { display: flex; gap: 10px; margin-top: 12px; font-size: 11px; color: var(--muted); align-items: center; flex-wrap: wrap; }
.c-map .legend i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; margin-inline-end: 4px; vertical-align: -1px; }
.fin-top { display: flex; gap: 28px; margin: 0 0 12px; flex-wrap: wrap; }
.c-fin .hbars { height: 128px; }
.today { display: grid; grid-template-columns: 1.4fr 1fr; gap: 12px; margin-top: 12px; }
.save-bar { position: sticky; bottom: 12px; z-index: 30; margin-top: 12px; display: flex; align-items: center; gap: 12px; justify-content: space-between; background: var(--card); border-radius: 22px; padding: 10px 10px 10px 16px; box-shadow: var(--sh-float); flex-wrap: wrap; }
.profile-head h1 { line-height: 1.5; }
@media (max-width: 1023px) {
  .dash { grid-template-columns: 1fr 1fr; }
  .c-att { grid-column: 1; grid-row: 1 / span 2; } .c-sess { grid-column: 2; grid-row: 1; } .c-inst { grid-column: 2; grid-row: 2; }
  .c-map { grid-column: 1; grid-row: 3; } .c-fin { grid-column: 2; grid-row: 3; }
  .today { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .dash { gap: 10px; }
  .c-att, .c-map, .c-fin { grid-column: 1 / -1; grid-row: auto; }
  .c-sess, .c-inst { grid-row: auto; } .c-sess { grid-column: 1; } .c-inst { grid-column: 2; }
  .c-att { order: 0; } .c-sess { order: 1; } .c-inst { order: 2; } .c-fin { order: 3; } .c-map { order: 4; }
  .c-sess .side-stat, .c-inst .side-stat { display: none; }
  .c-att .bubbles { max-width: 250px; }
  .save-bar { bottom: 88px; }
  .save-bar .btn { flex: 1; }
}



/* free slots: quieter than real events */
.week .ev.free { background: repeating-linear-gradient(135deg, rgb(238 248 195 / .9) 0 5px, transparent 5px 11px); box-shadow: inset 0 0 0 1px rgb(207 231 79 / .7); color: #6b7a10; font-weight: 600; }
.week .ev.free b { font-size: 10.5px; }
.ag-ev.free { opacity: .8; }

/* ---- fixes: touch scroll in sheets, toasts above tab bar, tablet module switch ---- */
.sheet { touch-action: auto; overscroll-behavior: contain; }
.sheet .handle { touch-action: none; }
.rail-mod { display: none; }
@media (min-width: 761px) and (max-width: 1023px) {
  .rail-mod { display: grid; place-items: center; width: 52px; height: 52px; margin: 0 auto 8px; border-radius: 18px; background: #19191b; color: var(--on-dark-muted); font-size: 10px; font-weight: 700; gap: 2px; }
  .rail-mod b { color: var(--lime); }
}
@media (max-width: 760px) { .toasts { bottom: 92px; } }

/* ---------- manager home: what to do now on top, then the numbers in colour ---------- */
.home { display: grid; grid-template-columns: 1.25fr 1fr; grid-template-areas: "hero tasks" "day tasks"; grid-template-rows: auto 1fr; gap: 12px; }
.home > * { min-width: 0; }
.home > .card, .home > .hero-s { margin-top: 0; }
.home > .hero-s { grid-area: hero; }
.home > .home-tasks { grid-area: tasks; }
.home > .home-day { grid-area: day; }
.home .dl-legend, .home-day .lst { display: none; }
.tiles { display: grid; grid-template-columns: 1fr .8fr 1.5fr; gap: 12px; margin-top: 12px; }
.tiles > .card { margin-top: 0; min-width: 0; }
.list-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; flex-wrap: wrap; }
@media (max-width: 1023px) {
  .home { grid-template-columns: minmax(0, 1fr); grid-template-areas: "hero" "tasks" "day"; grid-template-rows: none; }
  .tiles { grid-template-columns: 1fr 1fr; }
  .tile-fin { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .home .dl, .home .dl-x { display: none; }
  .home-day .lst { display: grid; }
  .tiles { grid-template-columns: minmax(0, 1fr); }
  .tile { min-height: 0; }
  .due-row { min-height: 50px; }
}

/* ---------- manager home: tiles share one skeleton: head, big number with two lines, body that takes the rest ---------- */
.tile { display: flex; flex-direction: column; min-height: 330px; }
.stat-top { display: flex; align-items: center; gap: 12px; min-height: 52px; }
.stat-top > b { font-size: 44px; font-weight: 800; line-height: 1; letter-spacing: -.02em; }
.stat-top > div { display: grid; gap: 2px; min-width: 0; }
.stat-top span { font-size: 13px; font-weight: 700; }
.stat-top em { font-style: normal; font-size: 12px; color: var(--muted); }
.stat-top em.good { color: var(--ok); font-weight: 700; } .stat-top em.bad { color: var(--danger); font-weight: 700; }
.tile-body { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; margin-top: 12px; min-height: 0; }
.tile-att, .tile-inst { cursor: pointer; }
.tile-att .tile-body { justify-content: center; }
.tile-att .bubbles { max-width: 250px; }
.tile-inst .icon-dot, .tile-inst .select-pill { background: #fff; }
.tile-inst .stat-top em { color: #3b4214; }
.due-list { justify-content: stretch; gap: 8px; }
.due-list p { font-size: 13px; color: #3b4214; margin: auto 0; }
.due-row { display: flex; align-items: center; gap: 10px; flex: 1; max-height: 64px; background: rgb(255 255 255 / .72); border-radius: 18px; padding: 6px 14px; }
.due-row:hover { background: #fff; }
.due-row .grow { flex: 1; min-width: 0; display: grid; }
.due-row b { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.due-row span { font-size: 11px; color: var(--muted); }
.due-row em { font-style: normal; font-size: 13.5px; font-weight: 800; }
.tile-fin .stat-top em { color: var(--on-dark-muted); }
.tile-fin .tile-body .hbars { flex: 1; height: auto; min-height: 120px; }

/* tasks: rounded rows in the site's own colours, the most urgent one dark */
.home-tasks, .home-day { display: flex; flex-direction: column; }
.tasks { flex: 1; display: flex; flex-direction: column; gap: 8px; }
.task { flex: 1 0 auto; max-height: 82px; display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 24px; background: var(--track); cursor: pointer; transition: transform .35s var(--spring-soft); }
.task:hover { transform: translateY(-2px); }
.task > .grow { flex: 1; min-width: 0; display: grid; }
.task > .grow b { font-size: 13.5px; font-weight: 700; }
.task > .grow span { font-size: 11.5px; color: var(--muted); }
.task-ic { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; flex: none; background: #fff; }
.task-ic b { font-size: 18px; font-weight: 800; }
.t-danger .task-ic { background: var(--danger); color: #fff; }
.t-warn .task-ic { background: var(--lime); }
.t-info { background: var(--lav-faint); } .t-info .task-ic { background: var(--lavender); }
.t-lime .task-ic { background: var(--ink); color: var(--lime); }
.task-go { flex: none; display: inline-flex; align-items: center; gap: 4px; height: 34px; padding: 0 14px; border: 0; border-radius: var(--r-pill); background: var(--ink); color: #fff; font: inherit; font-size: 12px; font-weight: 700; white-space: nowrap; cursor: pointer; }
.task.hot { background: var(--ink); color: #fff; }
.task.hot > .grow span { color: var(--on-dark-muted); }
.task.hot .task-go { background: var(--lime); color: var(--ink); }
.task-rest { flex: 1; min-height: 56px; display: grid; place-items: center; border-radius: 24px; border: 1.5px dashed var(--line-2); color: var(--muted); font-size: 12.5px; }

/* today's timeline grows with the card */
@media (min-width: 761px) { .home-day .dl { flex: 1; display: flex; flex-direction: column; } }
.home-day .dl-track { flex: 1; height: auto; min-height: 62px; }

/* ---------- no card stretched around nothing ----------
   .col: the card is a column · .spread: its rows share the height · .center: its content sits in the middle
   .col-fill: a column of cards (or a block) whose last item takes whatever height is left */
.card.col { display: flex; flex-direction: column; }
.card.col > .card-head { flex: none; }
.card.spread > .lst, .card.spread > .set-row { flex: 1 0 auto; }
.card.spread > .lst { display: flex; flex-direction: column; }
.card.spread > .lst > * { flex: 1 0 auto; }
.card.center > .donut { flex: 1; align-content: center; }
.col-fill { display: flex; flex-direction: column; gap: 12px; }
.col-fill > :last-child { flex: 1; }
.kpi-fill { grid-auto-rows: 1fr; }
.fill-note { flex: 1; min-height: 110px; margin-top: 8px; display: grid; place-content: center; justify-items: center; gap: 6px; text-align: center; padding: 16px; border: 1.5px dashed #cdced2; border-radius: 18px; background: none; color: var(--muted); font: inherit; cursor: pointer; }
.fill-note b { color: var(--ink); font-size: 13.5px; }
.fill-note small { font-size: 12px; }
.fill-note:hover { background: var(--track); }
.fill-note + .hint { margin-top: 8px; }
.tile-inst .fill-note { margin-top: 0; border-color: rgba(34, 34, 36, .28); color: #3b4214; text-decoration: none; }
.tile-inst .fill-note:hover { background: rgba(255, 255, 255, .45); }
.live-link { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 16px; border-radius: 18px; background: var(--ink-3); color: #fff; font-size: 12.5px; }
.live-link span { color: var(--on-dark-muted); }
.grow-bars { flex: 1; display: flex; flex-direction: column; }
.hbars-lite.grow-bars .hbars { flex: 1; height: auto; min-height: 120px; }
.bars-h.fill { flex: 1; display: flex; flex-direction: column; justify-content: space-around; gap: 8px; margin-top: 14px; }
.bars-h .r.is-now span, .bars-h .r.is-now b { font-weight: 800; }

.att-live { display: flex; flex-direction: column; min-height: 190px; }
.att-live .icon-dot { background: var(--ink-3); }
.att-live .col-fill { flex: 1; justify-content: space-between; }
.att-live .col-fill > :last-child { flex: 0 0 auto; }
.live-num { display: flex; align-items: baseline; gap: 10px; margin: auto 0; }
.live-num b { font-size: 72px; font-weight: 800; line-height: 1.1; color: var(--lime); }
.live-num span { color: var(--on-dark-muted); font-size: 13px; }
.live-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.live-grid div { border-radius: 18px; padding: 8px 4px; text-align: center; background: var(--ink-3); color: #fff; display: grid; }
.live-grid b { font-size: 22px; font-weight: 800; } .live-grid span { font-size: 11px; }
.live-grid .k-p { background: var(--lime); color: var(--ink); } .live-grid .k-a { background: #fff; color: var(--ink); } .live-grid .k-l { background: var(--lavender); color: var(--ink); }
.live-none { margin: auto; color: var(--on-dark-muted); font-size: 13px; }

.hero-s.tall { display: flex; flex-direction: column; }
.hero-s.tall .bub { bottom: auto; top: -40px; }
.hero-foot { margin-top: auto; display: grid; gap: 8px; padding-top: 8px; }
.hero-line { display: flex; justify-content: space-between; gap: 10px; font-size: 12.5px; background: var(--ink-3); border-radius: 14px; padding: 8px 14px; }
.hero-line span { color: var(--on-dark-muted); }
.segs { display: flex; gap: 4px; margin-top: 4px; }
.segs i { flex: 1; height: 8px; border-radius: 99px; background: var(--ink-3); }
.segs i.done { background: var(--lavender); } .segs i.now { background: var(--lime); }

.cta { display: flex; flex-direction: column; justify-content: flex-end; align-items: flex-start; gap: 8px; min-height: 180px; overflow: hidden; }
.cta h3 { font-size: 18px; font-weight: 800; }
.cta p { font-size: 12.5px; color: #3b4214; }
.cta-art { flex: 1; align-self: stretch; position: relative; min-height: 118px; }
.cta-art i { position: absolute; border-radius: 50%; }
.cta-art i:nth-child(1) { width: 38%; max-width: 110px; aspect-ratio: 1; background: var(--lavender); inset-inline-end: 8%; top: 0; }
.cta-art i:nth-child(2) { width: 28%; max-width: 80px; aspect-ratio: 1; background: var(--ink); inset-inline-end: 34%; top: 22%; }
.cta-art i:nth-child(3) { width: 18%; max-width: 52px; aspect-ratio: 1; background: #fff; inset-inline-end: 26%; top: 0; }
/* one column but wide: the art sits beside the words instead of above them */
@media (min-width: 761px) and (max-width: 1180px) { .cta { min-height: 0; padding-block: 26px; } .cta-art { position: absolute; inset-inline-end: 24px; top: 22px; width: 240px; height: 120px; min-height: 0; } .cta > p { max-width: 58%; } }

/* ---------- sidebar: foldable groups ---------- */
.nav-group { display: flex; align-items: center; gap: 8px; width: 100%; height: 42px; padding: 0 14px; margin-top: 4px; border: 0; border-top: 1px solid var(--ink-3); background: none; color: var(--on-dark-muted); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; text-align: start; }
.nav-group:hover { color: #fff; }
.nav-group .badge { margin-inline-start: auto; }
.nav-group > svg { margin-inline-start: auto; transition: transform .25s var(--ease-out); }
.nav-group .badge + svg { margin-inline-start: 0; }
.nav-group[aria-expanded="true"] > svg { transform: rotate(180deg); }
.nav-group[aria-expanded="true"] .badge { visibility: hidden; }
.nav-sub { display: none; gap: 2px; }
.nav-group[aria-expanded="true"] + .nav-sub { display: grid; }
@media (min-width: 761px) and (max-width: 1023px) { .side .nav-group { display: none; } .side .nav-sub { display: grid; } }

/* ---------- session rows: date tile, topic, one state ---------- */
.sc { display: flex; align-items: center; gap: 12px; padding: 8px; padding-inline-end: 14px; border-radius: 24px; background: var(--track); min-width: 0; color: inherit; }
a.sc { cursor: pointer; transition: transform .35s var(--spring-soft); }
a.sc:hover { transform: translateY(-2px); }
.sc time { width: 52px; height: 52px; flex: none; border-radius: 50%; background: #fff; color: var(--ink); display: grid; place-content: center; text-align: center; line-height: 1.15; }
.sc time b { font-size: 18px; font-weight: 800; }
.sc time span { font-size: 10px; color: var(--muted); }
.sc > .grow { flex: 1; min-width: 0; display: grid; gap: 1px; }
.sc > .grow b { font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc > .grow span { font-size: 11.5px; color: var(--muted); }
.sc em { font-style: normal; font-size: 11px; font-weight: 700; background: #fff; color: var(--ink); border-radius: var(--r-pill); padding: 3px 9px; white-space: nowrap; }
.sc > .status, .sc-n { flex: none; }
.sc-n { font-size: 11.5px; color: var(--muted); white-space: nowrap; }
.sc-n b { font-size: 16px; font-weight: 800; color: var(--ink); }
.sc.hot { background: var(--ink); color: #fff; }
.sc.hot time { background: var(--lime); }
.sc.hot time span { color: var(--ink); }
.sc.hot > .grow span { color: var(--on-dark-muted); }
.sc.hot em { background: var(--ink-3); color: #fff; }
.sc.off time { background: #fbe3e0; }
.sc-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.sc-col { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.sc-head { font-size: 13px; font-weight: 800; padding: 0 8px; }
.sc-col .list-foot { margin-top: auto; }
.sc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
@media (max-width: 900px) { .sc-cols, .sc-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 480px) { .sc em { display: none; } }

.cc-next { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 9px 14px; border-radius: var(--r-pill); background: var(--track); font-size: 12px; }
.cc-next span { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.cc-next b { font-weight: 800; white-space: nowrap; }

.hero-topics { display: flex; flex-wrap: wrap; gap: 6px; }
.hero-topics span { background: var(--ink-3); border-radius: 12px; padding: 5px 12px; font-size: 12.5px; font-weight: 600; }
.hero-topics span.carry, .carry-key { box-shadow: inset 0 0 0 1.5px var(--lime); }
.carry-key { display: inline-block; width: 12px; height: 12px; border-radius: 4px; margin-inline-end: 6px; vertical-align: -2px; }

/* parent progress: two cards of one shape; the rows take whatever height the pair needs */
.pg .stat-top { margin-bottom: 12px; }
.pg-rows { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; flex: 1; }
.pg-rows > * { flex: 1 0 auto; max-height: 76px; }
.pg-more { margin-top: 12px; align-self: center; }

/* rows of cards that never leave a hole: fixed columns, a labelled slot takes what is left of the last row */
.g-cards { display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-cards.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-cards > * { min-width: 0; margin: 0; }
#view > .g-cards + .card { margin-top: 12px; }
.g-cards > .row-rest { margin: 0; border-radius: var(--r-card); min-height: 120px; }
.row-rest.d0 { display: none; } .row-rest.d2 { grid-column: span 2; } .row-rest.d3 { grid-column: span 3; }
.card.class-card.col { gap: 10px; }
.class-card .crs-rows + .hint { margin-top: 0; }
.class-card .stat-top { margin-top: 4px; }
.crs-rows { flex: 1; display: flex; flex-direction: column; gap: 8px; }
.crs-row { flex: 1 0 auto; max-height: 72px; display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 20px; background: var(--track); }
.crs-row > i { width: 32px; height: 32px; flex: none; display: grid; place-items: center; border-radius: 50%; background: var(--card); font-style: normal; font-weight: 800; font-size: 13px; }
.crs-row div { display: grid; min-width: 0; } .crs-row b { font-size: 13px; } .crs-row span { font-size: 11.5px; color: var(--muted); }
.tch > .status { margin-top: auto; justify-content: center; }
@media (min-width: 761px) and (max-width: 1180px) { .g-cards.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g-cards > .row-rest { grid-column: auto; display: grid; } .g-cards > .row-rest.t0 { display: none; } .g-3.keep3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) { .g-cards, .g-cards.four { grid-template-columns: 1fr; } .g-cards > .row-rest { display: none; } }
.terms.wide .term { flex: 1; }
.syl-card .syl { flex: 1; display: flex; flex-direction: column; }
.syl-card .syl-item { flex: 1 0 auto; max-height: 68px; min-height: 46px; padding-block: 5px; }
.syl-item .syl-att { display: inline-grid; place-items: center; vertical-align: middle; width: 22px; height: 22px; border-radius: 50%; background: var(--lavender); margin-inline-start: 6px; }
.syl-item .syl-att .ic { width: 13px; height: 13px; }
.fill-note.slim { min-height: 76px; }
.card.col > .task-rest { margin-top: 8px; }
.syl-card .syl:empty { display: none; }
.syl-card .syl:has(+ .fill-note) { flex: none; }
.syl-card .fill-note { margin-top: 6px; }
.crs-short > .syl-card { margin-bottom: 12px; }
.crs-side > .card { display: flex; flex-direction: column; margin: 0; min-width: 0; }
.crs-side > .card > :last-child { flex: 1 0 auto; }
.crs-side .kv { align-content: space-between; }
.crs-side .empty { justify-content: center; }
.syl-foot[hidden] { display: none; }
.syl-foot { margin-top: auto; padding-top: 12px; }
.sp-tile { background: var(--track); border-radius: 16px; padding: 12px; }
.sp-tile.sp-att { background: var(--card); box-shadow: inset 0 0 0 1.5px var(--line-2); }
.profile-head .hint .ltr { display: inline-block; white-space: nowrap; }
.sp-att { display: flex; flex-direction: column; justify-content: center; gap: 8px; }
.sp-att .cap-line { margin: 0; }

/* plans and reports */
.card.plan-card.col { gap: 8px; }
.plan-card.col .mini-bars { margin-top: auto; height: 48px; }
.att-rep .stat-top { margin-bottom: 12px; }
.att-rep .list-foot { margin-top: auto; padding-top: 12px; }
.rate { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; padding-top: 4px; }
.rep-top { margin-bottom: 12px; }
.mx.wide { width: 100%; min-width: 540px; table-layout: fixed; }
.mx.wide th:first-child { width: 92px; }
.mx.wide td.c { width: auto; height: 40px; border-radius: 13px; }
.mx.wide td.p { background: var(--lime); }
@media (max-width: 760px) { .mx.wide { min-width: 0; border-spacing: 2px; } .mx.wide th { padding-inline: 0; font-size: 10px; } .mx.wide th:first-child { width: 62px; } .mx.wide td.n { padding-inline-end: 4px; font-size: 11px; } .mx.wide td.c { height: 28px; border-radius: 7px; } }

/* sidebar card: whole when there is room, only its button when there is little, gone when there is none */
.promo-slot { flex: 1 1 0; min-height: 0; container-type: size; display: flex; flex-direction: column; justify-content: flex-end; }
@container (max-height: 146px) { .side .side-promo { padding: 10px; gap: 6px; } .side .side-promo p, .side .side-promo .promo-bubbles { display: none; } .side .side-promo h4 { font-size: 13px; padding-inline: 4px; } }
@container (max-height: 92px) { .side .side-promo { padding: 6px; gap: 0; } .side .side-promo h4 { display: none; } }
@container (max-height: 48px) { .side .side-promo { display: none; } }
/* short laptop screens: tighten the menu so the card keeps its place */
@media (min-width: 1024px) and (max-height: 820px) { .side { padding-top: 12px; gap: 4px; } .side .brand { padding-bottom: 6px; } .side .nav { gap: 1px; } .side .nav-item { height: 38px; } .side .nav-group { height: 34px; margin-top: 2px; } }

.room-card .room-go { margin-top: auto; align-self: flex-start; }
.room-card .kv { margin-bottom: 14px; }
.room-card .room-go { margin-top: 12px; }
a.crs-row { color: inherit; }

/* class cards: the head keeps one height, so teacher, bars and next session line up across a row */
@media (min-width: 761px) { .class-card:has(.cc-next) .top { min-height: 90px; } }
@media (max-width: 760px) { .req-rest { display: none; } }

/* ---------- guided tour ---------- */
.tour-spot { position: fixed; z-index: 95; left: 0; top: 0; width: 0; height: 0; border-radius: 24px; pointer-events: none; opacity: 0;
  box-shadow: 0 0 0 3px var(--lime), 0 0 0 9px rgb(218 241 101 / .28), 0 0 0 200vmax rgb(20 20 22 / .42);
  transition: transform .55s var(--spring-soft), width .55s var(--spring-soft), height .55s var(--spring-soft), opacity .3s var(--ease-out); }
.tour-spot.show { opacity: 1; }
.tour-card { position: fixed; z-index: 130; left: 20px; bottom: 20px; width: min(400px, calc(100vw - 24px)); background: var(--ink); color: #fff; border-radius: 26px; padding: 14px 16px 14px; box-shadow: var(--sh-pop);
  opacity: 0; transform: translateY(24px) scale(.96); pointer-events: none; transition: opacity .25s var(--ease-out), transform .5s var(--spring-soft); overflow: hidden; }
.tour-card.show { opacity: 1; transform: none; pointer-events: auto; }
.tour-card h3 { font-size: 17px; font-weight: 800; margin: 8px 0 4px; color: var(--lime); }
.tour-card p { font-size: 13px; line-height: 1.95; color: #e4e4e7; }
.tour-prog { position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--ink-3); }
.tour-prog i { display: block; height: 100%; background: var(--lime); transform-origin: right; transform: scaleX(0); }
.tour-top { display: flex; align-items: center; gap: 6px; margin-top: 4px; }
.tour-n { font-size: 11px; font-weight: 800; background: var(--lime); color: var(--ink); border-radius: 999px; padding: 1px 9px; }
.tour-chip { font-size: 11.5px; font-weight: 700; color: #fff; background: var(--ink-3); border-radius: 999px; padding: 2px 10px; display: inline-flex; align-items: center; gap: 4px; }
.tour-as { font-size: 11px; color: var(--on-dark-muted); display: inline-flex; align-items: center; gap: 4px; margin-inline-start: auto; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tour-x { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; color: var(--on-dark-muted); flex: none; }
.tour-x:hover { background: var(--ink-3); color: #fff; }
.tour-acts { display: flex; gap: 8px; align-items: center; margin-top: 12px; }
.tour-card .btn-secondary { background: var(--ink-3); color: #fff; box-shadow: none; }
.tour-card .btn[disabled] { opacity: .3; }
.tour-chaps { display: none; margin-top: 10px; background: var(--ink-2); border-radius: 16px; padding: 4px; max-height: 40vh; overflow-y: auto; }
.tour-card.chaps-open .tour-chaps { display: block; }
.tour-chaps .menu-item { color: #e4e4e7; }
.tour-chaps .menu-item:hover { background: var(--ink-3); }
body.touring .demo-flag { display: none; }
@media (min-width: 761px) { .tour-card.right { left: auto; right: 20px; } }
@media (max-width: 760px) {
  .tour-card { left: 10px; right: 10px; width: auto; bottom: 86px; padding: 12px 14px; border-radius: 22px; }
  .tour-card p { font-size: 12.5px; line-height: 1.85; max-height: 30vh; overflow-y: auto; }
  body.touring .tabbar { opacity: .35; pointer-events: none; }
  body.touring #view { padding-bottom: 60vh; } /* room to scroll the last cards above the tour card */
}


/* ---------- day timeline ---------- */
.dl { position: relative; }
.dl-track { position: relative; height: 58px; background: var(--track); border-radius: 14px; overflow: hidden; }
.dl.compact .dl-track { height: 18px; border-radius: 9px; }
.dl-h { position: absolute; top: 0; bottom: 0; width: 1px; background: rgb(0 0 0 / .05); }
.dl-h.even { background: rgb(0 0 0 / .09); }
.dl-past { position: absolute; top: 0; bottom: 0; background: repeating-linear-gradient(135deg, rgb(0 0 0 / .045) 0 4px, transparent 4px 9px); }
.dl-ev { position: absolute; top: 6px; bottom: 6px; border-radius: 10px; padding: 3px 7px; font-size: 10.5px; line-height: 1.3; display: flex; flex-direction: column; justify-content: center; overflow: hidden; min-width: 6px; color: var(--ink); text-align: start;
  transition: transform .35s var(--spring-soft), box-shadow .2s; z-index: 1; }
.dl.compact .dl-ev { top: 3px; bottom: 3px; border-radius: 6px; padding: 0; }
a.dl-ev:hover, button.dl-ev:hover { transform: translateY(-2px); box-shadow: var(--sh-float); z-index: 3; }
.dl-ev b { font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dl-ev span { font-size: 10px; opacity: .75; white-space: nowrap; }
.dl-ev.cls { background: var(--ink); color: #fff; } .dl-ev.cls b { color: var(--lime); }
.dl-ev.cls2 { background: var(--lavender); } .dl-ev.cls3 { background: var(--lime); }
.dl-ev.mtg { background: var(--card); box-shadow: inset 0 0 0 1.5px var(--ink); }
.dl-ev.busy { background: repeating-linear-gradient(135deg, #cfcfd3 0 2px, #e6e6e9 2px 6px); color: var(--muted); }
.dl-ev.cancel { background: var(--card); color: var(--muted); text-decoration: line-through; box-shadow: inset 0 0 0 1px var(--line-2); opacity: .8; }
.dl-ev.free { background: repeating-linear-gradient(135deg, rgb(238 248 195 / .95) 0 5px, rgb(255 255 255 / .6) 5px 10px); box-shadow: inset 0 0 0 1px rgb(207 231 79 / .8); color: #6b7a10; z-index: 0; }
.dl-ev.free b { font-weight: 600; }
.dl-now { position: absolute; top: 0; bottom: 0; width: 2px; margin-right: -1px; background: var(--danger); z-index: 4; pointer-events: none; }
.dl-now span { position: absolute; top: 2px; right: 4px; font-size: 9.5px; font-weight: 800; color: #fff; background: var(--danger); border-radius: 6px; padding: 0 5px; line-height: 1.6; }
.dl-x { position: relative; height: 18px; margin-top: 4px; font-size: 10.5px; color: var(--muted); }
.dl-x span { position: absolute; top: 0; transform: translateX(50%); white-space: nowrap; }
.dl-x span:first-child { transform: none; } .dl-x span:last-child { transform: translateX(100%); }
.dl-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 11px; color: var(--muted); margin: 8px 0 4px; }
.dl-legend span { display: inline-flex; align-items: center; gap: 5px; }
.dl-legend i { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }
.dl-legend i.cls { background: var(--ink); } .dl-legend i.cls2 { background: var(--lavender); } .dl-legend i.cls3 { background: var(--lime); }
.dl-legend i.mtg { box-shadow: inset 0 0 0 1.5px var(--ink); } .dl-legend i.free { background: var(--lime-soft); box-shadow: inset 0 0 0 1px var(--lime-2); }
.dl-legend i.now { width: 3px; border-radius: 2px; background: var(--danger); }
/* week as stacked timelines */
.wl { display: grid; gap: 8px; }
.wl-row { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px; align-items: center; }
.wl-axis { align-items: end; } .wl-axis .dl-x { margin: 0; }
.wl-day b { display: block; font-size: 13px; } .wl-day span { font-size: 11px; color: var(--muted); }
.wl-row.today .wl-day b { background: var(--lime); border-radius: 999px; padding: 0 10px; display: inline-block; }
.wl-row.today .dl-track { box-shadow: inset 0 0 0 2px var(--lime-2); }
.wl-row.hol .dl-track { background: repeating-linear-gradient(135deg, var(--danger-bg) 0 6px, #fff 6px 12px); }
.wl-row.hol .wl-day span { color: var(--danger); }
.wv-bar { display: flex; justify-content: flex-start; margin-bottom: 12px; }
@media (max-width: 760px) {
  .wl-row { grid-template-columns: 58px minmax(0, 1fr); gap: 8px; }
  .wl-day b { font-size: 12px; } .wl-day span { font-size: 10px; }
  .dl-track { height: 50px; }
  .dl-ev { padding: 2px 4px; } .dl-ev span { display: none; } .dl-ev b { font-size: 10px; }
  .dl-x span:nth-child(even) { display: none; }
  /* in timeline mode the classic grid/agenda isn't shown, so nothing else to hide */
}

/* ---------- raw-element styling sweep ---------- */
/* scrollbars: thin, rounded, on-brand (WebKit + Firefox) */
* { scrollbar-width: thin; scrollbar-color: #c4c4c9 transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #c4c4c9; border-radius: 10px; border: 3px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background: #9a9aa0; background-clip: padding-box; border: 3px solid transparent; }
::-webkit-scrollbar-corner { background: transparent; }
.side, .tour-card, .card.dark, .hero-s, .notif-pop { scrollbar-color: #4c4c4e transparent; }
.side::-webkit-scrollbar-thumb, .card.dark ::-webkit-scrollbar-thumb { background: #4c4c4e; background-clip: padding-box; }
/* selects: custom chevron (RTL → on the left), focus ring, readable options */
select.input { padding-inline-end: 38px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2377777c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6.5 9.5 5.5 5.5 5.5-5.5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-size: 16px; background-position: left 14px center; }
select.input:focus { box-shadow: inset 0 0 0 1.5px var(--ink); background-color: var(--card); }
select.input option { background: var(--card); color: var(--text); font-family: var(--font); }
select.input:disabled, .input:disabled { opacity: .5; cursor: not-allowed; }
/* number-ish inputs: no spinners */
input::-webkit-outer-spin-button, input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
input[type=password].input { letter-spacing: .2em; }
/* tabs: clear active underline */
.tabs-line button { position: relative; }
.tabs-line button.on::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; border-radius: 3px; background: var(--ink); }
.tabs-line button:hover { color: var(--text); }
/* lists, definition lists, disabled controls */
dl.kv { margin: 0; }
.slot:disabled, .chip:disabled, .rc:disabled { opacity: .45; cursor: not-allowed; }
.btn:disabled, .btn.is-disabled { cursor: not-allowed; }
button:focus-visible, a:focus-visible, select:focus-visible, input:focus-visible { outline: none; box-shadow: var(--ring); }
textarea.input { font-family: var(--font); }
.mx-wrap, .table-wrap, .week-wrap, .chips-row, .terms { scrollbar-width: thin; }
.chips-row::-webkit-scrollbar, .terms::-webkit-scrollbar, .kids::-webkit-scrollbar, .tabs-line::-webkit-scrollbar { height: 0; }
/* quieter free slots in timelines so the real events pop */
.dl-ev.free { background: rgb(238 248 195 / .55); box-shadow: inset 0 0 0 1px rgb(207 231 79 / .45); color: #8a9640; }
.dl-ev.free span { display: none; }
.wl-day span { white-space: nowrap; }

.day-card { margin-top: 12px; }
.day-card .dl-track { height: 64px; }


[hidden] { display: none !important; }

/* SMS panel switched off (SMS_PANEL=0 on the server): hide every button that sends or schedules a text.
   The code behind them stays; set SMS_PANEL=1 and they all come back. */
.sms-off [data-act="msgClass"], .sms-off [data-act="smsRemind"], .sms-off [data-act="bulkSms"],
.sms-off [data-act="tMsg"], .sms-off [data-act="smsToggle"], .sms-off .sms-only { display: none !important; }
