/* Общие стили */
body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #FBF9F6;
    background-image: url('bg.png');
    background-size: cover;
    background-attachment: fixed;
    background-position: center;
    color: #2C2C2C;
    font-size: 16px;
    line-height: 1.6;
}

/* Шапка */
header {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background-color: transparent; /* Фон прозрачный, чтобы видеть bg.png */
    border-bottom: none;
}

.logo-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.logo {
    height: 300px;
    width: auto;
}

nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

nav a {
    text-decoration: none;
    color: #2C2C2C;
    font-weight: 500;
    padding: 10px 20px;
    border: 2px solid #2E4E34;
    border-radius: 8px;
    background-color: #FBF9F6;
    transition: all 0.2s ease;
}

nav a:hover {
    background-color: #7C9070;
    color: #FBF9F6;
    border-color: #7C9070;
}

nav a:active {
    transform: scale(0.95);
}

/* Основной контент */
main {
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

h1, h2 {
    color: #2E4E34;
    margin-top: 0;
}

.hero {
    text-align: center;
    padding: 60px 20px;
    background-color: rgba(251, 249, 246, 0.7);
    border-radius: 8px;
}

/* Футер */
footer {
    text-align: center;
    padding: 30px 20px;
    margin-top: 40px;
}

.footer-line {
    border: 0;
    border-top: 3px solid #2E4E34;
    margin-bottom: 15px;
}

/* Стили для новостей */
.news-section {
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.news-header {
    text-align: center;
    margin-bottom: 30px;
}

.news-header h1 {
    color: #2E4E34;
    font-size: 28px;
    margin-bottom: 10px;
}

.news-header p {
    color: #7C9070;
    font-style: italic;
    font-size: 16px;
}

/* Блок новости */
.news-block {
    background-color: #FBF9F6;
    border: 2px solid #2E4E34;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.news-block:hover {
    border-color: #7C9070;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.news-title {
    color: #2E4E34;
    font-size: 20px;
    margin-bottom: 15px;
    line-height: 1.3;
}

.news-title a {
    text-decoration: none;
    color: #2E4E34;
}

.news-title a:hover {
    color: #7C9070;
    text-decoration: underline;
}

.news-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.news-date {
    color: #7C9070;
    font-size: 14px;
}

.news-content {
    color: #2C2C2C;
    line-height: 1.8;
    margin-bottom: 20px;
}

.news-content p {
    margin-bottom: 15px;
}

.news-content strong {
    color: #2E4E34;
}

.news-content u {
    text-decoration: underline;
}

.news-content em {
    font-style: italic;
}

.news-links {
    margin-bottom: 15px;
}

.news-links a {
    color: #7C9070;
    text-decoration: none;
    background-color: rgba(124, 144, 112, 0.1);
    padding: 8px 15px;
    border-radius: 4px;
    display: inline-block;
    margin-right: 10px;
}

.news-links a:hover {
    background-color: rgba(124, 144, 112, 0.3);
}

/* Таблицы */
.news-table {
    border-collapse: collapse;
    width: 100%;
    margin-bottom: 20px;
}

.news-table th, .news-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.news-table th {
    background-color: #FBF9F6;
    color: #2E4E34;
    font-weight: bold;
}

.news-table tr:hover td {
    background-color: rgba(124, 144, 112, 0.05);
}

/* Список */
.news-list {
    list-style-type: disc;
    padding-left: 20px;
    margin-bottom: 15px;
}

.news-list li {
    margin-bottom: 8px;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .news-block {
        padding: 20px;
    }

    .news-title {
        font-size: 18px;
    }

    .news-meta {
        flex-direction: column;
        gap: 5px;
    }

    .news-links a {
        display: block;
        margin-right: 0;
        margin-bottom: 5px;
    }
}

@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    nav ul {
        flex-direction: column;
        gap: 30px;
    }
}

/* Стили пагинации */
.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 40px;
    padding: 20px 0;
    border-top: 1px solid #e0e0e0;
}

.pagination-btn {
    padding: 10px 25px;
    border: 2px solid #2E4E34;
    border-radius: 8px;
    background-color: #FBF9F6;
    color: #2E4E34;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pagination-btn:hover:not(:disabled) {
    background-color: #7C9070;
    border-color: #7C9070;
    color: #FBF9F6;
}

.pagination-btn:disabled {
    border-color: #ccc;
    color: #ccc;
    cursor: not-allowed;
    background-color: #eee;
}

#pageInfo {
    font-weight: bold;
    color: #2C2C2C;
}

@media (max-width: 768px) {
    .pagination-container {
        flex-direction: column;
        gap: 15px;
    }
}

.hidden {
    display: none !important;
}
