/* Локальный шрифт Inter */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
    src: url('/assets/fonts/inter-variable.woff2') format('woff2');
}

/* Fallback для старых браузеров (если скачали отдельные файлы) */
@supports not (font-variation-settings: normal) {
    @font-face {
        font-family: 'Inter';
        font-style: normal;
        font-weight: 400;
        font-display: swap;
        src: url('/assets/fonts/inter-regular.woff2') format('woff2');
    }
    @font-face {
        font-family: 'Inter';
        font-style: normal;
        font-weight: 500;
        font-display: swap;
        src: url('/assets/fonts/inter-medium.woff2') format('woff2');
    }
    @font-face {
        font-family: 'Inter';
        font-style: normal;
        font-weight: 600;
        font-display: swap;
        src: url('/assets/fonts/inter-semibold.woff2') format('woff2');
    }
    @font-face {
        font-family: 'Inter';
        font-style: normal;
        font-weight: 700;
        font-display: swap;
        src: url('/assets/fonts/inter-bold.woff2') format('woff2');
    }
}
/* ========== ПЕРЕМЕННЫЕ ========== */
:root {
    --deep-blue: #1B3B6A;
    --deep-blue-light: #2a4f85;
    --deep-blue-dark: #122b4d;
    --gold-brown: #9E7B56;
    --gold-brown-light: #b5946e;
    --gold-brown-dark: #7e6043;
    --bg-gradient: linear-gradient(135deg, var(--deep-blue) 0%, var(--deep-blue-dark) 100%);
    --accent-gradient: linear-gradient(135deg, var(--gold-brown) 0%, #b08b64 100%);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Inter', sans-serif;
    background: #f8faff;
    color: #2d3748;
    overflow-x: hidden;
}

/* ========== НАВИГАЦИЯ ========== */

.navbar {
    background: white;
    box-shadow: 0 4px 30px rgba(27, 59, 106, 0.1);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    background: rgba(255,255,255,0.98);
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
}

.logo-img { height: 40px; width: auto; }

.logo-text {
    font-weight: 700;
    font-size: 1.1rem;
    line-height: 1.2;
    color: var(--deep-blue);
}

.logo-text small {
    display: block;
    font-size: 0.7rem;
    color: var(--gold-brown);
    font-weight: 500;
}

/* ========== СТИЛИ ДЛЯ МЕНЮ ========== */
.nav-link {
    font-weight: 500;
    color: var(--deep-blue);
    padding: 0.5rem 1.2rem !important;
    margin: 0 0.2rem;
    border-radius: 50px;
    transition: all 0.3s;
    position: relative;
    text-decoration: none;
    display: inline-block;
}

/* Эффект линии при наведении */
.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, var(--gold-brown), var(--gold-brown-light));
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 30px;
}

.nav-link:hover {
    color: var(--gold-brown);
}

/* Активный пункт меню - как на главной (только жирный и цвет) */
.nav-link.active {
    color: var(--gold-brown);
    font-weight: 600;
}

.nav-link.active::after {
    width: 30px;  /* Показываем линию */
    background: linear-gradient(135deg, var(--gold-brown), var(--gold-brown-light));
}

/* Для мобильного меню */
@media (max-width: 768px) {
    .nav-link {
        padding: 0.5rem 1rem !important;
        font-size: 0.9rem;
    }
    
    .nav-link::after {
        left: 0;
        transform: none;
    }
}

/* ========== КНОПКИ ========== */
.btn-accent {
    background: var(--accent-gradient);
    color: white;
    border: none;
    padding: 0.5rem 1.2rem;
    border-radius: 50px;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(158, 123, 86, 0.3);
    text-decoration: none;
    display: inline-block;
}

.btn-accent:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(158, 123, 86, 0.4);
    color: white;
}

.btn-outline-accent {
    background: transparent;
    color: var(--deep-blue);
    border: 2px solid var(--gold-brown);
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-outline-accent:hover {
    background: var(--gold-brown);
    color: white;
}

/* ========== СОЦИАЛЬНЫЕ СЕТИ ========== */
.social-links {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.social-link {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: all 0.3s;
    text-decoration: none;
    font-size: 1rem;
}

.social-link img {
    width: 16px;
    height: 16px;
    filter: brightness(0) invert(1);
}

.social-link.vk { background: #4a76a8; }
.social-link.telegram { background: #0088cc; }
.social-link.max { background: var(--accent-gradient); }

.social-link:hover {
    transform: translateY(-3px) scale(1.1);
}

/* ========== КАРТОЧКИ ========== */
.section-title {
    color: var(--deep-blue);
    font-weight: 800;
    margin-bottom: 3rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 80px;
    height: 4px;
    background: var(--accent-gradient);
    border-radius: 2px;
}

.tool-card {
    background: white;
    border-radius: 30px;
    padding: 2rem;
    box-shadow: 0 20px 40px rgba(27, 59, 106, 0.08);
    transition: all 0.4s;
    height: 100%;
    text-decoration: none;
    color: inherit;
    display: block;
    border: 1px solid rgba(158, 123, 86, 0.1);
}

.tool-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 30px 60px rgba(27, 59, 106, 0.15);
}

.tool-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, rgba(27, 59, 106, 0.05), rgba(158, 123, 86, 0.05));
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.tool-icon i { font-size: 2.5rem; color: var(--deep-blue); }

.tool-badge {
    display: inline-block;
    padding: 0.3rem 1rem;
    background: #e9ecef;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
}

.tool-badge.ready { background: var(--deep-blue); color: white; }

/* ========== ФУТЕР ========== */
.footer {
    background: var(--deep-blue);
    color: white;
    padding: 4rem 0 2rem;
    margin-top: 5rem;
}

.footer-title {
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--gold-brown-light);
    font-size: 1.1rem;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: all 0.3s;
    font-size: 0.95rem;
}

.footer-links a:hover {
    color: var(--gold-brown-light);
    padding-left: 5px;
}

.footer-divider {
    background: rgba(255,255,255,0.1);
    margin: 2rem 0;
}

/* Виджет ИКС */
.iks-widget {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.1);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.8);
}

.iks-widget i {
    color: #fc3f1d; /* Цвет Яндекса */
}

.iks-widget strong {
    color: white;
}

.footer-stat-badge {
    display: inline-block;
    background: rgba(158, 123, 86, 0.2);
    color: var(--gold-brown-light);
    font-size: 0.75rem;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 8px;
    font-weight: 600;
}

.footer-links a:hover .footer-stat-badge {
    background: var(--gold-brown);
    color: white;
}

/* ========== ПРОЧИЕ КОМПОНЕНТЫ ========== */
.scroll-top {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--deep-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0;
    transition: all 0.3s;
    z-index: 9997;
    border: none;
    box-shadow: 0 5px 20px rgba(27, 59, 106, 0.3);
}

.scroll-top.show { opacity: 1; }
.scroll-top:hover { background: var(--gold-brown); }

.cookie-notice {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    border-radius: 50px;
    padding: 1rem 2rem;
    box-shadow: 0 10px 40px rgba(27, 59, 106, 0.2);
    display: none;
    align-items: center;
    gap: 20px;
    z-index: 9998;
    max-width: 90%;
    border: 1px solid rgba(158, 123, 86, 0.2);
}

.cookie-notice.show { display: flex; }

/* ========== АДАПТИВНОСТЬ ========== */
@media (max-width: 768px) {
    .navbar-brand .logo-text { font-size: 1rem; }
    .tool-card { padding: 1.5rem; }
    .scroll-top { bottom: 20px; right: 20px; }
}

/* Фиксированная навигация */
#mainNav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 30px rgba(27, 59, 106, 0.1);
}

/* Отступ для контента, чтобы не наезжал на меню */
body {
    padding-top: 90px; /* Подбери под высоту меню */
}

/* Если контент все еще наезжает, добавь медиа-запрос для мобильных */
@media (max-width: 768px) {
    body {
        padding-top: 120px; /* На мобильных меню выше */
    }
}

/* Стильные хлебные крошки-лейблы */
.breadcrumb-custom {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    padding: 10px 0;
}

.crumb-label {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    background: rgba(27, 59, 106, 0.05); /* Прозрачный синий */
    color: var(--deep-blue, #1B3B6A);
    border: 1px solid transparent;
}

.crumb-label:hover {
    background: rgba(27, 59, 106, 0.1);
    transform: translateY(-1px);
}

/* Активный элемент (текущая страница) */
.crumb-label.active {
    background: var(--deep-blue, #1B3B6A);
    color: white;
    box-shadow: 0 4px 10px rgba(27, 59, 106, 0.2);
    cursor: default;
}

/* Разделитель между лейблами (опционально, можно убрать для чистоты) */
.crumb-label:not(:last-child)::after {
    content: '/';
    margin-left: 8px;
    opacity: 0.3;
    font-weight: 400;
}
.crumb-label:last-child::after {
    content: '';
}

/* ========== COOKIE УВЕДОМЛЕНИЕ ========== */
.cookie-notice {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    border-radius: 16px; /* Более современные скругления */
    padding: 1.2rem 2rem;
    box-shadow: 0 10px 40px rgba(27, 59, 106, 0.25);
    display: none;
    align-items: center;
    gap: 25px;
    z-index: 9998;
    max-width: 90%;
    border: 1px solid rgba(158, 123, 86, 0.15);
}

.cookie-notice.show {
    display: flex;
}

.cookie-text {
    color: var(--deep-blue);
    font-size: 0.95rem;
    line-height: 1.5;
}

.cookie-text i {
    color: var(--gold-brown);
    margin-right: 10px;
    font-size: 1.1rem;
}

/* Кнопка СОГЛАСЕН */
.cookie-btn {
    background: var(--deep-blue);
    color: white;
    border: none;
    padding: 0.6rem 1.8rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 12px rgba(27, 59, 106, 0.2);
}

.cookie-btn:hover {
    background: var(--gold-brown);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(158, 123, 86, 0.3);
}

/* ========== ИНДИКАТОР ОФЛАЙН-РЕЖИМА ========== */
.offline-indicator {
    position: fixed;
    top: 20px;
    left: 20px;
    background: white;
    border-radius: 12px;
    padding: 8px 15px;
    box-shadow: 0 4px 20px rgba(27, 59, 106, 0.1);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 9996;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    border-left: 4px solid #28a745;
    cursor: help;
}

.offline-indicator i {
    font-size: 1.1rem;
    color: var(--deep-blue);
    transition: color 0.3s;
}

.offline-indicator .indicator-text {
    font-weight: 600;
    color: var(--deep-blue);
}

/* Подсказка */
.indicator-tooltip {
    visibility: hidden;
    opacity: 0;
    width: 300px;
    background-color: var(--deep-blue);
    color: #fff;
    text-align: left;
    border-radius: 8px;
    padding: 12px;
    position: absolute;
    z-index: 10000;
    top: 130%;
    left: 0;
    font-size: 0.8rem;
    line-height: 1.4;
    transition: opacity 0.3s, visibility 0.3s;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    pointer-events: none;
}

/* Стрелочка подсказки */
.indicator-tooltip::after {
    content: "";
    position: absolute;
    bottom: 100%;
    left: 15px;
    margin-left: -5px;
    border-width: 6px;
    border-style: solid;
    border-color: transparent transparent var(--deep-blue) transparent;
}

.offline-indicator:hover .indicator-tooltip {
    visibility: visible;
    opacity: 1;
}

.offline-indicator.offline {
    border-left-color: #dc3545;
}

.offline-indicator.offline i {
    color: #dc3545;
}

@media (max-width: 768px) {
    .offline-indicator {
        top: auto;
        bottom: 10px;
        left: 10px;
        right: 10px;
        max-width: none;
    }
    
    .indicator-tooltip {
        display: none;
    }
    
    .cookie-notice {
        bottom: 20px;
        padding: 1rem;
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
}
.app-labels { display: flex; gap: 5px; margin-top: 5px; }
.app-label { font-size: 0.7rem; padding: 2px 6px; border-radius: 4px; font-weight: 600; }
.label-new { background: #2ecc71; color: white; }
.label-top { background: var(--gold-brown); color: white; }
.label-updated { background: #3498db; color: white; }
.app-version { font-size: 0.75rem; color: #888; margin-top: 3px; }

/* Вместо #header-placeholder * используем конкретные селекторы */
#header-placeholder .nav-link,
#header-placeholder .menu-item,
#header-placeholder a,
#header-placeholder span:not([class*="fa"]) {
    font-family: 'Inter', sans-serif !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
}

/* Принудительно задаем одинаковый цвет для всех состояний ссылок в футере */
#footer-placeholder a,
#footer-placeholder a:visited,
#footer-placeholder a:hover,
#footer-placeholder a:active {
    color: inherit !important; /* Наследуем цвет от родителя */
    transition: color 0.2s ease;
}

#footer-placeholder a:hover {
    color: var(--gold-brown, #9E7B56) !important;
}
