/* Stylizacja kalendarza  */

/* Kalendarz */
input[type="date"]:invalid {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
    background-color: #f8d7da;
}

input[type="date"]:valid {
    border-color: #28a745 !important;
    box-shadow: 0 0 0 0.2rem rgba(40, 167, 69, 0.25);
}

/* Godzina dostawy */
#delivery_time {
    transition: all 0.3s ease;
}

#delivery_time:disabled {
    background-color: #e9ecef;
    opacity: 0.6;
    cursor: not-allowed;
}

#delivery_time option:disabled {
    color: #6c757d;
    font-style: italic;
}

.form-text {
    font-size: 0.875rem;
}

.form-text .fas {
    color: #17a2b8;
    margin-right: 0.25rem;
}

/* Niedostępne daty */
.date-unavailable-alert {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 0.75rem;
    margin-bottom: 1rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
}

.date-unavailable-alert .fas {
    color: #721c24;
    margin-right: 0.5rem;
}

/* Oznaczenia dni tygodnia w kalendarzu */
.calendar-legend {
    margin-top: 0.5rem;
    font-size: 0.75rem;
}

.calendar-legend .badge {
    margin-right: 0.5rem;
    margin-bottom: 0.25rem;
}

.badge-closed {
    background-color: #dc3545;
}

.badge-open {
    background-color: #28a745;
}

.badge-blocked {
    background-color: #6c757d;
}

.loading-hours {
    position: relative;
}

.loading-hours::after {
    content: "Ładowanie godzin...";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    color: #6c757d;
}

/* Responsywny design */
@media (max-width: 576px) {
    .form-text {
        font-size: 0.8rem;
    }

    #delivery_date, #delivery_time {
        font-size: 16px;
    }
}
