/* CG Artist File Browser: feature clips (cg-media.js). Chips + one player, CTA, credits. */
.clip-frame { position: relative; aspect-ratio: 16 / 9; max-width: 100%; background: var(--ink); border-radius: 18px; overflow: hidden; border: 1px solid var(--line); }
.clip-frame video, .clip-frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.clip-frame .bar { position: absolute; left: 0; bottom: 0; height: 2px; width: 0; background: var(--accent); opacity: .7; }

/* Chips (shared by spotlight) */
.fchips { display: flex; flex-wrap: wrap; gap: 8px; }
.fc { border: 0; font: inherit; font-size: 14px; color: var(--sub); background: var(--card); padding: 8px 14px 8px 10px; border-radius: 999px; display: inline-flex; align-items: center; gap: 8px; cursor: pointer; transition: background .2s, color .2s, box-shadow .2s; }
.fc .ic { width: 16px; height: 16px; color: var(--muted); transition: color .2s; }
.fc:hover { background: var(--hover); color: var(--text); }
.fc[aria-pressed="true"] { background: var(--hover); color: var(--text); box-shadow: inset 0 0 0 1.5px var(--accent); }
.fc[aria-pressed="true"] .ic { color: var(--accent-hover); }

/* A: spotlight */
.clips-spot .fchips { margin-bottom: 18px; }
.clips-spot .stage { background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 10px; }
.clips-spot .clip-frame { border-radius: 16px; border: 0; }
.clips-spot .cap { display: flex; align-items: baseline; gap: 12px; padding: 14px 12px 6px; flex-wrap: wrap; }
.clips-spot .cap b { font-size: 17px; font-weight: 650; }
.clips-spot .cap span { color: var(--sub); font-size: 15px; min-width: 0; }

.fc .n { font-size: 11px; color: var(--muted); background: var(--surface); padding: 0 7px; border-radius: 999px; line-height: 18px; }
.fc[aria-pressed="true"] .n { color: var(--sub); }
.clip-frame .seg { position: absolute; left: 12px; top: 12px; display: inline-flex; align-items: baseline; gap: 8px; padding: 4px 11px; border-radius: 999px; background: rgba(21,20,19,.78); color: var(--text); font-size: 13px; font-weight: 600; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); pointer-events: none; }
.clip-frame .seg:empty { display: none; }
.clip-frame .seg small { color: var(--muted); font-size: 11.5px; font-weight: 500; font-variant-numeric: tabular-nums; }

.clip-frame { cursor: pointer; }
.clip-frame .flash { position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; background: rgba(21,20,19,.72); color: var(--text); display: grid; place-items: center; opacity: 0; pointer-events: none; }
.clip-frame .flash .ic { width: 26px; height: 26px; }
.clip-frame .flash.on { animation: flash .6s ease-out; }
@keyframes flash { 0% { opacity: 1; transform: scale(.85); } 100% { opacity: 0; transform: scale(1.15); } }
.clip-frame .ticks i { position: absolute; bottom: 0; width: 2px; height: 6px; margin-left: -1px; background: var(--sub); opacity: .55; }
.clips-spot .cap { flex-wrap: nowrap; justify-content: space-between; align-items: center; }
.clips-spot .cap .txt { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; min-width: 0; }
.ctrl { display: flex; gap: 6px; flex: none; }
.cb { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--card); color: var(--text); display: grid; place-items: center; cursor: pointer; transition: background .2s; }
.cb:hover { background: var(--hover); }
.cb .ic { width: 16px; height: 16px; }
.cb.play { background: var(--accent); color: var(--ink); }
.cb.play:hover { background: var(--accent-hover); }
@media (max-width: 600px) {
  .clips-spot .cap { flex-direction: column; align-items: flex-start; gap: 12px; }
}
@media (prefers-reduced-motion: reduce) { .clip-frame .flash.on { animation: none; } }

/* CTA + credits */
.clips-cta { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 24px; padding: 20px 24px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; }
.clips-cta p { color: var(--sub); font-size: 15px; }
.clips-cta p b { color: var(--text); display: block; font-size: 17px; }
.credits { color: var(--muted); font-size: 13px; line-height: 1.6; margin-top: 18px; max-width: none; }
.credits a { color: var(--sub); }

@media (max-width: 600px) {
  .fchips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-right: -20px; padding-right: 20px; }
  .fchips::-webkit-scrollbar { display: none; }
  .fc { flex: none; }
}

/* Chips as an even grid: 3 across, 5 full rows of 15. Phones and tablets get one swipe row. */
@media (min-width: 901px) {
  .fchips { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .fc { justify-content: flex-start; min-width: 0; }
  .fc .n { margin-left: auto; }
  .fc .t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; text-align: left; }
}
@media (min-width: 601px) and (max-width: 900px) {
  .fchips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-right: -20px; padding-right: 20px; }
  .fchips::-webkit-scrollbar { display: none; }
  .fc { flex: none; }
}

/* Chip panel (2026-10-29): same look as the Emulsion "See it work" panel.
   Chips sit in a rounded panel as equal tiles; phones swipe three full rows. */
.clips-spot .fchips { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 20px; margin-bottom: 16px; gap: 8px; }
.clips-spot .fc { border-radius: 14px; min-height: 44px; padding: 9px 12px; }
@media (max-width: 900px) {
  .clips-spot .fchips { display: grid; grid-auto-flow: column; grid-template-rows: repeat(3, auto); grid-auto-columns: 46%; overflow-x: auto; flex-wrap: nowrap; margin-right: 0; padding: 16px; scroll-snap-type: x mandatory; scroll-padding: 16px; }
  .clips-spot .fc { flex: none; justify-content: flex-start; min-width: 0; scroll-snap-align: start; }
  .clips-spot .fc .n { margin-left: auto; }
}
@media (max-width: 600px) {
  .clips-spot .fchips { grid-auto-columns: 72%; }
}
