body {
    font-family: Arial, sans-serif;
    background-color: #f3f4f6;
    margin: 0;
    padding: 0;
    overflow-x: hidden; /* Скрываем горизонтальную прокрутку */
}
.article-container {
    position: relative;
}
section.article {
    background-color: #f8f9fa;
    padding: 20px;
    margin-top: 20px;
}
h1 {
    font-size: 1.5em;
    margin-bottom: 10px;
}

.intro {
    font-size: 1.1em;
    line-height: 1.6;
    color: #333;
}

.full-article {
    display: none; /* Скрываем полную статью по умолчанию */
    margin-top: 20px;
    font-size: 1em;
    line-height: 1.6;
    color: #555;
}

.toggle-button {
    background:none;
    color: #09a5f4;
    border: none;
    font-size: 1em;
    cursor: pointer;
    border-bottom: 1px dashed;
}


.dashboard, .header-container {
    overflow-x: hidden; /* Также скрываем переполнение на этих контейнерах */
}

#availabilityChart {
    margin-left: auto;
    margin-right: auto;
}

.chart-container {
    width: 100%;
    height: 300px;
    position: relative;
    padding: 20px 10px 0;
    box-sizing: border-box;
}

.chart-container canvas {
    width: 100% !important;
    height: 100% !important;
    display: block;
}

.dashboard {
    max-width: 1200px;
    margin: 20px auto;
    background-color: #fff;
    padding: 20px;
    box-sizing: border-box;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #fff;
    padding: 10px 20px;
    max-width: 1200px;
    margin: 0px auto 20px;
    box-sizing: border-box;
}

.header-left .description {
    margin: 0;
    font-size: 0.8em;
    color: #000;
    font-weight:600;
}

.logo {
    font-size: 3em;
    font-weight: 600;
}

.header-left .description span {
    display: block;
    font-size: 12px;
}

.header-left {
    margin-left: 10px;
}

.header-right {
    width: 275px;
}

.header-right .add-site-btn {
    background-color: #2196F3;
    color: white;
    padding: 15px 20px;
    font-size: 1em;
    border: none;
    border-radius: 0px;
    cursor: pointer;
    text-decoration: none;
    display: block;
    text-align: center;
}

.logo span {
    color: #ff0000;
}

.header-right .add-site-btn:hover {
    opacity: 0.8;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    gap: 20px;
}

.status-block {
    padding: 15px;
    color: white;
    text-align: center;
    flex: 1;
    font-weight: 600;
}

.status-block span {
    font-size: 0.9em;
    font-weight: 400;
}

section.sales-report {
    padding-left: 0;
}

.status-1 {
    background: linear-gradient(45deg, #FF6B6B, #FF8E53);
}

.status-2 {
    background: linear-gradient(45deg, #4CAF50, #8BC34A);
}

.status-3 {
    background: linear-gradient(45deg, #2196F3, #03A9F4);
}

.status-4 {
    background: linear-gradient(45deg, #FFEB3B, #FF9800);
}

.dashboard-content {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.sales-report, .total-year-views, .inventory-summary, .lead-summary {
    background-color: #f8f9fa;
    padding: 20px;
}

h2 {
    font-size: 1.2em;
    margin-bottom: 15px;
    color: #333;
    text-align: center;
}

canvas {
    max-width: 100%;
    height: 200px;
}

.inventory-details {
    display: flex;
    justify-content: space-between;
    padding: 20px 0;
}

.inventory-item {
    font-size: 1em;
    color: #555;
}

.total-inventory {
    text-align: center;
    font-size: 2em;
    font-weight: bold;
    color: #333;
}

.summary-item {
    font-size: 1.2em;
    margin-bottom: 10px;
}

.square {
    width: 150px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 16px;
    text-align: center;
    gap: 5px;
}

.green {
    background: linear-gradient(45deg, #4CAF50, #8BC34A);
}

.blue {
    background: linear-gradient(45deg, #2196F3, #03A9F4);
}

.red {
    background: linear-gradient(45deg, #FF6B6B, #FF8E53);
}

.domain-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    padding: 20px;
}

.domain-item {
    font-size: 18px;
    font-weight: bold;
    transition: transform 0.2s;
}

.domain-item:hover {
    transform: translateX(10px);
}

.masked-domain {
    display: inline-block;
    position: relative;
}

.masked-domain::after {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, rgba(248, 249, 250, 0) 0%, rgba(248, 249, 250, 1) 100%);
}

.footer-container {
    width: 100%;
    background-color: #333;
    color: white;
    padding: 10px 0;
    position: relative;
    bottom: 0;
    text-align: center;
}

.footer p {
    margin: 0;
    font-size: 14px;
}

/* Адаптивные стили */
@media (max-width: 768px) {
    .header-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .header-left {
        margin-left: 0;
        margin-bottom: 10px;
    }

    .header-right {
        width: 100%;
    }

    .header-right .add-site-btn {
        padding: 10px;
    }

    .dashboard-header {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .status-block {
        margin-bottom: 0px;
    }
    
    .status-block span {
        font-size: 0.9em;
        font-weight: 400;
        display: block;
    }

    .dashboard-content {
        grid-template-columns: 1fr;
    }

    .inventory-details {
        flex-direction: column;
        gap: 10px;
        display:grid;
        grid-template-columns: repeat(3, 1fr);
    }

    .square {
        width: 100%;
        height: 70px;
        flex-direction: column;
    }

    .domain-grid {
      
    }

    .chart-container {
        height: 200px;
    }

    #availabilityPieChart {
        width: 100% !important;
        height: auto !important;
    }
}

@media (max-width: 480px) {
    .logo {
        font-size: 2em;
    }

    .header-left h1 {
        font-size: 0.7em;
    }

    .status-block {
        font-size: 0.9em;
    }

    h2 {
        font-size: 1em;
    }

    .domain-item {
        font-size: 16px;
    }
}