/**
 * ===========================================
 * СТИЛИ СВАДЕБНОГО ПРИГЛАШЕНИЯ
 * ===========================================
 */

/* ===== CSS ПЕРЕМЕННЫЕ ===== */
:root {
    --color-primary: #c9a86c;
    --color-secondary: #8b7355;
    --color-background: #f5f0e8;
    --color-text: #5a4a40;
    --color-accent: #e8d5c4;
    --color-white: #ffffff;
    --color-dark: #3a3a3a;
    
    --font-heading: 'Great Vibes', cursive;
    --font-body: 'Cormorant Garamond', serif;
    --font-accent: 'Montserrat', sans-serif;
    --font-hero: 'Cinzel', serif;

    
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 3rem;
    --spacing-xl: 5rem;
    
    --border-radius: 8px;
    --transition: all 0.3s ease;
}

/* ===== БАЗОВЫЕ СТИЛИ ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
    min-height: 100%;
    background-color: var(--color-background);
}

body {
    font-family: var(--font-body);
    min-height: 100%;
    background-color: transparent;
    background-image: none;
    color: var(--color-text);
    line-height: 1.7;
    overflow-x: hidden;
    font-size: 18px;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    min-height: 100%;
    background-image: url('../images/background.webp');
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
    background-attachment: initial;
    transform: translate3d(0, 0, 0);
    pointer-events: none;
    backface-visibility: hidden;
    will-change: transform;
    z-index: -1;
}

@supports (height: 100lvh) {
    body::before {
        height: 100lvh;
    }
}

@media (min-width: 1001px) {
    body {
        background-color: transparent;
        background-image: none;
    }

    body::before {
        content: '';
        position: fixed;
        top: 50%;
        left: 50%;
        width: 100vh;
        height: 100vw;
        transform: translate(-50%, -50%) rotate(90deg);
        transform-origin: center;
        background-image: url('../images/background.webp');
        background-repeat: no-repeat;
        background-position: center center;
        background-size: cover;
        pointer-events: none;
        z-index: -1;
    }
}

body.page-loading {
    overflow: hidden;
}

.page-loader {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background:
        radial-gradient(circle at top, rgba(255, 255, 255, 0.92), rgba(245, 240, 232, 0.97) 55%, rgba(232, 213, 196, 0.92)),
        var(--color-background);
    opacity: 1;
    visibility: visible;
    transition: opacity 0.45s ease, visibility 0.45s ease;
}

.page-loader--hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.page-loader__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-align: center;
}

.page-loader__spinner {
    width: 56px;
    height: 56px;
    border: 3px solid rgba(201, 168, 108, 0.24);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
}

.page-loader__label {
    margin-bottom: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 1rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--color-secondary);
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
    display: none;
}

/* ===== ТИПОГРАФИЯ ===== */
h1, h2, h3 {
    font-family: var(--font-heading);
    font-weight: 400;
    color: var(--color-secondary);
}

h1 {
    font-size: clamp(3.5rem, 10vw, 7rem);
}

h2 {
    font-size: clamp(3rem, 6vw, 4.5rem);
    line-height: 1;
    margin-bottom: 1.25rem;
}

h3 {
    font-size: clamp(1.8rem, 4vw, 3rem);
}

p {
    font-size: clamp(1.15rem, 2.5vw, 1.4rem);
    margin-bottom: var(--spacing-sm);
}

a {
    color: var(--color-secondary);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--color-secondary);
}

/* ===== КОНТЕЙНЕРЫ ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.section {
    padding: var(--spacing-xl) 0;
    position: relative;
}

.section--light {
    background-color: rgba(255, 255, 255, 0.5);
}

.section--dark {
    background-color: var(--color-accent);
}

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

/* ===== ИЗОБРАЖЕНИЯ В КОНТЕНТЕ ===== */
.welcome__image {
    display: block;
    width: min(100%, 360px);
    height: auto;
    margin: 0 auto 1.25rem;
    border-radius: 20px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);
}

.dresscode__caption {
    max-width: 420px;
    margin: -0.2rem auto 1.1rem;
    padding: 0 0.4rem;
    font-family: var(--font-accent);
    font-size: clamp(0.8rem, 2.5vw, 0.85rem);
    font-weight: 400;
    line-height: 1.5;
    letter-spacing: 0.04em;
    text-transform: lowercase;
    color: rgba(90, 74, 64, 0.5);
}

.welcome__title-wrap {
    display: flex;
    width: max-content;
    flex-direction: column;
    align-items: flex-end;
    width: max-content;
    max-width: 100%;
    margin: 3rem auto 0;
}

.welcome__title {
    margin-bottom: 0;
    line-height: 1;
    font-size: clamp(3.5rem, 6vw, 4.5rem);
}

.welcome__title-note {
    margin: 0 0 0.18rem;
    font-family: var(--font-heading);
    font-size: clamp(2rem, 3vw, 2rem);
    line-height: 0.9;
    letter-spacing: 0;
    text-transform: lowercase;
    text-align: right;
    color: var(--color-secondary);
    opacity: 0.8;
}

.welcome__message {
    max-width: 700px;
    margin: 2rem auto 2rem;
    font-size: 1.25rem;
}

.welcome-date-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    width: fit-content;
    margin: 0 auto 0;
    color: rgba(90, 74, 64, 0.78);
}

.welcome-date-block__stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 130px;
}

.welcome-date-block__number {
    display: block;
    font-family: var(--font-accent);
    font-size: clamp(2.5rem, 6vw, 3rem);
    font-weight: 300;
    line-height: 0.92;
}

.welcome-date-block__divider {
    display: block;
    width: 78px;
    height: 1px;
    margin: 0.2rem 0 0.28rem;
    background: rgba(90, 74, 64, 0.38);
}

.welcome-date-block__time {
    margin: 1rem 0 0;
    font-family: var(--font-heading);
    font-size: clamp(2.3rem, 3.6vw, 3rem);
    line-height: 1;
    color: rgba(90, 74, 64, 0.72);
}

/* ===== ГЛАВНЫЙ ЭКРАН (HERO) ===== */
.hero {
    min-height: 100vh;
    min-height: 100svh;
    padding: 0;
    position: relative;
    overflow: hidden;
}

.hero__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(245, 240, 232, 0.3) 0%,
        rgba(255, 255, 255, 0.25) 55%,
        rgba(255, 255, 255, 0.5) 100%
    );
}

.hero__content {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-rows: auto 1fr auto;
    justify-items: center;
    min-height: 100vh;
    min-height: 100svh;
    width: 100%;
    max-width: 100%;
    text-align: center;
    padding: clamp(1.2rem, 3vh, 2rem) var(--spacing-md) var(--spacing-md);
}

.hero__subtitle {
    font-family: var(--font-hero);
    font-size: clamp(1.3rem, 1.5vw, 1.45rem);
    font-weight: 400;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: rgba(87, 74, 65, 1);
    margin-bottom: 0;
    margin-top: 2.5rem;
    width: fit-content;
    max-width: 100%;
    margin-inline: auto;
}

.hero__main {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: fit-content;
    max-width: 100%;
    margin-inline: auto;
}

.hero__title {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    padding-top: 2.5rem;
    width: fit-content;
    max-width: 100%;
    font-family: var(--font-heading);
    font-size: clamp(6rem, 8vw, 7rem);
    font-weight: 400;
    line-height: 0.92;
    letter-spacing: 0.08em;
    color: rgba(77, 65, 58, 0.9);
    text-shadow: none;
}

.hero__name {
    display: block;
}

.hero__ampersand {
    display: block;
    font-size: 0.9em;
    font-family: var(--font-hero);
    line-height: 0.68;
    letter-spacing: 0.1em;
    margin: 3px 0 17px;
    color: rgba(132, 114, 100, 0.66);
}

.hero__bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-self: center;
    gap: 1rem;
    width: fit-content;
    max-width: 100%;
    margin-inline: auto;
    padding-bottom: 0.75rem;
}

.hero__date {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.15rem;
    width: fit-content;
    margin-inline: auto;
    margin-bottom: 1rem;
    color: rgba(79, 67, 59, 0.9);
}

.hero__date-month,
.hero__date-year {
    font-family: var(--font-hero);
    font-size: clamp(1.3rem, 1.8vw, 1.6rem);
    font-weight: 500;
    letter-spacing: 0.22em;
    text-transform: uppercase;
}

.hero__date-day {
    font-family: var(--font-hero);
    font-size: clamp(3rem, 7vw, 4.6rem);
    font-weight: 500;
    line-height: 0.95;
    letter-spacing: 0.08em;
}

.hero__scroll {
    display: flex;
    justify-content: center;
    align-items: center;
    width: fit-content;
    margin-inline: auto;
    margin-bottom: 0rem;
    transition: opacity 2s ease, visibility 2s ease;
}

.hero__scroll--hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    animation: none !important;
}

.hero__scroll-icon {
    width: 26px;
    height: 22px;
    display: block;
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='26' height='22' viewBox='0 0 26 22' fill='none'%3E%3Cpath d='M5 4.5L13 12.5L21 4.5' stroke='%23574A41' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3Cpath d='M5 11.5L13 19.5L21 11.5' stroke='%23574A41' stroke-opacity='0.9' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

.page-ready .hero__subtitle {
    animation: fadeInUp 1s ease 0.3s both;
}

.page-ready .hero__title {
    animation: fadeInUp 1s ease 0.5s both;
}

.page-ready .hero__date {
    animation: fadeInUp 1s ease 0.9s both;
}

.page-ready .hero__scroll {
    animation: bounce 2s infinite;
}

/* ===== ДЕКОРАТИВНЫЕ ЭЛЕМЕНТЫ ===== */
.decor {
    position: absolute;
    pointer-events: none;
    z-index: 1;
}

.decor--top-left {
    top: -50px;
    left: -50px;
    transform: rotate(-30deg);
}

.decor--top-right {
    top: -50px;
    right: -50px;
    transform: rotate(30deg) scaleX(-1);
}

.decor--bottom-left {
    bottom: -50px;
    left: -50px;
    transform: rotate(30deg);
}

.decor--bottom-right {
    bottom: -50px;
    right: -50px;
    transform: rotate(-30deg) scaleX(-1);
}

.decor img {
    width: 200px;
    height: auto;
    opacity: 0.6;
}

/* ===== ТАЙМЕР ОБРАТНОГО ОТСЧЁТА ===== */
.countdown {
    background: transparent;
}

.countdown__title {
    margin-bottom: var(--spacing-md);
}

.countdown__timer {
    display: flex;
    justify-content: center;
    gap: var(--spacing-md);
    flex-wrap: wrap;
}

.countdown__item {
    text-align: center;
    min-width: 100px;
}

.countdown__number {
    font-family: var(--font-heading);
    font-size: clamp(3rem, 8vw, 5rem);
    color: var(--color-primary);
    line-height: 1;
}

.countdown__label {
    font-family: var(--font-accent);
    font-size: 0.9rem;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--color-secondary);
}

/* ===== TIMELINE ===== */
.timeline {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
    padding: var(--spacing-sm) 0;
    list-style: none;
}

.timeline__item {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    align-items: start;
    column-gap: 1rem;
    margin-bottom: 1rem;
    position: relative;
}

.timeline__item:last-child {
    margin-bottom: 0;
}

.timeline__item::before {
    content: '';
    position: absolute;
    left: 31px;
    top: 10px;
    bottom: -1rem;
    width: 2px;
    background: linear-gradient(to bottom, rgba(201, 168, 108, 0.55), rgba(201, 168, 108, 0.12));
}

.timeline__item:last-child::before {
    display: none;
}

.timeline__marker {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.timeline__icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-accent);
    font-size: 1.4rem;
    font-weight: 500;
    line-height: 1;
    color: var(--color-secondary);
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(201, 168, 108, 0.35);
    box-shadow: 0 8px 20px rgba(139, 115, 85, 0.08);
}

.timeline__content {
    width: 100%;
    padding: 1rem 1.15rem;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(201, 168, 108, 0.18);
    border-radius: 18px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
    text-align: left;
}

.timeline__header {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-bottom: 0.45rem;
    flex-wrap: wrap;
}

.timeline__time {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.75rem;
    border-radius: 999px;
    background: rgba(201, 168, 108, 0.14);
    font-family: var(--font-accent);
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: var(--color-secondary);
}

.timeline__title {
    font-family: var(--font-body);
    font-size: 1.55rem;
    font-weight: 600;
    color: var(--color-secondary);
    margin-bottom: 0;
}

.timeline__desc {
    font-size: 1.25rem;
    color: var(--color-text);
    opacity: 0.85;
    margin-bottom: 0;
}

/* ===== МЕСТО ПРОВЕДЕНИЯ ===== */
.venue-section {
    padding-top: var(--spacing-xl);
    padding-bottom: var(--spacing-xl);
}

.venue-section .container {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.venue__card {
    display: grid;
    grid-template-columns: minmax(320px, 1.05fr) minmax(300px, 0.95fr);
    gap: var(--spacing-lg);
    align-items: stretch;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(201, 168, 108, 0.18);
    border-radius: 24px;
    padding: 1.1rem;
    overflow: hidden;
    background-clip: padding-box;
    transform: translateZ(0);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
}

.venue__media {
    min-width: 0;
}

.venue__image {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 360px;
    border-radius: 18px;
    object-fit: cover;
}

.venue__info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding: 1.1rem 1.25rem;
}

.venue__title-group {
    margin-bottom: 1rem;
}

.venue__place {
    font-family: var(--font-body);
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 600;
    line-height: 1.05;
    color: var(--color-primary);
    margin-bottom: 0.25rem;
}

.venue__hall {
    font-family: var(--font-body);
    font-size: clamp(1.05rem, 2vw, 1.35rem);
    font-weight: 500;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--color-secondary);
    margin-bottom: 0;
}

.venue__address {
    font-size: 1.25rem;
    line-height: 1.6;
    color: var(--color-text);
    margin-bottom: 0.85rem;
}

.venue__note {
    font-size: 1.25rem;
    color: var(--color-text);
    opacity: 0.82;
    margin-bottom: 1.2rem;
}

.venue__map-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: center;
    margin-inline: auto;
    padding: 0.95rem 1.4rem;
    background: var(--color-primary);
    color: var(--color-white);
    border: none;
    border-radius: 999px;
    font-family: var(--font-accent);
    font-size: 0.92rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1.4px;
    transition: var(--transition);
    cursor: pointer;
}

.venue__map-btn:hover {
    background: var(--color-secondary);
    color: var(--color-white);
    transform: translateY(-2px);
}

.map-modal {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    z-index: 30;
}

.map-modal.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.map-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(58, 58, 58, 0.52);
    backdrop-filter: blur(4px);
}

.map-modal__dialog {
    position: relative;
    width: min(1020px, 100%);
    max-height: min(90vh, 900px);
    overflow: auto;
    background: rgba(255, 255, 255, 0.97);
    border-radius: 26px;
    box-shadow: 0 28px 90px rgba(0, 0, 0, 0.18);
}

.map-modal__close {
    position: absolute;
    top: 0.85rem;
    right: 0.85rem;
    width: 42px;
    height: 42px;
    border: none;
    border-radius: 50%;
    background: rgba(245, 240, 232, 0.92);
    color: var(--color-secondary);
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    z-index: 1;
}

.map-modal__content {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
    gap: 1.25rem;
    padding: 1.25rem;
}

.map-modal__image {
    display: block;
    width: 100%;
    height: auto;
    max-height: min(72vh, 640px);
    border-radius: 20px;
    object-fit: contain;
    background: rgba(245, 240, 232, 0.9);
}

.map-modal__info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.map-modal__title {
    font-family: var(--font-body);
    font-size: clamp(1.9rem, 3vw, 2.5rem);
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 0.75rem;
}

.map-modal__text {
    font-size: 1.05rem;
    color: var(--color-text);
    margin-bottom: 1.2rem;
}

.map-modal__actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: nowrap;
}

.map-modal__link {
    display: flex;
    flex: 1 1 0;
    justify-content: center;
    align-items: center;
    min-height: 48px;
    padding: 0.85rem 1.1rem;
    border-radius: 999px;
    background: rgba(201, 168, 108, 0.14);
    border: 1px solid rgba(201, 168, 108, 0.3);
    color: var(--color-secondary);
    font-family: var(--font-accent);
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.6px;
    text-align: center;
}

.map-modal__link:hover {
    background: var(--color-primary);
    color: var(--color-white);
}

body.modal-open {
    overflow: hidden;
}

/* ===== ДРЕСС-КОД ===== */
.dress-code__content {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.dress-code__style {
    font-family: var(--font-heading);
    font-size: 3rem;
    color: var(--color-primary);
    margin-bottom: var(--spacing-sm);
}

.dress-code__colors {
    display: flex;
    justify-content: center;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-md);
}

.dress-code__color {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 3px solid var(--color-white);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* ===== ПОДАРКИ ===== */
.gifts__content {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.gifts__icon {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--spacing-md);
}

/* ===== ФОРМА ===== */
.form-section {
    background: linear-gradient(135deg, var(--color-white) 0%, var(--color-background) 100%);
}

.form-container {
    max-width: 600px;
    margin: 0 auto;
    background: var(--color-background);
    padding: var(--spacing-lg);
    border-radius: var(--border-radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
}

.form__deadline {
    display: flex;
    justify-content: center;
    align-items: baseline;
    gap: 0.25rem;
    width: fit-content;
    max-width: 100%;
    font-family: var(--font-body);
    font-size: clamp(0.9rem, 3vw, 1.5rem);
    font-style: italic;
    color: var(--color-secondary);
    text-align: center;
    margin: 1rem auto var(--spacing-md);
    opacity: 0.82;
}

/* ===== ФУТЕР ===== */
.footer {
    background: var(--color-secondary);
    color: var(--color-white);
    padding: 1rem 0;
    text-align: center;
}

.footer__text {
    font-family: var(--font-heading);
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    margin-bottom: 0.25rem;
}

.footer__names {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 3vw, 3rem);
    color: var(--color-accent);
    margin-bottom: 0;
    line-height: 1;
}

/* ===== АНИМАЦИИ ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

@keyframes scroll-down {
    0% {
        opacity: 1;
        top: 8px;
    }
    100% {
        opacity: 0;
        top: 25px;
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

/* ===== Анимации при скролле ===== */
.animate-on-scroll {
    opacity: 0;
    transform: translate3d(0, 24px, 0);
    transition: opacity 0.55s ease, transform 0.55s ease;
    will-change: opacity, transform;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translate3d(0, 0, 0);
    will-change: auto;
}

.welcome__image.animate-on-scroll,
.venue__card.animate-on-scroll,
.form-container.animate-on-scroll,
#wedding-form-root {
    transform: translateZ(0);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    will-change: transform, opacity;
}

.welcome__image.animate-on-scroll,
.venue__card.animate-on-scroll,
.form-container.animate-on-scroll {
    contain: paint;
}

/* ===== АДАПТИВНОСТЬ ===== */
@media (max-width: 992px) {
    .venue__card {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .venue__image {
        min-height: 260px;
    }

    .venue__info {
        padding: 0.5rem 0.35rem 0.35rem;
    }

    .map-modal__content {
        grid-template-columns: 1fr;
    }

    .map-modal__image {
        min-height: 260px;
    }
}

@media (max-width: 768px) {
    :root {
        --spacing-xl: 3rem;
        --spacing-lg: 2rem;
    }

    .map-modal__close {
        position: absolute;
        top: 0.85rem;
        left: 0.85rem;
    }
    
    .countdown__item {
        min-width: 70px;
    }
    
    .countdown__number {
        font-size: 2.5rem;
    }
    
    .decor img {
        width: 100px;
    }

    .timeline {
        max-width: 100%;
    }

    .timeline__item {
        grid-template-columns: 56px minmax(0, 1fr);
        column-gap: 0.85rem;
    }

    .timeline__item::before {
        left: 27px;
    }

    .timeline__icon {
        width: 44px;
        height: 44px;
        font-size: 1.25rem;
    }

    .timeline__content {
        padding: 0.9rem 1rem;
        border-radius: 16px;
    }

    .timeline__title {
        font-size: 1.35rem;
    }

    .timeline__desc {
        font-size: 1.1rem;
    }

    .venue-section .container {
        gap: 1.25rem;
    }

    .venue__card {
        padding: 0.8rem;
        border-radius: 20px;
    }

    .venue__image {
        min-height: 220px;
        border-radius: 16px;
    }

    .venue__place {
        font-size: 1.7rem;
    }

    .venue__hall {
        font-size: 1rem;
    }

    .venue__address,
    .venue__note {
        font-size: 1.1rem;
    }

    .venue__map-btn {
        width: min(100%, 320px);
    }

    .map-modal {
        padding: 0.9rem;
    }

    .map-modal__dialog {
        border-radius: 20px;
    }

    .map-modal__content {
        padding: 0.9rem;
        gap: 1rem;
    }

    .map-modal__image {
        min-height: 220px;
        border-radius: 16px;
    }

    .map-modal__actions {
        flex-direction: column;
    }

    .map-modal__link {
        width: 100%;
    }

    .welcome__image {
        width: min(100%, 300px);
        border-radius: 16px;
    }

    .welcome__title-note {
        margin-top: 0;
        margin-bottom: 0.15rem;
        font-size: clamp(1.8rem, 5vw, 1.6rem);
        letter-spacing: 0;
    }

    .welcome-date-block {
        gap: 0.7rem;
        margin-top: 1.1rem;
    }

    .welcome-date-block__stack {
        min-width: 96px;
    }

    .welcome-date-block__divider {
        width: 58px;
        margin: 0.14rem 0 0.2rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 var(--spacing-sm);
    }
    
    .hero__content {
        padding: 1rem var(--spacing-sm) 1rem;
    }

    .hero__title {
        font-size: clamp(5.5rem, 13vw, 6rem);
        letter-spacing: 0.06em;
    }

    .hero__subtitle {
        letter-spacing: 0.18em;
        font-size: 1.1rem;
        margin-top: 2.5rem;
    }

    .hero__bottom {
        gap: 0.7rem;
        padding-bottom: 0.4rem;
    }

    .hero__date-month,
    .hero__date-year {
        font-size: 1.3rem;
        letter-spacing: 0.18em;
    }

    .hero__date-day {
        font-size: clamp(4rem, 12vw, 5rem);
    }
    
    .countdown__timer {
        gap: var(--spacing-sm);
    }
    
    .countdown__item {
        min-width: 60px;
    }
    
    .form-container {
        padding: var(--spacing-md);
    }
}

/* ===== ЧАСТИЦЫ (опционально) ===== */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 0;
}

.particle {
    position: absolute;
    width: 8px;
    height: 8px;
    background: radial-gradient(circle, rgba(201, 168, 108, 0.6) 0%, transparent 70%);
    border-radius: 50%;
    animation: particle-float 5s infinite ease-in-out;
    animation-fill-mode: backwards;
}

@keyframes particle-float {
    0% {
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.8;
    }
    90% {
        opacity: 0.8;
    }
    100% {
        transform: translateY(-100px) rotate(720deg);
        opacity: 0;
    }
}
