/**
 * HDD — Recipes for Pets grid (cards only).
 * Markup: inc/shortcodes/hdd-recipes-pets.php
 *
 * The filter is a separate Search & Filter Pro form in Elementor —
 * its styles are intentionally NOT included yet (waiting for the plugin update decision).
 */

/* ══════════════════════ Base / tokens ══════════════════════ */
.hddrec-pet,
.hddrec-pet *,
.hddrec-pet *::before,
.hddrec-pet *::after {
  box-sizing: border-box;
}

.hddrec-pet {
  --hddrec-pet-navy: #003082;
  --hddrec-pet-gold: #B58F11;
  --hddrec-pet-black: #000000;
  --hddrec-pet-white: #FFFFFF;
  --hddrec-pet-cream: #F7F4EE;

  width: 100%;
  font-family: "Figtree", sans-serif;
}

.hddrec-pet__title {
  margin: 0 0 56px;
  font-family: "Prata", serif;
  font-weight: 400;
  font-size: 40px;
  line-height: 1.2;
  color: var(--hddrec-pet-black);
  letter-spacing: -0.01em;
  text-align: center;
}

/* ══════════════════════ Card grid ══════════════════════ */
.hddrec-pet__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px 24px;
}

.hddrec-pet__card {
  display: flex;
  flex-direction: column;
  margin: 0;
  border-radius: 18px;
  overflow: hidden;
  background: var(--hddrec-pet-white);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.10);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease;
}

.hddrec-pet__card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.14);
}

.hddrec-pet__card-link {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  color: inherit;
  text-decoration: none;
}

.hddrec-pet__card-link:focus-visible {
  outline: 2px solid var(--hddrec-pet-navy);
  outline-offset: -2px;
  border-radius: 18px;
}

.hddrec-pet__card-image {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background-image: url(/wp-content/uploads/2026/09/Not-Image-Include-Pet-Product.jpg);
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.hddrec-pet__card-image img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
}

.hddrec-pet__card-title {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 14px 16px 16px;
  font-family: "Prata", serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 1.2;
  color: var(--hddrec-pet-black);
  letter-spacing: -0.01em;
  text-align: center;
  background: var(--hddrec-pet-white);
}

/* ══════════════════════ Empty state ══════════════════════ */
.hddrec-pet__empty {
  margin: 0;
  padding: 60px 20px;
  font-family: "Figtree", sans-serif;
  font-weight: 500;
  font-size: 16px;
  color: #6B6B6B;
  text-align: center;
}

/* ══════════════════════ Pagination ══════════════════════ */
.hddrec-pet__pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 48px;
}

.hddrec-pet__pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: 100px;
  font-family: "Figtree", sans-serif;
  font-weight: 600;
  font-size: 15px;
  color: var(--hddrec-pet-black);
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.hddrec-pet__pagination a.page-numbers:hover {
  background: var(--hddrec-pet-cream);
  color: var(--hddrec-pet-gold);
}

.hddrec-pet__pagination .page-numbers.current {
  background: var(--hddrec-pet-navy);
  color: var(--hddrec-pet-white);
}

.hddrec-pet__pagination .page-numbers:focus-visible {
  outline: 2px solid var(--hddrec-pet-navy);
  outline-offset: 2px;
}

/* ══════════════════════ Reduced motion ══════════════════════ */
@media (prefers-reduced-motion: reduce) {
  .hddrec-pet__card,
  .hddrec-pet__pagination .page-numbers {
    transition: none;
  }

  .hddrec-pet__card:hover {
    transform: none;
  }
}

/* ══════════════════════ Responsive ══════════════════════ */
@media (max-width: 1279px) {
  .hddrec-pet__title { font-size: 34px; margin-bottom: 44px; }
}

@media (max-width: 1023px) {
  .hddrec-pet__title { font-size: 28px; margin-bottom: 36px; }
  .hddrec-pet__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 767px) {
  .hddrec-pet__title { font-size: 24px; }
  .hddrec-pet__card-title { font-size: 15px; }
}

@media (max-width: 479px) {
  .hddrec-pet__grid { grid-template-columns: 1fr; gap: 24px; }
}








/* ==========================================================================
   Happy Days — Recipes for Pets: Search & Filter Pro 3 sidebar
   Scope: Elementor container .main-post-type-recipes-cl
   Fields: #1 Search (text), #2 Holiday (radio), #3 Ingredients (radio, ACF)
   ========================================================================== */

/* --------------------------------------------------------------------------
   Design tokens (scoped to the sidebar container)
   -------------------------------------------------------------------------- */
.recipes-for-pets-sidebar {
  --hdd-sf-navy: #003082;
  --hdd-sf-gold: #B58F11;
  --hdd-sf-black: #000000;
  --hdd-sf-white: #FFFFFF;
  --hdd-sf-cream: #F7F4EE;
  --hdd-sf-text: #4A4A4A;
  --hdd-sf-placeholder: #8A8A8A;
  --hdd-sf-divider: rgba(0, 48, 130, 0.14);
  --hdd-sf-input-border: rgba(0, 48, 130, 0.18);
  --hdd-sf-focus-ring: rgba(0, 48, 130, 0.14);
  --hdd-sf-underline: rgba(181, 143, 17, 0.4);
}



/* --------------------------------------------------------------------------
   Sidebar card
   Elementor containers read padding/gap from CSS variables, so we set both
   the variables and the real properties. Doubled class = higher specificity
   than Elementor's per-element CSS (.elementor-xxx .elementor-element-xxx).
   -------------------------------------------------------------------------- */
.recipes-for-pets-sidebar {
  --padding-top: 32px;
  --padding-right: 28px;
  --padding-bottom: 32px;
  --padding-left: 28px;
  --gap: 0px;
  --row-gap: 0px;
  --column-gap: 0px;

  position: sticky;
  top: 120px;
  align-self: flex-start;        /* sticky won't work if the column stretches */
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 32px 28px;
  background: var(--hdd-sf-cream);
  border-radius: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

/* Widgets inside the sidebar: full width, no Elementor spacing */
.recipes-for-pets-sidebar > .elementor-widget {
  width: 100%;
  max-width: 100%;
  margin: 0;
}

.recipes-for-pets-sidebar .search-filter-field {
  margin: 0;
  padding: 0;
  width: 100%;
  font-family: "Figtree", sans-serif;
}

/* Divider + spacing between groups (search → holiday → ingredients) */
.recipes-for-pets-sidebar > .elementor-widget + .elementor-widget {
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--hdd-sf-divider);
}

/* --------------------------------------------------------------------------
   Group titles (Holiday / Happy Days Ingredients)
   -------------------------------------------------------------------------- */
.recipes-for-pets-sidebar .search-filter-field .search-filter-label {
    display: block;
    margin: 0 0 11px;
    padding: 0;
    font-family: "Prata", serif;
    font-weight: 400;
    font-size: 20px;
    line-height: normal;
    letter-spacing: -0.01em;
    color: var(--hdd-sf-black);
}

/* Search field has an empty label — remove it completely */
.recipes-for-pets-sidebar .search-filter-field .search-filter-label:empty {
  display: none;
}

/* --------------------------------------------------------------------------
   #1 Search — pill input
   The border lives on the wrapper so the S&F clear button stays inside it.
   -------------------------------------------------------------------------- */
.recipes-for-pets-sidebar .search-filter-field--id-1 .search-filter-input-text {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  height: 46px;
  padding: 0 20px;
  background: var(--hdd-sf-white);
  border: 1.5px solid var(--hdd-sf-input-border);
  border-radius: 100px;
  box-shadow: none;
  transition: box-shadow 0.2s ease;
}

.recipes-for-pets-sidebar .search-filter-field--id-1 .search-filter-input-text:focus-within {
  box-shadow: 0 0 0 3px var(--hdd-sf-focus-ring);
}

.recipes-for-pets-sidebar .search-filter-field--id-1 .search-filter-input-text__input {
    flex: 1 1 auto;
    width: 100% !important;
    min-width: 0;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0;
    box-shadow: none !important;
    outline: none !important;
    font-family: "Figtree", sans-serif !important;
    font-weight: 500;
    font-size: 14px !important;
    color: var(--hdd-sf-black) !important;
}

.recipes-for-pets-sidebar .search-filter-field--id-1 .search-filter-input-text__input::placeholder {
  color: var(--hdd-sf-placeholder);
  opacity: 1;
}

/* Magnifier icon is not in the mockup — hide the leading icon only,
   so the clear (×) button still works */
.recipes-for-pets-sidebar .search-filter-field--id-1 .search-filter-input-text__icon:first-child {
  display: none;
}

/* --------------------------------------------------------------------------
   #2 / #3 Radio groups — styled as text links
   -------------------------------------------------------------------------- */
.recipes-for-pets-sidebar .search-filter-input-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 13px;
  margin: 0;
  padding: 0;
}

.recipes-for-pets-sidebar .search-filter-input-radio {
  position: relative;
  margin: 0;
  padding: 0;
}

/* Native radio: visually hidden but still focusable */
.recipes-for-pets-sidebar .search-filter-input-radio__input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}

/* Custom radio circle (SVG) is not in the mockup */
.recipes-for-pets-sidebar .search-filter-input-radio__control {
  display: none;
}

.recipes-for-pets-sidebar .search-filter-input-radio__container {
  display: inline-block;
  margin: 0;
  padding: 0;
  cursor: pointer;
}

.recipes-for-pets-sidebar .search-filter-input-radio__label {
    display: inline;
    margin: 0;
    padding: 0;
    font-family: "Figtree", sans-serif;
    font-weight: 500;
    font-size: 15px;
    line-height: normal;
    color: var(--hdd-sf-text);
    text-decoration: none;
    transition: color 0.2s ease;
}

/* Hover */
.recipes-for-pets-sidebar .search-filter-input-radio:hover .search-filter-input-radio__label {
  color: var(--hdd-sf-gold);
}

/* Active option */
.recipes-for-pets-sidebar .search-filter-input-radio--is-active .search-filter-input-radio__label {
  color: var(--hdd-sf-gold);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--hdd-sf-underline);
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

/* Keyboard focus (radio is hidden, so show focus on its label) */
.recipes-for-pets-sidebar .search-filter-input-radio__input:focus-visible + .search-filter-input-radio__container .search-filter-input-radio__label {
  outline: 2px solid var(--hdd-sf-navy);
  outline-offset: 3px;
  border-radius: 2px;
}

/* S&F Pro 3 derives font-size, padding and icon sizes from --search-filter-scale-base.
   Override the base per field so computed values match the mockup. */
.recipes-for-pets-sidebar .search-filter-base.search-filter-field--id-1 {
  --search-filter-scale-base: 14;
}

.recipes-for-pets-sidebar .search-filter-base.search-filter-field--id-2,
.recipes-for-pets-sidebar .search-filter-base.search-filter-field--id-3 {
  --search-filter-scale-base: 15;
}

/* Explicit fallback with higher specificity, in case app.css sets font-size directly */
.recipes-for-pets-sidebar .search-filter-base.search-filter-field--id-1 .search-filter-input-text .search-filter-input-text__input {
  font-size: 14px !important;
  line-height: 1.2;
}






/* --------------------------------------------------------------------------
   Responsive (same breakpoints as the recipes grid)
   -------------------------------------------------------------------------- */
@media (max-width: 1023px) {
  .recipes-for-pets-sidebar {
    position: static;
    width: 100%;
    max-width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .recipes-for-pets-sidebar .search-filter-input-text,
  .recipes-for-pets-sidebar .search-filter-input-radio__label {
    transition: none;
  }
}