/* ================================================================
   Rêve Beauty Store — Ottaviano (NA)
   Palette: Napoli Cream — cream base, espresso text,
   terracotta accent, champagne hairlines
   Type: Fraunces (display serif) + Manrope (sans)
   ================================================================ */

:root {
  --cream: #F5EEE5;
  --ivory: #FBF7F1;
  --espresso: #2B221C;
  --espresso-90: rgba(43, 34, 28, .9);
  --terracotta: #B4674D;
  --terracotta-text: #9E5540;
  --champagne: #C9A667;
  --muted: #6E6055;
  --hairline: rgba(43, 34, 28, .14);
  --hairline-light: rgba(245, 238, 229, .18);
  --serif: "Fraunces", Georgia, serif;
  --sans: "Manrope", -apple-system, BlinkMacSystemFont, sans-serif;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --wrap: 1200px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: auto; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  font-family: var(--sans);
  font-weight: 400;
  background: var(--cream);
  color: var(--espresso);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, video { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
em { font-style: italic; }

.wrap { width: min(var(--wrap), 92vw); margin: 0 auto; }
section[id] { scroll-margin-top: 90px; }
.wrap-wide { width: min(1400px, 94vw); margin: 0 auto; }
.wrap-narrow { width: min(760px, 90vw); margin: 0 auto; text-align: center; }

::selection { background: var(--terracotta); color: var(--ivory); }

/* ---------------- Loader ---------------- */
.loader {
  position: fixed; inset: 0; z-index: 200;
  background: var(--espresso);
  display: flex; align-items: center; justify-content: center;
  /* failsafe: if JS never removes the curtain, CSS fades it out */
  animation: loader-bail .6s ease 3.4s forwards;
}
@keyframes loader-bail { to { opacity: 0; visibility: hidden; } }
.loader-logo {
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-size: clamp(42px, 7vw, 84px); color: var(--cream);
  opacity: 0;
}

/* ---------------- Cursor ---------------- */
.cursor {
  position: fixed; top: 0; left: 0; z-index: 150;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--terracotta);
  pointer-events: none;
  transition: width .35s var(--ease), height .35s var(--ease), opacity .3s;
  opacity: 0;
  mix-blend-mode: multiply;
}
.cursor.is-on { opacity: .85; }
.cursor.is-hover { width: 52px; height: 52px; opacity: .28; }
@media (pointer: coarse) { .cursor { display: none; } }

/* ---------------- Nav ---------------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 26px 0;
  transition: padding .45s var(--ease), background .45s, box-shadow .45s;
}
.nav.is-scrolled {
  padding: 12px 0;
  background: rgba(251, 247, 241, .88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--hairline);
}
.nav-inner {
  width: min(1400px, 94vw); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.logo {
  font-family: var(--serif); font-style: italic; font-weight: 500;
  font-size: 30px; letter-spacing: .01em; line-height: 1;
  display: flex; align-items: baseline; gap: 10px;
}
.logo-sub {
  font-family: var(--sans); font-style: normal; font-weight: 500;
  font-size: 10px; letter-spacing: .32em; text-transform: uppercase;
  color: var(--muted);
}
.nav-links { display: flex; gap: clamp(16px, 2.5vw, 36px); }
.nav-links a {
  font-size: 13px; font-weight: 500; letter-spacing: .14em; text-transform: uppercase;
  position: relative; padding: 4px 0;
  white-space: nowrap;
}
.nav-links a::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 100%; height: 1px; background: var(--champagne);
  transform: scaleX(0); transform-origin: right;
  transition: transform .45s var(--ease);
}
.nav-links a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav-right { display: flex; align-items: center; gap: 20px; }

.lang-toggle {
  background: none; border: none; cursor: pointer;
  font-family: var(--sans); font-size: 12px; font-weight: 600;
  letter-spacing: .12em; color: var(--muted);
  display: flex; gap: 5px; align-items: center; padding: 6px 2px;
}
.lang-toggle span { transition: color .3s; }
.lang-toggle .active { color: var(--espresso); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; text-decoration-color: var(--champagne); }
.lang-sep { color: var(--hairline); }

/* ---------------- Buttons ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--sans); font-size: 13px; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase;
  padding: 16px 34px; border-radius: 999px;
  border: 1px solid var(--espresso);
  transition: background .4s var(--ease), color .4s var(--ease), border-color .4s;
  will-change: transform;
}
.btn-solid { background: var(--espresso); color: var(--cream); }
.btn-solid:hover { background: var(--terracotta); border-color: var(--terracotta); color: var(--ivory); }
.btn-ghost { background: transparent; color: var(--espresso); }
.btn-ghost:hover { background: var(--espresso); color: var(--cream); }
.btn-nav { padding: 11px 24px; font-size: 11px; }
.btn-cream { background: var(--cream); color: var(--espresso); border-color: var(--cream); }
.btn-cream:hover { background: var(--champagne); border-color: var(--champagne); color: var(--espresso); }
.btn-big { padding: 20px 44px; font-size: 14px; }
.wa-ico { width: 19px; height: 19px; flex: none; }

/* ---------------- Burger / mobile menu ---------------- */
.nav-burger { display: none; background: none; border: none; cursor: pointer; width: 34px; height: 26px; position: relative; z-index: 130; }
.nav-burger span {
  position: absolute; left: 4px; right: 4px; height: 2px; background: var(--espresso);
  transition: transform .4s var(--ease), top .4s var(--ease);
}
.nav-burger span:nth-child(1) { top: 8px; }
.nav-burger span:nth-child(2) { top: 16px; }
.nav-burger.is-open span:nth-child(1) { top: 12px; transform: rotate(45deg); }
.nav-burger.is-open span:nth-child(2) { top: 12px; transform: rotate(-45deg); }

.mobile-menu {
  position: fixed; inset: 0; z-index: 120;
  background: var(--ivory);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 30px;
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .45s var(--ease), visibility .45s;
}
.mobile-menu.is-open { opacity: 1; visibility: visible; pointer-events: auto; }
.mobile-menu-logo {
  position: absolute; top: 22px; left: 4vw;
  font-family: var(--serif); font-style: italic; font-weight: 500; font-size: 30px;
}
.mobile-menu > a:not(.btn) {
  font-family: var(--serif); font-size: 32px; font-weight: 400;
}

/* ---------------- Hero ---------------- */
.hero {
  min-height: 100svh;
  display: flex; align-items: center;
  padding: 140px 0 80px;
  position: relative;
}
.hero-inner {
  width: min(var(--wrap), 92vw); margin: 0 auto;
  display: grid; grid-template-columns: 1.15fr .85fr;
  align-items: center; gap: clamp(40px, 6vw, 90px);
}
.eyebrow {
  font-size: 12px; font-weight: 600; letter-spacing: .28em; text-transform: uppercase;
  color: var(--terracotta-text); margin-bottom: 26px;
}
.eyebrow-light { color: var(--champagne); }
.hero-title {
  font-family: var(--serif); font-weight: 300;
  font-size: clamp(52px, 7.6vw, 118px);
  line-height: 1.02; letter-spacing: -0.015em;
}
.hero-title em { font-weight: 400; color: var(--terracotta); }
.hero-title .w { display: inline-block; overflow: hidden; vertical-align: bottom; }
.hero-title .w > span { display: inline-block; will-change: transform; }
.hero-sub {
  margin-top: 30px; max-width: 46ch;
  font-size: clamp(16px, 1.5vw, 19px); font-weight: 300; color: var(--muted);
}
.hero-cta { margin-top: 44px; display: flex; gap: 16px; flex-wrap: wrap; }

.hero-media { position: relative; justify-self: end; width: 100%; max-width: 460px; }
.hero-arch {
  border-radius: 999px 999px 14px 14px;
  overflow: hidden;
  aspect-ratio: 4 / 5.6;
  background: var(--espresso);
  clip-path: inset(0 0 0 0 round 999px 999px 14px 14px);
}
.hero-arch video, .hero-arch img { width: 100%; height: 100%; object-fit: cover; }
.hero-badge {
  position: absolute; right: 20px; bottom: 24px;
  width: 122px; height: 122px;
  background: var(--cream); border-radius: 50%;
  box-shadow: 0 10px 34px rgba(43, 34, 28, .22);
}
.hero-badge svg { animation: spin 22s linear infinite; }
.hero-badge text {
  font-family: var(--sans); font-size: 10.5px; font-weight: 600;
  letter-spacing: .24em; fill: var(--espresso);
}
@keyframes spin { to { transform: rotate(360deg); } }

.hero-scrollcue {
  position: absolute; bottom: 0; left: 50%;
  width: 1px; height: 72px; overflow: hidden;
}
.scrollcue-line {
  display: block; width: 1px; height: 100%;
  background: var(--espresso);
  animation: cue 2.2s var(--ease) infinite;
}
@keyframes cue {
  0% { transform: translateY(-100%); }
  55% { transform: translateY(0); }
  100% { transform: translateY(100%); }
}

/* ---------------- Marquee ---------------- */
.marquee {
  border-top: 1px solid var(--hairline);
  border-bottom: 1px solid var(--hairline);
  overflow: hidden; padding: 22px 0;
  background: var(--ivory);
}
.marquee-track {
  display: flex; align-items: center;
  width: max-content;
  animation: marquee 36s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
/* margin instead of gap so the duplicated track's 50% point lands exactly on the seam */
.marquee-track span, .marquee-track i { margin-right: 48px; }
.marquee-track span {
  font-family: var(--serif); font-style: italic; font-weight: 300;
  font-size: clamp(20px, 2.2vw, 30px); color: var(--espresso); white-space: nowrap;
}
.marquee-track i { font-style: normal; color: var(--champagne); font-size: 14px; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------------- Philosophy ---------------- */
.philosophy { padding: clamp(110px, 14vw, 190px) 0; }
.phil-mark { display: block; color: var(--champagne); font-size: 18px; margin-bottom: 36px; }
.phil-lead {
  font-family: var(--serif); font-weight: 300;
  font-size: clamp(26px, 3.4vw, 44px); line-height: 1.28; letter-spacing: -0.01em;
}
.phil-lead em { color: var(--terracotta); }
.phil-dialect {
  margin-top: 40px;
  font-family: var(--serif); font-style: italic; font-weight: 300;
  font-size: clamp(16px, 1.6vw, 20px); color: var(--muted);
}

/* ---------------- Sections shared ---------------- */
.section-head { margin-bottom: clamp(48px, 6vw, 90px); }
.section-title {
  font-family: var(--serif); font-weight: 300;
  font-size: clamp(38px, 4.6vw, 68px); line-height: 1.05; letter-spacing: -0.015em;
}
.section-title em { color: var(--terracotta); font-weight: 400; }

/* ---------------- Services ---------------- */
.services { padding: 0 0 clamp(110px, 13vw, 180px); position: relative; }
.svc-list { border-top: 1px solid var(--hairline); }
.svc-item {
  display: grid; grid-template-columns: 80px 1fr auto;
  align-items: center; gap: 28px;
  padding: clamp(30px, 4vw, 52px) 8px;
  border-bottom: 1px solid var(--hairline);
  transition: padding-left .5s var(--ease), background .5s;
}
.svc-item:hover { padding-left: 28px; background: var(--ivory); }
.svc-num {
  font-family: var(--serif); font-style: italic; font-weight: 300;
  font-size: 20px; color: var(--champagne);
}
.svc-body h3 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(26px, 3vw, 42px); line-height: 1.1; margin-bottom: 10px;
}
.svc-body p { max-width: 62ch; color: var(--muted); font-weight: 300; font-size: 16px; }
.svc-link {
  font-size: 12px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase;
  color: var(--terracotta-text);
  padding: 10px 2px; align-self: center; justify-self: end;
  opacity: .65; border-bottom: 1px solid transparent;
  transition: opacity .4s var(--ease), border-color .4s var(--ease);
}
.svc-item:hover .svc-link, .svc-link:hover, .svc-link:focus-visible { opacity: 1; border-color: var(--champagne); }

/* ---------------- Boutique (sticky editorial) ---------------- */
.boutique { background: var(--ivory); border-top: 1px solid var(--hairline); border-bottom: 1px solid var(--hairline); }
.boutique-grid {
  width: min(1400px, 94vw); margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 7vw, 110px);
}
.boutique-sticky { position: relative; }
.boutique-img-wrap {
  position: sticky; top: 0;
  height: 100vh; height: 100svh;
  display: flex; align-items: center;
}
.boutique-img {
  position: absolute; top: 50%; left: 0; transform: translateY(-50%);
  width: 100%; max-height: 78svh; object-fit: cover;
  border-radius: 10px;
  opacity: 0; transition: opacity .7s var(--ease);
}
.boutique-img.is-active { opacity: 1; }
.boutique-panels { padding: 12vh 0; }
.boutique-panel {
  min-height: 88svh;
  display: flex; flex-direction: column; justify-content: center;
}
.boutique-panel p:not(.eyebrow) { margin-top: 26px; max-width: 46ch; color: var(--muted); font-weight: 300; }
.boutique-panel-img { display: none; }

/* ---------------- Gallery ---------------- */
.gallery { padding: clamp(110px, 13vw, 180px) 0 0; }
.gal-grid {
  columns: 3; column-gap: 24px;
}
.gal-item {
  break-inside: avoid; margin-bottom: 24px;
  position: relative; overflow: hidden; border-radius: 8px;
  will-change: transform;
}
.gal-item img, .gal-item video { width: 100%; height: auto; transition: transform 1.1s var(--ease); }
.gal-item:hover img, .gal-item:hover video { transform: scale(1.045); }
.gal-item figcaption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 40px 20px 16px;
  background: linear-gradient(180deg, transparent, rgba(43, 34, 28, .55));
  color: var(--cream);
  font-size: 12px; font-weight: 500; letter-spacing: .2em; text-transform: uppercase;
  opacity: 0; transform: translateY(8px);
  transition: opacity .5s var(--ease), transform .5s var(--ease);
}
.gal-item:hover figcaption { opacity: 1; transform: translateY(0); }
.gal-more { margin-top: clamp(48px, 5vw, 70px); text-align: center; padding-bottom: clamp(110px, 13vw, 180px); }

/* ---------------- Quote ---------------- */
.quote {
  background: var(--ivory);
  border-top: 1px solid var(--hairline);
  padding: clamp(110px, 13vw, 180px) 0;
}
.quote-text {
  font-family: var(--serif); font-weight: 300;
  font-size: clamp(26px, 3.6vw, 46px); line-height: 1.3; letter-spacing: -0.01em;
}
.quote-text em { color: var(--terracotta); }
.quote-attr { margin-top: 36px; font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted); }

/* ---------------- Team ---------------- */
.team { padding: clamp(110px, 13vw, 180px) 0; }
.team-inner {
  display: grid; grid-template-columns: 1.05fr .95fr;
  gap: clamp(40px, 7vw, 110px); align-items: center;
}
.team-copy p:not(.eyebrow) { margin: 26px 0 40px; max-width: 50ch; color: var(--muted); font-weight: 300; }
.team-media { justify-self: end; width: 100%; max-width: 440px; }
.team-img-arch {
  border-radius: 999px 999px 14px 14px; overflow: hidden; aspect-ratio: 4/5.2;
}
.team-img-arch img, .team-img-arch video { width: 100%; height: 100%; object-fit: cover; }

/* ---------------- Contact ---------------- */
.contact {
  background: var(--espresso); color: var(--cream);
  padding: clamp(110px, 13vw, 180px) 0;
}
.contact-inner {
  display: grid; grid-template-columns: 1.1fr .9fr;
  gap: clamp(48px, 7vw, 110px); align-items: center;
}
.contact-title {
  font-family: var(--serif); font-weight: 300;
  font-size: clamp(44px, 5.8vw, 86px); line-height: 1.03; letter-spacing: -0.015em;
}
.contact-title em { color: var(--champagne); font-weight: 400; }
.contact-sub { margin: 28px 0 44px; max-width: 44ch; color: rgba(245, 238, 229, .72); font-weight: 300; }
.contact-meta { list-style: none; margin-top: 52px; border-top: 1px solid var(--hairline-light); }
.contact-meta li {
  display: flex; gap: 24px; align-items: baseline;
  padding: 18px 0; border-bottom: 1px solid var(--hairline-light);
  font-size: 15px; font-weight: 300;
}
.meta-label {
  flex: 0 0 110px;
  font-size: 11px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase;
  color: var(--champagne);
}
.contact-meta a { border-bottom: 1px solid transparent; transition: border-color .3s; }
.contact-meta a:hover { border-color: var(--champagne); }
.contact-map {
  border-radius: 12px; overflow: hidden;
  aspect-ratio: 4/4.6;
  filter: grayscale(1) sepia(.3) contrast(.95) brightness(.85);
}
.contact-map iframe { width: 100%; height: 100%; border: 0; }

/* ---------------- Footer ---------------- */
.footer {
  background: var(--espresso); color: var(--cream);
  border-top: 1px solid var(--hairline-light);
  padding: 64px 0 44px;
}
.footer-inner { text-align: center; }
.footer-logo {
  font-family: var(--serif); font-style: italic; font-weight: 400;
  font-size: 44px;
}
.footer-line { margin-top: 12px; font-family: var(--serif); font-style: italic; font-weight: 300; color: rgba(245, 238, 229, .6); }
.footer-links { margin-top: 28px; display: flex; justify-content: center; gap: 32px; }
.footer-links a {
  font-size: 12px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase;
  color: var(--champagne);
}
.footer-tiny { margin-top: 34px; font-size: 12px; color: rgba(245, 238, 229, .58); font-weight: 300; }

/* ---------------- Reveal helpers (JS adds .in) ---------------- */
.fade-up { opacity: 0; transform: translateY(44px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.fade-up.in { opacity: 1; transform: none; }
.img-reveal { clip-path: inset(0 0 100% 0); transition: clip-path 1.2s var(--ease); }
.img-reveal.in { clip-path: inset(0 0 0% 0); }

/* ---------------- Responsive ---------------- */
@media (max-width: 1024px) {
  .nav-links, .btn-nav { display: none; }
  .nav-burger { display: block; }
  .hero-inner { grid-template-columns: 1fr; gap: 56px; }
  .hero-media { justify-self: center; max-width: 400px; }
  .hero-badge { left: auto; right: -40px; }
  .gal-grid { columns: 2; }
  .boutique-grid { grid-template-columns: 1fr; }
  .boutique-sticky { display: none; }
  .boutique-panel { min-height: 0; padding: 60px 0; }
  .boutique-panels { padding: 30px 0; }
  .boutique-panel-img { display: block; width: 100%; height: auto; border-radius: 10px; margin-bottom: 28px; }
  .team-inner, .contact-inner { grid-template-columns: 1fr; }
  .team-media { justify-self: start; }
}
@media (max-width: 820px) {
  .svc-item { grid-template-columns: 1fr; gap: 10px; }
  .svc-num { font-size: 16px; }
  .svc-link { justify-self: start; opacity: 1; border-color: var(--champagne); }
  .svc-item:hover { padding-left: 8px; background: none; }
  .gal-item figcaption { opacity: 1; transform: none; }
  .gal-grid { columns: 1; }
  .contact-map { aspect-ratio: 4/3; }
  .hero { padding-top: 120px; }
  .hero-badge { width: 96px; height: 96px; right: 8px; bottom: 24px; }
}

/* ---------------- Reduced motion ---------------- */
@media (prefers-reduced-motion: reduce) {
  .marquee-track, .hero-badge, .scrollcue-line { animation: none; }
  .fade-up, .img-reveal { opacity: 1; transform: none; clip-path: none; transition: none; }
  * { scroll-behavior: auto !important; }
}
