.ezwp-booking-calendar-field {
    border: 1px solid #d8dee4;
    border-radius: 8px;
    padding: 12px;
    background: #fff;
}

.ezwp-booking-calendar-field.ezwp-booking-calendar-admin-mode {
    border-color: #93c5fd;
    background: #eff6ff;
    box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.08);
}

.ezwp-booking-calendar-admin-mode .ezwp-booking-calendar-slot-day {
    border-color: #bfdbfe;
    background: rgba(255, 255, 255, 0.78);
}

.ezwp-booking-calendar-admin-mode .ezwp-booking-calendar-summary {
    margin: 0 0 14px;
    border-color: #7dd3fc;
    background: #e0f2fe;
    color: #0c4a6e;
    box-shadow: 0 2px 8px rgba(14, 116, 144, 0.08);
}

.ezwp-booking-calendar {
    min-height: 520px;
}

.ezwp-booking-calendar-toolbar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 8px;
}

.ezwp-booking-calendar-view-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.ezwp-booking-calendar-view-toggle {
    margin-bottom: 0;
}

.ezwp-booking-calendar-extended-wrap {
    margin: 0;
    padding: 6px 10px 6px 2.5em;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    background: #f8fafc;
}

.ezwp-booking-calendar-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-top: 10px;
    padding: 9px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    background: #f8fafc;
    color: #334155;
    font-size: 0.9rem;
}

.ezwp-booking-calendar-clear {
    margin-left: auto;
}

.ezwp-booking-calendar-summary-pending {
    color: #92400e;
    font-size: 0.82rem;
    font-weight: 600;
}

.ezwp-booking-calendar-summary-actions {
    min-width: 130px;
}

.ezwp-booking-calendar-user-comment {
    flex: 1 0 100%;
}

.ezwp-booking-calendar-user-comment[hidden] {
    display: none;
}

.ezwp-booking-calendar-user-comment .form-label {
    margin-bottom: 4px;
    font-size: 0.82rem;
    font-weight: 700;
}

.ezwp-booking-calendar-user-comment textarea {
    min-height: 76px;
    resize: vertical;
}

.ezwp-booking-calendar-current-booking {
    margin-bottom: 12px;
    padding: 12px;
    border: 1px solid #93c5fd;
    border-radius: 8px;
    background: #eff6ff;
    color: #1e3a8a;
}

.ezwp-booking-calendar-current-header,
.ezwp-booking-calendar-current-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.ezwp-booking-calendar-current-header {
    margin-bottom: 10px;
}

.ezwp-booking-calendar-current-status-pending {
    background: #f59e0b;
    color: #111827;
}

.ezwp-booking-calendar-current-status-booked {
    background: #16a34a;
    color: #fff;
}

.ezwp-booking-calendar-current-status-reserved {
    background: #2563eb;
    color: #fff;
}

.ezwp-booking-calendar-current-status-cancelled {
    background: #dc2626;
    color: #fff;
}

.ezwp-booking-calendar-summary-slot-label {
    color: #475569;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.ezwp-booking-calendar-summary-help,
.ezwp-booking-calendar-reschedule-notice {
    color: #1d4ed8;
    font-size: 0.82rem;
}

.ezwp-booking-calendar-reschedule-notice {
    margin-top: 10px;
    padding-top: 9px;
    border-top: 1px solid #bfdbfe;
}

.ezwp-booking-calendar-staged-slot {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    margin-bottom: 12px;
    padding: 10px;
    border-bottom: 1px solid #60a5fa;
    background: #dbeafe;
}

.ezwp-booking-calendar-staged-info {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    align-items: center;
}

.ezwp-booking-calendar-staged-date {
    color: #1e3a8a;
}

.ezwp-booking-calendar-staged-slot .ezwp-booking-calendar-slot-btn,
.ezwp-booking-calendar-admin-booking > .ezwp-booking-calendar-slot-btn {
    display: inline-flex;
    width: fit-content;
    min-width: 88px;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
}

.ezwp-booking-calendar-staged-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
}

.ezwp-booking-calendar-admin-details {
    display: grid;
    grid-template-columns: minmax(180px, 0.45fr) minmax(260px, 1fr);
    gap: 16px;
    align-items: start;
}

.ezwp-booking-calendar-admin-booking {
    display: grid;
    gap: 9px;
}

.ezwp-booking-calendar-admin-date {
    color: #1e3a8a;
    font-size: 1rem;
    font-weight: 700;
}

.ezwp-booking-calendar-respondent-comment {
    padding: 8px;
    border: 1px solid #bfdbfe;
    border-radius: 6px;
    background: #fff;
    color: #334155;
    white-space: pre-wrap;
}

.ezwp-booking-calendar-admin-field {
    min-width: 0;
}

.ezwp-booking-calendar-admin-field .form-label {
    margin-bottom: 4px;
    color: #1e3a8a;
    font-size: 0.82rem;
    font-weight: 700;
}

.ezwp-booking-calendar-admin-comment textarea {
    min-height: 108px;
    resize: vertical;
}

.ezwp-booking-calendar-update-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
}

.ezwp-booking-calendar-pending-decision {
    display: grid;
    gap: 7px;
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid #bfdbfe;
}

.ezwp-booking-calendar-pending-decision .ezwp-booking-calendar-pending-actions {
    width: fit-content;
}

.ezwp-booking-calendar-save-details {
    display: inline-flex;
    gap: 7px;
    align-items: center;
    justify-content: center;
    min-width: 92px;
}

.ezwp-booking-calendar-update-spinner[hidden] {
    display: none;
}

.ezwp-booking-calendar-respondent-booking,
.ezwp-booking-calendar-respondent-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.ezwp-booking-calendar-respondent-actions {
    justify-content: flex-end;
    margin-top: 10px;
}

.ezwp-booking-calendar-cancellation-warning {
    margin-top: 10px;
}

.ezwp-booking-calendar-change-comparison {
    display: grid;
    gap: 8px;
}

.ezwp-booking-calendar-change-row {
    display: grid;
    gap: 8px;
    padding: 10px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #f8fafc;
}

.ezwp-booking-calendar-change-row:last-child {
    border-color: #93c5fd;
    background: #eff6ff;
}

.ezwp-booking-calendar-change-label {
    color: #64748b;
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
}

.ezwp-booking-calendar-change-details {
    display: grid;
    grid-template-columns: minmax(140px, 1fr) minmax(90px, 0.45fr) minmax(120px, 0.55fr);
    gap: 12px;
    align-items: end;
}

.ezwp-booking-calendar-change-item {
    display: grid;
    gap: 4px;
}

.ezwp-booking-calendar-change-item-label {
    color: #64748b;
    font-size: 0.74rem;
    font-weight: 700;
}

.ezwp-booking-calendar-change-item .ezwp-booking-calendar-slot-btn {
    display: inline-flex;
    width: fit-content;
    min-width: 80px;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
}

.ezwp-booking-calendar-status {
    margin-top: 8px;
    color: #b45309;
    font-size: 0.88rem;
    font-weight: 600;
}

.ezwp-booking-calendar-slots {
    display: grid;
    gap: 12px;
}

.ezwp-booking-calendar-slots-header {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) 38px;
    gap: 8px;
    align-items: center;
}

.ezwp-booking-calendar-slots-range {
    color: #0f172a;
    font-size: 0.95rem;
    font-weight: 700;
    text-align: center;
}

.ezwp-booking-calendar-slots-nav {
    min-width: 38px;
}

.ezwp-booking-calendar-booked-toggle {
    white-space: nowrap;
}

.ezwp-booking-calendar-status-filter {
    position: relative;
}

.ezwp-booking-calendar-admin-filter {
    width: auto;
    min-width: 170px;
    border-color: #93c5fd;
    background-color: #fff;
}

.ezwp-booking-calendar-status-filter > summary {
    min-width: 130px;
    list-style: none;
    cursor: pointer;
}

.ezwp-booking-calendar-status-filter > summary::-webkit-details-marker {
    display: none;
}

.ezwp-booking-calendar-status-filter-menu {
    position: absolute;
    z-index: 20;
    top: calc(100% + 4px);
    right: 0;
    width: max-content;
    min-width: 190px;
    padding: 6px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.14);
}

.ezwp-booking-calendar-status-filter-option {
    display: flex;
    gap: 8px;
    align-items: center;
    margin: 0;
    padding: 6px 8px;
    border-radius: 4px;
    cursor: pointer;
    white-space: nowrap;
}

.ezwp-booking-calendar-status-filter-option:hover {
    background: #f1f5f9;
}

.ezwp-booking-calendar-status-filter-option .form-check-input {
    flex: 0 0 auto;
    margin: 0;
}

.ezwp-booking-calendar-slot-control {
    display: grid;
    gap: 4px;
}

.ezwp-booking-calendar-slot-status {
    min-width: 0;
    font-size: 0.75rem;
}

.ezwp-booking-calendar-pending-actions {
    display: flex;
    width: 100%;
}

.ezwp-booking-calendar-pending-actions > .btn:first-child {
    flex: 1 1 auto;
}

.ezwp-booking-calendar-pending-actions .btn {
    padding-right: 6px;
    padding-left: 6px;
    font-size: 0.72rem;
}

.ezwp-booking-calendar-pending-more {
    position: relative;
}

.ezwp-booking-calendar-pending-more > summary {
    height: 100%;
    list-style: none;
    cursor: pointer;
}

.ezwp-booking-calendar-pending-more > summary::-webkit-details-marker {
    display: none;
}

.ezwp-booking-calendar-pending-menu {
    position: absolute;
    z-index: 20;
    top: calc(100% + 3px);
    right: 0;
    min-width: 90px;
    padding: 5px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.14);
}

.ezwp-booking-calendar-pending-menu .btn {
    width: 100%;
}

.ezwp-booking-calendar-slot-day {
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 10px;
    background: #f8fafc;
}

.ezwp-booking-calendar-slot-date {
    margin-bottom: 8px;
    color: #0f172a;
    font-size: 0.94rem;
    font-weight: 700;
}

.ezwp-booking-calendar-slot-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(86px, 1fr));
    gap: 8px;
    transition: opacity 0.14s ease, transform 0.14s ease;
}

.ezwp-booking-calendar-slot-btn {
    min-height: 38px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #fff;
    color: #1e293b;
    font-weight: 600;
    cursor: pointer;
}

.ezwp-booking-calendar-slot-btn:hover,
.ezwp-booking-calendar-slot-btn:focus {
    border-color: #2563eb;
    color: #1d4ed8;
    outline: none;
}

.ezwp-booking-calendar-slots-earlier,
.ezwp-booking-calendar-slots-later {
    border-style: dashed;
    background: transparent;
    color: #64748b;
    font-weight: 500;
}

.ezwp-booking-calendar-slots-earlier:hover,
.ezwp-booking-calendar-slots-earlier:focus,
.ezwp-booking-calendar-slots-later:hover,
.ezwp-booking-calendar-slots-later:focus {
    border-color: #94a3b8;
    color: #334155;
}

.ezwp-booking-calendar-slot-day-selected {
    border-color: #93c5fd;
    background: #eff6ff;
}

.ezwp-booking-calendar-selected-content {
    display: flex;
    gap: 12px;
    align-items: center;
}

.ezwp-booking-calendar-selected-choice {
    display: grid;
    gap: 5px;
    min-width: 96px;
    text-align: center;
}

.ezwp-booking-calendar-selected-pending {
    display: block;
}

.ezwp-booking-calendar-selected-confirmed {
    display: block;
}

.ezwp-booking-calendar-selected-notice {
    flex: 1 1 auto;
    color: #92400e;
    font-size: 0.86rem;
    font-weight: 600;
    line-height: 1.35;
}

.ezwp-booking-calendar-selected-update-notice {
    color: #1d4ed8;
}

.ezwp-booking-calendar-slot-selected {
    border-color: #2563eb;
    background: #2563eb;
    color: #fff;
}

.ezwp-booking-calendar-slot-selected:hover,
.ezwp-booking-calendar-slot-selected:focus {
    border-color: #1d4ed8;
    background: #1d4ed8;
    color: #fff;
}

.ezwp-booking-calendar-slot-selected-static,
.ezwp-booking-calendar-slot-selected-static:hover,
.ezwp-booking-calendar-slot-selected-static:focus {
    border-color: #2563eb;
    background: #2563eb;
    color: #fff;
    cursor: default;
}

.ezwp-booking-calendar-slot-admin-selected,
.ezwp-booking-calendar-slot-admin-selected:disabled,
.ezwp-booking-calendar-slot-admin-selected:hover,
.ezwp-booking-calendar-slot-admin-selected:focus {
    border-color: #2563eb;
    background: #dbeafe;
    color: #1d4ed8;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.18);
    cursor: pointer;
    opacity: 1;
}

.ezwp-booking-calendar-admin-slot-summary {
    display: grid;
    flex: 1 0 100%;
    gap: 12px;
}

.ezwp-booking-calendar-admin-slot-empty {
    color: #475569;
}

.ezwp-booking-calendar-admin-slot-heading,
.ezwp-booking-calendar-admin-slot-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    justify-content: space-between;
}

.ezwp-booking-calendar-admin-slot-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
}

.ezwp-booking-calendar-admin-slot-detail {
    display: grid;
    gap: 3px;
    padding: 8px 10px;
    border: 1px solid #bae6fd;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.86);
}

.ezwp-booking-calendar-admin-slot-label {
    color: #64748b;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.ezwp-booking-calendar-slot-booked,
.ezwp-booking-calendar-slot-booked:disabled {
    border-color: #cbd5e1;
    background: #f1f5f9;
    color: #64748b;
    cursor: not-allowed;
    font-size: 13px;
    font-weight: 500;
}

.ezwp-booking-calendar-slot-booked:hover,
.ezwp-booking-calendar-slot-booked:focus {
    border-color: #cbd5e1;
    color: #64748b;
}

.ezwp-booking-calendar-slot-current,
.ezwp-booking-calendar-slot-current:disabled,
.ezwp-booking-calendar-slot-current:hover,
.ezwp-booking-calendar-slot-current:focus {
    border-color: #dc2626;
    background: #fee2e2;
    color: #b91c1c;
    cursor: not-allowed;
    font-weight: 700;
    opacity: 1;
}

.ezwp-booking-calendar-field .fc .ezwp-booking-calendar-event-current {
    border-color: #b91c1c;
    background-color: #dc2626;
}

.ezwp-booking-calendar-slots-empty,
.ezwp-booking-calendar-slots-note {
    border: 1px dashed #cbd5e1;
    border-radius: 6px;
    padding: 12px;
    background: #f8fafc;
    color: #475569;
    font-size: 0.92rem;
}

.ezwp-slots-slide-out-left,
.ezwp-slots-slide-out-right {
    opacity: 0;
}

.ezwp-slots-slide-out-left {
    transform: translateX(-10px);
}

.ezwp-slots-slide-out-right {
    transform: translateX(10px);
}

.ezwp-slots-slide-in-left,
.ezwp-slots-slide-in-right {
    animation-duration: 0.16s;
    animation-timing-function: ease;
}

.ezwp-slots-slide-in-left {
    animation-name: ezwpSlotsInLeft;
}

.ezwp-slots-slide-in-right {
    animation-name: ezwpSlotsInRight;
}

@keyframes ezwpSlotsInLeft {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes ezwpSlotsInRight {
    from {
        opacity: 0;
        transform: translateX(10px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@media (prefers-reduced-motion: reduce) {
    .ezwp-booking-calendar-slot-grid {
        transition: none;
    }

    .ezwp-slots-slide-in-left,
    .ezwp-slots-slide-in-right {
        animation: none;
    }
}

@media (max-width: 640px) {
    .ezwp-booking-calendar-change-details {
        grid-template-columns: 1fr;
    }

    .ezwp-booking-calendar-staged-slot {
        grid-template-columns: 1fr;
    }

    .ezwp-booking-calendar-staged-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .ezwp-booking-calendar-admin-details {
        grid-template-columns: 1fr;
    }

    .ezwp-booking-calendar-save-details {
        width: 100%;
    }

    .ezwp-booking-calendar-selected-content {
        align-items: stretch;
        flex-direction: column;
    }

    .ezwp-booking-calendar-field {
        padding: 8px;
    }

    .ezwp-booking-calendar {
        min-height: 460px;
    }

    .ezwp-booking-calendar-toolbar {
        justify-content: stretch;
    }

    .ezwp-booking-calendar-extended-wrap {
        width: 100%;
    }

    .ezwp-booking-calendar-field .fc .fc-toolbar {
        align-items: stretch;
        flex-direction: column;
        gap: 8px;
    }

    .ezwp-booking-calendar-field .fc .fc-toolbar-chunk {
        display: flex;
        justify-content: center;
    }

    .ezwp-booking-calendar-field .fc .fc-button {
        padding: 0.28rem 0.45rem;
        font-size: 0.82rem;
    }

    .ezwp-booking-calendar-summary {
        display: block;
    }

    .ezwp-booking-calendar-clear {
        margin-top: 8px;
        margin-left: 0;
        width: 100%;
    }

    .ezwp-booking-calendar-slot-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
