/**
 * Room Calendar Booking Styles
 * File: assets/css/calendar-booking.css
 */

/* Main Container */
.rrs-calendar-booking-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* Grid Layout */
.rrs-calendar-booking-grid {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 40px;
    align-items: start;
}

/* Calendar Section */
.rrs-calendar-section {
    width: 100%;
}

.rrs-calendar-wrapper {
    background: #ffffff;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.08);
}

.rrs-calendar-header {
    margin-bottom: 24px;
}

.rrs-calendar-header h3 {
    font-size: 28px;
    font-weight: 700;
    color: #222;
    margin: 0 0 8px 0;
    letter-spacing: -0.5px;
}

.rrs-calendar-subtitle {
    font-size: 14px;
    color: #717171;
    margin: 0;
}

/* Inline Calendar */
.rrs-inline-calendar {
    width: 100%;
}

.flatpickr-calendar.inline {
    width: 100% !important;
    max-width: none !important;
    box-shadow: none !important;
    border: none !important;
}

.flatpickr-months {
    padding: 16px 0;
}

.flatpickr-month {
    height: auto;
}

.flatpickr-current-month {
    color: #222;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 8px 0;
    font-size: 14px;
    font-weight: 600 !important;
}

.flatpickr-current-month .numInputWrapper input {
    font-weight: 700;
}

.flatpickr-weekdays {
    height: 40px;
    align-items: center;
}

.flatpickr-weekday {
    font-size: 12px;
    font-weight: 600;
    color: #717171;
    text-transform: uppercase;
}

.flatpickr-days {
    width: 100% !important;
}

.dayContainer {
    display: block !important;
}

.flatpickr-day {
    height: 37px !important;
    max-width: 38px !important;
    font-size: 14px;
    color: #222;
    border: 1px solid transparent;
    margin: 2px;
}

.flatpickr-day:hover {
    background: #f7f7f7;
    border-color: #e0e0e0;
}

.flatpickr-day.today {
    border-color: #222;
    font-weight: 600;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange {
    background: #222 !important;
    border-color: #222 !important;
    color: #fff !important;
    font-weight: 600;
}

.flatpickr-day.inRange {
    background: #f7f7f7;
    border-color: transparent;
    box-shadow: -5px 0 0 #f7f7f7, 5px 0 0 #f7f7f7;
}

.flatpickr-day.disabled,
.flatpickr-day.rrs-booked-date {
    color: #dddddd !important;
    cursor: not-allowed !important;
    background: #f7f7f7;
    text-decoration: line-through;
}

.flatpickr-day.disabled:hover,
.flatpickr-day.rrs-booked-date:hover {
    background: #f7f7f7 !important;
    border-color: transparent !important;
}

/* Calendar Legend */
.rrs-calendar-legend {
    display: flex;
    gap: 24px;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid #ebebeb;
}

.rrs-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #717171;
}

.rrs-legend-color {
    width: 16px;
    height: 16px;
    border-radius: 4px;
    display: inline-block;
}

.rrs-legend-color.rrs-available {
    background: #ffffff;
    border: 2px solid #222;
}

.rrs-legend-color.rrs-selected {
    background: #222;
}

.rrs-legend-color.rrs-booked {
    background: #f7f7f7;
    border: 2px solid #dddddd;
}

/* Booking Summary Section */
.rrs-booking-summary-section {
    position: sticky;
    top: 100px;
}

.rrs-booking-summary {
    background: #ffffff;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.12);
    border: 1px solid #ebebeb;
}

/* Price Header */
.rrs-price-header {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid #ebebeb;
}

.rrs-price-amount {
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.rrs-price-value {
    font-size: 28px;
    font-weight: 700;
    color: #222;
    letter-spacing: -0.5px;
}

.rrs-price-period {
    font-size: 16px;
    color: #717171;
    font-weight: 400;
}

/* Date Inputs */
.rrs-date-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 16px;
}

.rrs-date-input-group {
    display: flex;
    flex-direction: column;
}

.rrs-date-input-group label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #222;
    margin-bottom: 6px;
}

.rrs-date-display {
    padding: 12px 14px;
    border: 1px solid #b0b0b0;
    border-radius: 8px;
    font-size: 14px;
    color: #222;
    background: #ffffff;
    cursor: pointer;
    transition: all 0.2s;
    width: 100%;
}

.rrs-date-display:focus {
    outline: none;
    border-color: #222;
    box-shadow: 0 0 0 2px rgba(34, 34, 34, 0.1);
}

.rrs-date-display::placeholder {
    color: #b0b0b0;
}

/* Guests Input */
.rrs-guests-input {
    margin-bottom: 20px;
}

.rrs-guests-input label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #222;
    margin-bottom: 6px;
    display: block;
}

.rrs-guests-select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #b0b0b0;
    border-radius: 8px;
    font-size: 14px;
    color: #222;
    background: #ffffff;
    cursor: pointer;
    transition: all 0.2s;
}

.rrs-guests-select:focus {
    outline: none;
    border-color: #222;
    box-shadow: 0 0 0 2px rgba(34, 34, 34, 0.1);
}

/* Reserve Button */
.rrs-reserve-btn {
    width: 100% !important;
    padding: 16px 32px;
    background: #A98B2C;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: none !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.rrs-reserve-btn:hover:not(:disabled) {
    transform: translateY(-2px);
}

.rrs-reserve-btn:disabled {
    background: #ebebeb;
    color: #b0b0b0;
    cursor: not-allowed;
    box-shadow: none;
}

.rrs-no-charge-text {
    text-align: center;
    font-size: 13px;
    color: #717171;
    margin: 12px 0 0 0;
}

/* Price Breakdown */
.rrs-price-breakdown {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid #ebebeb;
}

.rrs-price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    font-size: 14px;
    color: #222;
}

.rrs-price-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 16px;
    border-top: 1px solid #ebebeb;
    font-size: 16px;
    font-weight: 600;
    color: #222;
}

/* Modal */
.rrs-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rrs-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.rrs-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    font-size: 32px;
    color: #717171;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.rrs-modal-close:hover {
    background: #f7f7f7;
    color: #222;
}

.rrs-modal-booking-summary {
    background: #f7f7f7;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 32px;
}

.rrs-modal-booking-summary h3 {
    font-size: 18px;
    font-weight: 600;
    color: #222;
    margin: 0 0 16px 0;
}

.rrs-modal-dates {
    display: grid;
    gap: 12px;
}

.rrs-modal-dates div {
    font-size: 14px;
    color: #222;
}

.rrs-modal-dates strong {
    font-weight: 600;
    margin-right: 8px;
}

/* Form Styles */
.rrs-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.rrs-form-group {
    margin-bottom: 16px;
}

.rrs-form-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #222;
    margin-bottom: 8px;
}

.rrs-form-group textarea {
    resize: vertical;
    min-height: 100px;
}


/* Responsive */
@media (max-width: 1024px) {
    .rrs-calendar-booking-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .rrs-booking-summary-section {
        position: static;
    }

    .rrs-booking-summary {
        max-width: 500px;
        margin: 0 auto;
    }
}

@media (max-width: 768px) {
    .rrs-calendar-booking-container {
        padding: 24px 16px;
    }

    .rrs-calendar-wrapper,
    .rrs-booking-summary {
        padding: 24px;
    }

    .rrs-calendar-header h3 {
        font-size: 24px;
    }

    .flatpickr-day {
        height: 40px !important;
        line-height: 40px !important;
    }

    .rrs-date-inputs {
        grid-template-columns: 1fr;
    }

    .rrs-form-row {
        grid-template-columns: 1fr;
    }

    .rrs-calendar-legend {
        flex-direction: column;
        gap: 12px;
    }
}

@keyframes rrs-spin {
    to {
        transform: rotate(360deg);
    }
}



.flatpickr-months .flatpickr-next-month,
.flatpickr-months .flatpickr-prev-month {
    top: 12px !important;
}

.flatpickr-months .flatpickr-month {
    background: transparent !important;
}

.flatpickr-day.disabled,
.flatpickr-day.rrs-booked-date {
    color: #767676 !important;
    cursor: not-allowed !important;
    background: transparent !important;
}