/* ===================================================================
   SSLSD MEDIA UNIT INAUGURATION - OFFICIAL PRESTIGE INVITATION
   Royal School Colors: Imperial Maroon, Royal Midnight Navy, Lustrous Gold
   =================================================================== */

:root {
  /* Color Palette */
  --color-maroon-dark: #2B050C;
  --color-maroon: #4D0917;
  --color-maroon-rich: #6D0D21;
  --color-maroon-bright: #93132D;

  --color-navy-deep: #050A17;
  --color-navy: #0B132B;
  --color-navy-card: #0F1B38;
  --color-navy-light: #1C2B54;

  --color-gold-light: #F9E7B3;
  --color-gold-base: #DFB757;
  --color-gold-rich: #C99736;
  --color-gold-dark: #8F651C;
  --color-gold-foil: linear-gradient(135deg, #F9E7B3 0%, #DFB757 35%, #FFF0C2 50%, #C99736 75%, #8F651C 100%);
  --color-gold-gradient: linear-gradient(135deg, #ECC86A 0%, #C99736 100%);

  --color-surface-glass: rgba(15, 27, 56, 0.72);
  --color-surface-glass-border: rgba(223, 183, 87, 0.35);

  --font-serif-royal: 'Cinzel', 'Playfair Display', Georgia, serif;
  --font-serif-decorative: 'Cinzel Decorative', 'Cinzel', serif;
  --font-serif-body: 'Playfair Display', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  --shadow-gold-glow: 0 0 25px rgba(223, 183, 87, 0.38);
  --shadow-gold-intense: 0 0 40px rgba(223, 183, 87, 0.65);
  --shadow-card: 0 20px 50px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(223, 183, 87, 0.3);
  
  --ease-smooth: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Base Reset & Smooth Scroll */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  min-height: 100%;
  overflow-x: hidden;
  background-color: var(--color-navy-deep);
  color: #FFFFFF;
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Radial luxury backdrop */
body {
  background: 
    radial-gradient(circle at 50% 15%, rgba(109, 13, 33, 0.45) 0%, transparent 65%),
    radial-gradient(circle at 10% 80%, rgba(14, 27, 70, 0.7) 0%, transparent 60%),
    radial-gradient(circle at 90% 85%, rgba(43, 5, 12, 0.6) 0%, transparent 60%),
    linear-gradient(180deg, #050A17 0%, #0A1124 50%, #060914 100%);
  background-attachment: fixed;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  padding-bottom: env(safe-area-inset-bottom, 20px);
}

/* Background Ambient Canvas & Confetti */
.ambient-canvas,
.confetti-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 1;
}

.confetti-canvas {
  z-index: 99;
}

/* ===================================================================
   TOP NAVIGATION
   =================================================================== */
.top-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  padding-top: env(safe-area-inset-top, 0px);
  background: rgba(5, 10, 23, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(223, 183, 87, 0.18);
  z-index: 50;
  transition: transform 0.3s ease;
}

.school-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(109, 13, 33, 0.35);
  border: 1px solid rgba(223, 183, 87, 0.3);
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-gold-light);
  font-weight: 600;
}

.school-mini-logo {
  width: 22px;
  height: 22px;
  object-fit: contain;
  filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.7));
}

.pill-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--color-gold-base);
  box-shadow: 0 0 8px var(--color-gold-base);
  animation: pulseDot 2s infinite ease-in-out;
}

@keyframes pulseDot {
  0%, 100% { opacity: 0.6; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.15); box-shadow: 0 0 12px var(--color-gold-light); }
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.icon-btn {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(223, 183, 87, 0.25);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-gold-light);
  cursor: pointer;
  transition: all 0.2s ease;
}

.icon-btn:hover {
  background: rgba(223, 183, 87, 0.2);
  border-color: var(--color-gold-base);
  transform: scale(1.05);
}

.btn-icon {
  width: 18px;
  height: 18px;
}



/* ===================================================================
   MAIN CONTAINER
   =================================================================== */
.invitation-container {
  width: 100%;
  max-width: 520px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 80px 16px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  z-index: 10;
}

/* ===================================================================
   STAGE 1: ENVELOPE SCENE
   =================================================================== */
.envelope-scene {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  perspective: 1200px;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.envelope-wrapper {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.envelope-teaser {
  text-align: center;
  margin-bottom: 24px;
  animation: fadeInDown 0.9s var(--ease-smooth);
}

.teaser-tag {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-gold-base);
  font-weight: 700;
  margin-bottom: 6px;
}

.teaser-guest {
  font-family: var(--font-serif-royal);
  font-size: 1.55rem;
  font-weight: 700;
  color: #FFFFFF;
  background: var(--color-gold-foil);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.25;
  margin-bottom: 6px;
}

.teaser-sub {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.7);
  letter-spacing: 0.05em;
}

/* Envelope Box Structure */
.envelope-box {
  position: relative;
  width: 100%;
  max-width: 400px;
  height: 250px;
  background: linear-gradient(160deg, #4A0815 0%, #2A050D 100%);
  border-radius: 12px;
  box-shadow: 
    0 25px 50px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(223, 183, 87, 0.35),
    inset 0 0 35px rgba(0, 0, 0, 0.5);
  perspective: 1000px;
  overflow: visible;
  transition: transform 0.5s var(--ease-smooth);
}

/* Flaps */
.flap {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  pointer-events: none;
}

/* Flap Top (Triangular fold) */
.flap-top {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 130px;
  transform-origin: top center;
  transition: transform 0.85s cubic-bezier(0.4, 0, 0.2, 1), z-index 0.2s 0.4s;
  z-index: 15;
}

.flap-top::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  border-left: 200px solid transparent;
  border-right: 200px solid transparent;
  border-top: 130px solid #5C0C1C;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.6));
}

@media (max-width: 420px) {
  .envelope-box {
    height: 230px;
  }
  .flap-top::after {
    border-left-width: 175px;
    border-right-width: 175px;
    border-top-width: 118px;
  }
}

/* Gold Embroidery trim on flap */
.flap-lining {
  position: absolute;
  top: 2px;
  left: 10px;
  right: 10px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--color-gold-base), transparent);
}

/* Flap Left & Right */
.flap-left {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 0;
  border-top: 125px solid transparent;
  border-bottom: 125px solid transparent;
  border-left: 170px solid #3F0611;
  z-index: 10;
}

.flap-right {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 0;
  height: 0;
  border-top: 125px solid transparent;
  border-bottom: 125px solid transparent;
  border-right: 170px solid #3F0611;
  z-index: 10;
}

/* Flap Bottom */
.flap-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 0;
  border-left: 200px solid transparent;
  border-right: 200px solid transparent;
  border-bottom: 140px solid #35050E;
  z-index: 11;
}

@media (max-width: 420px) {
  .flap-bottom {
    border-left-width: 175px;
    border-right-width: 175px;
    border-bottom-width: 125px;
  }
  .flap-left {
    border-left-width: 140px;
    border-top-width: 115px;
    border-bottom-width: 115px;
  }
  .flap-right {
    border-right-width: 140px;
    border-top-width: 115px;
    border-bottom-width: 115px;
  }
}

/* Envelope Letter Hint inside pocket */
.envelope-letter-hint {
  position: absolute;
  top: 25px;
  left: 20px;
  right: 20px;
  height: 180px;
  background: linear-gradient(180deg, #101E42 0%, #081024 100%);
  border-radius: 8px 8px 0 0;
  border: 1px solid rgba(223, 183, 87, 0.4);
  border-bottom: none;
  z-index: 2;
  box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.4);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 14px;
  transition: transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.hint-gold-header {
  font-family: var(--font-serif-royal);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  color: var(--color-gold-base);
  display: flex;
  align-items: center;
  gap: 6px;
}

.hint-crest-mini {
  color: var(--color-gold-light);
  font-size: 0.7rem;
}

/* Wax Seal Assembly */
.wax-seal-container {
  position: absolute;
  top: 115px;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 25;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  outline: none;
}

@media (max-width: 420px) {
  .wax-seal-container {
    top: 105px;
  }
  .wax-seal {
    width: 98px !important;
    height: 98px !important;
  }
}

.wax-seal {
  position: relative;
  width: 106px;
  height: 106px;
  border-radius: 50%;
  box-shadow: 
    0 12px 28px rgba(0, 0, 0, 0.85),
    0 0 30px rgba(223, 183, 87, 0.55),
    inset 0 0 12px rgba(0, 0, 0, 0.6);
  transition: transform 0.3s var(--ease-spring), filter 0.3s ease;
  overflow: hidden;
  border: 2px solid #F9E7B3;
}

.wax-seal-container:hover .wax-seal,
.wax-seal-container:focus-visible .wax-seal {
  transform: scale(1.08);
  box-shadow: 
    0 14px 35px rgba(0, 0, 0, 0.9),
    0 0 40px rgba(223, 183, 87, 0.9);
}

.seal-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 50%;
}

.seal-shimmer {
  position: absolute;
  top: -100%;
  left: -100%;
  width: 300%;
  height: 300%;
  background: linear-gradient(
    45deg,
    transparent 40%,
    rgba(255, 255, 255, 0.45) 50%,
    transparent 60%
  );
  animation: sealShine 3.5s infinite linear;
  pointer-events: none;
}

@keyframes sealShine {
  0% { transform: translate(-50%, -50%) rotate(0deg); }
  100% { transform: translate(50%, 50%) rotate(360deg); }
}

.wax-seal-pulse {
  position: absolute;
  top: -12px;
  left: -12px;
  right: -12px;
  bottom: 20px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(223, 183, 87, 0.35) 0%, transparent 70%);
  animation: sealPulseRing 2.2s infinite ease-out;
  pointer-events: none;
}

@keyframes sealPulseRing {
  0% { transform: scale(0.85); opacity: 0.8; }
  50% { transform: scale(1.2); opacity: 0.3; }
  100% { transform: scale(1.4); opacity: 0; }
}

/* Tap to Open Pill */
.unseal-action-pill {
  margin-top: 10px;
  background: rgba(5, 10, 23, 0.88);
  border: 1px solid var(--color-gold-base);
  color: var(--color-gold-light);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 20px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6), 0 0 10px rgba(223, 183, 87, 0.3);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  animation: bounceHint 2s infinite ease-in-out;
}

@keyframes bounceHint {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

.envelope-footnote {
  margin-top: 28px;
  font-size: 0.8rem;
  color: rgba(223, 183, 87, 0.8);
  letter-spacing: 0.05em;
  text-align: center;
}

/* ===================================================================
   OPENING ENVELOPE ANIMATION STATES
   =================================================================== */
.envelope-scene.is-opening .wax-seal-container {
  animation: sealCrackOpen 0.5s forwards ease-in;
  pointer-events: none;
}

@keyframes sealCrackOpen {
  0% { transform: translate(-50%, -50%) scale(1); filter: brightness(1); }
  50% { transform: translate(-50%, -50%) scale(1.25); filter: brightness(2) drop-shadow(0 0 25px #FFF); }
  100% { transform: translate(-50%, -50%) scale(0); opacity: 0; }
}

.envelope-scene.is-opening .flap-top {
  transform: rotateX(180deg);
  z-index: 1;
}

.envelope-scene.is-opening .envelope-letter-hint {
  transform: translateY(-80px);
  transition-delay: 0.35s;
}

.envelope-scene.fade-out {
  opacity: 0;
  transform: scale(0.92) translateY(20px);
  pointer-events: none;
}

/* ===================================================================
   STAGE 2: 3D PRESTIGE INVITATION CARD
   =================================================================== */
.card-scene {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: cardRevealPop 0.9s cubic-bezier(0.2, 1, 0.28, 1) forwards;
}

@keyframes cardRevealPop {
  0% {
    opacity: 0;
    transform: translateY(60px) scale(0.9);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.tilt-wrapper {
  width: 100%;
  max-width: 480px;
  perspective: 1200px;
  margin: 0 auto;
}

.prestige-card {
  position: relative;
  width: 100%;
  background: 
    radial-gradient(circle at 50% 10%, rgba(109, 13, 33, 0.55) 0%, transparent 60%),
    radial-gradient(circle at 50% 90%, rgba(14, 27, 70, 0.6) 0%, transparent 70%),
    linear-gradient(175deg, #0C152E 0%, #070B18 50%, #160710 100%);
  border-radius: 18px;
  padding: 30px 24px;
  box-shadow: 
    0 25px 60px rgba(0, 0, 0, 0.85),
    0 0 0 1px rgba(223, 183, 87, 0.45),
    inset 0 0 40px rgba(0, 0, 0, 0.6);
  transform: none !important;
  transition: box-shadow 0.25s ease;
  overflow: hidden;
}

/* Refined Specular Glint Sheen Layer */
.holographic-sheen {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  background: none;
  opacity: 0;
  pointer-events: none;
  z-index: 5;
  mix-blend-mode: overlay;
  transition: opacity 0.35s ease;
}

/* Card Double Gold Filigree Border */
.card-border-filigree {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  bottom: 10px;
  border: 1px solid rgba(223, 183, 87, 0.38);
  border-radius: 12px;
  pointer-events: none;
  z-index: 2;
}

.card-border-filigree::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  right: 3px;
  bottom: 3px;
  border: 1px dashed rgba(223, 183, 87, 0.22);
  border-radius: 9px;
}

/* Corner Ornaments (Prestige Royal Motifs) */
.corner-ornament {
  position: absolute;
  width: 24px;
  height: 24px;
  z-index: 3;
  pointer-events: none;
}

.corner-ornament::before,
.corner-ornament::after {
  content: '';
  position: absolute;
  background: var(--color-gold-base);
}

.corner-top-left {
  top: 14px;
  left: 14px;
  border-top: 2px solid var(--color-gold-base);
  border-left: 2px solid var(--color-gold-base);
}
.corner-top-right {
  top: 14px;
  right: 14px;
  border-top: 2px solid var(--color-gold-base);
  border-right: 2px solid var(--color-gold-base);
}
.corner-bottom-left {
  bottom: 14px;
  left: 14px;
  border-bottom: 2px solid var(--color-gold-base);
  border-left: 2px solid var(--color-gold-base);
}
.corner-bottom-right {
  bottom: 14px;
  right: 14px;
  border-bottom: 2px solid var(--color-gold-base);
  border-right: 2px solid var(--color-gold-base);
}

/* Card Content Inner Layout */
.card-inner {
  position: relative;
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* Header & Insignia */
.card-header {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 18px;
}

.insignia-wrapper {
  width: 82px;
  height: 82px;
  margin-bottom: 12px;
  position: relative;
}

.card-seal-icon {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  box-shadow: 
    0 8px 24px rgba(0, 0, 0, 0.7),
    0 0 25px rgba(223, 183, 87, 0.45);
  border: 2px solid var(--color-gold-light);
  display: block;
  object-fit: cover;
}

.school-headline {
  font-family: var(--font-sans);
  font-size: 0.76rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-gold-light);
  font-weight: 700;
  margin-bottom: 2px;
}

.school-motto-tag {
  font-family: var(--font-serif-body);
  font-style: italic;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: var(--color-gold-base);
  margin-bottom: 6px;
  opacity: 0.95;
}

.invitation-kicker {
  font-family: var(--font-serif-body);
  font-style: italic;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 8px;
}

.event-title {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 10px;
}

.title-sub {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-gold-base);
  font-weight: 700;
}

.title-main {
  font-family: var(--font-serif-royal);
  font-size: 1.65rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  background: var(--color-gold-foil);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 4px 15px rgba(223, 183, 87, 0.3);
  line-height: 1.2;
}

@media (max-width: 380px) {
  .title-main {
    font-size: 1.45rem;
  }
}

.motto-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  max-width: 280px;
  margin-top: 4px;
}

.divider-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(223, 183, 87, 0.5), transparent);
}

.divider-icon {
  font-size: 0.72rem;
  color: var(--color-gold-light);
  letter-spacing: 0.1em;
}

/* ===================================================================
   VIP GUEST SPOTLIGHT SECTION (PERSONALIZED)
   =================================================================== */
.guest-spotlight {
  width: 100%;
  background: linear-gradient(135deg, rgba(109, 13, 33, 0.35) 0%, rgba(14, 27, 70, 0.45) 100%);
  border: 1px solid rgba(223, 183, 87, 0.4);
  border-radius: 14px;
  padding: 16px 14px;
  margin-bottom: 20px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4), inset 0 0 15px rgba(223, 183, 87, 0.08);
  position: relative;
  overflow: hidden;
}

.guest-salutation {
  font-family: var(--font-sans);
  font-size: 0.65rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-gold-base);
  font-weight: 700;
  margin-bottom: 4px;
}

.guest-name-plate {
  position: relative;
  display: inline-block;
  margin-bottom: 8px;
}

.guest-name-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80%;
  height: 100%;
  background: radial-gradient(circle, rgba(223, 183, 87, 0.3) 0%, transparent 70%);
  pointer-events: none;
  filter: blur(10px);
}

.guest-name {
  font-family: var(--font-serif-royal);
  font-size: 1.6rem;
  font-weight: 800;
  color: #FFFFFF;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
  letter-spacing: 0.03em;
  position: relative;
}

@media (max-width: 380px) {
  .guest-name {
    font-size: 1.38rem;
  }
}

.guest-credentials {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.badge-role,
.badge-level {
  background: rgba(223, 183, 87, 0.16);
  border: 1px solid rgba(223, 183, 87, 0.45);
  color: var(--color-gold-light);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  letter-spacing: 0.04em;
}

.badge-separator {
  color: var(--color-gold-base);
  font-size: 0.8rem;
}

.cordial-message {
  font-size: 0.84rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.88);
  font-weight: 400;
  max-width: 400px;
  margin: 0 auto;
}

/* ===================================================================
   EVENT META GRID (DATE, TIME, VENUE)
   =================================================================== */
.event-meta-grid {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.meta-box {
  background: rgba(11, 19, 43, 0.75);
  border: 1px solid rgba(223, 183, 87, 0.25);
  border-radius: 12px;
  padding: 12px 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-align: left;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.meta-box:hover {
  border-color: var(--color-gold-base);
}

.meta-box.full-width {
  grid-column: 1 / -1;
}

.meta-icon-circle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(109, 13, 33, 0.4);
  border: 1px solid rgba(223, 183, 87, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--color-gold-base);
}

.meta-icon-circle svg {
  width: 18px;
  height: 18px;
}

.meta-text {
  display: flex;
  flex-direction: column;
}

.meta-label {
  font-size: 0.62rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-gold-base);
  font-weight: 700;
}

.meta-value {
  font-size: 0.95rem;
  font-weight: 700;
  color: #FFFFFF;
  line-height: 1.25;
}

.meta-sub {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.65);
}

/* ===================================================================
   COUNTDOWN TIMER
   =================================================================== */
.countdown-section {
  width: 100%;
  background: rgba(5, 10, 23, 0.7);
  border: 1px solid rgba(223, 183, 87, 0.3);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 22px;
}

.countdown-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-gold-base);
  font-weight: 700;
  margin-bottom: 8px;
}

.countdown-timer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.timer-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 50px;
}

.timer-num {
  font-family: var(--font-serif-royal);
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--color-gold-light);
  line-height: 1;
  text-shadow: 0 0 10px rgba(223, 183, 87, 0.5);
}

.timer-tag {
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.6);
  margin-top: 3px;
}

.timer-colon {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--color-gold-base);
  padding-bottom: 12px;
}

/* ===================================================================
   ACTION BUTTONS
   =================================================================== */
.card-actions {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.action-btn {
  width: 100%;
  height: 48px;
  border-radius: 10px;
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.25s var(--ease-smooth);
  border: none;
  outline: none;
  text-decoration: none;
}

.action-btn-icon {
  width: 18px;
  height: 18px;
}

/* Gold Primary Button */
.primary-gold-btn {
  background: var(--color-gold-gradient);
  color: #1A0909;
  box-shadow: 0 4px 18px rgba(223, 183, 87, 0.35);
}

.primary-gold-btn:hover {
  background: linear-gradient(135deg, #FFF0C2 0%, #DFB757 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(223, 183, 87, 0.55);
}

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

/* Royal Blue Secondary Button */
.royal-blue-btn {
  background: rgba(28, 43, 84, 0.8);
  border: 1px solid rgba(223, 183, 87, 0.4);
  color: #FFFFFF;
}

.royal-blue-btn:hover {
  background: rgba(36, 56, 110, 0.95);
  border-color: var(--color-gold-base);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(11, 19, 43, 0.6);
}

/* Royal Green WhatsApp Button */
.royal-green-btn {
  background: linear-gradient(135deg, #1E7E44 0%, #155E32 100%);
  border: 1px solid #48D17B;
  color: #FFFFFF;
}

.royal-green-btn:hover {
  background: linear-gradient(135deg, #259954 0%, #1B7840 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
}

/* Secondary Ghost Links */
.secondary-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  width: 100%;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.ghost-link-btn {
  background: none;
  border: none;
  color: var(--color-gold-light);
  font-size: 0.78rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 6px;
  border-radius: 4px;
  opacity: 0.85;
  transition: all 0.2s ease;
}

.ghost-link-btn:hover {
  opacity: 1;
  color: #FFFFFF;
  text-decoration: underline;
}

.tiny-icon {
  width: 14px;
  height: 14px;
}

/* Card Footer */
.card-footer {
  width: 100%;
  border-top: 1px solid rgba(223, 183, 87, 0.2);
  padding-top: 14px;
  margin-top: 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.footer-signoff {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.signoff-role {
  font-family: var(--font-serif-body);
  font-style: italic;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.9);
}

.signoff-unit {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-gold-base);
  font-weight: 700;
}

.footer-crest-decor {
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  color: rgba(223, 183, 87, 0.55);
}

/* Motion Hint */
.motion-hint {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  color: rgba(223, 183, 87, 0.75);
  margin-top: 14px;
  background: rgba(5, 10, 23, 0.5);
  padding: 4px 12px;
  border-radius: 12px;
  border: 1px solid rgba(223, 183, 87, 0.15);
}

/* ===================================================================
   MODALS
   =================================================================== */
.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(4, 7, 18, 0.82);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 100;
  animation: fadeIn 0.25s ease;
}

.modal-card {
  width: 100%;
  max-width: 440px;
  background: linear-gradient(165deg, #101B3A 0%, #070D1F 100%);
  border: 1px solid var(--color-gold-base);
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8), var(--shadow-gold-glow);
  padding: 22px;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
  animation: scaleUp 0.28s var(--ease-spring);
}

.modal-large {
  max-width: 480px;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(223, 183, 87, 0.2);
  padding-bottom: 10px;
}

.modal-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-icon {
  font-size: 1.25rem;
}

.modal-header h3 {
  font-family: var(--font-serif-royal);
  font-size: 1.12rem;
  color: var(--color-gold-light);
  font-weight: 700;
}

.modal-close-btn {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.65);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  transition: color 0.2s ease;
  padding: 0 4px;
}

.modal-close-btn:hover {
  color: var(--color-gold-light);
}

.modal-body {
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.9);
}

.modal-desc {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 16px;
  line-height: 1.45;
}

/* Venue rows */
.venue-detail-row {
  margin-bottom: 12px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 8px;
  border-left: 3px solid var(--color-gold-base);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.venue-detail-row strong {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-gold-light);
}

.venue-detail-row span {
  font-size: 0.85rem;
  color: #FFFFFF;
}

.modal-buttons {
  margin-top: 18px;
  display: flex;
  justify-content: flex-end;
}

/* Calendar Choices */
.calendar-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.calendar-choice-btn {
  width: 100%;
  padding: 12px 14px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(223, 183, 87, 0.3);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
}

.calendar-choice-btn:hover {
  background: rgba(223, 183, 87, 0.15);
  border-color: var(--color-gold-base);
  transform: translateX(4px);
}

.cal-brand-icon {
  font-size: 1.5rem;
}

.cal-name {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--color-gold-light);
}

.cal-hint {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.6);
}

/* Generator Form */
.generator-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
  text-align: left;
}

.form-group label {
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-gold-light);
}

.form-group input {
  height: 42px;
  padding: 0 12px;
  border-radius: 8px;
  background: rgba(5, 10, 23, 0.9);
  border: 1px solid rgba(223, 183, 87, 0.4);
  color: #FFFFFF;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input:focus {
  border-color: var(--color-gold-base);
  box-shadow: 0 0 10px rgba(223, 183, 87, 0.4);
}

.generated-preview-box {
  margin-top: 10px;
  background: rgba(5, 10, 23, 0.85);
  border: 1px solid rgba(223, 183, 87, 0.4);
  border-radius: 10px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.preview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.preview-title {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-gold-light);
  font-weight: 700;
}

.preview-format-tag {
  font-size: 0.68rem;
  background: rgba(223, 183, 87, 0.2);
  color: var(--color-gold-light);
  padding: 2px 8px;
  border-radius: 4px;
}

.url-display {
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.8rem;
  color: #8AE6AF;
  word-break: break-all;
  background: rgba(0, 0, 0, 0.45);
  padding: 8px 10px;
  border-radius: 6px;
  border: 1px dashed rgba(223, 183, 87, 0.3);
}

.generator-actions-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 6px;
}

.presets-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.presets-label {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.6);
  width: 100%;
  margin-bottom: 2px;
}

.preset-pill {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(223, 183, 87, 0.3);
  color: var(--color-gold-light);
  font-size: 0.72rem;
  padding: 4px 9px;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.preset-pill:hover {
  background: rgba(223, 183, 87, 0.25);
  border-color: var(--color-gold-base);
}

/* ===================================================================
   TOAST NOTIFICATION
   =================================================================== */
.toast-notification {
  position: fixed;
  bottom: 25px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(8, 14, 30, 0.95);
  border: 1px solid var(--color-gold-base);
  color: var(--color-gold-light);
  padding: 10px 18px;
  border-radius: 30px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7), var(--shadow-gold-glow);
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  z-index: 200;
  animation: toastPop 0.3s var(--ease-spring);
}

.toast-icon {
  background: var(--color-gold-base);
  color: #1A0909;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 800;
}

/* Utility Animations */
.hidden {
  display: none !important;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-16px); }
  to { opacity: 1; transform: translateY(0); }
}

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

@keyframes toastPop {
  from { opacity: 0; transform: translate(-50%, 15px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

/* ===================================================================
   VIP INVITATION PASS PDF TEMPLATE STYLES
   =================================================================== */
.pdf-render-container {
  position: fixed;
  left: -9999px;
  top: 0;
  width: 680px;
  z-index: -999;
}

.pdf-card {
  width: 660px;
  max-width: 660px;
  min-height: auto;
  max-height: 940px;
  background: 
    radial-gradient(circle at 50% 12%, rgba(109, 13, 33, 0.6) 0%, transparent 65%),
    radial-gradient(circle at 50% 88%, rgba(14, 27, 70, 0.65) 0%, transparent 70%),
    linear-gradient(175deg, #0A132C 0%, #070B18 50%, #1A050E 100%);
  border-radius: 16px;
  padding: 30px 24px;
  position: relative;
  box-sizing: border-box;
  color: #FFFFFF;
  text-align: center;
  font-family: var(--font-sans);
  border: 2px solid var(--color-gold-base);
  box-shadow: 0 0 30px rgba(0, 0, 0, 0.9);
  page-break-inside: avoid !important;
  page-break-after: avoid !important;
  page-break-before: avoid !important;
}

.pdf-card-border {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  bottom: 10px;
  border: 1px dashed rgba(223, 183, 87, 0.45);
  border-radius: 10px;
  pointer-events: none;
}

.pdf-corner {
  position: absolute;
  width: 22px;
  height: 22px;
  border-color: var(--color-gold-base);
  border-style: solid;
  pointer-events: none;
}

.pdf-corner-tl { top: 14px; left: 14px; border-width: 2px 0 0 2px; }
.pdf-corner-tr { top: 14px; right: 14px; border-width: 2px 2px 0 0; }
.pdf-corner-bl { bottom: 14px; left: 14px; border-width: 0 0 2px 2px; }
.pdf-corner-br { bottom: 14px; right: 14px; border-width: 0 2px 2px 0; }

.pdf-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 16px;
}

.pdf-seal-img {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  border: 2px solid var(--color-gold-light);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
  margin-bottom: 10px;
  display: block;
  object-fit: cover;
}

.pdf-school-name {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--color-gold-light);
  font-weight: 700;
  margin-bottom: 3px;
}

.pdf-school-motto {
  font-family: var(--font-serif-body);
  font-style: italic;
  font-size: 0.82rem;
  color: var(--color-gold-base);
  margin-bottom: 10px;
}

.pdf-pass-tag {
  font-size: 0.66rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  background: rgba(109, 13, 33, 0.5);
  border: 1px solid rgba(223, 183, 87, 0.4);
  color: var(--color-gold-light);
  padding: 4px 14px;
  border-radius: 20px;
  margin-bottom: 10px;
  font-weight: 700;
}

.pdf-event-title {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 6px;
}

.pdf-title-sub {
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  color: var(--color-gold-base);
  font-weight: 700;
}

.pdf-title-main {
  font-family: var(--font-serif-royal);
  font-size: 1.75rem;
  font-weight: 900;
  color: #F9E7B3;
  letter-spacing: 0.08em;
  line-height: 1.2;
}

.pdf-divider {
  color: var(--color-gold-base);
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  margin: 6px 0;
}

.pdf-body {
  background: linear-gradient(135deg, rgba(109, 13, 33, 0.35) 0%, rgba(14, 27, 70, 0.45) 100%);
  border: 1px solid rgba(223, 183, 87, 0.4);
  border-radius: 12px;
  padding: 16px 14px;
  margin-bottom: 18px;
}

.pdf-salutation-tag {
  font-size: 0.64rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-gold-base);
  font-weight: 700;
  margin-bottom: 4px;
}

.pdf-guest-name-box {
  margin-bottom: 6px;
}

.pdf-guest-name {
  font-family: var(--font-serif-royal);
  font-size: 1.75rem;
  font-weight: 800;
  color: #FFFFFF;
  letter-spacing: 0.04em;
}

.pdf-guest-badges {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
}

.pdf-badge {
  background: rgba(223, 183, 87, 0.18);
  border: 1px solid rgba(223, 183, 87, 0.5);
  color: var(--color-gold-light);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 6px;
}

.pdf-badge-sep {
  color: var(--color-gold-base);
}

.pdf-message {
  font-size: 0.84rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 14px;
  max-width: 440px;
  margin-left: auto;
  margin-right: auto;
}

.pdf-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-around;
  background: rgba(7, 13, 28, 0.75);
  border: 1px solid rgba(223, 183, 87, 0.35);
  border-radius: 10px;
  padding: 10px 8px;
}

.pdf-meta-item {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.pdf-meta-lbl {
  font-size: 0.6rem;
  letter-spacing: 0.16em;
  color: var(--color-gold-base);
  font-weight: 700;
}

.pdf-meta-val {
  font-size: 0.92rem;
  font-weight: 700;
  color: #FFFFFF;
}

.pdf-meta-sub {
  font-size: 0.68rem;
  color: rgba(255, 255, 255, 0.65);
}

.pdf-meta-divider {
  width: 1px;
  height: 32px;
  background: rgba(223, 183, 87, 0.3);
}

.pdf-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid rgba(223, 183, 87, 0.25);
  padding-top: 12px;
}

.pdf-pass-code {
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.7rem;
  color: var(--color-gold-light);
  display: flex;
  align-items: center;
  gap: 6px;
}

.pdf-dot {
  color: var(--color-gold-base);
}

.pdf-signoff {
  text-align: right;
}

.pdf-sign-role {
  font-family: var(--font-serif-body);
  font-style: italic;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.9);
}

.pdf-sign-unit {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-gold-base);
  font-weight: 700;
}

/* Print CSS - Strictly Exactly 1 Page of A4 */
@page {
  size: A4 portrait;
  margin: 6mm;
}

@media print {
  html, body {
    width: 210mm !important;
    height: 297mm !important;
    max-height: 297mm !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    background: #070B18 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  body * {
    visibility: hidden !important;
  }

  .pdf-render-container,
  .pdf-render-container * {
    visibility: visible !important;
  }

  .pdf-render-container {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    width: 100% !important;
    height: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    page-break-after: avoid !important;
    page-break-before: avoid !important;
    page-break-inside: avoid !important;
  }

  .pdf-card {
    width: 185mm !important;
    max-height: 270mm !important;
    box-shadow: none !important;
    page-break-inside: avoid !important;
    page-break-after: avoid !important;
    page-break-before: avoid !important;
    margin: auto !important;
  }
}

