/* ==========================================================================
   HSGM Header Design - "Bold & Bouncy"
   High-contrast, vibrant, energetic with spring animations
   ========================================================================== */

/* --------------------------------------------------------------------------
   WordPress Admin Bar Offset
   When logged in, WordPress adds a 32px admin bar (46px on mobile <782px)
   -------------------------------------------------------------------------- */
body.admin-bar .header {
  top: 32px;
}

body.admin-bar .mobile-menu {
  top: 32px;
  height: calc(100vh - 32px);
}

@media screen and (max-width: 782px) {
  body.admin-bar .header {
    top: 46px;
  }

  body.admin-bar .mobile-menu {
    top: 46px;
    height: calc(100vh - 46px);
  }
}

/* --------------------------------------------------------------------------
   Elementor Style Reset - Isolate header from Elementor global styles
   -------------------------------------------------------------------------- */
.header,
.header *,
.header *::before,
.header *::after,
.mobile-menu,
.mobile-menu *,
.mobile-menu *::before,
.mobile-menu *::after {
  box-sizing: border-box;
}

/* Reset Elementor's heading styles within header */
.header h3,
.header h4,
.mobile-menu h3,
.mobile-menu h4 {
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
  margin: 0;
  padding: 0;
}

/* Reset Elementor's global link styles within header (except CTA buttons) */
.header a:not(.cta),
.header a:not(.cta):hover,
.header a:not(.cta):focus,
.header a:not(.cta):active,
.header a:not(.cta):visited,
.mobile-menu a:not(.cta),
.mobile-menu a:not(.cta):hover,
.mobile-menu a:not(.cta):focus,
.mobile-menu a:not(.cta):active,
.mobile-menu a:not(.cta):visited {
  color: inherit;
  text-decoration: none;
  background: transparent;
  outline: none;
  box-shadow: none;
  transition: none;
}

/* Reset Elementor button styles */
.header button,
.mobile-menu button {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  color: inherit;
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   Design Tokens
   -------------------------------------------------------------------------- */
:root {
  /* Primary Colors - HSGM Brand Colors */
  --color-magenta: #CC3366;
  --color-magenta-dark: #A62953;
  --color-magenta-light: #E04D80;
  --color-teal: #00796B;
  --color-teal-dark: #005A4F;
  --color-teal-light: #009688;

  /* Spay/Neuter Button Color */
  --color-blue: #2196F3;
  --color-blue-dark: #1976D2;
  --color-blue-light: #42A5F5;

  /* Accent Colors */
  --color-orange: #FF6B35;
  --color-orange-light: #FF8A5C;
  --color-yellow: #FFD23F;
  --color-purple: #9B5DE5;

  /* Neutral Colors */
  --color-white: #FFFFFF;
  --color-off-white: #FFF8F5;
  --color-gray-100: #F7F7F7;
  --color-gray-200: #E8E8E8;
  --color-gray-300: #D1D1D1;
  --color-gray-500: #8A8A8A;
  --color-gray-700: #4A4A4A;
  --color-gray-900: #1A1A1A;

  /* Typography */
  --font-primary: 'Quicksand', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-accent: 'Fredoka One', cursive;
  --font-size-xs: 0.75rem;
  --font-size-sm: 0.875rem;
  --font-size-base: 1rem;
  --font-size-lg: 1.125rem;
  --font-size-xl: 1.25rem;

  /* Spacing */
  --spacing-xs: 0.25rem;
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 3rem;

  /* Header Heights */
  --header-height: 90px;
  --header-height-shrunk: 65px;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(204, 51, 102, 0.1);
  --shadow-md: 0 4px 20px rgba(204, 51, 102, 0.15);
  --shadow-lg: 0 8px 40px rgba(204, 51, 102, 0.2);
  --shadow-bounce: 0 10px 30px rgba(0, 121, 107, 0.3);

  /* Borders */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  /* Transitions - Spring Physics Feel */
  --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --duration-fast: 150ms;
  --duration-normal: 250ms;
  --duration-slow: 400ms;

  /* Z-Index */
  --z-header: 1000;
  --z-dropdown: 1010;
  --z-mobile-menu: 1020;
  --z-overlay: 1015;
}

/* --------------------------------------------------------------------------
   Header Container
   -------------------------------------------------------------------------- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: var(--color-white);
  box-shadow: var(--shadow-sm);
  z-index: var(--z-header);
  transition: height var(--duration-slow) var(--ease-bounce),
              box-shadow var(--duration-normal) var(--ease-smooth);
}

.header.is-scrolled {
  height: var(--header-height-shrunk);
  box-shadow: var(--shadow-md);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

/* --------------------------------------------------------------------------
   Logo Area
   -------------------------------------------------------------------------- */
.logo {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
  text-decoration: none;
  position: relative;
  flex-shrink: 0;
}

.header .logo__image {
  height: 50px;
  width: auto;
  max-width: 220px;
  object-fit: contain;
  transition: all var(--duration-normal) var(--ease-bounce);
}

.header.is-scrolled .logo__image {
  height: 45px;
}

.logo:hover .logo__image {
  transform: scale(1.05);
}

/* Bouncy paw prints on logo hover */
.logo__paw {
  position: absolute;
  width: 20px;
  height: 20px;
  opacity: 0;
  pointer-events: none;
  fill: var(--color-magenta);
  transition: all var(--duration-slow) var(--ease-bounce);
}

.logo:hover .logo__paw--1 {
  opacity: 0.6;
  transform: translate(-30px, -20px) rotate(-20deg);
}

.logo:hover .logo__paw--2 {
  opacity: 0.4;
  transform: translate(40px, -15px) rotate(15deg);
}

.logo__text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.logo__name {
  font-family: var(--font-accent);
  font-size: var(--font-size-xl);
  color: var(--color-magenta);
  letter-spacing: -0.5px;
}

.header.is-scrolled .logo__name {
  font-size: var(--font-size-lg);
}

.logo__tagline {
  font-size: var(--font-size-xs);
  color: var(--color-teal-dark);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.header.is-scrolled .logo__tagline {
  display: none;
}

/* --------------------------------------------------------------------------
   Main Navigation
   -------------------------------------------------------------------------- */
.nav {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
}

.nav__list {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav__item {
  position: relative;
}

.nav__link {
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  padding: var(--spacing-sm) var(--spacing-md);
  font-size: var(--font-size-base);
  font-weight: 600;
  color: var(--color-gray-700);
  text-decoration: none;
  border-radius: var(--radius-md);
  transition: all var(--duration-normal) var(--ease-bounce);
  position: relative;
  overflow: hidden;
}

.nav__link::before {
  content: '';
  position: absolute;
  bottom: 6px;
  left: 50%;
  width: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--color-magenta), var(--color-teal));
  border-radius: var(--radius-full);
  transition: all var(--duration-normal) var(--ease-bounce);
  transform: translateX(-50%);
}

.nav__link:hover,
.nav__link:focus {
  color: var(--color-magenta);
  background: rgba(204, 51, 102, 0.05);
}

.nav__link:hover::before,
.nav__link:focus::before,
.nav__item.is-open .nav__link::before {
  width: calc(100% - 24px);
}

.nav__link-icon {
  width: 12px;
  height: 12px;
  fill: currentColor;
  transition: transform var(--duration-normal) var(--ease-bounce);
}

.nav__item.is-open .nav__link-icon {
  transform: rotate(180deg);
}

/* --------------------------------------------------------------------------
   Dropdown Menus
   -------------------------------------------------------------------------- */
.dropdown {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  min-width: 220px;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: var(--spacing-md);
  opacity: 0;
  visibility: hidden;
  transition: all var(--duration-normal) var(--ease-bounce);
  z-index: var(--z-dropdown);
}

.dropdown::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  border: 8px solid transparent;
  border-bottom-color: var(--color-white);
  border-top: none;
}

.nav__item:hover .dropdown,
.nav__item.is-open .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.dropdown__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.dropdown__link {
  display: block;
  padding: var(--spacing-sm) var(--spacing-md);
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--color-gray-700);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: all var(--duration-fast) var(--ease-smooth);
  position: relative;
}

.dropdown__link::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 0;
  background: var(--color-magenta);
  border-radius: var(--radius-full);
  transition: height var(--duration-normal) var(--ease-bounce);
}

.dropdown__link:hover,
.dropdown__link:focus {
  color: var(--color-magenta);
  background: rgba(204, 51, 102, 0.05);
  padding-left: var(--spacing-lg);
}

.dropdown__link:hover::before,
.dropdown__link:focus::before {
  height: 20px;
}

/* --------------------------------------------------------------------------
   Dropdown with Headings (WHO WE ARE, HOW YOU HELP)
   -------------------------------------------------------------------------- */
.dropdown--with-headings {
  min-width: auto;
  padding: var(--spacing-lg);
}

.dropdown__grid {
  display: flex;
  gap: var(--spacing-md);
}

.dropdown__column {
  min-width: 130px;
  padding: 0 var(--spacing-md);
  border-right: 2px dashed var(--color-gray-200);
  white-space: nowrap;
}

.dropdown__column:last-child {
  border-right: none;
}

.dropdown__title,
h4.dropdown__title {
  font-family: var(--font-accent);
  font-size: var(--font-size-xs);
  font-weight: 700;
  color: var(--color-magenta);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  line-height: 1.2;
  margin: 0 0 var(--spacing-sm) 0;
  padding: 0;
}

.dropdown--with-headings .dropdown__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.dropdown--with-headings .dropdown__link {
  display: block;
  padding: var(--spacing-xs) var(--spacing-sm);
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--color-gray-700);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: all var(--duration-fast) var(--ease-smooth);
  position: relative;
}

.dropdown--with-headings .dropdown__link::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 0;
  background: var(--color-magenta);
  border-radius: var(--radius-full);
  transition: height var(--duration-normal) var(--ease-bounce);
}

.dropdown--with-headings .dropdown__link:hover,
.dropdown--with-headings .dropdown__link:focus {
  color: var(--color-magenta);
  background: rgba(204, 51, 102, 0.05);
}

.dropdown--with-headings .dropdown__link:hover::before,
.dropdown--with-headings .dropdown__link:focus::before {
  height: 20px;
}

/* --------------------------------------------------------------------------
   Mega Menu (Services)
   -------------------------------------------------------------------------- */
.mega-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(10px);
  width: 800px;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: var(--spacing-xl);
  opacity: 0;
  visibility: hidden;
  transition: all var(--duration-normal) var(--ease-bounce);
  z-index: var(--z-dropdown);
}

.mega-menu::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 50%;
  transform: translateX(-50%);
  border: 8px solid transparent;
  border-bottom-color: var(--color-white);
  border-top: none;
}

.nav__item:hover .mega-menu,
.nav__item.is-open .mega-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.mega-menu__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--spacing-xl);
}

.mega-menu__column {
  padding: 0 var(--spacing-md);
  border-right: 2px dashed var(--color-gray-200);
}

.mega-menu__column:last-child {
  border-right: none;
}

.mega-menu__title,
h3.mega-menu__title {
  font-family: var(--font-accent);
  font-size: var(--font-size-xs);
  font-weight: 700;
  color: var(--color-magenta);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  line-height: 1.2;
  margin: 0 0 var(--spacing-sm) 0;
  padding: 0;
}

.mega-menu__title-icon {
  display: none;
}

.mega-menu__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mega-menu__link {
  display: block;
  padding: var(--spacing-xs) var(--spacing-sm);
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--color-gray-700);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: all var(--duration-fast) var(--ease-smooth);
  position: relative;
}

.mega-menu__link::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 0;
  background: var(--color-magenta);
  border-radius: var(--radius-full);
  transition: height var(--duration-normal) var(--ease-bounce);
}

.mega-menu__link:hover,
.mega-menu__link:focus {
  color: var(--color-magenta);
  background: rgba(204, 51, 102, 0.05);
}

.mega-menu__link:hover::before,
.mega-menu__link:focus::before {
  height: 20px;
}

/* Paw print decoration in mega menu */
.mega-menu__decoration {
  position: absolute;
  bottom: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23CC3366'%3E%3Cellipse cx='12' cy='17' rx='5' ry='4'/%3E%3Cellipse cx='6' cy='9' rx='2.5' ry='3'/%3E%3Cellipse cx='18' cy='9' rx='2.5' ry='3'/%3E%3Cellipse cx='9' cy='5' rx='2' ry='2.5'/%3E%3Cellipse cx='15' cy='5' rx='2' ry='2.5'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  animation: float-paw 3s ease-in-out infinite;
  opacity: 0.25;
}

@keyframes float-paw {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-8px) rotate(5deg); }
}

/* --------------------------------------------------------------------------
   Search - Enhanced Playful Design
   -------------------------------------------------------------------------- */
.search {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Search Toggle Button */
.search__toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: transparent;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  color: var(--color-gray-700);
  transition: all var(--duration-normal) var(--ease-bounce);
}

.search__toggle:hover,
.search__toggle:focus {
  background: linear-gradient(135deg, rgba(204, 51, 102, 0.15), rgba(0, 121, 107, 0.15));
  color: var(--color-magenta);
  transform: scale(1.15);
}

.search__toggle svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
  transition: transform var(--duration-normal) var(--ease-bounce);
}

.search__toggle:hover svg {
  transform: rotate(-15deg) scale(1.1);
}

/* Hide toggle when search is open */
.search.is-open .search__toggle {
  opacity: 0;
  pointer-events: none;
  transform: scale(0.8);
}

/* Search Form Container */
.search__form {
  position: absolute;
  top: 50%;
  right: 0;
  transform: translateY(-50%) scale(0.9);
  display: flex;
  align-items: center;
  width: 0;
  height: 52px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--color-white) 0%, #FFF8F5 100%);
  border-radius: var(--radius-full);
  box-shadow:
    0 4px 20px rgba(204, 51, 102, 0.15),
    0 8px 40px rgba(0, 121, 107, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
  border: none;
  opacity: 0;
  transition:
    width var(--duration-slow) var(--ease-bounce),
    opacity var(--duration-normal) ease,
    transform var(--duration-slow) var(--ease-bounce),
    border-color var(--duration-normal) ease,
    box-shadow var(--duration-normal) ease;
}

.search.is-open .search__form {
  width: 420px;
  opacity: 1;
  transform: translateY(-50%) scale(1);
}

/* Focus state - subtle glow */
.search__form:focus-within {
  box-shadow:
    0 4px 20px rgba(204, 51, 102, 0.25),
    0 8px 40px rgba(0, 121, 107, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

/* Decorative paw print inside search - hidden to avoid overlapping placeholder */
.search__form::before {
  display: none;
}

/* Search Input */
.search__input,
.header .search__input,
input[type="search"].search__input {
  flex: 1;
  padding: var(--spacing-md);
  border: none !important;
  border-radius: 0 !important;
  background: transparent;
  font-family: var(--font-primary);
  font-size: var(--font-size-base);
  font-weight: 500;
  color: var(--color-gray-900);
  outline: none;
  min-width: 0;
  width: auto;
}

.search__input::placeholder {
  color: var(--color-gray-600);
  font-weight: 500;
  transition: color var(--duration-normal) ease;
}

.search__input:focus::placeholder {
  color: var(--color-gray-300);
}

/* Close Button */
.search__close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--color-gray-100) !important;
  border: none !important;
  border-radius: 50%;
  cursor: pointer;
  opacity: 0;
  transform: scale(0.8);
  transition:
    opacity var(--duration-normal) ease,
    transform var(--duration-normal) var(--ease-bounce),
    background var(--duration-fast) ease !important;
  flex-shrink: 0;
  margin-right: var(--spacing-sm);
}

.search.is-open .search__close {
  opacity: 1;
  transform: scale(1);
}

.search__close:hover,
.search__close:focus {
  background: rgba(204, 51, 102, 0.2) !important;
}

.search__close:hover svg,
.search__close:focus svg {
  fill: var(--color-magenta);
}

.search__close svg {
  width: 14px;
  height: 14px;
  fill: var(--color-gray-600);
  transition: fill var(--duration-fast) ease;
}

/* Submit Button */
.search__submit {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--color-magenta), var(--color-magenta-dark)) !important;
  border: none;
  border-radius: 50%;
  margin: 4px;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(204, 51, 102, 0.4);
  transition:
    transform var(--duration-normal) var(--ease-bounce),
    box-shadow var(--duration-normal) ease;
  flex-shrink: 0;
}

.search__submit:focus {
  background: linear-gradient(135deg, var(--color-magenta), var(--color-magenta-dark)) !important;
  outline: 2px solid var(--color-magenta);
  outline-offset: 2px;
}

.search__submit svg {
  width: 20px;
  height: 20px;
  fill: var(--color-white);
  transition: transform var(--duration-normal) var(--ease-bounce);
}

.search__submit:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 20px rgba(204, 51, 102, 0.5);
}

.search__submit:hover svg {
  transform: rotate(-10deg) scale(1.1);
}

.search__submit:active {
  transform: scale(0.95);
}

/* Animated gradient on submit hover */
.search__submit::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--color-teal), var(--color-magenta));
  border-radius: 50%;
  opacity: 0;
  transition: opacity var(--duration-normal) ease;
}

.search__submit:hover::before {
  opacity: 1;
}

.search__submit svg {
  position: relative;
  z-index: 1;
}

/* --------------------------------------------------------------------------
   Contact
   -------------------------------------------------------------------------- */
.contact {
  display: none; /* Hidden per design decision */
}

.contact:hover,
.contact:focus {
  color: var(--color-teal-dark);
  background: rgba(0, 121, 107, 0.1);
}

.contact__icon {
  width: 20px;
  height: 20px;
  fill: currentColor;
  animation: ring 2s ease-in-out infinite;
  animation-play-state: paused;
}

.contact:hover .contact__icon {
  animation-play-state: running;
}

@keyframes ring {
  0%, 100% { transform: rotate(0); }
  10%, 30% { transform: rotate(-10deg); }
  20%, 40% { transform: rotate(10deg); }
  50% { transform: rotate(0); }
}

/* --------------------------------------------------------------------------
   CTA Buttons
   -------------------------------------------------------------------------- */
.ctas {
  display: flex;
  align-items: center;
  gap: var(--spacing-sm);
}

.cta {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-sm) var(--spacing-lg);
  font-family: var(--font-accent);
  font-size: var(--font-size-base);
  text-decoration: none;
  border-radius: var(--radius-full);
  border: none;
  cursor: pointer;
  overflow: hidden;
  transition: all var(--duration-normal) var(--ease-bounce);
}

.cta--donate {
  background: linear-gradient(135deg, var(--color-teal), var(--color-teal-dark));
  color: var(--color-white) !important;
  box-shadow: 0 4px 15px rgba(0, 121, 107, 0.4);
}

.cta--donate:hover,
.cta--donate:focus {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 25px rgba(0, 121, 107, 0.5);
  color: var(--color-white) !important;
}

.cta--adopt {
  background: linear-gradient(135deg, var(--color-magenta), var(--color-magenta-dark));
  color: var(--color-white) !important;
  box-shadow: 0 4px 15px rgba(204, 51, 102, 0.4);
}

.cta--adopt:hover,
.cta--adopt:focus {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 25px rgba(204, 51, 102, 0.5);
  color: var(--color-white) !important;
}

/* Jumping paw animation on CTA hover */
.cta__paw {
  position: absolute;
  width: 14px;
  height: 14px;
  fill: rgba(255, 255, 255, 0.3);
  opacity: 0;
  transition: all var(--duration-slow) var(--ease-bounce);
}

.cta:hover .cta__paw--1 {
  opacity: 1;
  transform: translate(-20px, -15px);
}

.cta:hover .cta__paw--2 {
  opacity: 1;
  transform: translate(20px, -12px);
}

/* Pulse effect for adopt button */
.cta--adopt::after {
  content: '';
  position: absolute;
  inset: -4px;
  background: linear-gradient(135deg, var(--color-magenta), var(--color-magenta-light));
  border-radius: inherit;
  z-index: -1;
  opacity: 0;
  animation: pulse-glow 2s var(--ease-smooth) infinite;
}

/* Spay/Neuter Button - Blue */
.cta--spay-neuter {
  background: linear-gradient(135deg, var(--color-blue), var(--color-blue-dark));
  color: var(--color-white) !important;
  box-shadow: 0 4px 15px rgba(33, 150, 243, 0.4);
}

.cta--spay-neuter:hover,
.cta--spay-neuter:focus {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 25px rgba(33, 150, 243, 0.5);
  color: var(--color-white) !important;
}

/* Cart Icon */
.cart {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: var(--color-gray-100);
  border-radius: var(--radius-full);
  color: var(--color-gray-700);
  transition: all var(--duration-normal) var(--ease-bounce);
  cursor: pointer;
  text-decoration: none;
}

.cart:hover,
.cart:focus {
  background: var(--color-magenta);
  color: var(--color-white);
  transform: scale(1.1);
}

.cart svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.cart__count {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  background: var(--color-orange);
  color: var(--color-white);
  font-size: var(--font-size-xs);
  font-weight: 700;
  line-height: 20px;
  text-align: center;
  border-radius: var(--radius-full);
  animation: bounce-in 0.4s var(--ease-bounce);
}

@keyframes bounce-in {
  0% { transform: scale(0); }
  50% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

@keyframes pulse-glow {
  0%, 100% { transform: scale(1); opacity: 0; }
  50% { transform: scale(1.1); opacity: 0.3; }
}

/* --------------------------------------------------------------------------
   Mobile Menu Toggle
   -------------------------------------------------------------------------- */
.mobile-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 48px;
  height: 48px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: var(--spacing-sm);
  border-radius: var(--radius-md);
  transition: background var(--duration-fast);
}

.mobile-toggle:hover {
  background: rgba(204, 51, 102, 0.1);
}

.mobile-toggle__line {
  width: 26px;
  height: 3px;
  background: var(--color-magenta);
  border-radius: var(--radius-full);
  transition: all var(--duration-normal) var(--ease-bounce);
}

.mobile-toggle__line:nth-child(1) {
  transform-origin: left center;
}

.mobile-toggle__line:nth-child(2) {
  margin: 6px 0;
}

.mobile-toggle__line:nth-child(3) {
  transform-origin: left center;
}

.mobile-toggle.is-active .mobile-toggle__line:nth-child(1) {
  transform: rotate(45deg) translateY(-2px);
}

.mobile-toggle.is-active .mobile-toggle__line:nth-child(2) {
  opacity: 0;
  transform: translateX(-10px);
}

.mobile-toggle.is-active .mobile-toggle__line:nth-child(3) {
  transform: rotate(-45deg) translateY(2px);
}

/* --------------------------------------------------------------------------
   Mobile Menu Overlay
   -------------------------------------------------------------------------- */
.mobile-overlay {
  position: fixed;
  inset: 0;
  background: rgba(26, 26, 26, 0.5);
  backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition: all var(--duration-normal);
  z-index: var(--z-overlay);
}

.mobile-overlay.is-visible {
  opacity: 1;
  visibility: visible;
}

/* --------------------------------------------------------------------------
   Mobile Menu Panel
   -------------------------------------------------------------------------- */
.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  max-width: 400px;
  height: 100vh;
  background: var(--color-white);
  transform: translateX(100%);
  transition: transform var(--duration-slow) var(--ease-bounce);
  z-index: var(--z-mobile-menu);
  overflow-y: auto;
  padding: var(--spacing-xl);
  padding-top: var(--spacing-lg);
}

.mobile-menu.is-open {
  transform: translateX(0);
}

/* Mobile menu header with logo */
.mobile-menu__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--spacing-xl);
  padding-bottom: var(--spacing-lg);
  border-bottom: 2px solid var(--color-gray-100);
}

.mobile-menu__logo {
  height: 45px;
  width: auto;
  max-width: 240px;
  object-fit: contain;
}

.mobile-menu__close {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-gray-100);
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--duration-normal) var(--ease-bounce);
}

.mobile-menu__close:hover {
  background: var(--color-magenta);
  color: var(--color-white);
  transform: rotate(90deg);
}

.mobile-menu__close svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.mobile-menu__nav {
  margin-bottom: var(--spacing-xl);
}

.mobile-menu__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mobile-menu__item {
  border-bottom: 1px solid var(--color-gray-200);
}

.mobile-menu__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-md) 0;
  font-size: var(--font-size-lg);
  font-weight: 600;
  color: var(--color-gray-900);
  text-decoration: none;
  transition: color var(--duration-fast);
}

.mobile-menu__link:hover,
.mobile-menu__link:focus {
  color: var(--color-magenta);
}

.mobile-menu__link-icon {
  width: 20px;
  height: 20px;
  fill: currentColor;
  transition: transform var(--duration-normal) var(--ease-bounce);
}

.mobile-menu__item.is-open .mobile-menu__link-icon {
  transform: rotate(180deg);
}

/* Mobile submenu */
.mobile-submenu {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--duration-slow) var(--ease-smooth);
}

.mobile-menu__item.is-open .mobile-submenu {
  max-height: 1000px;
}

.mobile-submenu__list {
  list-style: none;
  padding: var(--spacing-sm) 0 var(--spacing-md) var(--spacing-md);
  margin: 0;
}

.mobile-submenu__title {
  font-family: var(--font-accent);
  font-size: var(--font-size-xs);
  font-weight: 700;
  color: var(--color-magenta);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: var(--spacing-sm) 0;
  margin-top: var(--spacing-md);
}

.mobile-submenu__title:first-child {
  margin-top: 0;
}

.mobile-submenu__link {
  display: block;
  padding: var(--spacing-sm) 0;
  font-size: var(--font-size-base);
  color: var(--color-gray-700);
  text-decoration: none;
  transition: all var(--duration-fast);
}

.mobile-submenu__link:hover,
.mobile-submenu__link:focus {
  color: var(--color-magenta);
  padding-left: var(--spacing-sm);
}

/* Mobile CTAs */
.mobile-menu__ctas {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  margin-top: var(--spacing-xl);
}

.mobile-menu__cta {
  width: 100%;
  padding: var(--spacing-md);
  text-align: center;
  font-family: var(--font-accent);
  font-size: var(--font-size-lg);
}

/* Mobile cart */
.mobile-menu__cart {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  margin-top: var(--spacing-md);
  padding: var(--spacing-md);
  background: var(--color-gray-100);
  border-radius: var(--radius-md);
  font-weight: 600;
  color: var(--color-gray-700);
  text-decoration: none;
  transition: all var(--duration-normal) var(--ease-bounce);
}

.mobile-menu__cart:hover {
  background: var(--color-magenta);
  color: var(--color-white);
}

.mobile-menu__cart svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.mobile-menu__cart-count {
  background: var(--color-orange);
  color: var(--color-white);
  font-size: var(--font-size-xs);
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

/* Mobile contact */
.mobile-menu__contact {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  margin-top: var(--spacing-xl);
  padding: var(--spacing-md);
  background: var(--color-gray-100);
  border-radius: var(--radius-md);
  font-weight: 600;
  color: var(--color-gray-700);
  text-decoration: none;
}

.mobile-menu__contact svg {
  width: 20px;
  height: 20px;
  fill: var(--color-teal);
}

/* Decorative paw prints in mobile menu */
.mobile-menu__decoration {
  position: absolute;
  bottom: 30px;
  left: 30px;
  opacity: 0.1;
  transform: rotate(-15deg);
}

.mobile-menu__decoration svg {
  width: 80px;
  height: 80px;
  fill: var(--color-magenta);
}

/* --------------------------------------------------------------------------
   Responsive - Smaller Desktops (1024px - 1400px)
   -------------------------------------------------------------------------- */
@media (max-width: 1400px) and (min-width: 1025px) {
  .header .logo__image {
    height: 42px;
    max-width: 160px;
  }

  .nav__link {
    font-size: 0.8rem;
    padding: var(--spacing-sm) var(--spacing-xs);
  }

  .contact span {
    display: none;
  }

  .contact__icon {
    width: 20px;
    height: 20px;
  }

  .cta {
    padding: var(--spacing-xs) var(--spacing-sm);
    font-size: 0.75rem;
  }

  .cta__paw {
    display: none;
  }

  .cart svg {
    width: 20px;
    height: 20px;
  }

  .search__toggle svg {
    width: 20px;
    height: 20px;
  }
}

/* Even smaller desktops (1024px - 1200px) */
@media (max-width: 1200px) and (min-width: 1025px) {
  .header .logo__image {
    height: 36px;
    max-width: 130px;
  }

  .nav__link {
    font-size: 0.7rem;
    padding: 4px 6px;
  }

  .header__inner {
    padding: 0 var(--spacing-sm);
    gap: 2px;
  }

  .cta {
    padding: 5px 8px;
    font-size: 0.65rem;
  }
}

/* --------------------------------------------------------------------------
   Responsive - Tablet and Mobile
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .nav,
  .search,
  .contact,
  .ctas {
    display: none;
  }

  .mobile-toggle {
    display: flex;
  }

  .header__inner {
    padding: 0 var(--spacing-md);
  }
}

/* Small mobile adjustments */
@media (max-width: 480px) {
  .logo__text {
    display: none;
  }

  .mobile-menu {
    max-width: 100%;
  }
}

/* --------------------------------------------------------------------------
   Accessibility
   -------------------------------------------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Focus styles */
.header :focus-visible {
  outline: 3px solid var(--color-magenta);
  outline-offset: 2px;
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  .header *, .header *::before, .header *::after,
  .mobile-menu *, .mobile-menu *::before, .mobile-menu *::after,
  .mobile-overlay {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* --------------------------------------------------------------------------
   Paw Print Click Effect (Global)
   -------------------------------------------------------------------------- */
.paw-print-effect {
  position: fixed;
  width: 30px;
  height: 30px;
  pointer-events: none;
  z-index: 9998;
  animation: paw-appear 0.6s var(--ease-bounce) forwards;
}

.paw-print-effect svg {
  width: 100%;
  height: 100%;
  fill: var(--color-magenta);
}

@keyframes paw-appear {
  0% {
    opacity: 0;
    transform: scale(0) rotate(-30deg);
  }
  50% {
    opacity: 0.7;
    transform: scale(1.2) rotate(0deg);
  }
  100% {
    opacity: 0;
    transform: scale(1) rotate(10deg) translateY(-20px);
  }
}

/* --------------------------------------------------------------------------
   Body Padding for Fixed Header
   -------------------------------------------------------------------------- */
body.has-playful-header {
  padding-top: var(--header-height);
}

/* ==========================================================================
   SEARCH RESULTS PAGE
   Matching the pet cards design from adopt page
   ========================================================================== */

/* Page Container - override parent theme's restrictive max-width */
body.search.has-playful-header .site-main {
  flex-grow: 1;
  width: 100% !important;
  max-width: 1200px !important;
  margin: 0 auto;
  padding: var(--spacing-2xl) var(--spacing-lg);
}

/* Search Results Header */
body.search.has-playful-header .site-main::before {
  content: 'Search Results';
  display: block;
  font-family: var(--font-accent);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  color: var(--color-gray-900);
  text-align: center;
  margin-bottom: var(--spacing-2xl);
}

/* Results Grid - target .page-content wrapper */
body.search.has-playful-header .site-main .page-content {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--spacing-lg);
}

/* Article Cards - matching adoptable-pet-card style */
body.search.has-playful-header article.post {
  background: var(--color-white);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
  position: relative;
  display: flex;
  flex-direction: column;
}

body.search.has-playful-header article.post:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* Image Container */
body.search.has-playful-header article.post > a:first-of-type:has(img),
body.search.has-playful-header article.post > a:first-child {
  display: block;
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
}

/* Article Images - matching pet card image style */
body.search.has-playful-header article.post img.wp-post-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

body.search.has-playful-header article.post:hover img.wp-post-image {
  transform: scale(1.03);
}

/* Content Info Area */
body.search.has-playful-header article.post .entry-title {
  font-family: var(--font-primary);
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
  padding: var(--spacing-md) var(--spacing-md) var(--spacing-xs);
  line-height: 1.3;
  color: var(--color-gray-900);
}

body.search.has-playful-header article.post .entry-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

body.search.has-playful-header article.post .entry-title a:hover {
  color: var(--color-magenta);
}

/* Entry Content/Excerpt */
body.search.has-playful-header article.post p {
  font-family: var(--font-primary);
  font-size: 0.875rem;
  color: var(--color-gray-500);
  line-height: 1.5;
  margin: 0;
  padding: 0 var(--spacing-md) var(--spacing-md);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex-grow: 1;
}

/* Read More CTA - matching "Meet [name]" style */
body.search.has-playful-header article.post::after {
  content: 'Learn More →';
  display: block;
  font-family: var(--font-primary);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-magenta);
  padding: 0 var(--spacing-md) var(--spacing-md);
  transition: color 0.2s ease;
}

body.search.has-playful-header article.post:hover::after {
  color: var(--color-magenta-dark);
}

/* Pagination */
body.search.has-playful-header .pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--spacing-lg);
  margin-top: var(--spacing-2xl);
  padding-top: var(--spacing-xl);
}

body.search.has-playful-header .pagination .nav-previous a,
body.search.has-playful-header .pagination .nav-next a {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  font-family: var(--font-primary);
  font-size: var(--font-size-base);
  font-weight: 600;
  color: var(--color-magenta);
  background: transparent;
  padding: var(--spacing-sm) var(--spacing-lg);
  border: 2px solid var(--color-magenta);
  border-radius: var(--radius-full);
  text-decoration: none;
  transition:
    background 0.2s ease,
    color 0.2s ease;
}

body.search.has-playful-header .pagination .nav-previous a:hover,
body.search.has-playful-header .pagination .nav-next a:hover {
  background: var(--color-magenta);
  color: var(--color-white);
}

body.search.has-playful-header .pagination .meta-nav {
  font-size: 1.1em;
}

/* No Results State */
body.search.has-playful-header .site-main .no-results {
  grid-column: 1 / -1;
  text-align: center;
  padding: var(--spacing-3xl);
  background: #f9f9f9;
  border-radius: 16px;
}

body.search.has-playful-header .site-main .no-results h2 {
  font-family: var(--font-primary);
  font-size: 1.5rem;
  color: var(--color-gray-900);
  margin-bottom: var(--spacing-md);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  body.search.has-playful-header .site-main .page-content {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
  }

  body.search.has-playful-header .site-main {
    padding: var(--spacing-lg) var(--spacing-md);
  }

  body.search.has-playful-header .site-main::before {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-lg);
  }
}

@media (max-width: 480px) {
  body.search.has-playful-header .site-main .page-content {
    grid-template-columns: 1fr;
  }

  body.search.has-playful-header article.post > a:first-of-type:has(img),
  body.search.has-playful-header article.post > a:first-child {
    aspect-ratio: 1 / 1;
  }
}
