/* ui-grid-pages.css — grid-only components
   Purpose: reusable grids (recipes/videos, simple card grids)
   Scope: body.ui-scope
*/

/* ============================
   Recipes / Videos grid
============================ */
body.ui-scope .ui-recipes-head{
  margin: 0 0 12px;
}

body.ui-scope .ui-recipes-grid{
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
}

/* Card */
body.ui-scope .ui-recipes-card{
  display: block;
  text-decoration: none;
  color: inherit;

  border: 1px solid rgba(255,255,255,.10);
  background: rgba(255,255,255,.02);
  border-radius: 18px;
  padding: 12px;

  transition: transform .12s ease, border-color .15s ease, background-color .15s ease;
}

body.ui-scope .ui-recipes-card:hover{
  transform: translateY(-1px);
  border-color: rgba(255,255,255,.18);
  background: rgba(255,255,255,.04);
}

/* Thumb */
body.ui-scope .ui-recipes-thumb{
  width: 100%;
  height: auto;
  display: block;

  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.10);
  background: rgba(0,0,0,.10);

  margin-bottom: 10px;
}

/* Text */
body.ui-scope .ui-recipes-title{
  font-weight: 850;
  font-size: 14px;
  line-height: 1.2;
  margin: 0 0 6px;
  color: rgba(255,255,255,.92);
}

body.ui-scope .ui-recipes-subtitle{
  font-size: 12.5px;
  line-height: 1.35;
  margin: 0;
  color: rgba(229,231,235,.76);
}

/* Responsive */
@media (max-width: 1200px){
  body.ui-scope .ui-recipes-grid{ grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 980px){
  body.ui-scope .ui-recipes-grid{ grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 680px){
  body.ui-scope .ui-recipes-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 420px){
  body.ui-scope .ui-recipes-grid{ grid-template-columns: 1fr; }
}
/* ================================
   Grid Pages: restore 5-up panel grid
   (Scoped to ui-scope to avoid bleed)
================================== */

.ui-scope .ui-gridpage-wrap{
  width: 80vw;
  margin: 0 auto;
  padding: clamp(16px, 2vw, 28px) 0;
}

@media (max-width: 1024px){
  .ui-scope .ui-gridpage-wrap{ width: 90vw; }
}
@media (max-width: 640px){
  .ui-scope .ui-gridpage-wrap{
    width: 100%;
    padding-left: 16px;
    padding-right: 16px;
  }
}

/* the actual grid */
.ui-scope .ui-gridpage-grid{
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: clamp(14px, 1.6vw, 20px);
  align-items: stretch;
}

/* breakpoints */
@media (max-width: 1200px){
  .ui-scope .ui-gridpage-grid{ grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px){
  .ui-scope .ui-gridpage-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px){
  .ui-scope .ui-gridpage-grid{ grid-template-columns: 1fr; }
}

/* card: dark panel look (matches existing UI style) */
.ui-scope .ui-gridpage-card{
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 16px;
  overflow: hidden;
}

/* thumbnail */
.ui-scope .ui-gridpage-thumb{
  display: block;
  overflow: hidden;
}
.ui-scope .ui-gridpage-thumb img{
  width: 100%;
  height: 150px;
  object-fit: cover;
  display: block;
  transform: scale(1);
  transition: transform 220ms ease;
}

/* hover: NO vertical jump, only subtle zoom */
.ui-scope .ui-gridpage-card:hover .ui-gridpage-thumb img{
  transform: scale(1.04);
}

/* tidy internal spacing (keeps your content intact) */
.ui-scope .ui-gridpage-card h2{
  margin: 12px 14px 8px;
}
.ui-scope .ui-gridpage-links{
  margin: 0 14px 14px;
  padding-left: 18px;
}
/* Grid page: remove bullets + turn links into clean rows */
.ui-scope .ui-gridpage-links{
  list-style: none;
  margin: 0 14px 14px;
  padding: 0;
  display: grid;
  gap: 8px;
}

.ui-scope .ui-gridpage-links li{
  margin: 0;
  padding: 0;
}

/* subtle row separators, no hover jump */
.ui-scope .ui-gridpage-links a{
  display: block;
  padding: 8px 10px;
  border-radius: 10px;
  text-decoration: none;
  color: inherit;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.08);
  transition: background-color 180ms ease, border-color 180ms ease;
}

.ui-scope .ui-gridpage-links a:hover{
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.14);
}
/* Grid page: smaller panel titles */
.ui-scope .ui-gridpage-card h2{
  font-size: 1.05rem;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 0.2px;
  margin: 12px 14px 8px;
}

@media (max-width: 640px){
  .ui-scope .ui-gridpage-card h2{
    font-size: 1rem;
  }
}
