/* Страница: schedule */

.schedule-tools{
  
  

  gap: 8px;
  padding: 0 0 16px;
  justify-content: flex-start;
  border-bottom: 1px solid var(--line);
}

.schedule-tools label{
  min-width: 150px;
  width: 150px;
  display: grid;
  gap: 4px;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 720;
}

.schedule-tools input[type="month"]{
  height: 40px;
  min-height: 40px;
  font-size: 15px;
  font-weight: 760;
}

.schedule-panel{
  overflow: hidden;
}

.schedule-scroll{
  position: relative;
  
  
  overflow: auto;
  
  cursor: default;
  touch-action: auto;
  user-select: auto;

  height: calc(100vh - 350px);
  min-height: 320px;
  border-radius: 10px;
  background: var(--paper);
  border: 1px solid var(--line);
  box-shadow: none;
}

.schedule-scroll.zoomed{
  cursor: grab;
}

.schedule-scroll.zoomed.dragging{
  cursor: grabbing;
}

.schedule-plane{
  position: relative;
  left: auto;
  top: auto;
  min-width: 100%;
  transform-origin: left top;
  transition: none;
  will-change: transform;
}

.schedule-table{
  width: 100%;
  min-width: 100%;
  table-layout: fixed;
  border-collapse: separate;
  
  

  border-spacing: 2px;
  font-size: 11px;
}

.schedule-col-day{
  width: 32px;
}

.schedule-col-total{
  width: 42px;
}

.schedule-table th.day-head b,.schedule-table th.day-head span{
  display: block;
  line-height: 1.08;
}

.schedule-table th.day-head b{
  margin-bottom: 3px;
}

.schedule-table th.day-head em{
  display: none;
}

.schedule-table td.cal-work{
  

  background: transparent;
}

.schedule-table td.cal-off{
  

  background: color-mix(in srgb,var(--weekend) 30%,transparent);
}

.schedule-table td.cal-short{
  

  background: rgba(240,180,41,.12);
}

.schedule-table td.today{
  
  

  outline: 2px solid rgba(240,180,41,.78);
  outline-offset: -1px;
  border-radius: 5px;
}

.sched-cell{
  width: 100%;
  min-width: 0;
  
  padding: 0;
  
  
  color: #fff;
  
  
  box-shadow: none;

  height: 28px;
  min-height: 28px;
  border: 1px solid transparent;
  border-radius: 5px;
  font-size: 10px;
  font-weight: 600;
  transition: box-shadow .12s;
}

.code-Н,.status-Н,.sched-cell.code-Н{
  background: #8a9099;
  color: #fff;
}

.schedule-legend{
  display: flex;
  flex-wrap: wrap;
  
  align-items: center;
  

  margin: 14px 0;
  gap: 6px;
}

.schedule-legend span{
  
  
  
  

  font-size: 11px;
  font-weight: 500;
  padding: 4px 7px;
  border-radius: 6px;
}

.print-preview.print-landscape,.print-preview.schedule-print-preview{
  padding: 0;
}

.schedule-official-header,.official-approval{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18mm;
  margin-bottom: 2mm;
  font-size: 8.5px;
  line-height: 1.15;
}

.schedule-print-sheet h1,.official-schedule-sheet h1{
  margin: 1mm 0 2.5mm;
  text-align: center;
  font-size: 11px;
  letter-spacing: .02em;
  color: #111;
}

.official-schedule-table .pnum{
  width: 8mm;
}

.official-schedule-table .pemp{
  width: 34mm;
  text-align: left;
  font-size: 7.4px;
  font-weight: 700;
}

.official-schedule-table .ppos{
  width: 23mm;
  text-align: left;
  font-size: 6.8px;
}

.official-schedule-table .phead th{
  font-weight: 700;
}

.schedule-print-toolbar{
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.schedule-table th{
  position: sticky;
  top: 0;
  z-index: 2;
  min-width: 0;
  
  
  
  

  border-radius: 6px;
  padding: 7px 2px;
  background: var(--surface-2);
  color: var(--text-2);
  font-weight: 600;
}

.schedule-table th.holiday{
  

  background: var(--weekend);
  color: var(--weekend-text);
}

.schedule-table th.workday{
  

  background: var(--surface-2);
}

.sched-cell.code-Р{
  

  background: #18b76b;
  color: #062519;
}

.sched-cell.code-В{
  

  background: #566d80;
  color: #fff;
}

.sched-cell.code-ОТ{
  

  background: #1687d9;
  color: #001423;
}

.sched-cell.code-Б{
  
  

  background: #f0b429;
  color: #241800;
}

.sched-cell.code-Н{
  background: #8a9099;
  color: #fff;
}

.schedule-print-sheet.official-schedule-sheet{
  width: 287mm;
  min-height: 198mm;
  padding: 4mm 5mm;
  color: #111;
  background: #fff;
  overflow: hidden;
  font-family: "Times New Roman",Times,serif;
}

.schedule-official-header{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 36mm;
  margin: 0 0 2mm;
  font-size: 8.4px;
  line-height: 1.12;
  color: #111;
}

.schedule-official-header .approve{
  display: block;
  color: #111;
}

.schedule-official-header .approve b{
  display: block;
  margin-bottom: .6mm;
}

.schedule-official-header .approve span{
  display: block;
}

.schedule-official-header .approve.right{
  text-align: left;
  justify-self: end;
  width: 58mm;
}

.schedule-official-header .approve.left{
  width: 62mm;
}

.official-schedule-sheet h1{
  margin: 1mm 0 2mm;
  text-align: center;
  font-size: 10.8px;
  letter-spacing: .01em;
  color: #111;
}

.official-schedule-table{
  height: 174mm;
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 7.2px;
  line-height: 1.03;
  color: #111;
  background: #fff;
}

.official-schedule-table th,.official-schedule-table td{
  border: 1px solid #111;
  padding: .35mm .25mm;
  color: #111;
  background: #fff;
  text-align: center;
  vertical-align: middle;
}

.official-schedule-table col.pnum-col{
  width: 7mm;
}

.official-schedule-table col.pemp-col{
  width: 30mm;
}

.official-schedule-table col.ppos-col{
  width: 24mm;
}

.official-schedule-table col.pday-col{
  width: auto;
}

.official-schedule-table .pemp,.official-schedule-table .pemp-head{
  width: 30mm;
  text-align: left;
  padding-left: 1.2mm;
  font-size: 8.6px;
  font-weight: 800;
  white-space: nowrap;
}

.official-schedule-table .pemp b{
  font-size: 8.8px;
  font-weight: 900;
}

.official-schedule-table .ppos,.official-schedule-table .ppos-head{
  width: 24mm;
  text-align: center;
  font-size: 8.0px;
  font-weight: 800;
}

.official-schedule-table .pnum,.official-schedule-table .pnum-head{
  width: 7mm;
}

.official-schedule-table .phead th,.official-schedule-table .pweek th{
  height: 5.2mm;
  font-weight: 800;
  font-size: 7.4px;
}

.official-schedule-table .pdate b{
  font-size: 8.4px;
}

.official-schedule-table .pshift td{
  letter-spacing: .02em;
  background: #fff;
  color: #111;
  text-align: left;
  padding-left: 1mm;
  font-weight: 800;
  font-size: 7.4px;
  border-top: 1.4px solid #111;
  border-bottom: 1.4px solid #111;
}

.official-schedule-table th.pholiday{
  background: #e6e6e6;
  color: #8a0f24;
}

.official-schedule-table th.pshort{
  background: #f1f1f1;
}

.official-schedule-table .pwork,.official-schedule-table .prest,.official-schedule-table .pvac,.official-schedule-table .psick,.official-schedule-table .pabsence{
  background: #fff;
  color: #111;
  font-weight: 900;
  font-size: 10px;
  line-height: 1;
}


/* 10.3.2 — аккуратный выбор месяца: без слипающихся рамок и пёстрой синей ленты */
.month-picker-head{
  display:grid;
  grid-template-columns:42px minmax(90px,1fr) 42px;
  align-items:center;
  gap:12px;
  

  margin-bottom: 20px;
}
.month-picker-head b{
  text-align:center;
  font-size:18px;
  font-weight:700;
}
.month-picker-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(118px,1fr));
  gap:12px;
  align-items:stretch;
}
.month-picker-grid .month-pick{
  width:100%;
  min-width:0;
  
  margin:0;
  border:1px solid var(--line);
  border-radius:var(--radius-md);
  
  color:var(--text-2);
  box-shadow:none;
  

  background: var(--surface-2);
  border-color: var(--line);
  min-height: 42px;
  font-weight: 500;
}
.month-picker-grid .month-pick:hover{
  border-color:var(--line-strong);
  background:var(--surface-3);
  color:var(--text);
}
.month-picker-grid .month-pick.active{
  border-color:color-mix(in srgb,var(--primary) 72%,white 28%);
  background:color-mix(in srgb,var(--primary) 42%,var(--surface-2) 58%);
  color:#fff;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.08);
}
body.light .month-picker-grid .month-pick{
  background:#f1f5f8;
  border-color:#c7d3dd;
  color:#24384b;
}
body.light .month-picker-grid .month-pick:hover{
  background:#e7eff5;
  border-color:#96afc2;
}
body.light .month-picker-grid .month-pick.active{
  background:#d7e7f4;
  border-color:#4e82a8;
  color:#12344d;
}
@media(max-width:760px){
  .month-picker-grid{grid-template-columns:repeat(2,minmax(0,1fr));}
}

.schedule-tools .zoom-readout {display:grid;align-items:center;margin-left:0;min-width:44px}
.schedule-panel .seg-row {margin:16px 0 12px;gap:6px}
.schedule-panel .shift-row {gap:6px}
.schedule-panel #absenceHelp {margin-left:auto;font-size:11px}
.schedule-table .emp-cell b {font-size:10px;font-weight:600;line-height:1.4}
.schedule-table th.sticky-col {z-index:5;border-radius:6px 0 0 0;font-size:10px}
.schedule-table th.today {box-shadow:inset 0 3px 0 var(--warn)}
.schedule-table .sched-cell:hover {box-shadow:inset 0 0 0 2px var(--text)}
.schedule-table .sched-cell:focus-visible {outline:2px solid var(--text);outline-offset:0}
.code-sample.code-Р {color:#062519}.code-sample.code-В {color:#fff}.code-sample.code-ОТ {color:#001423}.code-sample.code-Б {color:#241800}
.schedule-legend .muted {font-size:10px;margin-left:auto}
.modal-card:has(.month-picker-grid) {width:min(640px,92vw)}
@media(max-width:1366px){.schedule-scroll{height:calc(100vh - 320px)}.schedule-panel .seg-row{margin-top:12px}.schedule-legend{margin:10px 0}.schedule-tools{padding-bottom:12px}}
