* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.hero {
    height: 100vh;
    background: 
        /* Звёзды разной яркости */
        radial-gradient(1px 1px at 20% 30%, rgba(255,255,255,0.7), rgba(0,0,0,0)),
        radial-gradient(2px 2px at 40% 70%, rgba(255,255,255,0.5), rgba(0,0,0,0)),
        radial-gradient(1px 1px at 60% 20%, rgba(255,255,255,0.6), rgba(0,0,0,0)),
        radial-gradient(2px 2px at 80% 40%, rgba(255,255,255,0.4), rgba(0,0,0,0)),
        /* Тёмный космический фон */
        linear-gradient(
            135deg,
            #000000 0%,
            #0a0a12 25%,
            #111 50%,
            #0a0a12 75%,
            #000000 100%
        );
    background-size: 
        200px 200px,
        250px 250px,
        170px 170px,
        220px 220px,
        100% 100%;
    background-repeat: repeat, repeat, repeat, repeat, no-repeat;
    position: relative;
    overflow: hidden;
    animation: shimmer 60s linear infinite;
}

.poet-image {
    position: absolute;
    bottom: -7%;
    left: 5%;
    width: auto;
    height: 55vh;
    filter: drop-shadow(0 0 20px rgba(255,255,255,0.1));
}

.menu {
    position: fixed;
    width: 100%;
    height: 100vh;
    pointer-events: none;
}

.menu ul {
    list-style: none;
    height: 100%;
    position: relative;
}

.menu li {
    position: absolute;
    transform-origin: center;
}

/* Обновляем позиции пунктов меню, теперь правее */
.menu li:nth-child(1) { /* Книги */
    top: 10%;
    right: 40%;
    transform: rotate(8deg);
}

.menu li:nth-child(2) { /* Публикации */
    top: 45%; /* Было 35%, делаем ещё ниже */
    right: 30%;
    transform: rotate(10deg);
}

.menu li:nth-child(3) { /* Интервью */
    top: 60%; /* Подстраиваем под новую позицию Публикаций */
    right: 20%;
    transform: rotate(-5deg);
}

.menu li:nth-child(4) { /* Аудио */
    top: 75%; /* Подстраиваем под новую позицию */
    right: 25%;
    transform: rotate(8deg);
}

.menu li:nth-child(5) { /* Видео */
    top: 85%;
    right: 15%;
    transform: rotate(-12deg);
}

.menu li:nth-child(6) { /* Википедия */
    top: 15%;
    right: 25%;
    transform: rotate(-15deg);
}

.menu li:nth-child(7) { /* Фото */
    top: 30%;
    right: 35%;
    transform: rotate(10deg);
}

.menu a {
    pointer-events: auto;
    font-family: 'Cormorant Garamond', serif;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 1.5rem;
    letter-spacing: 2px;
    padding: 1rem 2rem;
    position: relative;
    transition: all 0.5s ease;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

.menu a::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transform: scaleX(0);
    transition: transform 0.5s ease;
}

.menu a:hover {
    color: white;
    text-shadow: 
        0 0 5px rgba(255, 255, 255, 0.5),
        0 0 15px rgba(255, 255, 255, 0.3),
        0 0 25px rgba(255, 255, 255, 0.2);
    letter-spacing: 5px;
}

.menu a:hover::before {
    transform: scaleX(1);
}

/* Стиль для звездочек - бежевый/золотистый цвет как на books */
.menu a,
.mobile-menu a,
.books-menu a {
    position: relative;
}

/* Окрашиваем символы ✦ и ✓ в бежевый цвет */
.menu a:contains('✦'),
.mobile-menu a:contains('✦'),
.books-menu a:contains('✓') {
    /* Для текста со звездочками/галочками */
}

/* Альтернативный подход через span */
.menu .check-symbol,
.mobile-menu .check-symbol,
.books-menu .check-symbol {
    color: #f5deb3; /* Бежевый/пшеничный цвет */
    opacity: 0.9;
    margin-left: 0.3rem;
}

/* Добавляем уникальные эффекты появления */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.menu li {
    opacity: 0;
    animation: fadeIn 0.8s ease forwards;
}

.menu li:nth-child(1) { animation-delay: 0.2s; }
.menu li:nth-child(2) { animation-delay: 0.4s; }
.menu li:nth-child(3) { animation-delay: 0.6s; }
.menu li:nth-child(4) { animation-delay: 0.8s; }
.menu li:nth-child(5) { animation-delay: 1.0s; }
.menu li:nth-child(6) { animation-delay: 1.2s; }
.menu li:nth-child(7) { animation-delay: 1.4s; }

@keyframes shimmer {
    0% {
        background-position: 
            0 0,
            0 0,
            0 0,
            0 0,
            0 0;
    }
    100% {
        background-position: 
            200px 200px,
            250px 250px,
            170px 170px,
            220px 220px,
            0 0;
    }
} 

/* Стили для фото на странице книг */
.books-image {
    height: 45vh;
    bottom: 0;
}

/* Меню книг */
.books-menu {
    position: fixed;
    width: 100%;
    height: 100vh;
    pointer-events: none;
}

.books-menu ul {
    list-style: none;
    height: 100%;
    position: relative;
}

.books-menu li {
    position: absolute;
    transform-origin: center;
    opacity: 0;
    animation: fadeIn 0.8s ease forwards;
}

/* Располагаем пункты меню книг правее */
.books-menu li:nth-child(1) {
    top: 12%;
    right: 15%;
    transform: rotate(-8deg);
}

.books-menu li:nth-child(2) {
    top: 28%;
    right: 45%;
    transform: rotate(12deg);
}

.books-menu li:nth-child(3) {
    top: 20%;
    right: 75%;
    transform: rotate(-5deg);
}

.books-menu li:nth-child(4) {
    top: 45%;
    right: 25%;
    transform: rotate(15deg);
}

.books-menu li:nth-child(5) {
    top: 65%;
    right: 55%;
    transform: rotate(-10deg);
}

.books-menu li:nth-child(6) {
    top: 80%;
    right: 30%;
    transform: rotate(8deg);
}

.books-menu li:nth-child(7) {
    top: 90%;
    right: 65%;
    transform: rotate(-12deg);
}

.books-menu a {
    pointer-events: auto;
    font-family: 'Cormorant Garamond', serif;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 1.2rem;
    letter-spacing: 3px;
    padding: 0.8rem 1.5rem;
    position: relative;
    transition: all 0.5s ease;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

.books-menu a:hover {
    color: white;
    transform: scale(1.1);
    letter-spacing: 6px;
    text-shadow: 
        0 0 10px rgba(255, 255, 255, 0.6),
        0 0 20px rgba(255, 255, 255, 0.4),
        0 0 30px rgba(255, 255, 255, 0.2);
}

.books-menu a::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transform: scaleX(0);
    transition: transform 0.5s ease;
}

.books-menu a:hover::before {
    transform: scaleX(1);
}

/* Кнопка возврата на главную */
.back-home {
    position: fixed;
    top: 2rem;
    right: 2rem;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 1.2rem;
    padding: 0.5rem 1rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 3px;
    transition: all 0.3s ease;
    margin-left: 1rem;
}

.back-home:hover {
    color: white;
    border-color: rgba(255, 255, 255, 0.8);
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Анимация появления пунктов меню */
.books-menu li:nth-child(1) { animation-delay: 0.2s; }
.books-menu li:nth-child(2) { animation-delay: 0.4s; }
.books-menu li:nth-child(3) { animation-delay: 0.6s; }
.books-menu li:nth-child(4) { animation-delay: 0.8s; }
.books-menu li:nth-child(5) { animation-delay: 1.0s; }
.books-menu li:nth-child(6) { animation-delay: 1.2s; }
.books-menu li:nth-child(7) { animation-delay: 1.4s; } 

/* Стили для страницы писем */
.letters-image {
    height: 50vh;
    bottom: 0;
    left: auto;
    right: 5%;
    filter: brightness(0.9) contrast(1.1);
}

.letters-menu {
    position: fixed;
    width: 100%;
    height: 100vh;
    pointer-events: none;
}

.letters-menu ul {
    list-style: none;
    height: 100%;
    position: relative;
}

.letters-menu li {
    position: absolute;
    transform-origin: center;
    opacity: 0;
    animation: fadeIn 0.8s ease forwards;
}

.letters-menu a {
    pointer-events: auto;
    font-family: 'Cormorant Garamond', serif;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 1.2rem;
    letter-spacing: 3px;
    padding: 0.8rem 1.5rem;
    position: relative;
    transition: all 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
    display: inline-block;
}

.letters-menu a:hover {
    color: white;
    transform: scale(1.01) translateY(-2px);
    letter-spacing: 4px;
    text-shadow: 
        0 0 10px rgba(255, 255, 255, 0.4),
        0 0 20px rgba(255, 255, 255, 0.2);
    transition: all 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.letters-menu a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent,
        rgba(255, 255, 255, 0.5),
        transparent
    );
    transform: scaleX(0);
    transition: transform 1s ease;
}

.letters-menu a:hover::before {
    transform: scaleX(1);
}

/* Модальное окно */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: transparent;
    pointer-events: none;
}

.modal-content {
    position: relative;
    margin: 5% auto;
    padding: 2rem;
    width: 80%;
    max-width: 800px;
    background: none;
    box-shadow: none;
    backdrop-filter: none;
    color: white;
    animation: modalFade 0.8s ease-out;
    pointer-events: auto;
    border-radius: 10px;
    z-index: 1150;
}

.close {
    position: fixed;
    right: 2rem;
    top: 2rem;
    color: rgba(255,255,255,0.7);
    font-size: 3rem;
    cursor: pointer;
    z-index: 1200;
    opacity: 0.7;
    transition: all 0.3s ease;
    text-shadow: 0 0 10px rgba(255,255,255,0.3);
}

.close:hover {
    color: white;
    opacity: 1;
    transform: scale(1.1);
    text-shadow: 0 0 15px rgba(255,255,255,0.5);
}

/* Позиционирование писем */
.letters-menu li:nth-child(1) {
    top: 10%;
    right: 45%;
    transform: rotate(-8deg);
}

.letters-menu li:nth-child(2) {
    top: 25%;
    right: 55%;
    transform: rotate(12deg);
}

.letters-menu li:nth-child(3) {
    top: 15%;
    right: 65%;
    transform: rotate(-5deg);
}

.letters-menu li:nth-child(4) {
    top: 35%;
    right: 50%;
    transform: rotate(10deg);
}

.letters-menu li:nth-child(5) {
    top: 45%;
    right: 60%;
    transform: rotate(-12deg);
}

.letters-menu li:nth-child(6) {
    top: 55%;
    right: 45%;
    transform: rotate(8deg);
}

.letters-menu li:nth-child(7) {
    top: 65%;
    right: 55%;
    transform: rotate(-10deg);
}

.letters-menu li:nth-child(8) {
    top: 75%;
    right: 50%;
    transform: rotate(15deg);
}

.letters-menu li:nth-child(9) {
    top: 85%;
    right: 65%;
    transform: rotate(-8deg);
}

.letters-menu li:nth-child(10) {
    top: 70%;
    right: 45%;
    transform: rotate(10deg);
}

/* Анимация появления для писем */
.letters-menu li:nth-child(1) { animation-delay: 0.1s; }
.letters-menu li:nth-child(2) { animation-delay: 0.2s; }
.letters-menu li:nth-child(3) { animation-delay: 0.3s; }
.letters-menu li:nth-child(4) { animation-delay: 0.4s; }
.letters-menu li:nth-child(5) { animation-delay: 0.5s; }
.letters-menu li:nth-child(6) { animation-delay: 0.6s; }
.letters-menu li:nth-child(7) { animation-delay: 0.7s; }
.letters-menu li:nth-child(8) { animation-delay: 0.8s; }
.letters-menu li:nth-child(9) { animation-delay: 0.9s; }
.letters-menu li:nth-child(10) { animation-delay: 1.0s; } 

.poem {
    font-family: 'Cormorant Garamond', serif;
    color: rgba(255, 255, 255, 0.9);
    text-align: left;
    padding: 2rem 3rem;
    line-height: 1.8;
    font-size: 1.4rem;
    letter-spacing: 1px;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
}

.poem p:first-child {
    font-size: 1.8rem;
    margin-bottom: 2rem;
    letter-spacing: 3px;
    color: white;
    text-shadow: 
        0 0 10px rgba(255, 255, 255, 0.6),
        0 0 20px rgba(255, 255, 255, 0.4);
}

@keyframes modalFade {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
} 

/* Анимация для строк стихотворения */
.poem p {
    opacity: 0;
    transform: translateY(20px);
    animation: poemLine 0.8s ease forwards;
}

@keyframes poemLine {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Задержка для каждой строки */
.poem p:nth-child(1) { animation-delay: 0.2s; }  /* Заголовок */
.poem p:nth-child(3) { animation-delay: 0.4s; }  /* Первая строка */
.poem p:nth-child(4) { animation-delay: 0.6s; }
.poem p:nth-child(5) { animation-delay: 0.8s; }
.poem p:nth-child(6) { animation-delay: 1.0s; }
.poem p:nth-child(8) { animation-delay: 1.4s; }  /* Вторая строфа */
.poem p:nth-child(9) { animation-delay: 1.6s; }
.poem p:nth-child(10) { animation-delay: 1.8s; }
.poem p:nth-child(11) { animation-delay: 2.0s; } 

/* Стили для второй кнопки возврата */
.back-home-main {
    right: 10rem;
    left: auto;
} 

/* Стили для страницы фотографий */
.foto-image {
    height: 50vh;
    bottom: 0;
    left: auto;
    right: 3%;
    filter: brightness(0.95) contrast(1.05);
}

.foto-menu {
    position: fixed;
    width: 100%;
    height: 100vh;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(4, 1fr);
    gap: 20px;
    padding: 5vh 5vw;
}

.foto-menu ul {
    list-style: none;
    grid-column: 1 / -1;
    grid-row: 1 / -1;
    display: grid;
    grid-template-columns: inherit;
    grid-template-rows: inherit;
    gap: inherit;
}

.foto-menu li {
    opacity: 0;
    animation: fadeIn 0.8s ease forwards;
    display: flex;
    align-items: center;
    justify-content: center;
    transform-origin: center;
}

/* Распределяем элементы по сетке */
.foto-menu li:nth-child(1) { 
    grid-area: 1 / 3 / 2 / 4;
    animation-delay: 0.2s;
    transform: rotate(-8deg);
}

.foto-menu li:nth-child(2) {
    grid-area: 2 / 2 / 3 / 3;
    animation-delay: 0.4s;
    transform: rotate(12deg);
}

.foto-menu li:nth-child(3) {
    grid-area: 3 / 3 / 4 / 4;
    animation-delay: 0.6s;
    transform: rotate(-5deg);
}

.foto-menu li:nth-child(4) {
    grid-area: 2 / 3 / 3 / 4;
    animation-delay: 0.8s;
    transform: rotate(10deg);
}

.foto-menu li:nth-child(5) {
    grid-area: 2 / 4 / 3 / 5;
    animation-delay: 1.0s;
    transform: rotate(-12deg);
}

.foto-menu li:nth-child(6) {
    grid-area: 3 / 2 / 4 / 3;
    animation-delay: 1.2s;
    transform: rotate(8deg);
}

.foto-menu li:nth-child(7) {
    grid-area: 4 / 2 / 5 / 3;
    animation-delay: 1.4s;
    transform: rotate(-10deg);
}

.foto-menu li:nth-child(8) {
    grid-area: 4 / 3 / 5 / 4;
    animation-delay: 1.6s;
    transform: rotate(15deg);
}

.foto-menu li:nth-child(9) {
    grid-area: 2 / 1 / 3 / 2;
    animation-delay: 1.8s;
    transform: rotate(-8deg);
}

.foto-menu li:nth-child(10) {
    grid-area: 3 / 1 / 4 / 2;
    animation-delay: 2.0s;
    transform: rotate(12deg);
}

.foto-menu li:nth-child(11) {
    grid-area: 1 / 4 / 2 / 5;
    animation-delay: 2.2s;
    transform: rotate(-15deg);
}

.foto-menu li:nth-child(12) {
    grid-area: 1 / 2 / 2 / 3;
    animation-delay: 2.4s;
    transform: rotate(10deg);
}

.foto-menu li:nth-child(13) {
    grid-area: 1 / 1 / 2 / 2;
    animation-delay: 2.6s;
    transform: rotate(-12deg);
}

/* Адаптивность для разных экранов */
@media (max-width: 768px) {
    .foto-menu {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: repeat(5, 1fr);
    }
}

@media (max-width: 480px) {
    .foto-menu {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(7, 1fr);
    }
}

.foto-menu a {
    pointer-events: auto;
    font-family: 'Cormorant Garamond', serif;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 1.2rem;
    letter-spacing: 3px;
    padding: 0.8rem 1.5rem;
    position: relative;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
    display: inline-block;
}

.foto-menu a:hover {
    color: white;
    transform: scale(1.03) translateY(-3px);
    letter-spacing: 5px;
    text-shadow: 
        0 0 10px rgba(255, 255, 255, 0.6),
        0 0 20px rgba(255, 255, 255, 0.4);
    transition: all 1.2s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.foto-menu a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent,
        rgba(255, 255, 255, 0.5),
        transparent
    );
    transform: scaleX(0);
    transition: transform 1s ease;
}

.foto-menu a:hover::before {
    transform: scaleX(1);
} 

/* Стили для галереи */
.gallery {
    position: relative;
    padding: 2rem;
    height: 80vh;
    width: 90vw;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: none;
    border-radius: 10px;
    font-family: 'Cormorant Garamond', serif;
}

.gallery-main {
    position: relative;
    width: 100%;
    height: 70vh;
    margin-bottom: 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Добавляем эффект вспышки */
.gallery-main::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(255,255,255,0.2) 0%, transparent 100%);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.gallery-main.flash::after {
    animation: flash 0.6s ease-out;
}

@keyframes flash {
    0% {
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0;
    }
}

.gallery-main img {
    max-width: 85%;
    max-height: 60vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 5px;
    box-shadow: 
        0 0 30px rgba(255,255,255,0.1),
        0 0 60px rgba(255,255,255,0.05),
        0 0 90px rgba(255,255,255,0.03);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
    z-index: 1;
}

.gallery-main img.fade {
    opacity: 0;
    transform: scale(0.98);
    filter: brightness(1.2);
}

.gallery-main img.appear {
    opacity: 1;
    transform: scale(1);
    filter: brightness(1);
}

.caption {
    margin-top: 1rem;
    font-style: italic;
    color: rgba(255,255,255,0.8);
    transform: translateX(0);
    font-family: 'Cormorant Garamond', serif;
    letter-spacing: 1px;
    font-size: 1.1rem;
}

.gallery-thumbs {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding: 1rem 0;
    width: 85%;
    margin: 0 auto;
    justify-content: center;
    
    /* Стилизация скроллбара */
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.3) transparent;
}

/* Стиль для сообщения о пустой галерее */
.empty-gallery {
    color: rgba(255, 255, 255, 0.7);
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2rem;
    text-align: center;
    padding: 2rem;
    letter-spacing: 2px;
}

/* Стили для Webkit (Chrome, Safari, Edge) */
.gallery-thumbs::-webkit-scrollbar {
    height: 6px; /* Высота скроллбара */
}

.gallery-thumbs::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05); /* Фон дорожки */
    border-radius: 3px;
}

.gallery-thumbs::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3); /* Цвет полосы прокрутки */
    border-radius: 3px;
    backdrop-filter: blur(5px);
}

.gallery-thumbs::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5); /* Цвет при наведении */
}

.thumb {
    flex: 0 0 100px;
    cursor: pointer;
    opacity: 0.6;
    transition: all 0.3s ease;
}

.thumb.active {
    opacity: 1;
    transform: scale(1.1);
}

.thumb:hover {
    opacity: 0.8;
}

.thumb img {
    width: 100%;
    height: 70px;
    object-fit: cover;
    border-radius: 3px;
}

.gallery-nav {
    position: absolute;
    top: -3rem;
    transform: none;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.6);
    border: 1px solid rgba(255,255,255,0.2);
    color: white;
    cursor: pointer;
    font-size: 1.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
    z-index: 1100;
}

.gallery-nav:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-2px);
}

.prev {
    left: 50%;
    margin-left: -50px;
}

.next {
    left: 50%;
    margin-left: 10px;
} 

/* Анимация исчезновения */
@keyframes fadeOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(-20px);
        visibility: hidden;
    }
}

/* Стили для полноэкранного стихотворения */
.poem-fullscreen {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    max-width: 800px;
    text-align: center;
    z-index: 1100;
}

/* Обновляем стили модального окна */
.modal {
    background-color: transparent;
}

.modal-content {
    background: none;
    box-shadow: none;
    backdrop-filter: none;
}

/* Убираем крестик закрытия */
.close {
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.close:hover {
    opacity: 1;
} 

/* Стили для кнопки play */
.play-button {
    position: absolute;
    left: 15%;
    top: 20%;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.15) 0%, 
        rgba(255, 255, 255, 0.05) 100%);
    backdrop-filter: blur(10px);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
    z-index: 100;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 
        0 4px 15px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.play-button:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.2) 0%, 
        rgba(255, 255, 255, 0.1) 100%);
    box-shadow: 
        0 6px 20px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 0 20px rgba(255, 255, 255, 0.1);
}

.play-icon {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0;
    transition: all 0.3s ease;
    position: relative;
    width: 20px;
    height: 20px;
}

/* Современная иконка play */
.play-icon::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-40%, -50%);
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 10px 0 10px 16px;
    border-color: transparent transparent transparent rgba(255, 255, 255, 0.9);
}

/* Современная иконка pause */
.play-button.playing .play-icon::before {
    border: none;
    width: 14px;
    height: 18px;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.9) 0%, 
        rgba(255, 255, 255, 0.9) 35%, 
        transparent 35%, 
        transparent 65%, 
        rgba(255, 255, 255, 0.9) 65%, 
        rgba(255, 255, 255, 0.9) 100%);
}

.loading-indicator {
    text-align: center;
    padding: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 5px;
    z-index: 1000;
}

/* Ключевые кадры для эффекта вспышки */
@keyframes flash {
    0% {
        opacity: 0;
        transform: scale(0.95);
    }
    50% {
        opacity: 1;
        transform: scale(1);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Класс для эффекта вспышки */
.modal-flash {
    animation: flash 0.5s ease-in-out;
}

/* Стили для оверлея при вспышке */
#flashOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    opacity: 0;
    pointer-events: none;
    z-index: 2000;
    transition: opacity 0.3s ease-in-out;
}

#flashOverlay.active {
    opacity: 1;
}

/* Улучшенные стили для модального окна заглушки без фото (потемнее) */
#placeholderModal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 2rem;
    /* Фон: тёмный градиент для мрачной атмосферы */
    background: linear-gradient(135deg, rgba(0,0,0,0.95) 0%, rgba(30,30,30,0.95) 100%);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.8);
    z-index: 3000;
    display: none;
    text-align: center;
    max-width: 90%;
    animation: fadeInModal 0.4s ease-in-out;
}

/* Анимация плавного появления модального окна */
@keyframes fadeInModal {
    from {
        opacity: 0;
        transform: translate(-50%, -40%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

/* Стили для текста модального окна */
#placeholderModal .modal-text {
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    line-height: 1.4;
}

/* Стили для кнопки закрытия модального окна */
#placeholderModal .close-placeholder {
    cursor: pointer;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    font-size: 1rem;
    transition: background 0.3s ease;
    margin-top: 2rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

#placeholderModal .close-placeholder:hover {
    background: rgba(255, 255, 255, 0.4);
}

/* ==================== МОБИЛЬНАЯ АДАПТАЦИЯ ==================== */

/* Бургер-меню - скрыто на десктопе */
.mobile-menu-toggle {
    display: none;
    position: fixed;
    top: 2rem;
    right: 2rem;
    width: 35px;
    height: 30px;
    z-index: 3500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mobile-menu-toggle span {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 2px;
    opacity: 1;
    left: 0;
    transform: rotate(0deg);
    transition: all 0.25s ease-in-out;
}

.mobile-menu-toggle span:nth-child(1) {
    top: 0px;
}

.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) {
    top: 10px;
    transform: rotate(135deg);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
    left: -60px;
}

.mobile-menu-toggle.active span:nth-child(3) {
    top: 10px;
    transform: rotate(-135deg);
}

/* Мобильное меню оверлей */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.98) 0%, 
        rgba(10, 10, 18, 0.98) 50%, 
        rgba(0, 0, 0, 0.98) 100%);
    z-index: 3000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
}

.mobile-menu {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    width: 100%;
}

.mobile-menu ul {
    list-style: none;
    padding: 0;
}

.mobile-menu li {
    margin: 1.5rem 0;
    opacity: 0;
    transform: translateY(20px);
    animation: none;
}

.mobile-menu-overlay.active .mobile-menu li {
    animation: mobileMenuFadeIn 0.5s ease forwards;
}

.mobile-menu li:nth-child(1) { animation-delay: 0.1s; }
.mobile-menu li:nth-child(2) { animation-delay: 0.2s; }
.mobile-menu li:nth-child(3) { animation-delay: 0.3s; }
.mobile-menu li:nth-child(4) { animation-delay: 0.4s; }
.mobile-menu li:nth-child(5) { animation-delay: 0.5s; }
.mobile-menu li:nth-child(6) { animation-delay: 0.6s; }
.mobile-menu li:nth-child(7) { animation-delay: 0.7s; }

@keyframes mobileMenuFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mobile-menu a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.8rem;
    letter-spacing: 3px;
    transition: all 0.3s ease;
    display: inline-block;
    padding: 0.5rem 1rem;
    position: relative;
}

.mobile-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.mobile-menu a:active {
    transform: scale(0.95);
}

.mobile-menu a:hover::after,
.mobile-menu a:focus::after {
    width: 80%;
}

/* Медиа-запросы для планшетов */
@media (max-width: 1024px) {
    .poet-image {
        height: 45vh;
        left: 2%;
    }
    
    .menu li {
        font-size: 1.2rem;
    }
    
    .play-button {
        left: 10%;
        top: 15%;
    }
}

/* Медиа-запросы для мобильных устройств */
@media (max-width: 768px) {
    /* Скрываем бургер-меню */
    .mobile-menu-toggle,
    .mobile-menu-overlay {
        display: none !important;
    }
    
    /* Адаптируем hero-секцию */
    .hero {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 1rem;
        min-height: 100vh;
        position: relative;
    }
    
    /* Фото поэта по центру без обрезки */
    .poet-image {
        position: absolute;
        bottom: 5%;
        left: 50%;
        transform: translateX(-50%);
        height: auto;
        width: 65%;
        max-width: 250px;
        margin: 0;
        opacity: 0.9;
        filter: drop-shadow(0 0 30px rgba(255,255,255,0.2));
        animation: poetFloat 6s ease-in-out infinite;
        z-index: 1;
    }
    
    @keyframes poetFloat {
        0%, 100% {
            transform: translateX(-50%) translateY(0);
        }
        50% {
            transform: translateX(-50%) translateY(-10px);
        }
    }
    
    /* Показываем меню поверх всего для мобильных */
    .menu {
        display: block !important;
        position: fixed;
        width: 100%;
        height: 100vh;
        pointer-events: none;
        z-index: 100;
    }
    
    .menu ul {
        list-style: none;
        height: 100%;
        position: relative;
        padding: 0;
    }
    
    .menu li {
        position: absolute;
        opacity: 0;
        animation: fadeInMobile 0.8s ease forwards;
        pointer-events: auto;
    }
    
    /* Раскидываем пункты по экрану */
    .menu li:nth-child(1) { /* Книги */
        top: 25%;
        left: 15%;
        animation-delay: 0.1s;
        transform: rotate(-5deg);
    }
    
    .menu li:nth-child(2) { /* Публикации */
        top: 35%;
        right: 20%;
        animation-delay: 0.2s;
        transform: rotate(8deg);
    }
    
    .menu li:nth-child(3) { /* Интервью */
        top: 45%;
        left: 25%;
        animation-delay: 0.3s;
        transform: rotate(-3deg);
    }
    
    .menu li:nth-child(4) { /* Аудио */
        top: 55%;
        right: 15%;
        animation-delay: 0.4s;
        transform: rotate(5deg);
    }
    
    .menu li:nth-child(5) { /* Видео */
        top: 65%;
        left: 20%;
        animation-delay: 0.5s;
        transform: rotate(-7deg);
    }
    
    .menu li:nth-child(6) { /* Википедия */
        top: 75%;
        right: 25%;
        animation-delay: 0.6s;
        transform: rotate(4deg);
    }
    
    .menu li:nth-child(7) { /* Галерея */
        top: 85%;
        left: 30%;
        animation-delay: 0.7s;
        transform: rotate(-2deg);
    }
    
    @keyframes fadeInMobile {
        from {
            opacity: 0;
            transform: translateY(20px) rotate(0deg);
        }
        to {
            opacity: 1;
            transform: translateY(0) rotate(inherit);
        }
    }
    
    .menu a {
        font-size: 1.2rem;
        color: rgba(255, 255, 255, 0.85);
        text-decoration: none;
        letter-spacing: 2px;
        text-shadow: 
            0 0 20px rgba(255, 255, 255, 0.3),
            0 2px 4px rgba(0, 0, 0, 0.5);
        font-family: 'Cormorant Garamond', serif;
        transition: all 0.3s ease;
        display: inline-block;
        padding: 0.5rem;
    }
    
    .menu a:active {
        transform: scale(0.95);
        color: white;
        text-shadow: 
            0 0 30px rgba(255, 255, 255, 0.5),
            0 2px 4px rgba(0, 0, 0, 0.7);
    }
    
    /* Адаптируем кнопку play */
    .play-button {
        position: absolute;
        top: 15%;
        left: 50%;
        transform: translateX(-50%);
        width: 70px;
        height: 70px;
        animation: gentlePulse 3s ease-in-out infinite;
        z-index: 10;
    }
    
    @keyframes gentlePulse {
        0%, 100% {
            box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.2);
        }
        50% {
            box-shadow: 0 0 0 15px rgba(255, 255, 255, 0);
        }
    }
    
    .play-icon {
        font-size: 32px;
    }
    
    /* Модальное окно заглушки */
    #placeholderModal {
        width: 90%;
        padding: 1.5rem;
    }
    
    #placeholderModal .modal-text {
        font-size: 1.1rem;
    }
}

/* Медиа-запросы для маленьких мобильных */
@media (max-width: 480px) {
    .poet-image {
        width: 75%;
        max-width: 220px;
        bottom: 3%;
    }
    
    .play-button {
        width: 60px;
        height: 60px;
        top: 10%;
    }
    
    .menu a {
        font-size: 1rem;
        padding: 0.3rem;
    }
    
    /* Подстраиваем позиции для маленьких экранов */
    .menu li:nth-child(1) { top: 22%; left: 10%; }
    .menu li:nth-child(2) { top: 32%; right: 10%; }
    .menu li:nth-child(3) { top: 42%; left: 15%; }
    .menu li:nth-child(4) { top: 52%; right: 8%; }
    .menu li:nth-child(5) { top: 62%; left: 12%; }
    .menu li:nth-child(6) { top: 72%; right: 15%; }
    .menu li:nth-child(7) { top: 82%; left: 20%; }
    
    .books-menu a {
        font-size: 0.85rem;
        padding: 0.3rem;
    }
    
    /* Подстраиваем позиции книг */
    .books-menu li:nth-child(1) { top: 18%; left: 5%; }
    .books-menu li:nth-child(2) { top: 28%; right: 8%; }
    .books-menu li:nth-child(3) { top: 38%; left: 10%; }
    .books-menu li:nth-child(4) { top: 48%; right: 5%; }
    .books-menu li:nth-child(5) { top: 58%; left: 8%; }
    .books-menu li:nth-child(6) { top: 68%; right: 10%; }
    .books-menu li:nth-child(7) { top: 78%; left: 15%; }
    
    .books-image {
        height: 30vh;
    }
}

/* Специальные стили для iPhone SE и маленьких экранов */
@media (max-width: 375px) {
    .hero {
        padding: 0.5rem;
    }
    
    .poet-image {
        width: 80%;
        max-width: 200px;
        bottom: 2%;
    }
    
    .menu a {
        font-size: 0.9rem;
        padding: 0.2rem;
        letter-spacing: 1px;
    }
    
    .play-button {
        width: 55px;
        height: 55px;
        top: 8%;
    }
    
    /* Еще компактнее для маленьких экранов */
    .menu li:nth-child(1) { top: 20%; left: 8%; }
    .menu li:nth-child(2) { top: 30%; right: 8%; }
    .menu li:nth-child(3) { top: 40%; left: 10%; }
    .menu li:nth-child(4) { top: 50%; right: 5%; }
    .menu li:nth-child(5) { top: 60%; left: 8%; }
    .menu li:nth-child(6) { top: 70%; right: 10%; }
    .menu li:nth-child(7) { top: 80%; left: 15%; }
    
    .books-menu a {
        font-size: 0.75rem;
        padding: 0.2rem;
    }
    
    .books-image {
        height: 25vh;
        opacity: 0.2;
    }
}

/* Ландшафтная ориентация на мобильных */
@media (max-width: 768px) and (orientation: landscape) {
    .hero {
        flex-direction: row;
        padding: 1rem;
    }
    
    .poet-image {
        height: 70vh;
        width: auto;
        margin-top: 0;
        margin-left: 2rem;
    }
    
    .play-button {
        margin-bottom: 0;
        margin-right: 2rem;
    }
    
    .mobile-menu a {
        font-size: 1.3rem;
    }
    
    .mobile-menu li {
        margin: 0.8rem 0;
    }
}

/* Поддержка тач-устройств */
@media (hover: none) and (pointer: coarse) {
    .menu a:hover,
    .mobile-menu a:hover {
        transform: none;
    }
    
    .play-button:hover {
        transform: none;
    }
}

/* ==================== СТРАНИЦА КНИГ - МОБИЛЬНАЯ ВЕРСИЯ ==================== */

/* Кнопка меню "Книги" */
.books-menu-toggle {
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.1) 0%, 
        rgba(255, 255, 255, 0.05) 100%);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 25px;
    padding: 10px 20px;
    width: auto;
    height: auto;
}

.books-menu-toggle .menu-text {
    font-family: 'Cormorant Garamond', serif;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.2rem;
    letter-spacing: 2px;
    display: block;
    background: none;
    height: auto;
    width: auto;
    position: static;
    transform: none;
    opacity: 1;
}

.books-menu-toggle span:not(.menu-text) {
    display: none;
}

.books-menu-toggle.active .menu-text::after {
    content: ' ×';
    font-size: 1.5rem;
    margin-left: 5px;
}

/* Оверлей для книг */
.books-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(0, 0, 0, 0.98) 0%, 
        rgba(10, 10, 18, 0.98) 50%, 
        rgba(0, 0, 0, 0.98) 100%);
    z-index: 3000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.books-menu-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

/* Адаптация фото на странице книг для мобильных */
@media (max-width: 768px) {
    /* Скрываем бургер-меню */
    .books-menu-toggle,
    .books-menu-overlay {
        display: none !important;
    }
    
    /* Показываем меню книг поверх всего */
    .books-menu {
        display: block !important;
        position: fixed;
        width: 100%;
        height: 100vh;
        pointer-events: none;
        z-index: 100;
    }
    
    .books-menu ul {
        list-style: none;
        height: 100%;
        position: relative;
        padding: 0;
    }
    
    .books-menu li {
        position: absolute;
        opacity: 0;
        animation: fadeInMobile 0.8s ease forwards;
        pointer-events: auto;
    }
    
    /* Раскидываем книги по экрану */
    .books-menu li:nth-child(1) {
        top: 20%;
        left: 10%;
        animation-delay: 0.1s;
        transform: rotate(-8deg);
    }
    
    .books-menu li:nth-child(2) {
        top: 30%;
        right: 15%;
        animation-delay: 0.2s;
        transform: rotate(5deg);
    }
    
    .books-menu li:nth-child(3) {
        top: 40%;
        left: 20%;
        animation-delay: 0.3s;
        transform: rotate(-3deg);
    }
    
    .books-menu li:nth-child(4) {
        top: 50%;
        right: 10%;
        animation-delay: 0.4s;
        transform: rotate(7deg);
    }
    
    .books-menu li:nth-child(5) {
        top: 60%;
        left: 15%;
        animation-delay: 0.5s;
        transform: rotate(-5deg);
    }
    
    .books-menu li:nth-child(6) {
        top: 70%;
        right: 20%;
        animation-delay: 0.6s;
        transform: rotate(3deg);
    }
    
    .books-menu li:nth-child(7) {
        top: 80%;
        left: 25%;
        animation-delay: 0.7s;
        transform: rotate(-4deg);
    }
    
    .books-menu a {
        font-size: 1rem;
        color: rgba(255, 255, 255, 0.85);
        text-decoration: none;
        letter-spacing: 1.5px;
        text-shadow: 
            0 0 20px rgba(255, 255, 255, 0.3),
            0 2px 4px rgba(0, 0, 0, 0.5);
        font-family: 'Cormorant Garamond', serif;
        transition: all 0.3s ease;
        display: inline-block;
        padding: 0.4rem;
    }
    
    .books-menu a:active {
        transform: scale(0.95);
        color: white;
        text-shadow: 
            0 0 30px rgba(255, 255, 255, 0.5),
            0 2px 4px rgba(0, 0, 0, 0.7);
    }
    
    /* Фото по центру сзади */
    .books-image {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        height: 35vh;
        width: auto;
        opacity: 0.25;
        z-index: 1;
        animation: subtleFloat 8s ease-in-out infinite;
    }
    
    @keyframes subtleFloat {
        0%, 100% {
            transform: translate(-50%, -50%) scale(1);
        }
        50% {
            transform: translate(-50%, -52%) scale(1.02);
        }
    }
    
    /* Кнопка возврата */
    .back-home {
        position: fixed;
        top: 1rem;
        right: 1rem;
        font-size: 1rem;
        padding: 0.4rem 0.8rem;
        z-index: 200;
    }
}

/* Адаптация для маленьких экранов */
@media (max-width: 480px) {
    .books-menu-toggle {
        top: 1.5rem;
        right: 1.5rem;
    }
    
    .books-menu-toggle .menu-text {
        font-size: 1.1rem;
    }
    
    .books-image {
        height: 35vh;
    }
}

/* ==================== СТРАНИЦА ФОТО - МОБИЛЬНАЯ ВЕРСИЯ ==================== */
@media (max-width: 768px) {
    /* Адаптируем меню фото */
    .foto-menu {
        display: block !important;
        position: fixed;
        width: 100%;
        height: 100vh;
        pointer-events: none;
        z-index: 100;
    }
    
    .foto-menu ul {
        list-style: none;
        height: 100%;
        position: relative;
        padding: 0;
        display: block;
    }
    
    .foto-menu li {
        position: absolute;
        opacity: 0;
        animation: fadeInMobile 0.6s ease forwards;
        pointer-events: auto;
    }
    
    /* Раскидываем фото-ссылки по экрану плотнее */
    .foto-menu li:nth-child(1) { top: 12%; left: 5%; animation-delay: 0.05s; transform: rotate(-6deg); }
    .foto-menu li:nth-child(2) { top: 19%; right: 8%; animation-delay: 0.1s; transform: rotate(4deg); }
    .foto-menu li:nth-child(3) { top: 26%; left: 10%; animation-delay: 0.15s; transform: rotate(-3deg); }
    .foto-menu li:nth-child(4) { top: 33%; right: 5%; animation-delay: 0.2s; transform: rotate(5deg); }
    .foto-menu li:nth-child(5) { top: 40%; left: 8%; animation-delay: 0.25s; transform: rotate(-4deg); }
    .foto-menu li:nth-child(6) { top: 47%; right: 10%; animation-delay: 0.3s; transform: rotate(3deg); }
    .foto-menu li:nth-child(7) { top: 54%; left: 6%; animation-delay: 0.35s; transform: rotate(-5deg); }
    .foto-menu li:nth-child(8) { top: 61%; right: 7%; animation-delay: 0.4s; transform: rotate(4deg); }
    .foto-menu li:nth-child(9) { top: 68%; left: 12%; animation-delay: 0.45s; transform: rotate(-3deg); }
    .foto-menu li:nth-child(10) { top: 75%; right: 9%; animation-delay: 0.5s; transform: rotate(5deg); }
    .foto-menu li:nth-child(11) { top: 82%; left: 8%; animation-delay: 0.55s; transform: rotate(-4deg); }
    .foto-menu li:nth-child(12) { top: 89%; right: 12%; animation-delay: 0.6s; transform: rotate(3deg); }
    .foto-menu li:nth-child(13) { top: 85%; left: 40%; animation-delay: 0.65s; transform: rotate(-2deg); }
    
    .foto-menu a {
        font-size: 0.8rem;
        color: rgba(255, 255, 255, 0.85);
        text-decoration: none;
        letter-spacing: 1px;
        text-shadow: 
            0 0 20px rgba(255, 255, 255, 0.3),
            0 2px 4px rgba(0, 0, 0, 0.5);
        font-family: 'Cormorant Garamond', serif;
        transition: all 0.3s ease;
        display: inline-block;
        padding: 0.3rem;
    }
    
    .foto-menu a:active {
        transform: scale(0.95);
        color: white;
        text-shadow: 
            0 0 30px rgba(255, 255, 255, 0.5),
            0 2px 4px rgba(0, 0, 0, 0.7);
    }
    
    /* Фото сзади */
    .foto-image {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        height: 30vh;
        width: auto;
        opacity: 0.2;
        z-index: 1;
        animation: subtleFloat 10s ease-in-out infinite;
    }
}

@media (max-width: 480px) {
    .foto-menu a {
        font-size: 0.7rem;
        padding: 0.2rem;
    }
    
    .foto-image {
        height: 25vh;
        opacity: 0.15;
    }
}

@media (max-width: 375px) {
    .foto-menu a {
        font-size: 0.65rem;
        letter-spacing: 0.5px;
    }
    
    /* Еще плотнее для маленьких экранов */
    .foto-menu li:nth-child(1) { top: 10%; left: 3%; }
    .foto-menu li:nth-child(2) { top: 17%; right: 5%; }
    .foto-menu li:nth-child(3) { top: 24%; left: 7%; }
    .foto-menu li:nth-child(4) { top: 31%; right: 3%; }
    .foto-menu li:nth-child(5) { top: 38%; left: 5%; }
    .foto-menu li:nth-child(6) { top: 45%; right: 7%; }
    .foto-menu li:nth-child(7) { top: 52%; left: 4%; }
    .foto-menu li:nth-child(8) { top: 59%; right: 5%; }
    .foto-menu li:nth-child(9) { top: 66%; left: 8%; }
    .foto-menu li:nth-child(10) { top: 73%; right: 6%; }
    .foto-menu li:nth-child(11) { top: 80%; left: 5%; }
    .foto-menu li:nth-child(12) { top: 87%; right: 8%; }
    .foto-menu li:nth-child(13) { top: 83%; left: 35%; }
}

/* ==================== ГАЛЕРЕЯ - МОБИЛЬНАЯ ВЕРСИЯ ==================== */
@media (max-width: 768px) {
    .gallery {
        padding: 1rem;
        height: 90vh;
        width: 100vw;
        transform: none;
    }
    
    .gallery-main {
        height: 60vh;
    }
    
    .gallery-main img {
        max-width: 95%;
        max-height: 50vh;
    }
    
    .caption {
        font-size: 1rem;
        margin-top: 0.5rem;
    }
    
    .gallery-thumbs {
        gap: 0.5rem;
        padding: 0.5rem 0;
        width: 95%;
    }
    
    .thumb {
        flex: 0 0 60px;
    }
    
    .thumb img {
        height: 50px;
    }
    
    .gallery-nav {
        width: 50px;
        height: 50px;
        font-size: 1.8rem;
        background: rgba(0,0,0,0.8);
        border: 1px solid rgba(255,255,255,0.3);
    }
    
    .prev {
        left: 1rem;
        top: 50%;
        transform: translateY(-50%);
        margin-left: 0;
    }
    
    .next {
        right: 1rem;
        left: auto;
        top: 50%;
        transform: translateY(-50%);
        margin-left: 0;
    }
    
    .loading-indicator {
        font-size: 0.9rem;
        font-family: 'Cormorant Garamond', serif;
    }
    
    /* Модальное окно на мобильных */
    .modal-content {
        margin: 0;
        padding: 1rem;
        width: 100%;
        max-width: 100%;
        height: 100vh;
    }
    
    .close {
        right: 1rem;
        top: 1rem;
        font-size: 2.5rem;
        background: rgba(0,0,0,0.5);
        width: 40px;
        height: 40px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        line-height: 1;
    }
}

@media (max-width: 480px) {
    .gallery-main img {
        max-height: 45vh;
    }
    
    .thumb {
        flex: 0 0 50px;
    }
    
    .thumb img {
        height: 40px;
    }
    
    .gallery-nav {
        width: 40px;
        height: 40px;
        font-size: 1.5rem;
    }
} 