/* Benefit — Landing temporal "Nos estamos renovando"
   Diseño base: Desktop 1600px / Mobile 360px (Figma "Renovación Benefit") */

@font-face {
  font-family: "Poppins";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/poppins-400.woff2") format("woff2");
}
@font-face {
  font-family: "Poppins";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/poppins-500.woff2") format("woff2");
}
@font-face {
  font-family: "Poppins";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("fonts/poppins-700.woff2") format("woff2");
}

:root {
  --green-dark: #032416;
  --green-mid: #48a659;
  --green-highlight: #00c51a;
  --blue-primary: #0039a6;
  --blue-primary-hover: #002d84;
  --gray-900: #1f1f1f;
  --bg: #fbfbfb;
  --white: #ffffff;

  /* Ancho útil del contenido en desktop (1600 - 2 x 160) */
  --content-max: 1280px;
  --gutter: 160px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--gray-900);
  font-family: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
p,
ul {
  margin: 0;
  padding: 0;
}

img {
  display: block;
  max-width: 100%;
}

.only-mobile {
  display: none;
}

/* ---------- Banner ---------- */

.banner {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 484px;
  padding: 48px max(var(--gutter), calc((100% - var(--content-max)) / 2));
  border-bottom-right-radius: 100px;
  overflow: hidden;
  color: var(--white);
  background-color: var(--green-dark);
  background-image:
    linear-gradient(90deg, rgba(3, 36, 22, 0.55) 0%, rgba(72, 166, 89, 0) 55%),
    url("img/banner-desktop.jpg");
  background-size: cover, cover;
  background-position: center, right center;
  background-repeat: no-repeat;
}

.banner__inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
}

.banner__logo {
  width: 185px;
  height: auto;
}

.banner__text {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.banner__title {
  max-width: 578px;
  font-size: 48px;
  font-weight: 700;
  line-height: 64px;
}

.banner__highlight {
  color: var(--green-highlight);
}

.banner__subtitle {
  max-width: 717px;
  font-size: 22px;
  font-weight: 500;
  line-height: 1.5;
}

/* ---------- Sección de canje ---------- */

.redeem {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 44px;
  padding: 32px 0 68px;
}

.redeem__title {
  font-size: 32px;
  font-weight: 500;
  line-height: 48px;
  text-align: center;
  color: var(--gray-900);
}

.cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  width: 100%;
  max-width: calc(var(--content-max) + 2 * var(--gutter));
  padding: 0 var(--gutter);
  list-style: none;
}

.card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: 24px;
  min-height: 366px;
  padding: 24px 36px;
  border-radius: 16px;
  overflow: hidden;
  color: var(--white);
  background-color: #2b2b2b;
  background-size: cover, cover;
  background-position: center, center;
  background-repeat: no-repeat;
}

.card--shopstar {
  background-image:
    linear-gradient(90deg, rgba(0, 0, 0, 0.55) 0%, rgba(102, 102, 102, 0) 70%),
    url("img/card-shopstar.jpg");
}

.card--viajes {
  background-image:
    linear-gradient(90deg, rgba(0, 0, 0, 0.55) 0%, rgba(102, 102, 102, 0) 70%),
    url("img/card-viajes.jpg");
}

.card__icon {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
}

.card__text {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 445px;
}

.card__title {
  font-size: 28px;
  font-weight: 500;
  line-height: 1.5;
}

.card__description {
  font-size: 20px;
  font-weight: 400;
  line-height: 28px;
}

.card__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 326px;
  max-width: 100%;
  min-height: 56px;
  padding: 16px 24px;
  border-radius: 80px;
  background: var(--blue-primary);
  color: var(--white);
  font-size: 16px;
  font-weight: 500;
  line-height: 24px;
  text-align: center;
  text-decoration: none;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.card__button:hover {
  background: var(--blue-primary-hover);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.card__button:focus-visible {
  outline: 3px solid var(--white);
  outline-offset: 3px;
}

/* ---------- Pantallas intermedias (laptop / tablet) ---------- */

@media (max-width: 1439.98px) {
  :root {
    --gutter: clamp(24px, 6vw, 96px);
  }

  .banner {
    min-height: 420px;
    border-bottom-right-radius: 80px;
    background-image:
      linear-gradient(90deg, rgba(3, 36, 22, 0.7) 0%, rgba(3, 36, 22, 0.35) 45%, rgba(72, 166, 89, 0) 65%),
      url("img/banner-desktop.jpg");
    background-position: center, right center;
  }

  .banner__title {
    max-width: 500px;
    font-size: 42px;
    line-height: 56px;
  }

  .banner__subtitle {
    max-width: 560px;
    font-size: 20px;
  }

  .card {
    padding: 24px 28px;
  }

  .card__title {
    font-size: 24px;
  }

  .card__description {
    font-size: 18px;
    line-height: 26px;
  }
}

@media (max-width: 1023.98px) {
  .banner {
    min-height: 380px;
    border-bottom-right-radius: 64px;
    background-image:
      linear-gradient(90deg, rgba(3, 36, 22, 0.8) 0%, rgba(3, 36, 22, 0.45) 45%, rgba(72, 166, 89, 0) 70%),
      url("img/banner-desktop.jpg");
    background-position: center, right center;
  }

  .banner__title {
    max-width: 420px;
    font-size: 36px;
    line-height: 48px;
  }

  .banner__subtitle {
    max-width: 420px;
    font-size: 18px;
  }

  .banner__subtitle br {
    display: none;
  }

  .redeem__title {
    font-size: 28px;
    line-height: 40px;
  }

  .redeem {
    gap: 32px;
  }

  .cards {
    gap: 20px;
  }

  .card {
    min-height: 320px;
    padding: 24px;
    gap: 20px;
  }

  .card__text {
    gap: 12px;
  }

  .card__title {
    font-size: 22px;
  }

  .card__description {
    font-size: 16px;
    line-height: 24px;
  }

  .card__button {
    width: 100%;
    font-size: 15px;
  }
}

/* ---------- Mobile (diseño base 360px) ---------- */

@media (max-width: 767.98px) {
  .only-desktop {
    display: none;
  }

  .only-mobile {
    display: inline;
  }

  .banner {
    align-items: stretch;
    min-height: 270px;
    padding: 40px 16px;
    border-bottom-right-radius: 50px;
    background-image:
      linear-gradient(180deg, rgba(3, 36, 22, 0.15) 0%, rgba(72, 166, 89, 0) 100%),
      url("img/banner-mobile.jpg");
    background-position: center, center bottom;
  }

  .banner__inner {
    flex: 1;
    justify-content: space-between;
    align-items: stretch;
    gap: 20px;
  }

  .banner__logo {
    align-self: center;
    width: 136px;
  }

  .banner__text {
    gap: 8px;
  }

  .banner__title {
    max-width: 328px;
    font-size: 28px;
    line-height: 32px;
  }

  .banner__subtitle {
    max-width: 328px;
    font-size: 15px;
    line-height: 1.5;
  }

  .redeem {
    gap: 16px;
    padding: 28px 0 36px;
  }

  .redeem__title {
    font-size: 20px;
    line-height: 30px;
  }

  /* Carrusel horizontal */
  .cards {
    display: flex;
    gap: 12px;
    max-width: none;
    padding: 0 16px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 16px;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .cards::-webkit-scrollbar {
    display: none;
  }

  .card {
    flex: 0 0 228px;
    justify-content: flex-start;
    gap: 12px;
    min-height: 248px;
    padding: 20px 12px;
    scroll-snap-align: start;
  }

  .card--shopstar,
  .card--viajes {
    background-position: center, 65% center;
  }

  .card__text {
    gap: 0;
  }

  .card__title {
    font-size: 18px;
    line-height: 24px;
  }

  .card__description {
    font-size: 15px;
    line-height: 22px;
  }

  .card__button {
    width: 100%;
    min-height: 48px;
    margin-top: auto;
    padding: 12px 8px;
    white-space: nowrap;
    font-size: 14px;
    line-height: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .card__button {
    transition: none;
  }
}
