/* ============================================================
   Amazing Travel — Animace a micro-interakce
   ============================================================ */

/* ── Fade in up ────────────────────────────────────────────── */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    opacity: 0;
    animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* ── Fade in ───────────────────────────────────────────────── */
@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.animate-fade-in {
    animation: fadeIn 0.4s ease forwards;
}

/* ── Scale in ──────────────────────────────────────────────── */
@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.92); }
    to   { opacity: 1; transform: scale(1); }
}

.animate-scale-in {
    animation: scaleIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

/* ── Stagger — dětské elementy se animují se zpožděním ──────── */
.stagger-children > * {
    opacity: 0;
    animation: fadeInUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.stagger-children > *:nth-child(1) { animation-delay: 0ms; }
.stagger-children > *:nth-child(2) { animation-delay: 60ms; }
.stagger-children > *:nth-child(3) { animation-delay: 120ms; }
.stagger-children > *:nth-child(4) { animation-delay: 180ms; }
.stagger-children > *:nth-child(5) { animation-delay: 240ms; }
.stagger-children > *:nth-child(6) { animation-delay: 300ms; }
.stagger-children > *:nth-child(7) { animation-delay: 360ms; }
.stagger-children > *:nth-child(8) { animation-delay: 420ms; }

/* ── Scroll-triggered reveal (IntersectionObserver) ─────────── */
.reveal {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 100ms; }
.reveal-delay-2 { transition-delay: 200ms; }
.reveal-delay-3 { transition-delay: 300ms; }

/* ── Pulse dot (live indicator) ────────────────────────────── */
@keyframes livePulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50%      { transform: scale(1.6); opacity: 0.5; }
}

.live-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #4ade80;
    border-radius: 50%;
    animation: livePulse 2s ease infinite;
}

/* ── Number count-up ─────────────────────────────────────────  */
.count-up {
    display: inline-block;
    transition: opacity 0.3s ease;
}

/* ── Card hover lift ─────────────────────────────────────────  */
.hover-lift {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
                box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.15);
}

/* ── Shimmer loading effect ──────────────────────────────────  */
@keyframes shimmer {
    0%   { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
}

.shimmer {
    background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
    background-size: 1000px 100%;
    animation: shimmer 1.8s infinite;
}

/* ── Floating animation (USP icons, badges) ──────────────────  */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-6px); }
}

.animate-float {
    animation: float 3s ease-in-out infinite;
}

/* ── Spin loading ─────────────────────────────────────────────  */
@keyframes spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

.animate-spin-slow {
    animation: spin 2s linear infinite;
}

/* ── Star rating fill animation ────────────────────────────── */
@keyframes starFill {
    from { color: #e2e8f0; }
    to   { color: #fbbf24; }
}

.star-animated {
    animation: starFill 0.3s ease forwards;
}

/* ── Overlay slide-in (mobile menu) ────────────────────────── */
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to   { opacity: 1; transform: translateY(0); }
}

#mobile-menu:not(.hidden) {
    animation: slideDown 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── Progress bar animation ─────────────────────────────────  */
@keyframes progressBar {
    from { width: 0%; }
    to   { width: 100%; }
}

.progress-bar {
    height: 3px;
    background: linear-gradient(90deg, #0057B8, #00B4D8);
    animation: progressBar 0.6s ease forwards;
    border-radius: 2px;
}

/* ── Tooltip ─────────────────────────────────────────────────  */
[data-tooltip] {
    position: relative;
}

[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    background: #0F1B2D;
    color: white;
    font-size: 0.75rem;
    padding: 0.375rem 0.625rem;
    border-radius: 0.5rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 100;
}

[data-tooltip]:hover::after {
    opacity: 1;
}
