/* Reset и базовые стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Герой секция */
.hero-section {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

/* Контейнер для фоновых изображений */
.background-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
}

.bg-image.active {
    opacity: 1;
}

/* Контент поверх фона - теперь в левом верхнем углу */
.content {
    position: relative;
    z-index: 10;
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    height: 100vh;
    padding: 30px;
}

/* Стили для логотипа и контактов в левом верхнем углу */
.logo-wrapper {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 15px;
    padding: 20px 25px;
    box-shadow: 
        0 10px 25px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    display: flex;
    align-items: center;
    gap: 25px;
}

/* Эффект свечения по краям */
.logo-wrapper::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(
        45deg,
        rgba(255, 255, 255, 0.3),
        rgba(255, 255, 255, 0.1),
        rgba(255, 255, 255, 0.3)
    );
    border-radius: 17px;
    z-index: -1;
    opacity: 0.7;
    animation: gentleGlow 4s ease-in-out infinite alternate;
}

@keyframes gentleGlow {
    0% {
        opacity: 0.5;
    }
    100% {
        opacity: 0.8;
    }
}

.logo {
    width: 180px;
    height: auto;
    filter: brightness(0) invert(1) drop-shadow(0 2px 8px rgba(255, 255, 255, 0.3));
    opacity: 0.95;
    transition: all 0.3s ease;
}

/* Контейнер для контактов */
.contacts {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* Общие стили для ссылок контактов */
.contact-link {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: white;
    font-size: 1em;
    font-weight: 500;
    padding: 8px 15px;
    border-radius: 8px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    white-space: nowrap;
}

.contact-link:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.contact-icon {
    font-size: 1.2em;
    filter: drop-shadow(0 2px 4px rgba(255, 255, 255, 0.3));
}

.contact-text {
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Специфичные стили для WhatsApp */
.whatsapp-link {
    background: rgba(37, 211, 102, 0.2);
    border: 1px solid rgba(37, 211, 102, 0.3);
}

.whatsapp-link:hover {
    background: rgba(37, 211, 102, 0.3);
}

.whatsapp-link .contact-icon {
    filter: drop-shadow(0 2px 4px rgba(37, 211, 102, 0.4));
}

.logo-wrapper:hover .logo {
    opacity: 1;
    filter: brightness(0) invert(1) drop-shadow(0 4px 15px rgba(255, 255, 255, 0.5));
}

/* Секция с описанием */
.description-section {
    padding: 80px 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.description-container {
    max-width: 1000px;
    margin: 0 auto;
    background: white;
    padding: 60px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.description-container h2 {
    color: #2c5530;
    font-size: 2.4em;
    margin-bottom: 40px;
    text-align: center;
    font-weight: 300;
    line-height: 1.3;
}

.description-container p {
    margin-bottom: 25px;
    font-size: 1.1em;
    color: #555;
    text-align: justify;
    line-height: 1.7;
}

/* Адаптивность */
@media (max-width: 768px) {
    .content {
        padding: 20px;
    }
    
    .logo-wrapper {
        padding: 15px 20px;
        gap: 20px;
    }
    
    .logo {
        width: 140px;
    }
    
    .contact-link {
        font-size: 0.95em;
        padding: 6px 12px;
    }
    
    .contact-icon {
        font-size: 1.1em;
    }
    
    .description-container {
        padding: 40px 30px;
    }
    
    .description-container h2 {
        font-size: 1.8em;
        margin-bottom: 30px;
    }
    
    .description-container p {
        font-size: 1em;
    }
}

@media (max-width: 650px) {
    .logo-wrapper {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .contacts {
        align-items: center;
    }
    
    .contact-link {
        justify-content: center;
        min-width: 200px;
    }
}

@media (max-width: 480px) {
    .content {
        padding: 15px;
    }
    
    .logo-wrapper {
        padding: 12px 15px;
        gap: 12px;
    }
    
    .logo {
        width: 120px;
    }
    
    .contact-link {
        font-size: 0.9em;
        padding: 5px 10px;
        min-width: 180px;
    }
    
    .description-container {
        padding: 30px 20px;
    }
    
    .description-container h2 {
        font-size: 1.6em;
    }
}

/* Поддержка для старых браузеров */
@supports not (backdrop-filter: blur(25px)) {
    .logo-wrapper {
        background: rgba(255, 255, 255, 0.25);
    }
}

/* Стили для блока с картой */
.location-section {
    padding: 60px 20px;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
}

.location-container {
    max-width: 1000px;
    margin: 0 auto;
}

.location-title {
    text-align: center;
    color: #2c5530;
    font-size: 2.2em;
    margin-bottom: 40px;
    font-weight: 300;
}

.map-container {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
    height: 400px;
}

#map {
    width: 100%;
    height: 100%;
    border: none;
}

.location-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.info-card {
    background: white;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    border-left: 4px solid #2c5530;
}

.info-card h3 {
    color: #2c5530;
    margin-bottom: 15px;
    font-size: 1.3em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.info-card p {
    color: #555;
    line-height: 1.6;
    margin: 0;
}

.directions-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #2c5530;
    color: white;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.directions-button:hover {
    background: #1e3a23;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(44, 85, 48, 0.3);
}

/* Адаптивность для карты */
@media (max-width: 768px) {
    .location-section {
        padding: 40px 15px;
    }
    
    .location-title {
        font-size: 1.8em;
        margin-bottom: 30px;
    }
    
    .map-container {
        height: 300px;
        border-radius: 15px;
    }
    
    .location-info {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .info-card {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .map-container {
        height: 250px;
    }
    
    .location-title {
        font-size: 1.6em;
    }
}

/* Стили для галереи */
.gallery-section {
    padding: 80px 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.gallery-container {
    max-width: 1200px;
    margin: 0 auto;
}

.gallery-title {
    text-align: center;
    color: #2c5530;
    font-size: 2.4em;
    margin-bottom: 50px;
    font-weight: 300;
}

/* Сетка галереи */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.gallery-item {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
    aspect-ratio: 4/3;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-image {
    transform: scale(1.05);
}

/* Overlay при наведении */
.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(44, 85, 48, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.zoom-icon {
    color: white;
    font-size: 2em;
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.gallery-item:hover .zoom-icon {
    transform: scale(1);
}

/* Lightbox (модальное окно) */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox.active {
    display: flex;
    opacity: 1;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

.lightbox-image {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Кнопки управления lightbox */
.lightbox-close {
    position: absolute;
    top: -50px;
    right: 0;
    background: none;
    border: none;
    color: white;
    font-size: 2.5em;
    cursor: pointer;
    padding: 5px;
    transition: color 0.3s ease;
}

.lightbox-close:hover {
    color: #2c5530;
}

.lightbox-nav {
    position: absolute;
    top: 50%;
    width: 100%;
    display: flex;
    justify-content: space-between;
    transform: translateY(-50%);
    padding: 0 20px;
}

.lightbox-prev,
.lightbox-next {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 2em;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(44, 85, 48, 0.8);
    transform: scale(1.1);
}

/* Индикатор текущего изображения */
.lightbox-counter {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    color: white;
    font-size: 1.1em;
    background: rgba(255, 255, 255, 0.2);
    padding: 5px 15px;
    border-radius: 20px;
    backdrop-filter: blur(10px);
}

/* Анимация загрузки */
.gallery-item.loading {
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #2c5530;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Адаптивность */
@media (max-width: 768px) {
    .gallery-section {
        padding: 60px 15px;
    }
    
    .gallery-title {
        font-size: 2em;
        margin-bottom: 30px;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 15px;
    }
    
    .lightbox-nav {
        padding: 0 10px;
    }
    
    .lightbox-prev,
    .lightbox-next {
        width: 40px;
        height: 40px;
        font-size: 1.5em;
    }
    
    .lightbox-close {
        top: -40px;
        font-size: 2em;
    }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .gallery-item {
        aspect-ratio: 3/2;
    }
}