/* ==========================================================================
   UB Heritage — Thank You page
   assets/css/thank-you.css
   Loaded only on page-thank-you.php
   ========================================================================== */

.ubh-ty {
    --ty-gold: var(--color-gold, #d2ab67);
    --ty-title: 64px;
    --ty-eyebrow: 14px;
    --ty-text: 18px;
    --ty-pad-block: 180px;
    --ty-mark: 64px;
    --ty-gap: 28px;

    display: block;
    background-color: #0d0d0d;
}

/* --------------------------------------------------------------------------
   Section — full-bleed background image (never an <img> tag)
   -------------------------------------------------------------------------- */
.ubh-ty__section {
    position: relative;
    isolation: isolate;
    background-color: #0d0d0d;
    background-image: var(--ty-bg-d, none);
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
    padding-block: var(--ty-pad-block);
    min-height: 72vh;
    display: flex;
    align-items: center;
}

.ubh-ty__section::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.55) 45%, rgba(0, 0, 0, 0.78) 100%);
    pointer-events: none;
}

.ubh-ty .ubh-container {
    width: 100%;
    max-width: var(--container, 1820px);
    margin-inline: auto;
    padding-inline: var(--gutter, 50px);
}

.ubh-ty__row {
    display: flex;
    justify-content: center;
}

.ubh-ty__inner {
    width: 100%;
    max-width: 820px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--ty-gap);
}

/* --------------------------------------------------------------------------
   Tick mark
   -------------------------------------------------------------------------- */
.ubh-ty__mark {
    display: inline-flex;
    color: var(--ty-gold);
    line-height: 0;
    opacity: 0;
    transform: translateY(14px);
    animation: ubh-ty-in 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) 0.05s forwards;
}

.ubh-ty__mark svg {
    width: var(--ty-mark);
    height: var(--ty-mark);
    display: block;
}

.ubh-ty__mark circle {
    stroke-dasharray: 195;
    stroke-dashoffset: 195;
    animation: ubh-ty-draw 1.1s ease-out 0.25s forwards;
}

.ubh-ty__mark path {
    stroke-dasharray: 44;
    stroke-dashoffset: 44;
    animation: ubh-ty-draw 0.6s ease-out 0.95s forwards;
}

/* --------------------------------------------------------------------------
   Type
   -------------------------------------------------------------------------- */
.ubh-ty__eyebrow {
    font-family: var(--font-body, "Avenir", sans-serif);
    font-weight: 800;
    font-size: var(--ty-eyebrow);
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--ty-gold);
    margin: 0;
    opacity: 0;
    transform: translateY(14px);
    animation: ubh-ty-in 0.7s cubic-bezier(0.22, 0.61, 0.36, 1) 0.18s forwards;
}

.ubh-ty__title {
    font-family: var(--font-display, "IvyBodoni", serif);
    font-style: italic;
    font-weight: 400;
    font-size: var(--ty-title);
    line-height: 1.15;
    color: #ffffff;
    margin: 0;
    opacity: 0;
    transform: translateY(14px);
    animation: ubh-ty-in 0.8s cubic-bezier(0.22, 0.61, 0.36, 1) 0.3s forwards;
}

.ubh-ty__rule {
    display: block;
    width: 90px;
    height: 1px;
    background: var(--ty-gold);
    opacity: 0;
    animation: ubh-ty-rule 0.8s cubic-bezier(0.22, 0.61, 0.36, 1) 0.45s forwards;
    transform-origin: center;
}

.ubh-ty__text {
    font-family: var(--font-body, "Avenir", sans-serif);
    font-weight: 400;
    font-size: var(--ty-text);
    line-height: 1.75;
    color: rgba(255, 255, 255, 0.78);
    margin: 0;
    max-width: 640px;
    opacity: 0;
    transform: translateY(14px);
    animation: ubh-ty-in 0.8s cubic-bezier(0.22, 0.61, 0.36, 1) 0.55s forwards;
}

/* --------------------------------------------------------------------------
   Manual download link (brochure only)
   -------------------------------------------------------------------------- */
.ubh-ty__download {
    margin: -6px 0 0;
    opacity: 0;
    transform: translateY(14px);
    animation: ubh-ty-in 0.8s cubic-bezier(0.22, 0.61, 0.36, 1) 0.65s forwards;
}

.ubh-ty__dl-link {
    font-family: var(--font-body, "Avenir", sans-serif);
    font-weight: 800;
    font-size: 14px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ty-gold);
    text-decoration: none;
    border-bottom: 1px solid rgba(210, 171, 103, 0.45);
    padding-bottom: 4px;
    transition: border-color 0.3s ease, color 0.3s ease;
}

.ubh-ty__dl-link:hover,
.ubh-ty__dl-link:focus-visible {
    color: #ffffff;
    border-bottom-color: #ffffff;
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */
.ubh-ty__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 18px;
    margin-top: 10px;
    opacity: 0;
    transform: translateY(14px);
    animation: ubh-ty-in 0.8s cubic-bezier(0.22, 0.61, 0.36, 1) 0.75s forwards;
}

.ubh-ty__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 220px;
    padding: 17px 38px;
    font-family: var(--font-body, "Avenir", sans-serif);
    font-weight: 800;
    font-size: 13px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    text-decoration: none;
    border: 1px solid var(--ty-gold);
    transition: background-color 0.35s ease, color 0.35s ease, border-color 0.35s ease;
}

.ubh-ty__btn--solid {
    background-color: var(--ty-gold);
    color: #0d0d0d;
}

.ubh-ty__btn--solid:hover,
.ubh-ty__btn--solid:focus-visible {
    background-color: transparent;
    color: var(--ty-gold);
}

.ubh-ty__btn--ghost {
    background-color: transparent;
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.45);
}

.ubh-ty__btn--ghost:hover,
.ubh-ty__btn--ghost:focus-visible {
    background-color: var(--ty-gold);
    border-color: var(--ty-gold);
    color: #0d0d0d;
}

/* --------------------------------------------------------------------------
   Animations
   -------------------------------------------------------------------------- */
@keyframes ubh-ty-in {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes ubh-ty-rule {
    to {
        opacity: 1;
    }
}

@keyframes ubh-ty-draw {
    to {
        stroke-dashoffset: 0;
    }
}

@media (prefers-reduced-motion: reduce) {

    .ubh-ty__mark,
    .ubh-ty__eyebrow,
    .ubh-ty__title,
    .ubh-ty__rule,
    .ubh-ty__text,
    .ubh-ty__download,
    .ubh-ty__actions {
        opacity: 1;
        transform: none;
        animation: none;
    }

    .ubh-ty__mark circle,
    .ubh-ty__mark path {
        stroke-dashoffset: 0;
        animation: none;
    }
}

/* --------------------------------------------------------------------------
   Responsive — stepped
   -------------------------------------------------------------------------- */
@media (max-width: 1440px) {

    .ubh-ty {
        --ty-title: 56px;
        --ty-pad-block: 160px;
    }
}

@media (max-width: 1200px) {

    .ubh-ty {
        --ty-title: 46px;
        --ty-text: 17px;
        --ty-pad-block: 130px;
        --ty-mark: 58px;
        --ty-gap: 24px;
    }

    .ubh-ty .ubh-container {
        padding-inline: 40px;
    }

    .ubh-ty__section {
        background-image: var(--ty-bg-m, none);
        min-height: 68vh;
    }
}

@media (max-width: 1024px) {

    .ubh-ty {
        --ty-title: 40px;
        --ty-pad-block: 110px;
    }

    .ubh-ty .ubh-container {
        padding-inline: 32px;
    }
}

@media (max-width: 768px) {

    .ubh-ty {
        --ty-title: 34px;
        --ty-eyebrow: 12px;
        --ty-text: 16px;
        --ty-pad-block: 90px;
        --ty-mark: 50px;
        --ty-gap: 20px;
    }

    .ubh-ty .ubh-container {
        padding-inline: 24px;
    }

    .ubh-ty__actions {
        gap: 14px;
    }

    .ubh-ty__btn {
        min-width: 0;
        width: 100%;
        padding: 16px 28px;
    }
}

@media (max-width: 425px) {

    .ubh-ty {
        --ty-title: 29px;
        --ty-text: 15px;
        --ty-pad-block: 74px;
        --ty-mark: 46px;
    }

    .ubh-ty .ubh-container {
        padding-inline: 20px;
    }

    .ubh-ty__rule {
        width: 64px;
    }

    .ubh-ty__btn {
        font-size: 12px;
        letter-spacing: 0.14em;
    }
}