:root {
    --primary: #8B0000;
    --primary-dark: #5A0000;
    --primary-light: #CD5C5C;
    --secondary: #C9A94B;
    --secondary-dark: #A8882E;
    --dark: #1A1A2E;
    --dark-light: #2A2A40;
    --gray-100: #F5F5F5;
    --gray-200: #E8E8E8;
    --gray-300: #D4D4D4;
    --gray-400: #A3A3A3;
    --gray-500: #737373;
    --gray-600: #525252;
    --gray-700: #404040;
    --gray-800: #262626;
    --gray-900: #171717;
    --white: #FFFFFF;
    --black: #000000;
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    
    --transition-fast: 150ms ease;
    --transition-base: 300ms ease;
    --transition-slow: 500ms ease;
    
    --container-width: 1280px;
    --container-padding: 2rem;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: var(--gray-800);
    background-color: var(--gray-100);
}

.site-wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.main {
    flex: 1;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--container-padding);
    width: 100%;
}

/* ===== ТОП-БАР ===== */
.top-bar {
    background: var(--dark);
    color: var(--white);
    padding: 0.75rem 0;
    font-size: 0.875rem;
}

.top-bar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.top-bar__contacts {
    display: flex;
    gap: 1.5rem;
}

.top-bar__contacts a {
    color: var(--white);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: color var(--transition-fast);
}

.top-bar__contacts a:hover {
    color: var(--secondary);
}

.top-bar__social {
    display: flex;
    gap: 1rem;
}

.top-bar__social a {
    color: var(--white);
    font-size: 1.125rem;
    transition: color var(--transition-fast);
}

.top-bar__social a:hover {
    color: var(--secondary);
}

/* ===== ХЕДЕР ===== */
.header {
    background: var(--bg-white);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-sm);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 80px;
}

.header__logo a {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
}

.logo-img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

.logo-text h1 {
    font-family: 'Playfair Display', serif;
    font-size: 1.125rem;
    letter-spacing: 1px;
    color: var(--primary);
    line-height: 1.3;
}

.logo-text p {
    font-size: 0.75rem;
    color: var(--gray-500);
}

/* ===== НАВИГАЦИЯ ===== */
.nav__list {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav__link {
    text-decoration: none;
    color: var(--gray-700);
    font-weight: 500;
    transition: color var(--transition-fast);
    position: relative;
}

.nav__link:hover,
.nav__item.active .nav__link {
    color: var(--primary);
}

.nav__link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width var(--transition-base);
}

.nav__link:hover::after,
.nav__item.active .nav__link::after {
    width: 100%;
}

/* Dropdown */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--bg-white);
    min-width: 240px;
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    padding: 0.5rem 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all var(--transition-base);
    z-index: 100;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    list-style: none;
}

.dropdown-menu a {
    display: block;
    padding: 0.625rem 1.25rem;
    color: var(--gray-700);
    text-decoration: none;
    font-size: 0.875rem;
    transition: all var(--transition-fast);
}

.dropdown-menu a:hover {
    background: var(--gray-100);
    color: var(--primary);
    padding-left: 1.75rem;
}

/* ===== МОБИЛЬНОЕ МЕНЮ ===== */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    width: 30px;
    height: 24px;
    position: relative;
}

.mobile-menu-toggle span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: var(--gray-700);
    border-radius: 3px;
    transition: all var(--transition-fast);
}

.mobile-menu-toggle span:nth-child(1) { top: 0; }
.mobile-menu-toggle span:nth-child(2) { top: 10px; }
.mobile-menu-toggle span:nth-child(3) { top: 20px; }

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg);
    top: 10px;
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg);
    top: 10px;
}

@media (max-width: 992px) {
    .mobile-menu-toggle {
        display: block;
    }
    
    .nav {
        position: fixed;
        top: 0;
        left: -100%;
        width: 80%;
        max-width: 320px;
        height: 100vh;
        background: var(--bg-white);
        box-shadow: var(--shadow-xl);
        transition: left var(--transition-base);
        z-index: 1001;
        overflow-y: auto;
    }
    
    .nav.active {
        left: 0;
    }
    
    .nav__list {
        flex-direction: column;
        gap: 0;
        padding: 1rem;
    }
    
    .nav__item {
        border-bottom: 1px solid var(--gray-200);
    }
    
    .nav__link {
        display: block;
        padding: 1rem;
    }
    
    .dropdown-menu {
        position: static;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none;
        padding-left: 1.5rem;
    }
    
    .dropdown.active .dropdown-menu {
        display: block;
    }
    
    .dropdown > .nav__link .fa-chevron-down {
        float: right;
        transition: transform var(--transition-fast);
    }
    
    .dropdown.active > .nav__link .fa-chevron-down {
        transform: rotate(180deg);
    }
}

/* ===== ФУТЕР ===== */
.footer {
    background: var(--dark);
    color: var(--white);
    padding: 4rem 0 2rem;
    margin-top: auto;
}

.footer__grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer__logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.footer__logo img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: contain;
    box-shadow: 0 0 6px rgba(255,255,255,1);
}

.footer__logo h3 {
    font-family: 'Playfair Display', serif;
    font-size: 0.875rem;
    line-height: 1.3;
}

.footer__col p {
    color: rgba(255,255,255,0.7);
    font-size: 0.875rem;
    line-height: 1.6;
}

.footer__col h4 {
    font-size: 1.125rem;
    margin-bottom: 1.25rem;
    position: relative;
}

.footer__col h4::after {
    content: '';
    position: absolute;
    bottom: -0.5rem;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--secondary);
}

.footer__links,
.footer__contacts {
    list-style: none;
}

.footer__links li,
.footer__contacts li {
    margin-bottom: 0.75rem;
}

.footer__links a,
.footer__contacts a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.footer__links a:hover,
.footer__contacts a:hover {
    color: var(--secondary);
}

.footer__contacts i {
    width: 24px;
    color: var(--secondary);
}

.footer__bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.875rem;
    color: rgba(255,255,255,0.5);
}

@media (max-width: 768px) {
    .footer__grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer__col h4::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .footer__logo {
        justify-content: center;
    }
    
    .footer__contacts li {
        justify-content: center;
    }
}

/* ===== КНОПКИ ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.625rem;
    padding: 0.75rem 1.75rem;
    border-radius: 40px;
    font-weight: 600;
    text-decoration: none;
    transition: all var(--transition-base);
    cursor: pointer;
    border: none;
    font-size: 0.875rem;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--secondary);
    color: var(--dark);
}

.btn-secondary:hover {
    background: var(--secondary-dark);
    color: var(--dark);
}

/* ===== ТЕМНАЯ ТЕМА ===== */
/* Светлая тема (по умолчанию) */
:root {
    --bg-light: #f5f5f5;
    --bg-white: #ffffff;
    --text-dark: #333333;
    --text-light: #666666;
    --card-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

/* Тёмная тема — переопределение переменных */
.dark-theme {
    --bg-light: #1a1a2e;
    --bg-white: #16213e;
    --text-dark: #f0f0f0;
    --text-light: #a0a0a0;
    --card-shadow: 0 2px 8px rgba(0,0,0,0.3);
    --primary: #CD5C5C;
    --primary-dark: #8B0000;
    --primary-light: #E08080;
    --secondary: #D4B85A;
    --secondary-dark: #C9A94B;
    --gray-100: #2a2a40;
    --gray-200: #3a3a50;
    --gray-300: #4a4a60;
    --gray-400: #5a5a70;
    --gray-500: #8a8aa0;
    --gray-600: #aaaac0;
    --gray-700: #cccce0;
    --gray-800: #e0e0e0;
    --gray-900: #f0f0f0;
    --dark: #0d0d1a;
    --dark-light: #1a1a30;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.3), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
}

/* Применяем переменные к body */
body {
    background-color: var(--bg-light);
    color: var(--text-dark);
}

/* Кнопка переключения темы в top-bar */
.theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    color: var(--white);
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    background: rgba(255,255,255,0.2);
    transform: rotate(15deg);
}

.dark-theme .theme-toggle .fa-moon {
    display: none;
}

.dark-theme .theme-toggle .fa-lightbulb {
    display: inline-block !important;
}
/* ===== ВЕРХНЯЯ ПАНЕЛЬ ===== */
.top-bar__right {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ===== ПЕРЕКЛЮЧАТЕЛЬ ЯЗЫКА С ИКОНКОЙ ===== */
.top-bar__lang {
    display: flex;
    gap: 0.1rem;
    align-items: center;
}

.top-bar__lang .lang-icon {
    color: rgba(255, 255, 255, 0.3);
    font-size: 0.8rem;
    margin-right: 0.2rem;
}

.lang-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.15rem 0.4rem;
    text-decoration: none;
    font-size: 0.65rem;
    font-weight: 500;
    text-transform: uppercase;
    transition: all 0.3s ease;
    color: rgba(255, 255, 255, 0.4);
    border-radius: 3px;
    letter-spacing: 0.3px;
}

.lang-link:hover {
    color: rgba(255, 255, 255, 0.8);
}

.lang-link.active {
    color: var(--white);
    background: rgba(255, 255, 255, 0.08);
}

/* Разделитель */
.lang-link:not(:last-child)::after {
    content: '|';
    color: rgba(255, 255, 255, 0.1);
    font-size: 0.5rem;
    padding-left: 0.3rem;
}

.lang-link.active::after {
    display: none;
}

/* ===== ХЛЕБНЫЕ КРОШКИ ===== */
.breadcrumbs {
    padding: 1rem 0;
    background: var(--bg-light);
    font-size: 0.875rem;
}

.breadcrumbs .container {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.3rem;
}

.breadcrumbs a {
    color: var(--text-light);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.breadcrumbs a:hover {
    color: var(--primary);
}

.breadcrumbs .separator {
    color: var(--gray-400);
    margin: 0 0.2rem;
}

.breadcrumbs .current {
    color: var(--text-primary);
    font-weight: 500;
}

/* Тёмная тема */
.dark-theme .breadcrumbs {
    background: var(--bg-light);
}

.dark-theme .breadcrumbs a {
    color: var(--text-light);
}

.dark-theme .breadcrumbs a:hover {
    color: var(--primary);
}

.dark-theme .breadcrumbs .separator {
    color: var(--gray-500);
}

.dark-theme .breadcrumbs .current {
    color: var(--text-primary);
}