/* ==============================================================================
 * FILE: training/assets/tsu.css
 * VERSION: 1.5.0 - TrackStage University styles
 * DATE: 2026-10-14
 * CHANGES:
 *   - v1.5.0: Off-site (link) cards: external marker, host label\n *   - v1.4.0: Site search styles (hero box, results list)
 *   - v1.3.0: Live class cards (badge, next-session line, Register button)
 *   - v1.2.0: Help Center band (.kbband) linking to ../knowledgebase/
 *   - v1.1.0: Brand artwork (purple swoosh) in hero, footer, topbar and video tiles
 *   - v1.0.1: Hero tile hides session number under play button; path link style
 *   - v1.0.0: Initial. Palette from TrackStage product code.
 * ============================================================================== */

:root {
  --ts-deep: #351B5B;
  --ts-deep-2: #4A2580;
  --ts-purple: #6D3BB6;
  --ts-pink: #D92BD6;
  --ts-gold: #FFC300;
  --ts-lav: #A592C0;

  --bg: #F7F5FB;
  --surface: #FFFFFF;
  --ink: #221A30;
  --ink-2: #5B5369;
  --line: #E4DEEE;
  --chip: #EFEAF7;
  --shadow: 0 10px 30px rgba(53, 27, 91, .12);
  --radius: 14px;
  --wrap: 1180px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #150D22;
    --surface: #1F1531;
    --ink: #F1ECF8;
    --ink-2: #B7ACC8;
    --line: #34274A;
    --chip: #2A1E40;
    --shadow: 0 10px 30px rgba(0, 0, 0, .4);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px; line-height: 1.6; -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--ts-purple); }
h1, h2, h3 { line-height: 1.2; margin: 0; letter-spacing: -.01em; }
button { font: inherit; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ts-gold); color: #000; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--ts-gold); outline-offset: 2px; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 0; border-radius: 999px; padding: 12px 22px; font-weight: 600;
  text-decoration: none; cursor: pointer; transition: transform .15s, box-shadow .15s, background .15s;
  min-height: 44px;
}
.btn:hover { transform: translateY(-1px); }
.btn--gold { background: var(--ts-gold); color: #2A1500; box-shadow: 0 6px 18px rgba(255, 195, 0, .35); }
.btn--ghost { background: transparent; color: inherit; box-shadow: inset 0 0 0 2px currentColor; }
.btn--sm { padding: 8px 16px; font-size: 14px; min-height: 38px; white-space: nowrap; }

/* ---- Top bar ---- */
.topbar {
  color: #fff; position: sticky; top: 0; z-index: 20;
  background: linear-gradient(90deg, #120A1E 0%, var(--ts-deep) 55%, var(--ts-deep-2) 100%);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.topbar__inner { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.brand__mark {
  width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--ts-pink), var(--ts-purple)); font-weight: 800; font-size: 14px;
}
.brand__crest { width: 36px; height: 36px; object-fit: contain; }
.brand__text { font-size: 17px; font-weight: 400; }
.brand__text strong { color: var(--ts-gold); font-weight: 700; }
.topnav { display: flex; align-items: center; gap: 22px; }
.topnav a:not(.btn) { color: #E6DDF5; text-decoration: none; font-size: 15px; }
.topnav a:not(.btn):hover { color: #fff; }

/* ---- Hero ---- */
.hero {
  position: relative; color: #fff; padding: 76px 0 84px; overflow: hidden;
  background: #0B0612;
  background-image: image-set(url("tsu-hero-bg.webp") type("image/webp"), url("tsu-hero-bg.jpg") type("image/jpeg"));
  background-image: -webkit-image-set(url("tsu-hero-bg.webp") type("image/webp"), url("tsu-hero-bg.jpg") type("image/jpeg"));
  background-size: cover; background-position: center right; background-repeat: no-repeat;
}
/* Scrim: keeps headline contrast high over the bright side of the artwork. */
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(11, 6, 18, .92) 0%, rgba(11, 6, 18, .78) 38%, rgba(11, 6, 18, .30) 62%, rgba(11, 6, 18, .15) 100%),
    linear-gradient(180deg, rgba(53, 27, 91, .55) 0%, transparent 35%);
}
.hero__inner { position: relative; z-index: 1; }
@supports not (background-image: image-set(url("x.webp") type("image/webp"))) {
  .hero { background-image: url("tsu-hero-bg.jpg"); }
}
.hero__inner { display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: center; }
.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: 13px; font-weight: 600; color: var(--ts-gold); margin: 0 0 12px; }
.hero h1 { font-size: clamp(32px, 5vw, 52px); font-weight: 700; }
.lede { font-size: 18px; color: #E6DDF5; margin: 18px 0 28px; max-width: 34em; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; }
.hero__stats { margin: 22px 0 0; color: var(--ts-lav); font-size: 14px; }
.hero__feature { cursor: pointer; }

/* ---- Thumbnails ---- */
.thumb {
  position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden;
  background: #120A1E;
  background-image: image-set(url("tsu-hero-bg.webp") type("image/webp"), url("tsu-hero-bg.jpg") type("image/jpeg"));
  background-image: -webkit-image-set(url("tsu-hero-bg.webp") type("image/webp"), url("tsu-hero-bg.jpg") type("image/jpeg"));
  background-size: cover; background-position: center;
}
/* Vary the crop so a row of tiles does not read as one repeated image. */
.thumb--p1 { background-position: 12% 40%; background-size: 150%; }
.thumb--p2 { background-position: 62% 30%; background-size: 165%; }
.thumb--p3 { background-position: 88% 62%; background-size: 155%; }
.thumb--p4 { background-position: 35% 78%; background-size: 175%; }
.thumb__num { text-shadow: 0 2px 18px rgba(0, 0, 0, .55); }
.thumb--art { background-image: none; background: linear-gradient(135deg, var(--ts-deep-2), var(--ts-purple)); }
.thumb img, .thumb video { width: 100%; height: 100%; object-fit: cover; }
.thumb__num {
  position: absolute; inset: 0; display: grid; place-items: center; text-align: center;
  color: #fff; font-weight: 800; font-size: clamp(28px, 4vw, 44px); letter-spacing: .02em;
}
.thumb__num small { display: block; font-size: 12px; font-weight: 600; letter-spacing: .18em; opacity: .8; }
.thumb__play {
  position: absolute; left: 50%; top: 50%; width: 58px; height: 58px; margin: -29px 0 0 -29px;
  border-radius: 50%; background: rgba(255, 195, 0, .95); display: grid; place-items: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .35); transform: scale(.9); opacity: 0; transition: .2s;
}
.thumb__play::after { content: ""; border-left: 18px solid #2A1500; border-top: 11px solid transparent; border-bottom: 11px solid transparent; margin-left: 5px; }
.card:hover .thumb__play, .card:focus-within .thumb__play, .hero__feature:hover .thumb__play { opacity: 1; transform: scale(1); }
.hero__feature .thumb__num { display: none; }
.cat-block a { font-weight: 600; }
.hero__feature .thumb { box-shadow: 0 24px 60px rgba(0, 0, 0, .45); }
.hero__feature .thumb__play { opacity: 1; transform: scale(1); width: 72px; height: 72px; margin: -36px 0 0 -36px; }
.badge {
  position: absolute; bottom: 10px; right: 10px; background: rgba(0, 0, 0, .72); color: #fff;
  font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 6px;
}
.badge--tl { left: 10px; right: auto; top: 10px; bottom: auto; }
.badge--pro { background: var(--ts-gold); color: #2A1500; }
.badge--watched { background: #1F9D55; }
.badge--live { background: var(--ts-pink); color: #fff; letter-spacing: .06em; }
.thumb--live .thumb__play { display: none; }
.card__next { font-size: 14px; color: var(--ink-2); margin-top: 8px !important; }
.card__next strong { color: var(--ink); font-weight: 600; }
.card__cta { align-self: flex-start; margin-top: 10px; }
.hero__caption { margin-top: 14px; }
.hero__caption span { color: var(--ts-gold); font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.hero__caption h3 { font-size: 20px; margin-top: 4px; }

/* ---- Sections ---- */
.path, .library { padding: 64px 0; }
.library { padding-top: 24px; padding-bottom: 88px; }
.section-head { margin-bottom: 24px; }
.section-head h2 { font-size: clamp(24px, 3vw, 32px); color: var(--ink); }
.section-head p { color: var(--ink-2); margin: 8px 0 0; max-width: 44em; }
.section-head--row { display: flex; align-items: end; justify-content: space-between; gap: 20px; flex-wrap: wrap; }

/* ---- Path ---- */
.path__progress { height: 8px; background: var(--chip); border-radius: 99px; overflow: hidden; }
.path__progress span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--ts-purple), var(--ts-pink)); transition: width .4s; }
.path__progress-label { font-size: 14px; color: var(--ink-2); margin: 8px 0 24px; }
.path__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: step; }

/* ---- Cards ---- */
.card {
  background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow);
  overflow: hidden; display: flex; flex-direction: column; border: 1px solid var(--line);
  transition: transform .18s, box-shadow .18s;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 16px 40px rgba(53, 27, 91, .18); }
.card .thumb { border-radius: 0; }
.card__btn { all: unset; cursor: pointer; display: block; }
.card__btn:focus-visible { outline: 3px solid var(--ts-gold); outline-offset: -3px; }
.card__body { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card__kicker { font-size: 12px; text-transform: uppercase; letter-spacing: .12em; font-weight: 600; color: var(--ts-purple); }
@media (prefers-color-scheme: dark) { .card__kicker { color: var(--ts-lav); } }
.card h3 { font-size: 17px; font-weight: 600; }
.card p { margin: 0; color: var(--ink-2); font-size: 14px; }

/* ---- Filters ---- */
.search { position: relative; flex: 0 1 360px; }
.search svg { position: absolute; left: 14px; top: 50%; width: 18px; height: 18px; margin-top: -9px; fill: none; stroke: var(--ink-2); stroke-width: 2; stroke-linecap: round; }
.search input {
  width: 100%; padding: 12px 16px 12px 42px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--surface); color: var(--ink); font: inherit; font-size: 15px; min-height: 46px;
}
.search input:focus { outline: none; border-color: var(--ts-purple); box-shadow: 0 0 0 3px rgba(109, 59, 182, .25); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.chip {
  border: 0; background: var(--chip); color: var(--ink); padding: 8px 16px; border-radius: 999px;
  font-size: 14px; font-weight: 500; cursor: pointer; min-height: 38px;
}
.chip[aria-pressed="true"] { background: var(--ts-deep); color: #fff; }
@media (prefers-color-scheme: dark) { .chip[aria-pressed="true"] { background: var(--ts-gold); color: #2A1500; } }
.chip .n { opacity: .6; margin-left: 4px; }
.result-count { font-size: 14px; color: var(--ink-2); margin: 8px 0 20px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 24px; }
.cat-block { grid-column: 1 / -1; margin-top: 18px; }
.cat-block:first-child { margin-top: 0; }
.cat-block h3 { font-size: 20px; }
.cat-block p { margin: 4px 0 0; color: var(--ink-2); font-size: 14px; }
.empty { text-align: center; color: var(--ink-2); padding: 40px 0; }

/* ---- Player ---- */
.player { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 20px; }
.player[hidden] { display: none; }
.player__backdrop { position: absolute; inset: 0; background: rgba(12, 6, 22, .85); backdrop-filter: blur(4px); }
.player__panel {
  position: relative; width: min(1100px, 100%); max-height: calc(100vh - 40px); overflow: auto;
  background: var(--surface); border-radius: 18px; box-shadow: 0 30px 80px rgba(0, 0, 0, .5);
}
.player__stage { aspect-ratio: 16 / 9; background: #000; }
.player__stage video, .player__stage iframe { width: 100%; height: 100%; border: 0; display: block; }
.player__close {
  position: absolute; top: 10px; right: 10px; z-index: 2; width: 42px; height: 42px; border-radius: 50%;
  border: 0; background: rgba(0, 0, 0, .6); color: #fff; font-size: 26px; line-height: 1; cursor: pointer;
}
.player__meta { display: flex; justify-content: space-between; gap: 20px; padding: 18px 22px 22px; align-items: start; }
.player__kicker { margin: 0; font-size: 12px; text-transform: uppercase; letter-spacing: .12em; font-weight: 600; color: var(--ts-purple); }
@media (prefers-color-scheme: dark) { .player__kicker { color: var(--ts-lav); } }
.player__meta h3 { font-size: 22px; margin-top: 4px; }
.player__meta p:last-child { margin: 6px 0 0; color: var(--ink-2); }
.player__actions { display: flex; gap: 10px; flex-shrink: 0; flex-wrap: wrap; justify-content: end; }
.player__error { color: #fff; display: grid; place-items: center; height: 100%; text-align: center; padding: 20px; }

/* ---- Help Center band ---- */
.kbband { padding: 0 0 88px; }
.kbband__inner {
  display: grid; grid-template-columns: 1fr 1.4fr; gap: 40px; align-items: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow);
  padding: 40px;
}
.kbband__copy h2 { font-size: clamp(24px, 3vw, 32px); }
.kbband__copy p:not(.eyebrow) { color: var(--ink-2); margin: 10px 0 22px; }
.kbband .eyebrow { color: var(--ts-purple); }
@media (prefers-color-scheme: dark) { .kbband .eyebrow { color: var(--ts-gold); } }
.kbband__links { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.kbband__link {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  padding: 11px 14px; border-radius: 10px; background: var(--chip); color: var(--ink);
  text-decoration: none; font-size: 15px; font-weight: 500; transition: background .15s, color .15s;
}
.kbband__link:hover { background: var(--ts-deep); color: #fff; }
.kbband__link .n { font-size: 12px; opacity: .65; }

/* ---- Footer ---- */
.footer {
  position: relative; color: #CFC4E2; font-size: 14px; background: var(--ts-deep);
  background-image: image-set(url("tsu-hero-bg.webp") type("image/webp"), url("tsu-hero-bg.jpg") type("image/jpeg"));
  background-image: -webkit-image-set(url("tsu-hero-bg.webp") type("image/webp"), url("tsu-hero-bg.jpg") type("image/jpeg"));
  background-size: cover; background-position: center 35%; overflow: hidden;
}
.footer::before { content: ""; position: absolute; inset: 0; background: rgba(11, 6, 18, .74); }
.footer__inner { position: relative; z-index: 1; }
.footer__inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding: 22px 20px; }
.footer p { margin: 0; }
.footer a { color: var(--ts-gold); }

/* ---- Responsive ---- */
@media (max-width: 960px) {
  .hero__inner { grid-template-columns: 1fr; }
  .path__list { grid-template-columns: repeat(2, 1fr); }
  .kbband__inner { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .wrap { padding: 0 16px; }
  .topnav a:not(.btn) { display: none; }
  .brand__text { font-size: 15px; }
  .hero { padding: 40px 0 48px; }
  .path__list { grid-template-columns: 1fr; }
  .kbband__inner { padding: 24px 20px; }
  .kbband__links { grid-template-columns: 1fr; }
  .search { flex-basis: 100%; }
  .player { padding: 0; }
  .player__panel { border-radius: 0; max-height: 100vh; height: 100%; }
  .player__meta { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}

/* ==============================================================================
 * END OF FILE: training/assets/tsu.css | VERSION: 1.4.0
 * ============================================================================== */

/* ---------- Site search results (videos + Help Center) ---------- */
.search--hero { display: block; flex: 0 1 auto; max-width: 520px; margin: 22px 0 0; }
.search--hero input { background: rgba(255, 255, 255, .10); border-color: rgba(255, 255, 255, .28); color: #fff; }
.search--hero input::placeholder { color: rgba(255, 255, 255, .60); }
.search--hero svg { stroke: rgba(255, 255, 255, .70); }
.search--hero input:focus { border-color: var(--ts-gold); box-shadow: 0 0 0 3px rgba(255, 195, 0, .30); }

.results { padding: 40px 0 10px; }
.results__h { font-size: 15px; text-transform: uppercase; letter-spacing: .10em; color: var(--ink-2); margin: 28px 0 14px; }
.results__h:first-of-type { margin-top: 8px; }
.res-list { list-style: none; margin: 0 0 8px; padding: 0; display: grid; gap: 12px; }
.res-item a { display: block; padding: 16px 18px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); text-decoration: none; color: inherit; }
.res-item a:hover { border-color: var(--ts-purple); }
.res-item h4 { margin: 0 0 6px; font-size: 17px; color: var(--ts-purple); }
.res-item p { margin: 0; font-size: 14px; color: var(--ink-2); line-height: 1.5; }
.thumb__ext {
  position: absolute; left: 50%; top: 50%; width: 58px; height: 58px; margin: -29px 0 0 -29px;
  border-radius: 50%; background: rgba(255, 195, 0, .95); color: #2A1500;
  display: grid; place-items: center; font-size: 24px; line-height: 1; font-weight: 700;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .35); transform: scale(.9); opacity: 0; transition: .2s;
}
.card:hover .thumb__ext, .card:focus-within .thumb__ext { opacity: 1; transform: scale(1); }
.card--link .card__host { opacity: .75; }
.card--link .card__host::before { content: "\00b7"; margin: 0 5px; }
.results__more { margin: 18px 0 4px; }
.res-item mark { background: rgba(255, 195, 0, .35); color: inherit; padding: 0 2px; border-radius: 3px; }
