/*
 * Theme Name:THRYVE CUSTOM ITCS
 * Theme URI: https://thryve.itcs.uk
 * Author: ITCS UK LTD
 * Description: High-end wellness clinic theme
 * Version: 2.4.26
 * Text Domain: thryve-custom-itcs
 */

/* ==========================================================================
   Global reset – consistent rendering across all browsers
   ========================================================================== */

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

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    overflow-x: hidden;
}

.screen-reader-text {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}

.skip-link:focus {
    position: fixed !important;
    top: 0.75rem;
    left: 0.75rem;
    z-index: 10100;
    width: auto;
    height: auto;
    margin: 0;
    padding: 0.8rem 1rem;
    overflow: visible;
    clip: auto;
    clip-path: none;
    white-space: normal;
    background: #fff;
    color: #3f2a1e;
    border: 2px solid #3f2a1e;
}

:where(a, button, input, select, textarea, [tabindex]):focus-visible {
    outline: 3px solid currentColor;
    outline-offset: 3px;
}

.site-main > section:first-of-type.bg-primary.text-white {
    background-color: #3f2a1e !important;
    padding-top: 2.25rem !important;
    padding-bottom: 2.25rem !important;
}

.site-main > section:first-of-type.bg-primary.text-white [class*="bg-primary/75"] {
    background-color: rgba(63, 42, 30, 0.78) !important;
}

.site-main > section:first-of-type.bg-primary.text-white h1 {
    font-size: clamp(2.35rem, 3.9vw, 3.55rem) !important;
    line-height: 1 !important;
    margin-bottom: 0.55rem !important;
}

.site-main > section:first-of-type.bg-primary.text-white p[class*="tracking"] {
    margin-bottom: 0.45rem !important;
}

@media (min-width: 768px) {
    .site-main > section:first-of-type.bg-primary.text-white {
        padding-top: 2.55rem !important;
        padding-bottom: 2.55rem !important;
    }
}

@media (max-width: 767px) {
    .site-main > section:first-of-type.bg-primary.text-white {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }
}

/* Mega menu interaction polish: smooth open/close with forgiving hover movement */
@media (hover: hover) and (pointer: fine) and (min-width: 1280px) {

    #treatmentsModal,
    #aboutModal {
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: opacity 260ms ease, visibility 260ms ease;
    }

    #treatmentsModal.mega-menu-open,
    #aboutModal.mega-menu-open {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    #treatmentsModal .modal-overlay,
    #aboutModal .modal-overlay {
        transition: opacity 260ms ease, backdrop-filter 260ms ease;
    }

    #treatmentsModal:not(.mega-menu-open) .modal-overlay,
    #aboutModal:not(.mega-menu-open) .modal-overlay {
        opacity: 0;
        backdrop-filter: blur(0);
    }

    #treatmentsModal .bg-secondary.text-dark,
    #aboutModal .bg-secondary.text-dark {
        opacity: 0;
        transform: translateY(14px) scale(0.985);
        transition: opacity 280ms ease, transform 280ms ease;
        will-change: opacity, transform;
    }

    #treatmentsModal.mega-menu-open .bg-secondary.text-dark,
    #aboutModal.mega-menu-open .bg-secondary.text-dark {
        opacity: 1;
        transform: translateY(0) scale(1);
    }

    #treatmentsModal.mega-menu-closing,
    #aboutModal.mega-menu-closing {
        opacity: 0;
        visibility: visible;
        pointer-events: none;
    }
}

.thryve-modal-scroll-panel.has-scroll-more {
    box-shadow:
        inset 0 -54px 42px -46px rgba(63, 42, 30, 0.42),
        0 25px 60px rgba(63, 42, 30, 0.18);
}

.thryve-modal-scroll-cue {
    position: fixed;
    left: 50%;
    bottom: clamp(1rem, 3vh, 1.75rem);
    z-index: 10020;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.72rem 0.95rem;
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(63, 42, 30, 0.9);
    color: #fff;
    box-shadow: 0 16px 36px rgba(63, 42, 30, 0.22);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    opacity: 0;
    pointer-events: none;
    transform: translateX(-50%) translateY(8px);
    transition: opacity 180ms ease, transform 180ms ease, background 180ms ease;
    font-size: 12px;
    line-height: 1;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.thryve-modal-scroll-cue.is-visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
}

.thryve-modal-scroll-cue svg {
    width: 16px;
    height: 16px;
    animation: thryve-scroll-cue-nudge 1.45s ease-in-out infinite;
}

.thryve-modal-scroll-cue:hover,
.thryve-modal-scroll-cue:focus-visible {
    background: rgba(63, 42, 30, 0.98);
    transform: translateX(-50%) translateY(-1px);
}

.thryve-modal-scroll-cue:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.7);
    outline-offset: 3px;
}

@keyframes thryve-scroll-cue-nudge {

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

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

@media (min-width: 768px) {
    .thryve-modal-scroll-cue {
        bottom: clamp(1.25rem, 4vh, 2.2rem);
    }
}

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

    .thryve-modal-scroll-cue,
    .thryve-modal-scroll-cue svg {
        animation: none;
        transition: none;
    }
}

/* --------------------------------------------------------------------------
   Google rating badge — subtle, legible and in keeping with the theme
   -------------------------------------------------------------------------- */
.google-rating-link {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 0.9rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 999px;
    color: #ffffff;
    text-decoration: none;
    transition: transform 140ms ease, opacity 140ms ease;
    backdrop-filter: blur(6px);
}

.google-rating-link:hover {
    transform: translateY(-2px);
    opacity: 0.98;
}

.google-rating-link .google-g svg {
    display: block;
    width: 18px;
    height: 18px;
}

.google-rating-stars {
    display: inline-flex;
    gap: 0.25rem;
    align-items: center;
}

.google-star path {
    fill: #E4DDCB;
}

.google-rating-text {
    font-family: "Gill Sans Custom", system-ui, Arial, sans-serif;
    font-size: 0.95rem;
    letter-spacing: 0.01em;
    color: #ffffff;
    opacity: 0.95;
}

@media (max-width: 640px) {
    .google-rating-link {
        padding: 0.35rem 0.6rem;
        gap: 0.45rem;
    }

    .google-rating-text {
        font-size: 0.88rem;
    }

    .google-rating-stars svg {
        width: 14px;
        height: 14px;
    }
}

/* --------------------------------------------------------------------------
   Header CTA — keep Book Now aligned with the navigation typography
   -------------------------------------------------------------------------- */
.site-header .cta-book,
.site-header .cta-book-mobile {
    position: relative;
    z-index: 1;
    overflow: hidden;
    padding: 0.72rem 1.2rem;
    font-size: 12px;
    line-height: 1.2;
    letter-spacing: 0.18em;
    font-weight: 400;
    border: 1px solid rgba(255, 255, 255, 0.72);
    box-shadow: none;
    border-radius: 0;
    transition: background-color 220ms ease, color 220ms ease, border-color 220ms ease;
}

.site-header .cta-book::before,
.site-header .cta-book-mobile::before,
.site-header .cta-book::after,
.site-header .cta-book-mobile::after {
    content: none;
}

.site-header .cta-book:hover,
.site-header .cta-book-mobile:hover {
    border-color: rgba(255, 255, 255, 0.88);
}

.site-header .cta-book:focus,
.site-header .cta-book-mobile:focus {
    outline: 2px solid rgba(255, 255, 255, 0.24);
    outline-offset: 3px;
}

.site-header .cta-book-mobile {
    padding: 0.85rem 1rem;
}

.thryve-auto-reel {
    position: relative;
    overflow: hidden;
    width: 100%;
    outline: none;
}

.thryve-auto-reel::before,
.thryve-auto-reel::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    z-index: 2;
    width: clamp(48px, 10vw, 140px);
    pointer-events: none;
}

.thryve-auto-reel::before {
    left: 0;
    background: linear-gradient(90deg, #FDF9F2 0%, rgba(253, 249, 242, 0) 100%);
}

.thryve-auto-reel::after {
    right: 0;
    background: linear-gradient(270deg, #FDF9F2 0%, rgba(253, 249, 242, 0) 100%);
}

.thryve-auto-reel:focus-visible {
    outline: 1px solid rgba(63, 42, 30, 0.32);
    outline-offset: 6px;
}

.thryve-auto-reel__track {
    display: flex;
    align-items: stretch;
    width: max-content;
    animation: thryve-auto-reel-slide 42s linear infinite;
    will-change: transform;
}

.thryve-auto-reel__group {
    display: flex;
    align-items: stretch;
    gap: 1rem;
    padding-right: 1rem;
}

.thryve-auto-reel:hover .thryve-auto-reel__track,
.thryve-auto-reel:focus-within .thryve-auto-reel__track {
    animation-play-state: paused;
}

.thryve-auto-reel__item {
    flex: 0 0 auto;
    margin: 0;
    overflow: hidden;
    background: #E5DED4;
}

.thryve-auto-reel__image {
    display: block;
    width: clamp(270px, 38vw, 440px);
    height: clamp(340px, 50vw, 520px);
    object-fit: cover;
    object-position: center;
    transform: scale(1.01);
}

@keyframes thryve-auto-reel-slide {
    from {
        transform: translate3d(0, 0, 0);
    }

    to {
        transform: translate3d(-50%, 0, 0);
    }
}

@media (max-width: 640px) {
    .thryve-auto-reel__track {
        animation-duration: 34s;
    }

    .thryve-auto-reel__group {
        gap: 0.85rem;
        padding-right: 0.85rem;
    }

    .thryve-auto-reel__image {
        width: 78vw;
        height: 360px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .thryve-auto-reel {
        overflow-x: auto;
        scrollbar-width: thin;
    }

    .thryve-auto-reel::before,
    .thryve-auto-reel::after {
        display: none;
    }

    .thryve-auto-reel__track {
        animation: none;
    }
}

/* Navigation spacing and subtle divider */
.site-header .main-navigation {
    padding-bottom: 0.75rem;
    margin-bottom: 0.5rem;
}

.site-header .menu-toggle {
    width: 44px;
    height: 44px;
    padding: 0.5rem;
    line-height: 0;
}

.thryve-not-found {
    min-height: clamp(520px, 68vh, 760px);
    display: flex;
    align-items: center;
    padding: clamp(5rem, 10vw, 8rem) 0;
    isolation: isolate;
}

.thryve-not-found h1 {
    font-size: clamp(3rem, 7vw, 6.5rem);
    letter-spacing: 0;
}

.thryve-not-found__mark {
    position: absolute;
    inset: 50% auto auto 50%;
    z-index: -1;
    transform: translate(-50%, -50%);
    color: rgba(255, 255, 255, 0.045);
    font-family: Cormorant, Georgia, serif;
    font-size: clamp(14rem, 42vw, 38rem);
    font-weight: 300;
    line-height: 0.7;
    pointer-events: none;
}

@media (max-width: 767px) {
    .site-header .site-branding {
        padding-left: 3rem;
        padding-right: 3rem;
    }

    .thryve-not-found__actions a {
        width: 100%;
        max-width: 320px;
        margin-inline: auto;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .site-main section {
        scroll-margin-top: 7rem;
    }

    .site-main .md\:p-24 {
        padding: 3rem;
    }

    .site-main .md\:gap-16 {
        gap: 2.5rem;
    }
}

[data-card-href]:focus-visible {
    outline: 2px solid rgba(63, 42, 30, 0.36);
    outline-offset: 4px;
}
