/* New vs Old Tax Regime Calculator Custom Styles */

.recommendation-card {
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    color: #fff;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.recommendation-card.new-regime-better {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    border-left: 6px solid #047857;
}

.recommendation-card.old-regime-better {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    border-left: 6px solid #1d4ed8;
}

.recommendation-card.regimes-equal {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    border-left: 6px solid #374151;
}

.rec-badge {
    display: inline-block;
    background-color: rgba(255, 255, 255, 0.2);
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
}

.rec-regime {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.rec-savings {
    font-size: 1.1rem;
    font-weight: 500;
}

.breakeven-card {
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--border-color);
    background-color: var(--card-bg-color);
}

.breakeven-card.info {
    border-left: 5px solid #3b82f6;
    background-color: rgba(59, 130, 246, 0.05);
}

.breakeven-card.success {
    border-left: 5px solid #10b981;
    background-color: rgba(16, 185, 129, 0.05);
}

.breakeven-card h3 {
    margin-top: 0;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.breakeven-card p {
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0;
}

.results-tabs {
    display: flex;
    gap: 0.5rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1.25rem;
}

.tab-btn {
    background: none;
    border: none;
    padding: 0.75rem 1.25rem;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-color);
    opacity: 0.7;
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
}

.tab-btn:hover {
    opacity: 1;
}

.tab-btn.active {
    opacity: 1;
    color: var(--primary-color);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary-color);
}

.tab-panel {
    display: none;
}

.tab-panel.active {
    display: block;
}

/* Slabs Breakdown styles */
.slab-tables-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

.slab-table-wrapper h3 {
    font-size: 1.05rem;
    margin-top: 0;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px dashed var(--border-color);
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.5rem;
}

.comparison-table th, 
.comparison-table td {
    padding: 0.85rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.comparison-table th {
    font-weight: 600;
    background-color: rgba(0, 0, 0, 0.02);
}

.comparison-table td:nth-child(2),
.comparison-table td:nth-child(3) {
    text-align: right;
}

.comparison-table tr.total td {
    font-weight: 700;
    font-size: 1.1rem;
    background-color: rgba(0, 0, 0, 0.03);
    border-top: 2px solid var(--border-color);
    border-bottom: 2px solid var(--border-color);
}

.comparison-table tr.row-taxable td {
    font-weight: 600;
    background-color: rgba(0, 0, 0, 0.01);
}

.tax-higher {
    color: #ef4444;
    font-weight: 600;
}

.tax-lower {
    color: #10b981;
    font-weight: 600;
}

.cap-warn {
    color: #ef4444;
    font-size: 0.75rem;
    margin-top: 0.25rem;
    display: none;
}

.form-group-info {
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 0.25rem;
}

.input-wrapper select {
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    background-image: url("data:image/svg+xml;utf8,<svg fill='currentColor' height='24' viewBox='0 0 24 24' width='24' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/><path d='M0 0h24v24H0z' fill='none'/></svg>") !important;
    background-repeat: no-repeat !important;
    background-position: right 12px center !important;
    padding-right: 40px !important;
    width: 100% !important;
    border: none !important;
    outline: none !important;
    background-color: transparent !important;
    font-size: 1rem !important;
    color: var(--text-color) !important;
}

.accordion-section {
    margin-top: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.accordion-header {
    background-color: rgba(0, 0, 0, 0.02);
    padding: 0.85rem 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.accordion-content {
    padding: 1.25rem 1rem;
    border-top: 1px solid var(--border-color);
}

/* Responsive Table Container & Slab Table Enhancements */
.table-container {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.slab-table-wrapper {
    min-width: 0;
}

.slab-table-wrapper table {
    width: 100%;
    border-collapse: collapse;
    min-width: 380px; /* Forces scroll bar if container width is too narrow */
}

.slab-table-wrapper th, 
.slab-table-wrapper td {
    padding: 0.75rem 0.5rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
}

.slab-table-wrapper th {
    font-weight: 600;
    background-color: rgba(0, 0, 0, 0.02);
}

.slab-table-wrapper td:nth-child(3), 
.slab-table-wrapper td:nth-child(4) {
    text-align: right;
}

@media (min-width: 992px) {
    .content-column {
        min-width: 0;
    }
}
