/* Compositing Academy — Asset Store PREVIS
   Dark, video-forward. Branding cues from the Studio Portal spec:
   gradient bg, blue glow #3492eb, Rubik + DM Mono. */

:root {
  --bg-0: #07090d;
  --bg-1: #0b0f16;
  --bg-2: #11161f;
  --bg-3: #171e2a;
  --line: #232c3b;
  --text: #e8edf4;
  --text-dim: #8b96a8;
  --text-faint: #5b6577;
  --accent: #3492eb;
  --accent-soft: rgba(52, 146, 235, 0.16);
  --accent-glow: rgba(52, 146, 235, 0.35);
  --green: #2fbf71;
  --amber: #e8a13c;
  --red: #e05555;
  --radius: 10px;
  --font-ui: "Rubik", system-ui, -apple-system, sans-serif;
  --font-mono: "DM Mono", ui-monospace, "Cascadia Mono", monospace;
}

* { box-sizing: border-box; }
html { scrollbar-color: #2a3444 var(--bg-0); }
body {
  margin: 0;
  font-family: var(--font-ui);
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 75% -10%, rgba(52, 146, 235, 0.10), transparent 60%),
    radial-gradient(900px 500px at -10% 30%, rgba(52, 146, 235, 0.05), transparent 55%),
    linear-gradient(180deg, var(--bg-1), var(--bg-0) 700px);
  background-color: var(--bg-0);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font-family: var(--font-ui); cursor: pointer; }
input, select, textarea {
  font-family: var(--font-ui); color: var(--text);
  background: var(--bg-2); border: 1px solid var(--line);
  border-radius: 8px; padding: 9px 12px; font-size: 14px; outline: none;
}
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

.mono { font-family: var(--font-mono); }
.dim { color: var(--text-dim); }
.faint { color: var(--text-faint); }

/* ---------- layout ---------- */
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

.site-strip { background: #05070a; border-bottom: 1px solid var(--line); }
.site-strip-inner { display: flex; gap: 12px; height: 58px; align-items: center; justify-content: center; }
.site-strip a {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--text-dim); padding: 10px 22px; border-radius: 9px;
  border: 1px solid var(--line); background: var(--bg-2);
  transition: color .15s, border-color .15s, background .15s, box-shadow .15s;
}
.site-strip a:hover { color: var(--text); text-decoration: none; border-color: #35415a; background: #1c2434; }
.site-strip a.active {
  color: #fff; border-color: var(--accent);
  background: linear-gradient(135deg, rgba(52,146,235,.28), rgba(31,108,192,.18));
  box-shadow: 0 0 18px var(--accent-soft), inset 0 0 14px rgba(52,146,235,.08);
}
.site-strip .ss-ext { font-size: 11px; opacity: .7; }

.topbar {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(9, 12, 18, 0.82);
  border-bottom: 1px solid var(--line);
}
.topbar-inner { display: flex; align-items: center; gap: 24px; height: 62px; }
.brand { display: flex; align-items: center; gap: 11px; color: var(--text); font-weight: 600; letter-spacing: 0.02em; white-space: nowrap; }
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 30px; height: 30px; border-radius: 8px; flex: 0 0 auto;
  background: linear-gradient(135deg, var(--accent), #1b5fa8);
  box-shadow: 0 0 18px var(--accent-glow);
  display: grid; place-items: center; font-family: var(--font-mono); font-size: 13px; font-weight: 500; color: #fff;
}
.brand small { display: block; font-weight: 400; color: var(--text-dim); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; }
/* uploaded logo lockup (admin → Media Library) — replaces the text brand */
.brand-logo { display: block; height: 38px; width: auto; max-width: min(280px, 46vw); object-fit: contain; }
.topnav { display: flex; gap: 18px; margin-left: 8px; }
body.is-home .topnav { display: none; } /* Local Nav duplicates the home directory strip */
.topnav a { color: var(--text-dim); font-size: 14px; }
.topnav a.active, .topnav a:hover { color: var(--text); text-decoration: none; }
.topbar-spacer { flex: 1; }
.dlnav { color: var(--text-dim); font-size: 13.5px; margin-right: 14px; white-space: nowrap; }
.dlnav:hover { color: var(--text); text-decoration: none; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border-radius: 8px; border: 1px solid var(--line);
  background: var(--bg-3); color: var(--text);
  padding: 10px 18px; font-size: 14px; font-weight: 500;
  transition: border-color .15s, background .15s, box-shadow .15s, transform .05s;
}
.btn:hover { border-color: #35415a; background: #1c2434; }
.btn:active { transform: translateY(1px); }
.btn.primary {
  background: linear-gradient(135deg, var(--accent), #1f6cc0);
  border-color: transparent; color: #fff;
  box-shadow: 0 2px 16px var(--accent-glow);
}
.btn.primary:hover { filter: brightness(1.08); }
.btn.ghost { background: transparent; }
.btn.small { padding: 6px 12px; font-size: 13px; }
/* Inline pencil next to a name — present, but not competing with the name. */
.btn.tiny { padding: 2px 7px; font-size: 12px; line-height: 1.5; opacity: .45; }
.btn.tiny:hover { opacity: 1; }
.btn.danger { color: var(--red); border-color: rgba(224, 85, 85, 0.35); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }

/* ---------- chips / badges ---------- */
.chip {
  display: inline-flex; align-items: center; gap: 5px;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.05em;
  padding: 3px 8px; border-radius: 6px;
  background: var(--bg-3); border: 1px solid var(--line); color: var(--text-dim);
  white-space: nowrap;
}
.chip.comp { color: var(--accent); border-color: rgba(52, 146, 235, 0.4); background: var(--accent-soft); }
/* a file added to an asset AFTER this buyer paid — they'd never spot it otherwise */
.chip.dl-new { color: var(--green); border-color: rgba(55, 201, 120, 0.45); background: rgba(55, 201, 120, 0.12); font-size: 10px; letter-spacing: .06em; }
.chip.res { color: var(--text); }
.chip.free { color: var(--green); border-color: rgba(47, 191, 113, 0.4); background: rgba(47, 191, 113, 0.12); }
.chip.status-published { color: var(--green); border-color: rgba(47, 191, 113, 0.4); }
.chip.status-processing { color: var(--amber); border-color: rgba(232, 161, 60, 0.4); }
.chip.status-ready { color: var(--accent); border-color: rgba(52, 146, 235, 0.4); }
.chip.status-hidden, .chip.status-draft { color: var(--text-faint); }
.chip.warn { color: var(--amber); border-color: rgba(232, 161, 60, 0.45); background: rgba(232, 161, 60, 0.1); }

.tag-chip {
  font-size: 12px; padding: 4px 11px; border-radius: 20px;
  background: var(--bg-3); border: 1px solid var(--line); color: var(--text-dim);
  cursor: pointer; transition: all .12s;
}
.tag-chip:hover { color: var(--text); border-color: #35415a; }
.tag-chip.on { color: #fff; background: var(--accent-soft); border-color: var(--accent); }

/* ---------- shared meta bits (department rows, strips, sections) ---------- */
.dr-meta {
  margin-left: auto; font-family: var(--font-mono); font-size: 13px;
  color: var(--text-faint); white-space: nowrap; transition: color .18s;
}
.dr-arrow { display: inline-block; transition: transform .22s; }

/* ---------- home: spotlight hero + directory strip (approved design) ---------- */
.spot { position: relative; height: min(54vh, 520px); min-height: 360px; overflow: hidden; }
.spot > img, .spot > video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity .7s ease;
}
.spot > img.on { opacity: .55; }
.spot > video.on { opacity: .85; }
.spot-shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(7,9,13,.7) 0%, rgba(7,9,13,.22) 55%, rgba(7,9,13,.03) 100%),
    linear-gradient(0deg, rgba(7,9,13,.8) 0%, transparent 30%);
}
.spot-inner { position: relative; z-index: 2; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; padding-bottom: 34px; }
.spot-inner h1 { margin: 0 0 8px; font-size: clamp(30px, 4.4vw, 52px); font-weight: 600; letter-spacing: -0.015em; text-shadow: 0 0 40px rgba(0,0,0,.6); }
.spot-inner p { margin: 0 0 18px; color: var(--text-dim); max-width: 540px; font-size: 15px; line-height: 1.55; }
.spot-inner .btn { align-self: flex-start; }
.dir-strip-clip { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: rgba(9,12,18,.6); }
.dir-strip { display: flex; }
.dir-item {
  flex: 1; padding: 15px 16px 13px; border-right: 1px solid var(--line);
  border-top: 2px solid transparent; margin-top: -1px;
  transition: background .15s, border-color .15s;
}
.dir-item:first-child { padding-left: 0; }
.dir-item:last-child { border-right: 0; }
.dir-item:hover { text-decoration: none; background: rgba(52,146,235,.05); }
.dir-item.on { border-top-color: var(--accent); background: rgba(52,146,235,.07); }
.di-name { display: block; font-size: 14.5px; font-weight: 600; color: var(--text); margin-bottom: 3px; }
.dir-item.soon .di-name { color: var(--text-faint); }
.dir-item .dr-meta { font-size: 11.5px; }
.dir-item.on .dr-meta { color: var(--accent); }
.announce {
  position: relative; display: block; overflow: hidden; margin-top: 28px;
  border-radius: 12px; border: 1px solid rgba(47, 191, 113, .35);
  box-shadow: 0 8px 40px rgba(0,0,0,.4), 0 0 26px rgba(47, 191, 113, .1);
  transition: border-color .18s, box-shadow .2s, transform .18s;
}
.announce:hover { text-decoration: none; border-color: var(--green); box-shadow: 0 10px 46px rgba(0,0,0,.5), 0 0 34px rgba(47,191,113,.22); transform: translateY(-2px); }
/* direct child only — the backdrop. The product thumbnail lives inside
   .an-inner and must not be stretched across the whole bar. */
.announce > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .35; }
/* Featured a specific product: show the product, not just a mood image. */
.an-thumb {
  flex: 0 0 auto; width: 72px; aspect-ratio: 16 / 9; object-fit: cover;
  border-radius: 7px; border: 1px solid rgba(255,255,255,.18);
  box-shadow: 0 4px 14px rgba(0,0,0,.5);
}
.announce.is-product:hover .an-thumb { border-color: rgba(47,191,113,.55); }
@media (max-width: 700px) { .an-thumb { width: 56px; } }
.an-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(7,9,13,.94) 0%, rgba(7,9,13,.72) 55%, rgba(7,9,13,.35) 100%); }
.an-inner { position: relative; z-index: 2; display: flex; align-items: center; gap: 16px; padding: 16px 20px; flex-wrap: wrap; }
.an-chip { color: var(--green); border-color: rgba(47,191,113,.45); background: rgba(47,191,113,.12); flex: 0 0 auto; }
.an-text { font-size: 15.5px; font-weight: 600; color: var(--text); letter-spacing: .005em; }
.an-btn { margin-left: auto; flex: 0 0 auto; }

.free-row { padding-top: 34px; }
.free-row-head h2 { margin: 0 0 4px; font-size: 21px; }

/* ---------- route transitions (dissolve, not a cut) ---------- */
#view.route-out { opacity: 0; transform: translateY(8px); transition: opacity .14s ease-in, transform .14s ease-in; }
#view.route-in { animation: routein .38s cubic-bezier(.2,.8,.25,1); }
@keyframes routein { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.fade-block { animation: routein .32s cubic-bezier(.2,.8,.25,1); }

/* NEW + SALE badges on asset cards */
.chip.new { color: #fff; background: linear-gradient(135deg, var(--accent), #1f6cc0); border-color: transparent; font-weight: 500; }
.chip.sale { color: #ff9066; border-color: rgba(255, 122, 74, .5); background: rgba(255, 110, 64, .14); font-weight: 600; }
.chip.free-demo { color: var(--green); border-color: rgba(47, 191, 113, .5); background: rgba(47, 191, 113, .12); font-weight: 600; }
.ac-flags { position: absolute; top: 8px; left: 8px; z-index: 2; display: flex; gap: 6px; }
.ac-flags .chip { box-shadow: 0 2px 12px rgba(0,0,0,.5); }

/* sale pricing: struck original + discounted */
.was { color: var(--text-faint); text-decoration: line-through; font-size: .86em; margin-right: 2px; font-weight: 400; }
.now { color: #ff9066; }

/* ---------- department page: cinematic video header (dept.videoHeader) ---------- */
.dept-hero { position: relative; height: min(38vh, 340px); min-height: 250px; overflow: hidden; border-bottom: 1px solid var(--line); }
.dept-hero > img, .dept-hero > video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity .7s ease;
}
.dept-hero > img.on { opacity: .55; }
.dept-hero > video.on { opacity: .85; }
.dept-hero-shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(7,9,13,.68) 0%, rgba(7,9,13,.24) 55%, rgba(7,9,13,.04) 100%),
    linear-gradient(0deg, rgba(7,9,13,.78) 0%, transparent 33%);
}
.dept-hero-inner { position: relative; z-index: 2; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; padding-bottom: 26px; }
.dept-hero-inner .crumb { margin-bottom: 8px; }
.dept-hero-inner h1 { margin: 0 0 6px; font-size: clamp(26px, 3.6vw, 42px); font-weight: 600; letter-spacing: -0.015em; text-shadow: 0 0 34px rgba(0,0,0,.6); }
.dept-hero-inner p { margin: 0; color: var(--text-dim); max-width: 560px; font-size: 14.5px; line-height: 1.55; }

/* collection section action buttons + expander */
.coll-actions { display: flex; gap: 8px; margin-left: auto; flex: 0 0 auto; align-items: center; flex-wrap: wrap; }
/* "Show all N assets in this collection" — the only thing standing between a
   shopper and the other 340 clips in a section, and it used to be dim grey text
   on a nearly invisible dashed line, so people missed it entirely (Alex,
   2026-08-14). Accent-coloured with a matching dashed edge: still clearly a
   secondary control, no longer scenery. */
.show-more { text-align: center; padding: 6px 0 12px; }
.show-more .btn {
  width: 100%; color: var(--accent); font-weight: 600;
  border: 1px dashed rgba(52, 146, 235, .55);
  background: rgba(52, 146, 235, .06);
}
.show-more .btn:hover {
  color: #fff; border-color: var(--accent); border-style: solid;
  background: var(--accent-soft); box-shadow: 0 0 22px rgba(52, 146, 235, .18);
}

/* buy-entire-collection box (collection page) */
.bundle-box {
  display: flex; align-items: center; gap: 20px; flex-wrap: wrap;
  border: 1px solid rgba(52, 146, 235, .35); border-radius: var(--radius);
  background: linear-gradient(90deg, rgba(52,146,235,.08), rgba(52,146,235,.02));
  padding: 16px 20px; margin: 6px 0 10px;
  box-shadow: 0 0 26px rgba(52,146,235,.07);
}
.bundle-box .bb-left { flex: 1; min-width: 260px; }
.bundle-box h3 { margin: 0 0 4px; font-size: 16px; }
.bundle-box p { margin: 0 0 10px; font-size: 13px; }
.bb-tiers { display: flex; gap: 8px; flex-wrap: wrap; }
.bb-tier {
  font-size: 13px; padding: 7px 13px; border-radius: 8px;
  background: var(--bg-2); border: 1px solid var(--line); color: var(--text-dim);
  transition: all .13s;
}
.bb-tier:hover { color: var(--text); border-color: #35415a; }
.bb-tier.on { color: #fff; background: var(--accent-soft); border-color: var(--accent); }
.bundle-box .btn.primary { flex: 0 0 auto; padding: 12px 22px; }

/* asset page: static image header + swipeable gallery + custom embed block */
.player-still { display: block; width: 100%; aspect-ratio: 16/9; object-fit: cover; }
.player.is-gallery { position: relative; }
.gal-nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
  width: 40px; height: 56px; border: 0; border-radius: 8px;
  background: rgba(7,9,13,.55); color: #fff; font-size: 26px; line-height: 1;
  backdrop-filter: blur(4px); transition: background .15s;
}
.gal-nav:hover { background: rgba(52,146,235,.55); }
.gal-nav.prev { left: 10px; }
.gal-nav.next { right: 10px; }
.gal-count {
  position: absolute; top: 10px; right: 12px; z-index: 3;
  font-size: 11px; color: #fff; background: rgba(7,9,13,.65);
  padding: 3px 8px; border-radius: 6px;
}
/* Thumbnail strip under the player — the thing that tells you a gallery is
   here at all. Scrolls horizontally when there are more than fit. */
.gal-strip {
  display: flex; gap: 8px; margin-top: 10px; padding-bottom: 6px;
  overflow-x: auto; scroll-snap-type: x proximity;
  scrollbar-width: thin; scrollbar-color: var(--line) transparent;
}
.gal-strip::-webkit-scrollbar { height: 6px; }
.gal-strip::-webkit-scrollbar-track { background: transparent; }
.gal-strip::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }
.gal-strip:hover::-webkit-scrollbar-thumb { background: rgba(255,255,255,.22); }
.gal-thumb {
  position: relative; flex: 0 0 auto; width: 104px; aspect-ratio: 16 / 9;
  padding: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden;
  background: #000; cursor: pointer; scroll-snap-align: start;
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.gal-thumb img, .gal-thumb video { width: 100%; height: 100%; object-fit: cover; display: block; }
.gal-thumb:hover { transform: translateY(-2px); border-color: rgba(255,255,255,.4); }
.gal-thumb.on { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 6px 18px rgba(52,146,235,.28); }
/* dim what isn't selected so the current item reads instantly */
.gal-thumb:not(.on) img, .gal-thumb:not(.on) video { opacity: .62; }
.gal-thumb:not(.on):hover img, .gal-thumb:not(.on):hover video { opacity: .9; }
.gt-play {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-size: 15px; color: #fff; text-shadow: 0 2px 8px rgba(0,0,0,.8);
  background: linear-gradient(transparent 35%, rgba(0,0,0,.45));
  pointer-events: none;
}
@media (max-width: 700px) { .gal-thumb { width: 84px; } }
.gal-dots { position: absolute; bottom: 12px; left: 0; right: 0; z-index: 3; display: flex; justify-content: center; gap: 7px; }
.gal-dot {
  width: 8px; height: 8px; border-radius: 50%; cursor: pointer;
  background: rgba(255,255,255,.35); transition: all .15s;
}
.gal-dot:hover { background: rgba(255,255,255,.65); }
/* the gallery's video item is a wider dot, so "the first one plays" is visible
   before you click it (asset gallery can lead with the watermarked preview) */
.gal-dot.is-video { width: 20px; border-radius: 4px; }
/* the slot holds either an <img> or a <video>; both are .player-still, so it
   just needs to not collapse while swapping */
.gal-slot { display: block; }
.gal-dot.on { background: var(--accent); box-shadow: 0 0 8px var(--accent-glow); }
.custom-block { padding: 10px 0 50px; }
.custom-block img, .custom-block video { max-width: 100%; }

/* ---------- department page: category sidebar + collection sections ---------- */
.dept-page { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 28px; align-items: start; padding-bottom: 70px; }
.cat-side { position: sticky; top: 78px; display: flex; flex-direction: column; gap: 5px; }
.cat-search { width: 100%; margin-bottom: 10px; font-size: 13.5px; }
.cat-tab {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  padding: 9px 12px; border-radius: 8px; font-size: 14px;
  background: transparent; border: 1px solid transparent; color: var(--text-dim);
  transition: all .13s;
}
.cat-tab:hover { color: var(--text); background: var(--bg-2); }
.cat-tab.on { color: #fff; background: var(--accent-soft); border-color: rgba(52,146,235,.4); box-shadow: 0 0 14px var(--accent-soft); }
.cat-tab .ct-icon { width: 20px; text-align: center; font-size: 14px; }
.cat-tab .ct-name { flex: 1; }
.cat-tab .ct-count { font-family: var(--font-mono); font-size: 11px; color: var(--text-faint); }
.cat-tab.on .ct-count { color: var(--accent); }

.coll-section { margin-bottom: 34px; }
.coll-section-head {
  display: flex; align-items: flex-start; gap: 16px;
  border-bottom: 1px solid var(--line); padding-bottom: 12px;
}
.coll-section-head h2 { margin: 0 0 4px; font-size: 20px; font-weight: 600; }
.coll-section-head p { margin: 0; color: var(--text-dim); font-size: 13.5px; line-height: 1.5; max-width: 640px; }
.coll-section-head .btn { margin-left: auto; flex: 0 0 auto; }

.empty-state { text-align: center; padding: 70px 20px; color: var(--text-dim); }
.empty-state .es-icon { font-size: 40px; margin-bottom: 12px; opacity: .6; }
.empty-state h3 { margin: 0 0 6px; color: var(--text); }
.empty-state p { margin: 0; font-size: 14px; }

/* ---------- asset grid + hover preview ---------- */
.page-head { padding: 42px 0 8px; }
.page-head h1 { margin: 0 0 8px; font-size: 30px; font-weight: 600; }
.page-head p { color: var(--text-dim); max-width: 680px; line-height: 1.55; margin: 0; }
.crumb { font-size: 13px; color: var(--text-faint); margin-bottom: 14px; display: block; }
.crumb a { color: var(--text-dim); }

.filter-row { display: flex; flex-wrap: wrap; gap: 8px; padding: 18px 0 6px; }

.asset-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 20px; padding: 18px 0 70px; }
.asset-card {
  border-radius: var(--radius); overflow: hidden; background: var(--bg-2);
  border: 1px solid var(--line); cursor: pointer;
  transition: border-color .18s, box-shadow .18s, transform .18s;
}
.asset-card:hover { border-color: var(--accent); box-shadow: 0 8px 36px rgba(0,0,0,.5), 0 0 20px var(--accent-soft); transform: translateY(-3px); }
.ac-media { position: relative; aspect-ratio: 16/9; background: #000; overflow: hidden; }
.ac-media img, .ac-media video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ac-media video { opacity: 0; transition: opacity .22s ease; }
.ac-media.playing video { opacity: 1; }
.ac-dur {
  position: absolute; right: 8px; bottom: 8px; z-index: 2;
  font-family: var(--font-mono); font-size: 11px; color: #fff;
  background: rgba(0,0,0,.65); padding: 2px 7px; border-radius: 5px;
}
.ac-play-hint {
  position: absolute; inset: 0; z-index: 1; display: grid; place-items: center;
  opacity: 0; transition: opacity .2s; pointer-events: none;
}
.ac-body { padding: 13px 15px 15px; }
.ac-title { font-size: 15px; font-weight: 600; margin: 0 0 7px; color: var(--text); }
.ac-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.ac-price { margin-left: auto; font-family: var(--font-mono); font-size: 13px; color: var(--text); white-space: nowrap; }
.ac-price.free { color: var(--green); }

/* ---------- asset detail page ---------- */
.asset-page { display: grid; grid-template-columns: minmax(0, 7fr) minmax(300px, 5fr); gap: 34px; padding: 34px 0 80px; align-items: start; }
/* Columns must be allowed to be narrower than their contents. Without this a
   single wide child — the gallery thumb strip is a nowrap flex row, so its
   minimum width is every thumbnail laid end to end — sets the track's minimum
   and pushes the whole page sideways. Cost Alex a broken mobile layout on every
   3D product page, 2026-08-11. Anything that scrolls sideways must be told it
   may shrink; overflow-x alone does not say that. */
.asset-page > *, .dept-page > * { min-width: 0; }
.player {
  border-radius: var(--radius); overflow: hidden; background: #000;
  border: 1px solid var(--line); box-shadow: 0 12px 50px rgba(0,0,0,.55);
}
.player video { display: block; width: 100%; aspect-ratio: 16/9; }
.player .player-embed { display: block; width: 100%; aspect-ratio: 16/9; border: 0; background: #000; }
.player-note { font-size: 12px; color: var(--text-faint); padding: 10px 2px 0; }

.meta-table { width: 100%; border-collapse: collapse; margin-top: 22px; font-size: 14px; }
.meta-table td { padding: 8px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
/* Spec values carry unbreakable strings — texture filenames like
   Speeder_Vehicle_BaseColor.1001.png. A table cannot lay out narrower than its
   longest unbreakable word, so one filename set the table's minimum width and
   pushed a 390px phone sideways. Let them wrap mid-token. */
.meta-table td { overflow-wrap: anywhere; }
.meta-table td:first-child { color: var(--text-faint); width: 120px; font-family: var(--font-mono); font-size: 12px; letter-spacing: .04em; text-transform: uppercase; padding-right: 14px; }
/* Divider heading for a spec block ("Camera & lens") — a second heading inside
   the same table, so the rows keep their column alignment. */
.meta-table .meta-sect th { text-align: left; padding: 26px 0 6px; border-bottom: 1px solid var(--line);
  color: var(--text-dim); font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  letter-spacing: .08em; text-transform: uppercase; }

.buy-panel h1 { font-size: 26px; margin: 0 0 10px; font-weight: 600; }
.buy-panel .desc { color: var(--text-dim); font-size: 14.5px; line-height: 1.6; margin: 0 0 18px; }
/* description under the main video, above the specs table */
.asset-desc { color: var(--text-dim); font-size: 14.5px; line-height: 1.65; margin: 18px 0 8px; max-width: 72ch; }
/* formatted / html description content */
.desc p { margin: 0 0 10px; }
.desc ul, .desc ol { margin: 0 0 10px 20px; }
.desc li { margin: 3px 0; }
.desc h1, .desc h2, .desc h3, .desc h4 { color: var(--text); margin: 14px 0 6px; font-size: 15px; }
.desc img { max-width: 100%; border-radius: 8px; }
.desc a { color: var(--accent); }
.desc > :last-child { margin-bottom: 0; }

/* floating add-to-cart: slides up once the buy panel's button scrolls away */
.float-buy {
  position: fixed; left: 50%; bottom: 16px; z-index: 60;
  transform: translate(-50%, 90px); opacity: 0; pointer-events: none;
  transition: transform .25s ease, opacity .25s ease;
  display: flex; align-items: center; gap: 12px;
  max-width: min(560px, calc(100vw - 24px)); padding: 10px 12px;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: 0 12px 34px rgba(0,0,0,.5);
}
.float-buy.on { transform: translate(-50%, 0); opacity: 1; pointer-events: auto; }
.float-buy img { width: 52px; height: 34px; object-fit: cover; border-radius: 6px; flex: 0 0 auto; }
.fb-info { min-width: 0; }
.fb-title { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 190px; }
.fb-lic { font-size: 11px; color: var(--text-dim); }
.fb-price { font-weight: 600; white-space: nowrap; }
.float-buy .btn { flex: 0 0 auto; }
@media (max-width: 560px) { .float-buy img { display: none; } .fb-title { max-width: 120px; } }
.includes { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 20px; }
.includes h4 { margin: 0 0 10px; font-size: 12px; font-family: var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--text-faint); font-weight: 500; }
.includes-row { display: flex; align-items: center; gap: 10px; padding: 6px 0; font-size: 14px; }
.includes-row .size { margin-left: auto; font-family: var(--font-mono); font-size: 12px; color: var(--text-faint); white-space: nowrap; }
.includes-row .comp-ico { width: 16px; height: 16px; object-fit: contain; flex: none; margin-right: -2px; }
/* A described component (two masters, and the buyer has to pick) gets room for
   the deciding facts. Undescribed rows keep the one-line shape they had. */
.includes-row .inc-body { min-width: 0; }
.includes-row.described { align-items: flex-start; padding: 9px 0; }
.includes-row.described .chip.comp, .includes-row.described .comp-ico { margin-top: 1px; }
.includes-row.described .size { align-self: flex-start; margin-top: 2px; }
.inc-tag { color: var(--text-dim); }
.inc-detail { display: block; margin-top: 3px; font-size: 12px; color: var(--text-faint); line-height: 1.5; }

/* "Buy collection" hover menu — every bundle license tier with its price */
.buycoll { position: relative; display: inline-block; }
.buycoll-menu {
  display: none; position: absolute; top: 100%; right: 0; z-index: 60;
  padding-top: 6px; /* hover bridge — no dead gap between button and menu */
  min-width: 250px;
}
.buycoll:hover .buycoll-menu, .buycoll.open .buycoll-menu { display: block; }
.buycoll-menu > .bc-head, .buycoll-menu > .bc-tier { background: var(--bg-2); }
.bc-head {
  border: 1px solid var(--line); border-bottom: 0; border-radius: 10px 10px 0 0;
  padding: 9px 12px 7px; font-family: var(--font-mono); font-size: 11px;
  letter-spacing: .07em; text-transform: uppercase; color: var(--text-faint);
  box-shadow: 0 10px 34px rgba(0,0,0,.55);
}
.bc-tier {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-top: 0;
  color: var(--text); font-family: var(--font-ui); font-size: 13.5px; text-align: left; cursor: pointer;
  box-shadow: 0 10px 34px rgba(0,0,0,.55);
}
.bc-tier:last-child { border-radius: 0 0 10px 10px; }
.bc-tier:hover { background: #1b3f66; color: #fff; border-color: var(--accent); } /* SOLID blue — translucent accent-soft let the page bleed through */
.bc-price { white-space: nowrap; }
@media (max-width: 900px) {
  /* stacked mobile head left-aligns the button — anchor the menu LEFT so it
     opens inward instead of hanging off the screen edge */
  .buycoll-menu { left: 0; right: auto; min-width: 230px; max-width: calc(100vw - 40px); }
}

/* Shared files (one file sold with several assets) — grouped once per order */
.dl-shared { border: 1px dashed var(--line); border-radius: 10px; padding: 12px 16px; margin: 0 0 18px; }
.dl-shared-head { font-size: 12px; font-family: var(--font-mono); letter-spacing: .06em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 8px; }
.dl-shared .dl-file { padding: 6px 0; }
.dl-shared .comp-ico { width: 16px; height: 16px; object-fit: contain; flex: none; }

.tier-cards { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.tier-card {
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-2);
  padding: 14px 16px; cursor: pointer; transition: border-color .14s, box-shadow .14s;
}
.tier-card:hover { border-color: #35415a; }
.tier-card.selected { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft), 0 0 20px var(--accent-soft); }
.tier-top { display: flex; align-items: baseline; gap: 10px; }
.tier-top .t-name { font-weight: 600; font-size: 15px; }
.tier-top .t-price { margin-left: auto; font-family: var(--font-mono); font-size: 16px; }
.tier-top .t-price.free { color: var(--green); }
.tier-delivers { font-size: 13px; color: var(--text-dim); margin-top: 5px; }
/* The tier card carries the license SUMMARY; the full terms are their own
   page, opened in a new tab so a buyer never loses their place mid-decision. */
.tier-terms { display: inline-block; margin-top: 9px; font-size: 12.5px; color: var(--accent); text-decoration: none; }
.tier-terms:hover { text-decoration: underline; }

.tag-row { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 18px; }

/* ---------- cart drawer ---------- */
.cart-btn { position: relative; }
.cart-count {
  position: absolute; top: -6px; right: -8px; min-width: 18px; height: 18px; border-radius: 9px;
  background: var(--accent); color: #fff; font-size: 11px; font-weight: 600;
  display: grid; place-items: center; padding: 0 5px;
  box-shadow: 0 0 10px var(--accent-glow);
}
.drawer-veil { position: fixed; inset: 0; background: rgba(3,5,8,.6); backdrop-filter: blur(2px); z-index: 90; opacity: 0; pointer-events: none; transition: opacity .2s; }
.drawer-veil.open { opacity: 1; pointer-events: auto; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(430px, 100vw); z-index: 100;
  background: var(--bg-1); border-left: 1px solid var(--line);
  transform: translateX(102%); transition: transform .25s cubic-bezier(.2,.8,.25,1);
  display: flex; flex-direction: column;
  box-shadow: -20px 0 60px rgba(0,0,0,.5);
}
.drawer.open { transform: translateX(0); }
.drawer-head { display: flex; align-items: center; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.drawer-head h3 { margin: 0; font-size: 17px; }
.drawer-head button { margin-left: auto; }
.drawer-body { flex: 1; overflow-y: auto; padding: 14px 20px; }
.drawer-foot { border-top: 1px solid var(--line); padding: 16px 20px 20px; }
.cart-line { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.cart-line img { width: 92px; aspect-ratio: 16/9; object-fit: cover; border-radius: 6px; }
.cart-line .cl-title { font-size: 14px; font-weight: 600; margin: 0 0 3px; }
.cart-line .cl-tier { font-size: 12.5px; color: var(--text-dim); display: flex; align-items: center; gap: 6px; }
.cl-lic-label { flex: 0 0 auto; font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: var(--text-dim); opacity: .75; }
.cart-line .cl-sub { font-size: 11.5px; color: var(--text-dim); opacity: .8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cl-lic {
  max-width: 100%; padding: 2px 4px; font-size: 12px;
  background: var(--bg-3); color: var(--text-dim);
  border: 1px solid var(--line); border-radius: 6px; cursor: pointer;
}
.cl-lic-q {
  flex: 0 0 auto; width: 16px; height: 16px; border-radius: 50%;
  display: grid; place-items: center; font-size: 10.5px; font-weight: 600;
  color: var(--text-dim); border: 1px solid var(--line); text-decoration: none;
}
.cl-lic-q:hover { color: var(--text); border-color: var(--text-dim); text-decoration: none; }
/* license modal — above the drawer (z100); bottom-sheet on mobile */
.lic-modal-veil {
  position: fixed; inset: 0; z-index: 240;
  background: rgba(4, 6, 10, .72); backdrop-filter: blur(3px);
  display: grid; place-items: center; padding: 18px;
  animation: licFade .16s ease;
}
@keyframes licFade { from { opacity: 0; } to { opacity: 1; } }
.lic-modal {
  width: min(680px, 100%); max-height: min(82vh, 720px);
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 24px 70px rgba(0,0,0,.6);
  animation: licPop .18s ease;
}
@keyframes licPop { from { transform: translateY(14px); opacity: .4; } to { transform: none; opacity: 1; } }
.lic-modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.lic-modal-text {
  flex: 1; overflow: auto; -webkit-overflow-scrolling: touch; margin: 0; padding: 16px;
  white-space: pre-wrap; font-family: var(--font-mono); font-size: 12.5px; line-height: 1.65; color: var(--text-dim);
}
.lic-modal-foot { padding: 10px 16px; border-top: 1px solid var(--line); font-size: 11.5px; }
@media (max-width: 640px) {
  .lic-modal-veil { padding: 0; align-items: end; }
  .lic-modal { width: 100%; max-height: 92vh; max-height: 92dvh; border-radius: 14px 14px 0 0; border-bottom: 0; }
  .lic-modal-text { font-size: 12px; padding: 14px; }
}

/* licenses index (footer page) */
.lic-index-row {
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  padding: 14px 16px; margin: 10px 0;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
}
/* The summary decides the row height, so let it wrap and keep the button
   pinned right. Without this, the two longest summaries pushed their button
   onto a second line and that half of the list read as a different design. */
.lic-index-row > div { flex: 1 1 260px; min-width: 0; }
.lic-index-row > .btn { flex: 0 0 auto; }
@media (max-width: 560px) { .lic-index-row > .btn { flex: 1 1 100%; text-align: center; } }

.fb-lic { display: flex; align-items: center; gap: 6px; margin-top: 3px; }
.fb-lic .cl-lic { font-size: 11.5px; padding: 1px 3px; max-width: 170px; }

.license-full {
  white-space: pre-wrap; font-family: var(--font-mono); font-size: 12.5px;
  line-height: 1.65; color: var(--text-dim);
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 20px; margin: 18px 0 14px;
}
.cart-line .cl-right { margin-left: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 9px; }
.cart-line .cl-price { text-align: right; font-family: var(--font-mono); font-size: 13.5px; }
.cart-line .cl-remove {
  font-size: 13px; line-height: 1; padding: 4px 8px; border-radius: 6px; cursor: pointer;
  color: rgba(224, 85, 85, .45); background: none; border: 1px solid transparent;
  transition: color .15s, background .15s, border-color .15s;
}
.cart-line:hover .cl-remove { color: rgba(224, 85, 85, .85); }
.cart-line .cl-remove:hover { color: #fff; background: rgba(224, 85, 85, .3); border-color: rgba(224, 85, 85, .55); }
.cart-total { display: flex; font-size: 15px; margin-bottom: 13px; }
.cart-total strong { margin-left: auto; font-family: var(--font-mono); font-size: 17px; }
.cart-note { font-size: 11.5px; color: var(--text-faint); margin-top: 10px; line-height: 1.5; }
.vd-nudge {
  font-size: 12.5px; color: var(--green); background: rgba(47, 191, 113, .1);
  border: 1px solid rgba(47, 191, 113, .35); border-radius: 8px;
  padding: 9px 12px; margin-bottom: 12px; line-height: 1.45;
}
.vd-line span, .vd-line strong { color: var(--green); }

/* ---------- coupons ---------- */
/* Green, like every other discount in the cart — a coupon is a discount, not
   a different species. The chips read as "these are switched on". */
.cl-coupon { font-size: 11px; color: var(--green); margin-top: 3px; letter-spacing: .01em; }
.coupon-box { margin-bottom: 13px; }
.coupon-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.coupon-chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11.5px; font-family: var(--font-mono); letter-spacing: .02em;
  border-radius: 999px; padding: 4px 6px 4px 10px; border: 1px solid transparent;
}
.coupon-chip.on { color: var(--green); background: rgba(47, 191, 113, .12); border-color: rgba(47, 191, 113, .4); }
.coupon-chip.idle { color: var(--text-faint); background: var(--bg-3); border-color: var(--line); }
.coupon-chip b { font-weight: 600; }
.coupon-x {
  border: none; background: none; cursor: pointer; padding: 0 2px;
  color: inherit; opacity: .6; font-size: 11px; line-height: 1;
}
.coupon-x:hover { opacity: 1; color: var(--red); }
.coupon-row { display: flex; gap: 8px; }
.coupon-row input {
  flex: 1; min-width: 0; padding: 8px 11px; font-size: 12.5px;
  font-family: var(--font-mono); letter-spacing: .06em; text-transform: uppercase;
}
.coupon-row input::placeholder { text-transform: none; letter-spacing: 0; font-family: var(--font-ui); }
.coupon-msg { font-size: 11.5px; margin-top: 6px; color: var(--text-faint); line-height: 1.45; }
.coupon-msg.bad { color: var(--red); }
.coupon-msg.warn { color: var(--amber); }

/* the product page, arrived at from a coupon link */
.coupon-banner {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-size: 12.5px; line-height: 1.45; color: var(--text);
  background: rgba(47, 191, 113, .1); border: 1px solid rgba(47, 191, 113, .38);
  border-radius: 9px; padding: 10px 12px; margin-bottom: 12px;
}
.coupon-banner .cb-tag {
  font-family: var(--font-mono); font-size: 11.5px; font-weight: 600; letter-spacing: .04em;
  color: var(--green); border: 1px solid rgba(47, 191, 113, .45);
  background: rgba(47, 191, 113, .12); border-radius: 999px; padding: 3px 9px; flex: 0 0 auto;
}
.tier-card.couponed { border-color: rgba(47, 191, 113, .45); }
.tier-card.coupon-free {
  border-color: rgba(47, 191, 113, .75);
  box-shadow: 0 0 0 3px rgba(47, 191, 113, .14), 0 0 22px rgba(47, 191, 113, .18);
}
.tier-coupon {
  display: inline-block; margin-top: 6px; font-size: 11px; font-weight: 600;
  letter-spacing: .04em; text-transform: uppercase; color: var(--green);
}
.consent { display: flex; gap: 9px; align-items: flex-start; font-size: 12px; color: var(--text-dim); line-height: 1.5; margin-bottom: 12px; cursor: pointer; }
.consent input { margin-top: 2px; accent-color: var(--accent); flex: 0 0 auto; cursor: pointer; }
.consent:hover { color: var(--text); }
.empty-cart { text-align: center; color: var(--text-faint); padding: 60px 10px; font-size: 14px; }

/* ---------- fake checkout / success ---------- */
.center-panel { max-width: 520px; margin: 70px auto; background: var(--bg-2); border: 1px solid var(--line); border-radius: 14px; padding: 34px 36px; box-shadow: 0 20px 70px rgba(0,0,0,.5); }
.center-panel h2 { margin: 0 0 10px; }
.center-panel p { color: var(--text-dim); line-height: 1.6; }
/* Coming-soon department page: a section that exists but isn't open yet. The
   video is the point, so it takes the width; the copy stays out of its way. */
.cs-wrap { max-width: 1100px; margin: 0 auto; padding: 54px 0 80px; text-align: center; }
.cs-head { margin-bottom: 26px; }
.cs-badge {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; margin-bottom: 16px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--bg-2);
  font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-dim);
}
.cs-head h1 { margin: 0 0 10px; font-size: clamp(30px, 4.6vw, 46px); letter-spacing: -.02em; }
.cs-blurb { max-width: 70ch; margin: 0 auto; color: var(--text-dim); line-height: 1.65; font-size: 15.5px; }
.cs-stage {
  position: relative; border-radius: 14px; overflow: hidden; background: #000;
  border: 1px solid var(--line); box-shadow: 0 30px 90px rgba(0,0,0,.55);
  aspect-ratio: 16 / 9;
}
.cs-stage video, .cs-stage iframe { display: block; width: 100%; height: 100%; object-fit: cover; border: 0; }
.cs-stage-empty { display: grid; place-items: center; background: var(--bg-2); }
.cs-stage-empty span { font-size: 64px; opacity: .5; }
.cs-note { max-width: 70ch; margin: 22px auto 0; color: var(--text-dim); line-height: 1.65; }
.cs-actions { margin-top: 26px; }
@media (max-width: 700px) { .cs-wrap { padding: 32px 0 60px; } }
.spinner { width: 26px; height: 26px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.dl-item {
  display: flex; gap: 18px; align-items: flex-start;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-2);
  padding: 16px; margin-bottom: 14px;
  transition: border-color .15s;
}
.dl-item:hover { border-color: #35415a; }
.dl-item h4 { margin: 0 0 7px; font-size: 16px; }
.dl-media { flex: 0 0 250px; border-radius: 8px; }
.dl-body { flex: 1; min-width: 0; }
.dl-chips { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.dl-license { font-size: 12px; }
.dl-files { border-top: 1px solid var(--line); }
.dl-order-head { display: flex; align-items: center; gap: 10px; margin: 28px 0 12px; padding-bottom: 7px; border-bottom: 1px solid var(--line); }
.dl-order-head .mono { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
/* whole-collection purchase: openable section */
.dl-bundle-acc {
  border: 1px solid rgba(52,146,235,.35); border-radius: 12px;
  background: rgba(52,146,235,.05); margin-bottom: 14px;
  box-shadow: 0 0 18px rgba(52,146,235,.06);
}
.dl-bundle-acc summary {
  display: flex; align-items: center; gap: 13px; cursor: pointer;
  list-style: none; padding: 13px 16px;
}
.dl-bundle-acc summary::-webkit-details-marker { display: none; }
.dl-bundle-acc summary:hover strong { color: var(--accent); }
.dlb-arrow { color: var(--text-faint); font-family: var(--font-mono); transition: transform .15s; flex: 0 0 auto; }
.dl-bundle-acc[open] .dlb-arrow { transform: rotate(90deg); }
.dlb-thumbs { display: flex; flex: 0 0 auto; }
.dlb-thumbs img {
  width: 52px; aspect-ratio: 16/9; object-fit: cover; border-radius: 5px;
  border: 2px solid var(--bg-1); margin-left: -14px;
}
.dlb-thumbs img:first-child { margin-left: 0; }
.dlb-title { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.dlb-title strong { font-size: 15px; }
.dlb-title .faint { font-size: 12.5px; }
.dlb-body { padding: 2px 14px 4px; }
.dlb-body .dl-item { background: var(--bg-1); }
.dl-file { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); margin-top: 8px; font-size: 13.5px; }
.dl-file .mono { font-size: 12px; color: var(--text-dim); }
.dl-file .btn { margin-left: auto; }
.expiry-note { font-size: 12px; color: var(--amber); }

/* ---------- previs banner ---------- */
/* Hidden until the page knows what it is. The storefront went live on
   2026-08-10, so a shopper must never catch "PREVIS PROTOTYPE" flashing before
   boot() resolves — it only appears for offline previs and local dev. */
.previs-banner { display: none; }
.previs-banner.on {
  display: block;
  position: fixed; left: 14px; bottom: 14px; z-index: 200;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em;
  color: var(--amber); background: rgba(20, 15, 5, .9); border: 1px solid rgba(232,161,60,.4);
  padding: 6px 11px; border-radius: 7px; pointer-events: none;
}

/* ---------- toast ---------- */
.toast-holder { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 300; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  background: var(--bg-3); border: 1px solid var(--accent); color: var(--text);
  border-radius: 9px; padding: 11px 18px; font-size: 14px;
  box-shadow: 0 8px 30px rgba(0,0,0,.5), 0 0 18px var(--accent-soft);
  animation: toastin .22s ease;
}
@keyframes toastin { from { opacity: 0; transform: translateY(8px); } }

/* ---------- ADMIN ---------- */
.admin-shell { display: grid; grid-template-columns: 218px 1fr; min-height: 100vh; }
.side {
  border-right: 1px solid var(--line); background: rgba(9, 12, 18, 0.6);
  padding: 18px 14px; position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.side .brand { padding: 4px 8px 18px; }
.side-nav { display: flex; flex-direction: column; gap: 3px; }
.side-nav a {
  display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 8px;
  color: var(--text-dim); font-size: 14px;
}
.side-nav a:hover { color: var(--text); background: var(--bg-2); text-decoration: none; }
.side-nav a.active { color: #fff; background: var(--accent-soft); box-shadow: inset 0 0 0 1px rgba(52,146,235,.35); }
.side-nav .nav-ico { font-family: var(--font-mono); font-size: 12px; width: 20px; text-align: center; color: var(--accent); }
.side-foot { margin-top: auto; padding: 16px 8px 4px; font-size: 12px; color: var(--text-faint); }

.main { padding: 26px 32px 80px; min-width: 0; }
.main-head { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.main-head h1 { font-size: 23px; margin: 0; font-weight: 600; }
.main-head .spacer { flex: 1; }

.panel { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; margin-bottom: 20px; }
.panel h3 { margin: 0 0 14px; font-size: 15px; font-weight: 600; }
.panel h3 small { color: var(--text-faint); font-weight: 400; margin-left: 8px; }

/* upload */
.dropzone {
  border: 2px dashed #2e3a4e; border-radius: 14px; padding: 52px 24px; text-align: center;
  color: var(--text-dim); transition: all .15s; background: rgba(17,22,31,.5);
}
.dropzone.drag { border-color: var(--accent); background: var(--accent-soft); color: var(--text); box-shadow: 0 0 30px var(--accent-soft) inset; }
.dropzone .big { font-size: 17px; color: var(--text); margin-bottom: 6px; }
.dropzone .mono { font-size: 12px; }

.upl-row { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.upl-row:last-child { border-bottom: 0; }
.upl-name { font-family: var(--font-mono); font-size: 12.5px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 0 0 34%; }
.upl-bar { flex: 1; height: 6px; border-radius: 3px; background: var(--bg-3); overflow: hidden; }
.upl-bar i { display: block; height: 100%; background: linear-gradient(90deg, #1f6cc0, var(--accent)); border-radius: 3px; transition: width .18s linear; box-shadow: 0 0 8px var(--accent-glow); }
.upl-state { font-family: var(--font-mono); font-size: 11px; width: 76px; text-align: right; color: var(--text-faint); }
.upl-state.ok { color: var(--green); }
.upl-state.err { color: var(--red); }
.upl-name.err { color: var(--amber); }

/* upload: visual naming-convention legend */
.suffix-legend { display: flex; flex-direction: column; gap: 6px; }
.sfx-row {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 9px 13px; border-radius: 8px;
  background: var(--bg-1); border: 1px solid var(--line);
  border-left: 3px solid var(--line); font-size: 13.5px;
}
.sfx-row.is-media { border-left-color: var(--accent); }
.sfx-row:not(.is-media):not(.sfx-bad) { border-left-color: var(--green); }
.sfx-row.sfx-bad { border-left-color: var(--amber); opacity: .85; }
.sfx-name { font-size: 12.5px; color: var(--text-dim); }
.sfx-name b { color: var(--text); font-weight: 600; }
.sfx-arrow { color: var(--text-faint); }
.sfx-label { color: var(--text-dim); }

.group-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-1); padding: 14px 16px; margin-bottom: 12px; }
.group-card h4 { margin: 0 0 8px; font-size: 14px; display: flex; align-items: center; gap: 9px; }
.group-card .gc-file { display: flex; align-items: center; gap: 9px; font-size: 13px; padding: 5px 0; color: var(--text-dim); }
.group-card .gc-file .mono { font-size: 12px; }

.tray { border: 1px solid rgba(232,161,60,.4); background: rgba(232,161,60,.06); border-radius: var(--radius); padding: 14px 16px; }
.tray-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; flex-wrap: wrap; }
.tray-row .mono { font-size: 12.5px; }
.tray-row select { padding: 6px 10px; font-size: 13px; }

/* tables */
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th { text-align: left; font-family: var(--font-mono); font-size: 11px; letter-spacing: .07em; text-transform: uppercase; color: var(--text-faint); font-weight: 500; padding: 8px 12px; border-bottom: 1px solid var(--line); }
.tbl td { padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:hover td { background: rgba(52,146,235,.04); }
.tbl tr.clickable { cursor: pointer; }
.tbl .thumb { width: 74px; aspect-ratio: 16/9; object-fit: cover; border-radius: 5px; display: block; }

/* editor */
.editor-grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(280px, 2fr); gap: 20px; align-items: start; }
.field { margin-bottom: 14px; }
.field label { display: block; font-family: var(--font-mono); font-size: 11px; letter-spacing: .07em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 6px; }
/* editable spec-row title: looks like the label until focused */
.field input.spec-key { width: 100%; border: none; background: transparent; padding: 0; font-family: var(--font-mono); font-size: 11px; letter-spacing: .07em; text-transform: uppercase; color: var(--text-faint); border-radius: 4px; }
.field input.spec-key:hover, .field input.spec-key:focus { background: rgba(110, 168, 254, .08); color: var(--text); outline: none; box-shadow: 0 0 0 1px rgba(110, 168, 254, .35); }
.field input, .field select, .field textarea { width: 100%; }
.field textarea { min-height: 88px; resize: vertical; line-height: 1.5; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* tiny software logos on catalog cards + the editor's picker chips */
.ac-sw { width: 16px; height: 16px; object-fit: contain; border-radius: 3px; vertical-align: middle; }
.sw-picker { display: flex; flex-wrap: wrap; gap: 8px; }
.sw-chip { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; opacity: .45; border: 1px solid var(--line); background: transparent; }
.sw-chip img { width: 16px; height: 16px; object-fit: contain; border-radius: 3px; }
.sw-chip.on { opacity: 1; border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent-soft); }
.sw-chip:hover { opacity: .85; }

.comp-row { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.comp-row:last-child { border-bottom: 0; }
.comp-row .c-label { font-size: 14px; }
.comp-row .c-size { font-family: var(--font-mono); font-size: 12px; color: var(--text-faint); }
.comp-row .c-actions { margin-left: auto; display: flex; gap: 6px; }

.switch { position: relative; width: 38px; height: 21px; flex: 0 0 auto; cursor: pointer; }
.switch input { display: none; }
.switch i { position: absolute; inset: 0; border-radius: 11px; background: var(--bg-3); border: 1px solid var(--line); transition: all .15s; }
.switch i::after { content: ""; position: absolute; top: 2px; left: 2px; width: 15px; height: 15px; border-radius: 50%; background: var(--text-faint); transition: all .15s; }
.switch input:checked + i { background: var(--accent-soft); border-color: var(--accent); }
.switch input:checked + i::after { left: 18px; background: var(--accent); box-shadow: 0 0 8px var(--accent-glow); }

.tier-edit { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-1); padding: 13px 15px; margin-bottom: 10px; }
.tier-edit-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.tier-edit-row select { flex: 1; min-width: 150px; }
.tier-edit-row .price-in { width: 100px; font-family: var(--font-mono); }
.tier-comps { display: flex; gap: 14px; margin-top: 10px; flex-wrap: wrap; }
.tier-comps label { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-dim); cursor: pointer; }
.mismatch { display: flex; gap: 8px; align-items: flex-start; margin-top: 10px; font-size: 12.5px; color: var(--amber); background: rgba(232,161,60,.08); border: 1px solid rgba(232,161,60,.3); border-radius: 7px; padding: 8px 11px; }

/* collections admin */
.coll-acc summary { display: flex; align-items: center; gap: 9px; cursor: pointer; list-style: none; font-size: 14px; flex-wrap: wrap; }
/* shared-collection reference row: reads like a collection line item, but
   it's a pointer — dashed border, click jumps to the real card */
.shared-row { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; font-size: 14px; border-style: dashed; cursor: pointer; }
.shared-row:hover { border-color: var(--accent); }
.shared-row:hover strong { color: var(--accent); }
.shared-row .acc-arrow { color: var(--text-faint); font-family: var(--font-mono); }
.coll-acc summary::-webkit-details-marker { display: none; }
.coll-acc summary:hover strong { color: var(--accent); }
.coll-acc .acc-arrow { color: var(--text-faint); font-family: var(--font-mono); transition: transform .15s; }
.coll-acc[open] .acc-arrow { transform: rotate(90deg); }
.coll-acc .acc-body { padding-top: 12px; }
.bundle-admin { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 0 10px; }
.bundle-tier-row { display: inline-flex; align-items: center; gap: 6px; }
.bundle-tier-row select { padding: 5px 8px; font-size: 12.5px; }
.bundle-tier-row input { padding: 5px 8px; font-size: 12.5px; }

.coll-asset-row {
  display: flex; align-items: center; gap: 12px; padding: 9px 12px; margin-bottom: 6px;
  background: var(--bg-1); border: 1px solid var(--line); border-radius: 8px; cursor: grab; font-size: 14px;
}
.coll-asset-row.dragging { opacity: .4; border-style: dashed; }
.coll-asset-row .drag-dots { color: var(--text-faint); font-family: var(--font-mono); cursor: grab; }
/* "↑ Top" — visible on hover only, but its space is always reserved, so rows
   do not jump sideways as the pointer travels down a long collection. */
.coll-asset-row .row-top { visibility: hidden; opacity: 1; flex: 0 0 auto; white-space: nowrap; padding: 2px 8px; font-size: 11.5px; }
.coll-asset-row:hover .row-top { visibility: visible; }
.coll-asset-row .row-top:disabled { visibility: hidden !important; }
.coll-asset-row:hover .row-top:disabled { visibility: visible; opacity: .3; cursor: default; }
.coll-asset-row img { width: 58px; aspect-ratio: 16/9; object-fit: cover; border-radius: 4px; }

/* analytics */
.an-bar { flex: 1; height: 8px; border-radius: 4px; background: var(--bg-3); overflow: hidden; }
.an-bar i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, #1f6cc0, var(--accent)); box-shadow: 0 0 8px var(--accent-glow); }
.rev-wrap { position: relative; }
.rev-wrap svg { display: block; width: 100%; height: auto; cursor: crosshair; }
.rev-axis { font-family: "DM Mono", monospace; font-size: 10px; fill: #5b6577; }
/* order detail expansion */
.odetail td { background: var(--bg-1) !important; padding: 0 12px 14px; }
.odetail-box { border: 1px solid rgba(52,146,235,.3); border-radius: 10px; padding: 12px 14px; margin-top: 4px; }
.odetail-totals { display: flex; flex-direction: column; gap: 5px; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 13.5px; }
.odetail-totals > div { display: flex; justify-content: space-between; gap: 20px; }
/* a course claim can carry a dozen assets — scroll the items, keep the totals
   in view instead of letting one order own the whole screen */
.odetail-items { max-height: 340px; overflow-y: auto; }
.odetail-items thead th { position: sticky; top: 0; background: var(--bg-1); z-index: 1; }
/* "+N more" on a collapsed row — hover names the rest */
.chip.omore { cursor: pointer; border-style: dashed; opacity: .8; }
tr.clickable:hover .chip.omore { opacity: 1; border-color: rgba(52,146,235,.55); }

.rev-breakdown {
  margin-top: 18px; padding: 14px 16px 8px;
  background: var(--bg-1); border: 1px solid rgba(52,146,235,.3); border-radius: 10px;
  animation: routein .3s cubic-bezier(.2,.8,.25,1);
}
.rev-tip {
  position: absolute; z-index: 5; pointer-events: none;
  background: rgba(9, 12, 18, .95); border: 1px solid var(--accent); border-radius: 8px;
  padding: 7px 11px; font-size: 13px; font-family: var(--font-mono); line-height: 1.45;
  box-shadow: 0 6px 24px rgba(0,0,0,.5), 0 0 14px var(--accent-soft);
  white-space: nowrap;
}

/* media library */
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; margin-top: 20px; }
.media-card { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.mc-preview { position: relative; aspect-ratio: 16/9; background: #000; }
.mc-preview img, .mc-preview video { width: 100%; height: 100%; object-fit: cover; display: block; }
.mc-type { position: absolute; top: 7px; left: 7px; }
.mc-body { padding: 10px 12px 12px; }
.mc-name { font-size: 12px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-meta { font-size: 10.5px; margin: 3px 0 6px; }
.mc-url {
  font-size: 10.5px; color: var(--text-faint); background: var(--bg-1);
  border: 1px solid var(--line); border-radius: 5px; padding: 4px 7px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

/* admin modal (new-asset popup) */
.modal-veil {
  position: fixed; inset: 0; z-index: 250; display: grid; place-items: center;
  background: rgba(3,5,8,.7); backdrop-filter: blur(3px);
  animation: toastin .18s ease;
}
.modal {
  width: min(420px, 92vw); background: var(--bg-2); border: 1px solid var(--line);
  border-radius: 14px; padding: 26px 28px;
  box-shadow: 0 30px 90px rgba(0,0,0,.6), 0 0 40px rgba(52,146,235,.08);
  /* A modal taller than the window used to put its own buttons off-screen with
     no way to reach them — it had never held more than a handful of rows. */
  max-height: min(86vh, 860px); overflow-y: auto;
}
/* Modals holding a long list: header and footer stay put, only the list moves,
   so Apply is always reachable no matter how many licences exist. */
.modal.tall { width: min(640px, 94vw); display: flex; flex-direction: column; overflow: hidden; padding: 22px 24px; }
.modal.tall .modal-list { flex: 1; min-height: 0; overflow-y: auto; margin: 0 -6px; padding: 2px 6px; }
.modal.tall .modal-foot { flex: 0 0 auto; display: flex; gap: 8px; justify-content: flex-end; align-items: center; padding-top: 14px; margin-top: 4px; border-top: 1px solid var(--line); }
/* Sweep-to-select rows, used anywhere a list is picked many-at-a-time (coupon
   scope, licence limits). Press on a row and drag — same gesture as the assets
   table. The box is drawn but not clickable in its own right, so the whole row
   is one target and a drag can't start inside the checkbox and stall. */
.pick-row {
  display: flex; align-items: center; gap: 10px; padding: 6px 8px; font-size: 13.5px;
  border: 1px solid transparent; border-radius: 8px; cursor: pointer; user-select: none;
}
.pick-row:hover { border-color: var(--line); }
.pick-row.sel { background: rgba(52,146,235,.08); border-color: rgba(52,146,235,.4); }
.pick-row img { width: 50px; height: 30px; object-fit: cover; border-radius: 5px; background: #000; flex: none; }
.pick-row input[type="checkbox"] { flex: none; pointer-events: none; }
.pick-row .pk-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pick-row .pk-sub { flex: none; font-size: 11.5px; color: var(--text-faint); }
/* the same rows inline on a page (not in a modal), laid out as a wrapping grid */
.pick-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 2px 10px; }
/* Licences & prices rows: name grows, the note sits under it, price stays put */
.bt-row { display: flex; gap: 10px; align-items: center; padding: 7px 0; font-size: 13.5px; }
.bt-row .bt-name { flex: 1; min-width: 0; }
.bt-row .bt-note { display: block; font-size: 11.5px; color: var(--amber); margin-top: 2px; }
.bt-row .bt-price { width: 90px; flex: none; }
.bt-row .bt-unify { flex: none; }
.bt-head { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-faint);
  margin: 12px 0 2px; padding-top: 8px; border-top: 1px solid var(--line); }
.bt-head:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
/* Default-tier ladder, one row per asset kind */
.dtk-row { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 13.5px; }
.dtk-row:first-of-type { border-top: 0; }
.dtk-row .dtk-kind { flex: 0 0 210px; }
.dtk-row .dtk-lad { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
/* "check your inbox" panel on a successful claim from an unrecognised visitor */
.claim-sent { margin: 18px auto 0; max-width: 460px; padding: 14px 16px; text-align: left;
  border: 1px solid rgba(52,146,235,.35); background: var(--accent-soft); border-radius: 10px; }
.claim-sent p { margin: 6px 0 0; font-size: 13px; }
.claim-sent .faint { font-size: 12px; line-height: 1.5; }
.tbl tr.sel td { background: rgba(52,146,235,.08); }

/* auth gate */
.gate { min-height: 100vh; display: grid; place-items: center; }
.gate-card { width: min(400px, 92vw); background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; padding: 40px 38px; text-align: center; box-shadow: 0 30px 90px rgba(0,0,0,.6), 0 0 60px rgba(52,146,235,.08); }
.gate-card .brand { justify-content: center; margin-bottom: 22px; }
.gate-card h2 { margin: 0 0 8px; font-size: 20px; }
.gate-card p { color: var(--text-dim); font-size: 13.5px; margin: 0 0 24px; line-height: 1.55; }
.google-btn { width: 100%; justify-content: center; padding: 12px; font-size: 15px; }

/* responsive */
@media (max-width: 900px) {
  /* minmax(0,1fr), never a bare 1fr: bare 1fr floors the track at the content's
     min-content width, which is how one nowrap strip widened the entire page */
  .asset-page { grid-template-columns: minmax(0, 1fr); }
  .dept-page { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .spot { height: 46svh; min-height: 300px; }
  .site-strip-inner { height: 52px; gap: 8px; padding: 0 10px; }
  .site-strip a { font-size: 12px; padding: 8px 13px; letter-spacing: .06em; white-space: nowrap; }
  .dept-hero { height: 240px; }
  .coll-actions { width: 100%; }
  .bundle-box { flex-direction: column; align-items: stretch; }
  .bundle-box .btn.primary { width: 100%; }
  /* department strip: no sideways scroll — 2-col grid, all visible */
  .dir-strip { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; padding: 10px 16px 12px; }
  .dir-item {
    border: 1px solid var(--line); border-radius: 9px; padding: 10px 13px;
    margin-top: 0; background: var(--bg-2);
  }
  .dir-item:first-child { padding-left: 13px; }
  .dir-item:last-child { border-right: 1px solid var(--line); }
  .dir-item:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .dir-item.on { border-color: var(--accent); box-shadow: 0 0 14px var(--accent-soft); }
  .di-name { font-size: 13px; }
  /* category tabs wrap instead of scrolling */
  .cat-side { position: static; flex-direction: row; flex-wrap: wrap; gap: 6px; padding-bottom: 4px; }
  .cat-search { flex: 1 1 100%; min-width: 0; margin-bottom: 4px; }
  .cat-tab { width: auto; white-space: nowrap; border: 1px solid var(--line); }
  .coll-section-head { flex-direction: column; gap: 8px; }
  .coll-section-head .btn { margin-left: 0; }
  .dl-item { flex-direction: column; }
  .dl-media { flex: none; width: 100%; }
  .editor-grid { grid-template-columns: 1fr; }
  .admin-shell { grid-template-columns: 1fr; }
  .side { position: fixed; z-index: 80; height: auto; top: auto; bottom: 0; left: 0; right: 0; border-right: 0; border-top: 1px solid var(--line); padding: 8px 10px; background: rgba(9,12,18,.95); backdrop-filter: blur(12px); }
  .side .brand, .side-foot { display: none; }
  .side-nav { flex-direction: row; overflow-x: auto; }
  .side-nav a { flex-direction: column; gap: 3px; font-size: 11px; padding: 7px 10px; white-space: nowrap; }
  .main { padding: 20px 16px 120px; }
  .hero { padding: 44px 0 26px; }
  .topnav { display: none; }
  /* topbar must fit without horizontal scroll: logo mark only, tight gaps */
  .topbar-inner { gap: 10px; height: 56px; padding: 0 14px; }
  .brand > span:not(.brand-mark) { display: none; }
  .dlnav { margin-right: 2px; font-size: 13px; }
  .dlnav-my { display: none; }
  .cart-btn { padding: 8px 14px; }
}

/* ---------- site footer ---------- */
.site-foot { border-top: 1px solid var(--line); background: rgba(255,255,255,.015); margin-top: 40px; }
.site-foot-inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; padding-top: 22px; padding-bottom: 26px; }
.sf-brand { display: flex; align-items: center; gap: 10px; color: var(--text-dim); font-size: 12.5px; }
.sf-brand .brand-mark { transform: scale(.85); }
.sf-links { display: flex; gap: 18px; flex-wrap: wrap; }
.sf-links a { color: var(--text-dim); font-size: 12.5px; text-decoration: none; }
.sf-links a:hover { color: var(--text); }

/* ---------- legal pages ---------- */
/* ---------- course-bundle claim page ----------
   It should read as a gift rather than a form: the value first, the whole
   haul laid out, the email box last. */
.claim-wrap { max-width: 900px; }
.claim-preview {
  margin: 16px 0 -10px; padding: 9px 14px; border-radius: 9px; font-size: 12.5px;
  background: rgba(240,180,41,.12); border: 1px solid rgba(240,180,41,.45); color: var(--amber);
}
.claim-hero { text-align: center; padding: 34px 0 26px; }
.claim-hero h1 { font-size: 32px; margin: 12px 0 6px; }
.claim-lede { max-width: 560px; margin: 0 auto; }
.claim-badge {
  background: rgba(55,201,120,.14); border-color: rgba(55,201,120,.45); color: var(--green);
  letter-spacing: .4px; text-transform: uppercase; font-size: 11px;
}
.claim-value { display: flex; align-items: baseline; justify-content: center; gap: 12px; margin-top: 16px; }
.claim-was { font-family: var(--font-mono); font-size: 26px; color: var(--text-dim); text-decoration: line-through; }
.claim-now { font-size: 26px; font-weight: 700; color: var(--green); }
.claim-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 12px; margin: 8px 0 30px;
}
/* one section per department, so a mixed pack reads in parts */
.claim-sec { margin-bottom: 6px; }
.claim-sec h3 {
  display: flex; align-items: center; gap: 9px; font-size: 14px; margin: 0 0 2px;
  padding-bottom: 8px; border-bottom: 1px solid var(--line);
}
.claim-sec-n {
  background: var(--bg-3); color: var(--text-dim); border-radius: 20px;
  padding: 1px 8px; font-size: 11.5px; font-family: var(--font-mono);
}
.claim-sec-v { margin-left: auto; color: var(--text-dim); font-size: 12.5px; }
.claim-card { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.claim-card-i { position: relative; }
.claim-card img { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: block; background: #000; }
/* Deliberately quiet: the page is about the gift, not about browsing away
   from it. Readable at rest, obvious on hover. */
.claim-view {
  position: absolute; top: 7px; right: 7px; z-index: 2;
  padding: 3px 8px; border-radius: 7px; font-size: 11.5px; text-decoration: none;
  background: rgba(8,11,16,.66); border: 1px solid rgba(255,255,255,.16);
  color: rgba(231,236,243,.72); backdrop-filter: blur(3px);
  opacity: .55; transition: opacity .12s, color .12s, border-color .12s;
}
.claim-card:hover .claim-view { opacity: 1; }
.claim-view:hover { color: #fff; border-color: var(--accent); text-decoration: none; }
.claim-card-b { padding: 9px 11px 11px; }
.claim-card-t { font-size: 13.5px; font-weight: 600; line-height: 1.35; }
.claim-card-p { font-size: 12.5px; margin-top: 3px; color: var(--text-dim); font-family: var(--font-mono); }
.claim-free { color: var(--green); font-weight: 600; }
.claim-box {
  background: var(--bg-1); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px 24px; max-width: 620px; margin: 0 auto;
}
.claim-box h3 { margin: 0 0 6px; font-size: 17px; }
.claim-form { display: flex; gap: 10px; flex-wrap: wrap; }
.claim-form input {
  flex: 1; min-width: 220px; background: var(--bg-0); border: 1px solid var(--line);
  color: var(--text); border-radius: 9px; padding: 11px 13px; font: inherit;
}
.claim-form input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.claim-msg { margin-top: 10px; font-size: 13.5px; min-height: 20px; }
.claim-msg.bad { color: #ff8b8f; }
/* A refusal panel under the form, not a one-line scold — it has to carry the
   way out as well as the bad news. */
.claim-fail {
  margin-top: 12px; padding: 13px 15px; border-radius: 10px;
  background: rgba(229,72,77,.09); border: 1px solid rgba(229,72,77,.4);
  animation: claimFail .18s ease;
}
.claim-fail strong { color: #ff8b8f; display: block; margin-bottom: 3px; }
.claim-fail p { margin: 0; color: var(--text-dim); font-size: 13px; line-height: 1.5; }
.claim-fail-help { margin-top: 7px !important; }
.claim-fail a { color: var(--accent); }
@keyframes claimFail { from { opacity: 0; transform: translateY(-4px); } }
@media (max-width: 620px) { .claim-hero h1 { font-size: 25px; } .claim-form .btn { width: 100%; } }

.legal-wrap { max-width: 760px; }
.legal-wrap h1 { margin-bottom: 4px; }
.legal-wrap h3 { margin: 26px 0 8px; font-size: 15.5px; }
.legal-wrap p, .legal-wrap li { color: var(--text-dim); font-size: 14px; line-height: 1.65; }
.legal-placeholder { display: inline-block; margin: 10px 0 4px; padding: 5px 10px; border: 1px dashed rgba(255,193,7,.5); border-radius: 8px; color: #ffc107; font-size: 12px; font-family: "DM Mono", monospace; }
/* the one-paragraph summary at the top of a legal page — the bit most people
   actually read, so it gets to look like it matters */
.legal-intro { font-size: 15px !important; color: var(--text) !important; line-height: 1.7 !important;
  padding: 14px 16px; margin: 18px 0 6px; border-left: 2px solid var(--accent);
  background: var(--accent-soft); border-radius: 0 10px 10px 0; }
.contact-card { margin: 20px 0 8px; padding: 20px 22px; border: 1px solid var(--line);
  background: var(--bg-2); border-radius: var(--radius); }
.contact-card .btn { font-size: 15px; }
/* "you're reading a superseded version" banner on the license reader */
.legal-wrap .notice { padding: 10px 13px; border: 1px solid rgba(255,193,7,.35); border-radius: 10px; background: rgba(255,193,7,.07); color: var(--text); font-size: 13px; }

/* Spec-table divider in the editor — mirrors the storefront's section heading
   so the portal shows the same split the buyer sees. */
.spec-divider { margin: 18px 0 10px; padding-top: 12px; border-top: 1px solid var(--line);
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--text-dim); }
.spec-divider .faint { text-transform: none; letter-spacing: 0; font-size: 11.5px; }

/* upload group-card quick edit (title + collection inline) */
.gc-quick { display: flex; gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line); align-items: center; flex-wrap: wrap; }
.gc-quick .gc-title { flex: 1 1 220px; min-width: 160px; }
.gc-quick .gc-coll { flex: 0 1 220px; }

/* sortable asset-table headers */
.tbl th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
.tbl th.sortable:hover { color: var(--text); }
.tbl th.sortable .sort-arrow { font-size: 10px; opacity: .45; }
.tbl th.sortable.on { color: var(--accent); }
.tbl th.sortable.on .sort-arrow { opacity: 1; }

/* ---------- floating hover preview (desktop) ---------- */
.hover-pop { position: fixed; z-index: 300; pointer-events: none; opacity: 0; transform: scale(.96); transition: opacity .16s ease, transform .2s ease; border-radius: 12px; overflow: hidden; background: #000; box-shadow: 0 14px 52px rgba(0,0,0,.7), 0 0 0 1px var(--line); }
.hover-pop.on { opacity: 1; transform: scale(1); }
.hover-pop video { width: 100%; height: 100%; object-fit: cover; display: block; }
/* card whose preview is popped out keeps a subtle cue */
.ac-media.popped { outline: 1px solid var(--accent-soft); }

/* checkout validation feedback: shake + red flag on the missed field */
@keyframes ca-shake { 10%,90% { transform: translateX(-2px); } 20%,80% { transform: translateX(4px); } 30%,50%,70% { transform: translateX(-6px); } 40%,60% { transform: translateX(6px); } }
.shake { animation: ca-shake .45s ease; }
.field-error input { border-color: var(--red) !important; box-shadow: 0 0 0 1px rgba(224,85,85,.35); }
.req-note { color: var(--red); font-size: 11.5px; margin-top: 4px; display: block; }
.consent.attn { color: var(--red); }
.consent.attn input[type="checkbox"] { outline: 2px solid rgba(224,85,85,.65); outline-offset: 1px; }

/* cart email section: clear separation from the totals + bright input text */
.co-email-sec { border-top: 1px solid var(--line); margin-top: 12px; padding-top: 12px; margin-bottom: 2px; }
#coEmail { color: var(--text); font-weight: 500; font-size: 14px; }
#coEmail::placeholder { color: var(--text-faint); font-weight: 400; }

/* ---------- course bundles ---------- */
.course-pick { max-height: 300px; overflow: auto; display: grid; gap: 2px; }
.course-row {
  display: flex; align-items: center; gap: 10px; padding: 7px 9px; border-radius: 8px;
  cursor: pointer; font-size: 13px;
}
.course-row:hover { background: var(--bg-2); }
.course-row span:nth-of-type(1) { flex: 1; }
.chosen { display: flex; flex-wrap: wrap; gap: 7px; }
.pick-chip { display: inline-flex; align-items: center; gap: 7px; }
.pick-chip button {
  background: none; border: 0; color: var(--text-dim); cursor: pointer; font-size: 12px; padding: 0 2px;
}
.pick-chip button:hover { color: #ff8b8f; }
.hits { display: grid; gap: 4px; margin-top: 8px; max-height: 320px; overflow: auto; }
.hit {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  background: var(--bg-2); border: 1px solid var(--line); border-radius: 8px;
  padding: 6px 9px; cursor: pointer; color: var(--text); font: inherit; font-size: 13px;
}
.hit:hover { border-color: var(--accent); }
.hit img { width: 54px; height: 34px; object-fit: cover; border-radius: 5px; background: #000; }
.hit span:nth-of-type(1) { flex: 1; }
@media (max-width: 1100px) { .two-col { grid-template-columns: 1fr !important; } }
.pick-group { margin-bottom: 12px; }
.pick-group-h {
  font-size: 12px; color: var(--text-dim); text-transform: uppercase;
  letter-spacing: .5px; margin-bottom: 6px; display: flex; align-items: center; gap: 8px;
}

/* Orders table — when a sale happened. Two lines, quiet by default: the day
   reads first, the clock time sits under it for lining a row up against a
   Stripe payment. Today is accented because those are the rows being looked
   for; everything older recedes. */
.ocell-when { white-space: nowrap; line-height: 1.35; padding-right: 6px; }
.ow-day {
  display: block; font-size: 12.5px; color: var(--text-dim);
  font-variant-numeric: tabular-nums;
}
.ow-day.is-today { color: var(--text); font-weight: 600; }
.ow-time {
  display: block; font-family: var(--font-mono); font-size: 11px;
  color: var(--text-faint); letter-spacing: .01em; font-variant-numeric: tabular-nums;
}

/* A shared block sits under the page's own custom block. Two stacked blocks
   would otherwise pay .custom-block's bottom padding twice, leaving a hole
   between them, so consecutive blocks close the gap and only the last keeps
   the run-out space before the footer. */
.custom-block + .custom-block { padding-top: 0; }
.custom-block:not(:last-child) { padding-bottom: 0; }

/* Draft preview bar. Fixed to the bottom rather than the top: the top of a
   product page is exactly what you opened the preview to look at, and a bar
   pushing the header down would misrepresent the layout being judged. */
.preview-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 200;
  padding: 11px 18px; text-align: center;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em;
  text-transform: uppercase; color: #08111d;
  background: linear-gradient(90deg, #ffc861, #ffb02e);
  box-shadow: 0 -8px 30px rgba(0,0,0,.45);
}
.preview-bar.is-bad { background: linear-gradient(90deg, #ff8f6b, #ff5f45); color: #1a0b06; }
body.has-preview-bar { padding-bottom: 42px; }

/* A shared block placed in the buy panel. Sits under Add to cart rather than
   between the licence picker and it — an aside in the middle of the purchase
   path is a distraction, at the foot of it a service. */
.buy-aside { margin-top: 14px; }
.buy-aside > *:last-child { margin-bottom: 0; }

/* Upload progress panel (Media Library, Shared files). Same rows as the asset
   batch uploader — one visual language for "bytes are moving", wherever you
   happen to be uploading from. */
.upl-panel { padding: 14px 16px; margin-top: 14px; }
.upl-panel h3 { margin: 0 0 8px; font-size: 14px; }
.upl-panel h3 small { font-weight: 400; color: var(--text-faint); margin-left: 8px; font-size: 12px; }

/* Department page trailer: a player you press play on, with sound — not the
   silent montage header. Sits above the catalogue, sized like a product page's
   player so it reads as "watch this", and never taller than the screen. */
.dept-trailer {
  margin: 18px 0 4px; border-radius: var(--radius); overflow: hidden;
  background: #000; border: 1px solid var(--line);
  box-shadow: 0 14px 54px rgba(0,0,0,.55);
}
.dept-trailer video, .dept-trailer iframe {
  display: block; width: 100%; aspect-ratio: 16/9; max-height: 72vh; border: 0; background: #000;
}
