@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,700;1,400&family=Lato:wght@300;400;700&display=swap');

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

:root {
  --crimson: #8B1A1A;
  --crimson-dark: #6a1212;
  --crimson-light: #a82020;
  --gold: #C9973A;
  --gold-light: #ddb05a;
  --cream: #FAF7F0;
  --cream-dark: #f0ebe0;
  --dark: #1a1a1a;
  --muted: #5a5a5a;
  --border: #ddd5c8;
  --card: #ffffff;
  --shadow: 0 2px 16px rgba(0,0,0,0.08);
}

html { scroll-behavior: smooth; }
body { font-family: 'Lato', sans-serif; background: var(--cream); color: var(--dark); min-height: 100vh; }

/* ── NAV ── */
nav {
  background: var(--crimson);
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 12px rgba(0,0,0,0.3);
}
.nav-logo { color: var(--gold); font-family: 'Playfair Display', serif; font-size: 1.15rem; font-weight: 700; letter-spacing: 0.04em; text-decoration: none; display: flex; align-items: center; gap: 12px; }
.nav-logo-img { height: 48px; width: auto; display: block; filter: drop-shadow(0 1px 3px rgba(0,0,0,0.4)); }
.nav-logo-text { color: var(--gold); }
.nav-links { display: flex; gap: 0; }
.nav-links a {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-size: 0.82rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  padding: 0 1.25rem;
  height: 60px;
  display: flex;
  align-items: center;
  transition: background 0.2s, color 0.2s;
  border-bottom: 3px solid transparent;
}
.nav-links a:hover, .nav-links a.active { color: #fff; background: rgba(255,255,255,0.08); border-bottom-color: var(--gold); }
.nav-hamburger { display: none; background: none; border: none; cursor: pointer; flex-direction: column; gap: 5px; padding: 8px; }
.nav-hamburger span { display: block; width: 22px; height: 2px; background: #fff; border-radius: 2px; transition: all 0.3s; }

/* ── PAGES ── */
.page { display: none; }
.page.active { display: block; }

/* ── HERO ── */
.hero {
  min-height: 560px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 5rem 2rem 4rem;
  position: relative;
  background:
    linear-gradient(to bottom, rgba(0,0,0,0.3) 0%, rgba(100,20,20,0.3) 50%, rgba(0,0,0,0.75) 100%),
    url('/images/redcampus.jpeg') center 25%/cover no-repeat;
}
.hero-eyebrow {
  background: var(--gold);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 7px 22px;
  border-radius: 2px;
  margin-bottom: 1.5rem;
  display: inline-block;
}
.hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  color: #fff;
  line-height: 1.12;
  text-shadow: 0 3px 24px rgba(0,0,0,0.55);
  margin-bottom: 1rem;
}
.hero h1 em { color: var(--gold); font-style: normal; }
.hero-sub { color: rgba(255,255,255,0.82); font-size: 1.15rem; font-weight: 300; margin-bottom: 2.5rem; letter-spacing: 0.04em; }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }
.btn-primary {
  background: var(--gold);
  color: #fff;
  border: none;
  padding: 14px 36px;
  font-family: 'Lato', sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  border-radius: 3px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.btn-primary:hover { background: #b8832c; transform: translateY(-1px); }
.btn-outline {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255,255,255,0.6);
  padding: 13px 32px;
  font-family: 'Lato', sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s;
  border-radius: 3px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.btn-outline:hover { background: rgba(255,255,255,0.12); border-color: #fff; }

/* ── COUNTDOWN ── */
.countdown-strip {
  background: var(--dark);
  color: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0;
  padding: 0;
  overflow: hidden;
}
.countdown-unit {
  text-align: center;
  padding: 1.25rem 2rem;
  border-right: 1px solid rgba(255,255,255,0.1);
}
.countdown-unit:last-child { border-right: none; }
.countdown-num { font-family: 'Playfair Display', serif; font-size: 2.4rem; color: var(--gold); display: block; line-height: 1; }
.countdown-label { font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; opacity: 0.55; margin-top: 4px; display: block; }
#countdown-message { padding: 1.25rem 2rem; font-family: 'Playfair Display', serif; font-size: 1.6rem; color: var(--gold); text-align: center; width: 100%; }

/* ── CONTENT WRAPPER ── */
.content-wrap { max-width: 980px; margin: 0 auto; padding: 3.5rem 1.5rem; }
.content-wrap-wide { max-width: 1100px; margin: 0 auto; padding: 3.5rem 1.5rem; }

/* ── SECTION HEADER ── */
.section-head { margin-bottom: 2.5rem; }
.section-head h2 { font-family: 'Playfair Display', serif; font-size: 2rem; color: var(--crimson); margin-bottom: 0.4rem; }
.section-rule { width: 56px; height: 3px; background: var(--gold); margin-bottom: 0.75rem; }
.section-head p { color: var(--muted); font-size: 0.95rem; line-height: 1.6; }

/* ── HOME ABOUT CARDS ── */
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-top: 2.5rem; }
.about-card { background: var(--card); border: 1px solid var(--border); border-radius: 8px; padding: 2rem; }
.about-card h3 { font-family: 'Playfair Display', serif; font-size: 1.25rem; color: var(--crimson); margin-bottom: 0.75rem; }
.about-card p { font-size: 0.93rem; color: #444; line-height: 1.75; }
.rocket-banner { background: var(--crimson); color: #fff; text-align: center; padding: 2rem; margin: 2.5rem 0 0; border-radius: 8px; }
.rocket-banner h3 { font-family: 'Playfair Display', serif; font-size: 1.5rem; margin-bottom: 0.5rem; }
.rocket-banner p { opacity: 0.82; font-size: 0.92rem; }

/* ── EVENTS ── */
.events-list { display: flex; flex-direction: column; gap: 1.25rem; }
.event-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
  display: grid;
  grid-template-columns: 80px 1fr auto;
  gap: 1.5rem;
  align-items: start;
  transition: box-shadow 0.2s;
}
.event-card:hover { box-shadow: var(--shadow); }
.event-datebox {
  background: var(--crimson);
  color: #fff;
  border-radius: 6px;
  text-align: center;
  padding: 12px 8px;
  flex-shrink: 0;
}
.event-datebox .ev-month { font-size: 0.68rem; letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.8; }
.event-datebox .ev-day { font-family: 'Playfair Display', serif; font-size: 2.2rem; line-height: 1; }
.event-datebox .ev-year { font-size: 0.68rem; opacity: 0.65; }
.event-body h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 5px; }
.event-body .event-meta { font-size: 0.84rem; color: var(--muted); margin-bottom: 8px; }
.event-body p { font-size: 0.91rem; color: #444; line-height: 1.6; }
.event-actions { display: flex; flex-direction: column; gap: 6px; }
.btn-edit { background: none; border: 1px solid var(--border); border-radius: 5px; padding: 7px 16px; font-size: 0.78rem; cursor: pointer; color: var(--muted); transition: all 0.2s; }
.btn-edit:hover { border-color: var(--crimson); color: var(--crimson); }
.btn-delete { background: none; border: 1px solid var(--border); border-radius: 5px; padding: 7px 16px; font-size: 0.78rem; cursor: pointer; color: #aaa; transition: all 0.2s; }
.btn-delete:hover { border-color: #c0392b; color: #c0392b; }
.btn-add-event { margin-top: 1.5rem; }

/* ── RSVP ── */
.rsvp-wrap { max-width: 680px; margin: 0 auto; }
.form-card { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 2.5rem; box-shadow: var(--shadow); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-bottom: 1rem; }
.form-group { display: flex; flex-direction: column; margin-bottom: 1rem; }
.form-group label { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.07em; color: var(--muted); margin-bottom: 5px; text-transform: uppercase; }
.form-group input, .form-group select, .form-group textarea {
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 11px 14px;
  font-family: 'Lato', sans-serif;
  font-size: 0.93rem;
  color: var(--dark);
  background: #fff;
  transition: border-color 0.2s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; border-color: var(--crimson); }
.form-group textarea { height: 90px; resize: vertical; }
.rsvp-list { margin-top: 3rem; }
.rsvp-item { background: var(--card); border: 1px solid var(--border); border-radius: 7px; padding: 1rem 1.25rem; display: flex; align-items: center; gap: 1rem; margin-bottom: 0.75rem; }
.rsvp-avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--crimson); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1rem; flex-shrink: 0; font-family: 'Playfair Display', serif; }
.rsvp-info strong { display: block; font-size: 0.95rem; }
.rsvp-info span { font-size: 0.82rem; color: var(--muted); }
.rsvp-badge { margin-left: auto; background: #e8f5e9; color: #2e7d32; font-size: 0.75rem; font-weight: 700; padding: 4px 12px; border-radius: 20px; white-space: nowrap; }
.rsvp-badge.maybe { background: #fff8e1; color: #f57f17; }

/* ── UPDATES ── */
.updates-layout { display: grid; grid-template-columns: 1fr 340px; gap: 2rem; align-items: start; }
.update-form-card { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 2rem; box-shadow: var(--shadow); position: sticky; top: 80px; }
.update-form-card h3 { font-family: 'Playfair Display', serif; font-size: 1.25rem; color: var(--crimson); margin-bottom: 1.25rem; }
.updates-feed { display: flex; flex-direction: column; gap: 1.25rem; }
.update-card { background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 1.5rem; transition: box-shadow 0.2s; }
.update-card:hover { box-shadow: var(--shadow); }
.update-header { display: flex; align-items: center; gap: 12px; margin-bottom: 1rem; }
.update-avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--crimson); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1.05rem; flex-shrink: 0; font-family: 'Playfair Display', serif; }
.update-meta strong { display: block; font-size: 0.97rem; }
.update-meta span { font-size: 0.8rem; color: var(--muted); }
.update-card p { font-size: 0.93rem; line-height: 1.7; color: #333; }

/* ── PHOTOS ── */
.upload-zone {
  border: 2px dashed var(--border);
  border-radius: 10px;
  padding: 3rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  margin-bottom: 2rem;
  background: #fff;
}
.upload-zone:hover { border-color: var(--crimson); background: rgba(139,26,26,0.02); }
.upload-icon { font-size: 2.5rem; margin-bottom: 0.75rem; display: block; }
.upload-zone p { color: var(--muted); font-size: 0.92rem; }
.upload-zone strong { color: var(--crimson); }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.photo-card { background: #fff; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; transition: box-shadow 0.2s, transform 0.2s; }
.photo-card:hover { box-shadow: 0 6px 24px rgba(0,0,0,0.12); transform: translateY(-2px); }
.photo-card img { width: 100%; height: 170px; object-fit: cover; display: block; }
.photo-caption { padding: 10px 12px; }
.photo-caption strong { display: block; font-size: 0.88rem; color: var(--dark); margin-bottom: 2px; }
.photo-caption span { font-size: 0.78rem; color: var(--muted); }

/* ── MODAL ── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.modal-overlay.open { display: flex; }
.modal-box {
  background: #fff;
  border-radius: 10px;
  padding: 2rem;
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
}
.modal-box h3 { font-family: 'Playfair Display', serif; font-size: 1.5rem; color: var(--crimson); margin-bottom: 1.5rem; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 1rem; }
.btn-cancel-sm { background: none; border: 1px solid var(--border); border-radius: 5px; padding: 10px 20px; font-size: 0.85rem; cursor: pointer; color: var(--muted); }
.btn-save-sm { background: var(--crimson); color: #fff; border: none; border-radius: 5px; padding: 10px 24px; font-size: 0.85rem; font-weight: 700; cursor: pointer; transition: background 0.2s; }
.btn-save-sm:hover { background: var(--crimson-dark); }

/* ── TOAST ── */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: var(--dark);
  color: #fff;
  padding: 12px 24px;
  border-radius: 6px;
  font-size: 0.9rem;
  border-left: 4px solid var(--gold);
  transform: translateY(80px);
  opacity: 0;
  transition: all 0.3s;
  z-index: 3000;
  max-width: 280px;
}
.toast.show { transform: translateY(0); opacity: 1; }

/* ── LIGHTBOX ── */
.lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.92);
  z-index: 5000;
  align-items: center;
  justify-content: center;
  cursor: zoom-out;
  padding: 1rem;
}
.lightbox-overlay.open { display: flex; }
.lightbox-overlay img {
  max-width: 92vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 48px rgba(0,0,0,0.6);
  cursor: default;
}
.lightbox-caption {
  position: fixed;
  bottom: 1.5rem;
  left: 0;
  right: 0;
  text-align: center;
  color: rgba(255,255,255,0.85);
  font-size: 0.95rem;
  pointer-events: none;
}
.lightbox-close {
  position: fixed;
  top: 1.25rem;
  right: 1.5rem;
  color: #fff;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.7;
  background: none;
  border: none;
  transition: opacity 0.2s;
}
.lightbox-close:hover { opacity: 1; }
footer {
  background: var(--dark);
  color: rgba(255,255,255,0.55);
  text-align: center;
  padding: 2rem;
  font-size: 0.83rem;
  margin-top: 4rem;
}
footer span { color: var(--gold); }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .nav-links { display: none; flex-direction: column; position: absolute; top: 60px; left: 0; right: 0; background: var(--crimson-dark); padding: 1rem 0; }
  .nav-links.open { display: flex; }
  .nav-links a { height: auto; padding: 0.75rem 2rem; border-bottom: none; border-left: 3px solid transparent; }
  .nav-links a.active, .nav-links a:hover { border-left-color: var(--gold); }
  .nav-hamburger { display: flex; }
  .about-grid { grid-template-columns: 1fr; }
  .updates-layout { grid-template-columns: 1fr; }
  .update-form-card { position: static; }
  .event-card { grid-template-columns: 70px 1fr; }
  .event-actions { flex-direction: row; grid-column: 1 / -1; }
  .form-row { grid-template-columns: 1fr; }
  .countdown-unit { padding: 1rem 1.2rem; }
  .countdown-num { font-size: 1.8rem; }
}
