/* Стили для конфигуратора */
.configurator-hero {
    background: linear-gradient(rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.8)), 
                url('https://via.placeholder.com/1920x600/111/333?text=Configurator') no-repeat center center/cover;
    padding: 120px 0 80px;
    text-align: center;
}

.configurator-hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.configurator-hero p {
    font-size: 1.2rem;
    color: #ccc;
}

.configurator-main {
    padding: 50px 0;
    background-color: #0a0a0a;
}

.configurator-layout {
    display: grid;
    grid-template-columns: 400px 1fr;
    gap: 2rem;
    min-height: 800px;
}

/* Сайдбар конфигуратора */
.config-sidebar {
    background: #111;
    border-radius: 10px;
    padding: 2rem;
    height: fit-content;
    position: sticky;
    top: 100px;
}

.config-step {
    margin-bottom: 2rem;
    display: none;
}

.config-step.active {
    display: block;
}

.config-step h3 {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    color: #d4af37;
    border-bottom: 1px solid #333;
    padding-bottom: 0.5rem;
}

/* Выбор бренда */
.brand-selection {
    display: grid;
    gap: 1rem;
}

.brand-option {
    background: #1a1a1a;
    padding: 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.brand-option:hover {
    border-color: #d4af37;
    transform: translateY(-2px);
}

.brand-option.selected {
    border-color: #d4af37;
    background: linear-gradient(135deg, #1a1a1a, #2a2a2a);
}

.brand-logo {
    width: 60px;
    height: 60px;
    background: linear-gradient(45deg, #d4af37, #6ba8e9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 1rem;
}

.brand-option[data-brand="benefactor"] .brand-logo {
    background: linear-gradient(45deg, #d4af37, #b8860b);
}

.brand-option[data-brand="ubermacht"] .brand-logo {
    background: linear-gradient(45deg, #6ba8e9, #4a90e2);
}

.brand-option h4 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.brand-option p {
    color: #999;
    font-size: 0.9rem;
}

/* Выбор модели */
.model-selection {
    display: grid;
    gap: 1rem;
    max-height: 400px;
    overflow-y: auto;
}

.model-option {
    background: #1a1a1a;
    padding: 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.model-option:hover {
    border-color: #6ba8e9;
}

.model-option.selected {
    border-color: #6ba8e9;
    background: linear-gradient(135deg, #1a1a1a, #2a2a2a);
}

.model-info h4 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.model-price {
    color: #d4af37;
    font-weight: bold;
    font-size: 1.1rem;
}

.model-type {
    color: #999;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Апгрейды */
.upgrades-selection {
    display: grid;
    gap: 1.5rem;
}

.upgrade-category h4 {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: #ccc;
}

.upgrade-options {
    display: grid;
    gap: 0.5rem;
}

.upgrade-option {
    background: #1a1a1a;
    padding: 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.upgrade-option:hover {
    border-color: #6ba8e9;
}

.upgrade-option.selected {
    border-color: #d4af37;
    background: linear-gradient(135deg, #1a1a1a, #2a2a2a);
}

.upgrade-option .level {
    font-weight: 500;
}

.upgrade-option .price {
    color: #d4af37;
    font-weight: bold;
}

/* Панель предпросмотра */
.config-preview {
    background: #111;
    border-radius: 10px;
    padding: 2rem;
}

.preview-container {
    position: sticky;
    top: 20px;
}

.car-info-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    padding: 20px;
    color: white;
}

.car-info-overlay h3 {
    margin: 0 0 5px 0;
    font-size: 1.4em;
    font-weight: 600;
}

.car-info-overlay .car-type {
    margin: 0;
    color: #ccc;
    font-size: 0.9em;
}

.car-preview {
    width: 100%;
    height: 300px;
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    margin-bottom: 20px;
}

.car-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.preview-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: rgba(255,255,255,0.05);
    border: 2px dashed rgba(255,255,255,0.1);
    border-radius: 12px;
    color: #888;
    font-size: 1.1em;
}

.preview-placeholder p {
    font-size: 1.2rem;
}

.car-image {
    max-width: 100%;
    max-height: 400px;
    border-radius: 8px;
}

/* Панель итогов */
.summary-panel {
    background: #1a1a1a;
    padding: 1.5rem;
    border-radius: 8px;
}

.summary-panel h3 {
    margin-bottom: 1rem;
    color: #d4af37;
    border-bottom: 1px solid #333;
    padding-bottom: 0.5rem;
}

.summary-details {
    display: grid;
    gap: 0.8rem;
    margin-bottom: 1.5rem;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid #2a2a2a;
}

.summary-item span:first-child {
    color: #999;
}

.summary-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.2rem;
    font-weight: bold;
    padding-top: 1rem;
    border-top: 2px solid #333;
    margin-top: 0.5rem;
}

.summary-total span:last-child {
    color: #d4af37;
    font-size: 1.4rem;
}

.order-button {
    width: 100%;
    padding: 15px;
    background: linear-gradient(45deg, #d4af37, #b8860b);
    color: #000;
    border: none;
    border-radius: 6px;
    font-size: 1.1rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.order-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(212, 175, 55, 0.3);
}

.order-button:disabled {
    background: #333;
    color: #666;
    cursor: not-allowed;
    transform: none;
}

/* Навигация шагов */
.config-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #333;
}

.nav-button {
    padding: 10px 20px;
    background: #333;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.nav-button:hover:not(:disabled) {
    background: #444;
}

.nav-button:disabled {
    background: #222;
    color: #666;
    cursor: not-allowed;
}

/* Адаптивность */
@media (max-width: 968px) {
    .configurator-layout {
        grid-template-columns: 1fr;
    }
    
    .config-sidebar {
        position: static;
    }
}

/* Стили для модалки заказа */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 2rem;
}

.order-modal {
    max-width: 600px;
    background: #1a1a1a;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-header h2 {
    font-size: 2rem;
    font-weight: 500;
    color: #ffffff;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    color: #b0b0b0;
    font-size: 2rem;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: #ffffff;
}

.modal-body {
    padding: 2rem;
}

.order-form {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.order-summary, .customer-info {
    background: rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.order-summary h3, .customer-info h3 {
    color: #d4af37;
    margin-bottom: 1rem;
    font-weight: 500;
}

.order-model {
    font-size: 1.3rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.5rem;
}

.order-config {
    color: #b0b0b0;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.order-total {
    color: #d4af37;
    font-weight: 600;
    font-size: 1.1rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    color: #ffffff;
    margin-bottom: 0.5rem;
    font-weight: 400;
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    color: #ffffff;
    font-family: 'Roboto', sans-serif;
    transition: all 0.3s ease;
}

.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: #6ba8e9;
    background: rgba(255, 255, 255, 0.15);
}

.form-group textarea {
    min-height: 80px;
    resize: vertical;
}

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.cancel-btn, .submit-order-btn {
    padding: 0.8rem 1.5rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cancel-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #ffffff;
}

.cancel-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.submit-order-btn {
    background: linear-gradient(135deg, #6ba8e9, #4a90e2);
    color: #000;
}

.submit-order-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(107, 168, 233, 0.4);
}

.submit-order-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.order-button {
    width: 100%;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #d4af37, #b8860b);
    color: #000;
    border: none;
    border-radius: 5px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1rem;
}

.order-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(212, 175, 55, 0.4);
}

.order-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Адаптивность модалки */
@media (max-width: 768px) {
    .modal-overlay {
        padding: 1rem;
    }
    
    .modal-header {
        padding: 1.5rem;
    }
    
    .modal-body {
        padding: 1.5rem;
    }
    
    .form-actions {
        flex-direction: column;
    }
}

/* Широкая стильная модалка */
.modal-content.order-modal {
    width: 95%;
    max-width: 800px;
    max-height: 90vh;
    margin: 5vh auto;
    border-radius: 16px;
    background: linear-gradient(145deg, #1e1e1e 0%, #2a2a2a 100%);
    border: 1px solid rgba(255,255,255,0.15);
    box-shadow: 0 25px 50px rgba(0,0,0,0.6);
    overflow: hidden;
}

.modal-body {
    padding: 0;
    max-height: calc(90vh - 80px);
}

.order-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    height: 100%;
}

.order-summary {
    padding: 30px;
    background: rgba(255,255,255,0.03);
    border-right: 1px solid rgba(255,255,255,0.1);
}

.customer-info {
    padding: 30px;
    background: rgba(255,255,255,0.02);
}

.customer-info h3 {
    margin-bottom: 25px;
    font-size: 1.3em;
    color: #fff;
    text-align: left;
    font-weight: 500;
    border-bottom: none;
    padding-bottom: 0;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    font-size: 0.9em;
    margin-bottom: 8px;
    display: block;
    color: #bbb;
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 16px;
    font-size: 1em;
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 8px;
    color: white;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: rgba(255,255,255,0.25);
    background: rgba(255,255,255,0.1);
    box-shadow: 0 0 0 3px rgba(255,255,255,0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
    max-height: 150px;
}

.form-actions {
    grid-column: 1 / -1;
    padding: 25px 30px;
    background: rgba(255,255,255,0.03);
    border-top: 1px solid rgba(255,255,255,0.1);
    display: flex;
    gap: 15px;
    justify-content: flex-end;
}

/* Убираем скролл */
.modal-body {
    overflow: visible;
}