/* === БАЗОВЫЕ СТИЛИ (ДЛЯ ВСЕХ СТРАНИЦ) === */

/* 1. Сброс и Переменные */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #09296c;
    --primary-dark: #0a2664;
    --secondary: #06b6d4;
    --accent: #bc0808;
    --dark: #0f172a;
    --gray: #64748b;
    --light: rgb(208, 229, 250);
    --white: #ffffff;
    --gradient: linear-gradient(135deg, #0279e0 0%, #014785 100%);
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1);
    --container-width: 1200px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--dark);
    background: var(--white);
}

/* 2. Глобальные Заголовки */
.page-header-title {
    font-size: 2.3rem;
    font-weight: 700;
    color: #005eb1;
    margin-bottom: 30px;
    text-align: left;
    line-height: 1.2;
}

.section-title {
    text-align: center;
    margin-bottom: 30px;
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--dark);
    line-height: 1.2;
}

.mini-title {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--dark);
    margin-bottom: 16px;
}

/* 3. Контейнер и Секции */
section {
    padding: 30px 20px;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 25px;
}

/* === ШАПКА === */
.site-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.header-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 12px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.logo img {
    height: 50px;
    width: auto;
    max-width: 200px;
    display: block;
}

.main-nav {
    display: flex;
    gap: 28px;
    flex: 1;
    justify-content: center;
}

.main-nav a {
    color: var(--dark);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    position: relative;
    transition: color 0.3s ease;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient);
    transition: width 0.3s ease;
}

.main-nav a:hover {
    color: var(--primary);
}

.main-nav a:hover::after {
    width: 100%;
}

.header-contacts {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.phone-link {
    display: flex;
    align-items: center;
    padding: 8px 16px;
    border: 1.5px solid #005eb1;
    border-radius: 50px;
    background: var(--white);
    color: #005eb1;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    box-shadow: var(--shadow);
    transition: none;
}

.social-vk img {
    width: 45px;
    height: 45px;
}

/* === ГАМБУРГЕР === */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 28px;
    height: 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1002;
    margin-left: 12px;
}

.hamburger span {
    display: block;
    height: 2px;
    width: 100%;
    background-color: #0f172a;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.hamburger.active span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

/* === ОВЕРЛЕЙ (затемнение фона) === */
.menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.menu-overlay.active {
    display: block;
    opacity: 1;
    visibility: visible;
}

/* === МОБИЛЬНОЕ МЕНЮ (выезжает справа) === */
.mobile-menu {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    width: 85%;
    max-width: 320px;
    height: 100vh;
    background: #ffffff;
    flex-direction: column;
    padding: 20px;
    transform: translateX(100%);
    transition: transform 0.3s ease-in-out;
    box-shadow: -4px 0 20px rgba(0,0,0,0.15);
    z-index: 1001;
    overflow-y: auto;
}

.mobile-menu.active {
    display: flex;
    transform: translateX(0);
}

/* Кнопка закрытия */
.mobile-menu-close {
    align-self: flex-end;
    width: 36px;
    height: 36px;
    background: none;
    border: none;
    font-size: 32px;
    cursor: pointer;
    color: var(--dark);
    margin-bottom: 10px;
    line-height: 1;
    padding: 0;
}

/* Навигация внутри мобильного меню */
.mobile-menu-nav {
    display: flex;
    flex-direction: column;
    gap: 0;
    flex-grow: 1;
}

.mobile-menu-nav a {
    font-size: 18px;
    font-weight: 600;
    width: 100%;
    padding: 16px 0;
    border-bottom: 1px solid #f0f2f5;
    color: var(--dark);
    text-decoration: none;
}

.mobile-menu-nav a:hover {
    color: var(--primary);
}

/* Контакты внутри мобильного меню */
.mobile-menu-contacts {
    margin-top: auto;
    padding-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
}

.mobile-phone-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border: 1.5px solid #005eb1;
    border-radius: 50px;
    background: var(--white);
    color: #005eb1;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    box-shadow: var(--shadow);
    width: 100%;
}

.mobile-phone-btn:hover {
    background: #f8f9fa;
}

.mobile-vk-link {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--dark);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    padding: 8px 0;
}

.mobile-vk-link img {
    width: 45px;
    height: 45px;
}

.mobile-vk-link span {
    font-size: 15px;
}

.mobile-vk-link:hover {
    color: var(--primary);
}

/* === ПОДВАЛ === */
.site-footer {
    background: var(--dark);
    color: var(--white);
    padding: 60px 24px 24px;
}

.footer-container {
    max-width: var(--container-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr; 
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-col {
    display: flex;
    flex-direction: column;
}

.footer-logo-text {
    margin-bottom: 20px;
}

.footer-logo-text strong {
    font-size: 1.2rem;
    display: block;
    margin-bottom: 5px;
}

.footer-logo-text p {
    font-size: 0.9rem;
    opacity: 0.6;
    margin: 0;
}

.footer-col h4 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--white);
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 15px;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: var(--white);
}

.footer-address {
    font-size: 14px;
    line-height: 1.6;
    opacity: 0.8;
    margin-bottom: 20px;
}

.footer-address strong {
    display: block;
    margin-bottom: 4px;
    color: var(--white);
}

.footer-phone-email {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-phone,
.footer-email {
    color: var(--white);
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    transition: color 0.2s ease;
}

.footer-phone:hover,
.footer-email:hover {
    color: var(--secondary);
}
.social-vk-footer {
    background: transparent; 
    width: auto;
    height: auto;
    display: inline-flex;
    transition: none;
}

.social-vk-footer:hover {
    background: transparent;
    transform: none;
}

.social-vk-footer img {
    width: 48px;
    height: 48px;
}

.footer-copyright {
    max-width: var(--container-width);
    margin: 0 auto;
    padding-top: 24px;
    text-align: center;
    font-size: 13px;
    opacity: 0.5;
}

/* === АДАПТИВНОСТЬ === */

@media (max-width: 900px) {
    .hamburger { display: flex; }

    .main-nav,
    .header-contacts {
        display: none;
    }

    .menu-overlay,
    .mobile-menu {
        display: block;
    }

    .mobile-menu {
        display: flex;
    }

    .mobile-menu-close {
        width: 48px;
        height: 48px;
        font-size: 42px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .footer-container {
        grid-template-columns: 1fr 1fr;
    }
    .footer-col:first-child {
        grid-column: span 2;
        margin-bottom: 20px;
    }
}

@media (max-width: 600px) {
    .header-container { padding: 12px 16px; gap: 12px; }
    .logo img { height: 40px; }
    section { padding: 30px 16px; }

    .mobile-menu {
        width: 90%;
        padding: 16px;
    }

    .mobile-menu-close {
        width: 44px;
        height: 44px;
        font-size: 38px;
    }

    .mobile-menu-nav a {
        font-size: 16px;
        padding: 14px 0;
    }

    .mobile-vk-link img {
        width: 40px;
        height: 40px;
    }

    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
        align-items: center;
    }
    .footer-col:first-child { grid-column: auto; margin-bottom: 30px; }
}