:root{
--bg:var(--tg-theme-secondary-bg-color,#F4F5F7);--card:var(--tg-theme-bg-color,#FFFFFF);
--text:var(--tg-theme-text-color,#14171F);--muted:var(--tg-theme-hint-color,#5B6270);
--link:var(--tg-theme-link-color,#1E47AE);--accent:var(--tg-theme-button-color,#1E3A8A);
--accent-text:var(--tg-theme-button-text-color,#FFFFFF);--line:rgba(127,135,150,.25);
--pub:#36A86B;--pub-bg:#E5F5EC;--pub-text:#17703F;--sch:#2D5FD3;--sch-bg:#E9EFFC;--sch-text:#1E47AE;
--amber:#E08A1E;--amber-bg:#FDF1E2;--amber-soft:#FFF8EF;--amber-text:#7A3A00;
--red:#D9534A;--red-bg:#FDECEA;--red-soft:#FFF5F4;--red-text:#8F1D14;--empty:#E6E9EE;
color-scheme:light}
@media (prefers-color-scheme:dark){:root:not([data-scheme=light]){--bg:var(--tg-theme-secondary-bg-color,#101318);--card:var(--tg-theme-bg-color,#1A1E25);
--text:var(--tg-theme-text-color,#ECEEF2);--muted:var(--tg-theme-hint-color,#A0A7B4);--link:var(--tg-theme-link-color,#8FB0FF);
--pub-bg:#16352A;--pub-text:#7FD6A4;--sch-bg:#1C2A4A;--sch-text:#A9C1FF;--amber-bg:#3A2A12;--amber-soft:#2A2116;--amber-text:#F5C27A;
--red-bg:#3D1C1A;--red-soft:#2C1A19;--red-text:#F4A69E;--empty:#2C323C;color-scheme:dark}}
:root[data-scheme=dark]{--bg:var(--tg-theme-secondary-bg-color,#101318);--card:var(--tg-theme-bg-color,#1A1E25);
--text:var(--tg-theme-text-color,#ECEEF2);--muted:var(--tg-theme-hint-color,#A0A7B4);--link:var(--tg-theme-link-color,#8FB0FF);
--pub-bg:#16352A;--pub-text:#7FD6A4;--sch-bg:#1C2A4A;--sch-text:#A9C1FF;--amber-bg:#3A2A12;--amber-soft:#2A2116;--amber-text:#F5C27A;
--red-bg:#3D1C1A;--red-soft:#2C1A19;--red-text:#F4A69E;--empty:#2C323C;color-scheme:dark}
*{box-sizing:border-box}
body{margin:0;background:var(--bg);color:var(--text);font:15px/1.4 Inter,system-ui,-apple-system,"Segoe UI",Roboto,sans-serif}
a{color:var(--link)}
button{font:inherit;color:inherit}
.page{max-width:1240px;margin:0 auto;padding:16px 16px 32px;display:flex;flex-direction:column;gap:14px}
.top{display:flex;align-items:center;justify-content:space-between;gap:12px}
h1{margin:0;font-size:22px;font-weight:700}
.muted{color:var(--muted);margin:2px 0 0;font-size:13px}
.small{font-size:12px}
.square{width:44px;height:44px;border:1px solid var(--line);border-radius:10px;background:var(--card);display:flex;align-items:center;justify-content:center;cursor:pointer}
.bar-row{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px}
.tabs{display:inline-flex;padding:4px;gap:4px;background:var(--empty);border-radius:10px}
.tabs button{min-height:38px;padding:0 14px;border:0;border-radius:8px;background:transparent;font-weight:600;cursor:pointer}
.tabs button[aria-pressed=true]{background:var(--card);box-shadow:0 1px 2px rgba(0,0,0,.08)}
.only{display:inline-flex;align-items:center;gap:8px;min-height:44px;font-size:14px;cursor:pointer}
.only input{width:20px;height:20px;margin:0;accent-color:var(--accent)}
.card{background:var(--card);border:1px solid var(--line);border-radius:14px;padding:16px}
.message{margin:0;padding:14px 16px;border-radius:12px;background:var(--amber-bg);color:var(--amber-text)}
.summary{display:flex;flex-wrap:wrap;gap:14px 32px;align-items:center}
.summary .main{flex:1 1 320px;min-width:0}
.summary .side{flex:1 1 280px;min-width:0;display:flex;flex-direction:column;gap:8px}
.big{font-size:26px;font-weight:700;margin-top:4px}
.big span{font-size:16px;font-weight:600;color:var(--muted)}
.meter{display:flex;gap:2px;height:12px;margin-top:12px}
.meter span{border-radius:4px;min-width:0}
.legend{display:flex;flex-wrap:wrap;gap:14px;margin-top:8px;font-size:13px;color:var(--muted)}
.legend i{display:inline-block;width:12px;height:10px;border-radius:3px;margin-right:6px;vertical-align:-1px}
.hatch{background:repeating-linear-gradient(135deg,#F3C58F 0 4px,var(--amber-bg) 4px 8px)}
.note{display:flex;gap:12px;align-items:baseline;padding:10px 12px;border-radius:10px;font-size:14px}
.note b{font-size:20px;min-width:24px}
.note.amber{background:var(--amber-bg);color:var(--amber-text)}
.note.red{background:var(--red-bg);color:var(--red-text)}
.cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:12px}
.group{display:flex;flex-direction:column;gap:8px}
.group.gap{border:2px solid var(--amber);padding:15px}
.group.lack{border:2px solid var(--red);padding:15px}
.group h2{margin:0;font-size:16px;font-weight:700;min-width:0;overflow-wrap:anywhere}
.ghead{display:flex;align-items:center;justify-content:space-between;gap:8px}
.badge{flex:none;padding:3px 10px;border-radius:999px;font-size:13px;font-weight:700;font-variant-numeric:tabular-nums}
.badge.ok{background:var(--pub-bg);color:var(--pub-text)}
.badge.gap{background:var(--amber-bg);color:var(--amber-text)}
.badge.lack{background:var(--red-bg);color:var(--red-text)}
.slot{display:flex;align-items:center;gap:10px;min-height:48px;padding:6px 10px;border-radius:8px;border:1px solid var(--line)}
.slot .dot{flex:none;width:26px;height:26px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:14px;font-weight:700}
.slot .what{flex:1 1 auto;min-width:0}
.slot .kind{font-size:12px;font-weight:600}
.slot .title{font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.slot.published .dot{background:var(--pub-bg);color:var(--pub-text)}.slot.published .kind{color:var(--pub-text)}
.slot.scheduled .dot{background:var(--sch-bg);color:var(--sch-text)}.slot.scheduled .kind{color:var(--sch-text)}
.slot.offer{border:1.5px dashed var(--amber);background:var(--amber-soft)}.slot.offer .dot{background:var(--amber-bg);color:var(--amber-text)}.slot.offer .kind{color:var(--amber-text)}
.slot.none{border:1.5px dashed var(--red);background:var(--red-soft)}.slot.none .dot{background:var(--red-bg);color:var(--red-text)}.slot.none .kind,.slot.none .title{color:var(--red-text)}
.gfoot{display:flex;align-items:center;justify-content:space-between;gap:10px;font-size:13px;color:var(--muted)}
.gfoot a{flex:none;font-weight:600}
.gfoot a.lack{color:var(--red-text)}
.week{overflow-x:auto}
.grid{display:grid;gap:6px;align-items:center;min-width:820px}
.grid .h{font-size:12px;font-weight:600;color:var(--muted);text-align:center}
.grid .h.today{color:var(--accent)}
.grid .name,.grid .h.first{position:sticky;left:0;z-index:1;background:var(--card);align-self:stretch;display:flex;align-items:center}
.grid .name{font-size:14px;font-weight:600;padding-right:6px}
.grid .num{text-align:right;font-variant-numeric:tabular-nums;font-size:14px}
.grid .num.take{color:var(--red-text);font-weight:700}
.cell{height:44px;border-radius:8px;padding:6px;display:flex;flex-direction:column;gap:3px;background:var(--amber-soft)}
.cell.full{background:var(--pub-bg)}
.cell .pair{display:flex;gap:3px;flex:1 1 auto}
.cell .pair span{flex:1 1 0;border-radius:4px}
.cell .pair .e{border:1.5px dashed var(--amber)}
.cell .lbl{font-size:11px;font-weight:600;text-align:center;font-variant-numeric:tabular-nums}
.cabinet{display:flex;align-items:center;justify-content:center;min-height:48px;border-radius:12px;background:var(--accent);color:var(--accent-text);font-weight:600;text-decoration:none}
[hidden]{display:none!important}
