/* Four-card layout. The approved photography and fading remain in the
   existing design stylesheet and are deliberately not overridden here. */
@media screen {
  body #day-setup { padding: 0; border: 0; background: transparent; min-height: auto; }
  body #day-setup label { font-size: 14px; font-weight: 500; color: #30362d; }
  body #day-setup input:not([type='checkbox']),
  body #day-setup select { min-height: 46px; border: 1px solid #cfc6b4; border-radius: 7px; background-color: #faf8f1; color: #252a22; box-shadow: 0 1px 2px #493a1a04 inset; }
  body #day-setup input[type='checkbox'] { accent-color: #414d35; }
  body #day-setup :is(input,select,button,summary):focus-visible { outline: 3px solid #9b785e; outline-offset: 3px; }
  body #day-setup button { min-height: 44px; border-radius: 7px; background: #414d35; border-color: #414d35; box-shadow: 0 2px 3px #302d1910; }
  body #day-setup button.secondary { background: #faf8f1; border-color: #a5a58f; color: #303a28; box-shadow: none; }
  body #day-setup button.ghost { background: transparent; color: #9b3444; border-color: transparent; box-shadow: none; }
  body #day-setup #add-club { color: #96344a; background: #f3dfdc; border-color: #e6bcb7; }
  body #day-setup .club-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; padding: 16px 0; margin: 12px 0; border: 0; background: transparent; }
  body #day-setup .notice { background: #e7e8dd; border: 1px solid #dadbce; border-radius: 9px; }
  body #day-setup .editorial-schedule-layout { display: grid; grid-template-columns: minmax(0, 1fr); }
  body #day-setup #schedule-days,
  body #day-setup .editorial-monday,
  body #day-setup .editorial-monday > .day-hours-fields { display: contents; }
  body #day-setup .editorial-hours-card,
  body #day-setup .editorial-pupil-breaks-card,
  body #day-setup .editorial-specific-days-card,
  body #day-setup .editorial-clubs-card {
    background: #fbf9f3;
    border: 1px solid #d9d0bf;
    border-radius: 12px;
    padding: 26px 32px;
    margin: 0 0 24px;
    min-width: 0;
    box-shadow: 0 4px 16px #4b3c1f04;
  }
  body #day-setup .editorial-hours-card { grid-row: 1; margin-bottom: 0; border-bottom: 0; border-radius: 12px 12px 0 0; }
  body #day-setup .editorial-schedule-layout > .actions {
    grid-row: 2;
    margin: 0 0 24px;
    padding: 0 32px 26px;
    border: 1px solid #d9d0bf;
    border-top: 0;
    border-radius: 0 0 12px 12px;
    background: #fbf9f3;
    box-shadow: none;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
  }
  body #day-setup .editorial-pupil-breaks-card { grid-row: 3; }
  body #day-setup .editorial-specific-days-card { grid-row: 4; }
  body #day-setup .editorial-hours-card > h2,
  body #day-setup .editorial-pupil-breaks-card > h2,
  body #day-setup .editorial-specific-days-card > h2,
  body #day-setup .editorial-clubs-card > h2 {
    position: relative;
    min-height: 44px;
    padding: 5px 0 0 62px;
    margin: 0 0 8px;
    color: #242a20;
    font: 30px/1.2 Georgia, serif;
  }
  body #day-setup .editorial-hours-card > h2::before,
  body #day-setup .editorial-pupil-breaks-card > h2::before,
  body #day-setup .editorial-specific-days-card > h2::before,
  body #day-setup .editorial-clubs-card > h2::before {
    position: absolute;
    inset: 0 auto auto 0;
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #414d35;
    color: #fffdf3;
    font: 25px/1 Georgia, serif;
  }
  body #day-setup .editorial-hours-card > h2::before { content: '1'; }
  body #day-setup .editorial-pupil-breaks-card > h2::before { content: '2'; }
  body #day-setup .editorial-specific-days-card > h2::before { content: '3'; }
  body #day-setup .editorial-clubs-card > h2::before { content: '4'; }
  body #day-setup :is(.editorial-hours-card,.editorial-pupil-breaks-card,.editorial-specific-days-card,.editorial-clubs-card) > h2::after { display: none; }
  body #day-setup .editorial-card-description { margin: 0 0 22px; padding-left: 62px; font: 14px/1.5 system-ui, sans-serif; color: #62665e; }
  body #day-setup .editorial-hours-card > strong { display: inline-block; font-size: 14px; margin: 0 0 10px; color: #5e6557; }
  body #day-setup .editorial-hours-fields { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
  body #day-setup .editorial-pupil-break-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; margin: 14px 0; }
  body #day-setup .editorial-schedule-layout .day-options { flex: 1; width: auto; margin: 0; gap: 10px; border: 0; padding: 0; }
  body #day-setup .editorial-schedule-layout .day-options legend { font: 14px/1.5 system-ui, sans-serif; margin-bottom: 8px; }
  body #day-setup .editorial-schedule-layout .day-options label { padding: 10px 12px; font-size: 13px; background: #eeeee4; border-radius: 6px; }
  body #day-setup .editorial-schedule-layout .day-options label:has(:checked) { color: #fffdf3; background: #414d35; }
  body #day-setup .editorial-day-buttons { display: flex; gap: 10px; margin: 14px 0 18px; }
  body #day-setup .editorial-day-buttons button { flex: 1; background: #eaeade; border-color: transparent; color: #282f22; }
  body #day-setup .editorial-day-buttons button[aria-pressed='true'] { background: #414d35; color: #fffdf3; }
  body #day-setup .editorial-specific-days-card .other-days { margin: 0; padding: 16px 20px; background: #e9eade; border: 0; border-radius: 9px; }
  body #day-setup .editorial-specific-days-card .other-days > summary { font: 16px/1.5 system-ui, sans-serif; }
  body #day-setup .editorial-specific-days-card .schedule-day[hidden] { display: none; }
  body #day-setup .editorial-specific-days-card .schedule-grid { display: block; }
  body #day-setup .editorial-specific-days-card .schedule-day > strong { padding-left: 0; }
  body #day-setup .editorial-specific-days-card .schedule-day { background: #fbf9f3; border: 1px solid #d9d0bf; border-radius: 8px; padding: 20px; margin: 16px 0 0; }
  body #day-setup .editorial-specific-days-card .day-hours-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
  body #day-setup .teacher-break-choice { margin: 24px 0 0; padding: 24px 0 0; border: 0; border-top: 1px solid #d9d0bf; border-radius: 0; background: transparent; }
  body #day-setup .teacher-break-choice > h3,
  body #day-setup .editorial-breaks-subheading { margin: 0 0 16px; font: 22px/1.3 Georgia, serif; color: #30362d; }
  body #day-setup .teacher-break-choice .quick-settings { gap: 16px; }
  body #day-setup .preview-pupil-break-scope { margin: 18px 0 10px; padding: 16px; border: 1px solid #cbd0bf; border-radius: 8px; background: #eeefe5; }
  body #day-setup .preview-pupil-break-scope legend { padding: 0 6px; font-size: 14px; font-weight: 600; }
  body #day-setup :is(.preview-break-scope-options,.preview-break-chosen-days) { display: flex; flex-wrap: wrap; gap: 12px 24px; }
  body #day-setup .preview-break-chosen-days { margin-top: 16px; }
  body #day-setup .preview-break-chosen-days[hidden] { display: none; }
  body #day-setup .preview-pupil-break-scope label { display: flex; align-items: center; gap: 8px; margin: 0; min-height: 32px; }
  body #day-setup .preview-pupil-break-scope input { width: auto; min-height: 0; margin: 0; accent-color: #414d35; }
  body #day-setup .teacher-break-name-field { display: grid; gap: 6px; max-width: 360px; margin: 18px 0; }
  body #day-setup .teacher-break-name-field input { width: 100%; min-width: 0; }
  body #day-setup .teacher-break-name-field small { font: 12px/1.5 system-ui, sans-serif; color: #62665e; }
  body #day-setup .editorial-page-guidance { padding: 14px 0; color: #606356; font-size: 13px; }
  body #day-setup .editorial-page-guidance > summary { cursor: pointer; }
  body #workspace-navigation { grid-template-columns: minmax(0, 1fr) auto; gap: 8px 18px; margin-bottom: 24px; }
  body #workspace-navigation > .editorial-plan-identity { grid-column: 1; align-self: start; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) 160px; align-items: end; gap: 12px; padding: 0; }
  body #workspace-navigation .editorial-plan-identity label { display: grid; align-content: start; gap: 6px; margin: 0; min-width: 0; font: 13px/1.4 system-ui, sans-serif; }
  body #workspace-navigation .editorial-plan-identity > .preview-saved-months-shortcut { grid-column: 1; grid-row: 2; }
  body #workspace-navigation .editorial-plan-identity label[hidden] { display: none; }
  body #workspace-navigation .editorial-plan-identity :is(select,input) { width: 100%; min-width: 0; min-height: 44px; margin: 0; padding: 6px 8px; font: 14px/1.4 system-ui, sans-serif; }
  body #workspace-navigation #preview-plan-name { width: 100%; min-width: 0; min-height: 44px; padding: 6px 8px; margin: 0; background: #faf8f1; border: 1px solid #d5b9b3; font-size: 14px; color: #272d23; }
  body #workspace-navigation #preview-plan-name:hover { border-color: #d5b9b3; }
  body #workspace-navigation #preview-plan-name:focus-visible { outline: 2px solid #9b3444; outline-offset: 2px; }
  body #workspace-navigation .editorial-plan-identity button { width: 160px; min-width: 160px; min-height: 44px; height: 44px; margin: 0; padding: 8px 10px; font: 600 13px/1.2 system-ui, sans-serif; }
  body #workspace-navigation > .editorial-plan-actions { grid-column: 2; align-self: end; padding-top: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
  body #workspace-navigation .editorial-plan-actions .preview-top-section-nav { grid-column: 1 / -1; justify-content: flex-end; margin: 0; }
  body #workspace-navigation .editorial-plan-actions .preview-top-section-nav[hidden] { display: none; }
  body #workspace-navigation > .editorial-plan-actions button { width: 160px; min-width: 160px; min-height: 44px; height: 44px; margin: 0; padding: 8px 10px; font: 600 13px/1.2 system-ui, sans-serif; }
  body #workspace-navigation > details { grid-column: 1 / -1; margin: 0; font-size: 12px; }
  body #workspace-navigation > details[open] { padding-top: 12px; }
  body #workspace-navigation .workspace-progress { margin-top: 14px; }
  @media (max-width: 1100px) {
    body #workspace-navigation { grid-template-columns: minmax(0, 1fr); }
    body #workspace-navigation > .editorial-plan-identity { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    body #workspace-navigation .editorial-plan-identity > .preview-saved-months-shortcut { grid-column: 2; }
    body #workspace-navigation > .editorial-plan-actions { grid-column: 1; padding-top: 0; }
  }
  @media (max-width: 540px) {
    body #workspace-navigation > .editorial-plan-identity { grid-template-columns: minmax(0, 1fr); }
    body #workspace-navigation .editorial-plan-identity > .preview-saved-months-shortcut { grid-column: 1; grid-row: auto; }
    body #workspace-navigation > .editorial-plan-actions { grid-template-columns: 160px; justify-content: start; }
    body #workspace-navigation .editorial-plan-actions .preview-top-section-nav { grid-column: 1; }
    body #workspace-navigation > .editorial-plan-actions button { width: 160px; min-width: 160px; }
  }
  @media (min-width: 1280px) {
    body #day-setup .teacher-break-choice .quick-settings { grid-template-columns: repeat(5, minmax(0, 1fr)); }
    body #day-setup .club-row { grid-template-columns: 1.4fr 1fr 1.1fr .8fr 1fr auto; gap: 12px; }
    body #day-setup .editorial-specific-days-card .day-hours-fields { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  }
  @media (max-width: 1279px) {
    body #day-setup .editorial-hours-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  }
  @media (max-width: 700px) {
    body #day-setup .editorial-hours-card,
    body #day-setup .editorial-pupil-breaks-card,
    body #day-setup .editorial-specific-days-card,
    body #day-setup .editorial-clubs-card { padding: 20px; }
    body #day-setup .editorial-schedule-layout > .actions { padding: 0 20px 20px; flex-direction: column; align-items: stretch; }
    body #day-setup .editorial-hours-fields,
    body #day-setup .editorial-pupil-break-row { grid-template-columns: minmax(0, 1fr); gap: 16px; }
    body #day-setup .editorial-hours-card > h2,
    body #day-setup .editorial-pupil-breaks-card > h2,
    body #day-setup .editorial-specific-days-card > h2,
    body #day-setup .editorial-clubs-card > h2 { font-size: 25px; padding-left: 54px; }
    body #day-setup .editorial-card-description { padding-left: 54px; }
      body #day-setup .editorial-day-buttons { flex-wrap: wrap; gap: 6px; }
    body #day-setup .editorial-day-buttons button { flex: 1 0 28%; }
    body #workspace-navigation { grid-template-columns: minmax(0, 1fr); }
    body #workspace-navigation > .editorial-plan-identity,
    body #workspace-navigation > .editorial-plan-actions { grid-column: 1; }
    body #workspace-navigation > .editorial-plan-actions { padding-top: 0; }
    body #workspace-navigation > .editorial-plan-actions button { flex: 1; min-width: 0; width: 100%; }
    body #day-setup .club-row,
    body #day-setup .teacher-break-choice .quick-settings,
    body #day-setup .editorial-specific-days-card .day-hours-fields { grid-template-columns: minmax(0, 1fr); }
  }
}
