/* V249: fix description display mode not respecting 'Always visible'.
   The V248 reveal rules accidentally collapsed descriptions on all cards,
   including those in brand-desc-mode-always. Only cards explicitly configured
   for hover may ever collapse their copy. Both layouts and the Healthcare card
   use the same animation and layout. */

/* Use the same smooth bottom-up reveal everywhere a brand description exists.
   On devices without hover, descriptions remain visible for accessibility. */
@media (hover:hover) and (pointer:fine) {
  body[data-design-system="2026"] main .brand-showcase .card.brand-desc-mode-hover > .brand-description-reveal {
    grid-template-rows:minmax(0,0fr)!important;
    opacity:0!important;
    transform:translateY(10px) scale(.985)!important;
    margin-bottom:0!important;
    pointer-events:none!important;
  }
  body[data-design-system="2026"] main .brand-showcase .card.brand-desc-mode-hover:is(:hover,:focus-within) > .brand-description-reveal {
    grid-template-rows:minmax(0,1fr)!important;
    opacity:1!important;
    transform:translateY(0) scale(1)!important;
    margin-bottom:12px!important;
    pointer-events:auto!important;
  }

  /* When collapsed, remove any reserved gap in both property and care cards. */
  body[data-design-system="2026"] main .brand-showcase .prop .card.brand-layout-full.brand-desc-mode-hover:not(:hover):not(:focus-within) > .brand-description-reveal,
  body[data-design-system="2026"] main .brand-showcase .care .card.big.brand-desc-mode-hover:not(:hover):not(:focus-within) > .brand-description-reveal,
  body[data-design-system="2026"] main .brand-showcase .card.brand-layout-top.brand-desc-mode-hover:not(:hover):not(:focus-within) > .brand-description-reveal {
    margin-bottom:0!important;
  }
}

/* Top-banner cards: keep the action anchored low so the description reveals
   upward from the lower content stack instead of feeling detached. */
body[data-design-system="2026"] main .brand-showcase .card.brand-layout-top > a[data-brand] {
  margin-top:auto!important;
}

/* Tall Healthcare card: keep the service subtitle down with the bottom stack.
   On hover the subtitle naturally lifts as the description expands beneath it,
   matching the full-cover property-card behaviour. */
body[data-design-system="2026"] main .brand-showcase .care .card.big > small.brand-service-pill {
  margin-top:auto!important;
  margin-bottom:12px!important;
  align-self:stretch!important;
}
body[data-design-system="2026"] main .brand-showcase .care .card.big > .brand-description-reveal {
  margin-top:0!important;
  align-self:stretch!important;
}
body[data-design-system="2026"] main .brand-showcase .care .card.big > ul.areas {
  margin-top:0!important;
  margin-bottom:14px!important;
  align-self:stretch!important;
}
body[data-design-system="2026"] main .brand-showcase .care .card.big > a[data-brand] {
  margin-top:0!important;
}

/* Slightly reduce the fully covered card heights while preserving comfortable
   room for the lower content stack and hover-revealed copy. */
@media (min-width: 561px) {
  body[data-design-system="2026"] main .brand-showcase .prop .card.brand-layout-full {
    min-height:272px!important;
    padding:78px 18px 14px!important;
  }
  body[data-design-system="2026"] main .brand-showcase .care .card.big.brand-layout-full {
    min-height:404px!important;
    padding:136px 20px 18px!important;
  }
}
@media (max-width: 560px) {
  body[data-design-system="2026"] main .brand-showcase .prop .card.brand-layout-full {
    min-height:295px!important;
    padding:84px 16px 14px!important;
  }
  body[data-design-system="2026"] main .brand-showcase .care .card.big.brand-layout-full {
    min-height:418px!important;
    padding:124px 18px 18px!important;
  }
}

@media (prefers-reduced-motion:reduce) {
  body[data-design-system="2026"] main .brand-showcase .card > .brand-description-reveal {
    transition:none!important;
    transform:none!important;
  }
}

/* Guard the explicit always-visible mode against other historical brand
   stylesheets and against hover/focus state changes. */
body[data-design-system="2026"] main .brand-showcase .card.brand-desc-mode-always > .brand-description-reveal {
  display:grid!important;
  grid-template-rows:minmax(0,1fr)!important;
  opacity:1!important;
  transform:none!important;
  visibility:visible!important;
  margin-bottom:12px!important;
  pointer-events:auto!important;
}
