* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family:
        -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI",
        "Roboto", "Helvetica Neue", Arial, sans-serif;
    height: 100vh;
    width: 100vw;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #fdfaf5;
    background-image:
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 2px,
            rgba(0, 0, 0, 0.02) 2px,
            rgba(0, 0, 0, 0.02) 3px
        ),
        repeating-linear-gradient(
            90deg,
            transparent,
            transparent 2px,
            rgba(0, 0, 0, 0.02) 2px,
            rgba(0, 0, 0, 0.02) 3px
        );
    overflow: hidden;
    position: fixed;
    top: 0;
    left: 0;
}

/* Sketch paper texture */
body::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(
            circle at 20% 50%,
            transparent 0%,
            rgba(0, 0, 0, 0.01) 100%
        ),
        radial-gradient(
            circle at 80% 80%,
            transparent 0%,
            rgba(0, 0, 0, 0.01) 100%
        );
    pointer-events: none;
}

.container {
    text-align: center;
    z-index: 10;
    padding: 2vh 5vw;
    max-width: 90vw;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

h1 {
    font-size: clamp(2em, 8vw, 4em);
    font-weight: 700;
    color: #2c2c2c;
    margin-bottom: 0.5vh;
    transform: rotate(-1deg);
    text-shadow: 2px 2px 0px rgba(255, 200, 200, 0.3);
    letter-spacing: -1px;
}

.subtitle {
    font-size: clamp(1em, 3vw, 1.4em);
    color: #666;
    margin-bottom: 3vh;
    transform: rotate(0.5deg);
    font-weight: 400;
}

.sketch-box {
    position: relative;
    display: inline-block;
    padding: 10px;
}

/* Hand-drawn border effect */
.sketch-box::before {
    content: "";
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border: 3px solid #2c2c2c;
    border-radius: 15px;
    transform: rotate(-0.5deg);
    box-shadow: 3px 3px 0px rgba(0, 0, 0, 0.1);
}

.useless-button {
    position: relative;
    padding: clamp(15px, 3vh, 25px) clamp(30px, 6vw, 50px);
    font-size: clamp(1.2em, 4vw, 1.8em);
    font-weight: 600;
    background: #fff;
    color: #2c2c2c;
    border: 3px solid #2c2c2c;
    border-radius: 12px;
    cursor: pointer;
    box-shadow:
        5px 5px 0px rgba(0, 0, 0, 0.15),
        inset 2px 2px 0px rgba(255, 255, 255, 0.5);
    transition: all 0.1s ease;
    transform: rotate(0deg);
    letter-spacing: 1px;
}

.useless-button:hover {
    transform: rotate(-2deg) translateY(-2px);
    box-shadow:
        7px 7px 0px rgba(0, 0, 0, 0.15),
        inset 2px 2px 0px rgba(255, 255, 255, 0.5);
}

.useless-button:active {
    transform: rotate(1deg) translateY(2px);
    box-shadow:
        2px 2px 0px rgba(0, 0, 0, 0.15),
        inset 2px 2px 0px rgba(255, 255, 255, 0.5);
}

.click-counter {
    margin-top: 2vh;
    font-size: clamp(1em, 3vw, 1.5em);
    color: #666;
    font-weight: bold;
    padding: clamp(10px, 2vh, 15px) clamp(20px, 4vw, 30px);
    background: #fff;
    border: 2px dashed #999;
    border-radius: 8px;
    display: inline-block;
    transform: rotate(-1deg);
    box-shadow: 2px 2px 0px rgba(0, 0, 0, 0.05);
}

.message {
    margin-top: 2vh;
    font-size: clamp(1.2em, 4vw, 2em);
    color: #ff6b6b;
    font-weight: 600;
    min-height: clamp(30px, 6vh, 60px);
    animation: fadeIn 0.3s ease;
    transform: rotate(1deg);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.8) rotate(1deg);
    }
    to {
        opacity: 1;
        transform: scale(1) rotate(1deg);
    }
}

.particle {
    position: absolute;
    pointer-events: none;
    font-size: 2em;
    animation: float-away 2s ease-out forwards;
}

@keyframes float-away {
    to {
        transform: translateY(-200px) translateX(var(--drift)) rotate(360deg);
        opacity: 0;
    }
}

.shake {
    animation: shake 0.4s;
}

@keyframes shake {
    0%,
    100% {
        transform: rotate(0deg);
    }
    25% {
        transform: rotate(-3deg);
    }
    75% {
        transform: rotate(3deg);
    }
}

.spin {
    animation: wobble-spin 0.8s ease-in-out;
}

@keyframes wobble-spin {
    0% {
        transform: rotate(0deg) scale(1);
    }
    25% {
        transform: rotate(-15deg) scale(1.1);
    }
    50% {
        transform: rotate(180deg) scale(0.9);
    }
    75% {
        transform: rotate(195deg) scale(1.1);
    }
    100% {
        transform: rotate(360deg) scale(1);
    }
}

.glitch {
    animation: sketch-glitch 0.3s;
}

@keyframes sketch-glitch {
    0% {
        transform: translate(0) rotate(-1deg);
    }
    25% {
        transform: translate(-3px, 2px) rotate(-2deg);
    }
    50% {
        transform: translate(3px, -2px) rotate(0deg);
    }
    75% {
        transform: translate(-2px, -3px) rotate(-1deg);
    }
    100% {
        transform: translate(0) rotate(-1deg);
    }
}

.doodle {
    position: absolute;
    pointer-events: none;
    opacity: 0.3;
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%,
    100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

.arrow {
    position: absolute;
    font-size: clamp(2em, 5vw, 3em);
    color: #ff6b6b;
    animation: bounce 1s infinite;
    top: clamp(150px, 20vh, 200px);
    right: clamp(30px, 8vw, 60px);
}

@keyframes bounce {
    0%,
    100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

.footer {
    position: fixed;
    bottom: clamp(15px, 3vh, 30px);
    color: #999;
    font-size: clamp(0.8em, 2vw, 1em);
    transform: rotate(-0.5deg);
    padding: 0 20px;
    text-align: center;
}

.footer a {
    color: #666;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s ease;
}

.footer a:hover {
    color: #2c2c2c;
    text-decoration: underline;
}

.scribble {
    position: absolute;
    width: 100px;
    height: 100px;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    animation: rotate-slow 20s linear infinite;
}

@keyframes rotate-slow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.useless-fact {
    margin-top: 2vh;
    padding: clamp(15px, 2vh, 20px) clamp(20px, 4vw, 30px);
    background: #fffef8;
    border-left: 4px solid #ffd93d;
    border-radius: 5px;
    color: #666;
    font-size: clamp(1em, 2.5vw, 1.2em);
    max-width: 90vw;
    margin-left: auto;
    margin-right: auto;
    box-shadow: 2px 2px 0px rgba(0, 0, 0, 0.05);
    transform: rotate(-0.5deg);
    text-align: left;
}

.progress-bar {
    margin-top: 2vh;
    width: clamp(200px, 60vw, 300px);
    height: clamp(20px, 3vh, 30px);
    background: #fff;
    border: 2px solid #2c2c2c;
    border-radius: 15px;
    position: relative;
    overflow: hidden;
    display: inline-block;
}

.progress-fill {
    height: 100%;
    background: repeating-linear-gradient(
        45deg,
        #ffd93d,
        #ffd93d 10px,
        #ffed4e 10px,
        #ffed4e 20px
    );
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 13px;
}
