/* =============================================
   TOKENS
============================================= */
:root {
  --jungle-deep: #3a4a2b;
  --jungle-green: #5c6b3f;
  --leaf-green: #7fa563;
  --wood-brown: #8a5e3c;
  --wood-dark: #5a3b23;
  --cream: #fbf3e2;
  --cream-soft: #f3ecd9;
  --sand: #e4d2a8;
  --sun-yellow: #f4c542;
  --mango-orange: #e8934a;
  --clay: #b5713a;
  --ink: #4a3826;

  --font-display: "Fraunces", Georgia, serif;
  --font-script: "Caveat", cursive;
  --font-body: "Nunito", system-ui, sans-serif;
  --font-agbalumo: "Agbalumo", cursive;

  --radius-lg: 28px;
  --radius-md: 18px;
  --shadow-soft: 0 10px 30px rgba(58, 38, 15, 0.15);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  position: relative;
  z-index: 0;
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(58, 74, 43, 0.55) 0%, rgba(58, 74, 43, 0.3) 30%, rgba(58, 74, 43, 0.3) 70%, rgba(58, 74, 43, 0.55) 100%),
    url("../assets/BACKGROUND HERO.jpeg") center/cover no-repeat;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

img { max-width: 100%; display: block; }

button { font-family: inherit; cursor: pointer; }

a { text-decoration: none; color: inherit; }

:focus-visible {
  outline: 3px solid var(--mango-orange);
  outline-offset: 3px;
}

/* =============================================
   BACKGROUND DECOR
============================================= */
.bg-decor {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 1;
}

.bg-decor span {
  position: absolute;
  font-size: 2rem;
  opacity: 0.55;
}

.leaf--1 { top: 8%; left: 4%; animation: sway 7s ease-in-out infinite; }
.leaf--2 { top: 60%; right: 6%; font-size: 2.6rem; animation: sway 9s ease-in-out infinite 1s; }
.leaf--3 { bottom: 10%; left: 10%; animation: sway 8s ease-in-out infinite 2s; }

.cloud--1 { top: 5%; right: 12%; font-size: 2.4rem; opacity: 0.5; animation: drift 40s linear infinite; }
.cloud--2 { top: 30%; left: -10%; font-size: 3rem; opacity: 0.4; animation: drift 55s linear infinite 5s; }

.butterfly--1 { top: 22%; left: 15%; animation: flutter 6s ease-in-out infinite; }
.butterfly--2 { top: 70%; right: 18%; animation: flutter 7s ease-in-out infinite 1.5s; }

@keyframes sway {
  0%, 100% { transform: rotate(-6deg) translateY(0); }
  50% { transform: rotate(6deg) translateY(-10px); }
}

@keyframes drift {
  from { transform: translateX(-10vw); }
  to { transform: translateX(110vw); }
}

@keyframes flutter {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  25% { transform: translate(15px, -12px) rotate(10deg); }
  50% { transform: translate(0, -20px) rotate(-8deg); }
  75% { transform: translate(-15px, -8px) rotate(6deg); }
}

/* =============================================
   MUSIC BUTTON
============================================= */
.music-btn {
  position: fixed;
  bottom: 90px;
  right: 18px;
  z-index: 40;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: none;
  background: var(--mango-orange);
  color: var(--cream);
  font-size: 1.4rem;
  box-shadow: var(--shadow-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease;
}

.music-btn:active { transform: scale(0.92); }

.music-btn.is-playing .music-btn__icon {
  animation: pulse 1.1s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.2); }
}

/* =============================================
   NAV
============================================= */
.site-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 30;
  display: flex;
  justify-content: space-around;
  background: rgba(251, 243, 226, 0.92);
  backdrop-filter: blur(8px);
  border-top: 2px solid var(--cream-soft);
  padding: 8px 4px calc(env(safe-area-inset-bottom, 0px) + 6px);
  opacity: 0;
  transform: translateY(100%);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.site-nav.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 0.65rem;
  color: var(--jungle-deep);
  font-weight: 600;
  padding: 4px 6px;
  border-radius: 12px;
}

.nav-item span:first-child { font-size: 1.2rem; }

.nav-item.is-active {
  background: var(--cream-soft);
  color: var(--wood-dark);
}

@media (min-width: 860px) {
  .site-nav {
    top: 0;
    bottom: auto;
    left: 50%;
    right: auto;
    transform: translate(-50%, -120%);
    border-top: none;
    border-radius: 0 0 20px 20px;
    padding: 10px 28px;
    gap: 28px;
    box-shadow: var(--shadow-soft);
  }
  .site-nav.is-visible { transform: translate(-50%, 0); }
  .nav-item { flex-direction: row; font-size: 0.8rem; gap: 6px; }
}

/* =============================================
   BUTTONS
============================================= */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 600;
  border: none;
  border-radius: 999px;
  padding: 14px 28px;
  font-size: 1rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn:active { transform: scale(0.96); }

.btn--primary {
  background: linear-gradient(135deg, var(--mango-orange), var(--sun-yellow));
  color: var(--wood-dark);
  box-shadow: 0 8px 22px rgba(232, 147, 74, 0.45);
}

.btn--large { padding: 16px 36px; font-size: 1.1rem; }

.btn--outline {
  margin-top: 14px;
  background: transparent;
  border: 2px solid var(--jungle-green);
  color: var(--jungle-deep);
  padding: 10px 22px;
  font-size: 0.9rem;
}

/* =============================================
   COVER
============================================= */
.cover {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 15% 22%, rgba(244,197,66,0.26), transparent 13%),
    radial-gradient(circle at 68% 14%, rgba(244,197,66,0.2), transparent 11%),
    radial-gradient(circle at 42% 58%, rgba(244,197,66,0.14), transparent 15%),
    radial-gradient(circle at 82% 10%, rgba(244, 197, 66, 0.28), transparent 40%),
    radial-gradient(ellipse at 0% 0%, rgba(58,74,43,0.55), transparent 38%),
    radial-gradient(ellipse at 100% 0%, rgba(58,74,43,0.55), transparent 38%),
    linear-gradient(180deg, #f6efdd 0%, var(--cream-soft) 45%, var(--sand) 85%, #c9ad76 100%);
  text-align: center;
  padding: 56px 20px 40px;
  z-index: 2;
}

.cover__sun {
  position: absolute;
  top: 6%;
  right: 8%;
  width: 90px;
  height: 90px;
  opacity: 0.85;
  filter: blur(0.3px);
}

 .cover__ground { 
  position: absolute; 
  bottom: 0; left: 0; right: 0; 
  height: 70px; 
  background: repeating-linear-gradient(75deg, transparent 0 8px, rgba(92,107,63,0.35) 8px 11px), 
  linear-gradient(180deg, transparent, rgba(58,74,43,0.45)); 
  clip-path: polygon(0% 100%,0% 55%,4% 70%,8% 40%,12% 65%,16% 45%,20% 72%,24% 38%,28% 68%,32% 48%,36% 75%,40% 42%,44% 66%,48% 50%,52% 73%,56% 40%,60% 68%,64% 46%,68% 72%,72% 38%,76% 66%,80% 48%,84% 74%,88% 42%,92% 68%,96% 50%,100% 60%,100% 100%); }

.cover__branch {
  position: absolute;
  width: 150px;
  height: auto;
  opacity: 0.9;
}
.cover__branch--left { top: -6px; left: -18px; }
.cover__branch--right { top: -6px; right: -18px; transform: scaleX(-1); }

.cover__critter { position: absolute; width: 60px; height: auto; }
.cover__critter--monkey { top: 78px; left: 22px; transform: rotate(-6deg); }
.cover__critter--toucan { top: 92px; right: 18px; transform: rotate(6deg); }

.cover__content {
  position: relative;
  max-width: 480px;
  animation: fadeZoomIn 1s ease both;
}

@keyframes fadeZoomIn {
  from { opacity: 0; transform: scale(0.92) translateY(16px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.cover__eyebrow {
  font-family: var(--font-agbalumo);
  font-weight: 600;
  color: var(--jungle-green);
  letter-spacing: 0.06em;
  font-size: 3.0rem;
  margin: 0 0 18px;
}

.cover__envelope {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 0;
  margin: 0 auto 22px;
}

.cover__photo {
  height: 480px;
  width: auto;
  max-width: 340px;
  object-fit: contain;
  filter: drop-shadow(0 12px 14px rgba(58, 38, 15, 0.28));
}



.cover__name {
  font-family: var(--font-script);
  font-weight: 700;
  font-size: clamp(2.6rem, 10vw, 4rem);
  color: var(--clay);
  margin: 0 0 12px;
  line-height: 1;
}

.cover__tagline {
  font-size: 1.05rem;
  color: var(--wood-brown);
  margin-bottom: 30px;
}

/* =============================================
   MAIN CONTENT + REVEAL
============================================= */
.main-content {
  position: relative;
  z-index: 2;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition: opacity 0.6s ease;
}

.main-content.is-open {
  opacity: 1;
  max-height: none;
  overflow: visible;
}

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

main section {
  padding: 70px 24px;
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

.section-kicker {
  font-family: var(--font-display);
  color: var(--jungle-green);
  font-size: 2rem;
  margin-bottom: 14px;
  margin-top: -20px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 5vw, 2.1rem);
  color: var(--jungle-deep);
  margin-bottom: 16px;
}

.section-title--light { color: var(--cream); }

.section-desc {
  color: var(--wood-brown);
  max-width: 46ch;
  margin: 0 auto 32px;
  line-height: 1.6;
}

#hero .section-kicker,
#hero .hero__story,
#details .section-title,
#gallery .section-title {
  display: inline-block;
  background: rgba(251, 243, 226, 0.85);
  border-radius: var(--radius-md);
  padding: 10px 18px;
}

/* =============================================
   HERO
============================================= */
.hero__story {
  color: var(--wood-brown);
  max-width: 48ch;
  margin: 0 auto 8px;
  line-height: 1.7;
  font-size: 1.05rem;
}

#hero {
  position: relative;
  padding: 60px 24px 20px;
}

.hero__inner {
  max-width: 720px;
  margin: 0 auto;
}

.hero__family {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 0;
  margin: 10px 0 -10px;
}

.hero__photo {
  width: 100%;
  max-width: 380px;
  height: auto;
}

.hero__birthday-name {
  position: relative;
  z-index: 2;
  background: var(--cream-soft);
  border-radius: var(--radius-lg);
  padding: 26px 20px;
  box-shadow: var(--shadow-soft);
}

.hero__name {
  display: block;
  font-family: var(--font-script);
  font-weight: 700;
  font-size: clamp(2.2rem, 8vw, 3rem);
  color: var(--clay);
}

.hero__turning {
  display: block;
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--jungle-green);
  margin-top: 6px;
}


/* =============================================
   EXPLORER (PHOTO)
============================================= */
  .explorer { background: rgba(243, 236, 217, 0.85); border-radius: var(--radius-lg); max-width: 760px; }

.explorer__frame {
  position: relative;
  width: min(320px, 80vw);
  margin: 0 auto;
  border: 10px solid var(--wood-brown);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.explorer__photo { width: 100%; height: auto; display: block; }

.explorer__frame-badge {
  position: absolute;
  bottom: -14px;
  right: -14px;
  background: var(--leaf-green);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  box-shadow: var(--shadow-soft);
}

/* =============================================
   DETAILS
============================================= */
.details__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.detail-card {
  background: var(--cream);
  border: 2px solid var(--cream-soft);
  border-radius: var(--radius-md);
  padding: 22px 14px;
  box-shadow: var(--shadow-soft);
}

.detail-card--wide { grid-column: 1 / -1; }
.detail-card--center {
  grid-column: 1 / -1;
  max-width: calc((100% - 16px) / 2);
  margin: 0 auto;
}

.detail-card__icon { font-size: 1.8rem; margin-bottom: 8px; }

.detail-card__label {
  font-family: var(--font-display);
  text-transform: none;
  color: var(--jungle-green);
  font-size: 0.85rem;
  margin: 0 0 4px;
}

.detail-card__value {
  font-weight: 700;
  color: var(--wood-dark);
  margin: 0;
  font-size: 1.05rem;
}

.detail-card__sub {
  color: var(--wood-brown);
  margin: 2px 0 0;
  font-size: 0.9rem;
}

/* =============================================
   COUNTDOWN
============================================= */
.countdown {
  background: linear-gradient(160deg, rgba(58, 74, 43, 0.85), rgba(92, 107, 63, 0.85));
  border-radius: var(--radius-lg);
  max-width: 760px;
  color: var(--cream);
}

.countdown__timer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.countdown__unit {
  background: rgba(251, 243, 226, 0.12);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  min-width: 72px;
}

.countdown__number {
  display: block;
  font-family: var(--font-display);
  font-size: 1.9rem;
  color: var(--sun-yellow);
}

.countdown__label {
  display: block;
  font-size: 0.75rem;
  color: var(--cream-soft);
  margin-top: 2px;
}

.countdown__sep { font-size: 1.5rem; color: var(--cream-soft); opacity: 0.5; }

.countdown__today {
  margin-top: 20px;
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--sun-yellow);
}

/* =============================================
   WISH
============================================= */
.wish {
  background: rgba(251, 243, 226, 0.85);
  border-radius: var(--radius-lg);
  max-width: 640px;
  margin: 0 auto;
  padding: 40px 24px;
}

.wish__quote {
  font-style: normal;
  color: var(--wood-brown);
  font-size: 1.1rem;
  line-height: 1.8;
  max-width: 52ch;
  margin: 0 auto 22px;
}

.wish__signoff {
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--jungle-deep);
}

/* =============================================
   GALLERY
============================================= */
.gallery__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}

@media (min-width: 720px) {
  .gallery__grid { grid-template-columns: repeat(4, 1fr); }
}

.gallery__item {
  border: none;
  padding: 0;
  background: none;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  aspect-ratio: 1 / 1;
}

.gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.gallery__item:nth-child(7) {
  grid-column: 1 / -1;
  aspect-ratio: auto;
}

.gallery__item:nth-child(7) img {
  height: auto;
  object-fit: contain;
}

.gallery__item:hover img,
.gallery__item:focus-visible img { transform: scale(1.08); }

/* =============================================
   LIGHTBOX
============================================= */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(35, 71, 46, 0.92);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.lightbox[hidden] { display: none; }

.lightbox__image {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: var(--radius-md);
}

.lightbox__close {
  position: absolute;
  top: 18px;
  right: 18px;
  background: var(--cream);
  border: none;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  font-size: 1.1rem;
}

/* =============================================
   RSVP
============================================= */
  .rsvp {
    background: linear-gradient(160deg, rgba(232, 147, 74, 0.85), rgba(244, 197, 66, 0.85));
    border-radius: var(--radius-lg);
    max-width: 760px;
    padding: 20px 24px;
  }

.rsvp__desc {
  color: var(--wood-dark);
  margin-bottom: 26px;
  font-size: 1.05rem;
}

.rsvp .btn--primary {
  background: var(--jungle-deep);
  color: var(--cream);
  box-shadow: 0 8px 22px rgba(35, 71, 46, 0.35);
}

/* =============================================
   FOOTER
============================================= */
  .site-footer {
    text-align: center;
    padding: 30px 24px 120px;
    background: rgba(58, 74, 43, 0.85);
    color: var(--cream-soft);
  }

  .site-footer .btn--outline {
  margin-top: 18px;
  border-color: var(--cream-soft);
  color: var(--cream-soft);
}

.site-footer__decor { font-size: 1.6rem; margin-bottom: 14px; letter-spacing: 6px; }

.site-footer__thanks {
  font-family: var(--font-display);
  font-size: 1.2rem;
  color: var(--cream);
  margin-bottom: 14px;
}

.site-footer__love { line-height: 1.7; margin-bottom: 14px; }

.site-footer__copy { font-size: 0.8rem; opacity: 0.7; }

@media (min-width: 860px) {
  .site-footer { padding: 60px 24px; }
}

/* =============================================
   EASTER EGG
============================================= */
.monkey-egg {
  position: fixed;
  bottom: 90px;
  left: 18px;
  z-index: 40;
  background: var(--cream);
  border: 2px solid var(--cream-soft);
  border-radius: 50%;
  width: 48px;
  height: 48px;
  font-size: 1.4rem;
  box-shadow: var(--shadow-soft);
}

.easter-toast {
  position: fixed;
  bottom: 150px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--wood-dark);
  color: var(--cream);
  padding: 12px 20px;
  border-radius: 999px;
  font-size: 0.9rem;
  z-index: 50;
  box-shadow: var(--shadow-soft);
  animation: toastPop 0.3s ease;
}

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

@media (min-width: 860px) {
  .monkey-egg { bottom: auto; top: 100px; left: 18px; }
}
