@font-face {
    font-family: 'Satoshi';
    src: url('font.otf') format('opentype');
    font-weight: bold;
    font-style: normal;
}

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

body {
    font-family: 'Satoshi', 'Arial', sans-serif;
    background: linear-gradient(-45deg, #ff69b4, #ff1493, #db7093, #ffc0cb);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    height: 100vh;
    overflow: hidden;
}

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

.container {
    position: relative;
    width: 100%;
    height: 100vh;
}

.page {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.page.active {
    opacity: 1;
    transform: translateX(0);
}

.page.exit-left {
    opacity: 0;
    transform: translateX(-100%);
}

/* PAGE 1: LOVE WELCOME */
.floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.floating-heart {
    position: absolute;
    object-fit: contain;
    pointer-events: none;
    filter: drop-shadow(0 0 10px rgba(255, 20, 147, 0.4));
    opacity: 0;
}

.floating-flower {
    position: absolute;
    width: 50px;
    height: 50px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(255, 105, 180, 0.4));
    pointer-events: none;
}

@keyframes heartSpawn {
    0% { 
        opacity: 0; 
        transform: scale(0) rotate(0deg); 
    }
    20% { 
        opacity: 0.6; 
        transform: scale(1) rotate(10deg); 
    }
    80% { 
        opacity: 0.6; 
        transform: scale(1) rotate(-10deg); 
    }
    100% { 
        opacity: 0; 
        transform: scale(0) rotate(20deg); 
    }
}

@keyframes heartFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    25% { transform: translateY(-15px) rotate(5deg); }
    50% { transform: translateY(-10px) rotate(-5deg); }
    75% { transform: translateY(-20px) rotate(3deg); }
}

.love-messages {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
}

.love-message {
    position: absolute;
    color: white;
    font-size: 1.2rem;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    animation: loveMessageFloat 6s ease-in-out infinite;
    animation-delay: var(--delay);
    left: var(--x);
    top: var(--y);
    opacity: 0;
}

@keyframes loveMessageFloat {
    0%, 100% { opacity: 0; transform: translateY(0); }
    20%, 80% { opacity: 1; transform: translateY(-20px); }
}

.main-heart {
    z-index: 3;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 2rem;
}

.heart-image {
    width: 450px;
    height: 450px;
    object-fit: contain;
    animation: heartBeat 1.5s ease-in-out infinite;
    filter: drop-shadow(0 0 20px rgba(255, 20, 147, 0.6));
}

.heart-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 2.5rem;
    font-weight: bold;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.8);
    z-index: 4;
    text-align: center;
}

@keyframes heartBeat {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* PAGE 2: VIDEO PAGE */
.video-page {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.video-container {
    background: rgba(0, 0, 0, 0.8);
    border-radius: 20px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.main-video {
    width: 100%;
    max-width: 800px;
    height: auto;
    border-radius: 15px;
    filter: grayscale(100%) contrast(1.2);
}

/* PAGE 2: REASONS PAGE - STAR WARS STYLE */
.reasons-page {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem;
    position: relative;
}

.reasons-title-container {
    margin-bottom: 2rem;
    text-align: center;
    z-index: 10;
    position: relative;
}

.reasons-title {
    background: linear-gradient(45deg, #ff1493, #ff69b4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.reasons-title-image {
    width: 700px;
    height: 200px;
    object-fit: contain;
    filter: drop-shadow(0 0 20px rgba(255, 20, 147, 0.6));
    animation: heartBeat 1.5s ease-in-out infinite;
}

.star-wars-container {
    flex: 1;
    width: 100%;
    height: 60vh;
    overflow-y: auto;
    position: relative;
    padding: 2rem;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* Internet Explorer 10+ */
    scroll-behavior: smooth;
}

.star-wars-container::-webkit-scrollbar { /* WebKit */
    width: 0;
    height: 0;
}

.star-wars-crawl {
    position: relative;
    width: 100%;
    padding-bottom: 12rem;
}

.crawl-reason {
    color: white;
    font-size: 2rem;
    line-height: 2.2;
    margin-bottom: 1.5rem;
    padding: 1rem;
    text-align: center;
    text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.8);
    font-weight: bold;
    opacity: 1;
}

@keyframes fadeInStay {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* PAGE 2: BEAR GAME PAGE */
.bear-game-page {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 2rem;
}

.game-title-container {
    position: absolute;
    top: 5%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.game-title-image {
    max-width: 700px;
    height: auto;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.3));
}

.bears-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 800px;
    padding: 0 4rem;
}

.boy-bear-container, .girl-bear-container {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.boy-bear, .girl-bear {
    width: 200px;
    height: 200px;
    object-fit: contain;
    filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.3));
    transition: transform 0.3s ease, filter 0.3s ease;
}

.girl-bear {
    cursor: grab;
    animation: floatBear 3s ease-in-out infinite;
}

.girl-bear:active {
    cursor: grabbing;
}

.girl-bear.dragging {
    transform: scale(1.1);
    filter: drop-shadow(0 10px 25px rgba(255, 105, 180, 0.5));
    z-index: 1000;
}

.boy-bear.drop-target {
    animation: bounceTarget 0.5s ease-in-out infinite;
    filter: drop-shadow(0 10px 25px rgba(70, 130, 255, 0.5));
}

.hugging-bears {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 5;
}

.hugging-image {
    width: 200px;
    height: 200px;
    object-fit: contain;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.3));
    animation: heartPulse 1.5s ease-in-out infinite;
}

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

@keyframes bounceTarget {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes heartPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

/* Bottom image styling for bear game */
.bear-game-bottom-image {
    position: absolute;
    bottom: 15%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.bottom-image {
    width: 300px;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.3));
}

/* Button styling for bear game */
#bearGameNextBtn {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

/* PAGE 3: LOVE LETTER PAGE */
.love-letter-page {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.letter-title-container {
    position: absolute;
    top: 5%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.letter-title-image {
    max-width: 400px;
    height: auto;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.3));
}

.letter-text-space {
    width: 60%;
    max-width: 600px;
    height: 60%;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 2rem;
    margin-top: 6rem;
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    position: relative;
    z-index: 5;
    overflow-y: auto;
    border: 3px solid rgba(255, 105, 180, 0.3);
    font-size: 1.1rem;
    line-height: 1.6;
    color: #333;
    font-family: 'Satoshi', Georgia, serif;
    text-align: left;
}

.letter-decorations {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.decoration-image {
    position: absolute;
    width: 80px;
    height: 80px;
    object-fit: contain;
    filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.2));
    transition: transform 0.3s ease;
    opacity: 0.4;
}

.decoration-image:hover {
    transform: scale(1.1);
}

/* Button styling for love letter page */
#letterNextBtn {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    margin: 0;
}

/* PAGE 5: ANNIVERSARY PAGE */
.anniversary-page {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.anniversary-container {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.anniversary-heart-image {
    width: 500px;
    height: 500px;
    object-fit: contain;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.3));
}

.anniversary-text-below {
    text-align: center;
    margin-bottom: 1rem;
}

.time-together {
    font-size: 3.5rem;
    font-weight: bold;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    white-space: nowrap;
}

/* PAGE 6: MARRIAGE GAME PAGE */
.marriage-game-page {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.proposal-screen, .happy-screen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.proposal-image-container, .happy-image-container {
    margin-bottom: 3rem;
}

.proposal-center-image {
    width: 400px;
    height: 400px;
    object-fit: contain;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.3));
}

.happy-center-image {
    width: 600px;
    height: 600px;
    object-fit: contain;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.3));
}

.proposal-buttons {
    display: flex;
    gap: 3rem;
    align-items: center;
}

.proposal-button-image {
    width: 200px;
    height: auto;
    cursor: pointer;
    transition: transform 0.3s ease, filter 0.3s ease;
    filter: drop-shadow(0 4px 15px rgba(0, 0, 0, 0.2));
}

.proposal-button-image:hover {
    transform: translateY(-2px) scale(1.05);
    filter: drop-shadow(0 6px 20px rgba(0, 0, 0, 0.3));
}

.proposal-button-image:active {
    transform: translateY(0) scale(0.95);
}

.yes-button:hover {
    filter: drop-shadow(0 8px 25px rgba(255, 20, 147, 0.4));
}

.no-button:hover {
    filter: drop-shadow(0 8px 25px rgba(255, 0, 0, 0.4));
}

.no-button.avoid-hover {
    position: absolute;
    transition: all 0.3s ease;
}

.no-button.avoid-hover:hover {
    filter: drop-shadow(0 8px 25px rgba(255, 0, 0, 0.6));
}

.content {
    text-align: center;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    max-width: 600px;
    width: 90%;
}

h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: white;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: white;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

/* Image button styling */
.button-image {
    cursor: pointer;
    transition: transform 0.3s ease, filter 0.3s ease;
    filter: drop-shadow(0 4px 15px rgba(0, 0, 0, 0.2));
    position: relative;
    z-index: 1000;
    max-width: 200px;
    height: auto;
}

.button-image:hover {
    transform: translateY(-2px) scale(1.05);
    filter: drop-shadow(0 6px 20px rgba(0, 0, 0, 0.3));
}

.button-image:active {
    transform: translateY(0) scale(0.95);
}

.animated-element {
    font-size: 4rem;
    margin: 1rem 0;
}

.feature-list {
    list-style: none;
    margin: 2rem 0;
}

.feature-list li {
    font-size: 1.3rem;
    margin: 0.8rem 0;
    color: white;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.gallery {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin: 2rem 0;
}

.gallery-item {
    font-size: 4rem;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 1rem;
    backdrop-filter: blur(5px);
}

@keyframes welcome-text {
    0% { transform: scale(0); opacity: 0; }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

.welcome-text {
    animation: welcome-text 1s ease-out;
}

@keyframes cute-message {
    0% { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

.cute-message {
    animation: cute-message 1s ease-out 0.5s both;
}

@keyframes slide-in {
    0% { transform: translateX(-50px); opacity: 0; }
    100% { transform: translateX(0); opacity: 1; }
}

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

@keyframes fade-in {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

.fade-in {
    animation: fade-in 1s ease-out 0.3s both;
}

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

.bounce {
    animation: bounce 2s infinite;
}

@keyframes rotate-in {
    0% { transform: rotate(-180deg) scale(0); opacity: 0; }
    100% { transform: rotate(0) scale(1); opacity: 1; }
}

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

@keyframes pop-in {
    0% { transform: scale(0); opacity: 0; }
    80% { transform: scale(1.1); }
    100% { transform: scale(1); opacity: 1; }
}

.pop-in {
    animation: pop-in 0.6s ease-out both;
}

@keyframes zoom-in {
    0% { transform: scale(0); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

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

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

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

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.pulse {
    animation: pulse 2s ease-in-out infinite;
}

@keyframes heart-beat {
    0% { transform: scale(1); }
    14% { transform: scale(1.1); }
    28% { transform: scale(1); }
    42% { transform: scale(1.1); }
    70% { transform: scale(1); }
}

.heart-beat {
    animation: heart-beat 1.5s ease-in-out infinite;
}

@media (max-width: 768px) {
    h1 { font-size: 2rem; }
    p { font-size: 1rem; }
    .content { padding: 1.5rem; }
    .gallery { flex-direction: column; align-items: center; }
}