/* ============================================================
   Alana's Epic 60th — shared stylesheet
   Mobile-first. Warm tropical sunset palette.
   ============================================================ */

:root {
  --coral: #e8604c;
  --coral-dark: #c94a38;
  --sand: #f6c86a;
  --sand-light: #f4e3c4;
  --aqua: #3fbfb2;
  --teal: #0e4d5c;
  --teal-dark: #093642;
  --ink: #23333a;
  --white: #ffffff;
  --font-display: "Fredoka", "Trebuchet MS", sans-serif;
  --font-body: "Nunito", "Segoe UI", Arial, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 18px;              /* large base size for older guests */
  line-height: 1.65;
  color: var(--ink);
  /* Sandy beach ground: warm gradient, fine grain, soft sand ripples */
  background-color: var(--sand-light);
  background-image:
    url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160' viewBox='0 0 160 160'><g fill='%23b8935c' fill-opacity='0.18'><circle cx='12' cy='20' r='1.7'/><circle cx='34' cy='8' r='1.2'/><circle cx='58' cy='26' r='2'/><circle cx='80' cy='14' r='1.4'/><circle cx='104' cy='30' r='1.6'/><circle cx='130' cy='10' r='1.3'/><circle cx='150' cy='24' r='1.8'/><circle cx='20' cy='52' r='1.5'/><circle cx='44' cy='66' r='2.1'/><circle cx='68' cy='48' r='1.2'/><circle cx='92' cy='60' r='1.7'/><circle cx='116' cy='52' r='1.4'/><circle cx='140' cy='68' r='1.9'/><circle cx='8' cy='86' r='1.6'/><circle cx='30' cy='102' r='1.3'/><circle cx='54' cy='92' r='1.8'/><circle cx='76' cy='110' r='1.5'/><circle cx='100' cy='88' r='2'/><circle cx='124' cy='104' r='1.2'/><circle cx='148' cy='94' r='1.6'/><circle cx='16' cy='124' r='1.9'/><circle cx='40' cy='140' r='1.4'/><circle cx='64' cy='130' r='1.7'/><circle cx='88' cy='148' r='1.3'/><circle cx='112' cy='132' r='1.8'/><circle cx='136' cy='146' r='1.5'/><circle cx='156' cy='120' r='1.3'/></g><g fill='%23fffaf0' fill-opacity='0.55'><circle cx='26' cy='34' r='1.3'/><circle cx='70' cy='18' r='1'/><circle cx='110' cy='44' r='1.4'/><circle cx='48' cy='78' r='1.1'/><circle cx='128' cy='80' r='1.5'/><circle cx='22' cy='110' r='1.2'/><circle cx='92' cy='120' r='1.3'/><circle cx='144' cy='36' r='1'/><circle cx='60' cy='152' r='1.2'/><circle cx='100' cy='66' r='1'/></g></svg>"),
    url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='420' height='140' viewBox='0 0 420 140'><g fill='none' stroke='%23b8935c' stroke-opacity='0.09' stroke-width='3' stroke-linecap='round'><path d='M0 32 q52 -14 105 0 t105 0 t105 0 t105 0'/><path d='M0 82 q52 -14 105 0 t105 0 t105 0 t105 0'/><path d='M0 126 q52 -14 105 0 t105 0 t105 0 t105 0'/></g></svg>"),
    linear-gradient(180deg, #fbf1dd 0%, #f4e3c4 45%, #eed7b0 100%);
  background-repeat: repeat, repeat, no-repeat;
  background-attachment: scroll;  /* never fixed: iOS Safari mishandles it and it judders while scrolling */
}

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

h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--teal);
  line-height: 1.2;
}

h1 { font-size: 2.1rem; }
h2 { font-size: 1.7rem; margin-bottom: 0.75rem; }
h3 { font-size: 1.25rem; margin-bottom: 0.5rem; }

p { margin-bottom: 1rem; }

a { color: var(--coral-dark); }
a:hover { color: var(--coral); }

.container {
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

section { padding: 2.5rem 0; }

/* ---------------- Buttons ---------------- */

.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 1.15rem;
  text-decoration: none;
  padding: 0.9rem 2.2rem;       /* generous tap target */
  border-radius: 999px;
  transition: transform 0.15s ease, background 0.15s ease;
}

.btn-primary {
  background: var(--coral);
  color: var(--white);
}
.btn-primary:hover { background: var(--coral-dark); color: var(--white); transform: translateY(-2px); }

.btn-secondary {
  background: var(--aqua);
  color: var(--teal-dark);
}
.btn-secondary:hover { background: #35a89d; color: var(--teal-dark); transform: translateY(-2px); }

/* ---------------- Header & navigation ---------------- */

.site-header {
  background: var(--teal);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.25rem;
  max-width: 960px;
  margin: 0 auto;
}

.brand {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--sand);
  text-decoration: none;
  white-space: nowrap;
}
.brand:hover { color: var(--white); }

.nav-toggle {
  background: none;
  border: 2px solid var(--sand);
  border-radius: 8px;
  color: var(--sand);
  font-size: 1.5rem;
  line-height: 1;
  padding: 0.4rem 0.7rem;       /* big tap target */
  cursor: pointer;
}

.site-nav {
  display: none;
  width: 100%;
}
.site-nav.open { display: block; }

.site-nav ul { list-style: none; }

.site-nav a {
  display: block;
  padding: 0.9rem 1.25rem;      /* big tap targets on mobile */
  color: var(--white);
  text-decoration: none;
  font-family: var(--font-display);
  font-size: 1.05rem;
  border-top: 1px solid rgba(255,255,255,0.12);
}
.site-nav a:hover { background: var(--teal-dark); color: var(--sand); }
.site-nav a.active { color: var(--sand); background: var(--teal-dark); }

@media (min-width: 820px) {
  .nav-toggle { display: none; }
  .site-header { display: flex; flex-direction: column; }
  .site-nav { display: block; }
  .site-nav ul {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
  }
  .site-nav a { border-top: none; padding: 0.75rem 1.1rem; }
}

/* ---------------- Wave divider ---------------- */

.wave {
  display: block;
  width: 100%;
  height: 48px;
}

/* ---------------- Hero (home page) ---------------- */

.hero {
  position: relative;
  min-height: 78vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--white);
  /* The cartoon ocean below is the hero. To use a photo instead, add
     url("images/your-photo.jpg") center / cover no-repeat as a background
     layer here and remove the hero--water class in index.html. */
  overflow: hidden;
  background: var(--teal);
  padding: 4rem 1.25rem;
}

.hero h1 {
  font-size: 2.6rem;
  color: var(--white);
  text-shadow: 0 2px 12px rgba(0,0,0,0.45);
  margin-bottom: 0.5rem;
}

.hero .hero-sub {
  font-size: 1.3rem;
  color: var(--sand);
  font-family: var(--font-display);
  margin-bottom: 1.5rem;
  text-shadow: 0 1px 8px rgba(0,0,0,0.5);
}

@media (min-width: 820px) {
  .hero h1 { font-size: 3.6rem; }
}

/* ---------------- Countdown ---------------- */

.countdown {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin: 1.5rem 0;
}

.countdown .unit {
  background: rgba(255,255,255,0.14);
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  min-width: 82px;
}

.countdown .num {
  display: block;
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--sand);
}

.countdown .label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ---------------- Cards ---------------- */

.card-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}
@media (min-width: 700px) {
  .card-grid { grid-template-columns: repeat(3, 1fr); }
}

.card {
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(14,77,92,0.12);
  display: flex;
  flex-direction: column;
}

.card img { height: 200px; object-fit: cover; width: 100%; }

/* photo with a sticker badge layered over it */
.card-media { position: relative; }

.sticker {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  transform: rotate(-5deg);
  background: rgba(232, 96, 76, 0.72);   /* coral, see-through so the hotel shows */
  -webkit-backdrop-filter: blur(2px);
          backdrop-filter: blur(2px);
  color: var(--white);
  font-family: var(--font-display);
  font-size: 0.95rem;
  line-height: 1.15;
  text-align: center;
  padding: 0.45rem 0.85rem;
  border: 2px solid rgba(255, 255, 255, 0.9);
  border-radius: 12px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.28);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
}

.card .card-body { padding: 1.25rem; flex: 1; display: flex; flex-direction: column; }
.card .card-body .btn { margin-top: auto; align-self: flex-start; }

.tier-tag {
  display: inline-block;
  background: var(--sand);
  color: var(--teal-dark);
  font-family: var(--font-display);
  font-size: 0.85rem;
  border-radius: 999px;
  padding: 0.15rem 0.9rem;
  margin-bottom: 0.5rem;
}

/* ---------------- Timeline (schedule) ---------------- */

.timeline {
  list-style: none;
  position: relative;
  padding-left: 1.75rem;
  margin: 1.5rem 0;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 0.5rem;
  top: 0;
  bottom: 0;
  width: 4px;
  border-radius: 2px;
  background: var(--aqua);
}

.timeline li {
  position: relative;
  background: var(--white);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  margin-bottom: 1.25rem;
  box-shadow: 0 3px 10px rgba(14,77,92,0.1);
}

.timeline li::before {
  content: "";
  position: absolute;
  left: -1.62rem;
  top: 1.35rem;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--coral);
  border: 3px solid var(--sand-light);
}

.timeline .time {
  font-family: var(--font-display);
  color: var(--coral-dark);
}

.timeline .dress {
  font-size: 0.95rem;
  color: var(--teal);
  font-style: italic;
}

.day-heading {
  margin-top: 2rem;
  color: var(--coral-dark);
}

/* ---------------- Info sections (travel, hints) ---------------- */

.info-block {
  background: var(--white);
  border-radius: 16px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 3px 10px rgba(14,77,92,0.1);
}

.info-block h3 { color: var(--coral-dark); }

.bullets {
  list-style: disc;
  padding-left: 1.5rem;        /* the global reset zeroes this, so put it back */
  margin-bottom: 1rem;
}

.bullets li { margin-bottom: 0.5rem; }
.bullets li::marker { color: var(--coral); }

.note {
  background: var(--sand);
  border-radius: 12px;
  padding: 1rem 1.25rem;
  font-size: 0.95rem;
  color: var(--teal-dark);
}

/* ---------------- Guestbook (messages for Alana) ---------------- */

.guestbook-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}
@media (min-width: 700px) {
  .guestbook-grid { grid-template-columns: repeat(2, 1fr); }
}

.guestbook-card {
  background: var(--white);
  border-radius: 16px;
  padding: 1.25rem 1.5rem;
  box-shadow: 0 3px 10px rgba(14,77,92,0.1);
  border-top: 5px solid var(--aqua);
}

.guestbook-card .who {
  font-family: var(--font-display);
  color: var(--coral-dark);
  margin-top: 0.5rem;
}

/* ---------------- Gallery ---------------- */

.gallery-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(2, 1fr);
}
@media (min-width: 700px) {
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
}

.gallery-grid button {
  border: none;
  padding: 0;
  cursor: pointer;
  border-radius: 12px;
  overflow: hidden;
  background: var(--teal);
  aspect-ratio: 1 / 1;
}

.gallery-grid img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.2s ease;
}
.gallery-grid button:hover img { transform: scale(1.04); }

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(9,54,66,0.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 1rem;
}
.lightbox.open { display: flex; }

.lightbox img {
  max-width: 92vw;
  max-height: 82vh;
  border-radius: 8px;
}

.lightbox .lb-close,
.lightbox .lb-prev,
.lightbox .lb-next {
  position: absolute;
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.4);
  color: var(--white);
  font-size: 1.6rem;
  line-height: 1;
  border-radius: 50%;
  width: 56px;                 /* big tap targets */
  height: 56px;
  cursor: pointer;
}
.lightbox .lb-close { top: 1rem; right: 1rem; }
.lightbox .lb-prev { left: 0.75rem; top: 50%; transform: translateY(-50%); }
.lightbox .lb-next { right: 0.75rem; top: 50%; transform: translateY(-50%); }

/* ---------------- RSVP embed ---------------- */

.form-wrap {
  background: var(--white);
  border-radius: 16px;
  padding: 1rem;
  box-shadow: 0 3px 10px rgba(14,77,92,0.1);
}
.form-wrap iframe { width: 100%; border: none; display: block; }

/* ---------------- Footer ---------------- */

.site-footer {
  background: var(--teal-dark);
  color: var(--white);
  text-align: center;
  padding: 2.5rem 1.25rem 2rem;
  margin-top: 2rem;
}

.site-footer .btn { margin-bottom: 1.25rem; }

.site-footer .fine {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  margin-top: 1rem;
  margin-bottom: 0;
}

/* ---------------- Page intro banner ---------------- */

.page-banner {
  background: var(--teal);
  color: var(--white);
  text-align: center;
  padding: 2.75rem 1.25rem 2.25rem;
}
.page-banner h1 { color: var(--sand); }
.page-banner p { max-width: 620px; margin: 0.5rem auto 0; }

/* ============================================================
   Cartoon water hero
   .hero--water paints a stylised ocean behind the countdown:
   a sea gradient, drifting surface ripples, and two layered
   wave bands rolling along the bottom.
   Only remove this class if you add a photo background to .hero instead.
   ============================================================ */

.hero--water {
  padding-bottom: 8rem;          /* keeps the RSVP button clear of the waves */
  background:
    radial-gradient(circle at 76% 12%, rgba(255,255,255,0.20), rgba(255,255,255,0) 46%),
    linear-gradient(180deg, #1e97ac 0%, #16809a 35%, #12707f 100%);
}

/* hero text sits above the water layers */
.hero > div { position: relative; z-index: 2; }

/* drifting surface ripples, faded top and bottom */
.hero--water::before {
  content: "";
  position: absolute;
  inset: 0;
  bottom: 150px;
  pointer-events: none;
  background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='260' height='170' viewBox='0 0 260 170'><g fill='none' stroke='%23eafffd' stroke-opacity='0.22' stroke-width='4' stroke-linecap='round'><path d='M18 26 q14 -12 28 0 t28 0'/><path d='M110 8 q14 -12 28 0 t28 0'/><path d='M148 50 q14 -12 28 0 t28 0'/><path d='M68 94 q14 -12 28 0 t28 0'/><path d='M184 126 q14 -12 28 0 t28 0'/><path d='M10 148 q14 -12 28 0 t28 0'/></g></svg>");
  background-repeat: repeat;
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0) 6%, #000 32%, #000 74%, rgba(0,0,0,0) 100%);
          mask-image: linear-gradient(to bottom, rgba(0,0,0,0) 6%, #000 32%, #000 74%, rgba(0,0,0,0) 100%);
  animation: rippleDrift 28s linear infinite;
}

/* two cartoon wave bands along the bottom; the front band is the
   same teal as the wave divider below, so the seam stays invisible */
.hero--water::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 160px;
  pointer-events: none;
  background-image:
    url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='600' height='200' viewBox='0 0 600 200' preserveAspectRatio='none'><path d='M0,98 q75,-30 150,0 t150,0 t150,0 t150,0 V200 H0 Z' fill='%230e4d5c'/><path d='M0,98 q75,-30 150,0 t150,0 t150,0 t150,0' fill='none' stroke='%235fd0c8' stroke-opacity='0.30' stroke-width='5'/></svg>"),
    url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' width='600' height='200' viewBox='0 0 600 200' preserveAspectRatio='none'><path d='M0,70 q75,-32 150,0 t150,0 t150,0 t150,0 V200 H0 Z' fill='%230d6377'/><path d='M0,70 q75,-32 150,0 t150,0 t150,0 t150,0' fill='none' stroke='%2386e8e0' stroke-opacity='0.22' stroke-width='5'/></svg>");
  background-repeat: repeat-x, repeat-x;
  background-position: 0 bottom, 0 bottom;
  background-size: 620px 100%, 860px 100%;
  animation: waveDrift 22s linear infinite;
}

@keyframes rippleDrift {
  from { background-position: 0 0; }
  to   { background-position: 260px 0; }
}

@keyframes waveDrift {
  from { background-position: 0 bottom, 0 bottom; }
  to   { background-position: 620px bottom, 860px bottom; }
}

@media (prefers-reduced-motion: reduce) {
  .hero--water::before,
  .hero--water::after { animation: none; }
}
