/* ── Cost Estimator Widget ──────────────────────────────────────────── */

.mtfe-cost-estimator {
    background: #ffffff;
    border-radius: 16px;
    padding: 32px;
    font-family: inherit;
    box-sizing: border-box;
}

/* Header */
.mtfe-cost-estimator__title {
    margin: 0 0 6px;
    font-size: 22px;
    font-weight: 700;
    color: #111827;
    line-height: 1.3;
}

.mtfe-cost-estimator__subtitle {
    margin: 0 0 24px;
    font-size: 14px;
    color: #6B7280;
    line-height: 1.5;
}

/* Sections */
.mtfe-cost-estimator__section {
    margin-bottom: 20px;
}

.mtfe-cost-estimator__section-label {
    margin: 0 0 12px;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

/* Visit Type Grid */
.mtfe-cost-estimator__visit-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.mtfe-cost-estimator__visit-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 14px 16px;
    background: #ffffff;
    border: 1.5px solid #E5E7EB;
    border-radius: 10px;
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    user-select: none;
    outline: none;
}

.mtfe-cost-estimator__visit-card:hover:not(.is-selected) {
    border-color: #93C5FD;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
}

.mtfe-cost-estimator__visit-card:focus-visible {
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.3);
}

.mtfe-cost-estimator__visit-card.is-selected {
    background: #1B4F9F;
    border-color: #1B4F9F;
}

.mtfe-cost-estimator__visit-label {
    font-size: 15px;
    font-weight: 600;
    color: #111827;
    line-height: 1.3;
    transition: color 0.2s ease;
}

.mtfe-cost-estimator__visit-price {
    font-size: 13px;
    color: #6B7280;
    transition: color 0.2s ease;
}

.mtfe-cost-estimator__visit-card.is-selected .mtfe-cost-estimator__visit-label,
.mtfe-cost-estimator__visit-card.is-selected .mtfe-cost-estimator__visit-price {
    color: #ffffff;
}

/* Toggle Rows */
.mtfe-cost-estimator__toggles {
    display: flex;
    flex-direction: column;
    border: 1.5px solid #E5E7EB;
    border-radius: 10px;
    overflow: hidden;
}

.mtfe-cost-estimator__toggle-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px;
    border-bottom: 1.5px solid #E5E7EB;
}

.mtfe-cost-estimator__toggle-row:last-child {
    border-bottom: none;
}

.mtfe-cost-estimator__toggle-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
    min-width: 0;
}

.mtfe-cost-estimator__toggle-label {
    font-size: 14px;
    font-weight: 500;
    color: #111827;
    line-height: 1.4;
}

.mtfe-cost-estimator__toggle-sublabel {
    font-size: 12px;
    color: #6B7280;
    line-height: 1.4;
}

/* Toggle Switch */
.mtfe-cost-estimator__toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 28px;
    flex-shrink: 0;
    cursor: pointer;
}

.mtfe-cost-estimator__toggle-input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.mtfe-cost-estimator__toggle-slider {
    position: absolute;
    inset: 0;
    background: #D1D5DB;
    border-radius: 100px;
    transition: background 0.25s ease;
}

.mtfe-cost-estimator__toggle-slider::before {
    content: '';
    position: absolute;
    left: 3px;
    top: 50%;
    transform: translateY(-50%);
    width: 22px;
    height: 22px;
    background: #ffffff;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
    transition: transform 0.25s ease;
}

.mtfe-cost-estimator__toggle-input:checked + .mtfe-cost-estimator__toggle-slider {
    background: #2563EB;
}

.mtfe-cost-estimator__toggle-input:checked + .mtfe-cost-estimator__toggle-slider::before {
    transform: translateY(-50%) translateX(20px);
}

/* Footer */
.mtfe-cost-estimator__footer {
    background: #1E2B3A;
    border-radius: 12px;
    padding: 20px 24px;
    margin-top: 8px;
}

.mtfe-cost-estimator__footer-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 4px;
}

.mtfe-cost-estimator__footer-label {
    font-size: 14px;
    color: #CBD5E1;
    line-height: 1.4;
}

.mtfe-cost-estimator__price {
    font-size: 32px;
    font-weight: 800;
    color: #ffffff;
    white-space: nowrap;
    line-height: 1;
}

.mtfe-cost-estimator__save-text {
    margin: 6px 0 0;
    font-size: 13px;
    font-weight: 500;
    color: #FF6B35;
    line-height: 1.4;
}

.mtfe-cost-estimator__note {
    margin: 10px 0 0;
    font-size: 11px;
    color: #94A3B8;
    line-height: 1.5;
    text-align: center;
}

/* Responsive */
@media (max-width: 480px) {
    .mtfe-cost-estimator {
        padding: 24px 20px;
    }

    .mtfe-cost-estimator__visit-grid {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .mtfe-cost-estimator__price {
        font-size: 26px;
    }
}
