.gift-promotion {
    --gift-bronze: #80653f;
    position: relative;
    width: min(100%, 21rem);
    margin: 28px auto 20px;
    text-align: center;
}

.gift-promotion [hidden] {
    display: none;
}

.gift-countdown__title {
    display: block;
    color: #34312d;
    font-size: 20px;
    font-weight: 600;
    line-height: 28px;
}

.gift-countdown__display {
    display: grid;
    align-items: center;
    min-height: 78px;
    margin-top: 6px;
}

.gift-countdown__fallback {
    color: var(--gift-bronze);
}

.gift-countdown__units {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin: 0;
}

.gift-countdown__units > div {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.gift-countdown__units > div + div {
    border-inline-start: 1px solid #e6ded3;
}

.gift-countdown__units dt {
    color: var(--gift-bronze);
    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
}

.gift-countdown__units dd {
    order: -1;
    margin: 0;
    color: #34312d;
    font-size: clamp(36px, 6vw, 48px);
    font-variant-numeric: tabular-nums;
    font-weight: 600;
    line-height: 1;
}

.gift-meeting .button {
    max-width: 100%;
    height: auto;
    min-height: 44px;
    padding: 12px clamp(16px, 5vw, 48px);
    line-height: 20px;
    white-space: normal;
}

.gift-snow-toggle {
    position: absolute;
    top: -6px;
    right: 0;
    display: inline-flex;
    height: 40px;
    gap: 6px;
    align-items: center;
    padding: 0 4px;
    border: 0;
    background: transparent;
    color: var(--gift-bronze);
    font: inherit;
    font-size: 13px;
    cursor: pointer;
}

.gift-snow-toggle:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 1px;
}

.gift-snow-toggle__icon {
    width: 9px;
    height: 11px;
    border-inline: 3px solid currentColor;
}

.gift-snow-toggle[data-paused] .gift-snow-toggle__icon {
    width: 0;
    height: 0;
    border: solid transparent;
    border-width: 6px 0 6px 9px;
    border-left-color: currentColor;
}

.gift-snow {
    position: fixed;
    z-index: 4;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    user-select: none;
}

.gift-snow > span {
    position: absolute;
    top: 0;
    left: calc((var(--lane) + .5) * 100% / var(--lanes, 10));
    width: calc(var(--size, 44px) * var(--flake-scale, 1));
    translate: -50% 0;
    aspect-ratio: 1;
    opacity: var(--opacity);
    background: url("snowflakes.webp") var(--flake) center / 400% 100% no-repeat;
    animation: gift-snow-fall var(--duration) linear infinite;
    animation-delay: calc((var(--lane) + 1) * -3.7s);
}

.gift-snow > :nth-child(4n + 1) { --flake: 0%; --duration: 18s; --drift: 32px; --opacity: .64; }
.gift-snow > :nth-child(4n + 2) { --flake: 33.333333%; --duration: 23s; --drift: -26px; --opacity: .55; }
.gift-snow > :nth-child(4n + 3) { --flake: 66.666667%; --duration: 20s; --drift: 24px; --opacity: .62; }
.gift-snow > :nth-child(4n) { --flake: 100%; --duration: 17s; --drift: -38px; --opacity: .66; }

.gift-snow[data-paused] > span {
    animation-play-state: paused;
}

@keyframes gift-snow-fall {
    from { transform: translate3d(0, -120%, 0) rotate(-22deg); }
    to { transform: translate3d(var(--drift), var(--fall-distance, 100vh), 0) rotate(95deg); }
}

@supports (height: 100lvh) {
    .gift-snow { --fall-distance: 100lvh; }
}

@media (max-width: 575.98px) {
    .gift-promotion { margin-block: 20px 16px; }
    .gift-snow { --flake-scale: .75; }
    .gift-snow > :nth-child(5n),
    .gift-snow > :nth-child(5n + 2) { display: none; }
}

@media (prefers-reduced-motion: reduce), print {
    .gift-snow, .gift-snow-toggle { display: none; }
    .gift-snow > span { animation: none; }
}

.glightbox-container.fancybox-container.gift-booking-lightbox .gclose {
    display: none;
}

.gift-booking-lightbox .gslide-inline {
    max-height: none;
    overflow: visible;
}

.glightbox-container.gift-booking-lightbox .ginlined-content {
    max-height: calc(100vh - 32px);
    max-height: calc(100dvh - 32px);
    overflow: auto;
    overscroll-behavior: contain;
}

.popup.gift-booking {
    --booking-gutter: clamp(18px, 4vw, 32px);
    --booking-accent: #80653f;
    box-sizing: border-box;
    width: min(552px, calc(100vw - 24px));
    padding: 0;
    background: #fff;
    color: #34312d;
    text-align: left;
}

.gift-booking__header {
    position: sticky;
    z-index: 2;
    top: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 18px var(--booking-gutter) 4px;
    background: #fff;
}

.gift-booking__header h2 {
    margin: 0;
    color: inherit;
    font-size: clamp(24px, 4vw, 32px);
    font-weight: 600;
    line-height: 1.15;
}

.gift-booking__close {
    position: relative;
    flex: 0 0 44px;
    height: 44px;
    margin-right: -10px;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--booking-accent);
    cursor: pointer;
}

.gift-booking__close::before,
.gift-booking__close::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 18px;
    height: 2px;
    background: currentColor;
    transform: translate(-50%, -50%) rotate(45deg);
}

.gift-booking__close::after { transform: translate(-50%, -50%) rotate(-45deg); }

.gift-booking__intro {
    margin: 0;
    padding-inline: var(--booking-gutter);
    color: #625d56;
    font-size: 16px;
    line-height: 1.4;
}

.gift-booking__body {
    position: relative;
    width: 100%;
    min-width: 0;
    padding: 22px var(--booking-gutter) var(--booking-gutter);
}

.gift-booking__body form,
.gift-booking__agreements {
    display: grid;
    gap: 18px;
}

.gift-booking__fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 16px;
}

.gift-booking__fields .form-field { display: block; min-width: 0; margin: 0; }
.gift-booking__fields .form-field:first-child { grid-column: 1 / -1; }
.gift-booking__fields .input-label { margin: 0 0 5px; font-size: 15px; line-height: 20px; }
.gift-booking__fields .input { width: 100%; height: 44px; margin: 0; font-size: 16px; }

.gift-booking__agreements {
    gap: 10px;
    border-top: 1px solid #e7e0d7;
    padding-top: 16px;
}

.gift-booking__agreement .input-checkbox {
    padding: 0;
    font-size: 14px;
    line-height: 19px;
}

.gift-booking__agreement label {
    position: relative;
    display: block;
    padding-left: 27px;
}

.gift-booking__agreement input[type="checkbox"] {
    top: 1px;
    width: 17px;
    height: 17px;
    margin: 0;
    padding: 0;
    opacity: 1;
    appearance: auto;
    accent-color: var(--booking-accent);
    cursor: pointer;
}

.gift-booking__agreement .input-checkbox span { color: inherit; }
.gift-booking__agreement .input-checkbox span::before { content: none; }
.gift-booking__agreement label > span:last-child { display: none; }
.gift-booking__agreement input:required + span::after { content: "*"; color: var(--booking-accent); }

.gift-booking__agreement a {
    display: inline-block;
    margin-left: 27px;
    color: var(--booking-accent);
    font-size: 13px;
    line-height: 20px;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.gift-booking :is(a, button, input):focus-visible {
    outline: 2px solid var(--booking-accent);
    outline-offset: 2px;
}

.gift-booking__body .button {
    width: 100%;
    height: auto;
    min-height: 46px;
    padding: 12px 20px;
    line-height: 20px;
    white-space: normal;
}

.gift-booking__body .button:disabled { opacity: .7; cursor: wait; }
.gift-booking__body .form-submit-status { margin: 0; font-size: 14px; line-height: 20px; }
.gift-booking__body input[type="checkbox"].red-border-form { outline: 2px solid #a42121; }
.gift-booking__body.ajax-success form > :is(.gift-booking__fields, .gift-booking__agreements, .text-center) {
    display: none;
}

.gift-booking__body.ajax-success .form-submit-status {
    padding-top: 12px;
    border-top: 1px solid #e7e0d7;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.3;
}

@media (max-width: 550px) {
    .gift-booking__header { padding-top: 10px; }
    .gift-booking__body { padding-top: 16px; }
    .gift-booking__fields { grid-template-columns: minmax(0, 1fr); gap: 10px; }
}
