/* The White Medispa — cinematic Italian sanctuary
 * Fixed full-viewport hero (image + slogan); the cream page rises over it on scroll.
 */

@import url("/css/tokens.css");

/* ============================ Reset ============================ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; overflow-x: clip; scroll-behavior: smooth; }
body {
  margin: 0; overflow-x: clip;
  background: var(--color-ink-deep);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-size: var(--text-base); line-height: 1.65; font-weight: 400;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
img { display: block; max-width: 100%; height: auto; }
h1,h2,h3,h4,p,figure,blockquote,dl,dd { margin: 0; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 3px; }

.shell { width: 100%; max-width: var(--shell); margin-inline: auto; padding-inline: var(--gutter); }
.shell-wide { width: 100%; max-width: var(--shell-wide); margin-inline: auto; padding-inline: var(--gutter); }
.display { font-family: var(--font-display); font-weight: 400; }

/* ============================ Labels / type ============================ */
.label {
  font-family: var(--font-body); font-size: var(--text-xs); font-weight: 400;
  letter-spacing: 0.34em; text-transform: uppercase; color: var(--color-neutral);
}
.label--light { color: var(--color-on-dark); text-shadow: 0 1px 18px rgba(16, 11, 8, 0.55); }
.lede { font-size: var(--text-md); line-height: 1.6; color: var(--color-muted); max-width: 48ch; }

.ulink {
  position: relative; color: inherit;
  background-image: linear-gradient(currentColor, currentColor);
  background-size: 0% 1px; background-repeat: no-repeat; background-position: left 100%;
  transition: background-size var(--dur-mid) var(--ease-out); padding-bottom: 2px;
}
@media (hover: hover) and (pointer: fine) { .ulink:hover { background-size: 100% 1px; } }
.ulink:focus-visible { background-size: 100% 1px; }

/* ============================ Buttons / badges ============================ */
.btn {
  --_bg: var(--color-ink-deep); --_fg: var(--color-on-dark);
  display: inline-flex; align-items: center; gap: var(--space-2xs);
  font-family: var(--font-body); font-size: var(--text-xs); font-weight: 500;
  letter-spacing: 0.18em; text-transform: uppercase; white-space: nowrap;
  padding: 1em 1.8em; background: var(--_bg); color: var(--_fg);
  border: var(--rule-hair) solid var(--_bg); border-radius: var(--radius-pill); cursor: pointer;
  transition: transform var(--dur-fast) var(--ease-out), background var(--dur-mid) var(--ease-soft), color var(--dur-mid) var(--ease-soft), border-color var(--dur-mid) var(--ease-soft);
}
.btn:active { transform: scale(0.97); }
.btn--line { --_bg: transparent; --_fg: currentColor; border-color: currentColor; }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { background: var(--color-accent); border-color: var(--color-accent); color: var(--color-on-dark); }
  .btn--line:hover { background: var(--color-on-dark); border-color: var(--color-on-dark); color: var(--color-ink-deep); }
}

.badges { display: flex; flex-wrap: wrap; gap: var(--space-xs); align-items: center; }
.badge {
  display: inline-flex; align-items: center; gap: 0.6em; padding: 0.7em 1.15em;
  border: var(--rule-hair) solid var(--color-ink-deep); border-radius: var(--radius-md);
  background: var(--color-ink-deep); color: var(--color-on-dark); min-width: 0;
  transition: transform var(--dur-fast) var(--ease-out), background var(--dur-mid) var(--ease-soft);
}
.badge:active { transform: scale(0.97); }
@media (hover: hover) and (pointer: fine) { .badge:hover { background: var(--color-accent); border-color: var(--color-accent); } }
.badge svg { flex: none; width: 21px; height: 21px; }
.badge__txt { display: flex; flex-direction: column; line-height: 1.1; }
.badge__txt small { font-size: 0.6rem; letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.72; }
.badge__txt span { font-family: var(--font-display); font-weight: 500; font-size: var(--text-md); }
.badge--light { background: var(--color-on-dark); color: var(--color-ink-deep); border-color: var(--color-on-dark); }
@media (hover: hover) and (pointer: fine) { .badge--light:hover { background: var(--color-accent); border-color: var(--color-accent); color: var(--color-on-dark); } }

/* ============================ Nav ============================ */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 30; transition: background var(--dur-mid) var(--ease-soft), border-color var(--dur-mid) var(--ease-soft), color var(--dur-mid) var(--ease-soft); border-bottom: var(--rule-hair) solid transparent; color: var(--color-on-dark); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-md); padding-block: var(--space-md); }
.nav[data-solid="true"] { background: color-mix(in oklch, var(--color-paper) 92%, transparent); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom-color: var(--color-rule-soft); color: var(--color-ink); }
.wordmark { font-family: var(--font-display); font-weight: 500; font-size: var(--text-lg); letter-spacing: 0.02em; display: inline-flex; align-items: baseline; gap: 0.4em; color: inherit; }
.wordmark b { font-weight: 500; font-style: italic; }
.nav__links { display: flex; align-items: center; gap: var(--space-lg); }
.nav__links a { font-family: var(--font-body); font-size: var(--text-xs); letter-spacing: 0.2em; text-transform: uppercase; color: inherit; opacity: 0.82; transition: opacity var(--dur-mid) var(--ease-soft); }
.nav__links a:hover, .nav__links a[aria-current="page"] { opacity: 1; }
.nav__right { display: flex; align-items: center; gap: var(--space-md); }
.lang { display: inline-flex; gap: 0.4em; font-size: var(--text-xs); letter-spacing: 0.12em; align-items: center; color: inherit; opacity: 0.8; }
.lang a[aria-current="true"] { font-weight: 600; opacity: 1; }
.lang span { opacity: 0.4; }
@media (max-width: 900px) { .nav__links { display: none; } }
@media (max-width: 560px) { .wordmark { font-size: var(--text-md); } .nav .btn { padding: 0.85em 1.25em; } .nav__right { gap: var(--space-sm); } }
@media (max-width: 430px) { .nav .lang { display: none; } }

/* ============================ Fixed cinematic hero ============================ */
.hero { position: fixed; inset: 0; height: 100svh; z-index: 1; overflow: hidden; background: var(--color-ink-deep); }
.hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 42%; will-change: transform; animation: kenburns 28s ease-in-out infinite alternate; }
@keyframes kenburns { from { transform: scale(1.03) translate3d(0, 0, 0); } to { transform: scale(1.1) translate3d(-1.6%, -1.4%, 0); } }
.hero::after { content: ""; position: absolute; inset: 0; background: var(--scrim); z-index: 1; }
.hero__inner { position: relative; z-index: 2; height: 100%; display: grid; align-content: center; justify-items: center; text-align: center; gap: var(--space-lg); padding: var(--space-2xl) var(--gutter); color: var(--color-on-dark); }
.hero__label { letter-spacing: 0.4em; text-shadow: 0 1px 24px rgba(18,13,10,0.55); }
.hero h1 { font-family: var(--font-display); font-weight: 300; font-size: var(--text-hero); line-height: 1.04; letter-spacing: 0.005em; max-width: 18ch; text-wrap: balance; text-shadow: 0 1px 40px rgba(20,15,12,0.35); }
.hero h1 em { font-style: italic; }
.hero__cue { position: absolute; bottom: var(--space-lg); left: 50%; transform: translateX(-50%); z-index: 2; color: var(--color-on-dark); display: grid; justify-items: center; gap: var(--space-2xs); }
.hero__cue .label { color: var(--color-on-dark); text-shadow: 0 1px 18px rgba(16, 11, 8, 0.55); }
.hero__cue i { display: block; width: 1px; height: 46px; background: linear-gradient(var(--color-on-dark-mut), transparent); animation: cue 2.4s var(--ease-in-out) infinite; transform-origin: top; }
@keyframes cue { 0%,100% { transform: scaleY(0.4); opacity: 0.4; } 50% { transform: scaleY(1); opacity: 1; } }

/* the page panel that rises over the hero */
.site { position: relative; z-index: 2; margin-top: 100svh; background: var(--color-paper); box-shadow: 0 -40px 80px rgba(20,15,12,0.18); }
@media (prefers-reduced-motion: reduce) { .hero__cue i { animation: none; } }

/* pages without the cinematic hero (treatments / visit) */
.site--flat { margin-top: 0; box-shadow: none; }
.pagehero { position: relative; min-height: 64svh; display: grid; align-items: end; overflow: hidden; color: var(--color-on-dark); }
.pagehero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pagehero::after { content: ""; position: absolute; inset: 0; background: var(--scrim-soft); }
.pagehero__inner { position: relative; z-index: 1; padding-block: var(--space-2xl); display: grid; gap: var(--space-md); text-shadow: 0 1px 28px rgba(18,13,10,0.5); }
.pagehero h1 { font-family: var(--font-display); font-weight: 300; font-size: var(--text-display); line-height: 1.04; max-width: 16ch; }
.pagehero p { color: var(--color-on-dark-mut); max-width: 50ch; }

/* ============================ Sections ============================ */
.section { padding-block: var(--space-3xl); }
.section--tight { padding-block: var(--space-2xl); }
.eyebrow-row { display: grid; gap: var(--space-md); max-width: var(--measure); margin-bottom: var(--space-2xl); }
.eyebrow-row h2 { font-family: var(--font-display); font-weight: 300; font-size: var(--text-display-s); line-height: 1.08; color: var(--color-ink-deep); }
.eyebrow-row p { color: var(--color-muted); }

/* opening statement (poetic) */
.statement { padding-block: var(--space-3xl); text-align: center; }
.statement p { font-family: var(--font-display); font-weight: 300; font-size: clamp(1.8rem, 4vw, 3.4rem); line-height: 1.28; color: var(--color-ink-deep); max-width: 22ch; margin-inline: auto; }
.statement p em { font-style: italic; color: var(--color-muted); }

/* full-bleed image chapter (parallax) */
.chapter { position: relative; height: 92svh; overflow: hidden; display: grid; align-items: end; color: var(--color-on-dark); }
.chapter__img { position: absolute; left: 0; right: 0; top: -12%; height: 124%; width: 100%; object-fit: cover; will-change: transform; }
.chapter::after { content: ""; position: absolute; inset: 0; background: var(--scrim-soft); }
.chapter__inner { position: relative; z-index: 1; padding-block: var(--space-2xl); display: grid; gap: var(--space-sm); text-shadow: 0 1px 28px rgba(18,13,10,0.5); }
.chapter__title { font-family: var(--font-display); font-weight: 300; font-style: italic; font-size: clamp(2rem, 4.5vw, 3.6rem); line-height: 1.12; max-width: 20ch; }
.chapter__sub { color: var(--color-on-dark-mut); max-width: 46ch; }

/* ============================ Rituals (home treatments) ============================ */
.rituals { display: grid; }
.ritual { display: grid; gap: var(--space-lg); align-items: center; padding-block: var(--space-2xl); border-top: var(--rule-hair) solid var(--color-rule-soft); }
.ritual:last-child { border-bottom: var(--rule-hair) solid var(--color-rule-soft); }
.ritual__media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; }
.ritual__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.6s var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .ritual:hover .ritual__media img { transform: scale(1.05); } }
.ritual__index { font-family: var(--font-display); font-style: italic; font-size: var(--text-md); color: var(--color-accent); }
.ritual__title { font-family: var(--font-display); font-weight: 400; font-size: var(--text-2xl); color: var(--color-ink-deep); line-height: 1.05; margin-top: var(--space-2xs); }
.ritual__items { color: var(--color-muted); margin-top: var(--space-sm); }
.ritual__link { display: inline-flex; align-items: center; gap: 0.5em; margin-top: var(--space-md); font-family: var(--font-body); font-size: var(--text-xs); letter-spacing: 0.2em; text-transform: uppercase; color: var(--color-ink-deep); }
.ritual__link span { transition: transform var(--dur-mid) var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .ritual__link:hover span { transform: translateX(5px); } }
@media (min-width: 860px) {
  .ritual { grid-template-columns: 1fr 1fr; gap: var(--space-2xl); }
  .ritual--rev .ritual__media { order: 2; }
}

/* ============================ Booking · slim, light, unobtrusive ============================ */
.book { background: var(--color-paper-2); border-block: var(--rule-hair) solid var(--color-rule-soft); }
.book__inner { display: grid; gap: var(--space-md); padding-block: var(--space-2xl); justify-items: start; }
.book h2 { font-family: var(--font-display); font-weight: 400; font-size: var(--text-2xl); line-height: 1.08; color: var(--color-ink-deep); }
.book p { color: var(--color-muted); max-width: 46ch; }
.book .label { color: var(--color-neutral); }
.book__badges { margin-top: var(--space-sm); }

/* ============================ Treatments menu ============================ */
.menu { display: grid; gap: var(--space-3xl); }
.group { display: grid; gap: var(--space-lg); }
.group__top { display: grid; gap: var(--space-2xs); }
.group__index { font-family: var(--font-display); font-style: italic; font-size: var(--text-md); color: var(--color-accent); }
.group__title { font-family: var(--font-display); font-weight: 400; font-size: var(--text-3xl); color: var(--color-ink-deep); line-height: 1; }
.group__media { aspect-ratio: 3 / 2; overflow: hidden; }
.group__media img { width: 100%; height: 100%; object-fit: cover; }
.group__list { display: grid; }
.treat { display: grid; gap: var(--space-2xs); padding-block: var(--space-md); border-top: var(--rule-hair) solid var(--color-rule-soft); }
.treat:last-child { border-bottom: var(--rule-hair) solid var(--color-rule-soft); }
.treat__name { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.4em var(--space-sm); }
.treat__name h3 { font-family: var(--font-display); font-weight: 500; font-size: var(--text-xl); color: var(--color-ink-deep); }
.treat__tag { font-family: var(--font-body); font-size: var(--text-xs); letter-spacing: 0.16em; text-transform: uppercase; color: var(--color-neutral); }
.treat p { color: var(--color-muted); max-width: 62ch; }
@media (min-width: 880px) {
  .group { grid-template-columns: 0.8fr 1.2fr; gap: var(--space-2xl); align-items: start; }
  .group--rev .group__media { order: 2; }
  .group__media { position: sticky; top: 110px; aspect-ratio: 4 / 5; }
}
.pricing-note { margin-top: var(--space-2xl); padding-top: var(--space-lg); border-top: var(--rule-hair) solid var(--color-rule); display: grid; gap: var(--space-2xs); max-width: var(--measure); }
.pricing-note dt { font-family: var(--font-body); font-size: var(--text-xs); letter-spacing: 0.2em; text-transform: uppercase; color: var(--color-neutral); }
.pricing-note dd { font-family: var(--font-display); font-size: var(--text-xl); color: var(--color-ink-deep); }
.pricing-note .small { font-family: var(--font-body); font-size: var(--text-sm); color: var(--color-muted); }

/* ============================ Visit ============================ */
.visit__grid { display: grid; gap: var(--space-2xl); }
.info { display: grid; gap: var(--space-lg); align-content: start; }
.info__row { display: grid; gap: var(--space-3xs); padding-top: var(--space-sm); border-top: var(--rule-hair) solid var(--color-rule-soft); }
.info__row dt { font-family: var(--font-body); font-size: var(--text-xs); letter-spacing: 0.22em; text-transform: uppercase; color: var(--color-neutral); }
.info__row dd { font-family: var(--font-display); font-size: var(--text-xl); color: var(--color-ink-deep); line-height: 1.4; }
.info__sub { font-family: var(--font-body); font-size: var(--text-sm); color: var(--color-neutral); }
.info__hours { display: grid; gap: 4px; font-family: var(--font-body); font-size: var(--text-base); color: var(--color-muted); }
.info__hours span b { color: var(--color-ink); font-weight: 500; }
.info__hours .closed { color: var(--color-neutral); }
.note { font-size: var(--text-sm); color: var(--color-neutral); font-style: italic; }
.visit__media { aspect-ratio: 4 / 5; overflow: hidden; }
.visit__media img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 880px) { .visit__grid { grid-template-columns: 1fr 0.85fr; gap: var(--space-3xl); align-items: start; } }

/* ============================ Footer ============================ */
.foot { background: var(--color-paper-2); border-top: var(--rule-hair) solid var(--color-rule); padding-block: var(--space-2xl) var(--space-xl); position: relative; z-index: 2; }
.foot__top { display: grid; gap: var(--space-xl); }
.foot__brand .wordmark { color: var(--color-ink-deep); font-size: var(--text-xl); }
.foot__tag { margin-top: var(--space-sm); color: var(--color-muted); max-width: 32ch; font-family: var(--font-display); font-size: var(--text-md); font-style: italic; }
.foot__social { display: flex; gap: var(--space-md); margin-top: var(--space-md); }
.foot__cols { display: grid; gap: var(--space-xl); }
.foot__col h4 { font-family: var(--font-body); font-size: var(--text-xs); letter-spacing: 0.2em; text-transform: uppercase; color: var(--color-neutral); margin-bottom: var(--space-sm); }
.foot__col p, .foot__col a { color: var(--color-muted); line-height: 1.8; }
.foot__col a { display: inline-block; }
.foot__bottom { display: flex; flex-wrap: wrap; gap: var(--space-sm) var(--space-lg); justify-content: space-between; align-items: baseline; margin-top: var(--space-2xl); padding-top: var(--space-md); border-top: var(--rule-hair) solid var(--color-rule-soft); }
.foot__bottom p { font-size: var(--text-xs); letter-spacing: 0.04em; color: var(--color-neutral); }
@media (min-width: 760px) { .foot__top { grid-template-columns: 1.3fr 1fr; } .foot__cols { grid-template-columns: repeat(2, 1fr); } }

/* ============================ Legal / privacy ============================ */
.legal { padding-top: calc(var(--space-2xl) + 64px); padding-bottom: var(--space-3xl); }
.legal__head { display: grid; gap: var(--space-md); max-width: var(--measure); margin-bottom: var(--space-xl); }
.legal h1 { font-family: var(--font-display); font-weight: 300; font-size: var(--text-display-s); line-height: 1.04; color: var(--color-ink-deep); }
.legal__head p { color: var(--color-neutral); }
.legal__body { max-width: var(--measure); display: grid; gap: var(--space-lg); }
.legal__body section { display: grid; gap: var(--space-xs); }
.legal h2 { font-family: var(--font-display); font-weight: 400; font-size: var(--text-xl); color: var(--color-ink-deep); }
.legal p, .legal li { color: var(--color-muted); }
.legal a { color: var(--color-ink-deep); text-decoration: underline; text-underline-offset: 2px; }
.legal ul { display: grid; gap: var(--space-3xs); padding-left: 1.1em; list-style: disc; }
.legal .updated { font-size: var(--text-sm); color: var(--color-neutral); font-style: italic; }

/* ============================ Reveal ============================ */
.reveal-on [data-reveal] { opacity: 0; transform: translateY(22px); transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out); transition-delay: var(--reveal-delay, 0ms); }
.reveal-on [data-reveal].is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .ritual__media img, .btn, .badge, .ulink, .hero__img, .chapter__img { transition: none; }
  .hero__img { animation: none; }
}

/* Lenis smooth scroll hooks */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-smooth [data-lenis-prevent] { overscroll-behavior: contain; }
.lenis.lenis-stopped { overflow: hidden; }

/* ============================ Mobile — tighten the stretch ============================ */
@media (max-width: 640px) {
  :root { --space-2xl: 3.25rem; --space-3xl: 4.25rem; --space-4xl: 5.5rem; }
  .hero h1 { font-size: clamp(2.5rem, 12vw, 3.4rem); }
  .chapter { height: auto; min-height: 58svh; }
  .chapter__inner { padding-block: var(--space-xl); }
  .statement { padding-block: var(--space-2xl); }
  .statement p { font-size: clamp(1.7rem, 7vw, 2.4rem); }
  .ritual { padding-block: var(--space-xl); gap: var(--space-md); }
  .pagehero { min-height: 56svh; }
  .foot { padding-top: var(--space-xl); }
  .foot__top { gap: var(--space-lg); }
  .foot__cols { gap: var(--space-lg); }
  .foot__bottom { margin-top: var(--space-lg); }
}

/* ============================ Touch targets (mobile / coarse pointer) ============================ */
@media (max-width: 640px), (pointer: coarse) {
  .nav .btn { padding-block: 1em; }
  .ritual__link { min-height: 44px; }
  .foot__col a, .foot__social a { display: inline-block; padding-block: 11px; }
  .info__row dd a, .pricing-note a { display: inline-block; padding-block: 4px; }
  .lang a { display: inline-block; padding: 6px 2px; }
  .nav__links a { padding-block: 8px; }
}
