#reservation_form {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --secondary-color: #64748b;
    --accent-color: #3b82f6;
    --border-radius: 12px;
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.1);
}
/* Стили для полей с ошибками (не трогаем) */
/* Стили для полей с ошибками */
.is-invalid {
    border-color: #dc3545 !important;
    background-color: #fff8f8;
}

/* Подсветка при фокусировке на поле через ошибку */
.field-highlight {
    animation: pulse-highlight 2s ease-in-out;
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25) !important;
}

@keyframes pulse-highlight {
    0% { box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.7); }
    50% { box-shadow: 0 0 0 10px rgba(220, 53, 69, 0); }
    100% { box-shadow: 0 0 0 0 rgba(220, 53, 69, 0); }
}

/* Стили для полей с автоформатированием */
.turist_dr, #lid-tel {
    font-family: 'Courier New', monospace;
    font-weight: 500;
    letter-spacing: 0.5px;
}

/* Анимация автоформатирования */
.formatting-hint {
    font-size: 0.8rem;
    color: #6c757d;
    margin-top: 2px;
    opacity: 0;
    transform: translateY(-5px);
    transition: all 0.3s ease;
}

.formatting-hint.show {
    opacity: 1;
    transform: translateY(0);
}

/* Подсказки при фокусе */
input:focus + .formatting-hint {
    opacity: 1;
    transform: translateY(0);
}

/* Стили для collapse с ошибками */
#validation-errors-accordion .accordion-button {
    padding: 0.75rem 1.25rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

#validation-errors-accordion .accordion-button:not(.collapsed) {
    color: white;
    background-color: #dc3545;
    box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.125);
}

#validation-errors-accordion .accordion-button:not(.collapsed)::after {
    filter: brightness(0) invert(1);
}

#error-count-badge {
    font-size: 0.9em;
    font-weight: bold;
    padding: 0.25em 0.6em;
    min-width: 24px;
}

/* Стили для списка ошибок */
#error-list {
    list-style: none;
    padding-left: 0;
}

.error-link {
    transition: all 0.2s ease;
    border-left: 3px solid #dc3545;
    font-size: 0.9rem;
}

.error-link:hover {
    background-color: #f8f9fa !important;
    transform: translateX(5px);
}

.error-link i {
    width: 16px;
    text-align: center;
}

/* Сообщения статуса */
.alert-info {
    border-left: 4px solid #0dcaf0;
}

.alert-success {
    border-left: 4px solid #198754;
}

.alert-warning {
    border-left: 4px solid #ffc107;
}

.alert-danger {
    border-left: 4px solid #dc3545;
}

/* Анимация для форматирования */
@keyframes formatSuccess {
    0% { background-color: #fff8f8; }
    50% { background-color: #e8f5e8; }
    100% { background-color: white; }
}

.format-success {
    animation: formatSuccess 1s ease;
}

/* Стили для состояния валидации */
.validation-ok {
    color: #198754;
    font-size: 0.85rem;
    margin-top: 3px;
}

.validation-error {
    color: #dc3545;
    font-size: 0.85rem;
    margin-top: 3px;
}

/* Адаптивность */
@media (max-width: 768px) {
    #validation-errors-accordion .accordion-button {
        font-size: 0.85rem;
        padding: 0.6rem 1rem;
    }

    .error-link {
        font-size: 0.85rem;
        padding: 0.5rem !important;
    }

    #validation-hint {
        font-size: 0.8rem;
        padding: 0.5rem !important;
    }

    .turist_dr, #lid-tel {
        font-size: 16px !important; /* Убирает zoom на iOS */
    }
}

/* Для лучшего отображения на мобильных устройствах */
input[type="tel"],
input[type="text"].turist_dr {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* Убираем стрелки у числовых полей в некоторых браузерах */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* НОВЫЕ СТИЛИ ДИЗАЙНА */

/* Общие стили формы */


/* Карточка с информацией об отеле */
.reservation-hotel-info-card {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1px solid #e2e8f0;
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.reservation-hotel-info-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.hotel-image-container {
    position: relative;
    height: 100%;
    max-height: 416px;
    overflow: hidden;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.hotel-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.hotel-image-container:hover img {
    transform: scale(1.05);
}

.hotel-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    text-decoration: none;
    transition: color 0.2s ease;
    display: block;
    margin-bottom: 0.5rem;
}

.hotel-name:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

/* Стили для деталей бронирования */
.booking-details {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    display: flex;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f1f5f9;
    width: 100%;
}

.detail-item:last-child {
    border-bottom: none;
}

.detail-icon {
    width: 40px;
    height: 40px;
    background: var(--primary-color);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
}

.detail-content h6 {
    margin: 0;
    color: #1e293b;
    font-weight: 600;
}

.detail-content p {
    margin: 0.25rem 0 0 0;
    color: #64748b;
    font-size: 0.9rem;
}

/* Аккордеон */
.reservation-accordion-item {
    border: 1px solid #e2e8f0;
    border-radius: var(--border-radius) !important;
    margin-bottom: 1rem;
    overflow: hidden;
    background: white;
}

.reservation-accordion-button {
    /* background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);*/
    border: none;
    font-weight: 600;
    color: #1e293b;
    padding: 1.25rem;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    border-radius: 0;
    overflow-anchor: none;
}

.reservation-accordion-button:not(.collapsed) {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover) 100%);
    color: white;
    box-shadow: none;
}

.reservation-accordion-button:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(37, 99, 235, 0.1);
}

.reservation-accordion-button::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%231e293b'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
    transition: transform 0.3s ease;
}

.reservation-accordion-button:not(.collapsed)::after {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='white'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}

/* Поля формы */
.form-control {
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: white;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
    background: white;
}

.form-label {
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}

/* Секция оплаты */
.payment-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-lg);
    position: sticky;
    top: 20px;
}

.price-display {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    text-align: center;
    margin: 1rem 0;
}

/* Стили для выбора способа оплаты */
.payment-option {
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.payment-option:hover {
    border-color: var(--primary-color);
    background: #f8fafc;
}

.payment-option.selected {
    border-color: var(--primary-color);
    background: rgba(37, 99, 235, 0.05);
}

.payment-option input[type="radio"] {
    margin: 0;
    width: 20px;
    height: 20px;
}

.payment-icon {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    border-radius: 8px;
    padding: 0.5rem;
}

.payment-icon img {
    max-width: 100%;
    max-height: 100%;
}

.payment-info {
    flex: 1;
}

.payment-info h6 {
    margin: 0;
    font-weight: 600;
    color: #1e293b;
}

.payment-info p {
    margin: 0.25rem 0 0 0;
    color: #64748b;
    font-size: 0.9rem;
}

/* Чекбоксы */
.form-check {
    padding-left: 2rem;
    margin-bottom: 0.75rem;
}

.form-check-input {
    width: 1.2em;
    height: 1.2em;
    margin-left: -2rem;
    margin-top: 0.2em;
    border: 2px solid #cbd5e1;
}

.form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.form-check-input:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(37, 99, 235, 0.1);
}

.form-check-label {
    color: #334155;
    line-height: 1.5;
}

.form-check-label a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

.form-check-label a:hover {
    text-decoration: underline;
}

/* Кнопки */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover) 100%);
    border: none;
    border-radius: 8px;
    padding: 0.875rem 1.75rem;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-primary:disabled {
    background: #94a3b8;
    transform: none;
    box-shadow: none;
    cursor: not-allowed;
}

.btn-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 0;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-link:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

/* Алерты */
.alert {
    border-radius: var(--border-radius);
    border: 1px solid transparent;
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
}

/* Процесс бронирования */
.booking-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    position: relative;
}

.booking-steps::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e2e8f0;
    z-index: 1;
}

.step {
    position: relative;
    z-index: 2;
    text-align: center;
    flex: 1;
}

.step-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: white;
    border: 3px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.5rem;
    font-weight: 600;
    color: #94a3b8;
    transition: all 0.3s ease;
}

.step.active .step-circle {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.step.completed .step-circle {
    background: #10b981;
    border-color: #10b981;
    color: white;
}

.step-label {
    font-size: 0.85rem;
    color: #64748b;
    font-weight: 500;
}

.step.active .step-label {
    color: var(--primary-color);
    font-weight: 600;
}

/* Адаптивность */
@media (max-width: 768px) {
    .booking-steps {
        flex-direction: column;
        gap: 1rem;
    }

    .booking-steps::before {
        display: none;
    }

    .step {
        display: flex;
        align-items: center;
        gap: 1rem;
        text-align: left;
    }

    .step-circle {
        margin: 0;
        flex-shrink: 0;
    }

    .payment-card {
        position: static;
        margin-top: 2rem;
    }

    .detail-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .accordion-button {
        padding: 1rem;
        font-size: 1rem;
    }
}

/* Для лучшего отображения на мобильных устройствах (не трогаем) */
input[type="tel"],
input[type="text"].turist_dr {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* Убираем стрелки у числовых полей в некоторых браузерах (не трогаем) */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Анимация загрузки */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.loading {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}
.payment-options-container {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.payment-info-box {
    border: 1px solid #e2e8f0;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
}

.payment-option .payment-info p {
    margin-bottom: 0.25rem;
}

.payment-option .payment-info small {
    font-size: 0.75rem;
}

/* Иконки статусов */
.text-success i.fa-bolt,
.text-warning i.fa-clock {
    font-size: 0.8em;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .payment-option {
        padding: 0.75rem;
    }

    .payment-icon {
        width: 40px;
        height: 40px;
        min-width: 40px;
    }

    .payment-info h6 {
        font-size: 0.95rem;
    }

    .payment-info p {
        font-size: 0.85rem;
    }
}
.booking-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2.5rem;
    position: relative;
    counter-reset: step;
    padding: 0 1rem;
}

.booking-steps::before {
    content: '';
    position: absolute;
    top: 24px;
    left: 10%;
    right: 10%;
    height: 3px;
    background: #e2e8f0;
    z-index: 1;
}

.step {
    position: relative;
    z-index: 2;
    text-align: center;
    flex: 1;
    max-width: 200px;
}

.step-circle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: white;
    border: 3px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.75rem;
    font-weight: 700;
    color: #94a3b8;
    font-size: 1.1rem;
    transition: all 0.4s ease;
    position: relative;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.step-circle::before {
    counter-increment: step;
    content: counter(step);
}

.step.active .step-circle {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-hover) 100%);
    border-color: var(--primary-color);
    color: white;
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

.step.completed .step-circle {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    border-color: #10b981;
    color: white;
}

.step.completed .step-circle::after {
    content: '✓';
    font-size: 1.2rem;
    font-weight: bold;
}

.step.completed .step-circle::before {
    display: none;
}

.step-label {
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 600;
    transition: all 0.3s ease;
    background: white;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    display: inline-block;
}

.step.active .step-label {
    color: var(--primary-color);
    background: rgba(37, 99, 235, 0.1);
    font-weight: 700;
}

.step.completed .step-label {
    color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.step-connector {
    position: absolute;
    top: 24px;
    left: calc(50% + 24px);
    right: calc(-50% + 24px);
    height: 3px;
    background: #e2e8f0;
    z-index: 1;
    transition: all 0.4s ease;
}

.step.completed .step-connector {
    background: #10b981;
}

@media (max-width: 768px) {
    .booking-steps {
        flex-direction: column;
        gap: 1.5rem;
        padding: 0;
    }

    .booking-steps::before {
        display: none;
    }

    .step {
        display: flex;
        align-items: center;
        gap: 1rem;
        text-align: left;
        max-width: none;
    }

    .step-circle {
        margin: 0;
        flex-shrink: 0;
        width: 42px;
        height: 42px;
        font-size: 1rem;
    }

    .step-connector {
        display: none;
    }

    .step.active .step-circle {
        transform: scale(1.05);
    }
}
@media (max-width: 425px) {
    .detail-item {
        flex-direction: row;
    }
    .booking-details {
        flex-wrap: wrap;
    }
}
/* Анимации для шагов */
@keyframes stepPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); }
    100% { transform: scale(1.1); }
}

.step.active .step-circle {
    animation: stepPulse 0.6s ease-out;
}

@keyframes stepComplete {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.step.completed .step-circle {
    animation: stepComplete 0.5s ease-out;
}

/* Плавные переходы для меток шагов */
.step-label {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Эффект при наведении на шаги */
.step:not(.active):not(.completed):hover .step-circle {
    border-color: var(--primary-color);
    background: #f1f5f9;
    cursor: pointer;
}

.step:not(.active):not(.completed):hover .step-label {
    color: var(--primary-color);
}