/* APR Calculator Widget Styles */
.apr-calculator-widget {
    max-width: 480px;
    margin: 0 auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
}

.apr-calculator-widget * {
    box-sizing: border-box;
}

.apr-widget-header {
    background: linear-gradient(135deg, #2271b1, #135e96);
    color: #fff;
    padding: 24px;
    text-align: center;
}

.apr-widget-header h2 {
    margin: 0 0 8px 0;
    font-size: 24px;
    font-weight: 600;
}

.apr-widget-header p {
    margin: 0;
    opacity: 0.9;
    font-size: 14px;
}

.apr-widget-body {
    padding: 24px;
}

.apr-form-row {
    margin-bottom: 20px;
}

.apr-form-row label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #1d2327;
    font-size: 14px;
}

.apr-hint {
    font-weight: 400;
    color: #757575;
    font-size: 12px;
}

.apr-form-row input,
.apr-form-row select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #c3c4c7;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.apr-form-row input:focus,
.apr-form-row select:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 0 2px rgba(34, 113, 177, 0.2);
}

.apr-input-group {
    position: relative;
}

.apr-input-group .apr-prefix {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #757575;
    font-size: 16px;
}

.apr-input-group input {
    padding-left: 28px;
}

.apr-form-row-half {
    display: flex;
    gap: 16px;
}

.apr-form-row-half .apr-form-row {
    flex: 1;
}

.apr-btn-calculate {
    width: 100%;
    padding: 14px 24px;
    background: #2271b1;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.apr-btn-calculate:hover {
    background: #135e96;
}

.apr-btn-calculate:disabled {
    background: #a0a5aa;
    cursor: not-allowed;
}

.apr-results-panel {
    margin-top: 24px;
    padding: 20px;
    background: #f6f7f7;
    border-radius: 6px;
    border: 1px solid #e0e0e0;
}

.apr-hidden {
    display: none !important;
}

.apr-result-main {
    text-align: center;
    padding-bottom: 16px;
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 16px;
}

.apr-result-main .apr-label {
    font-size: 14px;
    color: #757575;
    margin-bottom: 4px;
}

.apr-result-main .apr-value {
    font-size: 42px;
    font-weight: 700;
    color: #1d2327;
}

.apr-result-main .apr-value span {
    font-size: 24px;
}

.apr-result-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.apr-result-item {
    background: #fff;
    padding: 12px;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
}

.apr-result-item .apr-label {
    font-size: 11px;
    color: #757575;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.apr-result-item .apr-value {
    font-size: 18px;
    font-weight: 600;
    color: #1d2327;
}

.apr-final-payment-notice {
    margin-top: 16px;
    padding: 12px;
    background: #e7f3ff;
    border-left: 4px solid #2271b1;
    font-size: 13px;
    color: #1d4f7a;
    border-radius: 0 4px 4px 0;
}

.apr-final-payment-notice strong {
    color: #135e96;
}

.apr-download-section {
    margin-top: 16px;
    text-align: center;
}

.apr-btn-download {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: #00a32a;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.apr-btn-download:hover {
    background: #008a20;
}

.apr-btn-download svg {
    flex-shrink: 0;
}

.apr-disclaimer {
    margin-top: 16px;
    padding: 12px;
    background: #fff8e5;
    border-left: 4px solid #dba617;
    font-size: 12px;
    color: #6e5a1a;
    border-radius: 0 4px 4px 0;
}

.apr-error-panel {
    margin-top: 24px;
    padding: 16px;
    background: #fcf0f1;
    border-left: 4px solid #d63638;
    border-radius: 0 4px 4px 0;
}

.apr-error-panel p {
    margin: 0;
    color: #8a1e1e;
    font-size: 14px;
}

/* Responsive */
@media (max-width: 480px) {
    .apr-form-row-half {
        flex-direction: column;
        gap: 0;
    }

    .apr-result-details {
        grid-template-columns: 1fr;
    }

    .apr-result-main .apr-value {
        font-size: 36px;
    }
}
