/* ==========================================================================
   FONTY (lokální soubory ve složce /fonts)
   ========================================================================== */
@font-face {
    font-family: 'The Seasons';
    src: url('fonts/the-seasons-light.woff2') format('woff2');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'The Seasons';
    src: url('fonts/the-seasons-regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'The Seasons';
    src: url('fonts/the-seasons-italic.woff2') format('woff2');
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: 'The Seasons';
    src: url('fonts/the-seasons-bold.woff2') format('woff2');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Montserrat';
    src: url('fonts/montserrat-variable.woff2') format('woff2-variations'),
         url('fonts/montserrat-variable.woff2') format('woff2');
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

/* ==========================================================================
   PROMĚNNÉ
   ========================================================================== */
:root {
    --blue: #1E4FA3;            /* sytá modrá z pozvánky (linky, nadpisy) */
    --blue-dark: #163C80;
    --sky: #A9D4F2;             /* světle modrá akvarelová */
    --sky-soft: #D6EBFA;
    --sky-faint: #EEF6FD;
    --paper: #FBF9F3;
    --text: #1F2F4D;
    --text-light: #4D5D7A;
    --border: rgba(30, 79, 163, 0.22);
    --error-color: #C0392B;
    --leaf-fill: var(--paper);

    --font-heading: 'The Seasons', 'Cormorant Garamond', Georgia, serif;
    --font-body: 'Montserrat', system-ui, -apple-system, 'Segoe UI', sans-serif;

    --shadow-soft: 0 18px 50px -20px rgba(22, 60, 128, 0.35);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
    font-family: var(--font-body);
    font-weight: 400;
    color: var(--text);
    background-color: var(--paper);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.ico { display: block; color: var(--blue); }

.hidden { display: none !important; }

/* Akvarelové modré pozadí s jemnou texturou */
.watercolor {
    background-color: var(--sky);
    background-image:
        radial-gradient(ellipse 60% 50% at 15% 20%, rgba(255,255,255,0.55), transparent 70%),
        radial-gradient(ellipse 50% 60% at 85% 75%, rgba(255,255,255,0.45), transparent 70%),
        radial-gradient(ellipse 40% 40% at 70% 15%, rgba(150,200,240,0.6), transparent 70%),
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.012' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.35 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Papírová karta s nepravidelným okrajem jako na pozvánce */
.paper {
    position: relative;
    isolation: isolate;
}
.paper::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    background-color: var(--paper);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='p'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.12 0 0 0 0 0.3 0 0 0 0 0.6 0 0 0 0.05 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23p)'/%3E%3C/svg%3E");
    /* nepravidelný „natrhaný" okraj papíru */
    clip-path: polygon(0.00% 5.8px, 1.43% 7.3px, 2.86% 9.2px, 4.29% 10px, 5.71% 10px, 7.14% 10px, 8.57% 7.0px, 10.00% 6.8px, 11.43% 9.6px, 12.86% 10px, 14.29% 10px, 15.71% 7.5px, 17.14% 7.3px, 18.57% 5.7px, 20.00% 6.0px, 21.43% 6.5px, 22.86% 3.3px, 24.29% 1.5px, 25.71% 0.5px, 27.14% 3.2px, 28.57% 4.9px, 30.00% 2.7px, 31.43% 4.6px, 32.86% 2.3px, 34.29% 3.0px, 35.71% 0.6px, 37.14% 0.5px, 38.57% 2.9px, 40.00% 1.0px, 41.43% 0.5px, 42.86% 3.6px, 44.29% 6.0px, 45.71% 4.6px, 47.14% 7.6px, 48.57% 7.8px, 50.00% 9.0px, 51.43% 7.1px, 52.86% 9.9px, 54.29% 10px, 55.71% 10px, 57.14% 10px, 58.57% 8.7px, 60.00% 7.8px, 61.43% 5.7px, 62.86% 3.4px, 64.29% 0.6px, 65.71% 0.5px, 67.14% 1.2px, 68.57% 0.5px, 70.00% 1.6px, 71.43% 0.6px, 72.86% 0.5px, 74.29% 2.5px, 75.71% 2.4px, 77.14% 1.2px, 78.57% 1.1px, 80.00% 2.4px, 81.43% 0.5px, 82.86% 3.5px, 84.29% 0.5px, 85.71% 2.1px, 87.14% 4.3px, 88.57% 1.2px, 90.00% 3.1px, 91.43% 2.2px, 92.86% 2.7px, 94.29% 0.5px, 95.71% 0.5px, 97.14% 0.5px, 98.57% 3.4px, calc(100% - 3.1px) 0.00%, calc(100% - 4.7px) 1.43%, calc(100% - 7.4px) 2.86%, calc(100% - 10px) 4.29%, calc(100% - 9.0px) 5.71%, calc(100% - 8.1px) 7.14%, calc(100% - 8.2px) 8.57%, calc(100% - 10.0px) 10.00%, calc(100% - 7.5px) 11.43%, calc(100% - 9.1px) 12.86%, calc(100% - 10px) 14.29%, calc(100% - 10px) 15.71%, calc(100% - 7.0px) 17.14%, calc(100% - 9.9px) 18.57%, calc(100% - 7.3px) 20.00%, calc(100% - 6.3px) 21.43%, calc(100% - 7.0px) 22.86%, calc(100% - 9.6px) 24.29%, calc(100% - 8.6px) 25.71%, calc(100% - 10px) 27.14%, calc(100% - 10px) 28.57%, calc(100% - 8.8px) 30.00%, calc(100% - 7.6px) 31.43%, calc(100% - 5.6px) 32.86%, calc(100% - 2.9px) 34.29%, calc(100% - 0.6px) 35.71%, calc(100% - 1.8px) 37.14%, calc(100% - 5.0px) 38.57%, calc(100% - 2.8px) 40.00%, calc(100% - 0.5px) 41.43%, calc(100% - 3.6px) 42.86%, calc(100% - 3.8px) 44.29%, calc(100% - 3.2px) 45.71%, calc(100% - 1.5px) 47.14%, calc(100% - 2.1px) 48.57%, calc(100% - 4.2px) 50.00%, calc(100% - 4.0px) 51.43%, calc(100% - 3.5px) 52.86%, calc(100% - 0.6px) 54.29%, calc(100% - 3.3px) 55.71%, calc(100% - 0.5px) 57.14%, calc(100% - 0.5px) 58.57%, calc(100% - 2.7px) 60.00%, calc(100% - 0.5px) 61.43%, calc(100% - 2.0px) 62.86%, calc(100% - 4.9px) 64.29%, calc(100% - 5.7px) 65.71%, calc(100% - 7.5px) 67.14%, calc(100% - 5.0px) 68.57%, calc(100% - 4.6px) 70.00%, calc(100% - 2.4px) 71.43%, calc(100% - 4.6px) 72.86%, calc(100% - 3.3px) 74.29%, calc(100% - 3.0px) 75.71%, calc(100% - 6.1px) 77.14%, calc(100% - 8.4px) 78.57%, calc(100% - 10px) 80.00%, calc(100% - 9.7px) 81.43%, calc(100% - 9.6px) 82.86%, calc(100% - 10px) 84.29%, calc(100% - 9.9px) 85.71%, calc(100% - 8.5px) 87.14%, calc(100% - 7.9px) 88.57%, calc(100% - 5.7px) 90.00%, calc(100% - 4.9px) 91.43%, calc(100% - 8.0px) 92.86%, calc(100% - 10px) 94.29%, calc(100% - 10px) 95.71%, calc(100% - 10.0px) 97.14%, calc(100% - 9.0px) 98.57%, 100.00% calc(100% - 2.4px), 98.57% calc(100% - 0.9px), 97.14% calc(100% - 2.7px), 95.71% calc(100% - 5.1px), 94.29% calc(100% - 4.2px), 92.86% calc(100% - 6.0px), 91.43% calc(100% - 7.8px), 90.00% calc(100% - 9.0px), 88.57% calc(100% - 10px), 87.14% calc(100% - 10px), 85.71% calc(100% - 9.1px), 84.29% calc(100% - 10px), 82.86% calc(100% - 8.6px), 81.43% calc(100% - 8.5px), 80.00% calc(100% - 10px), 78.57% calc(100% - 10px), 77.14% calc(100% - 8.7px), 75.71% calc(100% - 10px), 74.29% calc(100% - 10px), 72.86% calc(100% - 10px), 71.43% calc(100% - 6.9px), 70.00% calc(100% - 7.2px), 68.57% calc(100% - 5.6px), 67.14% calc(100% - 6.7px), 65.71% calc(100% - 6.4px), 64.29% calc(100% - 8.5px), 62.86% calc(100% - 9.4px), 61.43% calc(100% - 10px), 60.00% calc(100% - 9.0px), 58.57% calc(100% - 9.9px), 57.14% calc(100% - 10px), 55.71% calc(100% - 10px), 54.29% calc(100% - 9.0px), 52.86% calc(100% - 10px), 51.43% calc(100% - 10px), 50.00% calc(100% - 10px), 48.57% calc(100% - 10px), 47.14% calc(100% - 10px), 45.71% calc(100% - 10px), 44.29% calc(100% - 10px), 42.86% calc(100% - 7.9px), 41.43% calc(100% - 10px), 40.00% calc(100% - 10px), 38.57% calc(100% - 9.9px), 37.14% calc(100% - 10px), 35.71% calc(100% - 10px), 34.29% calc(100% - 10px), 32.86% calc(100% - 7.9px), 31.43% calc(100% - 9.7px), 30.00% calc(100% - 10px), 28.57% calc(100% - 10px), 27.14% calc(100% - 9.5px), 25.71% calc(100% - 10px), 24.29% calc(100% - 10px), 22.86% calc(100% - 10px), 21.43% calc(100% - 10px), 20.00% calc(100% - 7.0px), 18.57% calc(100% - 4.8px), 17.14% calc(100% - 4.4px), 15.71% calc(100% - 5.4px), 14.29% calc(100% - 3.6px), 12.86% calc(100% - 4.8px), 11.43% calc(100% - 5.6px), 10.00% calc(100% - 2.7px), 8.57% calc(100% - 2.5px), 7.14% calc(100% - 0.7px), 5.71% calc(100% - 0.5px), 4.29% calc(100% - 0.5px), 2.86% calc(100% - 0.5px), 1.43% calc(100% - 0.5px), 3.0px 100.00%, 0.5px 98.57%, 0.5px 97.14%, 0.5px 95.71%, 1.2px 94.29%, 1.8px 92.86%, 0.5px 91.43%, 3.1px 90.00%, 0.5px 88.57%, 0.5px 87.14%, 0.5px 85.71%, 0.5px 84.29%, 0.5px 82.86%, 2.6px 81.43%, 1.8px 80.00%, 0.5px 78.57%, 1.2px 77.14%, 0.5px 75.71%, 0.8px 74.29%, 0.5px 72.86%, 1.0px 71.43%, 4.0px 70.00%, 6.0px 68.57%, 5.5px 67.14%, 7.5px 65.71%, 8.4px 64.29%, 7.5px 62.86%, 5.3px 61.43%, 5.9px 60.00%, 6.3px 58.57%, 9.2px 57.14%, 10px 55.71%, 10px 54.29%, 9.0px 52.86%, 10px 51.43%, 6.8px 50.00%, 4.3px 48.57%, 4.7px 47.14%, 5.5px 45.71%, 3.2px 44.29%, 4.0px 42.86%, 6.5px 41.43%, 5.7px 40.00%, 5.3px 38.57%, 3.5px 37.14%, 2.2px 35.71%, 5.2px 34.29%, 4.4px 32.86%, 7.4px 31.43%, 10px 30.00%, 10px 28.57%, 8.5px 27.14%, 10px 25.71%, 10.0px 24.29%, 9.4px 22.86%, 8.3px 21.43%, 10px 20.00%, 9.9px 18.57%, 8.6px 17.14%, 8.4px 15.71%, 6.0px 14.29%, 6.8px 12.86%, 6.4px 11.43%, 5.1px 10.00%, 6.9px 8.57%, 9.0px 7.14%, 5.9px 5.71%, 6.1px 4.29%, 4.6px 2.86%, 7.4px 1.43%);
}

/* ==========================================================================
   TYPOGRAFIE A TLAČÍTKA
   ========================================================================== */
h1, h2, h3, .font-heading {
    font-family: var(--font-heading);
    font-weight: 400;
    color: var(--blue);
    line-height: 1.15;
}

.eyebrow {
    display: block;
    font-family: var(--font-body);
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--blue);
    opacity: 0.75;
    margin-bottom: 0.9rem;
}

.section-title {
    font-size: clamp(2.2rem, 5vw, 3.2rem);
    margin-bottom: 1.2rem;
}

.section-text {
    font-size: 1rem;
    color: var(--text-light);
    margin-bottom: 1.2rem;
}

.text-center { text-align: center; }

.divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.9rem;
    color: var(--blue);
    margin: 1.2rem auto;
    max-width: 320px;
}
.divider::before, .divider::after {
    content: '';
    flex: 1;
    height: 1.5px;
    background: currentColor;
}
.divider .ico { width: 18px; height: 18px; }
.divider.plain::before { flex: 1; }
.divider.plain::after { display: none; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    font-family: var(--font-heading);
    font-size: 1.2rem;
    letter-spacing: 0.02em;
    text-decoration: none;
    padding: 0.85rem 2.2rem;
    border-radius: 999px;
    border: 1.5px solid var(--blue);
    background: var(--blue);
    color: #fff;
    cursor: pointer;
    transition: background 0.25s, color 0.25s, transform 0.25s, box-shadow 0.25s;
    box-shadow: 0 10px 24px -12px rgba(22, 60, 128, 0.7);
}
.btn:hover {
    background: var(--blue-dark);
    transform: translateY(-2px);
    box-shadow: 0 14px 28px -12px rgba(22, 60, 128, 0.8);
}
.btn-outline {
    background: transparent;
    color: var(--blue);
    box-shadow: none;
}
.btn-outline:hover { background: var(--blue); color: #fff; }
.btn-light {
    background: var(--paper);
    border-color: var(--paper);
    color: var(--blue);
}
.btn-light:hover { background: #fff; color: var(--blue-dark); }

/* ==========================================================================
   NAVIGACE
   ========================================================================== */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    background: rgba(251, 249, 243, 0.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}
.nav-content {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0.55rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}
.nav-brand {
    position: relative;
    display: block;
    width: 150px;
    aspect-ratio: 220 / 80;
    color: var(--blue);
    text-decoration: none;
}
.nav-brand .ico { width: 100%; height: 100%; }
/* monogram uvnitř srdce */
.nav-brand span {
    position: absolute;
    left: 50%;
    top: 43%;
    transform: translate(-50%, -50%);
    font-family: var(--font-heading);
    font-size: 0.95rem;
    line-height: 1;
    letter-spacing: -0.02em;
    white-space: nowrap;
}
.nav-links { display: flex; align-items: center; gap: 2rem; }
.nav-links a {
    font-size: 0.78rem;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text);
    text-decoration: none;
    transition: color 0.2s;
}
.nav-links a:not(.btn):hover { color: var(--blue); }
.nav-links .btn {
    font-size: 1rem;
    letter-spacing: 0.02em;
    text-transform: none;
    padding: 0.5rem 1.4rem;
    color: #fff;
}

/* ==========================================================================
   HERO (pozvánka)
   ========================================================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 7rem 1.25rem 4rem;
}
.invite {
    width: 100%;
    max-width: 560px;
    padding: 2.6rem 2.5rem 3rem;
    text-align: center;
}
.invite .laurel { width: min(300px, 80%); height: auto; margin: 0 auto 1.4rem; aspect-ratio: 360 / 80; }

.wreath {
    position: relative;
    width: min(360px, 82vw);
    aspect-ratio: 1;
    margin: 0 auto 1.6rem;
}
.wreath img {
    position: absolute;
    inset: 8%;
    width: 84%;
    height: 84%;
    object-fit: cover;
    border-radius: 50%;
}
.wreath .ico { position: absolute; inset: 0; width: 100%; height: 100%; }

.invite .names {
    font-size: clamp(2.6rem, 9vw, 3.6rem);
}
.invite .lead {
    font-family: var(--font-heading);
    font-size: clamp(1.4rem, 4.5vw, 1.8rem);
    color: var(--blue);
}
.invite .date {
    margin-top: 1rem;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--blue);
}
.invite .subtitle {
    max-width: 360px;
    margin: 0.9rem auto 1.8rem;
    color: var(--text-light);
    font-size: 0.95rem;
}
.invite-corner {
    position: absolute;
    bottom: 1.6rem;
    width: 96px;
    height: auto;
}
.invite-corner.rings { left: 1.4rem; aspect-ratio: 130 / 100; }
.invite-corner.envelope { right: 1.2rem; aspect-ratio: 140 / 100; width: 104px; }
.invite .btn { position: relative; z-index: 1; }

/* ==========================================================================
   SEKCE
   ========================================================================== */
.section { padding: 6.5rem 1.5rem; position: relative; }
.section-inner { max-width: 1100px; margin: 0 auto; }
.bg-paper { background: var(--paper); }
.bg-sky { background: var(--sky-faint); }

.section-head { text-align: center; max-width: 640px; margin: 0 auto 3.5rem; }
.section-head .laurel { width: 220px; height: auto; aspect-ratio: 360 / 80; margin: 0 auto 1.2rem; }

/* Příběh */
.story {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 4rem;
    align-items: center;
}
.story-art {
    position: relative;
    aspect-ratio: 1;
    max-width: 400px;
    width: 100%;
    margin: 0 auto;
    display: grid;
    place-items: center;
}
.story-art::before {
    content: '';
    position: absolute;
    inset: 8%;
    border-radius: 50%;
    background: var(--sky-soft);
}
.story-art > .ico { position: absolute; inset: 0; width: 100%; height: 100%; --leaf-fill: var(--paper); }
.story-art .rings-big { position: relative; width: 52%; height: auto; aspect-ratio: 130 / 100; --leaf-fill: var(--sky-soft); }

/* Kdy a kde */
.info-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    max-width: 860px;
    margin: 0 auto 4.5rem;
}
.info-card {
    background: #fff;
    border: 1.5px solid var(--border);
    border-radius: 24px;
    padding: 2.4rem 2rem;
    text-align: center;
    box-shadow: var(--shadow-soft);
    position: relative;
}
.info-card::after {
    content: '';
    position: absolute;
    inset: 8px;
    border: 1px solid var(--border);
    border-radius: 18px;
    pointer-events: none;
}
.info-card .ico { width: 64px; height: 64px; margin: 0 auto 1rem; }
.info-card h3 { font-size: 1.8rem; margin-bottom: 0.6rem; }
.info-card .big { font-weight: 600; color: var(--text); }
.info-card .sub-detail { font-size: 0.9rem; color: var(--text-light); margin-top: 0.5rem; }

.gallery {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-auto-rows: 200px;
    gap: 1rem;
}
.gallery figure {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    margin: 0;
}
.gallery figure img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.gallery figure:hover img { transform: scale(1.05); }
.gallery figure:nth-child(1) { grid-column: span 4; grid-row: span 2; border-radius: 200px 200px 18px 18px; }
.gallery figure:nth-child(2) { grid-column: span 2; }
.gallery figure:nth-child(3) { grid-column: span 2; }
.gallery figure:nth-child(4) { grid-column: span 3; }
.gallery figure:nth-child(5) { grid-column: span 3; }

/* Harmonogram */
.timeline {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
}
.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 10px;
    bottom: 10px;
    border-left: 2px dashed var(--sky);
    transform: translateX(-1px);
}
.timeline-item {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 84px 1fr;
    align-items: center;
    gap: 1.6rem;
    margin-bottom: 2.2rem;
}
.timeline-item:last-child { margin-bottom: 0; }
.timeline-icon {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    background: var(--paper);
    border: 2px solid var(--blue);
    display: grid;
    place-items: center;
    position: relative;
    z-index: 1;
    box-shadow: 0 0 0 7px var(--sky-faint);
}
.timeline-icon .ico { width: 52px; height: 52px; }
.timeline-item .time {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    color: var(--blue);
    text-align: right;
}
.timeline-item .event { font-weight: 500; color: var(--text); }
.timeline-item:nth-child(even) .time { order: 3; text-align: left; }
.timeline-item:nth-child(even) .timeline-icon { order: 2; }
.timeline-item:nth-child(even) .event { order: 1; text-align: right; }

/* Výzva k potvrzení */
.cta {
    text-align: center;
    padding: 6rem 1.5rem;
}
.cta-card {
    max-width: 720px;
    margin: 0 auto;
    padding: 3.5rem 2.5rem;
}
.cta-card .envelope-big { width: 150px; height: auto; aspect-ratio: 140 / 100; margin: 0 auto 1.5rem; }
.cta-card .section-text { max-width: 520px; margin: 0 auto 2rem; }

/* Patička */
.footer {
    background: var(--blue);
    color: var(--sky-soft);
    text-align: center;
    padding: 3rem 1.5rem;
}
.footer .laurel { width: 180px; height: auto; aspect-ratio: 360 / 80; margin: 0 auto 1rem; color: var(--sky); --leaf-fill: var(--blue); }
.footer p { font-family: var(--font-heading); font-size: 1.4rem; }
.footer small { display: block; margin-top: 0.3rem; font-size: 0.75rem; letter-spacing: 0.25em; text-transform: uppercase; opacity: 0.75; }

/* ==========================================================================
   FORMULÁŘ
   ========================================================================== */
.form-page {
    min-height: 100vh;
    padding: 7.5rem 1rem 4rem;
}
.container {
    max-width: 640px;
    margin: 0 auto;
}
.form-card {
    padding: 2.8rem 2.6rem 2.6rem;
}
.header { text-align: center; margin-bottom: 2.2rem; }
.header .laurel { width: 240px; height: auto; aspect-ratio: 360 / 80; margin: 0 auto 1rem; }
.header h1 { font-size: clamp(2.4rem, 8vw, 3.2rem); }
.header .date {
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--blue);
    margin-top: 0.4rem;
}
.header .subtitle { color: var(--text-light); margin-top: 0.4rem; }

.form-group { margin-bottom: 1.8rem; }

label,
.allergens-section h3 {
    display: block;
    font-family: var(--font-heading);
    font-size: 1.35rem;
    color: var(--blue);
    margin-bottom: 0.6rem;
}

input[type="text"],
input[type="email"],
input[type="tel"] {
    width: 100%;
    font-family: var(--font-body);
    font-size: 1rem;
    color: var(--text);
    padding: 0.9rem 1.1rem;
    background: #fff;
    border: 1.5px solid var(--border);
    border-radius: 14px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
input::placeholder { color: #9AA6BC; }
input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus {
    border-color: var(--blue);
    box-shadow: 0 0 0 4px rgba(169, 212, 242, 0.55);
}

/* Vyhledávací select hostů */
.custom-select-container { position: relative; }
.custom-select-trigger { position: relative; }
.custom-select-trigger input { padding-right: 3rem; }
.custom-select-trigger .arrow {
    position: absolute;
    right: 1.1rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.7rem;
    color: var(--blue);
    pointer-events: none;
    transition: transform 0.25s;
}
.custom-select-container.open .arrow { transform: translateY(-50%) rotate(180deg); }
.custom-select-options {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    max-height: 260px;
    overflow-y: auto;
    background: #fff;
    border: 1.5px solid var(--border);
    border-radius: 14px;
    box-shadow: var(--shadow-soft);
    z-index: 20;
    padding: 0.35rem;
}
.custom-option {
    padding: 0.7rem 0.9rem;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}
.custom-option:hover { background: var(--sky-soft); color: var(--blue); }
.custom-option.no-results { cursor: default; color: var(--text-light); font-style: italic; }
.custom-option.no-results:hover { background: transparent; color: var(--text-light); }

/* Velké volby (účast, ubytování) */
.main-choices {
    display: grid;
    gap: 1rem;
    margin-bottom: 2rem;
}
.big-checkbox-card { margin: 0; cursor: pointer; font-family: var(--font-body); font-size: 1rem; color: var(--text); }
.big-checkbox-card input { position: absolute; opacity: 0; pointer-events: none; }
.big-checkbox-card .card-content {
    display: flex;
    align-items: center;
    gap: 1.1rem;
    padding: 1.1rem 1.3rem;
    background: #fff;
    border: 1.5px solid var(--border);
    border-radius: 18px;
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.big-checkbox-card:hover .card-content { border-color: var(--blue); }
.card-icon {
    flex-shrink: 0;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: var(--sky-faint);
    display: grid;
    place-items: center;
    --leaf-fill: var(--sky-faint);
    transition: background 0.2s;
}
.card-icon .ico { width: 42px; height: 42px; }
.card-text { flex: 1; display: flex; flex-direction: column; }
.card-text .label-text { font-family: var(--font-heading); font-size: 1.25rem; color: var(--blue); line-height: 1.25; }
.card-text .desc-text { font-size: 0.85rem; color: var(--text-light); }
.checkmark-big {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1.5px solid var(--blue);
    position: relative;
    transition: background 0.2s;
}
.checkmark-big::after {
    content: '';
    position: absolute;
    left: 9px; top: 5px;
    width: 7px; height: 12px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg) scale(0);
    transition: transform 0.2s;
}
.big-checkbox-card input:checked + .card-content {
    border-color: var(--blue);
    background: var(--sky-faint);
    box-shadow: 0 0 0 3px rgba(169, 212, 242, 0.6);
}
.big-checkbox-card input:checked + .card-content .card-icon { background: var(--sky-soft); --leaf-fill: var(--sky-soft); }
.big-checkbox-card input:checked + .card-content .checkmark-big { background: var(--blue); }
.big-checkbox-card input:checked + .card-content .checkmark-big::after { transform: rotate(45deg) scale(1); }
.big-checkbox-card input:focus-visible + .card-content { outline: 2px solid var(--blue); outline-offset: 3px; }

/* Alergeny */
.allergens-section {
    padding-top: 1.6rem;
    border-top: 1.5px solid var(--border);
}
.section-desc { font-size: 0.9rem; color: var(--text-light); margin-bottom: 1rem; }
.allergens-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.6rem;
}
.custom-checkbox {
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    margin: 0;
    padding: 0.6rem 0.85rem;
    background: #fff;
    border: 1.5px solid var(--border);
    border-radius: 12px;
    cursor: pointer;
    font-family: var(--font-body);
    font-size: 0.9rem;
    color: var(--text);
    transition: border-color 0.2s, background 0.2s;
}
.custom-checkbox:hover { border-color: var(--blue); }
.custom-checkbox input { position: absolute; opacity: 0; pointer-events: none; }
.custom-checkbox .checkmark {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    border: 1.5px solid var(--blue);
    border-radius: 5px;
    position: relative;
    transition: background 0.2s;
}
.custom-checkbox .checkmark::after {
    content: '';
    position: absolute;
    left: 5px; top: 1px;
    width: 5px; height: 10px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg) scale(0);
    transition: transform 0.15s;
}
.custom-checkbox:has(input:checked) { background: var(--sky-faint); border-color: var(--blue); }
.custom-checkbox input:checked + .checkmark { background: var(--blue); }
.custom-checkbox input:checked + .checkmark::after { transform: rotate(45deg) scale(1); }
.custom-checkbox input:focus-visible + .checkmark { outline: 2px solid var(--blue); outline-offset: 2px; }

/* Údaje hosta – zamčené, dokud není vybráno jméno */
.guest-details { position: relative; }
.guest-details > *:not(.guest-details-overlay) { transition: opacity 0.3s, filter 0.3s; }
.guest-details.is-locked > *:not(.guest-details-overlay),
.guest-details.is-loading > *:not(.guest-details-overlay) {
    opacity: 0.35;
    filter: grayscale(0.6);
    pointer-events: none;
    user-select: none;
}
.guest-details-overlay {
    display: none;
    position: absolute;
    inset: 0;
    z-index: 5;
    justify-content: center;
    align-items: flex-start;
    padding-top: 4rem;
    text-align: center;
}
.guest-details.is-locked .guest-details-overlay,
.guest-details.is-loading .guest-details-overlay { display: flex; }
.locked-hint, .details-loading {
    position: sticky;
    top: 45vh;
    background: var(--paper);
    border: 1.5px solid var(--border);
    border-radius: 999px;
    padding: 0.7rem 1.4rem;
    font-family: var(--font-heading);
    font-size: 1.2rem;
    color: var(--blue);
    box-shadow: var(--shadow-soft);
}
.details-loading { display: none; border-radius: 18px; padding: 1.2rem 1.6rem; font-family: var(--font-body); font-size: 0.95rem; color: var(--text-light); }
.details-loading .spinner { width: 34px; height: 34px; margin-bottom: 0.6rem; }
.guest-details.is-loading .locked-hint { display: none; }
.guest-details.is-loading .details-loading { display: block; }

/* Přípitek – přepínač Alko / Nealko */
.field-label {
    display: block;
    font-family: var(--font-heading);
    font-size: 1.35rem;
    color: var(--blue);
    margin-bottom: 0.6rem;
}
.toast-switch {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 1rem 1.3rem;
    background: #fff;
    border: 1.5px solid var(--border);
    border-radius: 18px;
}
.toast-option {
    flex: 1;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--text-light);
    opacity: 0.55;
    cursor: pointer;
    transition: color 0.2s, opacity 0.2s;
    user-select: none;
}
.toast-option[data-value="Alko"] { text-align: right; }
.toast-option.active { color: var(--blue); opacity: 1; }
.switch { position: relative; display: inline-block; margin: 0; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch-track {
    display: block;
    width: 60px;
    height: 32px;
    border-radius: 999px;
    background: var(--blue);
    transition: background 0.25s;
}
.switch-thumb {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--paper);
    box-shadow: 0 2px 6px rgba(22, 60, 128, 0.35);
    transition: transform 0.25s;
}
.switch input:checked + .switch-track { background: var(--sky); }
.switch input:checked + .switch-track .switch-thumb { transform: translateX(28px); }
.switch input:focus-visible + .switch-track { outline: 2px solid var(--blue); outline-offset: 3px; }

/* Odeslání */
.submit-btn { width: 100%; margin-top: 0.6rem; padding: 1rem 2rem; font-size: 1.35rem; min-height: 58px; }
.submit-btn:disabled { opacity: 0.75; cursor: wait; transform: none; }

/* Načítání */
.loader-wrapper { text-align: center; padding: 2.5rem 0; color: var(--text-light); }
.spinner, .btn-loader {
    border-radius: 50%;
    border: 3px solid var(--sky-soft);
    border-top-color: var(--blue);
    animation: spin 0.9s linear infinite;
}
.spinner { width: 46px; height: 46px; margin: 0 auto 1rem; }
.btn-loader { width: 22px; height: 22px; border-color: rgba(255,255,255,0.35); border-top-color: #fff; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Výsledky */
#success-message { text-align: center; padding: 1rem 0 0.5rem; }
#success-message .success-icon { width: 150px; height: auto; aspect-ratio: 140 / 100; margin: 0 auto 1.2rem; }
#success-message h2 { font-size: 2.8rem; margin-bottom: 0.5rem; }
#success-message p { color: var(--text-light); }

#error-message {
    margin-top: 1.2rem;
    padding: 1rem 1.2rem;
    border-radius: 14px;
    background: #FDF0EE;
    border: 1.5px solid rgba(192, 57, 43, 0.3);
    color: var(--error-color);
    text-align: center;
    font-size: 0.92rem;
}

.back-link-container { text-align: center; margin-top: 2rem; }
.back-link {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--blue);
    text-decoration: none;
    border-bottom: 1.5px solid transparent;
    transition: border-color 0.2s;
}
.back-link:hover { border-color: var(--blue); }

/* ==========================================================================
   ANIMACE PŘI SCROLLU
   ========================================================================== */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    html { scroll-behavior: auto; }
}

/* ==========================================================================
   RESPONZIVITA
   ========================================================================== */
@media (max-width: 900px) {
    .story { grid-template-columns: 1fr; gap: 2.5rem; text-align: center; }
    .story-art { max-width: 320px; }
    .gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 180px; }
    .gallery figure:nth-child(n) { grid-column: span 1; grid-row: span 1; border-radius: 18px; }
    .gallery figure:nth-child(1) { grid-column: span 2; grid-row: span 2; border-radius: 200px 200px 18px 18px; }
    .gallery figure:nth-child(5) { grid-column: span 2; }
}

@media (max-width: 760px) {
    .nav-links a:not(.btn) { display: none; }
    .info-cards { grid-template-columns: 1fr; }
    .section { padding: 4.5rem 1rem; }

    .timeline::before { left: 32px; }
    .timeline-item,
    .timeline-item:nth-child(even) {
        grid-template-columns: 64px 1fr;
        grid-template-rows: auto auto;
        column-gap: 1.2rem;
        row-gap: 0;
    }
    .timeline-item .timeline-icon,
    .timeline-item:nth-child(even) .timeline-icon {
        order: 0;
        width: 64px; height: 64px;
        grid-row: span 2;
    }
    .timeline-icon .ico { width: 40px; height: 40px; }
    .timeline-item .time,
    .timeline-item:nth-child(even) .time { order: 1; text-align: left; font-size: 1.8rem; }
    .timeline-item .event,
    .timeline-item:nth-child(even) .event { order: 2; text-align: left; }
}

@media (max-width: 560px) {
    .invite { padding: 2rem 1.3rem 7rem; }
    .invite-corner { bottom: 1.3rem; width: 78px; }
    .invite-corner.envelope { width: 86px; }
    .form-card { padding: 2.2rem 1.3rem; }
    .allergens-grid { grid-template-columns: 1fr; }
    .cta-card { padding: 3rem 1.3rem; }
    .nav-content { padding: 0.7rem 1rem; }
}
