:root {
    --bg-dark: #1a1c18;
    --bg-light: #fdfcf9;
    --primary-green: #4a5043;
    --accent-gold: #c5a37d;
    --text-main: #3d3d3d;
    --text-muted: #8a8a8a;
    --white: #fff;
    --decorative-font: 'Great Vibes', cursive;
    --main-font: Montserrat, sans-serif
}

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden
}

body {
    font-family: var(--main-font);
    background: var(--bg-light);
    color: var(--white);
    -webkit-font-smoothing: antialiased;
    line-height: 1.6;
    overflow-x: hidden
}

/* ===== HERO SECTION ===== */
.hero {
    position: relative;
    height: 100vh;
    height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden
}

/* Particles canvas */
.hero-particles {
    position: absolute;
    inset: 0;
    z-index: 5;
    pointer-events: none
}

.hero-background {
    position: absolute;
    inset: 0;
    z-index: 1
}

.hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.08);
    animation: heroZoomIn 18s ease-out forwards
}

@keyframes heroZoomIn {
    0% {
        transform: scale(1.15)
    }

    100% {
        transform: scale(1.03)
    }
}

/* Multi-layer overlays */
.overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(0, 0, 0, 0.35) 0%, rgba(0, 0, 0, 0.05) 40%, rgba(0, 0, 0, 0.1) 60%, rgba(0, 0, 0, 0.55) 100%);
    z-index: 2
}

.overlay-vignette {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, transparent 40%, rgba(0, 0, 0, 0.55) 100%);
    z-index: 3
}

.overlay-grain {
    position: absolute;
    inset: 0;
    z-index: 4;
    opacity: 0.06;
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    background-size: 128px 128px
}

/* Gold corner frame */
.hero-frame {
    position: absolute;
    inset: 28px;
    z-index: 6;
    pointer-events: none
}

.hero-frame-corner {
    position: absolute;
    width: 60px;
    height: 60px;
    opacity: 0;
    animation: frameCornerIn 1.5s cubic-bezier(0.16, 1, 0.3, 1) forwards
}

.hero-frame-tl {
    top: 0;
    left: 0;
    border-top: 1px solid var(--accent-gold);
    border-left: 1px solid var(--accent-gold);
    animation-delay: 1.2s
}

.hero-frame-tr {
    top: 0;
    right: 0;
    border-top: 1px solid var(--accent-gold);
    border-right: 1px solid var(--accent-gold);
    animation-delay: 1.4s
}

.hero-frame-bl {
    bottom: 0;
    left: 0;
    border-bottom: 1px solid var(--accent-gold);
    border-left: 1px solid var(--accent-gold);
    animation-delay: 1.6s
}

.hero-frame-br {
    bottom: 0;
    right: 0;
    border-bottom: 1px solid var(--accent-gold);
    border-right: 1px solid var(--accent-gold);
    animation-delay: 1.8s
}

@keyframes frameCornerIn {
    0% {
        opacity: 0;
        width: 0;
        height: 0
    }

    50% {
        opacity: 0.7
    }

    100% {
        opacity: 0.45;
        width: 60px;
        height: 60px
    }
}

/* Hero content */
.hero-content {
    position: relative;
    z-index: 7;
    text-align: center;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0
}

/* Micro label */
.hero-label {
    font-family: var(--main-font);
    font-size: clamp(0.6rem, 2.5vw, 0.75rem);
    text-transform: uppercase;
    letter-spacing: 0.5em;
    color: var(--accent-gold);
    margin-bottom: 20px;
    opacity: 0;
    transform: translateY(-15px);
    animation: heroFadeUp 1s ease-out 0.5s forwards
}

/* Names */
.name {
    font-family: var(--decorative-font);
    font-size: clamp(4.5rem, 18vw, 9rem);
    font-weight: 400;
    font-style: normal;
    line-height: 0.85;
    margin: 0;
    text-shadow: 0 2px 30px rgba(0, 0, 0, 0.4), 0 0 80px rgba(0, 0, 0, 0.15);
    color: var(--white);
    opacity: 0;
    transform: translateY(25px);
    letter-spacing: 0.01em
}

.name--first {
    animation: heroFadeUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) 0.7s forwards
}

.name--second {
    animation: heroFadeUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) 1.1s forwards
}

/* Ampersand separator */
.hero-ampersand-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin: 8px 0;
    opacity: 0;
    animation: heroFadeUp 1s ease-out 0.9s forwards
}

.hero-ampersand {
    font-family: var(--decorative-font);
    font-size: clamp(1.5rem, 5vw, 2.2rem);
    color: var(--accent-gold);
    display: inline-block
}

.hero-ampersand-line {
    display: inline-block;
    width: clamp(30px, 12vw, 70px);
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-gold), transparent);
    vertical-align: middle
}

/* Date ornament */
.hero-date-ornament {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin-top: 15px
}

.hero-date-line {
    display: inline-block;
    width: clamp(20px, 8vw, 45px);
    height: 1px;
    background: rgba(255, 255, 255, 0.35)
}

.date {
    margin: 0;
    font-size: clamp(0.7rem, 2.8vw, 1rem);
    letter-spacing: .45em;
    text-transform: uppercase;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.9);
    opacity: 0;
    animation: heroFadeUp 1s ease-out 1.3s forwards
}

/* Mini countdown */
.hero-countdown {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 30px;
    padding: 14px 28px;
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    opacity: 0;
    animation: heroFadeUp 1s ease-out 1.6s forwards
}

.hero-countdown-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 46px
}

.hero-countdown-number {
    font-family: var(--main-font);
    font-size: clamp(1.1rem, 4vw, 1.6rem);
    font-weight: 300;
    color: var(--white);
    line-height: 1;
    letter-spacing: 0.05em
}

.hero-countdown-label {
    font-size: 0.55rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 4px
}

.hero-countdown-sep {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.25);
    margin-top: -10px;
    font-weight: 200
}

/* Scroll down indicator */
.hero-scroll-down {
    position: absolute;
    bottom: 30px;
    left: 0;
    right: 0;
    margin: 0 auto;
    width: max-content;
    z-index: 8;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    opacity: 0;
    animation: heroFadeUp 1s ease-out 2.2s forwards
}

.hero-scroll-text {
    font-size: 0.65rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
    white-space: nowrap;
}

.hero-scroll-arrow {
    animation: heroBounce 2s ease-in-out infinite 3s
}

@keyframes heroBounce {

    0%,
    100% {
        transform: translateY(0)
    }

    50% {
        transform: translateY(8px)
    }
}

/* Master entrance animation */
@keyframes heroFadeUp {
    0% {
        opacity: 0;
        transform: translateY(20px);
        filter: blur(4px)
    }

    100% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0)
    }
}

.invitation-text {
    background-color: var(--bg-light);
    color: var(--text-main);
    padding: 80px 24px;
    text-align: center
}

.invitation-inner {
    max-width: 600px;
    margin: 0 auto
}

.invitation-heading {
    font-family: var(--decorative-font);
    font-size: 3rem;
    color: var(--primary-green);
    margin-bottom: 30px
}

.invitation-inner p {
    font-size: 1.09rem;
    margin-bottom: 20px;
    color: var(--text-main)
}

.invitation-inner .invitation-signature {
    font-family: var(--decorative-font);
    font-size: 1.8rem !important;
    margin-top: 40px;
    color: var(--primary-green);
    line-height: 1.2;
}

/* ===== PHOTO GALLERY — EDITORIAL MINIMAL ===== */
.photo-stack {
    background: var(--bg-light);
    padding: 40px 0 60px;
    overflow: hidden;
}

/* Editorial container */
.gallery-editorial {
    max-width: 500px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Label: ── Наши моменты ── */
.gallery-label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.gallery-label-text {
    font-family: var(--decorative-font);
    font-size: clamp(1.8rem, 6vw, 2.6rem);
    color: var(--primary-green);
    white-space: nowrap;
}

.gallery-label-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-gold), transparent);
    max-width: 80px;
}

/* Photo container */
.gallery-photo-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 3/4;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 20px 60px -15px rgba(0, 0, 0, 0.25);
}

/* Inner gold frame overlay */
.gallery-photo-frame {
    position: absolute;
    inset: 14px;
    border: 1px solid rgba(197, 163, 125, 0.4);
    border-radius: 2px;
    z-index: 5;
    pointer-events: none;
    transition: inset 0.6s ease;
}

.gallery-photo-wrap:hover .gallery-photo-frame {
    inset: 18px;
}

/* Soft vignette */
.gallery-photo-wrap::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at center, transparent 55%, rgba(0, 0, 0, 0.2) 100%);
    z-index: 4;
    pointer-events: none;
}

/* Photo inner */
.gallery-photo-inner {
    position: relative;
    width: 100%;
    height: 100%;
}

.gallery-slide {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transform: scale(1.05);
    transition: opacity 1.2s ease, transform 12s linear;
    z-index: 1;
    will-change: opacity, transform;
}

.gallery-slide.active {
    opacity: 1;
    z-index: 3;
    transform: scale(1);
}

/* Minimal glass arrow buttons */
.gallery-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    width: 44px;
    height: 44px;
    border: none;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: var(--white);
    border-radius: 50%;
    cursor: pointer;
    opacity: 0.8;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    -webkit-tap-highlight-color: transparent;
}

.gallery-arrow.gallery-prev {
    left: 15px;
}

.gallery-arrow.gallery-next {
    right: 15px;
}

.gallery-arrow:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.9);
    color: var(--text-main);
    transform: translateY(-50%) scale(1.1);
}

/* Pip indicators */
.gallery-pager {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 24px;
}

.gallery-pip {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-gold);
    opacity: 0.3;
    cursor: pointer;
    transition: opacity 0.4s, transform 0.4s;
}

.gallery-pip.active {
    opacity: 1;
    transform: scale(1.5);
}

/* Location Photo - Horizontal 4:3 */
.location-photo {
    margin: 0 auto 35px;
    max-width: 500px;
    aspect-ratio: 4/3;
    /* Задаем горизонтальную пропорцию */
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    border: 4px solid #fff;
}

.location-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Заполняем контейнер */
    display: block;
    transition: transform 0.6s ease;
}

.location-photo:hover img {
    transform: scale(1.04);
}

.location-section {
    background-color: var(--bg-light);
    color: var(--text-main);
    padding: 0 24px 60px;
    text-align: center
}

.location-heading {
    font-family: var(--decorative-font);
    font-size: 2.8rem;
    margin-bottom: 20px;
    color: var(--primary-green)
}

.location-address {
    font-size: 1rem;
    max-width: 400px;
    margin: 0 auto 30px;
    color: var(--text-muted)
}

.location-button {
    display: inline-block;
    padding: 14px 35px;
    border: 1px solid var(--primary-green);
    background: transparent;
    color: var(--primary-green);
    text-transform: uppercase;
    letter-spacing: .15em;
    font-size: .8rem;
    border-radius: 40px;
    cursor: pointer;
    transition: all .4s ease;
    text-decoration: none
}

.location-button:hover {
    background: var(--primary-green);
    color: var(--white);
    box-shadow: 0 10px 20px #4a504333
}

.calendar-section {
    background-color: var(--bg-light);
    color: var(--text-main);
    padding: 0 24px 80px;
    text-align: center
}

.calendar-heading {
    font-family: var(--decorative-font);
    font-size: 4rem;
    color: var(--text-main);
    margin-bottom: 30px;
    font-weight: 400
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 15px 10px;
    max-width: 400px;
    margin: 0 auto;
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    font-size: 1.2rem
}

.calendar-day-name {
    font-weight: 400;
    text-transform: uppercase;
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 10px
}

.calendar-day {
    position: relative;
    padding: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1
}

.calendar-day.active {
    font-weight: 600;
    color: var(--primary-green)
}

.calendar-day.active::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 36px;
    height: 36px;
    transform: translate(-50%, -50%);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ff4d4d' stroke-width='1.5'%3E%3Cpath d='M4.318 6.318a4.5 4.5 0 000 6.364L12 20.364l7.682-7.682a4.5 4.5 0 00-6.364-6.364L12 7.636l-1.318-1.318a4.5 4.5 0 00-6.364 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    z-index: -1;
    opacity: 0;
    animation: drawHeart 1.5s ease-out forwards 0.5s, heartBeat 2s infinite ease-in-out 2s
}

@keyframes drawHeart {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.5)
    }

    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.3)
    }
}

.reveal-blur-wrapper .char,
.reveal-blur-wrapper .word,
.reveal-blur-day {
    opacity: 0;
    will-change: transform, opacity, filter
}

@keyframes revealBlur {
    0% {
        opacity: 0;
        filter: blur(10px);
        transform: translateY(10px) scale(1.05)
    }

    100% {
        opacity: 1;
        filter: blur(0);
        transform: translateY(0) scale(1)
    }
}

.reveal-blur-active .char,
.reveal-blur-active .word,
.reveal-blur-active.calendar-day,
.reveal-blur-active.reveal-blur-day {
    animation: revealBlur 1.2s cubic-bezier(0.2, 0.8, 0.2, 1) forwards
}

@keyframes heartBeat {
    0% {
        transform: translate(-50%, -50%) scale(1.3)
    }

    15% {
        transform: translate(-50%, -50%) scale(1.5)
    }

    30% {
        transform: translate(-50%, -50%) scale(1.3)
    }

    45% {
        transform: translate(-50%, -50%) scale(1.45)
    }

    60% {
        transform: translate(-50%, -50%) scale(1.3)
    }

    100% {
        transform: translate(-50%, -50%) scale(1.3)
    }
}

@media (max-width: 480px) {
    .calendar-grid {
        gap: 10px 5px
    }

    .calendar-day {
        padding: 5px;
        font-size: 1rem
    }

    .calendar-heading {
        font-size: 3rem
    }
}

/* Timeline styles moved to the bottom (Robust Timeline section) */

.dresscode-section {
    background-color: var(--primary-green);
    padding: 160px 24px 100px;
    text-align: center;
    position: relative;
    z-index: 1;
    color: var(--white);
    margin-bottom: -5px
}

.dresscode-heading {
    font-family: var(--decorative-font);
    font-size: 3rem;
    margin-bottom: 30px
}

.dresscode-text {
    max-width: 500px;
    margin: 0 auto 40px;
    font-weight: 300;
    opacity: .9
}

.dresscode-palette {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.dresscode-circle {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: transform 0.3s ease;
}

.dresscode-circle:hover {
    transform: scale(1.15);
}

.rsvp-section {
    background-color: var(--primary-green);
    padding: 10px 24px 80px
}

.rsvp-card-container {
    background: var(--bg-light);
    max-width: 420px;
    margin: 0 auto;
    padding: 40px 32px;
    border-radius: 24px;
    box-shadow: 0 25px 50px #00000050;
    color: var(--text-main)
}

.rsvp-heading {
    font-family: var(--decorative-font);
    font-size: 2.6rem;
    text-align: center;
    color: var(--primary-green);
    margin-bottom: 4px
}

.rsvp-subtitle {
    text-align: center;
    font-size: .8rem;
    color: var(--text-muted);
    margin-bottom: 28px;
    letter-spacing: .03em
}

.rsvp-field {
    margin-bottom: 20px
}

.rsvp-label {
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: #999;
    display: block;
    margin-bottom: 8px
}

.rsvp-input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #e8e8e8;
    border-radius: 12px;
    background: #fafafa;
    font-family: inherit;
    font-size: .95rem;
    color: var(--text-main);
    outline: none;
    transition: all .3s ease
}

.rsvp-input:focus {
    border-color: var(--primary-green);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(74, 9, 9, 0.1)
}

.rsvp-textarea {
    min-height: 70px;
    resize: none;
    border-radius: 12px
}

.rsvp-presence-toggle {
    display: flex;
    gap: 10px;
    margin-top: 6px
}

.presence-option {
    flex: 1;
    cursor: pointer
}

.presence-option input {
    display: none
}

.presence-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 12px;
    border: 1px solid #e8e8e8;
    border-radius: 12px;
    transition: all .3s cubic-bezier(0.4, 0, 0.2, 1);
    background: #fafafa
}

.presence-box .emoji {
    font-size: 1.1rem;
    filter: grayscale(1);
    transition: all .3s
}

.presence-box .text {
    font-size: .85rem;
    font-weight: 500;
    color: var(--text-muted)
}

.presence-option input:checked+.presence-box {
    border-color: var(--primary-green);
    background-color: #fff;
    box-shadow: 0 4px 12px rgba(74, 9, 9, 0.15)
}

.presence-option input:checked+.presence-box .emoji {
    filter: grayscale(0);
    transform: scale(1.15)
}

.presence-option input:checked+.presence-box .text {
    color: var(--primary-green)
}

.rsvp-row {
    display: flex;
    gap: 12px
}

.rsvp-row .rsvp-field {
    flex: 1
}

.rsvp-button {
    position: relative;
    overflow: hidden;
    width: 100%;
    padding: 16px;
    margin-top: 8px;
    background: var(--primary-green);
    color: var(--white);
    border: none;
    border-radius: 14px;
    text-transform: uppercase;
    letter-spacing: .15em;
    font-size: .8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all .3s ease
}

.rsvp-button:hover {
    background: #3a0707;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(74, 9, 9, 0.3)
}

/* Button Loading State */
.rsvp-button.is-loading {
    color: transparent !important;
    pointer-events: none;
    background: #3a0707;
    box-shadow: none;
    transform: translateY(0);
}

.rsvp-button.is-loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 22px;
    height: 22px;
    margin-top: -11px;
    margin-left: -11px;
    border: 2px solid rgba(255, 255, 255, 0.25);
    border-top-color: #fff;
    border-radius: 50%;
    animation: rsvpSpin 0.7s linear infinite;
}

@keyframes rsvpSpin {
    to {
        transform: rotate(360deg);
    }
}

/* === RSVP SUCCESS STATE === */
.rsvp-card-container {
    position: relative;
    min-height: 440px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rsvp-form-wrap {
    width: 100%;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.8s cubic-bezier(0.4, 0, 0.2, 1),
        filter 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.rsvp-form-wrap.is-hidden {
    opacity: 0;
    transform: translateY(-20px) scale(0.98);
    filter: blur(10px);
    pointer-events: none;
}

.rsvp-success {
    position: absolute;
    inset: 0;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 40px 24px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.rsvp-success.is-visible {
    display: flex;
    opacity: 1;
    transform: translateY(0);
}

/* Decorative gold line that expands from center */
.rsvp-success-line {
    width: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-gold), transparent);
    margin-bottom: 32px;
    animation: lineExpand 1s cubic-bezier(0.22, 1, 0.36, 1) 0.2s forwards;
}

@keyframes lineExpand {
    to {
        width: 80px;
    }
}

/* Icon — gentle scale-in with subtle float */
.rsvp-success-icon {
    font-size: 3rem;
    margin-bottom: 24px;
    opacity: 0;
    transform: scale(0.5) translateY(10px);
    animation: iconReveal 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.4s forwards;
}

@keyframes iconReveal {
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Title — elegant fade with distance */
.rsvp-success-title {
    font-family: var(--decorative-font);
    font-size: 2.2rem;
    color: var(--primary-green);
    margin-bottom: 14px;
    opacity: 0;
    transform: translateY(30px);
    animation: rsvpReveal 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.7s forwards;
}

/* Subtext */
.rsvp-success-text {
    font-size: 0.92rem;
    color: var(--text-muted);
    font-weight: 300;
    line-height: 1.7;
    max-width: 280px;
    opacity: 0;
    transform: translateY(25px);
    animation: rsvpReveal 0.9s cubic-bezier(0.22, 1, 0.36, 1) 1s forwards;
}

/* Promo — more prominent but elegant signature */
.rsvp-promo {
    margin-top: 40px;
    padding-top: 28px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    opacity: 0;
    transform: translateY(15px);
    animation: rsvpReveal 1s cubic-bezier(0.22, 1, 0.36, 1) 2.5s forwards;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.rsvp-promo-text {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 400;
    line-height: 1.6;
    max-width: 320px;
    opacity: 0.9;
}

.rsvp-promo-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--primary-green);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.03em;
    padding: 8px 18px;
    border: 1px solid rgba(42, 58, 47, 0.1);
    border-radius: 20px;
    transition: all 0.4s ease;
    margin-top: 4px;
}

.rsvp-promo-link:hover {
    background: var(--primary-green);
    color: var(--white);
    border-color: var(--primary-green);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(42, 58, 47, 0.15);
}

@keyframes rsvpReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (prefers-reduced-motion: reduce) {

    .rsvp-form-wrap,
    .rsvp-success-icon,
    .rsvp-success-title,
    .rsvp-success-text,
    .rsvp-success-line,
    .rsvp-promo {
        transition: none;
        animation: none;
        opacity: 1;
        transform: none;
        width: 80px;
        filter: none;
    }
}

.paper--top::before {
    content: "";
    position: absolute;
    left: 0;
    width: 100%;
    height: 67px;
    background-repeat: no-repeat;
    background-position: bottom center;
    background-size: 100% 100%;
    top: 64px;
    transform: translateY(-99%);
    z-index: 10;
    pointer-events: none
}

.paper--bottom::after {
    content: "";
    position: absolute;
    left: 0;
    width: 100%;
    height: 67px;
    background-repeat: no-repeat;
    background-position: top center;
    background-size: 100% 100%;
    bottom: 62px;
    transform: translateY(99%);
    z-index: 10;
    pointer-events: none
}

.bottom-spacer {
    height: 1px;
    background: transparent
}

.reveal,
.reveal-heading,
.reveal-text,
.reveal-card,
.reveal-circle {
    will-change: transform, opacity, filter
}

.reveal-heading {
    opacity: 0;
    transform: translateY(30px);
    filter: blur(10px);
    transition: all 1.2s cubic-bezier(0.16, 1, 0.3, 1)
}

.reveal-text {
    opacity: 0;
    transform: translateY(20px);
    filter: blur(5px);
    transition: all 1s cubic-bezier(0.16, 1, 0.3, 1)
}

.reveal-card {
    opacity: 0;
    transform: translateY(40px) scale(0.98);
    filter: blur(12px);
    transition: all 1.1s cubic-bezier(0.19, 1, 0.22, 1)
}

.reveal-circle {
    opacity: 0;
    transform: scale(0);
}

.active.reveal-circle {
    animation: liquidDrop 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes liquidDrop {
    0% {
        opacity: 0;
        transform: scale(0) scaleY(0.3);
        border-radius: 50%;
    }

    30% {
        opacity: 1;
        transform: scale(1.1) scaleY(0.75);
        border-radius: 45% 45% 50% 50%;
    }

    50% {
        transform: scale(0.95) scaleY(1.15);
        border-radius: 50% 50% 45% 45%;
    }

    70% {
        transform: scale(1.05) scaleY(0.95);
    }

    85% {
        transform: scale(0.98) scaleY(1.02);
    }

    100% {
        opacity: 1;
        transform: scale(1) scaleY(1);
        border-radius: 50%;
    }
}

.reveal-left {
    opacity: 0;
    transform: translateX(-60px);
    filter: blur(10px);
    transition: all 1.6s cubic-bezier(0.2, 0.8, 0.2, 1)
}

.reveal-right {
    opacity: 0;
    transform: translateX(60px);
    filter: blur(10px);
    transition: all 1.6s cubic-bezier(0.2, 0.8, 0.2, 1)
}

.active.reveal-heading,
.active.reveal-text,
.active.reveal-card,
.active.reveal-circle,
.active.reveal-left,
.active.reveal-right,
.active.reveal {
    opacity: 1;
    transform: translateY(0) scale(1) rotate(0deg) translateX(0);
    filter: blur(0)
}

.delay-1 {
    transition-delay: 100ms
}

.delay-2 {
    transition-delay: 200ms
}

.delay-3 {
    transition-delay: 300ms
}

.location-button,
.rsvp-button {
    transition: transform .3s ease, box-shadow .3s ease !important
}

.location-button:hover,
.rsvp-button:hover {
    transform: translateY(-3px) scale(1.05) !important
}

.hero-img {
    transform-origin: center center;
    will-change: transform
}

@media (max-width: 768px) {
    .timeline-track {
        min-height: auto
    }

    .timeline-item {
        width: 40%
    }

    .rsvp-card-container {
        padding: 40px 20px
    }

    .rsvp-presence-toggle {
        gap: 10px
    }

    .presence-box {
        padding: 15px 5px
    }

    .paper--top::before,
    .paper--bottom::after {
        height: 67px
    }
}

@media (max-width: 480px) {
    .invitation-heading {
        font-size: 2.5rem
    }

    .dresscode-heading,
    .timeline-heading,
    .location-heading {
        font-size: 2.5rem
    }

    .rsvp-heading {
        font-size: 2.8rem
    }
}

/* ========== VISUAL TIMELINE (ROBUST) ========== */
.timeline-section {
    padding: 60px 20px;
    background: transparent;
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline-heading {
    font-family: var(--decorative-font);
    font-size: 3rem;
    color: var(--primary-green);
    text-align: center;
    margin-bottom: 50px;
}

.timeline-track {
    position: relative;
    padding: 20px 0;
    margin-left: 0;
    padding-left: 60px;
}

/* Вертикальная линия — ровно на 25px от края */
.timeline-track::before {
    content: '';
    position: absolute;
    left: 25px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--accent-gold);
    transform: translateX(-50%) scaleY(0);
    transform-origin: top;
    transition: transform 2s cubic-bezier(0.16, 1, 0.3, 1);
}

.timeline-track.active::before {
    transform: translateX(-50%) scaleY(1);
}

.timeline-item {
    position: relative;
    margin-bottom: 50px;
    opacity: 0;
    display: flex;
    flex-direction: column;
}

/* Точка на линии — ГАРАНТИРОВАННО ПО ЦЕНТРУ */
.timeline-item::before {
    content: '';
    position: absolute;
    left: -35px;
    /* (25px - 60px padding) */
    top: 6px;
    width: 14px;
    height: 14px;
    background: #fff;
    border: 3px solid var(--accent-gold);
    border-radius: 50%;
    z-index: 2;
    transform: translateX(-50%) scale(0);
    box-shadow: 0 0 0 4px #fff;
    transition: transform 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    transition-delay: inherit;
}

.timeline-item.active::before {
    transform: translateX(-50%) scale(1);
}

.timeline-header {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
}

.timeline-time {
    font-family: var(--main-font);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent-gold);
    margin-right: 15px;
}

.timeline-title {
    font-family: var(--main-font);
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary-green);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0;
}

.timeline-desc {
    font-family: var(--main-font);
    font-size: 1rem;
    color: var(--text-muted);
    line-height: 1.5;
    font-style: italic;
    margin: 0;
}

/* Иконка (опционально рядом с заголовком) */
.timeline-icon-inline {
    width: 24px;
    height: 24px;
    margin-right: 10px;
    fill: var(--primary-green);
}