/* Cash Flow Section Styles */

.cashflow-container {
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.cashflow-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.cashflow-header h2 {
    color: #00CED1;
    font-size: 1.75rem;
    margin: 0;
}

.date-range-selector {
    display: flex;
    gap: 0.5rem;
}

.range-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.875rem;
}

.range-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.range-btn.active {
    background: rgba(0, 206, 209, 0.2);
    border-color: #00CED1;
    color: #00CED1;
}

/* Summary Cards */
.cashflow-summary {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.summary-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
}

.summary-card h4 {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
    font-weight: 500;
    margin: 0 0 0.5rem 0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.summary-value {
    font-size: 2rem;
    font-weight: 600;
    color: white;
}

.summary-card.income .summary-value {
    color: #4ade80;
}

.summary-card.expenses .summary-value {
    color: #f87171;
}

.summary-card.net .summary-value.positive {
    color: #4ade80;
}

.summary-card.net .summary-value.negative {
    color: #f87171;
}

/* Charts */
.cashflow-charts {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.chart-container {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
}

.chart-container h3 {
    color: white;
    font-size: 1rem;
    margin: 0 0 1rem 0;
}

.chart-container canvas {
    max-height: 300px;
}

/* Category Breakdown */
.category-breakdown {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.category-breakdown h3 {
    color: white;
    font-size: 1rem;
    margin: 0 0 1rem 0;
}

.breakdown-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.breakdown-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.breakdown-category {
    min-width: 120px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
}

.breakdown-bar-container {
    flex: 1;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.breakdown-bar {
    height: 100%;
    background: linear-gradient(90deg, #00CED1, #00a8a8);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.breakdown-amount {
    min-width: 100px;
    text-align: right;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

.breakdown-percent {
    min-width: 50px;
    text-align: right;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
}

/* Transactions Section */
.transactions-section {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem;
}

.transactions-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.transactions-header h3 {
    color: white;
    font-size: 1rem;
    margin: 0;
}

.transaction-search {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 0.5rem 1rem;
    color: white;
    width: 250px;
    font-size: 0.875rem;
}

.transaction-search:focus {
    outline: none;
    border-color: #00CED1;
}

.transaction-search::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.transactions-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 400px;
    overflow-y: auto;
}

.transaction-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    transition: background 0.2s ease;
}

.transaction-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.transaction-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.transaction-merchant {
    color: white;
    font-weight: 500;
}

.transaction-category {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
}

.transaction-date {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.75rem;
}

.transaction-amount {
    font-weight: 600;
}

.transaction-amount.income {
    color: #4ade80;
}

.transaction-amount.expense {
    color: #f87171;
}

/* Empty State */
.cashflow-empty {
    text-align: center;
    padding: 4rem 2rem;
}

.cashflow-empty-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.cashflow-empty h3 {
    color: white;
    margin-bottom: 0.5rem;
}

.cashflow-empty p {
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 1.5rem;
}

/* Responsive */
@media (max-width: 1024px) {
    .cashflow-charts {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .cashflow-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }

    .cashflow-summary {
        grid-template-columns: 1fr;
    }

    .transactions-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }

    .transaction-search {
        width: 100%;
    }
}
