/* =========================
   PAGE: RECETAS (grid)
========================= */
.page-recetas main{
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(280px, 1fr));
  gap:25px;
  padding:40px;
}

.page-recetas .receta{
  background-color:#fff;
  border-radius:15px;
  box-shadow:0 4px 10px rgba(0,0,0,0.1);
  transition:transform 0.3s ease;
  display:flex;
  flex-direction:column;
  height:100%;
}

.page-recetas .receta:hover{
  transform:translateY(-5px);
}

.page-recetas .receta img{
  width:100%;
  height:200px;
  object-fit:cover;
}

.page-recetas .receta-content{
  padding:20px;
  flex-grow:1;
  display:flex;
  flex-direction:column;
  justify-content:space-between;
}

.page-recetas .receta-content h2{
  font-family:'Poppins', sans-serif;
  font-weight:600;
  color:#d32f2f;
  margin-bottom:10px;
  font-size:1.4rem;
}

.page-recetas .receta-content p{
  flex-grow:1;
  color:#333;
  line-height:1.6;
  font-size:0.95rem;
  margin-bottom:15px;
}

.page-recetas .receta-content .btn{
  display:inline-block;
  text-align:center;
  background-color:#d32f2f;
  color:white;
  padding:10px 15px;
  border-radius:8px;
  text-decoration:none;
  font-weight:500;
  transition:background-color 0.3s;
}

.page-recetas .receta-content .btn:hover{
  background-color:#9a0007;
}
/* ===== ASIDE DE RECETA ===== */
.page-recetas aside{
  background-color:#ffd6c2;
  padding:1rem;
  border-radius:10px;
  height:fit-content;
}

.page-recetas aside h3{
  color:#d32f2f;
  margin:0.75rem 0 1rem;
  text-align:center;
}

.page-recetas aside ul{
  list-style:none;
  padding-left:0;
  margin-bottom:1rem;
}

.page-recetas aside ul li{
  margin-bottom:0.8rem;
  font-weight:bold;
}

.page-recetas aside a{
  color:#1f2937; 
  text-decoration:none;
  font-weight:600;
}

.page-recetas aside a:hover{
  text-decoration:underline;
  color:#b71c1c;
}

/* RESPONSIVE ASIDE */
.page-recetas .container{display:flex;gap:2rem;padding:2rem;align-items:flex-start}
.page-recetas main{flex:3;min-width:0}
.page-recetas aside{flex:1;min-width:240px;height:fit-content}

@media (max-width:768px){
  .page-recetas .container{flex-direction:column;padding:1.25rem}
  .page-recetas main,.page-recetas aside{width:100%}
}


/* =========================
   DETALLE DE RECETA
========================= */
.receta-detalle{
  padding:2rem;
  max-width:1200px;
  margin:auto;
  background-color:#fff;
  border-radius:15px;
  box-shadow:0 4px 10px rgba(0,0,0,0.1);
}

.receta-hero{
  display:flex;
  flex-wrap:wrap;
  gap:2rem;
  align-items:center;
}

.receta-img-principal{
  width:100%;
  max-width:500px;
  border-radius:10px;
  object-fit:cover;
  transition:transform 0.3s ease;
}

.receta-hero:hover .receta-img-principal{
  transform:scale(1.02);
}

.receta-info{
  flex:1;
}

.receta-info h2{
  color:#d32f2f;
  font-size:2rem;
  margin-bottom:1rem;
}

.receta-info p{
  color:#333;
  line-height:1.6;
}

.galeria{
  margin-top:2rem;
}

.galeria h3{
  color:#d32f2f;
  margin-bottom:1rem;
}

/* Galería horizontal */
.carrusel{
  display:flex;
  overflow-x:auto;
  gap:15px;
  scroll-snap-type:x mandatory;
  padding-bottom:1rem;
}

.imagen-carrusel{
  position:relative;
  scroll-snap-align:center;
  flex:0 0 auto;
}

.imagen-carrusel img{
  width:300px;
  height:200px;
  border-radius:10px;
  object-fit:cover;
  transition:transform 0.3s ease, filter 0.3s ease;
}

.imagen-carrusel:hover img{
  transform:scale(1.05);
  filter:brightness(0.9);
}

.descripcion-imagen{
  position:absolute;
  bottom:0;
  left:0;
  right:0;
  background:rgba(0,0,0,0.6);
  color:#fff;
  font-size:0.9rem;
  padding:0.5rem;
  text-align:center;
  border-radius:0 0 10px 10px;
  opacity:0;
  transition:opacity 0.3s ease;
}

.imagen-carrusel:hover .descripcion-imagen{
  opacity:1;
}

/* Video */
.receta-video{
  margin-top:2rem;
  text-align:center;
}

.receta-video video{
  width:100%;
  max-width:700px;
  border-radius:10px;
  margin-bottom:1rem;
}

.video-responsive{
  position:relative;
  padding-bottom:56.25%;
  height:0;
  border-radius:10px;
  margin-bottom:1rem;
  box-shadow:0 3px 10px rgba(0,0,0,0.2);
}

.video-responsive iframe{
  position:absolute;
  top:0;
  left:0;
  width:100%;
  height:100%;
  border:none;
}

/* Ingredientes / preparación */
.receta-ingredientes,
.receta-preparacion{
  margin-top:2rem;
}

.receta-ingredientes h3,
.receta-preparacion h3{
  color:#d32f2f;
  margin-bottom:0.8rem;
}

/* Título y separadores */
.receta-detalle h3{
  border-bottom:3px solid #ffe082;
  display:inline-block;
  padding-bottom:0.3rem;
  margin-bottom:1rem;
}

.receta-ingredientes ul,
.receta-preparacion ol{
  margin-left:1.5rem;
  color:#333;
  line-height:1.8;
}

.volver-recetas{
  text-align:center;
  margin-top:3rem;
}

.btn-volver{
  display:inline-block;
  background-color:#d32f2f;
  color:white;
  padding:0.8rem 1.5rem;
  border-radius:8px;
  text-decoration:none;
  font-weight:500;
  transition:background-color 0.3s, transform 0.2s, box-shadow 0.2s;
  box-shadow:0 3px 8px rgba(0,0,0,0.2);
  font-size:1rem;
}

.btn-volver:hover{
  background-color:#9a0007;
  transform:translateY(-2px);
  box-shadow:0 4px 10px rgba(0,0,0,0.3);
}

/* =========================
   RESPONSIVE RECETAS/DETALLE
========================= */
@media (max-width:768px){
  .page-recetas main{
    padding:20px;
    gap:18px;
  }

  .receta-detalle{
    padding:1.25rem;
  }

  .imagen-carrusel img{
    width:260px;
    height:170px;
  }
}