/* =========================================================
   RESET
========================================================= */

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
}

body {
    --red: #f20d2f;
    --red-dark: #c30024;
    --red-deep: #870019;

    --white: #fffdfa;
    --pure-white: #ffffff;

    --black: #121212;
    --gray: #77726e;

    --border: rgba(18, 18, 18, 0.18);

    min-width: 280px;

    overflow-x: hidden;

    background: var(--white);
    color: var(--black);

    font-family:
        Arial,
        Helvetica,
        sans-serif;

    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

body.is-locked {
    height: 100%;
    overflow: hidden;
    overscroll-behavior: none;
}

button,
input,
textarea {
    font: inherit;
}

button,
a,
label {
    -webkit-tap-highlight-color: transparent;
}

button {
    border: 0;
}

a {
    color: inherit;
    text-decoration: none;
}

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


/* =========================================================
   GLOBAL
========================================================= */

.section {
    position: relative;

    width: 100%;

    padding:
        clamp(90px, 12vw, 180px)
        clamp(20px, 5vw, 80px);
}

.section-number {
    margin-bottom:
        clamp(45px, 7vw, 70px);

    font-size: 13px;
    font-weight: 700;

    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.section-number--light {
    color: var(--pure-white);
}

.eyebrow {
    display: inline-flex;

    font-size: 11px;
    font-weight: 700;

    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.eyebrow--light {
    color: var(--pure-white);
}

.section-title {
    max-width: 1100px;

    margin: 0;

    font-size:
        clamp(52px, 9vw, 145px);

    font-weight: 900;

    line-height: 0.87;
    letter-spacing: -0.075em;

    text-transform: uppercase;

    overflow-wrap: anywhere;
}

.section-title span {
    display: block;

    color: var(--red);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-weight: 400;
    font-style: italic;

    text-transform: none;
}


/* =========================================================
   COVER
========================================================= */

.cover {
    position: fixed;
    inset: 0;

    z-index: 9999;

    width: 100%;

    min-height: 100vh;
    min-height: 100svh;
    min-height: 100dvh;

    display: flex;
    flex-direction: column;
    justify-content: space-between;

    overflow: hidden;

    padding:
        max(20px, env(safe-area-inset-top))
        clamp(16px, 5vw, 72px)
        max(20px, env(safe-area-inset-bottom));

    background: var(--red);
    color: var(--pure-white);

    clip-path: inset(0 0 0 0);

    transition:
        clip-path 1.05s cubic-bezier(.76, 0, .24, 1),
        opacity 0.55s ease 0.5s,
        visibility 0s linear 1.1s;
}

.cover.is-open {
    clip-path: inset(0 0 100% 0);

    opacity: 0;
    visibility: hidden;

    pointer-events: none;
}

.cover__noise {
    position: absolute;
    inset: 0;

    opacity: 0.055;

    pointer-events: none;

    background-image:
        repeating-radial-gradient(
            circle at 0 0,
            transparent 0,
            rgba(255, 255, 255, 0.45) 1px,
            transparent 2px
        );

    background-size: 8px 8px;
}

.cover__top,
.cover__bottom {
    position: relative;

    z-index: 20;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    font-size: 10px;
    font-weight: 700;

    line-height: 1.35;

    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.cover__center {
    position: relative;

    flex: 1;

    min-height: 0;

    display: grid;
    place-items: center;
}

.cover__word {
    position: absolute;

    left: 50%;
    top: 50%;

    transform:
        translate(-50%, -50%)
        scaleX(0.88);

    white-space: nowrap;

    color: var(--pure-white);

    opacity: 0.1;

    font-size:
        clamp(130px, 31vw, 600px);

    font-weight: 900;

    line-height: 0.7;
    letter-spacing: -0.11em;

    user-select: none;

    pointer-events: none;
}

.cover__hint {
    display: flex;
    align-items: center;

    gap: 12px;
}

.cover__hint span {
    animation:
        hintBounce 1.7s ease-in-out infinite;
}

@keyframes hintBounce {

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

    50% {
        transform: translateY(5px);
    }

}


/* =========================================================
   ENVELOPE
========================================================= */

.envelope {
    position: relative;

    isolation: isolate;

    width:
        min(
            82vw,
            520px,
            calc(51svh * 1.48)
        );

    width:
        min(
            82vw,
            520px,
            calc(51dvh * 1.48)
        );

    aspect-ratio: 1.48 / 1;

    perspective: 1400px;

    filter:
        drop-shadow(
            0 30px 50px rgba(72, 0, 15, 0.27)
        );
}

.envelope__back,
.envelope__front {
    position: absolute;
    inset: 0;

    border-radius: 4px;
}

.envelope__back {
    z-index: 1;

    background: #f4e9e1;
}


/* =========================================================
   LETTER
   ВАЖНО:
   ДО ОТКРЫТИЯ ПОЛНОСТЬЮ СКРЫТО
========================================================= */

.envelope__letter {
    position: absolute;

    z-index: 3;

    left: 6%;
    top: 8%;

    width: 88%;
    height: 84%;

    display: grid;
    place-items: center;

    border-radius: 2px;

    background: var(--pure-white);
    color: var(--red);

    opacity: 0;
    visibility: hidden;

    pointer-events: none;

    transform:
        translateY(30%);

    clip-path:
        inset(0 0 100% 0);

    will-change:
        transform,
        opacity,
        clip-path;
}

.envelope.is-opening
.envelope__letter {
    animation:
        letterRise
        1s
        cubic-bezier(.16, 1, .3, 1)
        0.78s
        forwards;
}

@keyframes letterRise {

    0% {
        z-index: 6;

        opacity: 0;
        visibility: visible;

        transform:
            translateY(30%);

        clip-path:
            inset(0 0 100% 0);
    }

    12% {
        z-index: 6;

        opacity: 1;

        visibility: visible;

        clip-path:
            inset(0 0 62% 0);
    }

    40% {
        z-index: 6;

        opacity: 1;

        visibility: visible;

        clip-path:
            inset(0 0 0 0);
    }

    100% {
        z-index: 6;

        opacity: 1;

        visibility: visible;

        transform:
            translateY(-56%);

        clip-path:
            inset(0 0 0 0);
    }

}

.envelope__letter-inner {
    width: 100%;

    padding:
        clamp(16px, 4vw, 28px);

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    text-align: center;
}

.envelope__letter strong {
    display: flex;
    flex-direction: column;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size:
        clamp(28px, 6vw, 64px);

    font-weight: 400;
    font-style: italic;

    line-height: 0.83;
}

.envelope__letter strong span {
    margin: 6px 0;

    font-family:
        Arial,
        Helvetica,
        sans-serif;

    font-size: 0.42em;
    font-style: normal;
}

.envelope__letter small,
.mini-label {
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

.mini-label {
    margin-bottom:
        clamp(12px, 2vw, 22px);

    font-size:
        clamp(6px, 1vw, 8px);

    font-weight: 700;
}

.envelope__letter small {
    margin-top:
        clamp(14px, 2vw, 24px);

    font-size:
        clamp(6px, 1vw, 8px);
}


/* =========================================================
   ENVELOPE FRONT
========================================================= */

.envelope__front {
    z-index: 5;

    overflow: hidden;

    background:
        linear-gradient(
            32deg,
            #f0e4dc 49.5%,
            transparent 50%
        ),
        linear-gradient(
            -32deg,
            #fff8f2 49.5%,
            transparent 50%
        );

    background-color: #f5e9e1;

    clip-path:
        polygon(
            0 42%,
            50% 74%,
            100% 42%,
            100% 100%,
            0 100%
        );
}


/* =========================================================
   FLAP
========================================================= */

.envelope__flap {
    position: absolute;

    z-index: 7;

    left: 0;
    top: 0;

    width: 100%;
    height: 57%;

    background: #fff7f1;

    clip-path:
        polygon(
            0 0,
            100% 0,
            50% 100%
        );

    transform-origin: top center;

    transform:
        rotateX(0deg);

    transform-style: preserve-3d;

    backface-visibility: hidden;

    will-change: transform;
}

.envelope.is-opening
.envelope__flap {
    animation:
        flapOpen
        0.78s
        cubic-bezier(.63, 0, .37, 1)
        forwards;
}

@keyframes flapOpen {

    0% {
        z-index: 7;

        transform:
            rotateX(0deg);
    }

    99% {
        z-index: 7;

        transform:
            rotateX(179deg);
    }

    100% {
        z-index: 2;

        transform:
            rotateX(180deg);
    }

}


/* =========================================================
   SEAL
========================================================= */

.seal {
    position: absolute;

    z-index: 15;

    left: 50%;
    top: 50%;

    width: 132px;
    height: 132px;

    display: grid;
    place-items: center;

    transform:
        translate(-50%, -30%);

    border-radius: 50%;

    background: transparent;
    color: var(--pure-white);

    cursor: pointer;

    touch-action: manipulation;

    transition:
        transform 0.3s ease,
        opacity 0.22s ease;
}

.seal:hover {
    transform:
        translate(-50%, -30%)
        scale(1.06);
}

.seal:active {
    transform:
        translate(-50%, -30%)
        scale(0.96);
}

.seal:focus-visible {
    outline:
        2px solid var(--pure-white);

    outline-offset: 5px;
}

.envelope.is-opening
.seal {
    opacity: 0;

    pointer-events: none;

    transform:
        translate(-50%, -30%)
        scale(0.88);
}

.seal__circle {
    position: absolute;

    width: 82px;
    height: 82px;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 4px;

    border-radius: 50%;

    background: var(--red);

    box-shadow:
        0 8px 30px rgba(118, 0, 23, 0.35);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-style: italic;

    transform:
        rotate(-7deg);
}

.seal__circle span:nth-child(2) {
    font-size: 12px;
}

.seal__text {
    position: absolute;

    top: calc(50% + 54px);

    white-space: nowrap;

    font-size: 8px;
    font-weight: 700;

    letter-spacing: 0.17em;
    text-transform: uppercase;
}


/* =========================================================
   SITE INITIAL STATE
========================================================= */

.site {
    width: 100%;

    opacity: 0;

    transform:
        scale(0.988);

    outline: none;

    transition:
        opacity 0.8s ease,
        transform 1.1s cubic-bezier(.16, 1, .3, 1);
}

body.invitation-opened
.site {
    opacity: 1;

    transform:
        scale(1);
}


/* =========================================================
   HERO
========================================================= */

.hero {
    position: relative;

    min-height: 100vh;
    min-height: 100svh;
    min-height: 100dvh;

    display: flex;
    flex-direction: column;

    padding-top:
        max(24px, env(safe-area-inset-top));

    padding-bottom:
        max(28px, env(safe-area-inset-bottom));

    overflow: hidden;
}

.hero__header {
    position: relative;

    z-index: 5;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    padding-bottom: 20px;

    border-bottom:
        1px solid var(--border);
}

.hero__date-small {
    flex-shrink: 0;

    font-size: 11px;
    font-weight: 700;

    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero__content {
    position: relative;

    z-index: 4;

    flex: 1;

    min-height: 0;

    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero__intro {
    width:
        min(380px, 80%);

    margin:
        clamp(30px, 5vh, 60px)
        0
        clamp(30px, 6vw, 65px)
        auto;

    font-size:
        clamp(15px, 1.7vw, 22px);

    line-height: 1.25;
}

.hero__title {
    position: relative;

    margin: 0;

    display: flex;
    flex-direction: column;

    max-width: 100%;

    font-size:
        clamp(82px, 20vw, 315px);

    font-weight: 900;

    line-height: 0.62;
    letter-spacing: -0.09em;

    text-transform: uppercase;
}

.hero__name {
    position: relative;

    display: block;

    max-width: 100%;
}

.hero__name--right {
    align-self: flex-end;
}

.hero__ampersand {
    position: absolute;

    z-index: 5;

    left: 50%;
    top: 48%;

    transform:
        translate(-50%, -50%)
        rotate(-11deg);

    color: var(--red);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size:
        clamp(85px, 16vw, 230px);

    font-weight: 400;
    font-style: italic;
}

.hero__meta {
    margin-top:
        clamp(45px, 9vw, 110px);

    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    border-top:
        1px solid var(--border);
}

.hero__meta > div {
    min-width: 0;

    padding: 20px 0;

    display: flex;
    flex-direction: column;

    gap: 8px;

    border-right:
        1px solid var(--border);
}

.hero__meta > div:not(:first-child) {
    padding-left: 22px;
}

.hero__meta > div:last-child {
    border-right: 0;
}

.hero__meta span {
    color: var(--gray);

    font-size: 9px;

    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.hero__meta strong {
    font-size:
        clamp(17px, 2vw, 28px);

    overflow-wrap: anywhere;
}

.hero__scroll {
    display: flex;
    align-items: center;

    gap: 14px;

    font-size: 8px;

    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.hero__scroll-line {
    width: 70px;
    height: 1px;

    background: var(--black);

    transform-origin: left;

    animation:
        scrollLine 2.1s ease-in-out infinite;
}

@keyframes scrollLine {

    0%,
    100% {
        transform: scaleX(0.2);
    }

    50% {
        transform: scaleX(1);
    }

}

.hero__decor {
    position: absolute;

    color: var(--red);

    opacity: 0.08;

    font-weight: 900;

    line-height: 0.75;

    user-select: none;
    pointer-events: none;

    will-change: transform;
}

.hero__decor--one {
    top: 13%;
    left: -8%;

    font-size:
        clamp(150px, 33vw, 500px);

    transform:
        rotate(-90deg);
}

.hero__decor--two {
    right: -3%;
    bottom: 8%;

    font-size:
        clamp(160px, 38vw, 650px);
}


/* =========================================================
   MARQUEE
========================================================= */

.marquee {
    width: 100%;

    overflow: hidden;

    padding: 20px 0;

    background: var(--red);
    color: var(--pure-white);
}

.marquee__track {
    width: max-content;

    display: flex;
    align-items: center;

    gap: 35px;

    font-size:
        clamp(22px, 3vw, 42px);

    font-weight: 900;

    letter-spacing: -0.04em;
    text-transform: uppercase;

    animation:
        marquee 22s linear infinite;
}

.marquee__track i {
    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-weight: 400;
    font-style: normal;
}

@keyframes marquee {

    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(-50%);
    }

}


/* =========================================================
   INTRO
========================================================= */

.intro {
    min-height: 100vh;
}

.intro__grid {
    display: grid;

    grid-template-columns:
        minmax(100px, 0.55fr)
        minmax(0, 2.5fr);

    gap:
        clamp(35px, 7vw, 100px);
}

.intro__small {
    font-size: 11px;

    line-height: 1.4;

    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.intro__text {
    width:
        min(580px, 80%);

    margin:
        70px 0
        0 auto;

    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 40px;
}

.intro__text p {
    margin: 0;

    font-size:
        clamp(14px, 1.35vw, 19px);

    line-height: 1.48;
}

.big-heart {
    margin-top:
        clamp(80px, 13vw, 180px);

    text-align: center;

    color: var(--red);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size:
        clamp(180px, 40vw, 620px);

    line-height: 0.62;

    transform:
        rotate(-8deg);

    transform-origin: center;
}


/* =========================================================
   DATE
========================================================= */

.date-section {
    position: relative;

    width: 100%;

    overflow: hidden;

    padding:
        clamp(90px, 12vw, 170px)
        clamp(20px, 5vw, 80px);

    background: var(--red);
    color: var(--pure-white);
}

.date-section__top {
    margin-bottom:
        clamp(80px, 15vw, 200px);

    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    font-size:
        clamp(70px, 17vw, 260px);

    font-weight: 900;

    line-height: 0.64;
    letter-spacing: -0.09em;

    text-transform: uppercase;
}

.date-section__top span:nth-child(2) {
    text-align: center;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-weight: 400;
    font-style: italic;

    text-transform: lowercase;
}

.date-section__top span:last-child {
    text-align: right;
}

.date-card {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        minmax(0, 2fr)
        minmax(0, 1fr);

    align-items: center;

    border-top:
        1px solid rgba(255, 255, 255, 0.35);

    border-bottom:
        1px solid rgba(255, 255, 255, 0.35);
}

.date-card__month,
.date-card__year {
    font-size:
        clamp(16px, 2.2vw, 32px);

    font-weight: 700;

    letter-spacing: -0.04em;
    text-transform: uppercase;
}

.date-card__year {
    text-align: right;
}

.date-card__day {
    text-align: center;

    font-size:
        clamp(150px, 27vw, 440px);

    font-weight: 900;

    line-height: 0.9;
    letter-spacing: -0.1em;
}

.date-card__week {
    grid-column:
        1 / -1;

    display: grid;

    grid-template-columns:
        repeat(7, minmax(0, 1fr));

    padding: 28px 0;

    border-top:
        1px solid rgba(255, 255, 255, 0.35);
}

.date-card__week span {
    position: relative;

    text-align: center;

    font-size: 10px;

    letter-spacing: 0.15em;
}

.date-card__week .is-active {
    z-index: 1;

    color: var(--red);
}

.date-card__week .is-active::before {
    content: "";

    position: absolute;

    z-index: -1;

    left: 50%;
    top: 50%;

    width: 45px;
    height: 45px;

    border-radius: 50%;

    background: var(--pure-white);

    transform:
        translate(-50%, -50%);
}


/* =========================================================
   SCHEDULE
========================================================= */

.schedule {
    background: var(--black);
    color: var(--pure-white);
}

.schedule__header {
    margin-bottom:
        clamp(90px, 14vw, 180px);

    display: grid;

    grid-template-columns:
        minmax(120px, 1fr)
        minmax(0, 3fr);

    gap: 40px;

    align-items: start;
}

.schedule__header > p {
    margin: 0;

    font-size: 11px;

    line-height: 1.35;

    letter-spacing: 0.13em;
    text-transform: uppercase;
}

.schedule__header h2 {
    margin: 0;

    font-size:
        clamp(75px, 15vw, 240px);

    font-weight: 900;

    line-height: 0.68;
    letter-spacing: -0.09em;

    text-transform: uppercase;
}

.schedule__header h2 em {
    display: block;

    text-align: right;

    color: var(--red);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-weight: 400;
    font-style: italic;

    text-transform: lowercase;
}

.timeline {
    border-top:
        1px solid rgba(255, 255, 255, 0.2);
}

.timeline__item {
    display: grid;

    grid-template-columns:
        minmax(100px, 0.7fr)
        90px
        minmax(0, 2fr);

    gap:
        clamp(20px, 5vw, 70px);

    align-items: start;

    padding: 35px 0;

    border-bottom:
        1px solid rgba(255, 255, 255, 0.2);
}

.timeline__time {
    color: var(--red);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size:
        clamp(34px, 5vw, 70px);

    font-style: italic;
}

.timeline__circle {
    width: 60px;
    height: 60px;

    display: grid;
    place-items: center;

    border:
        1px solid rgba(255, 255, 255, 0.4);

    border-radius: 50%;

    font-size: 9px;

    letter-spacing: 0.15em;
}

.timeline__content span {
    display: inline-block;

    margin-bottom: 12px;

    color:
        rgba(255, 255, 255, 0.55);

    font-size: 9px;

    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.timeline__content h3 {
    margin:
        0 0 12px;

    font-size:
        clamp(27px, 4vw, 55px);

    letter-spacing: -0.045em;
}

.timeline__content p {
    width:
        min(520px, 100%);

    margin: 0;

    color:
        rgba(255, 255, 255, 0.7);

    font-size:
        clamp(13px, 1.4vw, 18px);

    line-height: 1.5;
}


/* =========================================================
   PLACE
========================================================= */

.place {
    background: var(--white);
}

.place__grid {
    display: grid;

    grid-template-columns:
        minmax(0, 1.5fr)
        minmax(0, 1fr);

    gap:
        clamp(45px, 7vw, 120px);

    align-items: center;
}

.place__visual {
    position: relative;

    min-height:
        clamp(420px, 65vw, 790px);

    overflow: hidden;

    background: var(--red);
    color: var(--pure-white);
}

.place__visual::after {
    content: "";

    position: absolute;

    inset: 6%;

    border:
        1px solid rgba(255, 255, 255, 0.42);

    border-radius: 50%;

    transform:
        scaleX(1.2)
        rotate(-18deg);
}

.place__visual::before {
    content: "";

    position: absolute;

    left: -30%;
    top: 40%;

    width: 80%;
    height: 80%;

    border:
        1px solid rgba(255, 255, 255, 0.25);

    border-radius: 50%;
}

.place__visual-number {
    position: absolute;

    top: -4%;
    left: -2%;

    font-size:
        clamp(140px, 25vw, 390px);

    font-weight: 900;

    line-height: 0.8;
    letter-spacing: -0.12em;
}

.place__visual-text {
    position: absolute;

    z-index: 2;

    left: 7%;
    right: 7%;
    bottom: 7%;

    display: flex;
    justify-content: space-between;

    gap: 15px;

    font-size: 10px;
    font-weight: 700;

    letter-spacing: 0.15em;
}

.place__circle {
    position: absolute;

    z-index: 3;

    left: 50%;
    top: 55%;

    width:
        clamp(90px, 13vw, 170px);

    aspect-ratio: 1;

    display: grid;
    place-items: center;

    border-radius: 50%;

    background: var(--pure-white);
    color: var(--red);

    box-shadow:
        0 20px 40px rgba(94, 0, 18, 0.25);

    transform:
        translate(-50%, -50%)
        rotate(-9deg);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size:
        clamp(40px, 7vw, 90px);
}

.place__content {
    min-width: 0;
}

.place__content h2 {
    margin:
        22px 0 36px;

    font-size:
        clamp(65px, 10vw, 150px);

    line-height: 0.72;
    letter-spacing: -0.08em;

    text-transform: uppercase;

    overflow-wrap: anywhere;
}

.place__content h2 em {
    display: block;

    color: var(--red);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-weight: 400;
    font-style: italic;

    text-transform: none;
}

.place__content p {
    margin:
        0 0 45px;

    font-size:
        clamp(18px, 2vw, 27px);

    line-height: 1.35;
}

.button {
    width: 100%;

    min-height: 62px;

    padding:
        18px 22px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    border:
        1px solid var(--black);

    font-size: 11px;

    letter-spacing: 0.12em;
    text-transform: uppercase;

    transition:
        background 0.25s ease,
        color 0.25s ease;
}

.button--dark:hover {
    background: var(--black);
    color: var(--pure-white);
}


/* =========================================================
   DRESS
========================================================= */

.dress {
    overflow: hidden;

    background: var(--red);
    color: var(--pure-white);
}

.dress__heading {
    display: flex;
    flex-direction: column;

    font-size:
        clamp(120px, 30vw, 460px);

    font-weight: 900;

    line-height: 0.55;
    letter-spacing: -0.1em;

    text-transform: uppercase;
}

.dress__heading span:last-child {
    align-self: flex-end;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-weight: 400;
    font-style: italic;

    text-transform: lowercase;
}

.dress__body {
    margin-top:
        clamp(110px, 18vw, 250px);

    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        minmax(0, 1.6fr);

    gap:
        clamp(45px, 8vw, 130px);

    align-items: end;
}

.dress__description p {
    max-width: 450px;

    margin:
        25px 0 0;

    font-size:
        clamp(16px, 1.8vw, 24px);

    line-height: 1.45;
}

.palette {
    display: grid;

    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    height:
        clamp(180px, 26vw, 370px);
}

.palette__color {
    transition:
        transform 0.35s
        cubic-bezier(.16, 1, .3, 1);
}

.palette__color:hover {
    transform:
        translateY(-14px);
}

.palette__color--1 {
    background: #fa173a;
}

.palette__color--2 {
    background: #720014;
}

.palette__color--3 {
    background: #f8eee6;
}

.palette__color--4 {
    background: #141414;
}


/* =========================================================
   DETAILS
========================================================= */

.details__title {
    margin:
        0 0
        clamp(80px, 13vw, 180px);

    font-size:
        clamp(72px, 16vw, 250px);

    font-weight: 900;

    line-height: 0.7;
    letter-spacing: -0.09em;

    text-transform: uppercase;
}

.details__title em {
    display: block;

    text-align: right;

    color: var(--red);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-weight: 400;
    font-style: italic;

    text-transform: lowercase;
}

.details__cards {
    border-top:
        1px solid var(--border);
}

.detail-card {
    display: grid;

    grid-template-columns:
        90px
        minmax(0, 1fr)
        minmax(0, 1.2fr);

    gap:
        clamp(20px, 5vw, 70px);

    align-items: start;

    padding: 35px 0;

    border-bottom:
        1px solid var(--border);
}

.detail-card__number {
    color: var(--red);

    font-size: 11px;
    font-weight: 700;
}

.detail-card h3 {
    margin: 0;

    font-size:
        clamp(32px, 5vw, 68px);

    letter-spacing: -0.05em;
}

.detail-card p {
    max-width: 500px;

    margin: 0;

    color: #585451;

    font-size:
        clamp(14px, 1.5vw, 19px);

    line-height: 1.5;
}


/* =========================================================
   RSVP
========================================================= */

.rsvp {
    min-height: 100vh;

    overflow: hidden;

    background: var(--black);
    color: var(--pure-white);
}

.rsvp__background-text {
    position: absolute;

    top: 3%;
    left: -3%;

    color:
        rgba(255, 255, 255, 0.03);

    font-size:
        clamp(210px, 46vw, 730px);

    font-weight: 900;

    line-height: 0.7;
    letter-spacing: -0.1em;

    user-select: none;
    pointer-events: none;
}

.rsvp__header {
    position: relative;

    z-index: 2;

    margin-bottom:
        clamp(70px, 10vw, 130px);

    display: grid;

    grid-template-columns:
        minmax(100px, 0.5fr)
        minmax(0, 2fr);

    gap: 50px;
}

.rsvp__header h2 {
    margin:
        25px 0;

    font-size:
        clamp(70px, 14vw, 210px);

    line-height: 0.7;
    letter-spacing: -0.08em;

    text-transform: uppercase;
}

.rsvp__header h2 em {
    display: block;

    color: var(--red);

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-weight: 400;
    font-style: italic;

    text-transform: none;
}

.rsvp__header p {
    max-width: 520px;

    color:
        rgba(255, 255, 255, 0.65);

    font-size:
        clamp(14px, 1.5vw, 18px);

    line-height: 1.5;
}

.rsvp-form {
    position: relative;

    z-index: 3;

    width:
        min(920px, 100%);

    margin-left: auto;
}

.form-field {
    position: relative;

    margin: 0;

    padding:
        28px 0;

    border: 0;

    border-bottom:
        1px solid rgba(255, 255, 255, 0.22);
}

.form-field > label,
.form-field > legend {
    display: block;

    margin-bottom: 17px;

    padding: 0;

    color:
        rgba(255, 255, 255, 0.55);

    font-size: 9px;
    font-weight: 700;

    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.form-field input[type="text"],
.form-field textarea {
    width: 100%;

    padding: 0;

    border: 0;
    outline: 0;

    border-radius: 0;

    background: transparent;
    color: var(--pure-white);

    font-size:
        clamp(20px, 3vw, 38px);

    line-height: 1.25;

    resize: vertical;

    -webkit-appearance: none;
    appearance: none;
}

.form-field textarea {
    min-height: 80px;
}

.form-field input::placeholder,
.form-field textarea::placeholder {
    color:
        rgba(255, 255, 255, 0.22);
}

.choice-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 10px;
}

.choice {
    position: relative;

    cursor: pointer;
}

.choice input {
    position: absolute;

    opacity: 0;

    pointer-events: none;
}

.choice span {
    min-height: 66px;

    padding: 14px 18px;

    display: flex;
    align-items: center;
    justify-content: center;

    text-align: center;

    border:
        1px solid rgba(255, 255, 255, 0.3);

    font-size:
        clamp(11px, 1.3vw, 15px);

    transition:
        background 0.22s ease,
        color 0.22s ease,
        border-color 0.22s ease,
        transform 0.22s ease;
}

.choice:hover span {
    border-color: var(--pure-white);

    transform:
        translateY(-2px);
}

.choice input:checked + span {
    background: var(--red);
    border-color: var(--red);
    color: var(--pure-white);
}

.choice input:focus-visible + span {
    outline:
        2px solid var(--pure-white);

    outline-offset: 3px;
}

.guest-counter {
    width:
        min(330px, 100%);

    display: grid;

    grid-template-columns:
        70px
        minmax(0, 1fr)
        70px;

    border:
        1px solid rgba(255, 255, 255, 0.3);
}

.counter-button {
    min-width: 44px;
    height: 68px;

    background: transparent;
    color: var(--pure-white);

    cursor: pointer;

    font-size: 28px;

    touch-action: manipulation;

    transition:
        background 0.2s ease,
        color 0.2s ease;
}

.counter-button:hover {
    background: var(--red);
}

.counter-button:focus-visible {
    outline:
        2px solid var(--pure-white);

    outline-offset: -4px;
}

.guest-counter input {
    width: 100%;

    min-width: 0;

    border: 0;

    border-left:
        1px solid rgba(255, 255, 255, 0.3);

    border-right:
        1px solid rgba(255, 255, 255, 0.3);

    outline: 0;

    background: transparent;
    color: var(--pure-white);

    text-align: center;

    font-size: 22px;

    appearance: textfield;
    -moz-appearance: textfield;
}

.guest-counter input::-webkit-inner-spin-button,
.guest-counter input::-webkit-outer-spin-button {
    appearance: none;

    margin: 0;
}

.website-field {
    position: absolute;

    left: -9999px;

    width: 1px;
    height: 1px;

    overflow: hidden;

    opacity: 0;

    pointer-events: none;
}

.submit-button {
    width: 100%;

    min-height:
        clamp(90px, 11vw, 145px);

    margin-top: 45px;

    padding:
        20px 30px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 30px;

    background: var(--red);
    color: var(--pure-white);

    cursor: pointer;

    touch-action: manipulation;

    font-size:
        clamp(21px, 3vw, 45px);

    font-weight: 700;

    letter-spacing: -0.04em;

    transition:
        background 0.25s ease,
        transform 0.25s ease,
        opacity 0.25s ease;
}

.submit-button:hover {
    background: #ff2447;
}

.submit-button:active {
    transform:
        scale(0.99);
}

.submit-button:focus-visible {
    outline:
        2px solid var(--pure-white);

    outline-offset: 4px;
}

.submit-button:disabled {
    opacity: 0.62;

    cursor: wait;
}

.submit-button__icon {
    flex-shrink: 0;

    font-size: 1.4em;

    transition:
        transform 0.25s ease;
}

.submit-button:hover
.submit-button__icon {
    transform:
        translate(4px, -4px);
}

.form-status {
    min-height: 24px;

    margin-top: 18px;

    font-size: 13px;

    line-height: 1.5;
}

.form-status.is-success {
    color: #7eff9b;
}

.form-status.is-error {
    color: #ff6b7f;
}

.field-error {
    display: block;

    margin-top: 8px;

    color: #ff6b7f;

    font-size: 11px;
}

.form-field.has-error
input[type="text"],
.form-field.has-error
textarea {
    color: #ff6b7f;
}


/* =========================================================
   FOOTER
========================================================= */

.footer {
    position: relative;

    width: 100%;

    min-height: 100vh;
    min-height: 100svh;
    min-height: 100dvh;

    overflow: hidden;

    display: flex;
    flex-direction: column;
    justify-content: center;

    padding:
        clamp(100px, 15vw, 200px)
        clamp(20px, 5vw, 80px)
        max(35px, env(safe-area-inset-bottom));

    background: var(--red);
    color: var(--pure-white);
}

.footer__date {
    margin-bottom: 45px;

    text-align: center;

    font-size:
        clamp(25px, 4vw, 55px);

    font-weight: 700;
}

.footer__date span {
    opacity: 0.45;
}

.footer h2 {
    max-width: 1400px;

    margin: 0 auto;

    text-align: center;

    font-size:
        clamp(74px, 18vw, 270px);

    font-weight: 900;

    line-height: 0.66;
    letter-spacing: -0.09em;

    text-transform: uppercase;
}

.footer h2 em {
    display: block;

    margin-top: 20px;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-weight: 400;
    font-style: italic;

    text-transform: lowercase;
}

.footer__names {
    margin-top:
        clamp(80px, 12vw, 150px);

    text-align: center;

    font-family:
        Georgia,
        "Times New Roman",
        serif;

    font-size:
        clamp(34px, 5vw, 70px);

    font-style: italic;
}

.footer__bottom {
    margin-top: auto;

    padding-top: 100px;

    display: flex;
    justify-content: space-between;

    gap: 20px;

    font-size: 9px;

    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.footer__bottom a {
    padding-bottom: 4px;

    border-bottom:
        1px solid rgba(255, 255, 255, 0.6);
}


/* =========================================================
   REVEAL
========================================================= */

.reveal {
    opacity: 0;

    transform:
        translateY(45px);

    transition:
        opacity 0.9s ease,
        transform 1.05s cubic-bezier(.16, 1, .3, 1);
}

.reveal.is-visible {
    opacity: 1;

    transform:
        translateY(0);
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 900px) {

    .section {
        padding-left: 24px;
        padding-right: 24px;
    }

    .intro__grid,
    .schedule__header,
    .place__grid,
    .dress__body,
    .rsvp__header {
        grid-template-columns: 1fr;
    }

    .intro__small {
        margin-bottom: 15px;
    }

    .intro__text {
        width: 100%;

        grid-template-columns: 1fr;

        gap: 20px;
    }

    .place__visual {
        min-height:
            clamp(480px, 80vw, 650px);
    }

    .dress__description {
        order: 2;
    }

    .palette {
        order: 1;
    }

    .rsvp__header {
        gap: 20px;
    }

    .detail-card {
        grid-template-columns:
            60px
            minmax(0, 0.8fr)
            minmax(0, 1.2fr);
    }

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 640px) {

    .cover {
        padding-left: 16px;
        padding-right: 16px;
    }

    .cover__top {
        align-items: flex-start;
    }

    .cover__top span:last-child {
        text-align: right;
    }

    .cover__bottom > span:first-child {
        display: none;
    }

    .cover__bottom {
        justify-content: center;
    }

    .envelope {
        width:
            min(
                92vw,
                calc(45svh * 1.48)
            );

        width:
            min(
                92vw,
                calc(45dvh * 1.48)
            );
    }

    .seal {
        width: 110px;
        height: 110px;
    }

    .seal__circle {
        width: 72px;
        height: 72px;
    }

    .seal__text {
        top:
            calc(50% + 48px);
    }


    /* GLOBAL */

    .section {
        padding:
            90px 16px;
    }

    .section-number {
        margin-bottom: 50px;
    }


    /* HERO */

    .hero {
        padding:
            max(18px, env(safe-area-inset-top))
            16px
            max(24px, env(safe-area-inset-bottom));
    }

    .hero__header {
        align-items: flex-start;

        padding-bottom: 14px;
    }

    .hero__header .eyebrow,
    .hero__date-small {
        font-size: 8px;
    }

    .hero__intro {
        width: 80%;

        margin:
            35px 0
            48px auto;

        font-size: 14px;
    }

    .hero__title {
        font-size:
            clamp(72px, 27vw, 135px);

        line-height: 0.68;
    }

    .hero__ampersand {
        top: 50%;

        font-size:
            clamp(78px, 31vw, 145px);
    }

    .hero__meta {
        margin-top: 65px;

        grid-template-columns: 1fr;
    }

    .hero__meta > div {
        padding:
            13px 0;

        border-right: 0;

        border-bottom:
            1px solid var(--border);
    }

    .hero__meta > div:not(:first-child) {
        padding-left: 0;
    }

    .hero__meta > div:last-child {
        border-bottom: 0;
    }


    /* INTRO */

    .section-title {
        font-size:
            clamp(46px, 14vw, 82px);

        line-height: 0.91;
    }

    .big-heart {
        margin-top: 95px;
    }


    /* DATE */

    .date-section {
        padding:
            90px 16px;
    }

    .date-section__top {
        margin-bottom: 100px;

        grid-template-columns: 1fr;

        font-size:
            clamp(60px, 23vw, 120px);
    }

    .date-section__top span:nth-child(2) {
        text-align: center;
    }

    .date-section__top span:last-child {
        text-align: right;
    }

    .date-card {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .date-card__month {
        padding-top: 18px;
    }

    .date-card__year {
        padding-top: 18px;
    }

    .date-card__day {
        grid-column:
            1 / -1;

        grid-row: 2;

        font-size:
            clamp(160px, 51vw, 300px);
    }

    .date-card__week {
        grid-row: 3;

        margin-top: 15px;

        padding:
            25px 0;
    }

    .date-card__week span {
        font-size: 8px;
    }

    .date-card__week
    .is-active::before {
        width: 34px;
        height: 34px;
    }


    /* SCHEDULE */

    .schedule__header h2 {
        font-size:
            clamp(68px, 21vw, 120px);
    }

    .timeline__item {
        grid-template-columns:
            minmax(0, 1fr)
            56px;

        gap: 18px;
    }

    .timeline__time {
        font-size: 40px;
    }

    .timeline__circle {
        width: 52px;
        height: 52px;
    }

    .timeline__content {
        grid-column:
            1 / -1;

        padding-top: 5px;
    }


    /* PLACE */

    .place__visual {
        min-height: 450px;
    }

    .place__content h2 {
        font-size:
            clamp(60px, 20vw, 105px);
    }


    /* DRESS */

    .dress__heading {
        font-size:
            clamp(90px, 25vw, 180px);

        line-height: 0.6;
    }

    .dress__body {
        margin-top: 90px;
    }

    .palette {
        height: 220px;
    }


    /* DETAILS */

    .details__title {
        font-size:
            clamp(64px, 20vw, 120px);
    }

    .detail-card {
        grid-template-columns:
            42px
            minmax(0, 1fr);

        gap:
            15px 18px;

        padding:
            28px 0;
    }

    .detail-card p {
        grid-column: 2;
    }


    /* RSVP */

    .rsvp__header h2 {
        font-size:
            clamp(62px, 20vw, 112px);
    }

    .choice-grid {
        grid-template-columns: 1fr;
    }

    .choice span {
        min-height: 58px;
    }

    .form-field {
        padding:
            24px 0;
    }

    /*
       Не меньше 16px —
       предотвращает автоматический zoom Safari iOS
    */
    .form-field input[type="text"],
    .form-field textarea {
        font-size: 20px;
    }

    .guest-counter {
        width: 100%;
    }

    .submit-button {
        min-height: 94px;

        padding:
            18px 20px;
    }


    /* FOOTER */

    .footer {
        padding-left: 8px;
        padding-right: 16px;
    }

    .footer h2 {
        font-size:
            clamp(62px, 20vw, 120px);

        line-height: 0.72;
    }

    .footer__bottom {
        flex-direction: column;
        align-items: center;

        gap: 22px;

        text-align: center;
    }

}


/* =========================================================
   SMALL PHONES
========================================================= */

@media (max-width: 380px) {

    .hero__title {
        font-size:
            clamp(64px, 26vw, 96px);
    }

    .hero__ampersand {
        font-size:
            clamp(72px, 29vw, 110px);
    }

    .dress__heading {
        font-size:
            clamp(82px, 25vw, 115px);
    }

    .details__title {
        font-size:
            clamp(58px, 19vw, 85px);
    }

    .rsvp__header h2 {
        font-size:
            clamp(58px, 19vw, 82px);
    }

}


/* =========================================================
   MOBILE LANDSCAPE
========================================================= */

@media
(max-height: 620px)
and (orientation: landscape) {

    .cover {
        padding-top: 12px;
        padding-bottom: 12px;
    }

    .cover__top,
    .cover__bottom {
        font-size: 8px;
    }

    .envelope {
        width:
            min(
                55vw,
                420px,
                calc(55dvh * 1.48)
            );
    }

    .seal {
        width: 92px;
        height: 92px;
    }

    .seal__circle {
        width: 60px;
        height: 60px;
    }

    .seal__text {
        top:
            calc(50% + 39px);

        font-size: 7px;
    }

}


/* =========================================================
   TOUCH DEVICES
========================================================= */

@media (hover: none) {

    .palette__color:hover {
        transform: none;
    }

    .choice:hover span {
        transform: none;

        border-color:
            rgba(255, 255, 255, 0.3);
    }

}


/* =========================================================
   REDUCED MOTION
========================================================= */

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

    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;

        transition-duration: 0.01ms !important;

        scroll-behavior: auto !important;
    }

    .reveal {
        opacity: 1;

        transform: none;
    }

}

/* =========================================================
   RESPONSIVE FIX
   SCREEN /02 — PROGRAM
   SCREEN /04 — DETAILS
========================================================= */


/* =========================================================
   /02 — PROGRAM
========================================================= */

.schedule {
    width: 100%;
    overflow: hidden;
}

.schedule__header {
    width: 100%;

    display: grid;
    grid-template-columns:
        minmax(100px, 0.55fr)
        minmax(0, 2fr);

    gap:
        clamp(30px, 6vw, 90px);

    align-items: start;
}

.schedule__header > p {
    max-width: 150px;
}

.schedule__header h2 {
    min-width: 0;
    max-width: 100%;

    font-size:
        clamp(64px, 13vw, 220px);

    line-height: 0.72;
    letter-spacing: -0.085em;

    overflow-wrap: normal;
    word-break: normal;
}

.schedule__header h2 em {
    display: block;

    margin-top: 0.08em;

    font-size: 0.9em;

    text-align: right;
}


/* Timeline */

.timeline {
    width: 100%;
}

.timeline__item {
    width: 100%;

    display: grid;

    grid-template-columns:
        minmax(100px, 0.6fr)
        minmax(56px, 80px)
        minmax(0, 2fr);

    gap:
        clamp(20px, 4vw, 65px);

    align-items: start;
}

.timeline__time {
    min-width: 0;

    font-size:
        clamp(34px, 4.7vw, 68px);

    line-height: 1;
}

.timeline__circle {
    flex-shrink: 0;
}

.timeline__content {
    min-width: 0;
}

.timeline__content h3 {
    max-width: 100%;

    font-size:
        clamp(28px, 4vw, 54px);

    line-height: 1;

    overflow-wrap: break-word;
}

.timeline__content p {
    width: 100%;
    max-width: 520px;
}


/* =========================================================
   /04 — DETAILS
========================================================= */

.details {
    width: 100%;
    overflow: hidden;
}

.details__title {
    width: 100%;
    max-width: 100%;

    font-size:
        clamp(65px, 14vw, 220px);

    line-height: 0.75;
    letter-spacing: -0.085em;

    overflow-wrap: normal;
    word-break: normal;
}

.details__title em {
    display: block;

    margin-top: 0.07em;

    font-size: 0.92em;

    text-align: right;
}

.details__cards {
    width: 100%;
}

.detail-card {
    width: 100%;

    display: grid;

    grid-template-columns:
        minmax(45px, 70px)
        minmax(160px, 0.8fr)
        minmax(0, 1.3fr);

    gap:
        clamp(20px, 4vw, 70px);

    align-items: start;
}

.detail-card__number {
    min-width: 0;
}

.detail-card h3 {
    min-width: 0;
    max-width: 100%;

    font-size:
        clamp(30px, 4.5vw, 64px);

    line-height: 0.95;

    overflow-wrap: break-word;
}

.detail-card p {
    width: 100%;
    max-width: 520px;

    overflow-wrap: break-word;
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 1024px) {

    /* /02 */

    .schedule__header {
        grid-template-columns:
            minmax(90px, 0.4fr)
            minmax(0, 2fr);
    }

    .schedule__header h2 {
        font-size:
            clamp(62px, 13vw, 145px);
    }

    .timeline__item {
        grid-template-columns:
            minmax(90px, 0.5fr)
            62px
            minmax(0, 2fr);

        gap:
            clamp(20px, 3.5vw, 45px);
    }


    /* /04 */

    .details__title {
        font-size:
            clamp(65px, 14vw, 150px);
    }

    .detail-card {
        grid-template-columns:
            50px
            minmax(140px, 0.8fr)
            minmax(0, 1.25fr);

        gap:
            clamp(20px, 3vw, 40px);
    }

}


/* =========================================================
   SMALL TABLET
========================================================= */

@media (max-width: 800px) {

    /* =========================
       /02
    ========================== */

    .schedule__header {
        grid-template-columns: 1fr;

        gap: 35px;

        margin-bottom:
            clamp(70px, 12vw, 110px);
    }

    .schedule__header > p {
        max-width: none;
    }

    .schedule__header h2 {
        width: 100%;

        font-size:
            clamp(62px, 17vw, 125px);

        line-height: 0.73;
    }

    .schedule__header h2 em {
        padding-right: 5%;
    }


    .timeline__item {
        grid-template-columns:
            minmax(0, 1fr)
            58px;

        grid-template-areas:
            "time number"
            "content content";

        gap:
            20px;

        padding:
            32px 0;
    }

    .timeline__time {
        grid-area: time;

        align-self: center;

        font-size:
            clamp(38px, 8vw, 58px);
    }

    .timeline__circle {
        grid-area: number;

        justify-self: end;

        width: 56px;
        height: 56px;
    }

    .timeline__content {
        grid-area: content;

        padding-top: 10px;
    }

    .timeline__content h3 {
        font-size:
            clamp(30px, 7vw, 48px);
    }

    .timeline__content p {
        max-width: 600px;
    }


    /* =========================
       /04
    ========================== */

    .details__title {
        font-size:
            clamp(64px, 17vw, 125px);

        line-height: 0.76;

        margin-bottom:
            clamp(70px, 13vw, 120px);
    }

    .details__title em {
        padding-right: 4%;
    }


    .detail-card {
        grid-template-columns:
            52px
            minmax(0, 1fr);

        grid-template-areas:
            "number title"
            ". text";

        gap:
            16px 24px;

        padding:
            32px 0;
    }

    .detail-card__number {
        grid-area: number;

        padding-top: 8px;
    }

    .detail-card h3 {
        grid-area: title;

        font-size:
            clamp(32px, 7vw, 52px);

        line-height: 1;
    }

    .detail-card p {
        grid-area: text;

        width: 100%;
        max-width: 600px;
    }

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 640px) {

    /* =========================
       /02 PROGRAM
    ========================== */

    .schedule {
        padding-left: 16px;
        padding-right: 16px;
    }

    .schedule .section-number {
        margin-bottom: 45px;
    }

    .schedule__header {
        gap: 28px;

        margin-bottom: 70px;
    }

    .schedule__header > p {
        font-size: 9px;
        line-height: 1.4;
    }

    .schedule__header h2 {
        /*
         * Ключевой фикс:
         * надпись теперь всегда входит
         * в ширину телефона
         */
        font-size:
            clamp(52px, 18.2vw, 100px);

        line-height: 0.76;
        letter-spacing: -0.07em;
    }

    .schedule__header h2 em {
        margin-top: 4px;

        padding-right: 2%;

        font-size: 0.92em;
    }


    .timeline__item {
        gap: 18px;

        padding:
            28px 0 30px;
    }

    .timeline__time {
        font-size:
            clamp(35px, 10vw, 48px);
    }

    .timeline__circle {
        width: 50px;
        height: 50px;

        font-size: 8px;
    }

    .timeline__content {
        padding-top: 4px;
    }

    .timeline__content span {
        margin-bottom: 10px;

        font-size: 8px;
    }

    .timeline__content h3 {
        margin-bottom: 13px;

        font-size:
            clamp(29px, 8.5vw, 43px);

        line-height: 0.98;
    }

    .timeline__content p {
        font-size: 14px;

        line-height: 1.52;
    }


    /* =========================
       /04 DETAILS
    ========================== */

    .details {
        padding-left: 16px;
        padding-right: 16px;
    }

    .details .section-number {
        margin-bottom: 45px;
    }

    .details__title {
        font-size:
            clamp(52px, 14vw, 96px);

        line-height: 0.78;
        letter-spacing: -0.07em;

        margin-bottom: 75px;
    }

    .details__title em {
        margin-top: 5px;

        padding-right: 2%;
    }


    .detail-card {
        grid-template-columns:
            38px
            minmax(0, 1fr);

        gap:
            13px 15px;

        padding:
            27px 0;
    }

    .detail-card__number {
        padding-top: 5px;

        font-size: 9px;
    }

    .detail-card h3 {
        font-size:
            clamp(29px, 9vw, 42px);

        line-height: 1;
    }

    .detail-card p {
        font-size: 14px;

        line-height: 1.52;
    }

}


/* =========================================================
   SMALL PHONES
   320px — 390px
========================================================= */

@media (max-width: 390px) {

    /* /02 */

    .schedule {
        padding-left: 14px;
        padding-right: 14px;
    }

    .schedule__header h2 {
        font-size:
            clamp(48px, 17.5vw, 68px);

        letter-spacing: -0.065em;
    }

    .timeline__time {
        font-size: 34px;
    }

    .timeline__circle {
        width: 46px;
        height: 46px;
    }

    .timeline__content h3 {
        font-size:
            clamp(27px, 8.5vw, 34px);
    }


    /* /04 */

    .details {
        padding-left: 14px;
        padding-right: 14px;
    }

    .details__title {
        font-size:
            clamp(48px, 14vw, 68px);
    }

    .detail-card {
        grid-template-columns:
            32px
            minmax(0, 1fr);

        gap:
            12px;
    }

    .detail-card h3 {
        font-size:
            clamp(27px, 8.5vw, 34px);
    }

}


/* =========================================================
   VERY SMALL PHONES
   280px — 340px
========================================================= */

@media (max-width: 340px) {

    /* /02 */

    .schedule__header h2 {
        font-size:
            clamp(44px, 17vw, 58px);
    }

    .timeline__item {
        grid-template-columns:
            minmax(0, 1fr)
            42px;
    }

    .timeline__circle {
        width: 42px;
        height: 42px;
    }

    .timeline__time {
        font-size: 30px;
    }


    /* /04 */

    .details__title {
        font-size:
            clamp(44px, 17vw, 58px);
    }

    .detail-card {
        grid-template-columns: 1fr;

        grid-template-areas:
            "number"
            "title"
            "text";

        gap: 10px;
    }

    .detail-card__number {
        padding-top: 0;
    }

}

/* =========================================================
   FINAL FIX — /02 ПРОГРАММА ДНЯ
========================================================= */

.schedule {
    overflow: hidden;
}

.schedule__header {
    min-width: 0;
}

.schedule__header h2 {
    width: 100%;
    max-width: 100%;

    margin: 0;

    font-size: clamp(52px, 10.8vw, 185px);
    line-height: 0.72;

    letter-spacing: -0.085em;

    white-space: nowrap;

    overflow: visible;

    word-break: normal;
    overflow-wrap: normal;
}

.schedule__header h2 em {
    display: block;

    width: 100%;

    margin-top: 0.08em;

    text-align: right;

    font-size: 0.9em;

    white-space: nowrap;
}


/* =========================================================
   TABLET
========================================================= */

@media (max-width: 900px) {

    .schedule__header {
        grid-template-columns: 1fr;
    }

    .schedule__header h2 {
        font-size: clamp(52px, 13.5vw, 115px);
    }

}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 640px) {

    .schedule {
        padding-left: 16px;
        padding-right: 16px;
    }

    .schedule__header {
        width: 100%;

        gap: 25px;

        margin-bottom: 70px;
    }

    .schedule__header h2 {
        /*
         * Главный фикс.
         * На 390px ≈ 56px
         * На 375px ≈ 54px
         * На 320px ≈ 46px
         */
        font-size: clamp(44px, 14.4vw, 82px);

        line-height: 0.75;
        letter-spacing: -0.075em;

        white-space: nowrap;
    }

    .schedule__header h2 em {
        font-size: 0.92em;

        padding-right: 2%;
    }

}


/* =========================================================
   390px И МЕНЬШЕ
========================================================= */

@media (max-width: 390px) {

    .schedule {
        padding-left: 14px;
        padding-right: 14px;
    }

    .schedule__header h2 {
        font-size: clamp(42px, 14vw, 55px);
    }

}


/* =========================================================
   340px И МЕНЬШЕ
========================================================= */

@media (max-width: 340px) {

    .schedule {
        padding-left: 12px;
        padding-right: 12px;
    }

    .schedule__header h2 {
        font-size: clamp(40px, 13.7vw, 48px);

        letter-spacing: -0.08em;
    }

}


/* =========================================================
   ОЧЕНЬ УЗКИЕ ЭКРАНЫ
========================================================= */

@media (max-width: 300px) {

    .schedule__header h2 {
        font-size: 38px;
    }

}