/* Tokens */
:root {
    --template-5-primary: rgba(78, 100, 55, 1);
    --template-5-primary-rgb: 78, 100, 55;
    --template-5-deep: rgba(49, 80, 14, 0.85);
    --template-5-deep-rgb: 49, 80, 14;
    --template-5-dark: #26321c;
    --template-5-dark-rgb: 38, 50, 28;
    --template-5-story-dark: #27321c;
    --template-5-lovestory-background: var(--template-5-story-dark);
    --template-5-lovestory-text: #fff;
    --template-5-muted: #65705c;
    --template-5-soft: #b8c6a6;
    --template-5-soft-rgb: 184, 198, 166;
    --template-5-soft-light: #dce5d3;
    --template-5-mid: #aab99a;
    --template-5-darkest: #1e2817;
    --template-5-secondary-dark: #334126;
    --template-5-overlay-rgb: 20, 45, 21;
    --template-5-cream: #f3f6ee;
    --template-5-cream-card: #f8faf5;
    --template-5-cream-soft: #f6f8f2;
    --env-green: var(--template-5-primary);
    --env-green-dark: var(--template-5-dark);
    --env-cream: var(--template-5-cream);
    --env-cream-card: var(--template-5-cream-card);
    --env-gold: rgba(var(--template-5-deep-rgb), 0.85);
    --env-gold-light: var(--template-5-primary);
    --env-text-dark: var(--template-5-dark);
    --env-text-mid: var(--template-5-muted);
}

/* Scene wrapper */
#envelope-scene {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: opacity 0.85s ease, transform 0.85s ease;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.65), rgba(255, 255, 255, 0.65)),
        url('../images/template-3/bg-frame.webp');
}

#envelope-scene.template-5-envelope--orange {
    --template-5-primary: rgba(150, 105, 5, 1);
    --template-5-primary-rgb: 150, 105, 5;
    --template-5-deep: rgba(121, 83, 4, 0.85);
    --template-5-deep-rgb: 121, 83, 4;
    --template-5-dark: #4b3503;
    --template-5-dark-rgb: 75, 53, 3;
    --template-5-muted: #806f49;
    --template-5-soft: #dfc98f;
    --template-5-soft-rgb: 223, 201, 143;
    --template-5-soft-light: #f0e4c5;
    --template-5-darkest: #352502;
    --template-5-secondary-dark: #604803;
    --template-5-cream: #fff8ed;
    --template-5-cream-card: #fffbf5;
    --template-5-cream-soft: #fff6e8;
}

#envelope-scene.hidden {
    opacity: 0;
    pointer-events: none;
}

#envelope-scene.is-opening {
    pointer-events: none;
}

body {
    --olive-dark: rgba(var(--template-5-deep-rgb), 0.85);
    background: var(--body-bg);
    background-image:
        radial-gradient(ellipse 80% 50% at 50% -20%, rgba(var(--template-5-primary-rgb), 0.08) 0%, transparent 70%);
    font-family: 'Lato', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    overflow-x: hidden;
}

/* Keep the invitation layout stretched to the viewport inside the flex body. */
.ws-template-demo-preview__shell,
#ws-demo-mount,
.ws-thiep-cuoi-single__shell,
#ws-thiep-cuoi-mount,
#ws-route-content,
#primary {
    width: 100%;
    min-width: 0;
}

/* ===================== ENVELOPE SCENE ===================== */
#envelope-scene.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* ===================== INVITATION CONTENT ===================== */
#invitation-content {
    display: none;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    opacity: 0;
    overflow: hidden;
    transition: opacity 0.8s ease, padding-top 0.8s ease;
    box-sizing: border-box;
    border-left: 1px solid rgba(var(--template-5-primary-rgb), 0.25);
    border-right: 1px solid rgba(var(--template-5-primary-rgb), 0.25);
    box-shadow:
        0 0 0 1px rgba(var(--template-5-primary-rgb), 0.10),
        0 40px 80px rgba(0, 0, 0, 0.6);
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.65), rgba(255, 255, 255, 0.65)),
        url('../images/template-3/bg-frame.webp');
}

@media (max-width: 786px) {
    #invitation-content {
        border-left: none;
        border-right: none;
        box-shadow: none;
    }
}

#invitation-content.visible {
    opacity: 1;
    padding-top: 0;
}

.template-5-content {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    box-sizing: border-box;
}


.ws-section {
    padding-inline: clamp(20px, 2.46vw + 9.7px, 29px);
    padding-block: 38px;
}

.last-section {
    padding-bottom: 76px;
}

.section-title {
    color: var(--template-5-primary);
    text-align: center;
    font-family: "Great Vibes";
    font-size: 40px;
    font-style: normal;
    font-weight: 400;
    line-height: 60px;
    /* 150% */
}

/* ===================== AOS ===================== */
[data-aos] {
    pointer-events: none;
}

[data-aos].aos-animate {
    pointer-events: auto;
}

/* ===================== AOS ===================== */
[data-aos] {
    pointer-events: none;
}

[data-aos].aos-animate {
    pointer-events: auto;
}

/* Envelop scene */
#envelope-scene {
    --env-envelope-width: min(100vw, 500px);
    --env-top-height: clamp(250px, 40vh, 383px);
    --env-top-height: clamp(250px, 40svh, 383px);
    --env-center-height: 112px;
    --env-opening-duration: 2200ms;
    --env-backdrop-duration: 1500ms;
    cursor: pointer;
    outline: none;
    perspective: 1600px;
    transform-style: preserve-3d;
}

#envelope-scene:focus-visible .env-bottom {
    box-shadow:
        0 0 0 3px var(--template-5-soft-light),
        0 30px 90px rgba(0, 0, 0, 0.38);
}

#envelope-scene.ws-envelope-backdrop-ready {
    isolation: isolate;
    background-color: transparent !important;
    background-image: none !important;
}

#envelope-scene.ws-envelope-backdrop-ready::before {
    position: absolute;
    inset: 0;
    z-index: 0;
    content: '';
    pointer-events: none;
    background-color: var(--env-scene-background-color, transparent);
    background-image: var(--env-scene-background-image, none);
    background-position: var(--env-scene-background-position, center);
    background-size: var(--env-scene-background-size, auto);
    background-repeat: var(--env-scene-background-repeat, repeat);
}

.env-top-clip {
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    width: var(--env-envelope-width);
    height: 100%;
    margin-inline: auto;
    overflow: hidden;
    z-index: 2;
    perspective: 1400px;
}

.env-top {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: var(--env-top-height);
    opacity: 1;
    visibility: visible;
    transition: opacity 0.24s ease, visibility 0.24s ease;
    z-index: 2;
    transform-origin: top center;
    transform-style: preserve-3d;
    filter: drop-shadow(0 14px 20px rgba(var(--template-5-dark-rgb), 0.14));
}

.env-open {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: fill;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.24s ease, visibility 0.24s ease;
    z-index: 2;
    transform-origin: top center;
    backface-visibility: hidden;
    filter: saturate(0.42) brightness(1.025);
}

.env-save_the_date {
    position: absolute;
    left: 50%;
    top: 37%;
    transform: translate(-50%, -50%);
    opacity: 1;
    visibility: visible;
    transition: opacity 0.24s ease, visibility 0.24s ease;
    z-index: 3;
    display: block;
    width: clamp(142px, 38vw, 176px);
    max-width: 78%;
    aspect-ratio: 352 / 222;
    background-color: #7f8575;
    -webkit-mask: url('../images/template-5/save-the-date.png') center / contain no-repeat;
    mask: url('../images/template-5/save-the-date.png') center / contain no-repeat;
    filter: drop-shadow(0 3px 12px rgba(var(--template-5-dark-rgb), 0.12));
}

.template-5-envelope--orange .env-save_the_date {
    background-color: #998b68;
}

.env-center {
    position: absolute;
    left: 50%;
    top: 92%;
    height: var(--env-center-height);
    width: auto;
    transform: translate(-50%, -50%);
    opacity: 1;
    visibility: visible;
    transition: opacity 0.24s ease, visibility 0.24s ease, filter 0.3s ease;
    z-index: 3;
    filter: sepia(0.2) saturate(0.72) drop-shadow(0 10px 16px rgba(var(--template-5-dark-rgb), 0.18));
}


.env-bottom {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    width: var(--env-envelope-width);
    height: 100%;
    margin-inline: auto;
    overflow: hidden;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.24s ease, visibility 0.24s ease;
    z-index: 1;
    border-inline: 1px solid rgba(var(--template-5-primary-rgb), 0.16);
    background: var(--template-5-cream-card);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.34);
    box-sizing: border-box;
}

.env-bottom::before {
    position: absolute;
    inset: 18px;
    z-index: 2;
    content: '';
    border: 1px solid rgba(var(--template-5-primary-rgb), 0.22);
    pointer-events: none;
}

.env-paper {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: bottom center;
    z-index: 1;
    filter: saturate(0.38) brightness(1.035);
}

.env-botanical {
    position: absolute;
    z-index: 2;
    display: block;
    width: 235px;
    height: auto;
    pointer-events: none;
    user-select: none;
}

.template-5-envelope--orange .env-botanical {
    opacity: .7;
}

.env-botanical--upper {
    top: calc(var(--env-top-height) + 12px);
    right: -90px;
}

.env-botanical--lower {
    left: -92px;
    bottom: -104px;
    transform: rotate(180deg);
}

.env-names {
    position: absolute;
    left: 50%;
    top: calc(var(--env-top-height) + 16px);
    bottom: 104px;
    z-index: 3;
    display: flex;
    width: min(88%, 440px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transform: translateX(-50%);
    text-align: center;
}

.env-event-label {
    display: block;
    color: #7f8575;
    font-family: 'Inter', sans-serif;
    font-size: 9px;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.28em;
    text-transform: uppercase;
}

.template-5-envelope--orange .env-event-label {
    color: #998b68;
}

.env-couple-line {
    width: 100%;
    min-width: 0;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 2px;
    display: flex;
}

.env-name {
    display: block;
    width: 100%;
    min-width: 0;
    color: var(--template-5-primary);
    font-family: 'Playfair Display', serif;
    font-size: 40px;
    font-weight: 600;
    line-height: 1.08;
    letter-spacing: 0.02em;
    text-align: center;
    text-transform: uppercase;
    white-space: normal;
    overflow-wrap: anywhere;
    text-shadow: 0 2px 12px rgba(var(--template-5-dark-rgb), 0.08);
}

.env-name:first-child {
    text-align: center;
}

.env-name:last-child {
    text-align: center;
}

.env-amp {
    display: block;
    flex: 0 0 auto;
    color: var(--template-5-primary);
    font-size: clamp(28px, 8vw, 30px);
    font-weight: 400;
    line-height: 1;
    font-family: "Playball", cursive;
}

.env-date {
    position: relative;
    margin-top: 0;
    padding-top: 16px;
    color: var(--template-5-dark);
    font-family: 'Literata', serif;
    font-size: 14px;
    font-weight: 500;
    line-height: 1;
    letter-spacing: 0.22em;
}

.env-date::before {
    position: absolute;
    top: 0;
    left: 50%;
    width: 82px;
    height: 1px;
    content: '';
    transform: translateX(-50%);
    background: linear-gradient(90deg, transparent, var(--template-5-primary), transparent);
    opacity: 0.55;
}

@media (max-width: 480px) {
    .env-event-label {
        font-size: 8px;
        letter-spacing: 0.24em;
    }

    .env-name,
    .env-name:first-child,
    .env-name:last-child {
        width: 100%;
        color: var(--template-5-primary);
        font-size: clamp(25px, 8vw, 32px);
        font-weight: 600;
        line-height: 1.08;
        text-align: center;
        white-space: normal;
        overflow-wrap: anywhere;
        text-shadow: 0 2px 12px rgba(var(--template-5-dark-rgb), 0.08);
    }

    .env-date {
        padding-top: 14px;
        font-size: 13px;
    }
}

.env-open-cue {
    position: absolute;
    left: 50%;
    bottom: max(32px, env(safe-area-inset-bottom));
    z-index: 4;
    display: inline-flex;
    align-items: center;
    gap: 0;
    transform: translateX(-50%);
    color: var(--template-5-muted);
    font-family: 'Inter', sans-serif;
    font-size: 0;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0;
    text-transform: uppercase;
    white-space: nowrap;
}

.env-open-cue__icon {
    position: relative;
    width: 24px;
    height: 24px;
    border: 1px solid rgba(var(--template-5-primary-rgb), 0.45);
    border-radius: 50%;
}

.env-open-cue__icon::before,
.env-open-cue__icon::after {
    position: absolute;
    left: 50%;
    content: '';
    transform: translateX(-50%);
}

.env-open-cue__icon::before {
    top: 6px;
    width: 1px;
    height: 8px;
    background: var(--template-5-primary);
}

.env-open-cue__icon::after {
    top: 10px;
    width: 5px;
    height: 5px;
    border-right: 1px solid var(--template-5-primary);
    border-bottom: 1px solid var(--template-5-primary);
    transform: translateX(-50%) rotate(45deg);
}

#envelope-scene:not(.is-opening) .env-open-cue__icon {
    animation: ws-envelope-open-cue 2.2s ease-in-out infinite;
}

#envelope-scene:hover .env-center {
    filter: sepia(0.2) saturate(0.84) drop-shadow(0 13px 19px rgba(var(--template-5-dark-rgb), 0.24));
}

@keyframes ws-envelope-open-cue {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(4px);
    }
}

/* ---------- Hiá»‡u á»©ng má»Ÿ phong bÃ¬ khi click ---------- */
#envelope-scene.is-opening .env-top {
    animation: ws-envelope-top-release var(--env-opening-duration) cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

#envelope-scene.is-opening {
    animation: ws-envelope-scene-release var(--env-opening-duration) ease-in-out forwards;
}

#envelope-scene.is-opening.ws-envelope-backdrop-ready::before {
    animation: ws-envelope-backdrop-release var(--env-backdrop-duration) cubic-bezier(0.4, 0, 0.2, 1) forwards;
    will-change: opacity;
}

#envelope-scene.is-opening .env-top,
#envelope-scene.is-opening .env-open,
#envelope-scene.is-opening .env-center,
#envelope-scene.is-opening .env-save_the_date,
#envelope-scene.is-opening .env-bottom,
#envelope-scene.is-opening .env-names {
    will-change: transform, opacity, filter;
}

#envelope-scene.is-opening .env-open {
    animation: ws-envelope-flap-fold var(--env-opening-duration) cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

#envelope-scene.is-opening .env-center {
    animation: ws-envelope-seal-release var(--env-opening-duration) cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

#envelope-scene.is-opening .env-save_the_date {
    animation: ws-envelope-title-release var(--env-opening-duration) cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

#envelope-scene.is-opening .env-names {
    animation: ws-envelope-names-release var(--env-opening-duration) cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

#envelope-scene.is-opening .env-bottom {
    animation: ws-envelope-bottom-release var(--env-opening-duration) cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

#envelope-scene.is-closed {
    pointer-events: none;
}

@keyframes ws-envelope-backdrop-release {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

@keyframes ws-envelope-scene-release {

    0%,
    72% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

@keyframes ws-envelope-top-release {

    0%,
    24% {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }

    38% {
        transform: translate3d(0, -6px, 18px);
    }

    100% {
        opacity: 0;
        transform: translate3d(0, -52vh, -30px);
    }
}

@keyframes ws-envelope-flap-fold {

    0%,
    22% {
        opacity: 1;
        transform: rotateX(0deg) translateZ(0);
    }

    38% {
        transform: rotateX(5deg) translateZ(12px);
    }

    100% {
        opacity: 0.45;
        transform: rotateX(-78deg) translateZ(-12px);
        filter: blur(0.4px);
    }
}

@keyframes ws-envelope-seal-release {

    0%,
    10% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1) rotate(0deg);
        filter: drop-shadow(0 10px 16px rgba(82, 58, 20, 0.16));
    }

    18% {
        transform: translate(-50%, -50%) scale(0.94) rotate(-1deg);
        filter: drop-shadow(0 6px 10px rgba(82, 58, 20, 0.12));
    }

    29% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.045) rotate(0.75deg);
        filter: drop-shadow(0 16px 24px rgba(82, 58, 20, 0.22));
    }

    48%,
    100% {
        opacity: 0;
        transform: translate(-50%, -42%) scale(0.88) rotate(0deg);
        filter: drop-shadow(0 4px 8px rgba(82, 58, 20, 0));
    }
}

@keyframes ws-envelope-title-release {

    0%,
    14% {
        opacity: 1;
        transform: translate(-50%, -50%);
        filter: blur(0);
    }

    38%,
    100% {
        opacity: 0;
        transform: translate(-50%, calc(-50% - 14px)) scale(0.985);
        filter: blur(1.5px);
    }
}

@keyframes ws-envelope-names-release {

    0%,
    16% {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
        filter: blur(0);
    }

    42%,
    100% {
        opacity: 0;
        transform: translateX(-50%) translateY(18px);
        filter: blur(1.5px);
    }
}

@keyframes ws-envelope-bottom-release {

    0%,
    36% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
    }

    52% {
        transform: translate3d(0, 7px, 0) scale(1);
    }

    100% {
        opacity: 0;
        transform: translate3d(0, 28vh, -20px) scale(0.99);
    }
}

@media (prefers-reduced-motion: reduce) {
    #envelope-scene:not(.is-opening) .env-open-cue__icon {
        animation: none;
    }

    #envelope-scene.is-opening.ws-envelope-backdrop-ready::before {
        animation-duration: 1ms;
    }

    #envelope-scene.is-opening,
    #envelope-scene.is-opening .env-top,
    #envelope-scene.is-opening .env-open,
    #envelope-scene.is-opening .env-center,
    #envelope-scene.is-opening .env-save_the_date,
    #envelope-scene.is-opening .env-bottom,
    #envelope-scene.is-opening .env-names {
        animation-duration: 360ms;
    }
}


/* Love story */

.lovestory {
    position: relative;
    background-image:
        linear-gradient(var(--template-5-lovestory-background)),
        url('../images/template-3/bg-frame.webp');
    padding-top: 76px;
}

.lovestory__flower-top {
    position: absolute;
    top: -60px;
    right: 0;
    width: 270px;
}

.lovestory__flower-bottom {
    position: absolute;
    bottom: -190px;
    left: 0;
    width: 180px;
}

.orange .lovestory__flower-bottom {
    opacity: 0.2;
}

.orange .lovestory__flower-top {
    opacity: .5;
}

.orange .calendar__flower-top {
    opacity: .8;
}

.orange .guestbook__flower-bottom,
.orange .rsvp__flower-bottom {
    opacity: .7;
}

.green .lovestory {
    overflow: hidden;
}

.lovestory__title {
    color: var(--template-5-lovestory-text);
    font-family: 'Playfair Display', sans-serif;
    font-size: 23px;
    text-transform: uppercase;
    line-height: 1.3;
    max-width: 250px;
    margin: auto;
}

.lovestory__subtitle {
    color: var(--template-5-lovestory-text);
    font-family: 'Literata', sans-serif;
    font-size: 16px;
    text-align: center;
    max-width: 200px;
    margin: auto;
}

.lovestory__grid {
    padding: 20px;
    position: relative;
    width: min(100%, 500px);
    margin: auto;
    margin-top: 48px;
}

.lovestory__row {
    display: grid;
    gap: clamp(20px, 5.13vw, 24px);
    padding: 10px;
    z-index: 2;
    position: relative;
}

.lovestory__row--top {
    grid-template-columns: minmax(0, 6fr) minmax(0, 4fr);
    align-items: start;
}

.lovestory__row--bottom {
    grid-template-columns: minmax(0, 4fr) minmax(0, 6fr);
    align-items: center;
    margin-top: -10px;
}

.lovestory__photo {
    width: 100%;
    min-width: 0;
}

.lovestory__photo-frame {
    width: 100%;
    aspect-ratio: 203 / 250;
    box-sizing: border-box;
    max-width: 255px;
    box-shadow: 0 4px 4px 0 rgba(var(--template-5-dark-rgb), 0.31);
    border-radius: 12px;
    overflow: hidden;
}

.lovestory__row--top .lovestory__photo {
    display: flex;
    justify-content: flex-end;
}

.lovestory__row--top .lovestory__photo-frame {
    rotate: -4.5deg;
}

.lovestory__row--bottom .lovestory__photo {
    display: flex;
    justify-content: flex-start;
}

.lovestory__row--bottom .lovestory__photo-frame {
    rotate: 4.5deg;
}

.lovestory__photo-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.lovestory__spacer {
    display: flex;
    align-items: center;
    min-width: 0;
}

.lovestory__row--top .lovestory__spacer {
    justify-content: flex-start;
}

.lovestory__row--bottom .lovestory__spacer {
    justify-content: flex-end;
}

.lovestory__couple-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 0;
}

.lovestory__couple-role {
    color: var(--template-5-lovestory-text);
    font-family: 'Great Vibes', cursive;
    font-size: 24px;
    font-weight: 300;
    line-height: 1.2;
    margin: 0;
    text-transform: capitalize;
}

.lovestory__couple-name {
    color: var(--template-5-lovestory-text);
    font-family: 'Playfair Display', sans-serif;
    font-size: clamp(18px, 5vw, 22px);
    font-weight: 500;
    line-height: 1.2;
    margin: 0;
    text-align: center;
    text-shadow: 0 4px 4px rgba(0, 0, 0, 0.25);
    text-transform: uppercase;
    white-space: nowrap;
}

.lovestory__groom-center {
    width: 117px;
    position: absolute;
    top: 47%;
    left: 57%;
    width: 117px;
    transform: translate(-50%, -50%);
    z-index: 3;
    pointer-events: none;
    filter: contrast(102%) grayscale(26%) hue-rotate(0deg) invert(0%) saturate(63%) sepia(0%) opacity(100%) brightness(126%) blur(0px);

}

.lovestory__line-circle {
    position: absolute;
    inset: 0;
    width: 100%;
}

.lovestory__flower {
    position: absolute;
    bottom: -134px;
    left: 0;
    width: 203px;
    z-index: 3;
}

.lovestory__leaf {
    position: absolute;
    left: 0;
    top: 146px;
    width: 77px;
}

@keyframes rotate-in-groom {
    from {
        opacity: 0;
        transform: perspective(1000px) rotateZ(-90deg);
    }

    to {
        opacity: 1;
        transform: perspective(1000px) rotateZ(-10.5deg);
    }
}

@keyframes rotate-in-bride {
    from {
        opacity: 0;
        transform: perspective(1000px) rotateZ(90deg);
    }

    to {
        opacity: 1;
        transform: perspective(1000px) rotateZ(10.5deg);
    }
}

.lovestory__row--top [data-aos="rotate-in-groom"].aos-animate {
    animation: rotate-in-groom 1.5s ease-in-out forwards;
}

.lovestory__row--bottom [data-aos="rotate-in-bride"].aos-animate {
    animation: rotate-in-bride 1.5s ease-in-out forwards;
}


/* COUPLE SECTION */
.couple-section__banner .ws-image-placeholder__content {
    top: 50%;
    right: auto;
    bottom: auto;
    left: 50%;
    transform: translate(-50%, -50%);
}

.couple-section {
    display: flex;
    align-items: flex-end;
    overflow: hidden;
    min-height: 650px;
    padding-bottom: 30px;
}

.couple-section__content {
    position: relative;
    width: 100%;
    margin-bottom: 8px;
}

.couple-section__title {
    color: #FFF;
    text-align: center;
    font-family: 'Manstein';
    font-size: 32px;
    font-style: normal;
    line-height: 16px;
    letter-spacing: 2.4px;
    margin: 0;
    text-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
}

.couple-section__date {
    color: #FFF;
    text-align: center;
    font-size: 16px;
    font-style: normal;
    font-weight: 500;
    line-height: 16px;
    letter-spacing: 2.4px;
    margin: 0;
    text-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
    font-family: 'Literata', sans-serif;
}

.couple-section__names-wrapper {
    align-items: center;
    gap: 8px;
    display: flex;
    justify-content: center;
    padding-block: 12px;
}

.couple-section__divider,
.couple-section__name {
    color: #FFF;
    text-align: center;
    font-size: 40px;
    font-style: normal;
    font-weight: 400;
    line-height: 60px;
    margin: 0;
    text-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
    min-width: 0;
    font-family: 'Playfair Display', sans-serif;
    font-size: clamp(22px, 6.5vw, 30px) !important;
    line-height: 1.2 !important;
    white-space: nowrap;
    text-transform: uppercase;
}

.couple-section__divider {
    font-family: "Playball", cursive;
}

/* Party section */


.event-info-wrapper {
    position: relative;
    padding-top: 0;
    z-index: 2;
}

.event-info {
    border-radius: 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 36px;
    align-self: stretch;
    position: relative;
    z-index: 1;
    width: min(100%, 500px);
    margin: auto;
}

.event-info-list {
    display: grid;
    gap: 24px;
    position: relative;
    z-index: 1;
}

.event-calendar {
    display: flex;
    flex-direction: column;
    gap: 24px;
    align-self: stretch;
    padding-bottom: 0;
}

.event-calendar:not(:last-child) {
    border-bottom: none;
}

.event-calendar__event-name {
    color: var(--template-5-primary);
    text-align: center;
    font-family: "Montserrat";
    font-size: clamp(13px, 1.8vw, 17px);
    font-style: normal;
    line-height: 1.5;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.event-calendar+.event-calendar {
    position: relative;
    padding-top: 64px;
}

.event-calendar+.event-calendar::before {
    content: "";
    position: absolute;
    top: 24px;
    left: 50%;
    width: 120px;
    height: 1px;
    transform: translateX(-50%);
    background: linear-gradient(90deg, transparent, var(--template-5-primary), transparent);
    opacity: 0.4;
}

.event-calendar__time {
    color: var(--template-5-primary);
    text-align: center;
    font-family: 'Yeseva One', sans-serif;
    font-style: normal;
    font-weight: 600;
    line-height: 40px;
    font-size: 22px;
}

.event-calendar__month,
.event-calendar__weekday {
    font-size: 16px;
    color: var(--template-5-primary);
    text-align: center;
    font-family: 'Yeseva One', sans-serif;
    font-style: normal;
    font-weight: 400;
    line-height: 15px;
    text-transform: uppercase;
    padding-block: 8px;
    border-top: 1px solid var(--template-5-primary);
    border-bottom: 1px solid var(--template-5-primary);
}

.event-calendar__day {
    font-size: 48px;
    color: var(--template-5-primary);
    text-align: center;
    font-family: 'Yeseva One', sans-serif;
    font-style: normal;
    font-weight: 400;
    line-height: 32px;
}

.event-calendar__vietnamese-date {
    color: var(--template-5-primary);
    text-align: center;
    font-style: italic;
    font-weight: 400;
    line-height: 1.5;
    font-size: 16px;
    font-family: 'Literata', sans-serif;

}

.event-calendar__date {
    display: flex;
    align-items: center;
    gap: 24px;
    justify-content: center;
}

.party-item {
    display: flex;
    padding: 32px;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    align-self: stretch;
    border-radius: 4px;
    padding-top: 0;
}

.party-item__label {
    font-family: 'Literata', sans-serif;
    font-size: 16px;
    color: var(--template-5-primary);
}

.party-item__place {
    color: var(--template-5-primary);
    font-family: 'Yeseva One', sans-serif;
    font-size: 24px;
    text-transform: uppercase;
    padding-block: 8px;
    text-align: center;
}

.party-item__address {
    color: var(--template-5-primary);
    text-align: center;
    line-height: 28.8px;
    font-family: 'Literata', sans-serif;
    font-size: 16px;
    font-style: italic;
}

.party-item__button {
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    font-family: 'Inter';
    line-height: 12px;
    letter-spacing: 1.2px;
    border: none;
    text-transform: uppercase;
    border-bottom: 1px solid rgba(216, 199, 163, 0.30);
    cursor: pointer;
    padding: 16px 24px;
    color: rgba(255, 255, 255, 1);
    font-size: 14px;
    font-weight: bold;
    border-radius: 12px;
    background: var(--template-5-primary);
}

.party-item__button:hover {
    opacity: .9;
}

.party-item__actions {
    display: flex;
    gap: 16px;
    margin-top: 24px;
}

/* calendar section */
.ws-mini-calendar__wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 32px;
}

.calendar__flower-top {
    position: absolute;
    top: 1px;
    right: 0;
    width: 200px;
}

.ws-mini-calendar__year {
    color: var(--template-5-primary);
    font-family: 'Yeseva One', sans-serif;
    font-size: 58px;
}

.calendar-divider {
    width: 100%;
    margin-top: 30px;
}

.template-5-cover__banner {
    position: relative;
}

.template-5-cover__text {
    display: flex;
    flex-direction: column;
    position: absolute;
    bottom: 40px;
    left: 20px;
    gap: 24px;
}

.template-5-cover__text span {
    font-family: 'Manstein';
    font-size: 32px;
    color: #fff;
}

.template-5-cover__text strong {
    font-family: 'Yeseva One', sans-serif;
    color: #fff;
    font-size: 30px;
}

.template-5-cover__banner img {
    width: 100%;
}

.template-5-cover__banner--placeholder {
    aspect-ratio: 16 / 9;
}

.template-5-cover__banner--placeholder .ws-image-placeholder {
    min-height: 100%;
}

.calendar__subtitle {
    color: var(--template-5-primary);
    text-align: center;
    font-family: 'Inter';
    font-size: 12px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.ws-mini-calendar--love-story {
    width: min(100%, 380px);
    padding: 28px 20px 24px;
    border-radius: 0;
    box-shadow: none;
    padding-bottom: 0;
    margin: auto;
}

.ws-mini-calendar__month-title {
    color: var(--template-5-primary);
    font-size: 32px;
    font-style: normal;
    font-weight: 400;
    line-height: 56px;
    text-align: center;
    font-family: 'Manstein';
}

.ws-mini-calendar__grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 16px;
}

.ws-mini-calendar__dow,
.ws-mini-calendar__cell {
    display: flex;
    align-items: center;
    justify-content: center;
}

.ws-mini-calendar__dow {
    color: rgba(var(--template-5-deep-rgb), 0.85);
    text-align: center;
    font-family: 'Inter';
    font-size: 11px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
    letter-spacing: 0.55px;
    padding-bottom: 12px;
}

.ws-mini-calendar__cell {
    color: var(--template-5-primary);
    font-family: 'Inter';
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: 22px;
    position: relative;
}

.ws-mini-calendar__num {
    color: rgba(var(--template-5-deep-rgb), 0.85);
    font-family: 'Inter';
    font-size: 14px;
    font-style: normal;
    font-weight: 700;
    line-height: 22px;
}

.ws-mini-calendar__cell--empty {
    background: transparent;
}

.ws-mini-calendar__cell--event {
    color: var(--t3-primary);
    background: transparent;
    box-shadow: none;
}

.ws-mini-calendar__heart {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 37px;
    height: 37px;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: ws-heart-beat 1.4s ease-in-out infinite;
    pointer-events: none;
}

.ws-mini-calendar__heart svg {
    width: 100%;
    height: 100%;
    color: var(--t3-primary);
    overflow: visible;
}

@keyframes ws-heart-beat {
    0% {
        transform: translate(-50%, -50%) scale(1);
    }

    14% {
        transform: translate(-50%, -50%) scale(1.13);
    }

    28% {
        transform: translate(-50%, -50%) scale(1);
    }

    42% {
        transform: translate(-50%, -50%) scale(1.08);
    }

    70% {
        transform: translate(-50%, -50%) scale(1);
    }

    100% {
        transform: translate(-50%, -50%) scale(1);
    }
}

/* Timline section */
/* Timeline section */
.ws-timeline-love {
    position: relative;
    z-index: 1;
}

.ws-timeline-love__background-placeholder {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}

.ws-timeline-bg-center {
    position: absolute;
    top: 25%;
    left: 37%;
    transform: translate(-50%, -50%);
    z-index: 0;
    width: 100%;
    opacity: 0.13;
    width: 100%;
}

.ws-timeline-love__inner {
    position: relative;
    z-index: 1;
    width: min(100%, 500px);
    margin: auto;
}

.ws-timeline-love .section-title {
    margin-bottom: clamp(22px, 2.6vw + 10px, 34px);
}

.ws-timeline-love__list {
    list-style: none;
    margin: 0 auto;
    padding: 0;
    max-width: min(100%, 500px);
    width: fit-content;
    margin: auto;
}

.ws-timeline-love__list--empty {
    width: min(100%, 420px);
}

.ws-timeline-love__empty {
    --ws-content-placeholder-border-color: rgba(255, 255, 255, 0.45);
    --ws-content-placeholder-background: rgba(0, 0, 0, 0.22);
    --ws-content-placeholder-icon-color: #701620;
    --ws-content-placeholder-icon-background: #FDF8F2;
    --ws-content-placeholder-title-color: #FDF8F2;
    --ws-content-placeholder-path-color: rgba(255, 255, 255, 0.78);
}

.ws-timeline-love__item {
    display: grid;
    grid-template-columns: 89px 2.25rem minmax(0, 1fr);
    position: relative;
    align-items: stretch;
}

.ws-timeline-love__icon {
    align-self: start;
    justify-self: center;
    width: 89px;
    height: 89px;
    object-fit: contain;
    color: #FDF8F2;
    font-size: 42px;
    line-height: 1;
}

.ws-timeline-love__icon--image {
    display: block;
    background-color: #FDF8F2;
    -webkit-mask: var(--ws-timeline-icon-url) center / contain no-repeat;
    mask: var(--ws-timeline-icon-url) center / contain no-repeat;
}

.ws-timeline-love__marker {
    position: relative;
}

.ws-timeline-love__marker::after {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    width: 2px;
    bottom: calc(-1 * clamp(1.1rem, 2.8vw, 1.65rem));
    transform: translateX(-50%);
    border-radius: 2px;
    background: #fff;
}

.ws-timeline-love__item:last-child .ws-timeline-love__marker::after {
    margin-bottom: 38px;
}

.ws-timeline-love__dot {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    border-radius: 12px;
    background: #fff;
    transform: translate(-50%, -50%);
}

.ws-timeline-love__dot i {
    font-size: 14px;
    line-height: 1;
    color: #701620;
}

.ws-timeline-love__card {
    align-self: start;
    text-align: left;
    padding: clamp(1rem, 2.4vw, 1.35rem) clamp(1rem, 2.8vw, 1.5rem);
    padding-top: 4px;
}

.ws-timeline-love__date {
    color: #fff;
    font-style: normal;
    line-height: 1;
    font-family: 'Yeseva One', sans-serif;
    font-size: 24px;
}

.ws-timeline-love__heading {
    margin: 0 0 clamp(0.65rem, 1.5vw, 0.85rem);
    color: #FDF8F2;
    font-size: 24px;
    font-style: normal;
    font-weight: 300;
    line-height: 33.6px;
    font-family: 'Literata', sans-serif;
    font-size: 16px;
}

.ws-timeline-love__desc {
    margin: clamp(0.65rem, 1.5vw, 0.85rem) 0 0;
    color: #D8C7A3;
    font-family: 'Inter';
    font-size: clamp(16px, 0.8vw + 0.7rem, 20px);
    font-style: normal;
    font-weight: 400;
    line-height: 24px;
}

.ws-timeline-love__figure {
    margin: 0;
    overflow: hidden;
    border: 1px solid rgba(var(--kit-primary-rgb), 0.18);
}

.ws-timeline-love__img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
    object-fit: cover;
}

@media (max-width: 480px) {
    .ws-timeline-love__item {
        grid-template-columns: 89px 1.85rem minmax(0, 1fr);
    }
}

@media (prefers-reduced-motion: reduce) {
    .ws-timeline-love::before {
        background-attachment: scroll;
    }

    .ws-timeline-love__card {
        box-shadow: none;
    }
}

.timeline-dress__wrapper {
    display: flex;
    position: relative;
    z-index: 1;
    justify-content: end;
}

.ws-timeline-love__inner .section-title {
    color: #fff;
    text-align: left;
}

.timeline-dress__inner {
    display: flex;
    flex-direction: column;
    width: fit-content;
    padding-right: 20px;
}

.timeline-dress {
    font-family: 'Great Vibes', cursive;
    color: #fff;
    font-size: 48px;
    text-align: center;
    text-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
    padding-top: 40px;
    padding-bottom: 24px;
}

.ws-timeline-love--timeline-hidden .timeline-dress {
    color: var(--template-5-primary);
}

.timeline-dress__color {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.timeline-dress__color-item {
    border-color: rgba(229, 231, 235, 1);
    border-radius: 50px;
    border-style: solid;
    box-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
    background: var(--timeline-dress-color, rgba(255, 255, 255, 1));
    background-clip: padding-box;
    height: 63px;
    width: 63px;
    margin-right: -20px;
}

.ws-timeline-love {
    padding-bottom: 56px;
}

/* Cover section */
/* Cover section */

.absolute {
    position: absolute;
}

.cover-bg-bottom-left {
    left: -33px;
    bottom: -35px;
    width: 225px;
    z-index: 3;
}

.cover-bg-bottom-right {
    bottom: -103px;
    width: 250px;
    z-index: 3;
    right: -72px;
}

.envelop-warpper {
    width: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    height: 370px;
}

.envelop-content-anchor {
    position: absolute;
    z-index: 3;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    height: 100%;
    width: 100%;
}

.envelop-content {
    height: auto;
    padding-top: 56px;
    text-align: center;
    transform: translateY(clamp(18px, 9vw, 60px));
}

.cover-content-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-block: 12px;
}

.cover-welcome {
    color: var(--t3-primary);
    font-family: 'Literata', sans-serif;
    font-size: 11px;
    text-align: center;
    line-height: 1;
}

.cover-divider,
.cover-name {
    color: var(--t3-primary);
    font-size: 28px;
    text-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
    font-family: 'Great Vibes', cursive;
}

.cover-divider {
    font-size: 20px;
}

.cover-date {
    font-family: 'Literata', sans-serif;
    font-size: 16px;
    font-weight: 400;
    color: var(--t3-primary);
    text-align: center;
    line-height: 1;
}

.envelop-img {
    width: 100%;
    display: block;
    z-index: 2;
}

@media (min-width: 768px) {
    .envelop-img {
        margin-bottom: -23px;
    }
}


.envelop-bottom {
    margin-top: -78px;
}

.envelop-paper {
    position: absolute;
    inset: 0;
    top: 20px;
}

.envelop-center {
    position: absolute;
    width: 70px !important;
    height: 70px;
    top: 55%;
    left: 50%;
    z-index: 3 !important;
    transform: translateX(-50%);
}

.w-100 {
    width: 100%;
}

.template-5-cover {
    position: relative;
    overflow: visible;
}

.template-5-cover__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    align-items: center;
    position: relative;
    overflow: visible;
    max-width: 460px;
    margin: auto;
}

.cover-bg-top {
    position: absolute;
    right: -48px;
    width: 157px;
    bottom: -59px;
}

.template-5-cover__card {
    margin: 0;
    overflow: hidden;
    aspect-ratio: 4 / 5;
    background: #fff;
    padding: 6px;
    z-index: 2;
    will-change: transform, opacity;
    backface-visibility: hidden;
}

.template-5-cover__card img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.template-5-cover__card--2 {
    height: 214px;
    width: 100%;
}

.envelop-paper,
.envelop-content {
    will-change: transform, opacity;
    backface-visibility: hidden;
}

/* RSVP section */

.rsvp-section {
    display: flex;
    justify-content: center;
    position: relative;
}

.rsvp__flower-bottom {
    position: absolute;
    bottom: 260px;
    right: 0;
    width: 220px;
}

.rsvp-section__inner {
    width: min(100%, 500px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    align-self: stretch;
}

.rsvp-section__title {
    color: var(--template-5-primary);
    text-align: center;
    font-family: "Great Vibes";
    font-size: 42px;
    font-style: normal;
    font-weight: 400;
    line-height: 48px;
    margin: 0;
    text-transform: capitalize;
}

.rsvp-section__subtitle {
    color: var(--template-5-primary);
    text-align: center;
    font-family: 'Inter';
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: 1.6;
    margin: 0;
    font-family: 'Literata', sans-serif;
    max-width: 350px;
}

.rsvp-section__form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin: 0;
}

.rsvp-section__field {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: var(--template-5-primary);
    font-family: 'Inter';
    font-size: 13px;
    font-weight: 600;
    line-height: 1.3;
}

.rsvp-section__field input::placeholder {
    color: var(--template-5-primary);
}

.rsvp-section__field input,
.rsvp-section__field select {
    width: 100%;
    min-height: 45px;
    padding: 12px 14px;
    border: 1px solid var(--template-5-primary);
    background: transparent;
    font-family: 'Inter';
    font-size: 14px;
    font-weight: 400;
    line-height: 1.4;
    outline: none;
    transition: border-color 180ms ease, box-shadow 180ms ease;
    border-radius: 15px;
    color: var(--template-5-primary);
}

.rsvp-section__field select {
    cursor: pointer;
    padding-right: 48px;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-color: transparent;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%234B382A' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 18px center;
    background-size: 14px 14px;
}

.rsvp-section__field select::-ms-expand {
    display: none;
}

.rsvp-section__field input:focus,
.rsvp-section__field select:focus {
    border-color: var(--template-5-primary);
    box-shadow: 0 0 0 3px rgba(var(--template-5-primary-rgb), 0.14);
}

.rsvp-section__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    min-height: 48px;
    padding: 14px 22px;
    border: 0;
    border-radius: 999px;
    color: #FFF;
    font-family: 'Inter';
    font-size: 14px;
    font-style: normal;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 180ms ease, transform 180ms ease;
    background: var(--template-5-primary);
}

.rsvp-section__button:hover {
    opacity: .9;
}

.rsvp-section__button:disabled {
    cursor: wait;
    opacity: 0.72;
    transform: none;
}

.rsvp-section .ws-wedding-rsvp-inline-feedback {
    width: 100%;
    margin: 0;
}

@media (max-width: 575px) {
    .rsvp-section__inner {
        padding: 28px 20px;
        border-radius: 22px;
    }

    .rsvp-section__title {
        font-size: 38px;
        line-height: 44px;
    }
}

/* Guestbook section */
/* Guestbook */
.guestbook-section {
    text-align: center;
    color: var(--on-dark-text);
    position: relative;
    z-index: 1;
}

.guestbook__flower-bottom {
    position: absolute;
    top: 150px;
    right: 0;
    width: 220px;
}

.guestbook-section__subtitle {
    color: var(--template-5-primary);
    text-align: center;
    font-family: 'Inter';
    font-size: 12px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.guestbook-grid {
    display: grid;
    text-align: left;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    padding: 20px;
    width: min(100%, 500px);
    margin: auto;
    border-radius: 28px;
    border: 1px solid rgba(var(--template-5-primary-rgb), 0.60);
    background: var(--template-5-cream-soft);
}

.guestbook-form {
    display: grid;
    gap: 12px;
    z-index: 1;
    margin: auto;
    width: min(100%, 500px);
}

.guestbook-field {
    position: relative;
}

.guestbook-field input,
.guestbook-field textarea {
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.25);
    transition: border-color 0.2s ease;
    box-sizing: border-box;
    font-size: clamp(15px, 2vw, 18px);
    font-style: normal;
    line-height: normal;
    border-bottom: 1px solid rgba(var(--template-5-soft-rgb), 0.40);
    margin-top: 12px;
    color: rgba(var(--template-5-deep-rgb), 0.85);
    font-family: 'Inter';
    font-weight: 400;
    padding: 12px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 8px;
    outline: none;
    border-radius: 16px;
    border: 1px solid rgba(var(--template-5-primary-rgb), 0.28);
    background: #FFF;
}

.guestbook-field input::placeholder,
.guestbook-field textarea::placeholder {
    color: rgba(var(--template-5-deep-rgb), 0.85);
}

.guestbook-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
    padding-top: 8px;
}

.btn-guestbook {
    font-size: clamp(13px, 1.8vw, 16px);
    display: flex;
    justify-content: center;
    align-items: center;
    align-self: stretch;
    color: #fff;
    text-align: center;
    font-family: 'Inter';
    font-style: normal;
    font-weight: 600;
    line-height: 12px;
    letter-spacing: 1.2px;
    background: rgba(var(--template-5-deep-rgb), 0.85);
    border: 1px solid var(--template-5-soft-light);
    cursor: pointer;
    padding: 16px 0;
    border-radius: 10px;
    text-transform: uppercase;
    border-radius: 30px;
    background: var(--template-5-dark);
}

.btn-guestbook:hover {
    transition: opacity 0.2s ease-in-out;
    opacity: .9;
}

.guestbook-notice {
    font-size: clamp(12px, 1.6vw, 15px);
    font-style: normal;
    line-height: 1.7;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    text-align: center;
    color: rgba(var(--template-5-deep-rgb), 0.85);
}

.guestbook-notice.is-error {
    color: #e8a0a0;
}

.guestbook-notice[hidden] {
    display: none;
}

.guestbook-divider {
    width: 100%;
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.guestbook-list-wrap {
    display: grid;
    gap: clamp(16px, 2.5vw, 24px);
    padding-right: 6px;
    padding-top: 20px;
    z-index: 2;
}

.guestbook-list-count {
    color: var(--on-dark-text-subtle);
    margin-left: 4px;
}

.guestbook-list {
    display: grid;
    width: min(100%, 500px);
    max-height: 250px;
    margin: auto;
    overflow-y: auto;
}

@media (max-width: 480px) {
    .guestbook-list {
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        scrollbar-color: rgba(var(--template-5-deep-rgb), 0.85) rgba(var(--template-5-deep-rgb), .3);
    }
}

.guestbook-list::-webkit-scrollbar {
    width: 4px;
    border-radius: 999px;
}

.guestbook-list::-webkit-scrollbar-track {
    background: transparent;
    background: rgba(var(--template-5-deep-rgb), .3) !important;
    border-radius: 999px;
}

.guestbook-list::-webkit-scrollbar-thumb {
    background: rgba(var(--template-5-deep-rgb), 0.85);
    border-radius: 999px;
    border: 0;
}

.guestbook-entry {
    display: flex;
    padding-block: 12px;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    align-self: stretch;
    border-radius: 2px;

}

.guestbook-entry__name {
    font-size: 15px;
    color: rgba(var(--template-5-deep-rgb), 0.85);
    font-style: normal;
    font-weight: bold;
    line-height: 1;
    text-transform: capitalize;
    font-family: 'Inter', serif;
}

.guestbook-entry__message {
    font-size: 14px;
    font-style: italic;
    font-weight: 400;
    line-height: 1;
    color: rgba(var(--template-5-deep-rgb), 0.85);
    font-family: 'Inter', serif;
}

.guestbook-entry__message::before {
    content: none;
}

.guestbook-empty {
    font-family: "Cormorant", serif;
    font-style: italic;
    text-align: center;
    color: var(--on-dark-text-subtle);
    font-size: clamp(14px, 2vw, 18px);
    padding: 28px 0;
    letter-spacing: 0.06em;
}

.guestbook-bg-top {
    width: 350px;
    position: absolute;
    top: 13px;
    left: -83px;
    opacity: 0.3;
}

.guestbook-section_desc {
    font-family: 'Literata', sans-serif;
    font-size: 14px;
    font-style: italic;
    color: rgba(var(--template-5-deep-rgb), 0.85);
    width: min(100%, 350px);
    margin: auto;
    margin-bottom: 20px;
}

/* Match the RSVP section visual language. */
.guestbook-section {
    display: flex;
    justify-content: center;
    color: var(--template-5-primary);
    text-align: center;
}

.guestbook-grid {
    width: min(100%, 500px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    align-self: stretch;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

.guestbook-section__title {
    margin: 0;
    color: var(--template-5-primary);
    font-family: "Great Vibes";
    font-size: 42px;
    font-style: normal;
    font-weight: 400;
    line-height: 48px;
    text-align: center;
}

.guestbook-section__subtitle {
    max-width: 350px;
    margin: 0;
    color: var(--template-5-primary);
    font-family: 'Literata', sans-serif;
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: 1.6;
    letter-spacing: normal;
    text-align: center;
    text-transform: none;
}

.guestbook-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin: 0;
}

.guestbook-field {
    width: 100%;
    display: flex;
    flex-direction: column;
    margin: 0;
}

.guestbook-field input,
.guestbook-field textarea {
    width: 100%;
    min-height: 45px;
    box-sizing: border-box;
    margin: 0;
    padding: 12px 14px;
    border: 1px solid var(--template-5-primary);
    border-radius: 15px;
    background: transparent;
    color: var(--template-5-primary);
    font-family: 'Inter';
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: 1.4;
    outline: none;
    transition: border-color 180ms ease, box-shadow 180ms ease;
}

.guestbook-field textarea {
    min-height: 96px;
    resize: vertical;
}

.guestbook-field input::placeholder,
.guestbook-field textarea::placeholder {
    color: rgba(var(--template-5-primary-rgb), 0.72);
}

.guestbook-field input:focus,
.guestbook-field textarea:focus {
    border-color: var(--template-5-primary);
    box-shadow: 0 0 0 3px rgba(var(--template-5-primary-rgb), 0.14);
}

.guestbook-actions {
    width: 100%;
    display: flex;
    padding: 0;
}

.btn-guestbook {
    width: 100%;
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 22px;
    border: 0;
    border-radius: 999px;
    background: var(--template-5-primary);
    color: #FFF;
    font-family: 'Inter';
    font-size: 14px;
    font-style: normal;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 180ms ease, transform 180ms ease;
}

.btn-guestbook:hover {
    opacity: .9;
}

.btn-guestbook:disabled {
    cursor: wait;
    opacity: 0.72;
    transform: none;
}

.guestbook-notice {
    width: 100%;
    color: var(--template-5-primary);
    font-size: 14px;
    line-height: 1.6;
    letter-spacing: normal;
    text-align: center;
    text-transform: none;
}

.guestbook-list-wrap,
.guestbook-list {
    width: 100%;
}

.guestbook-list-wrap {
    padding: 0 6px 0 0;
}

.guestbook-list {
    margin: 0;
    text-align: left;
}

@media (max-width: 575px) {
    .guestbook-section__title {
        font-size: 38px;
        line-height: 44px;
    }
}

/* Thanks */
.gift-section-wrapper-bottom {
    position: relative;
    height: 500px;
}

.gift-thanks-banner {
    width: 100%;
    aspect-ratio: 3 / 2;
    overflow: hidden;
    height: 100%;
}

.gift-thanks-banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
}

.gift-section-wrapper-bottom-content {
    position: absolute;
    z-index: 1;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(190, 171, 126, 0.6);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-block: 30px;
    padding-bottom: 50px;
}

.gift-thanks-title {
    font-family: 'Great Vibes', cursive;
    font-size: 38px;
    color: #fff;
    margin-bottom: 16px;
    text-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25);
    z-index: 2;
}

.gift-thanks-text,
.gift-thanks-groom-bride {
    color: #fff;
    font-family: 'Literata', sans-serif;
    font-size: 12px;
    text-shadow: 0px 4px 4px rgba(0, 0, 0, 0.25), 0px 4px 4px rgba(0, 0, 0, 0.25);
    text-align: center;
}

.gift-thanks-groom-bride {
    margin-top: 14px;
    font-family: 'Great Vibes', cursive;
    font-size: 32px;
    line-height: 1.2;
    text-align: center;
}

/* Music button */
.ws-music-button-wrap {
    position: fixed;
    bottom: 50px;
    right: 20px;
    z-index: 9999999;
    display: inline-flex;
    align-items: center;
    gap: 0.62rem;
    pointer-events: auto;
}

.ws-music-toggle {
    width: 40px;
    height: 40px;
    border-radius: 999px;
    border: none;
    background: transparent;
    color: var(--t3-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

.ws-music-toggle[disabled] {
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
    opacity: 0.55;
}

.ws-music-toggle__icon {
    display: inline-flex;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    transform-origin: center;
    animation: none;
}

.ws-music-toggle__icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.ws-music-button-wrap.is-playing .ws-music-toggle__icon {
    animation: ws-music-spin 3s linear infinite;
}

.ws-music-button__hint {
    border-radius: 999px;
    padding: 0.3rem 1.15rem;
    display: inline-flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.92);
    color: var(--template-5-primary);
    font-size: 16px;
    font-weight: 500;
    line-height: 1.2;
    white-space: nowrap;
    box-shadow: 0 12px 26px -18px rgba(0, 0, 0, 0.5);
    max-width: min(70vw, 28rem);
    text-overflow: ellipsis;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px);
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0s linear 0.2s;
    height: 40px;
}

.ws-music-toggle:hover+.ws-music-button__hint,
.ws-music-toggle:focus-visible+.ws-music-button__hint {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
    transition-delay: 0s;
}

.ws-music-button-wrap.is-playing .ws-music-button__hint {
    color: var(--template-5-primary);
}

@keyframes ws-music-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(var(--template-5-deep-rgb), 0.55);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(var(--template-5-deep-rgb), 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(var(--template-5-deep-rgb), 0);
    }
}

.ws-music-button-wrap.needs-tap .ws-music-toggle {
    animation: ws-music-pulse 1.4s ease-out infinite;
}

@keyframes ws-music-spin {
    to {
        transform: rotate(360deg);
    }
}

/* rsvp */
.rsvp-btn-confirm {
    font-size: clamp(13px, 1.8vw, 14px);
    border-radius: 4px;
    background: rgba(var(--template-5-deep-rgb), 0.85);
    color: #FFF;
    text-align: center;
    font-family: "Montserrat";
    font-style: normal;
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: 1px;
    text-transform: uppercase;
    display: flex;
    padding: 10px 0;
    justify-content: center;
    align-items: center;
    align-self: stretch;
    width: 100%;
    border: 1px solid rgba(var(--template-5-deep-rgb), 0.85);
    gap: 8px;
    cursor: pointer;
    width: min(100%, 500px);
    margin: auto;
    z-index: 10;
}

.rsvp-btn-close {
    font-size: clamp(13px, 1.8vw, 14px);
    border-radius: 4px;
    text-align: center;
    font-family: "Montserrat";
    font-style: normal;
    font-weight: 500;
    line-height: 1.5;
    letter-spacing: 1px;
    text-transform: uppercase;
    display: flex;
    padding: 10px 0;
    justify-content: center;
    align-items: center;
    align-self: stretch;
    width: 100%;
    gap: 8px;
    cursor: pointer;
    width: min(100%, 500px);
    margin: auto;
    z-index: 10;
    background: #ccc;
    border: 1px solid #ccc;
    color: #000;
}

.rsvp-btn-confirm:hover,
.rsvp-btn-close:hover {
    opacity: 0.9;
    transition: opacity 0.2s ease-in-out;
}

.rsvp__choice input {
    flex: 0 0 auto;
    margin: 0;
    accent-color: rgba(var(--template-5-deep-rgb), 0.85);
}

.rsvp__notice {
    border-radius: 4px;
}

/* family info */
.family-info__heart-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.family-info__heart {
    display: flex;
    width: 40px;
    height: 40px;
    justify-content: center;
    align-items: center;
    border-radius: 999px;
    border: 1px solid var(--template-5-soft);
    color: var(--template-5-lovestory-text);
    position: relative;
}

.family-info__heart::before {
    content: '';
    position: absolute;
    inset: 0;
    box-sizing: border-box;
    border-radius: inherit;
    padding: 1px;
    background: conic-gradient(from 0deg, rgba(var(--template-5-soft-rgb), 0) 0deg, rgba(var(--template-5-deep-rgb), 0.85) 72deg, var(--template-5-soft) 128deg, rgba(var(--template-5-soft-rgb), 0) 190deg, rgba(var(--template-5-soft-rgb), 0) 360deg);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: familyInfoHeartBorderSpin 2.8s linear infinite;
    pointer-events: none;
}

.family-info__heart svg {
    position: relative;
    z-index: 1;
    width: 16px;
}

@keyframes familyInfoHeartBorderSpin {
    to {
        transform: rotate(360deg);
    }
}

.family-info__heart-line {
    width: 1px;
    height: 49px;
    position: relative;
    overflow: hidden;
}

.family-info__heart-line::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: linear-gradient(180deg, rgba(var(--template-5-deep-rgb), 0.85) 0%, var(--template-5-soft) 45%, rgba(var(--template-5-soft-rgb), 0) 100%);
    background-size: 100% 180%;
    background-position: 50% 0%;
    animation: familyInfoHeartLineGrow 2.4s ease-in-out infinite;
}

@keyframes familyInfoHeartLineGrow {
    0% {
        height: 0;
        opacity: 0;
        background-position: 50% 0%;
    }

    12% {
        opacity: 1;
    }

    62% {
        height: 49px;
        opacity: 1;
        background-position: 50% 100%;
    }

    82% {
        height: 49px;
        opacity: 1;
        background-position: 50% 100%;
    }

    100% {
        height: 49px;
        opacity: 0;
        background-position: 50% 100%;
    }
}

.family-info {
    width: min(100%, 500px);
    margin: auto;
}

.family-info__names {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.family-info__person {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.family-info__divider,
.family-info__name {
    font-size: clamp(28px, 5.5vw, 30px);
    color: var(--template-5-primary);
    text-align: center;
    font-family: "Great Vibes";
    font-style: normal;
    font-weight: 400;
    line-height: 1.2;
    margin: 0;
    color: var(--template-5-primary);
    font-family: 'Playfair Display', serif;
    text-transform: uppercase;
}

.family-info__divider {
    font-family: "Playball", cursive;
}

.family-info__description {
    color: var(--template-5-muted);
    text-align: center;
    font-family: 'Inter';
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: normal;
    max-width: 286px;
}

.family-info__guest {
    color: rgba(var(--template-5-deep-rgb), 0.85);
    text-align: center;
    font-family: "Playball", cursive;
    font-size: clamp(36px, 5.5vw, 42px);
    font-style: normal;
    font-weight: 400;
    line-height: 110%;
    text-transform: capitalize;
}

.family-info__line {
    width: 284px;
    border: 1px solid var(--template-5-mid);
    border-style: dashed;
}

.family-info__title {
    color: var(--template-5-primary);
    text-align: center;
    font-family: 'Inter';
    font-size: 14px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.family-info__invitation {
    padding-block: 30px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    justify-content: center;
    align-items: center;
    margin-top: 24px;
}

.family-info__parents-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.family-info__parents-column {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
    padding-bottom: 12px;
}

.family-info__parents-label {
    color: var(--template-5-primary);
    text-align: center;
    font-size: clamp(12px, 1.8vw, 16px);
    text-align: center;
    font-weight: 400;
    line-height: 20px;
    font-size: 18px;
    font-weight: bold;
    text-transform: uppercase;
    font-family: 'Playfair Display', sans-serif;
}

.family-info__parents-address,
.family-info__parents-name {
    color: var(--template-5-primary);
    font-size: clamp(14px, 2vw, 20px);
    text-align: center;
    font-style: normal;
    font-weight: 700;
    line-height: 1;
    font-family: 'Playfair Display', sans-serif;
    font-size: 14px;
    font-weight: 400;
}

/* ===================== ALBUM SECTION ===================== */
.album-section {
    max-width: 100%;
    position: relative;
    background: rgba(var(--template-5-overlay-rgb), 0.8);
    padding-bottom: 100px;
    overflow: hidden;
}

.album-head {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 40px;
}

.album-head__title {
    margin: auto;
    display: flex;
    gap: 20px;
    margin-bottom: 16px;
}

.album-head__title span {
    color: rgba(255, 255, 255, 1);
    font-family: 'Literata', sans-serif;
    font-size: 26px;
}

.album-head__title i {
    font-family: "Great Vibes";
    font-size: 26px;
    color: #fff;
}

.album__flower-bottom {
    position: absolute;
    bottom: -80px;
    right: 0;
    width: 170px;
}

.album__desc {
    color: #fff;
    text-align: center;
    font-family: 'Inter';
    font-size: 14px;
    font-style: normal;
    font-weight: 400;
    line-height: 160%;
    width: min(100%, 400px);
    margin: auto;
}

.album__subtitle {
    color: #fff;
    text-align: center;
    font-family: 'Inter';
    font-size: 12px;
    font-style: normal;
    font-weight: 500;
    line-height: normal;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.album-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    align-items: start;
    max-width: 500px;
    margin: 0 auto;
}

.album-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.album-col--left {
    padding-bottom: 32px;
}

.album-col--right {
    padding-top: 32px;
}

.album-item {
    border: 0;
    padding: 0;
    background: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    display: block;
    border-radius: 4px;
    width: 100%;
}

.album-item--placeholder {
    cursor: default;
}

.album-item--portrait {
    aspect-ratio: 3 / 4;
}

.album-item--square {
    aspect-ratio: 1 / 1;
}

.album-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
    border-radius: 4px;
}

.album-item:hover img,
.album-item:focus-visible img {
    transform: scale(1.04);
}

.album-item:focus-visible {
    outline: 2px solid var(--focus-outline);
    outline-offset: 2px;
}

.album-more {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.25);
    color: #fff;
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(18px, 2.05vw + 9.4px, 24px);
    letter-spacing: 3px;
    text-transform: uppercase;
}

.album-btn-more {
    display: flex;
    padding: clamp(8px, 0.5vw + 0.3rem, 12px) clamp(24px, 1.5vw + 1rem, 36px);
    justify-content: center;
    align-items: center;
    border-radius: 4px;
    background: linear-gradient(135deg, var(--template-5-mid) 0%, var(--template-5-soft-light) 100%);
    color: var(--template-5-primary);
    text-align: center;
    font-family: 'Inter';
    font-size: clamp(10px, 0.3vw + 0.5rem, 13px);
    font-style: normal;
    font-weight: 600;
    line-height: 1.5;
    letter-spacing: clamp(1px, 0.05vw + 0.05rem, 1.3px);
    text-transform: uppercase;
    border: none;
    margin: auto;
    margin-top: clamp(48px, 3vw + 1rem, 64px);
    cursor: pointer;
}

.album-btn-more:hover {
    background: var(--template-5-soft);
}

.album-btn-more:active {
    transform: scale(0.98);
}

@media (prefers-reduced-motion: reduce) {

    [data-ws-album-lightbox],
    [data-ws-album-lightbox] .ws-album-lightbox__dialog,
    [data-ws-album-lightbox] [data-ws-album-lightbox-dialog],
    .ws-album-lightbox__image {
        animation: none !important;
        transition: none !important;
    }
}

[data-ws-album-lightbox] {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.28s ease;
}

[data-ws-album-lightbox].is-active {
    opacity: 1;
    pointer-events: auto;
}

[data-ws-album-lightbox] .ws-album-lightbox__dialog,
[data-ws-album-lightbox] [data-ws-album-lightbox-dialog] {
    opacity: 0;
    transform: translate3d(0, 20px, 0) scale(0.96);
    transform-origin: center center;
    transition:
        transform 0.44s cubic-bezier(0.22, 1, 0.36, 1),
        opacity 0.30s ease;
}

[data-ws-album-lightbox].is-active .ws-album-lightbox__dialog,
[data-ws-album-lightbox].is-active [data-ws-album-lightbox-dialog] {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
}

.ws-album-lightbox__figure {
    overflow: hidden;
}

.ws-album-lightbox__image {
    opacity: 0;
    transform: scale(1.07);
    transition:
        transform 0.52s cubic-bezier(0.22, 1, 0.36, 1),
        opacity 0.38s ease;
    will-change: transform, opacity;
}

.ws-album-lightbox__image.is-loaded {
    opacity: 1;
    transform: scale(1);
}

/* Gift section */
.gift__subtitle {
    color: var(--template-5-primary);
    text-align: center;
    font-family: 'Inter';
    font-size: 16px;
    font-style: italic;
    font-weight: 400;
    line-height: 24px;
    width: min(100%, 500px);
    margin: auto;
    margin-bottom: 24px;
}

.gift-box__image {
    position: absolute;
    width: 100%;
    height: 90%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transform-origin: 50% 82%;
    object-fit: contain;
}

.gift-box:not(.gift-box--disabled) .gift-box__image,
.gift-box:not(.gift-box--disabled) .gift-box__button {
    animation: gift-box-shake 2.8s ease-in-out infinite;
}

@keyframes gift-box-shake {

    0%,
    58%,
    100% {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    62% {
        transform: translate(calc(-50% - 2px), -50%) rotate(-2.5deg);
    }

    66% {
        transform: translate(calc(-50% + 2px), -50%) rotate(2.5deg);
    }

    70% {
        transform: translate(calc(-50% - 1px), -50%) rotate(-1.6deg);
    }

    74% {
        transform: translate(calc(-50% + 1px), -50%) rotate(1.6deg);
    }

    78% {
        transform: translate(-50%, -50%) rotate(0deg);
    }
}

.gift-box__button {
    position: absolute;
    width: 56px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transform-origin: 50% 82%;
}

.gift-box {
    appearance: none;
    border: none;
    height: 319px;
    padding: 24px 0;
    border-radius: 24px;
    background: var(--template-5-primary);
    position: relative;
    width: 100%;
    cursor: pointer;
    width: min(100%, 400px);
}

.gift-box--disabled {
    cursor: default;
}

.gift-box:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {

    .gift-box__image,
    .gift-box__button {
        animation: none !important;
    }
}

.gift {
    margin: auto;
    overflow: hidden;
    padding-bottom: 56px;
}

.gift__top {
    display: flex;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    flex-direction: column;
    gap: 20px;
    z-index: 1;
    min-width: 0;
    align-items: center;
}

.gift-qr-panel {
    display: grid;
    gap: 10px;
    border-radius: 18px;
    padding: 12px;
    width: fit-content;
}

.gift-qr-panel__list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: min(100%, 500px);
    gap: 24px;
}

.gift__single {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.gift-qr-placeholder {
    width: min(100%, 180px);
    aspect-ratio: 1;
}

.gift-qr-placeholder .ws-image-placeholder {
    min-height: 100%;
}

.gift-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.gift-modal.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.gift-modal.is-manage-preview {
    top: var(--gift-modal-preview-top, 0px);
    bottom: auto;
    height: var(--gift-modal-preview-visible-height, 100vh);
}

.gift-modal.is-manage-preview .gift-modal__dialog {
    max-height: calc(var(--gift-modal-preview-visible-height, 100vh) - 40px);
}

.gift-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
}

.gift-modal__dialog {
    position: relative;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    border-radius: 24px;
    background: var(--template-5-cream);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.2);
    z-index: 1;
    width: min(500px, 100%);
}

.gift-modal__content {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 24px;
    align-items: center;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.65), rgba(255, 255, 255, 0.65)),
        url('../images/template-3/bg-frame.webp');
}

.gift-modal__title {
    color: var(--template-5-primary);
    text-align: center;
    font-family: "Great Vibes";
    font-size: clamp(28px, 3vw, 32px);
    font-style: normal;
    font-weight: 400;
    line-height: 60px;
}

.gift-modal__close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 999px;
    color: var(--template-5-primary);
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
}

.gift-qr-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    min-width: 0;
}

.gift-qr-card__role {
    margin: 0 0 8px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    color: var(--template-5-primary);
    font-size: clamp(10px, 1.3vw, 13px);
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.gift-qr-card__media {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    width: 100%;
}

.gift-qr-card__image {
    display: flex;
    justify-content: center;
    width: 100%;
}

.gift-qr-card__image img {
    display: block;
    padding: 8px;
    border-radius: 4px;
    border: 2px solid rgba(255, 255, 255, 0.20);
    background: #FFF;
    margin-bottom: 0;
    max-width: 146px;
    width: 100%;
    height: auto;
    box-sizing: border-box;
}

.gift-qr-card__download {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: var(--template-5-primary);
    font-size: clamp(9px, 1.2vw, 12px);
    font-weight: 600;
    line-height: 1;
    padding: 4px 8px;
    border-radius: 999px;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.gift-qr-card__download-icon {
    display: grid;
    place-items: center;
}

.gift-qr-card__download-icon--done,
.gift-qr-card__download.is-downloaded .gift-qr-card__download-icon--down {
    display: none;
}

.gift-qr-card__download.is-downloaded .gift-qr-card__download-icon--done {
    display: grid;
}

.gift-qr-card__download.is-downloaded {
    background: rgba(255, 255, 255, 0.92);
    border-color: var(--template-5-primary);
    color: var(--template-5-primary);
}

.gift-qr-card__bank,
.gift-qr-card__number,
.gift-qr-card__name {
    max-width: 100%;
    word-break: break-word;
}

.gift-qr-card__bank {
    color: var(--template-5-primary);
    text-align: center;
    font-size: clamp(12px, 1.6vw, 15px);
    font-weight: 400;
    line-height: 1.5;
}

.gift-qr-card__number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    max-width: 100%;
    color: var(--template-5-primary);
    font-size: clamp(11px, 1.5vw, 14px);
    font-weight: 600;
    line-height: 1;
    padding: 4px 6px;
    border-radius: 6px;
    transition: background 0.2s ease;
}

.gift-qr-card__number-value {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.gift-qr-card__copy {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    color: var(--template-5-primary);
    padding: 0;
    border-radius: 5px;
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
    background: none;
    border: none;
}

.gift-qr-card__copy-icon {
    display: grid;
    place-items: center;
}

.gift-qr-card__copy-icon--done,
.gift-qr-card__copy.is-copied .gift-qr-card__copy-icon--copy {
    display: none;
}

.gift-qr-card__copy.is-copied .gift-qr-card__copy-icon--done {
    display: grid;
}

.gift-qr-card__copy.is-copied {
    background: #FFF;
    border-color: var(--template-5-primary);
    color: var(--template-5-primary);
}

.gift-qr-card__name {
    color: var(--template-5-primary);
    font-size: clamp(12px, 1.6vw, 15px);
    font-weight: 400;
    line-height: 1.5;
    text-transform: uppercase;
}

.gift__text {
    color: var(--template-5-soft-light);
    text-align: center;
    font-family: 'Inter';
    font-size: clamp(16px, 2vw, 17px);
    font-style: italic;
    font-weight: 400;
    line-height: 1.6;
    padding-inline: 24px;
    margin: 0;
    max-width: 400px;
}

.gift-qr-card--panel {
    min-width: 0;
    gap: 4px;
}

.gift-qr-card--panel .gift-qr-card__role {
    margin: 0 0 4px;
    padding: 3px 8px;
    font-size: clamp(9px, 1.2vw, 12px);
    letter-spacing: 0.1em;
    background: rgba(var(--template-5-primary-rgb), 0.08);
    color: var(--template-5-primary);
}

.gift-qr-card--panel .gift-qr-card__image img {
    padding: 4px;
    max-width: 100px;
    width: 100%;
    border: 1px solid rgba(var(--template-5-primary-rgb), 0.12);
    border-radius: 6px;
}

.gift-qr-card--panel .gift-qr-card__download {
    background: rgba(var(--template-5-primary-rgb), 0.06);
    color: var(--template-5-primary);
    font-size: clamp(8px, 1.1vw, 11px);
    padding: 3px 6px;
}

.gift-qr-card--panel .gift-qr-card__download.is-downloaded {
    border-color: var(--template-5-primary);
    color: var(--template-5-primary);
}

.gift-qr-card--panel .gift-qr-card__bank,
.gift-qr-card--panel .gift-qr-card__number,
.gift-qr-card--panel .gift-qr-card__name {
    color: var(--template-5-primary);
    text-align: center;
    width: 100%;
}

.gift-qr-card--panel .gift-qr-card__bank {
    font-size: clamp(10px, 1.4vw, 13px);
    line-height: 1.4;
    font-weight: 500;
}

.gift-qr-card--panel .gift-qr-card__number {
    gap: 3px;
    padding: 3px 4px;
    width: 100%;
    box-sizing: border-box;
}

.gift-qr-card--panel .gift-qr-card__number.is-copied {
    background: rgba(var(--template-5-primary-rgb), 0.08);
}

.gift-qr-card--panel .gift-qr-card__number-value {
    font-size: clamp(10px, 1.4vw, 13px);
    line-height: 1.4;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.gift-qr-card--panel .gift-qr-card__copy {
    width: 18px;
    height: 18px;
    border-radius: 4px;
    background: rgba(var(--template-5-primary-rgb), 0.06);
    color: var(--template-5-primary);
    border: none;
}

.gift-qr-card--panel .gift-qr-card__copy.is-copied {
    border-color: var(--template-5-primary);
    color: var(--template-5-primary);
}

.gift-qr-card--panel .gift-qr-card__name {
    font-size: clamp(9px, 1.2vw, 12px);
    line-height: 1.4;
    text-transform: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    opacity: 0.85;
}

@media screen and (min-width: 501px) {
    .gift-qr-card--panel .gift-qr-card__image img {
        max-width: 96px;
    }
}

@media screen and (max-width: 500px) {
    .gift-modal {
        padding: 16px;
    }

    .gift-modal__content {
        padding: 20px 16px;
    }

    .gift__text {
        padding-inline: 32px;
    }

    .thanks__bg-top-left {
        width: 75px;
    }

    .thanks__bg-bottom-right {
        width: 110px;
    }
}

@media screen and (min-width: 768px) {
    .couple-section {
        height: 800px;
    }

    .couple-hero__bg--top {
        top: -265px;
    }

    .gift__top {
        bottom: 80px;
    }


    .gift-qr-card__image img {
        max-width: 180px;
    }

    .gift-qr-card--panel .gift-qr-card__image img {
        max-width: 160px;
    }
}