:root{font-family:Inter,Arial,Helvetica,sans-serif;color:#183348;background:#f4f7fa;font-synthesis:none;--blue:#175b84;--blue2:#0e3d60;--border:#dce5ed;--muted:#758797;--shadow:0 8px 32px rgba(13,47,74,.06)}
*{box-sizing:border-box}body{margin:0;font-size:14px}button,input,select,textarea{font:inherit}button{cursor:pointer}button:disabled{opacity:.5;cursor:not-allowed}.hidden{display:none!important}
.topbar{min-height:72px;display:flex;justify-content:space-between;align-items:center;padding:13px max(26px,calc((100vw - 1680px)/2));background:#fff;border-bottom:1px solid var(--border)}.brand,.topbar-right{display:flex;align-items:center;gap:13px}.brandmark{height:41px;width:41px;background:linear-gradient(145deg,#226991,#092f51);border-radius:11px;display:grid;place-items:center;color:#fff;font-size:24px;font-weight:800}.brand-title{font-size:20px;font-weight:800;letter-spacing:-.5px}.brand-title span{font-size:11px;font-weight:600;background:#e9f2f9;color:#34729c;padding:4px 7px;border-radius:5px;margin-left:4px;vertical-align:middle}.brand-subtitle{font-size:11px;color:#7891a1;margin-top:2px}.local-tag{font-size:12px;color:#607f90;background:#f0f7f7;border-radius:9px;padding:9px 12px}.dot{display:inline-block;width:7px;height:7px;background:#23a785;border-radius:100%;margin-right:5px}
.container{max-width:1680px;margin:auto;padding:27px 26px 60px}.pageheading{display:flex;justify-content:space-between;align-items:center;gap:20px;margin-bottom:23px}.eyebrow{color:#3784a7;letter-spacing:1.8px;font-size:10px;font-weight:800;margin:0 0 7px}h1{font-size:29px;margin:0;letter-spacing:-1.1px;color:#183951}h2{font-size:16px;margin:0;color:#173d59}.subtext{color:#708599;margin:10px 0 0;font-size:13px;line-height:1.5}.weeknav,.actionbar-group{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.weeknav{background:#fff;border:1px solid var(--border);padding:6px;border-radius:12px}.weeknav input{width:145px;padding:8px 5px;border:0;color:#234b67;background:transparent;font-size:13px;outline:none}.navarrow{border:0;background:#eff4f8;border-radius:7px;color:#1d5d88;font-size:22px;line-height:1;width:34px;height:34px}.navarrow:hover{background:#dcebf6}.btn{border:1px solid transparent;border-radius:8px;padding:10px 13px;background:#fff;color:#234763;font-size:12px;font-weight:700;white-space:nowrap;display:inline-flex;justify-content:center;align-items:center;gap:7px;min-height:36px;transition:background .15s,border .15s}.btn:hover{filter:brightness(.96)}.btn-primary{background:#195f88;color:#fff}.btn-outline{border-color:#d8e2eb;background:#fff}.btn-ghost{background:transparent;color:#5a7890}.btn-sm{padding:7px 10px}.actionbar{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin-bottom:18px}.status-pill{font-size:11px;border-radius:30px;padding:7px 11px;font-weight:700;white-space:nowrap}.status-draft{background:#f3f2e9;color:#80672d}.status-approved{background:#e2f5e9;color:#158353}.dropdown-holder{position:relative}.dropdown{position:absolute;right:0;top:calc(100% + 6px);background:#fff;border:1px solid var(--border);box-shadow:0 12px 35px #173d5920;border-radius:10px;min-width:230px;padding:5px;z-index:10}.dropdown button{background:none;border:0;padding:12px 13px;text-align:left;width:100%;color:#24445d;font-size:12px;border-radius:6px}.dropdown button:hover{background:#eef5fa}
.stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:13px;margin-bottom:17px}.stat{background:#fff;border:1px solid var(--border);padding:16px 18px;border-radius:11px;display:flex;align-items:center;justify-content:space-between;gap:8px}.stat .kicker{color:#8293a1;font-size:11px;margin-bottom:5px}.stat .number{font-size:25px;color:#1e455e;font-weight:800;letter-spacing:-.8px}.stat .number small{font-size:12px;font-weight:600;color:#73909b}.stat .glyph{font-size:23px;width:42px;height:42px;display:grid;place-items:center;border-radius:10px;background:#eaf2f7;color:#326a91}.stat.warn .glyph{background:#fff0e8;color:#db7536}.stat.danger .glyph{background:#ffebeb;color:#ca4a47}
.mainlayout{display:grid;grid-template-columns:minmax(0,1fr) 305px;gap:17px;align-items:start}.sheet-card,.side-card{border:1px solid var(--border);background:#fff;border-radius:12px;box-shadow:var(--shadow);overflow:hidden}.sheet-top{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:17px 18px 15px}.sheet-top p{font-size:12px;color:#8392a0;margin:6px 0 0}.sheet-tools{display:flex;align-items:center;gap:8px;font-size:11px;color:#8192a0}.sheet-tools select,.field-group select{background:#fff;border:1px solid #d8e3eb;border-radius:7px;padding:9px 10px;font-size:12px;color:#315169;outline-color:#2879a0}
.sheet-scroll{width:100%;overflow-x:auto;max-height:none;overflow-y:visible;scrollbar-color:#cbd8e1 #fff}.dept-section{min-width:880px;margin:0 12px 10px}.sheet-grid{display:grid;grid-template-columns:176px repeat(7,minmax(0,1fr));border-left:1px solid #d5e1e9;border-top:1px solid #d5e1e9}.grid-top{padding:10px 5px;text-align:center;background:#155b85;color:#fff;border-right:1px solid #ffffff42;border-bottom:1px solid #d5e1e9;min-height:56px}.grid-top span{font-weight:800;font-size:10px;letter-spacing:.4px;display:block}.grid-top small{font-weight:600;font-size:11px;display:block;margin-top:5px;color:#cfe6f5}.grid-top.sunday{background:#104568}.grid-name,.cell{border-bottom:1px solid #e0e7ec;border-right:1px solid #e0e7ec;min-height:55px;display:flex;align-items:center}.grid-name{position:sticky;left:0;z-index:2;background:#f7f9fb;padding:8px 10px;font-weight:700;font-size:12px;box-shadow:3px 0 5px #18395106}.grid-name small{display:block;font-size:10px;font-weight:500;color:#98a5b0;margin-top:4px}.cell{cursor:pointer;position:relative;padding:4px 3px;flex-direction:column;justify-content:center;gap:2px;background:#fff;text-align:center;transition:outline .07s,background .1s;border-radius:0}.cell:hover{outline:2px solid #4c98b8;outline-offset:-2px;z-index:1}.cell:focus-visible{outline:3px solid #2e9cc6;outline-offset:-3px;z-index:3}.cell.selected{outline:2px solid #1270a0;outline-offset:-2px;z-index:1}.cell .mainshift{font-size:11px;font-weight:800;white-space:nowrap}.cell .secondaryshift{font-size:10px;font-weight:700}.cell .tiny{font-size:9px;color:#6e7883;line-height:1.1}.cell.off{background:#fafbfc;color:#98a4ae}.cell.empty{background:repeating-linear-gradient(135deg,#fff,#fff 10px,#f9fbfc 10px,#f9fbfc 20px);color:#bac7d0}.cell.early{background:#fff0ce;color:#725110}.cell.morning{background:#f5f9fb;color:#27516b}.cell.afternoon{background:#ddf2df;color:#235c3e}.cell.night{background:#f8dbd8;color:#943e3c}.cell.unavailable{background:#f2e9fb;color:#754f8a}.cell.conflict{box-shadow:inset 0 0 0 2px #d43e46}.cell .attention{position:absolute;right:3px;top:2px;font-size:11px;color:#c83e40}.empty-label{font-size:10px;color:#acbdc7;font-weight:700}.dept-bar{display:flex;justify-content:space-between;align-items:center;background:#eaf2f7;color:#144c70;border-left:4px solid #205b84;font-weight:800;padding:8px 13px;font-size:12px;letter-spacing:.4px}.dept-bar small{color:#557a92;font-size:10px;font-weight:500;letter-spacing:0}.dept-bar[data-dept="sprzatanie"]{border-left-color:#13818b;background:#e9f4f4}.dept-bar[data-dept="restauracja"]{border-left-color:#b88340;background:#f7f0e3}
.sheet-foot{border-top:1px solid #e9eef2;padding:13px 16px;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:7px}.sheet-foot p{font-size:10px;color:#a3aeb7;margin:0}.legend{display:flex;flex-wrap:wrap;gap:12px;font-size:10px;color:#748792}.legend span{display:flex;align-items:center;gap:5px}.swatch{height:9px;width:9px;border-radius:2px;display:inline-block;border:1px solid #ddd}.swatch.early{background:#ffe3a7}.swatch.morning{background:#f5f9fb}.swatch.afternoon{background:#c8eaca}.swatch.night{background:#f3b8b4}.swatch.unavailable{background:#e2d0f2}kbd{font-size:10px;border:1px solid #cad6df;background:#f6f9fa;border-radius:3px;padding:2px 3px}.notes-section{background:#fafcfd;padding:17px 18px 20px;border-top:1px solid #ecf0f3}.notes-section label{display:flex;justify-content:space-between;gap:6px;font-size:12px;margin-bottom:10px}.notes-section label span{font-size:10px;color:#8495a2}.notes-section textarea{width:100%;resize:vertical;border:1px solid #d8e3e9;border-radius:8px;padding:10px 12px;color:#27495e;min-height:69px;outline-color:#3a89aa;background:#fff;line-height:1.5}
.side-header{padding:19px 16px 14px;display:flex;justify-content:space-between;align-items:center}.side-label{font-size:10px;background:#ecf5f4;color:#458b7c;padding:5px 7px;border-radius:20px}.tabs{display:flex;border-top:1px solid #ebf0f3;border-bottom:1px solid #e5edf2;padding:0 8px;gap:1px}.tab{flex:1;border:0;background:transparent;font-size:11px;font-weight:700;padding:13px 2px;color:#8294a2;border-bottom:2px solid transparent}.tab.active{color:#17658b;border-bottom-color:#17658b}.side-content{padding:17px 15px;min-height:250px}.panel-intro{font-size:12px;line-height:1.55;color:#6b8799;margin:0 0 14px}.panel-strong{font-weight:800;font-size:12px;color:#31566f;margin-bottom:7px}.health-row{border:1px solid #e2e9ee;padding:12px 11px;border-radius:9px;margin-bottom:9px;background:#fff}.health-row.warning{background:#fff8f4;border-color:#f5dec7}.health-row .row-title{font-size:11px;font-weight:800;color:#324f65;display:flex;justify-content:space-between;gap:5px}.health-row .row-sub{font-size:11px;color:#8e7c75;margin-top:5px}.okline{padding:14px 12px;background:#eaf8f1;border:1px solid #cceadb;border-radius:9px;color:#27754f;font-weight:700;font-size:12px;line-height:1.5}.note-line{margin-top:11px;font-size:11px;color:#8b9da9;line-height:1.5}.small-link{font-size:11px;color:#23729d;text-decoration:underline;background:none;border:0;padding:0}.hourrow{margin:0 0 14px}.hourrow-top{display:flex;justify-content:space-between;gap:5px;font-size:11px;color:#476579;margin-bottom:5px}.hourrow-top strong{color:#2a4f69}.hourbar{background:#eaf0f4;border-radius:8px;height:7px;overflow:hidden}.hourbar i{background:#4e9abb;height:100%;display:block;border-radius:8px}.hour-filter{width:100%;padding:9px 10px;border:1px solid #dce6ec;color:#41627b;border-radius:8px;background:#fff;margin-bottom:12px}.bottom-note{text-align:center;color:#9baab5;font-size:11px;margin-top:22px}
.overlay{position:fixed;inset:0;background:rgba(12,36,53,.48);z-index:40;display:flex;justify-content:flex-end;animation:fadein .13s ease-out}.drawer{height:100%;width:min(480px,100vw);display:flex;flex-direction:column;background:#fff;box-shadow:-12px 0 35px #0a1e3050;animation:slidein .18s ease-out}.drawer-head{padding:24px;border-bottom:1px solid #e5edf2;display:flex;justify-content:space-between;gap:12px}.drawer-head h2{font-size:21px;letter-spacing:-.5px}.drawer-date{color:#7893a6;margin:6px 0 0;font-size:12px}.icon-btn{border:0;background:#eef3f6;color:#315f7e;width:32px;height:32px;font-size:24px;border-radius:9px;line-height:1}.drawer-body{padding:21px 24px;overflow:auto;flex:1}.field-group{margin-bottom:22px}.field-label{display:block;font-size:12px;font-weight:800;color:#284860;margin-bottom:11px}.presets,.quickother{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.choice{border:1px solid #dbe5eb;border-radius:8px;background:#f8fafb;text-align:center;padding:12px 8px;font-size:12px;font-weight:700;color:#335e7a}.choice:hover{border-color:#6caccb;background:#eaf6fc}.quickother{margin-top:7px}.choice-muted{color:#8c979f}.muted-hint{color:#8a9dab;font-size:11px;line-height:1.6;margin:10px 0 0}.separator{height:1px;background:#e7eff3;margin:21px 0}.sectionline{display:flex;justify-content:space-between;align-items:baseline;gap:8px}.link-btn{border:0;background:transparent;color:#1677a3;font-size:11px;font-weight:800;padding:0}.shift-row{border:1px solid #e4ebef;background:#fbfcfd;border-radius:10px;margin-bottom:9px;padding:12px}.shift-row .shift-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:9px;color:#748b9e;font-size:11px;font-weight:800}.shift-row .row-inputs{display:grid;grid-template-columns:1fr 1fr;gap:8px}.shift-row input,.shift-row select{padding:9px 8px;width:100%;border:1px solid #d8e3eb;background:white;border-radius:7px;color:#27516c;font-size:12px}.shift-row .shift-heading button{border:0;background:none;font-size:11px;color:#b36664}.shift-row select{margin-top:9px}.field-group>select,.field-group>textarea{width:100%;background:white;border:1px solid #dbe6ed;border-radius:8px;color:#31556d;padding:10px;font-size:12px;resize:vertical}.drawer-footer{padding:17px 24px;border-top:1px solid #e9eff3;display:flex;gap:9px;justify-content:flex-end;background:white}.help-dialog{width:min(540px,calc(100vw - 24px));background:white;border-radius:15px;max-height:min(700px,90vh);margin:auto;display:flex;flex-direction:column;box-shadow:0 18px 60px #10263860}.help-body{padding:18px 25px;overflow:auto;font-size:13px;line-height:1.7;color:#506d81}.help-body p{margin:0 0 14px}.help-body code{font-size:12px;color:#1d6289}.toast{position:fixed;right:22px;bottom:22px;z-index:80;background:#1c4765;color:white;padding:13px 19px;border-radius:9px;box-shadow:0 10px 24px #1c476533;font-size:12px;max-width:380px;line-height:1.5}@keyframes fadein{from{opacity:0}to{opacity:1}}@keyframes slidein{from{transform:translateX(20px)}to{transform:translateX(0)}}
@media(max-width:1200px){.mainlayout{grid-template-columns:minmax(0,1fr) 275px}.container{padding:20px 16px 45px}.sheet-grid{grid-template-columns:150px repeat(7,minmax(0,1fr))}.dept-section{min-width:840px}}@media(max-width:980px){.mainlayout{grid-template-columns:1fr}.side-card{order:2}.side-content{min-height:100px}.topbar{padding:10px 15px}.pageheading{align-items:flex-start;flex-direction:column}.stats{grid-template-columns:repeat(2,minmax(0,1fr))}.actions-secondary{width:100%}.actionbar{align-items:start}.sheet-scroll{max-height:none}.sheet-foot{flex-direction:column;align-items:start}}@media(max-width:600px){.container{padding:17px 10px 32px}h1{font-size:24px}.topbar-right .local-tag{display:none}.pageheading{margin-bottom:15px}.actionbar-group{gap:6px}.btn{padding:10px 9px;font-size:11px}.stats{gap:8px}.stat{padding:10px}.stat .number{font-size:22px}.stat .glyph{height:32px;width:32px;font-size:17px}.sheet-top{padding:15px 12px}.sheet-top{flex-direction:column;align-items:start}.dept-section{margin:0 8px 9px}.sheet-scroll{max-height:none}.drawer-body{padding:15px 18px}.drawer-head{padding:20px 18px}.weeknav{max-width:100%}}
@page{size:A4 landscape;margin:8mm}
@media print{html,body{background:white!important;font-size:10pt;print-color-adjust:exact;-webkit-print-color-adjust:exact}.topbar,.pageheading,.actionbar,.stats,.side-card,.sheet-top,.sheet-foot,.bottom-note,.weeknav,.drawer,.overlay,.toast{display:none!important}.container{max-width:none;padding:0}.mainlayout{display:block}.sheet-card{border:0;box-shadow:none;border-radius:0;overflow:visible}.sheet-scroll{max-height:none;overflow:visible}.dept-section{min-width:0;margin:0 0 8px}.sheet-grid{grid-template-columns:172px repeat(7,minmax(0,1fr));border-color:#546271}.grid-top{padding:6px 1px;min-height:32px}.grid-top span{font-size:9px}.grid-top small{font-size:9px}.grid-name,.cell{min-height:32px;border-color:#8a9aa4}.grid-name{font-size:10px;padding:5px}.grid-name small{display:none}.cell .mainshift{font-size:9px}.cell .secondaryshift,.cell .tiny{font-size:8px}.dept-bar{padding:5px 8px;margin-top:7px}.notes-section{padding:6px 3px;border:0;background:white}.notes-section label{font-size:11px}.notes-section label span{display:none}.notes-section textarea{padding:2px 4px;border:0;resize:none;min-height:0;font-size:10px;overflow:hidden}.dept-section{break-inside:avoid;page-break-inside:avoid}#scheduleGrid:before{content:'GRAFIK PRACY — ' attr(data-print-title);display:block;font-size:18px;font-weight:800;color:#173c5b;margin:0 0 12px}}

.mobile-scroll-tip{display:none;text-align:center;padding:0 10px;margin:0 0 12px;color:#427e9c;font-size:11px;font-weight:700}@media(max-width:980px){.mobile-scroll-tip{display:block}}@media print{.mobile-scroll-tip{display:none!important}.grid-name,.cell{min-height:27px}.grid-top{min-height:29px;padding:3px 1px}.dept-bar{padding:4px 8px;margin-top:4px}.dept-section{margin-bottom:3px}.notes-section{padding-top:2px;padding-bottom:2px}}

.hours-group{border-bottom:1px solid #e6edf1;padding-bottom:8px;margin-bottom:16px}.hours-group:last-of-type{border-bottom:0}.average-text{float:right;font-size:10px;color:#8595a2;font-weight:500}.hourrow-top small{font-size:9px;color:#92a2ae;margin-left:3px;font-weight:500}

/* ============================================================
   GRAFIK v1.0.1 — uproszczona tabela na pełną szerokość
   Jedna linia z datami, wąskie wiersze i oś 00:00–24:00
   ============================================================ */
.topbar{min-height:57px;padding:8px 20px}
.brandmark{height:35px;width:35px;font-size:20px;border-radius:9px}
.brand-title{font-size:18px}
.container{max-width:none;width:100%;margin:0;padding:20px 20px 38px}
.pageheading{margin-bottom:13px}
.pageheading h1{font-size:25px}
.pageheading .subtext{font-size:12px;margin-top:6px}
.actionbar{margin-bottom:11px;gap:8px}
.btn{min-height:33px;padding:8px 11px}
.sheet-card{border-radius:10px}
.sheet-top{padding:10px 13px;min-height:50px}
.sheet-top h2{font-size:14px}
.sheet-top p{margin:2px 0 0;font-size:11px}
.sheet-tools select{padding:6px 9px}
/* Przewijamy jedną tabelę, zachowując wspólny nagłówek u góry. */
.sheet-scroll{max-height:calc(100vh - 235px);min-height:0;overflow:auto;scrollbar-color:#cbd8e1 #f5f9fb}
.sheet-grid{
  min-width:1050px;width:100%;display:grid;
  grid-template-columns:minmax(178px,1.35fr) repeat(7,minmax(105px,1fr)) minmax(75px,.55fr);
  border-top:1px solid #d4e1e9;border-left:1px solid #d4e1e9;
}
.grid-top{position:sticky;top:0;z-index:5;padding:6px 3px;min-height:45px;display:flex;flex-direction:column;justify-content:center}
.grid-top span{font-size:10px;line-height:1.2;letter-spacing:.25px}
.grid-top small{font-size:10px;margin-top:3px}
.grid-top-name{z-index:8;left:0;text-align:left;padding-left:12px}
.grid-top-total{z-index:6}
.dept-bar{grid-column:1/-1;min-height:25px;margin:0;padding:5px 10px;font-size:11px;border-right:1px solid #d4e1e9;letter-spacing:.25px}
.dept-bar small{display:none}
.grid-name,.cell,.grid-total{height:39px;min-height:39px;border-right:1px solid #d7e1e8;border-bottom:1px solid #d7e1e8}
.grid-name{z-index:2;left:0;position:sticky;padding:5px 10px;font-size:11.5px;font-weight:700;background:#f7f9fb;white-space:nowrap}
.cell{padding:3px 3px 6px;gap:1px;overflow:hidden}
.cell .mainshift{font-size:11px;line-height:1.1}
.cell .secondaryshift{font-size:9px;line-height:1}
.cell .tiny{font-size:8px;line-height:1}
.cell .attention{top:1px;right:3px}
/* Pasek ma dokładnie tę samą szerokość co doba w komórce.
   Odcinek 00:00–08:00 zajmuje 1/3 od lewej,
   a 22:00–24:00 — 1/12 od prawej. */
.time-track{position:absolute;bottom:0;left:0;right:0;height:4px;overflow:hidden;pointer-events:none}
.time-fill{position:absolute;top:0;bottom:0;display:block;min-width:0}
.time-fill.morning{background:#4387b5}
.time-fill.early{background:#c49a44}
.time-fill.afternoon{background:#4ba56b}
.time-fill.night{background:#ce655d}
.time-fill.continuation{opacity:.87}
.grid-total{display:flex;justify-content:center;align-items:center;background:#eef4f8;color:#194d70;font-weight:800;font-size:12px;white-space:nowrap}
.grid-total span{font-size:10px;margin-left:3px;font-weight:600;color:#688599}
.sheet-foot{padding:9px 12px}
.notes-section{padding:10px 13px 12px}
.notes-section label{margin-bottom:6px}
.notes-section textarea{min-height:54px;padding:8px 10px}
.bottom-note{margin-top:13px}
.analysis-overlay{justify-content:center;align-items:center}
.analysis-dialog{width:min(580px,calc(100vw - 24px));max-height:min(800px,92vh)}
.analysis-dialog .side-content{overflow-y:auto;min-height:0}
.analysis-dialog .tabs{padding:0 18px}
@media(max-width:980px){
 .container{padding:14px 10px 28px}
 .sheet-scroll{max-height:calc(100vh - 240px)}
 .sheet-grid{min-width:1000px;grid-template-columns:165px repeat(7,minmax(106px,1fr)) 80px}
 .grid-top-name{padding-left:9px}
 .sheet-top{padding:10px}
 .mobile-scroll-tip{margin:4px 0 7px;font-size:10px}
}
@media(max-width:600px){
 .topbar{padding:8px 10px}
 .pageheading h1{font-size:22px}
 .pageheading .subtext{line-height:1.35}
 .sheet-scroll{max-height:calc(100vh - 295px)}
 .grid-name,.cell,.grid-total{height:40px;min-height:40px}
 .sheet-grid{min-width:1020px}
 .sheet-foot p{display:none}
 .weeknav{flex-wrap:nowrap}
}
@media print{
 @page{size:A4 landscape;margin:8mm}
 html,body{print-color-adjust:exact;-webkit-print-color-adjust:exact}
 .container{width:100%;padding:0;margin:0}
 .topbar,.pageheading,.actionbar,.sheet-top,.sheet-foot,.bottom-note,.overlay,.toast,.mobile-scroll-tip{display:none!important}
 .sheet-card{box-shadow:none;border:0;overflow:visible}
 .sheet-scroll{overflow:visible!important;max-height:none!important}
 .sheet-grid{min-width:0!important;width:100%;grid-template-columns:21% repeat(7,minmax(0,1fr)) 7%!important;}
 .grid-top{position:static;min-height:30px;padding:3px 0;z-index:auto}
 .grid-top span{font-size:8px}
 .grid-top small{font-size:8px;margin-top:2px}
 .grid-name{position:static;font-size:9px;padding:3px 5px}
 .grid-name,.cell,.grid-total{height:27px!important;min-height:27px!important;box-shadow:none}
 .grid-total{font-size:10px}
 .cell{padding:2px 1px 5px}
 .cell .mainshift{font-size:8.6px}
 .cell .secondaryshift{font-size:7px}
 .cell .tiny{font-size:6px}
 .dept-bar{grid-column:1/-1;min-height:18px;padding:2px 7px;font-size:9px;break-after:avoid}
 .time-track{height:3px}
 .notes-section{padding:7px 0 0;border:0;background:#fff;break-inside:avoid}
 .notes-section textarea{font-size:9px;min-height:20px}
 #scheduleGrid:before{content:'GRAFIK PRACY — ' attr(data-print-title);font-size:15px;margin-bottom:8px}
}

/* ============================================================
   GRAFIK v1.0.2 — panel edycji obok grafiku i ustawienia
   ============================================================ */
.topbar{position:relative;z-index:35}
.topbar-right{gap:10px}
.settings-trigger{width:35px;height:35px;border:1px solid #d5e2e9;background:#f8fafc;color:#235777;border-radius:9px;display:inline-flex;align-items:center;justify-content:center;transition:background .14s}
.settings-trigger:hover{background:#e7f2fa}
.container{transition:width .16s ease, margin-right .16s ease}
body.editor-open .container{width:calc(100% - 380px);margin-right:380px;margin-left:0}
.editor-dock{position:fixed;right:0;top:57px;bottom:0;width:380px;z-index:32;background:white;box-shadow:-6px 0 22px rgba(12,40,60,.12);border-left:1px solid #d9e5ed}
.editor-dock .drawer{width:100%;height:100%;box-shadow:none;animation:slidein .12s ease-out}
.editor-dock .drawer-head{padding:17px 18px 15px}
.editor-dock .drawer-head h2{font-size:19px}
.editor-dock .drawer-body{padding:17px 18px}
.editor-dock .drawer-footer{padding:12px 18px}
.editor-dock .field-group{margin-bottom:17px}
.editor-dock .separator{margin:14px 0}
.editor-dock .choice{padding:10px 7px}
.editor-dock .muted-hint{font-size:10px}
.editor-dock .field-label{margin-bottom:8px}
.editor-dock .shift-row{padding:9px}
body.editor-open .pageheading{gap:8px}
body.editor-open .pageheading h1{font-size:22px}
body.editor-open .pageheading .subtext{font-size:11px}
body.editor-open .weeknav{padding:4px}
body.editor-open .weeknav input{width:120px}
body.editor-open .btn{padding:7px 9px;font-size:11px}
body.editor-open .sheet-grid{min-width:880px;grid-template-columns:minmax(145px,1.32fr) repeat(7,minmax(91px,1fr)) minmax(62px,.57fr)}
body.editor-open .grid-name{padding-left:7px;padding-right:4px;font-size:10.5px}
body.editor-open .grid-top span{font-size:9px}
body.editor-open .grid-top small{font-size:9px}
body.editor-open .cell .mainshift{font-size:10px}
.cell.selected{outline:2px solid #117ead;outline-offset:-2px;box-shadow:inset 0 0 0 1px #117ead22;z-index:1}
.cell.selected:hover{outline-color:#076ea1}
.cell:focus-visible{outline:3px solid #0a80b7;z-index:3}
/* Ustawienia w osobnym oknie: na co dzień interfejs pozostaje maksymalnie prosty. */
.settings-overlay{align-items:center;justify-content:center;z-index:55;padding:18px}
.settings-dialog{background:white;border:1px solid #d8e4ec;border-radius:13px;width:min(860px,100%);max-height:min(790px,94vh);display:flex;flex-direction:column;overflow:hidden;box-shadow:0 20px 70px #0a263b55}
.settings-dialog .drawer-head{padding:18px 22px}
.settings-dialog .drawer-head h2{font-size:21px}
.settings-tabs{display:flex;border-bottom:1px solid #dfe9ef;padding:0 22px;gap:12px;flex-shrink:0}
.settings-tab{border:0;border-bottom:3px solid transparent;background:none;color:#688195;padding:14px 10px;font-weight:750;font-size:12px}
.settings-tab.active{color:#14658e;border-bottom-color:#14658e}
.settings-content{padding:16px 22px;overflow-y:auto;min-height:130px;flex:1}
.settings-info{background:#f1f6f9;border:1px solid #dce9ef;color:#59768a;border-radius:8px;padding:11px 13px;font-size:11.5px;line-height:1.55;margin-bottom:14px}
.settings-section-title{background:#eaf2f7;border-left:3px solid #155e87;color:#225777;font-size:12px;font-weight:800;padding:8px 11px;margin:14px 0 5px;display:flex;justify-content:space-between}
.settings-section-title span{font-weight:500;color:#748c9d}
.employee-settings-row{display:grid;grid-template-columns:minmax(140px,1.4fr) minmax(120px,1.1fr) 98px 64px;align-items:center;gap:8px;padding:5px 3px;border-bottom:1px solid #eef2f5}
.employee-settings-row.employee-hidden{opacity:.66}
.employee-settings-row input[type=text],.employee-settings-row select,.preset-settings-row input:not([type=color]){height:34px;width:100%;min-width:0;border:1px solid #d7e4ed;border-radius:6px;padding:6px 8px;font-size:12px;color:#234a66;background:white}
.visibility-toggle{display:flex;align-items:center;gap:5px;font-size:10.5px;color:#48677b;white-space:nowrap}
.visibility-toggle input{accent-color:#17668d}
.row-actions{display:flex;gap:5px}
.mini-btn{height:31px;min-width:29px;padding:0 5px;border:1px solid #d9e4ec;background:#fff;color:#376981;border-radius:6px;font-weight:750;font-size:15px}
.mini-btn:hover{background:#eaf4fa}
.mini-delete{font-size:19px;color:#a34f51}
.settings-add{margin-top:13px}
.preset-settings-head,.preset-settings-row{display:grid;grid-template-columns:minmax(140px,1.7fr) minmax(94px,1fr) minmax(94px,1fr) 62px 32px;align-items:center;gap:9px}
.preset-settings-head{font-size:10.5px;color:#7a8c9c;font-weight:750;padding:2px 4px 9px}
.preset-settings-row{padding:5px 3px;border-top:1px solid #ecf2f5}
.preset-settings-row input[type=color]{width:45px;height:33px;padding:3px;border:1px solid #d8e5ed;border-radius:7px;background:#fff;cursor:pointer}
.settings-footer{padding:14px 22px;border-top:1px solid #e6eef3;display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;background:#fff}
.settings-footer-right{display:flex;gap:8px}
@media(max-width:1400px){
 body.editor-open .container{width:calc(100% - 345px);margin-right:345px}
 .editor-dock{width:345px}
 body.editor-open .sheet-grid{min-width:865px}
 body.editor-open .pageheading{align-items:flex-start;flex-direction:column}
}
@media(max-width:1100px){
 body.editor-open .container{width:100%;margin-right:0}
 .editor-dock{top:auto;left:0;right:0;bottom:0;width:100%;height:min(73vh,660px);box-shadow:0 -10px 45px #0b2b4355;border-radius:14px 14px 0 0}
 .editor-dock .drawer{border-radius:14px 14px 0 0;overflow:hidden}
 body.editor-open .sheet-grid{min-width:1020px}
 .settings-dialog{max-height:95vh}
}
@media(max-width:620px){
 .settings-overlay{padding:6px}
 .settings-dialog{max-height:96vh}
 .settings-content{padding:12px 10px}
 .settings-dialog .drawer-head,.settings-footer{padding:12px 13px}
 .settings-tabs{padding:0 10px}
 .employee-settings-row{grid-template-columns:minmax(120px,1fr) minmax(110px,1fr);gap:6px}
 .employee-settings-row .visibility-toggle{padding-left:6px}
 .row-actions{justify-content:end}
 .preset-settings-head{display:none}
 .preset-settings-row{grid-template-columns:minmax(120px,1.5fr) minmax(80px,1fr) minmax(80px,1fr) 45px 29px;gap:3px}
 .preset-settings-row input:not([type=color]){font-size:10px;padding:5px 3px}
 .preset-settings-row input[type=color]{width:39px}
 .settings-footer{align-items:stretch}
 .settings-footer>#resetSettings{width:100%}
 .settings-footer-right{width:100%;justify-content:flex-end}
}
@media print{
 body.editor-open .container{margin:0!important;width:100%!important}
 .editor-dock,.settings-overlay,.settings-trigger{display:none!important}
 body.editor-open .sheet-grid{min-width:0!important;width:100%!important;grid-template-columns:21% repeat(7,minmax(0,1fr)) 7%!important}
}
