:root {
  --linen: #fdfbf8;
  --stone: #d1c7be;
  --charcoal: #1c1a19;
  --gold: #c9a97f;
  --shadow: rgba(28, 26, 25, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--linen);
  color: var(--charcoal);
}

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

.page-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: radial-gradient(circle at top left, rgba(201, 169, 127, 0.18), transparent 45%), #fffdfa;
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2rem;
  font-family: 'Cinzel', serif;
  letter-spacing: 0.2em;
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 253, 250, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(28, 26, 25, 0.1);
}

.nav__status {
  font-size: 0.75rem;
  color: rgba(28, 26, 25, 0.65);
}

.nav__status-message,
.nav__status-timer {
  display: block;
}

.nav__status-timer {
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 0.98rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: rgba(28, 26, 25, 0.9);
  letter-spacing: 0.15em;
  margin-top: 0.15rem;
  display: none;
}

.nav__status--unlocked .nav__status-message {
  display: none;
}

.nav__status--unlocked .nav__status-timer {
  display: block;
}

.hero {
  text-align: center;
  padding: 4rem 1.5rem 2rem;
}

.hero__eyebrow {
  letter-spacing: 0.35em;
  text-transform: uppercase;
  font-size: 0.8rem;
  margin-bottom: 1.25rem;
  color: rgba(28, 26, 25, 0.5);
}

.hero__names {
  font-family: 'Great Vibes', cursive;
  font-size: clamp(3rem, 6vw, 4rem);
  margin: 0;
  color: var(--charcoal);
}

h1 {
  font-family: 'Cinzel', 'Times New Roman', serif;
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1.2;
  margin-bottom: 1rem;
}

.hero h1 {
  font-size: clamp(1.65rem, 4.2vw, 2.4rem);
}

p {
  line-height: 1.7;
  color: rgba(28, 26, 25, 0.76);
}

.hero__actions {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

.status-pill {
  padding: 0.35rem 1rem;
  border-radius: 999px;
  background: var(--gold);
  color: #1a110e;
  font-weight: 600;
}

.hero__note {
  font-size: 0.9rem;
  color: rgba(28, 26, 25, 0.55);
}

main {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  padding: 1rem 2rem 3rem;
}

.section {
  border-radius: 20px;
  padding: 2rem;
  background: #ffffff;
  border: 1px solid rgba(28, 26, 25, 0.08);
  box-shadow: 0 20px 45px var(--shadow);
}

.section.highlight {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 2rem;
  align-items: center;
}

.section.highlight h2 {
  font-family: 'Cinzel', serif;
  font-size: clamp(2.1rem, 3.3vw, 2.9rem);
  margin-bottom: 0.5rem;
}

.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.section.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}

.section.grid article {
  background: rgba(255, 255, 255, 0.02);
  padding: 1.25rem;
  min-height: 180px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.subscribe {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.5rem;
  align-items: start;
}

/*
  The unlocked "secret" content is rendered after the subscribe form.
  Since `.subscribe` is a 2-column grid, make the secret section span
  the full width to avoid awkward wrapping/misalignment.
*/
#secret-root {
  grid-column: 1 / -1;
}

.subscribe__intro {
  max-width: 520px;
}

.subscribe__access {
  width: 100%;
  max-width: 560px;
  margin-left: auto;
}

.subscription {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.subscription input {
  flex: 1;
  min-width: 0;
  padding: 0.9rem 1.4rem;
  border-radius: 30px;
  border: 1px solid rgba(28, 26, 25, 0.15);
  background: rgba(255, 255, 255, 0.95);
  color: var(--charcoal);
  font-size: 16px;
}

.subscription button {
  flex-shrink: 0;
  border-radius: 30px;
  border: none;
  padding: 0.95rem 1.8rem;
  font-weight: 600;
  background: linear-gradient(135deg, #f3d2b5, #c9a97f);
  color: #1a110e;
  cursor: pointer;
}

/* Shared primary button styling (used by the invitation download link too). */
.button-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 30px;
  border: none;
  padding: 0.95rem 1.8rem;
  font-weight: 600;
  background: linear-gradient(135deg, #f3d2b5, #c9a97f);
  color: #1a110e;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
}

.button-primary:hover {
  opacity: 0.9;
}

.subscription button:hover {
  opacity: 0.9;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  border: 0;
  clip: rect(0, 0, 0, 0);
  overflow: hidden;
}

.form-feedback {
  margin-top: 0.75rem;
  min-height: 1.5rem;
  width: 100%;
  text-align: center;
  padding: 0.85rem 1rem;
  border-radius: 14px;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.75);
}

.form-feedback:empty {
  padding: 0;
  border: 0;
  min-height: 0;
}

.form-feedback--error {
  color: #7b2c2c;
  border-color: rgba(123, 44, 44, 0.2);
  background: rgba(255, 214, 214, 0.55);
}

.form-feedback--success {
  color: rgba(28, 26, 25, 0.82);
  border-color: rgba(201, 169, 127, 0.4);
  background: rgba(201, 169, 127, 0.18);
}

/* After a successful unlock, hide the prompt + form but keep feedback visible. */
.subscribe.subscribe--unlocked .subscribe__intro {
  display: none;
}

.subscribe.subscribe--unlocked .subscription {
  display: none;
}

/* In unlocked mode, stop using the 2-column grid so the feedback can be centered. */
.subscribe.subscribe--unlocked {
  display: block;
}

.subscribe.subscribe--unlocked .subscribe__access {
  margin: 0 auto;
}

.secret-section {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(28, 26, 25, 0.08);
  background: transparent;
  border-left: 0;
  border-right: 0;
  border-bottom: 0;
  border-radius: 0;
  box-shadow: none;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  width: 100%;
  animation: fadeIn 0.6s ease;
}

.secret-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.5rem;
  padding: 0;
  border-radius: 0;
  background: transparent;
  border: 0;
}

.secret-hero__script {
  font-family: 'Great Vibes', cursive;
  font-size: clamp(2.75rem, 5vw, 3.35rem);
  margin: 0;
  color: var(--charcoal);
  word-spacing: 0.25em;
  letter-spacing: 0.02em;
}

.secret-hero__date {
  margin: 0;
  font-family: 'Cinzel', serif;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.95rem;
  color: rgba(28, 26, 25, 0.72);
}

.secret-hero__message {
  margin: 0;
  max-width: 52ch;
}

.secret-hero__tagline {
  margin: 0;
  font-size: 0.9rem;
  color: rgba(28, 26, 25, 0.6);
  letter-spacing: 0.35em;
  text-transform: uppercase;
}

.secret-tabs {
  width: fit-content;
  margin: 0 auto 1.25rem;
  display: flex;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.35rem;
  border-radius: 999px;
  background: rgba(201, 169, 127, 0.16);
  border: 1px solid rgba(201, 169, 127, 0.35);
}

.secret-tab-button {
  padding: 0.58rem 1.4rem;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 999px;
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(28, 26, 25, 0.7);
  cursor: pointer;
  transition: all 0.2s ease;
}

.secret-tab-button.is-active {
  background: #fff;
  border-color: rgba(28, 26, 25, 0.25);
  color: var(--charcoal);
  box-shadow: 0 6px 14px rgba(28, 26, 25, 0.08);
}

.secret-tab-panels {
  display: block;
}

.secret-tab-panel {
  width: 100%;
}

.secret-tab-panel .carousel {
  margin-top: 0;
  border-radius: 0;
  border: 0;
  background: transparent;
  padding: 0;
}

.carousel__slide {
  min-height: 300px;
  align-items: center;
  justify-content: center;
}


.carousel {
  position: relative;
  width: 100%;
  margin-top: 1rem;
  overflow: hidden;
}

.secret-section .carousel {
  margin-top: 0;
}

.carousel__track {
  position: relative;
}

.carousel__slide {
  display: none;
  width: 100%;
  text-align: center;
}

.carousel__slide.is-visible {
  display: block;
}

.carousel__slide img {
  width: 100%;
  height: auto;
  max-height: 600px;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  padding-bottom: 30px;
}

.carousel__button {
  position: absolute;
  top: 50%;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: rgba(28, 26, 25, 0.65);
  color: var(--linen);
  font-size: 1.4rem;
  transform: translateY(-50%);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
}

.carousel__button:hover {
  background: rgba(0, 0, 0, 0.85);
}

.carousel__button--prev {
  left: 0.5rem;
}

.carousel__button--next {
  right: 0.5rem;
}

.carousel__indicators {
  display: flex;
  gap: 0.4rem;
  margin-top: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.carousel__indicator {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  border: none;
  cursor: pointer;
}

.carousel__indicator.is-active {
  background: rgba(255, 255, 255, 0.9);
}

.carousel__empty {
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
  margin: 2rem 0;
}

footer {
  text-align: center;
}

@media (max-width: 900px) {
  .section.highlight {
    grid-template-columns: 1fr;
  }
  .subscribe {
    grid-template-columns: 1fr;
  }

  .subscribe__access {
    margin-left: 0;
    max-width: none;
  }
}

@media (max-width: 600px) {
  .nav {
    flex-direction: column;
    gap: 0.3rem;
  }
  .section {
    padding: 1.5rem;
  }
  main {
    padding: 1rem 1.25rem 2rem;
  }
  .subscription {
    flex-direction: column;
    width: 100%;
    align-items: stretch;
    justify-content: flex-start;
  }
  .subscription input {
    width: 100%;
  }
  .carousel__button {
    width: 34px;
    height: 34px;
    font-size: 1.1rem;
  }

  .secret-tabs {
    width: 100%;
  }

  .secret-tab-button {
    flex: 1;
  }
}

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