/* =====================================================================
 *  Wedding invitation — главный стиль.
 *
 *  Структура:
 *    1. Reset / base
 *    2. Design tokens (цвета, шрифты, spacing)
 *    3. Утилиты и типографика
 *    4. Контейнер и сетка секций
 *    5. Кнопки
 *    6. Форма (input, radio, checkbox)
 *    7. Секции (по порядку страницы)
 *    8. Модалка и «Спасибо»
 *    9. Слайдер (slick)
 *   10. Прелоадер
 * ===================================================================== */


/* -------------------------------------------------------------------- *
 * 1. Reset                                                              *
 * -------------------------------------------------------------------- */

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

html, body { margin: 0; padding: 0; overflow-x: clip; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--font-sans);
    color: var(--clr-text);
    background: var(--clr-bg);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-width: 320px;
}

img, picture, svg { display: block; max-width: 100%; height: auto; }
h1, h2, h3, h4, h5, h6, p { margin: 0; }
button { background: none; border: 0; padding: 0; cursor: pointer; font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
input, textarea, select { font: inherit; color: inherit; }

[hidden] { display: none !important; }


/* -------------------------------------------------------------------- *
 * 2. Design tokens                                                      *
 * -------------------------------------------------------------------- */

:root {
    /* Палитра */
    --clr-text:          #2a2a2a;
    --clr-text-muted:    #6b6b6b;
    --clr-text-soft:     rgba(42, 42, 42, 0.55);
    --clr-bg:            #f7f4ef;
    --clr-surface:       #ffffff;
    --clr-line:          #cbc3b6;
    --clr-accent:        #5f6a57;
    --clr-accent-soft:   #a3b9ad;
    --clr-beige-1:       #dcccc1;
    --clr-beige-2:       #d5d9dc;
    --clr-sage:          #a3b9ad;
    --clr-sage-dark:     #557257;

    /* Типографика */
    --font-sans:    "SMTextsFont", "Gilroy", "Manrope", system-ui, sans-serif;
    --font-serif:   "SMHeadersFont", "Cormorant Garamond", "Times New Roman", serif;
    --font-script:  "kudry", "Brush Script MT", cursive;
    --font-hand:    "Kids", "Comic Sans MS", cursive;
    --font-inter:   "Inter", var(--font-sans);

    /* Размеры */
    --container-max: 1200px;
    --container-pad: clamp(16px, 4vw, 32px);

    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-xl: 40px;

    /* Шкала отступов */
    --sp-1:  4px;
    --sp-2:  8px;
    --sp-3: 12px;
    --sp-4: 16px;
    --sp-5: 24px;
    --sp-6: 32px;
    --sp-7: 48px;
    --sp-8: 64px;
    --sp-9: 96px;

    /* Вертикальный ритм секций (адаптивный) */
    --section-pad-y: clamp(40px, 8vw, 96px);
    --section-gap:   clamp(24px, 4vw, 40px);
}


/* -------------------------------------------------------------------- *
 * 3. Утилиты / типографика                                              *
 * -------------------------------------------------------------------- */

.sm-line {
    width: 1px;
    height: 64px;
    background: var(--clr-line);
    margin: 0 auto;
}

.mob { display: none; }
@media (max-width: 768px) { .mob { display: block; } }

/* Старые utility-классы приводим к общему размеру через clamp,
   чтобы имена в разметке оставались, но сами размеры были адаптивны. */

.sm-cormorantRegular-100-50,
.sm-cormorantRegular-100-30 {
    font-family: var(--font-serif);
    font-weight: 400;
    font-size: clamp(40px, 8vw, 96px);
    line-height: 1.1;
    color: var(--clr-text);
    text-align: center;
}

.sm-cormorantRegular-70-30,
.sm-cormorantRegular-70-40 {
    font-family: var(--font-serif);
    font-weight: 400;
    font-size: clamp(32px, 5vw, 64px);
    line-height: 1.15;
    color: var(--clr-text);
    text-align: center;
}

.sm-cormorantRegular-50,
.sm-cormorantRegular-50-30 {
    font-family: var(--font-serif);
    font-weight: 400;
    font-size: clamp(24px, 3vw, 40px);
    line-height: 1.2;
    color: var(--clr-text);
}

.sm-cormorantLight-70-30 {
    font-family: var(--font-serif);
    font-weight: 300;
    font-size: clamp(18px, 2vw, 28px);
    color: var(--clr-text);
}

.sm-cormorantLight-40-30 {
    font-family: var(--font-serif);
    font-weight: 300;
    font-size: clamp(20px, 2.4vw, 32px);
    color: var(--clr-text);
}

.sm-cormorantLight-30-20px {
    font-family: var(--font-sans);
    font-weight: 300;
    font-size: clamp(14px, 1.6vw, 20px);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--clr-text-muted);
}

.sm-manropeLight-20,
.sm-manropeLight-20-18 {
    font-family: var(--font-sans);
    font-weight: 300;
    font-size: clamp(15px, 1.4vw, 18px);
    line-height: 1.55;
    color: var(--clr-text);
}

.sm-manropeRegular-20-18 {
    font-family: var(--font-sans);
    font-weight: 400;
    font-size: clamp(15px, 1.4vw, 18px);
    line-height: 1.55;
    color: var(--clr-text);
}

.sm-manropeBold-20-18 {
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: clamp(15px, 1.4vw, 18px);
    line-height: 1.55;
    color: var(--clr-text);
}

.sm-manropeMedium-50px-20,
.sm-manropeMedium-30px-20 {
    font-family: var(--font-sans);
    font-weight: 500;
    font-size: clamp(16px, 2vw, 24px);
}

.sm-manropeSemiBold-20 {
    font-family: var(--font-sans);
    font-weight: 500;
    font-size: clamp(14px, 1.6vw, 18px);
    color: var(--clr-text);
}

.sm-main_save {
    font-family: var(--font-sans);
    font-weight: 300;
    font-size: clamp(14px, 1.4vw, 18px);
    letter-spacing: 0.3em;
    text-transform: uppercase;
    text-align: center;
    color: var(--clr-text);
}

/* Цветные хелперы */
.color-1 { color: var(--clr-accent); }
.color-2 { color: var(--clr-text); }

.bold { font-weight: 500; }


/* -------------------------------------------------------------------- *
 * 4. Контейнер и базовая сетка секций                                   *
 * -------------------------------------------------------------------- */

.sm-container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding-inline: var(--container-pad);
    position: relative;
    z-index: 1;
}

main > section {
    position: relative;
    padding-block: var(--section-pad-y);
}
/* По умолчанию: внутри контейнера каждой секции контент центрирован
   по горизонтали flex-колонкой с одинаковым вертикальным ритмом. */
main > section:not(.sm-main):not(.sm-location):not(.sm-bg-image) > .sm-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--section-gap);
    text-align: center;
}
main > section h2 {
    margin: 0;
    text-align: center;
}

/* Декоративная фоновая плашка (исходный .sm-background-photo) */
.sm-background-photo,
.sm-background-photo__bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background: transparent;
}

.sm-bg_img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    pointer-events: none;
}


/* -------------------------------------------------------------------- *
 * 5. Кнопки                                                             *
 * -------------------------------------------------------------------- */

.sm-btn {
    --btn-bg: var(--clr-surface);
    --btn-fg: var(--clr-text);
    --btn-border: var(--clr-text);

    font-family: var(--font-serif);
    font-size: clamp(14px, 1.2vw, 18px);
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    text-align: center;

    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 120px;
    height: 120px;
    padding: 16px 24px;
    border: 1px solid var(--btn-border);
    border-radius: 999px;
    background: var(--btn-bg);
    color: var(--btn-fg);
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.1s ease;
}
.sm-btn:hover {
    background: var(--btn-fg);
    color: var(--btn-bg);
}
.sm-btn:active { transform: scale(0.98); }

.sm-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 20px;
    background: var(--clr-accent);
    color: #fff;
    font-family: var(--font-sans);
    font-weight: 500;
    font-size: 14px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    width: 100%;
    height: 56px;
    cursor: pointer;
}
.sm-button:hover { background: var(--clr-sage-dark); }

/* Пульсирующая кнопка — простая анимация для главного CTA */
@keyframes wedding-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(95, 106, 87, 0.35); }
    70%  { box-shadow: 0 0 0 14px rgba(95, 106, 87, 0); }
    100% { box-shadow: 0 0 0 0 rgba(95, 106, 87, 0); }
}
.pulse-button,
.pulse-button-center50,
.pulse-button-center-50-mob {
    animation: wedding-pulse 2.2s infinite;
}


/* -------------------------------------------------------------------- *
 * 6. Форма                                                              *
 * -------------------------------------------------------------------- */

.sm-form {
    display: flex;
    flex-direction: column;
    gap: var(--sp-6);
    width: 100%;
}

.sm-form__wrapper {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: var(--sp-7);
}
@media (max-width: 1024px) {
    .sm-form__wrapper { grid-template-columns: 1fr; gap: var(--sp-6); }
}

.sm-form__left,
.sm-form__block {
    display: flex;
    flex-direction: column;
    gap: var(--sp-4);
}

.sm-form__left { gap: var(--sp-6); }

.sm-form__input {
    width: 100%;
    padding: 14px 18px;
    font-family: var(--font-sans);
    font-size: 16px;
    color: var(--clr-text);
    background: #fff;
    border: 1px solid var(--clr-line);
    border-radius: var(--radius-md);
    outline: none;
    transition: border-color 0.15s ease;
}
.sm-form__input::placeholder { color: var(--clr-text-soft); }
.sm-form__input:focus { border-color: var(--clr-accent); }

.sm-form__item {
    display: flex;
    flex-direction: column;
    gap: var(--sp-3);
}
.sm-form__item-radio {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-3);
    cursor: pointer;
}

.radio-input {
    width: 18px; height: 18px;
    accent-color: var(--clr-accent);
    cursor: pointer;
}

.sm-form__drinks { display: flex; flex-direction: column; gap: var(--sp-3); }

.sm-form__drinks-check {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: var(--sp-5);
    row-gap: var(--sp-3);
}
@media (max-width: 480px) {
    .sm-form__drinks-check { grid-template-columns: 1fr; row-gap: var(--sp-3); }
}

/* Custom checkbox на чистом CSS — без SVG-масок */
.sm-form_checkbox {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-3);
    cursor: pointer;
    user-select: none;
    position: relative;
}

.sm-form_checkbox_input {
    position: absolute;
    opacity: 0;
    width: 0; height: 0;
    pointer-events: none;
}

.sm-form_checkbox_box {
    flex: 0 0 22px;
    width: 22px; height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--clr-text);
    border-radius: 5px;
    background: transparent;
    transition: background-color 0.15s ease, border-color 0.15s ease;
}
.sm-form_checkbox_box::after {
    content: "";
    display: block;
    width: 6px; height: 10px;
    margin-top: -2px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg) scale(0);
    opacity: 0;
    transition: transform 0.15s ease, opacity 0.15s ease;
}
.sm-form_checkbox_input:checked + .sm-form_checkbox_box {
    background: var(--clr-accent);
    border-color: var(--clr-accent);
}
.sm-form_checkbox_input:checked + .sm-form_checkbox_box::after {
    opacity: 1;
    transform: rotate(45deg) scale(1);
}
.sm-form_checkbox_input:focus-visible + .sm-form_checkbox_box {
    outline: 2px solid var(--clr-accent);
    outline-offset: 2px;
}
.sm-form_checkbox_label {
    font-family: var(--font-sans);
    font-size: 16px;
    color: var(--clr-text);
}


/* -------------------------------------------------------------------- *
 * 7. Секции                                                             *
 * -------------------------------------------------------------------- */

/* 7.1 Hero (sm-main) ------------------------------------------------- */

.sm-main {
    position: relative;
    min-height: 80vh;
    padding-block: var(--sp-7) 0;
    overflow: hidden;
}
.sm-main .sm-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--sp-7);
    align-items: center;
}
@media (max-width: 1024px) {
    .sm-main .sm-container { grid-template-columns: 1fr; }
}

.sm-main__img {
    position: relative;
    height: clamp(360px, 45vw, 520px);
}
.sm-main__img__wrapper {
    position: absolute;
    background: #fff;
    padding: 20px 16px 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08), 0 40px 60px rgba(0, 0, 0, 0.04);
}
.sm-main__img__wrapper:first-child {
    top: 10%; left: 0; transform: rotate(-10deg);
}
.sm-main__img__wrapper:last-child {
    top: 40%; right: 0; transform: rotate(10deg);
}
.sm-main__img__wrapper > img {
    width: clamp(180px, 22vw, 280px);
    aspect-ratio: 1 / 1;
    object-fit: cover;
}
.sm-main__img__text {
    margin-top: 10px;
    font-family: var(--font-hand);
    font-size: 20px;
    text-align: center;
}
.sm-main__img__text img { max-width: 80%; margin: 0 auto; height: auto; }

.sm-main__content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-5);
    padding-block: var(--sp-7);
}

.sm-main__content-date {
    font-family: var(--font-script);
    font-weight: 300;
    font-size: clamp(36px, 6vw, 72px);
    line-height: 1;
    text-align: center;
    color: var(--clr-text-soft);
    display: flex;
    gap: var(--sp-3);
    align-items: baseline;
    justify-content: center;
}
.sm-main__content-date span { display: inline-block; }

.sm-main__content-titel {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: clamp(4px, 0.8vw, 16px);
    text-align: center;
    text-transform: uppercase;
    font-family: var(--font-serif);
    font-weight: 500;
    font-size: clamp(48px, 11vw, 140px);
    line-height: 1;
    letter-spacing: 0.02em;
    color: var(--clr-text);
    width: 100%;
}
.sm-main__content-titel p {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(8px, 1.5vw, 24px);
    flex-wrap: wrap;
    margin: 0;
    width: 100%;
}
.sm-main__content-titel span {
    font: inherit;
    color: inherit;
    display: inline-block;
}
.sm-main__content-titel .sm-cormorantRegular-100-50 {
    font-size: inherit;
    line-height: inherit;
}
.sm-main__content-titel .sm-cormorantRegular-70-30 {
    font-size: 0.35em;
    font-weight: 400;
    opacity: 0.55;
    letter-spacing: 0;
    text-transform: lowercase;
}
.sm-main__content-titel svg {
    flex-shrink: 0;
    width: clamp(24px, 3vw, 48px);
    height: auto;
}
.sm-main__content-titel path { fill: var(--clr-accent-soft); }
.sm-main__content-titel br { display: none; }
@media (max-width: 768px) {
    .sm-main__content-titel br.mob { display: block; }
}

/* 7.2 Moment --------------------------------------------------------- */

.sm-moment__wrapper-decr {
    display: flex;
    flex-direction: column;
    gap: var(--sp-4);
    max-width: 620px;
}
.sm-moment__wrapper-decr_text { line-height: 1.55; }
.sm-moment__wrapper-img {
    max-width: 420px;
    border-radius: var(--radius-lg);
    overflow: hidden;
}
.sm-moment__wrapper-img img { width: 100%; height: auto; object-fit: contain; }
.sm-moment__wrapper-img path { fill: var(--clr-text); }

/* 7.3 Date / Calendar ------------------------------------------------ */

.sm-date {
    overflow: hidden;
}
.sm-date .sm-bg_img { opacity: 0.35; }
.sm-date__content {
    position: relative;
    background: var(--clr-surface);
    border-radius: var(--radius-xl) 0 var(--radius-xl) 0;
    padding: clamp(24px, 4vw, 56px);
    max-width: 520px;
    margin: 0 auto;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: var(--sp-5);
}
.sm-date__calendar__wrapper { margin: 0 auto; }
.sm-date__calendar-top {
    display: flex;
    justify-content: center;
    padding-bottom: var(--sp-4);
}
.sm-date__calendar-item {
    font-family: var(--font-serif);
    font-size: clamp(28px, 4vw, 40px);
}
.sm-date__calendar-bottom {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: var(--sp-3);
    justify-items: center;
}
.sm-date__calendar-bottom > span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: clamp(28px, 5vw, 38px);
    height: clamp(28px, 5vw, 38px);
    font-variant-numeric: tabular-nums;
}
.number-acrive {
    background: var(--clr-accent);
    color: #fff !important;
    border-radius: 50%;
    font-weight: 600;
}
.sm-date__text { color: var(--clr-text-muted); }
.sm-date__date {
    display: flex;
    justify-content: center;
    align-items: baseline;
    gap: var(--sp-2);
    font-family: var(--font-sans);
    font-size: clamp(20px, 2.4vw, 28px);
}

/* 7.4 Location ------------------------------------------------------- */

.sm-location .sm-container { max-width: 1120px; }
.sm-location__content {
    display: block;
}
.sm-location__content__wrepper,
.sm-location__content__wrapper {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(24px, 5vw, 64px);
    align-items: center;
}
@media (max-width: 1024px) {
    .sm-location__content__wrepper,
    .sm-location__content__wrapper {
        grid-template-columns: 1fr;
        gap: var(--sp-6);
        text-align: center;
    }
}
.sm-location__content-collecting {
    display: flex;
    flex-direction: column;
    gap: var(--sp-5);
    align-items: stretch;
}
.sm-location__content-collecting > div {
    display: flex;
    flex-direction: column;
    gap: var(--sp-3);
}
.sm-location__content-collecting > div:last-child {
    align-items: flex-start;
    padding-top: var(--sp-2);
}
.sm-location__content-collecting h2 {
    text-align: left;
    margin: 0;
}
@media (max-width: 1024px) {
    .sm-location__content-collecting h2 { text-align: center; }
    .sm-location__content-collecting > div:last-child { align-items: center; }
}
.sm-location__content__subtitle {
    font-family: var(--font-serif);
    font-size: clamp(22px, 3vw, 36px);
}
.sm-location__content-description_text { color: var(--clr-text-muted); }
.sm-location__content-collecting_wrap {
    display: inline-flex;
    align-items: center;
    gap: var(--sp-2);
    font-family: var(--font-inter);
    font-style: italic;
    color: var(--clr-text);
    padding-top: var(--sp-2);
}
.sm-location__content-collecting_wrap p { margin: 0; }
@media (max-width: 1024px) {
    .sm-location__content-collecting_wrap { justify-content: center; }
}
.sm-location__content-picture {
    aspect-ratio: 3 / 4;
    max-height: 560px;
    width: 100%;
    border-radius: var(--radius-lg);
    overflow: hidden;
    justify-self: center;
}
.sm-location__content-picture_img {
    width: 100%; height: 100%; object-fit: cover;
}
.sm-location .sm-btn {
    min-width: 140px;
    height: 140px;
}

/* 7.5 Timing --------------------------------------------------------- */

.sm-timing__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-3);
}
.sm-timing__item__img svg {
    width: clamp(60px, 6vw, 100px);
    height: auto;
}
.sm-timing__item__img path { fill: var(--clr-text); }
.sm-timing__item__text {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    font-family: var(--font-sans);
    font-size: clamp(18px, 2vw, 24px);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.sm-timing__item__text p:first-child { font-weight: 600; }
.sm-timing__item__text span {
    width: 5px; height: 5px; border-radius: 50%;
    background: var(--clr-text);
}

/* 7.6 Dress code ----------------------------------------------------- */

.sm-dress-code_wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-6);
}
.sm-dress-code_wrap-top {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-4);
}
.sm-dress-code_wrap-top_line { width: 180px; border-top: 1px solid var(--clr-text); }
.sm-dress-code_wrap-top_text { max-width: 620px; text-align: center; }
.sm-dress-code_wrap-bottom {
    display: flex;
    gap: var(--sp-3);
    flex-wrap: wrap;
    justify-content: center;
}
.sm-dress-code_wrap-bottom > div {
    width: clamp(60px, 12vw, 110px);
    aspect-ratio: 1;
    position: relative;
    border: 1px solid var(--clr-text);
}
.sm-dress-code_wrap-bottom > div > div {
    position: absolute;
    inset: 4px;
}

/* 7.7 Timer ---------------------------------------------------------- */

.sm-timer { padding-block: var(--section-pad-y); }
.sm-timer__container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-5);
    padding: clamp(24px, 4vw, 64px);
    background: var(--clr-surface);
    border-radius: var(--radius-xl) 0 var(--radius-xl) 0;
    max-width: 920px;
    margin: 0 auto;
}
.sm-timer-time {
    display: flex;
    gap: clamp(8px, 2vw, 48px);
    justify-content: center;
    align-items: flex-start;
    flex-wrap: wrap;
}
.sm-timer-time > span {
    font-family: var(--font-serif);
    font-size: clamp(30px, 5vw, 56px);
    font-weight: 300;
    color: var(--clr-text);
    align-self: center;
}
.sm-timer-time_item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-2);
}
.sm-timer-time_numbers {
    display: flex;
    gap: var(--sp-1);
}
.sm-timer-time_number {
    width: clamp(42px, 6vw, 72px);
    height: clamp(54px, 8vw, 96px);
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
}
.sm-timer-time_number-span {
    font-family: var(--font-serif);
    font-size: clamp(28px, 5vw, 64px);
    font-weight: 400;
    line-height: 1;
    color: var(--clr-text);
}

/* 7.8 Wishes --------------------------------------------------------- */

.sm-wishes__content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-5);
    max-width: 820px;
    width: 100%;
    margin: 0 auto;
    padding-inline: var(--container-pad);
}
.sm-wishes__content-wrap {
    position: relative;
    max-width: 660px;
    width: 100%;
}
.sm-wishes__content-slider { padding-bottom: 48px; }
.sm-wishes__content-item { text-align: center; padding-inline: var(--sp-3); }
.sm-wishes__content-slide {
    overflow-wrap: break-word;
    word-break: normal;
    hyphens: auto;
}
.sm-wishes__content-wrap_pagination {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 4px;
    align-items: baseline;
    color: var(--clr-text-muted);
}
.sm-wishes__content-wrap_text {
    font-family: var(--font-script);
    font-size: clamp(18px, 2vw, 24px);
    color: var(--clr-text-muted);
    position: absolute;
    right: 0;
    bottom: 0;
    pointer-events: none;
    display: none; /* декоративный элемент ломает читаемость — скрываем */
}
.sm-q-l, .sm-q-r { display: none; } /* кавычки-артефакт слайдера, прячем */

/* 7.9 Contact -------------------------------------------------------- */

.sm-contact {
    padding-block: var(--section-pad-y);
}
.sm-contact__shell {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-5);
    max-width: 580px;
    margin: 0 auto;
    text-align: center;
}
.sm-contact__shell-descr {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-3);
}
.sm-contact__shell-descr_text { color: var(--clr-text-muted); max-width: 520px; }
.sm-contact__shell__container {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--sp-5);
}
@media (max-width: 768px) {
    .sm-contact__shell__container {
        flex-direction: column;
        gap: var(--sp-4);
    }
}
.sm-contact__shell-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-2);
}
.sm-contact__shell-item > a {
    font-family: var(--font-sans);
    font-size: clamp(18px, 2vw, 24px);
    font-weight: 300;
    color: var(--clr-text);
}
.sm-contact .sm-manropeBold-20-18 {
    font-family: var(--font-sans);
    font-size: clamp(20px, 2.4vw, 28px);
    font-weight: 300;
}
.sm-contact__shell .sm-btn { min-width: 150px; height: 150px; }
.sm-bg-text { display: none; } /* декоративные фоновые цифры-буквы — без них чище */

/* 7.10 Questionnaire ------------------------------------------------ */

.sm-questionnaire {
    padding-block: var(--section-pad-y);
}
.sm-questionnaire__container {
    max-width: 960px;
    margin: 0 auto;
    padding-inline: var(--container-pad);
    display: flex;
    flex-direction: column;
    gap: var(--sp-6);
    align-items: center;
}
.sm-questionnaire__top {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-3);
    text-align: center;
}
.sm-questionnaire__top-text { max-width: 540px; }
.sm-questionnaire__content-date {
    font-family: var(--font-serif);
    font-size: clamp(22px, 2.8vw, 34px);
    display: flex;
    gap: var(--sp-2);
    align-items: baseline;
}

/* На десктопе — форма inline, кнопка «Подтвердить» скрыта.
   На мобилке — наоборот: форма в модалке, показываем кнопку. */
.sm-questionnaire-form {
    width: 100%;
    max-width: 780px;
    margin: 0 auto;
    padding: clamp(24px, 4vw, 56px);
    background: var(--clr-surface);
    border-radius: var(--radius-xl) 0 var(--radius-xl) 0;
}
.sm-questionnaire-btn { display: none; }

@media (max-width: 768px) {
    .sm-questionnaire-form { display: none; }
    .sm-questionnaire-btn  { display: inline-flex; margin: 0 auto; }
}

/* 7.11 BG image ------------------------------------------------------ */

.sm-bg-image {
    padding-block: var(--section-pad-y);
    overflow: hidden;
}
.sm-bg-image_photo {
    width: min(1180px, 100%);
    aspect-ratio: 16 / 9;
    margin: 0 auto;
    object-fit: cover;
    border-radius: var(--radius-lg);
}

/* 7.12 Footer -------------------------------------------------------- */

.sm-footer {
    position: relative;
    overflow: hidden;
}
.sm-footer .sm-container {
    padding-block: var(--section-pad-y);
    position: relative;
    z-index: 1;
}
.sm-footer__shell {
    display: flex;
    flex-direction: column;
    gap: var(--sp-4);
    align-items: center;
    text-align: center;
}
.sm-footer__shell__title {
    color: var(--clr-text);
    font-family: var(--font-sans);
    font-weight: 300;
}
.sm-footer__shell-love {
    display: flex;
    flex-direction: column;
    gap: var(--sp-3);
    align-items: center;
}
.sm-footer__shell-love_text {
    font-family: var(--font-serif);
    font-size: clamp(36px, 6vw, 72px);
    line-height: 1.1;
    text-transform: uppercase;
    text-align: center;
}
.sm-footer__shell-love_text svg { display: inline-block; vertical-align: middle; }


/* 7.13 Sticky mobile CTA -------------------------------------------- */

.sm-mob-btn {
    display: none;
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 90;
    background: var(--clr-accent);
    box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.12);
    transition: transform 0.25s ease;
}
.sm-mob-btn.sm-hidden_slow { transform: translateY(100%); }
.sm-mob-btn .sm-button { padding-bottom: calc(14px + env(safe-area-inset-bottom)); }
@media (max-width: 768px) {
    .sm-mob-btn { display: block; }
    body { padding-bottom: calc(56px + env(safe-area-inset-bottom)); }
}


/* -------------------------------------------------------------------- *
 * 8. Модалка и «Спасибо»                                                *
 * -------------------------------------------------------------------- */

.sm-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(30, 30, 30, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    overflow-y: auto;
    padding: var(--sp-5);
}
.sm-modal.modal-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.sm-modal .sm-container {
    position: relative;
    max-width: 780px;
    margin: var(--sp-5) auto;
    padding: clamp(24px, 4vw, 48px);
    background: var(--clr-surface);
    border-radius: var(--radius-xl) 0 var(--radius-xl) 0;
}
.sm-modal-close {
    position: absolute;
    top: 16px; right: 16px;
    cursor: pointer;
    z-index: 2;
}
.sm-modal-close_img { width: 28px; height: 28px; object-fit: contain; }
.sm-modal-titel {
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 16px;
    color: var(--clr-accent);
    text-align: center;
    margin-bottom: var(--sp-5);
}

.sm-thanks {
    position: fixed;
    inset: 0;
    z-index: 1100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--sp-5);
    background: rgba(247, 244, 239, 0.96);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}
.sm-thanks.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.sm-thanks-wrapp {
    background: var(--clr-surface);
    padding: clamp(32px, 5vw, 64px);
    border-radius: var(--radius-xl) 0 var(--radius-xl) 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--sp-4);
    max-width: 520px;
    width: 100%;
    font-family: var(--font-serif);
    font-size: clamp(32px, 5vw, 56px);
    line-height: 1.2;
    text-align: center;
    color: var(--clr-text);
}
.sm-thanks-close {
    position: absolute;
    top: 20px; right: 20px;
    cursor: pointer;
    z-index: 2;
}
.sm-thanks-close_img { width: 32px; height: 32px; object-fit: contain; }
.sm-thanks .sm-line { height: 40px; }


/* -------------------------------------------------------------------- *
 * 9. Slick                                                              *
 * -------------------------------------------------------------------- */

.sm-slider .slick-list { overflow: hidden; }
.sm-slider .slick-track { display: flex; }
.sm-slider .slick-slide { height: auto; }

/* Стрелок не используем: есть свайп и счётчик */
.sm-slider .slick-arrow { display: none !important; }

/* Пока slick не инициализировался — показываем только первый слайд */
.sm-slider:not(.slick-initialized) .sm-wishes__content-item + .sm-wishes__content-item {
    display: none;
}


/* -------------------------------------------------------------------- *
 * 10. Мобильный адаптив (≤768 / ≤480 / ≤360)                            *
 *
 * Шкала брейкпоинтов:
 *   ≤1024 — планшет-альбом / маленький ноут (выше по файлу)
 *   ≤768  — планшет-портрет / большие телефоны
 *   ≤480  — стандартный мобильный портрет
 *   ≤360  — iPhone SE 1G, старые Android
 * -------------------------------------------------------------------- */

@media (max-width: 768px) {
    :root {
        --section-pad-y: clamp(32px, 10vw, 64px);
        --section-gap:   clamp(20px, 5vw, 32px);
    }

    .sm-main { min-height: auto; padding-block: var(--sp-6) 0; }

    /* Hero-фотки на мобиле: убираем absolute и повороты,
       ставим в flex-ряд под заголовком. */
    .sm-main__img {
        height: auto;
        display: flex;
        justify-content: center;
        gap: var(--sp-3);
        margin-bottom: var(--sp-5);
    }
    .sm-main__img__wrapper {
        position: static;
        top: auto; left: auto; right: auto;
        transform: rotate(-4deg);
        padding: 14px 12px 10px;
    }
    .sm-main__img__wrapper:last-child { transform: rotate(4deg); }
    .sm-main__img__wrapper > img {
        width: clamp(140px, 38vw, 220px);
    }
    .sm-main__content { padding-block: var(--sp-5); }

    /* Контакты: блок с кнопкой сжимаем */
    .sm-contact__shell .sm-btn { min-width: 120px; height: 120px; }

    /* Таймер: тесный gap на узком */
    .sm-timer-time { gap: clamp(4px, 2vw, 24px); }

    /* Форма: padding модалки-секции поменьше */
    .sm-questionnaire-form { padding: clamp(20px, 5vw, 32px); }
}

@media (max-width: 480px) {
    /* Круглые CTA-кнопки превращаем в pill во всю ширину */
    .sm-btn {
        width: 100%;
        max-width: 320px;
        min-width: 0;
        height: 56px;
        padding: 14px 24px;
        border-radius: 28px;
        font-size: 14px;
        letter-spacing: 0.06em;
    }
    .sm-location .sm-btn,
    .sm-contact__shell .sm-btn {
        min-width: 0;
        height: 56px;
    }

    /* Герой — убираем верхний паддинг и чуть жмём фото */
    .sm-main__img__wrapper > img { width: clamp(130px, 42vw, 200px); }
    .sm-main__img__wrapper { padding: 10px 10px 8px; }
    .sm-main__img__text { font-size: clamp(14px, 4vw, 20px); }

    /* Календарь: компактнее ячейки, тонкий gap */
    .sm-date__content {
        padding: clamp(20px, 5vw, 32px);
        border-radius: var(--radius-lg) 0 var(--radius-lg) 0;
    }
    .sm-date__calendar-bottom { gap: 4px; }
    .sm-date__calendar-bottom > span {
        width: 100%;
        aspect-ratio: 1;
        height: auto;
        font-size: clamp(12px, 3.6vw, 15px);
    }
    .sm-date__calendar-bottom .sm-cormorantLight-30-20px {
        font-size: clamp(11px, 3vw, 13px);
        letter-spacing: 0.04em;
    }

    /* Таймер: компактные ячейки цифр */
    .sm-timer__container {
        padding: clamp(20px, 5vw, 32px);
        border-radius: var(--radius-lg) 0 var(--radius-lg) 0;
    }
    .sm-timer-time_number {
        width: clamp(38px, 13vw, 56px);
        height: clamp(48px, 16vw, 72px);
    }
    .sm-timer-time_item { gap: 6px; }

    .sm-wishes__content-item { padding-inline: var(--sp-2); }

    /* Модалка: уменьшенный радиус, плотный padding, крестик с touch-зоной */
    .sm-modal { padding: 8px; }
    .sm-modal .sm-container {
        margin: 8px auto;
        padding: clamp(20px, 5vw, 28px) clamp(16px, 5vw, 24px);
        border-radius: var(--radius-lg) 0 var(--radius-lg) 0;
    }
    .sm-modal-close {
        top: 8px; right: 8px;
        padding: 10px;
    }
    .sm-thanks-close {
        top: 12px; right: 12px;
        padding: 10px;
    }
    .sm-thanks-wrapp {
        padding: clamp(28px, 7vw, 48px) clamp(20px, 6vw, 40px);
        border-radius: var(--radius-lg) 0 var(--radius-lg) 0;
    }

    /* Touch-таргеты для label-обёрток */
    .sm-form__item-radio,
    .sm-form_checkbox {
        min-height: 44px;
        padding-block: 2px;
    }

    /* Декоративная линия дресс-кода не должна съедать экран */
    .sm-dress-code_wrap-top_line { width: clamp(80px, 32vw, 180px); }

    /* Цветовые квадраты дресс-кода — оставляем в 4 колонки, но плотнее */
    .sm-dress-code_wrap-bottom { gap: var(--sp-2); }

    /* Footer-имя: фиксированный 64px заменяем на адаптив */
    .sm-footer__shell-love_text[style] { font-size: clamp(36px, 10vw, 64px) !important; }

    /* BG-фото-картинка в полную ширину и чуть меньше скругление */
    .sm-bg-image_photo { border-radius: var(--radius-md); aspect-ratio: 4 / 3; }
}

@media (max-width: 360px) {
    /* Самые крайние правки — плотнее шрифты и отступы */
    :root {
        --container-pad: 12px;
        --section-pad-y: clamp(28px, 12vw, 48px);
    }

    .sm-main__content-date {
        font-size: clamp(28px, 9vw, 40px);
        gap: var(--sp-2);
    }
    .sm-main__content-titel { font-size: clamp(42px, 14vw, 72px); }
    .sm-main__img__wrapper > img { width: clamp(120px, 44vw, 180px); }

    .sm-date__calendar-bottom { gap: 2px; }
    .sm-date__calendar-bottom > span { font-size: clamp(11px, 3.4vw, 13px); }

    .sm-timer-time_number {
        width: clamp(34px, 14vw, 48px);
        height: clamp(44px, 18vw, 64px);
    }
    .sm-timer-time_number-span { font-size: clamp(22px, 7vw, 40px); }

    .sm-form_checkbox_label,
    .sm-form__item-radio span { font-size: 14px; }
}
/* -------------------------------------------------------------------- *
 * 11. Прелоадер                                                         *
 * -------------------------------------------------------------------- */

.sm-loader_wrapper {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--clr-bg);
    transition: opacity 0.3s ease;
}
.loader {
    width: 40px; height: 40px;
    border: 3px solid var(--clr-line);
    border-top-color: var(--clr-accent);
    border-radius: 50%;
    animation: wedding-spin 0.9s linear infinite;
}
@keyframes wedding-spin { to { transform: rotate(360deg); } }
