/* Формы и таблицы обновлённых сервисов */
.rs .rs-field[hidden] { display: none; }
.rs > .re-fields .rs-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: 2.65em auto;
  min-width: 0;
  align-content: start;
}
.rs > .re-fields .rs-input { min-width: 0; margin-top: 0; }

.rs-preview .rk-schedule {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
}
.rk-schedule th:nth-child(1) { width: 9%; }
.rk-schedule th:nth-child(2) { width: 16%; }
.rk-schedule th:nth-child(3) { width: 29%; }
.rk-schedule th:nth-child(4) { width: 8%; }
.rk-schedule th:nth-child(5) { width: 38%; }
.rs-preview .rk-schedule th,
.rs-preview .rk-schedule td { white-space: normal; overflow-wrap: anywhere; }
.rs-preview .rk-schedule td:nth-child(4) { font-variant-numeric: tabular-nums; }
.rk-cell-label { display: none; }

.ab-plan-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
  margin: 6px 0 12px;
}
.ab-plan-actions button[hidden] { display: none; }
.ab-plan-actions .rs-btn { font-size: 12px; padding: 4px 8px; white-space: normal; }
.ab-plan-actions .rs-note { flex-basis: 100%; margin: 0; }
.ab-plan-actions .rs-note:empty { display: none; }

@media (max-width: 640px) {
  .rs > .re-fields .rs-field { grid-template-rows: auto auto; }
  .rs > .re-fields .rs-input { margin-top: 4px; }
}

@media (max-width: 560px) {
  .rk-schedule thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .rk-schedule, .rk-schedule tbody, .rk-schedule tr { display: block; }
  .rk-schedule tbody tr { padding: 6px 0; border-bottom: 1px solid #dbe2e4; }
  .rs-preview .rk-schedule td {
    display: grid;
    grid-template-columns: 7.8em minmax(0, 1fr);
    gap: 8px;
    border: 0;
  }
  .rk-cell-label { display: block; font-weight: 500; color: #2f5f6b; }
}
