/* ============================================================
   Mehek & Ethan Wedding Website — Shared Styles
   ============================================================ */

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

html { -webkit-text-size-adjust: 100%; }

html, body {
  height: 100%;
  overflow-x: hidden;
}

body {
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  color: #2a1a0e;
  background: #817c7e;
}

/* ── Background painting ── */
.bg-painting {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  object-fit: cover;
  object-position: center 60%;
  filter: saturate(0.88) brightness(0.96);
}

.bg-small { z-index: 0; }

.bg-full {
  z-index: 1;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.bg-full[src] {
  @starting-style { opacity: 0; }
  opacity: 1;
}

/* ── Vignette ── */
.vignette {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 1;
  background: radial-gradient(
    ellipse at 50% 48%,
    transparent 38%,
    rgba(8, 18, 12, 0.50) 100%
  );
  pointer-events: none;
}

/* ── Navigation (interior pages) ── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 20;
  padding: 18px 40px;
  background: linear-gradient(
    to bottom,
    rgba(12, 26, 18, 0.68) 0%,
    rgba(12, 26, 18, 0.0) 100%
  );
}

.nav ul {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2.4rem;
  list-style: none;
}

.nav a {
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(242, 232, 210, 0.88);
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
  white-space: nowrap;
}

.nav a:hover:not(.soon) { color: #e8c88a; }
.nav a.active            { color: #e8c88a; }
.nav a.soon { opacity: 0.40; cursor: default; pointer-events: none; }
.nav a.nav-rsvp { color: #e8c88a; border-bottom: 1px solid rgba(232,200,138,0.55); padding-bottom: 2px; }
.nav a.nav-rsvp:hover { color: #f0d8a0; }

/* ============================================================
   Main layout
   ============================================================ */
.main {
  position: relative;
  z-index: 10;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 20px;
}

/* ============================================================
   Invitation card
   ============================================================ */
.card {
  position: relative;
  overflow: hidden;
  background: rgba(252, 246, 234, 0.92);
  border: 1px solid rgba(160, 120, 80, 0.26);
  box-shadow:
    0 12px 64px rgba(0, 0, 0, 0.24),
    0 2px 12px rgba(0, 0, 0, 0.10);
  padding: 44px 56px;
  text-align: center;
  max-width: 520px;
  width: 100%;
  animation: fadeUp 1.2s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Corner ornaments ── */
.corner {
  position: absolute;
  width: 88px;
  height: 88px;
  opacity: 0.38;
  pointer-events: none;
}

.corner.tl { top: 0;    left: 0;                             }
.corner.tr { top: 0;    right: 0;  transform: scaleX(-1);   }
.corner.bl { bottom: 0; left: 0;   transform: scaleY(-1);   }
.corner.br { bottom: 0; right: 0;  transform: scale(-1,-1); }

/* ── Eyebrow ── */
.eyebrow {
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-style: italic;
  font-size: 0.9rem;
  color: #6b5040;
  letter-spacing: 0.06em;
  margin-bottom: 12px;
}

/* ── Ornamental divider ── */
.ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: #8b6f47;
  font-size: 0.65rem;
  margin: 10px 0;
}

.orn-rule {
  display: block;
  width: 40px;
  height: 1px;
  background: #8b6f47;
  opacity: 0.55;
}

/* ── Names ── */
.names {
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-weight: 400;
  font-size: 2.8rem;
  line-height: 1.25;
  color: #2a1a0e;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  margin: 4px 0;
}

.amp {
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-style: italic;
  font-size: 1.6rem;
  color: #8b6f47;
  display: block;
  line-height: 1.2;
}

/* ── Body text ── */
.invite-text {
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-style: italic;
  font-size: 0.95rem;
  color: #5a3d28;
  letter-spacing: 0.02em;
  margin-bottom: 14px;
}

/* ── Event details ── */
.event-info { margin: 4px 0 14px; }

.date-line {
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-size: 1.0rem;
  letter-spacing: 0.12em;
  color: #2a1a0e;
  margin-bottom: 4px;
}

.city {
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-style: italic;
  font-size: 0.9rem;
  color: #6b5040;
}

/* ── RSVP button ── */
.rsvp-btn {
  display: inline-block;
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-size: 0.7rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: #fdf8f0;
  background: #8b6f47;
  padding: 12px 36px;
  text-decoration: none;
  margin-bottom: 14px;
  transition: background 0.2s ease, transform 0.1s ease;
}

.rsvp-btn:hover  { background: #7a5e38; }
.rsvp-btn:active { transform: translateY(1px); }

/* ── Footnote ── */
.std-note {
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-style: italic;
  font-size: 0.78rem;
  color: #8b6f47;
  letter-spacing: 0.06em;
}

/* ── Painting credit ── */
.painting-credit {
  position: fixed;
  bottom: 8px;
  right: 12px;
  z-index: 10;
  font-family: 'Didot', 'Palatino Linotype', 'Palatino', 'Book Antiqua', Georgia, serif;
  font-style: italic;
  font-size: 0.62rem;
  color: rgba(255, 248, 235, 0.50);
  pointer-events: none;
}

/* ── Code gate card ── */
.code-gate {
  animation: fadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* ── Code entry form ── */
.code-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
}

.code-input {
  width: 100%;
  padding: 13px 18px;
  font-family: inherit;
  font-size: 1.05rem;
  letter-spacing: 0.22em;
  text-align: center;
  text-transform: uppercase;
  background: rgba(255, 252, 244, 0.88);
  border: 1px solid rgba(139, 111, 71, 0.42);
  color: #2a1a0e;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.code-input:focus {
  border-color: #8b6f47;
  box-shadow: 0 0 0 3px rgba(139, 111, 71, 0.14);
}

.code-input::placeholder {
  color: #b09570;
  letter-spacing: 0.10em;
  font-size: 0.82rem;
  font-style: italic;
}

.code-submit {
  width: 100%;
  padding: 13px 24px;
  font-family: inherit;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  background: #8b6f47;
  color: #fdf8f0;
  border: none;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.1s ease;
}

.code-submit:hover  { background: #7a5e38; }
.code-submit:active { transform: translateY(1px); }

.code-error {
  font-style: italic;
  font-size: 0.88rem;
  color: #9a3020;
  min-height: 1.3em;
  text-align: center;
}

/* ── Page navigation (in-card, per-page) ── */
.page-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.8rem;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(139, 111, 71, 0.18);
}

.page-nav a {
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #8b6f47;
  text-decoration: none;
  transition: color 0.2s;
}

.page-nav a:hover   { color: #5a3d28; }
.page-nav a.current { color: #2a1a0e; pointer-events: none; }

/* ── Generic link ── */
.link { color: #8b6f47; text-decoration: underline; text-underline-offset: 2px; }
.link:hover { color: #6a5030; }

/* ============================================================
   Responsive — Mobile
   ============================================================ */
@media (max-width: 600px) {
  .main { padding: 32px 14px; }

  .card { padding: 32px 24px; }

  .corner { width: 68px; height: 68px; }

  .names     { font-size: 2.1rem; }
  .amp       { font-size: 1.3rem; }
  .date-line { font-size: 0.9rem; }
  .rsvp-btn  { padding: 11px 28px; }
}

@media (max-width: 380px) {
  .card  { padding: 26px 16px; }
  .names { font-size: 1.75rem; }
  .corner { width: 54px; height: 54px; }
}
