:root {
    --teos-ink: #111111;
    --teos-muted: #6e6a63;
    --teos-line: #ded8cd;
    --teos-surface: #ffffff;
    --teos-soft: #f5f2ec;
    --teos-accent: #8a7758;
    --teos-good: #0d7a42;
    --teos-bad: #b42318;
}

.teos-reservation,
.teos-admin .teos-admin-card {
    background: var(--teos-surface);
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    color: var(--teos-ink);
    box-sizing: border-box;
}

.teos-reservation {
    max-width: 980px;
    padding: clamp(20px, 4vw, 42px);
    margin: 24px auto;
    box-shadow: 0 18px 40px rgba(17, 17, 17, 0.06);
}

.teos-reservation.teos-staff:not(.teos-staff--locked) {
    position: relative;
    left: 50%;
    width: calc(100vw - 24px);
    max-width: none;
    margin-left: 0;
    margin-right: 0;
    transform: translateX(-50%);
}

.teos-staff--locked {
    display: grid;
    place-items: center;
    min-height: min(72vh, 620px);
    text-align: center;
}

.teos-staff--locked h2 {
    margin-bottom: 18px;
}

.teos-staff--locked .teos-notice {
    width: min(100%, 520px);
    text-align: left;
}

.teos-staff-login {
    display: grid;
    gap: 16px;
    width: min(100%, 460px);
    margin: 0 auto;
}

.teos-staff-login label {
    text-align: left;
}

.teos-staff-login input {
    min-height: 62px;
    border-width: 2px;
    padding: 16px 18px;
    font-size: 24px;
    font-weight: 800;
    text-align: center;
}

.teos-staff-login .teos-button {
    width: 100%;
    min-height: 62px;
    font-size: 16px;
}

.teos-reservation *,
.teos-admin * {
    box-sizing: border-box;
}

.teos-reservation__header {
    margin-bottom: 22px;
}

.teos-reservation__header--split {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
}

.teos-reservation h2,
.teos-admin-card h2 {
    margin: 0 0 8px;
    color: var(--teos-ink);
    font-size: clamp(28px, 4vw, 46px);
    line-height: 1.05;
    letter-spacing: 0;
}

.teos-admin-card h2 {
    font-size: 24px;
}

.teos-kicker {
    display: block;
    color: var(--teos-accent);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.teos-form label,
.teos-location-choice,
.teos-filterbar label,
.teos-admin-fields label,
.teos-email-template label {
    display: grid;
    gap: 7px;
    min-width: 0;
    font-weight: 700;
}

.teos-form label span,
.teos-location-choice > span,
.teos-filterbar label span,
.teos-admin-fields label span,
.teos-email-template label span {
    color: var(--teos-muted);
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-form input,
.teos-form select,
.teos-form textarea,
.teos-filterbar input,
.teos-filterbar select,
.teos-admin-fields input,
.teos-admin-fields select,
.teos-email-template input,
.teos-email-template textarea,
.teos-hours-table input,
.teos-hours-table select {
    width: 100%;
    max-width: 100%;
    min-height: 44px;
    border: 1px solid var(--teos-line);
    border-radius: 6px;
    background: #fff;
    color: var(--teos-ink);
    padding: 10px 12px;
    font: inherit;
}

.teos-form textarea,
.teos-email-template textarea {
    min-height: 96px;
    resize: vertical;
}

.teos-note-box {
    display: grid;
    gap: 9px;
    min-width: 0;
}

.teos-note-box--wide {
    grid-column: 1 / -1;
}

.teos-note-box textarea {
    min-height: 118px;
    max-height: 240px;
    overflow-y: auto;
    line-height: 1.45;
}

.teos-note-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.teos-note-chip {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    border: 1px solid var(--teos-line);
    border-radius: 999px;
    background: var(--teos-soft);
    color: var(--teos-ink);
    padding: 0 11px;
    font-size: 12px;
    font-weight: 900;
    cursor: pointer;
}

.teos-note-chip:hover,
.teos-note-chip:focus {
    border-color: var(--teos-accent);
    background: #fff;
}

.teos-date-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 8px;
}

.teos-guest-control {
    display: grid;
    gap: 8px;
    min-width: 0;
}

.teos-guest-stepper {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) 52px;
    min-height: 52px;
    border: 1px solid var(--teos-line);
    border-radius: 6px;
    background: #fff;
    overflow: hidden;
}

.teos-form .teos-guest-stepper {
    gap: 0;
    letter-spacing: 0;
    text-transform: none;
}

.teos-form .teos-guest-stepper input {
    min-height: 52px;
    border: 0;
    border-right: 1px solid var(--teos-line);
    border-left: 1px solid var(--teos-line);
    border-radius: 0;
    padding: 0 8px;
    font-size: 22px;
    font-weight: 900;
    text-align: center;
    -moz-appearance: textfield;
}

.teos-form .teos-guest-stepper input::-webkit-outer-spin-button,
.teos-form .teos-guest-stepper input::-webkit-inner-spin-button {
    margin: 0;
    -webkit-appearance: none;
}

.teos-guest-step-button {
    min-width: 0;
    min-height: 52px;
    border: 0;
    background: #fff;
    color: var(--teos-ink);
    padding: 0;
    font: inherit;
    font-size: 26px;
    font-weight: 900;
    cursor: pointer;
}

.teos-guest-step-button:hover,
.teos-guest-step-button:focus {
    background: var(--teos-soft);
}

.teos-guest-step-button:disabled {
    color: #b5b0a7;
    cursor: not-allowed;
}

.teos-guest-buttons {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 6px;
}

.teos-guest-button {
    min-width: 0;
    min-height: 36px;
    border: 1px solid var(--teos-line);
    border-radius: 6px;
    background: var(--teos-soft);
    color: var(--teos-ink);
    padding: 0;
    font: inherit;
    font-weight: 900;
    cursor: pointer;
}

.teos-guest-button:hover,
.teos-guest-button:focus,
.teos-guest-button.is-active {
    border-color: var(--teos-ink);
    background: var(--teos-ink);
    color: #fff;
}

.teos-mini-button {
    min-height: 44px;
    border: 1px solid var(--teos-ink);
    border-radius: 6px;
    background: #fff;
    color: var(--teos-ink);
    padding: 0 14px;
    font: inherit;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
}

.teos-mini-button:hover,
.teos-mini-button:focus {
    background: var(--teos-ink);
    color: #fff;
}

.teos-grid {
    display: grid;
    gap: 16px;
}

.teos-grid--booking {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
}

.teos-public-reservation .teos-booking-phone,
.teos-public-reservation .teos-booking-note {
    grid-column: 1 / -1;
}

.teos-public-reservation .teos-booking-note {
    margin-top: 2px;
}

.teos-public-reservation .teos-booking-note textarea {
    min-height: 150px;
}

.teos-public-reservation .teos-note-tools {
    gap: 6px;
}

.teos-public-reservation .teos-note-chip {
    min-height: 34px;
    padding: 0 10px;
    font-size: 11px;
}

.teos-location-choice {
    grid-column: 1 / -1;
}

.teos-location-buttons {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.teos-location-button {
    position: relative;
    display: block;
    margin: 0;
    cursor: pointer;
}

.teos-location-button input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.teos-form .teos-location-button span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 62px;
    border: 2px solid var(--teos-line);
    border-radius: 8px;
    background: var(--teos-soft);
    color: var(--teos-ink);
    padding: 14px 16px;
    font-size: 16px;
    font-weight: 900;
    letter-spacing: 0;
    line-height: 1.2;
    text-align: center;
    text-transform: none;
    transition: border-color 160ms ease, background-color 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.teos-form .teos-location-button input:checked + span {
    border-color: var(--teos-ink);
    background: var(--teos-ink);
    color: #fff;
    box-shadow: 0 10px 24px rgba(17, 17, 17, 0.14);
}

.teos-form .teos-location-button input:focus-visible + span {
    outline: 3px solid rgba(138, 119, 88, 0.35);
    outline-offset: 3px;
}

.teos-grid--staff,
.teos-admin-fields {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.teos-time-select {
    display: grid;
    margin: 16px 0 8px;
}

.teos-availability-warning {
    border: 1px solid #ead1a6;
    border-radius: 6px;
    background: #fff8ea;
    color: #7a4b00;
    margin: 0 0 16px;
    padding: 12px 14px;
    font-weight: 800;
    line-height: 1.4;
}

.teos-availability-warning[hidden] {
    display: none;
}

.teos-consent {
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    align-items: center;
    gap: 11px;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: var(--teos-soft);
    margin: 18px 0;
    padding: 11px 12px;
    font-weight: 600;
    cursor: pointer;
}

.teos-consent:hover,
.teos-consent:focus-within {
    border-color: var(--teos-accent);
    background: #fff;
}

.teos-form .teos-consent input {
    width: 30px;
    height: 30px;
    min-height: 30px;
    margin: 0;
    accent-color: var(--teos-ink);
    cursor: pointer;
}

.teos-form .teos-consent span {
    color: var(--teos-muted);
    font-size: 12px;
    letter-spacing: 0;
    line-height: 1.35;
    text-transform: none;
}

.teos-consent a {
    color: var(--teos-ink);
    font-weight: 900;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.teos-static-field {
    display: flex;
    align-items: center;
    min-height: 44px;
    border: 1px solid var(--teos-line);
    border-radius: 6px;
    padding: 10px 12px;
    background: var(--teos-soft);
}

.teos-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    border: 1px solid var(--teos-ink);
    border-radius: 0;
    background: var(--teos-ink);
    color: #fff;
    padding: 0 22px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    text-decoration: none;
}

.teos-button:hover,
.teos-button:focus {
    background: var(--teos-accent);
    border-color: var(--teos-accent);
    color: #fff;
}

.teos-button--light {
    background: #fff;
    color: var(--teos-ink);
}

.teos-button--small {
    min-height: 40px;
    padding: 0 16px;
    font-size: 12px;
}

.teos-staff-submit-button {
    width: 100%;
    margin-top: 14px;
}

.teos-modal-open {
    overflow: hidden;
}

.teos-staff-quick-add {
    position: fixed;
    left: calc(18px + env(safe-area-inset-left));
    bottom: calc(18px + env(safe-area-inset-bottom));
    z-index: 9990;
    width: 64px;
    height: 64px;
}

.teos-staff-quick-add__button {
    display: grid;
    place-items: center;
    width: 64px;
    height: 64px;
    border: 2px solid #fff;
    border-radius: 50%;
    background: var(--teos-ink);
    color: #fff;
    box-shadow: 0 16px 34px rgba(17, 17, 17, 0.24);
    cursor: pointer;
}

.teos-staff-quick-add__button span {
    display: block;
    margin-top: -4px;
    font-size: 46px;
    font-weight: 800;
    line-height: 1;
}

.teos-staff-quick-add__button:hover,
.teos-staff-quick-add__button:focus {
    background: var(--teos-accent);
    outline: 0;
}

.teos-staff-quick-add__button:focus-visible {
    outline: 3px solid rgba(138, 119, 88, 0.35);
    outline-offset: 4px;
}

.teos-quick-modal[hidden] {
    display: none;
}

.teos-quick-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: grid;
    align-items: center;
    justify-items: center;
    padding: 18px;
}

.teos-quick-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(17, 17, 17, 0.48);
}

.teos-quick-modal__panel {
    position: relative;
    z-index: 1;
    width: min(100%, 980px);
    max-height: calc(100dvh - 36px);
    overflow-y: auto;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: #fff;
    padding: clamp(18px, 3vw, 28px);
    box-shadow: 0 28px 70px rgba(17, 17, 17, 0.32);
    -webkit-overflow-scrolling: touch;
}

.teos-quick-modal__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.teos-quick-modal__head h3 {
    margin: 0;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.05;
}

.teos-quick-modal__close {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border: 1px solid var(--teos-line);
    border-radius: 50%;
    background: var(--teos-soft);
    color: var(--teos-ink);
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
}

.teos-quick-modal__close:hover,
.teos-quick-modal__close:focus {
    border-color: var(--teos-ink);
    background: var(--teos-ink);
    color: #fff;
}

.teos-notice {
    border-radius: 6px;
    margin: 0 0 18px;
    padding: 13px 15px;
    font-weight: 700;
}

.teos-notice--success {
    background: #eaf7ef;
    color: var(--teos-good);
}

.teos-notice--error {
    background: #fff0ed;
    color: var(--teos-bad);
}

.teos-muted {
    display: block;
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 600;
}

.teos-filterbar {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    gap: 12px;
    margin-bottom: 18px;
}

.teos-filterbar label {
    min-width: 180px;
}

.teos-secondary-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 18px;
}

.teos-staff-location-filter {
    display: grid;
    gap: 7px;
    min-width: min(100%, 420px);
    font-weight: 700;
}

.teos-staff-location-filter > span {
    color: var(--teos-muted);
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-staff-location-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.teos-staff-search-field {
    display: grid;
    gap: 7px;
    min-width: min(100%, 360px);
    font-weight: 700;
}

.teos-staff-search-field label span {
    color: var(--teos-muted);
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-staff-search-control {
    display: flex;
    align-items: stretch;
    gap: 8px;
}

.teos-staff-search-control input {
    min-width: 0;
}

.teos-search-submit-button {
    flex: 0 0 auto;
    min-height: 44px;
    padding: 0 18px;
    font-size: 12px;
}

.teos-search-submit-button[hidden] {
    display: none;
}

.teos-switch-button {
    min-height: 44px;
    border: 1px solid var(--teos-line);
    border-radius: 6px;
    background: #fff;
    color: var(--teos-ink);
    padding: 0 14px;
    font: inherit;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.04em;
    cursor: pointer;
}

.teos-switch-button:hover,
.teos-switch-button:focus,
.teos-switch-button.is-active {
    border-color: var(--teos-ink);
    background: var(--teos-ink);
    color: #fff;
}

.teos-edit-actions,
.teos-delete-form {
    display: flex;
    justify-content: flex-start;
}

.teos-delete-form {
    border-top: 1px solid var(--teos-line);
    margin-top: 12px;
    padding-top: 12px;
}

.teos-button--danger {
    border-color: var(--teos-bad);
    background: var(--teos-bad);
    color: #fff;
}

.teos-button--danger:hover,
.teos-button--danger:focus {
    border-color: #86180f;
    background: #86180f;
}

.teos-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.teos-summary > div {
    min-height: 86px;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: var(--teos-soft);
    padding: 16px;
}

.teos-summary strong {
    display: block;
    font-size: 32px;
    line-height: 1;
}

.teos-summary span {
    display: block;
    margin-top: 8px;
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.teos-stat-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    margin: 18px 0;
}

.teos-stat-cards article,
.teos-stats-panel {
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: var(--teos-soft);
}

.teos-stat-cards article {
    min-height: 94px;
    padding: 16px;
}

.teos-stat-cards strong {
    display: block;
    font-size: 34px;
    line-height: 1;
}

.teos-stat-cards span {
    display: block;
    margin-top: 9px;
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.teos-stats-grid {
    display: grid;
    grid-template-columns: minmax(280px, 0.8fr) minmax(0, 1.2fr);
    gap: 18px;
}

.teos-stats-panel {
    padding: 16px;
}

.teos-stats-panel h3 {
    margin-top: 0;
}

.teos-top-months {
    display: grid;
    gap: 12px;
}

.teos-top-month {
    display: grid;
    gap: 7px;
}

.teos-top-month strong,
.teos-top-month span {
    display: block;
}

.teos-top-month span {
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 800;
}

.teos-top-month__bar {
    height: 12px;
    overflow: hidden;
    border-radius: 999px;
    background: #e8e1d7;
}

.teos-top-month__bar span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--teos-ink), var(--teos-accent));
}

.teos-stats-table {
    min-width: 940px;
}

.teos-coming-today {
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    margin: 16px 0;
    padding: 14px;
    background: #fff;
}

.teos-section-title {
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.teos-coming-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.teos-coming-item {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 4px 10px;
    align-items: baseline;
    border: 1px solid var(--teos-line);
    border-radius: 6px;
    padding: 10px;
    background: var(--teos-soft);
}

.teos-coming-item strong {
    font-size: 18px;
}

.teos-coming-item span {
    font-weight: 900;
}

.teos-coming-item em {
    grid-column: 2;
    color: var(--teos-muted);
    font-size: 12px;
    font-style: normal;
    font-weight: 700;
}

.teos-panel {
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    margin: 18px 0;
    padding: 16px;
}

.teos-panel summary {
    cursor: pointer;
    font-weight: 800;
    margin-bottom: 16px;
}

.teos-panel:not([open]) summary {
    margin-bottom: 0;
}

.teos-staff-settings {
    margin-top: 24px;
}

.teos-staff-settings__section {
    display: grid;
    gap: 14px;
    border-top: 1px solid var(--teos-line);
    padding-top: 18px;
}

.teos-staff-settings__section + .teos-staff-settings__section {
    margin-top: 24px;
}

.teos-staff-settings h3,
.teos-staff-location-settings h4 {
    margin: 0 0 6px;
}

.teos-blocked-date-add.teos-staff-blocked-form {
    grid-template-columns: minmax(180px, 240px) minmax(260px, 1fr) auto;
}

.teos-staff-special-hours-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.teos-staff-special-hours-form .teos-special-note-field,
.teos-staff-special-hours-form .teos-button {
    grid-column: 1 / -1;
}

.teos-simple-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 620px;
}

.teos-simple-table th,
.teos-simple-table td {
    border-bottom: 1px solid var(--teos-line);
    padding: 10px 12px;
    text-align: left;
    vertical-align: top;
}

.teos-simple-table th {
    color: var(--teos-muted);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-text-button {
    border: 0;
    background: transparent;
    color: var(--teos-bad);
    padding: 0;
    font: inherit;
    font-weight: 900;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.teos-staff-location-settings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.teos-staff-location-settings {
    min-width: 0;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: #fff;
    padding: 16px;
}

.teos-staff-public-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.teos-staff-hours-table {
    width: 100%;
}

.teos-table-wrap {
    overflow-x: auto;
    max-width: 100%;
    -webkit-overflow-scrolling: touch;
}

.teos-reservations-table {
    min-width: 900px;
}

.teos-reservations-table td,
.teos-reservations-table th {
    vertical-align: top;
}

.teos-status-form {
    display: flex;
    gap: 6px;
    align-items: center;
}

.teos-status-form select {
    max-width: 140px;
}

.teos-status-badge {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    border-radius: 999px;
    background: var(--teos-soft);
    color: var(--teos-ink);
    padding: 0 10px;
    font-size: 12px;
    font-weight: 900;
    margin-bottom: 8px;
}

.teos-checkin-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.teos-checkin-buttons form {
    margin: 0;
}

.teos-chip-button {
    min-height: 32px;
    border: 1px solid var(--teos-line);
    border-radius: 999px;
    background: #fff;
    color: var(--teos-ink);
    padding: 0 10px;
    font-size: 12px;
    font-weight: 900;
    cursor: pointer;
}

.teos-chip-button:hover,
.teos-chip-button:focus {
    border-color: var(--teos-ink);
    background: var(--teos-ink);
    color: #fff;
}

.teos-inline-edit {
    margin-top: 8px;
}

.teos-inline-edit summary {
    cursor: pointer;
    color: var(--teos-accent);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
}

.teos-edit-form {
    min-width: 520px;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    margin-top: 8px;
    padding: 12px;
    background: #fff;
}

.teos-edit-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 10px;
}

.teos-edit-grid label {
    display: grid;
    gap: 5px;
    font-weight: 800;
}

.teos-edit-grid span {
    color: var(--teos-muted);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-edit-grid input,
.teos-edit-grid select,
.teos-edit-grid textarea {
    width: 100%;
    min-height: 38px;
    border: 1px solid var(--teos-line);
    border-radius: 6px;
    padding: 8px;
}

.teos-edit-grid .teos-note-box label {
    display: grid;
    gap: 5px;
}

.teos-edit-grid .teos-note-box textarea {
    min-height: 128px;
    padding: 10px;
    line-height: 1.45;
}

.teos-edit-wide {
    grid-column: 1 / -1;
}

.teos-note-cell {
    min-width: 240px;
}

.teos-note-display {
    display: grid;
    gap: 4px;
    border: 1px solid #ece5dc;
    border-radius: 7px;
    background: #fffaf1;
    margin-bottom: 7px;
    padding: 8px 10px;
    white-space: normal;
}

.teos-note-display:last-child {
    margin-bottom: 0;
}

.teos-note-display strong {
    color: #7a5a24;
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-note-display span {
    color: var(--teos-ink);
    font-size: 13px;
    line-height: 1.42;
}

.teos-note-display--internal {
    border-color: #d8e5d1;
    background: #f4fbf0;
}

.teos-note-display--internal strong {
    color: var(--teos-good);
}

.teos-note-readonly-label {
    color: var(--teos-muted);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-note-readonly {
    min-height: 72px;
    border: 1px solid #ece5dc;
    border-radius: 7px;
    background: #fffaf1;
    padding: 10px 12px;
    color: var(--teos-ink);
    font-size: 13px;
    line-height: 1.45;
    white-space: normal;
}

.teos-internal-note {
    border-left: 3px solid var(--teos-accent);
    color: var(--teos-muted);
    margin-top: 6px;
    padding-left: 8px;
    font-size: 12px;
    font-weight: 800;
}

.teos-status-cancelled {
    opacity: 0.55;
}

.teos-status-waitlist td:first-child {
    border-left: 4px solid #c98b1d;
}

.teos-all-reservations {
    display: grid;
    gap: 14px;
    margin: 16px 0 18px;
}

.teos-all-reservations__head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 14px;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: #fff;
    padding: 16px;
}

.teos-all-reservations__head h3 {
    margin: 5px 0 0;
    font-size: 24px;
}

.teos-all-reservations__head p {
    margin: 5px 0 0;
}

.teos-all-reservations__totals {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.teos-all-reservations__totals span,
.teos-search-result-note {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    border: 1px solid var(--teos-line);
    border-radius: 999px;
    background: var(--teos-soft);
    padding: 0 11px;
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 900;
}

.teos-all-reservations__totals strong,
.teos-search-result-note strong {
    color: var(--teos-ink);
    margin-right: 4px;
}

.teos-search-result-note {
    justify-self: start;
    gap: 10px;
}

.teos-search-result-note a {
    color: var(--teos-ink);
}

.teos-month-field select,
.teos-year-field select {
    width: 100%;
    min-height: 44px;
    border: 1px solid var(--teos-line);
    border-radius: 6px;
    background: #fff;
    color: var(--teos-ink);
    padding: 0 12px;
    font: inherit;
    font-weight: 800;
}

.teos-month-calendar {
    display: grid;
    gap: 14px;
    margin: 16px 0 18px;
}

.teos-month-calendar__head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 14px;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: #fff;
    padding: 16px;
}

.teos-month-calendar__head h3 {
    margin: 5px 0 0;
    font-size: 24px;
}

.teos-month-calendar__totals {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.teos-month-calendar__totals span {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    border: 1px solid var(--teos-line);
    border-radius: 999px;
    background: var(--teos-soft);
    padding: 0 11px;
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 900;
}

.teos-month-calendar__totals strong {
    color: var(--teos-ink);
    margin-right: 4px;
}

.teos-month-calendar-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.teos-month-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(122px, 1fr));
    gap: 1px;
    min-width: 900px;
    overflow: hidden;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: var(--teos-line);
}

.teos-month-calendar-weekday {
    background: var(--teos-ink);
    color: #fff;
    padding: 10px 12px;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-month-day {
    min-height: 150px;
    background: #fff;
    padding: 0;
}

.teos-month-day--blank {
    min-height: 150px;
    background: #f1eee7;
}

.teos-month-day.is-past {
    background: #f0f0f0;
    color: #777;
}

.teos-month-day.is-past .teos-month-day-number {
    background: #dedede;
    color: #666;
}

.teos-month-day-button {
    display: grid;
    align-content: start;
    gap: 10px;
    width: 100%;
    min-height: 150px;
    border: 0;
    background: transparent;
    color: inherit;
    padding: 10px;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.teos-month-day.is-today {
    box-shadow: inset 0 0 0 2px var(--teos-ink);
}

.teos-month-day.is-selected {
    box-shadow: inset 0 0 0 2px var(--teos-accent);
}

.teos-month-day.is-selected .teos-month-day-number {
    background: var(--teos-accent);
    color: #fff;
}

.teos-month-day.is-blocked {
    background: #fff8e9;
}

.teos-month-day.is-special {
    background: #f5f8f1;
}

.teos-month-day.is-past.is-blocked {
    background: #f0f0f0;
}

.teos-month-day-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.teos-month-day-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 999px;
    background: var(--teos-soft);
    color: var(--teos-ink);
    font-size: 15px;
    font-weight: 900;
    text-decoration: none;
}

.teos-month-day-button:hover .teos-month-day-number,
.teos-month-day-button:focus .teos-month-day-number {
    background: var(--teos-ink);
    color: #fff;
}

.teos-month-day-button:focus-visible {
    outline: 3px solid rgba(138, 119, 88, 0.35);
    outline-offset: -3px;
}

.teos-month-day-header > span:last-child {
    color: var(--teos-muted);
    font-size: 11px;
    font-weight: 900;
}

.teos-month-day-tag {
    display: inline-flex;
    width: fit-content;
    border: 1px solid #e7c885;
    border-radius: 6px;
    background: #fff3d8;
    color: #7a4b00;
    padding: 6px 7px;
    font-size: 11px;
    font-weight: 900;
}

.teos-month-day-tag--special {
    border-color: #b9d2a6;
    background: #eef7e8;
    color: #2f5f24;
}

.teos-month-day-count {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 34px;
    border-radius: 999px;
    background: var(--teos-ink);
    color: #fff;
    padding: 0 12px;
    font-size: 12px;
    font-weight: 900;
}

.teos-month-day-count strong {
    margin-right: 5px;
    font-size: 16px;
}

.teos-month-empty {
    color: var(--teos-muted);
    font-size: 11px;
    font-weight: 900;
}

.teos-day-modal__panel {
    width: min(100%, 1120px);
}

.teos-day-modal {
    z-index: 100000;
}

.teos-month-day-detail {
    display: grid;
    gap: 14px;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: #fff;
    padding: 16px;
}

.teos-month-day-detail__head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 14px;
}

.teos-month-day-detail__head h3 {
    margin: 5px 0 0;
    font-size: 22px;
}

.teos-month-day-detail__totals {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.teos-month-day-detail__totals span {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    border: 1px solid var(--teos-line);
    border-radius: 999px;
    background: var(--teos-soft);
    padding: 0 11px;
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 900;
}

.teos-month-day-detail__totals strong {
    color: var(--teos-ink);
    margin-right: 4px;
}

.teos-day-modal-list {
    display: grid;
    gap: 10px;
    margin-top: 16px;
}

.teos-day-modal-reservation {
    display: grid;
    gap: 8px;
    border: 1px solid var(--teos-line);
    border-left: 5px solid var(--teos-accent);
    border-radius: 8px;
    background: #fff;
    padding: 12px;
}

.teos-day-modal-reservation__head,
.teos-day-modal-reservation__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.teos-day-modal-reservation__head {
    justify-content: space-between;
}

.teos-day-modal-reservation__head strong {
    font-size: 16px;
}

.teos-day-modal-reservation__head span,
.teos-day-modal-reservation__meta span,
.teos-day-modal-reservation__meta a {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    border-radius: 999px;
    background: var(--teos-soft);
    color: var(--teos-muted);
    padding: 0 10px;
    font-size: 12px;
    font-weight: 900;
    text-decoration: none;
}

.teos-day-modal-reservation__notes {
    display: grid;
    gap: 6px;
    border-top: 1px solid var(--teos-line);
    padding-top: 8px;
}

.teos-day-modal-reservation__notes p {
    margin: 0;
    color: var(--teos-muted);
    font-size: 13px;
    font-weight: 700;
}

.teos-day-modal-reservation--confirmed,
.teos-day-modal-reservation--seated,
.teos-day-modal-reservation--completed {
    border-left-color: #168a3a;
}

.teos-day-modal-reservation--pending,
.teos-day-modal-reservation--waitlist {
    border-left-color: #c47a12;
    background: #fffaf0;
}

.teos-day-modal-reservation--cancelled,
.teos-day-modal-reservation--no_show {
    border-left-color: #999;
    opacity: 0.72;
}

.teos-month-day-detail-empty {
    border: 1px dashed var(--teos-line);
    border-radius: 8px;
    background: var(--teos-soft);
    padding: 18px;
    color: var(--teos-muted);
    font-weight: 900;
}

.teos-timeline-view {
    display: grid;
    gap: 16px;
    margin-top: 16px;
}

.teos-timeline-location {
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
}

.teos-timeline-location-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid var(--teos-line);
    background: var(--teos-soft);
    padding: 14px 16px;
}

.teos-timeline-location-head h3 {
    margin: 0;
    font-size: 18px;
}

.teos-timeline-location-head span {
    display: block;
    color: var(--teos-muted);
    margin-top: 4px;
    font-size: 12px;
    font-weight: 800;
}

.teos-timeline-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.teos-timeline-grid {
    background:
        linear-gradient(90deg, rgba(222, 216, 205, 0.55) 1px, transparent 1px) 160px 0 / calc((100% - 160px) / 6) 100%,
        #fff;
}

.teos-timeline-head,
.teos-timeline-row {
    display: grid;
    grid-template-columns: 160px minmax(560px, 1fr);
}

.teos-timeline-head {
    position: sticky;
    top: 0;
    z-index: 2;
    min-height: 42px;
    border-bottom: 1px solid var(--teos-line);
    background: rgba(255, 255, 255, 0.95);
}

.teos-timeline-table-label {
    display: flex;
    align-items: center;
    border-right: 1px solid var(--teos-line);
    padding: 0 12px;
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-timeline-scale {
    position: relative;
}

.teos-timeline-scale span {
    position: absolute;
    top: 11px;
    transform: translateX(-50%);
    color: var(--teos-muted);
    font-size: 12px;
    font-weight: 900;
}

.teos-timeline-row {
    min-height: 66px;
    border-bottom: 1px solid #eee8df;
}

.teos-timeline-row-label {
    display: grid;
    align-content: center;
    border-right: 1px solid var(--teos-line);
    padding: 8px 12px;
    background: rgba(245, 242, 236, 0.75);
}

.teos-timeline-row-label strong {
    overflow: hidden;
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.teos-timeline-row-label span {
    color: var(--teos-muted);
    font-size: 11px;
    font-weight: 800;
}

.teos-timeline-track {
    position: relative;
}

.teos-timeline-bar {
    position: absolute;
    top: 9px;
    bottom: 9px;
    display: grid;
    align-content: center;
    min-width: 88px;
    overflow: hidden;
    border-radius: 8px;
    background: var(--teos-accent);
    color: #fff;
    padding: 8px 12px;
    box-shadow: 0 8px 18px rgba(17, 17, 17, 0.14);
}

.teos-timeline-bar strong,
.teos-timeline-bar span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.teos-timeline-bar strong {
    font-size: 13px;
}

.teos-timeline-bar span {
    font-size: 11px;
    font-weight: 800;
    opacity: 0.9;
}

.teos-bar-status-confirmed {
    background: #168a3a;
}

.teos-bar-status-seated {
    background: #1976d2;
}

.teos-bar-status-completed {
    background: #6f6a60;
}

.teos-bar-status-pending {
    background: #c47a12;
}

.teos-timeline-empty {
    padding: 18px;
    color: var(--teos-muted);
    font-weight: 800;
}

.teos-timeline-waitlist {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    border-top: 1px solid var(--teos-line);
    padding: 12px 16px;
}

.teos-timeline-waitlist strong,
.teos-timeline-waitlist span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    border-radius: 999px;
    padding: 0 10px;
    font-size: 12px;
    font-weight: 900;
}

.teos-timeline-waitlist strong {
    background: #fff4df;
    color: #8a5300;
}

.teos-timeline-waitlist span {
    background: var(--teos-soft);
}

.teos-status-seated td:first-child {
    border-left: 4px solid var(--teos-good);
}

.teos-staff-clock {
    color: var(--teos-muted);
    font-weight: 800;
}

.teos-admin-page {
    margin-top: 20px;
}

.teos-admin-grid,
.teos-calendar-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.teos-admin .teos-admin-card {
    padding: 20px;
    margin-bottom: 18px;
}

.teos-admin-card__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.teos-admin-card__head h2 {
    margin-bottom: 6px;
}

.teos-security-form {
    align-items: end;
    margin-top: 16px;
}

.teos-security-form p {
    margin: 0;
}

.teos-security-log-table td {
    vertical-align: top;
}

.teos-security-badge {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    border-radius: 999px;
    background: var(--teos-soft);
    color: var(--teos-muted);
    padding: 0 10px;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.teos-security-badge--success {
    background: #eaf7ef;
    color: var(--teos-good);
}

.teos-security-badge--failed,
.teos-security-badge--locked,
.teos-security-badge--blocked {
    background: #fff0ed;
    color: var(--teos-bad);
}

.teos-security-badge--unlocked {
    background: #eef5ff;
    color: #1d4f91;
}

.teos-blocked-date-add,
.teos-special-hours-add {
    display: grid;
    align-items: end;
    gap: 12px;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: var(--teos-soft);
    margin: 18px 0;
    padding: 14px;
}

.teos-blocked-date-add {
    grid-template-columns: minmax(180px, 240px) minmax(320px, 1fr) 46px;
}

.teos-special-hours-add {
    grid-template-columns: minmax(150px, 1fr) minmax(160px, 1fr) minmax(110px, 0.7fr) minmax(110px, 0.7fr) minmax(210px, 1.2fr) 46px;
}

.teos-blocked-date-add label,
.teos-special-hours-add label {
    display: grid;
    gap: 6px;
    font-weight: 800;
}

.teos-blocked-date-add label span,
.teos-special-hours-add label span,
.teos-blocked-reason-field > span {
    color: var(--teos-muted);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.teos-blocked-date-add input,
.teos-special-hours-add input,
.teos-special-hours-add select {
    width: 100%;
    min-height: 38px;
    border: 1px solid var(--teos-line);
    border-radius: 6px;
    padding: 8px 10px;
}

.teos-blocked-reason-field {
    display: grid;
    gap: 8px;
    min-width: 0;
}

.teos-blocked-reason-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.teos-blocked-reason-button {
    min-height: 36px;
    border: 1px solid var(--teos-line);
    border-radius: 999px;
    background: #fff;
    color: var(--teos-ink);
    padding: 0 12px;
    font-size: 12px;
    font-weight: 900;
    cursor: pointer;
}

.teos-blocked-reason-button:hover,
.teos-blocked-reason-button:focus,
.teos-blocked-reason-button.is-active {
    border-color: var(--teos-accent);
    background: var(--teos-ink);
    color: #fff;
}

.teos-plus-button {
    min-height: 38px;
    font-size: 22px !important;
    line-height: 1 !important;
}

.teos-blocked-date-list,
.teos-special-hours-list {
    margin-top: 12px;
}

.teos-blocked-date-list .teos-muted,
.teos-special-hours-list .teos-muted {
    display: block;
    margin-top: 4px;
}

.teos-inline-delete {
    margin: 0;
}

.teos-calendar-location {
    min-width: 0;
    overflow: hidden;
}

.teos-calendar-location .teos-table-wrap {
    border: 1px solid #c3c4c7;
    margin-top: 10px;
}

.teos-calendar-location .teos-reservations-table {
    border: 0;
}

.teos-settings-form h2,
.teos-email-form h2 {
    margin-top: 8px;
}

.teos-location-settings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    align-items: start;
    margin-top: 16px;
}

.teos-location-settings,
.teos-email-template {
    border-top: 1px solid var(--teos-line);
    margin-top: 22px;
    padding-top: 18px;
}

.teos-location-settings {
    min-width: 0;
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: #fff;
    margin-top: 0;
    padding: 18px;
}

.teos-location-settings .teos-admin-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.teos-location-settings h3,
.teos-email-template h3 {
    margin-top: 0;
}

.teos-hours-wrap {
    overflow-x: auto;
    margin-top: 14px;
    -webkit-overflow-scrolling: touch;
}

.teos-hours-table {
    min-width: 620px;
}

.teos-slot-map {
    display: grid;
    gap: 8px;
    margin: 16px 0 22px;
}

.teos-slot-row {
    display: grid;
    grid-template-columns: 58px 1fr 64px;
    align-items: center;
    gap: 10px;
}

.teos-capacity-bar {
    height: 12px;
    overflow: hidden;
    border-radius: 999px;
    background: #ece7dd;
}

.teos-capacity-bar span {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, var(--teos-good), var(--teos-accent));
}

.teos-slot-time,
.teos-slot-count {
    font-size: 12px;
    font-weight: 800;
}

.teos-shortcode-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 20px;
}

.teos-shortcode-list article {
    border: 1px solid var(--teos-line);
    border-radius: 8px;
    background: var(--teos-soft);
    padding: 16px;
}

.teos-shortcode-list h3 {
    margin-top: 0;
}

.teos-shortcode-list code,
.teos-admin-card code {
    display: inline-block;
    max-width: 100%;
    white-space: normal;
    padding: 8px 10px;
    border-radius: 6px;
    background: #111;
    color: #fff;
}

@media print {
    .teos-reservation {
        width: 100%;
        max-width: none;
        border: 0;
        box-shadow: none;
        margin: 0;
        padding: 0;
    }

    .teos-note-tools,
    .teos-form--compact,
    .teos-filterbar,
    .teos-view-toggle,
    .teos-checkin-buttons,
    .teos-inline-edit,
    .teos-delete-form,
    .teos-staff-quick-add,
    .teos-quick-modal,
    .teos-button {
        display: none !important;
    }

    .teos-reservations-table {
        font-size: 11px;
    }

    .teos-reservations-table th,
    .teos-reservations-table td {
        padding: 7px 8px;
        vertical-align: top;
    }

    .teos-note-cell {
        min-width: 260px;
    }

    .teos-note-display {
        break-inside: avoid;
        border-color: #111;
        background: #fff;
        color: #000;
        padding: 7px 8px;
    }

    .teos-note-display strong,
    .teos-note-display span {
        color: #000;
    }
}

@media (min-width: 901px) {
    .teos-public-reservation .teos-date-field {
        min-height: 88px;
    }

    .teos-public-reservation .teos-date-field input,
    .teos-public-reservation .teos-date-field button {
        min-height: 88px;
    }
}

@media (max-width: 900px) {
    .teos-grid--booking,
    .teos-grid--staff,
    .teos-admin-fields,
    .teos-admin-grid,
    .teos-calendar-grid,
    .teos-location-settings-grid,
    .teos-location-settings .teos-admin-fields,
    .teos-stats-grid,
    .teos-shortcode-list,
    .teos-summary {
        grid-template-columns: 1fr;
    }

    .teos-stat-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .teos-staff .teos-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .teos-admin-card__head {
        display: grid;
    }

    .teos-security-form {
        align-items: stretch;
    }

    .teos-staff-search-field,
    .teos-staff-search-control {
        width: 100%;
    }

    .teos-staff-search-control {
        flex-wrap: wrap;
    }

    .teos-staff-search-control input,
    .teos-search-submit-button {
        flex: 1 1 100%;
    }

    .teos-public-reservation [data-teos-submit-button] {
        width: 100%;
        min-height: 58px;
    }

    .teos-staff-quick-add {
        left: calc(14px + env(safe-area-inset-left));
        bottom: calc(14px + env(safe-area-inset-bottom));
        width: 58px;
        height: 58px;
    }

    .teos-staff-quick-add__button {
        width: 58px;
        height: 58px;
    }

    .teos-staff-quick-add__button span {
        font-size: 42px;
    }

    .teos-quick-modal {
        align-items: start;
        padding: 10px;
    }

    .teos-quick-modal__panel {
        max-height: calc(100dvh - 20px);
    }

    .teos-day-modal {
        align-items: start;
        justify-items: stretch;
        overflow-y: auto;
        padding: calc(72px + env(safe-area-inset-top)) 12px calc(96px + env(safe-area-inset-bottom));
    }

    .teos-day-modal__panel {
        width: 100%;
        max-height: calc(100vh - 168px);
        max-height: calc(100svh - 168px);
    }

    .teos-form--compact .teos-grid--staff {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .teos-form--compact .teos-grid--staff > label,
    .teos-form--compact .teos-grid--staff .teos-guest-control,
    .teos-form--compact .teos-grid--staff .teos-note-box {
        grid-column: 1 / -1;
    }

    .teos-form--compact .teos-grid--staff .teos-staff-duration-field,
    .teos-form--compact .teos-grid--staff .teos-staff-time-field {
        grid-column: auto;
    }

    .teos-staff .teos-filterbar .teos-month-field,
    .teos-staff .teos-filterbar .teos-year-field {
        flex: 1 1 calc(50% - 6px);
        min-width: 0;
    }

    .teos-staff .teos-staff-location-filter {
        width: 100%;
        min-width: 0;
    }

    .teos-staff .teos-staff-location-buttons[aria-label="Ort filtern"] {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 6px;
        width: 100%;
    }

    .teos-staff .teos-staff-location-buttons[aria-label="Ort filtern"] .teos-switch-button {
        width: 100%;
        min-width: 0;
        min-height: 54px;
        padding: 0 6px;
        font-size: 12px;
        line-height: 1.15;
        letter-spacing: 0.01em;
        white-space: normal;
    }

    .teos-all-reservations__head {
        display: grid;
        align-items: start;
    }

    .teos-all-reservations__totals {
        justify-content: flex-start;
    }

    .teos-month-calendar__head {
        display: grid;
        align-items: start;
    }

    .teos-month-calendar__totals {
        justify-content: flex-start;
    }

    .teos-month-day-detail__head {
        display: grid;
        align-items: start;
    }

    .teos-month-day-detail__totals {
        justify-content: flex-start;
    }

    .teos-location-buttons {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .teos-form .teos-location-button span {
        min-height: 58px;
        padding: 12px 8px;
        font-size: 14px;
    }

    .teos-coming-list,
    .teos-edit-grid,
    .teos-blocked-date-add,
    .teos-blocked-date-add.teos-staff-blocked-form,
    .teos-special-hours-add,
    .teos-staff-special-hours-form,
    .teos-staff-location-settings-grid,
    .teos-staff-public-fields {
        grid-template-columns: 1fr;
    }

    .teos-coming-item em {
        grid-column: 1 / -1;
    }

    .teos-edit-form {
        min-width: 0;
    }

    .teos-timeline-head,
    .teos-timeline-row {
        grid-template-columns: 128px minmax(520px, 1fr);
    }

    .teos-timeline-grid {
        background:
            linear-gradient(90deg, rgba(222, 216, 205, 0.55) 1px, transparent 1px) 128px 0 / calc((100% - 128px) / 6) 100%,
            #fff;
    }

    .teos-reservation__header--split {
        display: block;
    }

    .teos-filterbar {
        display: grid;
    }

    .teos-staff .teos-filterbar--calendar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .teos-staff .teos-filterbar--calendar .teos-month-field,
    .teos-staff .teos-filterbar--calendar .teos-year-field {
        grid-column: auto;
        min-width: 0;
    }

    .teos-staff .teos-filterbar--calendar .teos-staff-location-filter {
        grid-column: 1 / -1;
    }

    .teos-filterbar label {
        min-width: 0;
    }
}

@media (max-width: 520px) {
    .teos-date-field {
        gap: 6px;
    }

    .teos-date-field .teos-mini-button {
        padding: 0 8px;
        font-size: 11px;
    }
}
