/* ==========================================================================
   Components: reusable sections and pieces
   Text, buttons, hero, split, stats, checklist, card, cta band, FAQ,
   rich text, page hero, breadcrumbs, article layout, fact box, contents,
   booking box, card groups
   ========================================================================== */

/* Text ------------------------------------------------------------------- */

.eyebrow {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-bottom: 0.85rem;
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    color: var(--primary-700);
}

/* Short accent rule before the label */
.eyebrow::before {
    content: "";
    flex: none;
    width: 1.75rem;
    height: 3px;
    border-radius: 2px;
    background: var(--accent-500);
}

.lead {
    max-width: 60ch;
    font-size: clamp(1.05rem, 1.6vw, 1.2rem);
    line-height: 1.6;
    color: var(--ink-700);
}

/* Section heading: title on the left, lead on the right from desktop up */
.section-head {
    margin-bottom: clamp(2rem, 4vw, 3rem);
}

.section-head h2 {
    max-width: 22ch;
    margin-bottom: 0;
}

.section-head .lead {
    margin: 1rem 0 0;
}

.section-foot {
    margin-top: 2.5rem;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 2.875rem;
    padding: 0.75rem 1.4rem;
    border: 2px solid transparent;
    border-radius: var(--radius);
    font-size: 0.97rem;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition:
        background-color 0.15s ease,
        border-color 0.15s ease,
        color 0.15s ease;
}

.btn--primary {
    background: var(--accent-500);
    color: var(--accent-ink);
}

.btn--primary:hover {
    background: var(--accent-600);
    color: var(--accent-ink);
}

.btn--dark {
    background: var(--primary-700);
    color: var(--white);
}

.btn--dark:hover {
    background: var(--primary-900);
    color: var(--white);
}

.btn--ghost {
    border-color: rgb(255 255 255 / 0.8);
    background: transparent;
    color: var(--white);
}

.btn--ghost:hover {
    background: var(--white);
    color: var(--primary-900);
}

.btn--outline {
    border-color: var(--primary-700);
    background: var(--white);
    color: var(--primary-800);
}

.btn--outline:hover {
    background: var(--primary-700);
    color: var(--white);
}

.btn--sm {
    min-height: 2.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.btn--block {
    display: flex;
    width: 100%;
}

.btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.75rem;
}

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

.hero,
.cta-band__panel {
    position: relative;
    isolation: isolate;
    color: var(--white);
}

.hero__bg,
.cta-band__bg {
    position: absolute;
    inset: 0;
    z-index: -2;
}

.hero__bg img,
.cta-band__bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero::after,
.cta-band__panel::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
}

/* The text sits at the bottom of a tall image, over a dark fade */
.hero {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: clamp(34rem, 86vh, 48rem);
    background: var(--primary-900);
}

.hero::after {
    background: linear-gradient(
        180deg,
        rgb(var(--primary-950-rgb) / 0.45) 0%,
        rgb(var(--primary-950-rgb) / 0.8) 40%,
        rgb(var(--primary-950-rgb) / 0.95) 100%
    );
}

/* Wide screens: the text sits on the left, so darken that side most */
@media (min-width: 64em) {
    .hero::after {
        background:
            linear-gradient(90deg, rgb(var(--primary-950-rgb) / 0.72) 0%, rgb(var(--primary-950-rgb) / 0.35) 55%, rgb(var(--primary-950-rgb) / 0) 80%),
            linear-gradient(180deg, rgb(var(--primary-950-rgb) / 0.25) 0%, rgb(var(--primary-950-rgb) / 0.55) 50%, rgb(var(--primary-950-rgb) / 0.9) 100%);
    }
}

.hero :focus-visible,
.cta-band__panel :focus-visible {
    outline: var(--focus-ring-on-dark);
}

.hero__inner {
    max-width: 44rem;
    padding-block: 7rem clamp(2.5rem, 6vw, 4.5rem);
}

.hero .eyebrow,
.cta-band__panel .eyebrow {
    color: var(--secondary-300);
}

.hero h1 {
    color: var(--white);
    text-shadow: 0 2px 16px rgb(0 0 0 / 0.3);
}

.hero .lead,
.cta-band__panel .lead {
    color: var(--on-dark);
}

/* Trust points: a row of small tags under the buttons */
.hero__trust {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 2rem 0 0;
    padding: 0;
    list-style: none;
    font-size: 0.87rem;
    font-weight: 600;
    color: var(--white);
}

.hero__trust li {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.35rem 0.75rem;
    border: 1px solid rgb(255 255 255 / 0.3);
    border-radius: var(--radius);
    background: rgb(var(--primary-950-rgb) / 0.45);
}

.hero__trust li::before {
    content: "";
    flex: none;
    width: 0.9rem;
    height: 0.9rem;
    background: var(--secondary-300);
    -webkit-mask: var(--icon-check) center / contain no-repeat;
    mask: var(--icon-check) center / contain no-repeat;
}

/* Split: text beside an image -------------------------------------------- */

.split {
    align-items: center;
    gap: clamp(2.5rem, 6vw, 4.5rem);
}

/* The image sits on an offset colour block */
.split__media {
    position: relative;
    isolation: isolate;
    padding: 0 1rem 1rem 0;
}

.split__media::before {
    content: "";
    position: absolute;
    inset: 1rem 0 0 1rem;
    z-index: -1;
    border-radius: var(--radius-lg);
    background: var(--secondary-100);
}

.section--tint .split__media::before {
    background: var(--secondary-300);
}

.split__media img {
    width: 100%;
    border-radius: var(--radius-lg);
}

/* Stats ------------------------------------------------------------------ */

.stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem 2rem;
    margin: 2rem 0 0;
    padding: 0;
    list-style: none;
}

.stat {
    padding-inline-start: 1rem;
    border-inline-start: 3px solid var(--accent-500);
}

.stat__value {
    display: block;
    font-family: var(--font-serif);
    font-size: 2.1rem;
    font-weight: 600;
    line-height: 1.05;
    color: var(--primary-900);
}

.stat__label {
    font-size: 0.88rem;
    color: var(--ink-500);
}

/* Checklist -------------------------------------------------------------- */

.checklist {
    margin: 0 0 1rem;
    padding: 0;
    list-style: none;
}

.checklist li {
    position: relative;
    margin-bottom: 0.5rem;
    padding-inline-start: 1.6rem;
}

.checklist li::before {
    content: "";
    position: absolute;
    top: 0.35em;
    inset-inline-start: 0;
    width: 1rem;
    height: 1rem;
    background: var(--primary-600);
    -webkit-mask: var(--icon-check) center / contain no-repeat;
    mask: var(--icon-check) center / contain no-repeat;
}

.checklist--sm {
    font-size: 0.9rem;
}

.checklist--sm li {
    margin-bottom: 0.35rem;
}

/* Card ------------------------------------------------------------------- */

.card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    border: 1px solid var(--border-200);
    border-radius: var(--radius-lg);
    background: var(--white);
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.card:hover {
    border-color: var(--primary-600);
    box-shadow: var(--shadow-md);
}

.card:has(.card__link:focus-visible) {
    outline: var(--focus-ring);
    outline-offset: 3px;
}

.card__media {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: var(--border-200);
}

.card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.card:hover .card__media img {
    transform: scale(1.03);
}

.card__body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 1.15rem 1.25rem 1.35rem;
}

.card__title {
    margin-bottom: 0.35rem;
}

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

.card:hover .card__title a {
    text-decoration: underline;
    text-decoration-thickness: 2px;
}

/* The primary link covers the whole card, so the card has one tab stop */
.card__link::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
}

@supports selector(:has(a)) {
    .card__link:focus-visible {
        outline: none;
    }
}

.card__tagline {
    margin-bottom: 0.55rem;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--ink-700);
}

.card__desc {
    font-size: 0.94rem;
    color: var(--ink-700);
}

.card__meta {
    display: flex;
    order: -1; /* Shown above the title, read after it */
    flex-wrap: wrap;
    gap: 0.35rem 0.9rem;
    margin: 0 0 0.6rem;
    padding: 0;
    list-style: none;
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--ink-500);
}

.card__meta li {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.card__meta li::before {
    content: "";
    flex: none;
    width: 0.95rem;
    height: 0.95rem;
    background: currentColor;
    -webkit-mask: var(--icon) center / contain no-repeat;
    mask: var(--icon) center / contain no-repeat;
}

.card__meta-time {
    --icon: var(--icon-clock);
}

.card__meta-place {
    --icon: var(--icon-pin);
}

.card__meta-date {
    --icon: var(--icon-calendar);
}

.card__foot {
    margin-top: auto;
    padding-top: 1rem;
}

/* Square tags along the top edge of the image */
.badge {
    position: absolute;
    top: 0;
    inset-inline-start: 0;
    max-width: calc(100% - 1rem);
    padding: 0.3rem 0.65rem;
    border-end-end-radius: var(--radius);
    background: var(--primary-900);
    color: var(--white);
    font-size: 0.78rem;
    font-weight: 700;
}

.badge--season {
    inset-inline: auto 0;
    border-end-end-radius: 0;
    border-end-start-radius: var(--radius);
    background: var(--white);
    color: var(--primary-900);
}

/* CTA band: an image panel inset in the page ----------------------------- */

.cta-band__panel {
    overflow: hidden;
    padding: clamp(2.5rem, 6vw, 4.5rem) clamp(1.5rem, 5vw, 4rem);
    border-radius: var(--radius-lg);
    background: var(--primary-900);
}

.cta-band__panel::after {
    background: linear-gradient(
        180deg,
        rgb(var(--primary-950-rgb) / 0.88),
        rgb(var(--primary-950-rgb) / 0.78)
    );
}

.cta-band__panel h2 {
    max-width: 24ch;
    color: var(--white);
}

.cta-band__panel .lead {
    margin-bottom: 0;
}

/* FAQ: heading beside the questions from desktop up ---------------------- */

.faq details {
    border-bottom: 1px solid var(--border-200);
}

.faq details:first-child {
    border-top: 1px solid var(--border-200);
}

.faq summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.1rem 0;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--primary-900);
    list-style: none;
    cursor: pointer;
}

.faq summary:hover {
    color: var(--primary-700);
}

.faq summary::-webkit-details-marker {
    display: none;
}

.faq summary::after {
    content: "";
    flex: none;
    width: 1.1rem;
    height: 1.1rem;
    background: var(--primary-600);
    -webkit-mask: var(--icon-chevron) center / contain no-repeat;
    mask: var(--icon-chevron) center / contain no-repeat;
    transition: transform 0.2s ease;
}

.faq details[open] summary::after {
    transform: rotate(180deg);
}

.faq .rich-text {
    padding-bottom: 1.25rem;
    color: var(--ink-700);
}

/* Rich text: CMS editor content, styled through the wrapper only --------- */

.rich-text > * {
    margin-top: 0;
    margin-bottom: 0;
}

.rich-text > * + * {
    margin-top: 1rem;
}

.rich-text > h2 {
    margin-top: 2.6rem;
    scroll-margin-top: calc(var(--header-height) + 1rem);
}

.rich-text > h2:first-child {
    margin-top: 0;
}

.rich-text > h3,
.rich-text > h4 {
    margin-top: 1.8rem;
}

.rich-text h2 {
    font-size: clamp(1.45rem, 2.8vw, 1.9rem);
}

.rich-text h3 {
    font-size: clamp(1.15rem, 2vw, 1.3rem);
}

.rich-text h4 {
    font-size: 1.1rem;
}

.rich-text ul,
.rich-text ol {
    padding-inline-start: 1.3rem;
}

.rich-text li + li {
    margin-top: 0.4rem;
}

.rich-text a {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.rich-text strong {
    font-weight: 700;
    color: var(--ink-900);
}

.rich-text em {
    font-style: italic;
}

.rich-text blockquote {
    margin-inline: 0;
    padding: 0.4rem 0 0.4rem 1.2rem;
    border-inline-start: 4px solid var(--secondary-500);
    font-style: italic;
    color: var(--ink-700);
}

.rich-text figure {
    margin-inline: 0;
    overflow-x: auto; /* A very wide table scrolls inside its figure, not the page */
}

.rich-text img {
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.rich-text figcaption {
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: var(--ink-500);
}

.rich-text table {
    width: 100%;
    border-collapse: collapse;
    border: 1px solid var(--border-200);
    background: var(--white);
    font-size: 0.93rem;
}

.rich-text caption {
    padding-bottom: 0.5rem;
    font-weight: 700;
    text-align: start;
    color: var(--primary-900);
}

.rich-text th,
.rich-text td {
    padding: 0.7rem 0.9rem;
    border-bottom: 1px solid var(--border-200);
    text-align: start;
    vertical-align: top;
}

.rich-text thead th {
    background: var(--surface-100);
    font-size: 0.85rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--primary-900);
}

.rich-text tbody th {
    color: var(--primary-800);
}

.rich-text hr {
    height: 1px;
    border: 0;
    background: var(--border-200);
}

/* Page hero: banner at the top of inner pages ---------------------------- */

.page-hero {
    position: relative;
    isolation: isolate;
    padding-block: clamp(3rem, 8vw, 5rem) clamp(2.4rem, 5vw, 3.5rem);
    background: var(--primary-900);
    color: var(--white);
}

.page-hero__bg {
    position: absolute;
    inset: 0;
    z-index: -2;
}

.page-hero__bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.page-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(180deg, rgb(var(--primary-950-rgb) / 0.45), rgb(var(--primary-950-rgb) / 0.9));
}

.page-hero:not(.page-hero--slim) {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: clamp(20rem, 46vh, 28rem);
}

/* Without an image: a light band with dark text */
.page-hero--slim {
    padding-block: clamp(2.5rem, 6vw, 4rem) clamp(2rem, 4vw, 3rem);
    border-bottom: 1px solid var(--border-200);
    background: var(--surface-100);
    color: var(--ink-900);
}

.page-hero--slim::after {
    content: none;
}

.page-hero.page-hero--slim h1 {
    color: var(--primary-900);
}

.page-hero.page-hero--slim .lead {
    color: var(--ink-700);
}

.page-hero.page-hero--slim .eyebrow {
    color: var(--primary-700);
}

.page-hero.page-hero--slim .page-hero__meta,
.page-hero--slim .crumbs ol {
    color: var(--ink-500);
}

.page-hero--slim .crumbs a {
    color: var(--primary-700);
}

.page-hero--slim .crumbs a:hover {
    color: var(--primary-900);
}

.page-hero.page-hero--slim :focus-visible {
    outline: var(--focus-ring);
}

.page-hero h1 {
    max-width: 24ch;
    color: var(--white);
}

.page-hero .lead {
    margin-bottom: 0;
    color: var(--on-dark);
}

.page-hero .eyebrow {
    color: var(--secondary-300);
}

.page-hero :focus-visible {
    outline: var(--focus-ring-on-dark);
}

.page-hero__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem 1.2rem;
    margin: 1rem 0 0;
    padding: 0;
    list-style: none;
    font-size: 0.9rem;
    color: var(--on-dark-muted);
}

/* Breadcrumbs ------------------------------------------------------------ */

.crumbs ol {
    display: flex;
    flex-wrap: wrap;
    gap: 0.2rem 0;
    margin: 0 0 0.9rem;
    padding: 0;
    list-style: none;
    font-size: 0.875rem;
    color: var(--on-dark-muted);
}

.crumbs li + li::before {
    content: "/";
    margin-inline: 0.5rem;
    opacity: 0.7;
}

.crumbs a {
    color: var(--on-dark);
}

.crumbs a:hover {
    color: var(--white);
}

/* Article with sidebar --------------------------------------------------- */

.layout-2col {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 2.5rem;
    align-items: start;
}

.article {
    max-width: 74ch;
}

.sidebar {
    display: flex;
    flex-direction: column;
    gap: 1.4rem;
}

/* Fact box --------------------------------------------------------------- */

.fact-box,
.toc {
    padding: 1.3rem 1.4rem;
    border: 1px solid var(--border-200);
    border-top: 3px solid var(--primary-700);
    border-radius: var(--radius);
    background: var(--white);
}

.fact-box__title,
.toc__title {
    margin-bottom: 0.9rem;
    font-size: 1.1rem;
}

.fact-box__list {
    display: grid;
    gap: 0.8rem;
    margin: 0;
}

.fact-box__list dt {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--ink-500);
}

.fact-box__list dd {
    margin: 0.1rem 0 0;
    font-size: 0.95rem;
    color: var(--ink-900);
}

/* Table of contents ------------------------------------------------------ */

.toc__list {
    margin: 0;
    padding: 0;
    list-style: none;
    font-size: 0.95rem;
}

.toc__list li + li {
    margin-top: 0.45rem;
}

.toc__list a {
    text-decoration: none;
}

.toc__list a:hover {
    text-decoration: underline;
}

/* Booking box ------------------------------------------------------------ */

.aff-box {
    padding: 1.5rem;
    border-top: 4px solid var(--accent-500);
    border-radius: var(--radius);
    background: var(--primary-900);
    color: var(--on-dark);
}

.aff-box--stay {
    background: var(--primary-800);
}

.aff-box__title {
    margin-bottom: 0.6rem;
    font-size: 1.25rem;
    color: var(--white);
}

.aff-box__text {
    font-size: 0.95rem;
}

.aff-box__note {
    margin: 0.8rem 0 0;
    font-size: 0.8rem;
    color: var(--on-dark-muted);
}

.aff-box :focus-visible {
    outline: var(--focus-ring-on-dark);
}

/* Section heading with a lead, left-aligned above a card group ----------- */

.group + .group {
    margin-top: clamp(2.5rem, 5vw, 3.5rem);
}

.group__head {
    max-width: 64ch;
    margin-bottom: 1.6rem;
}

.group__head p {
    margin-bottom: 0;
    color: var(--ink-700);
}

.card__bestfor {
    margin-bottom: 0;
    font-size: 0.9rem;
    color: var(--ink-500);
}

.card__bestfor strong {
    color: var(--ink-700);
}

/* Contact form (Contact Form 7) ------------------------------------------ */

.wpcf7-form {
    display: grid;
    gap: 1.1rem;
    max-width: 40rem;
}

.wpcf7-form p {
    margin: 0;
}

.wpcf7-form label {
    display: block;
    font-weight: 600;
    color: var(--ink-900);
}

.wpcf7-form-control-wrap {
    display: block;
    margin-top: 0.35rem;
}

.wpcf7-form input:not([type="submit"], [type="checkbox"], [type="radio"], [type="hidden"]),
.wpcf7-form textarea {
    width: 100%;
    min-height: 2.75rem;
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--ink-500);
    border-radius: 0.5rem;
    background: var(--white);
    color: var(--ink-900);
    font: inherit;
    font-weight: 400;
}

.wpcf7-form textarea {
    min-height: 10rem;
    resize: vertical;
}

.wpcf7-form .wpcf7-form-control.wpcf7-not-valid {
    border-color: #b3261e;
}

.wpcf7-form .wpcf7-not-valid-tip {
    margin-top: 0.35rem;
    color: #b3261e;
    font-size: 0.9rem;
    font-weight: 600;
}

.wpcf7-form .wpcf7-spinner {
    vertical-align: middle;
}

.wpcf7 form .wpcf7-response-output {
    margin: 0;
    padding: 0.8rem 1rem;
    border-radius: 0.5rem;
}

.form-note {
    color: var(--ink-500);
    font-size: 0.9rem;
}

/* Desktop ---------------------------------------------------------------- */

@media (min-width: 64em) {
    .section-head:has(.lead) {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        column-gap: clamp(2rem, 5vw, 4rem);
        align-items: end;
    }

    .section-head:has(.lead) > :not(.lead) {
        grid-column: 1;
    }

    .section-head .lead {
        grid-column: 2;
        grid-row: 1 / span 2;
        align-self: end;
        margin: 0;
    }

    .faq-layout {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
        gap: 4rem;
        align-items: start;
    }

    .faq-layout .section-head {
        position: sticky;
        top: calc(var(--header-height) + 2rem);
    }

    .layout-2col {
        grid-template-columns: minmax(0, 1fr) 20rem;
        gap: 3rem;
    }

    .sidebar {
        position: sticky;
        top: calc(var(--header-height) + 1.5rem);
    }
}
