/* The vintage stripe: three distinct bands (teal, coral, mustard) with a thin gap between them, decorative only.
   Pure CSS on a pseudo-element or an empty aria-hidden element, so assistive technology never sees it.
   It is placed, never glued to the edge of the viewport, in two chrome places only:
     - inside the member top bar, running behind its logo zone and nav box (the bold version, 5px bands; see the block below);
     - directly beneath the public navigation band (slim bands, full width);
   Never at the top of the main column, never inside a chart, Stage, or on cards. The gaps are transparent, so
   they take the colour of whatever the stripe sits on (bar charcoal, public band, page). The same three
   colours read on cream and on charcoal, so it needs no dark variant. */
:root {
  --stripe-band: 3px;
  --stripe-gap: 2px;
}

.brand-stripe,
.public-header::after {
  content: "";
  display: block;
  height: calc(var(--stripe-band) * 3 + var(--stripe-gap) * 2);
  background: linear-gradient(
    to bottom,
    var(--stripe-1) 0 var(--stripe-band),
    transparent var(--stripe-band) calc(var(--stripe-band) + var(--stripe-gap)),
    var(--stripe-2) calc(var(--stripe-band) + var(--stripe-gap)) calc(var(--stripe-band) * 2 + var(--stripe-gap)),
    transparent calc(var(--stripe-band) * 2 + var(--stripe-gap)) calc(var(--stripe-band) * 2 + var(--stripe-gap) * 2),
    var(--stripe-3) calc(var(--stripe-band) * 2 + var(--stripe-gap) * 2) calc(var(--stripe-band) * 3 + var(--stripe-gap) * 2)
  );
}

/* THE MEMBER BAR'S STRIPE (replaceable in one edit: this block and the two selectors in the pinned list below). The bold
   version of the stripe: 5px bands with 3px gaps (21px in all), running through the vertical middle of the bar from the
   viewport's left edge to its right edge, BEHIND the logo zone (which masks its left end with a slanted edge, brand_mark.css)
   and the nav box (which masks the stretch under it). It is part of the bar, so nothing sits under the bar and
   --stripe-height stays unset. The header is the stacking context (z-index -1 puts the stripe above the bar's background
   and under everything in it). The chart page's embedded bar is the same bar and carries the same stripe. Screen only. */
@media screen {
  .member-shell > .member-header::after,
  .member-shell--chart .member-header::after {
    --bar-stripe-band: 5px;
    --bar-stripe-gap: 3px;
    content: "";
    position: absolute;
    z-index: -1;
    top: calc(50% - (var(--bar-stripe-band) * 3 + var(--bar-stripe-gap) * 2) / 2);
    right: 0;
    left: 0;
    height: calc(var(--bar-stripe-band) * 3 + var(--bar-stripe-gap) * 2);
    pointer-events: none;
    background: linear-gradient(
      to bottom,
      var(--stripe-1) 0 var(--bar-stripe-band),
      transparent var(--bar-stripe-band) calc(var(--bar-stripe-band) + var(--bar-stripe-gap)),
      var(--stripe-2) calc(var(--bar-stripe-band) + var(--bar-stripe-gap)) calc(var(--bar-stripe-band) * 2 + var(--bar-stripe-gap)),
      transparent calc(var(--bar-stripe-band) * 2 + var(--bar-stripe-gap)) calc(var(--bar-stripe-band) * 2 + var(--bar-stripe-gap) * 2),
      var(--stripe-3) calc(var(--bar-stripe-band) * 2 + var(--bar-stripe-gap) * 2) calc(var(--bar-stripe-band) * 3 + var(--bar-stripe-gap) * 2)
    );
  }
}

/* The page header's rule (library, sets, groups, account and the other member pages): ONE 2px coral line across the
   full width of the page's content column, directly under the header block (title, subtitle and actions). It replaces
   the short three-band stripe that used to sit under the title: the three bands live only in the top bar. Never on the
   chart page, in a dialog, on Stage or on the shared public page (none of them carries .member-page-heading inside
   .member-shell). Screen only. */
@media screen {
  .member-shell:not(.member-shell--chart) .member-page-heading,
  .member-shell:not(.member-shell--chart) .library-finder__heading {
    padding-bottom: 1.25rem;
    border-bottom: 2px solid var(--heading-rule);
  }
}

@media print {
  .brand-stripe,
  .member-shell > .member-header::after,
  .member-shell--chart .member-header::after,
  .public-header::after {
    display: none;
  }
}
