/*
 * Pet Signal Guide public-site polish.
 * Scope: approved category archives, primary menu touch target, and shared
 * archive presentation. All selectors remain site-specific.
 */

.main-header-menu-toggle,
button.menu-toggle {
  min-width: 44px;
  min-height: 44px;
  box-sizing: border-box;
}

body.category {
  background: #f4f8f6;
}

body.category .site-content {
  background:
    radial-gradient(circle at 84% 8%, rgba(23, 120, 101, 0.14), transparent 30%),
    radial-gradient(circle at 10% 4%, rgba(244, 184, 76, 0.12), transparent 25%),
    linear-gradient(180deg, #f3f8f6 0%, #eef5f2 48%, #f7faf8 100%);
}

body.category #primary {
  margin-top: 48px;
  margin-bottom: 80px;
}

body.category .site-main {
  width: min(1160px, 100%);
  margin-inline: auto;
}

body.category .ast-archive-description {
  position: relative;
  overflow: hidden;
  width: min(1160px, 100%);
  margin: 0 auto 28px;
  padding: clamp(32px, 5vw, 56px);
  border: 1px solid rgba(201, 221, 211, 0.95);
  border-radius: 30px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(243, 250, 247, 0.88)),
    radial-gradient(circle at 88% 18%, rgba(23, 120, 101, 0.16), transparent 28%);
  box-shadow: 0 24px 70px rgba(20, 32, 29, 0.09);
}

body.category .ast-archive-description::after {
  content: "";
  position: absolute;
  right: -74px;
  top: -82px;
  width: 260px;
  height: 260px;
  border: 1px solid rgba(23, 120, 101, 0.12);
  border-radius: 999px;
  background:
    radial-gradient(circle, rgba(23, 120, 101, 0.13), transparent 62%),
    repeating-radial-gradient(circle, rgba(23, 120, 101, 0.11) 0 1px, transparent 1px 24px);
  pointer-events: none;
}

body.category .ast-archive-title {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: flex-end;
  gap: 16px;
  max-width: 820px;
  margin: 0;
  color: #0f4d42;
  font-size: clamp(2.7rem, 5.5vw, 4.9rem);
  font-weight: 900;
  letter-spacing: -0.065em;
  line-height: 0.96;
}

body.category .ast-archive-title::after {
  content: "";
  display: inline-block;
  flex: 0 0 auto;
  width: clamp(48px, 7vw, 86px);
  height: clamp(7px, 0.8vw, 11px);
  margin-bottom: 0.16em;
  border-radius: 999px;
  background: linear-gradient(90deg, #177865 0%, #f4b84c 100%);
  box-shadow: 0 10px 24px rgba(23, 120, 101, 0.16);
}

body.category .ast-archive-description p {
  position: relative;
  z-index: 1;
  max-width: 780px;
  margin: 18px 0 0;
  color: #4b625c;
  font-size: clamp(1.02rem, 1.7vw, 1.18rem);
  line-height: 1.7;
}

body.category .ast-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 350px), 1fr));
  gap: 28px;
  width: min(1160px, 100%);
  margin: 0 auto;
}

body.category .ast-article-post {
  width: 100%;
  padding: 0 !important;
}

body.category .ast-article-post .ast-article-inner {
  height: 100%;
  overflow: hidden;
  padding: 0;
  border: 1px solid rgba(201, 221, 211, 0.95);
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 48px rgba(20, 32, 29, 0.08);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

body.category .ast-article-post .ast-article-inner:hover {
  transform: translateY(-3px);
  border-color: rgba(23, 120, 101, 0.32);
  box-shadow: 0 26px 68px rgba(20, 32, 29, 0.12);
}

/*
 * Archive cards are vertical at every viewport.
 *
 * The archive parent becomes a multi-column grid as soon as a category has
 * more than one post. A fixed two-column layout inside each card therefore
 * overflows the card even when the page itself reports no horizontal scroll.
 * Keep this selector more specific than the historical Pet Tech Customizer
 * snapshot so the source-controlled plugin remains the durable owner.
 */
body.category .site-main .post-content {
  display: flex;
  flex-direction: column;
  min-height: 100%;
  min-width: 0;
}

body.category .site-main .post-content > * {
  min-width: 0;
}

body.category .ast-blog-featured-section,
body.category .post-thumb-img-content,
body.category .post-thumb-img-content a {
  display: block;
  margin: 0 !important;
}

body.category .site-main .ast-blog-featured-section {
  grid-row: auto;
  min-height: 0;
  overflow: hidden;
}

body.category .site-main .ast-blog-featured-section img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  object-fit: cover;
}

body.category .ast-taxonomy-container {
  margin: 34px 34px 12px;
}

body.category .ast-taxonomy-container a {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 7px 12px;
  border: 1px solid rgba(23, 120, 101, 0.18);
  border-radius: 999px;
  background: #eef8f2;
  color: #126a5a;
  font-size: 0.73rem;
  font-weight: 820;
  letter-spacing: 0.06em;
  line-height: 1;
  text-decoration: none;
  text-transform: uppercase;
}

body.category .entry-title {
  margin: 0 34px 14px;
  font-size: clamp(1.45rem, 2vw, 2rem);
  font-weight: 820;
  letter-spacing: -0.035em;
  line-height: 1.12;
}

body.category .entry-title a {
  color: #10201c;
  overflow-wrap: break-word;
  text-decoration: none;
}

body.category .entry-title a:hover,
body.category .entry-title a:focus {
  color: #126a5a;
}

body.category .entry-header {
  margin: 0 34px 14px;
  color: #6a7e77;
  font-size: 0.88rem;
}

body.category .ast-excerpt-container,
body.category .entry-content {
  margin: 0 34px 28px;
  color: #4b625c;
  font-size: 1rem;
  line-height: 1.66;
}

body.category .read-more {
  margin: auto 34px 34px;
}

body.category .read-more a,
body.category .ast-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 12px 16px;
  border-radius: 999px;
  background: #177865;
  color: #fff !important;
  font-weight: 780;
  text-decoration: none;
}

body.category .read-more a:hover,
body.category .read-more a:focus,
body.category .ast-button:hover,
body.category .ast-button:focus {
  background: #0f4d42;
}

@media (max-width: 921px) {
  body.category #primary {
    margin-top: 24px;
    margin-bottom: 56px;
  }

  body.category .site-content .ast-container {
    padding-left: 18px;
    padding-right: 18px;
  }

  body.category .ast-archive-description {
    border-radius: 24px;
  }

  body.category .site-main .post-content {
    display: flex;
    flex-direction: column;
  }

  body.category .site-main .ast-blog-featured-section {
    grid-row: auto;
    min-height: 0;
  }

  body.category .site-main .ast-blog-featured-section img {
    height: auto;
  }
}

@media (max-width: 544px) {
  body.category .site-content .ast-container {
    padding-left: 14px;
    padding-right: 14px;
  }

  body.category .ast-archive-description {
    padding: 26px 22px;
    border-radius: 22px;
  }

  body.category .ast-archive-title {
    gap: 10px;
    font-size: clamp(2.35rem, 12vw, 3.15rem);
  }

  body.category .ast-archive-title::after {
    width: 38px;
    height: 7px;
  }

  body.category .ast-taxonomy-container,
  body.category .entry-title,
  body.category .entry-header,
  body.category .ast-excerpt-container,
  body.category .entry-content,
  body.category .read-more {
    margin-left: 20px;
    margin-right: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.category .ast-article-post .ast-article-inner {
    transition: none;
  }

  body.category .ast-article-post .ast-article-inner:hover {
    transform: none;
  }
}
