/* AIEventOps – phone first (390 px), light and dark, every tap at least 44 px */
:root {
  --bg: #f4f6f5; --card: #ffffff; --ink: #17201d; --muted: #5b6a64; --line: #d5ddd9; --soft: #e9efec;
  --brand: #0f6b5c; --brand-ink: #ffffff; --accent: #b4590a; --ok: #1d7a3a; --warn: #8a5a00; --bad: #b42318;
  --okbg: #e3f4e8; --warnbg: #fff3d6; --badbg: #fde7e5; --sel: #dff1ec;
  --r: 14px; --tap: 44px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1513; --card: #17211e; --ink: #e8efec; --muted: #9fb0a9; --line: #2c3a35; --soft: #1f2b27;
    --brand: #52c7b0; --brand-ink: #062a24; --accent: #f0a35a; --ok: #6fd28a; --warn: #f2c35b; --bad: #ff8a80;
    --okbg: #16301f; --warnbg: #352a10; --badbg: #3a1b18; --sel: #173a33; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e1513; --card: #17211e; --ink: #e8efec; --muted: #9fb0a9; --line: #2c3a35; --soft: #1f2b27;
  --brand: #52c7b0; --brand-ink: #062a24; --accent: #f0a35a; --ok: #6fd28a; --warn: #f2c35b; --bad: #ff8a80;
  --okbg: #16301f; --warnbg: #352a10; --badbg: #3a1b18; --sel: #173a33; color-scheme: dark;
}
* { box-sizing: border-box }
html, body { background: var(--bg); overflow-x: clip }
body { margin: 0; color: var(--ink); font: 16px/1.45 var(--font); min-height: 100vh; -webkit-text-size-adjust: 100% }
a { color: var(--brand) }
.skip { position: absolute; left: -9999px } .skip:focus { left: 12px; top: 12px; z-index: 60; background: var(--card); color: var(--ink); padding: 10px 12px; border-radius: 8px }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px }
h1, h2, h3 { line-height: 1.2; margin: 0 }
h1 { font-size: 1.45rem } h2 { font-size: 1.15rem } h3 { font-size: 1rem }

.bar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 6px; padding: 8px 16px; padding-top: max(8px, env(safe-area-inset-top));
  background: var(--card); border-bottom: 1px solid var(--line) }
.brand { display: flex; align-items: center; gap: 10px; min-height: var(--tap); margin-right: auto; text-decoration: none; color: var(--ink); min-width: 0 }
.brand .logo { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--brand); font-size: 20px; flex: none }
.brand b { display: block; font-size: 1.05rem } .brand small { display: block; color: var(--muted); font-size: .78rem; margin-top: -2px }
.ib { min-width: var(--tap); min-height: var(--tap); border-radius: 12px; border: 1px solid var(--line); background: var(--card); color: var(--ink); font-size: 1.15rem; cursor: pointer }
#ebeSites .ebes > button { width: var(--tap); height: var(--tap) }
.menu { position: fixed; z-index: 40; right: 12px; top: 64px; width: min(330px, calc(100vw - 24px)); background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: 0 12px 30px rgba(0,0,0,.25); padding: 6px }
.menu > * { display: flex; align-items: center; width: 100%; min-height: var(--tap); padding: 8px 12px; border: 0; border-radius: 10px; background: none; color: var(--ink); font: inherit; text-align: left; text-decoration: none; cursor: pointer }
.menu > *:hover { background: var(--soft) }

.wrap { max-width: 1100px; margin: 0 auto; padding: 14px 16px 24px }
.wrap:focus { outline: none }
.foot { max-width: 1100px; margin: 0 auto; padding: 8px 16px 28px; color: var(--muted); font-size: .88rem }
.foot a { display: inline-block; min-height: var(--tap); line-height: var(--tap) }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: var(--tap); padding: 8px 14px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--card); color: var(--ink); font: 600 .95rem var(--font); cursor: pointer; text-decoration: none; white-space: nowrap }
.btn.pri { background: var(--brand); color: var(--brand-ink); border-color: var(--brand) }
.btn.ghost { background: transparent }
.btn:disabled { opacity: .5; cursor: default }
.btn.sm { padding: 6px 10px; font-size: .9rem }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center }
.row.end { justify-content: flex-end }
.sp { flex: 1 }
.note { color: var(--muted); font-size: .92rem; margin: 6px 0 }
.warnbox { background: var(--warnbg); border-radius: 12px; padding: 10px 12px; margin: 10px 0; font-size: .92rem }

.head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 4px 0 12px }
.head h1 { margin-right: auto }
.back { min-height: var(--tap); display: inline-flex; align-items: center; text-decoration: none; font-weight: 600 }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 10px }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; min-width: 0 }
a.card { display: block; color: var(--ink); text-decoration: none; min-height: var(--tap) }
a.card:hover { border-color: var(--brand) }
.card b { display: block; font-size: 1.02rem }
.card small, .meta { color: var(--muted); font-size: .88rem }
.pills { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px }
.pill { display: inline-block; font-size: .78rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--soft); color: var(--muted) }
.pill.confirmed { background: var(--okbg); color: var(--ok) } .pill.requested { background: var(--warnbg); color: var(--warn) } .pill.cancelled { background: var(--badbg); color: var(--bad) }
.pill.review { background: var(--sel); color: var(--brand) }

.tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--line); margin: 0 -16px 12px; padding: 0 16px; position: sticky; top: 61px; z-index: 20; background: var(--bg) }
.tabs a { flex: none; display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 12px; text-decoration: none; color: var(--muted); font-weight: 600; border-bottom: 3px solid transparent; white-space: nowrap }
.tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--brand) }

.tools { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px }
.field { display: flex; flex-direction: column; gap: 4px; min-width: 0 }
.field > span { font-size: .85rem; font-weight: 600; color: var(--muted) }
input, select, textarea { font: inherit; font-size: 16px; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 9px 10px; min-height: var(--tap); width: 100%; min-width: 0 }
textarea { min-height: 140px; resize: vertical; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 14px }
input[type="checkbox"] { width: 24px; height: 24px; min-height: 24px; accent-color: var(--brand); margin: 0 }
.inline { display: grid; grid-template-columns: 1fr 1fr; gap: 8px }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px }
.grid2 .full { grid-column: 1 / -1 }
.chips { display: flex; flex-wrap: wrap; gap: 6px }
.chip { min-height: var(--tap); padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--soft); color: var(--ink); font: 600 .88rem var(--font); cursor: pointer }
.chip[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); border-color: var(--brand) }
.seg { display: flex; border: 1px solid var(--line); border-radius: 12px; overflow: hidden }
.seg button { flex: 1; min-height: var(--tap); border: 0; background: var(--card); color: var(--ink); font: 600 .9rem var(--font); cursor: pointer; padding: 0 6px }
.seg button + button { border-left: 1px solid var(--line) }
.seg button[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink) }

/* guest rows */
.list { display: flex; flex-direction: column; gap: 8px }
.grp { margin: 14px 0 6px; font-size: .95rem; display: flex; gap: 8px; align-items: baseline }
.grp small { color: var(--muted); font-weight: 400 }
.g { display: grid; grid-template-columns: var(--tap) 1fr; align-items: start; background: var(--card); border: 1px solid var(--line); border-radius: var(--r) }
.g.on { background: var(--sel); border-color: var(--brand) }
.g.cx { opacity: .6 }
.g label.ck { display: grid; place-items: center; min-height: 100%; min-width: var(--tap); padding: 12px 0; cursor: pointer }
.g button.open { display: block; width: 100%; min-height: var(--tap); text-align: left; background: none; border: 0; color: var(--ink); font: inherit; padding: 10px 12px 10px 0; cursor: pointer }
.g .l1 { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap }
.g .l1 b { font-size: 1rem }
.g .c1, .g .c2, .g .c3 { display: block; min-width: 0 }
.g .dates { font-variant-numeric: tabular-nums }
.selbar { position: sticky; bottom: 0; z-index: 25; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; background: var(--card); border: 1px solid var(--brand); border-radius: var(--r); padding: 8px 10px; margin-top: 10px; box-shadow: 0 -6px 18px rgba(0,0,0,.12) }

/* the room block grid */
.gridwrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--card) }
table.blk { border-collapse: collapse; font-variant-numeric: tabular-nums; min-width: 100% }
table.blk th, table.blk td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: center; white-space: nowrap }
table.blk th:first-child, table.blk td:first-child { text-align: left; position: sticky; left: 0; background: var(--card) }
table.blk thead th { font-size: .82rem; color: var(--muted); vertical-align: bottom; white-space: normal; min-width: 70px }
table.blk td.z { color: var(--line) }
table.blk td.hi { background: var(--sel); font-weight: 700 }
table.blk tfoot td, table.blk .tot { font-weight: 700 }

dialog { width: min(560px, calc(100vw - 16px)); max-height: calc(100dvh - 16px); padding: 0; border: 1px solid var(--line); border-radius: 18px; background: var(--card); color: var(--ink) }
dialog::backdrop { background: rgba(0,0,0,.45) }
dialog form { display: flex; flex-direction: column; gap: 12px; padding: 16px }
dialog .dh { display: flex; align-items: center; gap: 8px }
dialog .dh h2 { margin-right: auto }
.prev { max-height: 220px; overflow: auto; border: 1px solid var(--line); border-radius: 10px; font-size: .85rem }
.prev table { border-collapse: collapse; width: 100% } .prev td, .prev th { padding: 4px 6px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap }

.toast { position: fixed; left: 50%; bottom: max(16px, env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 60; display: flex; gap: 10px; align-items: center;
  max-width: calc(100vw - 24px); background: var(--ink); color: var(--bg); padding: 8px 8px 8px 14px; border-radius: 14px; box-shadow: 0 8px 24px rgba(0,0,0,.3) }
.toast[hidden] { display: none }
.toast .btn { background: transparent; color: var(--bg); border-color: var(--bg) }
.empty { text-align: center; padding: 26px 12px; color: var(--muted) }
.empty .big { font-size: 2.2rem }
.done { text-decoration: line-through; color: var(--muted) }

#printArea { display: none }
@media (min-width: 760px) {
  .g button.open.gr { display: grid; grid-template-columns: 1.4fr 1.6fr 1fr; gap: 10px; align-items: center }
}
@media print {
  body > *:not(#printArea) { display: none !important }
  html, body { background: #fff; color: #000 }
  #printArea { display: block; font: 10.5pt/1.3 var(--font) }
  #printArea section { break-after: page }
  #printArea section:last-child { break-after: auto }
  #printArea h1 { font-size: 15pt } #printArea p { margin: 2px 0 8px; color: #333 }
  #printArea table { width: 100%; border-collapse: collapse }
  #printArea th, #printArea td { border: 1px solid #999; padding: 4px 5px; text-align: left; vertical-align: top }
  #printArea th { background: #eee }
  #printArea tr { break-inside: avoid }
  @page { size: A4 landscape; margin: 12mm }
}
.g button.open > span { display: block }

/* 🔑 ECO_AUTH: the account button in the header and the line under "Your events" */
#ecoAcct { display: inline-flex; flex: none; min-width: 0 }
.cloudline { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 8px 0 12px }
.cloudline .note { margin: 0 }
@media (max-width: 420px) { .bar { gap: 4px; padding-left: 12px; padding-right: 12px } .brand { gap: 8px } .brand small { display: none } .bar:has(#ecoAcctBtn) .brand > span:last-child { display: none } #ecoAcct { margin-left: 4px } }
/* 🔑 ECO_SIGNEDOUT: lists kept on this device only */
.cloudline.devonly { background: var(--warnbg); border-radius: 12px; padding: 8px 10px }
.devchip { display: inline-flex; align-items: center; min-height: 32px; padding: 0 10px; border-radius: 999px; background: var(--card, #fff); border: 1.5px solid var(--line); font-weight: 700; font-size: .88rem; color: var(--ink) }
/* 📚 ECO_SECTIONS */
.seclist { display: grid; gap: 10px; grid-template-columns: 1fr }
@media (min-width: 900px) { .seclist { grid-template-columns: 1fr 1fr } }
.sec { display: grid; gap: 8px; text-align: left }
.sech { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px }
.sech .secn { font-size: 1.05rem; flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere }
.secb { display: flex; flex-wrap: wrap; gap: 8px }
.secf { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px }
.secf .meta { flex: 1 1 200px; min-width: 0; overflow-wrap: anywhere }
.btn.off { opacity: .45; cursor: not-allowed; pointer-events: none; filter: grayscale(1) }
a.btn { text-decoration: none; display: inline-flex; align-items: center; justify-content: center }
/* ℹ️ ECO_DETAILS */
.evdet { margin: 8px 0 12px; text-align: left }
.evdet summary { min-height: 44px; display: flex; align-items: center; font-weight: 700; cursor: pointer }
.dlist { display: grid; gap: 8px; margin-top: 6px }
.dl { display: grid; grid-template-columns: minmax(110px, 160px) 1fr; gap: 4px 10px; align-items: start }
@media (max-width: 480px) { .dl { grid-template-columns: 1fr } }
.dk { color: var(--muted); font-size: .9rem; font-weight: 600 }
.dv { display: flex; flex-wrap: wrap; gap: 4px 12px; overflow-wrap: anywhere }
.dcon { display: block; width: 100% }
.dcon a { display: inline-flex; align-items: center; min-height: 44px; margin-right: 8px }
.detf .drow { border-top: 1px dashed var(--line); padding-top: 6px; margin-top: 6px }
/* 📋 ECO_TABLES – big tables, a screen at a time */
.tblock { margin: 10px 0 18px; min-width: 0 }
.thead { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap }
.ttools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 6px 0 }
.ttools .tq { flex: 1 1 220px; min-height: var(--tap) }
.tgroups { display: flex; flex-wrap: wrap; gap: 6px }
.tgrid { position: relative; overflow: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--card); max-width: 100%; -webkit-overflow-scrolling: touch; overscroll-behavior: contain }
.tin { position: relative; min-width: 100% }
.tgrid .tr { display: flex; height: 40px; width: 100% }
.tgrid .tbody { position: relative }
.tgrid .tbody .tr { position: absolute; left: 0; right: 0; border-bottom: 1px solid var(--line) }
.tgrid .tc { flex: none; box-sizing: border-box; height: 40px; padding: 0 8px; display: flex; align-items: center; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; border-right: 1px solid var(--line); background: var(--card); font-size: .9rem }
.tgrid .tc.nr { justify-content: flex-end; font-variant-numeric: tabular-nums }
.tgrid .tc.ctr { justify-content: center }
.tgrid .tc.fz { position: sticky; z-index: 1 }
.tgrid .th { position: sticky; top: 0; z-index: 3 }
.tgrid .th .tc { background: var(--soft); font-weight: 700; padding: 0 }
.tgrid .th .tc.fz { z-index: 4 }
.tsort { all: unset; box-sizing: border-box; width: 100%; height: 100%; padding: 0 8px; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700 }
.tsort:focus-visible { outline: 2px solid var(--brand); outline-offset: -2px }
.tgrid .tf { position: sticky; bottom: 0; z-index: 3 }
.tgrid .tf .tc { background: var(--soft); font-weight: 700 }
.tgrid .tf .tc.fz { z-index: 4 }
.tgrid .tr.hl .tc { background: color-mix(in srgb, var(--hl) 70%, var(--card)) }
.tgrid .tr.cx .tc { text-decoration: line-through; color: var(--muted) }
.tgrid .tc.tkey { font-weight: 600; cursor: pointer; text-decoration-color: var(--muted) }
.tgrid .tc.tkey::before { content: "ⓘ"; margin-right: 6px; color: var(--muted); font-weight: 400 }
.tgrid .tc a { color: var(--brand); overflow: hidden; text-overflow: ellipsis }
.tgrid .tc.editing { padding: 0; overflow: visible }
.tgrid .tedit { box-sizing: border-box; width: 100%; height: 100%; border: 2px solid var(--brand); border-radius: 0; font: inherit; padding: 0 6px; background: var(--card); color: var(--ink) }
.ttabs { overflow-x: auto }
.tfields .fv { display: block; padding: 6px 0; overflow-wrap: anywhere }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) .tgrid .tr.hl .tc { background: color-mix(in srgb, var(--hl) 22%, var(--card)) } }
:root[data-theme=dark] .tgrid .tr.hl .tc { background: color-mix(in srgb, var(--hl) 22%, var(--card)) }
/* 🛏️ ECO_ROOMING2 */
.pill.not_sure { background: var(--soft); color: var(--ink); border: 1px dashed var(--muted) }
.pill.gt { background: var(--sel); color: var(--ink) }
.g.staff, table.nights tr.staff th, table.nights tr.staff td { background: color-mix(in srgb, #5a8dd6 12%, var(--card)) }
.nsort { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 8px 0 }
.nwrap { max-height: 70vh; overflow: auto }
table.nights thead th { position: sticky; top: 0; z-index: 2; background: var(--soft) }
table.nights thead th:first-child { z-index: 3 }
table.nights tbody th { position: sticky; left: 0; background: var(--card); text-align: left; z-index: 1 }
table.nights .evday { background: color-mix(in srgb, var(--brand) 14%, var(--card)) }
table.nights thead th.evday { background: color-mix(in srgb, var(--brand) 26%, var(--soft)); color: var(--ink) }
table.nights td.tick { color: var(--brand); font-weight: 800 }
table.nights tr.cx th, table.nights tr.cx td { text-decoration: line-through; opacity: .6 }
table.nights tfoot td { position: sticky; bottom: 0; background: var(--soft) }
.lnk { all: unset; cursor: pointer; font-weight: 600; min-height: 44px; display: inline-flex; align-items: center }
.lnk:focus-visible { outline: 2px solid var(--brand) }
/* 👁️ ECO_WATCH: the closed row of events only kept an eye on, and its chooser */
.evwatch { margin: 10px 0 }
.evwatch summary { min-height: 44px; display: flex; align-items: center; font-weight: 700; cursor: pointer }
.evwatch .cards { margin-top: 8px }
.wck { display: flex; align-items: center; gap: 10px; min-height: 44px; cursor: pointer }
.wck input { width: 22px; height: 22px; flex: none }
/* 🏢 ECO_EXDB: Y / N squares, long text that wraps, taller rows when a table has long text */
.tgrid .tbody .tr, .tgrid .tbody .tr .tc { height: var(--rh, 40px) }
.tgrid .yn { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 7px; font-weight: 700; font-size: .85rem; color: #fff }
.tgrid .yn.y { background: #1f8f4e } .tgrid .yn.n { background: #cf3f3f } .tgrid .yn.e { background: none; border: 1px dashed var(--muted) }
.tgrid .tc.wrapc { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; white-space: normal; overflow: hidden; padding: 6px 8px 0; font-size: .8rem; line-height: 1.375 }   /* three lines fill the 60 px row exactly – no sliver of a fourth */
.tgrid .tc.wrapc.editing { display: flex; padding: 0 }
.tgrid .tc.redtx { color: var(--bad) }
.tgrid .tr.cx .tc .yn { opacity: .45 }
/* 🔒 ECO_EDITLOCK */
.tblock .btn[hidden] { display: none }
.tblock.locked .tgrid .tbody .tc { cursor: default }
.tlock[aria-pressed="true"] { background: var(--warnbg); border-color: var(--warn); color: var(--warn) }
/* 📄 ECO_SHEETLOOK: the table drawn like the working record – its own paper colours, light and dark */
.tblock.sheet { --sp: #FBFAF7; --ss: #FFFFFF; --ss2: #F4F2ED; --si: #1A1D24; --si2: #43485A; --sm: #6B7183; --sr: #DFDBD2; --srs: #EAE7E0; --sa: #1F4E79; --sg: #2F6B4F; --sc: #A33B32; --sgb: #E7F0EA; --scb: #F7E7E5; --sband: #1F4E79; --sbandi: #FFFFFF;
  --ty: #FBF6EA; --tp: #F7F2FB; --tb: #EEF4FC; --tr_: #FCF2F1; --to: #FDF4ED; --tg: #EEF6F0; --tk: #FBF1F6 }
@media (prefers-color-scheme: dark) { :root:not([data-theme=light]) .tblock.sheet { --sp: #14171C; --ss: #1B1F26; --ss2: #232830; --si: #E9E7E2; --si2: #C3C7D0; --sm: #949AA8; --sr: #2E343E; --srs: #262C35; --sa: #7FB2DD; --sg: #6FBF95; --sc: #E0776C; --sgb: #1C2C25; --scb: #33201E; --sband: #223A52; --sbandi: #E9E7E2;
  --ty: #221F19; --tp: #201B26; --tb: #191F28; --tr_: #241A18; --to: #241C17; --tg: #1A241E; --tk: #241A20 } }
:root[data-theme=dark] .tblock.sheet { --sp: #14171C; --ss: #1B1F26; --ss2: #232830; --si: #E9E7E2; --si2: #C3C7D0; --sm: #949AA8; --sr: #2E343E; --srs: #262C35; --sa: #7FB2DD; --sg: #6FBF95; --sc: #E0776C; --sgb: #1C2C25; --scb: #33201E; --sband: #223A52; --sbandi: #E9E7E2;
  --ty: #221F19; --tp: #201B26; --tb: #191F28; --tr_: #241A18; --to: #241C17; --tg: #1A241E; --tk: #241A20 }
.tblock.sheet .tgrid { border: 1px solid var(--sr); border-radius: 3px; background: var(--ss); color: var(--si); font: 11px/1.25 "IBM Plex Sans", ui-sans-serif, system-ui, -apple-system, sans-serif }
.tblock.sheet .tgrid.flow { max-height: 74vh }
.tblock.sheet .tgrid .tr { height: auto }
.tblock.sheet .tgrid .tband { position: sticky; top: 0; z-index: 5; height: 24px }
.tblock.sheet .tgrid .tbc { flex: none; box-sizing: border-box; height: 24px; padding: 0 8px; display: flex; align-items: center; overflow: hidden; white-space: nowrap; background: var(--sband); color: var(--sbandi);
  font: 600 9.6px/1 "IBM Plex Mono", ui-monospace, monospace; letter-spacing: .11em; text-transform: uppercase; border-right: 1px solid rgba(255,255,255,.22) }
.tblock.sheet .tgrid .tbc.fz { position: sticky; z-index: 6 }
.tblock.sheet .tgrid .th { top: 24px; height: 40px }
.tblock.sheet .tgrid .th .tc { height: 40px; background: var(--ss2); border-right: 1px solid var(--srs); border-bottom: 1px solid var(--sr) }
.tblock.sheet .tgrid .tsort { font: 500 9.6px/1.25 "IBM Plex Mono", ui-monospace, monospace; letter-spacing: .08em; text-transform: uppercase; color: var(--sm); white-space: normal; text-align: left; padding: 3px 6px; align-items: flex-start }
.tblock.sheet .tgrid .tbody .tr { position: static; display: flex; align-items: stretch; height: auto; border-bottom: 0 }
.tblock.sheet .tgrid .tbody .tr .tc { height: auto; min-height: 22px; padding: 2px 6px; background: var(--ss); border-right: 1px solid var(--srs); border-bottom: 1px solid var(--srs) }
.tblock.sheet .tgrid .tbody .tr .tc, .tblock.sheet .tgrid .tf .tc { font-size: 11px }
.tblock.sheet .tgrid .th .tc.thyn .tsort { font-size: 7.4px; letter-spacing: 0; padding: 3px 1px; text-align: center; justify-content: center; overflow: visible; text-overflow: clip; white-space: nowrap }
.tblock.sheet .tgrid .tbody .tr:hover .tc { filter: brightness(.97) }
.tblock.sheet .tgrid .tbody .tc.fz { background: var(--sp) }
.tblock.sheet .tgrid .tc.nr, .tblock.sheet .tgrid .tf .tc { font-family: "IBM Plex Mono", ui-monospace, monospace; font-variant-numeric: tabular-nums }
.tblock.sheet .tgrid .tc.tkey::before { content: none }
.tblock.sheet .tgrid .tc.tkey { color: var(--sa); font-weight: 500; text-decoration: underline dotted; text-underline-offset: 2px }
.tblock.sheet .tgrid .tbody .tc.wrapc { display: block; white-space: normal; overflow: visible; -webkit-line-clamp: unset; padding: 3px 6px; font-size: 11px; line-height: 1.3 }
.tblock.sheet .tgrid .tbody .tc.wrapc.editing { display: flex; padding: 0; min-height: 60px }
.tblock.sheet .tgrid .tc.redtx { color: var(--sc) }
.tblock.sheet .tgrid .tbody .tc[data-col].signed, .tblock.sheet .tgrid .tbody .tc.ync.yy { background: var(--sgb) }
.tblock.sheet .tgrid .tbody .tc.signed { font-weight: 600 }
.tblock.sheet .tgrid .tbody .tc.ync.ynn { background: var(--scb) }
.tblock.sheet .tgrid .tbody .tc.ync { padding: 0 }
.tblock.sheet .tgrid .yn { width: auto; height: auto; background: none; border: 0; border-radius: 0; font: 700 12px/1 "IBM Plex Mono", ui-monospace, monospace }
.tblock.sheet .tgrid .yn.y { color: var(--sg); background: none } .tblock.sheet .tgrid .yn.n { color: var(--sc); background: none } .tblock.sheet .tgrid .yn.e { border: 0 }
.tblock.sheet .tgrid .tbody .tc.tint-yellow { background: var(--ty) } .tblock.sheet .tgrid .tbody .tc.tint-purple { background: var(--tp) } .tblock.sheet .tgrid .tbody .tc.tint-blue { background: var(--tb) }
.tblock.sheet .tgrid .tbody .tc.tint-red { background: var(--tr_) } .tblock.sheet .tgrid .tbody .tc.tint-orange { background: var(--to) } .tblock.sheet .tgrid .tbody .tc.tint-green { background: var(--tg) } .tblock.sheet .tgrid .tbody .tc.tint-pink { background: var(--tk) }
.tblock.sheet .tgrid .tr.hl .tc { background: color-mix(in srgb, var(--hl) 55%, var(--ss)) }
.tblock.sheet .tgrid .tr.cx .tc { color: var(--sm) }
.tblock.sheet .tgrid .tf { height: 26px } .tblock.sheet .tgrid .tf .tc { height: 26px; background: var(--ss2); font-weight: 600; border-top: 2px solid var(--sr); border-right: 1px solid var(--srs) }
.tblock.sheet .tgrid .tedit { font: inherit; padding: 0 5px }
.tblock.sheet .tgroups .chip { min-height: 30px; padding: 3px 12px; border-radius: 14px; background: var(--ss); border: 1px solid var(--sr); color: var(--sm); font: 600 12px "IBM Plex Sans", ui-sans-serif, system-ui, sans-serif }
.tblock.sheet .tgroups .chip[aria-pressed="true"] { background: var(--ss); color: var(--si2); border-color: var(--sm) }
.tblock.sheet .tgroups .chip[aria-pressed="false"] { opacity: .4; text-decoration: line-through }
.tblock.sheet .tgroups .chip[data-gc=yellow] { color: #8A6524; border-color: #C9A75E } .tblock.sheet .tgroups .chip[data-gc=purple] { color: #6B3FA0; border-color: #A98AD0 }
.tblock.sheet .tgroups .chip[data-gc=blue] { color: #1F4E79; border-color: #7FA6C9 } .tblock.sheet .tgroups .chip[data-gc=red] { color: #A33B32; border-color: #D69A94 }
.tblock.sheet .tgroups .chip[data-gc=orange] { color: #B5581C; border-color: #E0A679 } .tblock.sheet .tgroups .chip[data-gc=green] { color: #2F6B4F; border-color: #8CBBA3 }
@media (pointer: coarse) { .tblock.sheet .tgroups .chip { min-height: 44px } .tblock.sheet .tgrid .tbody .tr .tc { min-height: 34px } }
/* 🧭 ECO_FRONT: every section a tab (they wrap), an overview of tiles, one tab for rooming + room block + transfers */
.tabs.front { flex-wrap: wrap; overflow: visible; position: static; row-gap: 0 }
.tabs.front a { min-height: 40px; padding: 0 10px; font-size: .92rem }
@media (pointer: coarse) { .tabs.front a { min-height: var(--tap) } }
.fgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; margin: 4px 0 16px }
.ftile { display: flex; align-items: center; gap: 12px; min-height: 76px; padding: 12px 16px; border: 1px solid var(--line); border-radius: var(--r); background: var(--card); color: var(--ink); text-decoration: none }
.ftile:hover { border-color: var(--brand) }
.ftile .fic { flex: none; font-size: 1.9rem; line-height: 1 }
.ftile .ftx { min-width: 0 }
.ftile b { display: block; font-size: 1.18rem; line-height: 1.2 }
.ftile.hastable { border-left: 4px solid var(--brand) }
.ftile .flink { color: var(--ink); opacity: .8 }
.fnav { margin: 0 0 12px }
.fnav > summary { display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--soft); color: var(--ink); font-weight: 600; cursor: pointer; list-style: none }
.fnav > summary::-webkit-details-marker { display: none }
.fnav[open] > summary { margin-bottom: 8px }
.fnav .tabs.front { margin-bottom: 0 }
.ftile small { display: block; margin-top: 3px; color: var(--muted); font-size: .84rem; line-height: 1.3 }
.subtabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 12px }
.subtabs a { display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: var(--soft); color: var(--ink); font-weight: 600; text-decoration: none }
.subtabs a[aria-current="page"] { background: var(--brand); color: var(--brand-ink); border-color: var(--brand) }
.seccard { margin: 0 0 12px }
.seccard.slim { padding: 8px 12px }
.seccard .secb { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px }
.seccard.slim .secb { margin-top: 6px }
