
:root {
    --ivory: #fffaf1;
    --blush: #f7e8e8;
    --rose: #c58d91;
    --dark-rose: #a66e76;
    --gold: #b88970;
    --brown: #76565b;
    --paper-edge: #d7b99d;

    /* Blue colour palette */
    --powder-blue: #dceaf2;
    --soft-blue: #c5dce8;
    --dusty-blue: #91b4c7;
    --deep-blue: #668da4;
    --blue-ink: #58798c;
}

/* RESET */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--brown);
    background: var(--ivory);
}

/* =================================
   OPENING SCREEN
================================= */

.opening-screen {
    min-height: 100svh;
    padding: 35px 18px;
    overflow: hidden;
    position: relative;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    background:
        radial-gradient(
            ellipse at 5% 15%,
            #c5dce8 0%,
            transparent 36%
        ),
        radial-gradient(
            ellipse at 95% 85%,
            #dceaf2 0%,
            transparent 38%
        ),
        radial-gradient(
            ellipse at 50% 30%,
            #fffdfb 0%,
            transparent 60%
        ),
        linear-gradient(
            145deg,
            #f7e9eb,
            #e2edf2 52%,
            #f4e4e7
        );
}

/* OPENING HEADING */

.opening-heading {
    position: relative;
    z-index: 2;
    text-align: center;
    margin-bottom: 55px;
}

.eyebrow {
    font-size: 9px;
    letter-spacing: 4px;
    color: var(--blue-ink);
}

.opening-heading h2 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 29px;
    font-weight: 500;
    margin-top: 12px;
}

.opening-heading p {
    font-size: 10px;
    letter-spacing: 1px;
    color: #718b9a;
    margin-top: 9px;
}

/* SCROLL STAGE */

.scroll-stage {
    position: relative;
    z-index: 2;
    width: min(100%, 340px);
    height: 440px;
    flex-shrink: 0;
}

/* PARCHMENT */

.parchment {
    position: absolute;
    top: 50%;
    left: 0;

    width: 100%;
    height: 0;

    overflow: hidden;

    background:
        radial-gradient(
            ellipse at 50% 20%,
            #fffefa 0%,
            transparent 70%
        ),
        linear-gradient(
            100deg,
            #e2edf0,
            #fffaf1 8%,
            #fffaf1 92%,
            #dce9ed
        );

    border-left: 2px solid #a9c4d1;
    border-right: 2px solid #a9c4d1;

    box-shadow:
        inset 8px 0 12px #91b4c71a,
        inset -8px 0 12px #91b4c71a,
        0 10px 30px #668da426;

    z-index: 1;
}

.parchment-inner {
    position: relative;
    width: 100%;
    height: 404px;
    overflow: hidden;
}

/* INNER BORDER */

.paper-border {
    position: absolute;
    inset: 17px;

    border: 1px solid #b8cbd2;

    pointer-events: none;
    z-index: 1;
}

/* SUBTLE PAPER FLORALS */

.paper-flower {
    position: absolute;
    font-size: 30px;
    line-height: 1;

    color: #91b4c76b;

    pointer-events: none;
    z-index: 0;
}

.flower-left {
    top: 27px;
    left: 24px;
}

.flower-right {
    bottom: 27px;
    right: 24px;
    transform: rotate(180deg);
    color: #c58d916b;
}

/* INVITATION CONTENT */

.invitation-content {
    position: absolute;
    inset: 0;
    z-index: 2;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;
    padding: 35px 24px;

    opacity: 0;
    visibility: hidden;
}

.invitation-content.revealed {
    opacity: 1;
    visibility: visible;
    transition: opacity 1.1s ease;
}

/* ORNAMENTS */

.small-ornament,
.bottom-ornament {
    color: var(--deep-blue);
    font-size: 21px;
    line-height: 1;
}

.bottom-ornament {
    margin-top: 24px;
}

/* INVITATION LABEL */

.invitation-label {
    margin-top: 24px;

    font-size: 8px;
    letter-spacing: 2px;

    color: var(--blue-ink);
}

/* COUPLE NAMES */

.invitation-content h1 {
    margin: 24px 0 20px;

    font-family: 'Great Vibes', cursive;
    font-size: clamp(60px, 16vw, 70px);
    font-weight: 400;
    line-height: 1.12;

    color: var(--brown);
}

.ampersand {
    display: block;

    font-family: 'Cormorant Garamond', serif;
    font-size: 30px;
    font-style: italic;
    line-height: 1;

    color: var(--deep-blue);
}

/* ORNAMENTAL DIVIDER */

.ornamental-divider {
    display: flex;
    align-items: center;
    gap: 12px;

    margin: 5px 0 20px;
}

.ornamental-divider span {
    width: 32px;
    height: 1px;
    background: linear-gradient(
        90deg,
        var(--dusty-blue),
        var(--gold)
    );
}

.ornamental-divider i {
    color: var(--deep-blue);
    font-size: 16px;
    font-style: normal;
}

/* QUOTE */

.invitation-quote {
    max-width: 225px;

    font-family: 'Cormorant Garamond', serif;
    font-size: 19px;
    font-style: italic;
    line-height: 1.5;

    color: #718e9d;
    letter-spacing: 0.2px;
}

/* SCROLL RODS */

.scroll-rod {
    position: absolute;
    top: 50%;
    left: -9px;

    width: calc(100% + 18px);
    height: 18px;

    border-radius: 12px;

    background: linear-gradient(
        to bottom,
        #668da4,
        #dceaf2 25%,
        #b88970 55%,
        #e5d2bd 78%,
        #668da4
    );

    box-shadow:
        0 4px 9px #526f8035,
        inset 0 1px 2px #fff5e7;

    z-index: 4;
}

.rod-cap {
    position: absolute;
    top: -3px;

    width: 13px;
    height: 24px;

    border-radius: 50%;

    background: linear-gradient(
        90deg,
        #668da4,
        #e5d2bd,
        #a8795c
    );

    box-shadow: 0 2px 4px #76565b30;
}

.left-cap {
    left: -3px;
}

.right-cap {
    right: -3px;
}

.top-rod,
.bottom-rod {
    transform: translateY(-50%);
}

.top-rod {
    z-index: 5;
}

.bottom-rod {
    z-index: 4;
}

/* RIBBON BAND */

.ribbon-band {
    position: absolute;
    top: 50%;
    left: -9px;

    width: calc(100% + 18px);
    height: 16px;

    transform: translateY(-50%);

    background: linear-gradient(
        to bottom,
        #b77a80,
        #e4b6b8 45%,
        #b77a80
    );

    box-shadow: 0 3px 7px #76565b30;
    z-index: 6;
}

/* CLICKABLE RIBBON */

.ribbon-trigger {
    position: absolute;
    top: 50%;
    left: 50%;

    width: 105px;
    height: 90px;

    transform: translate(-50%, -50%);

    border: none;
    background: transparent;
    cursor: pointer;

    z-index: 8;

    -webkit-tap-highlight-color: transparent;
}

.ribbon-trigger:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 8px;
    border-radius: 50%;
}

/* RIBBON LOOPS */

.ribbon-loop {
    position: absolute;
    top: 9px;

    width: 40px;
    height: 30px;

    background: linear-gradient(
        135deg,
        #e9bdc0,
        #b77a80
    );

    border: 1px solid #a96d74;
    box-shadow: 0 3px 5px #76565b25;
}

.loop-left {
    left: 7px;
    border-radius: 80% 15% 75% 25%;
    transform: rotate(25deg);
}

.loop-right {
    right: 7px;
    border-radius: 15% 80% 25% 75%;
    transform: rotate(-25deg);
}

/* RIBBON KNOT */

.ribbon-knot {
    position: absolute;
    top: 16px;
    left: 43px;

    width: 20px;
    height: 22px;

    border-radius: 6px;

    background: linear-gradient(
        135deg,
        #f3d1d0,
        #b77a80
    );

    box-shadow: 0 2px 5px #76565b35;
    z-index: 2;
}

/* RIBBON TAILS */

.ribbon-tail {
    position: absolute;
    top: 35px;

    width: 20px;
    height: 35px;

    background: linear-gradient(
        90deg,
        #b77a80,
        #e9bdc0
    );

    clip-path: polygon(
        0 0,
        100% 0,
        100% 100%,
        50% 75%,
        0 100%
    );
}

.tail-left {
    left: 29px;
    transform: rotate(18deg);
}

.tail-right {
    right: 29px;
    transform: rotate(-18deg);
}

/* ROSE-GOLD SEAL */

.ribbon-seal {
    position: absolute;
    left: 50%;
    top: 50%;

    width: 43px;
    height: 43px;

    transform: translate(-50%, -5%);

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;
    border: 2px solid #a87b57;

    background: radial-gradient(
        circle,
        #f7e0c2,
        #c49a72
    );

    box-shadow:
        0 3px 8px #76565b40,
        inset 0 0 0 3px #f6e2c5;

    color: #76565b;
    font-family: 'Cormorant Garamond', serif;
    font-size: 12px;
    font-weight: 600;
}

.ribbon-seal i {
    font-size: 10px;
    margin: 0 2px;
}

/* CLICK INSTRUCTION */

.opening-instruction {
    position: relative;
    z-index: 2;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    margin-top: 42px;

    font-size: 9px;
    letter-spacing: 2px;
    color: var(--blue-ink);

    transition: opacity .4s ease;
}

.instruction-line {
    width: 20px;
    height: 1px;
    background: linear-gradient(
        90deg,
        var(--dusty-blue),
        var(--gold)
    );
}

/* FINAL CAPTION */

.opening-caption {
    position: relative;
    z-index: 2;

    margin-top: 35px;

    font-family: 'Cormorant Garamond', serif;
    font-size: 20px;
    font-style: italic;

    opacity: 0;
    visibility: hidden;
}

.opening-caption.visible {
    opacity: 1;
    visibility: visible;
    transition: opacity 1s ease;
}

/* CONTINUE BUTTON */

.continue-button {
    position: relative;
    z-index: 2;

    margin-top: 22px;
    padding: 13px 25px;

    border: 1px solid var(--deep-blue);
    background: rgba(220, 234, 242, 0.45);
    color: var(--brown);

    font-family: 'Poppins', sans-serif;
    font-size: 10px;
    letter-spacing: 2px;

    cursor: pointer;
}

.continue-button span {
    margin-left: 10px;
}

.continue-button[hidden] {
    display: none;
}

/* BACKGROUND FLORALS */

.background-flower {
    position: absolute;
    pointer-events: none;

    color: #91b4c76b;
    font-size: 55px;

    z-index: 0;
}

.flower-one {
    top: 22px;
    right: 16px;
}

.flower-two {
    bottom: 22px;
    left: 16px;
    color: #c58d916b;
}

/* TEMPORARY PLACEHOLDER */

.invitation-placeholder {
    min-height: 100svh;

    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;

    text-align: center;
    padding: 30px;
}

.invitation-placeholder h2 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 48px;
    margin: 20px 0;
}

/* RIBBON RELEASE */

.scroll-stage.ribbon-released .ribbon-trigger {
    pointer-events: none;
    animation: ribbonUntie .65s ease forwards;
}

.scroll-stage.ribbon-released .ribbon-band {
    animation: ribbonSlide .65s ease forwards;
}

/* Instruction is a sibling of scroll-stage */

.scroll-stage.ribbon-released ~ .opening-instruction {
    opacity: 0;
    pointer-events: none;
}

@keyframes ribbonUntie {
    0% {
        transform: translate(-50%, -50%) scale(1) rotate(0);
        opacity: 1;
    }

    45% {
        transform: translate(-50%, -50%) scale(1.15) rotate(12deg);
    }

    100% {
        transform: translate(130%, -50%) scale(.7) rotate(35deg);
        opacity: 0;
    }
}

@keyframes ribbonSlide {
    to {
        transform: translate(110%, -50%);
        opacity: 0;
    }
}

/* SCROLL OPENING */

.scroll-stage.unrolling .parchment {
    top: 18px;
    height: 404px;

    transition:
        top 4s cubic-bezier(.22, .61, .36, 1),
        height 4s cubic-bezier(.22, .61, .36, 1);
}

.scroll-stage.unrolling .top-rod {
    top: 9px;
    transition: top 4s cubic-bezier(.22, .61, .36, 1);
}

.scroll-stage.unrolling .bottom-rod {
    top: calc(100% - 9px);
    transition: top 4s cubic-bezier(.22, .61, .36, 1);
}

/* SMALL PHONES */

@media (max-width: 360px) {
    .scroll-stage {
        width: min(100%, 300px);
    }

    .opening-heading {
        margin-bottom: 40px;
    }

    .invitation-content h1 {
        font-size: 56px;
    }

    .invitation-quote {
        font-size: 18px;
        max-width: 205px;
    }

    .paper-flower {
        font-size: 25px;
    }
}

/* REDUCED MOTION */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

/* =================================
   MAIN WEDDING INVITATION
================================= */

.main-invitation {
    position: relative;
    min-height: 100vh;
    padding: 75px 20px 45px;

    background:
        radial-gradient(
            ellipse at 0% 5%,
            rgba(197, 220, 232, 0.85),
            transparent 36%
        ),
        radial-gradient(
            ellipse at 100% 45%,
            rgba(220, 234, 242, 0.95),
            transparent 40%
        ),
        radial-gradient(
            ellipse at 0% 100%,
            rgba(197, 220, 232, 0.55),
            transparent 32%
        ),
        #fffaf1;

    color: #76565b;
    text-align: center;
    overflow: hidden;
}

.invitation-container {
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
}

.section-eyebrow {
    font-size: 10px;
    letter-spacing: 3px;
    color: var(--blue-ink);
    margin-bottom: 18px;
}

.invitation-heading {
    font-family: 'Cormorant Garamond', serif;
    font-size: 25px;
    font-weight: 400;
    line-height: 1.4;
    margin-bottom: 22px;
}

.couple-names {
    display: flex;
    flex-direction: column;
    align-items: center;

    font-family: 'Great Vibes', cursive;
    font-size: 66px;
    line-height: 1.05;

    color: #ae806f;
    margin: 20px 0 25px;
}

.couple-names .ampersand {
    font-family: 'Cormorant Garamond', serif;
    font-size: 30px;
    font-style: italic;
    color: var(--deep-blue);
    margin: 5px 0;
}

.invitation-message {
    max-width: 350px;
    margin: 0 auto 35px;

    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    line-height: 2;

    color: #718894;
}

/* COUNTDOWN */

.countdown-wrapper {
    margin: 35px 0 45px;
    padding: 20px 12px 22px;

    border: 1px solid #b8d0dc;
    border-radius: 12px;

    background: linear-gradient(
        135deg,
        #dceaf2,
        #f8eeee 58%,
        #e5f0f4
    );

    box-shadow: 0 8px 22px rgba(102, 141, 164, 0.12);
}

.countdown-title {
    font-size: 10px;
    letter-spacing: 2px;
    color: var(--blue-ink);
    margin-bottom: 20px;
}

.countdown {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.countdown-item {
    width: 68px;
    padding: 13px 5px;

    background: linear-gradient(
        145deg,
        #eaf3f7,
        #f7e8e8
    );

    border: 1px solid #b8d0dc;
    border-radius: 5px;
}

.countdown-item span {
    display: block;
    font-family: 'Cormorant Garamond', serif;
    font-size: 27px;
    color: #58798c;
}

.countdown-item small {
    display: block;
    font-family: 'Poppins', sans-serif;
    font-size: 9px;
    color: #718894;
    margin-top: 3px;
}

/* EVENT HEADING */

.event-heading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 40px 0 25px;
}

.event-heading span {
    width: 35px;
    height: 1px;
    background: linear-gradient(
        90deg,
        var(--dusty-blue),
        var(--gold)
    );
}

.event-heading p {
    font-size: 9px;
    letter-spacing: 1.5px;
    color: var(--blue-ink);
}

/* EVENT CARDS */

.event-cards {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.event-card {
    display: block;
    padding: 25px 18px;

    text-decoration: none;
    color: #76565b;

    background: linear-gradient(
        135deg,
        #ffffff 0%,
        #eaf3f7 55%,
        #f9eeee 100%
    );

    border: 1px solid #b9d0dc;
    border-radius: 9px;

    box-shadow: 0 7px 20px rgba(88, 121, 140, 0.12);

    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
}

.event-card:nth-child(2) {
    background: linear-gradient(
        135deg,
        #f9eeee 0%,
        #eaf3f7 55%,
        #ffffff 100%
    );
}

.event-card:active {
    transform: scale(0.98);
    border-color: var(--deep-blue);
}

.event-icon {
    font-size: 25px;
    color: var(--deep-blue);
    margin-bottom: 8px;
}

.event-type {
    font-size: 9px;
    letter-spacing: 2px;
    color: var(--blue-ink);
    margin-bottom: 8px;
}

.event-card h3 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 26px;
    font-weight: 500;
    margin-bottom: 12px;
}

.event-date,
.event-time {
    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    line-height: 1.8;
}

.event-link {
    display: inline-block;
    margin-top: 15px;
    font-size: 9px;
    letter-spacing: 1.5px;
    color: var(--blue-ink);
}

/* EXPLORE MORE */

.explore-more {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 9px;

    margin-top: 38px;

    text-decoration: none;
    font-size: 10px;
    letter-spacing: 2px;
    color: var(--blue-ink);
}

.explore-arrow {
    font-size: 20px;
    animation: exploreBounce 1.5s infinite;
}

@keyframes exploreBounce {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(6px);
    }
}

/* =================================
   FLORAL SCROLLBAR
================================= */

/* Chrome, Edge and Safari */

::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: #edf4f6;
    border-left: 1px solid #d7e5ea;
}

::-webkit-scrollbar-thumb {
    min-height: 48px;

    border: 2px solid #fffaf1;
    border-radius: 20px;

    background-color: #91b4c7;

    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='30' viewBox='0 0 18 30'%3E%3Cg transform='translate(9 9)' fill='%23fffaf1'%3E%3Cellipse cy='-3.5' rx='2' ry='3.4'/%3E%3Cellipse cy='-3.5' rx='2' ry='3.4' transform='rotate(72)'/%3E%3Cellipse cy='-3.5' rx='2' ry='3.4' transform='rotate(144)'/%3E%3Cellipse cy='-3.5' rx='2' ry='3.4' transform='rotate(216)'/%3E%3Cellipse cy='-3.5' rx='2' ry='3.4' transform='rotate(288)'/%3E%3Ccircle r='1.5' fill='%23b88970'/%3E%3C/g%3E%3C/svg%3E");

    background-repeat: repeat-y;
    background-position: center 4px;
    background-size: 16px 28px;
}

::-webkit-scrollbar-thumb:hover {
    background-color: #668da4;
}

/* Firefox */

html {
    scrollbar-width: thin;
    scrollbar-color: #91b4c7 #edf4f6;
}

/* Touch devices */

@media (hover: none) and (pointer: coarse) {
    ::-webkit-scrollbar {
        width: 4px;
    }
}


/* ==========================================
   FINAL COLOUR BALANCE
   Pink + Ivory dominant, Blue as an accent
========================================== */

/* Opening background */
.opening-screen {
    background:
        radial-gradient(
            ellipse at 8% 15%,
            rgba(220, 234, 242, 0.38),
            transparent 32%
        ),
        radial-gradient(
            ellipse at 90% 85%,
            rgba(220, 234, 242, 0.30),
            transparent 34%
        ),
        radial-gradient(
            ellipse at 50% 30%,
            #fffdfb 0%,
            transparent 60%
        ),
        linear-gradient(
            145deg,
            #f9eeee,
            #f5e7e9 65%,
            #edf2f3
        );
}

/* Parchment: return to warm ivory */
.parchment {
    background:
        radial-gradient(
            ellipse at 50% 20%,
            #fffefa 0%,
            transparent 70%
        ),
        linear-gradient(
            100deg,
            #f3e6d4,
            #fffaf1 8%,
            #fffaf1 92%,
            #e7e1d7
        );

    border-left-color: #d7b99d;
    border-right-color: #d7b99d;
}

/* Restore rose-gold paper border */
.paper-border {
    border-color: #d5b79e;
}

/* Florals: mostly blush with a hint of blue */
.paper-flower {
    color: #c58d9155;
}

.flower-left {
    color: #c58d916b;
}

.flower-right {
    color: #91b4c755;
}

.background-flower {
    color: #c58d9155;
}

.flower-two {
    color: #91b4c755;
}

/* Opening text and ornaments */
.eyebrow,
.opening-instruction,
.invitation-label {
    color: #a66e76;
}

.small-ornament,
.bottom-ornament {
    color: #b88970;
}

.ornamental-divider span {
    background: #b88970;
}

.ornamental-divider i {
    color: #91b4c7;
}

.invitation-quote {
    color: #987276;
}

/* Scroll rods: rose gold dominant with subtle blue */
.scroll-rod {
    background: linear-gradient(
        to bottom,
        #9d6e52,
        #e8c9a9 25%,
        #c39875 55%,
        #dceaf2 78%,
        #9d6e52
    );
}

.rod-cap {
    background: linear-gradient(
        90deg,
        #95694d,
        #e5c3a0,
        #a8795c
    );
}

/* Main invitation background */
.main-invitation {
    background:
        radial-gradient(
            ellipse at 5% 8%,
            rgba(220, 234, 242, 0.42),
            transparent 32%
        ),
        radial-gradient(
            ellipse at 95% 90%,
            rgba(220, 234, 242, 0.35),
            transparent 30%
        ),
        #fffaf1;
}

/* Couple names remain rose gold */
.couple-names {
    color: #b88970;
}

.couple-names .ampersand {
    color: #c58d91;
}

/* Countdown: pink dominant, blue undertone */
.countdown-wrapper {
    background: linear-gradient(
        135deg,
        #f7e8e8,
        #fffaf1 70%,
        #edf3f5
    );

    border-color: #e8d2cc;
    box-shadow: 0 8px 22px rgba(120, 80, 75, 0.07);
}

.countdown-title {
    color: #b88970;
}

.countdown-item {
    background: linear-gradient(
        145deg,
        #f7e8e8,
        #fffaf1 80%,
        #edf3f5
    );

    border-color: #e8d2cc;
}

.countdown-item span {
    color: #a66e76;
}

.countdown-item small {
    color: #876e6f;
}

/* Event cards: white and blush dominant */
.event-card {
    background: linear-gradient(
        135deg,
        #ffffff,
        #f7e8e8 80%,
        #edf3f5
    );

    border-color: #ead8d1;
    box-shadow: 0 5px 18px rgba(120, 80, 75, 0.07);
}

.event-card:nth-child(2) {
    background: linear-gradient(
        135deg,
        #f7e8e8,
        #ffffff 80%,
        #edf3f5
    );
}

.event-icon {
    color: #c58d91;
}

.event-type,
.event-heading p,
.event-link,
.explore-more {
    color: #b88970;
}

.event-heading span {
    background: linear-gradient(
        90deg,
        #b88970,
        #91b4c7,
        #b88970
    );
}

/* Subtle blue scrollbar with floral pattern */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #fff9f6;
    border-left: 1px solid #f1e5e0;
}

::-webkit-scrollbar-thumb {
    background-color: #b5cbd5;
    border: 2px solid #fff9f6;
    border-radius: 20px;

    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='30' viewBox='0 0 18 30'%3E%3Cg fill='%23fffaf1'%3E%3Cellipse cx='9' cy='9' rx='2.4' ry='4'/%3E%3Cellipse cx='9' cy='9' rx='2.4' ry='4' transform='rotate(72 9 9)'/%3E%3Cellipse cx='9' cy='9' rx='2.4' ry='4' transform='rotate(144 9 9)'/%3E%3Cellipse cx='9' cy='9' rx='2.4' ry='4' transform='rotate(216 9 9)'/%3E%3Cellipse cx='9' cy='9' rx='2.4' ry='4' transform='rotate(288 9 9)'/%3E%3Ccircle cx='9' cy='9' r='1.5' fill='%23b88970'/%3E%3C/g%3E%3C/svg%3E");

    background-repeat: repeat-y;
    background-position: center 4px;
    background-size: 16px 28px;
}

::-webkit-scrollbar-thumb:hover {
    background-color: #91b4c7;
}

html {
    scrollbar-color: #b5cbd5 #fff9f6;
}


/* ==========================================
   DELICATE FLORAL BACKGROUND DECORATIONS
========================================== */

/* Opening screen floral corners */

.opening-screen::before,
.opening-screen::after {
    content: "❀";
    position: absolute;
    z-index: 0;
    pointer-events: none;

    font-family: Georgia, serif;
    font-size: 115px;
    line-height: 1;

    color: rgba(197, 141, 145, 0.20);

    text-shadow:
        18px 20px 0 rgba(220, 234, 242, 0.45),
        35px 42px 0 rgba(184, 137, 112, 0.10);
}

.opening-screen::before {
    top: 15px;
    left: -30px;
    transform: rotate(-25deg);
}

.opening-screen::after {
    content: "❁";
    bottom: 15px;
    right: -25px;
    transform: rotate(25deg);

    color: rgba(184, 137, 112, 0.20);
}

/* Main invitation floral corners */

.main-invitation::before,
.main-invitation::after {
    content: "✿";
    position: absolute;
    z-index: 0;
    pointer-events: none;

    font-family: Georgia, serif;
    font-size: 125px;
    line-height: 1;

    color: rgba(197, 141, 145, 0.18);

    text-shadow:
        20px 22px 0 rgba(184, 137, 112, 0.10),
        42px 45px 0 rgba(220, 234, 242, 0.55);
}

.main-invitation::before {
    top: 25px;
    left: -35px;
    transform: rotate(-20deg);
}

.main-invitation::after {
    content: "❀";
    bottom: 20px;
    right: -35px;
    transform: rotate(30deg);

    color: rgba(197, 141, 145, 0.22);
}

/* Keep all invitation content above decorations */

.invitation-container {
    position: relative;
    z-index: 1;
}

/* Existing opening elements remain above background flowers */

.opening-heading,
.scroll-stage,
.opening-instruction,
.opening-caption,
.continue-button {
    position: relative;
    z-index: 2;
}

/* Smaller floral decorations on small phones */

@media (max-width: 360px) {
    .opening-screen::before,
    .opening-screen::after,
    .main-invitation::before,
    .main-invitation::after {
        font-size: 85px;
    }
}

/* ==========================================
   ELEGANT WEDDING EVENT CARDS
========================================== */

.event-cards {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin: 30px auto;
}

/* Main invitation card */

.event-card {
    position: relative;
    display: block;
    width: 100%;
    padding: 30px 20px 25px;
    text-align: center;

    background: #fffaf3;
    border: 1px solid #c9a58d;
    border-radius: 5px;

    box-shadow:
        0 7px 20px rgba(118, 86, 91, 0.07);

    color: inherit;
    text-decoration: none;
}

/* Inner decorative border */

.event-card::before {
    content: "";
    position: absolute;
    inset: 7px;
    border: 1px solid rgba(197, 141, 145, 0.35);
    pointer-events: none;
}

/* Floral ornament */

.event-card .event-icon {
    font-size: 27px;
    color: #c58d91;
    margin-bottom: 12px;
}

/* Event label */

.event-card .event-type {
    color: #b88970;
    font-family: 'Poppins', sans-serif;
    font-size: 9px;
    letter-spacing: 3px;
    margin: 0 0 8px;
}

/* Event name */

.event-card h3 {
    color: #a66e76;
    font-family: 'Cormorant Garamond', serif;
    font-size: 30px;
    font-weight: 500;
    margin: 0;
}

/* Ornamental divider */

.event-card-divider {
    color: #b88970;
    font-size: 20px;
    margin: 12px 0 18px;
}

/* Event information */

.event-detail {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 11px 0;
}

.event-detail span {
    color: #c58d91;
    font-size: 16px;
}

.event-detail p {
    color: #76565b;
    font-family: 'Poppins', sans-serif;
    font-size: 12px;
    margin: 0;
}

/* Map preview */

.event-map {
    position: relative;
    overflow: hidden;
    margin: 20px 5px 0;
    padding: 4px;

    border: 1px solid #d8c0aa;
    border-radius: 3px;
    background: #fff;
}

.event-map iframe {
    display: block;
    width: 100%;
    height: 165px;
    border: 0;
}

/* Directions button */

.event-card .directions-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    margin-top: 18px;
    padding: 10px 23px;

    background: transparent;
    border: 1px solid #b88970;
    border-radius: 30px;

    color: #a66e76;
    font-family: 'Poppins', sans-serif;
    font-size: 11px;
    letter-spacing: 0.5px;
    text-decoration: none;

    box-shadow: none;
    transition: all 0.25s ease;
}

.event-card .directions-button:active {
    background: #f7e8e8;
    transform: scale(0.97);
}

/* Mobile layout */

@media (max-width: 360px) {
    .event-card {
        padding: 27px 15px 22px;
    }

    .event-card h3 {
        font-size: 27px;
    }

    .event-detail p {
        font-size: 11px;
    }

    .event-map iframe {
        height: 145px;
    }
}

/* =================================
   MEMORIES SECTION
================================= */

.memories-section {
    position: relative;
    padding: 85px 20px;
    overflow: hidden;
    background: var(--ivory);
}

.memories-container {
    width: 100%;
    max-width: 850px;
    margin: 0 auto;
}

/* SECTION HEADING */

.memories-heading {
    text-align: center;
    margin-bottom: 65px;
}

.memories-heading h2 {
    font-family: 'Great Vibes', cursive;
    font-size: clamp(2.8rem, 8vw, 4rem);
    font-weight: 400;
    color: var(--dark-rose);
    margin: 12px 0;
}

.memories-heading > p {
    font-family: 'Poppins', sans-serif;
    font-size: 0.85rem;
    font-weight: 300;
    color: var(--brown);
    margin-top: 12px;
}

.memories-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: var(--gold);
}

.memories-divider span {
    width: 45px;
    height: 1px;
    background: var(--gold);
}

.memories-divider i {
    font-size: 1.1rem;
    font-style: normal;
}

/* MEMORY CATEGORIES */

.memory-category {
    margin-bottom: 65px;
}

.memory-category-heading {
    text-align: center;
    margin-bottom: 25px;
}

.memory-category-heading h3 {
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(1.8rem, 5vw, 2.3rem);
    font-weight: 500;
    color: var(--brown);
    margin: 0;
}

.memory-category-heading p {
    font-family: 'Poppins', sans-serif;
    font-size: 0.7rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--gold);
    margin-top: 7px;
}

/* PHOTO GRID */

.memory-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 13px;
}

.memory-photo {
    display: block;
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 4px;
    border: 5px solid #fffdf8;
    box-shadow: 0 4px 15px rgba(118, 86, 91, 0.12);
    cursor: pointer;
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.memory-photo:hover {
    transform: translateY(-5px);
    box-shadow: 0 9px 22px rgba(118, 86, 91, 0.18);
}

/* PHOTO LIGHTBOX */

.memory-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 55px 45px;
    background: rgba(35, 25, 28, 0.94);
}

.memory-lightbox.active {
    display: flex;
}

.memory-lightbox img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border: 5px solid #fffaf1;
    border-radius: 3px;
}

.lightbox-close,
.lightbox-nav {
    position: absolute;
    border: none;
    background: transparent;
    color: #fffaf1;
    cursor: pointer;
    font-family: Arial, sans-serif;
}

.lightbox-close {
    top: 15px;
    right: 22px;
    font-size: 2.5rem;
}

.lightbox-nav {
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.8rem;
    padding: 12px;
}

.lightbox-prev {
    left: 8px;
}

.lightbox-next {
    right: 8px;
}

.lightbox-counter {
    position: absolute;
    bottom: 15px;
    color: #fffaf1;
    font-family: 'Poppins', sans-serif;
    font-size: 0.75rem;
    letter-spacing: 2px;
}

/* MOBILE RESPONSIVENESS */

@media (max-width: 600px) {
    .memories-section {
        padding: 65px 17px;
    }

    .memories-heading {
        margin-bottom: 50px;
    }

    .memory-category {
        margin-bottom: 50px;
    }

    .memory-gallery {
        gap: 8px;
    }

    .memory-photo {
        border-width: 3px;
        border-radius: 3px;
    }

    .memory-category-heading {
        margin-bottom: 18px;
    }

    .memory-category-heading p {
        font-size: 0.62rem;
        letter-spacing: 1.5px;
    }

    .memory-lightbox {
        padding: 45px 35px;
    }

    .lightbox-nav {
        font-size: 1.3rem;
    }
}

/* Center the last photo when it occupies a row alone */
@media (max-width: 600px) {
    .memory-photo:last-child:nth-child(3n + 1) {
        grid-column: 2;
    }
}

/* =================================
   CLOSING SECTION
================================= */

.closing-section {
    position: relative;
    padding: 75px 20px 65px;
    text-align: center;
    background: var(--blush);
    overflow: hidden;
}

.closing-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 35px 20px;
    border: 1px solid var(--paper-edge);
    outline: 1px solid rgba(184, 137, 112, 0.35);
    outline-offset: 6px;
}

.closing-ornament {
    display: block;
    color: var(--gold);
    font-size: 1.3rem;
    margin-bottom: 18px;
}

.closing-eyebrow {
    font-family: 'Poppins', sans-serif;
    font-size: 0.65rem;
    letter-spacing: 3px;
    color: var(--dark-rose);
}

.closing-container h2 {
    font-family: 'Great Vibes', cursive;
    font-size: clamp(2.8rem, 9vw, 4rem);
    font-weight: 400;
    color: var(--dark-rose);
    margin: 18px 0;
}

.closing-container h2 span {
    color: var(--gold);
}

.closing-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: var(--gold);
}

.closing-divider span {
    width: 45px;
    height: 1px;
    background: var(--gold);
}

.closing-divider i {
    font-style: normal;
    font-size: 1.2rem;
}

.closing-message {
    max-width: 330px;
    margin: 25px auto;
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.35rem;
    line-height: 1.6;
    color: var(--brown);
}

.closing-flower {
    font-size: 2.3rem;
    color: var(--rose);
    margin: 20px 0;
}

.closing-date {
    font-family: 'Poppins', sans-serif;
    font-size: 0.65rem;
    letter-spacing: 1.5px;
    color: var(--dark-rose);
    line-height: 2.2;
}

.closing-date span {
    color: var(--gold);
    padding: 0 7px;
}

.closing-footer {
    margin-top: 30px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.55rem;
    letter-spacing: 3px;
    color: var(--gold);
}

/* =================================
   FLOATING MUSIC PLAYER
================================= */

.music-toggle {
    position: fixed;
    right: 20px;
    bottom: 22px;
    z-index: 9998;

    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid var(--gold);
    border-radius: 50%;

    background: rgba(255, 250, 241, 0.95);
    color: var(--dark-rose);

    font-size: 1.5rem;
    cursor: pointer;

    box-shadow: 0 4px 15px rgba(118, 86, 91, 0.2);

    transition:
        transform 0.3s ease,
        background 0.3s ease,
        box-shadow 0.3s ease;
}

.music-toggle:hover {
    transform: scale(1.08);
    background: var(--blush);
    box-shadow: 0 6px 18px rgba(118, 86, 91, 0.25);
}

.music-toggle.playing span {
    animation: musicPulse 1.5s ease-in-out infinite;
}

@keyframes musicPulse {
    0%, 100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }
}

@media (max-width: 600px) {
    .music-toggle {
        width: 44px;
        height: 44px;
        right: 15px;
        bottom: 18px;
    }
}