/* ============================================
   HOCHZEITSEINLADUNG — style.css
   Elegant, warm, cinematic — Mobile-First
   ============================================ */

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

:root {
  /* Warm, luxurious palette */
  --color-cream: #FBF9F6;
  --color-warm: #F3EDE4;
  --color-sand: #E8DFD1;
  --color-gold: #C4A265;
  --color-gold-light: rgba(196, 162, 101, 0.15);
  --color-gold-glow: rgba(196, 162, 101, 0.3);
  --color-text: #2B2520;
  --color-text-soft: #6B5E52;
  --color-text-light: #FBF9F6;

  /* Typography */
  --font-serif: 'Cormorant Garamond', 'Georgia', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  --section-padding: clamp(5rem, 12vh, 10rem);
}

html {
  font-family: var(--font-sans);
  font-size: 16px;
  color: var(--color-text);
  background: var(--color-cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  overflow-x: clip; /* clip statt hidden — bricht sticky nicht */
}

/* Hide scrollbar */
::-webkit-scrollbar { display: none; }
body { scrollbar-width: none; }


/* ---------- Preloader ---------- */
#preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--color-cream);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.8s ease, visibility 0.8s ease;
}

#preloader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-inner {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.preloader-ornament {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.preloader-line {
  display: block;
  width: 40px;
  height: 1px;
  background: var(--color-gold);
}

.preloader-diamond {
  display: block;
  width: 6px;
  height: 6px;
  background: var(--color-gold);
  transform: rotate(45deg);
}

.preloader-text {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 300;
  font-style: italic;
  letter-spacing: 0.08em;
  color: var(--color-text-soft);
}

.preloader-bar {
  width: 160px;
  height: 1px;
  background: var(--color-sand);
  overflow: hidden;
}

.preloader-bar-fill {
  width: 0%;
  height: 100%;
  background: var(--color-gold);
  transition: width 0.15s linear;
}


/* ---------- Ornaments (reusable) ---------- */
.section-ornament,
.footer-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
}

.ornament-line {
  display: block;
  width: 48px;
  height: 1px;
  background: var(--color-gold);
  opacity: 0.6;
}

.ornament-diamond {
  display: block;
  width: 5px;
  height: 5px;
  background: var(--color-gold);
  transform: rotate(45deg);
  opacity: 0.6;
}


/* ---------- Section Headings ---------- */
.section-heading {
  font-family: var(--font-serif);
  font-size: clamp(3.2rem, 7vw, 5.5rem);
  font-weight: 300;
  letter-spacing: -0.01em;
  line-height: 1.1;
  margin-bottom: 2rem;
  color: var(--color-text);
}


/* ---------- Section 1: Hero ---------- */
.section--hero {
  height: 400vh; /* extended scroll room */
  position: relative;
  background: var(--color-text);
}

.hero-canvas-wrap {
  position: sticky;
  top: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh; /* dynamische Viewport-Hoehe auf Mobile */
  overflow: hidden;
}

.hero-canvas-wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at center, transparent 30%, rgba(0, 0, 0, 0.4) 100%),
    linear-gradient(to bottom,
      rgba(0, 0, 0, 0.15) 0%,
      transparent 30%,
      transparent 60%,
      rgba(0, 0, 0, 0.45) 100%
    );
  pointer-events: none;
  z-index: 1;
}

.hero-canvas-wrap canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.hero-canvas-wrap .hero-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  filter: blur(20px);
  transform: scale(1.1);
  z-index: 0;
}

.hero-content {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 2;
}

/* Over-title: date with ornament lines */
.hero-overtitle {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
  opacity: 0;
}

.hero-ornament-line {
  display: block;
  width: 40px;
  height: 1px;
  background: rgba(196, 162, 101, 0.7);
}

.hero-overtitle-text {
  font-family: var(--font-sans);
  font-size: clamp(0.85rem, 1.4vw, 1rem);
  font-weight: 400;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--color-gold);
}

/* Hero title */
.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(4rem, 11vw, 9.5rem);
  font-weight: 300;
  line-height: 1.05;
  text-align: center;
  color: var(--color-text-light);
  text-shadow:
    0 2px 40px rgba(0, 0, 0, 0.5),
    0 0 80px rgba(0, 0, 0, 0.2);
}

.hero-title-word {
  display: block;
  will-change: transform, opacity;
  backface-visibility: hidden;
}

.hero-title-em {
  font-style: italic;
  color: var(--color-gold);
  text-shadow:
    0 2px 40px rgba(196, 162, 101, 0.3),
    0 0 80px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
  margin-top: 2rem;
  font-family: var(--font-serif);
  font-size: clamp(1.3rem, 2.4vw, 1.7rem);
  font-weight: 300;
  font-style: italic;
  color: rgba(251, 249, 246, 0.8);
  letter-spacing: 0.02em;
  text-shadow: 0 1px 20px rgba(0, 0, 0, 0.4);
  text-align: center;
  padding: 0 2rem;
}

/* Scroll hint arrow */
.hero-scroll-hint {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
}

.hero-scroll-arrow {
  display: block;
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, transparent, var(--color-gold));
  animation: scrollPulse 2.5s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; transform: scaleY(0.7); }
  50% { opacity: 1; transform: scaleY(1); }
}


/* ---------- Section 2: Wann & Wo ---------- */
.section--details {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--section-padding) clamp(1.5rem, 5vw, 3rem);
  background: linear-gradient(
    175deg,
    var(--color-cream) 0%,
    var(--color-warm) 50%,
    var(--color-cream) 100%
  );
  position: relative;
}

.details-inner {
  max-width: 560px;
  width: 100%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.details-label {
  font-family: var(--font-sans);
  font-size: clamp(0.8rem, 1.1vw, 0.9rem);
  font-weight: 400;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: 1rem;
}

.details-card {
  width: 100%;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(196, 162, 101, 0.2);
  border-radius: 16px;
  padding: clamp(2rem, 4vw, 3rem);
  margin-bottom: 2rem;
  box-shadow:
    0 4px 24px rgba(43, 37, 32, 0.04),
    0 16px 64px rgba(43, 37, 32, 0.06);
}

.details-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 0.75rem 0;
}

.details-key {
  font-family: var(--font-sans);
  font-size: clamp(0.8rem, 1.1vw, 0.9rem);
  font-weight: 400;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--color-text-soft);
}

.details-value {
  font-family: var(--font-serif);
  font-size: clamp(1.35rem, 2.2vw, 1.6rem);
  font-weight: 400;
  color: var(--color-text);
}

.details-divider {
  width: 100%;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    var(--color-gold-light),
    var(--color-gold),
    var(--color-gold-light),
    transparent
  );
  opacity: 0.5;
}

.details-note {
  font-family: var(--font-serif);
  font-size: clamp(1.15rem, 1.8vw, 1.35rem);
  font-weight: 300;
  font-style: italic;
  color: var(--color-text-soft);
  line-height: 1.6;
}


/* ---------- Section 3: RSVP ---------- */
.section--rsvp {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--section-padding) clamp(1.5rem, 5vw, 3rem);
  background: linear-gradient(
    175deg,
    var(--color-warm) 0%,
    var(--color-cream) 40%,
    var(--color-warm) 100%
  );
  position: relative;
}

.rsvp-inner {
  max-width: 620px;
  width: 100%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.rsvp-label {
  font-family: var(--font-sans);
  font-size: clamp(0.8rem, 1.1vw, 0.9rem);
  font-weight: 400;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: 1rem;
}

.rsvp-text {
  font-family: var(--font-serif);
  font-size: clamp(1.25rem, 1.9vw, 1.5rem);
  font-weight: 300;
  color: var(--color-text-soft);
  margin-bottom: 3rem;
  line-height: 1.7;
}

.rsvp-text strong {
  font-weight: 500;
  color: var(--color-text);
}

.typeform-container {
  width: 100%;
  min-height: 500px;
  background: rgba(255, 255, 255, 0.4);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(196, 162, 101, 0.15);
  border-radius: 16px;
  padding: clamp(1rem, 2vw, 2rem);
  box-shadow:
    0 4px 24px rgba(43, 37, 32, 0.04),
    0 16px 64px rgba(43, 37, 32, 0.06);
}

.typeform-container iframe {
  width: 100%;
  border: none;
  border-radius: 8px;
}


/* ---------- Footer ---------- */
#footer {
  padding: 4rem clamp(1.5rem, 5vw, 3rem) 3rem;
  background: var(--color-cream);
  text-align: center;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.footer-text {
  font-family: var(--font-serif);
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  font-weight: 300;
  font-style: italic;
  color: var(--color-text-soft);
}

.footer-heart {
  font-size: 1.4rem;
  color: var(--color-gold);
  opacity: 0.6;
}


/* ---------- Mobile refinements ---------- */
@media (max-width: 768px) {
  .hero-title {
    font-size: clamp(3.2rem, 13vw, 5rem);
    padding: 0 1rem;
  }

  .hero-subtitle {
    font-size: clamp(1.2rem, 4vw, 1.4rem);
    padding: 0 1.5rem;
  }

  .hero-ornament-line {
    width: 28px;
  }

  .details-card {
    padding: 1.5rem;
  }

  .details-row {
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    padding: 0.6rem 0;
  }

  .typeform-container {
    min-height: 400px;
    padding: 0.75rem;
  }
}


/* ---------- Smooth scroll ---------- */
@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}
