/* History reference: layered photographs, chapter details, and a connected timeline. */
body.about-page #history { background: #faf6ef; }
#history .abt__art {
  display: block;
  position: absolute;
  z-index: -1;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  mask-image: linear-gradient(to bottom, transparent, #000 5%, #000 95%, transparent);
}
#history .section-heading h2,
#history .chapter-copy .year,
#history .chapter-copy h3,
#history .chapter-tab-year { font-family: 'SPI Bodoni', Georgia, serif; }
@media (min-width: 1101px) {
  body.about-page #history { height: calc(960.8 * var(--hu)); }
  body.about-page #history .inner {
    height: 100%;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    row-gap: calc(38 * var(--hu));
  }
  #history .section-heading {
    position: absolute;
    z-index: 2;
    top: calc(55 * var(--hu));
    left: calc(915 * var(--hu));
    right: 0;
    margin: 0;
    text-align: left;
  }
  #history .section-heading h2 {
    margin: 0;
    font: 400 calc(76 * var(--hu))/.98 'SPI Bodoni', Georgia, serif;
    letter-spacing: -.045em;
    white-space: nowrap;
  }
  #history .section-heading em {
    display: block;
    margin: calc(6 * var(--hu)) 0 0 calc(70 * var(--hu));
    font: 400 1.2em/.8 'ABT Reference Script', cursive;
    letter-spacing: 0;
    color: #9d8c7a;
  }
  #history .chapter-stage { display: block; min-height: 0; margin: 0; }
  #history .chapter-panels { height: 100%; margin: 0; }
  #history .chapter-panel { position: relative; display: block; height: 100%; margin: 0; }
  #history .chapter-panel[hidden] { display: none; }
  #history .chapter-image {
    position: absolute;
    isolation: isolate;
    left: calc(64 * var(--hu));
    top: calc(150 * var(--hu));
    width: calc(800 * var(--hu));
    height: calc(520 * var(--hu));
    padding: calc(24 * var(--hu));
    aspect-ratio: auto;
    border: 1px solid #e4d5bc;
    border-radius: calc(5 * var(--hu));
    background: linear-gradient(115deg, #f8edda, #fffcf3 48%, #f6ecd9);
    box-shadow: 0 calc(12 * var(--hu)) calc(24 * var(--hu)) #5d432122;
    transform: rotate(-3deg);
  }
  #history .chapter-image::before,
  #history .chapter-image::after {
    content: '';
    position: absolute;
    inset: calc(4 * var(--hu));
    border: 1px solid #e5d4b9;
    border-radius: calc(5 * var(--hu));
    background: linear-gradient(125deg, #f0dfc5, #f9efde 55%, #ecdbc1);
    box-shadow: 0 calc(4 * var(--hu)) calc(10 * var(--hu)) #66523817;
    pointer-events: none;
  }
  #history .chapter-image::before { z-index: -2; transform: translate(calc(-14 * var(--hu)), calc(-18 * var(--hu))) rotate(-4deg); }
  #history .chapter-image::after { z-index: -1; transform: translate(calc(13 * var(--hu)), calc(15 * var(--hu))) rotate(4deg); }
  #history .chapter-image :is(img, .chapter-reference-photo) { position: relative; z-index: 1; }
  #history .chapter-copy {
    position: absolute;
    top: calc(260 * var(--hu));
    left: calc(915 * var(--hu));
    width: calc(440 * var(--hu));
    padding: 0;
  }
  #history .chapter-copy > .tiny {
    font: 400 calc(18 * var(--hu))/1.4 'ABT Reference Label', Arial, sans-serif;
    letter-spacing: .27em;
    color: #a18a76;
  }
  #history .chapter-copy .year {
    margin: calc(8 * var(--hu)) 0 calc(16 * var(--hu));
    font: 400 calc(132 * var(--hu))/.92 'SPI Bodoni', Georgia, serif;
    letter-spacing: -.06em;
    color: #073b57;
  }
  #history .chapter-copy h3 {
    font: 400 calc(42 * var(--hu))/1.05 'SPI Bodoni', Georgia, serif;
    letter-spacing: -.035em;
    white-space: nowrap;
  }
  #history .chapter-copy h3::before { width: calc(46 * var(--hu)); margin-bottom: calc(20 * var(--hu)); }
  #history .chapter-copy .description {
    max-width: 29ch;
    margin-top: calc(16 * var(--hu));
    font: 400 calc(26 * var(--hu))/1.2 'SPI Baskerville', Georgia, serif;
    letter-spacing: -.015em;
    color: #77736b;
  }
  #history .chapter-bottom {
    margin-top: calc(22 * var(--hu));
    gap: calc(24 * var(--hu));
    font-size: calc(11 * var(--hu));
    letter-spacing: .24em;
  }
  #history .wave-mark { width: calc(110 * var(--hu)); height: calc(22 * var(--hu)); }
  #history .chapter-arrow {
    position: absolute;
    z-index: 3;
    top: calc(430 * var(--hu));
    width: calc(64 * var(--hu));
    transform: translateY(-50%);
    background: #faf6efb3;
  }
  #history .chapter-arrow--prev { left: 0; }
  #history .chapter-arrow--next { right: 0; }
  #history .chapter-tabs {
    position: relative;
    isolation: isolate;
    margin: 0 calc(247 * var(--hu));
    gap: calc(110 * var(--hu));
  }
  #history .chapter-tabs::before {
    content: '';
    position: absolute;
    z-index: -1;
    left: calc(-247 * var(--hu));
    right: calc(-247 * var(--hu));
    top: calc(46 * var(--hu));
    height: 1px;
    background: #cbbfb2;
  }
  #history .chapter-tabs button { background: #faf6ef; }
  #history .chapter-tab-year { font: 400 calc(30 * var(--hu))/1 'SPI Bodoni', Georgia, serif; letter-spacing: -.04em; }
  #history .chapter-tabs .tab-line { width: calc(64 * var(--hu)); height: 2px; opacity: 0; left: 50%; transform: translateX(-50%); }
  #history .chapter-tabs button[aria-selected=true] .tab-line { width: calc(64 * var(--hu)); opacity: 1; }
}
@media (max-width: 1100px) {
  #history .chapter-image::before,
  #history .chapter-image::after { content: ''; position: absolute; z-index: -1; inset: 0; border: 1px solid #e2d0b6; background: #f6ead6; }
  #history .chapter-image { isolation: isolate; }
  #history .chapter-image::before { transform: rotate(-3deg); }
  #history .chapter-image::after { transform: rotate(2deg); }
}

/* Revised reference: two-line heading, deckled paper, and timeline markers. */
#history .history-title-main, #history .history-title-end { display: block; }
#history .section-heading .history-title-end em {
  display: inline;
  margin: 0;
  font: 400 1.2em/.8 'ABT Reference Script', cursive;
  margin-left: .06em;
  letter-spacing: 0;
  color: #9d8c7a;
}
#history .chapter-bottom { visibility: hidden; }
#history .chapter-image {
  --history-paper-edge: polygon(.3% 1%, 4% .4%, 8% .8%, 13% .2%, 18% .7%, 24% .1%, 30% .5%, 36% .1%, 42% .8%, 48% .2%, 54% .7%, 60% .1%, 66% .6%, 72% .2%, 78% .8%, 84% .3%, 90% .7%, 96% .2%, 99.6% .8%, 99.9% 9%, 99.6% 18%, 100% 28%, 99.5% 39%, 99.9% 50%, 99.5% 61%, 100% 72%, 99.6% 84%, 99.9% 94%, 99.4% 99.3%, 94% 99.7%, 88% 99.3%, 82% 100%, 76% 99.4%, 70% 99.9%, 64% 99.4%, 58% 99.9%, 52% 99.3%, 46% 100%, 40% 99.4%, 34% 99.8%, 28% 99.3%, 22% 100%, 16% 99.4%, 10% 99.9%, 4% 99.4%, .5% 99.6%, .1% 90%, .5% 80%, 0 70%, .5% 60%, .1% 50%, .5% 40%, 0 30%, .5% 20%, .1% 10%);
  background: none;
  border-color: transparent;
  box-shadow: none;
  filter: drop-shadow(0 8px 8px #5d43211a);
}
#history .chapter-paper {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 0;
  clip-path: var(--history-paper-edge);
  background: radial-gradient(#b69a6d0c .6px, transparent .8px) 0 0 / 5px 7px, linear-gradient(115deg, #fcf5e7, #fffdf5 48%, #f9f0df);
  pointer-events: none;
}
#history .chapter-image::before, #history .chapter-image::after {
  clip-path: var(--history-paper-edge);
  background: radial-gradient(#b69a6d0a .6px, transparent .8px) 0 0 / 5px 7px, linear-gradient(125deg, #f2e6d1, #faf1e1 55%, #f3e6d1);
}
#history .chapter-image :is(img, .chapter-reference-photo) { position: relative; z-index: 1; }
@media (min-width: 1101px) {
  #history .chapter-image::before { transform: translate(calc(-12 * var(--hu)), calc(-10 * var(--hu))) rotate(3deg); }
  #history .chapter-image::after { transform: translate(calc(10 * var(--hu)), calc(-16 * var(--hu))) rotate(-2deg); }
  #history .chapter-tabs button::before {
    content: '';
    position: absolute;
    left: calc(-28 * var(--hu));
    top: calc(46 * var(--hu));
    width: calc(8 * var(--hu));
    height: calc(8 * var(--hu));
    border: 1px solid #b59b85;
    border-radius: 50%;
    background: #faf6ef;
    transform: translate(-50%, -50%);
  }
  #history .chapter-tabs button[aria-selected=true]::before { background: #b59b85; }
}
@media (min-width: 701px) and (max-width: 1100px) {
  #history .section-heading h2 { height: calc(1.994em + 4 * var(--hu)); }
}
@media (max-width: 700px) {
  #history .section-heading h2 { height: calc(2.205em + 8px); }
}
