/**
 * Packages & Gifts page redesign — "Wrapped" (page 52650 only).
 *
 * Markup: wp:html sections inside an alignfull .tsa-pg group in the page
 * content. Pure CSS animations (gift-tag sway, floating product shots) —
 * no JS. Prices in copy come from the [tsa_pg_price] shortcode.
 */

.tsa-pg {
    --pg-cream: #F6EFE3;
    --pg-paper: #EDE3D0;
    --pg-pine: #12403F;
    --pg-ochre: #C77E22;
    --pg-amber: #E39A3B;
    --pg-gold: #E9B96A;
    --pg-clay: #C25B4A;
    --pg-green: #4E8A47;
    --pg-ink: #22312C;
    --pg-body-color: rgba(34, 49, 44, 0.75);
    --pg-head-font: var(--tsa-font-display);
    --pg-body-font: var(--tsa-font-body);
    --pg-pad-x: clamp(20px, 4vw, 48px);
    background: var(--pg-cream);
    color: var(--pg-ink);
    font-family: var(--pg-body-font);
    overflow: hidden;
}

.tsa-pg ::selection {
    background: var(--pg-pine);
    color: var(--pg-cream);
}

.tsa-pg a {
    text-decoration: none;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.tsa-pg h1,
.tsa-pg h2,
.tsa-pg h3 {
    font-family: var(--pg-head-font);
    font-weight: var(--tsa-font-display-weight, 800);
    padding: 0;
    color: var(--pg-pine);
}

.tsa-pg img {
    max-width: 100%;
    height: auto;
}

.tsa-pg .tsa-pg-wrap {
    max-width: 1280px;
    margin: 0 auto;
}

/* Buttons -------------------------------------------------------------- */

.tsa-pg .tsa-pg-btn {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 15px;
    line-height: 1.2;
}

.tsa-pg .tsa-pg-btn--pine {
    background: var(--pg-pine);
    color: var(--pg-cream);
}

.tsa-pg .tsa-pg-btn--pine:hover {
    background: var(--pg-amber);
    color: var(--pg-pine);
}

.tsa-pg .tsa-pg-btn--outline {
    border: 1.5px solid var(--pg-pine);
    color: var(--pg-pine);
}

.tsa-pg .tsa-pg-btn--outline:hover {
    background: var(--pg-pine);
    color: var(--pg-cream);
}

/* Animations ----------------------------------------------------------- */

@keyframes tsaPgSway {
    0%, 100% { transform: rotate(-3deg); }
    50% { transform: rotate(3.5deg); }
}

@keyframes tsaPgFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-9px); }
}

@media (prefers-reduced-motion: reduce) {
    .tsa-pg .tsa-pg-tag,
    .tsa-pg .tsa-pg-row__media img {
        animation: none !important;
    }
}

/* Hero ------------------------------------------------------------------ */

.tsa-pg .tsa-pg-hero {
    padding: calc(var(--wp--custom--header-height, 83px) + clamp(48px, 6vw, 76px)) var(--pg-pad-x) clamp(64px, 8vw, 100px);
    max-width: calc(1280px + 2 * var(--pg-pad-x));
    margin: 0 auto;
    box-sizing: border-box;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: clamp(36px, 5vw, 72px);
    align-items: center;
}

.tsa-pg .tsa-pg-tag {
    display: inline-block;
    background: var(--pg-clay);
    color: var(--pg-cream);
    font-family: var(--pg-head-font);
  font-weight: var(--tsa-font-display-weight, 800);
    font-size: 13px;
    letter-spacing: 0.1em;
    padding: 9px 18px 9px 26px;
    border-radius: 6px;
    margin-bottom: 26px;
    clip-path: polygon(12px 0, 100% 0, 100% 100%, 12px 100%, 0 50%);
    box-shadow: 0 8px 20px rgba(194, 91, 74, 0.35);
    transform: rotate(-3deg);
    transform-origin: 0 50%;
    animation: tsaPgSway 5s ease-in-out infinite;
}

.tsa-pg .tsa-pg-hero h1 {
    font-size: clamp(2.8rem, 5.6vw, 5.4rem);
    line-height: 1;
    letter-spacing: -0.01em;
    margin: 0 0 24px;
    text-wrap: balance;
}

.tsa-pg .tsa-pg-hero h1 em {
    font-style: normal;
    color: var(--pg-ochre);
}

.tsa-pg .tsa-pg-hero__copy > p {
    font-size: 18px;
    line-height: 1.7;
    color: var(--pg-body-color);
    max-width: 50ch;
    margin: 0 0 34px;
}

.tsa-pg .tsa-pg-hero__actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.tsa-pg .tsa-pg-hero__media {
    position: relative;
}

.tsa-pg .tsa-pg-hero__media > img {
    width: 100%;
    display: block;
    border-radius: 22px;
    aspect-ratio: 4 / 3.4;
    object-fit: cover;
    box-shadow: 0 22px 54px rgba(18, 64, 63, 0.22);
}

.tsa-pg .tsa-pg-hangtag {
    position: absolute;
    top: -16px;
    right: 26px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.tsa-pg .tsa-pg-hangtag__string {
    width: 2px;
    height: 38px;
    background: var(--pg-ochre);
    display: block;
}

.tsa-pg .tsa-pg-hangtag__label {
    background: var(--pg-cream);
    border: 2px solid var(--pg-ochre);
    border-radius: 10px;
    padding: 10px 16px;
    font-family: var(--pg-head-font);
  font-weight: var(--tsa-font-display-weight, 800);
    font-size: 13px;
    color: var(--pg-pine);
    transform: rotate(4deg);
    box-shadow: 0 10px 24px rgba(18, 64, 63, 0.15);
    white-space: nowrap;
}

/* Ticker strip ----------------------------------------------------------- */

.tsa-pg .tsa-pg-ticker {
    background: var(--pg-pine);
    padding: 15px var(--pg-pad-x);
    text-align: center;
    font-family: var(--pg-head-font);
  font-weight: var(--tsa-font-display-weight, 800);
    font-size: 15px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--pg-gold);
}

/* Section headings -------------------------------------------------------- */

.tsa-pg .tsa-pg-section {
    padding: clamp(72px, 9vw, 100px) var(--pg-pad-x) clamp(40px, 5vw, 60px);
    max-width: calc(1280px + 2 * var(--pg-pad-x));
    margin: 0 auto;
    box-sizing: border-box;
    scroll-margin-top: 24px;
}

.tsa-pg .tsa-pg-headline {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: clamp(36px, 4.5vw, 52px);
}

.tsa-pg .tsa-pg-headline h2 {
    font-size: clamp(2rem, 3.6vw, 3.25rem);
    margin: 0;
    line-height: 1;
    white-space: nowrap;
}

.tsa-pg .tsa-pg-headline .tsa-pg-rule {
    flex: 1;
    height: 2px;
    background-image: repeating-linear-gradient(90deg, var(--pg-ochre) 0, var(--pg-ochre) 8px, transparent 8px, transparent 15px);
}

/* Gift Adventure rows ------------------------------------------------------ */

.tsa-pg .tsa-pg-row {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: clamp(32px, 4.5vw, 64px);
    align-items: center;
    margin-bottom: clamp(64px, 7vw, 88px);
}

.tsa-pg .tsa-pg-row:last-child {
    margin-bottom: 0;
}

.tsa-pg .tsa-pg-row--textfirst {
    grid-template-columns: 0.9fr 1.1fr;
}

.tsa-pg .tsa-pg-row__media img {
    width: 100%;
    display: block;
    border-radius: 20px;
    box-shadow: 0 18px 44px rgba(18, 64, 63, 0.18);
    animation: tsaPgFloat 7s ease-in-out infinite;
}

.tsa-pg .tsa-pg-row--textfirst .tsa-pg-row__media img {
    animation-duration: 8s;
    animation-delay: 1s;
}

.tsa-pg .tsa-pg-row:nth-of-type(3) .tsa-pg-row__media img {
    animation-duration: 7.5s;
    animation-delay: 2s;
}

.tsa-pg .tsa-pg-eyebrow {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--pg-ochre);
    margin-bottom: 12px;
}

.tsa-pg .tsa-pg-eyebrow--clay { color: var(--pg-clay); }
.tsa-pg .tsa-pg-eyebrow--green { color: var(--pg-green); }

.tsa-pg .tsa-pg-row h3 {
    font-size: clamp(1.6rem, 2.4vw, 2rem);
    margin: 0 0 16px;
    line-height: 1.1;
}

.tsa-pg .tsa-pg-row p {
    font-size: 16px;
    line-height: 1.75;
    color: var(--pg-body-color);
    margin: 0 0 12px;
}

.tsa-pg .tsa-pg-note {
    display: inline-block;
    background: rgba(199, 126, 34, 0.14);
    border: 1.5px dashed var(--pg-ochre);
    border-radius: 10px;
    padding: 9px 16px;
    font-weight: 700;
    font-size: 13.5px;
    color: #8A5716;
    margin: 8px 0 26px;
}

.tsa-pg .tsa-pg-note--green {
    background: rgba(78, 138, 71, 0.14);
    border-color: var(--pg-green);
    color: #33602E;
}

/* Gift Connection (dark) --------------------------------------------------- */

.tsa-pg .tsa-pg-connection {
    background: var(--pg-pine);
    padding: clamp(72px, 9vw, 100px) var(--pg-pad-x);
    margin-top: clamp(40px, 5vw, 60px);
    scroll-margin-top: 24px;
}

.tsa-pg .tsa-pg-connection .tsa-pg-headline h2 {
    color: var(--pg-cream);
}

.tsa-pg .tsa-pg-connection .tsa-pg-headline .tsa-pg-rule {
    background-image: repeating-linear-gradient(90deg, rgba(233, 185, 106, 0.7) 0, rgba(233, 185, 106, 0.7) 8px, transparent 8px, transparent 15px);
}

.tsa-pg .tsa-pg-connection .tsa-pg-headline {
    margin-bottom: 20px;
}

.tsa-pg .tsa-pg-connection__intro {
    font-size: 17px;
    line-height: 1.6;
    color: rgba(246, 239, 227, 0.75);
    max-width: 60ch;
    margin: 0 0 56px;
}

.tsa-pg .tsa-pg-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
    gap: 28px;
}

.tsa-pg .tsa-pg-card {
    background: var(--pg-cream);
    border-radius: 24px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.25);
}

.tsa-pg .tsa-pg-card > img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    display: block;
}

.tsa-pg .tsa-pg-card > img.tsa-pg-card__img--contain {
    object-fit: contain;
    background: var(--pg-paper);
    padding: 12px;
    box-sizing: border-box;
}

.tsa-pg .tsa-pg-card__body {
    padding: 28px 30px 30px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
}

.tsa-pg .tsa-pg-card h3 {
    font-size: 1.5rem;
    margin: 0;
    line-height: 1.15;
}

.tsa-pg .tsa-pg-card p {
    margin: 0;
    font-size: 15px;
    line-height: 1.7;
    color: var(--pg-body-color);
    flex: 1;
}

.tsa-pg .tsa-pg-card .tsa-pg-btn {
    align-self: flex-start;
    padding: 12px 26px;
    font-size: 14px;
}

/* Responsive ---------------------------------------------------------------- */

@media (max-width: 900px) {
    .tsa-pg .tsa-pg-hero,
    .tsa-pg .tsa-pg-row,
    .tsa-pg .tsa-pg-row--textfirst {
        grid-template-columns: 1fr;
    }

    .tsa-pg .tsa-pg-row--textfirst .tsa-pg-row__media {
        order: -1;
    }

    .tsa-pg .tsa-pg-headline h2 {
        white-space: normal;
    }

    .tsa-pg .tsa-pg-hangtag {
        right: 14px;
    }
}

/* ---------------------------------------------------------------------------
 * Footer recolour — Wrapped palette (page 52650 only)
 * ------------------------------------------------------------------------- */

body.page-id-52650 footer.wp-block-template-part .has-darktext-background-color {
    background-color: #E39A3B !important;
}

body.page-id-52650 footer.wp-block-template-part .has-darktext-background-color .has-white-color,
body.page-id-52650 footer.wp-block-template-part .has-darktext-background-color h3,
body.page-id-52650 footer.wp-block-template-part .has-darktext-background-color p,
body.page-id-52650 footer.wp-block-template-part .has-darktext-background-color label,
body.page-id-52650 footer.wp-block-template-part .has-darktext-background-color .gfield_required_text {
    color: #12403F !important;
}

body.page-id-52650 footer.wp-block-template-part .gform_wrapper input:not([type="radio"]):not([type="checkbox"]):not([type="submit"]):not([type="button"]):not([type="image"]):not([type="file"]):not([type="hidden"]),
body.page-id-52650 footer.wp-block-template-part .gform_wrapper select,
body.page-id-52650 footer.wp-block-template-part .gform_wrapper textarea {
    background-color: #F6EFE3 !important;
    color: #12403F !important;
    border-color: rgba(18, 64, 63, 0.35) !important;
}

body.page-id-52650 footer.wp-block-template-part .gform_wrapper input::placeholder,
body.page-id-52650 footer.wp-block-template-part .gform_wrapper textarea::placeholder {
    color: rgba(18, 64, 63, 0.6) !important;
    opacity: 1 !important;
}

body.page-id-52650 footer.wp-block-template-part .gform_wrapper .gfield_label,
body.page-id-52650 footer.wp-block-template-part .gform_wrapper legend,
body.page-id-52650 footer.wp-block-template-part .gform_wrapper .gfield_description {
    color: #12403F !important;
}

body.page-id-52650 footer.wp-block-template-part .gform_wrapper .gform_button {
    background-color: #12403F !important;
    color: #F6EFE3 !important;
}

body.page-id-52650 footer.wp-block-template-part .gform_wrapper .gform_button:hover {
    background-color: #F6EFE3 !important;
    color: #12403F !important;
    opacity: 1 !important;
}

body.page-id-52650 footer.wp-block-template-part .footer-container.has-background-dark-background-color {
    background-color: #12403F !important;
}

body.page-id-52650 footer.wp-block-template-part .footer-container a:hover {
    color: #E9B96A;
}

body.page-id-52650 footer.wp-block-template-part .wp-block-cover.is-light .wp-block-cover__image-background {
    display: none !important;
}

body.page-id-52650 footer.wp-block-template-part .wp-block-cover.is-light {
    background: #F6EFE3;
}

body.page-id-52650 footer.wp-block-template-part .wp-block-cover.is-light .wp-block-cover__background {
    background-color: #F6EFE3 !important;
}
