/* ========================================
   ЖКС Адмиралтейского района
   Светлая тема | Эффект жидкого стекла
   Цвет акцента: #63a800
   ======================================== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #ffffff;
    color: #1a1a2e;
    line-height: 1.5;
    overflow-x: hidden;
}

/* ===== ОБЩИЙ КОНТЕЙНЕР ===== */
.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    width: 100%;
    box-sizing: border-box;
}

/* ===== ЦВЕТОВАЯ СХЕМА ===== */
:root {
    --primary: #63a800;
    --primary-dark: #4d8600;
    --primary-light: #8bcd2e;
    --primary-glow: rgba(99, 168, 0, 0.2);
    --primary-glow-strong: rgba(99, 168, 0, 0.35);
    --glass-bg: rgba(255, 255, 255, 0.72);
    --glass-bg-strong: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.6);
    --dark: #0f172a;
    --gray-text: #475569;
    --gray-light: #64748b;
}

/* ===== ШАПКА — ПО ЦЕНТРУ ===== */
.glass-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--glass-bg-strong);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    border-radius: 0 0 28px 28px;
    max-width: 1280px;
    width: calc(100% - 48px);
    margin: 0 auto;
    box-sizing: border-box;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 24px;
}

.logo img {
    height: 44px;
    width: auto;
    display: block;
}

/* ===== НАВИГАЦИЯ ===== */
.nav-menu {
    display: flex;
    gap: 6px;
}

.nav-menu a {
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    font-size: 0.85rem;
    padding: 8px 12px;
    border-radius: 40px;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.nav-menu a svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    fill: none;
    stroke-width: 1.8;
    flex-shrink: 0;
}

.nav-menu a:hover {
    background: rgba(99, 168, 0, 0.08);
    color: var(--primary);
}

.nav-menu a.active {
    background: var(--primary);
    color: white;
}

.nav-menu a.active svg {
    stroke: white;
}

/* ===== КОНТАКТНАЯ ПОЛОСА — ПО ЦЕНТРУ ===== */
.contact-bar {
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    padding: 10px 0;
    position: relative;
    z-index: 99;
    max-width: 1280px;
    width: calc(100% - 48px);
    margin: 0 auto;
    border-radius: 0 0 20px 20px;
    box-sizing: border-box;
}

.contact-bar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 0.85rem;
    padding: 0 24px;
}

.contact-hours, .contact-phones, .contact-email {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #94a3b8;
}

.contact-hours svg, .contact-phones svg, .contact-email svg {
    stroke: var(--primary);
}

.contact-hours span {
    color: #cbd5e1;
}

.contact-hours .break {
    color: #fbbf24;
    font-size: 0.75rem;
}

.contact-phones a, .contact-email a {
    color: #cbd5e1;
    text-decoration: none;
    transition: color 0.3s;
}

.contact-phones a:hover, .contact-email a:hover {
    color: var(--primary);
}

.contact-phones .separator {
    color: #475569;
}

/* ===== HERO С КАРТИНКОЙ ===== */
.hero {
    padding: 60px 0 40px;
    background: transparent;
    width: 100%;
}

.hero-glass {
    position: relative;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 32px;
    padding: 80px 60px;
    width: 100%;
    box-sizing: border-box;
    transition: transform 0.2s ease-out;
    overflow: hidden;
}

.hero-glass:hover {
    transform: perspective(1000px) rotateX(2deg) rotateY(2deg);
}

.hero-glass::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.55);
    border-radius: 32px;
    z-index: 0;
}

.hero-text {
    position: relative;
    z-index: 2;
    max-width: 550px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    border-radius: 28px;
    padding: 40px 36px;
    box-sizing: border-box;
}

.hero-text h2 {
    font-size: 2rem;
    margin-bottom: 16px;
    color: var(--dark);
}

.hero-text h2 .accent {
    color: var(--primary);
}

.hero-text p {
    font-size: 1rem;
    margin-bottom: 28px;
    color: var(--gray-text);
}

.hero-buttons {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

/* ===== КНОПКИ ===== */
.btn-primary, .btn-secondary {
    display: inline-block;
    padding: 14px 36px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 15px var(--primary-glow);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px var(--primary-glow-strong);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.9);
    color: var(--dark);
    border: 1px solid #e2e8f0;
}

.btn-secondary:hover {
    background: white;
    border-color: var(--primary);
    transform: translateY(-2px);
}

/* ===== НОВОСТИ ===== */
.news-section {
    padding: 80px 0;
    width: 100%;
}

.section-header {
    text-align: center;
    margin-bottom: 48px;
}

.section-header h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--dark);
}

.section-line {
    width: 70px;
    height: 4px;
    background: var(--primary);
    margin: 16px auto 0;
    border-radius: 4px;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 32px;
    width: 100%;
}

.news-card {
    display: flex;
    flex-direction: column;
    background: white;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    transition: all 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    cursor: pointer;
    height: 100%;
}

.news-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 40px rgba(0, 0, 0, 0.08);
}

.news-image-wrapper {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #f1f5f9;
    flex-shrink: 0;
}

.news-image-card {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.news-card:hover .news-image-card {
    transform: scale(1.05);
}

.news-content {
    padding: 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-date {
    color: var(--primary);
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.news-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--dark);
}

.news-excerpt {
    color: var(--gray-light);
    font-size: 0.9rem;
    line-height: 1.5;
}

/* ===== БЫСТРЫЕ ССЫЛКИ ===== */
.quick-links {
    padding: 0 0 80px;
    width: 100%;
}

.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 28px;
    align-items: stretch;
    width: 100%;
}

.link-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 32px 24px;
    text-align: center;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border-radius: 28px;
    border: 1px solid var(--glass-border);
    transition: all 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.link-card:hover {
    transform: translateY(-6px);
    background: rgba(255, 255, 255, 0.85);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.06), 0 0 0 1px var(--primary-glow);
}

.link-icon {
    margin-bottom: 20px;
}

.link-icon svg {
    width: 44px;
    height: 44px;
    stroke: var(--primary);
    stroke-width: 1.5;
    fill: none;
}

.link-card h3 {
    font-size: 1.2rem;
    margin-bottom: 12px;
    color: var(--dark);
}

.link-card p {
    flex: 1;
    margin-bottom: 24px;
    color: var(--gray-light);
    font-size: 0.95rem;
}

.link-more {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: gap 0.3s ease;
    margin-top: auto;
}

.link-more:hover {
    gap: 12px;
}

/* ===== БАННЕР ГОСТУСЛУГИ ===== */
.banner-section {
    padding: 40px 0 20px;
    width: 100%;
}

.banner-link {
    display: block;
    width: 100%;
    transition: all 0.3s ease;
    border-radius: 24px;
    overflow: hidden;
    background: var(--glass-bg);
    backdrop-filter: blur(8px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.banner-link:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border-color: var(--primary);
}

.banner-img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 24px;
}

/* ===== ПОДВАЛ — ПО ЦЕНТРУ ===== */
.footer {
    background: var(--dark);
    color: #94a3b8;
    padding: 48px 0 32px;
    margin-top: 60px;
    max-width: 1280px;
    width: calc(100% - 48px);
    margin: 60px auto 0;
    border-radius: 28px 28px 0 0;
    box-sizing: border-box;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 32px;
    padding: 0 24px;
}

.footer-info h3 {
    color: white;
    margin-bottom: 12px;
}

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.footer-contact-item svg {
    width: 18px;
    height: 18px;
    stroke: var(--primary);
    flex-shrink: 0;
}

/* ===== МОБИЛЬНАЯ ВЕРСИЯ ===== */
.mobile-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

@media (max-width: 992px) {
    .hero-glass {
        padding: 50px 40px;
    }
    
    .hero-text {
        max-width: 450px;
        padding: 32px 28px;
    }
    
    .hero-text h2 {
        font-size: 1.6rem;
    }
    
    .hero-glass:hover {
        transform: perspective(1000px) rotateX(1deg) rotateY(1deg);
    }
}

@media (max-width: 768px) {
    .glass-header,
    .contact-bar,
    .footer {
        width: calc(100% - 20px);
    }
    
    .glass-header {
        border-radius: 0 0 20px 20px;
    }
    
    .contact-bar {
        border-radius: 0 0 16px 16px;
    }
    
    .footer {
        border-radius: 20px 20px 0 0;
    }
    
    .header-inner {
        padding: 12px 16px;
    }
    
    .contact-bar-inner {
        flex-direction: column;
        align-items: flex-start;
        padding: 8px 16px;
    }
    
    .footer-inner {
        flex-direction: column;
        text-align: center;
        padding: 0 16px;
    }
    
    .mobile-toggle {
        display: block;
    }
    
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 16px;
        gap: 8px;
        border-bottom: 1px solid #e2e8f0;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    }
    
    .nav-menu.active {
        display: flex;
    }
    
    .nav-menu a {
        justify-content: flex-start;
        padding: 12px 16px;
        font-size: 1rem;
        white-space: normal;
    }
    
    .nav-menu a svg {
        width: 20px;
        height: 20px;
    }
    
    .hero {
        padding: 30px 0 20px;
    }
    
    .hero-glass {
        padding: 30px 20px;
    }
    
    .hero-glass:hover {
        transform: none;
    }
    
    .hero-text {
        max-width: 100%;
        padding: 24px 20px;
        text-align: center;
    }
    
    .hero-text h2 {
        font-size: 1.4rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .news-grid {
        grid-template-columns: 1fr;
    }
    
    .links-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .banner-section {
        padding: 20px 0 10px;
    }
}

@media (min-width: 769px) {
    .nav-menu {
        display: flex !important;
    }
}

/* ===== СКРОЛЛБАР ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}
/* ===== ЗЕЛЁНАЯ ОБВОДКА ДЛЯ КАРТОЧЕК ===== */

/* Быстрые ссылки (4 блока на главной) */
.link-card {
    border: 1px solid rgba(99, 168, 0, 0.3);
    transition: all 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.link-card:hover {
    border: 1px solid var(--primary);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.06), 0 0 0 1px var(--primary-glow);
}

/* Карточки новостей */
.news-card {
    border: 1px solid rgba(99, 168, 0, 0.2);
    transition: all 0.4s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

.news-card:hover {
    border: 1px solid var(--primary);
    box-shadow: 0 25px 40px rgba(0, 0, 0, 0.08);
}

/* Баннер Госуслуг */
.banner-link {
    border: 1px solid rgba(99, 168, 0, 0.3);
}

.banner-link:hover {
    border: 1px solid var(--primary);
}

/* Hero-блок — тонкая обводка */
.hero-glass {
    border: 1px solid rgba(99, 168, 0, 0.2);
}

.hero-glass:hover {
    border: 1px solid rgba(99, 168, 0, 0.5);
}
/* ===== FAQ АККОРДЕОН — ИСПРАВЛЕННЫЙ ===== */
.faq-list {
    max-width: 900px;
    margin: 0 auto;
}

.faq-item {
    background: white;
    border-radius: 20px;
    margin-bottom: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    border: 1px solid #e2e8f0;
}

.faq-question {
    padding: 20px 24px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
}

.faq-question:hover {
    background: #f1f5f9;
}

.faq-question::after {
    content: '+';
    font-size: 1.4rem;
    color: var(--primary);
    transition: transform 0.2s ease;
}

.faq-item.open .faq-question::after {
    content: '−';
}

.faq-answer {
    padding: 0 24px;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out;
    color: #475569;
    line-height: 1.6;
}

.faq-item.open .faq-answer {
    padding: 0 24px 24px;
    max-height: 800px;
}

/* Отключаем анимацию для faq-item, чтобы не мешала */
.faq-item {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
}
/* ===== ОТКЛЮЧАЕМ АНИМАЦИЮ ДЛЯ FAQ ===== */
.faq-item,
.faq-question,
.faq-answer {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
    animation: none !important;
}

.faq-item {
    cursor: default;
}

.faq-question {
    cursor: pointer;
}