footer { 
    background: var(--dark-brown); 
    color: var(--white); 
    padding: 80px 0 30px; 
}

.footer-grid { 
    display: grid; 
    grid-template-columns: 1.5fr 1fr 1fr 1fr; 
    gap: 70px; 
    margin-bottom: 60px; 
}

.foot-col h4 { 
    font-family: var(--serif); 
    font-size: 18px; 
    margin-bottom: 20px; 
    color: var(--gold); 
}

.foot-col p, 
.foot-col a { 
    font-size: 14px; 
    font-weight: 400; 
    opacity: 0.8; 
    line-height: 1.8; 
    display: block; 
    margin-bottom: 10px; 
    transition: var(--transition); 
}

.foot-col a:hover { 
    opacity: 1; 
    color: var(--gold); 
    padding-left: 5px; 
}

.foot-logo { 
    width: 180px; 
    height: auto; 
    max-height: 80px; 
    margin-bottom: 20px; 
    object-fit: contain; 
    filter: brightness(0) saturate(100%) invert(13%) sepia(74%) saturate(5834%) hue-rotate(345deg) brightness(85%) contrast(110%); 
}

.socials { 
    display: flex; 
    gap: 15px; 
    margin-top: 20px; 
}

.socials a { 
    width: 35px; 
    height: 35px; 
    border: 1px solid rgba(255,255,255,0.3); 
    border-radius: 50%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    opacity: 1; 
    margin: 0; 
    padding: 0 !important; 
    transition: var(--transition); 
}

.socials a:hover { 
    background: var(--white); 
    color: var(--dark-brown); 
    border-color: var(--white); 
}

.foot-bottom { 
    border-top: 1px solid rgba(255,255,255,0.1); 
    padding-top: 30px; 
    display: flex; 
    justify-content: space-between; 
    font-size: 13px; 
    font-weight: 500; 
    opacity: 0.6; 
}


/* --- АДАПТИВ ДЛЯ ПОДВАЛА (ПЛАНШЕТЫ И ТЕЛЕФОНЫ) --- */

@media (max-width: 1024px) {
    .footer-grid { 
        grid-template-columns: repeat(2, 1fr); 
    }
}

@media (max-width: 768px) {
    .footer-grid { 
        grid-template-columns: 1fr 1fr; 
        gap: 30px; 
    }
    
    /* Первая и последняя колонки занимают всю ширину */
    .foot-col:nth-child(1), 
    .foot-col:nth-child(4) { 
        grid-column: 1 / -1; 
    }
    
    .foot-bottom { 
        flex-direction: column; 
        align-items: center; 
        gap: 15px; 
        text-align: center; 
    }
}

/* =========================================
   СТИЛИ ДЛЯ МОДАЛЬНОГО ОКНА ГАЛЕРЕИ
   ========================================= */

/* Окно скрыто по умолчанию */
.gallery-modal {
    display: none; /* Скрываем из подвала */
    position: fixed;
    z-index: 99999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9); /* Черный полупрозрачный фон */
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Класс, который добавляет ваш JS-скрипт при клике */
.gallery-modal.show {
    display: flex;
    opacity: 1;
}

/* Сама картинка */
.gallery-modal-content {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    user-select: none;
}

/* Крестик закрытия */
.gallery-modal-close {
    position: absolute;
    top: 30px;
    right: 40px;
    color: #ffffff;
    font-size: 35px;
    cursor: pointer;
    transition: 0.3s;
    z-index: 100000;
}

.gallery-modal-close:hover {
    color: #d4a373; /* Золотой цвет при наведении */
    transform: scale(1.1);
}

/* Кнопки Влево/Вправо */
.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    z-index: 100000;
    backdrop-filter: blur(5px);
}

.gallery-nav:hover {
    background: rgba(255, 255, 255, 0.3);
    color: #d4a373;
}

.gallery-nav.prev {
    left: 30px;
}

.gallery-nav.next {
    right: 30px;
}

/* Адаптив для телефонов */
@media (max-width: 768px) {
    .gallery-nav.prev { left: 10px; }
    .gallery-nav.next { right: 10px; }
    .gallery-modal-close { top: 15px; right: 20px; font-size: 30px; }
    .gallery-modal-content { max-width: 95%; max-height: 80vh; }
}