/*
  story.css
  Page-specific layout for our-story.html: the centered hero and the
  20-entry zig-zag timeline with scroll-reveal cards (see js/timeline.js).
*/

/* ===== hero ===== */
.hero {
  background: var(--cream);
  text-align: center;
  padding: 92px 48px 84px;
  border-top: 1px solid var(--frame-line);
}
.hero .crest {
  height: 96px;
  width: auto;
  margin: 0 auto 24px;
}
.hero h1 {
  font-family: 'DM Serif Display', serif;
  font-weight: 400;
  font-size: 78px;
  line-height: 0.98;
  color: var(--ink);
  margin: 8px 0 0;
}
.hero .lead {
  max-width: 600px;
  margin: 30px auto 0;
}

/* ===== timeline ===== */
.timeline-sec {
  background: var(--stone);
  border-top: 1px solid var(--frame-line);
  padding: 104px 0 116px;
}
.timeline {
  position: relative;
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 48px;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 6px;
  bottom: 6px;
  width: 2px;
  transform: translateX(-50%);
  background: repeating-linear-gradient(to bottom, var(--copper) 0 7px, transparent 7px 14px);
  opacity: 0.55;
}

.tl-item {
  position: relative;
  width: 50%;
  padding: 0 56px 64px 0;
}
.tl-item.right {
  margin-left: 50%;
  padding: 0 0 64px 56px;
}
.tl-item:last-child {
  padding-bottom: 0;
}

.tl-node {
  position: absolute;
  top: 8px;
  width: 17px;
  height: 17px;
  background: var(--stone);
  border: 2px solid var(--copper);
  transform: rotate(45deg);
  z-index: 2;
}
.tl-item.left .tl-node {
  right: -8.5px;
}
.tl-item.right .tl-node {
  left: -8.5px;
}
.tl-node::after {
  content: "";
  position: absolute;
  inset: 3px;
  background: var(--copper);
}

.tl-card {
  background: var(--paper);
  border: 1px solid var(--line);
  box-shadow: 0 16px 40px rgba(40, 26, 12, 0.10);
  overflow: hidden;
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.tl-item.in .tl-card {
  opacity: 1;
  transform: translateY(0);
}

.tl-figure {
  margin: 0;
  height: 230px;
  background: #eee4d2;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--line);
}
.tl-figure img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.tl-figure.contain {
  background: #fff;
}
.tl-figure.contain img {
  object-fit: contain;
  padding: 16px;
}
.tl-body {
  padding: 26px 30px 30px;
}
.tl-year {
  display: inline-block;
  font-family: 'EB Garamond', serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #fff;
  background: var(--copper);
  padding: 5px 12px;
  margin-bottom: 14px;
}
.tl-card h3 {
  font-family: 'DM Serif Display', serif;
  font-weight: 400;
  font-size: 30px;
  line-height: 1.06;
  color: var(--ink);
  margin: 0 0 12px;
}
.tl-card p {
  font-size: 16.5px;
  line-height: 1.62;
  color: var(--ink-soft);
  margin: 0;
}

/* ===== closing CTA ===== */
.closing {
  background: var(--cream);
  border-top: 1px solid var(--frame-line);
  text-align: center;
  padding: 100px 48px;
}
.closing h2 {
  font-family: 'DM Serif Display', serif;
  font-weight: 400;
  font-size: 46px;
  color: var(--ink);
  margin: 0 auto 16px;
  max-width: 680px;
}
.closing .cta {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 30px;
}

@media (max-width: 900px) {
  .hero {
    padding: 64px 24px 56px;
  }
  .hero h1 {
    font-size: 46px;
  }
  .hero .crest {
    height: 74px;
  }
  .timeline-sec {
    padding: 64px 0 72px;
  }
  .timeline {
    padding: 0 8px;
  }
  .timeline::before {
    left: 18px;
  }
  .tl-item,
  .tl-item.right {
    width: 100%;
    margin-left: 0;
    padding: 0 0 40px 52px;
  }
  .tl-item.left .tl-node,
  .tl-item.right .tl-node {
    left: 10px;
    right: auto;
  }
  .tl-figure {
    height: 200px;
  }
  .closing {
    padding: 64px 24px;
  }
  .closing h2 {
    font-size: 34px;
  }
}
