/**
 * Erpé Appointment Maker Styles
 * jQuery UI Datepicker customization
 */

/* ===========================
   Calendar Container
   =========================== */
.erpe-appointment-date-container {
    margin: 15px 0;
}

.erpe-inline-calendar {
    max-width: 100%;
    margin: 0 auto;
}

/* ===========================
   jQuery UI Datepicker Customization
   =========================== */

/* Disabled days (closed days) */
.ui-datepicker td.erpe-disabled-day .ui-state-default {
    background: #f5f5f5 !important;
    color: #ccc !important;
    cursor: not-allowed !important;
    text-decoration: line-through;
    pointer-events: auto !important;
    /* Enable tooltips on disabled dates */
}

/* Blocked dates (holidays, vacations) */
.ui-datepicker td.erpe-blocked-date .ui-state-default {
    background: #ffebee !important;
    color: #c62828 !important;
    cursor: not-allowed !important;
    pointer-events: auto !important;
    /* Enable tooltips on blocked dates */
}

/* Preferred dates (highlighted) */
.ui-datepicker td.erpe-preferred-date .ui-state-default {
    background: #e8f5e9 !important;
    border: 2px solid #4caf50 !important;
    color: #2e7d32 !important;
    font-weight: bold;
}

.ui-datepicker td.erpe-preferred-date .ui-state-default:hover {
    background: #c8e6c9 !important;
}

/* Available dates (normal) */
.ui-datepicker td.erpe-available-date .ui-state-default {
    cursor: pointer;
}

.ui-datepicker td.erpe-available-date .ui-state-default:hover {
    background: #e3f2fd !important;
    border-color: #2196f3 !important;
}

/* Selected date */
.ui-datepicker td .ui-state-active {
    background: #2196f3 !important;
    border-color: #1976d2 !important;
    color: white !important;
}

/* Today's date */
.ui-datepicker td.ui-datepicker-today .ui-state-default {
    border: 2px solid #ff9800 !important;
}

/* ===========================
   Time Slot Selection
   =========================== */
.erpe-time-slot-container {
    margin: 20px 0;
}

.erpe-time-slots {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.erpe-time-slot-option {
    flex: 1;
    min-width: 150px;
}

.erpe-time-slot-option label {
    display: block;
    padding: 15px 20px;
    border: 2px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    background: white;
}

.erpe-time-slot-option label:hover {
    border-color: #2196f3;
    background: #e3f2fd;
}

/* Selected time slot - multiple selectors for specificity */
.erpe-time-slot-option.selected label,
.erpe-time-slot-option input[type="radio"]:checked+.erpe-time-slot-label,
.erpe-time-slot-option input[type="radio"]:checked~.erpe-time-slot-label,
label.erpe-time-slot-option.selected {
    border-color: #2196f3 !important;
    background: #2196f3 !important;
    color: white !important;
}

.erpe-time-slot-option input[type="radio"] {
    display: none;
}

.erpe-time-slot-label {
    font-size: 16px;
    font-weight: 600;
    display: block;
}

/* ===========================
   Validation Errors
   =========================== */
.gfield_error .erpe-inline-calendar {
    border: 2px solid #c62828;
    border-radius: 4px;
    padding: 10px;
}

.gfield_error .erpe-time-slot-container {
    border: 2px solid #c62828;
    border-radius: 4px;
    padding: 10px;
}