/* CSS для страницы истории экологии */

:root {
    --primary-green: #2a5934;
    --secondary-green: #4caf50;
    --light-green: #e8f5e9;
    --accent-green: #81c7b9;
    --dark-green: #1e3c1e;
    --earth-brown: #8d6e63;
    --sky-blue: #87ceeb;
    --text-dark: #2c3e2c;
    --text-light: #5d7a5d;
    --white: #ffffff;
    --gray-bg: #f8fdf8;
    --border-color: #e0f2e0;
    --shadow: 0 4px 20px rgba(42, 89, 52, 0.08);
    --shadow-hover: 0 8px 30px rgba(42, 89, 52, 0.12);
    --transition: all 0.3s ease;
    --radius: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'Roboto', system-ui, sans-serif;
}

body {
    background-color: var(--gray-bg);
    color: var(--text-dark);
    line-height: 1.7;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== НАВИГАЦИЯ ===== */
.navbar {
    background: linear-gradient(135deg, var(--dark-green) 0%, var(--primary-green) 100%);
    color: var(--white);
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(30, 60, 30, 0.25);
    border-bottom: 3px solid var(--accent-green);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px; /* Уменьшен gap для компактности */
    padding: 0 20px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Стили для логотипа - компактная версия */
.logo {
    display: flex;
    align-items: center;
    gap: 12px; /* Уменьшен gap между логотипом и текстом */
    text-decoration: none;
    color: var(--white);
    transition: var(--transition);
    flex-shrink: 0;
    padding: 5px 0;
}

.logo:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.logo-image {
    width: 50px; /* Уменьшен размер логотипа */
    height: 50px;
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.3); /* Тоньше граница */
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--white);
    padding: 3px; /* Уменьшен padding */
}

.logo-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 6px;
}

.logo-text {
    display: flex;
    flex-direction: column;
    gap: 2px; /* Уменьшен gap между строками */
}

.logo-text h2 {
    font-size: 1.2rem; /* Уменьшен шрифт */
    margin-bottom: 0;
    font-weight: 700;
    line-height: 1.1;
}

.logo-text p {
    font-size: 0.75rem; /* Уменьшен шрифт */
    opacity: 0.9;
    line-height: 1.1;
}

/* Меню навигации */
.nav-menu {
    display: flex;
    list-style: none;
    gap: 4px; /* Уменьшен gap между пунктами меню */
    flex-wrap: wrap;
    justify-content: center;
    flex-grow: 1;
    margin: 0;
    padding: 0;
}

.nav-link {
    color: var(--white);
    text-decoration: none;
    font-weight: 500;
    padding: 8px 14px; /* Уменьшен padding */
    border-radius: 30px;
    transition: var(--transition);
    font-size: 0.9rem; /* Уменьшен шрифт */
    display: inline-block;
    position: relative;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.nav-link.active {
    background: rgba(255, 255, 255, 0.2);
    border-bottom: 3px solid var(--accent-green);
    font-weight: 600;
}

.login-btn {
    background: linear-gradient(to right, var(--secondary-green), #3d9440);
    color: white;
    border: none;
    padding: 10px 22px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    font-size: 0.95rem;
    box-shadow: 0 4px 10px rgba(61, 148, 64, 0.3);
    flex-shrink: 0;
}

.login-btn:hover {
    background: linear-gradient(to right, #3d9440, #2e7d32);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(61, 148, 64, 0.4);
}

/* ===== HERO SECTION ===== */
.hero-section {
    background: linear-gradient(rgba(42, 89, 52, 0.88), rgba(42, 89, 52, 0.92)),
                url('https://images.unsplash.com/photo-1500382017468-9049fed747ef?ixlib=rb-4.0.3&auto=format&fit=crop&w=2000&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: var(--white);
    padding: 100px 0;
    text-align: center;
    margin-bottom: 60px;
    border-radius: 0 0 40px 40px;
    box-shadow: 0 10px 30px rgba(42, 89, 52, 0.2);
}

.hero-section h1 {
    font-size: 3.2rem;
    margin-bottom: 20px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    font-weight: 800;
}

.hero-section p {
    font-size: 1.3rem;
    max-width: 800px;
    margin: 0 auto;
    opacity: 0.95;
    font-weight: 300;
}

/* ===== СЕКЦИЯ ЗАГОЛОВКА ===== */
.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: 2.5rem;
    color: var(--dark-green);
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
    padding-bottom: 15px;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(to right, var(--accent-green), var(--secondary-green));
    border-radius: 2px;
}

.section-header p {
    font-size: 1.2rem;
    color: var(--text-light);
    max-width: 700px;
    margin: 0 auto;
}

/* ===== ТАЙМЛАЙН ===== */
.history-section {
    padding: 80px 0;
    background-color: var(--white);
    border-radius: 30px;
    margin: 0 20px 60px;
    box-shadow: var(--shadow);
}

.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(to bottom, var(--secondary-green), var(--accent-green));
    transform: translateX(-50%);
    border-radius: 2px;
}

.timeline-item {
    margin-bottom: 60px;
    position: relative;
    width: 100%;
}

.timeline-dot {
    position: absolute;
    left: 50%;
    top: 20px;
    width: 24px;
    height: 24px;
    background: var(--accent-green);
    border-radius: 50%;
    transform: translateX(-50%);
    z-index: 2;
    box-shadow: 0 0 0 8px rgba(129, 199, 132, 0.3);
    border: 3px solid var(--white);
}

.timeline-content {
    background: var(--white);
    padding: 30px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    position: relative;
    width: calc(50% - 50px);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.timeline-content:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
    border-color: var(--accent-green);
}

.timeline-item:nth-child(odd) .timeline-content {
    margin-left: auto;
    margin-right: 0;
}

.timeline-item:nth-child(even) .timeline-content {
    margin-left: 0;
    margin-right: auto;
}

.timeline-year {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary-green);
    margin-bottom: 10px;
    display: inline-block;
    padding: 5px 15px;
    background-color: var(--light-green);
    border-radius: 20px;
}

.timeline-content h3 {
    color: var(--dark-green);
    margin-bottom: 15px;
    font-size: 1.4rem;
    font-weight: 700;
}

.timeline-text {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-dark);
}

.timeline-text p {
    margin-bottom: 10px;
}

.timeline-text strong {
    color: var(--primary-green);
}

/* ===== РАЗДЕЛЫ ЭКОЛОГИИ ===== */
.branches-section {
    padding: 80px 0;
    background-color: var(--light-green);
    border-radius: 30px;
    margin: 0 20px 60px;
}

.branches-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.branch-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 40px 30px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    border-top: 4px solid var(--secondary-green);
}

.branch-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
}

.branch-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-green), var(--accent-green));
}

.branch-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--secondary-green), var(--accent-green));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
    color: white;
    font-size: 36px;
    box-shadow: 0 8px 20px rgba(79, 157, 105, 0.3);
}

.branch-card h3 {
    color: var(--primary-green);
    margin-bottom: 20px;
    font-size: 1.6rem;
    font-weight: 700;
}

.branch-card p {
    color: var(--text-light);
    line-height: 1.7;
    font-size: 1.05rem;
}
/* ===== ФУТЕР ===== */
.footer {
    background-color: #2c3e50; /* Темный сине-серый цвет */
    color: #ecf0f1; /* Светлый текст */
    padding: 60px 0 30px;
    margin-top: 80px;
    /* Убрано скругление */
    border-radius: 0;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h4 {
    font-size: 1.3rem;
    margin-bottom: 20px;
    color: #3498db; /* Голубой акцентный цвет */
}

.footer-section p {
    margin-bottom: 20px;
    opacity: 0.9;
    line-height: 1.6;
    color: #bdc3c7; /* Светло-серый текст */
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: #ecf0f1;
    font-size: 1.2rem;
    transition: var(--transition);
    text-decoration: none;
}

.social-links a:hover {
    background: #3498db; /* Голубой при наведении */
    transform: translateY(-3px);
    color: white;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #bdc3c7; /* Светло-серый цвет ссылок */
    text-decoration: none;
    transition: var(--transition);
    display: inline-block;
}

.footer-links a:hover {
    color: #3498db; /* Голубой при наведении */
    padding-left: 5px;
}

.contact-info p {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    color: #bdc3c7;
}

.contact-info i {
    color: #3498db; /* Голубой для иконок */
    width: 20px;
}

.copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    opacity: 0.8;
    color: #95a5a6; /* Более темный серый для копирайта */
}

/* ===== АДАПТИВНОСТЬ ===== */
@media (max-width: 992px) {
    /* ... существующие стили ... */
    
    .footer {
        margin-top: 60px;
        /* Убрано скругление */
        border-radius: 0;
    }
}

@media (max-width: 768px) {
    /* ... существующие стили ... */
    
    .footer {
        padding: 40px 0 20px;
        margin-top: 60px;
        /* Убрано скругление */
        border-radius: 0;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media (max-width: 576px) {
    /* ... существующие стили ... */
    
    .footer {
        padding: 30px 0 15px;
        margin-top: 40px;
        /* Убрано скругление */
        border-radius: 0;
    }
    
    .footer-section h4 {
        font-size: 1.1rem;
    }
    
    .copyright {
        padding-top: 20px;
        font-size: 0.8rem;
    }
}

/* ===== АДАПТИВНОСТЬ ===== */
@media (max-width: 992px) {
    .nav-container {
        flex-wrap: wrap;
        justify-content: space-between;
        gap: 15px;
        padding: 0 15px;
    }
    
    .nav-menu {
        order: 3;
        width: 100%;
        margin-top: 15px;
        justify-content: center;
        gap: 8px;
    }
    
    .logo {
        gap: 10px;
    }
    
    .logo-image {
        width: 45px;
        height: 45px;
    }
    
    .logo-text h2 {
        font-size: 1.1rem;
    }
    
    .logo-text p {
        font-size: 0.7rem;
    }
    
    .hero-section h1 {
        font-size: 2.5rem;
    }
    
    .timeline-content {
        width: calc(100% - 60px);
        margin: 0 auto 60px !important;
    }
    
    .timeline::before {
        left: 30px;
    }
    
    .timeline-dot {
        left: 30px;
    }
}

@media (max-width: 768px) {
    .hero-section {
        padding: 70px 0;
    }
    
    .hero-section h1 {
        font-size: 2.2rem;
    }
    
    .section-header h2 {
        font-size: 2rem;
    }
    
    .branches-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .nav-menu {
        gap: 6px;
    }
    
    .nav-link {
        padding: 7px 12px;
        font-size: 0.85rem;
    }
    
    .login-btn {
        padding: 7px 15px;
        font-size: 0.85rem;
    }
}

@media (max-width: 576px) {
    .logo {
        flex-direction: row; /* Оставляем логотип и текст в строку */
        gap: 8px;
    }
    
    .logo-image {
        width: 40px;
        height: 40px;
    }
    
    .logo-text h2 {
        font-size: 1rem;
    }
    
    .logo-text p {
        font-size: 0.65rem;
    }
    
    .nav-container {
        padding: 0 10px;
        gap: 10px;
    }
    
    .nav-link {
        padding: 6px 10px;
        font-size: 0.8rem;
    }
    
    .timeline-content {
        padding: 20px;
    }
}

/* Специальные стили для очень маленьких экранов */
@media (max-width: 480px) {
    .logo-text p {
        display: none; /* Скрываем подзаголовок на очень маленьких экранах */
    }
    
    .logo-text h2 {
        font-size: 0.9rem;
    }
    
    .nav-menu {
        gap: 4px;
    }
    
    .nav-link {
        padding: 5px 8px;
        font-size: 0.75rem;
    }
    
    .login-btn span {
        display: none; /* Скрываем текст в кнопке входа */
    }
    
    .login-btn {
        padding: 8px 10px;
    }
}