/* =====================================================================
   pages.css: the shared components of the inner pages (Publications, Blog,
   Activities, Tools, Services, Contact, Photography, the booking pages and
   the tools): the page header over the lattice, glass cards and tiles,
   pill buttons, chips and labels. Every value comes from the tokens in
   css/theme.css, so the theme changes there and these follow. Loaded after
   base.css and mobile-header.css; each page's own <style> adds what only
   it has, built on the same tokens.
   ===================================================================== */

/* ── The page header ── */
.page-hero {
    position: relative;
    overflow: hidden;
    margin: 0 0 2.4rem;
    padding: 2.3rem 2.6rem 2.2rem;
    border-radius: var(--radius-2xl);
    background: var(--hero-fill);
    border: 1px solid var(--hero-line);
    box-shadow: var(--hero-shadow);
    backdrop-filter: blur(var(--hero-blur));
    -webkit-backdrop-filter: blur(var(--hero-blur));
}
/* The lattice, strongest at the right and fading towards the title. */
.page-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--lattice);
    -webkit-mask-image: radial-gradient(ellipse 50% 130% at 92% 40%, #000 0%, transparent 74%);
    mask-image: radial-gradient(ellipse 50% 130% at 92% 40%, #000 0%, transparent 74%);
    pointer-events: none;
}
.page-hero::after {
    content: '';
    position: absolute;
    left: 28px;
    right: 28px;
    top: 0;
    height: 2px;
    border-radius: 2px;
    background: var(--edge);
    opacity: 0.85;
}
.page-hero > * {
    position: relative;
    z-index: 1;
}
.page-hero-head {
    display: flex;
    align-items: center;
    gap: 1.1rem;
}
.page-hero h1 {
    display: inline-block;   /* so the gradient spans the title and ends in gold */
    margin: 0;
    padding-bottom: 0.06em;
    font-family: var(--font-display);
    font-size: clamp(2rem, 4.2vw, 3rem);
    line-height: 1.1;
    font-weight: var(--weight-display);
    letter-spacing: -0.01em;
    color: var(--color-title);
    background: var(--title-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.page-lead {
    margin: 1.15rem 0 0;
    max-width: 68ch;
    font-size: 1.06rem;
    line-height: 1.7;
    color: var(--ink-2);
}
.page-lead a {
    color: var(--color-light-teal);
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: var(--link-underline);
    text-underline-offset: 3px;
    transition: color var(--t-fast) ease;
}
.page-lead a:hover {
    color: var(--color-title);
    text-decoration-color: var(--color-yellow);
}
/* A small note under the lead, with its icon. */
.page-note {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.7rem 0 0;
    font-size: 0.88rem;
    color: var(--ink-3);
}
.page-note svg {
    width: 17px;
    height: 17px;
    flex: none;
    color: var(--color-light-teal);
}
/* The page's own controls (search, filters) at the foot of the header. */
.page-hero-foot {
    margin-top: 1.5rem;
}

/* A rounded tile with the icon in teal, in a teal-to-gold ring like the
   homepage portrait's: the page's icon in the header (the same as in the
   menu), a service's badge, a booking state's badge. */
.icon-tile {
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    border-radius: var(--radius-lg);
    border: 1.5px solid transparent;
    color: var(--color-light-teal);
    background:
        radial-gradient(circle at 30% 25%, rgba(var(--accent-rgb), 0.28), transparent 70%) padding-box,
        linear-gradient(rgb(var(--deep-rgb)), rgb(var(--deep-rgb))) padding-box,
        var(--ring-gradient) border-box;
    box-shadow: 0 10px 26px rgba(var(--accent-rgb), 0.16), 0 0 18px rgba(var(--gold-rgb), 0.08);
}
.icon-tile svg {
    width: 28px;
    height: 28px;
}
/* A state worth noticing (cancelled, waiting) in gold; a failure in red. */
.icon-tile.gold {
    color: var(--gold-ink);
    background:
        radial-gradient(circle at 30% 25%, rgba(var(--gold-rgb), 0.26), transparent 70%) padding-box,
        linear-gradient(rgb(var(--deep-rgb)), rgb(var(--deep-rgb))) padding-box,
        linear-gradient(135deg, var(--color-yellow), rgba(var(--gold-rgb), 0.35)) border-box;
    box-shadow: 0 10px 26px rgba(var(--gold-rgb), 0.16);
}
.icon-tile.alert {
    color: var(--bad);
    background:
        radial-gradient(circle at 30% 25%, rgba(var(--bad-rgb), 0.24), transparent 70%) padding-box,
        linear-gradient(rgb(var(--deep-rgb)), rgb(var(--deep-rgb))) padding-box,
        linear-gradient(135deg, var(--bad), rgba(var(--bad-rgb), 0.35)) border-box;
    box-shadow: 0 10px 26px rgba(var(--bad-rgb), 0.16);
}

/* ── Surfaces: a glass card, with or without the teal-to-gold edge, and a
      tile inside it ── */
.glass {
    position: relative;
    border-radius: var(--radius-xl);
    background: var(--glass-fill);
    border: 1px solid var(--glass-line);
    box-shadow: var(--glass-shadow);
}
.glass.gold {
    background: var(--glass-gold-fill);
}
.glass-edge::before {
    content: '';
    position: absolute;
    left: 24px;
    right: 24px;
    top: 0;
    height: 2px;
    border-radius: 2px;
    background: var(--edge);
    opacity: 0.85;
    pointer-events: none;
}
.tile {
    border-radius: var(--radius-lg);
    background: var(--tile-fill);
    border: 1px solid var(--tile-line);
}

/* ── Buttons: pills with an icon; the primary one filled with teal ── */
.btn-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.62rem 1.15rem;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(var(--accent-rgb), 0.45);
    background: rgba(var(--deep-rgb), 0.35);
    color: var(--ink);
    font: inherit;
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: transform var(--t-fast) ease, box-shadow var(--t-fast) ease, border-color var(--t-fast) ease, background-color var(--t-fast) ease, color var(--t-fast) ease;
}
.btn-pill svg {
    width: 18px;
    height: 18px;
    flex: none;
    color: var(--color-light-teal);
}
.btn-pill:hover {
    transform: translateY(-2px);
    border-color: var(--color-light-teal);
    background: rgba(var(--accent-rgb), 0.12);
    box-shadow: 0 8px 22px rgba(var(--shadow-rgb), 0.3);
}
.btn-pill.primary {
    color: var(--color-black);
    background: var(--accent-fill);
    border-color: transparent;
    box-shadow: var(--accent-glow);
}
.btn-pill.primary svg {
    color: currentColor;
}
.btn-pill.primary:hover {
    box-shadow: var(--accent-glow-hover);
}
.btn-pill:focus-visible {
    outline: var(--focus-ring);
    outline-offset: 3px;
}

/* A small chip: a tag, a count, a fact. */
.chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.22rem 0.7rem;
    border-radius: var(--radius-pill);
    font-size: 0.74rem;
    font-weight: 700;
    color: var(--ink-2);
    background: rgba(var(--deep-rgb), 0.4);
    border: 1px solid rgba(var(--accent-rgb), 0.3);
}
.chip.gold {
    color: var(--gold-ink);
    background: var(--gold-fill);
    border-color: var(--gold-line);
}

/* A small label in gold capitals: a card's part, a date, a kind. */
.eyebrow {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--gold-ink);
}

/* A card's heading, with the teal-to-gold bar under it. */
.card-title {
    margin: 0 0 1.2rem;
    font-size: 1.22rem;
    font-weight: var(--weight-display);
    line-height: 1.3;
    color: var(--ink);
}
.card-title::after {
    content: '';
    display: block;
    width: 44px;
    height: 3px;
    margin-top: 0.55rem;
    border-radius: 3px;
    background: var(--rule);
}

/* The way back to a section's page: a small pill above the header. */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-bottom: 0.9rem;
    padding: 0.38rem 0.95rem;
    border-radius: var(--radius-pill);
    font-size: 0.86rem;
    font-weight: 700;
    color: var(--ink-2);
    text-decoration: none;
    background: rgba(var(--deep-rgb), 0.4);
    border: 1px solid rgba(var(--accent-rgb), 0.3);
    transition: color var(--t-fast) ease, border-color var(--t-fast) ease, background-color var(--t-fast) ease;
}
.back-link:hover,
.back-link:focus-visible {
    color: var(--color-light-teal);
    border-color: var(--color-light-teal);
    background: rgba(var(--accent-rgb), 0.1);
    transform: none;
}

/* "More coming soon": a quiet line between two fading rules. */
.slot-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    max-width: 560px;
    margin: 2.6rem auto 0;
    font-size: 0.92rem;
    text-align: center;
    color: var(--ink-3);
}
.slot-note::before,
.slot-note::after {
    content: '';
    flex: 1 1 0;
    min-width: 24px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(var(--accent-rgb), 0.5));
}
.slot-note::after {
    background: linear-gradient(90deg, rgba(var(--accent-rgb), 0.5), transparent);
}

@media (max-width: 768px) {
    .page-hero {
        margin-bottom: 1.6rem;
        padding: 1.7rem 1.25rem 1.5rem;
        border-radius: var(--radius-xl);
    }
    .page-hero::before {
        -webkit-mask-image: radial-gradient(ellipse 70% 90% at 100% 0%, #000 0%, transparent 76%);
        mask-image: radial-gradient(ellipse 70% 90% at 100% 0%, #000 0%, transparent 76%);
    }
    .page-hero-head {
        gap: 0.85rem;
    }
    .page-hero .icon-tile {
        width: 48px;
        height: 48px;
        border-radius: var(--radius-md);
    }
    .page-hero .icon-tile svg {
        width: 24px;
        height: 24px;
    }
    .page-hero h1 {
        font-size: clamp(1.7rem, 7.4vw, 2.2rem);
    }
    .page-lead {
        font-size: 1rem;
        line-height: 1.65;
    }
}

@media (prefers-reduced-motion: reduce) {
    .btn-pill,
    .back-link {
        transition: none;
    }
    .btn-pill:hover {
        transform: none;
    }
}
