/* ==========================================================================
   Licurici - a summer evening in the garden: fireflies drift over the page, gather around the names at the opening
   and scatter when the guest scrolls; the photo glows like a window above tall grass; the programme is a path whose
   lights come on one by one; a jar of fireflies at the end
   Palette (evening colours only): --inv-primary (the fireflies' light), --inv-accent (the sky), --inv-bg (night), --inv-text
   script.js draws the fireflies on a canvas and reads their colour from --lc-glow
   ========================================================================== */

.licurici {
    --lc-script: 'Mea Culpa', 'Segoe Script', cursive;
    --lc-ink-soft: color-mix(in srgb, var(--inv-text) 72%, var(--inv-bg));
    --lc-glow: color-mix(in srgb, var(--inv-primary) 85%, white);
    --lc-halo: color-mix(in srgb, var(--inv-primary) 45%, transparent);
    --lc-line: color-mix(in srgb, var(--inv-primary) 30%, transparent);
    --lc-sky: color-mix(in srgb, var(--inv-accent) 40%, var(--inv-bg));
    --lc-card: color-mix(in srgb, var(--inv-surface) 70%, transparent);
    --kit-radius: 12px;
    --kit-field-bg: color-mix(in srgb, var(--inv-surface) 85%, transparent);
    --kit-field-border: var(--lc-line);
    font-family: var(--inv-font-body);
    font-size: 1.03rem;
    line-height: 1.75;
    color: var(--inv-text);
    background:
        radial-gradient(90% 55% at 50% 0%, var(--lc-sky), transparent 75%),
        radial-gradient(60% 40% at 0% 60%, color-mix(in srgb, var(--inv-accent) 14%, transparent), transparent 70%),
        var(--inv-bg);
    overflow-x: clip;
}
.licurici h1, .licurici h2, .licurici h3 { font-family: var(--inv-font-heading); font-weight: 400; line-height: 1.15; }
:where(.licurici) :is(h1, h2, h3) { margin: 0; }
:where(.licurici) p { margin: 0 0 .9em; }
.licurici a { color: var(--inv-primary); }
.lc-kicker { font-size: .72rem; font-weight: 600; letter-spacing: .26em; text-transform: uppercase; color: var(--inv-primary); margin: 0 0 10px; }
.lc-role { font-size: .7rem; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: var(--lc-ink-soft); margin: 0 0 6px; }
.lc-names-line { font-family: var(--inv-font-heading); font-style: italic; font-size: 1.4rem; margin: 0; }

/* ---------- Fireflies ---------- */
.lc-fireflies { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 3; pointer-events: none; }
.lc-hero, .lc-main, .lc-footer { position: relative; z-index: 1; }
.lc-hero { z-index: 2; }
@keyframes lc-blink { 0%, 100% { opacity: .15; } 45%, 60% { opacity: 1; } }

/* A card lit from above: a dark glass pane whose top edge glows */
.lc-glow-card { background: var(--lc-card); border: 1px solid var(--lc-line); border-radius: 18px; box-shadow: inset 0 1px 0 var(--lc-halo), 0 24px 60px -30px rgba(0, 0, 0, .6); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }

/* ---------- Titles: a firefly draws its looping trail ---------- */
.lc-title { margin: 0 auto clamp(28px, 4.5vw, 46px); text-align: center; }
.lc-trail { display: block; width: 110px; margin: 0 auto 10px; overflow: visible; }
.lc-trail path { fill: none; stroke: var(--lc-line); stroke-width: 1.4; stroke-linecap: round; stroke-dasharray: 2 5; }
.lc-trail circle { fill: var(--lc-glow); filter: drop-shadow(0 0 4px var(--inv-primary)) drop-shadow(0 0 10px var(--inv-primary)); animation: lc-blink 3.2s ease-in-out infinite; }
.kit-js .lc-trail path { stroke-dashoffset: 160; transition: stroke-dashoffset 2s ease; }
.kit-js .is-visible .lc-trail path, .kit-js .lc-title.is-visible .lc-trail path { stroke-dashoffset: 0; }
.lc-title h2 { font-style: italic; font-size: clamp(2.1rem, 6vw, 3.1rem); }

/* ---------- Navigation ---------- */
.lc-nav { position: absolute; top: 0; left: 0; right: 0; z-index: 6; display: flex; justify-content: center; padding: 18px; }
.lc-nav .kit-nav-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 24px; }
.lc-nav a { text-decoration: none; font-size: .76rem; letter-spacing: .14em; text-transform: uppercase; color: var(--lc-ink-soft); padding: 6px 0; border-bottom: 1px solid transparent; }
.lc-nav a:hover, .lc-nav a.is-current { color: var(--inv-primary); border-bottom-color: currentColor; }
.lc-nav .kit-nav-brand { font-family: var(--lc-script); font-size: 1.9rem; letter-spacing: 0; text-transform: none; color: var(--inv-primary); margin-right: auto; border: 0; line-height: 1; }
.lc-nav.is-stuck { justify-content: space-between; align-items: center; padding: 6px clamp(16px, 4vw, 40px); background: color-mix(in srgb, var(--inv-bg) 88%, transparent); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: 0 1px 0 var(--lc-line); }
.licurici .kit-to-top { border-radius: 50%; background: var(--inv-surface); color: var(--inv-primary); border: 1px solid var(--lc-line); box-shadow: 0 0 18px -4px var(--lc-halo); }
@media (max-width: 899px) {
    .lc-nav { justify-content: flex-end; padding: 12px; }
    .lc-nav .kit-nav-toggle { width: 46px; height: 46px; border-radius: 50%; background: var(--lc-card); color: var(--inv-primary); border: 1px solid var(--lc-line); font-size: 1.2rem; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
    .lc-nav .kit-nav-links { display: none; }
    .lc-nav.is-open .kit-nav-links {
        display: flex; flex-direction: column; gap: 12px; position: absolute; top: 66px; left: 12px; right: 12px;
        padding: 24px; border-radius: 18px; background: var(--inv-surface); box-shadow: 0 20px 50px -20px rgba(0, 0, 0, .7);
    }
    .lc-nav.is-stuck { padding: 6px 12px; }
}

/* ---------- Hero: the names in handwriting, the photo glowing like a window, tall grass below ---------- */
.lc-hero { min-height: 100vh; min-height: 100svh; display: grid; place-items: center; padding: 96px 16px 130px; overflow: hidden; }
.lc-hero-inner { width: min(1100px, 100%); display: grid; gap: clamp(36px, 6vw, 70px); align-items: center; justify-items: center; }
.lc-hero-text { text-align: center; max-width: 540px; }
.licurici .lc-names { font-family: var(--lc-script); font-weight: 400; font-size: clamp(4rem, 15vw, 7.4rem); line-height: .95; color: var(--lc-glow); text-shadow: 0 0 18px var(--lc-halo), 0 0 50px color-mix(in srgb, var(--inv-primary) 25%, transparent); display: grid; justify-items: center; overflow-wrap: anywhere; margin: 8px 0; }
.lc-and { font-family: var(--inv-font-heading); font-style: italic; font-size: .28em; color: var(--inv-text); text-shadow: none; margin: .1em 0 .2em; }
.lc-hero-date { font-family: var(--inv-font-heading); font-size: 1.3rem; margin: 20px 0 2px; }
.lc-hero-place { font-size: .74rem; letter-spacing: .24em; text-transform: uppercase; color: var(--lc-ink-soft); margin: 0; }
.licurici .lc-subtitle { max-width: 38ch; margin: 18px auto 0; color: var(--lc-ink-soft); }
.lc-window { position: relative; margin: 0; width: min(400px, 82vw); aspect-ratio: 4 / 5; border-radius: 200px 200px 22px 22px; overflow: hidden; box-shadow: 0 0 0 1px var(--lc-line), 0 0 60px -6px var(--lc-halo), 0 0 140px -20px color-mix(in srgb, var(--inv-primary) 35%, transparent); }
.lc-window img { width: 100%; height: 100%; object-fit: cover; }
.lc-window::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, color-mix(in srgb, var(--inv-bg) 55%, transparent)); pointer-events: none; }
.lc-hero-grass { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: clamp(90px, 14vw, 170px); fill: var(--inv-bg); z-index: 1; }
@keyframes lc-dawn { from { opacity: 0; filter: blur(8px); } to { opacity: 1; filter: none; } }
.kit-js .lc-hero-text > * { animation: lc-dawn 1.6s ease both; }
.kit-js .lc-hero-text > :nth-child(2) { animation-delay: .4s; }
.kit-js .lc-hero-text > :nth-child(n+3) { animation-delay: .9s; }
.kit-js .lc-window { animation: lc-dawn 2s ease .2s both; }
@media (min-width: 1000px) {
    .lc-hero-inner { grid-template-columns: 1.1fr 1fr; }
    .lc-window { justify-self: start; }
}

/* ---------- Sections ---------- */
.lc-main { width: min(1060px, 100%); margin: 0 auto; padding: 0 16px; }
.lc-section { padding-top: clamp(80px, 11vw, 128px); }
.lc-welcome { text-align: center; max-width: 720px; margin: 0 auto; }
.licurici .lc-welcome-title { font-family: var(--lc-script); font-size: clamp(3rem, 9vw, 4.4rem); color: var(--lc-glow); text-shadow: 0 0 20px var(--lc-halo); margin-bottom: 10px; }
.lc-welcome p { font-size: 1.1rem; color: var(--lc-ink-soft); }
.lc-quote-author { font-family: var(--inv-font-heading); font-style: italic; color: var(--inv-primary); }
.lc-lead { text-align: center; font-family: var(--inv-font-heading); font-style: italic; font-size: 1.22rem; color: var(--lc-ink-soft); max-width: 40ch; margin: 0 auto 26px; }

/* Couple: two oval portraits ringed with a soft glow */
.lc-couple-grid { display: grid; gap: 50px; justify-items: center; }
.lc-person { text-align: center; max-width: 380px; }
.lc-portrait { margin: 0 auto 22px; width: min(270px, 64vw); aspect-ratio: 3 / 4; border-radius: 50%; overflow: hidden; box-shadow: 0 0 0 1px var(--lc-line), 0 0 0 10px color-mix(in srgb, var(--inv-primary) 6%, transparent), 0 0 50px -8px var(--lc-halo); }
.lc-portrait img, .lc-initial { width: 100%; height: 100%; object-fit: cover; }
.lc-initial { display: grid; place-items: center; background: var(--lc-sky); font-family: var(--lc-script); font-size: 6rem; color: var(--lc-glow); }
.lc-person h3 { font-size: 1.7rem; font-style: italic; margin: 8px 0 8px; }
.lc-person p { color: var(--lc-ink-soft); }
@media (min-width: 760px) { .lc-couple-grid { grid-template-columns: 1fr 1fr; align-items: start; } }

/* Family */
.lc-family-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); text-align: center; }
.lc-family-item { padding: 24px 22px; }

/* Story */
.lc-chapters { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(46px, 7vw, 76px); }
.lc-chapter { display: grid; gap: 26px; align-items: center; }
.lc-chapter-photo { margin: 0; aspect-ratio: 4 / 3; border-radius: 18px; overflow: hidden; box-shadow: 0 0 0 1px var(--lc-line), 0 0 60px -20px var(--lc-halo); }
.lc-chapter-photo img { width: 100%; height: 100%; object-fit: cover; }
.lc-chapter-text h3 { font-size: 1.95rem; font-style: italic; margin-bottom: 8px; }
.lc-chapter-text p:not(.lc-kicker) { color: var(--lc-ink-soft); }
@media (min-width: 900px) {
    .lc-chapter { grid-template-columns: 1fr 1fr; gap: 58px; }
    .lc-chapter:nth-child(even) .lc-chapter-photo { order: 2; }
}

/* Programme: a path through the garden, each stop a light that comes on as it reaches the screen */
.lc-path { list-style: none; margin: 0 auto; padding: 0; max-width: 760px; position: relative; display: grid; gap: 40px; }
.lc-path::before { content: ""; position: absolute; left: 21px; top: 10px; bottom: 10px; border-left: 2px dotted var(--lc-line); }
.lc-stop { position: relative; display: grid; grid-template-columns: 44px 1fr; column-gap: 18px; align-items: start; }
.lc-stop-light { grid-row: 1 / span 2; width: 16px; height: 16px; margin: 10px auto 0; border-radius: 50%; background: var(--lc-line); position: relative; z-index: 1; transition: background .8s ease, box-shadow .8s ease; }
.lc-stop.is-visible .lc-stop-light, html:not(.kit-js) .lc-stop-light { background: var(--lc-glow); box-shadow: 0 0 10px 2px var(--inv-primary), 0 0 30px 6px var(--lc-halo); animation: lc-blink 4s ease-in-out 1s infinite; }
.lc-stop-time { font-family: var(--inv-font-heading); font-size: 2.2rem; line-height: 1.1; color: var(--inv-primary); margin: 0 0 4px; }
.lc-stop-body { grid-column: 2; }
.lc-stop-body h3 { font-size: 1.55rem; font-style: italic; margin-bottom: 6px; }
.lc-stop-place { font-weight: 600; margin: 10px 0 0; }
.lc-stop-address, .lc-stop-notes { color: var(--lc-ink-soft); margin: 0; }
.lc-stop-notes { font-style: italic; margin-top: 6px; }
.lc-stop .kit-event-actions { justify-content: flex-start; }
.licurici .kit-button { border-radius: 999px; border: 1px solid var(--lc-line); color: var(--inv-primary); background: transparent; font-size: .78rem; padding: 9px 16px; text-decoration: none; }
.licurici .kit-button:hover { background: var(--inv-primary); color: var(--inv-bg); }

/* Countdown: the numbers glow and breathe, like fireflies */
.lc-countdown { text-align: center; }
.lc-countdown .kit-countdown { gap: clamp(14px, 5vw, 48px); }
.lc-countdown .kit-countdown-value { font-family: var(--inv-font-heading); font-size: clamp(2.6rem, 10vw, 4.4rem); line-height: 1; color: var(--lc-glow); text-shadow: 0 0 16px var(--lc-halo), 0 0 40px color-mix(in srgb, var(--inv-primary) 30%, transparent); animation: lc-breathe 4s ease-in-out infinite; }
.lc-countdown .kit-countdown-unit:nth-child(2) .kit-countdown-value { animation-delay: 1s; }
.lc-countdown .kit-countdown-unit:nth-child(3) .kit-countdown-value { animation-delay: 2s; }
.lc-countdown .kit-countdown-unit:nth-child(4) .kit-countdown-value { animation-delay: 3s; }
.lc-countdown .kit-countdown-label { margin-top: 10px; opacity: 1; color: var(--lc-ink-soft); }
@keyframes lc-breathe { 0%, 100% { text-shadow: 0 0 10px var(--lc-halo); } 50% { text-shadow: 0 0 22px var(--inv-primary), 0 0 60px var(--lc-halo); } }

/* Gallery */
.lc-gallery-grid.kit-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(10px, 2vw, 18px); }
.lc-gallery-grid.kit-gallery a { border-radius: 14px; aspect-ratio: 3 / 4; box-shadow: 0 0 0 1px var(--lc-line); }
@media (min-width: 760px) { .lc-gallery-grid.kit-gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* RSVP */
.lc-reply { max-width: 700px; margin: 0 auto; padding: clamp(30px, 6vw, 54px); }
.licurici .inv-rsvp__intro { font-family: var(--inv-font-heading); font-style: italic; font-size: 1.15rem; }
.licurici .inv-rsvp__deadline { font-size: .74rem; letter-spacing: .16em; text-transform: uppercase; color: var(--inv-primary); }
.licurici .inv-rsvp__choice label { border-radius: 999px; }

/* Info, contact */
.lc-info-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.lc-info-item { padding: 26px 24px 14px; text-align: center; }
.lc-info-item h3 { font-size: 1.4rem; font-style: italic; color: var(--inv-primary); margin-bottom: 8px; }
.lc-info-item p { color: var(--lc-ink-soft); }
.lc-faq { max-width: 720px; margin: 44px auto 0; text-align: center; }
.lc-faq details { text-align: left; border-bottom: 1px solid var(--lc-line); }
.lc-faq summary { cursor: pointer; list-style: none; padding: 18px 44px 18px 4px; position: relative; font-family: var(--inv-font-heading); font-style: italic; font-size: 1.18rem; }
.lc-faq summary::-webkit-details-marker { display: none; }
.lc-faq summary::after { content: ""; position: absolute; right: 12px; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: var(--lc-line); transition: background .3s, box-shadow .3s; }
.lc-faq details[open] summary::after { background: var(--lc-glow); box-shadow: 0 0 10px 2px var(--inv-primary); }
.lc-faq summary:focus-visible { outline: 2px solid var(--inv-primary); outline-offset: 2px; }
.lc-faq details p { padding: 0 4px; color: var(--lc-ink-soft); }
.lc-faq details p:last-child { padding-bottom: 14px; }
.lc-contact { text-align: center; }
.lc-contact-list { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px 60px; }
.lc-contact-person a { text-decoration: none; }

/* Footer: a jar of fireflies */
.lc-footer { text-align: center; padding: clamp(100px, 15vw, 160px) 16px 70px; }
.lc-jar { display: block; width: 110px; margin: 0 auto 24px; overflow: visible; }
.lc-jar-glass { fill: color-mix(in srgb, var(--inv-primary) 7%, transparent); stroke: var(--lc-line); stroke-width: 2; }
.lc-jar-lid { fill: color-mix(in srgb, var(--inv-text) 25%, var(--inv-bg)); }
.lc-jar-string, .lc-jar-shine { fill: none; stroke: var(--lc-line); stroke-width: 2; stroke-linecap: round; }
.lc-jar-fly { fill: var(--lc-glow); filter: drop-shadow(0 0 3px var(--inv-primary)) drop-shadow(0 0 8px var(--inv-primary)); animation: lc-blink 2.8s ease-in-out infinite; }
.lc-footer-message { font-family: var(--inv-font-heading); font-style: italic; font-size: 1.3rem; color: var(--lc-ink-soft); }
.lc-footer-names { font-family: var(--lc-script); font-size: clamp(3.2rem, 11vw, 5.4rem); line-height: 1.05; color: var(--lc-glow); text-shadow: 0 0 20px var(--lc-halo); margin: 6px 0 10px; }
.lc-hashtag { letter-spacing: .12em; color: var(--inv-primary); }

@media (prefers-reduced-motion: reduce) {
    .lc-trail circle, .lc-jar-fly, .lc-countdown .kit-countdown-value, .lc-stop.is-visible .lc-stop-light,
    .kit-js .lc-hero-text > *, .kit-js .lc-window { animation: none; }
    .kit-js .lc-trail path { transition: none; stroke-dashoffset: 0; }
}
