/*
 * parent_categories.css — /categories/ (body.footer-categories only).
 * Single source of truth (legacy minify + layered overrides removed).
 * Content shell: .catalog-main → PVC-like surface, --storefront-content-max (1248px).
 * Cards: .catalog-card BEM; submenu flyout must not be clipped by the shell.
 */

/* ---------------------------------------------------------------------------
 * Tokens & page shell
 * --------------------------------------------------------------------------- */
body.footer-categories {
  --pc-blue: #0b3672;
  --pc-dark: #071d42;
  --pc-muted: #31527f;
  --pc-gap: 28px;
  --pc-surface: #eef4fb;
  --pc-surface-border: rgba(11, 54, 114, 0.08);
  --pc-side-gutter: 30px;
  --pc-serif: var(--font-display);
  --pc-sans: var(--font-sans);
  margin: 0;
  color: var(--pc-dark);
  /* PVC-like page backdrop (same contract as homepage / pvc-guide). */
  background-color: #f3f8fe;
  background-image: linear-gradient(135deg, #fbfdff 0%, #edf5ff 48%, #f7fbff 100%);
  box-sizing: border-box;
}

body.footer-categories *,
body.footer-categories *::before,
body.footer-categories *::after {
  box-sizing: border-box;
}

body.footer-categories .page {
  min-height: 100vh;
  font-family: var(--font-sans);
  background-color: #f3f8fe;
  background-image: linear-gradient(135deg, #fbfdff 0%, #edf5ff 48%, #f7fbff 100%);
}

body.footer-categories .page a {
  text-decoration: none;
  color: inherit;
}

/*
 * White content surface mirrors home .site-shell / PVC .pvc-guide__surface.
 * Keep overflow visible so category submenus are not clipped.
 */
.catalog-main {
  --catalog-shell-radius: 12px;
  position: relative;
  isolation: isolate;
  width: min(var(--storefront-content-max, 1248px), calc(100% - 32px));
  max-width: var(--storefront-content-max, 1248px);
  margin: 18px auto 36px;
  overflow: visible;
  background: #fff;
  border: 1px solid rgba(116, 156, 204, 0.28);
  border-radius: var(--catalog-shell-radius);
  box-shadow: 0 18px 48px rgba(23, 73, 130, 0.08);
}

.catalog-main > .catalog-blueprint-banner,
.catalog-main > .catalog-category-cards:last-child {
  border-bottom-left-radius: var(--catalog-shell-radius);
  border-bottom-right-radius: var(--catalog-shell-radius);
  overflow: hidden;
}

.catalog-main > * {
  position: relative;
  z-index: 1;
}

/* ---------------------------------------------------------------------------
 * Hero
 * --------------------------------------------------------------------------- */
.hero {
  position: relative;
  min-height: 420px;
  overflow: hidden;
  border-bottom: 1px solid rgba(221, 234, 250, 0.22);
  border-top-left-radius: var(--catalog-shell-radius);
  border-top-right-radius: var(--catalog-shell-radius);
  background: #071a31;
}

/*
 * Desktop hero (variant A): full photo + HTML copy on left navy wall.
 * Spacing: left clear zone of artboard ~35–40% solid blue; logo sits top-left
 * on the wall → copy starts below logo (~12–14% from top), left gutter ~3–4%.
 * Mobile: see ≤767 (text stack then media, notebook grid).
 */
.hero--image {
  position: relative;
  min-height: 0;
  overflow: hidden;
}

.hero--image .hero-photo {
  position: relative;
  inset: auto;
  aspect-ratio: auto;
  min-height: 0;
  line-height: 0;
  overflow: hidden;
}

.hero--image .hero-photo__picture {
  position: relative;
  inset: auto;
  display: block;
  width: 100%;
}

.hero--image .hero-photo img {
  position: relative;
  inset: auto;
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  object-fit: contain;
  object-position: center top;
}

/* Desktop: overlay copy on left edge of photo (not clipped, not image-map links) */
@media (min-width: 768px) {
  .hero--image.hero--with-copy .hero-content {
    position: absolute;
    z-index: 3;
    left: 0;
    top: 0;
    bottom: 0;
    /* ~ left wall width of showroom art (~36–40%) */
    width: min(38%, 440px);
    min-width: 240px;
    min-height: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    /* top padding + gentle nudge down (~78px pad nudge + 9px translate = ~87px total) */
    padding:
      clamp(18px, calc(14% - 78px), 50px)
      clamp(20px, 2.4vw, 36px)
      clamp(36px, 5%, 56px)
      clamp(28px, 3.2vw, 52px);
    margin: 0;
    overflow: visible;
    clip: auto;
    white-space: normal;
    isolation: isolate;
    pointer-events: none; /* text not blocking image; no live hotspots */
    transform: translateY(9px);
  }

  .hero--image.hero--with-copy .hero-content::before {
    /* soft plate follows text (same +9px as transform) */
    inset: clamp(6px, calc(11% - 78px), 22px) clamp(12px, 1.5vw, 20px) clamp(28px, 4%, 40px) clamp(16px, 2vw, 28px);
    transform: translateY(9px);
    border: 0;
    border-radius: 0;
    background: linear-gradient(
      90deg,
      rgba(8, 28, 56, 0.22) 0%,
      rgba(8, 28, 56, 0.08) 70%,
      transparent 100%
    );
    box-shadow: none;
  }

  .hero--image.hero--with-copy .hero-content h1,
  .hero--image.hero--with-copy .hero-content p,
  .hero--image.hero--with-copy .hero-content__rule,
  .hero--image.hero--with-copy .hero-content .hero-cta {
    pointer-events: auto;
  }

  .hero--image.hero--with-copy h1 {
    color: #f7f9fc;
    font-size: clamp(36px, 4.5vw, 48px);
    line-height: 1.02;
    text-shadow: 0 2px 18px rgba(0, 0, 0, 0.25);
  }

  .hero--image.hero--with-copy .hero-content__rule {
    background: #8eb6e8;
    margin: 18px 0 14px;
  }

  .hero--image.hero--with-copy .hero-content p {
    color: #edf4fc;
    font-family: var(--font-sans);
    font-size: var(--text-xl);
    font-weight: 400;
    letter-spacing: 0.02em;
    text-transform: none;
    max-width: 46ch;
    text-shadow: 0 1px 14px rgba(0, 0, 0, 0.3);
  }
}

.hero-blueprint {
  position: absolute;
  inset: 0 62% 0 0;
  z-index: 1;
  background:
    linear-gradient(rgba(210, 228, 249, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(210, 228, 249, 0.045) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: linear-gradient(90deg, #000 0 68%, transparent 100%);
  pointer-events: none;
}

.hero-photo {
  position: absolute;
  z-index: 0;
  inset: 0;
  overflow: hidden;
  background: image-set(
      url("../../images/pages/parent-categories/hero-dark-showcase-v4.webp") type("image/webp"),
      url("../../images/pages/parent-categories/hero-dark-showcase-v4.jpg") type("image/jpeg")
    ) center / cover no-repeat;
}

.hero-angle {
  position: absolute;
  z-index: 1;
  inset: 0;
  background: linear-gradient(90deg, rgba(5, 22, 43, 0.34) 0 35%, rgba(5, 22, 43, 0.12) 48%, transparent 62%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  width: 42%;
  min-height: 420px;
  min-width: 0;
  flex-direction: column;
  justify-content: center;
  padding: 50px 48px 50px 52px;
  isolation: isolate;
}

.hero-content::before {
  content: "";
  position: absolute;
  inset: 22px 12px 22px 20px;
  z-index: -1;
  border: 1px solid rgba(214, 230, 249, 0.14);
  background: rgba(5, 22, 43, 0.28);
  box-shadow: 0 18px 48px rgba(0, 8, 19, 0.14);
}

.hero h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(36px, 4.5vw, 48px);
  line-height: 0.93;
  letter-spacing: -0.045em;
  margin: 0;
  color: #f7f9fc;
}

.hero-content__rule {
  display: block;
  width: 37px;
  height: 2px;
  background: #91b8e5;
  margin: 26px 0 20px;
}

.hero-content p {
  margin: 0;
  font-family: var(--font-sans);
  font-weight: 400;
  letter-spacing: 0.02em;
  font-size: var(--text-lg);
  line-height: 1.3;
  color: #d9e7f7;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 22px;
  padding: 12px 24px;
  background: #f4f8fd;
  color: #0b3672;
  font-size: var(--text-small);
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1;
  border: 1px solid rgba(244, 248, 253, 0.55);
  border-radius: 3px;
  box-shadow: 0 8px 24px rgba(0, 10, 26, 0.25);
  transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.hero-cta:hover {
  background: #ffffff;
  color: #082a57;
  transform: translateY(-1px);
}

/* ---------------------------------------------------------------------------
 * CMS images for the three visual slots of /categories/.
 * Banners + hero photo custom upload sizing.
 * --------------------------------------------------------------------------- */
.hero-photo--custom {
  background-image: none;
}

.hero-photo__picture {
  position: absolute;
  inset: 0;
  display: block;
}

.hero-photo img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  object-fit: cover;
  object-position: center;
}

.catalog-hero-banner,
.catalog-blueprint-banner {
  width: 100%;
  max-width: 100%;
  line-height: 0;
  overflow: hidden;
}

.catalog-hero-banner {
  margin-top: 9px;
  aspect-ratio: 1645 / 283;
}

.catalog-blueprint-banner {
  margin: 20px 0 0;
  aspect-ratio: 2172 / 724;
}

.catalog-page-banner__link {
  display: block;
  width: 100%;
  height: 100%;
}

.catalog-hero-banner img,
.catalog-blueprint-banner img,
.catalog-hero-banner picture,
.catalog-blueprint-banner picture {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
}

.catalog-hero-banner img {
  object-fit: cover;
  object-position: center;
}

.catalog-blueprint-banner img {
  object-fit: contain;
  object-position: center;
}

/* ---------------------------------------------------------------------------
 * Intro content block under the hero (styled, top of the page)
 * --------------------------------------------------------------------------- */
.catalog-intro {
  position: relative;
  overflow: hidden;
  padding: clamp(34px, 5vw, 64px) clamp(24px, 4.5vw, 56px);
  background:
    radial-gradient(120% 110% at 50% -10%, rgba(255, 255, 255, 0.92) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(180deg, #fdfeff 0%, #eaf2fb 100%);
  border-bottom: 1px solid rgba(11, 54, 114, 0.1);
}

.catalog-intro::after {
  content: "";
  position: absolute;
  top: 0;
  left: 6%;
  right: 6%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.95) 50%, transparent);
  pointer-events: none;
}

.catalog-intro h2 {
  position: relative;
  padding-top: 18px;
  margin: 0 0 14px;
  color: var(--pc-dark);
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(22px, 3vw, 28px);
  line-height: 1.08;
  letter-spacing: -0.02em;
}

.catalog-intro h2::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 52px;
  height: 2px;
  background: #123c86;
}

.catalog-intro p {
  margin: 0 0 12px;
  max-width: 80ch;
  color: var(--pc-muted);
  font-size: var(--text-lg);
  line-height: 1.7;
}

.catalog-intro p:last-child {
  margin-bottom: 0;
}

/* ---------------------------------------------------------------------------
 * Catalog grid
 * --------------------------------------------------------------------------- */
.catalog {
  padding: 16px 30px 32px;
}

.catalog-rows {
  display: flex;
  flex-direction: column;
  gap: var(--pc-gap);
}

.grid {
  display: grid;
  gap: var(--pc-gap);
}

.grid-row--three {
  grid-template-columns: repeat(3, 1fr);
}

.grid-row--two {
  grid-template-columns: repeat(2, 1fr);
}

/* ---------------------------------------------------------------------------
 * Cards (scoped refresh — BEM .catalog-card)
 * Scoped refresh for the existing /categories/ cards only.
 * --------------------------------------------------------------------------- */
.catalog-category-cards .grid-row--three .catalog-card {
  height: 300px;
  min-height: 300px;
}

.catalog-category-cards .grid-row--two .catalog-card {
  height: 320px;
  min-height: 320px;
}

.catalog-category-cards .catalog-card {
  --catalog-card-copy-left: 16px;
  --catalog-card-copy-bottom: 16px;
  --catalog-card-copy-width: min(78%, 360px);
  --catalog-card-action-inset: 13px;
  --catalog-card-action-size: 44px;
  /* Arrow (44) + insets must always fit inside the white label. */
  --catalog-card-copy-min-height: calc(
    var(--catalog-card-action-size) + 2 * var(--catalog-card-action-inset)
  );
  display: block;
  position: relative;
  border: 1px solid rgba(63, 125, 185, 0.22);
  border-radius: 12px;
  overflow: hidden;
  background: #eaf2fa;
  box-shadow: 0 10px 28px rgba(34, 83, 130, 0.1);
  isolation: isolate;
  transition:
    transform 280ms cubic-bezier(0.2, 0.7, 0.2, 1),
    border-color 280ms ease,
    box-shadow 280ms ease;
}

.catalog-category-cards .catalog-card--with-submenu {
  overflow: visible;
}

.catalog-category-cards .catalog-card--with-submenu.is-submenu-open {
  z-index: 30;
}

.catalog-category-cards .catalog-card__main-link,
.catalog-category-cards .catalog-card__main-surface {
  position: absolute;
  inset: 0;
  display: block;
  overflow: hidden;
  border-radius: inherit;
  color: inherit;
}

.catalog-category-cards .catalog-card__main-link:focus-visible {
  outline: 3px solid rgba(18, 76, 132, 0.62);
  outline-offset: -3px;
}

.catalog-category-cards .catalog-card__image,
.catalog-category-cards .catalog-card__image-placeholder {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
}

.catalog-category-cards .catalog-card__image {
  z-index: 0;
  object-fit: cover;
  object-position: center;
  opacity: 1;
  filter: none;
  transform: scale(1);
  transition: transform 320ms cubic-bezier(0.2, 0.7, 0.2, 1);
}

.catalog-category-cards picture.catalog-card__image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.catalog-category-cards .catalog-card__image-placeholder {
  z-index: 0;
  background: linear-gradient(145deg, #eef5fb, #dceaf6);
}

.catalog-category-cards .catalog-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(to top, rgba(15, 48, 84, 0.14), transparent 45%);
  opacity: 1;
  mix-blend-mode: normal;
}

.catalog-category-cards .catalog-card::after {
  content: "";
  position: absolute;
  top: 14px;
  right: 14px;
  bottom: auto;
  left: auto;
  width: 54px;
  height: 54px;
  z-index: 2;
  pointer-events: none;
  border-top: 1px solid rgba(116, 169, 214, 0.34);
  border-right: 1px solid rgba(116, 169, 214, 0.34);
  background: none;
  opacity: 0.72;
}

.catalog-category-cards .catalog-card__copy {
  position: absolute;
  left: var(--catalog-card-copy-left);
  bottom: var(--catalog-card-copy-bottom);
  z-index: 3;
  display: flex;
  width: var(--catalog-card-copy-width);
  min-width: 0;
  min-height: var(--catalog-card-copy-min-height);
  align-items: center;
  padding: 17px 18px 16px;
  /* 65% transparent white (desktop + mobile) */
  background: rgba(247, 251, 255, 0.35);
  border: 1px solid rgba(70, 130, 190, 0.28);
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(34, 83, 130, 0.08);
}

.catalog-category-cards .catalog-card__copy--linked {
  padding-right: 72px;
}

@supports ((backdrop-filter: blur(8px)) or (-webkit-backdrop-filter: blur(8px))) {
  .catalog-category-cards .catalog-card__copy {
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
  }
}

.catalog-category-cards .catalog-card__copy h2 {
  margin: 0;
  color: #0b2347;
  font-family: var(--font-sans);
  font-size: var(--text-xl);
  font-weight: var(--fw-title);
  line-height: 1.08;
  letter-spacing: -0.025em;
  overflow-wrap: anywhere;
}

.catalog-category-cards .catalog-card__arrow {
  position: absolute;
  top: 50%;
  right: var(--catalog-card-action-inset);
  bottom: auto;
  display: grid;
  width: var(--catalog-card-action-size);
  height: var(--catalog-card-action-size);
  place-items: center;
  border-radius: 10px;
  background: #123f76;
  color: #f8fbff;
  font-family: var(--font-sans);
  font-size: var(--text-2xl);
  line-height: 1;
  /* Optical nudge: → glyph sits heavy on the right in most fonts. */
  padding: 0 0 1px 2px;
  box-shadow: 0 7px 18px rgba(18, 63, 118, 0.18);
  transform: translateY(-50%);
  transition: transform 280ms ease, background-color 280ms ease;
}

.catalog-category-cards .catalog-card__submenu-wrap {
  position: absolute;
  right: auto;
  bottom: var(--catalog-card-copy-bottom);
  left: calc(
    var(--catalog-card-copy-left) + var(--catalog-card-copy-width)
    - var(--catalog-card-action-inset) - var(--catalog-card-action-size)
  );
  z-index: 5;
  display: grid;
  width: var(--catalog-card-action-size);
  height: var(--catalog-card-copy-min-height);
  place-items: center;
}

.catalog-category-cards .catalog-card__menu-trigger {
  position: relative;
  top: auto;
  right: auto;
  bottom: auto;
  padding: 0 0 1px 2px;
  border: 0;
  cursor: pointer;
  transform: none;
}

.catalog-category-cards .catalog-card__menu-trigger:focus-visible {
  outline: 3px solid #2d72c6;
  outline-offset: 3px;
}

.catalog-category-cards .catalog-card__submenu {
  --submenu-left: 56px;
  --submenu-top: 0px;
  --submenu-width: 260px;
  position: absolute;
  top: var(--submenu-top);
  left: var(--submenu-left);
  z-index: 1;
  display: none;
  width: var(--submenu-width);
  max-width: calc(100vw - 24px);
  max-height: min(60vh, 360px);
  overflow-x: hidden;
  overflow-y: auto;
  visibility: hidden;
  padding: 8px;
  border: 1px solid #b9cce4;
  border-radius: 10px;
  background: linear-gradient(180deg, #fff 0%, #f5faff 100%);
  box-shadow: 0 18px 38px rgba(8, 46, 108, 0.18);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px) scale(0.98);
  transform-origin: top right;
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s linear 0.22s;
}

.catalog-category-cards .catalog-card--with-submenu.is-submenu-open .catalog-card__submenu,
.catalog-category-cards .catalog-card__submenu.is-open {
  display: block;
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
  transform: none;
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0s;
}

.catalog-category-cards .catalog-card__submenu-list {
  display: grid;
  gap: 3px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.catalog-category-cards .catalog-card__submenu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 38px;
  padding: 8px 10px;
  border-radius: 6px;
  color: #173f78;
  font-size: var(--text-caption);
  font-weight: 700;
  line-height: 1.3;
  transition: background-color 0.18s ease, color 0.18s ease;
}

.catalog-category-cards a.catalog-card__submenu-item:hover {
  color: #fff;
  background: #0a438f;
}

.catalog-category-cards a.catalog-card__submenu-item:focus-visible {
  outline: 2px solid #2d72c6;
  outline-offset: -2px;
}

.catalog-category-cards a.catalog-card:focus-visible {
  outline: 3px solid rgba(18, 76, 132, 0.62);
  outline-offset: 3px;
  border-color: rgba(18, 76, 132, 0.58);
}

@media (hover: hover) and (pointer: fine) {
  .catalog-category-cards a.catalog-card:hover,
  .catalog-category-cards .catalog-card[data-has-children="true"]:hover {
    transform: translateY(-4px);
    border-color: rgba(44, 111, 174, 0.42);
    box-shadow: 0 16px 36px rgba(34, 83, 130, 0.16);
  }

  .catalog-category-cards a.catalog-card:hover .catalog-card__image,
  .catalog-category-cards .catalog-card[data-has-children="true"]:hover .catalog-card__image {
    transform: scale(1.025);
  }

  .catalog-category-cards a.catalog-card:hover .catalog-card__arrow {
    transform: translateY(-50%) translateX(4px);
    background: #0b3568;
  }

  .catalog-category-cards .catalog-card[data-has-children="true"]:hover .catalog-card__arrow {
    transform: translateX(4px);
    background: #0b3568;
  }
}

@media (prefers-reduced-motion: reduce) {
  .catalog-category-cards .catalog-card,
  .catalog-category-cards .catalog-card__image,
  .catalog-category-cards .catalog-card__arrow,
  .catalog-category-cards .catalog-card__submenu,
  .catalog-category-cards .catalog-card__submenu-item {
    transition: none;
  }

  .catalog-category-cards a.catalog-card:hover,
  .catalog-category-cards .catalog-card[data-has-children="true"]:hover,
  .catalog-category-cards a.catalog-card:hover .catalog-card__image,
  .catalog-category-cards .catalog-card[data-has-children="true"]:hover .catalog-card__image {
    transform: none;
  }

  .catalog-category-cards a.catalog-card:hover .catalog-card__arrow {
    transform: translateY(-50%);
  }

  .catalog-category-cards .catalog-card[data-has-children="true"]:hover .catalog-card__arrow {
    transform: none;
  }
}

/* ---------------------------------------------------------------------------
 * A11y helpers
 * --------------------------------------------------------------------------- */
.catalog-visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* ---------------------------------------------------------------------------
 * Responsive
 * --------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .hero {
    min-height: 390px;
  }

  .hero-blueprint {
    right: 58%;
  }

  .hero-content {
    width: 48%;
    min-height: 390px;
    padding: 42px 36px 42px 32px;
  }

  .hero h1 {
    font-size: clamp(36px, 4.5vw, 48px);
  }

  .grid-row--three,
  .grid-row--two {
    grid-template-columns: 1fr;
  }

  .catalog-category-cards .catalog-card {
    --catalog-card-copy-width: min(68%, 410px);
  }

  .catalog-category-cards .grid-row--three .catalog-card,
  .catalog-category-cards .grid-row--two .catalog-card {
    height: 340px;
    min-height: 340px;
  }
}

@media (max-width: 767px) {
  body.footer-categories {
    --pc-side-gutter: 16px;
  }

  body.footer-categories .catalog-hero-banner,
  body.footer-categories .catalog-blueprint-banner {
    display: none;
  }

  /* Hidden footer banner still matches :last-child; round cards section instead. */
  .catalog-main > .catalog-category-cards {
    border-bottom-left-radius: var(--catalog-shell-radius);
    border-bottom-right-radius: var(--catalog-shell-radius);
    overflow: hidden;
  }

  /* Mobile hero: light paper notebook grid (site tone), text then drawing */
  .hero {
    display: flex;
    min-height: 0;
    flex-direction: column;
    background-color: #f3f8fe;
    background-image:
      linear-gradient(rgba(18, 60, 134, 0.07) 1px, transparent 1px),
      linear-gradient(90deg, rgba(18, 60, 134, 0.07) 1px, transparent 1px);
    background-size: 28px 28px, 28px 28px;
    background-position: center top;
  }

  .hero-blueprint {
    inset: 0 0 auto;
    width: 100%;
    height: 244px;
    mask-image: linear-gradient(180deg, #000 0 72%, transparent 100%);
  }

  .hero--image,
  .hero--image.hero--with-copy {
    display: flex;
    flex-direction: column;
  }

  .hero--image .hero-content,
  .hero--image.hero--with-copy .hero-content {
    position: relative !important;
    z-index: 2;
    order: 1;
    left: auto !important;
    top: auto !important;
    bottom: auto !important;
    width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    height: auto !important;
    margin: 0 !important;
    padding: 28px 20px 18px !important;
    overflow: visible !important;
    clip: auto !important;
    white-space: normal !important;
    background: transparent;
    pointer-events: auto !important;
    transform: none !important;
  }

  .hero--image .hero-content::before,
  .hero--image.hero--with-copy .hero-content::before {
    display: none;
    transform: none !important;
  }

  .hero--image.hero--with-copy h1 {
    color: #0e3477;
    font-size: clamp(36px, 4.5vw, 48px);
    text-shadow: none;
  }

  .hero--image.hero--with-copy .hero-content p {
    color: #49618d;
    font-family: var(--font-display);
    text-transform: none;
    font-weight: 400;
    letter-spacing: 0.01em;
    text-shadow: none;
    max-width: none;
  }

  .hero--image.hero--with-copy .hero-content__rule {
    background: #123c86;
  }

  .hero--image .hero-content .hero-cta {
    margin-top: 18px;
    padding: 11px 20px;
    font-size: var(--text-caption);
    background: #0e3477;
    color: #f4f8fd;
    border-color: transparent;
    box-shadow: 0 6px 18px rgba(11, 54, 114, 0.18);
  }

  .hero--image .hero-photo,
  .hero--image .hero-photo--custom {
    position: relative;
    inset: auto;
    z-index: 1;
    order: 2;
    width: 100%;
    min-height: 0;
    aspect-ratio: auto;
    line-height: 0;
    background-color: transparent;
    background-image: none;
  }

  .hero--image .hero-photo__picture {
    position: relative;
    inset: auto;
    display: block;
  }

  .hero--image .hero-photo img {
    position: relative;
    inset: auto;
    width: 100%;
    height: auto;
    max-width: 100%;
    object-fit: contain;
    object-position: center top;
  }

  .hero-photo {
    position: relative;
    inset: auto;
    z-index: 1;
    order: 2;
    width: 100%;
    min-height: 0;
    aspect-ratio: 4 / 3;
    background-image: image-set(
      url("../../images/pages/parent-categories/hero-catalog-collage-mobile.webp") type("image/webp"),
      url("../../images/pages/parent-categories/hero-catalog-collage-mobile.jpg") type("image/jpeg")
    );
    background-position: center;
  }

  .hero-angle {
    inset: 0 0 auto;
    height: 244px;
    background: linear-gradient(90deg, rgba(5, 22, 43, 0.38), rgba(5, 22, 43, 0.08));
  }

  .hero-content {
    z-index: 2;
    order: 1;
    width: 100%;
    min-height: 0;
    padding: 28px 20px 18px;
  }

  .hero-content::before {
    display: none;
  }

  .hero h1 {
    font-size: clamp(36px, 4.5vw, 48px);
    color: #0e3477;
  }

  .hero-content__rule {
    background: #123c86;
  }

  .hero-content p {
    font-family: var(--font-sans);
    font-size: var(--text-md);
    letter-spacing: 0.01em;
    color: #49618d;
    text-transform: none;
    font-weight: 400;
  }

  .catalog {
    padding: 18px 16px 26px;
  }

  .catalog-intro {
    padding: 26px 20px;
    background-color: #f3f8fe;
    background-image:
      linear-gradient(rgba(18, 60, 134, 0.07) 1px, transparent 1px),
      linear-gradient(90deg, rgba(18, 60, 134, 0.07) 1px, transparent 1px);
    background-size: 28px 28px;
    border-bottom: 1px solid rgba(11, 54, 114, 0.08);
  }

  .catalog-intro::after {
    display: none;
  }

  .catalog-intro h2 {
    padding-top: 16px;
    font-size: clamp(22px, 3vw, 28px);
  }

  .catalog-intro p {
    font-size: var(--text-body);
    line-height: 1.6;
  }

  .catalog-rows {
    gap: 20px;
  }

  .grid-row--three,
  .grid-row--two {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .catalog-category-cards .catalog-card {
    --catalog-card-copy-left: 12px;
    --catalog-card-copy-bottom: 12px;
    --catalog-card-copy-width: calc(100% - 24px);
  }

  .catalog-category-cards .grid-row--three .catalog-card,
  .catalog-category-cards .grid-row--two .catalog-card,
  .catalog-category-cards .catalog-card,
  .catalog-category-cards .catalog-card--row-three {
    height: 320px;
    min-height: 320px;
  }

  .catalog-category-cards .catalog-card__copy {
    padding: 12px 16px;
    min-height: calc(var(--catalog-card-copy-min-height) - 8px);
  }

  .catalog-category-cards .catalog-card__copy--linked {
    padding-right: 68px;
  }

  .catalog-category-cards .catalog-card__copy h2 {
    font-family: var(--font-sans);
  font-size: var(--text-xl);
  }

  .catalog-category-cards .catalog-card::after {
    top: 12px;
    right: 12px;
    width: 42px;
    height: 42px;
    opacity: 0.48;
  }

  /* Mobile: keep hero copy, hide only the photo. */
  .hero-photo,
  .hero-photo--custom,
  .hero--image .hero-photo,
  .hero--image .hero-photo--custom,
  .hero-blueprint,
  .hero-angle {
    display: none !important;
  }
}

@media (max-width: 640px) {
  .catalog-main {
    --catalog-shell-radius: 8px;
    width: calc(100% - 16px);
    margin: 8px auto 16px;
  }

  .hero--image .hero-photo,
  .hero--image .hero-photo--custom {
    width: calc(100% - 16px);
    margin-inline: 8px;
  }
}

@media (max-width: 360px) {
  .hero-content {
    min-height: 0;
  }

  .hero-blueprint {
    height: 236px;
  }

  .hero-angle {
    height: 236px;
  }

  .catalog-category-cards .catalog-card__copy {
    width: 66%;
    min-width: 0;
  }

  .catalog-category-cards .catalog-card,
  .catalog-category-cards .catalog-card--row-three {
    height: 242px;
    min-height: 242px;
  }
}
