/**
 * About page sections (Figma Company • Desktop, 32:762).
 *
 * @package Atsko
 */

/* —— Page shell (full-bleed patterns) —— */
.page-main__content
  > *:not(.alignfull):not(.about-spotlight):not(.about-logos):not(.about-cta) {
  max-width: var(--atsko-container, 84rem);
  margin-inline: auto;
  padding-inline: max(2rem, calc((100% - var(--atsko-container)) / 2));
  box-sizing: border-box;
}

/* Override for cart and checkout page */
body.woocommerce-cart .wp-block-woocommerce-cart,
body.woocommerce-checkout .wp-block-woocommerce-checkout {
  padding-top: 24px !important;
  padding-left: 20px !important;
  padding-right: 20px !important;
}

.page-main__content > * {
  margin-block: 0;
}

.page-main__content > .alignfull,
.page-main__content > .about-spotlight,
.page-main__content > .about-logos,
.page-main__content > .about-cta {
  max-width: none;
  width: 100%;
}

/* Break out of .container when About patterns are used on a standard page. */
.container .about-spotlight.alignfull,
.container .about-logos.alignfull,
.container .about-cta.alignfull,
.entry-content .about-spotlight.alignfull,
.entry-content .about-logos.alignfull,
.entry-content .about-cta.alignfull {
  width: 100vw;
  max-width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}

/* —— Full-bleed spotlights —— */
.about-spotlight {
  position: relative;
  overflow: hidden;
  background: var(--atsko-white);
  box-sizing: border-box;
}

.about-spotlight.alignfull {
  width: 100%;
  max-width: none;
}

.about-spotlight--story::before {
  content: "";
  position: absolute;
  z-index: 0;
  pointer-events: none;
  left: -20%;
  bottom: 0;
  width: 70%;
  height: 100%;
  background: url("../images/about/angle-story.svg") no-repeat left center /
    100% 100%;
}

.about-spotlight--make::before {
  content: "";
  position: absolute;
  z-index: 0;
  pointer-events: none;
  right: 0;
  width: 50%;
  height: 100%;
  background-image: url("../images/about/angle-story.svg");
  background-size: 100% 80%;
  background-repeat: no-repeat;
  background-position: bottom right;
}

.about-spotlight__inner {
  position: relative;
  z-index: 1;
  display: flex !important;
  align-items: stretch !important;
  gap: 0 !important;
  margin: 0 !important;
  width: 100%;
}

.about-spotlight__media,
.about-spotlight__copy {
  flex-basis: 50% !important;
  width: 50% !important;
  min-width: 0;
  box-sizing: border-box;
}

.about-spotlight__copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1rem;
  padding: 4.5rem max(2rem, calc((100vw - var(--atsko-container)) / 2 + 2rem))
    4.5rem max(2rem, calc((100vw - var(--atsko-container)) / 2));
}

.about-spotlight--media-right .about-spotlight__copy {
  padding-right: clamp(2rem, 8vw, 10rem);
  padding-left: max(2rem, calc((100vw - var(--atsko-container)) / 2));
}

.about-spotlight--media-left .about-spotlight__copy {
  padding-left: clamp(2rem, 8vw, 10rem);
  padding-right: max(2rem, calc((100vw - var(--atsko-container)) / 2));
}

.about-spotlight__eyebrow {
  margin: 0 !important;
  font-size: 0.875rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  line-height: 1.5 !important;
  color: var(--atsko-orange-bright) !important;
}

.about-spotlight__title {
  margin: 0 !important;
  font-size: clamp(1.75rem, 3vw, 2rem) !important;
  font-weight: 700 !important;
  line-height: 0.9 !important;
  color: var(--atsko-charcoal) !important;
}

.about-spotlight__body {
  margin: 0 !important;
  font-size: 1rem !important;
  line-height: 1.3 !important;
  color: var(--atsko-charcoal) !important;
}

.about-spotlight__media {
  display: flex;
  align-items: stretch;
}

.about-spotlight__figure {
  position: relative;
  margin: 0 !important;
  width: 100%;
  min-height: 31rem;
  overflow: hidden;
  box-shadow: 0 4px 4px rgba(0, 0, 0, 0.25);
  background: var(--atsko-gray-400);
}

.about-spotlight__figure img,
.about-spotlight__bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.about-spotlight__figure .wp-block-image,
.about-spotlight__figure.wp-block-image {
  margin: 0 !important;
  width: 100%;
  height: 100%;
}

.about-spotlight__figure.wp-block-image img,
.about-spotlight__media .wp-block-image {
  margin: 0 !important;
  width: 100%;
  height: 100%;
  min-height: 31rem;
}

.about-spotlight__media .wp-block-image img {
  width: 100%;
  height: 100%;
  min-height: 31rem;
  object-fit: cover;
}

/* Brand logos over mountain media */
.about-spotlight__figure--brands {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.about-spotlight__figure--brands .about-spotlight__bg {
  position: absolute;
  inset: 0;
}

.about-spotlight__brand-logos {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 12rem));
  gap: 1.25rem 2rem;
  margin: 0;
  padding: 2rem;
  list-style: none;
  place-items: center;
}

.about-spotlight__brand-logos li {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 3.5rem;
}

.about-spotlight__brand-logos img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 3.25rem;
  object-fit: contain;
}

.about-spotlight__logo--invert {
  filter: brightness(0) invert(1);
}

.about-spotlight__logo-text {
  font-family: "PT Sans", system-ui, sans-serif;
  font-size: clamp(1.25rem, 2.5vw, 1.85rem);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  text-align: center;
  color: var(--atsko-white);
}

.about-spotlight__brand-logos li:last-child {
  grid-column: 1 / -1;
}

/* —— Logo strip —— */
.about-logos {
  padding: 7.5rem max(2rem, calc((100% - var(--atsko-container)) / 2));
  background: var(--atsko-white);
  box-sizing: border-box;
}

.about-logos.alignfull {
  width: 100%;
  max-width: none;
}

.about-logos__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem 1rem;
  margin: 0 0 0.5rem !important;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--atsko-gray-400);
  width: 100%;
}

.about-logos__row.wp-block-group,
.about-logos__names.wp-block-group {
  max-width: none;
}

.about-logos__item,
.about-logos__row .wp-block-image.about-logos__item {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1 1 6rem;
  min-height: 4rem;
  margin: 0 !important;
}

.about-logos__item img,
.about-logos__row .wp-block-image img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 2.5rem;
  object-fit: contain;
  filter: grayscale(1);
  opacity: 0.75;
}

.about-logos__names {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 3rem;
  margin: 0 !important;
  padding: 0.5rem 0 0;
  width: 100%;
}

.about-logos__name,
.about-logos__names .wp-block-image.about-logos__name {
  margin: 0 !important;
  flex: 0 0 auto;
}

.about-logos__name img,
.about-logos__names .wp-block-image img {
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 1.75rem;
  object-fit: contain;
}

/* —— CTA —— */
.about-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 4.5rem max(2rem, calc((100% - var(--atsko-container)) / 2));
  background: #f5fbff;
  border-top: 4px solid #e8f5ff;
  border-bottom: 4px solid #e8f5ff;
  box-sizing: border-box;
  text-align: center;
}

.about-cta.alignfull {
  width: 100%;
  max-width: none;
}

.about-cta__title {
  margin: 0 !important;
  font-size: clamp(1.75rem, 3vw, 2rem) !important;
  font-weight: 700 !important;
  line-height: 0.9 !important;
  color: var(--atsko-charcoal) !important;
  text-align: center;
}

.about-cta__body {
  margin: 0 auto !important;
  max-width: 40rem;
  font-size: 1rem !important;
  line-height: 1.3 !important;
  color: var(--atsko-charcoal) !important;
  text-align: center;
}

.about-cta__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin: 0.5rem 0 0 !important;
}

.about-cta__actions .atsko-btn {
  margin: 0;
}

@media (max-width: 900px) {
  .about-spotlight__inner {
    flex-direction: column !important;
  }

  .about-spotlight--media-left .about-spotlight__inner {
    flex-direction: column-reverse !important;
  }

  .about-spotlight__media,
  .about-spotlight__copy {
    flex-basis: 100% !important;
    width: 100% !important;
  }

  .about-spotlight__copy,
  .about-spotlight--media-right .about-spotlight__copy,
  .about-spotlight--media-left .about-spotlight__copy {
    padding: 3rem 1.5rem;
  }

  .about-spotlight__figure.wp-block-image img,
  .about-spotlight__media .wp-block-image {
    min-height: 0;
  }
  .about-spotlight--story::before {
    width: 120%;
  }
  .about-spotlight--make::before {
    background-position: top right;
    width: 100%;
  }

  .about-spotlight__brand-logos {
    grid-template-columns: repeat(2, minmax(0, 9rem));
  }

  .about-logos {
    padding: 4rem 1.5rem;
  }

  .about-logos__row {
    justify-content: center;
  }

  .about-logos__item {
    flex: 0 1 40%;
  }
}
