:root{--ink:#183c37;--deep:#102e2a;--sage:#789287;--pale:#e9eee5;--paper:#fbfaf5;--clay:#b77d65;--line:#cbd8ce}
*{box-sizing:border-box}html{scroll-behavior:smooth}
body{margin:0;background:var(--pale) url('taj.png') center center / cover fixed no-repeat;color:var(--ink);font-family:Georgia,'Times New Roman',serif}
/*body {
    margin: 0;
    background-color: #e9eee5;
    background-image: url('taj.png');
    background-position: center top;
    background-size: 100% auto;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--ink);
    font-family: Georgia, 'Times New Roman', serif;
}
button,a{font:inherit}*/
.cover{position:fixed;inset:0;z-index:10;background:#f5f2e8 url('taj.png') center center / cover no-repeat;display:grid;place-items:center;transition:opacity 1.35s ease,visibility 1.35s ease;overflow:hidden;isolation:isolate}.cover:before{content:'';position:absolute;inset:18px;border:1px solid #c5a86b;box-shadow:0 0 22px #d7b96a66,inset 0 0 22px #d7b96a33;pointer-events:none}.cover:after{content:none;display:none;position:absolute;bottom:8%;color:#bd9a52;letter-spacing:12px;font-size:18px;animation:softGlow 3s ease-in-out infinite}
/*.cover {
    position: fixed;
    inset: 0;
    z-index: 10;

    background-color: #f5f2e8;
    background-image: url('taj.png');
    background-position: center center;
    background-size: contain;
    background-repeat: no-repeat;

    display: grid;
    place-items: center;

    transition: opacity 1.35s ease, visibility 1.35s ease;
    overflow: hidden;
    isolation: isolate;
}*/
.cover.hide{opacity:0;visibility:hidden}
.cover-inner{width:min(460px,88vw);min-height:520px;padding:38px 28px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;text-align:center;border:1px solid #9db3a5;outline:1px solid #9db3a5;outline-offset:8px;position:relative;background:#fbfaf5;box-shadow:0 18px 55px rgba(24,60,55,.16);border-radius:3px;opacity:1}
.cover-inner:before,.cover-inner:after{content:none;display:none;position:absolute;color:var(--sage);font-size:35px;text-shadow:0 0 12px #c5a86b}.cover-inner:before{top:12px;left:16px}.cover-inner:after{bottom:12px;right:16px;transform:rotate(180deg)}
.monogram{width:108px;height:108px;border:1px solid var(--sage);border-radius:50%;display:grid;place-items:center;font-size:30px;color:var(--ink);margin:0 0 25px;background:#f8f8f0}
.cover small,.eyebrow{font:10px Arial,sans-serif;letter-spacing:4px;text-transform:uppercase;color:#648174}
.cover h2{font-size:36px;font-weight:400;line-height:1.2;margin:15px 0}
.cover-recipient{margin:8px 0 2px;padding:0 8px;color:#9b6d5b;font-style:italic;font-size:18px;line-height:1.45;text-shadow:none;overflow-wrap:anywhere}.cover-recipient.has-name{font-size:22px;color:var(--ink);font-weight:500}.cover h2{font-size:clamp(32px,8vw,40px);font-weight:400;line-height:1.12;margin:8px 0 4px}.cover-inner .monogram{flex:0 0 108px}.cover-inner button{flex:0 0 auto}.guest-link-builder{max-width:520px;margin:24px auto 0;padding:20px;background:rgba(251,250,245,.86);border:1px solid var(--line);border-radius:8px;text-align:left}.guest-link-builder label{display:block;margin-bottom:8px;color:var(--ink);font:10px Arial,sans-serif;letter-spacing:2px;text-transform:uppercase}.guest-link-row{display:flex;gap:8px;flex-wrap:wrap}.guest-link-row input{flex:1;min-width:180px;padding:12px 13px;border:1px solid #9db4a4;border-radius:22px;background:#fffdf7;color:var(--ink);font:14px Georgia,serif;outline:none}.guest-link-row input:focus{box-shadow:0 0 0 3px #9db4a455}.generated-link{margin-top:12px}.generated-link input{width:100%;padding:11px;border:1px solid #cbd8ce;border-radius:5px;background:#fff;color:#526e62;font:12px Arial,sans-serif}.builder-note{margin:10px 0 0!important;font-size:12px!important;color:#718278!important}
.cover button{margin-top:28px;border:1px solid var(--ink);background:var(--ink);color:white;border-radius:30px;padding:13px 25px;font:10px Arial;letter-spacing:2px;text-transform:uppercase;cursor:pointer}

main{
    overflow:hidden;
    background-image:
       linear-gradient(180deg,rgba(241,244,237,.42),rgba(226,235,227,.38) 65%,rgba(245,242,233,.45)),
        url('wedding-floral-background_old.png');
    background-position:center top;
    background-size:cover;
    background-repeat:no-repeat;
    background-attachment:scroll,fixed;
}
.hero{min-height: auto;padding: 65px 20px 15px;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:center;position:relative}
.hero:before,.hero:after{content:"";position:absolute;width:180px;height:300px;border:1px solid #9db4a4;border-radius:100% 0 100% 0;opacity:.35;transform:rotate(28deg);pointer-events:none}
.hero:before{left:-115px;top:60px}.hero:after{right:-115px;bottom:40px;transform:rotate(208deg)}
.arabic{font-size:clamp(23px,5vw,34px);color:#527567;margin:0 0 26px}
.intro{font-size:15px;line-height:1.9;max-width:510px;color:#526e62}
h1{font-size:clamp(48px,10vw,82px);line-height:1.02;font-weight:400;color:var(--ink);margin:23px 0 8px;text-shadow:0 0 8px #d8c17a,0 0 22px #d8c17a88;animation:nameGlow 4s ease-in-out infinite}
.amp{font-style:italic;color:var(--clay);font-size:.72em}
.weds{font-size:18px;letter-spacing:5px;color:var(--clay);font-style:italic;margin:8px 0}
.date{font:11px Arial;letter-spacing:4px;text-transform:uppercase;color:#648174;margin-top:20px}
.flourish{color:var(--clay);font-size:20px;letter-spacing:10px;margin:28px 0}
.guest{color:#9b6d5b;font-style:italic;font-size:16px;min-height:20px}
.section{width:min(760px,100%);padding:0 15px;margin:0 auto 30px}
.panel{background:rgba(251,250,245,.86);backdrop-filter:blur(2px);border:1px solid var(--line);border-radius:5px;padding:30px 28px;box-shadow:0 15px 35px #1a413014}
.panel-title{text-align:center;font:10px Arial;letter-spacing:4px;text-transform:uppercase;color:#789287;margin-bottom:22px}
.event-grid{display:grid;grid-template-columns:1fr 1fr;gap:0}
.event{padding:18px 20px;border-top:1px solid var(--line);text-align:left}
.event:nth-child(odd){border-right:1px solid var(--line)}
.event strong{display:block;font-size:20px;font-weight:400;margin:8px 0;color:var(--ink)}
.event small{font:10px Arial;letter-spacing:2px;text-transform:uppercase;color:#9b6d5b}
.event p{font-size:13px;line-height:1.7;color:#718278;margin:5px 0}
.location-panel{width:min(760px,calc(100% - 30px));margin:0 auto 34px;padding:26px 28px;background:rgba(251,250,245,.9);backdrop-filter:blur(3px);border:1px solid var(--line);border-radius:8px;box-shadow:0 15px 35px #1a413014;text-align:center}
.location-kicker{font:10px Arial,sans-serif;letter-spacing:3px;text-transform:uppercase;color:#789287}
.location-panel h2{font-size:25px;font-weight:400;margin:10px 0 6px;color:var(--ink)}
.location-panel p{font-size:13px;line-height:1.7;color:#718278;margin:5px 0 16px}
.map-frame{width:100%;height:260px;border:1px solid #cbd8ce;border-radius:9px;display:block;background:#e9eee5}
.location-actions{display:flex;justify-content:center;gap:10px;flex-wrap:wrap;margin-top:15px}
.pill{display:inline-block;border:1px solid #9eb3a5;border-radius:25px;padding:9px 13px;text-decoration:none;color:var(--ink);font:10px Arial;letter-spacing:1px;margin-top:9px}
.countdown{display:flex;justify-content:center;gap:10px;margin:25px auto 38px}
.time{min-width:65px;padding:13px 8px;border:1px solid #9db4a4;background:rgba(248,250,245,.88);text-align:center}
.time b{display:block;font-size:24px;font-weight:400;color:var(--ink)}.time span{font:9px Arial;letter-spacing:2px;color:#789287}
.rsvp{text-align:center;padding:12px 15px 28px}
.rsvp h2{font-size:27px;font-weight:400;margin:0 0 8px}
.rsvp p{font-size:14px;color:#6e8277;line-height:1.7}
.actions{display:flex;justify-content:center;gap:10px;flex-wrap:wrap;margin-top:18px}
.rsvp-response{width:min(520px,100%);margin:20px auto 0;padding:17px 20px;border:1px solid #9db4a4;border-radius:8px;background:#fbfaf5;color:var(--ink);box-shadow:0 10px 28px #1a413014}
.rsvp-response[hidden]{display:none}
.rsvp-response strong{display:block;font-size:19px;font-weight:400;margin-bottom:6px}
.rsvp-response p{margin:0;color:#6e8277;font-size:13px;line-height:1.65}
.rsvp-qr-block{margin:22px auto 0;text-align:center}
.rsvp-qr-block p{margin:0 0 11px;font:10px Arial,sans-serif;letter-spacing:2px;text-transform:uppercase;color:#789287}
.rsvp-qr{display:block;width:150px;height:150px;margin:0 auto;padding:8px;background:#fff;border:1px solid #cbd8ce;border-radius:8px;box-shadow:0 8px 22px #1a413014;object-fit:contain}
.qr-caption{display:block;margin-top:8px;color:#718278;font-size:11px}
.action{border:1px solid var(--ink);background:var(--ink);color:white;border-radius:25px;padding:13px 18px;font:10px Arial;letter-spacing:1.5px;cursor:pointer}
.action.secondary{background:transparent;color:var(--ink)}
.share{text-align:center;padding:12px 15px 55px}
.share h3{font-weight:400;font-size:22px}
.share p{font-size:13px;color:#718278}
.qr{height:112px;width:112px;margin:16px auto;background:repeating-linear-gradient(45deg,#183c37 0 4px,#fbfaf5 4px 8px);border:8px solid white;display:grid;place-items:center;color:#183c37;font:10px Arial}
.fairy-lights{position:fixed;top:0;left:0;right:0;height:36px;z-index:8;display:flex;justify-content:space-around;pointer-events:none;padding:0 5px}.fairy-lights span{width:7px;height:11px;border-radius:50% 50% 45% 45%;background:#f8d77d;box-shadow:0 0 7px 3px #f5d47b,0 0 18px 5px #e5bd62;animation:twinkle 1.8s ease-in-out infinite alternate}.fairy-lights span:nth-child(3n){animation-delay:.7s}.fairy-lights span:nth-child(2n){animation-delay:1.2s}.petal{position:fixed;top:-35px;z-index:7;pointer-events:none;color:#c98f83;text-shadow:0 1px 5px #fff8;font-size:18px;animation:petalFall linear forwards;opacity:.8}.floral-corner{position:absolute;z-index:1;color:#789287;opacity:.55;font-size:clamp(42px,8vw,76px);pointer-events:none;text-shadow:0 2px 8px #fff}.floral-corner.tl{top:18px;left:14px;transform:rotate(-28deg)}.floral-corner.tr{top:18px;right:14px;transform:scaleX(-1) rotate(-28deg)}.floral-corner.bl{bottom:18px;left:14px;transform:scaleY(-1) rotate(-28deg)}.floral-corner.br{bottom:18px;right:14px;transform:scale(-1) rotate(-28deg)}.hero{isolation:isolate}.hero:before,.hero:after{z-index:-1}.section .panel{position:relative;overflow:hidden}.section .panel:before,.section .panel:after{content:none;display:none;position:absolute;color:#91a99a;opacity:.28;font-size:38px}.section .panel:before{top:5px;left:10px}.section .panel:after{bottom:5px;right:10px;transform:rotate(180deg)}button,a,.panel,.time{transition:transform .3s ease,box-shadow .3s ease,background-color .3s ease}.action:hover,.cover button:hover,.pill:hover{transform:translateY(-2px);box-shadow:0 5px 18px #183c3728}.hero,.panel,.rsvp,.share{animation:riseIn .9s ease both}@keyframes twinkle{from{opacity:.45;filter:brightness(.85)}to{opacity:1;filter:brightness(1.5)}}@keyframes softGlow{0%,100%{text-shadow:0 0 5px #d8b65d;opacity:.7}50%{text-shadow:0 0 18px #d8b65d,0 0 30px #d8b65d;opacity:1}}@keyframes nameGlow{0%,100%{text-shadow:0 0 7px #d8c17a,0 0 16px #d8c17a66}50%{text-shadow:0 0 13px #e5ca7e,0 0 30px #e5ca7e,0 0 44px #d8c17a66}}@keyframes petalFall{to{transform:translate3d(var(--drift),110vh,0) rotate(620deg);opacity:.05}}@keyframes riseIn{from{opacity:0;transform:translateY(18px)}to{opacity:1;transform:translateY(0)}}@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation-duration:.01ms!important;animation-iteration-count:1!important;scroll-behavior:auto!important;transition-duration:.01ms!important}}footer{text-align:center;padding:0 15px 38px;font:10px Arial;letter-spacing:3px;color:#789287}
.toast{position:fixed;bottom:22px;left:50%;transform:translateX(-50%);background:var(--ink);color:white;padding:12px 16px;border-radius:25px;font:12px Arial;display:none;z-index:20}
@media(max-width:560px){.event-grid{grid-template-columns:1fr}.event:nth-child(odd){border-right:0}.hero{padding-top:60px}.panel{padding:25px 17px}.cover-inner{min-height:0;padding:30px 20px}.cover-inner .monogram{width:88px;height:88px;flex-basis:88px;margin-bottom:4px}.cover h2{font-size:34px}.location-panel{padding:23px 16px}.map-frame{height:230px}}

.music-btn{position:fixed;right:16px;bottom:18px;z-index:15;width:44px;height:44px;border-radius:50%;border:1px solid var(--ink);background:rgba(251,250,245,.92);color:var(--ink);font-size:18px;cursor:pointer;display:none;place-items:center;box-shadow:0 6px 18px #1a413026}
body.opened .music-btn{display:grid}
.music-btn.playing{animation:musicPulse 2.4s ease-in-out infinite}
@keyframes musicPulse{50%{box-shadow:0 0 0 8px #d8c17a40}}

.scroll-btn{position:fixed;right:16px;bottom:72px;z-index:15;width:44px;height:44px;border-radius:50%;border:1px solid var(--ink);background:rgba(251,250,245,.92);color:var(--ink);font-size:16px;cursor:pointer;display:none;place-items:center;box-shadow:0 6px 18px #1a413026}
body.opened .scroll-btn{display:grid}
/* Floating music and auto-scroll controls*/
.floating-controls {
    position: fixed;
    right: 22px;
    bottom: 25px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.floating-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid #9bb5a8;
    background: rgba(255, 253, 245, 0.95);
    color: #173f39;
    font-size: 21px;
    cursor: pointer;
    box-shadow: 0 3px 12px rgba(0,0,0,.15);
    display: flex;
    align-items: center;
    justify-content: center;
}

.floating-btn:hover {
    background: #173f39;
    color: white;
}
/* Swing animation */
@keyframes lanternSwing {
    0%, 100% {
        transform: rotate(-4deg);
    }
    50% {
        transform: rotate(4deg);
    }
}

/* Glowing animation */
@keyframes lanternGlow {
    0%, 100% {
        opacity: .45;
        transform: scale(.85);
    }
    50% {
        opacity: 1;
        transform: scale(1.15);
    }
}

/* Floating particles */
@keyframes floatingLight {
    0%, 100% {
        opacity: .3;
        transform: translateY(0) scale(.8);
    }
    50% {
        opacity: 1;
        transform: translateY(-15px) scale(1.2);
    }
}

@media(max-width:560px) {
    .hanging-decoration {
        height: 230px;
    }

    .hanging-lantern {
        transform-origin: top center;
        width: 125px;
        height: 145px;
    }
}

/* Scratch Date Section */
.scratch-section {
    text-align: center;
    margin: 24px auto 28px;
}

.scratch-heading {
    font: 10px Arial, sans-serif;
    letter-spacing: 3px;
    color: #d9b84f;
    margin-bottom: 14px;
}

.scratch-container {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.scratch-card {
    position: relative;
    width: 80px;
    height: 80px;
    overflow: hidden;
    border-radius: 9px;
    border: 1px solid #c6a044;
    background: linear-gradient(145deg, #fff4ce, #d6b45a);
    box-shadow: 0 4px 12px #0004;
    touch-action: none;
    user-select: none;
}

.scratch-content {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, #fff5d8, #e6cc82);
    color: #57201c;
}

.scratch-content strong {
    font-family: Georgia, serif;
    font-size: 19px;
    font-weight: normal;
}

.scratch-content span {
    font: 8px Arial, sans-serif;
    letter-spacing: 2px;
    margin-top: 7px;
    color: #8b6828;
}

.scratch-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    cursor: crosshair;
    touch-action: none;
}

.scratch-card.revealed .scratch-canvas {
    opacity: 0;
    pointer-events: none;
    transition: opacity .5s ease;
}

@media(max-width:400px) {
    .scratch-container {
        gap: 8px;
    }

    .scratch-card {
        width: 75px;
        height: 75px;
    }
}

/* =================================
   ANIMATED HANGING ISLAMIC ORNAMENT
================================= */

.hanging-decoration {
    height: 260px;
    width: 100%;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    margin: 0 auto 10px;
    perspective: 600px;
}

/* Hanging chain */
.ornament-chain {
    position: absolute;
    top: 0;
    width: 2px;
    height: 42px;
    background: linear-gradient(
        to bottom,
        transparent,
        #c5a34e,
        #e9d38c
    );
}

/* Ring */
.ornament-ring {
    position: absolute;
    top: 37px;
    width: 18px;
    height: 18px;
    border: 2px solid #c5a34e;
    border-radius: 50%;
    z-index: 2;
}

/* Lantern body */
.hanging-lantern {
    position: absolute;
    top: 49px;
    width: 145px;
    height: 165px;
    border: 2px solid #bd963d;
    border-radius: 75px 75px 9px 9px;
    background: linear-gradient(
        145deg,
        #fff4d5aa,
        #d8b75b33,
        #fff1c455
    );
    box-shadow:
        0 0 15px #d7b45b55,
        inset 0 0 20px #d7b45b33;
    transform-origin: top center;
    animation: lanternSwing 5s ease-in-out infinite;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Golden glow */
.lantern-glow {
    position: absolute;
    width: 105px;
    height: 105px;
    border-radius: 50%;
    background: #eacb7180;
    filter: blur(15px);
    animation: lanternGlow 3s ease-in-out infinite;
}

/* Crescent */
.lantern-star {
    position: relative;
    z-index: 1;
    color: #b58b36;
    font-size: 57px;
    text-shadow: 0 0 15px #e8c76e;
}

/* Decorative patterns */
.lantern-pattern {
    position: relative;
    color: #bd963d;
    font-size: 30px;
    margin-top: 8px;
}

.lantern-bottom {
    position: absolute;
    bottom: 8px;
    color: #bd963d;
    font-size: 22px;
}

/* Floating golden particles */
.ornament-light {
    position: absolute;
    color: #c5a34e;
    font-size: 20px;
    animation: floatingLight 3s ease-in-out infinite;
}

.light-one {
    left: calc(50% - 115px);
    top: 105px;
}

.light-two {
    left: calc(50% + 105px);
    top: 145px;
    animation-delay: 1s;
}

.light-three {
    left: calc(50% + 75px);
    top: 35px;
    animation-delay: 1.7s;
}

/* Swing animation */
@keyframes lanternSwing {
    0%, 100% {
        transform: rotate(-4deg);
    }
    50% {
        transform: rotate(4deg);
    }
}

/* Glowing animation */
@keyframes lanternGlow {
    0%, 100% {
        opacity: .45;
        transform: scale(.85);
    }
    50% {
        opacity: 1;
        transform: scale(1.15);
    }
}

/* Floating particles */
@keyframes floatingLight {
    0%, 100% {
        opacity: .3;
        transform: translateY(0) scale(.8);
    }
    50% {
        opacity: 1;
        transform: translateY(-15px) scale(1.2);
    }
}

@media(max-width:560px) {
    .hanging-decoration {
        height: 230px;
    }

    .hanging-lantern {
        transform-origin: top center;
        width: 125px;
        height: 145px;
    }
}

/* =====================================
   ISLAMIC HANGING ORNAMENT ANIMATION
===================================== */

.hanging-decoration {
    position: relative;
    width: 180px;
    height: 230px;
    margin: 5px auto 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    transform-origin: 50% 0%;
    animation: ornamentSwing 4s ease-in-out infinite;
    cursor: pointer;
    z-index: 5;
}

/* Hanging chain */
.ornament-chain {
    width: 2px;
    height: 38px;
    background: linear-gradient(
        to bottom,
        transparent,
        #c79a35,
        #e5c66c
    );
    box-shadow: 0 0 5px rgba(210, 165, 60, .5);
}

/* Top ring */
.ornament-ring {
    width: 15px;
    height: 15px;
    border: 2px solid #c99c38;
    border-radius: 50%;
    margin-top: -2px;
    position: relative;
}

/* Lantern body */
.hanging-lantern {
    position: relative;
    width: 128px;
    height: 145px;
    margin-top: -1px;
    border: 2px solid #c99c38;
    border-radius: 65px 65px 9px 9px;
    background: linear-gradient(
        145deg,
        rgba(255, 246, 211, .85),
        rgba(225, 190, 104, .25),
        rgba(255, 244, 206, .7)
    );
    box-shadow:
        0 0 15px rgba(205, 158, 52, .18),
        inset 0 0 20px rgba(209, 167, 73, .2);
    overflow: hidden;
    transition: transform .5s ease, box-shadow .5s ease;
}

/* Inner glowing light */
.lantern-glow {
    position: absolute;
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: radial-gradient(
        circle,
        rgba(255, 211, 100, .5),
        rgba(255, 211, 100, .08) 65%,
        transparent 75%
    );
    top: 18px;
    left: 18px;
    animation: lanternGlow 2.5s ease-in-out infinite alternate;
}

/* Crescent */
.lantern-star {
    position: absolute;
    top: 32px;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 38px;
    color: #b88b2f;
    text-shadow: 0 0 10px rgba(211, 166, 65, .7);
    transition: transform .5s ease;
}

/* Decorative pattern */
.lantern-pattern {
    position: absolute;
    bottom: 23px;
    left: 0;
    right: 0;
    text-align: center;
    color: #bd9137;
    font-size: 26px;
    animation: patternTwinkle 2s infinite alternate;
}

.lantern-bottom {
    position: absolute;
    bottom: 5px;
    left: 0;
    right: 0;
    text-align: center;
    color: #b88b2f;
}

/* Floating stars */
.ornament-light {
    position: absolute;
    color: #c69b3d;
    font-size: 17px;
    pointer-events: none;
    animation: floatingStars 2.5s ease-in-out infinite;
}

.light-one {
    top: 95px;
    left: -12px;
}

.light-two {
    top: 125px;
    right: -15px;
    animation-delay: .8s;
}

.light-three {
    top: 55px;
    right: 10px;
    animation-delay: 1.3s;
}

/* Natural swinging movement */
@keyframes ornamentSwing {
    0%, 100% {
        transform: rotate(-3deg);
    }
    50% {
        transform: rotate(3deg);
    }
}

/* Glowing lantern */
@keyframes lanternGlow {
    from {
        opacity: .45;
        transform: scale(.9);
    }
    to {
        opacity: 1;
        transform: scale(1.12);
    }
}

/* Twinkling */
@keyframes patternTwinkle {
    from {
        opacity: .5;
    }
    to {
        opacity: 1;
        text-shadow: 0 0 10px #d8ae52;
    }
}

/* Floating stars */
@keyframes floatingStars {
    0%, 100% {
        opacity: .4;
        transform: translateY(0) scale(.8);
    }
    50% {
        opacity: 1;
        transform: translateY(-9px) scale(1.2);
    }
}

/* Mouse hover interaction */
.hanging-decoration:hover {
    animation-play-state: paused;
}

.hanging-decoration:hover .hanging-lantern {
    transform: scale(1.12);
    box-shadow:
        0 0 25px rgba(218, 171, 65, .65),
        inset 0 0 25px rgba(218, 171, 65, .4);
}

.hanging-decoration:hover .lantern-star {
    transform: rotate(25deg) scale(1.15);
}

.hanging-decoration:hover .lantern-glow {
    opacity: 1;
    transform: scale(1.25);
}

/* Reduce unnecessary space before scratch cards */
.scratch-section {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Mobile */
@media (max-width: 600px) {
    .hanging-decoration {
        width: 150px;
        height: 205px;
        margin-top: 0;
    }

    .hanging-lantern {
        width: 112px;
        height: 130px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hanging-decoration,
    .lantern-glow,
    .lantern-pattern,
    .ornament-light {
        animation: none;
    }
}
/* Remove unwanted bottom image/strip */
html,
body {
    overflow-x: hidden;
}

main {
    position: relative;
    z-index: 1;
}

footer {
    position: relative;
    z-index: 2;
    background: transparent !important;
}

/* Hide unwanted media after the invitation */
body > img:last-of-type {
    display: none !important;
}


/* =========================================
   FINAL INVITATION LAYOUT AND CONTROL FIXES
   ========================================= */

html,
body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

body {
    background-color: var(--pale);
    background-image: url('taj.png');
    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
}

.cover {
    background-image: url('taj.png');
    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;
}

main {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    background-image:
        linear-gradient(
            180deg,
            rgba(241, 244, 237, .42),
            rgba(226, 235, 227, .38) 65%,
            rgba(245, 242, 233, .45)
        ),
        url('wedding-floral-background_old.png');
    background-position: center top;
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: scroll, fixed;
}

/* Keep the music and auto-scroll controls visible after opening. */
.music-btn,
.scroll-btn {
    z-index: 10001;
}

body.opened .music-btn,
body.opened .scroll-btn {
    display: grid;
}

/* Floating controls container, if used by the HTML. */
.floating-controls {
    position: fixed;
    right: 18px;
    bottom: 22px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.floating-btn {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid #9bb5a8;
    background: rgba(255, 253, 245, .96);
    color: #173f39;
    font-size: 21px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(0, 0, 0, .16);
    transition: .3s ease;
}

.floating-btn:hover {
    background: #173f39;
    color: #fff;
    transform: translateY(-3px);
}

footer {
    position: relative;
    z-index: 2;
    background: transparent !important;
}

/* Prevent decorative pseudo-elements from adding unwanted symbols. */
.cover:after,
.cover-inner:before,
.cover-inner:after,
.section .panel:before,
.section .panel:after {
    content: none !important;
    display: none !important;
}

/* Retain the bottom-strip fix from the original stylesheet. */
body > img:last-of-type {
    display: none !important;
}

@media (max-width: 560px) {
    .floating-controls {
        right: 12px;
        bottom: 16px;
        gap: 9px;
    }

    .floating-btn {
        width: 42px;
        height: 42px;
        font-size: 19px;
    }

    .music-btn,
    .scroll-btn {
        width: 42px;
        height: 42px;
    }

    main {
        background-position: center top;
        background-attachment: scroll;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}

/* ==========================================
   MOBILE BACKGROUND + LAYOUT CORRECTIONS
   ========================================== */
@media (max-width: 768px) {
    html, body {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }

    /* Keep the lantern image proportional on phone screens. */
    body {
        background-color: var(--pale);
        background-position: center top;
        background-size: 100% auto;
        background-attachment: scroll;
        background-repeat: repeat-y;
    }

    .cover {
        background-position: center center;
        background-size: cover;
        background-attachment: scroll;
        padding: 18px;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .cover-inner {
        width: min(440px, 100%);
        min-height: 0;
        max-height: calc(100dvh - 52px);
        padding: 26px 20px;
        overflow-y: auto;
    }

    /* The floral artwork is a tall portrait image. Do not use cover or
       fixed attachment on mobile: that enlarges and crops it badly. */
    main {
        background-color: #f7f4e9;
        background-image:
            linear-gradient(180deg, rgba(247,244,233,.34), rgba(239,242,231,.28) 65%, rgba(247,244,233,.34)),
            url('wedding-floral-background_old.png');
        background-position: center top, center top;
        background-size: 100% 100%, 100% auto;
        background-repeat: no-repeat, repeat-y;
        background-attachment: scroll, scroll;
        background-origin: border-box;
    }

    .hero {
        padding: 48px 16px 18px;
    }

    .hero:before,
    .hero:after {
        width: 90px;
        height: 170px;
        opacity: .18;
    }

    .hero:before { left: -65px; }
    .hero:after { right: -65px; }

    h1 {
        font-size: clamp(38px, 11vw, 58px);
        overflow-wrap: anywhere;
    }

    .intro {
        max-width: 100%;
        font-size: 14px;
        line-height: 1.75;
    }

    .section {
        width: 100%;
        padding-left: 12px;
        padding-right: 12px;
    }

    .panel,
    .location-panel {
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        background: rgba(251,250,245,.93);
    }

    .location-panel {
        width: calc(100% - 24px);
        padding: 22px 14px;
    }

    .event {
        padding: 16px 12px;
    }

    .countdown {
        gap: 6px;
        flex-wrap: wrap;
        padding: 0 10px;
    }

    .time {
        min-width: 58px;
        padding: 10px 6px;
    }

    .time b { font-size: 21px; }

    .fairy-lights {
        height: 25px;
    }

    .fairy-lights span {
        width: 5px;
        height: 8px;
        box-shadow: 0 0 5px 2px #f5d47b;
    }

    .floating-controls {
        right: 10px;
        bottom: max(12px, env(safe-area-inset-bottom));
        gap: 8px;
    }

    .floating-btn {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }

    .music-btn,
    .scroll-btn {
        right: 10px;
        width: 40px;
        height: 40px;
    }

    .music-btn { bottom: 12px; }
    .scroll-btn { bottom: 60px; }

    .toast {
        width: calc(100% - 32px);
        max-width: 420px;
        text-align: center;
        bottom: calc(62px + env(safe-area-inset-bottom));
    }
}

@media (max-width: 380px) {
    .cover-inner { padding: 22px 15px; }
    .cover h2 { font-size: 30px; }
    .cover-recipient { font-size: 16px; }
    .cover-recipient.has-name { font-size: 19px; }
    .monogram { width: 82px; height: 82px; font-size: 25px; }
    .weds { font-size: 15px; letter-spacing: 3px; }
    .date { letter-spacing: 2px; }
    .panel { padding: 22px 13px; }
}
/* =================================
   ELEGANT LANGUAGE SWITCH BUTTON
================================= */

.language-toggle {
    position: fixed;
    top: 20px;
    right: 22px;
    z-index: 10001;

    min-width: 105px;
    padding: 11px 19px;

    border: 1px solid #c5a34e;
    border-radius: 30px;

    background: rgba(251, 250, 245, .96);
    color: #183c37;

    font-family: Georgia, serif;
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 1px;

    cursor: pointer;

    box-shadow: 0 4px 15px rgba(24, 60, 55, .16);

    transition: all .3s ease;
}

.language-toggle:hover {
    background: #183c37;
    color: #fff4d5;
    border-color: #d8b45b;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(24, 60, 55, .25);
}

.language-toggle:active {
    transform: scale(.96);
}

/* Hide Google's visible dropdown */
#google_translate_element {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

#google_translate_element select,
.goog-te-gadget {
    display: none !important;
}

/* Remove Google translation top gap */
body {
    top: 0 !important;
}

.goog-te-banner-frame {
    display: none !important;
}

/* Mobile button */
@media (max-width: 560px) {
    .language-toggle {
        top: 12px;
        right: 12px;
        min-width: 88px;
        padding: 9px 13px;
        font-size: 12px;
    }
}

[hidden]{display:none!important}
.create-invitation-toggle{margin:20px auto 0;display:inline-block;border:1px solid #c5a34e;box-shadow:0 4px 14px #183c3720;}
.cover-inner {
    background: rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    border: 1px solid rgba(255, 215, 140, 0.6);
    outline: none;
    box-shadow: none;
    border-radius: 15px;
}

.cover-inner .monogram {
    background: transparent !important;
}

@media (max-width: 768px) {
    .cover {
        background-image: url('taj.png') !important;
        background-size: cover !important;
        background-position: center !important;
        background-attachment: scroll !important;
    }

    .cover-inner {
        width: 90%;
        min-height: 0;
        padding: 25px 15px;
    }

    .cover h2 {
        font-size: clamp(24px, 7vw, 34px);
        overflow-wrap: anywhere;
    }
}