:root {
  /* alpha as a percentage */
  --subtext-bg-alpha: 0%;
}

/* override just the alpha% on proximity classes */
.subtext-comment-parent.active-high { --subtext-bg-alpha: 100%; }
.subtext-comment-parent.active-mid  { --subtext-bg-alpha: 30%;  }
.subtext-comment-parent.active-low  { --subtext-bg-alpha: 0%;  }

/* combine your global accent hex with transparent */
.subtext-comment-parent {
  background-color: color-mix(
    in srgb,
    var(--e-global-color-accent) var(--subtext-bg-alpha),
    transparent
  );
  transition: background-color 0.1s ease-out;
  
/*
	border-bottom-width: 2px;
	border-bottom-style: solid;
    border-bottom-color: color-mix(
    in srgb,
    var(--e-global-color-text) var(--subtext-bg-alpha),
    transparent
  );
  transition: border-bottom-color 0.1s ease-out;  
*/
  
  cursor: help;
  
}

/* whenever we add .hover-active to the wrapper, force the same border-color you get on :hover */
.subtext-hover img {
  transition: border-color 2s ease-out;
}

.subtext-hover img:hover {
  transition-duration: 0.3s;
  border-color: var(--e-global-color-accent);
}




/* make .subtext a positioning context */
.footer-bar .subtext {
  position: relative;
  overflow: hidden; /* your existing rule */
  pointer-events: auto !important;
}

/* shared styles for both fades */
.footer-bar .subtext::before,
.footer-bar .subtext::after {
  content: "";
  position: absolute;
  left: 0; 
  width: 100%;
  height: .5em;           /* how tall the fade band is */
  pointer-events: none !important;    /* so clicks still go through */
  z-index: 1;              /* sit above the scrolling text */
  
}

/* top fade: transparent → solid text-color */
.footer-bar .subtext::before {
  top: 0;
  background: linear-gradient(
    to bottom,
    var(--e-global-color-text),
    transparent
  );
}

/* bottom fade: transparent ← solid text-color */
.footer-bar .subtext::after {
  bottom: 0;
  background: linear-gradient(
    to top,
    var(--e-global-color-text),
    transparent
  );
}


/* the tall shadow container */
.footer-bar .subtext-shadow {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  /* height set dynamically in JS */
}

/* each note, positioned absolutely inside the shadow */
.footer-bar .subtext-item {
  position: absolute;
  width: 100%;
  /* top set dynamically in JS */
  color: var(--e-global-color-background);
  color: var(--e-global-color-accent);
  font-size: 80%;
/*   font-style: italic; */
  font-weight: bolder;
  
  opacity: 1;
  transition: opacity 0.5s ease-in-out;  
}



.footer-bar .subtext-item a {
	text-decoration: underline;
	color: var(--e-global-color-background);
	color: var(--e-global-color-accent);
	cursor: pointer;
	pointer-events: auto !important;
}

/* target only links inside your subtext bar */
/*
.footer-bar .subtext-item a::before {
  content: "🔗 ";        
  display: inline-block;  
  vertical-align: middle;
}
*/


.footer-bar .subtext-item a {
  position: relative;
  padding-left: 1.1em;   /* make room for the icon */
}
.footer-bar .subtext-item a::before {
	content: "";
  position: absolute;
  left: 0.1em;
  top: 60%;
  transform: translateY(-50%);
  width: .8em;
  height: .8em;
  background-color: var(--e-global-color-background);
  background-color: var(--e-global-color-accent);
  mask: url('/assets/icon-link-fill.svg') no-repeat center;
  -webkit-mask: url('/assets/icon-link-fill.svg') no-repeat center;
  mask-size: contain;
  -webkit-mask-size: contain;  
}



/* hide the comment text in-place for any hoverable block */
.subtext-hover .subtext-comment {
  display: none;
}


@media (max-width: 767px) {
  /* stack footer children vertically on mobile */
  .footer-bar {
    display: flex !important;
    flex-direction: column !important;
    align-items: center;
    padding: 0 !important;
    margin: 0 !important;
    gap: 0.25em;
  }

  .footer-bar .subtext {
    order: -1;
    position: relative;
    flex: 0 0 auto;
    width: 100%;
    height: 2.5em;
    display: flex;
    align-items: center;
    overflow: hidden;
    padding: 0 .5em;
    box-sizing: border-box;
    margin: 0;
  }

  .footer-bar .subtext::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 100vw;
    height: 100%;
    pointer-events: none;
    background: linear-gradient(
      to left,
      var(--e-global-color-text) 0%,
      var(--e-global-color-text) 5%,
      transparent 40%
    );
  }

  /* 👇 mobile note style */
  .footer-bar .subtext-item {
    display: flex;                  /* flex container instead of block */
    align-items: center;            /* vertical centering */
    white-space: nowrap;
    overflow-x: scroll;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
    cursor: grab;
    padding-top: .8em;
    padding-left: .7em;
  }

  .footer-bar .subtext-item::after {
    content: "";
    display: inline-block;
    width: 3em;
    height: 1px;
  }

  .footer-bar .subtext-item::-webkit-scrollbar {
    display: none;
  }

  /* social icons below, smaller */
  .footer-bar .elementor-widget-social-icons {
    order: 1;
    flex: 0 0 auto;
    transform: scale(0.8);
    margin: 0.25em 0 0.5em 0;
  }

  /* wrappers provided by shortcode */
  .footer-bar .subtext-note-inner {
    flex: 1 0 auto;
    display: flex;
    align-items: center;            /* reinforce vertical centering */
    line-height: 1.4;
  }

  .footer-bar .subtext-note-content {
    display: inline-block;
    padding: 0.25em 0.75em;
    box-sizing: border-box;
    margin-right: 8em;
  }

  /* mitigate mobile Safari bottom touch area */
  @supports (-webkit-touch-callout: none) {
    footer.footer-bar {
      height: 130px;
    }
  }

  .footer-bar elementor-social-icons-wrapper {
    margin-bottom: -1em;
  }
}













