/* Scoped additions for category/filter entry points and ingredient archive links. */
.ingredient-filter-entry.card{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  gap:1.4rem;
  margin:1.6rem 0 1.5rem;
  padding:1.1rem 1.2rem;
  border:1px solid var(--border);
  border-radius:12px;
  background:var(--card);
  box-shadow:0 6px 18px rgba(0,0,0,.05);
}

.ingredient-filter-entry-copy{
  min-width:0;
}

.ingredient-filter-entry h2{
  margin:0;
  color:var(--text);
  font-size:1.25rem;
  line-height:1.3;
}

.ingredient-filter-entry p{
  margin:.35rem 0 0;
  color:var(--muted);
  font-size:.96rem;
  line-height:1.45;
}

.ingredient-filter-entry-button{
  display:inline-flex;
  height:44px;
  min-height:44px;
  flex:0 0 auto;
  align-items:center;
  justify-content:center;
  padding:0 1rem;
  border:1px solid var(--accent);
  border-radius:8px;
  background:var(--accent);
  color:#fff;
  font-size:.94rem;
  font-weight:800;
  line-height:1;
  text-decoration:none;
  white-space:nowrap;
}

.ingredient-filter-entry-button:hover{
  background:var(--accent-strong);
  border-color:var(--accent-strong);
  color:#fff;
  text-decoration:none;
}

.ingredient-filter-entry-button:focus-visible{
  outline:0;
  box-shadow:0 0 0 4px var(--accent-3);
}

.ingredient-filter-entry--single{
  margin:2rem 0 1.5rem!important;
}

.recipe-ingredient-link,
.recipe-ingredient-link:visited,
.recipe-ingredient-link:hover,
.recipe-ingredient-link:active{
  color:inherit;
  font:inherit;
  font-weight:inherit;
  text-decoration:none;
}

.recipe-ingredient-link:focus-visible{
  outline:2px solid var(--accent);
  outline-offset:2px;
  border-radius:2px;
}

@media(max-width:600px){
  .ingredient-filter-entry.card{
    grid-template-columns:1fr;
    gap:.8rem;
    margin:1.35rem 0;
    padding:1rem;
  }

  .ingredient-filter-entry--single{
    margin:1.75rem 0 1.3rem!important;
  }

  .ingredient-filter-entry-button{
    width:100%;
  }
}

/* Recipe enrichment and useful archive guidance. */
.recipe-card-meta{
  padding:0 20px .15rem;
  color:var(--accent-strong);
  font-size:.8rem;
  font-weight:700;
}

.recipe-enrichment{
  margin-top:2rem;
}

.recipe-enrichment-section{
  padding:1.35rem 0 0;
  margin:1.35rem 0 0;
  border-top:1px solid var(--border);
}

.recipe-enrichment-section h2{
  margin:0 0 .65rem;
  font-size:1.25rem;
  line-height:1.3;
}

.recipe-enrichment-section p,
.recipe-enrichment-section ul,
.recipe-enrichment-section dl{
  margin:.45rem 0 0;
}

.recipe-enrichment-section ul{
  padding-left:1.2rem;
}

.recipe-enrichment-section li+li{
  margin-top:.35rem;
}

.recipe-enrichment-heading{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:1rem;
}

.recipe-enrichment-heading h2{
  margin:0;
}

.recipe-enrichment-heading p{
  margin:.3rem 0 0;
  color:var(--muted);
  font-size:.9rem;
}

.nutrition-unit-toggle{
  display:inline-flex;
  min-height:38px;
  flex:0 0 auto;
  align-items:center;
  justify-content:center;
  padding:.45rem .7rem;
  border:1px solid var(--border);
  border-radius:8px;
  background:#fff;
  color:var(--text);
  font:inherit;
  font-size:.84rem;
  font-weight:700;
  cursor:pointer;
}

.nutrition-unit-toggle:hover{
  border-color:var(--accent);
  color:var(--accent-strong);
}

.nutrition-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:0 1rem;
}

.nutrition-item{
  padding:.7rem 0;
  border-bottom:1px solid #eef0f4;
}

.nutrition-item dt{
  color:var(--muted);
  font-size:.8rem;
}

.nutrition-item dd{
  margin:.18rem 0 0;
  color:var(--text);
  font-size:1rem;
  font-weight:700;
}

.recipe-enrichment-columns{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:0 1.5rem;
}

.recipe-storage dl{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:1rem;
}

.recipe-storage dt{
  font-weight:700;
}

.recipe-storage dd{
  margin:.25rem 0 0;
  color:var(--muted);
  line-height:1.5;
}

.recipe-allergen-list{
  font-weight:600;
}

.recipe-allergen-disclaimer{
  max-width:900px;
  font-size:.82rem;
  line-height:1.5;
}

.taxonomy-guide{
  max-width:920px;
  padding-top:.9rem;
  margin-top:.9rem;
  border-top:1px solid var(--border);
  line-height:1.55;
}

.taxonomy-guide>p{
  margin:.35rem 0;
}

.taxonomy-guide h2{
  margin:1rem 0 .35rem;
  font-size:1.05rem;
}

.taxonomy-guide ul{
  margin:.3rem 0 0;
  padding-left:1.2rem;
}

@media(max-width:700px){
  .nutrition-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }

  .recipe-enrichment-columns,
  .recipe-storage dl{
    grid-template-columns:1fr;
  }

  .recipe-enrichment-heading{
    align-items:flex-start;
    flex-direction:column;
  }
}

.page-search .recipe-card-meta{
  padding:0 .7rem .35rem;
}

/* Single recipe: compact metadata, quick navigation, share actions and ad overflow guards. */
.recipe-energy-pill small{
  display:block;
  margin-top:.18rem;
  font-size:.68rem;
  font-weight:600;
  line-height:1.15;
  color:var(--muted);
}

.recipe-quick-nav{
  position:fixed;
  z-index:35;
  top:50%;
  right:14px;
  display:flex;
  flex-direction:column;
  gap:8px;
  transform:translateY(-50%);
}

.recipe-quick-nav-link{
  position:relative;
  display:flex;
  width:44px;
  height:44px;
  align-items:center;
  justify-content:center;
  border:1px solid var(--border);
  border-radius:10px;
  background:#fff;
  color:var(--text);
  box-shadow:0 5px 16px rgba(0,0,0,.08);
  text-decoration:none;
}

.recipe-quick-nav-link:hover,
.recipe-quick-nav-link:focus-visible{
  border-color:var(--accent);
  color:var(--accent-strong);
  text-decoration:none;
}

.recipe-quick-nav-link:focus-visible{
  outline:0;
  box-shadow:0 0 0 4px var(--accent-3),0 5px 16px rgba(0,0,0,.08);
}

.recipe-quick-nav-link svg{
  width:21px;
  height:21px;
  fill:none;
  stroke:currentColor;
  stroke-width:1.8;
  stroke-linecap:round;
  stroke-linejoin:round;
}

.recipe-quick-nav-label{
  position:absolute;
  right:calc(100% + 8px);
  top:50%;
  max-width:190px;
  padding:.42rem .58rem;
  border:1px solid var(--border);
  border-radius:8px;
  background:#fff;
  color:var(--text);
  box-shadow:0 5px 16px rgba(0,0,0,.08);
  font-size:.78rem;
  font-weight:700;
  line-height:1.15;
  opacity:0;
  pointer-events:none;
  transform:translateY(-50%);
  transition:opacity .12s ease;
  white-space:nowrap;
}

.recipe-quick-nav-link:hover .recipe-quick-nav-label,
.recipe-quick-nav-link:focus-visible .recipe-quick-nav-label{
  opacity:1;
  transform:translateY(-50%);
}

#recipe-ingredients,
#recipe-instructions,
#recipe-nutrition,
#recipe-equipment{
  scroll-margin-top:92px;
}

.recipe-share{
  padding:1.15rem 0 0;
  margin:1.4rem 0 0;
  border-top:1px solid var(--border);
}

.recipe-share h2{
  margin:0 0 .7rem;
  font-size:1.15rem;
  line-height:1.3;
}

.recipe-share-actions{
  display:flex;
  flex-wrap:wrap;
  gap:.55rem;
}

.recipe-share-button{
  display:inline-flex;
  min-height:40px;
  align-items:center;
  justify-content:center;
  padding:.55rem .78rem;
  border:1px solid var(--border);
  border-radius:8px;
  background:#fff;
  color:var(--text);
  font:inherit;
  font-size:.84rem;
  font-weight:700;
  line-height:1;
  text-decoration:none;
  cursor:pointer;
  gap:.48rem;
}

.recipe-share-icon{
  --recipe-share-icon:none;
  display:inline-block;
  flex:0 0 auto;
  width:17px;
  height:17px;
  background:currentColor;
  -webkit-mask:var(--recipe-share-icon) center / contain no-repeat;
  mask:var(--recipe-share-icon) center / contain no-repeat;
}

.recipe-share-icon--facebook{
  --recipe-share-icon:url('/frontend/icons/fontawesome/share/facebook.svg');
  color:#1877f2;
}

.recipe-share-icon--x{
  --recipe-share-icon:url('/frontend/icons/fontawesome/share/x-twitter.svg');
  color:#111;
}

.recipe-share-icon--pinterest{
  --recipe-share-icon:url('/frontend/icons/fontawesome/share/pinterest.svg');
  color:#bd081c;
}

.recipe-share-icon--whatsapp{
  --recipe-share-icon:url('/frontend/icons/fontawesome/share/whatsapp.svg');
  color:#128c7e;
}

.recipe-share-icon--email{
  --recipe-share-icon:url('/frontend/icons/fontawesome/share/envelope.svg');
}

.recipe-share-icon--copy{
  --recipe-share-icon:url('/frontend/icons/fontawesome/share/link.svg');
}

.recipe-share-icon--native{
  --recipe-share-icon:url('/frontend/icons/fontawesome/share/share-nodes.svg');
}

.recipe-share-button:hover,
.recipe-share-button:focus-visible{
  border-color:var(--accent);
  color:var(--accent-strong);
  text-decoration:none;
}

.recipe-share-button:focus-visible{
  outline:0;
  box-shadow:0 0 0 4px var(--accent-3);
}

/* A responsive ad must never enlarge a recipe column or the whole mobile page. */
.single,
.recipe-layout,
.recipe-layout>*{
  min-width:0;
}

.single .ad-slot{
  width:100%;
  max-width:100%;
  min-width:0;
  box-sizing:border-box;
  overflow:hidden;
}

.single .ad-slot ins.adsbygoogle,
.single .ad-slot>ins,
.single .ad-slot>div{
  max-width:100%!important;
  box-sizing:border-box;
}

.recipe-ingredients,
.recipe-steps{
  min-width:0;
}

@media(min-width:1500px){
  .recipe-quick-nav-link{
    width:auto;
    min-width:44px;
    justify-content:flex-start;
    gap:.5rem;
    padding:0 .72rem;
  }

  .recipe-quick-nav-label{
    position:static;
    max-width:none;
    padding:0;
    border:0;
    background:transparent;
    box-shadow:none;
    opacity:1;
    transform:none;
    transition:none;
    white-space:nowrap;
  }

  .recipe-quick-nav-link:hover .recipe-quick-nav-label,
  .recipe-quick-nav-link:focus-visible .recipe-quick-nav-label{
    transform:none;
  }
}

@media(max-width:900px){
  .recipe-quick-nav{
    top:auto;
    right:auto;
    bottom:max(10px,env(safe-area-inset-bottom));
    left:50%;
    flex-direction:row;
    gap:4px;
    max-width:calc(100vw - 16px);
    padding:5px;
    border:1px solid var(--border);
    border-radius:12px;
    background:#fff;
    box-shadow:0 7px 22px rgba(0,0,0,.13);
    transform:translateX(-50%);
  }

  .recipe-quick-nav-link{
    width:64px;
    min-width:0;
    height:45px;
    flex:0 1 64px;
    flex-direction:column;
    gap:2px;
    padding:3px 2px;
    border:0;
    box-shadow:none;
  }

  .recipe-quick-nav-link svg{
    width:18px;
    height:18px;
  }

  .recipe-quick-nav-label{
    position:static;
    display:block;
    max-width:64px;
    padding:0;
    border:0;
    background:transparent;
    box-shadow:none;
    font-size:.62rem;
    line-height:1;
    opacity:1;
    overflow:hidden;
    text-overflow:ellipsis;
    transform:none;
    white-space:nowrap;
  }

  .recipe-quick-nav-link:hover .recipe-quick-nav-label,
  .recipe-quick-nav-link:focus-visible .recipe-quick-nav-label{
    transform:none;
  }

  .recipe-ingredients,
  .recipe-steps{
    max-width:100%;
    overflow:hidden;
    box-sizing:border-box;
  }

  .single .ad-slot,
  .recipe-ingredients .ad-slot,
  .recipe-steps .ad-slot{
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
  }

  .single .ad-slot iframe{
    max-width:100%!important;
  }
}

@media(max-width:520px){
  .recipe-share-actions{
    gap:.45rem;
  }

  .recipe-share-button{
    min-height:38px;
    padding:.5rem .68rem;
    font-size:.8rem;
  }
}
