/* GTAX's issuer panel (gtax_issuer.js) on the Explorer's issuer screen. The code is
   the largest thing on the panel; its tiles reuse the logo's square module and its one
   teal square, the resolved letter. Bars: the issuer's own entry in teal, the rest a
   recessive indigo tint, every bar labelled with its exact count (the tint's contrast
   is relieved by the labels), the own entry also marked in words. Tokens: gtax
   site.css :root, with fallbacks for a page that lacks them. */
.gtx {
  --gtx-indigo: var(--indigo, #272B63);
  --gtx-teal: var(--teal, #0F9488);
  --gtx-teal-text: var(--teal-deep, #0B6B63);
  --gtx-ink: var(--ink, #1C1F36);
  --gtx-slate: var(--slate, #585D78);
  --gtx-rule: var(--rule, #D5D8E3);
  --gtx-tint: var(--tint, #E8EAF1);
  --gtx-context: #A9ADCB;
  --gtx-display: var(--display, "League Spartan", "Futura", sans-serif);
  margin: 0 0 16px;
  padding: 22px 22px 18px;
  background: #fff;
  border: 1px solid var(--gtx-rule);
  border-top: 4px solid var(--gtx-indigo);
  border-radius: 4px;
  color: var(--gtx-ink);
  container-type: inline-size;
}
.gtx[hidden] { display: none; }
.gtx h3 { font-family: var(--gtx-display); font-size: 1.2rem; color: var(--gtx-indigo); margin: 26px 0 6px; }
.gtx h4 { font-family: var(--gtx-display); font-size: 1rem; color: var(--gtx-indigo); margin: 18px 0 8px; }
.gtx p { margin: 0; }
.gtx a { color: var(--gtx-teal-text); }

/* the code */
.gtx-head { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 24px; align-items: end; }
.gtx-kicker { grid-column: 1 / -1; font-family: var(--gtx-display); font-size: 0.85rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--gtx-slate); }
.gtx-code {
  font-family: var(--gtx-display); font-weight: 700; line-height: 0.9;
  font-size: clamp(3.6rem, 13cqi, 6.5rem); letter-spacing: 0.06em; color: var(--gtx-indigo);
}
.gtx-lede { font-size: 1.05rem; line-height: 1.55; max-width: 62ch; padding-bottom: 6px; }

/* the three tiers, letter by letter */
.gtx-tiers { list-style: none; margin: 22px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.gtx-tier { display: flex; gap: 12px; align-items: flex-start; padding: 14px; background: var(--gtx-tint); border-radius: 3px; }
.gtx-tiles { display: inline-flex; gap: 3px; flex: none; }
.gtx-tile {
  width: 30px; height: 30px; display: inline-grid; place-items: center;
  font-family: var(--gtx-display); font-weight: 700; font-size: 1.1rem; line-height: 1;
  background: var(--gtx-indigo); color: #fff;
}
.gtx-tile.on { background: var(--gtx-teal); }
.gtx-tile.off { background: transparent; color: var(--gtx-context); box-shadow: inset 0 0 0 1px var(--gtx-context); }
.gtx-tier-label { font-family: var(--gtx-display); font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--gtx-slate); }
.gtx-tier-label strong { color: var(--gtx-ink); letter-spacing: 0.04em; }
.gtx-tier-name { font-family: var(--gtx-display); font-weight: 700; font-size: 1.15rem; color: var(--gtx-indigo); margin-top: 2px; }
.gtx-tier-means { font-size: 0.92rem; line-height: 1.45; margin-top: 4px; }
.gtx-tier-count { font-size: 0.92rem; margin-top: 6px; color: var(--gtx-slate); font-variant-numeric: tabular-nums; }

/* the path: three ranked bar lists */
.gtx-note { font-size: 0.95rem; color: var(--gtx-slate); max-width: 72ch; }
.gtx-charts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; margin-top: 14px; align-items: start; }
.gtx-chart { margin: 0; min-width: 0; }
.gtx-chart figcaption { display: flex; flex-direction: column; margin-bottom: 8px; }
.gtx-chart figcaption strong { font-family: var(--gtx-display); color: var(--gtx-indigo); font-size: 1rem; }
.gtx-chart figcaption span { font-size: 0.85rem; color: var(--gtx-slate); }
.gtx-bars { list-style: none; margin: 0; padding: 0; }
.gtx-bar {
  display: grid; grid-template-columns: 3.2em minmax(0, 1fr) 4.2em; grid-template-areas: "code name n" "code track n";
  column-gap: 8px; align-items: center; padding: 3px 0; font-size: 0.86rem; line-height: 1.25;
}
.gtx-bar-code { grid-area: code; font-family: var(--gtx-display); font-weight: 600; color: var(--gtx-slate); }
.gtx-bar-name { grid-area: name; overflow-wrap: anywhere; }
.gtx-bar-track { grid-area: track; height: 8px; margin-top: 2px; }
.gtx-bar-fill { display: block; height: 100%; min-width: 1px; background: var(--gtx-context); border-radius: 0 4px 4px 0; }
.gtx-bar-n { grid-area: n; text-align: right; font-variant-numeric: tabular-nums; color: var(--gtx-slate); }
.gtx-bar.on .gtx-bar-fill { background: var(--gtx-teal); }
.gtx-bar.on .gtx-bar-code, .gtx-bar.on .gtx-bar-name, .gtx-bar.on .gtx-bar-n { color: var(--gtx-ink); font-weight: 700; }
.gtx-mine { color: var(--gtx-teal-text); font-weight: 600; white-space: nowrap; }

/* the profile */
.gtx-dl { display: grid; grid-template-columns: 13em minmax(0, 1fr); gap: 6px 16px; margin: 8px 0 0; }
.gtx-dl dt { font-family: var(--gtx-display); font-weight: 600; color: var(--gtx-slate); }
.gtx-dl dd { margin: 0; line-height: 1.45; }
.gtx-scores { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 24px; }
.gtx-scores li { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.gtx-meter { display: inline-flex; align-items: center; gap: 3px; }
.gtx-sq { width: 14px; height: 14px; box-shadow: inset 0 0 0 1px var(--gtx-context); }
.gtx-sq.on { background: var(--gtx-indigo); box-shadow: none; }
.gtx-meter-v { margin-left: 8px; font-variant-numeric: tabular-nums; color: var(--gtx-slate); font-size: 0.9rem; }
.gtx-meter-na { color: var(--gtx-slate); font-size: 0.9rem; }
.gtx-source { margin-top: 18px !important; font-size: 0.85rem; color: var(--gtx-slate); }

@container (max-width: 760px) {
  .gtx-head { grid-template-columns: 1fr; }
  .gtx-tiers, .gtx-charts { grid-template-columns: 1fr; }
  .gtx-dl { grid-template-columns: 1fr; gap: 2px; }
  .gtx-dl dd { margin-bottom: 8px; }
  .gtx-scores { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .gtx { padding: 16px 14px 14px; }
}
