/*
 * Home section "Découvre nos offres". Measurements from the Figma frame (1440px wide):
 * cards 411 × 581 at x 204 and x 854, collages 386 × 276, buttons 360 × 68.
 * Inside a card every size is expressed in cqi (1cqi = 1% of the card width, 411px in Figma)
 * so the whole composition scales together without distorting the collages.
 */
/* Overlaps the previous section by 1px: its fluid height can leave a hairline of page background. */
.offers {
  position: relative;
  margin-top: -1px;
  padding: 9px clamp(20px, 5vw, 72px) 64px;
  overflow-x: clip;
  background-color: var(--color-olive-deep);
  color: var(--color-white);
}

.offers__header {
  text-align: center;
}

.offers__title {
  font-size: clamp(1.625rem, 7.6vw, 4.1875rem);
  font-weight: 400;
  line-height: 1.2;
  white-space: nowrap;
}

/* In Figma the script D is drawn about twice as large as the rest of the title. */
.offers__title-initial {
  font-family: var(--font-script);
  font-size: 1.9em;
  font-weight: 700;
  line-height: 1.1;
}

.offers__title-accent {
  font-family: var(--font-serif);
  font-size: 1.333em;
  line-height: 1;
}

.offers__subtitle {
  margin-top: 0.1em;
  font-size: clamp(1.125rem, 1.94vw, 1.75rem);
  font-weight: 300;
}

.offers__list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 411px));
  justify-content: center;
  column-gap: clamp(24px, calc(33vw - 236px), 239px);
  row-gap: 40px;
  margin-top: clamp(32px, 3.75vw, 54px);
}

.offers__item {
  container-type: inline-size;
}

/* Card */
.offer-card {
  --card-bg: rgb(45 22 6 / 40%);
  --card-accent: var(--color-brown);
  --card-ink: var(--color-white);
  --card-ink-soft: var(--color-cream);
  --tab-ink: var(--color-cream);
  --collage-shift: -4cqi;
  --text-gap: 1.4cqi;
  --text-width: 65cqi;

  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  padding-bottom: 5.3cqi;
  overflow: hidden;
  border: 1.3cqi solid var(--card-accent);
  border-radius: 5.26cqi;
  background-color: var(--card-bg);
  color: var(--card-ink);
  text-align: center;
  transition:
    transform var(--duration-base) var(--ease-out),
    box-shadow var(--duration-base) var(--ease-out);
}

.offer-card--business {
  --card-bg: rgb(248 245 239 / 40%);
  --card-accent: var(--color-cream);
  --card-ink: var(--color-brown);
  --card-ink-soft: var(--color-brown);
  --tab-ink: var(--color-brown);
  --collage-shift: 0.75cqi;
  --text-gap: -1.4cqi;
  --text-width: 71cqi;
}

.offer-card__tab {
  align-self: stretch;
  margin: -1.3cqi -1.3cqi 0;
  padding: 0.6cqi 4cqi 1cqi;
  background-color: var(--card-accent);
  color: var(--tab-ink);
  font-size: max(0.9375rem, 5.26cqi);
  font-weight: 600;
  line-height: 1.3;
}

.offer-card__title {
  margin-top: 6.1cqi;
  font-size: max(1.75rem, 9.98cqi);
  font-weight: 600;
  line-height: 1.36;
}

.offer-card__tagline {
  font-size: max(0.875rem, 3.95cqi);
  font-weight: 300;
  line-height: 1.36;
}

.offer-card__collage {
  width: 93.8cqi;
  max-width: none;
  margin-top: var(--collage-shift);
}

.offer-card__text {
  max-width: var(--text-width);
  min-height: 19.5cqi;
  margin: var(--text-gap) 0 0.6cqi;
  color: var(--card-ink-soft);
  font-size: max(0.9375rem, 3.95cqi);
  font-weight: 300;
  line-height: 1.36;
}

.offer-card__button {
  --btn-bg: var(--card-accent);
  --btn-color: var(--color-cream);
  --btn-border: var(--card-accent);
  --btn-focus: var(--color-cream);

  width: 87.5cqi;
  min-height: 44px;
  margin-top: auto;
  padding: 3.8cqi 4cqi;
  font-size: max(1.0625rem, 6.58cqi);
}

.offer-card--business .offer-card__button {
  --btn-color: var(--color-brown);
  --btn-focus: var(--color-brown);
  --btn-hover-mix: var(--color-brown);
}

@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .offer-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 40px rgb(0 0 0 / 28%);
  }
}

/*
 * Phones: a serif title without the script D, and both offers side by side as compact cards
 * (tab, name, collage and button); the full details live on the services page.
 */
@media (max-width: 719.98px) {
  .offers {
    padding: 40px clamp(14px, 4vw, 20px) 52px;
  }

  .offers__title {
    font-family: var(--font-serif);
    font-size: clamp(2.125rem, 10.5vw, 2.875rem);
    font-weight: 500;
    line-height: 1.1;
    white-space: normal;
    text-wrap: balance;
  }

  .offers__title-initial {
    font: inherit;
  }

  .offers__title-accent {
    font-size: 1.08em;
    font-style: italic;
    color: var(--color-cream);
  }

  .offers__subtitle {
    margin-top: 12px;
    font-size: clamp(1rem, 4.4vw, 1.1875rem);
    letter-spacing: 0.02em;
  }

  .offers__list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: clamp(10px, 3vw, 14px);
    margin-top: 28px;
  }

  .offer-card {
    padding-bottom: 14px;
    border-width: 2px;
    border-radius: 18px;
  }

  .offer-card__tab {
    margin: -2px -2px 0;
    padding: 7px 8px 8px;
    font-size: clamp(0.8125rem, 3.6vw, 0.9375rem);
    line-height: 1.25;
    text-wrap: balance;
  }

  .offer-card__title {
    margin-top: 12px;
    padding-inline: 8px;
    font-size: clamp(1.25rem, 6vw, 1.625rem);
    line-height: 1.15;
  }

  .offer-card__tagline,
  .offer-card__text {
    display: none;
  }

  .offer-card__collage {
    width: 100%;
    margin: 8px 0 14px;
  }

  .offer-card__button {
    width: calc(100% - 20px);
    padding: 10px 12px;
    font-size: clamp(0.9375rem, 4.2vw, 1.0625rem);
  }

  .offer-card__button-more {
    display: none;
  }
}
