/* ===== Общие стили ===== */
body {
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    padding-top: 70px;
    background: #f1f1f1;
    color: #333;
}

h1, h2, h3, h4, h5, h6 {
    margin: 0;
}

/* ===== Верхнее меню ===== */
.top-menu {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #1d3557, #457b9d);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    padding: 0 20px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10000;
}

/* ЛОГО */
.top-menu .logo {
    color: #f1faee;
    font-size: 22px;
    font-weight: bold;
    padding: 16px 0;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
}

/* Список меню */
.top-menu ul {
    list-style: none;
    display: flex;
    flex-direction: row;
    gap: 10px;
    margin: 0;
    padding: 0;
}

.top-menu li {
    display: flex;
}

/* Ссылки */
.top-menu a {
    display: flex;
    align-items: center;
    padding: 14px 20px;
    color: #f1faee;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    position: relative;
    border-radius: 6px;
    transition: 0.25s ease;
}

.top-menu a i {
    margin-right: 8px;
}

/* Hover эффект */
.top-menu a:hover {
    background: rgba(255,255,255,0.15);
    color: #ffd700;
    filter: brightness(1.15);
    transform: translateY(-1px);
}

/* Линия под текстом */
.top-menu a::after {
    content: "";
    position: absolute;
    bottom: 6px;
    left: 50%;
    width: 0;
    height: 2px;
    background: #ffd700;
    transition: width 0.3s ease;
    transform: translateX(-50%);
}

.top-menu a:hover::after {
    width: 50%;
}

/* ===== Кнопка авторизации ===== */
.auth-btn {
    padding: 10px 20px;
    background: #f1faee;
    color: #1d3557;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.25s ease;
    box-shadow: 0 3px 6px rgba(0,0,0,0.2);
}

.auth-btn:hover {
    background: #ffd700;
    color: #1d3557;
    filter: brightness(1.05);
    transform: translateY(-1px);
}

.icon {
    width: 20px;
    height: 20px;
    margin-right: 8px;
    stroke: #f1faee;
}

.auth-btn .icon {
    stroke: #1d3557;
}

/* ===== Кнопка бургера ===== */
.menu-toggle {
    display: none;
    font-size: 28px;
    color: #f1faee;
    cursor: pointer;
}

/* ===== Адаптивность: мобильное меню ===== */
@media (max-width: 890px) {
    body {
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    padding-top: 100px;
    background: #f1f1f1;
    color: #333;
}
    .menu-toggle {
        display: block;
        cursor: pointer;
    }

    .top-menu ul {
        position: absolute;
        top: 60px;
        left: 0;
        right: 0;
        background: #1d3557;
        flex-direction: column;
        overflow: hidden;
        max-height: 0;
        transition: max-height 0.35s ease;
        z-index: 10001;
    }

    .top-menu ul.show {
        max-height: 1000px; /* достаточно для всех пунктов */
    }

    .top-menu li {
        justify-content: center;
    }

    .top-menu a, .auth-btn {
        justify-content: center;
        width: 100%;
        padding: 12px 0;
    }
    .right-banners {
        width: 100%;
        padding: 10px 0;
        border-bottom: 1px solid #e0e0e0;
    }

    .right-banners a img {
        width: 90%;
        max-width: 100%;
        height: auto;
        display: block;
        border-radius: 6px;
    }

}

/* ===== Основная структура ===== */
.container {
    display: flex;
    max-width: auto;
    margin: 20px auto;
    gap: 20px;
    padding: 0 10px;
    box-sizing: border-box;
}

/* ===== Левый сайдбар ===== */
.left-menu {
    width: 220px;
    background: #f8f9fa;
    padding: 15px 20px;
    border-right: 1px solid #e0e0e0;
    flex-shrink: 0;
}

.left-menu h3 {
    margin: 20px 0 10px;
    font-size: 18px;
    color: #1d3557;
    border-left: 4px solid #457b9d;
    padding-left: 10px;
}

.left-menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.left-menu li {
    margin-bottom: 8px;
}

.left-menu a {
    text-decoration: none;
    color: #343a40;
    font-size: 16px;
    padding: 8px 10px;
    display: block;
    border-radius: 4px;
    transition: 0.2s ease;
}

.left-menu a:hover {
    background: #457b9d;
    color: #fff;
}

/* ===== Правый сайдбар ===== */
.right-banners {
    width: 240px;
    padding: 15px 20px;
    flex-shrink: 0;
}

.right-banners a {
    display: block;
    margin-bottom: 15px;
    border-radius: 6px;
    overflow: hidden;
    transition: 0.3s ease;
}

.right-banners a img {
    width: 90%;
    display: block;
    border-radius: 6px;
    transition: 0.3s ease;
}

.right-banners a:hover img {
    transform: scale(1.05);
}

/* ===== Центральный контент ===== */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.content {
    background: #fff;
    padding: 20px;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

/* ===== Слайдер ===== */
.slider-container {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 20px;
}

.slide {
    position: relative;
    width: 100%;
    display: none;
}

.slide img {
    width: 100%;
    border-radius: 8px;
}

.slide-text {
    position: absolute;
    bottom: 15px;
    left: 20px;
    color: #fff;
    background: rgba(0,0,0,0.5);
    padding: 10px 15px;
    border-radius: 4px;
    font-size: 18px;
}

/* ===== Подвал ===== */
.site-footer {
    background: #1d3557;
    color: #f1faee;
    padding: 40px 20px 20px;
    font-size: 14px;
    line-height: 1.6;
    margin-top: 40px;
}

.footer-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    gap: 20px;
}

.footer-container div {
    flex: 1 1 250px;
}

.footer-container h3 {
    color: #a8dadc;
    margin-bottom: 10px;
    font-size: 16px;
}

.footer-container p,
.footer-container li a {
    color: #f1faee;
    text-decoration: none;
    font-size: 14px;
}

.footer-container ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-container ul li {
    margin-bottom: 6px;
}

.footer-container ul li a:hover {
    color: #e63946;
}

.footer-bottom {
    text-align: center;
    padding: 15px 0;
    border-top: 1px solid rgba(255,255,255,0.2);
    margin-top: 20px;
    font-size: 13px;
}

/* ===== Адаптивность ===== */
@media (max-width: 1200px) {
    .container {
        flex-direction: column;
        gap: 15px;
    }
    .left-menu, .right-banners {
        width: 90%;
        border-right: none;
        border-bottom: 1px solid #e0e0e0;
    }
}

@media (max-width: 576px) {
    .top-menu a {
        text-align: center;
        font-size: 16px;
        padding: 12px;
    }
    .slide-text {
        font-size: 16px;
        padding: 8px 10px;
    }
    .footer-container {
        flex-direction: column;
        gap: 15px;
    }
}

/* ===== Новости ===== */
.news-block {
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    margin-bottom: 40px;
}

.news-block h2 {
    color: #1d3557;
    margin-bottom: 20px;
    font-size: 28px;
    border-bottom: 3px solid #ffd700;
    display: inline-block;
    padding-bottom: 5px;
}

.news-item {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    background: #ffffff;
    margin-bottom: 20px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.news-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.15);
}

.news-item img {
    width: 200px;
    height: 140px;
    object-fit: cover;
    flex-shrink: 0;
}

.news-item .news-content {
    padding: 15px 20px;
    flex: 1;
}

.news-item h3 {
    margin: 0 0 10px 0;
    color: #1d3557;
    font-size: 20px;
}

.news-item p {
    margin: 0 0 15px 0;
    color: #333;
    line-height: 1.5;
    font-size: 15px;
}

.news-item .readmore {
    display: inline-block;
    padding: 8px 18px;
    background: #1d3557;
    color: #fff;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.news-item .readmore:hover {
    background: #457b9d;
    color: #ffd700;
}

@media (max-width: 768px) {
    .top-menu ul {
        top:92px;
    }
    .news-item {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .news-item img {
        width: 100%;
        height: auto;
        border-radius: 10px 10px 0 0;
    }

    .news-item .news-content {
        padding: 15px;
    }
}

.full-news img.news-full-img {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 15px 0;
    border-radius: 8px;
}

/* ===== Пагинация ===== */
.pagination {
    margin-top: 20px;
    text-align: center;
}

.pagination a, .pagination span {
    display: inline-block;
    padding: 10px 16px;
    margin: 0 5px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    font-size: 16px;
    transition: all 0.3s ease;
}

.pagination a {
    background: #1d3557;
    color: #fff;
}

.pagination a:hover {
    background: #457b9d;
}

.pagination span.current {
    background: #ffd700;
    color: #1d3557;
    font-weight: bold;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
