/*
 * Kintsugi Emas: wabi-sabi luxury. Sumi ink and raku stoneware glaze, warm washi paper and raw clay, pottery
 * mended with metallic gold, a vermilion hanko seal.
 * Section tones: .ke-tone-washi and .ke-tone-clay (light, a real handmade-paper texture), .ke-tone-glaze (dark,
 * a real raku glaze texture) and .ke-tone-ink (dark, usually over a faint client photo).
 * Colors from the variant: --inv-primary (ink), --inv-accent (gold), --inv-background (washi), --inv-text,
 * --inv-glaze, --inv-glazetext, --inv-bowl (stoneware), --inv-clay, --inv-surface, --inv-ink, --inv-rust (seal).
 * All classes start with "ke-".
 */

:root {
    --inv-primary: #1f1d22;
    --inv-accent: #c9a046;
    --inv-background: #efe5d3;
    --inv-text: #2a241f;
    --inv-glaze: #18171b;
    --inv-glazetext: #f3ebdc;
    --inv-bowl: #2e2b2c;
    --inv-clay: #e2d2b8;
    --inv-surface: #fbf5ea;
    --inv-ink: #141317;
    --inv-rust: #a5482c;
    --inv-radius: 14px;

    --ke-w: 460px;
    /* distance from the viewport edge to the column (0 on phones) */
    --ke-edge: max(0px, calc((100vw - var(--ke-w)) / 2));
    --ke-display: 'Shippori Mincho', 'Hiragino Mincho ProN', 'Yu Mincho', Georgia, serif;
    --ke-sans: 'Zen Kaku Gothic New', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --ke-script: 'Cormorant Garamond', Georgia, serif;

    --ke-washi: url('../img/washi.webp');
    --ke-glaze-tex: url('../img/glaze.webp');
    /* the same textures pre-blended, so no blend mode is needed (iOS Safari draws blend modes over images as plain grey):
       washi-mul = black with alpha (= multiply), glaze-screen = white with alpha (= screen),
       glaze-soft = black/white with alpha (= soft-light over the dark glaze) */
    --ke-washi-mul: url('../img/washi-mul.webp');
    --ke-glaze-screen: url('../img/glaze-screen.webp');
    --ke-glaze-soft: url('../img/glaze-soft.webp');

    /* metallic gold leaf, and a deeper burnished gold for text on washi */
    --ke-gold-bg: linear-gradient(115deg, color-mix(in srgb, var(--inv-accent) 50%, #fff) 0%, var(--inv-accent) 24%, color-mix(in srgb, var(--inv-accent) 62%, #3a2400) 48%, color-mix(in srgb, var(--inv-accent) 62%, #fff) 70%, var(--inv-accent) 86%, color-mix(in srgb, var(--inv-accent) 75%, #3a2400) 100%);
    --ke-gold-deep-bg: linear-gradient(115deg, color-mix(in srgb, var(--inv-accent) 72%, var(--inv-ink)) 0%, color-mix(in srgb, var(--inv-accent) 52%, var(--inv-ink)) 45%, color-mix(in srgb, var(--inv-accent) 80%, var(--inv-ink)) 70%, color-mix(in srgb, var(--inv-accent) 55%, var(--inv-ink)) 100%);
    --ke-gold-text: color-mix(in srgb, var(--inv-accent) 55%, var(--inv-ink));
    --ke-rust: var(--inv-rust, #a5482c);
    --ke-matte: color-mix(in srgb, var(--inv-primary) 88%, var(--inv-ink));

    /* context tokens: washi by default, redefined for the dark tones */
    --ke-bg: var(--inv-background);
    --ke-fg: var(--inv-text);
    --ke-muted: color-mix(in srgb, var(--inv-text) 86%, var(--inv-background));
    --ke-title: var(--inv-ink);
    --ke-label: var(--ke-gold-text);
    --ke-em: var(--ke-gold-deep-bg);
    --ke-seam: var(--ke-gold-text);
    --ke-line: color-mix(in srgb, var(--inv-text) 24%, transparent);
    --ke-line-soft: color-mix(in srgb, var(--inv-text) 12%, transparent);
    --ke-btn-bg: var(--ke-matte);
    --ke-btn-fg: var(--inv-surface);
    --ke-out-fg: var(--inv-ink);
}

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

html { background: var(--inv-glaze); scroll-behavior: smooth; }

body.ke-body {
    margin: 0;
    background: var(--inv-glaze);
    color: var(--inv-text);
    font: 400 1rem/1.75 var(--ke-sans);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img { max-width: 100%; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: inherit; }
figure { margin: 0; }

.ke-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.ke-stop-gold-light { stop-color: color-mix(in srgb, var(--inv-accent) 48%, #fff); }
.ke-stop-gold { stop-color: var(--inv-accent); }
.ke-stop-gold-deep { stop-color: color-mix(in srgb, var(--inv-accent) 62%, #3a2400); }
.ke-stop-bowl-light { stop-color: color-mix(in srgb, var(--inv-bowl) 70%, #fff); }
.ke-stop-bowl { stop-color: var(--inv-bowl); }
.ke-stop-bowl-deep { stop-color: color-mix(in srgb, var(--inv-bowl) 50%, #000); }

.ke-icon { width: 1.1em; height: 1.1em; flex: none; }

/* the dark tokens (cover, hero, glaze and ink sections) */
.ke-cover, .ke-hero, .ke-tone-glaze, .ke-tone-ink {
    --ke-bg: var(--inv-glaze);
    --ke-fg: var(--inv-glazetext);
    --ke-muted: color-mix(in srgb, var(--inv-glazetext) 84%, var(--inv-glaze));
    --ke-title: var(--inv-glazetext);
    --ke-label: color-mix(in srgb, var(--inv-accent) 78%, var(--inv-glazetext));
    --ke-em: var(--ke-gold-bg);
    --ke-seam: var(--inv-accent);
    --ke-line: color-mix(in srgb, var(--inv-glazetext) 28%, transparent);
    --ke-line-soft: color-mix(in srgb, var(--inv-glazetext) 14%, transparent);
    --ke-btn-bg: var(--ke-gold-bg);
    --ke-btn-fg: var(--inv-ink);
    --ke-out-fg: var(--inv-glazetext);
}
.ke-tone-ink { --ke-bg: var(--inv-primary); }

/* gold leaf text (one word of a title, the "&") */
.ke-gold-text {
    background: var(--ke-em); -webkit-background-clip: text; background-clip: text;
    color: transparent; -webkit-text-fill-color: transparent;
}

/* ---------- backdrop (wide screens) and the column ---------- */

.ke-backdrop {
    position: fixed; inset: 0; z-index: 0; overflow: hidden;
    background: var(--ke-glaze-soft) center / cover, var(--inv-glaze);
}
.ke-backdrop svg { display: block; width: 100%; height: 100%; }
.ke-backdrop path { fill: none; stroke: var(--inv-accent); stroke-width: 1.4; stroke-linejoin: round; stroke-linecap: round; opacity: .55; vector-effect: non-scaling-stroke; }

.ke-page {
    position: relative; z-index: 1;
    width: min(100%, var(--ke-w)); min-height: 100vh; margin: 0 auto;
    background: var(--inv-glaze);
    overflow-x: clip;
}
@media (min-width: 520px) {
    .ke-page { box-shadow: 0 0 0 1px color-mix(in srgb, var(--inv-accent) 45%, transparent), 0 40px 90px rgb(0 0 0 / .45); }
}
@media (max-width: 519px) {
    .ke-backdrop { display: none; }
}

.ke-preview {
    position: fixed; z-index: 60; top: 0; left: 0; right: 0;
    width: min(100%, var(--ke-w)); margin: 0 auto; padding: .35rem .75rem;
    background: var(--ke-matte); color: var(--inv-surface);
    font: 500 .68rem/1.3 var(--ke-sans); text-align: center; letter-spacing: .03em;
}

/* ---------- ornaments: seams, divider, hanko, bowl ---------- */

/* the branching seam across a section (drawn once when revealed) */
.ke-seamorn { position: absolute; z-index: 0; left: 0; right: 0; top: 0; height: 4.4rem; pointer-events: none; }
.ke-seamorn svg { display: block; width: 100%; height: 100%; overflow: visible; }
.ke-seamorn path { fill: none; stroke-linejoin: round; stroke-linecap: round; }
.ke-seamorn path { vector-effect: non-scaling-stroke; }
.ke-seamorn__glow { stroke: var(--inv-accent); stroke-width: 7; opacity: .14; }
.ke-seamorn__line { stroke: url(#ke-gold-u); stroke-width: 2.2; }
.ke-seamorn__branch { stroke-width: 1.4; }
.ke-tone-washi .ke-seamorn__line, .ke-tone-clay .ke-seamorn__line { filter: drop-shadow(0 1px 0 rgb(0 0 0 / .18)); }
html.inv-anim .ke-seamorn[data-reveal]:not(.is-revealed) svg { clip-path: inset(0 100% 0 0); }
html.inv-anim .ke-seamorn[data-reveal]:not(.is-revealed) .ke-seamorn__glow { opacity: 0; }
html.inv-anim .ke-seamorn[data-reveal] svg { clip-path: inset(0 0 0 0); transition: clip-path 1.8s cubic-bezier(.6, 0, .3, 1) .3s; }
html.inv-anim .ke-seamorn--b[data-reveal]:not(.is-revealed) svg { clip-path: inset(0 0 0 100%); }
html.inv-anim .ke-seamorn .ke-seamorn__glow { transition: opacity 1s ease 1.6s; }

.ke-divider { display: flex; align-items: center; justify-content: center; gap: .3rem; margin: .8rem auto 0; }
.ke-divider__line { width: 3.4rem; height: 1px; background: linear-gradient(90deg, transparent, var(--ke-line)); }
.ke-divider__line--end { transform: scaleX(-1); }
.ke-divider__seam { width: 4rem; height: .9rem; overflow: visible; }
.ke-divider__seam path { fill: none; stroke: var(--ke-seam); stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
.ke-divider__seam .ke-divider__branch { stroke-width: 1; }

/* hanko: a vermilion seal with the monogram stacked, slightly uneven like a real stamp */
.ke-hanko {
    display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: .05em;
    width: 2.9rem; padding: .35rem 0 .4rem;
    border-radius: 5px 7px 4px 6px;
    background:
        radial-gradient(circle at 30% 20%, rgb(255 255 255 / .14), transparent 55%),
        var(--ke-rust);
    box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--ke-rust) 70%, #fff 30%), inset 0 0 0 3.5px var(--ke-rust), 0 6px 14px -6px rgb(0 0 0 / .55);
    color: #fff4ea; font: 700 1.05rem/1.05 var(--ke-display);
    transform: rotate(-4deg);
}

/* the raku bowl emblem */
.ke-bowl { position: relative; margin: 0 auto; }
.ke-bowl svg { display: block; width: 100%; height: auto; overflow: visible; }
.ke-bowl__shadow { fill: rgb(0 0 0 / .35); }
.ke-bowl__tex { opacity: .45; }
.ke-bowl__mouth { fill: url(#ke-bowl-inside); stroke: color-mix(in srgb, var(--inv-bowl) 50%, #fff); stroke-width: 1; stroke-opacity: .5; }
.ke-bowl__lip { fill: none; stroke: rgb(255 255 255 / .16); stroke-width: 1.4; }
.ke-bowl__chip { fill: url(#ke-gold); stroke: color-mix(in srgb, var(--inv-accent) 60%, #3a2400); stroke-width: .6; }
.ke-bowl__seams { filter: drop-shadow(0 0 2px color-mix(in srgb, var(--inv-accent) 55%, transparent)); }
.ke-bowl__seams path { fill: none; stroke: url(#ke-gold); stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 0; }
.ke-bowl__seams path:nth-child(2), .ke-bowl__seams path:nth-child(4) { stroke-width: 1.6; }
/* section bowls: the seams draw when the bowl is revealed */
html.inv-anim .ke-bowl[data-reveal]:not(.is-revealed) .ke-bowl__seams path { stroke-dashoffset: 1; }
html.inv-anim .ke-bowl[data-reveal] .ke-bowl__seams path { transition: stroke-dashoffset 1.3s cubic-bezier(.6, 0, .3, 1) .5s; }
html.inv-anim .ke-bowl[data-reveal] .ke-bowl__seams path:nth-child(even) { transition-delay: 1.1s; }

.ke-kicker {
    position: relative; z-index: 2;
    font: 500 .72rem/1.4 var(--ke-sans); letter-spacing: .38em; text-transform: uppercase;
    color: var(--ke-label);
}

.ke-amp { font: italic 500 1.05em/1 var(--ke-script); text-transform: none; color: var(--inv-accent); }
.ke-tone-washi .ke-amp, .ke-tone-clay .ke-amp { color: var(--ke-gold-text); }

/* ---------- photo backgrounds and section tones ---------- */

.ke-bgphoto { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.ke-bgphoto img { position: absolute; inset: -40px 0; width: 100%; height: calc(100% + 80px); object-fit: cover; opacity: .5; }
.ke-bgphoto::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(180deg, color-mix(in srgb, var(--ke-bg) 66%, transparent), color-mix(in srgb, var(--ke-bg) 84%, transparent) 42%, var(--ke-bg) 94%);
}
.ke-bgphoto--light img { opacity: .5; filter: saturate(.75) sepia(.2); }
.ke-bgphoto--light::after { background: linear-gradient(180deg, color-mix(in srgb, var(--ke-bg) 30%, transparent), color-mix(in srgb, var(--ke-bg) 72%, transparent) 30%, color-mix(in srgb, var(--ke-bg) 88%, transparent) 52%, var(--ke-bg) 86%); }
.ke-bgphoto--clay::after { background: linear-gradient(180deg, color-mix(in srgb, var(--ke-bg) 35%, transparent), color-mix(in srgb, var(--ke-bg) 78%, transparent) 40%, color-mix(in srgb, var(--ke-bg) 86%, transparent) 70%, var(--ke-bg) 96%); }

.ke-main { position: relative; background: var(--inv-background); }

.ke-section {
    position: relative; overflow: hidden; isolation: isolate;
    padding: 4.6rem 1.5rem;
    text-align: center; color: var(--ke-fg);
    background: var(--ke-bg);
}
/* the material texture, laid over the photo background, under the content */
.ke-section::after {
    content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none;
}
.ke-tone-washi { --ke-bg: var(--inv-background); }
.ke-tone-washi::after { background: var(--ke-washi-mul) center / cover no-repeat; opacity: .45; }
.ke-tone-clay {
    --ke-bg: var(--inv-clay);
    --ke-muted: color-mix(in srgb, var(--inv-text) 90%, var(--inv-clay));
    background:
        radial-gradient(90% 60% at 50% 0, color-mix(in srgb, var(--inv-surface) 45%, transparent), transparent 70%),
        var(--inv-clay);
}
.ke-tone-clay::after { background: var(--ke-washi-mul) center / cover no-repeat; opacity: .45; }
.ke-tone-glaze {
    background:
        radial-gradient(90% 55% at 30% 0, color-mix(in srgb, var(--inv-bowl) 60%, transparent), transparent 70%),
        var(--inv-glaze);
}
.ke-tone-glaze::after { background: var(--ke-glaze-screen) center / cover; opacity: .2; }
.ke-tone-ink::after { background: var(--ke-glaze-screen) center / cover; opacity: .1; }

.ke-section > * { position: relative; z-index: 1; }
.ke-section > .ke-bgphoto, .ke-section > .ke-seamorn { position: absolute; z-index: 0; }

.ke-heading { margin-bottom: 2.2rem; }
.ke-heading__label { font: 500 .7rem/1.4 var(--ke-sans); letter-spacing: .36em; text-transform: uppercase; color: var(--ke-label); }
.ke-heading__title { margin-top: .4rem; font: 600 clamp(2rem, 9vw, 2.45rem)/1.22 var(--ke-display); color: var(--ke-title); letter-spacing: .01em; }

.ke-lead { max-width: 24rem; margin: -.6rem auto 1.8rem; color: var(--ke-muted); font-size: .95rem; }

/* washi cards: handmade paper on a warm surface */
.ke-card, .ke-plate, .inv-gift__account {
    background-color: var(--inv-surface);
    background-image: var(--ke-washi-mul);
    background-size: 300px auto;
}
.ke-plate { background-size: cover; background-repeat: no-repeat; background-position: center; }
.ke-card {
    position: relative; color: var(--inv-text);
    border-radius: 18px;
    box-shadow: inset 0 0 0 1px var(--ke-line-soft), 0 26px 44px -32px rgb(0 0 0 / .5);
}

/* ---------- buttons (shared components) ---------- */

.inv-button {
    gap: .55rem; padding: .85rem 1.5rem; border-radius: 999px;
    background: var(--ke-btn-bg); color: var(--ke-btn-fg);
    font: 700 .74rem/1.2 var(--ke-sans); letter-spacing: .16em; text-transform: uppercase;
    text-decoration: none;
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--inv-accent) 65%, transparent), 0 14px 24px -16px rgb(0 0 0 / .6);
}
.inv-button--outline {
    background: transparent; color: var(--ke-out-fg);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ke-out-fg) 45%, transparent);
}
.inv-button--outline:hover { background: color-mix(in srgb, var(--ke-out-fg) 7%, transparent); }
.inv-button .ke-icon { width: 1.1rem; height: 1.1rem; color: var(--inv-accent); }
.ke-cover .inv-button .ke-icon, .ke-tone-glaze .inv-button:not(.inv-button--outline) .ke-icon, .ke-tone-ink .inv-button:not(.inv-button--outline) .ke-icon { color: currentColor; }
.inv-button--outline .ke-icon { color: var(--ke-label); }

.ke-pill {
    display: inline-flex; align-items: center; gap: .4rem; margin-top: .8rem; padding: .42rem .85rem;
    border-radius: 999px; color: var(--ke-title); text-decoration: none;
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ke-title) 35%, transparent);
    font: 500 .76rem/1 var(--ke-sans); letter-spacing: .02em;
    max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    transition: background .25s ease;
}
.ke-pill .ke-icon { color: var(--ke-label); }
.ke-pill:hover { background: color-mix(in srgb, var(--ke-title) 6%, transparent); }

/* ---------- cover ---------- */

.ke-cover {
    position: fixed; inset: 0; z-index: 30;
    width: min(100%, var(--ke-w)); margin: 0 auto;
    display: flex; overflow-x: hidden; overflow-y: auto;
    color: var(--ke-fg);
    background:
        radial-gradient(80% 50% at 50% 30%, color-mix(in srgb, var(--inv-bowl) 55%, transparent), transparent 75%),
        var(--ke-glaze-soft) center / cover,
        var(--inv-glaze);
}
/* the cover photo, blurred and faint, gives the glaze depth */
.ke-cover__wash {
    position: absolute; inset: -30px; z-index: 0; pointer-events: none;
    background: var(--ke-photo) center / cover no-repeat;
    filter: blur(22px) saturate(.8); opacity: .3;
}
.ke-cover__wash::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, color-mix(in srgb, var(--inv-glaze) 40%, transparent), color-mix(in srgb, var(--inv-glaze) 75%, transparent) 55%, var(--inv-glaze)); }
.ke-cover__inner {
    position: relative; z-index: 2;
    width: 100%; min-height: 100%; margin: auto; padding: 2.4rem 1.6rem 2.4rem;
    display: flex; flex-direction: column; align-items: center; justify-content: space-evenly; gap: .5rem;
    text-align: center;
}

/* the photo in a hand-thrown ceramic frame: an organic round with a gold rim and a gold seam through it */
.ke-vessel {
    --ke-shape: 45% 55% 47% 53% / 55% 45% 56% 44%;
    position: relative;
    width: min(70vw, 292px); aspect-ratio: 1 / 1.04; margin: .5rem 0 .3rem; padding: 7px;
    /* the gold rim is the vessel itself (no layer behind the photo: Safari once painted that as a dark square) */
    border-radius: var(--ke-shape); background: var(--ke-gold-bg);
    box-shadow: 0 30px 50px -24px rgb(0 0 0 / .8), 0 0 40px -8px color-mix(in srgb, var(--inv-accent) 35%, transparent);
}
.ke-vessel__photo {
    position: relative; overflow: hidden; display: grid; place-items: center;
    width: 100%; height: 100%; border-radius: var(--ke-shape);
    background:
        var(--ke-photo, none) center 28% / cover no-repeat,
        radial-gradient(circle at 35% 30%, color-mix(in srgb, var(--inv-bowl) 70%, #fff), var(--inv-bowl) 60%, color-mix(in srgb, var(--inv-bowl) 55%, #000));
    box-shadow: inset 0 0 0 3px var(--inv-glaze), inset 0 0 0 4px rgb(255 255 255 / .18), inset 0 -40px 50px -36px rgb(0 0 0 / .55);
}
.ke-vessel--empty .ke-vessel__photo { background: radial-gradient(circle at 40% 30%, color-mix(in srgb, var(--inv-bowl) 60%, var(--inv-glaze)), var(--inv-glaze) 75%); }
.ke-bowl--cover { width: 80%; margin-top: 8%; }
.ke-vessel--empty .ke-vessel__seam { display: none; }
.ke-vessel__seam { position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.ke-vessel__seam path { fill: none; stroke: url(#ke-gold-u); stroke-width: 1; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 0; }
.ke-vessel__seam .ke-vessel__branch { stroke-width: .65; }
.ke-vessel__seam .ke-vessel__glow { stroke: var(--inv-accent); stroke-width: 3; opacity: .25; stroke-dasharray: none; }
.ke-hanko--cover { position: absolute; z-index: 3; right: -4%; bottom: 6%; }
/* a branching gold seam across the glaze behind the cover (static: the cover's one moment is the photo's seam) */
.ke-cover > .ke-seamorn { z-index: 1; top: auto; bottom: -4%; opacity: .75; }

/* opening moment: the photo fades in with a slight zoom, then the seam draws through it */
html.inv-anim .ke-vessel { animation: ke-vessel-in 1.3s cubic-bezier(.2, .7, .2, 1) .15s both; }
html.inv-anim .ke-vessel__seam path:not(.ke-vessel__glow) { animation: ke-draw 1.2s cubic-bezier(.6, 0, .3, 1) .75s both; }
html.inv-anim .ke-vessel__seam .ke-vessel__branch { animation-delay: 1.35s; animation-duration: .8s; }
html.inv-anim .ke-vessel__seam .ke-vessel__glow { animation: ke-fade-in .8s ease 1.6s both; }
html.inv-anim .ke-hanko--cover { animation: ke-stamp .5s cubic-bezier(.3, 1.4, .5, 1) 1.5s both; }
html.inv-anim .ke-bowl--cover .ke-bowl__seams path { animation: ke-draw 1.2s cubic-bezier(.6, 0, .3, 1) .8s both; }
@keyframes ke-vessel-in { from { opacity: 0; transform: scale(.94); } to { opacity: 1; transform: none; } }
@keyframes ke-draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes ke-fade-in { from { opacity: 0; } }
@keyframes ke-stamp { from { opacity: 0; transform: rotate(-4deg) scale(1.5); } to { opacity: 1; transform: rotate(-4deg); } }

.ke-cover__names {
    display: flex; flex-wrap: wrap; justify-content: center; align-items: baseline; gap: 0 .45rem;
    font: 600 clamp(2.1rem, 9.5vw, 2.6rem)/1.1 var(--ke-display); color: var(--ke-title);
    letter-spacing: .01em; overflow-wrap: anywhere; text-shadow: 0 2px 18px rgb(0 0 0 / .4);
}
.ke-cover__names .ke-amp { font-size: .85em; }
.ke-cover__date { font: 500 .74rem/1.4 var(--ke-sans); letter-spacing: .34em; color: var(--ke-label); }
.ke-cover__quote { max-width: 21rem; font: 500 .84rem/1.5 var(--ke-display); color: var(--ke-muted); }

.ke-guest {
    position: relative; width: min(100%, 18rem); margin-top: .3rem; padding: .7rem 1.1rem .75rem;
    border-radius: 4px;
    background: color-mix(in srgb, var(--inv-glazetext) 7%, transparent);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--inv-accent) 55%, transparent);
    -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}
/* a gold seam mending the card's top-right corner */
.ke-guest::after {
    content: ''; position: absolute; top: -1px; right: 14%; width: 2.6rem; height: 1.4rem;
    background: var(--ke-gold-bg);
    clip-path: polygon(0 0, 8% 0, 40% 46%, 58% 40%, 100% 100%, 92% 100%, 54% 50%, 36% 56%);
}
.ke-guest__label { font: 500 .6rem/1.4 var(--ke-sans); letter-spacing: .32em; text-transform: uppercase; color: var(--ke-label); }
.ke-guest__name { margin-top: .15rem; font: 600 1.06rem/1.3 var(--ke-display); color: var(--ke-title); overflow-wrap: anywhere; }
.ke-guest__note { margin-top: .2rem; font: 400 .74rem/1.45 var(--ke-sans); color: var(--ke-muted); }

.ke-open { margin-top: .4rem; }

/* with a photo: the photo full-bleed over the top of the screen, melting into the glaze; the words on the melt */
.ke-cover--photo { --ke-ph: min(133vw, 600px); }
.ke-cover--photo .ke-cover__inner { justify-content: flex-end; gap: .4rem; padding-top: calc(var(--ke-ph) * .56); }
.ke-cover--photo .ke-kicker { position: absolute; top: 2rem; left: 0; right: 0; text-shadow: 0 1px 10px rgb(0 0 0 / .6); }
.ke-cover--photo .ke-vessel {
    position: absolute; z-index: -1; inset: 0 0 auto; width: auto; height: var(--ke-ph); aspect-ratio: auto;
    margin: 0; padding: 0; border-radius: 0; background: none; box-shadow: none;
}
.ke-cover--photo .ke-vessel__photo {
    border-radius: 0; box-shadow: none; background-position: center 28%;
    -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent 100%); mask-image: linear-gradient(180deg, #000 55%, transparent 100%);
}
.ke-cover--photo .ke-vessel__photo::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(180deg, color-mix(in srgb, var(--inv-glaze) 55%, transparent) 0%, transparent 16%, transparent 44%, color-mix(in srgb, var(--inv-glaze) 70%, transparent) 72%, var(--inv-glaze) 96%);
}
/* only the seam in the top-right corner (the other one would run through the words) */
.ke-cover--photo .ke-vessel__seam path:nth-of-type(even) { display: none; }
.ke-cover--photo .ke-vessel__seam { inset: 0 0 auto auto; width: 70%; height: 60%; }
.ke-cover--photo .ke-hanko--cover { right: 1.1rem; bottom: 22%; }
.ke-cover--photo .ke-cover__wash { display: none; }

/* short screens: the guest card and "Buka Undangan" stay above the fold */
@media (max-height: 760px) {
    .ke-cover__inner { gap: .35rem; padding-block: 2rem; }
    .ke-cover--photo { --ke-ph: min(125vw, 520px); }
    .ke-vessel { width: min(58vw, 230px); margin: .3rem 0 .1rem; }
    .ke-cover--photo .ke-vessel { width: auto; margin: 0; }
    .ke-hanko--cover { width: 2.5rem; font-size: .92rem; }
    .ke-cover__names { font-size: clamp(2rem, 9vw, 2.3rem); line-height: 1.08; }
    .ke-cover__quote { font-size: .78rem; line-height: 1.45; }
    .ke-guest { margin-top: .15rem; padding: .55rem 1rem .6rem; }
    .ke-guest__name { margin-top: .1rem; font-size: 1rem; }
    .ke-guest__note { margin-top: .15rem; font-size: .7rem; line-height: 1.4; }
    .ke-open { margin-top: .15rem; }
}
@media (max-height: 700px) {
    .ke-cover--photo { --ke-ph: min(118vw, 470px); }
}
@media (max-height: 660px) {
    .ke-cover__inner { gap: .3rem; }
    .ke-cover--photo { --ke-ph: min(112vw, 420px); }
    .ke-vessel { width: min(52vw, 190px); }
    .ke-cover--photo .ke-vessel { width: auto; }
    .ke-cover__names { font-size: clamp(1.8rem, 8vw, 2rem); }
    .ke-cover__date { font-size: .68rem; }
    .ke-cover__quote { font-size: .74rem; line-height: 1.4; }
    .ke-guest { padding: .5rem 1rem .55rem; }
    .ke-guest__note { display: none; }
}

/* leaving: the seam flares, the vessel lifts away, then the cover fades (the page is usable within ~1.2s) */
.ke-cover--leave { transition: opacity .55s ease .55s; }
.ke-cover--leave .ke-vessel { animation: ke-lift 1.05s cubic-bezier(.5, 0, .2, 1) forwards; }
.ke-cover--leave .ke-vessel__seam { animation: ke-flare .7s ease-out forwards; }
.ke-cover--leave .ke-cover__inner > :not(.ke-vessel) { animation: ke-fade-out .45s ease forwards; }
@keyframes ke-lift { from { opacity: 1; transform: none; } to { opacity: 1; transform: scale(1.12) translateY(-8px); } }
@keyframes ke-fade-out { to { opacity: 0; transform: translateY(6px); } }
@keyframes ke-flare {
    0% { filter: drop-shadow(0 1px 1px rgb(0 0 0 / .45)); }
    50% { filter: drop-shadow(0 0 6px var(--inv-accent)) drop-shadow(0 0 16px color-mix(in srgb, var(--inv-accent) 70%, transparent)) brightness(1.35); }
    100% { filter: drop-shadow(0 0 4px var(--inv-accent)) drop-shadow(0 0 22px color-mix(in srgb, var(--inv-accent) 50%, transparent)) brightness(1.2); }
}
.ke-cover--from { opacity: 1; }
.ke-cover--gone { opacity: 0; }

/* ---------- hero (top of the page after opening) ---------- */

.ke-hero {
    --ke-bg: var(--inv-primary);
    position: relative; overflow: hidden; isolation: isolate;
    min-height: 600px; padding: 4.4rem 1.5rem 3.2rem;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    text-align: center; color: var(--ke-fg);
    background: var(--inv-primary);
}
.ke-hero::after { content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none; background: var(--ke-glaze-screen) center / cover; opacity: .14; }
.ke-hero > * { position: relative; z-index: 1; }
.ke-hero > .ke-bgphoto, .ke-hero > .ke-seamorn { position: absolute; z-index: 0; }
.ke-hero .ke-bgphoto img { opacity: .55; }
.ke-hero .ke-bgphoto::after { background: linear-gradient(180deg, color-mix(in srgb, var(--ke-bg) 55%, transparent), color-mix(in srgb, var(--ke-bg) 70%, transparent) 45%, var(--ke-bg) 92%); }
.ke-seamorn--top { top: 0; }
.ke-hero .ke-kicker { margin-bottom: 1.6rem; }
.ke-hero--photo { justify-content: flex-end; min-height: min(150vw, 640px); padding-bottom: 2.6rem; }
.ke-hero--photo .ke-bgphoto img { opacity: 1; object-position: center 25%; }
.ke-hero--photo .ke-bgphoto::after { background: linear-gradient(180deg, color-mix(in srgb, var(--ke-bg) 35%, transparent) 0%, transparent 18%, transparent 42%, color-mix(in srgb, var(--ke-bg) 72%, transparent) 66%, var(--ke-bg) 90%); }
.ke-hero--photo::after { opacity: .08; }
.ke-hero--photo .ke-kicker { margin-bottom: .4rem; text-shadow: 0 1px 10px rgb(0 0 0 / .6); }
.ke-hero--photo .ke-hero__names { margin-top: 0; }
.ke-bowl--hero { width: min(72%, 270px); }
html.inv-anim.inv-opened .ke-bowl--hero .ke-bowl__seams path { animation: ke-draw 1.4s cubic-bezier(.6, 0, .3, 1) .5s both; }
html.inv-anim.inv-opened .ke-bowl--hero .ke-bowl__seams path:nth-child(even) { animation-delay: 1.2s; animation-duration: .9s; }

.ke-hero__names {
    margin-top: 2rem;
    display: flex; flex-wrap: wrap; justify-content: center; align-items: baseline; gap: 0 .5rem;
    font: 600 clamp(2.3rem, 10.5vw, 2.9rem)/1.18 var(--ke-display); color: var(--ke-title);
    text-shadow: 0 2px 18px rgb(0 0 0 / .35);
}
.ke-hero__date { margin-top: .6rem; font: 500 .76rem/1.4 var(--ke-sans); letter-spacing: .28em; text-transform: uppercase; color: var(--ke-label); }

.ke-scroll { width: 1px; height: 2.8rem; margin-top: 1.8rem; background: var(--ke-line-soft); overflow: hidden; }
.ke-scroll span { position: absolute; left: 0; top: -1rem; width: 1px; height: 1rem; background: var(--inv-accent); animation: ke-drip 2.4s ease-in-out infinite; }
@keyframes ke-drip { to { transform: translateY(4rem); } }

/* ---------- opening ---------- */

.ke-opening { padding-top: 5rem; }
.ke-arabic { font: 400 1.75rem/1.8 'Amiri', serif; color: var(--ke-title); margin-bottom: .8rem; }
.ke-opening__greeting { font: 600 1.18rem/1.5 var(--ke-display); color: var(--ke-title); }
.ke-opening__message { max-width: 24rem; margin: 1.3rem auto 0; color: var(--ke-muted); }

/* the verse: a sumi-ink panel set off center, a vermilion block behind it, gold seams mending two corners */
.ke-quote { position: relative; max-width: 22.5rem; margin: 2.8rem auto 0; padding: 0 0 0 1.1rem; }
.ke-quote__block {
    position: absolute; left: 0; top: 1.6rem; bottom: -1rem; width: 72%;
    border-radius: 3px 26px 3px 26px;
    background: linear-gradient(160deg, color-mix(in srgb, var(--ke-rust) 92%, #fff), var(--ke-rust) 60%, color-mix(in srgb, var(--ke-rust) 80%, #000));
    box-shadow: 0 18px 30px -20px rgb(0 0 0 / .55);
}
.ke-quote__panel {
    position: relative; overflow: hidden; padding: 2rem 1.5rem 1.5rem;
    border-radius: 26px 3px 26px 3px; text-align: left;
    background:
        radial-gradient(90% 60% at 20% 0, color-mix(in srgb, var(--inv-bowl) 70%, transparent), transparent 70%),
        var(--ke-glaze-soft) center / cover,
        var(--inv-primary);
    color: var(--inv-glazetext);
    box-shadow: 0 30px 46px -28px rgb(0 0 0 / .7), inset 0 0 0 1px color-mix(in srgb, var(--inv-accent) 30%, transparent);
}
.ke-quote__seam { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.ke-quote__seam path { fill: none; stroke: url(#ke-gold); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.ke-quote__mark { position: absolute; right: 1rem; top: -.3rem; font: 600 4.5rem/1 var(--ke-display); color: var(--inv-accent); opacity: .5; }
.ke-quote blockquote { position: relative; margin: 0; font: 500 1rem/1.8 var(--ke-display); color: var(--inv-glazetext); }
.ke-quote figcaption { position: relative; margin-top: .9rem; font: 500 .68rem/1.4 var(--ke-sans); letter-spacing: .28em; text-transform: uppercase; color: color-mix(in srgb, var(--inv-accent) 80%, var(--inv-glazetext)); }

/* ---------- couple: two halves joined by gold ---------- */

.ke-couple .ke-lead { margin-bottom: 1.6rem; }
.ke-halves { width: min(100%, 330px); margin: 0 auto; }
.ke-halves__art { display: block; width: 100%; height: auto; overflow: visible; }
.ke-halves__shadow { fill: rgb(0 0 0 / .4); }
.ke-halves__glaze { fill: url(#ke-glaze); }
.ke-halves__initial { font: 600 44px var(--ke-display); fill: var(--inv-glazetext); }
/* glaze sheen on top of the photo: light from the top left */
.ke-halves__sheen { fill: url(#ke-sheen); }
.ke-halves__sheen--r { opacity: .55; }
.ke-halves__rim { fill: none; stroke: url(#ke-gold); stroke-width: 3; }
.ke-halves__glow { fill: none; stroke: var(--inv-accent); stroke-width: 8; stroke-linejoin: round; opacity: .3; }
.ke-halves__seam { fill: none; stroke: url(#ke-gold); stroke-width: 3.2; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 0; }
.ke-halves__half { transition: transform 1.1s cubic-bezier(.3, .7, .2, 1); }
.ke-halves__half--l { transform: translateX(-1.2px); }
.ke-halves__half--r { transform: translateX(1.2px); }

/* joining on reveal: the halves come together, then the seam is drawn in gold */
html.inv-anim .ke-halves:not(.is-revealed) .ke-halves__half--l { transform: translateX(-14px) rotate(-3deg); }
html.inv-anim .ke-halves:not(.is-revealed) .ke-halves__half--r { transform: translateX(14px) rotate(3deg); }
html.inv-anim .ke-halves .ke-halves__half { transform-box: fill-box; transform-origin: 50% 100%; }
html.inv-anim .ke-halves:not(.is-revealed) .ke-halves__seam { stroke-dashoffset: 1; }
html.inv-anim .ke-halves .ke-halves__seam { transition: stroke-dashoffset 1.4s cubic-bezier(.6, 0, .3, 1) .7s; }
html.inv-anim .ke-halves:not(.is-revealed) .ke-halves__glow { opacity: 0; }
html.inv-anim .ke-halves .ke-halves__glow { transition: opacity .8s ease 1.6s; }

.ke-pair { position: relative; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.1rem; margin-top: 1.8rem; }
.ke-pair__amp { position: absolute; left: 50%; top: 1rem; transform: translateX(-50%); font: italic 500 2.4rem/1 var(--ke-script); color: var(--inv-accent); }
.ke-person { min-width: 0; display: flex; flex-direction: column; align-items: flex-start; text-align: left; }
.ke-person--bride { align-items: flex-end; text-align: right; }
.ke-person__role { font: 500 .6rem/1.4 var(--ke-sans); letter-spacing: .26em; text-transform: uppercase; color: var(--ke-label); }
.ke-person__nick { margin-top: .2rem; font: 600 1.95rem/1.15 var(--ke-display); color: var(--ke-title); overflow-wrap: anywhere; }
.ke-person__name { margin-top: .35rem; font: 500 .95rem/1.4 var(--ke-display); color: var(--ke-fg); overflow-wrap: anywhere; }
.ke-person__parents { margin-top: .55rem; font-size: .82rem; line-height: 1.55; color: var(--ke-muted); overflow-wrap: anywhere; }
.ke-person__parents strong { font-weight: 500; color: var(--ke-fg); }

/* ---------- countdown: the bowl, four small round stoneware dishes ---------- */

.ke-countdown { padding-top: 3.6rem; }
.ke-bowl--count { width: min(46%, 180px); margin-bottom: 1.4rem; }
.ke-countdown__date { display: inline-flex; align-items: center; gap: .5rem; margin: -.6rem 0 1.8rem; font: 600 .95rem/1.4 var(--ke-display); color: var(--ke-title); }
.ke-countdown__date .ke-icon { color: var(--ke-label); }
.inv-countdown { gap: .6rem; }
.inv-countdown__item {
    position: relative; isolation: isolate;
    flex: 1 1 0; min-width: 0; max-width: 5.2rem; aspect-ratio: 1; padding: 0;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    border-radius: 50%; color: var(--inv-glazetext);
    background:
        radial-gradient(circle at 50% 50%, transparent 0 58%, rgb(0 0 0 / .18) 59% 61%, transparent 62%),
        radial-gradient(circle at 34% 28%, color-mix(in srgb, var(--inv-bowl) 72%, #fff), var(--inv-bowl) 55%, color-mix(in srgb, var(--inv-bowl) 55%, #000));
    box-shadow:
        inset 0 1px 0 rgb(255 255 255 / .25),
        inset 0 0 0 1px color-mix(in srgb, var(--inv-bowl) 55%, #fff),
        0 14px 20px -12px rgb(0 0 0 / .6);
}
/* a small gold-mended crack from the rim of each dish */
.inv-countdown__item::after {
    content: ''; position: absolute; z-index: -1; right: 6%; top: 8%; width: 34%; height: 40%;
    background: var(--ke-gold-bg);
    clip-path: polygon(100% 0, 66% 32%, 76% 56%, 40% 100%, 34% 97%, 70% 56%, 60% 31%, 93% 0);
}
.inv-countdown__item:nth-child(2)::after { right: auto; left: 8%; top: auto; bottom: 6%; transform: rotate(180deg); }
.inv-countdown__item:nth-child(3)::after { top: auto; bottom: 8%; transform: scaleY(-1); }
.inv-countdown__item:nth-child(4)::after { right: auto; left: 6%; transform: scaleX(-1); }
.inv-countdown__value { font: 600 1.6rem/1 var(--ke-display); color: var(--inv-glazetext); }
.inv-countdown__label { margin-top: .3rem; font: 500 .54rem/1.2 var(--ke-sans); letter-spacing: .16em; text-transform: uppercase; color: var(--inv-glazetext); opacity: .9; }
.inv-countdown__done { font-style: italic; color: var(--ke-muted); }
.inv-countdown__actions { margin-top: 1.9rem; }
.inv-countdown__actions .inv-button { padding: .7rem 1rem; font-size: .62rem; letter-spacing: .1em; }

/* ---------- events: washi cards one under another ---------- */

.ke-events { padding-left: 0; padding-right: 0; }
.ke-events .ke-heading { padding: 0 1.5rem; }
.ke-plates__track {
    position: relative;
    display: grid; gap: 1.2rem; justify-items: center;
    padding: .6rem 1.4rem 0;
}

.ke-plate {
    position: relative; width: min(100%, 360px);
    display: flex; flex-direction: column; align-items: center;
    padding: 1.5rem 1.2rem 1.4rem; border-radius: 6px 30px 6px 30px;
    box-shadow:
        inset 0 0 0 6px color-mix(in srgb, var(--inv-surface) 60%, transparent),
        inset 0 0 0 7px color-mix(in srgb, var(--inv-accent) 55%, transparent),
        0 26px 36px -22px rgb(0 0 0 / .7);
}
.ke-plate__count { font: 500 .66rem/1 var(--ke-sans); letter-spacing: .3em; color: var(--ke-gold-text); }
.ke-plate__count span { color: color-mix(in srgb, var(--inv-text) 70%, transparent); }
/* the gold rim is a round border and the depth a drop-shadow filter: iOS Safari drew a gold layer behind the photo,
   and later its box-shadow rings, as a plain square */
.ke-plate__dish { position: relative; width: 50%; aspect-ratio: 1; margin: 1rem 0 1.1rem; filter: drop-shadow(0 14px 14px rgb(0 0 0 / .35)); }
.ke-plate__photo {
    position: relative; width: 100%; height: 100%; border-radius: 47% 53% 49% 51% / 53% 47% 53% 47%;
    border: 5px solid var(--inv-accent);
    background: var(--ke-photo) center 30% / cover no-repeat;
}
.ke-plate__photo::after { content: ''; position: absolute; inset: 0; border-radius: inherit; border: 2px solid var(--inv-surface); }
.ke-plate__crack { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.ke-plate__crack path { fill: none; stroke: url(#ke-gold); stroke-width: 1.3; stroke-linejoin: round; stroke-linecap: round; opacity: .75; }
.ke-plate__name { font: 600 1.45rem/1.25 var(--ke-display); color: var(--inv-ink); overflow-wrap: anywhere; }
.ke-plate__rows { width: 100%; margin-top: .8rem; display: grid; gap: .45rem; text-align: left; }
.ke-plate__row { display: flex; align-items: flex-start; gap: .6rem; font-size: .87rem; line-height: 1.5; color: var(--inv-text); overflow-wrap: anywhere; }
.ke-plate__row > span { min-width: 0; }
.ke-plate__row .ke-icon { margin-top: .18rem; color: var(--ke-gold-text); }
.ke-plate__row--time { font-weight: 700; color: var(--ke-rust); }
.ke-plate__venue { display: block; font: 600 1rem/1.4 var(--ke-display); color: var(--inv-ink); }
.ke-plate__address { display: block; color: color-mix(in srgb, var(--inv-text) 88%, var(--inv-surface)); }
.ke-plate__actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem; width: 100%; margin-top: auto; padding-top: 1rem; }
.ke-plate__actions .inv-button { --ke-btn-bg: var(--ke-matte); --ke-btn-fg: var(--inv-surface); padding: .72rem .4rem; font-size: .6rem; letter-spacing: .05em; gap: .3rem; white-space: nowrap; }
.ke-plate__actions .inv-button .ke-icon { color: var(--inv-accent); }
.ke-plate__actions .inv-button:only-child { grid-column: 1 / -1; }
.ke-plate__actions .inv-button--outline { --ke-out-fg: var(--inv-ink); }
.ke-plate__actions .inv-button--outline .ke-icon { color: var(--ke-gold-text); }


/* ---------- love story: one gold crack as the timeline (R1 zig-zag) ---------- */

.ke-story { padding-left: 1rem; padding-right: 1rem; }
.ke-seam { position: relative; }
.ke-seam__crack { position: absolute; left: 50%; top: -1rem; bottom: -1rem; width: 24px; height: calc(100% + 2rem); transform: translateX(-50%); overflow: visible; }
.ke-seam__crack path { fill: none; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.ke-seam__line { stroke: url(#ke-gold); stroke-width: 2.6; }
.ke-seam__glow { stroke: var(--inv-accent); stroke-width: 8; opacity: .2; }
/* drawn while scrolling where scroll-driven animations exist; otherwise (and with reduced motion) fully drawn */
@supports (animation-timeline: view()) {
    @media (prefers-reduced-motion: no-preference) {
        .ke-seam__crack { animation: ke-crack linear both; animation-timeline: view(); animation-range: entry 15% cover 75%; }
    }
}
@keyframes ke-crack { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }

.ke-seam__list { position: relative; margin: 0; padding: 0; list-style: none; }
.ke-moment {
    position: relative;
    display: grid; grid-template-columns: minmax(0, 1fr) 1.6rem minmax(0, 1fr); column-gap: .55rem; align-items: start;
    grid-template-areas: "text node meta";
}
.ke-moment + .ke-moment { margin-top: 2.6rem; }
.ke-moment.is-flip { grid-template-areas: "meta node text"; }
/* the node: a drop of gold where the moment sits on the crack */
.ke-moment__node {
    grid-area: node; justify-self: center; margin-top: .35rem;
    width: .9rem; height: .9rem; transform: rotate(45deg); border-radius: 2px 50% 2px 50%;
    background: var(--ke-gold-bg);
    box-shadow: 0 0 0 4px var(--ke-bg), 0 0 0 5px color-mix(in srgb, var(--inv-accent) 55%, transparent), 0 0 12px color-mix(in srgb, var(--inv-accent) 60%, transparent);
}
.ke-moment__text { grid-area: text; min-width: 0; text-align: right; }
.is-flip .ke-moment__text { text-align: left; }
.ke-moment__title { font: 600 1.1rem/1.35 var(--ke-display); color: var(--ke-title); overflow-wrap: anywhere; }
.ke-moment__rule { display: block; width: 68%; margin: .45rem 0 .5rem auto; border-top: 2px dotted color-mix(in srgb, var(--ke-rust) 70%, transparent); }
.is-flip .ke-moment__rule { margin-left: 0; margin-right: auto; }
.ke-moment__story { font-size: .85rem; line-height: 1.62; color: var(--ke-muted); overflow-wrap: anywhere; }
.ke-moment__meta { grid-area: meta; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: .6rem; text-align: left; }
.is-flip .ke-moment__meta { align-items: flex-end; text-align: right; }
.ke-moment__date { font: 600 1.3rem/1.15 var(--ke-display); color: var(--ke-rust); overflow-wrap: anywhere; }

/* small photos in irregular ceramic-shard shapes, edged with gold */
.ke-moment__shard {
    display: block; width: min(7.4rem, 100%); aspect-ratio: 1; padding: 3px;
    background: var(--ke-gold-bg);
    filter: drop-shadow(0 12px 14px rgb(0 0 0 / .3));
}
.ke-moment__shard img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ke-moment__shard--1, .ke-moment__shard--1 img { clip-path: polygon(10% 2%, 78% 0, 100% 34%, 92% 86%, 40% 100%, 0 72%, 4% 30%); }
.ke-moment__shard--2, .ke-moment__shard--2 img { clip-path: polygon(24% 0, 92% 10%, 100% 62%, 74% 100%, 8% 92%, 0 44%); }
.ke-moment__shard--3, .ke-moment__shard--3 img { clip-path: polygon(0 12%, 60% 0, 100% 20%, 96% 78%, 56% 100%, 6% 88%); }

/* ---------- gallery: shards and rounded glaze shapes ---------- */

.inv-gallery { gap: .55rem; }
.ke-gallery .inv-gallery { grid-auto-flow: dense; }
.inv-gallery__item {
    background: var(--inv-bowl);
    box-shadow: 0 16px 22px -16px rgb(0 0 0 / .7), inset 0 0 0 1px color-mix(in srgb, var(--inv-accent) 30%, transparent);
}
.ke-gallery .inv-gallery__item:nth-child(6n + 1) { grid-column: span 2; grid-row: span 2; border-radius: 26px 8px 30px 10px; }
.ke-gallery .inv-gallery__item:nth-child(6n + 2) { border-radius: 8px 22px 10px 18px; }
.ke-gallery .inv-gallery__item:nth-child(6n + 3) { border-radius: 20px 8px 24px 6px; }
.ke-gallery .inv-gallery__item:nth-child(6n + 4) { border-radius: 6px 24px 10px 26px; }
.ke-gallery .inv-gallery__item:nth-child(6n + 5) { border-radius: 24px 24px 8px 14px; }
.ke-gallery .inv-gallery__item:nth-child(6n) { border-radius: 10px 6px 26px 22px; }
/* a gold seam mending some photos */
.ke-gallery .inv-gallery__item:nth-child(3n + 1)::after {
    content: ''; position: absolute; z-index: 1; top: 0; right: 16%; width: 22%; height: 34%; pointer-events: none;
    background: var(--ke-gold-bg);
    clip-path: polygon(100% 0, 92% 0, 56% 38%, 64% 60%, 30% 100%, 38% 100%, 70% 60%, 62% 38%);
    filter: drop-shadow(0 0 3px rgb(0 0 0 / .4));
}
.inv-gallery__play { background: color-mix(in srgb, var(--inv-ink) 65%, transparent); color: #fff; }

/* ---------- live streaming ---------- */

.ke-live__card { max-width: 24rem; margin: 0 auto; padding: 1.8rem 1.4rem 1.7rem; }
.ke-live__card::before {
    content: ''; position: absolute; top: -1px; left: 18%; width: 3rem; height: 1.5rem;
    background: var(--ke-gold-bg);
    clip-path: polygon(0 0, 8% 0, 40% 46%, 58% 40%, 100% 100%, 92% 100%, 54% 50%, 36% 56%);
}
.ke-live__badge {
    display: inline-flex; align-items: center; gap: .4rem; padding: .3rem .75rem;
    border-radius: 999px; background: var(--ke-rust); color: #fff4ea;
    font: 700 .64rem/1 var(--ke-sans); letter-spacing: .22em;
}
.ke-live__badge span { width: .45rem; height: .45rem; border-radius: 50%; background: #fff4ea; animation: ke-blink 1.4s ease-in-out infinite; }
@keyframes ke-blink { 50% { opacity: .25; } }
.ke-live__text { margin: 1rem 0 .5rem; color: var(--inv-text); }
.ke-live__note { margin-bottom: 1.1rem; font: 600 1rem/1.5 var(--ke-display); color: var(--ke-gold-text); }
.ke-live__card .inv-button { margin-top: .6rem; }

/* ---------- gift: washi cards mended with a gold crack, two per row ---------- */

.ke-gift .ke-lead { color: var(--ke-fg); }
.inv-gift { display: grid; gap: .9rem; max-width: 23rem; margin: 0 auto; }
.inv-gift__accounts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
.inv-gift__account:last-child:nth-child(odd) { grid-column: 1 / -1; }
.inv-gift__account {
    position: relative; overflow: hidden; isolation: isolate; min-width: 0;
    display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: .45rem;
    grid-template-areas: "chip bank" "number number" "holder holder" "button button";
    margin: 0; padding: .9rem .85rem .95rem;
    border-radius: 6px 18px 6px 18px; text-align: left; color: var(--inv-text);
    box-shadow: 0 18px 30px -18px rgb(0 0 0 / .7), inset 0 0 0 1px color-mix(in srgb, var(--inv-accent) 45%, transparent);
}
.inv-gift__account + .inv-gift__account { margin-top: 0; }
.inv-gift__account::before {
    content: ''; grid-area: chip; width: 1.7rem; height: 1.3rem; border-radius: .3rem;
    background:
        linear-gradient(90deg, transparent 31%, rgb(0 0 0 / .25) 31% 33%, transparent 33% 67%, rgb(0 0 0 / .25) 67% 69%, transparent 69%),
        linear-gradient(0deg, transparent 47%, rgb(0 0 0 / .25) 47% 53%, transparent 53%),
        var(--ke-gold-bg);
    box-shadow: inset 0 0 0 1px rgb(0 0 0 / .2);
}
/* the gold crack across the card */
.inv-gift__account::after {
    content: ''; position: absolute; z-index: -1; top: 0; bottom: 0; left: 62%; width: 24%;
    background: var(--ke-gold-bg); opacity: .85;
    clip-path: polygon(30% 0, 18% 22%, 46% 40%, 28% 63%, 62% 82%, 52% 100%, 57% 100%, 67% 82%, 33% 63%, 51% 40%, 23% 22%, 35% 0);
}
.inv-gift__bank {
    grid-area: bank; justify-self: end; min-width: 0; max-width: 100%; margin: 0;
    font: 700 .64rem/1.2 var(--ke-sans); letter-spacing: .06em; text-transform: uppercase; text-align: right; overflow-wrap: anywhere; color: var(--inv-ink);
}
.inv-gift__logo { height: 1.5rem; max-width: 100%; padding: .2rem .45rem; border-radius: .35rem; }
.inv-gift__logo img { max-width: 4.6rem; }
.inv-gift__number {
    grid-area: number; margin: .8rem 0 .15rem;
    font: 700 1rem/1.25 var(--ke-sans); font-variant-numeric: tabular-nums; letter-spacing: .05em; color: var(--inv-ink);
    overflow-wrap: anywhere;
}
.inv-gift__holder { grid-area: holder; margin: 0; font: 500 .62rem/1.35 var(--ke-sans); letter-spacing: .1em; text-transform: uppercase; color: var(--inv-text); overflow-wrap: anywhere; }
.inv-gift__account .inv-button {
    grid-area: button; justify-self: start; margin-top: .65rem; padding: .38rem .75rem; border-radius: 999px;
    font: 700 .58rem/1.2 var(--ke-sans); letter-spacing: .08em; color: var(--inv-surface); background: var(--ke-matte);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--inv-accent) 60%, transparent);
}
.inv-gift__account .inv-button .ke-icon { color: var(--inv-accent); }

/* the gift address: a washi card */
.inv-gift__account.inv-gift__address {
    display: block; min-height: 0; padding: 1.5rem 1.3rem; text-align: center; color: var(--inv-text);
}
.inv-gift__address::before, .inv-gift__address::after { content: none; }
.inv-gift__address .inv-gift__bank { justify-self: auto; text-align: center; font: 500 .68rem/1.4 var(--ke-sans); letter-spacing: .3em; color: var(--ke-gold-text); }
.inv-gift__address .inv-gift__holder { margin: .6rem 0 .2rem; font: 600 1.05rem/1.3 var(--ke-display); letter-spacing: .02em; text-transform: none; color: var(--inv-ink); }
.inv-gift__address p:not([class]) { color: color-mix(in srgb, var(--inv-text) 90%, transparent); }
.inv-gift__address .inv-button { margin-top: 1rem; }

/* ---------- rsvp & wishes forms ---------- */

.ke-form { max-width: 24rem; margin: 0 auto; padding: 1.7rem 1.25rem 1.5rem; text-align: left; }
.ke-form::before {
    content: ''; position: absolute; top: -1px; right: 16%; width: 3rem; height: 1.5rem;
    background: var(--ke-gold-bg);
    clip-path: polygon(0 0, 8% 0, 40% 46%, 58% 40%, 100% 100%, 92% 100%, 54% 50%, 36% 56%);
}
.ke-form .inv-button { --ke-btn-bg: var(--ke-matte); --ke-btn-fg: var(--inv-surface); }
.ke-form .inv-button--outline { --ke-out-fg: var(--inv-ink); }
.inv-form { gap: .9rem; }
.inv-form label, .inv-form__choices legend { font: 500 .8rem/1.4 var(--ke-sans); letter-spacing: .02em; color: var(--inv-text); }
.inv-form input:not([type=radio]):not([type=checkbox]), .inv-form select, .inv-form textarea {
    padding: .7rem .85rem; border-radius: 10px;
    border: 1px solid color-mix(in srgb, var(--inv-text) 24%, transparent);
    background: #fffdf8; color: var(--inv-text);
    font: 400 1rem/1.4 var(--ke-sans);
    transition: border-color .2s ease, box-shadow .2s ease;
}
.inv-form input::placeholder, .inv-form textarea::placeholder { color: color-mix(in srgb, var(--inv-text) 55%, transparent); }
.inv-form input:focus, .inv-form select:focus, .inv-form textarea:focus {
    outline: none; border-color: var(--inv-accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--inv-accent) 25%, transparent);
}
.inv-form option { background: #fff; color: var(--inv-ink); }
.inv-form input[type=radio], .inv-form input[type=checkbox] { accent-color: var(--ke-rust); }
.inv-form__choices label { color: var(--inv-text); font-size: .92rem; }
.inv-form__notice { color: var(--inv-text); background: color-mix(in srgb, var(--inv-clay) 50%, transparent); border: 1px solid var(--ke-line-soft); }
.inv-form .inv-button { justify-self: stretch; margin-top: .3rem; }
.inv-rsvp__deadline { font-style: italic; color: var(--ke-rust); }

/* wishes: compact cards in a scroll box of about three */
.inv-wishes { --inv-wishes-height: 20rem; }
.inv-wishes__list { gap: .6rem; margin-top: 1.4rem; }
.inv-wishes:not(.inv-wishes--paged) .inv-wishes__list {
    padding: .5rem .45rem .5rem .5rem; border-radius: 12px;
    background: color-mix(in srgb, var(--inv-clay) 55%, var(--inv-background));
    box-shadow: inset 0 0 0 1px var(--ke-line-soft), inset 0 -14px 16px -14px rgb(0 0 0 / .2);
    scrollbar-color: color-mix(in srgb, var(--inv-accent) 60%, transparent) transparent;
}
.inv-wishes__empty { text-align: center; font-style: italic; }
.inv-wish {
    position: relative; padding: .65rem .8rem .65rem .95rem; border-radius: 10px;
    background: #fffdf8; color: var(--inv-text);
    border: 1px solid var(--ke-line-soft);
}
/* a thin gold seam along the left edge */
.inv-wish::before { content: ''; position: absolute; left: 0; top: 18%; bottom: 18%; width: 2px; border-radius: 2px; background: var(--ke-gold-bg); }
.inv-wish__name { font: 600 .94rem/1.3 var(--ke-display); color: var(--inv-ink); }
.inv-wish__message { font-size: .92rem; line-height: 1.6; }
.inv-wish__time { margin-top: .25rem; font: 400 .7rem/1.3 var(--ke-sans); letter-spacing: .04em; }
.inv-wish__reply { margin-top: .5rem; padding: .45rem .65rem; background: color-mix(in srgb, var(--inv-clay) 45%, transparent); }
.inv-wish__reply-text { font-size: .9rem; }
.inv-wishes__page-button { color: var(--inv-ink); }

/* ---------- closing: the photo fading into the glaze ---------- */

.ke-closing { padding: 0 0 2.4rem; }
/* the glaze texture over the whole section, under the photo (it began below the photo with a hard edge) */
.ke-closing::after { top: 0; background-size: auto 100%; }
.ke-closing__photo { position: relative; z-index: 0; height: min(118vw, 470px); margin-bottom: -9rem; overflow: hidden; -webkit-mask-image: linear-gradient(180deg, #000 50%, transparent 98%); mask-image: linear-gradient(180deg, #000 50%, transparent 98%); }
.ke-closing__photo img { display: block; width: 100%; height: calc(100% + 60px); margin-top: -30px; object-fit: cover; object-position: center 20%; }
.ke-closing__photo::after {
    content: ''; position: absolute; inset: 0;
    background: linear-gradient(180deg, transparent 28%, color-mix(in srgb, var(--inv-glaze) 55%, transparent) 56%, var(--inv-glaze) 94%);
}
.ke-closing__photo--empty {
    height: 17rem; margin-bottom: -6rem;
    background:
        radial-gradient(60% 70% at 50% 100%, color-mix(in srgb, var(--inv-bowl) 80%, transparent), transparent 70%),
        radial-gradient(40% 50% at 70% 30%, color-mix(in srgb, var(--inv-accent) 18%, transparent), transparent 70%),
        var(--inv-glaze);
}
.ke-seamorn--closing { top: min(66vw, 15.5rem); }
.ke-closing__photo--empty { padding-top: 3.4rem; }
.ke-bowl--closing { width: min(48%, 190px); }
.ke-closing__photo--empty ~ .ke-seamorn--closing { display: none; }
.ke-closing__body { position: relative; z-index: 1; display: grid; justify-items: center; margin: 0 1.3rem; padding: 2.2rem 1.2rem 1.2rem; }
.ke-closing__corner { position: absolute; top: .8rem; width: 3rem; height: 3rem; overflow: visible; }
.ke-closing__corner--l { left: 0; }
.ke-closing__corner--r { right: 0; transform: scaleX(-1); }
.ke-closing__corner path { fill: none; stroke: url(#ke-gold); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.ke-closing__corner .ke-closing__twig { stroke-width: 1.3; }
.ke-hanko--closing { width: 2.3rem; margin-bottom: .7rem; font-size: .85rem; }
.ke-closing__label { font: 500 .62rem/1.4 var(--ke-sans); letter-spacing: .36em; text-transform: uppercase; color: var(--ke-label); }
.ke-closing__thanks { margin-top: .3rem; font: 600 clamp(1.9rem, 8.5vw, 2.3rem)/1.2 var(--ke-display); color: var(--ke-title); text-shadow: 0 2px 18px rgb(0 0 0 / .35); }
.ke-closing__message { max-width: 21rem; margin: .7rem auto 0; font-size: .85rem; line-height: 1.55; color: var(--ke-muted); }
.ke-closing__sign { margin-top: .9rem; font: 500 .62rem/1.4 var(--ke-sans); letter-spacing: .3em; text-transform: uppercase; color: var(--ke-label); }
.ke-closing__names { margin-top: .2rem; font: 600 clamp(1.6rem, 7vw, 1.9rem)/1.3 var(--ke-display); color: var(--ke-title); }

/* ---------- shared components: nav, music, to-top, QR tab, branding ---------- */

.ke-nav.inv-nav {
    --inv-nav-bg: color-mix(in srgb, var(--inv-glaze) 92%, transparent);
    --inv-nav-text: color-mix(in srgb, var(--inv-glazetext) 76%, transparent);
    --inv-nav-active: var(--ke-gold-bg);
    border-color: color-mix(in srgb, var(--inv-accent) 45%, transparent);
    box-shadow: 0 14px 34px -14px rgb(0 0 0 / .5);
    font-family: var(--ke-sans);
}
.ke-nav.inv-nav--icons .inv-nav__item.is-active { color: var(--inv-ink); box-shadow: 0 0 0 2px var(--inv-glaze), 0 0 0 3px color-mix(in srgb, var(--inv-accent) 60%, transparent), 0 8px 18px -6px rgb(0 0 0 / .5); }

.inv-music { right: calc(var(--ke-edge) + 1rem); }
.inv-music__button { background: var(--ke-matte); color: var(--inv-accent); box-shadow: 0 8px 22px -8px rgb(0 0 0 / .55), 0 0 0 1px color-mix(in srgb, var(--inv-accent) 60%, transparent); }
.inv-autoscroll { color: var(--inv-ink); background: color-mix(in srgb, var(--inv-surface) 94%, transparent); border-color: color-mix(in srgb, var(--inv-accent) 55%, transparent); font-family: var(--ke-sans); }
.inv-autoscroll--running { background: var(--ke-matte); color: var(--inv-surface); }

.inv-to-top {
    left: calc(var(--ke-edge) + 1rem); border-radius: 50%;
    background: var(--ke-matte); color: var(--inv-accent);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--inv-accent) 60%, transparent), 0 6px 16px -6px rgb(0 0 0 / .45);
}
.inv-qr-tab {
    right: var(--ke-edge); font-family: var(--ke-sans); color: var(--inv-accent);
    background: var(--ke-matte);
    border-color: color-mix(in srgb, var(--inv-accent) 55%, transparent);
}
.inv-qr-sheet .inv-checkin { font-family: var(--ke-sans); color: var(--inv-ink); }
.inv-checkin__title { color: var(--inv-ink); font-family: var(--ke-display); }

.ke-branding { position: relative; z-index: 1; color: var(--inv-glazetext); font-family: var(--ke-sans); background: var(--inv-glaze); }

/* ---------- motion preferences ---------- */

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .ke-scroll span, .ke-live__badge span { animation: none; }
    .ke-cover--leave { transition: opacity .3s ease; }
    .ke-cover--leave .ke-vessel, .ke-cover--leave .ke-cover__inner > :not(.ke-vessel), .ke-cover--leave .ke-vessel__seam { animation: none; }
}

/* ======================================================= intro scene "Retak Emas" (scene.json, sections/_scene) */
.ke-scene-glaze { position: absolute; inset: 0; background: var(--ke-glaze-screen) center / cover; opacity: .32; }
.ke-scene-crack { display: block; width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 0 3px color-mix(in srgb, var(--inv-accent) 55%, transparent)); }
.ke-scene-crack path { fill: none; stroke: url(#ke-gold-u); stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.ke-scene-crack .ke-scene-crack__branch { stroke-width: 1.4; }
.ke-scene-crack .ke-scene-crack__glow { stroke: var(--inv-accent); stroke-width: 6; opacity: .12; }
.ke-scene-washi {
    position: absolute; inset: 0; background: var(--ke-washi-mul) center / cover, var(--inv-clay);
    clip-path: polygon(0 12%, 9% 4%, 21% 9%, 33% 0, 47% 7%, 60% 2%, 74% 8%, 88% 1%, 100% 9%, 100% 88%, 86% 96%, 71% 90%, 56% 100%, 41% 92%, 27% 98%, 13% 91%, 0 97%);
    filter: drop-shadow(0 10px 14px rgb(0 0 0 / .45));
}
.ke-scene-washi svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.ke-scene-washi path { fill: none; stroke: url(#ke-gold-u); stroke-width: 2; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.ke-scene-washi--b svg { transform: scaleX(-1); }
.ke-scene-bowl { width: 100%; filter: drop-shadow(0 18px 18px rgb(0 0 0 / .45)); }
.ke-scene-half { display: block; width: 100%; height: auto; overflow: visible; filter: drop-shadow(0 14px 16px rgb(0 0 0 / .45)); }
.ke-scene-half__rim { fill: none; stroke: url(#ke-gold); stroke-width: 3; }
.ke-scene-hanko { font-size: .95rem; }
/* the seams draw once while the camera moves in */
html.inv-anim .ke-scene-crack { animation: ke-scene-crack 2.4s cubic-bezier(.6, 0, .3, 1) .3s both; }
html.inv-anim .ke-scene-crack .ke-scene-crack__glow { animation: ke-fade-in 1s ease 2.4s both; }
@keyframes ke-scene-crack { from { clip-path: inset(0 100% 100% 0); } to { clip-path: inset(0 0 0 0); } }
html.inv-anim .ke-scene-bowl .ke-bowl__seams path { animation: ke-draw 1.3s cubic-bezier(.6, 0, .3, 1) 1.6s both; }
html.inv-anim .ke-scene-half .ke-halves__seam { animation: ke-draw 1s cubic-bezier(.6, 0, .3, 1) 4.1s both; }
/* the card of this scene is a sheet of washi paper with a gold-leaf edge */
.ke-body .inv-scene__card {
    aspect-ratio: auto; padding: 2.2rem 1.5rem 2rem; -webkit-mask: none; mask: none; -webkit-backdrop-filter: none; backdrop-filter: none;
    border-radius: 6px 10px 5px 9px / 9px 5px 10px 6px;
    background: var(--ke-washi-mul) center / cover, var(--inv-surface);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--inv-accent) 70%, transparent), inset 0 0 0 6px var(--inv-surface), inset 0 0 0 7px color-mix(in srgb, var(--inv-accent) 45%, transparent),
        0 0 0 2px var(--inv-accent), 0 24px 40px -14px rgb(0 0 0 / .6);
}
.ke-body .inv-scene__card .inv-intro__label { color: var(--ke-gold-text); font-family: var(--ke-sans); letter-spacing: .32em; }
.ke-body .inv-scene__card .inv-intro__names { font-weight: 600; font-size: clamp(1.9rem, 8.6vw, 2.6rem); color: var(--inv-ink); }
.ke-body .inv-scene__card .inv-intro__date { color: var(--inv-text); font-family: var(--ke-sans); }
.ke-body .inv-scene__card .inv-intro__rule { background: linear-gradient(90deg, transparent, var(--ke-gold-text), transparent); }
.ke-body .inv-intro--scene .inv-intro__skip { background: color-mix(in srgb, var(--inv-glaze) 70%, transparent); border-color: color-mix(in srgb, var(--inv-accent) 55%, transparent); color: var(--inv-glazetext); }
@media (prefers-reduced-motion: reduce) {
    .ke-scene-crack, .ke-scene-crack path, .ke-scene-bowl .ke-bowl__seams path, .ke-scene-half .ke-halves__seam { animation: none !important; }
}
