/* ==========================================================================
   AddonForYou Calculator Hub - Calculator Layouts & Component CSS
   Handles interactive panels, scientific keypads, sliders, result cards, and formulas.
   ========================================================================== */

.calc-page-wrapper {
    padding: 40px 0 60px;
}

.calc-layout-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 36px;
    align-items: start;
}

.calc-layout-full {
    display: block;
    max-width: 900px;
    margin: 0 auto;
}

/* Calculator Main Panel */
.calc-card-main {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    padding: 36px;
    margin-bottom: 40px;
}

.calc-header-title {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    font-weight: 800;
    color: var(--text-main);
    letter-spacing: -0.02em;
    margin-bottom: 12px;
}

.calc-header-intro {
    font-size: 1.0625rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 28px;
}

/* Form Controls */
.calc-form-group {
    margin-bottom: 24px;
}

.calc-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9375rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}

.calc-label-hint {
    font-size: 0.8125rem;
    color: var(--text-muted);
    font-weight: normal;
}

.calc-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.calc-input-prefix, .calc-input-suffix {
    position: absolute;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.9375rem;
    pointer-events: none;
}

.calc-input-prefix {
    left: 16px;
}

.calc-input-suffix {
    right: 16px;
}

.calc-input, .calc-select {
    width: 100%;
    padding: 13px 16px;
    font-size: 1.0625rem;
    color: var(--text-main);
    background: #ffffff;
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-md);
    outline: none;
    transition: all 0.2s ease;
}

.has-prefix .calc-input {
    padding-left: 36px;
}

.has-suffix .calc-input {
    padding-right: 48px;
}

.calc-input:focus, .calc-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

/* Synchronized Sliders */
.calc-slider-wrapper {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.calc-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    background: #e2e8f0;
    border-radius: 4px;
    outline: none;
}

.calc-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(79, 70, 229, 0.4);
    transition: transform 0.1s ease;
}

.calc-slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
}

.slider-limits {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-light);
    margin-top: 4px;
}

/* Radio / Button Pill Toggles */
.calc-pill-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.calc-pill-btn {
    padding: 8px 16px;
    background: var(--bg-alt);
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-full);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    transition: all 0.15s ease;
}

.calc-pill-btn:hover {
    background: #ffffff;
    border-color: var(--border-focus);
}

.calc-pill-btn.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #ffffff;
}

/* Action Buttons (Calculate / Reset) */
.calc-action-bar {
    display: flex;
    gap: 14px;
    margin-top: 28px;
}

.btn-calc {
    flex: 2;
    padding: 14px 24px;
    font-size: 1.0625rem;
}

.btn-reset {
    flex: 1;
    padding: 14px 20px;
    background: var(--bg-alt);
    color: var(--text-muted);
    border: 1px solid var(--border-color);
}

.btn-reset:hover {
    background: #e2e8f0;
    color: var(--text-main);
}

/* Result Box Display */
.calc-result-box {
    margin-top: 32px;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border: 2px solid #e2e8f0;
    border-radius: var(--radius-lg);
    padding: 28px;
    position: relative;
    transition: all 0.3s ease;
}

.calc-result-box.highlight {
    border-color: var(--primary);
    background: linear-gradient(135deg, #eef2ff 0%, #f5f3ff 100%);
}

.calc-result-label {
    font-size: 0.875rem;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.calc-result-primary {
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 800;
    color: #0f172a;
    font-family: var(--font-mono);
    line-height: 1.15;
    margin-bottom: 16px;
    word-break: break-all;
}

.calc-result-breakdown {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 14px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.result-breakdown-item {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px 14px;
}

.breakdown-title {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: block;
    margin-bottom: 4px;
}

.breakdown-val {
    font-size: 1.125rem;
    font-weight: 700;
    color: #0f172a;
    font-family: var(--font-mono);
}

/* Result Actions (Copy / Share) */
.calc-result-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.btn-tool-action {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-tool-action:hover {
    background: var(--bg-alt);
    border-color: var(--primary);
    color: var(--primary);
}

.copy-success-tooltip {
    color: var(--accent-green);
    font-size: 0.8125rem;
    margin-left: 8px;
    display: none;
}

/* Scientific & Basic Calculator Display Keypad */
.calc-screen-wrapper {
    background: #0f172a;
    color: #ffffff;
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.4);
}

.calc-screen-sub {
    min-height: 24px;
    font-size: 0.875rem;
    color: #94a3b8;
    text-align: right;
    font-family: var(--font-mono);
    word-break: break-all;
}

.calc-screen-main {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    color: #f8fafc;
    text-align: right;
    font-family: var(--font-mono);
    word-break: break-all;
    line-height: 1.2;
}

.keypad-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.keypad-grid-sci {
    grid-template-columns: repeat(5, 1fr);
}

.key-btn {
    padding: 16px 10px;
    font-size: 1.125rem;
    font-weight: 600;
    border: 1px solid var(--border-color);
    background: #ffffff;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.15s ease;
    user-select: none;
}

.key-btn:hover {
    background: var(--bg-alt);
    border-color: #cbd5e1;
}

.key-btn:active {
    transform: scale(0.96);
}

.key-btn.op {
    background: #f1f5f9;
    color: var(--primary);
    font-weight: 700;
}

.key-btn.fn {
    background: #f8fafc;
    color: var(--secondary);
    font-size: 0.9375rem;
}

.key-btn.clear {
    background: #fee2e2;
    color: var(--accent-red);
    border-color: #fca5a5;
}

.key-btn.equals {
    background: var(--primary-gradient);
    color: #ffffff;
    border: none;
    font-weight: 700;
}

/* Educational Explanatory Content Section */
.calc-content-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 36px;
    margin-bottom: 32px;
}

.content-block {
    margin-bottom: 32px;
}

.content-block:last-child {
    margin-bottom: 0;
}

.content-block-title {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.content-block-title svg {
    color: var(--primary);
}

.formula-display-box {
    background: #f8fafc;
    border-left: 4px solid var(--primary);
    padding: 16px 20px;
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    font-family: var(--font-mono);
    font-size: 0.9375rem;
    color: #1e293b;
    margin: 14px 0;
}

.example-box {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: var(--radius-md);
    padding: 18px 20px;
    color: #166534;
    font-size: 0.9375rem;
}

.limitations-box {
    background: #fffbeb;
    border: 1px solid #fef3c7;
    border-radius: var(--radius-md);
    padding: 18px 20px;
    color: #92400e;
    font-size: 0.9375rem;
}

.steps-list {
    padding-left: 20px;
    line-height: 1.8;
    color: var(--text-main);
}

.steps-list li {
    margin-bottom: 8px;
}

/* Sidebar Widgets */
.sidebar-widget {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 24px;
}

.widget-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-main);
}

.related-calcs-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.related-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-radius: var(--radius-md);
    background: var(--bg-alt);
    color: var(--text-main);
    font-size: 0.875rem;
    font-weight: 600;
    transition: all 0.15s ease;
}

.related-link:hover {
    background: var(--primary-light);
    color: var(--primary);
}

/* History Box */
.calc-history-list {
    max-height: 240px;
    overflow-y: auto;
    font-family: var(--font-mono);
    font-size: 0.8125rem;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.history-item {
    padding: 8px 10px;
    background: var(--bg-alt);
    border-radius: var(--radius-sm);
    display: flex;
    justify-content: space-between;
    cursor: pointer;
}

.history-item:hover {
    background: #e2e8f0;
}

/* -------------------------------------------------------------------------
 * HOMEPAGE FLAGSHIP FEATURED SECTION
 * Direct Top Loan EMI Calculator + Quick Nav Sidebar
 * ------------------------------------------------------------------------- */

.home-flagship-section {
    padding: 32px 0 44px;
    background: #f8fafc;
    border-bottom: 1px solid var(--border-color);
}

.home-flagship-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 32px;
    align-items: start;
}

.home-flagship-main {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 32px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.04);
}

.home-flagship-header {
    margin-bottom: 24px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--border-color);
}

.flagship-sidebar-card {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 22px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
}

.flagship-sidebar-title {
    font-size: 0.9375rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 0 0 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

.flagship-sidebar-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.flagship-calc-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 12px;
    border-radius: var(--radius-md);
    background: #f8fafc;
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 600;
    transition: all 0.15s ease;
}

.flagship-calc-link:hover {
    background: var(--primary-light);
    color: var(--primary);
    transform: translateX(3px);
}

.flagship-calc-arrow {
    color: var(--text-muted);
    font-size: 0.875rem;
    transition: transform 0.15s ease;
}

.flagship-calc-link:hover .flagship-calc-arrow {
    color: var(--primary);
    transform: translateX(2px);
}

.flagship-cat-count {
    font-size: 0.6875rem;
    background: #e2e8f0;
    color: #475569;
    padding: 2px 8px;
    border-radius: var(--radius-full);
    font-weight: 700;
}

@media (max-width: 992px) {
    .home-flagship-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    .home-flagship-main {
        padding: 20px 16px;
    }
}

/* -------------------------------------------------------------------------
 * ADVANCED LOAN EMI CALCULATOR (Inspired by emicalculator.net)
 * Tabs, Tenure Toggle, SVG Donut Chart, and Amortization Schedule
 * ------------------------------------------------------------------------- */

.emi-loan-tabs {
    display: flex;
    gap: 8px;
    background: #f1f5f9;
    padding: 6px;
    border-radius: var(--radius-lg);
    margin-bottom: 24px;
    border: 1px solid var(--border-color);
}

.emi-tab {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 16px;
    background: transparent;
    border: none;
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.emi-tab:hover {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.6);
}

.emi-tab.active {
    background: #ffffff;
    color: var(--primary);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

.tenure-input-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}

.tenure-toggle-group {
    display: flex;
    background: #f1f5f9;
    padding: 3px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-color);
    flex-shrink: 0;
}

.tenure-toggle-btn {
    border: none;
    background: transparent;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.15s ease;
}

.tenure-toggle-btn.active {
    background: var(--primary);
    color: #ffffff;
    box-shadow: 0 1px 3px rgba(79, 70, 229, 0.3);
}

/* EMI Donut Chart & Breakup Cards */
.emi-result-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: center;
    margin-top: 10px;
}

.emi-breakup-chart-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: #ffffff;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
}

.emi-chart-title {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.donut-svg-wrapper {
    position: relative;
    width: 190px;
    height: 190px;
}

.donut-svg {
    transform: rotate(-90deg);
    border-radius: 50%;
}

.donut-slice-principal {
    transition: stroke-dasharray 0.4s ease, stroke-dashoffset 0.4s ease;
}

.donut-slice-interest {
    transition: stroke-dasharray 0.4s ease, stroke-dashoffset 0.4s ease;
}

.donut-center-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    pointer-events: none;
}

.donut-center-sub {
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
}

.donut-center-val {
    font-size: 1.125rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1.1;
    margin-top: 2px;
}

.donut-legend {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    margin-top: 16px;
    font-size: 0.8125rem;
}

.legend-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.legend-color-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 6px;
}

.legend-dot-principal {
    background: #10b981;
}

.legend-dot-interest {
    background: #f59e0b;
}

/* Amortization Table & Visual Yearly Graph */
.emi-amortization-card {
    margin-top: 36px;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-sm);
}

.amortization-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border-color);
}

.amortization-title {
    font-size: 1.125rem;
    font-weight: 800;
    color: var(--text-main);
    margin: 0;
}

/* Yearly Bar Chart Visualization */
.emi-bar-chart-container {
    margin-bottom: 24px;
    padding: 16px 12px;
    background: #f8fafc;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.bar-chart-bars {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    height: 140px;
    padding-top: 10px;
    overflow-x: auto;
}

.chart-bar-group {
    flex: 1;
    min-width: 24px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    cursor: pointer;
    position: relative;
}

.bar-stack {
    width: 100%;
    display: flex;
    flex-direction: column-reverse;
    border-radius: 3px 3px 0 0;
    overflow: hidden;
}

.bar-slice-principal {
    background: #10b981;
    width: 100%;
    transition: height 0.3s ease;
}

.bar-slice-interest {
    background: #f59e0b;
    width: 100%;
    transition: height 0.3s ease;
}

.bar-label-year {
    font-size: 0.6875rem;
    color: #64748b;
    margin-top: 6px;
    font-weight: 600;
    text-align: center;
}

/* EMI Schedule Control Bar (Start month/year & Calendar vs Financial View) */
.emi-schedule-control-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    background: #f8fafc;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px 18px;
    margin-bottom: 20px;
}

.schedule-start-group {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.schedule-control-label {
    font-size: 0.875rem;
    font-weight: 700;
    color: #334155;
}

.schedule-date-pickers {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: var(--radius-sm);
    padding: 4px 8px;
}

.schedule-mini-select {
    border: none;
    background: transparent;
    font-size: 0.875rem;
    font-weight: 700;
    color: #0f172a;
    padding: 2px 4px;
    outline: none;
    cursor: pointer;
}

.schedule-calendar-icon {
    font-size: 0.9375rem;
    margin-left: 2px;
}

.schedule-view-group {
    display: flex;
    align-items: center;
}

.schedule-view-select {
    border: 1.5px solid #2563eb;
    background: #eff6ff;
    color: #1d4ed8;
    font-size: 0.875rem;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: var(--radius-sm);
    outline: none;
    cursor: pointer;
    transition: all 0.15s ease;
}

.schedule-view-select:hover {
    background: #dbeafe;
}

/* Prepayment & Rate Changes Impact Banner */
.emi-impact-card {
    background: linear-gradient(135deg, #f0fdf4 0%, #eff6ff 100%);
    border: 1.5px solid #86efac;
    border-radius: var(--radius-md);
    padding: 18px 20px;
    margin-bottom: 22px;
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.08);
}

.impact-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 14px;
}

.impact-badge {
    font-size: 0.8125rem;
    font-weight: 800;
    color: #15803d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-clear-adjustments {
    background: #ffffff;
    border: 1px solid #fca5a5;
    border-radius: 4px;
    padding: 4px 12px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #dc2626;
    cursor: pointer;
    transition: all 0.15s ease;
}

.btn-clear-adjustments:hover {
    background: #fee2e2;
}

.impact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 12px;
}

.impact-metric {
    background: #ffffff;
    padding: 10px 14px;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.impact-metric-label {
    display: block;
    font-size: 0.6875rem;
    color: #64748b;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.impact-metric-value {
    font-size: 1.05rem;
    font-weight: 800;
    color: #0f172a;
}

.highlight-green .impact-metric-value {
    color: #16a34a;
}

.highlight-blue .impact-metric-value {
    color: #2563eb;
}

/* Schedule Table */
.schedule-table-wrapper {
    overflow-x: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.schedule-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
    text-align: right;
}

.schedule-table th {
    background: #f8fafc;
    padding: 12px 14px;
    font-weight: 700;
    color: #334155;
    border-bottom: 2px solid var(--border-color);
    white-space: nowrap;
}

.schedule-table th:first-child,
.schedule-table td:first-child {
    text-align: left;
}

.schedule-table td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-main);
    white-space: nowrap;
}

.schedule-row-year {
    background: #ffffff;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.15s ease;
}

.schedule-row-year:hover {
    background: #f1f5f9;
}

.schedule-row-month {
    background: #f8fafc;
    font-size: 0.8125rem;
    color: #475569;
}

.schedule-row-month td {
    padding: 6px 14px;
    border-bottom: 1px dashed #e2e8f0;
}

/* Inline Table Inputs for Part Payment and Interest Rate */
.schedule-input-wrapper {
    display: inline-flex;
    align-items: center;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    padding: 2px 6px;
    width: 105px;
    box-sizing: border-box;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.schedule-input-wrapper:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.schedule-input-prefix {
    font-size: 0.75rem;
    color: #64748b;
    font-weight: 700;
    margin-right: 2px;
}

.schedule-cell-input {
    width: 100%;
    border: none;
    background: transparent;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #0f172a;
    text-align: right;
    padding: 1px 0;
    outline: none;
    -moz-appearance: textfield;
}

.schedule-cell-input::-webkit-outer-spin-button,
.schedule-cell-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.schedule-rate-wrapper {
    display: inline-flex;
    align-items: center;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    padding: 2px 6px;
    width: 72px;
    box-sizing: border-box;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.schedule-rate-wrapper:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.15);
}

.schedule-unit {
    font-size: 0.75rem;
    color: #64748b;
    font-weight: 700;
    margin-left: 2px;
}

.schedule-toggle-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 4px;
    background: #e2e8f0;
    color: #334155;
    font-size: 0.75rem;
    margin-right: 8px;
    font-weight: 800;
    user-select: none;
    transition: transform 0.2s ease;
}

.paid-progress-bar {
    display: inline-block;
    width: 50px;
    height: 6px;
    background: #e2e8f0;
    border-radius: 3px;
    margin-right: 8px;
    vertical-align: middle;
    overflow: hidden;
}

.paid-progress-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 3px;
}

@media (max-width: 768px) {
    .emi-result-layout {
        grid-template-columns: 1fr;
    }
    .emi-loan-tabs {
        flex-direction: column;
    }
    .donut-svg-wrapper {
        width: 160px;
        height: 160px;
    }
}

@media (max-width: 992px) {
    .calc-layout-grid {
        grid-template-columns: 1fr;
    }
}


