.calculator-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: Arial, sans-serif;
}

h1 {
    color: #333;
    margin-bottom: 30px;
    text-align: center;
}

/* Сообщения */
.messages {
    margin-bottom: 20px;
}

.alert {
    padding: 12px 20px;
    border-radius: 4px;
    margin-bottom: 10px;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Сетка проекций */
.projections-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

.projection-card {
    background: #f9f9f9;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.projection-card h3 {
    margin: 0 0 15px 0;
    color: #444;
    text-align: center;
}

.image-container {
    position: relative;
    display: inline-block;
    max-width: 100%;
}

.car-image {
    display: block;
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

.overlay-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: auto;
}

/* Список выбранных деталей */
.selected-parts-section {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.selected-parts-section h2 {
    margin: 0 0 20px 0;
    color: #333;
}

.selected-parts-table {
    width: 100%;
    border-collapse: collapse;
}

.selected-parts-table th {
    text-align: left;
    padding: 12px;
    background-color: #f2f2f2;
    border-bottom: 2px solid #ddd;
}

.selected-parts-table td {
    padding: 12px;
    border-bottom: 1px solid #eee;
}

.selected-parts-table tbody tr:hover {
    background-color: #f9f9f9;
}

.selected-parts-table tfoot {
    font-weight: bold;
    background-color: #f2f2f2;
}

.price, .total-price {
    color: #28a745;
    font-weight: bold;
}

.service-form {
    margin: 0;
}

.service-select {
    padding: 5px;
    border: 1px solid #ddd;
    border-radius: 4px;
    width: 150px;
}

.remove-form {
    margin: 0;
}

.remove-btn {
    background: none;
    border: none;
    color: #dc3545;
    font-size: 18px;
    cursor: pointer;
    padding: 0 5px;
}

.remove-btn:hover {
    color: #c82333;
}

.no-parts {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 40px;
}

/* Кнопки действий */
.actions {
    text-align: center;
    margin-top: 20px;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    margin: 0 10px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
}

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

.btn-primary:hover {
    background-color: #0056b3;
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background-color: #545b62;
}

/* Модальное окно */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    padding: 30px;
    border-radius: 8px;
    max-width: 400px;
    width: 90%;
}

.modal-content h3 {
    margin: 0 0 20px 0;
    color: #333;
}

.service-options {
    margin-bottom: 20px;
}

.service-option {
    display: block;
    margin: 10px 0;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
}

.service-option:hover {
    background-color: #f9f9f9;
}

.service-option input[type="radio"] {
    margin-right: 10px;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.modal-actions button {
    padding: 8px 16px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}

.modal-actions .btn-primary {
    background-color: #007bff;
    color: white;
}

.modal-actions .btn-secondary {
    background-color: #6c757d;
    color: white;
}

/* Адаптивность */
@media (max-width: 768px) {
    .projections-grid {
        grid-template-columns: 1fr;
    }
    
    .selected-parts-table {
        font-size: 14px;
    }
    
    .service-select {
        width: 120px;
    }
}

.service-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 10px 0;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
}

.service-option:hover {
    background-color: #f9f9f9;
}

.service-option input[type="radio"] {
    margin-right: 10px;
}

.service-name {
    flex-grow: 1;
    margin-left: 10px;
}

.service-price {
    font-weight: bold;
    color: #28a745;
}

.service-option {
    display: flex;
    align-items: center;
    margin: 10px 0;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.service-option:hover {
    background-color: #f5f5f5;
}

.service-option input[type="radio"] {
    margin-right: 15px;
}

.service-color-preview {
    width: 30px;
    height: 20px;
    border-radius: 4px;
    border: 1px solid #ccc;
    margin-right: 10px;
}

.service-name {
    flex-grow: 1;
}

.service-price {
    font-weight: bold;
    color: #28a745;
    margin-left: 15px;
}

/* Стили для модальных окон форм */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 10000;
}

.modal-content {
    background: #2d2d2d;
    padding: 30px;
    border-radius: 15px;
    border: 1px solid #4a4a4a;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    width: 90%;
    max-width: 500px;
}

.modal-content h3 {
    color: #e0e0e0;
    margin-bottom: 20px;
    font-family: 'Montserrat', sans-serif;
}

.modal-content input,
.modal-content select {
    background: #363636;
    border: 1px solid #4a4a4a;
    color: #e0e0e0;
    padding: 12px;
    border-radius: 5px;
    width: 100%;
    font-size: 16px;
}

.modal-content input:focus,
.modal-content select:focus {
    outline: none;
    border-color: #4a90e2;
}

.modal-content label {
    color: #b0b0b0;
    margin-bottom: 5px;
    display: block;
}

.action-buttons {
    margin: 30px 0;
}