/*
Theme Name: Canopy (Costa Rica Eco Lodges)
Description: Magazine theme for costaricaecolodges.com. Built-in SEO, structured data and llms.txt; no page builder or required plugins.
Version: 1.0.0
Requires at least: 6.4
Requires PHP: 8.0
Author: Costa Rica Eco Lodges
Text Domain: cel-canopy
*/

/* ---------- Fonts (self-hosted) ---------- */
@font-face { font-family: "Young Serif"; src: url(assets/fonts/YoungSerif-normal-400.woff2) format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Figtree"; src: url(assets/fonts/Figtree-normal-400-700.woff2) format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Figtree"; src: url(assets/fonts/Figtree-italic-400.woff2) format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url(assets/fonts/IBMPlexMono-normal-500.woff2) format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }

/* ---------- Tokens ---------- */
:root {
  --canopy: #0e2a21;      /* deep rainforest green */
  --canopy-2: #16392d;
  --moss: #2f5d45;
  --fern: #a3c98f;        /* light green on dark */
  --mist: #f1f4ee;        /* page ground, green-biased */
  --paper: #ffffff;
  --line: #d9e1d6;
  --ink: #16201b;
  --muted: #56645b;
  --morpho: #1d5fcc;      /* blue morpho butterfly */
  --morpho-ink: #15499f;
  --sun: #e7b347;         /* toucan bill */

  --serif: "Young Serif", Georgia, "Times New Roman", serif;
  --sans: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --step--1: .8125rem;
  --step-0: 1rem;
  --step-1: 1.125rem;
  --step-2: 1.375rem;
  --step-3: clamp(1.5rem, 1.2rem + 1.2vw, 2rem);
  --step-4: clamp(1.9rem, 1.4rem + 2.2vw, 2.85rem);
  --step-5: clamp(2.3rem, 1.5rem + 3.6vw, 4.1rem);

  --gutter: 16px;
  --radius: 14px;
  --wrap: 1320px;
}
@media (min-width: 700px) { :root { --gutter: 28px; } }
@media (min-width: 1100px) { :root { --gutter: 40px; } }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 90px; }
body { margin: 0; background: var(--mist); color: var(--ink); font: 400 var(--step-0)/1.6 var(--sans); text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, svg, video, iframe { max-width: 100%; }
img { height: auto; display: block; }
a { color: var(--morpho); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--morpho-ink); }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 400; line-height: 1.12; margin: 0; text-wrap: balance; letter-spacing: -.01em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
:focus-visible { outline: 3px solid var(--sun); outline-offset: 2px; border-radius: 4px; }
.cel-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.cel-skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--paper); padding: 8px 14px; border-radius: 8px; }
.cel-skip:focus { left: 8px; }
.cel-mono { font-family: var(--mono); font-weight: 500; letter-spacing: .02em; }

.cel-wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.cel-wrap--text { max-width: calc(760px + 2 * var(--gutter)); }
.cel-wrap--media { max-width: calc(1000px + 2 * var(--gutter)); }

.cel-eyebrow { font: 500 var(--step--1)/1.3 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--moss); }
.cel-eyebrow--light { color: var(--fern); }

.cel-tag { display: inline-block; font: 500 .72rem/1.2 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--moss); text-decoration: none; }
.cel-tag:hover { color: var(--canopy); text-decoration: underline; }

/* ---------- Header ---------- */
.cel-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--paper) 94%, transparent); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); }
.admin-bar .cel-header { top: 32px; }
@media (max-width: 782px) { .admin-bar .cel-header { top: 0; } }
.cel-topbar { background: var(--canopy); color: var(--fern); font: 500 .7rem/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; }
.cel-topbar__in { display: flex; gap: 10px; justify-content: center; padding-block: 8px; white-space: nowrap; overflow: hidden; }
@media (min-width: 900px) { .cel-topbar__in { justify-content: flex-start; } }
.cel-header__in { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 64px; }
.cel-brand { display: inline-flex; align-items: center; gap: 10px; color: var(--canopy); text-decoration: none; }
.cel-brand:hover { color: var(--canopy); }
.cel-mark { width: 36px; height: 36px; color: var(--moss); flex: none; }
.cel-brand__name { font: 400 1.22rem/1 var(--serif); letter-spacing: -.01em; white-space: nowrap; }
.cel-brand__name em { font-style: normal; color: var(--moss); }

.cel-navtoggle { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); cursor: pointer; }
.cel-navtoggle__bars, .cel-navtoggle__bars::before, .cel-navtoggle__bars::after { display: block; width: 18px; height: 2px; background: var(--canopy); border-radius: 2px; position: relative; transition: transform .2s; }
.cel-navtoggle__bars::before, .cel-navtoggle__bars::after { content: ""; position: absolute; left: 0; }
.cel-navtoggle__bars::before { top: -6px; }
.cel-navtoggle__bars::after { top: 6px; }
.cel-navtoggle[aria-expanded="true"] .cel-navtoggle__bars { background: transparent; }
.cel-navtoggle[aria-expanded="true"] .cel-navtoggle__bars::before { transform: translateY(6px) rotate(45deg); }
.cel-navtoggle[aria-expanded="true"] .cel-navtoggle__bars::after { transform: translateY(-6px) rotate(-45deg); }

.cel-nav { display: none; position: absolute; inset: 100% 0 auto 0; background: var(--paper); border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 20px; max-height: calc(100vh - 100px); overflow-y: auto; box-shadow: 0 18px 30px -20px rgba(14, 42, 33, .35); }
.cel-nav.is-open { display: block; }
.cel-nav__list { list-style: none; display: grid; }
.cel-nav__item { border-bottom: 1px solid var(--line); }
.cel-nav__btn, .cel-nav__link { display: flex; width: 100%; align-items: center; justify-content: space-between; padding: 14px 2px; font: 600 1rem/1.2 var(--sans); color: var(--ink); background: none; border: 0; cursor: pointer; text-decoration: none; }
.cel-nav__btn::after { content: ""; width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); margin: -4px 4px 0 10px; transition: transform .2s; }
.cel-nav__btn[aria-expanded="true"]::after { transform: rotate(225deg); margin-top: 4px; }
.cel-sub { display: none; padding: 0 0 14px; }
.cel-nav__btn[aria-expanded="true"] + .cel-sub { display: block; }
.cel-sub ul { list-style: none; display: grid; gap: 2px; }
.cel-sub a { display: block; padding: 8px 10px; border-radius: 10px; text-decoration: none; color: var(--ink); }
.cel-sub a:hover { background: var(--mist); }
.cel-sub__name { display: block; font-weight: 600; }
.cel-sub__meta { display: block; font-size: var(--step--1); color: var(--muted); }

.cel-search { display: flex; margin-top: 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--mist); overflow: hidden; }
.cel-search input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 11px 16px; font: inherit; color: var(--ink); }
.cel-search input:focus { outline: none; }
.cel-search:focus-within { outline: 3px solid var(--sun); outline-offset: 1px; }
.cel-search button { border: 0; background: var(--canopy); color: var(--paper); padding: 0 16px; cursor: pointer; display: grid; place-items: center; font: 600 .9rem var(--sans); }
.cel-search button svg { width: 18px; height: 18px; }

@media (min-width: 1000px) {
  .cel-navtoggle { display: none; }
  .cel-nav { display: flex; align-items: center; gap: 18px; position: static; padding: 0; border: 0; box-shadow: none; background: none; max-height: none; overflow: visible; }
  .cel-nav__list { display: flex; gap: 4px; }
  .cel-nav__item { border: 0; position: relative; }
  .cel-nav__btn, .cel-nav__link { padding: 10px 12px; border-radius: 999px; font-size: .95rem; width: auto; }
  .cel-nav__btn:hover, .cel-nav__link:hover { background: var(--mist); }
  .cel-sub { position: absolute; top: calc(100% + 10px); left: 50%; transform: translateX(-50%); width: min(760px, 80vw); background: var(--paper); border: 1px solid var(--line); border-radius: 18px; padding: 14px; box-shadow: 0 24px 50px -24px rgba(14, 42, 33, .4); }
  .cel-sub--narrow { width: 260px; }
  .cel-sub__grid { grid-template-columns: repeat(3, 1fr); }
  .cel-search { margin: 0; width: 230px; }
  .cel-search input { padding: 9px 14px; font-size: .92rem; }
}
@media (min-width: 1000px) and (max-width: 1180px) { .cel-search { width: 170px; } }

/* ---------- Cards ---------- */
.cel-card { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.cel-card__media { display: block; aspect-ratio: 3 / 2; border-radius: var(--radius); overflow: hidden; background: var(--canopy-2); }
.cel-card__img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.cel-card:hover .cel-card__img { transform: scale(1.035); }
.cel-card__img--blank { display: grid; place-items: center; color: var(--fern); background: radial-gradient(circle at 30% 20%, var(--moss), var(--canopy) 70%); }
.cel-card__img--blank .cel-mark { width: 56px; height: 56px; color: var(--fern); }
.cel-card__body { display: grid; gap: 6px; align-content: start; }
.cel-card__title { font-size: var(--step-2); line-height: 1.18; }
.cel-card__title a { color: var(--ink); text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .3s; }
.cel-card__title a:hover { background-size: 100% 1px; color: var(--ink); }
.cel-card__teaser { color: var(--muted); font-size: .95rem; line-height: 1.5; }

.cel-card--lead { background: var(--paper); border-radius: 20px; overflow: hidden; gap: 0; }
.cel-card--lead .cel-card__media { aspect-ratio: 16 / 10; border-radius: 0; }
.cel-card--lead .cel-card__body { padding: 20px 22px 24px; gap: 8px; }
.cel-card--lead .cel-card__title { font-size: var(--step-4); }
.cel-card--lead .cel-card__teaser { font-size: var(--step-1); }

.cel-card--wide { flex-direction: row; align-items: center; gap: 16px; }
.cel-card--wide .cel-card__media { flex: 0 0 38%; max-width: 200px; aspect-ratio: 4 / 3; border-radius: 12px; }
.cel-card--wide .cel-card__title { font-size: var(--step-1); }
.cel-card--wide .cel-card__teaser { font-size: .88rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.cel-card--feature .cel-card__title { font-size: var(--step-3); }

/* ---------- Hero ---------- */
.cel-hero {
  position: relative; color: var(--paper); padding: clamp(36px, 6vw, 72px) 0 clamp(40px, 6vw, 72px);
  background:
    repeating-radial-gradient(ellipse at 82% 18%, transparent 0 26px, rgba(163, 201, 143, .08) 26px 27px),
    repeating-radial-gradient(ellipse at 8% 92%, transparent 0 34px, rgba(163, 201, 143, .06) 34px 35px),
    linear-gradient(160deg, var(--canopy-2), var(--canopy) 60%);
}
.cel-hero__head { max-width: 860px; display: grid; gap: 16px; margin-bottom: clamp(28px, 4vw, 48px); }
.cel-hero__title { font-size: var(--step-5); line-height: 1.04; }
.cel-hero__title em { font-style: normal; color: var(--fern); }
.cel-hero__dek { font-size: var(--step-1); color: color-mix(in srgb, var(--paper) 82%, var(--fern)); max-width: 62ch; }
.cel-lead { display: grid; gap: 18px; }
.cel-lead__side { display: grid; gap: 12px; align-content: start; }
.cel-lead__side .cel-card--wide { background: var(--paper); border-radius: 16px; padding: 10px; color: var(--ink); }
.cel-lead__side .cel-card__media { max-width: 150px; }
@media (min-width: 960px) {
  .cel-lead { grid-template-columns: 1.4fr 1fr; gap: 24px; align-items: stretch; }
  .cel-lead__side { align-content: stretch; grid-auto-rows: 1fr; }
  .cel-lead__side .cel-card__media { max-width: 170px; }
}

/* ---------- Sections ---------- */
.cel-section { padding-block: clamp(44px, 6vw, 80px); }
.cel-section--tight { padding-top: 0; }
.cel-section__head { display: grid; gap: 14px; margin-bottom: clamp(22px, 3vw, 34px); }
.cel-section__head > div { display: grid; gap: 8px; }
.cel-section__title { font-size: var(--step-4); }
.cel-section__note { color: var(--muted); max-width: 52ch; }
@media (min-width: 900px) {
  .cel-section__head { grid-template-columns: 1fr auto; align-items: end; gap: 40px; }
  .cel-section__note { justify-self: end; }
}
.cel-section__head--row { grid-template-columns: 1fr auto; align-items: end; }
.cel-more { font-weight: 600; text-decoration: none; white-space: nowrap; color: var(--moss); border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.cel-more:hover { color: var(--canopy); }

/* Region tiles: swipe row on phones, 3 x 3 grid from tablets up */
.cel-tiles { list-style: none; display: grid; grid-auto-flow: column; grid-auto-columns: 78%; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); scrollbar-width: thin; }
.cel-tile { scroll-snap-align: start; }
.cel-tile a { position: relative; display: block; aspect-ratio: 4 / 3; border-radius: 18px; overflow: hidden; color: var(--paper); text-decoration: none; background: var(--canopy-2); }
.cel-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.cel-tile a:hover img { transform: scale(1.05); }
.cel-tile__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(14, 42, 33, .05) 30%, rgba(14, 42, 33, .88)); }
.cel-tile__coords { position: absolute; top: 12px; left: 12px; font-size: .68rem; background: rgba(14, 42, 33, .6); color: var(--fern); padding: 5px 8px; border-radius: 999px; backdrop-filter: blur(4px); }
.cel-tile__text { position: absolute; left: 16px; right: 16px; bottom: 14px; display: grid; gap: 2px; }
.cel-tile__name { font: 400 var(--step-3)/1.1 var(--serif); }
.cel-tile__area { font-size: .88rem; opacity: .86; }
.cel-tile__count { margin-top: 6px; font: 500 .72rem/1 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--sun); }
@media (min-width: 700px) {
  .cel-tiles { grid-auto-flow: row; grid-template-columns: repeat(3, 1fr); grid-auto-columns: auto; overflow: visible; margin: 0; padding: 0; gap: 16px; }
  .cel-tile a { aspect-ratio: 5 / 4; }
}
@media (min-width: 1100px) { .cel-tile a { aspect-ratio: 16 / 10; } }

/* Travel-style strip */
.cel-styles { background: var(--paper); border-block: 1px solid var(--line); }
.cel-styles__in { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; padding-block: 18px; }
.cel-styles__label { font: 400 var(--step-2)/1 var(--serif); color: var(--canopy); }
.cel-styles ul, .cel-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.cel-styles a, .cel-chips a { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--mist); color: var(--canopy); text-decoration: none; font-weight: 600; font-size: .92rem; }
.cel-styles a:hover, .cel-chips a:hover { background: var(--canopy); border-color: var(--canopy); color: var(--paper); }
.cel-chips span { font: 500 .72rem var(--mono); color: var(--moss); }
.cel-chips a:hover span { color: var(--fern); }
.cel-chips--light a { background: transparent; color: var(--paper); border-color: rgba(163, 201, 143, .4); }

/* Region rows: one feature story plus four, mirrored on alternate rows */
.cel-row:nth-of-type(even) { background: var(--paper); }
.cel-grid { display: grid; gap: 28px 24px; }
.cel-grid--row { grid-template-columns: 1fr; gap: 18px; }
.cel-grid--row .cel-card:not(.cel-card--feature) { flex-direction: row; align-items: center; gap: 14px; }
.cel-grid--row .cel-card:not(.cel-card--feature) .cel-card__media { flex: 0 0 34%; max-width: 160px; aspect-ratio: 4 / 3; border-radius: 12px; }
.cel-grid--row .cel-card:not(.cel-card--feature) .cel-card__title { font-size: var(--step-1); }
.cel-grid--row .cel-card:not(.cel-card--feature) .cel-card__teaser { display: none; }
@media (min-width: 700px) {
  .cel-grid--row { grid-template-columns: repeat(2, 1fr); gap: 28px 24px; }
  .cel-grid--row .cel-card--feature { grid-column: 1 / -1; }
  .cel-grid--row .cel-card:not(.cel-card--feature) { flex-direction: column; align-items: stretch; }
  .cel-grid--row .cel-card:not(.cel-card--feature) .cel-card__media { flex: none; max-width: none; aspect-ratio: 3 / 2; border-radius: var(--radius); }
}
@media (min-width: 1100px) {
  .cel-grid--row { grid-template-columns: repeat(4, 1fr); }
  .cel-grid--row .cel-card--feature { grid-column: 1 / span 2; grid-row: span 2; }
  .cel-row--flip .cel-grid--row .cel-card--feature { grid-column: 3 / span 2; grid-row: 1 / span 2; }
  .cel-grid--row .cel-card--feature .cel-card__media { aspect-ratio: auto; flex: 1; min-height: 300px; }
  .cel-grid--row .cel-card--feature .cel-card__title { font-size: var(--step-4); }
}

.cel-grid--3, .cel-grid--archive { grid-template-columns: 1fr; }
@media (min-width: 640px) { .cel-grid--3, .cel-grid--archive { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .cel-grid--3, .cel-grid--archive { grid-template-columns: repeat(3, 1fr); } }
.cel-grid--archive .cel-card--feature { grid-column: 1 / -1; }
@media (min-width: 900px) {
  .cel-grid--archive .cel-card--feature { flex-direction: row; align-items: center; gap: 32px; }
  .cel-grid--archive .cel-card--feature .cel-card__media { flex: 0 0 58%; aspect-ratio: 16 / 10; }
  .cel-grid--archive .cel-card--feature .cel-card__title { font-size: var(--step-4); }
}

/* Field notes */
.cel-notes { background: var(--paper); border-top: 1px solid var(--line); }
.cel-notes__in { display: grid; gap: 28px; }
.cel-notes__intro { display: grid; gap: 14px; align-content: start; }
.cel-notes__intro p:not(.cel-eyebrow) { color: var(--muted); max-width: 46ch; }
.cel-notes__list { display: grid; gap: 18px; }
@media (min-width: 960px) {
  .cel-notes__in { grid-template-columns: 1fr 1.6fr; gap: 56px; }
  .cel-notes__intro { position: sticky; top: 130px; }
  .cel-notes__list { grid-template-columns: repeat(2, 1fr); gap: 22px 28px; }
}

/* ---------- Bands (archive and search headers) ---------- */
.cel-band {
  color: var(--paper); padding: clamp(28px, 5vw, 56px) 0 clamp(34px, 5vw, 60px);
  background: repeating-radial-gradient(ellipse at 90% 10%, transparent 0 24px, rgba(163, 201, 143, .08) 24px 25px), linear-gradient(160deg, var(--canopy-2), var(--canopy) 65%);
}
.cel-band .cel-wrap { display: grid; gap: 12px; }
.cel-band__title { font-size: var(--step-5); }
.cel-band__dek { max-width: 68ch; font-size: var(--step-1); color: color-mix(in srgb, var(--paper) 84%, var(--fern)); }
.cel-band__dek p + p { margin-top: .8em; }
.cel-band__dek a { color: var(--sun); }
.cel-band__count { font: 500 .78rem var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--sun); }
.cel-band .cel-crumbs a, .cel-band .cel-crumbs li { color: var(--fern); }
.cel-search--band { max-width: 520px; background: var(--paper); }

/* ---------- Breadcrumbs ---------- */
.cel-crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 8px; font-size: var(--step--1); color: var(--muted); }
.cel-crumbs li + li::before { content: "/"; margin-right: 8px; opacity: .5; }
.cel-crumbs a { color: inherit; text-decoration: none; }
.cel-crumbs a:hover { text-decoration: underline; }
.cel-crumbs [aria-current] { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 46ch; }

/* ---------- Article ---------- */
.cel-article__head { padding: clamp(24px, 4vw, 48px) 0 24px; }
.cel-article__head .cel-wrap { display: grid; gap: 14px; justify-items: start; }
.cel-article__title { font-size: var(--step-5); line-height: 1.05; }
.cel-article__dek { font-size: var(--step-2); line-height: 1.45; color: var(--muted); font-family: var(--sans); }
.cel-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: .88rem; color: var(--muted); }
.cel-meta a { color: var(--ink); }
.cel-article__hero { margin: 0 auto 8px; }
.cel-article__hero img { width: 100%; max-height: 640px; object-fit: cover; border-radius: 20px; }
.cel-article__hero figcaption { font-size: .85rem; color: var(--muted); margin-top: 8px; }
.cel-article__body { padding-block: 28px 56px; display: grid; gap: 28px; }

.cel-summary { background: var(--paper); border: 1px solid var(--line); border-left: 4px solid var(--moss); border-radius: 12px; padding: 18px 20px; display: grid; gap: 6px; font-size: var(--step-1); }
.cel-toc { border: 1px solid var(--line); border-radius: 12px; padding: 16px 20px; display: grid; gap: 8px; }
.cel-toc ol { padding-left: 1.2em; display: grid; gap: 4px; }
.cel-toc a { color: var(--ink); text-decoration: none; }
.cel-toc a:hover { color: var(--morpho); text-decoration: underline; }

.cel-prose { font-size: var(--step-1); line-height: 1.72; }
.cel-prose::after { content: ""; display: table; clear: both; }
.cel-prose > * + * { margin-top: 1.1em; }
.cel-prose h2 { font-size: var(--step-3); margin-top: 1.8em; }
.cel-prose h3 { font-size: var(--step-2); margin-top: 1.5em; }
.cel-prose h2 + *, .cel-prose h3 + * { margin-top: .6em; }
.cel-prose ul, .cel-prose ol { padding-left: 1.3em; }
.cel-prose li + li { margin-top: .35em; }
.cel-prose blockquote { margin: 1.6em 0; padding: 4px 0 4px 20px; border-left: 3px solid var(--fern); font-family: var(--serif); font-size: var(--step-2); line-height: 1.4; }
.cel-prose img { border-radius: 12px; }
.cel-prose .alignright, .cel-prose .alignleft { margin: 0 0 1em; max-width: 100%; }
@media (min-width: 640px) {
  .cel-prose .alignright { float: right; margin: .3em 0 1em 1.6em; max-width: 46%; }
  .cel-prose .alignleft { float: left; margin: .3em 1.6em 1em 0; max-width: 46%; }
}
.cel-prose .aligncenter { margin-inline: auto; }
.cel-prose .wp-caption { max-width: 100%; }
.cel-prose .wp-caption-text, .cel-prose figcaption { font-size: .85rem; color: var(--muted); margin-top: 6px; line-height: 1.4; }
.cel-prose .gallery { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .cel-prose .gallery { grid-template-columns: repeat(3, 1fr); } }
.cel-prose .gallery-item { margin: 0; }
.cel-prose .gallery img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.cel-embed { position: relative; aspect-ratio: 16 / 9; clear: both; border-radius: 14px; overflow: hidden; background: var(--canopy); }
.cel-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.cel-table { overflow-x: auto; clear: both; }
.cel-table table { border-collapse: collapse; width: 100%; font-size: .95rem; }
.cel-table td, .cel-table th { border: 1px solid var(--line); padding: 10px 12px; text-align: left; vertical-align: top; }

/* "At a glance" lodge facts (written into old articles by the content pass) */
.cel-facts { clear: both; background: color-mix(in srgb, var(--fern) 18%, var(--paper)); border-radius: 14px; padding: 18px 20px; display: grid; gap: 10px; }
.cel-facts dl { display: grid; gap: 8px 18px; margin: 0; }
@media (min-width: 640px) { .cel-facts dl { grid-template-columns: max-content 1fr; } }
.cel-facts dt { font: 500 .74rem/1.6 var(--mono); text-transform: uppercase; letter-spacing: .1em; color: var(--moss); }
.cel-facts dd { margin: 0; font-size: 1rem; }

.cel-faq { display: grid; gap: 10px; }
.cel-faq h2 { font-size: var(--step-3); margin-bottom: 6px; }
.cel-faq details { background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; }
.cel-faq summary { cursor: pointer; font-weight: 600; font-size: var(--step-1); }
.cel-faq details[open] summary { margin-bottom: 8px; }
.cel-faq details > div p + p { margin-top: .7em; }

.cel-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.cel-tags span { font: 500 .72rem var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 5px 10px; }
.cel-note { font-size: .92rem; color: var(--muted); border-top: 1px solid var(--line); padding-top: 18px; }
.cel-related { background: var(--paper); border-top: 1px solid var(--line); }

.cel-article--page .cel-article__body { padding-top: 8px; }

/* ---------- Pagination ---------- */
.pagination { margin-top: 44px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.pagination .page-numbers { min-width: 42px; height: 42px; display: inline-grid; place-items: center; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--paper); color: var(--canopy); text-decoration: none; font-weight: 600; }
.pagination .page-numbers.current, .pagination a.page-numbers:hover { background: var(--canopy); color: var(--paper); border-color: var(--canopy); }

/* ---------- Footer ---------- */
.cel-footer { background: var(--canopy); color: color-mix(in srgb, var(--paper) 78%, var(--fern)); padding-top: clamp(44px, 6vw, 72px); }
.cel-footer__grid { display: grid; gap: 32px; grid-template-columns: repeat(2, 1fr); }
.cel-footer__about { grid-column: 1 / -1; display: grid; gap: 14px; max-width: 52ch; }
.cel-brand--footer, .cel-brand--footer:hover { color: var(--paper); }
.cel-brand--footer .cel-mark { color: var(--fern); }
.cel-brand--footer .cel-brand__name em { color: var(--fern); }
.cel-footer__col { display: grid; gap: 12px; align-content: start; }
.cel-footer__col ul { list-style: none; display: grid; gap: 7px; }
.cel-footer a { color: inherit; text-decoration: none; }
.cel-footer a:hover { color: var(--paper); text-decoration: underline; }
.cel-footer .cel-eyebrow { color: var(--fern); }
.cel-footer__base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; margin-top: 44px; padding-block: 20px 28px; border-top: 1px solid rgba(163, 201, 143, .2); font-size: .82rem; }
@media (min-width: 900px) {
  .cel-footer__grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 48px; }
  .cel-footer__about { grid-column: auto; }
}

/* ---------- WordPress bits ---------- */
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.wpcf7 input:not([type=submit]), .wpcf7 textarea { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; font: inherit; background: var(--paper); }
input[type=submit] { background: var(--canopy); color: var(--paper); border: 0; padding: 12px 22px; border-radius: 999px; font: 600 1rem var(--sans); cursor: pointer; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
