/* Palette colori */
:root {
  --whitish: #fdfbfe;
  --blackish: #151514;
  --gold: #ae9c85;
  --stone: #B8B8B8;
  --page-column-width: 760px;
}

html {
  margin: 0;
  padding: 0;
  font-family: sans-serif;
  scroll-behavior: smooth;
  height: 100%;
}

body {
  height: 100%;
  margin: 0;
  overflow: hidden;
  background-image: url('../images/sfondo2.jpg');
  background-repeat: repeat;
  background-size: auto; /* keep original size, or set e.g. 200px 200px */
}

.reel-scroll {
  height: 100vh;
  height: 100dvh;
  overflow-y: auto;
  scroll-snap-type: y mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

  h2 {
    font-family: "Herr Von Muellerhoff", cursive;
    font-weight: 400;
    font-style: normal;
    color: var(--blackish);
    margin: 0em;
    font-size: 3em
  }

    h3 {
    font-family: "Herr Von Muellerhoff", cursive;
    font-weight: 400;
    font-style: normal;
    color: var(--blackish);
    margin-bottom: 0.5em;
    font-size: 2em
  }

  .question {
    font-family: 'Cinzel', serif;
    font-size: clamp(1.15rem, 1.45vw, 1.45rem);
    font-style: italic;
    line-height: 1.4;
  }

  .answer {
    font-family: 'Cinzel', serif;
    font-size: clamp(0.98rem, 1.1vw, 1.18rem);
    font-style: italic;
    line-height: 1.45;
    padding-bottom: 15px;
  }

  .qa-images {
  display: flex;
  justify-content: center; /* center horizontally */
  gap: 1rem; /* space between the images */
  margin: 2rem; /* space before the questions */
}

.qa-images img {
  height: 80px;   /* or whatever size fits your design */
  width: auto;  /* keep aspect ratio */
}

.two-column {
  display: flex;
  align-items: center; /* center everything vertically */
  margin: 10 auto;
}

.two-column .column {
  flex: 1;
  padding: 1rem;
}

a {
  text-decoration: none;
}
.separator {
  width: 2px;
  background-color: #ccc;
  height: 100px; /* adjust this to make it shorter */
  align-self: center; /* center it in the row */
}

.two-column .left {
  text-align: center;
}

.two-column .right {
  text-align: center; /* or center if you prefer */
  gap: 0.5rem; /* space between text and image */
}

.two-column img {
  max-width: 40px; /* adjust size */
  height: auto;
}

p {
  font-family: 'Cinzel', serif;
  letter-spacing: 0.15em; 
  color: var(--blackish);
}

.page {
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  padding: 2rem 0;         /* space inside each section */
  box-sizing: border-box;  /* padding counts toward min-height */
  overflow: visible;       /* was hidden – don’t clip content */
}

.center-wrapper {
  width: min(92vw, var(--page-column-width));
  margin-inline: auto;
}

/* Top-aligned page variant */
.page.page-top {
  display: flex;           /* make the section a flex container like the others */
  align-items: flex-start; /* put the child at the top of the section */
  min-height: 100vh;       /* keep the full-height behavior if you're using it */
}

.page.page-top .top-wrapper {
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* start content at the very top */
  align-items: stretch;
  height: 100%;
  padding-top: 0;
}

/* Also make sure .top-wrapper itself never centers its children */
.top-wrapper {
  align-items: flex-start;
}

.page-compact {
  display: flex;             /* keep flex layout for consistent alignment */
  align-items: center;       /* or flex-start if you want top alignment */
  justify-content: center;   /* horizontal centering */
  padding: 3rem 0;           /* vertical space, no extra width padding */
  min-height: 80vh;          /* don't force 100vh like .page might */
}

/* Contenuto centrato */
.content {
  width: 90%;
  margin: 0 auto;
  text-align: center;
  position: relative;
  word-wrap: break-word;
  overflow-wrap: break-word;
  z-index: 1;
}

.content.full {
  width: 100%;
}

.hero-img-full {
  width: 100%;
  max-height: 70vh;   /* cap it to the section’s space */
  height: auto;       /* keep aspect ratio */
  object-fit: contain;/* show the whole image (no cropping) */
  object-position: center;
  display: block;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* o cover se vuoi riempire */
  display: block;
}

#diocesi .hero-img {
  height: auto;
  max-height: 42vh;
}

#ricevimento .hero-img {
  height: auto;
  max-height: 42vh;
}

.bottom-text {
  height: 30vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}

.section-title {
  margin-bottom: 24px;
}

#moreinfo .content {
  width: 100%;
  margin: 0;
}

.info-list {
  display: grid;
  gap: 0.85rem;
  text-align: left;
}

.info-item {
  border: 1px solid rgba(90, 58, 47, 0.28);
  border-radius: 8px;
  padding: 0.9rem 1rem;
  background: rgba(255, 255, 255, 0.35);
}

.info-label {
  margin: 0 0 0.2rem;
  font-family: 'Cinzel', serif;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.75;
}

.info-question {
  margin: 0 0 0.55rem;
  padding-left: 0.45rem;
  border-left: 2px solid rgba(90, 58, 47, 0.25);
  font-family: 'Old Standard TT', serif;
  font-size: clamp(1rem, 1.2vw, 1.2rem);
  font-style: italic;
  line-height: 1.4;
  letter-spacing: 0.03em;
}

.info-answer {
  margin: 0;
  padding-left: 0.45rem;
  border-left: 2px solid rgba(90, 58, 47, 0.16);
  font-family: 'Old Standard TT', serif;
  font-size: clamp(0.95rem, 1.05vw, 1.08rem);
  line-height: 1.45;
  letter-spacing: 0.02em;
}

.bottom-text p {
  word-break: break-word;
  overflow-wrap: break-word;
}

/* Intro */
#intro {
  padding: 0;
}

.intro-wrapper {
  height: 100%;
}

.intro-content {
  width: 100%;
  min-height: calc(100dvh - 4rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
}

.intro-floral {
  width: 100%;
  max-height: 28vh;
  height: auto;
  object-fit: contain;
  display: block;
}

.intro-text {
  text-align: center;
  padding: 0.2rem 0;
}

.intro-names {
  margin: 0.25rem 0 0;
  font-family: 'Cinzel', serif;
  font-weight: 400;
  line-height: 1.05;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: clamp(2.1rem, 5.3vw, 4.8rem);
  color: #5a3a2f;
}

.intro-date {
  margin: 0.55rem 0 0;
  font-family: 'Cinzel', serif;
  font-size: clamp(1rem, 2.4vw, 1.5rem);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #5a3a2f;
}

.intro-place {
  margin: 0.55rem 0 0;
  font-family: 'Cinzel', serif;
  font-size: clamp(1rem, 2vw, 1.5rem);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #5a3a2f;
}

/* Timeline */
#timeline {
  align-items: flex-start;
  padding: 1rem 0;
}

#timeline .center-wrapper {
  width: min(92vw, var(--page-column-width));
  height: 100%;
}

#timeline .content {
  width: 100%;
  padding: 0.5rem 1rem;
}

.timeline {
  position: relative;
  padding: 0.5rem 0;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: #8f7b6a;
  transform: translateX(-50%);
}

.timeline-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 66px;
}

.timeline-item::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #5a3a2f;
  z-index: 1;
  transform: translate(-50%, -50%);
}

.timeline-card {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  max-width: 320px;
}

.timeline-item.left .timeline-card {
  grid-column: 1;
  justify-self: end;
  text-align: right;
  margin-right: 1.1rem;
}

.timeline-item.right .timeline-card {
  grid-column: 3;
  justify-self: start;
  text-align: left;
  margin-left: 1.1rem;
}

.timeline-icon {
  width: 50px;
  height: 50px;
  flex: 0 0 50px;
}

.timeline-time,
.timeline-title,
.timeline-desc {
  margin: 0;
  color: #5a3a2f;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.timeline-time {
  font-size: 1.1rem;
  font-weight: 700;
  font-family: 'Old Standard TT', serif;
}

.timeline-title {
  font-size: 0.96rem;
  font-family: 'Cinzel', serif;
}

.timeline-desc {
  font-size: 0.8rem;
  margin-top: 0.2rem;
  opacity: 0.95;
}

/* Desktop */
@media (min-width: 768px) {
  .center-wrapper {
    width: min(88vw, var(--page-column-width));
  }
}

/* Timeline mobile: single side */
@media (max-width: 768px) {
  .intro-content {
    min-height: calc(100dvh - 4rem);
    gap: 0.4rem;
  }

  .intro-floral {
    width: 100%;
    max-height: 26vh;
  }

  .intro-names {
    letter-spacing: 0.09em;
    font-size: clamp(1.65rem, 8vw, 2.7rem);
  }

  .intro-date {
    letter-spacing: 0.14em;
  }

  #timeline .content {
    width: 100%;
    padding: 0.5rem 0.75rem;
  }

  .timeline::before {
    left: 13px;
    transform: none;
  }

  .timeline-item {
    grid-template-columns: 26px 1fr;
    min-height: 74px;
  }

  .timeline-item::after {
    left: 13px;
    top: 50%;
    width: 14px;
    height: 14px;
    transform: translate(-50%, -50%);
  }

  .timeline-item.left .timeline-card,
  .timeline-item.right .timeline-card {
    grid-column: 2;
    justify-self: start;
    text-align: left;
    max-width: none;
    width: 100%;
    margin-left: 0.75rem;
  }

  .timeline-icon {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }
}

@media (min-width: 1024px) {
  .intro-floral {
    max-height: 24vh;
  }

  .intro-names {
    font-size: clamp(1.95rem, 4vw, 3.8rem);
  }
}
/* Fade-in effect */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: none;
}

footer {
  scroll-snap-align: start;
  margin-bottom: 80px;
}

/* Quick nav snackbar */
.quick-nav {
  position: fixed;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 1200;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  pointer-events: none;
}

.quick-nav-toggle {
  pointer-events: auto;
  border: 1px solid rgba(90, 58, 47, 0.35);
  background: rgba(253, 251, 254, 0.95);
  color: #5a3a2f;
  border-radius: 999px;
  padding: 0.45rem 0.95rem;
  font-family: 'Cinzel', serif;
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.quick-nav-list {
  pointer-events: auto;
  list-style: none;
  margin: 0;
  padding: 0.45rem;
  width: min(88vw, 360px);
  display: none;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.35rem;
  border-radius: 14px;
  border: 1px solid rgba(90, 58, 47, 0.18);
  background: rgba(253, 251, 254, 0.95);
  backdrop-filter: blur(6px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.16);
  max-height: 40vh;
  overflow: auto;
}

.quick-nav.open .quick-nav-list {
  display: grid;
}

.quick-nav-list a {
  display: block;
  text-decoration: none;
  color: #5a3a2f;
  border: 1px solid rgba(90, 58, 47, 0.2);
  border-radius: 8px;
  padding: 0.4rem 0.45rem;
  font-family: 'Old Standard TT', serif;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  background: rgba(255, 255, 255, 0.75);
}

.quick-nav-list a.is-active {
  background: rgba(174, 156, 133, 0.24);
  border-color: rgba(90, 58, 47, 0.45);
}

.lang-switch {
  position: fixed;
  top: 12px;
  right: 12px;
  z-index: 1300;
  display: inline-flex;
  gap: 0.35rem;
  padding: 0.3rem;
  border-radius: 999px;
  border: 1px solid rgba(90, 58, 47, 0.18);
  background: rgba(253, 251, 254, 0.95);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.lang-btn {
  border: 0;
  background: transparent;
  border-radius: 999px;
  padding: 0.2rem 0.35rem;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  opacity: 0.75;
}

.lang-btn.is-active {
  opacity: 1;
  background: rgba(174, 156, 133, 0.25);
}

@media (max-width: 768px) {
  .lang-switch {
    top: 8px;
    right: 8px;
  }

  .quick-nav {
    bottom: 10px;
  }

  .quick-nav-list {
    grid-template-columns: 1fr;
    width: min(90vw, 300px);
  }
}
