@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@400;600;700&family=Nunito:wght@400;600;700&display=swap');

:root {
    --primary: #FF6B6B;
    /* Soft Red */
    --secondary: #4ECDC4;
    /* Teal */
    --accent: #FFE66D;
    /* Yellow */
    --text-main: #2D3436;
    --text-light: #636E72;
    --card-bg: rgba(255, 255, 255, 0.9);
    --bg-gradient: linear-gradient(135deg, #74ebd5 0%, #ACB6E5 100%);
}

* {
    box-sizing: border-box;
}

body {
    background: var(--bg-gradient);
    background-attachment: fixed;
    color: var(--text-main);
    font-family: 'Nunito', sans-serif;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    min-height: 100vh;
}

/* --- Animated Background Sprites --- */
.sprite-run {
    position: fixed;
    z-index: -1;
    /* Move behind everything */
    width: 80px;
    height: 80px;
    background-size: 200% 200%;
    /* 2x2 grid */
    pointer-events: none;
    opacity: 1.0;
    /* mix-blend-mode removed - assets are transparent */
}

@keyframes spriteWalk {
    0% {
        background-position: 0% 0%;
    }

    25% {
        background-position: 100% 0%;
    }

    50% {
        background-position: 0% 100%;
    }

    75% {
        background-position: 100% 100%;
    }

    100% {
        background-position: 0% 0%;
    }

    /* Loop back smoothly */
}

/* Smoother Running across screen */
@keyframes runAcross {
    0% {
        transform: translateX(-150px);
    }

    100% {
        transform: translateX(110vw);
    }
}

@keyframes flyAcross {
    0% {
        transform: translateX(-150px) translateY(0);
    }

    50% {
        transform: translateX(50vw) translateY(-30px);
    }

    100% {
        transform: translateX(110vw) translateY(0);
    }
}

.lion-run {
    background-image: url('pictures/SpriteLion.png');
    animation: spriteWalk 0.6s steps(1) infinite, runAcross 20s linear infinite;
    bottom: 5vh;
    left: 0;
    /* Position controlled by transform */
    animation-delay: 0s;
}

.bear-run {
    background-image: url('pictures/SpriteBear.png');
    width: 100px;
    height: 100px;
    animation: spriteWalk 0.7s steps(1) infinite, runAcross 25s linear infinite;
    bottom: 2vh;
    animation-delay: 8s;
}

.fox-run {
    background-image: url('pictures/SpriteFox.png');
    animation: spriteWalk 0.5s steps(1) infinite, runAcross 15s linear infinite;
    bottom: 15vh;
    animation-delay: 3s;
}

.owl-fly {
    background-image: url('pictures/SpriteOwl.png');
    animation: spriteWalk 0.5s steps(1) infinite, flyAcross 22s linear infinite;
    top: 15vh;
    z-index: -1;
    animation-delay: 12s;
}

.monkey-run {
    background-image: url('pictures/SpriteMonkey.png');
    animation: spriteWalk 0.55s steps(1) infinite, runAcross 18s linear infinite;
    bottom: 8vh;
    animation-delay: 15s;
}

.container {
    max-width: 700px;
    margin: 4rem auto 2rem auto;
    background: rgba(255, 255, 255, 0.92);
    /* More opaque for readability */
    border-radius: 24px;
    padding: 3rem 2.5rem;
    position: relative;
    z-index: 10;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow:
        0 10px 40px rgba(0, 0, 0, 0.1),
        0 4px 12px rgba(0, 0, 0, 0.05);
}

/* --- Header & Lang Switch --- */
.lang-switch {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-bottom: 2rem;
}

.lang-btn {
    background: rgba(255, 255, 255, 0.5);
    color: var(--text-main);
    border: none;
    border-radius: 12px;
    padding: 6px 12px;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Fredoka', sans-serif;
    transition: all 0.2s ease;
}

.lang-btn:hover,
.lang-btn.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
    transform: translateY(-2px);
}

.hero {
    text-align: center;
    margin-bottom: 2.5rem;
}

.hero-img {
    width: 140px;
    height: 140px;
    background: white;
    border-radius: 28px;
    margin: 0 auto 1.5rem auto;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    padding: 10px;
    transform: rotate(-3deg);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.hero-img:hover {
    transform: rotate(3deg) scale(1.05);
}

.hero-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 20px;
}

.hero-title {
    font-family: 'Fredoka', sans-serif;
    font-size: 2.8rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.5rem;
    letter-spacing: -1px;
    text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.05);
}

.hero-sub {
    font-size: 1.3rem;
    color: var(--text-light);
    font-weight: 600;
}

/* --- Content Blocks --- */
.promo {
    background: linear-gradient(135deg, var(--secondary) 0%, #45B7AF 100%);
    color: white;
    padding: 1.5rem;
    border-radius: 20px;
    margin-bottom: 2rem;
    font-size: 1.15rem;
    line-height: 1.6;
    box-shadow: 0 8px 20px rgba(78, 205, 196, 0.3);
    position: relative;
    overflow: hidden;
}

.desc {
    font-size: 1.15rem;
    line-height: 1.85;
    color: var(--text-main);
    margin-bottom: 2.5rem;
}

.desc ul {
    background: rgba(255, 255, 255, 0.5);
    padding: 1.8rem 1.8rem 1.8rem 2.8rem;
    border-radius: 16px;
    margin: 1.8rem 0;
}

.desc li {
    margin-bottom: 1.1rem;
    line-height: 1.6;
}

.desc li:last-child {
    margin-bottom: 0;
}

/* Privacy & Impressum */
.privacy-section,
.impressum-section {
    background: white;
    padding: 2rem;
    border-radius: 16px;
    margin-bottom: 2rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    font-size: 1.05rem;
    line-height: 1.7;
}

.privacy-section ul {
    list-style: none;
    padding: 0;
}

.privacy-section li {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
    position: relative;
}

.privacy-back-link {
    margin-top: 2rem;
}

.back-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.back-link:hover {
    color: var(--secondary);
}

/* Speed Mode Visual */
.speedmode-visual {
    margin: 2rem 0;
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 4px solid white;
}

.speed-bg {
    width: 100%;
    display: block;
}

.speed-fox {
    position: absolute;
    bottom: 35%;
    /* Moved up significantly */
    left: 50%;
    transform: translateX(-50%);
    width: 110px;
    /* Slightly larger */
    filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.25));
    z-index: 10;
    animation: fox-pulse 2.5s ease-in-out infinite alternate;
}

@keyframes fox-pulse {
    0% {
        transform: translateX(-50%) scale(1);
    }

    100% {
        transform: translateX(-50%) scale(1.08);
    }
}

/* Animals running inside the card */
.card-sprite {
    position: absolute;
    width: 60px;
    height: 60px;
    background-size: 200% 200%;
    z-index: 5;
    pointer-events: none;
    animation: spriteWalk 0.6s steps(1) infinite, cardRunAcross 7s linear infinite;
}

.card-owl {
    top: 15%;
    /* Top part */
    animation: spriteWalk 0.5s steps(1) infinite, cardRunAcross 8s linear infinite;
}

.card-bear {
    bottom: 5%;
    width: 70px;
    height: 70px;
    /* Bear is bigger */
    animation-duration: 0.7s, 9s;
    /* Slower */
}

.card-lion {
    bottom: 20%;
    animation-duration: 0.6s, 6.5s;
}

.card-monkey {
    bottom: 40%;
    /* Higher up the ground */
    animation-duration: 0.55s, 5.5s;
    /* Faster */
}

@keyframes cardRunAcross {
    0% {
        transform: translateX(-100px);
    }

    100% {
        transform: translateX(500px);
    }

    /* Tuned for container width */
}

.speed-caption {
    text-align: center;
    font-weight: 700;
    color: var(--primary);
    margin-top: 0.5rem;
    font-size: 1.1rem;
}

/* --- App Store Button --- */
.appstore-btn-wrapper {
    margin: 3rem 0;
    text-align: center;
}

.appstore-btn img {
    height: 60px;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.appstore-btn img:hover {
    transform: scale(1.1) rotate(-2deg);
}

/* --- Footer --- */
.site-footer {
    text-align: center;
    padding: 2rem 1rem 4rem 1rem;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
    position: relative;
    z-index: 10;
}

.footer-links a {
    color: white;
    text-decoration: none;
    margin: 0 0.5rem;
    font-weight: 700;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
    transition: all 0.2s;
}

.footer-links a:hover {
    border-color: white;
}

@media (max-width: 600px) {
    .container {
        margin-top: 0;
        border-radius: 0;
        min-height: 100vh;
        padding: 2rem 1.2rem;
    }

    .hero-title {
        font-size: 2.2rem;
    }

    .hero-sub {
        font-size: 1.1rem;
    }

    .promo {
        padding: 1.2rem;
        font-size: 1.05rem;
        border-radius: 16px;
    }

    .desc {
        font-size: 1.05rem;
        line-height: 1.75;
    }

    .desc ul {
        padding: 1.2rem 1.2rem 1.2rem 2rem;
        margin: 1.2rem 0;
    }

    .desc li {
        margin-bottom: 0.9rem;
    }

    .speedmode-visual {
        margin: 1.5rem 0;
        border-radius: 16px;
    }

    .privacy-section,
    .impressum-section {
        padding: 1.4rem;
        border-radius: 14px;
        font-size: 0.95rem;
        line-height: 1.6;
    }

    .privacy-section ul {
        margin: 0.5rem 0;
    }

    .privacy-section li {
        margin-bottom: 0.8rem;
        padding-left: 0.5rem;
        line-height: 1.5;
    }

    .privacy-back-link {
        margin-top: 1.5rem;
    }

    .back-link {
        font-size: 0.95rem;
    }

    .sprite-run {
        transform: scale(0.7) translateY(50px);
    }
}