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

html,
body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
    font-family: 'Caveat', sans-serif;
}

body {
    background: #65b2fb;
}

#cake {
    display: block;
    position: relative;
    margin: -10em auto 0 auto;
}

@keyframes candle-appear {
    0% {
        opacity: 0;
        transform: translateY(-20px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.candles-container {
    position: absolute;
    top: 220px;
    left: 50%;
    width: 140px;
    height: 35px;
    display: flex;
    justify-content: space-between;
    transform: translate(-50%, 0);
    opacity: 1;
    will-change: transform;
}

.velas {
    background: #ffffff;
    border-radius: 10px;
    position: relative;
    width: 5px;
    height: 35px;
    backface-visibility: hidden;
    transform: translateZ(0);
}

.velas:after,
.velas:before {
    background: rgba(255, 0, 0, 0.4);
    content: "";
    position: absolute;
    width: 100%;
    height: 3px;
}

.velas:after {
    top: 25%;
    left: 0;
}

.velas:before {
    top: 45%;
    left: 0;
}

.fuego {
    border-radius: 100%;
    position: absolute;
    top: -20px;
    left: 50%;
    margin-left: -2.6px;
    width: 6.66666667px;
    height: 18px;
    opacity: 1;
    transition: opacity 0.5s;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.fuego:nth-child(1) {
    animation: fuego 2s 1.5s infinite;
}

.fuego:nth-child(2) {
    animation: fuego 1.5s 1.5s infinite;
}

.fuego:nth-child(3) {
    animation: fuego 1s 1.5s infinite;
}

.fuego:nth-child(4) {
    animation: fuego 0.5s 1.5s infinite;
}

.fuego:nth-child(5) {
    animation: fuego 0.2s 1.5s infinite;
}

#gifContainer {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    z-index: 20;
    pointer-events: none; /* optional */
}

#gifContainer img {
    width: min(300px, 90vw);
    height: auto;
    display: block;
}

@keyframes fuego {

    0%,
    100% {
        background: rgba(254, 248, 97, 0.5);
        box-shadow: 0 0 40px 10px rgba(248, 233, 209, 0.2);
        transform: translateY(0) scale(1);
    }

    50% {
        background: rgba(255, 50, 0, 0.1);
        box-shadow: 0 0 40px 20px rgba(248, 233, 209, 0.2);
        transform: translateY(-20px) scale(0);
    }
}

@keyframes in {
    to {
        transform: translate(-50%, 0);
    }
}

.text {
    color: #7f6158;
    font-weight: 300;
    font-style: italic;
    text-align: center;
}

.text h1 {
    font-size: 2em;
}

.instructions {
    color: #7f6158;
    text-align: center;
    margin-top: 20px;
    font-size: 1.6em;
}

.confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    background-color: #f00;
    opacity: 0;
    top: -10px;
    animation: confetti-fall 3s linear forwards;
}

@keyframes confetti-fall {
    0% {
        transform: translateY(0) rotate(0deg);
        opacity: 1;
    }

    100% {
        transform: translateY(100vh) rotate(360deg);
        opacity: 0;
    }
}

.blow-area {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    background: transparent;
}