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

body {
    font-family: 'Quicksand', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 50%, #fecfef 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    transition: background 0.8s ease, opacity 0.5s ease;
}

/* Background color variations */
body.bg-1 {
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 50%, #fecfef 100%);
}

body.bg-2 {
    background: linear-gradient(135deg, #ffecd2 0%, #fcb69f 50%, #ff8a80 100%);
}

body.bg-3 {
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 50%, #ffc0cb 100%);
}

body.bg-4 {
    background: linear-gradient(135deg, #ffd1ff 0%, #ffe4e1 50%, #ffb6c1 100%);
}

body.bg-5 {
    background: linear-gradient(135deg, #ffeaa7 0%, #fab1a0 50%, #fd79a8 100%);
}

body.bg-6 {
    background: linear-gradient(135deg, #e17055 0%, #fdcb6e 50%, #fd79a8 100%);
}

body.fade-background {
    opacity: 0;
}

.container {
    width: 100%;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow-x: hidden;
    padding: 20px;
}

.section {
    display: none;
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.5s ease;
    margin: auto;
}

.section.active {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transform: scale(1);
}

/* Envelope Styles */
.envelope {
    position: relative;
    width: 400px;
    height: 280px;
    cursor: pointer;
    transition: transform 0.3s ease;
    margin-bottom: 20px;
    animation: bounce 0.8s ease-in-out 3;
}

.envelope:hover {
    transform: scale(1.05);
}

.envelope-body {
    width: 100%;
    height: 100%;
    background: rgb(231 76 60 / var(--tw-bg-opacity, 1));
    border: 3px solid #fff;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px rgba(231, 76, 60, 0.3);
    position: relative;
    z-index: 2;
}

.envelope-flap {
    position: absolute;
    bottom: -2px;
    left: -2px;
    right: -2px;
    height: 250px;
    background: transparent;
    border-radius: 20px 20px 10px 10px;
    transition: transform 0.8s ease;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    padding: 10px;
}

.envelope.opened .envelope-flap {
    transform: translateY(-100px);
}

.envelope.fully-opened .envelope-body {
    transform: translateY(80px);
    transition: transform 0.8s ease;
}

.envelope.fully-opened .envelope-flap {
    transform: translateY(-180px);
    transition: transform 0.8s ease;
}

.envelope-label {
    font-family: 'Quicksand', sans-serif;
    font-size: 24px;
    font-weight: bold;
    color: white;
    text-align: center;
}

/* Card Preview in Flap */
.card-preview {
    background: white;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="hearts-preview" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="1" fill="%23ff6b9d" opacity="0.1"/><path d="M10,15 C7,12 2,8 2,5 C2,3 4,1 6,1 C8,1 10,3 10,5 C10,3 12,1 14,1 C16,1 18,3 18,5 C18,8 13,12 10,15 Z" fill="%23ff6b9d" opacity="0.05" transform="scale(0.3) translate(15,15)"/></pattern></defs><rect width="100" height="100" fill="url(%23hearts-preview)"/></svg>');
    background-size: 60px 60px;
    border-radius: 20px;
    padding: 20px;
    margin: 25px 20px;
    box-shadow: 0 8px 25px rgba(255, 107, 157, 0.2);
    transform: scale(1) rotate(-5deg);
    opacity: 0.95;
    transition: all 0.8s ease;
    height: 200px;
    max-width: calc(100% - 40px);
}

.envelope.opened .card-preview {
    transform: scale(1) rotate(-5deg);
}

.envelope.fully-opened .card-preview {
    transform: scale(1) rotate(-5deg);
}

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

@keyframes gameCardZoomIn {
    0% {
        transform: scale(0.3) rotate(-5deg);
        opacity: 0;
    }
    50% {
        transform: scale(1.1) rotate(-5deg);
        opacity: 0.8;
    }
    100% {
        transform: scale(1) rotate(-5deg);
        opacity: 1;
    }
}

.preview-question {
    font-family: 'Quicksand', sans-serif;
    font-size: 16px;
    color: #ff6b9d;
    font-weight: bold;
    margin-bottom: 15px;
    text-align: center;
}

.preview-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.preview-btn {
    font-family: 'Quicksand', sans-serif;
    padding: 8px 16px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: bold;
    color: white;
    text-align: center;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15);
}

.vikas-preview {
    background: linear-gradient(45deg, rgb(59 130 246), rgb(37 99 235));
}

.anju-preview {
    background: linear-gradient(45deg, rgb(231 76 60), rgb(220 38 38));
}

/* Question Section Styles */
.question-card {
    background: white;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="hearts-question" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="1" fill="%23ff6b9d" opacity="0.1"/><path d="M10,15 C7,12 2,8 2,5 C2,3 4,1 6,1 C8,1 10,3 10,5 C10,3 12,1 14,1 C16,1 18,3 18,5 C18,8 13,12 10,15 Z" fill="%23ff6b9d" opacity="0.05" transform="scale(0.3) translate(15,15)"/></pattern></defs><rect width="100" height="100" fill="url(%23hearts-question)"/></svg>');
    background-size: 60px 60px;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(255, 107, 157, 0.3);
    text-align: center;
    max-width: 600px;
    width: 320px;
    animation: gameCardZoomIn 0.8s ease-out;
    transform: rotate(-5deg);
    margin: 30px;
}

.question-card h2 {
    font-family: 'Quicksand', sans-serif;
    font-size: 28px;
    color: #ff6b9d;
    margin-bottom: 30px;
}

.buttons-container {
    position: relative;
    height: 400px;
    width: 100%;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="hearts" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="1" fill="%23ff6b9d" opacity="0.1"/><path d="M10,15 C7,12 2,8 2,5 C2,3 4,1 6,1 C8,1 10,3 10,5 C10,3 12,1 14,1 C16,1 18,3 18,5 C18,8 13,12 10,15 Z" fill="%23ff6b9d" opacity="0.05" transform="scale(0.3) translate(15,15)"/></pattern></defs><rect width="100" height="100" fill="url(%23hearts)"/></svg>');
    background-size: 60px 60px;
    border-radius: 15px;
    background-color: rgba(255, 255, 255, 0.02);
}

.choice-btn {
    font-family: 'Quicksand', sans-serif;
    position: absolute;
    padding: 15px 30px;
    font-size: 18px;
    font-weight: bold;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.vikas-btn {
    background: linear-gradient(45deg, rgb(59 130 246), rgb(37 99 235));
    color: white;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}

.anju-btn {
    background: linear-gradient(45deg, rgb(231 76 60), rgb(220 38 38));
    color: white;
    left: 50%;
    top: 80%;
    transform: translate(-50%, -50%);
    transition: all 0.5s ease, opacity 0.3s ease;
}

.choice-btn:hover {
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.anju-btn.moving {
    transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Final Section Styles */
#final-section {
    overflow-y: auto;
    overflow-x: hidden;
    max-height: 100vh;
    padding: 20px 0;
    justify-content: flex-start !important;
}

.final-card {
    background: white;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="hearts-final" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="1" fill="%23ff6b9d" opacity="0.1"/><path d="M10,15 C7,12 2,8 2,5 C2,3 4,1 6,1 C8,1 10,3 10,5 C10,3 12,1 14,1 C16,1 18,3 18,5 C18,8 13,12 10,15 Z" fill="%23ff6b9d" opacity="0.05" transform="scale(0.3) translate(15,15)"/></pattern></defs><rect width="100" height="100" fill="url(%23hearts-final)"/></svg>');
    background-size: 60px 60px;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(255, 107, 157, 0.3);
    text-align: center;
    max-width: 500px;
    width: 90%;
    animation: fadeInUp 0.8s ease;
    transform: rotate(-5deg);
    margin: 30px auto;
    max-height: none;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px) rotate(-8deg);
    }
    to {
        opacity: 1;
        transform: translateY(0) rotate(-5deg);
    }
}

.final-card h1 {
    font-family: 'Quicksand', sans-serif;
    font-size: 32px;
    color: #ff6b9d;
    margin-bottom: 20px;
}

.love-message {
    font-family: 'Quicksand', sans-serif;
    font-size: 18px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 30px;
}

.gif-container {
    margin: 20px 0;
    width: 100%;
    height: auto;
}

.love-gif {
    width: 200px;
    height: 200px;
    border-radius: 15px;
    object-fit: cover;
    box-shadow: 0 10px 25px rgba(255, 107, 157, 0.3);
}

.restart-btn {
    font-family: 'Quicksand', sans-serif;
    background: linear-gradient(45deg, rgb(231 76 60), rgb(220 38 38));
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(231, 76, 60, 0.3);
}

.restart-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 157, 0.4);
}

/* Responsive Design */
@media (max-width: 768px) {
    body {
        align-items: flex-start;
        padding-top: 20px;
    }
    
    .container {
        align-items: flex-start;
        padding-top: 20px;
    }
    
    .envelope {
        width: 320px;
        height: 233px;
        animation: bounce 0.8s ease-in-out 3;
    }
    
    .envelope-flap {
        height: 250px;
    }
    
    .envelope-label {
        font-family: 'Quicksand', sans-serif;
        font-size: 20px;
    }
    
    .question-card, .final-card {
        padding: 30px 20px;
        margin: 20px auto;
    }
    
    .buttons-container {
        height: 300px;
    }
    
    .question-card h2 {
        font-family: 'Quicksand', sans-serif;
        font-size: 24px;
    }
    
    .final-card h1 {
        font-family: 'Quicksand', sans-serif;
        font-size: 28px;
    }
    
    .love-gif {
        width: 150px;
        height: 150px;
    }
    
    #final-section {
        padding: 10px 0;
        align-items: flex-start !important;
    }
    
    .final-card {
        margin: 10px auto 20px auto;
    }
}

/* Hearts Animation */
.hearts {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1000;
}

.heart {
    position: absolute;
    color: #ff6b9d;
    font-size: 20px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(-100px) rotate(360deg);
        opacity: 0;
    }
} 