/* (Claude) — Design System: Champagne palette + luxury 3D, bolle champagne */

/* ── Variables ─────────────────────────────────────────────── */
:root {
  --bg:            #FFFDF8;
  --bg-2:          #FAF5EA;
  --bg-3:          #F2E8D5;
  --border:        rgba(201, 168, 76, 0.20);
  --accent:        #C9A84C;
  --accent-2:      #A8882E;
  --accent-dim:    rgba(201, 168, 76, 0.10);
  --gold:          #D4AF37;
  --gold-2:        #B8943A;
  --gold-dim:      rgba(212, 175, 55, 0.18);
  --text:          #2A1F0D;
  --text-muted:    #7A6040;
  --text-dim:      #C4A870;

  --font-display:  'Cormorant Garamond', Georgia, serif;
  --font-body:     'Montserrat', system-ui, sans-serif;

  --ease-out:      cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out:   cubic-bezier(0.4, 0, 0.2, 1);

  --radius:        8px;
  --radius-lg:     16px;
  --transition:    0.35s var(--ease-out);

  --max-width:     1280px;
  --container-px:  clamp(1.25rem, 5vw, 4rem);
  --header-h:      72px;
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }

/* Background is transparent — parallax div handles it */
body {
  background: transparent;
  color: var(--text);
  font-family: var(--font-body);
  font-size: clamp(0.875rem, 1.4vw, 1rem);
  font-weight: 300;
  line-height: 1.7;
  cursor: none;
}

/* ── Parallax background (bg-image set inline via PHP in header.php) ── */
.parallax-bg {
  position: fixed;
  inset: 0;
  background-image: none !important;
  background-color: var(--bg-2); /* #FFF9F7 cream background */
  z-index: -2;
  pointer-events: none;
}

/* Warm tint overlay on parallax bg to blend with brand palette */
.parallax-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(236,178,24,0.08) 0%,
    rgba(188,65,42,0.06) 50%,
    rgba(26,8,5,0.12)    100%
  );
}

@media (pointer: coarse) { body { cursor: auto; } }

img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { cursor: none; border: none; background: none; font: inherit; }
ul, ol { list-style: none; }

/* ── Typography ─────────────────────────────────────────────── */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.8rem, 6vw, 5rem); }
h2 { font-size: clamp(2rem, 4vw, 3.2rem); }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.75rem); }

p { max-width: 65ch; }

/* ── Layout helpers ─────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--container-px);
}

.container--narrow { max-width: 760px; }

/* ── Custom cursor (gold) ───────────────────────────────────── */
.cursor-dot {
  position: fixed;
  top: 0; left: 0;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--gold);
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: transform 0.1s, width 0.25s var(--ease-out), height 0.25s var(--ease-out), background 0.25s;
  mix-blend-mode: multiply;
}

.cursor-dot.cursor-hover {
  width: 44px; height: 44px;
  background: var(--gold-dim);
  mix-blend-mode: multiply;
  border: 1.5px solid var(--gold);
}

@media (pointer: coarse) { .cursor-dot { display: none; } }

/* ── Scroll-reveal animations ────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(28px) scale(0.97);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.reveal-delay-1 { transition-delay: 0.12s; }
.reveal-delay-2 { transition-delay: 0.24s; }
.reveal-delay-3 { transition-delay: 0.36s; }

/* Blur-text reveal */
.blur-word {
  display: inline-block;
  opacity: 0;
  filter: blur(10px);
  transform: translateY(-18px);
  transition: opacity 0.55s var(--ease-out), filter 0.55s var(--ease-out), transform 0.55s var(--ease-out);
}

.blur-word.in-view {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0);
}

/* ── 3D Keyframe Animations ─────────────────────────────────── */

/* Hero content gentle 3D float */
@keyframes heroFloat {
  0%, 100% {
    transform: perspective(1000px) translateZ(0px) rotateX(1.2deg) rotateY(-0.8deg) translateY(0px);
  }
  30% {
    transform: perspective(1000px) translateZ(30px) rotateX(-0.8deg) rotateY(1.2deg) translateY(-14px);
  }
  60% {
    transform: perspective(1000px) translateZ(15px) rotateX(1.5deg) rotateY(-1.5deg) translateY(-6px);
  }
}

/* Rotating geometric shape (gold cube/diamond) */
@keyframes rotateCube {
  0%   { transform: perspective(500px) rotateX(0deg)   rotateY(0deg)   rotateZ(0deg); }
  33%  { transform: perspective(500px) rotateX(120deg)  rotateY(80deg)  rotateZ(45deg); }
  66%  { transform: perspective(500px) rotateX(240deg)  rotateY(160deg) rotateZ(90deg); }
  100% { transform: perspective(500px) rotateX(360deg)  rotateY(240deg) rotateZ(135deg); }
}

/* Floating up-down with 3D tilt */
@keyframes floatOrbit {
  0%, 100% {
    transform: perspective(600px) rotateX(15deg) rotateY(0deg) translateY(0px);
    opacity: 0.55;
  }
  25% {
    transform: perspective(600px) rotateX(-10deg) rotateY(45deg) translateY(-22px);
    opacity: 0.75;
  }
  50% {
    transform: perspective(600px) rotateX(20deg) rotateY(90deg) translateY(-10px);
    opacity: 0.45;
  }
  75% {
    transform: perspective(600px) rotateX(-5deg) rotateY(135deg) translateY(-18px);
    opacity: 0.65;
  }
}

/* Slower orbit for larger shape */
@keyframes floatOrbitSlow {
  0%, 100% {
    transform: perspective(700px) rotateX(-12deg) rotateY(0deg) translateY(0px) scale(1);
  }
  40% {
    transform: perspective(700px) rotateX(18deg) rotateY(-60deg) translateY(-28px) scale(1.08);
  }
  80% {
    transform: perspective(700px) rotateX(-8deg) rotateY(50deg) translateY(-12px) scale(0.95);
  }
}

/* Card ambient 3D breathing */
@keyframes cardBreath {
  0%, 100% { transform: perspective(900px) rotateX(1.2deg) rotateY(-1.2deg); }
  50%       { transform: perspective(900px) rotateX(-1.2deg) rotateY(1.2deg); }
}

/* Gold spin ring */
@keyframes spinRing {
  from { transform: perspective(400px) rotateY(0deg) rotateX(70deg); }
  to   { transform: perspective(400px) rotateY(360deg) rotateX(70deg); }
}

/* Hero name independent float (separate from shimmer) */
@keyframes heroNameFloat {
  0%, 100% { transform: translateY(0px) rotateX(1deg); }
  50%       { transform: translateY(-8px) rotateX(-1deg); }
}

/* Gold shimmer sweep on hero name */
@keyframes shimmer {
  0%   { background-position: -200% center; }
  100% { background-position:  200% center; }
}

/* ── Champagne bubbles rising ────────────────────────────────── */
@keyframes bubbleRise {
  0%   { transform: translateY(0) translateX(0) scale(1);                     opacity: 0; }
  6%   { opacity: 0.70; }
  82%  { opacity: 0.30; }
  100% { transform: translateY(-100vh) translateX(var(--drift,0px)) scale(0.25); opacity: 0; }
}

#champagneBubbles {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.ch-bubble {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 28%,
    rgba(255,252,230,0.92) 0%,
    rgba(212,175,55,0.22)  55%,
    rgba(201,168,76,0.04)  100%
  );
  border: 1px solid rgba(212, 175, 55, 0.35);
  box-shadow:
    inset 0 0 5px rgba(255,255,255,0.75),
    0 0 8px rgba(212,175,55,0.12);
  animation: bubbleRise var(--dur,7s) ease-in var(--delay,0s) infinite;
}

/* Section title underline draws in from left */
@keyframes drawLine {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

/* Marquee horizontal scroll */
@keyframes marqueeScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* Bounce arrow for CTA */
@keyframes bounceRight {
  0%, 100% { transform: translateX(0); }
  50%       { transform: translateX(5px); }
}

/* ── Buttons ─────────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 2.2rem;
  background: var(--accent);
  color: #FFFFFF;
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 2px;
  position: relative;
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition), letter-spacing 0.3s;
  z-index: 0;
}

/* GFD fill-from-left */
.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--accent-2);
  transform: translateX(-101%);
  transition: transform 0.42s var(--ease-out);
  z-index: -1;
}
.btn-primary:hover::before { transform: translateX(0); }

.btn-primary:hover {
  transform: translateY(-2px);
  letter-spacing: 0.14em;
  box-shadow: 0 14px 36px rgba(188, 65, 42, 0.34);
}

.btn-primary--outline {
  background: transparent;
  color: var(--accent);
  border: 1.5px solid var(--accent);
}

.btn-primary--outline:hover {
  background: var(--accent-dim);
  color: var(--accent-2);
  box-shadow: 0 8px 24px rgba(188, 65, 42, 0.18);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.4rem;
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 1px solid var(--border);
  border-radius: 2px;
  transition: border-color var(--transition), color var(--transition), background var(--transition);
}

.btn-secondary:hover {
  border-color: var(--gold);
  background: var(--gold-dim);
  color: var(--gold-2);
}

/* ── Section helpers ─────────────────────────────────────────── */
.section-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: clamp(2rem, 4vw, 3.5rem);
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 400;
  font-style: italic;
  color: var(--text);
}

.section-link {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-2);
  transition: color var(--transition);
}

.section-link:hover { color: var(--accent); }

/* ── Empty state ─────────────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 6rem 2rem;
  color: var(--text-muted);
  font-style: italic;
}

/* ── Social links ─────────────────────────────────────────────── */
.social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  transition: color var(--transition);
}

.social-link:hover { color: var(--accent); }

.social-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1.1rem;
  border: 1px solid var(--border);
  border-radius: 40px;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  transition: border-color var(--transition), color var(--transition), background var(--transition);
}

.social-pill:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-dim);
}

/* ── Mouse Trail dots ───────────────────────────────────────────
   The JS creates .trail-dot elements on body.
   Base styles here; JS overrides size/color/opacity per node.     */
.trail-dot {
  position: fixed;
  top: 0; left: 0;
  pointer-events: none;
  z-index: 9998;
  border-radius: 50%;
  will-change: transform;
  /* Soft glow via box-shadow matching own color */
  box-shadow: 0 0 6px 1px currentColor;
}

/* On coarse pointer (touch): trail and cursor dot both hidden */
@media (pointer: coarse) {
  .trail-dot { display: none; }
}

/* ── Parallax Background Enhancement ───────────────────────────
   Three additional layers sit above the .parallax-bg element:
   1. #parallaxVignette — dynamic dark vignette driven by JS opacity
   2. .parallax-bg::before — film-grain noise via SVG filter (static)
   3. .parallax-bg.bg-crossfade::after — secondary bg image cross-fade  */

/* Vignette overlay — disabled because we are using a solid cream background now */
#parallaxVignette {
  display: none !important;
}

/* Film-grain noise via embedded SVG feTurbulence filter
   The pseudo-element tiles a subtle monochromatic noise texture.
   mix-blend-mode: overlay keeps it non-destructive.               */
.parallax-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  /* SVG noise filter as data URI — no external file needed */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23g)' opacity='0.08'/%3E%3C/svg%3E");
  background-size: 180px 180px;
  background-repeat: repeat;
  opacity: 0.55;
  mix-blend-mode: overlay;
}

/* Cross-fade secondary bg: the ::after pseudo overlays a second image.
   JS adds .bg-crossfade at scroll > 50vh; opacity transitions from 0→1. */
.parallax-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  /* Very light warm gradient to blend with the brand palette */
  background: linear-gradient(
    to bottom,
    rgba(236,178,24,0.04) 0%,
    rgba(188,65,42,0.03) 50%,
    rgba(188,65,42,0.05) 100%
  );
  opacity: 1;
  transition: opacity 1.4s cubic-bezier(0.16,1,0.3,1);
}

.parallax-bg.bg-crossfade::after {
  /* Deeper warm tint when scrolled — keeps it light and warm */
  background: linear-gradient(
    160deg,
    rgba(188,65,42,0.05) 0%,
    rgba(236,178,24,0.06) 40%,
    rgba(188,65,42,0.03) 100%
  );
}

/* ── 3D Floating Image Cards ────────────────────────────────────
   #floatLayer is fixed, full-viewport, z-index 0 (between bg and content).
   Each .float-card is an absolutely-positioned card with 3D transforms.

   Transform chain (applied via CSS vars set by JS):
     translateY(--scroll-ty)   — parallax scroll offset
     rotateX(base + global + hover)
     rotateY(base + global + hover)
     translateZ(--tz)          — static depth offset

   The base rotations are set as inline styles from PHP.
   --hover-rx / --hover-ry are set by JS on mousemove.
   --global-rx / --global-ry come from mouse position over the page. */
#floatLayer {
  position: fixed;
  inset: 0;
  z-index: -1; /* above parallax bg (-2), below all content sections */
  pointer-events: none; /* JS re-enables when layer is visible */
  perspective: 900px;
  will-change: opacity;
  transition: opacity 0.6s ease;
}

.float-card {
  /* CSS custom props with fallback defaults */
  --hover-rx: 0deg;
  --hover-ry: 0deg;
  --global-rx: 0deg;
  --global-ry: 0deg;
  --scroll-ty: 0px;
  --base-rx: 0deg;
  --base-ry: 0deg;
  --tz: 0px;

  position: absolute;
  width: 140px !important; /* inline style overrides per card; this is the fallback */
  max-width: 140px;
  aspect-ratio: 3/4;
  border-radius: 10px;
  overflow: hidden;
  pointer-events: auto;
  cursor: none;

  /* Golden border — gradient for depth */
  border: 1.5px solid rgba(236,178,24,0.55);
  box-shadow:
    0 12px 40px rgba(26,8,5,0.55),
    0 0 0 0.5px rgba(188,65,42,0.20),
    inset 0 1px 0 rgba(236,178,24,0.25);

  /* Apply the composed transform */
  transform:
    translateY(var(--scroll-ty))
    rotateX(calc(var(--base-rx) + var(--global-rx) + var(--hover-rx)))
    rotateY(calc(var(--base-ry) + var(--global-ry) + var(--hover-ry)))
    translateZ(var(--tz));

  transform-style: preserve-3d;
  will-change: transform;

  /* Smooth the hover tilt transition */
  transition:
    box-shadow 0.4s var(--ease-out),
    border-color 0.4s var(--ease-out);
}

/* Hover state: deeper shadow + stronger gold border */
.float-card.is-hovered {
  box-shadow:
    0 24px 60px rgba(26,8,5,0.70),
    0 0 0 1.5px rgba(236,178,24,0.70),
    inset 0 1px 0 rgba(236,178,24,0.35);
  border-color: rgba(236,178,24,0.85);
  z-index: 2;
}

.float-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  /* Slight desaturate at rest — fully saturate on hover */
  filter: saturate(0.82) brightness(0.90);
  transition: filter 0.5s var(--ease-out);
}

.float-card.is-hovered img {
  filter: saturate(1.05) brightness(1.0);
}

/* Reflection shimmer: a diagonal gradient that sweeps across on hover */
.float-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(255,255,255,0.0) 35%,
    rgba(255,255,255,0.12) 50%,
    rgba(255,255,255,0.0) 65%
  );
  background-size: 300% 300%;
  background-position: 100% 100%;
  transition: background-position 0.55s var(--ease-out);
  pointer-events: none;
  z-index: 1;
  border-radius: inherit;
}

.float-card.is-hovered::after {
  background-position: 0% 0%;
}

/* Floating animation — each card has a unique orbit so they don't sync up.
   The keyframe only adds a gentle up/down oscillation; the parallax scroll
   and mouse tilt are handled by JS transforms on top of this. */
@keyframes cardFloat {
  0%, 100% { margin-top: 0px; }
  50%       { margin-top: -14px; }
}

/* Staggered float per card index — assigned via inline style in PHP */
.float-card:nth-child(1) { animation: cardFloat 7.0s ease-in-out infinite; }
.float-card:nth-child(2) { animation: cardFloat 9.5s ease-in-out infinite; animation-delay: -3.2s; }
.float-card:nth-child(3) { animation: cardFloat 8.2s ease-in-out infinite; animation-delay: -6.5s; }
.float-card:nth-child(4) { animation: cardFloat 10.8s ease-in-out infinite; animation-delay: -1.8s; }
.float-card:nth-child(5) { animation: cardFloat 6.8s ease-in-out infinite; animation-delay: -4.9s; }

/* Hide float layer on mobile — too much visual noise on small screens */
@media (max-width: 768px) {
  #floatLayer { display: none; }
}

/* Reduce motion: disable all float animations */
@media (prefers-reduced-motion: reduce) {
  .float-card,
  .float-card:nth-child(n) { animation: none; }
  #floatLayer { display: none; }
  .trail-dot  { display: none; }
}
