/* Auto Lease Calculator Specific Styles */

/* Input container for form inputs */
.input-container {
    display: flex;
    gap: 8px;
}

/* Input control styling */
.input-control {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.input-control:hover {
    border-color: #003049;
    box-shadow: 0 0 0 3px rgba(0, 48, 73, 0.1);
}

.input-control:focus {
    outline: none;
    border-color: #003049;
    box-shadow: 0 0 0 3px rgba(0, 48, 73, 0.1);
}

/* Custom select styling */
select.input-control {
    appearance: none;
    -webkit-appearance: none;
    padding-right: 36px;
    cursor: pointer;
    background: white url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L5 5L9 1' stroke='%23333333' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 12px center;
}

/* Type selector in input container */
.input-container select.input-control {
    max-width: 140px;
    flex-shrink: 0;
}

/* Error states */
.input-control.error {
    border-color: #dc2626;
    background-color: #fff;
}

.input-control.error:hover {
    border-color: #dc2626;
    box-shadow: 0 1px 2px rgba(220, 38, 38, 0.1);
}

.input-control.error:focus {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

.error-message {
    color: #dc2626;
    font-size: 14px;
    margin-top: 4px;
    display: none;
}

.error-message.visible {
    display: block;
}

/* Checkbox group */
.checkbox-group {
    margin: 20px 0;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

/* Fees section styling */
#feesSection {
    background: #f8f9fa;
    border: 1px dashed #ddd;
    border-radius: 4px;
    padding: 16px;
    margin-bottom: 20px;
}

#feesSection .form-group:last-child {
    margin-bottom: 0;
}

/* Button group */
.button-group {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

/* Results grid for lease summary */
.results-grid {
    display: grid;
    gap: 12px;
}

.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 4px;
    border: 1px solid #bae6fd;
}

.result-label {
    color: #666;
    font-size: 14px;
}

.result-value {
    color: #003049;
    font-size: 16px;
    font-weight: 600;
}

.result-value.highlight {
    color: #003049;
    font-size: 20px;
}

/* Monthly Payment Highlight */
.monthly-payment-highlight {
    background: linear-gradient(to bottom right, #003049, #00436b);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    margin-bottom: 16px;
}

.monthly-payment-label {
    color: #bae6fd;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.monthly-payment-value {
    color: white;
    font-size: 32px;
    font-weight: 700;
}

.monthly-payment-note {
    color: #bae6fd;
    font-size: 12px;
    margin-top: 4px;
}

/* Comparison Cards */
.comparison-cards {
    display: grid;
    gap: 20px;
}

.comparison-card {
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    padding: 20px;
    transition: all 0.3s ease;
}

.comparison-card.lease-card {
    border-color: #3b82f6;
}

.comparison-card.buy-card {
    border-color: #10b981;
}

.comparison-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e5e7eb;
}

.comparison-card-title {
    color: #003049;
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

.comparison-card-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.comparison-card.lease-card .comparison-card-badge {
    background: #dbeafe;
    color: #1d4ed8;
}

.comparison-card.buy-card .comparison-card-badge {
    background: #d1fae5;
    color: #047857;
}

.comparison-card-body {
    display: grid;
    gap: 10px;
}

.comparison-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #f3f4f6;
}

.comparison-item:last-child {
    border-bottom: none;
}

.comparison-label {
    color: #666;
    font-size: 14px;
}

.comparison-value {
    color: #003049;
    font-size: 16px;
    font-weight: 600;
}

.comparison-value.total {
    font-size: 18px;
}

/* Summary Box */
.summary-box {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 1px solid #0ea5e9;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
    text-align: center;
}

.summary-title {
    color: #0369a1;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
}

.summary-text {
    color: #0c4a6e;
    font-size: 14px;
    line-height: 1.5;
}

.summary-highlight {
    font-weight: 700;
    color: #003049;
}

/* Cost Breakdown Section */
.cost-breakdown {
    background: #f8f9fa;
    border-radius: 6px;
    padding: 16px;
    margin-top: 16px;
}

.cost-breakdown-title {
    font-size: 14px;
    font-weight: 600;
    color: #003049;
    margin-bottom: 12px;
}

.cost-breakdown-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    font-size: 13px;
}

.cost-breakdown-label {
    color: #666;
}

.cost-breakdown-value {
    color: #003049;
    font-weight: 500;
}

/* Responsive Design */
@media (min-width: 768px) {
    .comparison-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 767px) {
    .comparison-cards {
        grid-template-columns: 1fr;
    }

    .input-container {
        flex-direction: column;
    }

    .input-container select.input-control {
        max-width: 100%;
    }

    .monthly-payment-value {
        font-size: 28px;
    }

    .comparison-card {
        padding: 16px;
    }
}

@media (max-width: 480px) {
    .button-group {
        flex-direction: column;
    }

    .button-group .btn,
    .button-group .share-trigger-btn {
        width: 100%;
    }

    .result-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .comparison-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
}
