/**
 * ======================================================
 * ALL-RECIPES.CSS — Styles de la page /recipes-movie/
 * ======================================================
 * Chargé après movies.css + recipes-movie.css :
 *  - movies.css fournit : hero-stat, qtag, films-toolbar, tb-*, fcard--cta
 *  - recipes-movie.css fournit : recipe-card, badge, rating, author…
 */

/* ── FULL-BLEED ── */
body.all-recipes-page {
  max-width: unset;
  padding-left: 0;
  padding-right: 0;
  padding-top: 0;
}
body.all-recipes-page main {
  padding-top: var(--nav-h);
}

/* ══════════════════════════════════════════
   HERO — styles hérités de movies.css via .page-hero*
   Surcharges minimales spécifiques à cette page
══════════════════════════════════════════ */

/* Info de résultat de recherche */
.ar-search-info {
  margin-top: 10px;
  font-size: 0.75rem;
  color: rgba(232, 232, 232, 0.45);
}
.ar-search-info strong { color: rgba(232, 232, 232, 0.75); }
.ar-search-info a { color: rgba(196, 160, 82, 0.65); text-decoration: underline; }
.ar-search-info a:hover { color: var(--or-titre); }

/* ══════════════════════════════════════════
   TOOLBAR — tri supprimé : ar-sort-select
   → remplacé par .dropdown + .dd-filter-wrap (base.css)
══════════════════════════════════════════ */

/* ══════════════════════════════════════════
   SECTION + GRILLE
══════════════════════════════════════════ */
.ar-section {
  padding-bottom: 80px;
  overflow-x: hidden;
}

/* Wrapper — conteneur pleine largeur */
.ar-grid-wrap {
  width: min(var(--cd-max, 1440px), 100% - 2 * var(--cd-px, 2rem));
  margin: 0 auto;
  box-sizing: border-box;
  padding: 8px 0 80px; /* padding-top : espace pour translateY(-6px) hover sans clipping */
  overflow-x: clip;    /* clip ne crée pas de BFC → overflow-y reste visible */
}

/* Grille 4 colonnes — largeur contrôlée par .ar-grid-wrap */
/* (1440 − 3×16) / 4 = 348px par carte */
.all-recipes-page .recipes-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

/* ══════════════════════════════════════════
   AR-RECIPE-CARD — Carte compacte ~350×300px
   Classe indépendante de .recipe-card
══════════════════════════════════════════ */
.ar-recipe-card {
  background: linear-gradient(150deg, var(--surface-card, #0d1b2e) 0%, var(--bleu-nuit, #08101a) 100%);
  border: 1.5px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4), 0 8px 30px rgba(0, 2, 12, 0.5);
}

.ar-recipe-card::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(196, 160, 82, 0.55) 35%, rgba(196, 160, 82, 0.7) 55%, rgba(196, 160, 82, 0.55) 75%, transparent);
  opacity: 0;
  transition: opacity 0.3s;
  border-radius: 0 0 10px 10px;
  pointer-events: none;
  z-index: 2;
}

.ar-recipe-card:hover {
  transform: translateY(-6px);
  border-color: rgba(196, 160, 82, 0.35);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3), 0 20px 50px rgba(196, 160, 82, 0.14);
}

.ar-recipe-card:hover::after { opacity: 1; }

/* Image 16:9 */
.ar-recipe-card__img {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bleu-nuit, #08101a);
}

.ar-recipe-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.ar-recipe-card:hover .ar-recipe-card__img img { transform: scale(2); }

.ar-recipe-card__img::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 40%;
  background: linear-gradient(to bottom, transparent, rgba(10, 17, 28, 0.75));
  pointer-events: none;
  z-index: 1;
}

/* Overlay top : badge catégorie + favori */
.ar-recipe-card__ot {
  position: absolute;
  top: 0.5rem; left: 0.5rem; right: 0.5rem;
  display: flex; justify-content: space-between; align-items: flex-start;
  z-index: 5;
}

/* Badge film bas */
.ar-recipe-card__ob {
  position: absolute;
  bottom: 0.4rem; left: 0.5rem; right: 0.5rem;
  display: flex;
  z-index: 3;
}

.ar-recipe-card__ob .badge--film-dk {
  text-decoration: none;
  transition: opacity 0.2s;
}
.ar-recipe-card__ob .badge--film-dk:hover { opacity: 0.8; }

/* Corps de la carte */
.ar-recipe-card__body {
  padding-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
  overflow: hidden;
}

/* Titre + temps inline */
.ar-recipe-card__title-row {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.6rem;
}

/* Titre 2 lignes max */
.ar-recipe-card__title {
  font-size: 0.83rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--or-titre);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
  flex: 1;
  min-width: 0;
}

.ar-badge-new {
  flex-shrink: 0;
  font-size: 0.68rem;
  padding: 0.18rem 0.38rem;
  border-radius: 4px;
  line-height: 1.2;
}

/* Séparateur doré avant footer */
.ar-recipe-card__sep {
  height: 1px;
  background: linear-gradient(90deg, rgba(196,160,82,.18), rgba(196,160,82,.08) 60%, transparent);
  margin-bottom: 0.6rem;
}

/* Méta : difficulté + nouveau + durée */
.ar-recipe-card__meta {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* Tags de difficulté plus petits dans les cards compactes */
.ar-recipe-card .tag {
  font-size: 0.6rem;
  padding: 0.16rem 0.48rem;
  letter-spacing: 0.9px;
}

.ar-recipe-card__time {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 0.68rem;
  color: rgba(232, 232, 232, 0.5);
  margin-left: auto;
}

.ar-recipe-card__time .icon { width: 0.7rem; height: 0.7rem; }

/* Stretched link */
.ar-recipe-card__link {
  position: absolute; inset: 0; z-index: 1;
  border-radius: inherit;
}

/* Overlay doré + icône */
.ar-recipe-card:hover .cd-hover-overlay { opacity: 1; }
.ar-recipe-card:hover .cd-icon-btn { transform: translateY(0) scale(1); opacity: 1; }
.ar-recipe-card:hover .cd-icon-btn__ring { border-color: rgba(242,200,75,.9); transform: rotate(60deg); }
.ar-recipe-card:hover .cd-icon-btn__bg { box-shadow: 0 6px 28px rgba(184,136,42,.65); filter: brightness(1.08); }
.ar-recipe-card:hover .cd-icon-btn__bg svg { transform: scale(1.15) translateY(-1px); }
.ar-recipe-card:hover .cd-icon-btn__wrap { animation: cdIconFloat 2.2s ease-in-out infinite; }
.ar-recipe-card:hover .cd-icon-btn__bg::after { animation: cdPulse 1.9s ease-out infinite; }

/* Footer : auteur + favori — sibling du body, reste visible au hover */
.ar-recipe-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative; z-index: 4;
  gap: 6px;
  margin-top: auto;
  padding: 0.45rem 0.65rem 0.55rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}


.ar-recipe-card__foot .btn-fav { flex-shrink: 0; }

.ar-recipe-card__foot .btn--sm {
  padding: 0 10px;
  height: 26px;
  font-size: 0.65rem;
  flex-shrink: 0;
}

/* Masquage "voir plus" — nouvelle classe */
.recipes-grid.only__display__9__recipes .recipe-card:nth-child(n + 10) {
  display: none;
}

/* fcard--cta hors grille — largeur contrôlée par .ar-grid-wrap */
.all-recipes-page .fcard.fcard--cta {
  grid-column: unset;
  margin: 56px 0 80px;
}

/* Bouton "Voir plus" — centré dans .ar-grid-wrap */
.all-recipes-page .center-button {
  text-align: center;
}

/* Message vide */
.ar-empty {
  text-align: center;
  padding: 80px 20px;
  font-family: var(--f-title); font-size: 0.8rem; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: rgba(232, 232, 232, 0.25);
}

/* ══════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════ */
@media (max-width: 1200px) {
  .all-recipes-page .recipes-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 860px) {
  .all-recipes-page .recipes-grid { grid-template-columns: repeat(2, 1fr); }
  .ar-grid-wrap { padding-left: 16px; padding-right: 16px; }
}

@media (max-width: 540px) {
  .all-recipes-page .recipes-grid { grid-template-columns: 1fr; }
  .ar-recipe-card__title { font-size: 0.9rem; }
  .ar-recipe-card__time  { font-size: 0.72rem; }
}
