#modal {
    position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%);
    background: #2a2a2a; padding: 20px; border-radius: 12px; color: white;
    box-shadow: 0 0 10px rgba(0,0,0,0.5); z-index: 1000; display: none;
    width: 390px;
}
.free {
    color: #000; /* Черный цвет для свободных слотов */
    cursor: pointer;
    padding: 5px;
}

.free:hover {
    background-color: #f0f0f0;
}

.busy {
    color: red; /* Красный цвет для занятых слотов */
    cursor: not-allowed;
    padding: 5px;
}

.selected {
    background-color: #007bff;
    color: white;
}

.notification {
    padding: 10px;
    margin: 10px 0;
    border-radius: 5px;
}

.notification.success {
    background-color: #28a745;
    color: white;
}

.notification.error {
    background-color: #dc3545;
    color: white;
}
#modal:hover{
    cursor: pointer;
}
#modal_date { margin-bottom: 10px; padding: 10px; width: 100%; border-radius: 15px; margin-top: 30px;}
#slots { list-style: none; padding: 0; max-height: 279px; overflow-y: auto; }
#slots li { padding: 8px; cursor: pointer; border-bottom: 1px solid #444; }
#slots li.free { color: #2ecc71; }
#slots li:hover.free { background: #3a3a3a; }
#slots li.selected { background: #B80000 ; color: white; border-radius: 4px; }
#confirm { padding: 10px; background: #B80000 ; border: none; color: white; width: 100%; border-radius: 8px; cursor: pointer; }
.notification {
    position: fixed; top: 20px; right: 20px; padding: 15px; border-radius: 8px; color: white; opacity: 0; transition: opacity 0.3s;
}
.close-btn {
    position: absolute; top: 10px; right: 10px; padding: 5px 10px; background: #e74c3c; border: none; color: white; border-radius: 4px; cursor: pointer;
}
.notification.success { background: #2ecc71; }
.notification.error { background: #e74c3c; }
.notification.show { opacity: 1; }

.booking-container {
    max-width: 600px;
    margin: 50px auto;
    padding: 0 20px;
}

.booking-form-wrapper {
    background: linear-gradient(145deg, #1e1e1e, #2a2a2a);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15),
    0 0 0 1px rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.booking-form-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.booking-title {
    text-align: center;
    color: #ffffff;
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 30px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-group label {
    display: block;
    color: #e0e0e0;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-control {
    width: 100%;
    padding: 15px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #ffffff;
    font-size: 16px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-sizing: border-box;
}

.form-control:focus {
    outline: none;
    border-color: #3498db;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.15);
    transform: translateY(-1px);
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

select.form-control {
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: none;
    padding-right: 20px;
    line-height: 1.4;
    height: auto;
    min-height: 52px;
}

select.form-control option {
    background: #2a2a2a;
    color: #ffffff;
    padding: 10px;
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
    font-family: inherit;
}

.btn-primary {
    width: 100%;
    padding: 18px;
    background-color: #B80000 !important;
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(184, 0, 0, 0.2);
    background: linear-gradient(135deg, #3cb4f7, #3498db);
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:active {
    transform: translateY(0);
}

.alert {
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    font-weight: 500;
}

.alert-success {
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.2), rgba(39, 174, 96, 0.2));
    border: 1px solid rgba(46, 204, 113, 0.3);
    color: #2ecc71;
}

.alert-danger {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.2), rgba(192, 57, 43, 0.2));
    border: 1px solid rgba(231, 76, 60, 0.3);
    color: #e74c3c;
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    z-index: 9999;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    max-width: 300px;
    word-wrap: break-word;
}

.notification.show {
    opacity: 1;
    transform: translateX(0);
}

.notification.success {
    background: linear-gradient(135deg, #2ecc71, #27ae60);
}

.notification.error {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

.notification.warning {
    background: linear-gradient(135deg, #f39c12, #e67e22);
}

.resources-list {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 20px;
    margin-top: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.resources-list h3 {
    color: #ffffff;
    font-size: 18px;
    margin-bottom: 15px;
    font-weight: 500;
}

.resources-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.resources-list li {
    color: rgba(255, 255, 255, 0.8);
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 14px;
}

.resources-list li:last-child {
    border-bottom: none;
}

/* Стилизация flatpickr для темной темы */
/* .flatpickr-calendar {
    background: #2a2a2a !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 12px !important;
}

.flatpickr-calendar:before,
.flatpickr-calendar:after {
    border-bottom-color: #2a2a2a !important;
}

.flatpickr-months {
    background: #2a2a2a !important;
    border-radius: 12px 12px 0 0 !important;
}

.flatpickr-month {
    color: #ffffff !important;
}

.flatpickr-weekdays {
    background: #2a2a2a !important;
}

.flatpickr-weekday {
    color: rgba(255, 255, 255, 0.7) !important;
}

.flatpickr-day {
    color: #ffffff !important;
    border-radius: 6px !important;
}

.flatpickr-day:hover {
    background: rgba(52, 152, 219, 0.3) !important;
    border-color: rgba(52, 152, 219, 0.3) !important;
}

.flatpickr-day.selected {
    background: #3498db !important;
    border-color: #3498db !important;
}

.flatpickr-day.today {
    border-color: #3498db !important;
}

.flatpickr-time {
    background: #2a2a2a !important;
    border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.flatpickr-time input {
    background: transparent !important;
    color: #ffffff !important;
} */

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .booking-container {
        margin: 20px auto;
        padding: 0 15px;
    }

    .booking-form-wrapper {
        padding: 25px 20px;
        border-radius: 16px;
    }

    .booking-title {
        font-size: 24px;
        margin-bottom: 25px;
    }

    .form-group {
        margin-bottom: 20px;
    }

    .form-control {
        padding: 12px 15px;
        font-size: 14px;
    }

    .btn-primary {
        padding: 15px;
        font-size: 14px;
    }

    .flatpickr-calendar {
        font-size: 14px !important;
    }

    .notification {
        right: 10px;
        left: 10px;
        max-width: none;
    }
}

@media (max-width: 480px) {
    .booking-form-wrapper {
        padding: 20px 15px;
    }

    .booking-title {
        font-size: 20px;
    }

    .form-control {
        padding: 10px 12px;
    }

    .btn-primary {
        padding: 12px;
    }
}

@keyframes pulse {
    0% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
    100% {
        opacity: 1;
    }
}

.form-control:disabled {
    animation: pulse 1.5s infinite;
    cursor: not-allowed;
}

.booking-container {
    max-width: 600px;
    margin: 50px auto;
    padding: 0 20px;
}

.booking-form-wrapper {
    background: linear-gradient(145deg, #1e1e1e, #2a2a2a);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15),
    0 0 0 1px rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.booking-form-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.booking-title {
    text-align: center;
    color: #ffffff;
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 30px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.form-group {
    margin-bottom: 25px;
    position: relative;
}

.form-group label {
    display: block;
    color: #e0e0e0;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-control {
    width: 100%;
    padding: 15px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #ffffff;
    font-size: 16px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-sizing: border-box;
}

.form-control:focus {
    outline: none;
    border-color: #3498db;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.15);
    transform: translateY(-1px);
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

select.form-control {
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: none;
    padding-right: 20px;
    line-height: 1.4;
    height: auto;
    min-height: 52px;
}

select.form-control option {
    background: #2a2a2a;
    color: #ffffff;
    padding: 10px;
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
    font-family: inherit;
}



.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(184, 0, 0, 0.2);
    background: #B80000;

}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:active {
    transform: translateY(0);
}

.alert {
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    font-weight: 500;
}

.alert-success {
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.2), rgba(39, 174, 96, 0.2));
    border: 1px solid rgba(46, 204, 113, 0.3);
    color: #2ecc71;
}

.alert-danger {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.2), rgba(192, 57, 43, 0.2));
    border: 1px solid rgba(231, 76, 60, 0.3);
    color: #e74c3c;
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    color: white;
    font-weight: 500;
    z-index: 9999;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    max-width: 300px;
    word-wrap: break-word;
}

.notification.show {
    opacity: 1;
    transform: translateX(0);
}

.notification.success {
    background: linear-gradient(135deg, #2ecc71, #27ae60);
}

.notification.error {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

.notification.warning {
    background: linear-gradient(135deg, #f39c12, #e67e22);
}

.resources-list {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 20px;
    margin-top: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.resources-list h3 {
    color: #ffffff;
    font-size: 18px;
    margin-bottom: 15px;
    font-weight: 500;
}

.resources-list ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.resources-list li {
    color: rgba(255, 255, 255, 0.8);
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 14px;
}

.resources-list li:last-child {
    border-bottom: none;
}

/* Стилизация flatpickr для темной темы */
.flatpickr-calendar {
    background: #2a2a2a !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 12px !important;
}

.flatpickr-calendar:before,
.flatpickr-calendar:after {
    border-bottom-color: #2a2a2a !important;
}

.flatpickr-months {
    background: #2a2a2a !important;
    border-radius: 12px 12px 0 0 !important;
}

.flatpickr-month {
    color: #ffffff !important;
}

.flatpickr-weekdays {
    background: #2a2a2a !important;
}

.flatpickr-weekday {
    color: rgba(255, 255, 255, 0.7) !important;
}

.flatpickr-day {
    color: #ffffff !important;
    border-radius: 6px !important;
}

.flatpickr-day:hover {
    background: rgba(52, 152, 219, 0.3) !important;
    border-color: rgba(52, 152, 219, 0.3) !important;
}

.flatpickr-day.selected {
    background: #3498db !important;
    border-color: #3498db !important;
}

.flatpickr-day.today {
    border-color: #3498db !important;
}

.flatpickr-time {
    background: #2a2a2a !important;
    border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.flatpickr-time input {
    background: transparent !important;
    color: #ffffff !important;
}

@media (max-width: 768px) {
    .booking-container {
        margin: 20px auto;
        padding: 0 15px;
    }

    .booking-form-wrapper {
        padding: 25px 20px;
        border-radius: 16px;
    }

    .booking-title {
        font-size: 24px;
        margin-bottom: 25px;
    }

    .form-group {
        margin-bottom: 20px;
    }

    .form-control {
        padding: 12px 15px;
        font-size: 14px;
    }

    .btn-primary {
        padding: 15px;
        font-size: 14px;
    }

    .flatpickr-calendar {
        font-size: 14px !important;
    }

    .notification {
        right: 10px;
        left: 10px;
        max-width: none;
    }
}

@media (max-width: 480px) {
    .booking-form-wrapper {
        padding: 20px 15px;
    }

    .booking-title {
        font-size: 20px;
    }

    .form-control {
        padding: 10px 12px;
    }

    .btn-primary {
        padding: 12px;
    }
}

@keyframes pulse {
    0% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
    100% {
        opacity: 1;
    }
}

.form-control:disabled {
    animation: pulse 1.5s infinite;
    cursor: not-allowed;
}
#modal_date {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}


/* Стили для модального окна */
#bookingModal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
     overflow-y: auto; 
}

.booking-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    animation: fadeIn 0.3s ease;
}

.booking-modal-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: linear-gradient(145deg, #1e1e1e, #2a2a2a);
    border-radius: 24px;
    padding: 40px;
    max-width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    width: 600px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    animation: modalAppear 0.3s ease 0.1s forwards;
    opacity: 0;
}

.booking-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.booking-modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

/* Анимации */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes modalAppear {
    from { 
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.9);
    }
    to { 
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

@keyframes modalDisappear {
    from { 
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    to { 
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.9);
    }
}

.booking-modal-content.closing {
    animation: modalDisappear 0.2s ease forwards;
}

/* Стили для красивой кнопки */
.booking-header-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    background: linear-gradient(135deg, #B80000, #8B0000);
    color: white !important;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(184, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
    margin-left: 15px;
}

.booking-header-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.booking-header-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(184, 0, 0, 0.4);
    background: linear-gradient(135deg, #8B0000, #B80000);
    color: white !important;
    text-decoration: none;
}

.booking-header-btn:hover::before {
    left: 100%;
}

.booking-header-btn:active {
    transform: translateY(0);
}

/* Иконка для кнопки */
.booking-header-btn::after {
    content: '📅';
    margin-left: 8px;
    font-size: 16px;
}

/* Адаптивность для модального окна */
@media (max-width: 768px) {
    .booking-modal-content {
        width: 95%;
        padding: 30px 20px;
        max-height: 95vh;
        border-radius: 16px;
    }
    
    .booking-modal-close {
        top: 15px;
        right: 15px;
        width: 35px;
        height: 35px;
        font-size: 20px;
    }
    
    .booking-header-btn {
        padding: 10px 18px;
        font-size: 13px;
        margin-left: 10px;
    }
}

@media (max-width: 480px) {
    .booking-modal-content {
        padding: 25px 15px;
        border-radius: 12px;
    }
    
    .booking-header-btn {
        padding: 8px 15px;
        font-size: 12px;
        margin-left: 8px;
    }
}

/* Скрываем скроллбар при открытой модалке */
/* body.booking-modal-open {
    overflow: hidden;
}

.booking-modal-content::-webkit-scrollbar {
    width: 6px;
}

.booking-modal-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.booking-modal-content::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

.booking-modal-content::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
} */