/*
 * About timeline v2
 * Responsive recreation of the approved towel-stack mockups.
 * The same physical towel system now carries from desktop through mobile.
 */

body[data-page="about"] .about-towel-history {
  display: none;
}

@media (min-width: 0px) {
  body[data-page="about"] .about-claim-timeline[data-mobile-history] {
    display: none;
  }

  body[data-page="about"] .about-towel-history {
    --timeline-cream: #f1e5ce;
    --timeline-paper: #fbfaf6;
    --timeline-navy: #081321;
    --timeline-gold: #b8965a;
    display: block;
    width: 100%;
    margin: 0;
    padding: clamp(2.75rem, 3.7vw, 3.7rem) 0 clamp(3.5rem, 4.8vw, 5rem);
    overflow: clip;
    color: var(--timeline-navy);
    background: transparent;
    box-shadow: none;
  }

  body[data-page="about"] .about-towel-history__title {
    width: min(83.2vw, 77.5rem);
    margin: 0 auto clamp(2rem, 2.8vw, 2.65rem);
    color: var(--timeline-navy);
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: clamp(2.35rem, 4.35vw, 4rem);
    font-weight: 500;
    line-height: 1;
    letter-spacing: -0.038em;
    text-align: center;
  }

  body[data-page="about"] .about-towel-history__stage {
    width: min(83.2vw, 77.5rem);
    margin: 0 auto;
    position: relative;
  }

  body[data-page="about"] .about-towel-history__list {
    margin: 0;
    padding: 0;
    list-style: none;
  }

  body[data-page="about"] .about-towel-history__item,
  body[data-page="about"] .about-towel-history__item:nth-child(n) {
    margin: 0;
    padding: 0;
  }

  body[data-page="about"] .about-towel-history__trigger {
    appearance: none;
    width: 100%;
    margin: 0;
    padding: 0;
    position: relative;
    display: grid;
    align-items: center;
    overflow: visible;
    color: var(--timeline-navy);
    border: 0;
    border-radius: 0;
    background-color: transparent;
    background-image: url("../images/generated/about-timeline-row-terry-safe-v2.webp");
    background-position: center;
    background-repeat: no-repeat;
    background-size: 104.5% 100%;
    filter:
      drop-shadow(0 0.2rem 0.18rem rgba(50, 39, 27, 0.2))
      drop-shadow(0 0.62rem 0.72rem rgba(50, 39, 27, 0.12));
    cursor: pointer;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 600;
    text-align: left;
    transition: filter 180ms ease, transform 280ms cubic-bezier(0.2, 0.72, 0.2, 1);
  }

  body[data-page="about"] .about-towel-history__trigger:hover {
    filter:
      brightness(1.018)
      drop-shadow(0 0.28rem 0.22rem rgba(50, 39, 27, 0.23))
      drop-shadow(0 0.76rem 0.84rem rgba(50, 39, 27, 0.15));
  }

  body[data-page="about"] .about-towel-history__trigger:focus-visible {
    z-index: 20;
    outline: 0;
  }

  body[data-page="about"] .about-towel-history__trigger:focus-visible .about-towel-history__label {
    text-decoration-line: underline;
    text-decoration-color: rgba(8, 19, 33, 0.88);
    text-decoration-thickness: 2px;
    text-underline-offset: 0.14em;
  }

  body[data-page="about"] .about-towel-history__item.is-active .about-towel-history__trigger {
    z-index: 12;
    filter:
      brightness(1.012)
      drop-shadow(0 0.4rem 0.3rem rgba(50, 39, 27, 0.27))
      drop-shadow(0 0.95rem 1.05rem rgba(50, 39, 27, 0.18));
  }

  body[data-page="about"] .about-towel-history__trigger::before {
    content: none;
  }

  body[data-page="about"] .about-towel-history__year,
  body[data-page="about"] .about-towel-history__label {
    min-width: 0;
    position: relative;
    z-index: 2;
  }

  body[data-page="about"] .about-towel-history__year {
    width: 18%;
    position: absolute;
    left: 23.5%;
    transform: translateX(-50%);
    color: #8a6228;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
  }

  body[data-page="about"] .about-towel-history__label {
    width: 100%;
    box-sizing: border-box;
    padding-left: calc(35.5% + clamp(0.45rem, 0.85vw, 0.72rem));
    color: var(--timeline-navy);
    font-weight: 600;
    line-height: 1.03;
    letter-spacing: -0.024em;
    white-space: nowrap;
  }

  body[data-page="about"] .about-towel-history__arrow {
    display: none;
    color: var(--timeline-gold);
  }

  body[data-page="about"] .about-towel-history__detail {
    box-sizing: border-box;
  }

  body[data-page="about"] .about-towel-history__detail-clip,
  body[data-page="about"] .about-towel-history__detail-surface {
    min-height: 0;
    box-sizing: border-box;
  }

  body[data-page="about"] .about-towel-history__detail-surface {
    position: relative;
    --towel-band-start: 0.905;
    background-position: center;
    background-repeat: no-repeat;
    background-size: 100% 100%;
  }

  body[data-page="about"] .about-towel-history__detail-content {
    box-sizing: border-box;
    position: relative;
    z-index: 2;
  }

  body[data-page="about"] .about-towel-history__detail-header {
    margin: 0;
    color: var(--timeline-navy);
  }

  body[data-page="about"] .about-towel-history__detail-header time {
    color: #8a6228;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 600;
    line-height: 1;
  }

  body[data-page="about"] .about-towel-history__detail-rule {
    display: block;
    height: 1px;
    background: rgba(184, 150, 90, 0.82);
  }

  body[data-page="about"] .about-towel-history__detail-header h3 {
    margin: 0;
    color: var(--timeline-navy);
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: var(--towel-detail-title-size, clamp(1.58rem, 3vw, 2.78rem));
    font-weight: 500;
    line-height: 0.98;
    letter-spacing: -0.038em;
    white-space: nowrap;
  }

  body[data-page="about"] .about-towel-history__photo {
    width: 100%;
    margin: 0;
    box-sizing: border-box;
    padding: clamp(0.48rem, 0.72vw, 0.72rem);
    background: var(--timeline-paper);
    border: 1px solid rgba(73, 63, 48, 0.16);
    box-shadow: 0 0.45rem 0.78rem rgba(45, 34, 22, 0.2);
  }

  body[data-page="about"] .about-towel-history__photo img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center;
    border: 1px solid rgba(42, 34, 25, 0.18);
    filter: none;
  }

  body[data-page="about"] .about-towel-history__copy {
    margin: 0;
    color: var(--timeline-navy);
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 500;
    line-height: 1.4;
    letter-spacing: 0.002em;
  }

  body[data-page="about"] .about-towel-history__photo img[src*="shelton-cleaners-poly-garments"] {
    object-position: 58% 50%;
  }
}

@media (min-width: 861px) {
  body[data-page="about"] .about-towel-history {
    padding-top: 1.875rem;
  }

  body[data-page="about"] .about-towel-history__title {
    margin-bottom: 3rem;
  }

  body[data-page="about"] .about-towel-history__stage {
    aspect-ratio: 1.462 / 1;
  }

  body[data-page="about"] .about-towel-history__list {
    width: 39.25%;
    height: 100%;
    display: grid;
    grid-template-rows: repeat(9, minmax(0, 1fr));
  }

  body[data-page="about"] .about-towel-history__item,
  body[data-page="about"] .about-towel-history__item:nth-child(n) {
    width: 100%;
    height: 100%;
    position: static;
  }

  body[data-page="about"] .about-towel-history__trigger {
    height: calc(100% + 0.2rem);
    grid-template-columns: minmax(0, 1fr);
    transform: translateY(-0.1rem);
  }

  body[data-page="about"] .about-towel-history__item.is-active .about-towel-history__trigger {
    transform: translateY(-0.18rem) scale(1.006);
  }

  body[data-page="about"] .about-towel-history__year {
    font-size: clamp(0.76rem, 1.42vw, 1.3rem);
  }

  body[data-page="about"] .about-towel-history__label {
    padding-top: 0.1rem;
    padding-right: clamp(0.72rem, 1.15vw, 1.08rem);
    padding-bottom: 0.1rem;
    font-size: var(--towel-trigger-title-size, clamp(0.94rem, 1.58vw, 1.46rem));
  }

  body[data-page="about"] .about-towel-history__detail {
    width: 55.35%;
    height: 100%;
    position: absolute;
    inset: 0 0 auto auto;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 280ms ease;
  }

  body[data-page="about"] .about-towel-history__item.is-active .about-towel-history__detail {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  body[data-page="about"] .about-towel-history__detail-clip,
  body[data-page="about"] .about-towel-history__detail-surface {
    width: 100%;
    height: 100%;
  }

  body[data-page="about"] .about-towel-history__detail-surface {
    background-image: url("../images/generated/about-timeline-story-towel-terry-surface-v5.webp");
    background-size: 103.5% 102.5%;
  }

  body[data-page="about"] .about-towel-history__detail-content {
    height: 100%;
    padding: 9.3% 10.25% 11.25%;
    display: flex;
    flex-direction: column;
  }

  body[data-page="about"] .about-towel-history__detail-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: auto auto;
    column-gap: clamp(0.65rem, 1vw, 1rem);
    align-items: end;
  }

  body[data-page="about"] .about-towel-history__detail-header time {
    grid-column: 2;
    grid-row: 1;
    align-self: center;
    justify-self: end;
    font-size: clamp(0.72rem, 1.28vw, 1.18rem);
  }

  body[data-page="about"] .about-towel-history__detail-rule {
    grid-column: 1 / -1;
    grid-row: 2;
    margin-top: 3.5%;
  }

  body[data-page="about"] .about-towel-history__detail-header h3 {
    grid-column: 1;
    grid-row: 1;
    min-width: 0;
  }

  body[data-page="about"] .about-towel-history__photo {
    height: 46.5%;
    aspect-ratio: auto;
    margin-top: 4.2%;
    flex: 0 0 auto;
    overflow: hidden;
  }

  body[data-page="about"] .about-towel-history__copy {
    min-height: 5.2em;
    margin-top: 1.5%;
    padding-right: 2%;
    font-size: var(--towel-copy-size, clamp(1.04rem, 1.25vw, 1.2rem));
    line-height: 1.42;
  }

}

@media (min-width: 861px) and (max-width: 1100px) {
  body[data-page="about"] .about-towel-history__detail-content {
    padding-top: 10.5%;
  }

  body[data-page="about"] .about-towel-history__photo {
    height: 50%;
    margin-top: 5.5%;
  }

  body[data-page="about"] .about-towel-history__copy {
    margin-top: 5.5%;
  }
}

@media (min-width: 1101px) {
  body[data-page="about"] .about-towel-history__detail-content {
    padding-top: 11%;
  }

  body[data-page="about"] .about-towel-history__detail-rule {
    margin-top: 5%;
  }

  body[data-page="about"] .about-towel-history__photo {
    height: 49%;
    margin-top: 6%;
  }

  body[data-page="about"] .about-towel-history__copy {
    margin-top: 5.5%;
  }
}

@media (max-width: 860px) {
  body[data-page="about"] .about-towel-history {
    padding-top: clamp(2.65rem, 5.7vw, 3.35rem);
    padding-bottom: clamp(3.2rem, 6.7vw, 4.4rem);
  }

  body[data-page="about"] .about-towel-history__title {
    width: min(78vw, 43.75rem);
    margin-bottom: clamp(2rem, 4.8vw, 2.7rem);
    font-size: clamp(2.45rem, 6.15vw, 3.35rem);
  }

  body[data-page="about"] .about-towel-history__stage {
    width: min(70vw, 43.75rem);
  }

  body[data-page="about"] .about-towel-history__item {
    width: 100%;
  }

  body[data-page="about"] .about-towel-history__trigger {
    height: clamp(3.75rem, 9.15vw, 5.75rem);
    grid-template-columns: minmax(0, 1fr) 3.25rem;
  }

  body[data-page="about"] .about-towel-history__year {
    font-size: clamp(1rem, 2.52vw, 1.34rem);
  }

  body[data-page="about"] .about-towel-history__label {
    grid-column: 1;
    padding-top: 0.2rem;
    padding-right: 0.45rem;
    padding-bottom: 0.2rem;
    --towel-trigger-title-max-size: clamp(1.1rem, 3vw, 1.6rem);
    font-size: var(--towel-trigger-title-size, var(--towel-trigger-title-max-size));
  }

  body[data-page="about"] .about-towel-history__arrow {
    grid-column: 2;
    display: grid;
    place-items: center;
    padding-right: 12%;
    font-size: clamp(1.55rem, 3.4vw, 2rem);
    opacity: 0;
    transition: opacity 180ms ease, transform 280ms ease;
  }

  body[data-page="about"] .about-towel-history__item.is-active .about-towel-history__arrow {
    opacity: 1;
    transform: rotate(180deg);
  }

  body[data-page="about"] .about-towel-history__detail {
    width: 100%;
    display: grid;
    grid-template-rows: 0fr;
    opacity: 0;
    transition:
      grid-template-rows 280ms cubic-bezier(0.2, 0.72, 0.2, 1),
      opacity 220ms ease;
  }

  body[data-page="about"] .about-towel-history__item.is-active .about-towel-history__detail {
    grid-template-rows: 1fr;
    opacity: 1;
  }

  body[data-page="about"] .about-towel-history__detail-clip {
    width: 100%;
    overflow: hidden;
  }

  body[data-page="about"] .about-towel-history__detail-surface {
    width: 96%;
    margin-inline: 2%;
    min-height: 0;
    aspect-ratio: auto;
    background-image: url("../images/generated/about-timeline-compact-open-surface-v2.webp");
    background-size: 105.85% 100%;
  }

  body[data-page="about"] .about-towel-history__detail-content {
    height: auto;
    padding: 4.2% 9.1% 11%;
    display: flex;
    flex-direction: column;
  }

  body[data-page="about"] .about-towel-history__detail-header {
    display: flex;
    flex-direction: column;
  }

  body[data-page="about"] .about-towel-history__detail-header time {
    display: none;
  }

  body[data-page="about"] .about-towel-history__detail-rule {
    order: 2;
    width: 100%;
    margin-top: clamp(0.8rem, 2.2vw, 1.15rem);
  }

  body[data-page="about"] .about-towel-history__detail-header h3 {
    order: 1;
    --towel-detail-title-max-size: clamp(2rem, 5.2vw, 2.72rem);
    font-size: var(--towel-detail-title-size, var(--towel-detail-title-max-size));
  }

  body[data-page="about"] .about-towel-history__photo {
    height: calc(min(70vw, 43.75rem) * 0.518);
    min-height: 0;
    aspect-ratio: auto;
    margin-top: clamp(0.9rem, 2.6vw, 1.35rem);
    padding: clamp(0.48rem, 1.25vw, 0.75rem);
    flex: 0 0 auto;
    overflow: hidden;
  }

  body[data-page="about"] .about-towel-history__copy {
    min-height: 4.5em;
    margin-top: 5.9%;
    margin-bottom: clamp(2rem, calc(3rem - 2vw), 2.6rem);
    padding-right: 3%;
    font-size: var(--towel-copy-size, clamp(1.02rem, 2.5vw, 1.28rem));
  }

}

@media (max-width: 620px) {
  body[data-page="about"] .about-towel-history {
    padding-top: 2.35rem;
    padding-bottom: 3.4rem;
  }

  body[data-page="about"] .about-towel-history__title {
    width: min(calc(100% - 2rem), calc(52vw + 10rem));
    margin-bottom: 1.65rem;
    font-size: clamp(2.4rem, 11.5vw, 3rem);
  }

  body[data-page="about"] .about-towel-history__stage {
    width: min(calc(100% - 1.5rem), calc(33vw + 14.4rem));
  }

  body[data-page="about"] .about-towel-history__trigger {
    height: clamp(2.75rem, 12vw, 3.55rem);
    grid-template-columns: minmax(0, 1fr) 2.65rem;
  }

  body[data-page="about"] .about-towel-history__year {
    width: 20%;
    left: 22.5%;
    font-size: clamp(0.78rem, 3.35vw, 0.94rem);
  }

  body[data-page="about"] .about-towel-history__label {
    padding-left: calc(34.5% + clamp(0.35rem, 1.6vw, 0.5rem));
    padding-right: 0.2rem;
    --towel-trigger-title-max-size: clamp(0.8rem, 3.55vw, 1rem);
    font-size: var(--towel-trigger-title-size, var(--towel-trigger-title-max-size));
  }

  body[data-page="about"] .about-towel-history__arrow {
    padding-right: 8%;
    font-size: 1.35rem;
  }

  body[data-page="about"] .about-towel-history__detail-content {
    padding: 6.2% 6.8% 12%;
  }

  body[data-page="about"] .about-towel-history__detail-header h3 {
    --towel-detail-title-max-size: clamp(1.9rem, 8vw, 2.35rem);
    font-size: var(--towel-detail-title-size, var(--towel-detail-title-max-size));
  }

  body[data-page="about"] .about-towel-history__photo {
    height: auto;
    aspect-ratio: 1.34;
    margin-top: 5.5%;
    padding: 0.48rem;
  }

  body[data-page="about"] .about-towel-history__copy {
    min-height: 0;
    margin-top: 6.5%;
    padding-right: 1%;
    font-size: var(--towel-copy-size, 1.06rem);
    line-height: 1.42;
  }
}

@media (prefers-reduced-motion: reduce) {
  body[data-page="about"] .about-towel-history__trigger,
  body[data-page="about"] .about-towel-history__arrow,
  body[data-page="about"] .about-towel-history__detail {
    transition: none;
  }
}
