/* Основной контент */


/* Секция с кнопками +/- */
.transaction-buttons {
    display: flex;
    justify-content: center;
    gap: 80px;
}

.btn-circle {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    border: none;
    font-size: 50px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s;
    text-decoration: none;
}

.btn-circle:hover {
    transform: scale(1.05);
}

.btn-income {
    background-color: #27ae60;
    color: white;
}

.btn-expense {
    background-color: #e74c3c;
    padding-bottom: 8px;
    color: white;
}

/* Секция периода */
.period-section {
    background-color: white;
    border-radius: 15px;
    padding: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.section-title {
    font-size: 20px;
    font-weight: bold;
    text-align: center;
    margin-bottom: 8px;
    color: #2c3e50;
}

.period-buttons {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

/* Активная кнопка периода */

.btn-period.active::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    right: 0;
    height: 3px;
    border-radius: 2px;
    background-color: #2c3e5083;
}

.btn-period {
    position: relative;
    flex: 1;
    min-width: 70px;
    padding: 12px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 8px 8px 0 0;
    font-size: 15px;
    cursor: pointer;
    transition: background-color 0.2s;
    text-align: center;
}

.btn-period:hover {
    background-color: #65afe0;
}

.btn-period.active {
    background-color: white;
    color: #2c3e50;
    border-left: 2px solid #2c3e50d5;
    border-top: 2px solid #2c3e50d3;
    border-right: 2px solid #2c3e50d3;
    font-weight: bold;
}

.stats-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.profit-item {
    padding: 5px;
    border: #27ae60 solid 2px;
    border-radius: 10px;
}

.stat-label {
    font-size: 18px;
    font-weight: bold;
    color: #34495e;
    display: flex;
    justify-content: space-between;
    padding: 0px 6px 0px 5px;
    border-bottom: #bdc3c785 solid 1px;
}

.stat-bar-container {
    height: 30px;
    background-color: #ecf0f1;
    border-radius: 15px;
    overflow: hidden;
}

.stat-bar {
    height: 100%;
    border-radius: 15px;
    transition: width 0.5s ease;
}

.bar-expense {
    min-width: 4%;

}

.bar-income {
    min-width: 4%;
}


.bar-net-profit {
    min-width: 4%;
}
/* Состояние загруки для блока период */
.loading {
    display: inline-block;
}

.error {
    color: red;
    font-size: 0.9em;
}

/* Секция диаграммы */
.chart-section {
    background-color: white;
    border-radius: 15px;
    padding: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

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

.chart-title {
    font-size: 20px;
    margin-bottom: 5px;
    font-weight: bold;
    color: #2c3e50;
    display: flex;
    align-items: center;
}

.month-nav {
    width: 100%;
    display: flex;
    justify-content: space-around;
    gap: 10px;
}



.chart-container {
    display: flex;
    align-items: end;
    height: 200px;
    gap: 15px;
    padding: 10px 0;
    border-top: 2px solid #3498db;

}

.chart-bar {
    flex: 1;
    background-color: #3498db;
    border-radius: 8px 8px 0 0;
    position: relative;
    min-width: 40px;
    min-height: 33%;
}

.chart-bar-label {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 18px;
    white-space: nowrap;
    color: white;
    font-weight: bold;
}

.chart-bar-value {
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 18px;
    font-weight: bold;
    color: white;
}

/* Адаптивность */
@media (max-width: 480px) {
    .btn-circle {
        width: 70px;
        height: 70px;
        font-size: 50px;
    }

    .period-buttons {
        gap: 8px;
    }

    .btn-period {
        padding: 10px;
        font-size: 16px;
        min-width: 60px;
    }

    .stat-bar-container {
        height: 15px;
        border-radius: 8px;
    }

    .stat-label {
        font-size: 16px;
    }


    .chart-bar {
        min-width: 30px;
    }

    .chart-bar-label {
        font-size: 16px;
    }

    .chart-bar-value {
        font-size: 16px;
    }
}

@media (min-width: 768px) {
    .header {
        font-size: 28px;
        padding: 25px;
    }

    .content {
        padding: 30px;
        gap: 40px;
    }

    .btn-circle {
        width: 100px;
        height: 100px;
        font-size: 60px;
    }

    .period-section,
    .chart-section {
        padding: 30px;
    }

    .section-title {
        font-size: 24px;
    }

    .btn-period {
        padding: 15px;
        font-size: 18px;
    }

    .stat-label {
        font-size: 20px;
    }


    .chart-title {
        font-size: 24px;
    }

    .chart-container {
        height: 250px;
    }

    .reg-container {
        margin: 10px;
        padding: 15px;
        min-width: 310px;
    }

    .footer-btn {
        font-size: 18px;
    }

    .footer-icon {
        font-size: 28px;
    }
}