/* Shared structure of the three demo sites (patch 0665). Each site's style.css sets the tokens below and its own touches.
   Phone first; animations are subtle and switched off with prefers-reduced-motion. */
:root {
  --bg: #fff; --ink: #1d1d1f; --muted: #5d5d66; --surface: #f6f6f6; --line: #e4e4e7;
  --accent: #333; --accent-ink: #fff; --radius: 14px; --wrap: 1120px; --gap: clamp(16px, 4vw, 32px);
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; --font-display: var(--font-body);
  --hero-overlay: linear-gradient(180deg, rgba(0,0,0,.15), rgba(0,0,0,.55));
  --hero-ink: #fff; --shadow: 0 10px 30px rgba(0,0,0,.08);
  --top-offset: 72px;   /* the sticky header (.top-in, 64px) plus a little air: what scrolls into view lands below it */
}
*, *::before, *::after { box-sizing: border-box; }
/* scroll-padding (not scroll-margin on each target): it also holds for what a widget scrolls into view or focuses inside its
   own shadow root, such as the heading of a new step, which never slides under the sticky header */
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scroll-padding-top: var(--top-offset); }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1rem/1.6 var(--font-body); overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.15; margin: 0 0 .5em; }
h1 { font-size: clamp(2.1rem, 7vw, 4rem); }
h2 { font-size: clamp(1.6rem, 4.5vw, 2.5rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
a { color: inherit; }
.wrap { width: min(100% - 2 * 16px, var(--wrap)); margin-inline: auto; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--bg); padding: 8px 12px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

/* header */
.top { position: sticky; top: 0; z-index: 30; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid transparent; transition: border-color .3s, box-shadow .3s; }
.top.scrolled { border-color: var(--line); box-shadow: 0 4px 18px rgba(0,0,0,.05); }
.top-in { display: flex; align-items: center; gap: 12px; min-height: 64px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; margin-right: auto; min-width: 0; }
.logo svg { width: 34px; height: 34px; flex: none; }
.logo span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nav { display: none; gap: 22px; }
.nav a { text-decoration: none; color: var(--muted); font-weight: 500; }
.nav a:hover { color: var(--ink); }
.langs { display: inline-flex; align-items: center; gap: 4px; font-size: .85rem; color: var(--muted); }
.langs a { text-decoration: none; padding: 6px 4px; border-radius: 6px; font-weight: 600; min-width: 28px; text-align: center; }
.langs a[aria-current="page"] { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 2px; text-decoration-color: var(--accent); }
@media (min-width: 900px) { .nav { display: flex; } }
@media (max-width: 420px) { .top .btn-small { display: none; } }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 2px solid var(--accent);
  background: var(--accent); color: var(--accent-ink); font-weight: 600; text-decoration: none; transition: transform .25s ease, box-shadow .25s ease, background .25s; }
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 20px color-mix(in srgb, var(--accent) 35%, transparent); }
.btn-ghost { background: transparent; color: var(--hero-ink); border-color: color-mix(in srgb, var(--hero-ink) 70%, transparent); }
.btn-small { min-height: 40px; padding: 0 16px; font-size: .92rem; }

/* hero: the photo zooms in very slowly */
.hero { position: relative; isolation: isolate; min-height: min(86vh, 760px); display: grid; align-items: end; color: var(--hero-ink); overflow: hidden; }
.hero-media { position: absolute; inset: 0; z-index: -1; }
.hero-media::after { content: ""; position: absolute; inset: 0; background: var(--hero-overlay); }
.hero-img { width: 100%; height: 100%; object-fit: cover; transform-origin: 60% 40%; animation: heroZoom 24s ease-out both; }
@keyframes heroZoom { from { transform: scale(1.0); } to { transform: scale(1.09); } }
.hero-in { padding-block: 120px 56px; max-width: 760px; margin-left: max(16px, calc((100% - var(--wrap)) / 2)); }
.hero .kicker { text-transform: uppercase; letter-spacing: .14em; font-size: .8rem; font-weight: 600; opacity: .9; }
.hero .lead { font-size: clamp(1.05rem, 2.6vw, 1.25rem); max-width: 56ch; opacity: .95; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 24px 0; }
.hero-badge { max-width: 360px; }
.hero > *, .hero-in > * { animation: rise .9s cubic-bezier(.2,.7,.2,1) both; }
.hero-in > :nth-child(2) { animation-delay: .1s; } .hero-in > :nth-child(3) { animation-delay: .2s; } .hero-in > :nth-child(4) { animation-delay: .3s; } .hero-in > :nth-child(5) { animation-delay: .45s; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* sections: their anchor offset is html's scroll-padding-top (--top-offset) */
.intro { display: grid; gap: var(--gap); padding-block: clamp(56px, 9vw, 110px); align-items: center; }
.intro-img { border-radius: var(--radius); width: 100%; aspect-ratio: 4 / 3; object-fit: cover; box-shadow: var(--shadow); }
.intro-text p { font-size: 1.1rem; color: var(--muted); }
@media (min-width: 860px) { .intro { grid-template-columns: 1.1fr 1fr; } }
.offer, .book, .team, .reviews, .contact { padding-block: clamp(56px, 9vw, 100px); }
.sec-head { max-width: 640px; margin-bottom: 32px; }
.sec-head p { color: var(--muted); font-size: 1.05rem; }
.cards { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.card { background: var(--surface); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); transition: transform .35s ease, box-shadow .35s ease; }
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card-img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; transition: transform .8s ease; }
.card:hover .card-img { transform: scale(1.04); }
.card-body { padding: 18px 20px 20px; }
.card-body p { color: var(--muted); margin: 0; }
.widget-frame { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(12px, 3vw, 28px); min-height: 120px; }
.people { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 140px), 1fr)); }
.person { margin: 0; text-align: center; }
.person img { border-radius: var(--radius); aspect-ratio: 4 / 5; object-fit: cover; width: 100%; transition: transform .4s ease; }
.person:hover img { transform: translateY(-4px) rotate(-.6deg); }
.person figcaption { padding-top: 12px; display: grid; gap: 2px; }
.person figcaption span { color: var(--muted); font-size: .95rem; }
.contact-in { display: grid; gap: var(--gap); }
@media (min-width: 860px) { .contact-in { grid-template-columns: 1fr 1fr; } }
.foot { border-top: 1px solid var(--line); padding-block: 32px 96px; color: var(--muted); font-size: .92rem; }
.foot-in p { margin: 0 0 6px; }
.demo-note { font-size: .8rem; }
.credits { font-size: .8rem; margin-top: 8px; }
.credits ul { padding-left: 18px; margin: 6px 0 0; }

/* sections slide in when they come into view (site.js adds .in); without JavaScript everything simply shows */
.js .reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1); transition-delay: calc(var(--d, 0) * 90ms); }
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}
