/*
 * Template "Tropical Beach" (Pernikahan)
 * Modern beach-resort wedding: sea blues and warm sand, palm fronds + monstera + plumeria
 * (inline SVG symbols in sections/_defs.blade.php), slow-moving layered wave dividers
 * (sections/_waves.blade.php), sun-washed photos, Allura (relaxed script) + Jost (clean sans).
 * Colors from the variant: --inv-primary, --inv-accent, --inv-background, --inv-text,
 * --inv-deep, --inv-sea, --inv-sand, --inv-leaf. All classes start with "tb-".
 */

:root {
    --inv-primary: #2a9aa6;
    --inv-accent: #f19a76;
    --inv-background: #fcf8f1;
    --inv-text: #1c3a40;
    --inv-deep: #0e5a66;
    --inv-sea: #bfe5e4;
    --inv-sand: #f0e2c8;
    --inv-leaf: #2f7a58;
    --inv-radius: 18px;

    --tb-script: "Allura", "Great Vibes", cursive;
    --tb-sans: "Jost", "Futura", system-ui, -apple-system, "Segoe UI", sans-serif;
    --tb-col: 100%;
    --tb-muted: color-mix(in srgb, var(--inv-text) 80%, var(--inv-background));
    --tb-band: color-mix(in srgb, var(--inv-primary) 70%, var(--inv-deep));
    --tb-shadow: 0 20px 40px -24px color-mix(in srgb, var(--inv-deep) 55%, transparent);
    --tb-shadow-sm: 0 10px 22px -14px color-mix(in srgb, var(--inv-deep) 55%, transparent);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body.tb-body {
    margin: 0;
    min-height: 100vh;
    background: var(--inv-background);
    color: var(--inv-text);
    font: 400 1rem/1.7 var(--tb-sans);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img { max-width: 100%; }
p { margin: 0; }

.tb-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* ---------- SVG ornament colors ---------- */
.tb-palm { fill: var(--tb-palm, var(--inv-leaf)); }
.tb-palm use:nth-child(4n+1) { fill: color-mix(in srgb, var(--tb-palm, var(--inv-leaf)) 75%, #1d3b2a); }
.tb-palm use:nth-child(4n+2) { fill: color-mix(in srgb, var(--tb-palm, var(--inv-leaf)) 80%, #c9e6a9); }
.tb-palm--light { --tb-palm: color-mix(in srgb, var(--inv-leaf) 65%, #b9dc9a); }
.tb-palm__rib { fill: none; stroke: color-mix(in srgb, var(--inv-leaf) 70%, #20341f); stroke-width: 1.4; stroke-linecap: round; }
.tb-monstera { fill: var(--tb-mon, color-mix(in srgb, var(--inv-leaf) 82%, #0f2a1d)); }
.tb-monstera--light { --tb-mon: color-mix(in srgb, var(--inv-leaf) 80%, #9fd08a); }
.tb-monstera__veins path { fill: none; stroke: color-mix(in srgb, var(--inv-leaf) 45%, #d8f0c8); stroke-width: 1; stroke-linecap: round; opacity: .7; }
.tb-plumeria path { fill: url(#tb-plum-grad); stroke: color-mix(in srgb, var(--inv-accent) 45%, #e8d6b8); stroke-width: .35; }
.tb-plumeria__heart { fill: #eeb53a; }
.tb-stop-edge { stop-color: color-mix(in srgb, var(--inv-accent) 30%, #fff); }
.tb-buds circle { fill: var(--inv-accent); opacity: .85; }
.tb-divider__line { fill: none; stroke: var(--tb-div-line, var(--inv-primary)); stroke-width: 1.6; stroke-linecap: round; }
.tb-divider__leaf { fill: var(--inv-leaf); }

/* ---------- waves: three strips sliding slowly ---------- */
.tb-waves {
    --tb-w1: color-mix(in srgb, var(--inv-sea) 85%, transparent);
    --tb-w2: rgb(255 255 255 / .75);
    --tb-w3: var(--inv-background);
    position: relative;
    height: 38px;
    overflow: hidden;
    pointer-events: none;
}
.tb-wave { position: absolute; left: 0; bottom: 0; width: 200%; height: 100%; display: block; }
.tb-wave--back { fill: var(--tb-w1); }
.tb-wave--mid { fill: var(--tb-w2); bottom: -2px; }
.tb-wave--front { fill: var(--tb-w3); bottom: -1px; height: calc(100% + 1px); }
.tb-waves--sea { --tb-w1: color-mix(in srgb, var(--inv-primary) 40%, transparent); --tb-w2: color-mix(in srgb, var(--inv-primary) 65%, transparent); --tb-w3: var(--tb-band); }
.tb-waves--card { --tb-w1: color-mix(in srgb, var(--inv-sea) 70%, transparent); --tb-w2: rgb(255 255 255 / .6); --tb-w3: #fff; height: 30px; }
.tb-waves--scene { --tb-w1: color-mix(in srgb, var(--inv-primary) 55%, var(--inv-sea)); --tb-w2: rgb(255 255 255 / .8); --tb-w3: var(--inv-sand); position: absolute; left: 0; right: 0; bottom: 0; height: 44%; }
.tb-waves--shore { --tb-w1: color-mix(in srgb, var(--inv-primary) 45%, var(--inv-sea)); --tb-w2: rgb(255 255 255 / .8); --tb-w3: var(--inv-sand); height: 70px; }
.tb-waves--edge { position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; }
.tb-waves--top { margin-bottom: -1px; }
.tb-waves--bottom { margin-top: -1px; transform: scaleY(-1); }

html.inv-anim .tb-wave { will-change: transform; animation: tb-roll var(--tb-roll, 30s) linear infinite; }
html.inv-anim .tb-wave--back { --tb-roll: 38s; }
html.inv-anim .tb-wave--mid { --tb-roll: 26s; animation-direction: reverse; }
html.inv-anim .tb-wave--front { --tb-roll: 20s; }
@keyframes tb-roll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ---------- sun-washed light over photos ---------- */
.tb-sunwash {
    position: absolute; inset: 0; z-index: 1; pointer-events: none;
    background:
        radial-gradient(60% 45% at 88% 6%, rgb(255 222 160 / .65), transparent 70%),
        linear-gradient(205deg, rgb(255 196 140 / .3), transparent 50%);
    mix-blend-mode: screen;
}
html.inv-anim .tb-sunwash { animation: tb-glow 9s ease-in-out infinite alternate; }
@keyframes tb-glow { from { opacity: .7; } to { opacity: 1; } }

/* ---------- page column and wide-screen beach ---------- */
.tb-backdrop { display: none; }

.tb-page {
    position: relative;
    max-width: var(--tb-col);
    margin: 0 auto;
    background:
        radial-gradient(80% 22% at 100% 30%, color-mix(in srgb, var(--inv-sand) 55%, transparent), transparent 70%),
        radial-gradient(80% 22% at 0% 62%, color-mix(in srgb, var(--inv-sea) 40%, transparent), transparent 70%),
        radial-gradient(80% 20% at 100% 92%, color-mix(in srgb, var(--inv-sand) 55%, transparent), transparent 70%),
        var(--inv-background);
    overflow: hidden;
}

@media (min-width: 560px) {
    :root { --tb-col: 440px; }
    .tb-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 0;
        overflow: hidden;
        background: linear-gradient(180deg,
            color-mix(in srgb, var(--inv-sea) 55%, #fff) 0%,
            var(--inv-sea) 30%,
            color-mix(in srgb, var(--inv-primary) 70%, var(--inv-sea)) 52%,
            var(--tb-band) 68%,
            var(--inv-sand) 68%);
    }
    .tb-backdrop__sun {
        position: absolute; top: 8%; left: 12%;
        width: 160px; aspect-ratio: 1; border-radius: 50%;
        background: radial-gradient(circle, #fff6dc 0 35%, color-mix(in srgb, var(--inv-accent) 45%, #ffe2b0) 36% 52%, transparent 72%);
        opacity: .9;
    }
    .tb-backdrop__shore { position: absolute; left: 0; right: 0; top: calc(68% - 69px); }
    .tb-backdrop__palm { position: absolute; width: 380px; height: 380px; overflow: visible; opacity: .55; }
    .tb-backdrop__palm--l { left: -40px; top: -30px; }
    .tb-backdrop__palm--r { right: -40px; bottom: -30px; transform: scale(-1, -1); }
    .tb-page {
        z-index: 1;
        box-shadow: 0 30px 80px -30px color-mix(in srgb, var(--inv-deep) 70%, transparent);
    }
    /* keep the floating buttons inside the column */
    .inv-music { right: calc(50% - var(--tb-col) / 2 + 1rem); }
    .inv-to-top { left: calc(50% - var(--tb-col) / 2 + 1rem); }
    .inv-qr-tab { right: calc(50% - var(--tb-col) / 2); }
}

.tb-preview {
    position: fixed; inset: 0 0 auto; z-index: 60;
    padding: .35rem .75rem; text-align: center;
    font: 500 .72rem/1.3 var(--tb-sans); letter-spacing: .03em;
    color: #fff; background: color-mix(in srgb, var(--inv-deep) 92%, transparent);
}

/* ---------- corner clusters (sway gently) ---------- */
.tb-corner {
    position: absolute;
    z-index: 3;
    width: 46%;
    max-width: 190px;
    height: auto;
    pointer-events: none;
    overflow: visible;
    transform-origin: 0 0;
    filter: drop-shadow(0 6px 8px rgb(0 0 0 / .12));
}
.tb-corner--tl { top: -6px; left: -6px; }
.tb-corner--tr { top: -6px; right: -6px; transform: scaleX(-1); transform-origin: 50% 0; }
.tb-corner--bl { bottom: -6px; left: -6px; transform: scaleY(-1); transform-origin: 0 50%; }
.tb-corner--br { bottom: -6px; right: -6px; transform: scale(-1, -1); transform-origin: 50% 50%; }
.tb-corner--sm { width: 32%; max-width: 135px; }

html.inv-anim .tb-corner { will-change: transform; }
html.inv-anim .tb-corner--tl { animation: tb-sway-tl 6.5s ease-in-out infinite alternate; }
html.inv-anim .tb-corner--tr { animation: tb-sway-tr 7.4s ease-in-out infinite alternate; }
html.inv-anim .tb-corner--bl { animation: tb-sway-bl 7.9s ease-in-out infinite alternate; }
html.inv-anim .tb-corner--br { animation: tb-sway-br 6.8s ease-in-out infinite alternate; }
@keyframes tb-sway-tl { from { transform: rotate(-2.5deg); } to { transform: rotate(2deg); } }
@keyframes tb-sway-tr { from { transform: scaleX(-1) rotate(-2.5deg); } to { transform: scaleX(-1) rotate(2deg); } }
@keyframes tb-sway-bl { from { transform: scaleY(-1) rotate(-2deg); } to { transform: scaleY(-1) rotate(2.5deg); } }
@keyframes tb-sway-br { from { transform: scale(-1, -1) rotate(-2deg); } to { transform: scale(-1, -1) rotate(2.5deg); } }

/* ---------- shared type ---------- */
.tb-label {
    font: 500 .7rem/1.4 var(--tb-sans);
    letter-spacing: .3em;
    text-transform: uppercase;
    color: var(--inv-deep);
}
.tb-label--soft { letter-spacing: .22em; font-size: .64rem; color: color-mix(in srgb, var(--inv-deep) 80%, var(--inv-text)); }
.tb-label--light { color: #fff; }

.tb-names, .tb-title, .tb-person__nick, .tb-event__name, .tb-postcard__title, .tb-and__mark {
    font-family: var(--tb-script);
    font-weight: 400;
}
.tb-names {
    margin: .1rem 0 0;
    font-size: clamp(3rem, 15vw, 3.9rem);
    line-height: 1;
    color: var(--inv-deep);
}
.tb-names__amp { color: var(--inv-accent); font-size: .72em; padding: 0 .08em; }

.tb-title {
    margin: .15rem 0 0;
    font-size: 2.9rem;
    line-height: 1.05;
    color: var(--inv-deep);
}

.tb-divider { display: block; width: 200px; max-width: 66%; height: auto; margin: .45rem auto 0; overflow: visible; }

.tb-icon {
    flex: none; width: 1.05rem; height: 1.05rem;
    fill: none; stroke: var(--inv-deep); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}

.tb-lead { max-width: 30rem; margin: 0 auto 1.3rem; color: var(--tb-muted); font-size: .95rem; }

.tb-card {
    position: relative;
    z-index: 3;
    padding: 1.4rem 1.2rem;
    border-radius: 24px;
    background: #fff;
    box-shadow: var(--tb-shadow);
    border: 1px solid color-mix(in srgb, var(--inv-sand) 80%, transparent);
}

/* ---------- monogram ---------- */
.tb-monogram {
    position: relative; z-index: 3;
    display: inline-flex; align-items: center; justify-content: center; gap: .25rem;
    width: 4.4rem; height: 4.4rem;
    border-radius: 50%;
    font: 400 2rem/1 var(--tb-script);
    color: var(--inv-deep);
    background: color-mix(in srgb, #fff 86%, transparent);
    box-shadow: 0 0 0 1px color-mix(in srgb, #fff 80%, transparent), 0 0 0 5px color-mix(in srgb, #fff 35%, transparent), var(--tb-shadow-sm);
}
.tb-monogram span { padding-top: .2rem; }
.tb-monogram__dot { display: block; width: 4px; height: 4px; border-radius: 50%; background: var(--inv-accent); }
.tb-monogram--small { width: 3.6rem; height: 3.6rem; margin-top: 1rem; font-size: 1.6rem; box-shadow: inset 0 0 0 1px var(--inv-sand), var(--tb-shadow-sm); }

/* ---------- cover ---------- */
.tb-cover {
    position: fixed;
    inset: 0;
    z-index: 30;
    display: flex;
    justify-content: center;
    background: color-mix(in srgb, var(--inv-sea) 70%, transparent);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
}
.tb-cover__panel {
    position: relative;
    width: 100%;
    max-width: var(--tb-col);
    height: 100%;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    background:
        radial-gradient(90% 40% at 50% 100%, color-mix(in srgb, var(--inv-sand) 80%, transparent), transparent 70%),
        var(--inv-background);
}
.tb-cover__photo {
    position: relative;
    flex: 0 0 auto;
    height: clamp(220px, 44vh, 420px);
    background: var(--tb-photo, linear-gradient(170deg, var(--inv-sea), var(--inv-primary))) center 35% / cover no-repeat;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 1.3rem;
}
.tb-cover__shade {
    position: absolute; inset: 0; z-index: 1;
    background: linear-gradient(180deg, color-mix(in srgb, var(--inv-deep) 28%, transparent), transparent 40%, transparent 65%, color-mix(in srgb, var(--inv-sea) 45%, transparent));
}
.tb-cover .tb-corner { width: 40%; max-width: 165px; z-index: 4; }

.tb-cover__body {
    position: relative;
    z-index: 5;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: .6rem 1.5rem 1.6rem;
    text-align: center;
    overflow-y: auto;
}
.tb-names--cover { display: flex; flex-direction: column; align-items: center; line-height: .92; margin-top: .3rem; }
.tb-names--cover .tb-names__amp { font-size: .62em; line-height: 1; }
.tb-cover__date {
    display: inline-flex; align-items: center; gap: .6rem;
    margin-top: .6rem;
    font: 500 .8rem/1.5 var(--tb-sans); letter-spacing: .18em; text-transform: uppercase;
    color: var(--inv-text);
}
.tb-cover__date::before, .tb-cover__date::after { content: ""; width: 1.4rem; height: 1px; background: var(--inv-primary); }
.tb-cover__quote { max-width: 22rem; margin: .6rem auto 0; font-size: .86rem; line-height: 1.5; color: var(--tb-muted); font-style: italic; }

.tb-guest {
    position: relative;
    width: min(17.5rem, 100%);
    margin: 1rem auto;
    padding: .8rem 1rem .85rem;
    border-radius: 18px;
    background: color-mix(in srgb, #fff 82%, transparent);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--inv-primary) 45%, transparent), inset 0 0 0 5px #fff, inset 0 0 0 6px color-mix(in srgb, var(--inv-sand) 90%, transparent), var(--tb-shadow-sm);
}
.tb-guest__label { font: 500 .64rem/1.4 var(--tb-sans); letter-spacing: .26em; text-transform: uppercase; color: var(--tb-muted); }
.tb-guest__name { display: block; margin-top: .2rem; font: 500 1.15rem/1.3 var(--tb-sans); color: var(--inv-deep); overflow-wrap: anywhere; }

.tb-open.inv-button { padding: .82rem 1.7rem; }

.tb-cover--leave { transition: opacity .8s ease, transform .9s cubic-bezier(.65, 0, .35, 1); }
.tb-cover--gone { opacity: 0; transform: translateY(-6%); }

@media (max-height: 700px) {
    .tb-names--cover { font-size: 2.7rem; }
    .tb-cover__quote { display: none; }
    .tb-guest { margin: .7rem auto; }
}

/* ---------- buttons (shared components) ---------- */
.inv-button {
    padding: .72rem 1.35rem;
    background: var(--inv-deep);
    color: #fff;
    font: 500 .84rem/1.2 var(--tb-sans);
    letter-spacing: .06em;
    box-shadow: 0 12px 22px -12px color-mix(in srgb, var(--inv-deep) 85%, transparent);
    transition: transform .2s ease, box-shadow .2s ease;
}
.inv-button:hover { transform: translateY(-1px); }
.inv-button--outline {
    background: #fff;
    color: var(--inv-deep);
    box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--inv-deep) 50%, transparent);
}

/* ---------- hero (top of the page) ---------- */
.tb-hero { position: relative; }
.tb-hero__photo {
    position: relative;
    aspect-ratio: 3 / 4;
    max-height: 90vh;
    width: 100%;
    overflow: hidden;
    background: var(--tb-photo, linear-gradient(170deg, var(--inv-sea), var(--inv-primary))) center 35% / cover no-repeat;
    display: flex;
    align-items: flex-end;
}
.tb-hero__shade {
    position: absolute; inset: 0; z-index: 1;
    background: linear-gradient(180deg, transparent 38%, color-mix(in srgb, var(--inv-deep) 40%, rgb(0 0 0 / .2)) 68%, color-mix(in srgb, var(--inv-deep) 80%, #000) 100%);
}
.tb-hero__text { position: relative; z-index: 2; width: 100%; padding: 0 1.4rem 4rem; text-align: center; color: #fff; }
.tb-names--hero { color: #fff; text-shadow: 0 2px 16px rgb(0 0 0 / .3); }
.tb-names--hero .tb-names__amp { color: color-mix(in srgb, var(--inv-accent) 55%, #fff); }
.tb-hero__date { margin-top: .4rem; font: 500 .78rem/1.5 var(--tb-sans); letter-spacing: .2em; text-transform: uppercase; }
.tb-hero > .tb-waves { position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; }

/* ---------- sections ---------- */
.tb-main { position: relative; }
.tb-section {
    position: relative;
    padding: 3rem 1.4rem;
    text-align: center;
}
.tb-head { position: relative; z-index: 4; margin-bottom: 1.7rem; }

/* opening */
.tb-opening { padding-top: 2.2rem; }
.tb-arabic { margin-bottom: .8rem; font: 1.6rem/1.9 "Amiri", serif; color: var(--inv-deep); }
.tb-opening__greeting { font: 500 1.05rem/1.5 var(--tb-sans); color: var(--inv-deep); }
.tb-opening__message { margin: .8rem auto 0; max-width: 28rem; color: var(--tb-muted); }
.tb-quote {
    position: relative;
    margin: 2.4rem auto 0;
    padding: 1.6rem 1.3rem 1.3rem;
    max-width: 26rem;
    border-radius: 26px;
    background: linear-gradient(170deg, color-mix(in srgb, var(--inv-sea) 70%, #fff), #fff 70%);
    box-shadow: var(--tb-shadow-sm);
    isolation: isolate;
}
.tb-quote__leaf { position: absolute; z-index: -1; top: -2.2rem; left: -1rem; width: 5.5rem; height: 5.5rem; overflow: visible; transform: rotate(-38deg); }
.tb-quote__flower { position: absolute; top: -.9rem; left: 2.6rem; width: 2rem; height: 2rem; overflow: visible; filter: drop-shadow(0 2px 3px rgb(0 0 0 / .15)); }
.tb-quote blockquote { margin: 0; font: italic 400 1rem/1.65 var(--tb-sans); color: var(--inv-text); }
.tb-quote figcaption { margin-top: .7rem; font: 500 .7rem/1.4 var(--tb-sans); letter-spacing: .22em; text-transform: uppercase; color: var(--inv-deep); }

/* couple: zig-zag rows (R3) */
.tb-person {
    position: relative;
    z-index: 3;
    display: grid;
    grid-template-columns: 44% minmax(0, 1fr);
    gap: 1rem;
    align-items: center;
    text-align: left;
}
.tb-person--right { grid-template-columns: minmax(0, 1fr) 44%; text-align: right; }
.tb-person--right .tb-person__photo { order: 2; }
.tb-person__photo { position: relative; isolation: isolate; }
.tb-person__ring {
    position: relative;
    display: block;
    aspect-ratio: 1;
    border-radius: 50%;
    padding: 5px;
    background: #fff;
    box-shadow: 0 0 0 1px color-mix(in srgb, var(--inv-primary) 55%, transparent), 10px 12px 0 0 var(--inv-sand), 0 22px 34px -16px color-mix(in srgb, var(--inv-deep) 65%, transparent);
}
.tb-person--right .tb-person__ring { box-shadow: 0 0 0 1px color-mix(in srgb, var(--inv-primary) 55%, transparent), -10px 12px 0 0 var(--inv-sand), 0 22px 34px -16px color-mix(in srgb, var(--inv-deep) 65%, transparent); }
.tb-person__ring img, .tb-person__empty {
    display: block; width: 100%; height: 100%;
    border-radius: 50%;
    object-fit: cover;
}
.tb-person__empty {
    display: grid; place-items: center;
    background: linear-gradient(160deg, var(--inv-sea), #fff);
    font: 400 3.4rem/1 var(--tb-script); color: var(--inv-deep);
}
.tb-person__leaf { position: absolute; z-index: -1; top: -18%; left: -14%; width: 60%; height: 60%; overflow: visible; transform: rotate(-40deg); }
.tb-person--right .tb-person__leaf { left: auto; right: -14%; transform: rotate(40deg); }
.tb-person__flower { position: absolute; z-index: 2; width: 30%; height: 30%; bottom: 0; right: -2%; overflow: visible; filter: drop-shadow(0 3px 4px rgb(0 0 0 / .18)); }
.tb-person--right .tb-person__flower { right: auto; left: -2%; }
.tb-person__nick { margin: .1rem 0 0; font-size: 2.6rem; line-height: 1; color: var(--inv-deep); }
.tb-person__name { margin-top: .3rem; font: 500 .98rem/1.35 var(--tb-sans); color: var(--inv-text); overflow-wrap: anywhere; }
.tb-person__parents { margin-top: .4rem; font-size: .84rem; line-height: 1.5; color: var(--tb-muted); }
.tb-person__parents strong { color: var(--inv-text); font-weight: 500; }
.tb-ig {
    display: inline-flex; align-items: center; gap: .35rem;
    margin-top: .7rem; padding: .36rem .8rem;
    border-radius: 999px;
    font: 500 .76rem/1.2 var(--tb-sans);
    color: var(--inv-deep); text-decoration: none;
    background: #fff;
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--inv-deep) 40%, transparent), var(--tb-shadow-sm);
    max-width: 100%;
    overflow-wrap: anywhere;
}
.tb-and { position: relative; z-index: 3; display: flex; align-items: center; justify-content: center; gap: .9rem; margin: 1.8rem 0; }
.tb-and__line { width: 3.5rem; height: 1px; background: linear-gradient(90deg, transparent, var(--inv-primary)); }
.tb-and__line:last-child { background: linear-gradient(270deg, transparent, var(--inv-primary)); }
.tb-and__mark {
    display: grid; place-items: center;
    width: 3.3rem; height: 3.3rem; border-radius: 50%;
    padding-top: .3rem;
    font-size: 2.3rem; line-height: 1; color: var(--inv-accent);
    background: #fff;
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--inv-primary) 45%, transparent), var(--tb-shadow-sm);
}

/* countdown: a sea band */
.tb-countdown { padding: 1rem 0; }
.tb-countdown__sea {
    position: relative;
    overflow: hidden;
    padding: 1.4rem 1.4rem 1.8rem;
    color: #fff;
    background:
        radial-gradient(70% 40% at 50% 0%, rgb(255 255 255 / .12), transparent 70%),
        linear-gradient(180deg, var(--tb-band), color-mix(in srgb, var(--inv-deep) 85%, var(--tb-band)) 50%, var(--tb-band));
}
.tb-countdown__sun {
    position: absolute; top: -4rem; right: -4rem;
    width: 13rem; aspect-ratio: 1; border-radius: 50%;
    background: radial-gradient(circle, rgb(255 236 190 / .55) 0 18%, rgb(255 214 150 / .22) 34%, transparent 66%);
    mix-blend-mode: screen;
    pointer-events: none;
}
.tb-head--light { --tb-div-line: rgb(255 255 255 / .8); }
.tb-head--light .tb-label { color: color-mix(in srgb, var(--inv-sea) 60%, #fff); }
.tb-head--light .tb-title { color: #fff; }
.tb-countdown__date { position: relative; z-index: 3; display: inline-flex; align-items: center; gap: .5rem; margin-bottom: 1.3rem; font-weight: 500; letter-spacing: .04em; }
.tb-countdown__date .tb-icon { stroke: #fff; }
.inv-countdown { position: relative; z-index: 3; gap: .5rem; }
.inv-countdown__item {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    flex: none;
    width: 4.4rem; height: 4.8rem; min-width: 0;
    padding: 0;
    border-radius: 18px;
    background: linear-gradient(180deg, rgb(255 255 255 / .2), rgb(255 255 255 / .08));
    box-shadow: inset 0 0 0 1px rgb(255 255 255 / .38), 0 12px 20px -14px rgb(0 0 0 / .5);
}
.inv-countdown__value { font: 500 1.75rem/1 var(--tb-sans); color: #fff; }
.inv-countdown__label { margin-top: .35rem; font: 500 .58rem/1.2 var(--tb-sans); letter-spacing: .16em; text-transform: uppercase; color: #fff; opacity: .9; }
.inv-countdown__actions { position: relative; z-index: 3; margin-top: 1.4rem; }
.inv-countdown__actions .inv-button { font-size: .74rem; padding: .6rem 1rem; background: #fff; color: var(--inv-deep); box-shadow: 0 10px 18px -12px rgb(0 0 0 / .5); }
.inv-countdown__done { position: relative; z-index: 3; font-style: italic; }

/* events (pattern W): rounded cards with a sea header band over a faint, sun-bleached photo of the couple */
.tb-events { isolation: isolate; }
.tb-events::after {
    content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
    background:
        linear-gradient(color-mix(in srgb, var(--inv-background) 78%, transparent), color-mix(in srgb, var(--inv-background) 78%, transparent)),
        var(--tb-photo, none) center 30% / cover no-repeat;
    -webkit-mask: linear-gradient(180deg, transparent, #000 12%, #000 88%, transparent);
    mask: linear-gradient(180deg, transparent, #000 12%, #000 88%, transparent);
}
.tb-collage { position: relative; z-index: 4; height: 10.5rem; max-width: 22rem; margin: .4rem auto 1.8rem; }
.tb-collage__band {
    position: absolute; left: -1.6rem; right: -1.6rem; top: 2.3rem; height: 5.8rem; border-radius: 3rem;
    background: linear-gradient(100deg, color-mix(in srgb, var(--inv-sea) 85%, #fff), color-mix(in srgb, var(--inv-primary) 40%, var(--inv-sea)));
}
.tb-collage__photo {
    position: absolute; width: 58%; height: 7.6rem; object-fit: cover; object-position: center 35%;
    border: 4px solid #fff; box-shadow: var(--tb-shadow);
}
.tb-collage__photo--a { left: 0; bottom: 0; border-radius: 2.4rem 0 2.4rem 0; rotate: -3deg; }
.tb-collage__photo--b { right: 0; top: 0; border-radius: 0 2.4rem 0 2.4rem; rotate: 3deg; }
.tb-collage__flower { position: absolute; left: 50%; top: 46%; width: 2.6rem; height: 2.6rem; translate: -50% -50%; overflow: visible; filter: drop-shadow(0 4px 6px rgb(0 0 0 / .2)); }

.tb-events__list { position: relative; z-index: 3; display: grid; gap: 1.8rem; }
.tb-wcard {
    position: relative; max-width: 24rem; width: 100%; margin: 0 auto; padding-bottom: 1.4rem; overflow: hidden;
    border-radius: 2.2rem; background: color-mix(in srgb, #fff 94%, transparent);
    box-shadow: var(--tb-shadow); text-align: center;
}
.tb-wcard__band {
    position: relative; padding: 1.1rem 1rem 2.7rem;
    background: linear-gradient(160deg, var(--inv-primary), var(--tb-band) 70%, var(--inv-deep));
    color: #fff;
}
.tb-wcard__count { font: 500 .64rem/1.4 var(--tb-sans); letter-spacing: .26em; text-transform: uppercase; opacity: .9; }
.tb-wcard__name { margin: .05rem 0 0; font: 400 2.75rem/1.05 var(--tb-script); color: #fff; text-shadow: 0 2px 10px rgb(0 0 0 / .18); overflow-wrap: anywhere; }
.tb-wcard__photo {
    position: relative; z-index: 3; width: 11rem; max-width: 70%; aspect-ratio: 2 / 1; margin: -1.9rem auto .9rem; overflow: hidden;
    border: 4px solid #fff; border-radius: 999px; box-shadow: var(--tb-shadow-sm); background: var(--inv-sea);
}
.tb-wcard__photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tb-wcard__body { display: grid; justify-items: center; gap: .5rem; padding: 0 1.25rem; }
.tb-wcard__time, .tb-wcard__date, .tb-wcard__dress { display: inline-flex; align-items: center; gap: .45rem; min-width: 0; overflow-wrap: anywhere; }
.tb-wcard__time {
    padding: .3rem .95rem; border-radius: 999px;
    background: color-mix(in srgb, var(--inv-accent) 24%, #fff); color: var(--inv-deep);
    font: 600 1rem/1.3 var(--tb-sans); letter-spacing: .03em;
}
.tb-wcard__time .tb-icon { stroke: color-mix(in srgb, var(--inv-accent) 70%, var(--inv-deep)); }
.tb-wcard__date { font-size: .98rem; font-weight: 500; color: var(--inv-text); }
.tb-wcard__place {
    display: grid; justify-items: center; gap: .1rem; width: 100%; margin-top: .3rem; padding: .8rem .9rem;
    border-radius: 1.3rem; background: color-mix(in srgb, var(--inv-sea) 38%, #fff);
}
.tb-wcard__place .tb-icon { width: 1.2rem; height: 1.2rem; margin-bottom: .15rem; }
.tb-wcard__venue { font-weight: 600; color: var(--inv-deep); overflow-wrap: anywhere; }
.tb-wcard__address { color: var(--tb-muted); font-size: .88rem; line-height: 1.5; overflow-wrap: anywhere; }
.tb-wcard__dress { padding: .25rem .8rem; border-radius: 999px; border: 1px dashed color-mix(in srgb, var(--inv-primary) 55%, transparent); font-size: .88rem; }
.tb-wcard .inv-maps { width: 100%; margin-top: .45rem; }
.inv-maps { text-align: center; }
.inv-maps .inv-button { width: 100%; }

/* love story (pattern L): compact zig-zag along a dashed shoreline */
.tb-zz { position: relative; z-index: 3; list-style: none; margin: 0; padding: 0; }
.tb-zz::before {
    content: ""; position: absolute; top: .5rem; bottom: .5rem; left: 50%; translate: -1px 0;
    border-left: 2px dashed color-mix(in srgb, var(--inv-primary) 55%, transparent);
}
.tb-zz__item {
    position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 2.3rem minmax(0, 1fr);
    align-items: start; column-gap: .6rem;
}
.tb-zz__item + .tb-zz__item { margin-top: 1.8rem; }
.tb-zz__num {
    grid-column: 2; grid-row: 1; justify-self: center; display: grid; place-items: center;
    width: 2.3rem; height: 2.3rem; border-radius: 50%;
    background: var(--inv-primary); color: #fff; font: 500 .74rem/1 var(--tb-sans); letter-spacing: .06em;
    box-shadow: 0 0 0 4px var(--inv-background), 0 0 0 5px color-mix(in srgb, var(--inv-primary) 35%, transparent);
}
.tb-zz__text { grid-column: 1; grid-row: 1; text-align: right; }
.tb-zz__side { grid-column: 3; grid-row: 1; display: flex; flex-direction: column; align-items: flex-start; gap: .6rem; }
.tb-zz__item--flip .tb-zz__text { grid-column: 3; text-align: left; }
.tb-zz__item--flip .tb-zz__side { grid-column: 1; align-items: flex-end; }
.tb-zz__title { margin: 0; font: 400 1.8rem/1 var(--tb-script); color: var(--inv-deep); overflow-wrap: anywhere; }
.tb-zz__rule { display: block; width: 80%; margin: .35rem 0 .4rem auto; border-top: 2px dotted color-mix(in srgb, var(--inv-primary) 60%, transparent); }
.tb-zz__item--flip .tb-zz__rule { margin-left: 0; margin-right: auto; }
.tb-zz__story { color: var(--tb-muted); font-size: .86rem; line-height: 1.55; overflow-wrap: break-word; }
.tb-zz__stamp {
    max-width: 100%; padding: .3rem .5rem;
    font: 500 .62rem/1.3 var(--tb-sans); letter-spacing: .14em; text-transform: uppercase;
    color: var(--inv-deep); background: var(--inv-sand);
    border: 2px dashed #fff; box-shadow: 0 0 0 3px var(--inv-sand), 0 6px 12px -6px rgb(0 0 0 / .35);
    rotate: 3deg;
}
.tb-zz__item--flip .tb-zz__stamp { rotate: -3deg; }
.tb-zz__photo {
    position: relative; width: min(100%, 7.4rem); aspect-ratio: 1; margin: 0; overflow: hidden; border-radius: 50%;
    border: 4px solid #fff; background: var(--inv-sea);
    box-shadow: 0 0 0 1.5px color-mix(in srgb, var(--inv-primary) 45%, transparent), var(--tb-shadow-sm);
}
.tb-zz__photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tb-zz__photo .tb-postcard__sun { width: 2rem; margin-left: -1rem; }

/* a tiny seascape for a moment without a photo */
.tb-postcard__scene {
    position: absolute; inset: 0;
    background: linear-gradient(180deg, color-mix(in srgb, var(--inv-sea) 50%, #fff), var(--inv-sea) 60%);
}
.tb-postcard__sun {
    position: absolute; top: 18%; left: 50%;
    width: 3.2rem; aspect-ratio: 1; margin-left: -1.6rem; border-radius: 50%;
    background: radial-gradient(circle, #fff6dc 0 45%, color-mix(in srgb, var(--inv-accent) 55%, #ffe1ad) 46% 60%, transparent 72%);
}

/* gallery */
.tb-album { position: relative; z-index: 3; }
.tb-album .inv-gallery { gap: .45rem; }
.tb-album .inv-gallery__item { border-radius: 14px; box-shadow: var(--tb-shadow-sm); }
.tb-album .inv-gallery__item:first-child { grid-column: span 2; grid-row: span 2; border-radius: 20px; }

/* live streaming */
.tb-live__card { display: grid; gap: .8rem; justify-items: center; font-size: .95rem; }
.tb-live__badge {
    display: inline-flex; align-items: center; gap: .45rem;
    padding: .3rem .8rem; border-radius: 999px;
    font: 500 .68rem/1.3 var(--tb-sans); letter-spacing: .14em; text-transform: uppercase;
    color: var(--inv-deep); background: color-mix(in srgb, var(--inv-sea) 70%, #fff);
}
.tb-live__badge i { width: .5rem; height: .5rem; border-radius: 50%; background: #d9534f; }
html.inv-anim .tb-live__badge i { animation: tb-blink 1.6s ease-in-out infinite; }
@keyframes tb-blink { 50% { opacity: .3; } }
.tb-live__note { font-size: .9rem; font-style: italic; color: var(--tb-muted); }

/* gift: accounts as compact ocean bank cards, two per row (an odd last card spans both) */
.inv-gift { position: relative; z-index: 3; display: grid; gap: .8rem; max-width: 24rem; margin: 0 auto; text-align: left; }
.inv-gift__accounts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
.inv-gift__account { margin: 0; min-width: 0; }
.inv-gift__account + .inv-gift__account { margin-top: 0; }
.inv-gift__account:last-child:nth-child(odd) { grid-column: 1 / -1; }
.inv-gift__account:not(.inv-gift__address) {
    position: relative;
    overflow: hidden;
    min-height: 9.4rem;
    padding: .8rem .8rem .75rem;
    border-radius: 16px;
    color: #fff;
    background:
        radial-gradient(50% 36% at 90% 10%, rgb(255 226 170 / .4), transparent 70%),
        linear-gradient(145deg, var(--inv-deep), color-mix(in srgb, var(--inv-deep) 45%, var(--inv-primary)));
    box-shadow: 0 16px 28px -16px color-mix(in srgb, var(--inv-deep) 85%, transparent), inset 0 0 0 1px rgb(255 255 255 / .2);
    display: grid;
    grid-template-rows: auto 1fr auto auto;
    font-family: var(--tb-sans);
}
/* a scalloped wave line along the bottom of the card */
.inv-gift__account:not(.inv-gift__address)::after {
    content: "";
    position: absolute; left: 0; right: 0; bottom: 0; height: 2.2rem;
    background:
        radial-gradient(circle at 50% 0, transparent 62%, rgb(255 255 255 / .1) 64%) 0 0 / 1.6rem 1rem repeat-x,
        radial-gradient(circle at 50% 0, transparent 62%, rgb(255 255 255 / .08) 64%) .8rem 1rem / 1.6rem 1.2rem repeat-x;
    pointer-events: none;
}
.inv-gift__bank { margin: 0; min-width: 0; font: 600 .78rem/1.3 var(--tb-sans); letter-spacing: .08em; text-transform: uppercase; overflow-wrap: anywhere; }
.inv-gift__logo { height: 1.5rem; padding: .2rem .45rem; border-radius: .45rem; background: #fff; max-width: 100%; }
.inv-gift__logo img { max-width: 100%; }
.inv-gift__account:not(.inv-gift__address) .inv-gift__number::before {
    content: "";
    display: block;
    width: 2.2rem; height: 1.6rem; margin: 0 0 .5rem; border-radius: 5px;
    background:
        linear-gradient(90deg, transparent 32%, rgb(120 90 40 / .45) 33% 35%, transparent 36% 64%, rgb(120 90 40 / .45) 65% 67%, transparent 68%),
        linear-gradient(0deg, transparent 46%, rgb(120 90 40 / .45) 47% 53%, transparent 54%),
        linear-gradient(135deg, #f6e4b0, #d2b46c 55%, #efd796);
    box-shadow: inset 0 0 0 1px rgb(120 90 40 / .3);
}
.inv-gift__number {
    margin: .7rem 0 .2rem;
    align-self: end;
    font: 500 .98rem/1.3 "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    letter-spacing: .05em;
    text-shadow: 0 1px 2px rgb(0 0 0 / .25);
    overflow-wrap: anywhere;
}
.inv-gift__holder { margin: 0 0 .55rem; font-size: .6rem; font-weight: 600; line-height: 1.35; letter-spacing: .12em; text-transform: uppercase; overflow-wrap: anywhere; }
.inv-gift__account:not(.inv-gift__address) .inv-button--outline {
    position: relative; z-index: 1;
    justify-self: start;
    max-width: 100%;
    padding: .35rem .75rem; font-size: .66rem; letter-spacing: .04em;
    background: rgb(255 255 255 / .18); color: #fff;
    box-shadow: inset 0 0 0 1px rgb(255 255 255 / .65);
}
.inv-gift__address {
    padding: 1.1rem;
    border-radius: 20px;
    background: #fff;
    border: 1px solid color-mix(in srgb, var(--inv-sand) 90%, transparent);
    box-shadow: var(--tb-shadow-sm);
    display: grid; gap: .35rem;
    font-size: .92rem;
}
.inv-gift__address .inv-gift__bank { color: var(--inv-deep); font-size: .72rem; letter-spacing: .2em; }
.inv-gift__address .inv-gift__holder { margin: 0; font-size: 1rem; letter-spacing: 0; text-transform: none; font-weight: 500; }
.inv-gift__address .inv-button { justify-self: start; margin-top: .4rem; }

/* forms (rsvp, wishes) */
.tb-form { text-align: left; }
.inv-form { gap: .9rem; font-family: var(--tb-sans); }
.inv-form label, .inv-form__choices legend { font-size: .84rem; font-weight: 500; color: var(--inv-text); }
.inv-form input:not([type=radio]):not([type=checkbox]), .inv-form select, .inv-form textarea {
    padding: .7rem .9rem;
    border-radius: 14px;
    border: 1.5px solid color-mix(in srgb, var(--inv-primary) 35%, transparent);
    background: color-mix(in srgb, var(--inv-sand) 22%, #fff);
    color: var(--inv-text);
    font: 400 .95rem/1.4 var(--tb-sans);
}
.inv-form input:focus, .inv-form select:focus, .inv-form textarea:focus {
    outline: none;
    border-color: var(--inv-primary);
    background: #fff;
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--inv-primary) 20%, transparent);
}
.inv-form__choices label {
    padding: .45rem .85rem; border-radius: 999px;
    background: color-mix(in srgb, var(--inv-sea) 40%, #fff);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--inv-primary) 35%, transparent);
}
.inv-form .inv-button { justify-self: stretch; }
.inv-form__notice { background: color-mix(in srgb, var(--inv-sea) 60%, #fff); }

/* wishes: compact cards, three per page */
.inv-wishes__list { gap: .55rem; margin-top: 1.3rem; }
.inv-wish {
    padding: .65rem .85rem;
    border-radius: 16px;
    background: color-mix(in srgb, var(--inv-sand) 35%, #fff);
    border: 1px solid color-mix(in srgb, var(--inv-sand) 90%, transparent);
    border-left: 3px solid var(--inv-primary);
    font-family: var(--tb-sans);
}
.inv-wish__name { font: 500 .92rem/1.3 var(--tb-sans); color: var(--inv-deep); }
.inv-wish__message { font-size: .88rem; line-height: 1.5; }
.inv-wish__time { font-size: .68rem; }
.inv-wish__reply { border-left-color: var(--inv-accent); background: #fff; }
.inv-wishes__pager { gap: .9rem; margin-top: 1rem; font-family: var(--tb-sans); }
.inv-wishes__page-button {
    width: 2.2rem; height: 2.2rem;
    display: inline-grid; place-items: center;
    font: 500 1.15rem/1 var(--tb-sans);
    color: var(--inv-deep);
    background: #fff;
    border: 1px solid color-mix(in srgb, var(--inv-primary) 45%, transparent);
    box-shadow: var(--tb-shadow-sm);
    transition: background .2s, color .2s;
}
.inv-wishes__page-button:not(:disabled):hover { background: var(--inv-deep); color: #fff; }
.inv-wishes__page { min-width: 4rem; font-size: .78rem; font-weight: 500; letter-spacing: .1em; color: var(--inv-deep); opacity: 1; }

/* closing */
.tb-closing { padding-bottom: 4rem; }
.tb-closing__photo { position: relative; width: 78%; max-width: 290px; margin: .5rem auto 1.8rem; }
.tb-closing__photo img {
    display: block; width: 100%; aspect-ratio: 4 / 5; object-fit: cover;
    border-radius: 150px 150px 24px 24px;
    box-shadow: 0 0 0 6px #fff, 0 0 0 7px color-mix(in srgb, var(--inv-primary) 55%, transparent), 14px 16px 0 7px var(--inv-sand), var(--tb-shadow);
}
.tb-closing__flower { position: absolute; bottom: -1rem; left: -1rem; width: 3.6rem; height: 3.6rem; overflow: visible; filter: drop-shadow(0 3px 5px rgb(0 0 0 / .2)); }
.tb-closing__message { max-width: 27rem; margin: .7rem auto 0; color: var(--tb-muted); }
.tb-closing__sign { margin-top: 1.1rem; font-weight: 500; font-size: .95rem; color: var(--inv-text); }
.tb-names--closing { font-size: 3.2rem; }

/* check-in QR tab, back to top, branding, bottom menu, music */
.inv-qr-tab {
    background: var(--inv-deep); color: #fff; border-color: transparent;
    font-family: var(--tb-sans); font-weight: 500;
    box-shadow: -6px 8px 20px -10px color-mix(in srgb, var(--inv-deep) 80%, transparent);
}
.inv-qr-sheet__card { font-family: var(--tb-sans); border-radius: 24px; }
.inv-to-top {
    border-radius: 50%;
    background: #fff; color: var(--inv-deep);
    box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--inv-deep) 40%, transparent), var(--tb-shadow-sm);
}
.tb-branding { position: relative; z-index: 3; font: 500 .74rem/1.4 var(--tb-sans); color: var(--inv-text); opacity: .85; }

.inv-nav {
    --inv-nav-bg: color-mix(in srgb, #fff 90%, transparent);
    --inv-nav-text: color-mix(in srgb, var(--inv-deep) 80%, var(--inv-text));
    --inv-nav-active: var(--inv-deep);
    border-color: color-mix(in srgb, var(--inv-sand) 90%, transparent);
    box-shadow: 0 14px 30px -12px color-mix(in srgb, var(--inv-deep) 55%, transparent);
}
.inv-nav--icons { border-radius: 1.4rem; }
.inv-nav--icons .inv-nav__item { border-radius: 50%; }
.inv-nav--icons .inv-nav__item.is-active { box-shadow: 0 0 0 4px #fff, 0 10px 18px -6px color-mix(in srgb, var(--inv-deep) 70%, transparent); }
.inv-music__button { background: var(--inv-deep); box-shadow: 0 0 0 3px #fff, 0 8px 18px -6px color-mix(in srgb, var(--inv-deep) 70%, transparent); }
.inv-autoscroll { font-family: var(--tb-sans); font-weight: 500; }

/* the page ends above the bottom menu */
.tb-page { padding-bottom: 1rem; }
body:has(.inv-nav) .tb-page { padding-bottom: 5rem; }

@media (min-width: 400px) {
    .tb-section { padding-left: 1.6rem; padding-right: 1.6rem; }
    .tb-countdown { padding-left: 0; padding-right: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .tb-corner, .tb-wave, .tb-sunwash { animation: none !important; will-change: auto; }
    .tb-live__badge i { animation: none !important; }
    .inv-button { transition: none; }
    html { scroll-behavior: auto; }
}

/* ---------- motion (data-reveal-sections="rise"): sections rise like a slow swell, the closing photo drifts
   (data-parallax), the wave divider under each heading spreads open and the event photos surface after their card ---------- */
.tb-closing__photo { --inv-parallax: 26px; }
@keyframes tb-spread { from { transform: scaleX(.15); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes tb-surface { from { transform: translateY(14px) scale(.9); opacity: 0; } to { transform: none; opacity: 1; } }
html.inv-anim .tb-head.is-revealed .tb-divider { animation: tb-spread 1.2s .4s cubic-bezier(.16, 1, .3, 1) both; }
html.inv-anim .tb-wcard.is-revealed .tb-wcard__photo,
html.inv-anim .tb-zz__item.is-revealed .tb-zz__photo { animation: tb-surface .9s .45s cubic-bezier(.16, 1, .3, 1) both; }
@media (prefers-reduced-motion: reduce) {
    html.inv-anim .tb-head.is-revealed .tb-divider, html.inv-anim .tb-wcard.is-revealed .tb-wcard__photo,
    html.inv-anim .tb-zz__item.is-revealed .tb-zz__photo { animation: none; }
}

/* ---------- fit: the whole cover (names, guest, button) on one phone screen; a proportionate page end ---------- */

.tb-cover__photo { height: clamp(200px, 36svh, 400px); }
.tb-cover__body { justify-content: space-evenly; padding: .4rem 1.5rem 1.7rem; }
.tb-cover__quote { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 6; overflow: hidden; }
.tb-guest { margin: .7rem auto; }

@media (max-height: 760px) {
    .tb-cover__photo { height: clamp(170px, 33svh, 400px); }
    .tb-names--cover { font-size: clamp(2.5rem, 12vw, 2.9rem); }
    .tb-cover__quote { -webkit-line-clamp: 6; margin-top: .4rem; }
    .tb-cover__date { margin-top: .4rem; }
    .tb-guest { margin: .55rem auto; padding: .65rem 1rem .7rem; }
}
@media (max-height: 700px) {
    /* the base file hid the quote here; it stays, clamped to two lines */
    .tb-cover__quote { display: -webkit-box; }
}
@media (max-height: 660px) {
    .tb-cover__photo { height: clamp(150px, 29svh, 400px); }
    .tb-names--cover { font-size: clamp(2.3rem, 11vw, 2.6rem); line-height: .9; }
    .tb-cover__quote { font-size: .8rem; line-height: 1.45; }
    .tb-cover__body { padding: .2rem 1.4rem 1.6rem; }
    .tb-guest { margin: .4rem auto; }
}

/* page end: the monogram closes the page just above the bottom menu */
.tb-closing { padding-bottom: 1.5rem; }
body:has(.inv-nav) .tb-page { padding-bottom: 1.7rem; }
