/* Reset and global styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body, html {
    width: 100%;
    height: 100%;
    font-family: 'Aubrey', sans-serif;
    background: linear-gradient(to bottom right, #6fcde5, #b284be);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    opacity: 1;
    transition: opacity 1s ease;
}

/* Fade-out animation */
@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

.fade-out {
    animation: fadeOut 1s forwards;
}

/* Envelope styling */
.envelope {
    position: relative;
    width: 300px;
    height: 200px;
}

/* White envelope body with shadow effect */
.envelope-body {
    width: 100%;
    height: 100%;
    background-color: #6fcde5; /* Blue flap color */    
    border-radius: 10px;
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2); /* Shadow under the white body */
    z-index: 1;
}

/* Flap styling */
.envelope-flap {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background-color: #b284be; /* White body color */
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    transform-origin: top;
    transition: transform 0.8s ease;
    z-index: 2;
}

.envelope.open .envelope-flap {
    transform: rotateX(-180deg);
}

/* Seal button styling */
.seal-button {
    position: absolute;
    top: 60px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px; /* Adjust as needed */
    height: 100px;
    background-color: #fff; /* Background color for the seal */
    border-radius: 50%; /* Circular shape */
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
    z-index: 3;
}

/* Image inside the seal button */
.seal-button img {
    width: 70%; /* Make image smaller than button to show background color */
    height: 70%;
    border-radius: 50%;
    object-fit: cover;
}

/* Hide seal button and flap when opening */
.envelope.open .seal-button {
    opacity: 0;
    transition: opacity 0.4s ease;
}
