:is(rh-footer, rh-footer-universal) a {
  color: var(--rh-color-interactive-primary-default-on-dark, #92c5f9);
  text-decoration: none;
}

:is(rh-footer, rh-footer-universal) a:hover {
  color: var(--rh-color-interactive-primary-hover-on-dark, #b9dafc);
  text-decoration: underline;
}

:is(rh-footer, rh-footer-universal) a:is(:focus, :focus-within) {
  color: var(--rh-color-interactive-primary-hover-on-dark, #b9dafc);
  text-decoration: underline;
}

:is(rh-footer, rh-footer-universal) a:visited {
  color: var(--rh-color-interactive-primary-hover-on-dark, #b9dafc);
  text-decoration: none;
}

/* ensure links fully wrap img tags */
:is(rh-footer, rh-footer-universal) a[slot^='logo'] {
  display: block;
}

:is(rh-footer) a[slot^='logo'] > img {
  display: block;
  width: auto;
  height: 100%;
  height: var(--rh-size-icon-04, 40px);
}

:is(rh-footer, rh-footer-universal) :is(h1, h2, h3, h4, h5, h6) {
  font-family: var(--rh-font-family-heading, RedHatDisplay, 'Red Hat Display', 'Noto Sans Arabic', 'Noto Sans Hebrew', 'Noto Sans JP', 'Noto Sans KR', 'Noto Sans Malayalam', 'Noto Sans SC', 'Noto Sans TC', 'Noto Sans Thai', Helvetica, Arial, sans-serif);
  line-height: var(--rh-line-height-heading, 1.3);
}

rh-footer [slot='links']:is(h1, h2, h3, h4, h5):nth-of-type(n+5) {
  --_link-header-margin: calc(var(--rh-space-2xl, 32px) - var(--rh-space-lg, 16px));
}

rh-footer [slot^='links'] a {
  gap: var(--rh-footer-links-gap, var(--rh-space-md, 8px));
}

:is(rh-footer, rh-footer-universal) [slot^='links'] li {
  margin: 0;
  padding: 0;
  display: contents;
}

:is(rh-footer, rh-footer-universal) [slot^='links'] a {
  display: block;
  color: var(--rh-color-text-primary-on-dark, #ffffff) !important;
  font-size: var(--rh-footer-link-font-size, var(--rh-font-size-body-text-sm, 0.875rem));
  width: fit-content;
}

rh-footer-universal [slot^='links'] a {
  font-size: inherit;
}

/**
 * Section side gap
 */
:is(rh-footer, rh-footer-universal) {
  --rh-footer-section-side-gap: var(--rh-space-lg, 16px);
}

/* (min-width: --rh-breakpoint-sm) */
@media screen and (min-width: 768px) {
  :is(rh-footer, rh-footer-universal) {
    --rh-footer-section-side-gap: var(--rh-space-2xl, 32px);
  }
}

/* (min-width: --rh-breakpoint-xl) */
@media screen and (min-width: 1440px) {
  :is(rh-footer, rh-footer-universal) {
    --rh-footer-section-side-gap: var(--rh-space-4xl, 64px);
  }
}

/**
 * No JS Experience
 */
rh-footer:not(:defined) {
  background-color: var(--rh-color-surface-darker, #1f1f1f);
  width: 100%;
  display: grid;
  grid-template-areas:
    'footer'
    'global';
  grid-template-rows: 1fr auto;
  min-height: var(--rh-footer-nojs-min-height, 750px);
}

rh-footer-universal:not(:defined):before {
  grid-area: global;
}

/* Adding styles to logo */
rh-footer:not(:defined) > [slot='logo'] {
  padding: var(--rh-space-2xl, 32px) var(--_section-side-gap);
}

/* A11y hide child components */
rh-footer:not(:defined) > :not([slot='logo'], rh-footer-universal),
rh-footer-universal:not(:defined) > * {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
}

rh-footer-universal:not(:defined) {
  background-color: var(--rh-color-surface-darkest, #151515);
  display: block;
  width: 100%;
  min-height: 176px;
}

rh-footer-universal rh-footer-copyright {
  grid-column: -1/1;
}
