/* ============================================================
   UNDANGAN ULANG TAHUN — FAEYZA MAULA SAKHAWI
   style.css
   ============================================================ */

/* ── RESET & BASE ── */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  font-family: 'Nunito', sans-serif;
  overflow-x: hidden;
}

/* ── CSS VARIABLES ── */
:root {
  --red:    #E53935;
  --red2:   #FF5252;
  --dark:   #0d0d1f;
  --blue:   #1565C0;
  --blue2:  #42A5F5;
  --green:  #00C853;
  --yellow: #FFD600;
  --orange: #FF6D00;
  --purple: #7C4DFF;
}

body {
  background: var(--dark);
  min-height: 100vh;
}

/* ── BACKGROUND ── */
.rb-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 70% 60% at 10% 20%, rgba(229,57,53,0.35) 0%, transparent 55%),
    radial-gradient(ellipse 60% 70% at 90% 10%, rgba(21,101,192,0.40) 0%, transparent 55%),
    radial-gradient(ellipse 80% 50% at 50% 90%, rgba(124,77,255,0.30) 0%, transparent 55%),
    radial-gradient(ellipse 50% 60% at 80% 70%, rgba(229,57,53,0.25) 0%, transparent 50%),
    linear-gradient(160deg, #0d0d1f 0%, #1a1a2e 40%, #0a0a18 100%);
  animation: bgP 12s ease-in-out infinite alternate;
}

@keyframes bgP {
  0%   { filter: hue-rotate(0deg); }
  100% { filter: hue-rotate(10deg); }
}

.rb-grid {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.018) 1px, transparent 1px);
  background-size: 40px 40px;
}

/* ── GLASSMORPHISM ── */
.glass {
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(20px) saturate(1.5);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border: 1.5px solid rgba(255,255,255,0.18);
  box-shadow: 0 8px 32px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.15);
}

.glass-red {
  background: rgba(229,57,53,0.18);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1.5px solid rgba(229,57,53,0.4);
  box-shadow: 0 8px 32px rgba(229,57,53,0.2), inset 0 1px 0 rgba(255,255,255,0.15);
}

.glass-blue {
  background: rgba(21,101,192,0.20);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1.5px solid rgba(66,165,245,0.35);
  box-shadow: 0 8px 32px rgba(21,101,192,0.2), inset 0 1px 0 rgba(255,255,255,0.15);
}

.glass-green {
  background: rgba(0,200,83,0.15);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1.5px solid rgba(0,200,83,0.35);
  box-shadow: 0 8px 24px rgba(0,200,83,0.15), inset 0 1px 0 rgba(255,255,255,0.12);
}

.glass-gold {
  background: rgba(255,213,0,0.13);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1.5px solid rgba(255,213,0,0.30);
  box-shadow: 0 8px 24px rgba(255,213,0,0.12), inset 0 1px 0 rgba(255,255,255,0.12);
}

.glass-purple {
  background: rgba(124,77,255,0.15);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1.5px solid rgba(124,77,255,0.35);
  box-shadow: 0 8px 24px rgba(124,77,255,0.15), inset 0 1px 0 rgba(255,255,255,0.12);
}

.glass-wa {
  background: rgba(37,211,102,0.20);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1.5px solid rgba(37,211,102,0.45);
  box-shadow: 0 8px 28px rgba(37,211,102,0.25), inset 0 1px 0 rgba(255,255,255,0.15);
}

/* ── SHIMMER TEXT ── */
.shimmer-rb {
  background: linear-gradient(120deg, #FF5252 0%, #FFD600 30%, #fff 55%, #FF5252 80%);
  background-size: 300%;
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  animation: shim 3.5s ease-in-out infinite;
}

.shimmer-gold {
  background: linear-gradient(120deg, #FFD600, #FFF176, #FF6D00, #FFD600);
  background-size: 200%;
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  animation: shim 3s ease-in-out infinite;
}

@keyframes shim {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* ── FLOATING BALLS ── */
.ball {
  border-radius: 50%;
  position: absolute;
  pointer-events: none;
  animation: ballF ease-in-out infinite;
}

@keyframes ballF {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-18px); }
}

/* ── BALLOONS ── */
.bal-wrap {
  position: absolute;
  pointer-events: none;
  animation: balF ease-in-out infinite;
}

@keyframes balF {
  0%, 100% { transform: translateY(0) rotate(-3deg); }
  50%       { transform: translateY(-14px) rotate(3deg); }
}

.bal-body {
  border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
  position: relative;
}

.bal-body::after {
  content: '';
  position: absolute;
  bottom: -16px;
  left: 50%;
  transform: translateX(-50%);
  width: 1.5px;
  height: 18px;
  background: rgba(255,255,255,0.4);
}

.bal-shine {
  position: absolute;
  top: 12%;
  left: 20%;
  width: 25%;
  height: 25%;
  background: rgba(255,255,255,0.45);
  border-radius: 50%;
  transform: rotate(-30deg);
}

/* ── CONFETTI ── */
.cp {
  position: fixed;
  border-radius: 2px;
  animation: cpF linear forwards;
  pointer-events: none;
  z-index: 999;
}

@keyframes cpF {
  0%   { transform: translateY(-10px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(105vh) rotate(720deg); opacity: 0; }
}

/* ── STARS ── */
.star {
  position: fixed;
  border-radius: 50%;
  background: #fff;
  animation: twk ease-in-out infinite;
  z-index: 0;
  pointer-events: none;
}

@keyframes twk {
  0%, 100% { opacity: 0.06; transform: scale(1); }
  50%       { opacity: 0.70; transform: scale(1.4); }
}

/* ── OPENING / ENVELOPE ── */
/* Prevent page scroll while opening screen is active */
body.no-scroll {
  overflow: hidden;
  height: 100vh;
  touch-action: none;
}

#opening {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
  text-align: center;
  overflow: hidden;
  transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.34,1.56,0.64,1);
}

#opening.exit {
  opacity: 0;
  transform: scale(1.06);
  pointer-events: none;
}

/* ── ROBLOX BADGE (near envelope) ── */
.roblox-badge-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(0,0,0,0.45);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1.5px solid rgba(229,57,53,0.5);
  border-radius: 14px;
  padding: 8px 16px 8px 10px;
  margin-bottom: 18px;
  box-shadow: 0 4px 20px rgba(229,57,53,0.25), inset 0 1px 0 rgba(255,255,255,0.1);
  animation: badgePulse 3s ease-in-out infinite;
}
@keyframes badgePulse {
  0%,100% { box-shadow: 0 4px 20px rgba(229,57,53,0.25); }
  50%      { box-shadow: 0 6px 28px rgba(229,57,53,0.5); }
}

.roblox-icon-box {
  width: 42px; height: 42px;
  border-radius: 10px;
  background: linear-gradient(135deg, #E53935, #B71C1C);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  box-shadow: 0 3px 10px rgba(229,57,53,0.5);
  flex-shrink: 0;
}

.roblox-badge-text {
  display: flex;
  flex-direction: column;
  text-align: left;
  gap: 1px;
}

.roblox-title {
  font-family: 'Fredoka One', cursive;
  font-size: 1.05rem;
  color: white;
  letter-spacing: 0.06em;
  line-height: 1;
  text-shadow: 0 0 12px rgba(229,57,53,0.6);
}

.roblox-sub {
  font-family: 'Nunito', sans-serif;
  font-size: 10px;
  font-weight: 700;
  color: rgba(255,255,255,0.5);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* guest name card */
.guest-card {
  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 12px;
  padding: 6px 18px;
  margin-bottom: 8px;
  display: inline-block;
}

.guest-label {
  font-size: 10px;
  font-weight: 700;
  color: rgba(255,255,255,0.4);
  text-transform: uppercase;
  letter-spacing: 0.2em;
}

.guest-name {
  font-family: 'Baloo 2', cursive;
  font-size: 1.05rem;
  font-weight: 800;
  color: #FFD600;
  text-shadow: 0 0 14px rgba(255,213,0,0.5);
}

.envelope {
  width: min(240px, 72vw);
  height: min(160px, 48vw);
  position: relative;
  cursor: pointer;
  animation: envF 3s ease-in-out infinite;
  filter: drop-shadow(0 16px 40px rgba(229,57,53,0.5));
}

@keyframes envF {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50%       { transform: translateY(-12px) rotate(1deg); }
}

.env-body {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(229,57,53,0.35), rgba(21,101,192,0.35));
  border: 1.5px solid rgba(255,255,255,0.25);
  border-radius: 14px;
  backdrop-filter: blur(20px);
}

.env-flap {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 55%;
  background: linear-gradient(160deg, rgba(229,57,53,0.4), rgba(124,77,255,0.3));
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  border-radius: 14px 14px 0 0;
  transition: transform 0.6s ease;
  transform-origin: top center;
}

.envelope:hover .env-flap,
.envelope:active .env-flap {
  transform: rotateX(-150deg);
}

.env-seal {
  position: absolute;
  top: 28%; left: 50%;
  transform: translate(-50%, -50%);
  width: 44px; height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #E53935, #FF8F00);
  border: 2px solid rgba(255,255,255,0.4);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
  box-shadow: 0 4px 20px rgba(229,57,53,0.6);
  z-index: 2;
  animation: sP 2s ease-in-out infinite;
}

@keyframes sP {
  0%, 100% { box-shadow: 0 4px 20px rgba(229,57,53,0.5); }
  50%       { box-shadow: 0 4px 35px rgba(229,57,53,1); }
}

.open-btn {
  margin-top: 28px;
  padding: 15px 44px;
  border-radius: 999px;
  font-family: 'Fredoka One', sans-serif;
  font-size: 1.15rem;
  color: #fff;
  background: linear-gradient(135deg, #E53935, #C62828);
  border: 2px solid rgba(255,255,255,0.3);
  cursor: pointer;
  transition: transform 0.2s;
  box-shadow: 0 8px 32px rgba(229,57,53,0.5);
  animation: bP 2.5s ease-in-out infinite;
}

@keyframes bP {
  0%, 100% { box-shadow: 0 8px 32px rgba(229,57,53,0.5); }
  50%       { box-shadow: 0 12px 50px rgba(229,57,53,0.8), 0 0 0 8px rgba(229,57,53,0.1); }
}

.open-btn:hover { transform: scale(1.05); }

/* ── MAIN CONTENT ── */
#main-content {
  opacity: 0;
  transition: opacity 0.9s ease;
  position: relative;
  z-index: 10;
}

#main-content.show { opacity: 1; }

/* ── NAVBAR ── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 0 20px;
  background: rgba(13,13,31,0.80);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid rgba(229,57,53,0.25);
  box-shadow: 0 4px 24px rgba(0,0,0,0.4);
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}

.nav-logo-box {
  width: 34px; height: 34px;
  border-radius: 8px;
  background: linear-gradient(135deg, #E53935, #B71C1C);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  box-shadow: 0 4px 12px rgba(229,57,53,0.5);
}

.nav-logo-text {
  font-family: 'Fredoka One', sans-serif;
  font-size: 1rem;
  color: white;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: background 0.2s, color 0.2s;
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  background: rgba(229,57,53,0.15);
  color: white;
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 50%;
  transform: translateX(-50%);
  width: 20px; height: 2px;
  background: #E53935;
  border-radius: 2px;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-btn {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.15s;
  font-family: 'Nunito', sans-serif;
}

.nav-btn-wa {
  background: linear-gradient(135deg, #25D366, #128C7E);
  border: none;
  color: white;
  box-shadow: 0 4px 14px rgba(37,211,102,0.4);
}

.nav-btn-wa:hover { transform: scale(1.04); }

.nav-btn-solid {
  background: linear-gradient(135deg, #E53935, #C62828);
  border: none;
  color: white;
  box-shadow: 0 4px 14px rgba(229,57,53,0.4);
}

.nav-btn-solid:hover { transform: scale(1.04); }

.nav-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  flex-direction: column;
  gap: 5px;
  align-items: center;
  justify-content: center;
}

.nav-hamburger span {
  display: block;
  width: 22px; height: 2px;
  background: white;
  border-radius: 2px;
  transition: all 0.3s;
}

/* ── MOBILE NAV ── */
.nav-mobile {
  position: fixed;
  top: 60px; left: 0; right: 0;
  z-index: 99;
  background: rgba(13,13,31,0.97);
  backdrop-filter: blur(24px);
  border-bottom: 1px solid rgba(229,57,53,0.2);
  padding: 16px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transform: translateY(-110%);
  transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1);
}

.nav-mobile.open { transform: translateY(0); }

.nav-mobile-link {
  padding: 11px 14px;
  border-radius: 10px;
  color: rgba(255,255,255,0.7);
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  display: block;
  transition: background 0.2s;
}

.nav-mobile-link:hover {
  background: rgba(229,57,53,0.15);
  color: white;
}

@media (max-width: 767px) {
  .nav-links { display: none !important; }
  .nav-hamburger { display: flex !important; }
}

@media (min-width: 768px) {
  .nav-mobile { display: none !important; }
}

/* ── HERO ── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 80px 20px 40px;
  position: relative;
  overflow: hidden;
}

.hero-inner {
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

@media (max-width: 767px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 0;
    text-align: center;
  }
  .hero-right { order: -1; height: 260px; }
}

.hero-right {
  position: relative;
  height: 420px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-circle {
  position: absolute;
  width: 320px; height: 320px;
  border-radius: 50%;
  background: rgba(229,57,53,0.10);
  border: 1.5px solid rgba(229,57,53,0.20);
  backdrop-filter: blur(8px);
  box-shadow: 0 0 80px rgba(229,57,53,0.12);
}

@media (max-width: 767px) {
  .hero-circle { width: 220px; height: 220px; }
}

/* ── BADGE ── */
.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(229,57,53,0.18);
  border: 1px solid rgba(229,57,53,0.35);
  color: #FF8A80;
  backdrop-filter: blur(12px);
  margin-bottom: 12px;
}

/* ── SECTION WRAPPERS ── */
.sw {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

.sp { padding: 70px 0; }

@media (max-width: 640px) {
  .sp { padding: 48px 0; }
}

/* ── CARD HOVER ── */
.ch { transition: transform 0.3s cubic-bezier(0.34,1.56,0.64,1); }
.ch:hover, .ch:active { transform: translateY(-5px) scale(1.01); }

/* ── COUNTDOWN ── */
.cd-box {
  text-align: center;
  min-width: 64px;
  padding: 12px 8px;
  border-radius: 18px;
}

.cd-num {
  font-family: 'Fredoka One', sans-serif;
  font-size: clamp(1.8rem, 6vw, 2.8rem);
  line-height: 1;
  background: linear-gradient(135deg, #FFD600, #FF8A80, #42A5F5);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
}

.cd-label {
  font-size: 9px;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-weight: 700;
  margin-top: 4px;
}

/* ── CANDLE FLAME ── */
.flame {
  width: 11px; height: 18px;
  background: linear-gradient(to top, #FFD600, #FF6D00, #E53935, transparent);
  border-radius: 50% 50% 30% 30%;
  animation: fl 0.5s ease-in-out infinite alternate;
  filter: drop-shadow(0 0 8px rgba(255,109,0,0.9));
}

@keyframes fl {
  0%   { transform: scaleX(1) rotate(-2deg); }
  100% { transform: scaleX(0.82) scaleY(1.15) rotate(2deg); }
}

/* ── DIVIDER ── */
.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(229,57,53,0.4), transparent);
}

/* ── FADE UP ANIMATION ── */
.fu {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.34,1.56,0.64,1);
}

.fu.vis {
  opacity: 1;
  transform: translateY(0);
}

/* ── SCROLL PROGRESS BAR ── */
#sbar {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  background: linear-gradient(90deg, #E53935, #FFD600, #42A5F5);
  z-index: 9999;
  transition: width 0.1s;
  box-shadow: 0 0 8px rgba(229,57,53,0.8);
}

/* ── FORM INPUTS ── */
.wish-inp {
  background: rgba(255,255,255,0.07);
  border: 1.5px solid rgba(255,255,255,0.15);
  border-radius: 14px;
  padding: 13px 16px;
  color: white;
  font-family: 'Nunito', sans-serif;
  font-size: 14px;
  width: 100%;
  outline: none;
  transition: border-color 0.3s;
  backdrop-filter: blur(12px);
}

.wish-inp:focus {
  border-color: rgba(229,57,53,0.6);
  box-shadow: 0 0 0 3px rgba(229,57,53,0.12);
}

.wish-inp::placeholder { color: rgba(255,255,255,0.3); }

/* ── RSVP OPTIONS ── */
.rsvp-opt {
  padding: 14px 20px;
  border-radius: 14px;
  background: rgba(255,255,255,0.07);
  border: 1.5px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.7);
  font-weight: 700;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
  font-family: 'Nunito', sans-serif;
  text-align: center;
}

.rsvp-opt:hover {
  background: rgba(229,57,53,0.2);
  border-color: rgba(229,57,53,0.5);
  color: white;
}

.rsvp-opt.active {
  background: rgba(0,200,83,0.25);
  border-color: rgba(0,200,83,0.5);
  color: #A5D6A7;
}

.rsvp-opt.active-no {
  background: rgba(229,57,53,0.25);
  border-color: rgba(229,57,53,0.5);
  color: #FF8A80;
}

/* ── SCROLL HINT ── */
.sh { animation: shAn 2s ease-in-out infinite; }

@keyframes shAn {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50%       { transform: translateX(-50%) translateY(8px); }
}

/* ── WHATSAPP BUTTON ── */
.wa-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 14px;
  background: linear-gradient(135deg, #25D366, #128C7E);
  border: none;
  color: white;
  font-weight: 800;
  font-size: 14px;
  cursor: pointer;
  font-family: 'Nunito', sans-serif;
  box-shadow: 0 6px 24px rgba(37,211,102,0.4);
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
}

.wa-btn:hover {
  transform: scale(1.04);
  box-shadow: 0 10px 32px rgba(37,211,102,0.6);
}

/* ── MUSIC BUTTON PULSE ── */
@keyframes musicPulse {
  0%, 100% { box-shadow: 0 4px 24px rgba(0,0,0,0.5); }
  50%       { box-shadow: 0 0 0 6px rgba(229,57,53,0.2), 0 6px 28px rgba(229,57,53,0.35); }
}