/*
 * Apuseni Mountains Trail — responsive tour banner
 * --------------------------------------------------------------------------
 * Loaded after site.css.
 *
 * Desktop:
 * - rectangular, almost-full-viewport photographic banner
 * - small gap below the site header
 * - text sits over a cream-to-transparent fade
 * - the tour facts begin immediately after the first-screen banner
 *
 * Mobile:
 * - photograph becomes its own block
 * - text moves below the photograph
 * - no text overlay or horizontal fade
 */

:root {
  --tour-banner-header-height: 78px;
}

/* --------------------------------------------------------------------------
   Desktop banner
   -------------------------------------------------------------------------- */

.tour-banner {
  position: relative;
  isolation: isolate;

  height:
    calc(
      100svh
      - var(--tour-banner-header-height)
    );

  min-height: 560px;
  max-height: 820px;

  margin-top: 0;
  padding: 0;

  overflow: hidden;

  background: var(--paper, #f6f2e8);
  border-radius: 0;
}

.tour-banner-media {
  position: absolute;
  inset: 0;

  z-index: 0;

  overflow: hidden;
  border-radius: 0;
}

.tour-banner-media img {
  display: block;

  width: 100%;
  height: 100%;

  object-fit: cover;
  object-position: 65% 1%;

  border-radius: 0;
  box-shadow: none;
}

/*
 * Override older generic .tour-hero image rules from site.css.
 */
.tour-hero.tour-banner .tour-banner-media img {
  border-radius: 0;
  box-shadow: none;
}

/*
 * Cream fade:
 * solid behind the copy on the left, transparent over the image on the right.
 */
.tour-banner::after {
  content: "";

  position: absolute;
  inset: 0;

  z-index: 1;

  pointer-events: none;

  background:
    linear-gradient(
      90deg,
      rgba(246, 242, 232, 1) 0%,
      rgba(246, 242, 232, 0.99) 19%,
      rgba(246, 242, 232, 0.95) 29%,
      rgba(246, 242, 232, 0.82) 39%,
      rgba(246, 242, 232, 0.55) 49%,
      rgba(246, 242, 232, 0.22) 61%,
      rgba(246, 242, 232, 0.05) 70%,
      rgba(246, 242, 232, 0) 78%
    );
}

.tour-banner-content {
  position: relative;
  z-index: 2;
  top: -35px;

  display: flex;
  align-items: center;

  height: 100%;

  padding-top: clamp(2rem, 5vh, 4rem);
  padding-bottom: clamp(2rem, 5vh, 4rem);
}

.about-banner .tour-banner-content {
  align-items: flex-start;
  /* padding-top: clamp(4rem, 9vh, 7rem); */
}

.tour-banner-copy .button-row {
  margin-top: 2rem;
}

/* About page banner image framing */

.about-banner .tour-banner-media img {
  width: 80%;
  margin-left: auto;

  object-fit: cover;
  object-position: center 25%;
}

.owner-card {
  position: relative;

  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2rem;
  align-items: center;

  padding: 2rem 2.5rem;

  background: #fbf5ed;
  border-left: 4px solid var(--accent);
  border-radius: 0 1rem 1rem 0;
}

.owner-card-copy {
  max-width: 680px;
}

.owner-card-copy h2 {
  margin-bottom: 0.25rem;
}

.owner-role {
  margin-top: 0;
  font-weight: 700;
}

.owner-organisation {
  margin-bottom: 0;
  font-weight: 700;
}

.owner-portrait {
  width: 170px;
  height: 170px;

  object-fit: cover;
  object-position: center;

  border-radius: 50%;
}

/* --------------------------------------------------------------------------
   Medium desktop / tablet
   -------------------------------------------------------------------------- */

@media (max-width: 1000px) {
  :root {
    --tour-banner-header-height: 74px;
  }

  .tour-banner {
    min-height: 540px;
  }

  .tour-banner-copy {
    width: min(500px, 52%);
  }

  .tour-banner-media img {
    object-position: 62% 56%;
  }

  .tour-banner::after {
    background:
      linear-gradient(
        90deg,
        rgba(246, 242, 232, 1) 0%,
        rgba(246, 242, 232, 0.98) 29%,
        rgba(246, 242, 232, 0.88) 42%,
        rgba(246, 242, 232, 0.58) 57%,
        rgba(246, 242, 232, 0.18) 76%,
        rgba(246, 242, 232, 0.03) 100%
      );
  }
}

/* --------------------------------------------------------------------------
   Mobile
   -------------------------------------------------------------------------- */

@media (max-width: 700px) {
  .tour-banner {
    display: flex;
    flex-direction: column;

    height: auto;
    min-height: 0;
    max-height: none;

    overflow: visible;
  }

  .tour-banner-media {
    position: relative;
    inset: auto;

    order: 1;

    width: 100%;
    height: 44svh;
    min-height: 300px;
    max-height: 430px;
  }

  .tour-banner-media img {
    width: 100%;
    height: 100%;

    object-fit: cover;
    object-position: center 55%;

    border-radius: 0;
  }

  .about-banner .tour-banner-media img {
    width: 100%;
    margin-left: 0;
    object-position: center 45%;
  }

  .tour-banner::after {
    display: none;
  }

  .tour-banner-content {
    order: 2;

    display: block;

    /* width: 100%; */
    height: auto;

    padding-top: 2rem;
    padding-bottom: 2.75rem;
  }

  .tour-banner-copy {
    width: 100%;
    max-width: 100%;
  }

  .tour-banner-copy h1 {
    max-width: 100%;
  }

  .tour-banner-copy .lead {
    max-width: 100%;
  }

  .tour-banner-copy .button-row {
    margin-top: 1.5rem;
  }

    .owner-card {
    grid-template-columns: 1fr;
    padding: 1.75rem;
  }

  .owner-portrait {
    width: 120px;
    height: 120px;

    order: -1;
  }
}

/* --------------------------------------------------------------------------
   Small mobile
   -------------------------------------------------------------------------- */

@media (max-width: 480px) {
  .tour-banner-media {
    height: 40svh;
    min-height: 270px;
  }

  .tour-banner-content {
    padding-top: 3.5rem;
    padding-bottom: 2.25rem;
  }

  .tour-banner-copy .button-row {
    align-items: stretch;
  }

  .tour-banner-copy .button {
    width: 100%;
    text-align: center;
  }
}