/* Royal V2 Purple - Pure Vanilla CSS */

:root {
  --color-bg-primary: #190C1F;
  --color-bg-envelope-start: #240c30;
  --color-bg-envelope-end: #15081a;
  --color-gold-accent: #ffe491;
  --color-gold-seal: #B1804C;
  --color-gold-seal-dark: #874f22;
  --color-gold-border: rgba(135, 79, 34, 0.28);
  --color-text-primary: #ffffff;
  --color-text-muted: rgba(255, 255, 255, 0.75);
  --color-text-dim: rgba(255, 255, 255, 0.45);
  --font-cursive: 'Great Vibes', cursive;
  --font-serif: 'EB Garamond', 'Lora', serif;
  --font-sans: 'Outfit', 'Inter', sans-serif;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  color-scheme: dark;
  overflow-x: hidden;
}

body {
  background-color: var(--color-bg-primary);
  color: var(--color-text-primary);
  font-family: var(--font-serif);
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  width: 100%;
}

/* Damask Texture Overlay */
.damask-bg-overlay {
  position: fixed;
  inset: 0;
  background-image: url('assets/backgrounds/background.webp');
  background-size: 685px 685px;
  background-repeat: repeat;
  background-position: top left;
  opacity: 0.4;
  pointer-events: none;
  z-index: 1;
}

/* Main Container - Fully Responsive Fluid Width */
.page-wrapper {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
  min-height: 100vh;
  padding: 0 16px 80px 16px;
  overflow: hidden;
}

@media (max-width: 480px) {
  .page-wrapper {
    padding: 0 10px 60px 10px;
  }
}

/* Typography Helpers */
.font-cursive {
  font-family: var(--font-cursive);
}

.font-serif {
  font-family: var(--font-serif);
}

.text-gold {
  color: var(--color-gold-accent);
}

.text-muted {
  color: var(--color-text-muted);
}

/* Buttons */
.btn-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--color-gold-seal);
  color: #ffffff;
  font-family: var(--font-serif);
  font-weight: 500;
  padding: 12px 36px;
  border-radius: 9999px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(177, 128, 76, 0.4);
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
  user-select: none;
}

.btn-gold:hover {
  background: #c28d54;
  box-shadow: 0 6px 22px rgba(177, 128, 76, 0.6);
  transform: translateY(-2px);
}

.btn-gold:active {
  transform: translateY(0);
}

/* Inputs */
.royal-input {
  width: 100%;
  padding: 12px 16px;
  background-color: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-gold-border);
  border-radius: 10px;
  color: #ffffff;
  font-family: var(--font-serif);
  font-size: 15px;
  outline: none;
  transition: all 0.25s ease;
}

.royal-input:focus {
  border-color: var(--color-gold-accent);
  box-shadow: 0 0 12px rgba(255, 228, 145, 0.25);
  background-color: rgba(255, 255, 255, 0.07);
}

.royal-input::placeholder {
  color: rgba(255, 255, 255, 0.35);
}

/* ============================================================
   1. ENVELOPE GATE STAGE
============================================================ */
#envelope-gate {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(to bottom right, #240c30, #15081a);
  overflow: hidden;
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

#envelope-gate.hidden {
  opacity: 0;
  pointer-events: none;
  transform: scale(1.05);
}

.star-container {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.star-glyph {
  position: absolute;
  top: -30px;
  animation: ambient-fall 20s ease-in-out infinite;
}

.envelope-card {
  position: relative;
  width: 90%;
  max-width: 480px;
  margin: 0 auto;
  border-radius: 16px;
  box-shadow: 0 25px 60px -12px rgba(0, 0, 0, 0.7), 0 0 40px rgba(135, 79, 34, 0.25);
  border: 1px solid rgba(135, 79, 34, 0.28);
  background: radial-gradient(circle at 50% 35%, #230c2e 0%, #15071a 100%);
  text-align: center;
  padding: 84px 24px 44px 24px;
}

@media (max-width: 480px) {
  .envelope-card {
    padding: 76px 16px 36px 16px;
  }
}

.wax-seal {
  position: absolute;
  top: 0;
  left: 50%;
  width: 56px;
  height: 56px;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle at 30% 30%, #B1804C, #93622e);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 30;
  animation: seal-pulse 2s ease-in-out infinite;
}

/* Floral corner decorations scaled & positioned to prevent overlapping the names */
.envelope-flower-tl {
  position: absolute;
  top: -14%;
  left: -14%;
  width: 40%;
  max-width: 185px;
  pointer-events: none;
  opacity: 0.9;
  z-index: 1;
}

.envelope-flower-br {
  position: absolute;
  bottom: -10%;
  right: -12%;
  width: 40%;
  max-width: 190px;
  pointer-events: none;
  opacity: 0.9;
  z-index: 1;
}

@media (max-width: 480px) {
  .envelope-flower-tl {
    top: -10%;
    left: -12%;
    width: 36%;
    max-width: 140px;
  }

  .envelope-flower-br {
    bottom: -8%;
    right: -10%;
    width: 36%;
    max-width: 145px;
  }
}

/* Envelope Couple Names Typography & Alignment */
.envelope-names {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px auto;
  width: 100%;
}

.envelope-names .name-groom {
  font-family: var(--font-cursive);
  font-size: clamp(26px, 5.8vw, 36px);
  line-height: 1.25;
  color: #ffffff;
  letter-spacing: 0.02em;
  white-space: nowrap;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.95), 0 0 20px rgba(21, 8, 26, 0.95);
}

.envelope-names .name-amp {
  font-family: 'EB Garamond', 'Lora', serif;
  font-style: italic;
  font-size: clamp(18px, 4vw, 22px);
  line-height: 1.1;
  color: var(--color-gold-accent);
  margin: 3px 0;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.8);
}

.envelope-names .name-bride {
  font-family: var(--font-cursive);
  font-size: clamp(28px, 6.2vw, 38px);
  line-height: 1.25;
  color: #ffffff;
  letter-spacing: 0.02em;
  white-space: nowrap;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.95), 0 0 20px rgba(21, 8, 26, 0.95);
}

.btn-open-shine {
  position: absolute;
  top: 0;
  height: 100%;
  width: 30px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
  animation: shine 3s ease-in-out infinite;
  pointer-events: none;
}

/* ============================================================
   2. HERO SECTION
============================================================ */
.hero-section {
  position: relative;
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: center;
  padding: clamp(48px, 12vw, 90px) 16px 60px 16px;
}

.hero-frame-container {
  position: relative;
  z-index: 10;
  margin: 0 auto;
  aspect-ratio: 406 / 574;
  width: 100%;
  max-width: 540px;
}

.hero-frame-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
  z-index: 10;
}

.hero-tagline {
  position: absolute;
  left: 50%;
  top: 16%;
  z-index: 20;
  transform: translateX(-50%);
  text-align: center;
  /* text-transform: uppercase; */
  line-height: 1.6;
  color: var(--color-gold-accent);
  font-size: clamp(10px, 2.5vw, 12px);
  letter-spacing: 0.14em;
  white-space: pre-line;
}

.hero-gold-line-top {
  position: absolute;
  left: 50%;
  top: 26%;
  transform: translateX(-50%);
  width: 32%;
  max-width: 160px;
  height: auto;
  z-index: 20;
  pointer-events: none;
}

.hero-couple-names {
  position: absolute;
  left: 0;
  right: 0;
  top: 53%;
  transform: translateY(-50%);
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 0 16px;
  text-align: center;
  color: #ffffff;
}

.hero-couple-names .name {
  font-size: clamp(28px, 6.8vw, 44px);
  line-height: 1.25;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.9), 0 0 20px rgba(21, 8, 26, 0.95);
  white-space: nowrap;
}

.hero-couple-names .amp {
  font-family: 'EB Garamond', 'Lora', serif;
  font-style: italic;
  font-size: clamp(22px, 5vw, 30px);
  line-height: 1.1;
  color: var(--color-gold-accent);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.8);
}

.hero-gold-line-bottom {
  position: absolute;
  left: 50%;
  top: 76%;
  transform: translateX(-50%);
  width: 32%;
  max-width: 160px;
  height: auto;
  z-index: 20;
  pointer-events: none;
}

.hero-flower-tl {
  position: absolute;
  left: -24%;
  top: -16%;
  width: 62%;
  max-width: 320px;
  object-fit: contain;
  pointer-events: none;
  z-index: 30;
}

.hero-flower-br {
  position: absolute;
  left: 58%;
  top: 60%;
  width: 58%;
  max-width: 300px;
  object-fit: contain;
  pointer-events: none;
  z-index: 30;
}

/* ============================================================
   3. CEREMONY SECTION
============================================================ */
.ceremony-section {
  position: relative;
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: center;
  padding: 0 16px 50px 16px;
}

.ceremony-inner {
  position: relative;
  margin: 0 auto;
  width: 90%;
  max-width: 500px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 28px;
  padding: 40px 16px 20px 16px;
  text-align: center;
}

.corner-frame-l {
  position: absolute;
  left: -2%;
  top: -14px;
  width: 20%;
  max-width: 76px;
  object-fit: contain;
  pointer-events: none;
  z-index: 20;
}

.corner-frame-r {
  position: absolute;
  right: -2%;
  top: -14px;
  width: 20%;
  max-width: 76px;
  transform: scaleX(-1);
  object-fit: contain;
  pointer-events: none;
  z-index: 20;
}

.center-heart-flourish {
  position: absolute;
  left: 50%;
  top: -20px;
  transform: translateX(-50%);
  width: 44%;
  max-width: 160px;
  object-fit: contain;
  pointer-events: none;
  z-index: 20;
}

.ceremony-side-flower-l {
  position: absolute;
  left: -54%;
  top: 26%;
  width: 68%;
  max-width: 320px;
  pointer-events: none;
  z-index: 20;
}

.ceremony-side-flower-r {
  position: absolute;
  left: 82%;
  top: 68%;
  width: 68%;
  max-width: 320px;
  pointer-events: none;
  z-index: 20;
}

.parents-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
}

.parents-col {
  display: flex;
  flex-direction: column;
  gap: 2px;
  align-items: center;
}

.parents-divider {
  width: 1px;
  height: 48px;
  background-color: rgba(255, 228, 145, 0.35);
}

/* ============================================================
   SCRATCH CARD DATE REVEAL
============================================================ */
.ceremony-event-block {
  display: flex;
  flex-direction: column;
  gap: 3px;
  align-items: center;
  text-align: center;
}

.scratch-date-container {
  position: relative;
  width: 100%;
  max-width: 326px;
  height: 116px;
  margin: 14px auto;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.7), 0 0 24px rgba(177, 128, 76, 0.35);
  border: 1.5px solid rgba(255, 228, 145, 0.55);
  background: #190C1F;
  user-select: none;
  -webkit-user-select: none;
}

.scratch-revealed-date {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at center, #2e113a, #16081c 85%);
  z-index: 1;
  padding: 8px 14px;
  text-align: center;
}

.scratch-date-label {
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 600;
  /* text-transform: uppercase; */
  letter-spacing: 0.16em;
  color: var(--color-gold-accent);
  margin-bottom: 2px;
  opacity: 0.95;
}

.scratch-date-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  margin: 2px 0;
}

.scratch-day,
.scratch-month {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.05em;
  color: var(--color-gold-accent);
}

.scratch-sep {
  color: rgba(255, 228, 145, 0.45);
  font-size: 18px;
  line-height: 1;
}

.scratch-num {
  font-family: var(--font-sans);
  color: #ffffff;
  font-size: 38px;
  font-weight: 800;
  line-height: 1;
  text-shadow: 0 0 20px rgba(255, 228, 145, 0.55), 0 2px 6px rgba(0, 0, 0, 0.8);
}

.scratch-year {
  font-family: var(--font-sans);
  color: var(--color-gold-accent);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-shadow: 0 0 10px rgba(177, 128, 76, 0.45);
}

.scratch-canvas {
  position: absolute;
  inset: 0;
  z-index: 2;
  cursor: grab;
  touch-action: none;
  border-radius: 14px;
}

.scratch-canvas:active {
  cursor: grabbing;
}

.scratch-instruction-pill {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  background: rgba(25, 12, 31, 0.94);
  border: 1px solid var(--color-gold-border);
  color: var(--color-gold-accent);
  font-size: 11px;
  font-weight: 600;
  font-family: var(--font-sans);
  letter-spacing: 0.04em;
  padding: 3px 12px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.7);
  pointer-events: none;
  cursor: default;
  animation: pulse-hint 2.2s infinite ease-in-out;
  transition: opacity 0.3s ease;
}

@keyframes pulse-hint {

  0%,
  100% {
    transform: translateX(-50%) scale(1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
  }

  50% {
    transform: translateX(-50%) scale(1.05);
    box-shadow: 0 4px 18px rgba(255, 228, 145, 0.4);
  }
}

/* ============================================================
   ENGAGEMENT CEREMONY REVEAL ANIMATION (TRIGGERED AT 50% SCRATCH)
============================================================ */
.engagement-ceremony-hidden {
  display: none !important;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transform: translateY(-20px);
}

.engagement-ceremony-revealed {
  display: flex !important;
  animation: revealEngagementBlock 0.85s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes revealEngagementBlock {
  0% {
    opacity: 0;
    transform: translateY(-20px);
    max-height: 0;
    margin-bottom: 0;
    overflow: hidden;
  }
  30% {
    max-height: 200px;
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    max-height: 400px;
    overflow: visible;
  }
}

/* ============================================================
   CONTENT BELOW SCRATCH CARD: HIDDEN UNTIL SCRATCHED
============================================================ */
.below-scratch-hidden {
  display: none !important;
}

#ceremony-details-below-scratch.below-scratch-revealed {
  display: flex !important;
  flex-direction: column;
  gap: 14px;
  animation: revealBelowScratch 0.85s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

#sections-below-scratch.below-scratch-revealed {
  display: block !important;
  animation: revealBelowScratch 0.95s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes revealBelowScratch {
  0% {
    opacity: 0;
    transform: translateY(24px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================
   4. PHOTO GALLERY 3D COVERFLOW
============================================================ */
.gallery-section {
  position: relative;
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: center;
  padding: 30px 16px 50px 16px;
  text-align: center;
}

.coverflow-viewport {
  position: relative;
  width: 100%;
  max-width: 480px;
  height: 420px;
  perspective: 1000px;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  cursor: grab;
}

@media (max-width: 480px) {
  .coverflow-viewport {
    height: 350px;
  }
}

.coverflow-card {
  position: absolute;
  width: 250px;
  height: 370px;
  border-radius: 16px;
  overflow: hidden;
  background: #140719;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.5s cubic-bezier(0.25, 1, 0.5, 1);
  transform-style: preserve-3d;
  cursor: pointer;
}

.coverflow-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 16px;
  box-shadow: inset 0 0 20px rgba(10, 4, 15, 0.55);
  pointer-events: none;
  z-index: 3;
}

@media (max-width: 480px) {
  .coverflow-card {
    width: 210px;
    height: 310px;
  }
}

/* Ambient blurred background layer - matches image colors with zero black bars */
.coverflow-card-bg {
  position: absolute;
  inset: -14%;
  width: 128%;
  height: 128%;
  object-fit: cover;
  filter: blur(22px) brightness(0.5) saturate(1.3);
  transform: scale(1.12);
  pointer-events: none;
  z-index: 1;
}

/* Foreground sharp photo - 100% full photo visible with zero cropping */
.coverflow-card-img,
.coverflow-card img:not(.coverflow-card-bg) {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
}

.coverflow-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 40;
  background: rgba(25, 12, 31, 0.8);
  border: 1px solid var(--color-gold-border);
  border-radius: 50%;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  cursor: pointer;
  transition: all 0.25s ease;
}

.coverflow-arrow.prev {
  left: 4px;
}

.coverflow-arrow.next {
  right: 4px;
}

.gallery-controls-bar {
  margin-top: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: rgba(25, 12, 31, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 6px 16px;
  border-radius: 999px;
  border: 1px solid var(--color-gold-border);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
  user-select: none;
  z-index: 10;
  transition: border-color 0.25s ease, background-color 0.25s ease;
}

.gallery-controls-bar:hover {
  border-color: rgba(255, 228, 145, 0.45);
  background: rgba(25, 12, 31, 0.85);
}

.gallery-autoplay-btn {
  background: transparent;
  border: none;
  color: var(--color-gold-accent);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 999px;
  transition: all 0.2s ease;
  opacity: 0.85;
}

.gallery-autoplay-btn:hover {
  opacity: 1;
  color: #ffffff;
}

.gallery-autoplay-btn.is-active {
  opacity: 1;
}

.gallery-autoplay-btn:focus-visible {
  outline: 2px solid var(--color-gold-accent);
  outline-offset: 2px;
}

/* ============================================================
   5. RECEPTION & CALENDAR SECTION
============================================================ */
.reception-section {
  position: relative;
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: center;
  padding: 20px 16px 50px 16px;
  text-align: center;
}

.calendar-card {
  position: relative;
  margin: 12px auto 0 auto;
  width: 100%;
  max-width: 330px;
  border-radius: 28px;
  padding: 22px 18px;
  border: 1px solid #874f22;
  background-color: rgba(25, 12, 31, 0.6);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.45);
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  row-gap: 2px;
  padding-top: 8px;
}

.calendar-cell {
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  position: relative;
}

.calendar-heart-badge {
  position: relative;
  width: 26px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.calendar-heart-badge img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.calendar-heart-badge span {
  position: relative;
  z-index: 10;
  font-size: 11px;
  font-weight: bold;
  color: #190C1F;
}

/* ============================================================
   6. DRESS CODE & SCHEDULE TIMELINE
============================================================ */
.timeline-section {
  position: relative;
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: center;
  padding: 30px 16px 50px 16px;
}

.timeline-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 16px minmax(0, 1fr);
  align-items: center;
  column-gap: 20px;
  row-gap: 30px;
  list-style: none;
  margin: 0 auto;
  width: 100%;
  max-width: 440px;
  padding: 0;
}

/* ============================================================
   7. 3D GIFT BOX SECTION
============================================================ */
.giftbox-section {
  position: relative;
  display: flex;
  width: 100%;
  flex-direction: column;
  align-items: center;
  padding: 40px 16px 60px 16px;
  text-align: center;
}

.giftbox-btn {
  width: 250px;
  height: 270px;
  position: relative;
  cursor: pointer;
  outline: none;
  border: none;
  background: transparent;
  margin: 0 auto;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 24px;
}

.giftbox-img {
  width: 200px;
  height: 200px;
  object-fit: contain;
  animation: giftbox-bob 3.2s ease-in-out infinite alternate;
  filter: drop-shadow(0 15px 30px rgba(0, 0, 0, 0.6));
  position: relative;
  z-index: 10;
  pointer-events: none;
}

/* ============================================================
   8. MODALS (LIGHTBOX & GIFTBOX)
============================================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 4, 15, 0.88);
  backdrop-filter: blur(8px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: fadeIn 0.3s ease;
}

.modal-content {
  position: relative;
  width: 92%;
  max-width: 440px;
  background: #190C1F;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(135, 79, 34, 0.35);
  border: 1px solid var(--color-gold-border);
  animation: scaleUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ============================================================
   ADD TO CALENDAR MODAL & BUTTON
============================================================ */
.btn-calendar-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(25, 12, 31, 0.7);
  border: 1px solid var(--color-gold-border);
  color: var(--color-gold-accent);
  padding: 9px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  transition: all 0.25s ease;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.btn-calendar-trigger:hover {
  background: rgba(177, 128, 76, 0.22);
  border-color: rgba(255, 228, 145, 0.6);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.6), 0 0 16px rgba(177, 128, 76, 0.35);
}

/* ============================================================
   9. FLOATING WIDGETS
============================================================ */
/* Auto-Scroll Widget (Hidden from UI as requested) */
.floating-autoscroll-widget {
  display: none !important;
  position: fixed;
  bottom: 24px;
  left: 20px;
  z-index: 900;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #B1804C, #874f22);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45), 0 0 12px rgba(177, 128, 76, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.25);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  user-select: none;
}

@media (max-width: 480px) {
  .floating-autoscroll-widget {
    left: 16px;
    bottom: 20px;
    width: 44px;
    height: 44px;
  }
}

.floating-autoscroll-widget:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.6), 0 0 18px rgba(255, 228, 145, 0.65);
}

.floating-autoscroll-widget:active {
  transform: scale(0.95);
}

.autoscroll-pulse-ring {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2px dashed rgba(255, 228, 145, 0.7);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.floating-autoscroll-widget.is-scrolling .autoscroll-pulse-ring {
  opacity: 1;
  animation: rotate-ring 9s linear infinite;
}

@keyframes rotate-ring {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.autoscroll-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  color: #ffffff;
  pointer-events: none;
}

.autoscroll-icon svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.5));
}

.autoscroll-tooltip {
  position: absolute;
  left: 54px;
  top: 50%;
  transform: translateY(-50%);
  background: #190C1F;
  border: 1px solid var(--color-gold-border);
  color: #ffffff;
  font-size: 12px;
  font-family: var(--font-sans);
  font-weight: 500;
  padding: 5px 11px;
  border-radius: 8px;
  white-space: nowrap;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.55);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
}

.floating-autoscroll-widget:hover .autoscroll-tooltip,
.autoscroll-tooltip.show-toast {
  opacity: 1;
  visibility: visible;
  transform: translateY(-50%) translateX(2px);
}

/* While JS auto-scrolling is active, override smooth scrolling to avoid stutter */
html.is-auto-scrolling {
  scroll-behavior: auto !important;
}

.floating-sound-widget {
  position: fixed;
  bottom: 24px;
  right: 20px;
  z-index: 900;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #B1804C, #874f22);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45), 0 0 12px rgba(177, 128, 76, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.25);
  transition: transform 0.25s ease;
}

.floating-chat-widget {
  position: fixed;
  bottom: 80px;
  right: 20px;
  z-index: 900;
  display: flex;
  align-items: center;
  gap: 8px;
}

.chat-btn {
  position: relative;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background-color: #fb3570;
  border: none;
  box-shadow: 0 4px 14px rgba(251, 53, 112, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  cursor: pointer;
}

.chat-ping {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background-color: #fb3570;
  animation: ping-slow 2.4s cubic-bezier(0, 0, 0.2, 1) infinite;
  opacity: 0.3;
  pointer-events: none;
}

/* ============================================================
   ANIMATIONS & KEYFRAMES
============================================================ */
@keyframes ambient-fall {
  0% {
    transform: translateY(0) translateX(0) rotate(0deg);
    opacity: 0;
  }

  10% {
    opacity: 0.9;
  }

  90% {
    opacity: 0.9;
  }

  100% {
    transform: translateY(105vh) translateX(var(--sway, 20px)) rotate(360deg);
    opacity: 0;
  }
}

@keyframes seal-pulse {

  0%,
  100% {
    transform: translate(-50%, -50%) scale(1);
    box-shadow: 0 4px 20px rgba(177, 128, 76, 0.5), inset 0 2px 4px rgba(255, 255, 255, 0.3);
  }

  50% {
    transform: translate(-50%, -50%) scale(1.08);
    box-shadow: 0 6px 28px rgba(177, 128, 76, 0.75), inset 0 2px 6px rgba(255, 255, 255, 0.45);
  }
}

@keyframes shine {
  0% {
    transform: translateX(-150%) skewX(-20deg);
  }

  30%,
  100% {
    transform: translateX(350%) skewX(-20deg);
  }
}

@keyframes giftbox-bob {
  0% {
    transform: translateY(0px) rotate(0deg);
  }

  50% {
    transform: translateY(-10px) rotate(1deg);
  }

  100% {
    transform: translateY(0px) rotate(0deg);
  }
}

@keyframes float-mini-1 {

  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }

  50% {
    transform: translate(6px, -10px) rotate(8deg);
  }
}

@keyframes float-mini-2 {

  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }

  50% {
    transform: translate(-8px, -12px) rotate(-6deg);
  }
}

@keyframes soundbar-1 {

  0%,
  100% {
    height: 5px;
  }

  50% {
    height: 16px;
  }
}

@keyframes soundbar-2 {

  0%,
  100% {
    height: 18px;
  }

  50% {
    height: 7px;
  }
}

@keyframes soundbar-3 {

  0%,
  100% {
    height: 8px;
  }

  50% {
    height: 20px;
  }
}

@keyframes ping-slow {
  0% {
    transform: scale(1);
    opacity: 0.6;
  }

  75%,
  100% {
    transform: scale(1.8);
    opacity: 0;
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes scaleUp {
  from {
    opacity: 0;
    transform: scale(0.92);
  }

  to {
    opacity: 1;
    transform: scale(1);
  }
}