/* Общие стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

/* Шапка сайта */
header {
    background-color: #eaeaea;
    color: #333;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 0 0 20px 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 1;
}

.header-content {
    text-align: center;
    flex-grow: 1;
}

header h1 {
    margin: 0;
    font-size: 2rem;
    font-weight: bold;
    color: #4a69bd; /* Голубой цвет как у h2 */
}

header p {
    margin-top: 10px;
    font-size: 1rem;
    color: #555;
}

/* Основной контент */
.main-content {
    flex: 3;
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    background-color: #fff;
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Заголовки */
.main-content h1,
.main-content h2 {
    font-size: 2rem;
    color: #4a69bd;
    margin-bottom: 20px;
}

/* Параграфы */
.main-content p {
    font-size: 1.4rem;
    line-height: 1.8;
    color: #333;
    margin-bottom: 25px;
}

/* Списки */
.main-content ol,
.main-content ul {
    font-size: 1.4rem;
    margin-bottom: 25px;
    padding-left: 20px;
}

.main-content ol li,
.main-content ul li {
    margin-bottom: 10px;
}

/* Ссылки */
.main-content a {
    color: #4a69bd;
    text-decoration: none;
}

.main-content a:hover {
    text-decoration: underline;
}

/* Контейнер */
.container {
    display: flex;
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
    flex-wrap: wrap;
}

/* Боковая колонка */
.sidebar {
    flex: 1;
    background-color: #eaeaea;
    border: 1px solid #ddd;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.sidebar h3 {
    font-size: 1.2rem;
    color: #4a69bd;
    margin-bottom: 15px;
}
.main-content h4 {
    font-size: 1.19rem;
    color: #4a69bd;
    margin-bottom: 15px;
}
.sidebar p {
    font-size: 1rem;
    color: #555;
    margin-bottom: 15px;
}

/* Адаптивность */
@media (max-width: 768px) {
    .container {
        flex-direction: column;
    }

    .main-content,
    .sidebar {
        flex: 1 1 100%;
    }
}

/* Футер */
footer {
    background-color: #333333;
    color: #fff;
    text-align: center;
    padding: 20px 0;
    margin-top: 20px;
    border-radius: 10px;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
}

.social-icons {
    display: flex;
    gap: 10px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.social-icon {
    text-decoration: none;
    color: #fff;
    font-size: 0.9rem;
    padding: 8px 15px;
    border-radius: 20px;
    transition: background-color 0.3s ease;
}

.social-icon.facebook {
    background-color: #3b5998;
}

.social-icon.facebook:hover {
    background-color: #2d4373;
}

.social-icon.vk {
    background-color: #4c75a3;
}

.social-icon.vk:hover {
    background-color: #3a5f8c;
}

.social-icon.twitter {
    background-color: #1da1f2;
}

.social-icon.twitter:hover {
    background-color: #1a91da;
}

.social-icon.telegram {
    background-color: #0088cc;
}

.social-icon.telegram:hover {
    background-color: #0077b5;
}

/* Рекламный блок */
.ad-block {
    background-color: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 15px;
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.ad-block h3 {
    font-size: 1.5rem;
    color: #4a69bd;
    margin-bottom: 10px;
}

.ad-block p {
    font-size: 1.25rem;
    color: #555;
    margin-bottom: 15px;
}

.ad-block .ad-link {
    display: inline-block;
    padding: 10px 20px;
    background-color: #4a69bd;
    color: #fff;
    text-decoration: none;
    border-radius: 20px;
    transition: background-color 0.3s ease;
}

.ad-block .ad-link:hover {
    background-color: #3b5998;
}

/* Стиль для меню */
#main-nav {
    background-color: #ffffff;
    border-bottom: 1px solid #ddd;
    padding: 10px 20px;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    z-index: 999;
    position: relative;
}

#main-nav a {
    color: #333;
    text-decoration: none;
    font-size: 1.25rem;
    padding: 8px 12px;
    border-radius: 5px;
    transition: all 0.3s ease;
}

#main-nav a:hover {
    background-color: #f0f0f0;
    color: #4a69bd;
}

/* Адаптивное меню */
@media (max-width: 768px) {
    #main-nav {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 80px;
        left: 0;
        width: 100%;
        background-color: #fff;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
        padding: 20px;
        border-top: 1px solid #ddd;
    }

    #main-nav.active {
        display: flex;
    }

    .menu-toggle {
        display: flex;
        flex-direction: column;
        cursor: pointer;
        padding: 10px;
        position: absolute;
        top: 20px;
        right: 20px;
        z-index: 1000;
    }

    .menu-toggle span {
        height: 3px;
        width: 25px;
        background-color: #333;
        margin: 4px 0;
        border-radius: 2px;
        transition: all 0.3s ease;
    }
}

/* === Стили для таблиц === */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    font-size: 16px;
    line-height: 1.5;
    background-color: #fff;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    border-radius: 4px;
}

th,
td {
    padding: 12px 15px;
    text-align: left;
    vertical-align: top;
    border: 1px solid #ccc;
}

th {
    background-color: #f5f5f5;
    font-weight: bold;
    color: #333;
}

/* Чередование строк */
tbody tr:nth-child(even) {
    background-color: #fafafa;
}

/* Адаптация под мобильные устройства */
@media (max-width: 768px) {
    table,
    thead,
    tbody,
    th,
    td,
    tr {
        display: block;
    }

    thead {
        display: none;
    }

    tr {
        margin-bottom: 15px;
        border: 1px solid #ccc;
        border-radius: 4px;
        padding: 10px;
    }

    td {
        position: relative;
        display: block;
        padding-left: 50%;
        border: none;
        border-bottom: 1px solid #eee;
    }

    td::before {
        position: absolute;
        top: 12px;
        left: 15px;
        width: 45%;
        white-space: nowrap;
        font-weight: bold;
        color: #555;
        content: attr(data-label);
    }
}

/* ============================= Контейнер для таблицы === */
.table-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 20px 0;
}

/* === Стили для таблиц === */
.table-container table {
    width: 100%;
    border-collapse: collapse;
    font-size: 16px;
    line-height: 1.5;
    background-color: #fff;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.05);
    min-width: 480px;
}

.table-container th,
.table-container td {
    padding: 12px 15px;
    text-align: left;
    vertical-align: top;
    border: 1px solid #ccc;
    white-space: normal;
    word-wrap: break-word;
}

.table-container th {
    background-color: #f5f5f5;
    font-weight: bold;
    color: #333;
}

/* Чередование строк */
.table-container tbody tr:nth-child(even) {
    background-color: #fafafa;
}

/* === Адаптация под мобильные устройства === */
@media (max-width: 768px) {
    .table-container thead {
        display: none;
    }

    .table-container tbody tr {
        display: block;
        margin-bottom: 15px;
        border: 1px solid #ccc;
        border-radius: 4px;
        padding: 10px;
    }

    .table-container td {
        position: relative;
        display: block;
        padding-left: 50%;
        border: none;
        border-bottom: 1px solid #eee;
    }

    .table-container td::before {
        position: absolute;
        top: 12px;
        left: 15px;
        width: 45%;
        white-space: nowrap;
        font-weight: bold;
        color: #555;
        content: attr(data-label);
    }
}

/* === Стили для видео === */
.video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* Соотношение 16:9 */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    margin: 20px 0;
}

#player {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
}

.play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    padding: 15px 25px;
    font-size: 18px;
    border-radius: 8px;
    cursor: pointer;
    z-index: 10;
    transition: background-color 0.3s ease;
}

.play-button:hover {
    background-color: rgba(0, 0, 0, 0.9);
}