/* © 2026 Filip Mráček / Chineseffect. The one tab bar of the whole site – always at the top, the same on every page.
   On phones the bar slides away while scrolling down and returns on the way up (site/tabs.js). */
.cx-tabs {
  position: relative; display: flex; gap: 2px; padding: 3px; min-width: 0;
  border-radius: 999px; background: rgba(20, 22, 26, .72); border: 1px solid rgba(255, 255, 255, .1);
  overflow-x: auto; overflow-y: hidden; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.cx-tabs::-webkit-scrollbar { display: none; }
.cx-tabs > a {
  flex: none; color: #a1a1a6; font: 500 14px/1 -apple-system, BlinkMacSystemFont, "SF Pro Text", Inter, "Segoe UI", Roboto, sans-serif;
  padding: 8px 13px; border-radius: 999px; white-space: nowrap; text-decoration: none; background: transparent; box-shadow: none;
  transition: color .2s, background .2s;
}
.cx-tabs > a:hover { color: #f5f5f7; }
.cx-tabs > a.cx-tab-plus { color: rgb(255, 185, 120); }
.cx-tabs > a.cx-tab-plus:hover, .cx-tabs > a.cx-tab-plus.is-on { color: rgb(255, 205, 160); }
/* the thin light under a tab while its page is on the way (site/tabs.js sets --cxp 0…1 and --cxt) */
.cx-tabs > a { position: relative; }
.cx-tabs > a::after {
  content: ''; position: absolute; left: 12px; right: 12px; bottom: 2px; height: 2px; border-radius: 2px; pointer-events: none;
  background: linear-gradient(90deg, rgb(255 150 60 / .25), rgb(255 185 120)); box-shadow: 0 0 8px rgb(255 150 60 / .55);
  transform: scaleX(var(--cxp, 0)); transform-origin: left center; opacity: 0;
  transition: transform var(--cxt, .3s) cubic-bezier(.08, .7, .25, 1), opacity .3s;
}
.cx-tabs > a.cx-load::after { opacity: 1; }
@media (max-width: 760px) { .cx-tabs > a::after { left: 9px; right: 9px; } }
.cx-tabs > a.is-on, .cx-tabs > a[aria-current="page"] { color: #f5f5f7; background: rgba(255, 255, 255, .13); }
@media (max-width: 760px) {
  .cx-tabs .tab-long { display: none; }
  .cx-tabs > a { padding: 7px 10px; font-size: 13px; }
}

/* More tabs than fit (phones): a soft fade and a small arrow at the edge where tabs are hidden – tap it to see
   the rest. One rule for the whole bar, whatever order the tabs are in; nothing shows when everything fits.
   The arrows are added by site/tabs.js; they stick to the edges of the scrolling bar and take no room. */
.cx-tabs .cx-more {
  position: sticky; z-index: 2; flex: none; align-self: stretch; width: 38px; border: 0; padding: 0; cursor: pointer;
  display: grid; align-items: center; color: rgb(255, 190, 125); opacity: 0; pointer-events: none; transition: opacity .25s;
  -webkit-tap-highlight-color: transparent;
}
.cx-tabs .cx-more--r { right: -3px; margin: -3px -3px -3px -38px; justify-items: end; padding-right: 6px; border-radius: 0 999px 999px 0;
  background: linear-gradient(90deg, rgba(20, 22, 26, 0), rgba(20, 22, 26, .96) 55%); }
.cx-tabs .cx-more--l { left: -3px; margin: -3px -38px -3px -3px; justify-items: start; padding-left: 6px; border-radius: 999px 0 0 999px;
  background: linear-gradient(270deg, rgba(20, 22, 26, 0), rgba(20, 22, 26, .96) 55%); }
.cx-tabs .cx-more.is-on { opacity: 1; pointer-events: auto; }
.cx-tabs .cx-more i {
  display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%;
  background: rgb(255 150 60 / .16); box-shadow: inset 0 0 0 1px rgb(255 160 80 / .45);
}
.cx-tabs .cx-more svg { display: block; }
.cx-tabs .cx-more--l svg { transform: scaleX(-1); }
.cx-tabs .cx-more.is-hint i { animation: cxNudge 1.6s cubic-bezier(.45, 0, .25, 1) .6s 2; }
@keyframes cxNudge { 0%, 100% { transform: none; } 45% { transform: translateX(3px); } }
@media (prefers-reduced-motion: reduce) { .cx-tabs .cx-more.is-hint i { animation: none; } }

/* phones: the bar slides up out of the way while you scroll down (class set by site/tabs.js) */
@media (max-width: 760px) {
  .cx-slide { transition: transform .32s cubic-bezier(.2, .75, .25, 1) !important; }
  .cx-away { transform: translate3d(0, calc(-100% - 8px), 0) !important; }
}
@media (prefers-reduced-motion: reduce) { .cx-slide { transition: none !important; } }

/* Plus (site/plus.js): the one quiet note where something rests in the mist – same look everywhere */
.cx-mistnote { margin: 14px 0 4px; padding: 14px 16px; border-radius: 16px; font: 15px/1.5 -apple-system, BlinkMacSystemFont, "SF Pro Text", Inter, "Segoe UI", Roboto, sans-serif;
  color: #d8d8dc; background: linear-gradient(180deg, rgba(40, 28, 18, .55), rgba(20, 22, 26, .7)); box-shadow: inset 0 0 0 1px rgb(255 160 80 / .32); }
.cx-mistnote a { color: rgb(255, 190, 125); font-weight: 600; white-space: nowrap; text-decoration: none; }
.cx-mistnote a:hover { text-decoration: underline; }
