/* Cartes comparateur — desktop bandeau + mobile 3 colonnes */

@keyframes offer-cta-shimmer {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.offer-card {
  display: block;
  grid-template-columns: none;
}

.rankings .offer-card {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  margin-bottom: 0.5rem;
  width: 100%;
  max-width: 100%;
}

.rankings .offer-card:hover {
  transform: none !important;
}

.offer-card {
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.22);
  background: #f8f7fc;
  color: #1e1b2e;
}

.offer-card--featured {
  box-shadow: 0 0 0 1px rgba(201, 162, 39, 0.55), 0 8px 24px rgba(0, 0, 0, 0.28);
}

.offer-card__main {
  display: grid;
  align-items: stretch;
  width: 100%;
}

.offer-mobile-bonus,
.offer-mobile-cta {
  display: none;
}

.offer-card__review {
  display: none;
}

.offer-card__terms {
  display: none;
}

.rankings .offer-card__brand {
  min-height: 0 !important;
  gap: 0.2rem !important;
}

.rankings .offer-logo-box {
  width: 100% !important;
  max-width: 100% !important;
  min-height: 0 !important;
  flex: 0 0 auto !important;
  padding: 0.25rem 0.4rem !important;
  background: rgba(255, 255, 255, 0.1) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: 6px !important;
  box-shadow: none !important;
}

.rankings .offer-logo-box img {
  width: auto !important;
  max-width: 100% !important;
  max-height: 42px !important;
  min-height: 0 !important;
  object-fit: contain !important;
  margin: 0 auto;
  display: block;
}

.rankings .offer-logo--wide {
  max-height: 44px !important;
}

.rankings .offer-logo--parions {
  max-height: 40px !important;
}

.rankings .offer-logo--winamax {
  max-height: 36px !important;
}

/* —— Desktop —— */
@media (min-width: 900px) {
  .rankings .container {
    width: min(900px, 78vw);
  }

  .offer-card__main {
    grid-template-columns: 120px 62px minmax(96px, 0.75fr) minmax(0, 1fr) 96px;
    min-height: 92px;
  }

  .offer-card__brand {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-end;
    padding: 1.35rem 0.35rem 0.55rem;
    min-height: 0;
    background: linear-gradient(165deg, #2d2640 0%, #1a1628 100%);
    border-right: 1px solid #e4e0ec;
  }

  .rankings .offer-card__brand .offer-logo-box {
    max-height: 52px;
  }

  .rankings .offer-card__brand .offer-logo-box img {
    max-height: 44px !important;
  }

  .offer-ribbon {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 2;
    font-size: 0.52rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding: 0.28rem 0.45rem;
    color: #fff;
    background: linear-gradient(120deg, #c9a227, #a67c00);
    clip-path: polygon(0 0, 100% 0, 94% 100%, 0 100%);
    max-width: 92%;
  }

  .offer-rank,
  .offer-meta-mobile,
  .offer-mobile-bonus,
  .offer-mobile-cta {
    display: none !important;
  }

  .offer-card__score-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0.45rem 0.2rem;
    border-right: 1px solid #e4e0ec;
    background: #fff;
  }

  .score-label {
    font-size: 0.58rem;
    color: #6b6578;
    margin: 0 0 0.1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
  }

  .offer-card__score-col .score {
    font-size: 1.4rem;
    font-weight: 800;
    color: #4f46e5;
    line-height: 1;
  }

  .offer-card__review {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 0.15rem;
    padding: 0.35rem 0.5rem;
    border-right: 1px solid #e4e0ec;
    background: #fff;
  }

  .offer-card__review .stars {
    color: #d4a017;
    font-size: 0.82rem;
    letter-spacing: 1px;
  }

  .offer-views {
    font-size: 0.62rem;
    color: #6b6578;
    margin: 0;
  }

  .offer-review-link {
    font-size: 0.68rem;
    font-weight: 600;
    color: #5b21b6;
    text-decoration: underline;
  }

  .offer-card__detail {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0.5rem 0.55rem;
    border-right: 1px solid #e4e0ec;
    background: #faf9fd;
  }

  .offer-welcome {
    font-size: 0.58rem;
    color: #6b6578;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0 0 0.15rem;
  }

  .offer-name {
    display: none;
  }

  .offer-bonus {
    margin: 0;
    font-size: 0.82rem;
    font-weight: 700;
    line-height: 1.3;
    color: #1e1b2e;
  }

  .offer-card__action {
    display: flex;
    align-items: stretch;
    justify-content: center;
    padding: 0.25rem;
    background: #ebe8f2;
  }

  .offer-card__action .btn-cta {
    width: 100%;
    align-self: stretch;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 0.5rem 0.35rem;
    border-radius: 8px;
    color: #1a1020;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    line-height: 1.2;
    background: linear-gradient(120deg, #fcd34d, #f97316, #ec4899, #a855f7, #fcd34d);
    background-size: 300% 100%;
    animation: offer-cta-shimmer 4.5s ease infinite;
    box-shadow: 0 4px 14px rgba(249, 115, 22, 0.35);
  }

  .offer-card__action .btn-cta:hover {
    transform: scale(1.03);
    color: #0f0a14;
  }

  .offer-card__terms {
    display: block;
    margin: 0;
    padding: 0.35rem 0.55rem;
    font-size: 0.55rem;
    line-height: 1.35;
    color: rgba(255, 255, 255, 0.9);
    background: #2a2638;
    text-align: center;
  }

  .offer-disclaimer {
    display: none;
  }
}

/* —— Mobile —— */
@media (max-width: 899px) {
  .rankings .container {
    padding-inline: 0.65rem;
    width: 100%;
    max-width: 100%;
  }

  .offer-card {
    width: 100%;
    max-width: 100%;
    margin-bottom: 0.35rem;
  }

  .offer-card__main {
    display: grid;
    grid-template-columns: minmax(0, 36%) minmax(0, 1fr) minmax(68px, 24%);
    grid-template-rows: 1fr;
    align-items: stretch;
    width: 100%;
    min-height: 104px;
    max-height: none;
  }

  .offer-card__brand {
    grid-column: 1;
    grid-row: 1;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: stretch;
    gap: 0.15rem;
    min-height: 0 !important;
    padding: 0.85rem 0.35rem 0.35rem;
    background: linear-gradient(160deg, #3d3548 0%, #252030 100%);
    border-right: 2px solid #c9a227;
  }

  .offer-ribbon {
    position: absolute;
    top: 3px;
    left: 3px;
    font-size: 0.45rem;
    padding: 0.12rem 0.3rem;
    border-radius: 3px;
    background: linear-gradient(120deg, #d4a017, #b8860b);
    color: #fff;
    font-weight: 800;
    text-transform: uppercase;
    max-width: 90%;
    line-height: 1.15;
  }

  .rankings .offer-card__brand .offer-logo-box {
    max-height: 42px;
    min-height: 0 !important;
    padding: 0.15rem 0.25rem !important;
  }

  .rankings .offer-card__brand .offer-logo-box img {
    max-height: 32px !important;
    min-height: 0 !important;
  }

  .offer-meta-mobile {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.15rem;
    width: 100%;
    font-size: 0.55rem;
    flex-shrink: 0;
    color: #f5e6c8;
  }

  .offer-meta-mobile .stars {
    color: #fbbf24;
    font-size: 0.6rem;
  }

  .score--mobile {
    font-weight: 800;
    color: #fff;
  }

  .offer-card__score-col,
  .offer-card__review,
  .offer-card__detail,
  .offer-card__action {
    display: none !important;
  }

  .offer-card__review {
    display: none !important;
  }

  .offer-mobile-bonus {
    display: flex !important;
    grid-column: 2;
    grid-row: 1;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding: 0.3rem 0.35rem;
    border-right: 2px solid #c9a227;
    background: linear-gradient(90deg, #2a2638, #322e42);
    color: #f0ebe3;
    min-width: 0;
  }

  .offer-mobile-bonus .offer-welcome {
    font-size: 0.5rem;
    font-weight: 800;
    color: #d4a574;
    margin: 0 0 0.1rem;
    letter-spacing: 0.07em;
  }

  .offer-mobile-bonus .offer-bonus {
    font-size: 0.68rem;
    font-weight: 800;
    line-height: 1.2;
    margin: 0;
    color: #fde68a;
  }

  .offer-mobile-bonus .offer-bonus-sub {
    font-size: 0.52rem;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 0.15rem;
    line-height: 1.2;
  }

  .offer-mobile-cta {
    display: flex !important;
    grid-column: 3;
    grid-row: 1;
    align-items: stretch;
    justify-content: stretch;
    padding: 0.15rem;
    min-width: 0;
    background: linear-gradient(180deg, #3d3548, #252030);
  }

  .offer-mobile-cta .btn-cta {
    width: 100%;
    min-height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    padding: 0.5rem 0.35rem;
    border-radius: 8px;
    color: #1a1020;
    line-height: 1.1;
    text-align: center;
    background: linear-gradient(120deg, #fcd34d, #f97316, #ec4899, #fcd34d);
    background-size: 280% 100%;
    animation: offer-cta-shimmer 4s ease infinite;
    box-shadow: 0 3px 12px rgba(249, 115, 22, 0.45);
  }

  .score--mobile {
    display: inline !important;
  }

  .offer-card__terms {
    display: none;
  }

  .offer-disclaimer {
    display: block;
    font-size: 0.52rem;
    color: var(--text-muted);
    margin: 0 0 0.28rem;
    text-align: center;
    line-height: 1.25;
    padding: 0 0.15rem;
  }
}
