/* Глобальные эффекты для сайта */

/* 1. Пульсация (для сердечек) */
.pulse {
    animation: pulse-animation 1.5s infinite ease-in-out alternate;
}
@keyframes pulse-animation {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.15); opacity: 1; }
}

/* 2. Мерцание (для звездочек) */
.twinkle {
    animation: twinkle-animation 2s infinite ease-in-out alternate;
}
@keyframes twinkle-animation {
    0% { opacity: 0.4; transform: scale(0.9); }
    100% { opacity: 1; transform: scale(1.1) rotate(5deg); }
}

/* 3. Свечение текста (Glow) */
.glow-text {
    text-shadow: 0 0 10px rgba(250, 218, 221, 0.8), /* primary-container */
                 0 0 20px rgba(250, 218, 221, 0.5);
}

/* 4. Свечение картинок (Glow) */
.glow-img {
    filter: drop-shadow(0 0 15px rgba(250, 218, 221, 0.8)) drop-shadow(0 0 30px rgba(250, 218, 221, 0.4)) !important;
}

/* 5. Шлейф за мышкой */
.mouse-trail-particle {
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    font-size: 14px;
    animation: trail-fade 1s ease-out forwards;
}

@keyframes trail-fade {
    0% { transform: translateY(0) scale(1) rotate(0deg); opacity: 1; }
    100% { transform: translateY(-20px) scale(0.5) rotate(45deg); opacity: 0; }
}

/* 6. Падающие частицы на фоне */
.falling-particle {
    position: fixed;
    top: -50px;
    pointer-events: none;
    z-index: -1;
    font-size: 20px;
    animation: fall linear forwards;
    opacity: 0.6;
}

@keyframes fall {
    0% { transform: translateY(0) rotate(0deg); }
    100% { transform: translateY(110vh) rotate(360deg); }
}

/* 7. Peeking Chibis in corners */
.chibi-corner-1 {
    position: fixed;
    bottom: -10px;
    left: -10px;
    width: 140px;
    z-index: 0;
    opacity: 0.9;
    filter: drop-shadow(0 0 10px rgba(250, 218, 221, 0.5));
    animation: peek-corner-1 8s ease-in-out infinite alternate;
}
@keyframes peek-corner-1 {
    0% { transform: translate(-60px, 60px) rotate(-10deg); }
    100% { transform: translate(0, 0) rotate(5deg); }
}

.chibi-corner-2 {
    position: fixed;
    bottom: -10px;
    right: -10px;
    width: 140px;
    z-index: 0;
    opacity: 0.9;
    filter: drop-shadow(0 0 10px rgba(250, 218, 221, 0.5));
    animation: peek-corner-2 9s ease-in-out infinite alternate;
}
@keyframes peek-corner-2 {
    /* using scaleX(-1) to flip it if it faces left, but we can just use normal transform. I'll just flip it anyway to face inward */
    0% { transform: scaleX(-1) translate(-60px, 60px) rotate(-10deg); }
    100% { transform: scaleX(-1) translate(0, 0) rotate(5deg); }
}

/* --- IPAD SPECIFIC TWEAKS (768px - 1024px) --- */
@media (min-width: 768px) and (max-width: 1024px) {
    /* 1. Увеличиваем главный конверт и открытку на главной и proposal, чтобы они не казались слишком мелкими на большом экране */
    .envelope-container, 
    .bg-surface-container-low.max-w-\[450px\] {
        max-width: 600px !important;
    }

    /* 2. Увеличиваем чибиков в углах и плавающих чибиков */
    .chibi-corner-1, .chibi-corner-2 {
        width: 180px !important;
    }
    .peeking-jimin {
        width: 140px !important;
    }

    /* 3. Календарь на when.html: увеличиваем отступы между датами для более удобного нажатия пальцем на планшете */
    #dynamic-date-container {
        gap: 1.5rem !important;
        padding-bottom: 1.5rem !important;
    }

    /* 4. Карточки выбора места на where.html: делаем их немного выше для лучшей пропорции в сетке 2x2 */
    .card-option {
        min-height: 320px !important;
    }
    
    /* 5. Увеличиваем текст и отступы в центральных карточках */
    .pencil-shadow {
        padding: 3rem !important;
    }
    
    /* 6. Увеличиваем базовый размер шрифта для заголовков */
    h1 {
        font-size: 3.5rem !important;
        line-height: 1.3 !important;
    }
    
    /* 7. Кнопки (Далее, Да, Нет) - делаем их крупнее для удобства на iPad */
    .hand-drawn-btn, button {
        padding: 1rem 3rem !important;
        font-size: 1.5rem !important;
    }
}
