.lore-section {
  position: relative;
  overflow: hidden;
  padding-block: clamp(96px, 11vw, 160px);
  background:
    radial-gradient(circle at 12% 10%, rgba(242, 207, 99, 0.22), transparent 28%),
    linear-gradient(180deg, #f7f1e3 0%, #fff8e9 42%, #edf3df 100%);
  border-top: 1px solid rgba(45, 36, 29, 0.08);
  border-bottom: 1px solid rgba(45, 36, 29, 0.08);
}

.lore-section::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.22;
  background-image:
    repeating-linear-gradient(12deg, rgba(121, 82, 55, 0.04) 0 1px, transparent 1px 15px),
    repeating-linear-gradient(94deg, rgba(47, 109, 54, 0.025) 0 1px, transparent 1px 18px);
  mix-blend-mode: multiply;
}

.lore-shell {
  position: relative;
  z-index: 1;
}

.lore-intro {
  max-width: 880px;
  margin-bottom: 38px;
}

.lore-intro h2 {
  max-width: 900px;
  margin: 0;
  color: var(--cocoa);
  font-family: "Bowlby One SC", sans-serif;
  font-size: clamp(42px, 5vw, 70px);
  font-weight: 400;
  letter-spacing: -0.055em;
  line-height: 0.95;
}

.lore-intro-line {
  max-width: 560px;
  margin: 17px 0 0;
  color: rgba(45, 36, 29, 0.68);
  font-size: 18px;
  font-weight: 400;
}

.lore-story {
  position: relative;
}

.lore-root-track {
  position: absolute;
  z-index: 0;
  top: 170px;
  bottom: 200px;
  left: 50%;
  width: 38px;
  transform: translateX(-50%);
  opacity: 0.52;
}

.lore-root-track::before,
.lore-root-track::after,
.lore-root-track i {
  content: "";
  position: absolute;
  display: block;
  border: 2px solid rgba(121, 82, 55, 0.55);
  border-width: 0 0 0 3px;
  border-radius: 50%;
}

.lore-root-track::before {
  inset: 0 4px 34% 17px;
  transform: rotate(2deg);
}

.lore-root-track::after {
  inset: 28% 15px 0 8px;
  transform: rotate(-3deg);
}

.lore-root-track i {
  top: 44%;
  left: 17px;
  width: 95px;
  height: 85px;
  border-width: 0 0 3px 3px;
  transform: rotate(-24deg);
}

.lore-chapter {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(320px, 0.84fr);
  align-items: center;
  gap: clamp(52px, 8vw, 120px);
  min-height: 640px;
  padding-block: clamp(58px, 8vw, 105px);
}

.lore-chapter[data-lore-chapter="01"] {
  min-height: 0;
  padding-top: 0;
}

.lore-chapter-reverse .lore-scene {
  order: 2;
}

.lore-chapter-reverse .lore-copy {
  order: 1;
}

.lore-scene {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 11;
  margin: 0;
  border: 2px solid var(--cocoa);
  border-radius: 42% 58% 45% 55% / 52% 44% 56% 48%;
  background: #f6e8ce;
  box-shadow: 16px 20px 0 rgba(121, 82, 55, 0.08);
  isolation: isolate;
}

.lore-chapter-reverse .lore-scene {
  border-radius: 57% 43% 54% 46% / 44% 57% 43% 56%;
  box-shadow: -16px 20px 0 rgba(121, 82, 55, 0.08);
}

.lore-scene-art {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.9) contrast(0.96);
}

.lore-scene::after {
  content: "";
  position: absolute;
  z-index: 4;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 250, 240, 0.08), rgba(121, 82, 55, 0.055));
  mix-blend-mode: multiply;
}

.lore-copy {
  max-width: 500px;
}

.lore-chapter-label {
  display: inline-block;
  margin: 0 0 22px;
  padding: 8px 13px;
  border: 1px solid rgba(45, 36, 29, 0.28);
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.66);
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.13em;
}

.lore-copy > p,
.lore-finale-copy > p {
  margin: 0 0 18px;
  font-size: clamp(19px, 2vw, 26px);
  line-height: 1.48;
}

.lore-copy > p:last-child {
  margin-bottom: 0;
}

.lore-whispers {
  display: grid;
  gap: 8px;
  margin-top: 30px;
  padding-left: 22px;
  border-left: 3px solid var(--green);
  font-size: 16px;
}

.lore-whispers span {
  color: rgba(45, 36, 29, 0.72);
}

.lore-whispers strong {
  margin-top: 6px;
  color: var(--cocoa);
  font-size: 18px;
}

.lore-tree-foreshadow {
  color: var(--green-dark) !important;
  font-weight: 600;
  line-height: 1.25 !important;
}

.lore-tree-foreshadow strong {
  font-family: "Bowlby One SC", sans-serif;
  font-size: 1.08em;
  font-weight: 400;
  letter-spacing: 0.02em;
}

.lore-tree {
  position: absolute;
  z-index: 2;
  bottom: 12%;
  left: 52%;
  width: 24%;
  max-width: none;
  height: auto;
  filter: sepia(0.35) saturate(1.3) brightness(0.95) contrast(1.02);
  filter: url("#lore-tree-color-match");
  mix-blend-mode: normal;
  opacity: 1;
  pointer-events: none;
  user-select: none;
}

.lore-seed {
  position: absolute;
  z-index: 3;
  width: 31%;
  max-width: none;
  height: auto;
  filter: saturate(1.1) brightness(1) contrast(0.94);
  filter: url("#lore-gro-color-match");
  opacity: 1;
  pointer-events: none;
  user-select: none;
}

.lore-seed-arrival {
  right: auto;
  bottom: 11%;
  left: 49.4%;
  width: 20%;
  transform: translateX(-51.5%);
}

.lore-seed-watcher {
  right: auto;
  bottom: 16%;
  left: 50%;
  width: 18%;
  transform: translateX(-50%);
}

.lore-scene-magic {
  background: #f6e8ce;
}

.lore-seed-magic {
  right: auto;
  bottom: 16%;
  left: 50%;
  width: 18%;
  transform: translateX(-50%);
}

.lore-seed-rumors {
  right: auto;
  bottom: 16%;
  left: 50%;
  width: 18%;
  transform: translateX(-50%);
}

.lore-emphasis {
  color: var(--green-dark);
  font-size: clamp(28px, 3.4vw, 48px) !important;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.08 !important;
}

.lore-finale {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(380px, 0.75fr);
  align-items: center;
  gap: clamp(50px, 8vw, 110px);
  min-height: 0;
  margin-top: clamp(58px, 8vw, 105px);
  padding: clamp(38px, 4vw, 58px);
  overflow: hidden;
  border: 2px solid var(--cocoa);
  border-radius: 58px;
  background: #efe5c8;
  box-shadow: var(--shadow);
}

.lore-finale::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle at 78% 42%,
    rgba(231, 196, 92, 0.28) 0,
    rgba(231, 196, 92, 0.12) 30%,
    transparent 58%
  );
}

.lore-finale-copy,
.lore-finale-visual {
  position: relative;
  z-index: 2;
}

.lore-final-question {
  max-width: 620px;
  color: var(--green-dark);
  font-size: clamp(30px, 4vw, 56px) !important;
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1.05 !important;
}

.lore-name {
  display: block;
  margin-top: 30px;
  color: var(--green-dark);
  font-family: "Bowlby One SC", sans-serif;
  font-size: clamp(42px, 5vw, 70px);
  font-weight: 400;
  letter-spacing: -0.055em;
  line-height: 0.95;
}

.lore-finale-visual {
  width: 100%;
  min-height: 0;
  aspect-ratio: 3 / 2;
  margin: 0;
}

.lore-seed-finale-art {
  right: auto;
  bottom: 9.3%;
  left: 52.1%;
  width: clamp(86px, 21.5%, 165px);
  transform: translateX(-50%);
}

.lore-js .lore-reveal {
  opacity: 0;
  transform: translateY(38px);
  transition: opacity 700ms ease, transform 700ms ease;
}

.lore-js .lore-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .lore-js .lore-reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

@media (max-width: 900px) {
  .lore-root-track {
    left: 21px;
    transform: none;
  }

  .lore-chapter,
  .lore-finale {
    grid-template-columns: 1fr;
  }

  .lore-chapter {
    min-height: 0;
    gap: 32px;
    padding: 58px 0 58px 58px;
  }

  .lore-chapter .lore-scene,
  .lore-chapter .lore-copy {
    order: initial;
  }

  .lore-copy {
    max-width: 680px;
  }

  .lore-finale {
    margin-top: 58px;
    padding: 58px;
  }

  .lore-finale-visual {
    max-width: 380px;
    margin-inline: auto;
  }

}

@media (max-width: 760px) {
  .lore-intro {
    margin-bottom: 26px;
    text-align: center;
  }

  .lore-intro h2 {
    font-size: clamp(38px, 11vw, 54px);
  }

  .lore-intro-line {
    margin: 17px auto 0;
  }
}

@media (max-width: 620px) {
  .lore-section {
    padding-block: 78px;
  }

  .lore-root-track {
    left: 7px;
  }

  .lore-chapter {
    padding: 38px 0 38px 27px;
    gap: 20px;
  }

  .lore-scene {
    border-width: 1.5px;
    border-radius: 26px !important;
    box-shadow: 8px 10px 0 rgba(121, 82, 55, 0.08) !important;
  }

  .lore-copy > p,
  .lore-finale-copy > p {
    font-size: 18px;
  }

  .lore-chapter-label {
    margin-bottom: 15px;
  }

  .lore-whispers {
    margin-top: 22px;
    padding-left: 15px;
    font-size: 14px;
  }

  .lore-whispers strong {
    font-size: 16px;
  }

  .lore-emphasis {
    font-size: 31px !important;
  }

  .lore-finale {
    min-height: 0;
    margin-top: 38px;
    padding: 38px 25px 22px;
    border-radius: 30px;
  }

  .lore-final-question {
    font-size: 36px !important;
  }

  .lore-name {
    font-size: clamp(38px, 11vw, 54px);
  }

}
