/* カート画面内の車種・オプションのCSS */

/* 削除ボタン押下 */
.hidden {
    background-color: #DDDDDD !important;
    button {
        border-color: var(--bs-border-color) !important;
    }
}
.hidden * {
    background-color: #DDDDDD !important;
    color: #444444 !important;
}

.vehicle-section {
    margin-bottom: 32px;
    background: #fff;
    border-radius: 8px;
    padding: 24px;
    border: 1px solid #e0e0e0;
}

.vehicle-header {
    margin-bottom: 16px;
}

.vehicle-title {
    font-size: 1.2rem;
    font-weight: bold;
    color: #333;
    margin: 0;
}

.variation-name {
    font-size: 1rem;
    color: #666;
    margin: 0;
}

.vehicle-summary-table {
    margin-bottom: 16px;
}

.vehicle-summary-table .table {
    margin-bottom: 0;
}

.vehicle-summary-table th {
    background-color: #f8f9fa;
    font-weight: bold;
    text-align: center;
    vertical-align: middle;
    padding: 12px 8px;
}

.vehicle-summary-table td {
    vertical-align: middle;
    padding: 12px 8px;
}

.vehicle-quantity {
    width: 80px;
    margin: 0 auto;
    display: block;
}

.vehicle-total-price {
    text-align: center;
    font-weight: bold;
    font-size: 1.1rem;
}

.action-buttons {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.action-buttons .btn {
    font-size: 0.9rem;
    padding: 6px 12px;
}

.options-section {
    margin-top: 16px;
}

.options-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    padding: 8px 0;
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 16px;
}

.options-title {
    font-size: 1.1rem;
    font-weight: bold;
    margin: 0;
    color: #333;
}

.collapse-icon {
    transition: transform 0.3s ease;
}

.collapsed .collapse-icon {
    transform: rotate(-90deg);
}

.options-table .table {
    margin-bottom: 0;
}

.options-table th {
    background-color: #f8f9fa;
    font-weight: bold;
    text-align: center;
    vertical-align: middle;
    padding: 10px 8px;
    font-size: 0.9rem;
}

.options-table td {
    vertical-align: middle;
    padding: 10px 8px;
    font-size: 0.9rem;
}

.option-checkbox {
    text-align: center;
    width: 100px;
}

.option-price {
    text-align: center;
    font-weight: bold;
}

.delete-option-btn {
    font-size: 0.8rem;
    padding: 4px 8px;
}

.total-amount-section {
    margin: 32px 0;
    padding: 24px;
    background-color: #f8f9fa;
    border-radius: 8px;
    text-align: right;
    font-size: 1rem;
}

.total-amount-section #total-vehicle-and-option-amount,
.total-amount-section #total-options-amount,
.total-amount-section #return-location-charge-amount,
.total-amount-section #total-amount,
.total-amount-section #other-price-amount,
#total-price-this-section {
    font-size: 1.5rem;
}

#total-price-this-section-label {
    font-size: 1.3rem;
    padding-left: 30%;
    @media (max-width: 768px) {
        display: none;
    }
}

.total-amount {
    width: 100px;
}

.no-vehicles-message {
    text-align: center;
    padding: 40px;
    color: #666;
}

.add-vehicle-btn {
    margin-bottom: 16px;
}

.next-step-to-customer-btn {
    margin-top: 64px;
}

@media (max-width: 768px) {
    .vehicle-section {
        padding: 16px;
    }
    
    .action-buttons {
        flex-direction: column;
        gap: 4px;
    }
    
    .action-buttons .btn {
        width: 100%;
    }
    
    .vehicle-summary-table .table {
        font-size: 0.9rem;
    }
    
    .options-table .table {
        font-size: 0.8rem;
    }
    
    /* フォーム要素のレスポンシブ化 */
    .vehicle-form-row {
        flex-direction: column;
        gap: 8px;
        align-items: flex-start;
    }
    
    .vehicle-form-label {
        min-width: auto;
        max-width: none;
        margin-right: 0;
        margin-bottom: 4px;
        align-items: flex-start;
        justify-content: flex-start;
    }
    
    .vehicle-form-inputs {
        width: 100%;
    }
    
    .vehicle-quantity {
        width: 100%;
        max-width: none;
    }
}

@media (max-width: 480px) {
    .vehicle-section {
        padding: 12px;
    }
    
    .vehicle-form-row {
        margin-bottom: 16px;
    }
    
    .vehicle-form-label {
        font-size: 0.95rem;
    }
    
    .options-table .table {
        font-size: 0.75rem;
    }
    
    .options-table th,
    .options-table td {
        padding: 8px 4px;
    }

    .total-amount-section {
        padding: 16px;
    }

    span.delete-vehicle-btn-text {
        display: none;
    }

    span.edit-vehicle-btn-text {
        display: none;
    }

    .quantity {
      width: 30%;  
    }
    .vehicle-total-price {
      width: 45%;  
    }
    .action {
      width: 25%;  
    }
}