:root {
    color-scheme: light;
    font-family: Georgia, "Times New Roman", serif;
    color: #29352f;
    background: #f6f2e9;
}

* {
    box-sizing: border-box;
}

[hidden] {
    display: none !important;
}

body {
    min-width: 320px;
    min-height: 100vh;
    margin: 0;
    background:
        radial-gradient(circle at top, rgba(224, 194, 119, 0.22), transparent 42rem),
        #f6f2e9;
}

a {
    color: #4f622d;
}

:focus-visible {
    outline: 3px solid #005fcc;
    outline-offset: 3px;
}

.skip-link {
    position: fixed;
    top: 0.5rem;
    left: 0.5rem;
    z-index: 1000;
    padding: 0.75rem 1rem;
    color: #fff;
    background: #29352f;
    border-radius: 0.5rem;
    transform: translateY(-150%);
}

.skip-link:focus {
    transform: translateY(0);
}

button,
input,
select {
    font: inherit;
}

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem clamp(1rem, 4vw, 2.5rem);
    background: rgba(255, 253, 248, 0.95);
    border-bottom: 1px solid #e1d7c0;
    font-family: Arial, sans-serif;
}

.brand {
    color: #29352f;
    font-weight: 700;
    text-decoration: none;
}

.nav-toggle {
    display: none;
    min-height: 2.75rem;
    padding: 0.55rem 0.8rem;
    color: #29352f;
    background: #e9e1ce;
    border: 0;
    border-radius: 0.55rem;
    font-weight: 700;
}

.header-actions,
.locale-switcher,
.action-row,
.inline-form {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.header-actions form,
.locale-switcher form,
.action-row form {
    margin: 0;
}

.content-shell {
    width: min(100% - 1.5rem, 92rem);
    margin: 2rem auto;
}

.page-heading,
.search-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.search-form {
    display: grid;
    gap: 0.5rem;
    margin: 2rem 0 1rem;
    font-family: Arial, sans-serif;
}

.search-row input {
    flex: 1;
}

.export-actions {
    margin: 1rem 0;
    font-family: Arial, sans-serif;
}

.table-scroll {
    margin: 1.5rem 0;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-family: Arial, sans-serif;
    font-size: 0.92rem;
}

.data-table th,
.data-table td {
    padding: 0.75rem;
    border-bottom: 1px solid #e1d7c0;
    text-align: left;
    vertical-align: top;
}

.data-table th {
    color: #fff;
    background: #426248;
}

.notice {
    margin: 1.25rem 0;
    padding: 1rem;
    color: #4f4b37;
    background: #fff5d7;
    border-left: 0.3rem solid #c49b35;
    font-family: Arial, sans-serif;
    line-height: 1.5;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr));
    gap: 0.75rem;
    margin: 1.5rem 0;
}

.summary-grid div {
    display: grid;
    gap: 0.25rem;
    padding: 1rem;
    background: #f5f0e5;
    border-radius: 0.6rem;
    font-family: Arial, sans-serif;
}

.summary-grid strong {
    font-size: 1.5rem;
}

.share-panel {
    display: grid;
    gap: 0.8rem;
    margin: 1.5rem 0;
    padding: 1rem;
    border: 1px solid #d8d1c4;
    border-radius: 0.75rem;
    background: #fffdf8;
    font-family: Arial, sans-serif;
}

.share-panel label {
    display: grid;
    gap: 0.5rem;
}

.share-panel textarea {
    width: 100%;
    min-height: 18rem;
    padding: 0.8rem;
    color: #29352f;
    background: #fff;
    border: 1px solid #a99c80;
    border-radius: 0.55rem;
    font: 0.95rem/1.5 Arial, sans-serif;
    resize: vertical;
}

.share-panel textarea[data-share-introduction] { min-height: 6rem; }

.summary-preview {
    padding: 0.85rem;
    border: 1px solid #d8d1c4;
    border-radius: 0.55rem;
    background: #fff;
}

.summary-preview p { margin: 0.25rem 0; }
.summary-break { display: block; min-height: 0.65rem; }

.schedule-snapshot-card {
    margin: 1.25rem 0;
    padding: 0.75rem;
    border: 1px solid #d8d1c4;
    border-radius: 0.6rem;
    background: #fffdf8;
}

.schedule-snapshot-card canvas {
    display: block;
    width: 100%;
    height: auto;
    border: 1px solid #d8d1c4;
    background: #fff;
}

.schedule-snapshot-card figcaption { margin-top: 0.5rem; color: #58635d; }

.classification {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 999px;
    background: #ece6d9;
    white-space: nowrap;
}

.classification-proposed { color: #245338; background: #e3f1e8; }
.classification-ambiguous,
.classification-missing,
.classification-invalid { color: #762e28; background: #f8e5e2; }

.content-card {
    padding: clamp(1.5rem, 5vw, 3rem);
    background: rgba(255, 253, 248, 0.96);
    border: 1px solid #e1d7c0;
    border-radius: 1.25rem;
    box-shadow: 0 1.25rem 3.5rem rgba(67, 61, 46, 0.1);
}

.locale-switcher {
    justify-content: flex-end;
    margin-bottom: 1.5rem;
}

.locale-button,
.link-button {
    padding: 0;
    color: #4f622d;
    background: transparent;
    border: 0;
    cursor: pointer;
    text-decoration: underline;
}

.locale-button.is-current {
    color: #29352f;
    font-weight: 700;
    text-decoration: none;
}

.install-action {
    min-height: 2.75rem;
    padding: 0.5rem 0.65rem;
}

.stacked-form {
    display: grid;
    gap: 0.75rem;
    margin-top: 2rem;
    font-family: Arial, sans-serif;
}

.stacked-form label,
.inline-form label {
    font-weight: 700;
}

input,
select {
    width: 100%;
    min-height: 3rem;
    padding: 0.7rem 0.8rem;
    color: #29352f;
    background: #fff;
    border: 1px solid #a99c80;
    border-radius: 0.55rem;
}

.primary-button,
.secondary-button,
.danger-button {
    display: inline-flex;
    min-height: 3rem;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1rem;
    border: 0;
    border-radius: 0.65rem;
    cursor: pointer;
    font-family: Arial, sans-serif;
    font-weight: 700;
    text-decoration: none;
}

button[aria-busy="true"] {
    cursor: wait;
    opacity: 0.72;
}

.primary-button {
    color: #fff;
    background: #426248;
}

.secondary-button {
    color: #29352f;
    background: #e9e1ce;
}

.danger-button {
    color: #fff;
    background: #8a3f36;
}

.field-help,
.readonly-field small {
    color: #667069;
    font-family: Arial, sans-serif;
    line-height: 1.5;
}

.check-row {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-weight: 400 !important;
}

.check-row input {
    width: 1.25rem;
    min-height: 1.25rem;
    margin-top: 0.1rem;
}

.readonly-field {
    display: grid;
    gap: 0.4rem;
    padding: 1rem;
    background: #f5f0e5;
    border-radius: 0.6rem;
}

.flash {
    margin: 1rem 0;
    padding: 1rem;
    border-radius: 0.6rem;
    font-family: Arial, sans-serif;
}

.flash ul {
    margin: 0;
    padding-left: 1.25rem;
}

.flash-success {
    color: #245338;
    background: #e3f1e8;
}

.flash-error {
    color: #762e28;
    background: #f8e5e2;
}

.flash-error h2 {
    margin: 0 0 0.5rem;
    font-size: 1.2rem;
}

.flash-error p {
    margin: 0.25rem 0 0.75rem;
}

.field-error {
    margin: 0.35rem 0 0;
    color: #762e28;
    font: 700 0.9rem/1.4 Arial, sans-serif;
}

[aria-invalid="true"] {
    border-color: #9c2f26;
    box-shadow: 0 0 0 2px rgba(156, 47, 38, 0.18);
}

.details-list {
    display: grid;
    gap: 0;
    margin: 2rem 0;
    font-family: Arial, sans-serif;
}

.details-list div {
    display: grid;
    grid-template-columns: minmax(9rem, 1fr) 2fr;
    gap: 1rem;
    padding: 0.9rem 0;
    border-bottom: 1px solid #e1d7c0;
}

.details-list dt {
    font-weight: 700;
}

.details-list dd {
    margin: 0;
    overflow-wrap: anywhere;
}

.item-list,
.role-list {
    padding: 0;
    list-style: none;
    font-family: Arial, sans-serif;
}

.item-list li,
.role-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid #e1d7c0;
}

.role-list li > div {
    display: grid;
    gap: 0.3rem;
}

.danger-zone {
    display: grid;
    gap: 0.75rem;
    padding: 1rem;
    border: 1px solid #d4a19b;
    border-radius: 0.6rem;
}

.page-shell {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 1.5rem;
}

.welcome-card {
    width: min(100%, 42rem);
    padding: clamp(2rem, 7vw, 4.5rem);
    text-align: center;
    background: rgba(255, 253, 248, 0.9);
    border: 1px solid #e1d7c0;
    border-radius: 1.25rem;
    box-shadow: 0 1.25rem 3.5rem rgba(67, 61, 46, 0.1);
}

.welcome-content {
    max-width: 42rem;
    margin: 0 auto;
    text-align: center;
}

.symbol {
    position: relative;
    display: grid;
    width: 4.5rem;
    height: 4.5rem;
    margin: 0 auto 1.75rem;
    place-items: center;
    border: 1px solid #d8bf78;
    border-radius: 50%;
    background: #fffaf0;
}

.symbol::before,
.symbol span {
    display: block;
    content: "";
    background: #806725;
    border-radius: 999px;
}

.symbol::before {
    width: 0.18rem;
    height: 2.3rem;
}

.symbol span {
    position: absolute;
    width: 1.35rem;
    height: 0.18rem;
    transform: translateY(-0.45rem);
}

.eyebrow {
    margin: 0 0 0.75rem;
    color: #806725;
    font-family: Arial, sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

h1 {
    margin: 0;
    color: #26352e;
    font-size: clamp(2rem, 7vw, 3.5rem);
    font-weight: 500;
    line-height: 1.08;
}

.intro {
    max-width: 34rem;
    margin: 1.5rem auto 2rem;
    color: #59665f;
    font-family: Arial, sans-serif;
    font-size: clamp(1rem, 2.8vw, 1.15rem);
    line-height: 1.7;
}

.status {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.7rem 1rem;
    color: #355b45;
    background: #edf5ef;
    border-radius: 999px;
    font-family: Arial, sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
}

.status-dot {
    width: 0.65rem;
    height: 0.65rem;
    background: #4b8a62;
    border-radius: 50%;
}

.schedule-tabs,
.schedule-toolbar,
.date-picker {
    display: flex;
    align-items: end;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin: 1rem 0;
    font-family: Arial, sans-serif;
}

.date-picker label {
    width: 100%;
    font-weight: 700;
}

.date-picker input {
    width: auto;
}

.calendar-grid-wrap {
    margin: 1.5rem calc(-1 * clamp(0.75rem, 2vw, 1.5rem));
    overflow-x: auto;
}

.schedule-week-page {
    margin-top: -0.75rem;
}

.schedule-week-page .page-heading h1 {
    font-size: clamp(2rem, 4vw, 2.75rem);
}

.schedule-week-page .page-heading .intro {
    margin: 0.2rem 0 0;
    line-height: 1.25;
}

.schedule-week-page > .schedule-tabs,
.schedule-week-page > .schedule-toolbar,
.schedule-week-page > .action-row {
    margin: 0.4rem 0;
}

.schedule-week-page > .schedule-tabs .secondary-button,
.schedule-week-page > .schedule-toolbar .secondary-button,
.schedule-week-page > .schedule-toolbar .primary-button,
.schedule-week-page > .action-row .secondary-button {
    min-height: 2rem;
    padding: 0.35rem 0.55rem;
    font-size: 0.82rem;
}

.schedule-week-page .date-picker label {
    width: auto;
    font-size: 0.82rem;
}

.schedule-week-page .date-picker input {
    min-height: 2rem;
    padding: 0.2rem 0.35rem;
}

.calendar-halves {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
    margin: 0.6rem calc(-1 * clamp(0.75rem, 2vw, 1.5rem)) 0;
}

.calendar-halves .calendar-grid-wrap {
    min-width: 0;
    margin: 0;
    overflow: visible;
}

.calendar-halves .calendar-grid {
    font-size: 0.66rem;
}

.calendar-halves .calendar-grid caption {
    padding: 0.2rem 0.35rem;
}

.calendar-halves .calendar-grid th,
.calendar-halves .calendar-grid td {
    padding: 0.08rem;
}

.calendar-halves .schedule-cell.is-compact {
    min-height: 1rem;
    padding: 0.02rem;
    font-size: 0.61rem;
    line-height: 1.05;
}

.calendar-halves .schedule-cell.is-compact .cell-actions {
    display: block;
    margin: 0;
}

.calendar-halves .schedule-cell.is-compact summary {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.calendar-grid {
    width: 100%;
    table-layout: fixed;
    border-collapse: separate;
    border-spacing: 0;
    font-family: Arial, sans-serif;
    font-size: 0.78rem;
}

.calendar-grid caption {
    padding: 0.75rem;
    font-weight: 700;
    text-align: left;
}

.calendar-grid th,
.calendar-grid td {
    width: 13.7%;
    padding: 0.18rem;
    border-right: 1px solid #ded5c4;
    border-bottom: 1px solid #ded5c4;
    vertical-align: top;
}

.calendar-grid thead th,
.calendar-grid tbody > tr > th {
    color: #fff;
    background: #426248;
}

.calendar-grid tbody > tr > th {
    position: sticky;
    left: 0;
    z-index: 1;
    width: 4%;
    white-space: nowrap;
}

.schedule-cell {
    min-height: 4.5rem;
    padding: 0.35rem;
    border-radius: 0.4rem;
}

.schedule-cell.is-compact {
    min-height: 1.25rem;
    padding: 0.08rem;
    font-size: 0.68rem;
    line-height: 1.15;
}

.schedule-cell.is-compact > .state-badge {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.schedule-cell.is-compact .primary-button,
.schedule-cell.is-compact .secondary-button {
    min-height: 1.35rem;
    padding: 0.12rem 0.3rem;
    border-radius: 0.3rem;
    font-size: 0.64rem;
    line-height: 1.05;
}

.schedule-cell.is-compact .registration-list {
    min-width: 0;
    gap: 0.1rem;
    margin: 0.08rem 0;
}

.schedule-cell.is-compact .registration-list li {
    min-width: 0;
    max-width: 100%;
    padding: 0.12rem;
    overflow-wrap: anywhere;
}
.schedule-cell.is-compact .registration-list small { margin: 0.08rem 0; }
.schedule-cell.is-compact .compact-action { gap: 0.2rem; margin-top: 0.12rem; }
.schedule-cell.is-compact .cell-actions,
.schedule-cell.is-compact .annotation-editor { display: inline-block; margin: 0.08rem 0.15rem 0 0; }
.schedule-cell.is-compact summary { cursor: pointer; color: #4f622d; font-weight: 700; }

.schedule-cell.is-compact .registration-contact summary {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.schedule-cell.is-compact .registration-contact {
    min-width: 0;
    max-width: 100%;
}

.schedule-cell.is-compact .registration-contact[open] summary { white-space: normal; }
.schedule-cell.is-compact .registration-contact .contact-action { display: inline-block; margin-top: 0.15rem; }

.schedule-cell.is-compact .add-participant {
    display: block;
    width: 100%;
    margin: 0.1rem 0 0;
}

.schedule-cell.is-compact .add-participant > summary {
    display: grid;
    place-items: center;
    min-height: 1.4rem;
    border: 1px dashed #738264;
    border-radius: 0.3rem;
    font-size: 1rem;
    line-height: 1;
    list-style: none;
}

.schedule-cell.is-compact .add-participant > summary::-webkit-details-marker { display: none; }

.cell-plus,
.replacement-trigger {
    display: grid;
    place-items: center;
    width: 100%;
    min-height: 1.55rem;
    margin-top: 0.12rem;
    padding: 0.1rem 0.25rem;
    border: 1px dashed #738264;
    border-radius: 0.3rem;
    color: #36512f;
    background: rgba(255, 255, 255, 0.72);
    font: inherit;
    font-weight: 800;
    line-height: 1.05;
    cursor: pointer;
}

.replacement-trigger { border-style: solid; color: #593c70; border-color: #8f70a8; }
.absence-registration { text-align: center; }
.absence-marker { color: #7b3042; font-size: 1.1rem; font-weight: 900; line-height: 1; }

.registration-identity {
    display: flex;
    align-items: baseline;
    gap: 0.3rem;
    flex-wrap: wrap;
}

.contact-action {
    font-size: 0.9em;
    font-weight: 700;
}

.my-marker { font-size: 0.86em; }

.schedule-cell.state-missing { background: #fff2ef; }
.schedule-cell.state-pending { background: #fff7da; }
.schedule-cell.state-covered { background: #edf6ee; }
.schedule-cell.state-replacement { background: #f5ecfb; }
.schedule-cell.state-nonexistent { color: #626a66; background: repeating-linear-gradient(135deg, #f1eee7, #f1eee7 0.4rem, #e5e1d8 0.4rem, #e5e1d8 0.8rem); }
.schedule-cell.is-mine { outline: 3px solid #24629b; outline-offset: -2px; }

.state-badge {
    display: inline-flex;
    padding: 0.15rem 0.4rem;
    border-radius: 999px;
    color: #29352f;
    background: rgba(255,255,255,0.75);
    font-size: 0.7rem;
    font-weight: 700;
}

.occurrence-entry + .occurrence-entry {
    margin-top: 0.5rem;
    padding-top: 0.5rem;
    border-top: 2px dashed #766f63;
}

.fold-label,
.cell-note,
.empty-name,
.welcome-note,
.annotation,
.registration-list small {
    display: block;
    margin: 0.25rem 0;
    line-height: 1.35;
}

.registration-list {
    display: grid;
    gap: 0.3rem;
    margin: 0.35rem 0;
    padding: 0;
    list-style: none;
}

.registration-list li {
    padding: 0.3rem;
    background: rgba(255,255,255,0.72);
    border-radius: 0.3rem;
}

.registration-actions,
.compact-action {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    gap: 0.45rem;
    margin-top: 0.45rem;
}

.registration-actions form { margin: 0; }
.compact-action select { max-width: 11rem; }

.person-dialog {
    width: min(30rem, calc(100vw - 2rem));
    max-height: calc(100vh - 2rem);
    padding: 1rem;
    border: 1px solid #bdb4a5;
    border-radius: 0.75rem;
    color: #29352f;
    background: #fffdf8;
    box-shadow: 0 1rem 3rem rgba(25, 35, 30, 0.3);
    overflow-y: auto;
}

.person-dialog::backdrop { background: rgba(28, 37, 32, 0.58); }
.dialog-heading { display: flex; align-items: start; justify-content: space-between; gap: 1rem; }
.dialog-heading h2 { margin-top: 0; font-size: 1.25rem; }
.dialog-close { min-width: 2.75rem; min-height: 2.75rem; border: 0; color: #29352f; background: transparent; font-size: 1.5rem; cursor: pointer; }
.install-dialog p { font: 1rem/1.55 Arial, sans-serif; }
.person-picker { display: grid; gap: 0.45rem; }
.person-picker label { display: grid; gap: 0.25rem; }
.person-picker select { width: 100%; max-width: none; }
.person-search-clear { justify-self: start; }
.person-picker-empty { margin: 0; color: #8a2f3e; }

.management-panel {
    margin: 1.25rem 0;
    padding: 1rem;
    border: 1px solid #d8d1c4;
    border-radius: 0.75rem;
    background: #fffdf8;
}

.contact-request-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
    gap: 1.25rem;
    margin-top: 1.25rem;
}

.contact-request-card,
.privacy-panel,
.shared-contact-panel {
    margin: 0.75rem 0;
    padding: 1rem;
    border: 1px solid #d8d1c4;
    border-radius: 0.75rem;
    background: #fffdf8;
}

.privacy-panel {
    border-left: 0.35rem solid #426248;
}

.shared-contact-panel {
    border-color: #6a956f;
    background: #edf6ee;
}

.schedule-management-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
    gap: 0.8rem;
    align-items: end;
}

.schedule-management-form label { display: grid; gap: 0.3rem; }
.custom-shift-fields { display: grid; grid-template-columns: repeat(2, minmax(9rem, 1fr)); gap: 0.8rem; }
.duty-shift-form {
    grid-template-columns: minmax(13rem, 1.2fr) minmax(13rem, 1.15fr) minmax(11rem, 0.9fr) minmax(9rem, 0.75fr);
}
.duty-shift-form .duty-temporary-toggle { align-self: center; display: flex; align-items: center; gap: 0.5rem; }
.duty-shift-form .duty-temporary-toggle input { width: auto; }
.duty-shift-form .duty-submit { grid-column: 4; grid-row: 1; width: 100%; }
.duty-shift-form [data-duty-custom] { grid-column: 1 / 3; grid-row: 2; }
.duty-shift-form [data-duty-temporary-dates] { grid-column: 3 / 5; grid-row: 2; }
.duty-shift-table .is-cancelled { color: #6b6862; background: #f4f1eb; }
.table-section-heading th { color: #29352f; background: #e8e2d7; text-align: left; }
.danger-link { color: #8a2f3e; }
.managed-item { margin-top: 0.8rem; padding-top: 0.8rem; border-top: 1px solid #e4ded3; }

.contact-decision-panel {
    border-color: #6a956f;
    box-shadow: 0 0.45rem 1.2rem rgba(41, 53, 47, 0.1);
}

.contact-decision-panel .primary-button,
.contact-decision-panel .secondary-button { font-weight: 700; }

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.my-registration {
    border-left: 0.25rem solid #24629b;
}

.welcome-note {
    color: #355b45;
    font-style: italic;
}

.annotation {
    padding: 0.4rem;
    border-left: 0.3rem solid #8a8172;
    background: #fff;
}

.annotation-gold { border-color: #b18313; background: #fff7d6; }
.annotation-blue { border-color: #24629b; background: #e8f3fc; }
.annotation-green { border-color: #39734b; background: #e9f5eb; }
.annotation-rose { border-color: #ad5365; background: #fdecef; }
.annotation-violet { border-color: #74509a; background: #f3eafa; }

.annotation-editor {
    margin-top: 0.4rem;
}

.annotation-editor summary {
    cursor: pointer;
    font-weight: 700;
}

.annotation-form {
    display: grid;
    gap: 0.5rem;
    margin: 0.5rem 0;
}

.annotation-form input,
.annotation-form select,
.annotation-form button {
    min-height: 2.5rem;
}

.calendar-linear {
    display: none;
}

.day-list {
    display: grid;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.day-hour,
.linear-hour {
    display: grid;
    grid-template-columns: 7rem 1fr;
    gap: 1rem;
    padding: 0.75rem;
    border: 1px solid #ded5c4;
    border-radius: 0.6rem;
    font-family: Arial, sans-serif;
}

.day-hour h2,
.linear-hour h3 {
    margin: 0;
}

@media (max-width: 48rem) {
    .calendar-halves { display: none; }
    .calendar-grid-wrap { display: none; }
    .calendar-linear { display: grid; gap: 1.5rem; }
    .calendar-linear h2 { font-size: 1.4rem; }
    .linear-hour { grid-template-columns: 4rem 1fr; }
    .custom-shift-fields { grid-template-columns: 1fr; }
    .duty-shift-form { grid-template-columns: 1fr; }
    .duty-shift-form .duty-submit,
    .duty-shift-form [data-duty-custom],
    .duty-shift-form [data-duty-temporary-dates] { grid-column: 1; grid-row: auto; }
    .primary-button,
    .secondary-button,
    .danger-button,
    .link-button,
    .locale-button,
    .cell-plus,
    .replacement-trigger {
        min-height: 2.75rem;
    }
    .schedule-week-page > .schedule-tabs .secondary-button,
    .schedule-week-page > .schedule-toolbar .secondary-button,
    .schedule-week-page > .schedule-toolbar .primary-button,
    .schedule-week-page > .action-row .secondary-button,
    .schedule-week-page .date-picker input {
        min-height: 2.75rem;
    }
}

@media print {
    :root, body { color: #000; background: #fff; }
    .site-header, .locale-switcher, .no-print, .annotation-editor { display: none !important; }
    .content-shell { width: 100%; margin: 0; }
    .content-card { padding: 0; border: 0; box-shadow: none; }
    .calendar-grid-wrap { display: block; margin: 0; overflow: visible; }
    .calendar-halves { display: grid; margin: 0; gap: 4pt; }
    .calendar-grid { min-width: 0; font-size: 7pt; }
    .calendar-grid th, .calendar-grid td { padding: 2pt; border: 1px solid #777; }
    .calendar-grid thead th, .calendar-grid tbody > tr > th { color: #000; background: #ddd; }
    .schedule-cell { min-height: 0; break-inside: avoid; }
    .welcome-note { display: none; }
    .calendar-linear { display: none; }
    @page { size: landscape; margin: 0.35in; }
}

@media (max-width: 30rem) {
    .page-shell {
        padding: 0.75rem;
    }

    .welcome-card {
        border-radius: 1rem;
    }

    .site-header,
    .item-list li,
    .role-list li,
    .action-row,
    .inline-form,
    .page-heading,
    .search-row {
        align-items: stretch;
        flex-direction: column;
    }

    .site-header {
        align-items: stretch;
    }

    .brand {
        align-self: flex-start;
        padding: 0.65rem 0;
    }

    .nav-toggle {
        display: block;
        align-self: flex-end;
        margin-top: -3.25rem;
    }

    .js .header-actions {
        display: none;
    }

    .js .header-actions.is-open {
        display: flex;
    }

    .header-actions {
        align-items: stretch;
        flex-direction: column;
        padding-top: 0.75rem;
    }

    .header-actions a,
    .header-actions button,
    .header-actions form {
        width: 100%;
    }

    .details-list div {
        grid-template-columns: 1fr;
        gap: 0.25rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
