@import url('https://fonts.googleapis.com/css2?family=Great+Vibes&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Bellota:ital,wght@0,300;0,400;0,700;1,300;1,400;1,700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Bellota", system-ui;
    line-height: 1.5;
    font-weight: 700;
    background-color: #f1ede8;
    color: #4a4a4a;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.background-decor {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
}

.decor {
    position: absolute;
    opacity: 0.25;
    max-width: 200px;
}

.decor-1 {
    top: 10%;
    left: 5%;
}

.decor-2 {
    bottom: 15%;
    right: 8%;
}

.decor-3 {
    top: 50%;
    right: 0;
}

.title {
    text-align: center;
    margin-bottom: 40px;
    height: 50vh;
    margin: 50px;
    margin-bottom: 100px;
    color: #5f7a63;
}

.title h1 {
    font-size: clamp(64px, 10vw, 72px);
    text-align: center;
    display: inline-block;
    margin: 0px;
    font-family: "Great Vibes", cursive;
}

.dot {
    font-size: clamp(64px, 10vw, 72px);
    margin-top: -60px;
    margin-bottom: -20px;
    font-family: "Great Vibes", cursive;

}

.info-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.info-block {
    padding-top: 50px;
    margin: 0 auto;
    width: 100%;
    max-width: 500px;
    text-align: center;
}

.info-block__title {
    margin-bottom: 8px;
    color: #5f7a63;
    font-size: clamp(28px, 4vw, 38px);
    font-family: "Great Vibes", cursive;
}

.info-block__content button {
    border-radius: 50px;
    border: 2px;
    border-color: #e0ccb1;
    border-style: solid;
    background-color: transparent;
    box-shadow: 0 2px 10px 0 rgba(0,0,0,0.55);
    font-family: "Bellota", system-ui;
    color: #56564c;
    font-size: clamp(16px, 2.5vw, 22px);
    min-width: 300px;
    padding: 10px 15px;
    transition: 0.5s;
    margin-bottom: 20px;
}

.info-block__content button:hover {
    cursor: pointer;
    transform: translate(0,-3px);
    box-shadow: 0 5px 15px 0 rgba(0,0,0,0.55);
}

.info-block__content p {
    font-size: clamp(16px, 2.5vw, 22px);
    color: #56564c;
}

.info-block__content a {
    transition: 0.5s;
    color: #56564c;
    font-size: clamp(16px, 2.5vw, 22px);
}

.info-block__content a:hover {
    color: #5f7a63;
}

.schedule-row {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 20px;
    margin-bottom: 12px;
    align-items: center;
    font-size: clamp(16px, 2.5vw, 22px);
}

.schedule-time {
    text-align: right;
}

.schedule-event {
    text-align: left;
}

.envelope-section {
    padding-top: 200px;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background: transparent;
}

.envelope {
    width: 100%;
    max-width: 500px;
    aspect-ratio: 500 / 376;
    position: relative;
    margin: 0 auto;
    transform-style: preserve-3d;
}

.envelope__back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('envelope_bg.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    z-index: 1;
    pointer-events: none;
}

.envelope__body {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('envelope_body.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    z-index: 4;
    pointer-events: none;
}
.envelope__flap {
    position: absolute;
    left: 0;
    top: 1px;
    width: 100%;
    height: 100%;
    background-image: url('envelope_flap.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    transform: rotateX(0deg);
    transform-origin: top;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 5;
    pointer-events: none;
    backface-visibility: visible;
}

.envelope__flap.open {
    transform: rotateX(180deg);
    z-index: 1;
}

.envelope__letter {
    width: 90%;
    max-width: 450px;
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%) translateY(calc(100% - 40px));
    transition: transform 1.0s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 2;
    filter: drop-shadow(0 5px 10px rgba(0,0,0,0.2));
}

.envelope__letter.visible {
    transform: translateX(-50%) translateY(-80px);
    z-index: 3;
}

.letter-card {
    width: 100%;
    background: white;
    border-radius: 15px 15px 8px 8px;
    padding: 30px 25px;
    box-sizing: border-box;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
    border: 1px solid #f0f0f0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
}

.letter-card h2 {
    color: #5f7a63;
    margin: 15px 0 10px;
    font-family: "Great Vibes", cursive;
    font-size: clamp(28px, 4vw, 38px);
}

.letter-card p {
    color: #56564c;
    font-size: clamp(16px, 2.5vw, 22px);
    line-height: 1.7;
    margin: 8px 0;
}

.letter-empty {
    height: 120px;
}

.heart {
    font-size: 45px;
    color: #ff6b6b;
    animation: pulse 1.5s ease infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.line {
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, #e0ccb1, transparent);
    margin: 15px 0;
}

.empty {
    height: 100px;
}

iframe {
    width: 100%;
    max-width: 500px;
    height: auto;
    aspect-ratio: 16/9;
    display: block;
    margin: 10px 0;
}

@media (min-width: 560px) {
    .container {
        padding: 15px;
    }

    .info-block {
        margin-bottom: 15px;
    }

    .title h1,
    .dot {
        font-size: clamp(64px, 10vw, 72px);
    }

    .envelope__letter {
        width: 95%;
    }

    .envelope__letter.visible {
        transform: translateX(-50%) translateY(-180px);
        z-index: 3;
    }

    .schedule-row {
        grid-template-columns: 200px 1fr;
    }
}