/* Подключение шрифта Carelia */
@font-face {
    font-family: 'Carelia Upright';
    src: url('Font/carelia/Carelia-Upright.eot');
    src: local('Carelia Upright'), local('Carelia-Upright'),
        url('Font/carelia/Carelia-Upright.eot?#iefix') format('embedded-opentype'),
        url('Font/carelia/Carelia-Upright.woff2') format('woff2'),
        url('Font/carelia/Carelia-Upright.woff') format('woff'),
        url('Font/carelia/Carelia-Upright.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'Carelia';
    src: url('Font/carelia/Carelia-Italic.eot');
    src: local('Carelia Italic'), local('Carelia-Italic'),
        url('Font/carelia/Carelia-Italic.eot?#iefix') format('embedded-opentype'),
        url('Font/carelia/Carelia-Italic.woff2') format('woff2'),
        url('Font/carelia/Carelia-Italic.woff') format('woff'),
        url('Font/carelia/Carelia-Italic.ttf') format('truetype');
    font-weight: normal;
    font-style: italic;
}

/* Основные переменные */
:root {
    --primary-color: #3182ce;
    --secondary-color: #f5c933;
    --success-color: #38a169;
    --warning-color: #d69e2e;
    --error-color: #f5c933;
    --info-color: #3182ce;
    
    --text-primary: #1a365d;
    --text-secondary: #2d3748;
    --text-muted: #718096;
    --text-light: #a0aec0;
    
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-tertiary: #e2e8f0;
    
    --border-color: #e2e8f0;
    --border-radius: 8px;
    --border-radius-lg: 12px;
    
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    
    --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;
    --font-size-3xl: 2rem;
}

/* Сброс стилей */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    overflow-x: hidden; /* Предотвращаем горизонтальную прокрутку */
    width: 100%;
    max-width: 100%;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Специальные стили ТОЛЬКО для iPhone/Safari - улучшаем область клика для поля даты */
@supports (-webkit-touch-callout: none) {
    /* Это специфично для iOS Safari */
    #moveDate {
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
        position: relative;
        z-index: 1;
    }
    
    /* На iPhone picker должен быть видимым и работать напрямую */
    #moveDatePicker:not(.visually-hidden) {
        display: block !important;
        position: relative !important; /* Для позиционирования кнопки */
        width: 100% !important;
        min-height: 48px !important;
        height: auto !important;
        opacity: 1 !important;
        pointer-events: auto !important;
        z-index: 1 !important;
        top: auto !important;
        left: auto !important;
        margin: 0 !important;
        padding: 0.75rem 3rem 0.75rem 1rem !important; /* Увеличиваем padding справа для кнопки */
        border: 1px solid #ddd !important;
        border-radius: 8px !important;
        font-size: 1rem !important;
        background: white !important;
        -webkit-appearance: none !important;
        appearance: none !important; /* Убираем стандартную иконку iOS */
        -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1) !important;
        touch-action: manipulation !important;
        cursor: pointer !important;
    }
    
    /* Большая видимая кнопка календаря справа */
    #moveDatePicker:not(.visually-hidden)::after {
        content: '';
        position: absolute !important;
        right: 0.5rem !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        width: 44px !important;
        height: 44px !important;
        background: #f5c933 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23000'%3E%3Cpath d='M19 4h-1V2h-2v2H8V2H6v2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 16H5V10h14v10zm0-12H5V6h14v2z'/%3E%3C/svg%3E") center/24px 24px no-repeat !important;
        border-radius: 8px !important;
        pointer-events: none !important; /* Пропускаем клики через кнопку к input */
        z-index: 2 !important;
        display: block !important;
    }
    
    /* Убеждаемся, что picker видимый даже если класс не удален сразу */
    #moveDatePicker.form-input {
        display: block !important;
        visibility: visible !important;
    }
    
    /* Скрываем text input на iPhone, когда используется нативный picker */
    #moveDate[style*="display: none"] {
        display: none !important;
    }
    
    #moveDatePicker.visually-hidden {
        pointer-events: none !important;
        z-index: -999 !important;
        top: -9999px !important;
        left: -9999px !important;
        width: 0 !important;
        height: 0 !important;
        opacity: 0 !important;
    }
    
    /* Кастомный календарь для iPhone */
    .custom-calendar-ios {
        margin-top: 1rem;
        background: white;
        border: 1px solid #ddd;
        border-radius: 8px;
        padding: 1rem;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }
    
    .calendar-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 1rem;
    }
    
    .calendar-header h4 {
        margin: 0;
        font-size: 1.1rem;
        font-weight: 600;
        color: #1a365d;
    }
    
    .calendar-nav-btn {
        background: #f5c933;
        border: none;
        border-radius: 6px;
        width: 36px;
        height: 36px;
        font-size: 1.5rem;
        cursor: pointer;
        color: #000;
        font-weight: bold;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: all 0.2s;
        -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    }
    
    .calendar-nav-btn:active {
        background: #d4a629;
        transform: scale(0.95);
    }
    
    .calendar-weekdays {
        display: grid;
        grid-template-columns: repeat(7, 1fr);
        gap: 4px;
        margin-bottom: 0.5rem;
    }
    
    .calendar-weekdays div {
        text-align: center;
        font-weight: 600;
        font-size: 0.85rem;
        color: #718096;
        padding: 0.5rem 0;
    }
    
    .calendar-days {
        display: grid;
        grid-template-columns: repeat(7, 1fr);
        gap: 4px;
    }
    
    .calendar-day {
        aspect-ratio: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 6px;
        cursor: pointer;
        font-size: 0.9rem;
        font-weight: 500;
        transition: all 0.2s;
        min-height: 40px;
        -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
    }
    
    .calendar-day.empty {
        cursor: default;
    }
    
    .calendar-day:not(.empty):not(.disabled):active {
        background: #f5c933;
        color: #000;
        transform: scale(0.95);
    }
    
    .calendar-day.selected {
        background: #f5c933;
        color: #000;
        font-weight: 700;
    }
    
    .calendar-day.disabled {
        color: #cbd5e0;
        cursor: not-allowed;
        opacity: 0.5;
    }
    
    .calendar-day.today {
        border: 2px solid #f5c933;
    }
    
    .input-group:has(#moveDate) {
        position: relative;
        z-index: 1;
    }
    
}

/* 3 поля выбора даты для всех устройств */
.date-selectors {
    display: flex;
    gap: 0.5rem;
    width: 100%;
    align-items: stretch;
}

.date-select-input {
    flex: 1;
    padding: 12px 36px 12px 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--bg-primary);
    font-size: var(--font-size-base);
    font-family: var(--font-family);
    font-weight: 600;
    color: var(--text-primary);
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
    text-align: center;
    min-width: 0;
    box-sizing: border-box;
    transition: all 0.2s ease;
    height: 48px;
}

.date-select-input:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(245, 201, 51, 0.1);
}

.date-select-input option {
    text-align: center;
    padding: 8px;
}

.date-select-input:invalid {
    color: #999;
}

.date-select-input:not(:invalid) {
    color: var(--text-primary);
}

/* Контейнер */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

/* Шапка */
.header {
    background: linear-gradient(135deg, #f5c933, #f5c933);
    padding: 20px 0;
    margin-bottom: 40px;
    box-shadow: var(--shadow-sm);
    width: 100%;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-animation {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 80px;
    position: relative;
}

.animated-word {
    opacity: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: #1a365d;
    transition: opacity 0.35s ease-in;
    white-space: nowrap;
    font-family: var(--font-family);
}

.animated-word.visible {
    opacity: 1;
}

.lemon-emoji {
    opacity: 0;
    font-size: 2rem;
    transition: opacity 0.25s ease-in;
    position: relative;
}

.lemon-emoji.visible {
    opacity: 1;
}

.lemon-emoji.hidden {
    opacity: 0;
    transition: opacity 0.3s ease-out;
}

/* Салют из частиц */
.confetti-particle {
    position: fixed;
    width: 10px;
    height: 10px;
    background: #f5c933;
    border-radius: 50%;
    pointer-events: none;
    z-index: 10000;
    animation: confetti-fall 1s ease-out forwards;
}

.confetti-particle.yellow {
    background: #f5c933;
}

.confetti-particle.green {
    background: #38a169;
}

.confetti-particle.blue {
    background: #3182ce;
}

.confetti-particle.red {
    background: #e53e3e;
}

.confetti-particle.pink {
    background: #ed64a6;
}

@keyframes confetti-fall {
    0% {
        transform: translateY(0) translateX(0) rotate(0deg) scale(1);
        opacity: 1;
    }
    100% {
        transform: translateY(var(--random-y, 200px)) translateX(var(--random-x, 0)) rotate(360deg) scale(0);
        opacity: 0;
    }
}

.header-phone {
    display: flex;
    align-items: center;
}

.header-phone-mobile {
    display: none;
}

.phone-icon-mobile {
    font-size: 1.8rem;
    text-decoration: none;
    color: #000000;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #ffffff !important;
    border: 2px solid #ffffff !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
}

.phone-icon-emoji {
    filter: brightness(0) saturate(100%);
}

.phone-icon-mobile:hover {
    background: #ffffff !important;
    border: 2px solid #ffffff !important;
    transform: scale(1.1);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.phone-button {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    color: #000000;
    padding: 8px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.phone-button:hover {
    background: #f5f5f5;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.phone-icon {
    font-size: 1.2rem;
    color: #000000 !important;
    filter: brightness(0) saturate(100%);
}

.phone-button .phone-icon {
    color: #000000 !important;
    filter: brightness(0) saturate(100%);
}

.phone-number {
    font-family: 'Carelia Upright', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    letter-spacing: 0.5px;
    color: #000000;
}

.logo-link {
    display: inline-block;
    transition: transform 0.2s ease, opacity 0.2s ease;
    cursor: pointer;
}

.logo-link:hover {
    transform: scale(1.05);
    opacity: 0.9;
}

.logo-link:active {
    transform: scale(0.98);
}

.logo {
    width: 348px !important;
    height: 80px !important;
    object-fit: contain;
    display: block;
    flex: 0 0 348px !important;
}

.header-text h1 {
    font-family: 'Carelia Upright', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 3rem;
    line-height: 1.1;
    font-weight: normal;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.subtitle {
    font-family: 'Carelia Upright', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 1.5rem;
    line-height: 1.2;
    color: var(--text-secondary);
    font-weight: normal;
}

/* Основная форма */
.quote-form {
    max-width: 1280px;
    margin: 0 auto;
    padding: 40px 20px;
    background: var(--bg-primary);
    width: 100%;
    box-sizing: border-box;
}

.form-header {
    text-align: center;
    margin-bottom: 40px;
}

.form-header h2 {
    color: var(--text-primary);
    font-size: var(--font-size-3xl);
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.2;
}

.form-header h2 strong {
    color: var(--secondary-color);
}

.form-header p {
    color: var(--text-secondary);
    font-size: var(--font-size-lg);
    max-width: 600px;
    margin: 0 auto;
}

/* Секции формы */
.form-section {
    margin-bottom: 30px;
    padding: 25px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius-lg);
    border: 1px solid var(--border-color);
    width: 100%;
    box-sizing: border-box;
}

.form-section h3 {
    color: var(--text-primary);
    margin-bottom: 20px;
    font-size: var(--font-size-xl);
    font-weight: 600;
}

.required {
    color: var(--secondary-color);
    font-weight: 600;
}

/* Двухколоночный макет */
.two-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
    width: 100%;
    box-sizing: border-box;
}

/* Трехколоночный макет */
.three-column {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

/* Одноколоночный макет */
.single-column {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

/* Сетка формы (2x2) */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

/* Группы ввода */
.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-secondary);
    font-size: var(--font-size-base);
}

.form-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--bg-primary);
    font-size: var(--font-size-base);
    font-family: var(--font-family);
    box-sizing: border-box;
    max-width: 100%;
    transition: all 0.2s ease;
    color: var(--text-primary);
}

.form-input:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(245, 201, 51, 0.1);
}

.form-input::placeholder {
    color: var(--text-light);
}

.form-input:invalid {
    border-color: var(--error-color);
}

/* Унификация стилей для select элементов во всех браузерах */
.form-input select,
select.form-input {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%233182ce' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
    padding-right: 40px;
    cursor: pointer;
}

/* Убираем стандартную стрелку в IE */
.form-input select::-ms-expand,
select.form-input::-ms-expand {
    display: none;
}

/* Стили для focus состояния select */
.form-input select:focus,
select.form-input:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(245, 201, 51, 0.1);
}

/* Убираем outline в Safari при фокусе */
.form-input select:focus::-webkit-focus-ring,
select.form-input:focus::-webkit-focus-ring {
    outline: none;
}

/* Специальные стили для поля даты */
input[type="date"] {
    position: relative;
    cursor: pointer;
}

/* Увеличение календаря на 50% для мобильных устройств */
@media (max-width: 768px) {
    /* Попытка увеличить календарь через увеличение размера input при открытии */
    input[type="date"]:focus {
        font-size: 1.5rem;
    }
    
    /* Увеличиваем индикатор календаря */
    input[type="date"]::-webkit-calendar-picker-indicator {
        width: 24px;
        height: 24px;
        font-size: 1.2rem;
    }
}

input[type="date"]::-webkit-calendar-picker-indicator {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: auto;
    height: auto;
    color: transparent;
    background: transparent;
    cursor: pointer;
}

input[type="date"]::-webkit-datetime-edit {
    padding: 0;
}

input[type="date"]::-webkit-datetime-edit-fields-wrapper {
    padding: 0;
}

input[type="date"]::-webkit-datetime-edit-text {
    padding: 0 2px;
}

/* Стили для календаря */
input[type="date"]::-webkit-calendar-picker-indicator:hover {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

/* Вкладки адресов */
.address-tabs {
    display: flex;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
}

.tab {
    padding: 12px 24px;
    background: var(--bg-tertiary);
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    border-bottom: none;
    margin-right: 5px;
}

.tab.active {
    background: var(--secondary-color);
    color: var(--text-primary);
    border-color: var(--secondary-color);
}

.tab:hover:not(.active) {
    background: var(--bg-primary);
    color: var(--text-primary);
}

/* Форма адресов */
.address-form {
    margin-top: 20px;
}

/* Информация о расстоянии */
.distance-info {
    margin-top: 20px;
    padding: 15px;
    background: var(--bg-primary);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.distance-result {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.distance-label {
    font-weight: 600;
    color: var(--text-secondary);
}

.distance-value {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--primary-color);
}

.distance-unit {
    color: var(--text-muted);
    font-weight: 500;
}

.travel-time {
    display: flex;
    align-items: center;
    gap: 10px;
}

.time-label {
    font-weight: 600;
    color: var(--text-secondary);
}

.time-value {
    font-size: var(--font-size-lg);
    font-weight: 700;
    color: var(--success-color);
}

.time-unit {
    color: var(--text-muted);
    font-weight: 500;
}

/* Кнопки действий */
.form-actions {
    text-align: center;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid var(--border-color);
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    padding: 16px 32px;
    border: none;
    border-radius: var(--border-radius);
    font-size: var(--font-size-lg);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: var(--font-family);
    min-width: 200px;
}

.btn-primary:hover {
    background: #2c5aa0;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

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

.form-note {
    margin-top: 15px;
    color: var(--text-muted);
    font-size: var(--font-size-sm);
    font-style: italic;
}

.robot-checkbox-wrapper {
    margin-bottom: 16px;
}

.robot-checkbox {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 1rem;
    color: var(--text-primary);
}

.robot-checkbox input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

/* Help protect modal (message + audio, close X) */
.help-protect-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10001;
    animation: fadeIn 0.3s ease;
}

.help-protect-content {
    background: white;
    border-radius: 16px;
    padding: 40px 50px 40px 40px;
    max-width: 520px;
    width: 90%;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
}

.help-protect-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: none;
    border: none;
    font-size: 28px;
    line-height: 1;
    color: #666;
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.help-protect-close:hover {
    background: #f0f0f0;
    color: #333;
}

.help-protect-message {
    font-size: 1.1rem;
    color: var(--text-primary);
    line-height: 1.6;
    margin: 0;
}

/* Детальный калькулятор */
.detailed-calculator {
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: 3px;
    margin-bottom: 30px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 3px;
    transition: width 0.3s ease;
    width: 0%;
}

.step {
    display: none;
    padding: 30px;
    background: var(--bg-primary);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.step.active {
    display: block;
}

.step h2 {
    color: var(--text-primary);
    margin-bottom: 30px;
    font-size: var(--font-size-2xl);
    font-weight: 700;
}

/* Сетки элементов */
.items-grid,
.services-grid,
.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 30px;
}

.item-card,
.service-card,
.option-card {
    padding: 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.item-card:hover,
.service-card:hover,
.option-card:hover {
    border-color: var(--secondary-color);
    box-shadow: var(--shadow-sm);
}

.item-card.selected,
.service-card.selected,
.option-card.selected {
    border-color: var(--secondary-color);
    background: rgba(245, 201, 51, 0.1);
}

.item-card h3,
.service-card h3,
.option-card h3 {
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.item-card p,
.service-card p,
.option-card p {
    color: var(--text-muted);
    font-size: var(--font-size-sm);
    margin-bottom: 15px;
}

.item-card .price,
.service-card .price,
.option-card .price {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--primary-color);
}

/* Кнопки */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: var(--border-radius);
    font-size: var(--font-size-base);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: var(--font-family);
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: #2c5aa0;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--bg-primary);
    color: var(--text-primary);
    border-color: var(--secondary-color);
}

/* Результаты */
.calculation-summary,
.result-summary {
    background: var(--bg-secondary);
    padding: 30px;
    border-radius: var(--border-radius-lg);
    border: 1px solid var(--border-color);
    margin-bottom: 30px;
}

.total-price {
    text-align: center;
    margin-bottom: 30px;
}

.total-price .currency {
    font-size: var(--font-size-2xl);
    color: var(--text-muted);
    vertical-align: top;
}

.total-price .amount {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin: 0 10px;
}

.price-breakdown {
    margin-bottom: 20px;
}

.price-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
}

.price-item:last-child {
    border-bottom: none;
    font-weight: 700;
    font-size: var(--font-size-lg);
    color: var(--text-primary);
}

.price-item .label {
    color: var(--text-secondary);
}

.price-item .value {
    font-weight: 600;
    color: var(--text-primary);
}

/* Действия с результатами */
.result-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Адаптивность */
/* Планшеты (769px - 1024px) */
@media (max-width: 1024px) {
    .header-content {
        padding: 0 15px;
    }
    
    .logo {
        width: 348px !important;
        height: 80px !important;
        flex: 0 0 348px !important;
    }
    
    .header-text h1 {
        font-size: 2.4rem;
    }
    
    .subtitle {
        font-size: 1.2rem;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .quote-form {
        padding: 25px 15px;
    }
    
    .form-section {
        padding: 20px 15px;
    }
}

/* Мобильные и маленькие планшеты (до 768px) */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .header {
        padding: 15px 0;
        margin-bottom: 20px;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
        gap: 15px;
        padding: 0 15px;
    }
    
    .header-animation {
        display: none !important;
    }
    
    .header-left {
        flex-direction: column;
        gap: 12px;
        width: 100%;
    }
    
    .logo {
        width: 348px !important;
        height: 80px !important;
        flex: 0 0 348px !important;
    }
    
    .header-text h1 {
        font-size: 2rem;
        margin-bottom: 6px;
    }
    
    .subtitle {
        font-size: 1.1rem;
    }
    
    .phone-button {
        padding: 8px 18px;
        font-size: 0.9rem;
        width: auto;
    }
    
    .phone-number {
        font-size: 0.9rem;
    }
}

/* Планшеты и большие телефоны (445px - 767px) */
@media (min-width: 445px) and (max-width: 767px) {
    .header {
        position: sticky;
        top: 0;
        z-index: 1000;
        margin-bottom: 0;
        padding: 10px 0;
    }
    
    .header-content {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 0 15px;
        gap: 15px;
    }
    
    .header-left {
        flex-direction: row;
        gap: 0;
        width: auto;
    }
    
    .logo {
        width: 280px !important;
        height: 64px !important;
        flex: 0 0 280px !important;
    }
    
    .header-animation {
        display: none !important;
    }
    
    .header-phone {
        display: none !important;
    }
    
    .header-phone-mobile {
        display: flex !important;
        align-items: center;
    }
    
    .container {
        padding-top: 10px;
    }
}

/* Продолжение стилей для мобильных (до 768px) */
@media (max-width: 768px) {
    .form-header h2 {
        font-size: var(--font-size-2xl);
    }
    
    .form-header p {
        font-size: 0.95rem;
    }
    
    .two-column {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .three-column {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
        gap: 15px;
    }
    
    .quote-form {
        padding: 20px 15px;
    }
    
    .form-section {
        padding: 20px 15px;
    }
    
    .address-tabs {
        flex-direction: column;
    }
    
    .tab {
        margin-right: 0;
        margin-bottom: 5px;
        border-radius: var(--border-radius);
    }
    
    .result-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 100%;
        max-width: 300px;
    }
    
    .property-details-single {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .property-details-single .input-group {
        flex: none;
        width: 100%;
    }
}

/* Маленькие мобильные (до 480px) */
@media (max-width: 480px) {
    .header {
        padding: 12px 0;
    }
    
    .header-content {
        padding: 0 10px;
        gap: 12px;
    }
    
    .logo {
        width: 348px !important;
        height: 80px !important;
        flex: 0 0 348px !important;
    }
    
    .header-text h1 {
        font-size: 1.8rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .phone-button {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
    
    .phone-number {
        font-size: 0.85rem;
    }
    
    .container {
        padding: 0 10px;
    }
    
    .form-header h2 {
        font-size: var(--font-size-xl);
    }
    
    .form-header p {
        font-size: var(--font-size-base);
    }
    
    .items-grid,
    .services-grid,
    .options-grid {
        grid-template-columns: 1fr;
    }
    
    .total-price .amount {
        font-size: 2.5rem;
    }
    
    .quote-form {
        padding: 20px 10px;
    }
    
    .form-section {
        padding: 15px 10px;
    }
    
    .address-section {
        width: 100%;
        box-sizing: border-box;
    }
    
    .additional-stop-section {
        padding: 15px;
        margin-bottom: 15px;
    }
    
    .add-stop-button {
        width: 100%;
        padding: 12px 20px;
        font-size: 0.9rem;
    }
    
    .property-details-single {
        gap: 12px;
    }
    
    .property-details-single .input-group {
        width: 100%;
    }
}

/* Очень маленькие экраны (до 320px) */
@media (max-width: 320px) {
    .header {
        padding: 10px 0;
    }
    
    .header-content {
        padding: 0 8px;
    }
    
    .logo {
        width: 348px !important;
        height: 80px !important;
        flex: 0 0 348px !important;
    }
    
    .header-text h1 {
        font-size: 1.5rem;
    }
    
    .subtitle {
        font-size: 0.95rem;
    }
    
    .phone-button {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
    
    .container {
        padding: 0 8px;
    }
    
    .quote-form {
        padding: 15px 8px;
    }
    
    .form-section {
        padding: 12px 8px;
    }
    
    .form-header h2 {
        font-size: 1.2rem;
    }
    
    .form-header p {
        font-size: 0.9rem;
    }
    
    .date-card {
        min-width: 70px;
        padding: 8px 4px;
    }
    
    .date-number {
        font-size: 1.1rem;
    }
    
    .time-slot {
        font-size: 0.5rem;
        padding: 2px 1px;
    }
    
    .btn-book-now,
    .btn-back {
        padding: 12px 16px;
        font-size: 0.9rem;
    }
}

/* Анимации */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.step.active {
    animation: fadeIn 0.3s ease;
}

/* Состояния загрузки */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid var(--border-color);
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Трёхколоночный layout */
.three-panel-layout {
    display: grid;
    grid-template-columns: 300px 1fr 300px; /* Фиксированная ширина для боковых панелей */
    gap: 20px;
    min-height: 80vh;
    background: #f9f9f9;
    padding: 20px;
    max-width: 1600px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
}

.panel {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    height: fit-content;
    min-width: 0; /* Предотвращает расширение панелей */
    overflow: hidden; /* Скрывает переполнение */
    box-sizing: border-box; /* Включаем padding в размер */
}

.panel h2 {
    color: #f5c933;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

/* Боковые панели - фиксированная ширина */
.rooms-panel,
.move-panel {
    width: 300px;
    max-width: 300px;
    min-width: 300px;
    flex-shrink: 0; /* Не сжимаются */
    box-sizing: border-box;
}

.panel-description {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 20px;
    line-height: 1.4;
}

.panel-subtitle {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 20px;
}

/* Левая панель: Your Rooms */
.rooms-panel {
    min-height: 600px;
}

.rooms-summary {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 10px;
    background: #f0f0f0;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
}

.summary-item {
    color: #333;
}

.rooms-list {
    margin-bottom: 20px;
}

.room-item {
    display: flex;
    align-items: center;
    padding: 12px;
    margin-bottom: 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid transparent; /* Фиксированная толщина границы */
    box-sizing: border-box; /* Включаем границу в размер */
}

.room-item:hover {
    background: #f5f5f5;
}

.room-item.active {
    background: #e0f0ff;
    border-color: #f5c933;
    font-weight: 600;
    box-shadow: 0 2px 4px rgba(245, 201, 51, 0.2); /* Добавляем тень */
    /* Убираем transform чтобы избежать смещения */
}

.room-icon {
    width: 20px;
    height: 20px;
    margin-right: 12px;
    font-size: 1.2rem;
}

.room-name {
    flex: 1;
    font-size: 0.9rem;
    line-height: 1.2;
    white-space: pre-line;
    word-break: break-word;
    min-height: 2.4em; /* Фиксированная высота для двух строк */
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.room-count {
    color: #666;
    font-size: 0.8rem;
    margin-left: 8px;
}

.room-delete {
    color: #999;
    cursor: pointer;
    margin-left: 8px;
    font-size: 0.9rem;
}

.room-delete:hover {
    color: #ff4444;
}

.btn-add-room {
    width: 100%;
    padding: 14px;
    background: #f5c933;
    color: white;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 1rem;
}

.btn-add-room:hover {
    background: #f5c933;
}

.plus-icon {
    font-size: 1.5rem;
    font-weight: bold;
    line-height: 1;
    align-self: center;
}

/* Центральная панель: Your Items */
.items-panel {
    min-height: 600px;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
    min-width: 0;
}

.search-bar {
    position: relative;
    margin-bottom: 20px;
}

.search-input {
    width: 100%;
    padding: 12px 40px 12px 16px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 0.9rem;
    background: white;
    box-sizing: border-box; /* Включаем padding в ширину */
    max-width: 100%; /* Не превышаем ширину контейнера */
    overflow: hidden; /* Скрываем переполнение */
}

.search-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 1.1rem;
    z-index: 1;
}

.autocomplete-container {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 6px 6px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    margin-top: -1px;
}

.autocomplete-item {
    padding: 10px 16px;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.2s ease;
    font-size: 0.9rem;
    color: #333;
}

.autocomplete-item:last-child {
    border-bottom: none;
}

.autocomplete-item:hover {
    background-color: #f5f5f5;
}

.autocomplete-item strong {
    color: #2d89ef;
    font-weight: 600;
}

.items-tabs {
    display: flex;
    margin-bottom: 20px;
    border-bottom: 1px solid #ddd;
}

.items-tabs .tab {
    padding: 12px 20px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    font-weight: 500;
    color: #666;
    transition: all 0.2s ease;
}

.items-tabs .tab.active {
    color: #f5c933;
    border-bottom-color: #2d89ef;
}

.items-tabs .tab:hover:not(.active) {
    color: #333;
}

.items-content {
    max-height: 400px;
    overflow-y: auto;
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.items-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.item-card {
    background: white;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 15px;
    text-align: center;
    transition: all 0.2s ease;
    overflow: hidden; /* Скрываем переполнение */
    word-wrap: break-word; /* Переносим длинные слова */
    word-break: break-word; /* Разрываем длинные слова */
    min-width: 0; /* Позволяем сжиматься */
    max-width: 100%; /* Не превышаем ширину */
    min-height: 180px; /* Фиксированная минимальная высота для единообразия */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.item-card:hover {
    border-color: #f5c933;
    box-shadow: 0 2px 8px rgba(245, 201, 51, 0.1);
}

.item-image {
    width: 100%;
    height: 60px;
    object-fit: contain;
    margin-bottom: 10px;
    background: white;
    border: 1px solid white;
    border-radius: 4px;
    padding: 8px;
    box-sizing: border-box; /* Включаем padding в ширину */
    max-width: 100%; /* Не превышаем ширину */
    overflow: hidden; /* Скрываем переполнение */
}

.item-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
    line-height: 1.2;
    min-height: 2.6em; /* Для двух строк */
    max-width: 100%; /* Не превышаем ширину */
    word-wrap: break-word; /* Переносим длинные слова */
    word-break: break-word; /* Разрываем длинные слова */
}

.item-volume {
    font-size: 0.75rem;
    color: var(--text-muted, #666);
    margin-bottom: 8px;
    display: block;
}

.item-description {
    font-size: 0.7rem;
    color: #666;
    margin-bottom: 12px;
    line-height: 1.3;
    overflow: hidden; /* Скрываем переполнение */
    text-overflow: ellipsis; /* Многоточие для длинного текста */
    white-space: nowrap; /* Не переносим строки */
    max-width: 100%; /* Не превышаем ширину */
}

.quantity-selector {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.quantity-btn {
    width: 32px;
    height: 32px;
    border: 1px solid #ddd;
    background: white;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: #333;
    transition: all 0.2s ease;
    font-size: 1rem;
    box-sizing: border-box;
    flex-shrink: 0;
}

.quantity-btn:hover {
    background: #f5c933;
    border-color: #f5c933;
    color: white;
}

/* Дополнительные стили для центрирования текста в полях количества */
input[type="number"].quantity-input {
    text-align: center !important;
    -moz-appearance: textfield; /* Убираем стрелки в Firefox */
}

input[type="number"].quantity-input::-webkit-outer-spin-button,
input[type="number"].quantity-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Your added items: two-block layout (Gemini list + catalog grid) */
.items-grid > .added-wrapper,
.items-grid > .no-items {
    grid-column: 1 / -1;
}

.added-wrapper {
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 100%;
}

.added-section-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary, #333);
    margin-bottom: 12px;
}

.added-ai-section {
    width: 100%;
}

.added-ai-list {
    list-style: none;
    margin: 0;
    padding: 0;
    border: 1px solid var(--border-color, #ddd);
    border-radius: var(--border-radius, 6px);
    background: var(--bg-secondary, #f8f9fa);
}

.added-ai-list-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    border-bottom: 1px solid var(--border-color, #eee);
    font-size: 0.9rem;
}

.added-ai-list-item:last-child {
    border-bottom: none;
}

.added-ai-name {
    color: var(--text-primary, #333);
}

.added-ai-meta {
    color: var(--text-muted, #666);
    font-size: 0.85rem;
}

.added-ai-qty {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.added-ai-qty .quantity-btn {
    width: 28px;
    height: 28px;
    font-size: 0.9rem;
}

.added-ai-qty-num {
    min-width: 1.5em;
    text-align: center;
    font-weight: 600;
}

.added-catalog-section {
    width: 100%;
}

.added-catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 16px;
}

.added-catalog-grid .item-card {
    min-height: 180px;
}

.quantity-input {
    width: 50px;
    height: 32px;
    text-align: center !important;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: white;
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    padding: 0;
    box-sizing: border-box;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Правая панель: Your Move */
.move-panel {
    min-height: 600px;
}

.move-details {
    margin-bottom: 25px;
}

.detail-item {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 8px 0;
}

.detail-icon {
    font-size: 1.2rem;
    margin-right: 10px;
    color: #f5c933; /* Желтый брендовый цвет */
}

.detail-text {
    font-weight: 600;
    color: #333;
}

.detail-label {
    font-weight: 600;
    color: #333;
    margin-right: 8px;
    min-width: 120px;
}

.detail-value {
    color: #666;
    font-size: 0.9rem;
}

/* Стили для Inventory Summary */
.inventory-summary {
    margin-bottom: 20px;
}

.inventory-summary h3 {
    color: #333;
    font-size: 1rem;
    margin-bottom: 15px;
    font-weight: 600;
}

.summary-boxes {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.summary-box {
    flex: 1;
    background: #f5f5f5;
    border-radius: 6px;
    padding: 15px 10px;
    text-align: center;
    border: 1px solid #ddd;
}

.summary-number {
    font-size: 1.5rem;
    font-weight: bold;
    color: #333;
    display: block;
    margin-bottom: 5px;
}

.summary-label {
    font-size: 0.8rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Стили для сообщения "No items added yet" */
.no-items {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 40px 20px;
    width: 100%; /* Фиксированная ширина */
    max-width: 100%; /* Не превышаем ширину */
    overflow: hidden; /* Скрываем переполнение */
    box-sizing: border-box; /* Включаем padding в ширину */
    word-wrap: break-word; /* Переносим длинные слова */
    word-break: break-word; /* Разрываем длинные слова */
}

.comments-section {
    margin-bottom: 20px;
}

.comments-section label {
    display: block;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.comments-section textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: white;
    font-family: inherit;
    font-size: 0.9rem;
    resize: vertical;
    min-height: 80px;
}

.student-checkbox {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.student-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #f5c933;
}

.student-checkbox label {
    font-size: 0.9rem;
    color: #333;
    cursor: pointer;
}

.btn-see-quote {
    width: 100%;
    padding: 14px;
    background: #f5c933;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.2s ease;
}

.btn-see-quote:hover {
    background: #f5c933;
}

/* Нижняя навигация */
.bottom-navigation {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    padding: 20px;
}

.btn-previous {
    padding: 12px 24px;
    background: #ddd;
    color: #333;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.btn-previous:hover {
    background: #ccc;
}

/* Адаптивность для трехколоночного layout */
/* Планшеты большие (1025px - 1200px) */
@media (max-width: 1200px) {
    .three-panel-layout {
        grid-template-columns: 250px 1fr 250px;
        gap: 15px;
        padding: 15px;
    }
    
    .rooms-panel,
    .move-panel {
        width: 250px;
        max-width: 250px;
        min-width: 250px;
    }
    
    .items-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }
}

/* Планшеты средние (901px - 1024px) */
@media (max-width: 1024px) {
    .three-panel-layout {
        grid-template-columns: 220px 1fr 220px;
        gap: 12px;
        padding: 15px;
    }
    
    .rooms-panel,
    .move-panel {
        width: 220px;
        max-width: 220px;
        min-width: 220px;
    }
    
    .items-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
}

/* Планшеты маленькие и мобильные (до 900px) */
@media (max-width: 900px) {
    .three-panel-layout {
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 15px;
        min-height: auto;
    }
    
    .rooms-panel,
    .move-panel {
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }
    
    .rooms-panel {
        min-height: auto;
    }
    
    .items-panel {
        min-height: auto;
    }
    
    .items-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .panel {
        padding: 15px;
    }
}

/* Мобильные (до 768px) */
@media (max-width: 768px) {
    .three-panel-layout {
        padding: 10px;
        gap: 12px;
    }
    
    .panel {
        padding: 12px;
    }
    
    .panel h2 {
        font-size: 1.3rem;
    }
    
    .items-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .rooms-summary {
        flex-direction: column;
        gap: 8px;
        padding: 8px;
        font-size: 0.85rem;
    }
    
    .search-input {
        padding: 10px 35px 10px 12px;
        font-size: 0.85rem;
    }
    
    .item-card {
        padding: 12px;
    }
    
    .item-card img {
        max-height: 80px;
    }
}

/* Маленькие мобильные (до 480px) */
@media (max-width: 480px) {
    .three-panel-layout {
        padding: 8px;
        gap: 10px;
    }
    
    .panel {
        padding: 10px;
    }
    
    .panel h2 {
        font-size: 1.2rem;
        margin-bottom: 8px;
    }
    
    .panel-description,
    .panel-subtitle {
        font-size: 0.85rem;
        margin-bottom: 15px;
    }
    
    .items-grid {
        gap: 8px;
    }
    
    .item-card {
        padding: 10px;
    }
    
    .item-card img {
        max-height: 60px;
    }
    
    .search-input {
        padding: 8px 30px 8px 10px;
        font-size: 0.8rem;
    }
}

.items-header {
    margin-bottom: 30px;
}

.items-header h2 {
    color: var(--text-primary);
    font-size: var(--font-size-2xl);
    font-weight: 700;
    margin-bottom: 20px;
}

.search-bar {
    position: relative;
    margin-bottom: 20px;
}

.search-input {
    width: 100%;
    padding: 12px 40px 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--bg-primary);
    font-size: var(--font-size-base);
    font-family: var(--font-family);
}

.search-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: var(--font-size-lg);
}

.items-tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--border-color);
}

.items-tabs .tab {
    padding: 12px 24px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-bottom: none;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    color: var(--text-secondary);
}

.items-tabs .tab.active {
    background: var(--secondary-color);
    color: var(--text-primary);
    border-color: var(--secondary-color);
}

.items-tabs .tab:hover:not(.active) {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.items-content {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 20px;
    max-height: 500px;
    overflow-y: auto;
}

.items-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.item-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 15px;
    text-align: center;
    transition: all 0.2s ease;
}

.item-card:hover {
    border-color: var(--secondary-color);
    box-shadow: var(--shadow-sm);
}

.item-image {
    width: 100%;
    height: 80px;
    object-fit: contain;
    margin-bottom: 10px;
    background: white;
    border: 1px solid white;
    border-radius: var(--border-radius);
    padding: 10px;
}

.item-name {
    font-size: var(--font-size-sm);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    line-height: 1.3;
}

.item-volume {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    display: block;
}

.item-description {
    font-size: var(--font-size-sm);
    color: var(--text-muted);
    margin-bottom: 15px;
    line-height: 1.3;
}


/* Боковая панель с деталями переезда */
.move-summary {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 25px;
    height: fit-content;
}

.move-details h3 {
    color: var(--text-primary);
    font-size: var(--font-size-xl);
    font-weight: 700;
    margin-bottom: 5px;
}

.move-details p {
    color: var(--text-muted);
    margin-bottom: 25px;
}

.move-info {
    margin-bottom: 25px;
}

.date-info {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    padding: 10px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
}

.calendar-icon {
    font-size: var(--font-size-lg);
}

.address-info {
    position: relative;
}

.address-line {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 15px;
    position: relative;
}

.address-line:not(:last-child)::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 20px;
    bottom: -15px;
    width: 2px;
    background: var(--secondary-color);
}

.address-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 4px;
}

.address-dot.pickup {
    background: var(--secondary-color);
}

.address-dot.delivery {
    background: var(--secondary-color);
}

.address-text {
    flex: 1;
}

.address-label {
    color: var(--secondary-color);
    font-weight: 600;
    margin-right: 5px;
}

.address-details {
    display: block;
    color: var(--text-muted);
    font-size: var(--font-size-sm);
    margin-top: 2px;
}

.inventory-summary {
    margin-bottom: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.inventory-summary h4 {
    color: var(--text-primary);
    font-size: var(--font-size-lg);
    font-weight: 600;
    margin-bottom: 15px;
}

.summary-boxes {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.summary-box {
    text-align: center;
    padding: 15px 10px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.summary-number {
    display: block;
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 5px;
}

.summary-label {
    font-size: var(--font-size-sm);
    color: var(--text-muted);
    font-weight: 500;
}

.comments-section {
    margin-bottom: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.comments-section h4 {
    color: var(--text-primary);
    font-size: var(--font-size-lg);
    font-weight: 600;
    margin-bottom: 15px;
}

.comments-section textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--bg-primary);
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    resize: vertical;
    min-height: 80px;
}

.recaptcha-section {
    margin-bottom: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.recaptcha-widget {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.recaptcha-widget input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--secondary-color);
}

.recaptcha-logo {
    color: var(--text-muted);
    font-size: var(--font-size-sm);
}

.recaptcha-terms {
    font-size: var(--font-size-sm);
    color: var(--text-muted);
    line-height: 1.4;
}

.recaptcha-terms a {
    color: var(--primary-color);
    text-decoration: none;
}

.recaptcha-terms a:hover {
    text-decoration: underline;
}

.btn-quote {
    width: 100%;
    padding: 16px;
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: var(--font-size-lg);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: var(--font-family);
}

.btn-quote:hover {
    background: var(--secondary-color);
    color: white;
    border-color: var(--secondary-color);
}

/* Адаптивность для страницы выбора предметов */
@media (max-width: 768px) {
    .items-selection-page {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .items-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .summary-boxes {
        grid-template-columns: 1fr;
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .items-grid {
        grid-template-columns: 1fr;
    }
}

/* Модальное окно для добавления комнат */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease;
    padding: 20px;
    overflow-y: auto;
    box-sizing: border-box;
}

.modal-overlay.show {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow: hidden;
    animation: slideIn 0.3s ease;
    box-sizing: border-box;
    margin: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
}

.modal-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1a365d;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #718096;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #f7fafc;
    color: #2d3748;
}

.modal-description {
    padding: 0 24px 20px;
    color: #718096;
    font-size: 0.9rem;
    line-height: 1.4;
}

.modal-body {
    display: flex;
    gap: 20px;
    padding: 0 24px;
    max-height: 60vh;
    overflow: hidden;
}

.rooms-selection {
    flex: 2;
    overflow-y: auto;
}

.rooms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
    padding: 20px 0;
}

.room-card {
    background: #f8f9fa;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.room-card:hover {
    border-color: #f5c933;
    box-shadow: 0 2px 8px rgba(245, 201, 51, 0.1);
}

.room-card-icon {
    font-size: 1.5rem;
    color: #f5c933;
}

.room-card-name {
    flex: 1;
    font-weight: 600;
    color: #2d3748;
    font-size: 0.9rem;
}

.room-card-add {
    width: 32px;
    height: 32px;
    background: #f5c933;
    color: white;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
}

.room-card-add:hover {
    background: #f5c933;
    transform: scale(1.1);
}

.added-rooms {
    flex: 1;
    background: #f8f9fa;
    border-radius: 8px;
    overflow: hidden;
}

.added-rooms-header {
    background: #f5c933;
    color: white;
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
}

.clear-all-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1.1rem;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: background 0.2s ease;
}

.clear-all-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.added-rooms-list {
    max-height: 300px;
    overflow-y: auto;
    padding: 8px;
}

.added-room-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    margin-bottom: 4px;
    background: white;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    font-size: 0.9rem;
    color: #2d3748;
}

.added-room-remove {
    background: none;
    border: none;
    color: #718096;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.added-room-remove:hover {
    background: #f7fafc;
    color: #e53e3e;
}

.modal-footer {
    padding: 20px 24px;
    border-top: 1px solid #e2e8f0;
    text-align: right;
}

.btn-add-rooms {
    background: #f5c933;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-add-rooms:hover {
    background: #f5c933;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(245, 201, 51, 0.3);
}

/* Анимации для модального окна */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Адаптивность для модального окна */
@media (max-width: 768px) {
    .modal-overlay {
        padding: 10px;
    }
    
    .modal-content {
        width: 95%;
        max-width: 95%;
        padding: 20px 15px;
        max-height: 95vh;
    }
    
    .modal-body {
        flex-direction: column;
        gap: 16px;
    }
    
    .rooms-grid {
        grid-template-columns: 1fr;
    }
    
    .added-rooms {
        max-height: none;
        min-height: 150px;
        display: flex;
        flex-direction: column;
    }
    
    .added-rooms-list {
        max-height: 250px;
        min-height: 100px;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
        padding: 12px;
    }
    
    .added-rooms-list::-webkit-scrollbar {
        width: 6px;
    }
    
    .added-rooms-list::-webkit-scrollbar-track {
        background: #f1f1f1;
        border-radius: 3px;
    }
    
    .added-rooms-list::-webkit-scrollbar-thumb {
        background: #f5c933;
        border-radius: 3px;
    }
    
    .added-rooms-list::-webkit-scrollbar-thumb:hover {
        background: #d4a82a;
    }
}

/* Улучшения доступности */
.form-input:focus,
.btn:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Страница расчёта стоимости */
.quote-page {
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px;
    width: 100%;
    box-sizing: border-box;
}

.quote-layout {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 40px;
    min-height: 80vh;
    width: 100%;
    box-sizing: border-box;
}

/* Левая панель: Детали переезда */
.quote-left-panel {
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    height: fit-content;
}

.move-details {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.move-header {
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 16px;
}

.move-date-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.move-date-label {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.move-date-value {
    font-weight: 600;
    color: var(--text-secondary);
}

.price-section {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
}

.estimated-price {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.price-icon {
    font-size: 2rem;
    color: #f5c933;
}

.price-info {
    display: flex;
    flex-direction: column;
}

.price-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 5px;
}

.price-container {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.price-amount {
    font-size: 2rem;
    font-weight: 700;
    color: #f5c933;
}

.price-original {
    font-size: 1.5rem;
    font-weight: 600;
    color: #718096;
    text-decoration: line-through;
    text-decoration-thickness: 2px;
}

.price-discount-badge {
    display: inline-block;
    background: #38a169;
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.875rem;
    font-weight: 700;
    margin-left: 5px;
}

.deposit-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    font-size: 0.9rem;
}

.deposit-text {
    color: var(--text-muted);
}

.deposit-amount {
    font-weight: 600;
    color: var(--text-secondary);
}

.price-explanation {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* Route map block (between Discount Code and INCLUDED) */
.route-map-section {
    width: 100%;
    margin: 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    position: relative;
}

.route-map-container {
    min-height: 300px;
    height: 300px;
    width: 100%;
    display: none;
}

.route-map-container.visible {
    display: block;
}

.route-map-placeholder {
    min-height: 300px;
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: #f8f9fa;
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

.route-map-placeholder.hidden {
    display: none;
}

.included-section,
.not-included-section {
    border-top: 1px solid #e2e8f0;
    padding-top: 16px;
}

.included-section h4,
.not-included-section h4 {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.included-section ul,
.not-included-section ul {
    list-style: none;
    padding: 0;
}

.included-section li,
.not-included-section li {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
    padding-left: 15px;
    position: relative;
}

.included-section li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--success-color);
    font-weight: bold;
}

.not-included-section li::before {
    content: "✗";
    position: absolute;
    left: 0;
    color: var(--error-color);
    font-weight: bold;
}

/* Правая панель: Выбор дат и услуг */
.quote-right-panel {
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.date-selection h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 20px;
}

.date-grid-container {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #f5c933 #f1f1f1;
    box-sizing: border-box;
}

.date-grid-container::-webkit-scrollbar {
    height: 8px;
}

.date-grid-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.date-grid-container::-webkit-scrollbar-thumb {
    background: #f5c933;
    border-radius: 4px;
}

.date-grid-container::-webkit-scrollbar-thumb:hover {
    background: #d4a629;
}

.date-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
    flex: 1;
    overflow-x: auto;
    padding: 10px 0;
    width: 100%;
    min-width: min-content;
    box-sizing: border-box;
}

.date-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 100px;
    max-width: 100px;
    width: 100%;
    box-sizing: border-box;
    flex-shrink: 0;
}

.date-card:hover {
    border-color: #f5c933;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(245, 201, 51, 0.2);
}

.date-card.selected {
    border-color: #f5c933;
    background: rgba(245, 201, 51, 0.1);
}

.date-card.unavailable {
    opacity: 0.5;
    cursor: not-allowed;
}

.date-card.unavailable:hover {
    transform: none;
    box-shadow: none;
}

.date-info {
    margin-bottom: 10px;
    text-align: center;
}


.date-line {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 4px;
}

.date-number {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    margin-right: 4px;
}

.date-month {
    font-size: 0.8rem;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin: 0;
    font-weight: 700;
}

.day-of-week {
    font-size: 0.7rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center;
    margin-bottom: 8px;
    font-weight: 500;
    padding: 4px 8px;
    background: #f8f9fa;
    border-radius: 4px;
}


.time-slots {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.time-slot {
    background: #f8f9fa;
    border-radius: 6px;
    padding: 6px 4px;
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-secondary);
    line-height: 1.2;
}

.time-slot:hover {
    background: #f0f0f0;
    transform: translateY(-1px);
}

.time-slot.selected {
    background: #f5c933;
    color: #1a365d;
}

.time-slot.unavailable {
    background: #e2e8f0;
    color: var(--text-muted);
}

.date-legend {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.legend-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.legend-dot.selected {
    background: #f5c933;
}

.legend-dot.available {
    background: white;
    border: 2px solid #e2e8f0;
}

.legend-dot.unavailable {
    background: #e2e8f0;
}

/* Опции услуг */
.service-options {
    margin-bottom: 30px;
}

.service-option {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid #e2e8f0;
}

.service-header h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 15px;
}

.service-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}



.quantity-display {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    min-width: 30px;
    text-align: center;
}

.service-price {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.service-select-btn {
    background: #f5c933;
    color: #1a365d;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.service-select-btn:hover {
    background: #f5c933;
    transform: translateY(-1px);
}

.service-select-btn.selected {
    background: #28a745;
    color: white;
}

.service-select-btn.selected:hover {
    background: #218838;
}


.service-note {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-style: italic;
}

/* Дополнительные комментарии */
.additional-comments {
    margin-bottom: 30px;
}

.additional-comments label {
    display: block;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.additional-comments textarea {
    width: 100%;
    min-height: 100px;
    padding: 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-family: var(--font-family);
    font-size: 0.9rem;
    resize: vertical;
    transition: border-color 0.2s ease;
}

.additional-comments textarea:focus {
    outline: none;
    border-color: #f5c933;
}

/* Кнопки действий */
.quote-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.btn-book-now {
    background: #f5c933;
    color: #1a365d;
    border: none;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-book-now:hover {
    background: #f5c933;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 201, 51, 0.3);
}

.btn-back {
    background: white;
    color: var(--text-secondary);
    border: 2px solid #e2e8f0;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-back:hover {
    border-color: #f5c933;
    color: #f5c933;
}

/* Адаптивность для quote-page */
/* Планшеты большие (1025px - 1200px) */
@media (max-width: 1200px) {
    .quote-layout {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .quote-left-panel,
    .quote-right-panel {
        padding: 25px;
    }
    
    .date-grid-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        padding-bottom: 10px;
    }
    
    .date-grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 10px;
        min-width: min-content;
    }
}

/* Планшеты средние (769px - 1024px) */
@media (max-width: 1024px) {
    .quote-page {
        padding: 15px;
    }
    
    .quote-layout {
        gap: 25px;
    }
    
    .quote-left-panel,
    .quote-right-panel {
        padding: 20px;
    }
    
    .date-grid-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 0 -15px;
        padding: 0 15px 10px;
    }
    
    .date-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
        min-width: min-content;
    }
    
    .date-card {
        min-width: 90px;
    }
    
    .time-slot {
        font-size: 0.65rem;
        padding: 5px 3px;
    }
}

/* Мобильные и маленькие планшеты (до 768px) */
@media (max-width: 768px) {
    .quote-page {
        padding: 10px;
    }
    
    .quote-layout {
        gap: 20px;
    }
    
    .quote-left-panel,
    .quote-right-panel {
        padding: 15px;
    }
    
    .move-details {
        display: flex;
        flex-direction: column;
    }
    
    .move-details .discount-section { order: 1; }
    .move-details .move-header { order: 2; }
    .move-details .price-section { order: 3; }
    .move-details .route-map-section { order: 4; }
    .move-details .included-section { order: 5; }
    .move-details .not-included-section { order: 6; }
    
    .move-date-info {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    
    .price-amount {
        font-size: 1.5rem;
    }
    
    .price-icon {
        font-size: 1.5rem;
    }
    
    .date-grid-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 0 -15px;
        padding: 0 15px 10px;
    }
    
    .date-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
        min-width: min-content;
    }
    
    .date-card {
        min-width: 90px;
    }
    
    .date-number {
        font-size: 1.5rem;
    }
    
    .date-month {
        font-size: 0.7rem;
    }
    
    .day-of-week {
        font-size: 0.65rem;
    }
    
    .time-slot {
        font-size: 0.6rem;
        padding: 4px 2px;
    }
    
    .quote-actions {
        flex-direction: column;
        gap: 12px;
    }
    
    .btn-book-now,
    .btn-back {
        width: 100%;
        padding: 14px 20px;
        font-size: 1rem;
    }
    
    .service-option {
        padding: 15px;
        margin-bottom: 15px;
    }
    
    .service-header h4 {
        font-size: 1rem;
    }
    
    .discount-input-container {
        flex-direction: column;
        gap: 10px;
    }
    
    .discount-button {
        width: 100%;
    }
}

/* Маленькие мобильные (до 480px) */
@media (max-width: 480px) {
    .quote-page {
        padding: 8px;
    }
    
    .quote-left-panel,
    .quote-right-panel {
        padding: 12px;
    }
    
    .quote-layout {
        gap: 15px;
    }
    
    .price-amount {
        font-size: 1.3rem;
    }
    
    .move-date-value {
        font-size: 0.9rem;
    }
    
    .date-grid-container {
        margin: 0 -8px;
        padding: 0 8px 10px;
    }
    
    .date-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }
    
    .date-card {
        min-width: 80px;
    }
    
    .date-number {
        font-size: 1.3rem;
    }
    
    .date-month {
        font-size: 0.65rem;
    }
    
    .day-of-week {
        font-size: 0.6rem;
        padding: 3px 6px;
    }
    
    .time-slot {
        font-size: 0.55rem;
        padding: 3px 2px;
    }
    
    .service-option {
        padding: 12px;
        margin-bottom: 12px;
    }
    
    .service-header h4 {
        font-size: 0.9rem;
    }
    
    .quantity-btn {
        width: 28px;
        height: 28px;
        font-size: 0.9rem;
    }
    
    .quantity-display {
        font-size: 0.9rem;
    }
    
    .service-price {
        font-size: 0.9rem;
    }
    
    .service-select-btn {
        padding: 10px 16px;
        font-size: 0.85rem;
    }
}

/* Property details styles */
.property-details {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    align-items: flex-start;
}

.property-details-single {
    display: flex;
    gap: 20px;
    margin-top: 20px;
    align-items: flex-end;
}

.property-details-single .input-group {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.property-details-single .input-group label {
    margin-bottom: 8px;
    font-weight: 500;
}

.property-details-single .coi-checkbox {
    margin-bottom: 0;
    align-self: flex-start;
    margin-top: 28px;
}

.detail-dropdown {
    flex: 1;
    position: relative;
}

.detail-toggle {
    width: 100%;
    padding: 12px 16px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.detail-toggle:hover {
    border-color: var(--secondary-color);
}

.dropdown-arrow {
    transition: transform 0.2s ease;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.detail-content {
    margin-top: 10px;
    padding: 12px;
    background: var(--bg-secondary);
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.detail-content label {
    display: block;
    margin-bottom: 8px;
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.detail-content label:last-child {
    margin-bottom: 0;
}

.detail-content input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--secondary-color);
}

.coi-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.coi-checkbox:hover {
    border-color: var(--secondary-color);
}

.coi-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--secondary-color);
}

/* Dropdown animation */
.detail-dropdown.active .dropdown-arrow {
    transform: rotate(180deg);
}

.detail-dropdown.active .detail-content {
    display: block;
    animation: slideDown 0.2s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Адаптивность для property details */
@media (max-width: 768px) {
    .property-details {
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }
    
    .property-details-single {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
        width: 100%;
    }
    
    .property-details-single .input-group {
        flex: none;
        width: 100%;
    }
    
    .property-details-single .coi-checkbox {
        margin-top: 0;
        align-self: stretch;
        order: 3; /* Перемещаем COI Required в конец */
    }
}

/* Discount section styles */
.discount-section {
    margin: 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.discount-input-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.discount-input-group label {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.discount-input-container {
    display: flex;
    gap: 10px;
    align-items: center;
}

.discount-input {
    flex: 1;
    padding: 12px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.9rem;
    background: white;
    transition: border-color 0.2s ease;
}

.discount-input:focus {
    outline: none;
    border-color: var(--secondary-color);
}

.discount-button {
    padding: 12px 24px;
    background: var(--secondary-color);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
    white-space: nowrap;
}

.discount-button:hover {
    background: #f5c933;
}

.discount-button:active {
    transform: translateY(1px);
}

.discount-message {
    font-size: 0.85rem;
    font-weight: 500;
    min-height: 20px;
    margin-top: 5px;
}

.discount-message.success {
    color: #28a745;
}

.discount-message.error {
    color: #dc3545;
}

.discount-message.info {
    color: var(--text-secondary);
}

/* Мобильная версия для discount section */
@media (max-width: 768px) {
    .discount-input-container {
        flex-direction: column;
        gap: 10px;
    }
    
    .discount-button {
        width: 100%;
    }
}

/* Стили для кнопки добавления остановок */
.add-stops-section {
    text-align: center;
    margin: 20px 0;
}

.add-stop-button {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: #f5c933;
    color: black;
    border: none;
    border-radius: 8px;
    padding: 12px 24px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(245, 201, 51, 0.2);
}

.add-stop-button:hover {
    background: #f5c933;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(245, 201, 51, 0.3);
}

.add-stop-button:active {
    transform: translateY(0);
}

.add-stop-icon {
    width: 24px;
    height: 24px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: bold;
    color: black;
}

.add-stop-text {
}

/* Контейнер для дополнительных остановок */
.additional-stops-container {
    margin-top: 20px;
}

.additional-stop-section {
    background: #f8f9fa;
    border: 2px dashed #dee2e6;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

.additional-stop-section h4 {
    margin: 0 0 20px 0;
    color: #495057;
    font-size: 1.1rem;
    font-weight: 600;
}

.remove-stop-button {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1rem;
    font-weight: bold;
    line-height: 1;
    padding: 0;
    transition: all 0.2s ease;
}

.remove-stop-button:hover {
    background: #c82333;
    transform: scale(1.1);
}

/* Переключатель типа остановки (Pick Up / Drop Off) */
.stop-type-toggle-container {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.stop-type-toggle {
    display: flex;
    gap: 0;
    border: 2px solid #f5c933;
    border-radius: 8px;
    overflow: hidden;
    background: white;
}

.stop-type-button {
    padding: 10px 20px;
    border: none;
    background: white;
    color: #1a365d;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border-right: 2px solid #f5c933;
    font-family: var(--font-family);
}

.stop-type-button:last-child {
    border-right: none;
}

.stop-type-button.active {
    background: #f5c933;
    color: #1a365d;
}

.stop-type-button:hover:not(.active) {
    background: #f8f9fa;
}

.address-hint {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    font-style: italic;
}

/* Стили для секций адресов */
.address-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
    box-sizing: border-box;
}

.address-section .property-details-single {
    margin-top: 10px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    display: flex;
    flex-wrap: wrap; /* Позволяем элементам переноситься на новую строку */
    gap: 20px;
}

.address-section .property-details-single .input-group {
    display: flex;
    flex-direction: column;
    flex: 1 1 calc(50% - 10px); /* Два поля в ряд, учитывая gap */
    margin-bottom: 0;
}

.address-section .property-details-single .input-group label {
    margin-bottom: 8px;
    font-weight: 500;
}

.address-section .coi-checkbox {
    width: 100%; /* Принудительно занимаем всю ширину строки */
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px; /* Отступ от полей выше */
    margin-bottom: 0;
    order: 3; /* Принудительно размещаем в конце */
}
#moveDate {
    direction: ltr !important;
    text-align: left !important;
}

/* WebKit браузеры (Chrome, Safari, Edge) - принудительный порядок MM/DD/YYYY */
#moveDate::-webkit-datetime-edit {
    direction: ltr !important;
}

#moveDate::-webkit-datetime-edit-month-field {
    order: 1 !important;
    margin-right: 4px;
}

#moveDate::-webkit-datetime-edit-day-field {
    order: 2 !important;
    margin-right: 4px;
}

#moveDate::-webkit-datetime-edit-year-field {
    order: 3 !important;
}

/* Стили для разделителей в WebKit */
#moveDate::-webkit-datetime-edit-text {
    color: #666;
    font-weight: 600;
}

/* Для Firefox */
@-moz-document url-prefix() {
    #moveDate {
        text-align: left !important;
        direction: ltr !important;
    }
}

/* Дополнительные стили для принудительного формата */
#moveDate[type="date"] {
    direction: ltr !important;
    text-align: left !important;
    -webkit-appearance: none;
    -moz-appearance: textfield;
}

/* Принудительная установка американского формата */
#moveDate::before {
    content: "MM/DD/YYYY";
    position: absolute;
    top: 50%;
    left: 12px;
    transform: translateY(-50%);
    color: #999;
    font-size: 0.9rem;
    pointer-events: none;
    z-index: 1;
}

#moveDate:focus::before,
#moveDate:not(:placeholder-shown)::before {
    display: none;
}

/* Мобильные стили для секций адресов */
@media (max-width: 768px) {
    .address-section .property-details-single {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .address-section .property-details-single .input-group {
        flex: none;
        width: 100%;
        margin-bottom: 0;
    }
    
    .address-section .coi-checkbox {
        width: 100%;
        margin-top: 0;
        order: 3; /* Перемещаем COI Required в конец */
        justify-content: flex-start;
    }
}

/* Принудительное отображение скроллбара для всех элементов */
.items-content,
.items-panel,
.rooms-selection,
.added-rooms-list {
    overflow-y: scroll !important; /* Принудительно показываем скроллбар */
    scrollbar-width: thin;
    scrollbar-color: #f5c933 #f1f1f1;
}

/* Универсальные стили для всех скроллбаров на странице */
*::-webkit-scrollbar {
    width: 12px;
    -webkit-appearance: none;
}

*::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 6px;
    -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.1);
}

*::-webkit-scrollbar-thumb {
    background: #f5c933;
    border-radius: 6px;
    border: 2px solid #f1f1f1;
    min-height: 20px;
}

*::-webkit-scrollbar-thumb:hover {
    background: #f5c933;
    border-color: #e0e0e0;
}

*::-webkit-scrollbar-thumb:active {
    background: #f5c933;
}

*::-webkit-scrollbar-corner {
    background: #f1f1f1;
}

/* Modal: Boxes Prompt */
.modal-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-popup-content {
    background: white;
    border-radius: 12px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-popup-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 28px;
    color: #666;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.modal-popup-close:hover {
    background: #f0f0f0;
    color: #333;
}

.modal-popup-content h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 15px;
    margin-right: 30px;
}

.modal-popup-content p {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 30px;
    line-height: 1.6;
}

.modal-popup-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.btn-outline-pink {
    background: white;
    color: #f5c933;
    border: 2px solid #f5c933;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1rem;
}

.btn-outline-pink:hover {
    background: #f5c933;
    color: #1a365d;
    transform: translateY(-1px);
}

.btn-pink {
    background: #f5c933;
    color: #1a365d;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1rem;
}

.btn-pink:hover {
    background: #f5c933;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(245, 201, 51, 0.3);
}

/* Date arrow for loading more dates */
.date-load-more-btn {
    background: var(--secondary-color);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 20px;
    color: #1a365d;
    flex-shrink: 0;
}

.date-load-more-btn:hover {
    background: #f5c933;
    transform: translateX(3px);
}

.date-load-more-btn:active {
    transform: translateX(3px) scale(0.95);
}

/* Страница успеха */
.success-page {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    padding: 40px 20px;
    background: var(--bg-primary);
}

.success-content {
    text-align: center;
    max-width: 600px;
    padding: 60px 40px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    width: 100%;
    box-sizing: border-box;
}

.success-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 30px;
    background: #f5c933;
    color: #1a365d;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-weight: bold;
    line-height: 1;
}

.success-title {
    font-size: 2rem;
    font-weight: 700;
    color: #1a365d;
    margin-bottom: 20px;
}

.success-message {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.6;
}

.btn-return-home {
    display: inline-block;
    background: #1a365d;
    color: #f5c933;
    padding: 15px 40px;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.2s ease;
    cursor: pointer;
    border: 2px solid #1a365d;
}

.btn-return-home:hover {
    background: #f5c933;
    color: #1a365d;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(26, 54, 93, 0.3);
}

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

/* Адаптивность для страницы успеха */
@media (max-width: 768px) {
    .success-page {
        padding: 20px 10px;
        min-height: 50vh;
    }
    
    .success-content {
        padding: 40px 20px;
        max-width: 100%;
    }
    
    .success-icon {
        width: 60px;
        height: 60px;
        font-size: 36px;
        margin-bottom: 20px;
    }
    
    .success-title {
        font-size: 1.5rem;
        margin-bottom: 15px;
    }
    
    .success-message {
        font-size: 1rem;
        margin-bottom: 30px;
    }
    
    .btn-return-home {
        padding: 12px 30px;
        font-size: 1rem;
        width: 100%;
        max-width: 300px;
    }
}

@media (max-width: 480px) {
    .success-page {
        padding: 15px 8px;
    }
    
    .success-content {
        padding: 30px 15px;
    }
    
    .success-icon {
        width: 50px;
        height: 50px;
        font-size: 30px;
        margin-bottom: 15px;
    }
    
    .success-title {
        font-size: 1.3rem;
        margin-bottom: 12px;
    }
    
    .success-message {
        font-size: 0.9rem;
        margin-bottom: 25px;
    }
    
    .btn-return-home {
        padding: 12px 24px;
        font-size: 0.9rem;
    }
}

/* Страница ошибки */
.error-page {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    padding: 40px 20px;
    background: var(--bg-primary);
}

.error-content {
    text-align: center;
    max-width: 600px;
    padding: 60px 40px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    width: 100%;
    box-sizing: border-box;
}

.error-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 30px;
    background: #e53e3e;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-weight: bold;
    line-height: 1;
}

.error-title {
    font-size: 2rem;
    font-weight: 700;
    color: #1a365d;
    margin-bottom: 20px;
}

.error-message {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.6;
}

/* Адаптивность для страницы ошибки */
@media (max-width: 768px) {
    .error-page {
        padding: 20px 10px;
        min-height: 50vh;
    }
    
    .error-content {
        padding: 40px 20px;
        max-width: 100%;
    }
    
    .error-icon {
        width: 60px;
        height: 60px;
        font-size: 36px;
        margin-bottom: 20px;
    }
    
    .error-title {
        font-size: 1.5rem;
        margin-bottom: 15px;
    }
    
    .error-message {
        font-size: 1rem;
        margin-bottom: 30px;
    }
    
    .error-page .btn-return-home {
        padding: 12px 30px;
        font-size: 1rem;
        width: 100%;
        max-width: 300px;
    }
}

@media (max-width: 480px) {
    .error-page {
        padding: 15px 8px;
    }
    
    .error-content {
        padding: 30px 15px;
    }
    
    .error-icon {
        width: 50px;
        height: 50px;
        font-size: 30px;
        margin-bottom: 15px;
    }
    
    .error-title {
        font-size: 1.3rem;
        margin-bottom: 12px;
    }
    
    .error-message {
        font-size: 0.9rem;
        margin-bottom: 25px;
    }
    
    .error-page .btn-return-home {
        padding: 12px 24px;
        font-size: 0.9rem;
    }
}

/* Record Section - Видео запись */
.record-section {
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Pop-up инструкций перед записью */
.record-instructions-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.record-instructions-content {
    background: white;
    border-radius: 16px;
    padding: 40px;
    max-width: 600px;
    width: 90%;
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
}

.record-instructions-content h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 30px;
    text-align: center;
}

.instructions-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 30px;
}

.instruction-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.instruction-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.instruction-text {
    font-size: 1.1rem;
    color: var(--text-primary);
    font-weight: 500;
}

.privacy-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px;
    background: #e8f5e9;
    border-radius: 8px;
    margin-bottom: 20px;
}

.badge-icon {
    font-size: 1.5rem;
}

.badge-text {
    font-size: 0.95rem;
    color: #2e7d32;
    font-weight: 600;
}

.instruction-note {
    text-align: center;
    margin-bottom: 30px;
}

.instruction-note p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 8px;
}

.btn-ready {
    background: #f5c933;
    color: #1a365d;
    border: none;
    padding: 15px 40px;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-ready:hover {
    background: #f5c933;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 201, 51, 0.3);
}

/* Интерфейс записи видео */
.record-interface {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.record-header {
    text-align: center;
}

.record-header h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.record-header p {
    font-size: 1rem;
    color: var(--text-secondary);
}

.video-container {
    width: 100%;
    max-width: 800px;
    position: relative;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    aspect-ratio: 16/9;
}

#videoPreview,
#videoPlayback {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.record-controls {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-record {
    background: #dc3545;
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-record:hover {
    background: #c82333;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

.btn-record.btn-stop {
    background: #ffc107;
    color: #1a365d;
}

.btn-record.btn-stop:hover {
    background: #e0a800;
}

.btn-upload {
    background: #28a745;
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-upload:hover {
    background: #218838;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

.btn-retake {
    background: white;
    color: var(--text-secondary);
    border: 2px solid #e2e8f0;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-retake:hover {
    border-color: #f5c933;
    color: #f5c933;
}

.recording-status {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.recording-indicator {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #dc3545;
    font-weight: 600;
}

.recording-dot {
    width: 12px;
    height: 12px;
    background: #dc3545;
    border-radius: 50%;
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(1.2);
    }
}

.recording-timer {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    font-variant-numeric: tabular-nums;
}

/* Шкала загрузки */
.loading-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    padding: 40px 20px;
}

.loading-content {
    max-width: 600px;
    width: 100%;
    text-align: center;
}

.loading-content h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 40px;
}

.loading-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    position: relative;
}

.loading-steps::before {
    content: '';
    position: absolute;
    top: 30px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e2e8f0;
    z-index: 0;
}

.loading-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    position: relative;
    z-index: 1;
    flex: 1;
}

.step-icon {
    font-size: 2rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e2e8f0;
    border-radius: 50%;
    color: var(--text-muted);
    transition: all 0.3s ease;
}

.loading-step.active .step-icon {
    background: #f5c933;
    color: #1a365d;
    transform: scale(1.1);
}

.loading-step.completed .step-icon {
    background: #28a745;
    color: white;
}

.step-text {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.loading-step.active .step-text {
    color: var(--text-primary);
    font-weight: 600;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e2e8f0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 20px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #f5c933, #ffd700);
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

.loading-message {
    font-size: 1rem;
    color: var(--text-secondary);
    font-style: italic;
}

/* Адаптивность для record-section */
@media (max-width: 768px) {
    .record-instructions-content {
        padding: 30px 20px;
    }

    .record-instructions-content h2 {
        font-size: 1.5rem;
    }

    .instruction-item {
        padding: 12px;
    }

    .instruction-icon {
        font-size: 1.5rem;
    }

    .instruction-text {
        font-size: 1rem;
    }

    .record-header h2 {
        font-size: 1.5rem;
    }

    .record-controls {
        flex-direction: column;
        width: 100%;
    }

    .btn-record,
    .btn-upload,
    .btn-retake {
        width: 100%;
    }

    .loading-steps {
        flex-direction: column;
        gap: 20px;
    }

    .loading-steps::before {
        display: none;
    }
}
