:root {
    --hero-blue: #0066cc;
    --hero-red: #ff3333;
    --skin-color: #ffdbac;
    --villain-black: #333333;
}

body {
    font-family: 'Comic Sans MS', cursive;
    background-color: #f0f0f0;
    margin: 0;
    padding: 20px;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    background-color: white;
    padding: 20px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

header {
    text-align: center;
    margin-bottom: 20px;
}

h1 {
    color: var(--hero-blue);
    font-size: 3em;
    margin: 0;
    text-shadow: 2px 2px var(--hero-red);
}

.controls {
    margin-bottom: 20px;
    text-align: center;
}

button {
    font-family: 'Comic Sans MS', cursive;
    padding: 10px 20px;
    margin: 0 10px;
    font-size: 1.2em;
    cursor: pointer;
    background-color: var(--hero-blue);
    color: white;
    border: none;
    border-radius: 5px;
}

.comic-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px;
}

.panel {
    min-height: 300px;
    margin-bottom: 30px;
    position: relative;
    overflow: visible;
    border: 3px solid black;
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 
        5px 5px 15px rgba(0,0,0,0.2),
        inset 0 0 30px rgba(0,0,0,0.05);
    transform: perspective(1000px) rotateX(1deg);
    transition: transform 0.3s;
}

.panel:hover {
    transform: perspective(1000px) rotateX(1deg) translateY(-5px);
    box-shadow: 
        8px 8px 20px rgba(0,0,0,0.3),
        inset 0 0 30px rgba(0,0,0,0.05);
}

.scene {
    position: relative;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    padding: 20px;
    background: linear-gradient(to bottom, #87CEEB 0%, #87CEEB 60%, #90EE90 60%, #90EE90 100%);
    border-radius: 10px;
    overflow: hidden;
}

.character {
    position: relative;
    width: 100px;
    height: 200px;
    cursor: pointer;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    filter: drop-shadow(2px 2px 4px rgba(0,0,0,0.3));
}

.hero {
    left: 0;
    order: 1;
}

.villain {
    right: 0;
    order: 2;
}

.head {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--skin-color) 60%, #e0b088);
    border-radius: 50%;
    position: relative;
    box-shadow: 
        inset -3px -3px 10px rgba(0,0,0,0.2),
        2px 2px 4px rgba(0,0,0,0.1);
}

.eyes {
    position: relative;
    top: 20px;
    display: flex;
    justify-content: space-around;
    padding: 0 10px;
}

.eyes::before, .eyes::after {
    content: '';
    width: 12px;
    height: 8px;
    background: linear-gradient(to bottom, #000000, #222222);
    border-radius: 50% 50% 0 0;
    box-shadow: 
        inset 0 2px 2px rgba(255,255,255,0.4),
        0 1px 2px rgba(0,0,0,0.4);
    position: relative;
    animation: blink 4s infinite;
}

.eyes.evil::before, .eyes.evil::after {
    background: linear-gradient(to bottom, #ff0000, #aa0000);
    box-shadow: 
        0 0 5px #ff0000,
        0 0 10px rgba(255,0,0,0.5);
}

.cape {
    position: absolute;
    width: 60px;
    height: 120px;
    background: linear-gradient(45deg, #990000, var(--hero-red));
    left: -20px;
    top: 20px;
    z-index: -1;
    transform-origin: top center;
    animation: capeWave 3s ease-in-out infinite;
    box-shadow: 
        -3px 3px 5px rgba(0,0,0,0.3),
        inset 2px -2px 10px rgba(255,255,255,0.3);
    border-radius: 10px;
}

.body {
    width: 50px;
    height: 80px;
    background: linear-gradient(45deg, #004080, var(--hero-blue));
    margin-top: -10px;
    box-shadow: 
        -2px 2px 4px rgba(0,0,0,0.2),
        inset 2px -2px 10px rgba(255,255,255,0.2);
    border-radius: 8px;
}

.underwear {
    width: 50px;
    height: 30px;
    background: linear-gradient(to bottom, white, #f0f0f0);
    border: 2px solid var(--hero-blue);
    margin-top: -40px;
    box-shadow: 
        -1px 1px 3px rgba(0,0,0,0.2),
        inset 1px -1px 5px rgba(0,0,0,0.1);
    border-radius: 5px;
}

.villain-body {
    background-color: var(--villain-black);
}

.mustache {
    width: 40px;
    height: 10px;
    background-color: black;
    position: absolute;
    bottom: 15px;
    left: 10px;
}

.speech-bubble {
    background: linear-gradient(to bottom, #ffffff, #f8f8f8);
    border: 3px solid #000;
    border-radius: 20px;
    padding: 15px;
    box-shadow: 
        3px 3px 10px rgba(0,0,0,0.2),
        inset 0 0 20px rgba(0,0,0,0.05);
    position: relative;
}

.speech-bubble::before {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    background: linear-gradient(45deg, #ffffff, #f8f8f8);
    border-left: 3px solid #000;
    border-bottom: 3px solid #000;
    transform: rotate(45deg);
    left: -12px;
    top: 20px;
    box-shadow: inset 3px 3px 5px rgba(0,0,0,0.1);
}

.hero + .speech-bubble {
    left: 120px;
}

.villain + .speech-bubble {
    right: 120px;
}

.speech-bubble.evil {
    background: linear-gradient(to right, #ffeeee, #fff);
    font-style: italic;
    right: 150px;
    left: auto;
}

.sfx {
    position: absolute;
    font-size: 3em;
    font-weight: bold;
    color: var(--hero-red);
    transform: rotate(-15deg);
    top: 50%;
    left: 50%;
    text-shadow: 2px 2px black;
}

.story-panel {
    min-height: 400px;
    transition: all 0.3s ease;
    background: linear-gradient(to bottom, #ffffff, #f8f8f8);
}

.fight-scene {
    background: linear-gradient(45deg, #ff9999, #ffff99);
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 0 50px rgba(255,255,0,0.3);
}

.fight-scene::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    top: -50%;
    left: -50%;
    background: 
        radial-gradient(circle, transparent 30%, rgba(255,255,255,0.2) 32%, transparent 33%),
        radial-gradient(circle, transparent 30%, rgba(255,255,255,0.15) 32%, transparent 33%);
    background-size: 50px 50px;
    background-position: 0 0, 25px 25px;
    animation: backgroundMove 2s linear infinite;
}

.hero-title {
    font-size: 4em;
    color: var(--hero-blue);
    text-shadow: 3px 3px var(--hero-red),
                 5px 5px #000;
    animation: heroEntrance 1s ease-out;
}

@keyframes heroEntrance {
    from {
        transform: translateY(-100px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.story-intro {
    text-align: center;
    margin: 40px 0;
    padding: 20px;
    background: linear-gradient(to right, #fff, #f0f0f0, #fff);
    border-radius: 10px;
}

.character:hover {
    transform: scale(1.1);
    transition: transform 0.2s;
}

.character::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 25%;
    width: 50%;
    height: 10px;
    background: rgba(0,0,0,0.1);
    border-radius: 50%;
    filter: blur(3px);
}

.fight-scene .character {
    transform: scale(1.1);
    transition: transform 0.3s;
}

/* Add these styles for the cover page and logo */
.cover-page {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #0066cc, #ff3333, #0066cc);
    background-size: 200% 200%;
    animation: gradientBG 10s ease infinite;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.logo-container {
    margin-bottom: 40px;
}

.cc-logo {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 0 auto;
    filter: drop-shadow(0 0 10px rgba(255,255,255,0.3));
}

.outer-circle {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 4px solid white;
    border-radius: 50%;
    box-shadow: 
        0 0 20px rgba(255,255,255,0.5),
        inset 0 0 20px rgba(255,255,255,0.3);
}

.inner-circle {
    position: absolute;
    width: 80%;
    height: 80%;
    border: 4px solid white;
    border-radius: 50%;
    top: 10%;
    left: 10%;
}

.spikes {
    position: absolute;
    width: 100%;
    height: 100%;
}

.spikes::before {
    content: '';
    position: absolute;
    width: 120%;
    height: 120%;
    top: -10%;
    left: -10%;
    background: repeating-conic-gradient(
        from 0deg,
        transparent 0deg 15deg,
        rgba(255,255,255,0.9) 15deg 20deg
    );
    filter: drop-shadow(0 0 5px rgba(255,255,255,0.5));
    mask: radial-gradient(
        transparent 65%,
        black 65% 75%
    );
    -webkit-mask: radial-gradient(
        transparent 65%,
        black 65% 75%
    );
}

.cc-logo span {
    position: absolute;
    width: 100%;
    text-align: center;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 48px;
    font-weight: bold;
    font-family: 'Comic Sans MS', cursive;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.cover-title {
    font-size: 72px;
    color: white;
    text-shadow: 4px 4px 0 #000;
    margin: 20px 0;
}

.cover-subtitle {
    font-size: 36px;
    color: white;
    text-shadow: 2px 2px 0 #000;
    margin: 10px 0;
}

.cover-credit {
    font-size: 24px;
    color: white;
    margin: 20px 0;
}

.start-button {
    font-size: 24px;
    padding: 15px 30px;
    background: white;
    color: #0066cc;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    margin-top: 40px;
    transition: transform 0.2s;
}

.start-button:hover {
    transform: scale(1.1);
}

/* New animations */
@keyframes backgroundMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

@keyframes capeWave {
    0% { transform: rotate(5deg) skewX(2deg); }
    50% { transform: rotate(-5deg) skewX(-2deg); }
    100% { transform: rotate(5deg) skewX(2deg); }
}

@keyframes blink {
    0%, 48%, 52%, 100% { transform: scaleY(1); }
    50% { transform: scaleY(0.1); }
}

.comic-name {
    position: absolute;
    top: 20px;
    width: 100%;
    text-align: center;
    font-family: 'Comic Sans MS', cursive;
    color: white;
    text-shadow: 
        2px 2px 0 #000,
        -2px -2px 0 #000,
        2px -2px 0 #000,
        -2px 2px 0 #000,
        0 0 20px rgba(255,255,255,0.5);
    font-size: 24px;
    letter-spacing: 2px;
    transform: rotate(-5deg);
    animation: floatText 3s ease-in-out infinite;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

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

/* City background for urban scenes */
.scene.city-scene::before {
    content: '';
    position: absolute;
    bottom: 20%;
    left: 0;
    right: 0;
    height: 40%;
    background: 
        linear-gradient(to bottom, transparent, rgba(0,0,0,0.1)),
        repeating-linear-gradient(
            to right,
            #666 0px,
            #666 40px,
            #888 40px,
            #888 80px
        );
    z-index: 1;
}

/* Buildings */
.buildings {
    position: absolute;
    bottom: 20%;
    left: 0;
    right: 0;
    height: 60%;
    background:
        linear-gradient(to bottom, rgba(0,0,0,0.2), transparent),
        repeating-linear-gradient(
            to right,
            #444 0px,
            #444 100px,
            #555 100px,
            #555 200px
        );
    z-index: 1;
}

/* Props */
.laundry-basket {
    position: absolute;
    bottom: 10%;
    width: 60px;
    height: 40px;
    background: linear-gradient(45deg, #ff9966, #ff6666);
    border-radius: 5px;
    box-shadow: inset -2px -2px 5px rgba(0,0,0,0.2);
    z-index: 2;
}

.laundry-basket::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 5px;
    right: 5px;
    height: 15px;
    background: repeating-linear-gradient(
        90deg,
        white 0px,
        white 10px,
        #eee 10px,
        #eee 20px
    );
    border-radius: 2px;
    transform: rotate(-2deg);
}

.washing-machine {
    position: absolute;
    bottom: 10%;
    right: 10%;
    width: 80px;
    height: 100px;
    background: linear-gradient(to bottom, #fff, #eee);
    border-radius: 10px;
    box-shadow: 
        -2px 2px 5px rgba(0,0,0,0.2),
        inset 2px -2px 10px rgba(0,0,0,0.1);
}

.washing-machine::before {
    content: '';
    position: absolute;
    top: 20%;
    left: 20%;
    width: 60%;
    height: 60%;
    border-radius: 50%;
    background: linear-gradient(45deg, #ccc, #fff);
    border: 3px solid #999;
}

/* Add clouds */
.cloud {
    position: absolute;
    background: white;
    border-radius: 20px;
    opacity: 0.9;
    animation: floatCloud 20s linear infinite;
}

.cloud::before,
.cloud::after {
    content: '';
    position: absolute;
    background: white;
    border-radius: 50%;
}

.cloud.small {
    width: 60px;
    height: 20px;
    top: 20%;
}

.cloud.large {
    width: 100px;
    height: 30px;
    top: 10%;
}

/* Add environmental effects */
.scene.indoor-scene {
    background: linear-gradient(to bottom, #f5f5f5, #e0e0e0);
}

.scene.indoor-scene::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 40%;
    background: 
        linear-gradient(45deg, #ddd 25%, transparent 25%),
        linear-gradient(-45deg, #ddd 25%, transparent 25%);
    background-size: 20px 20px;
    opacity: 0.5;
}

/* Add animations */
@keyframes floatCloud {
    from { transform: translateX(-100%); }
    to { transform: translateX(100vw); }
}

/* Enhanced visual effects */
.sky {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 70%;
    transition: all 0.5s ease;
}

.sky.day {
    background: linear-gradient(to bottom, #87CEEB, #b4e4ff);
}

.sky.night {
    background: linear-gradient(to bottom, #1a1a2e, #4a4a6e);
}

.sun {
    position: absolute;
    width: 60px;
    height: 60px;
    background: radial-gradient(circle, #fff176, #ffd700);
    border-radius: 50%;
    box-shadow: 0 0 50px #ffd700;
    animation: sunMove 20s linear infinite;
}

.building {
    position: absolute;
    bottom: 0;
    width: 15%;
    background: linear-gradient(to right, #444, #666);
    box-shadow: -2px 0 5px rgba(0,0,0,0.3);
}

.building::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        to bottom,
        transparent 0%,
        transparent 10%,
        rgba(255,255,255,0.1) 10%,
        rgba(255,255,255,0.1) 12%
    );
}

.laundromat-interior {
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, #f5f5f5, #e0e0e0);
    perspective: 1000px;
}

.floor-tiles {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 40%;
    background: repeating-linear-gradient(
        45deg,
        #ddd 0px,
        #ddd 20px,
        #ccc 20px,
        #ccc 40px
    );
    transform: rotateX(60deg);
    transform-origin: bottom;
}

.ceiling-lights {
    position: absolute;
    top: 10%;
    width: 100%;
    height: 10px;
    background: repeating-linear-gradient(
        to right,
        transparent 0%,
        transparent 45%,
        rgba(255,255,255,0.9) 45%,
        rgba(255,255,255,0.9) 55%,
        transparent 55%,
        transparent 100%
    );
    filter: blur(2px);
}

/* Enhanced animations */
@keyframes sunMove {
    from { transform: translateX(-20%) translateY(100%); }
    50% { transform: translateX(60%) translateY(0); }
    to { transform: translateX(120%) translateY(100%); }
}

.action-lines {
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        45deg,
        transparent 0,
        transparent 10px,
        rgba(255,255,0,0.1) 10px,
        rgba(255,255,0,0.1) 20px
    );
    animation: actionLinesMove 0.5s linear infinite;
}

.impact-stars {
    position: absolute;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 30% 40%, yellow 0%, transparent 10%),
        radial-gradient(circle at 70% 60%, yellow 0%, transparent 10%),
        radial-gradient(circle at 40% 80%, yellow 0%, transparent 10%);
    animation: starsTwinkle 0.3s ease infinite alternate;
}

/* Add realistic shadows and lighting */
.character::before {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 20px;
    background: radial-gradient(ellipse, rgba(0,0,0,0.3), transparent 70%);
    filter: blur(3px);
} 