/* Studio page: asset-library (features/studio/asset-library.js). Page-specific styles only; shared ones are in kit.css. */
.al-filters { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.al-filter-row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.al-filter-label { flex: none; width: 76px; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); }
.al-filter-row .sk-chips { min-width: 0; }
.al-select-wrap { position: relative; display: inline-flex; max-width: 100%; }
.al-select { height: 30px; max-width: 100%; padding: 0 30px 0 12px; border-radius: 999px; border: 1px solid var(--border-strong); background: var(--card); font: inherit; font-size: 12.5px; font-weight: 500; color: var(--text); appearance: none; cursor: pointer;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-2) 50%), linear-gradient(135deg, var(--text-2) 50%, transparent 50%);
  background-position: calc(100% - 15px) 13px, calc(100% - 11px) 13px; background-size: 4px 4px; background-repeat: no-repeat; }
.al-select-wrap.on .al-select { border-color: var(--text); }

.al-grid { display: grid; gap: clamp(12px, 1.2vw, 18px); grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr)); }
.al-card { position: relative; padding: 8px; display: flex; flex-direction: column; min-width: 0; transition: box-shadow .2s, border-color .2s; }
.al-card:hover { box-shadow: var(--shadow-card-hover); border-color: light-dark(rgba(0, 0, 0, 0.1), rgba(255, 255, 255, 0.17)); }
.al-card:has(.al-open:focus-visible) { outline: 2px solid rgba(0, 113, 227, 0.5); outline-offset: 2px; }
.al-card .art { border-radius: 10px; }
.al-card .art .fallback .initials { font-size: 20px; }
.al-card.is-canceled .art, .al-card.is-canceled .al-name { opacity: .55; }
.al-body { padding: 10px 6px 4px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.al-name { font-size: 14px; font-weight: 600; letter-spacing: -0.005em; min-width: 0; }
.al-open { display: block; width: 100%; font: inherit; color: inherit; text-align: left; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.al-open::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius-card); }   /* the whole card opens the details */
.al-open:focus-visible { outline: none; }
.al-meta { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pill.al-type { flex: none; max-width: 60%; overflow: hidden; text-overflow: ellipsis; --c: var(--blue-700); --bg: var(--blue-50); --bd: var(--blue-200); }
.pill.al-type.missing { --c: var(--text-3); --bg: transparent; --bd: var(--zinc-200); }
.al-prod { min-width: 0; font-size: 12px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Empty library: a small stack of placeholder cards above the message */
.al-empty { padding: 56px 24px; }
.al-empty p { max-width: 420px; margin: 0 auto; line-height: 1.5; }
.al-empty .sk-kitsu { margin-top: 18px; }
.al-empty-art { position: relative; width: 120px; height: 72px; margin: 0 auto 20px; }
.al-empty-art span { position: absolute; top: 8px; width: 56px; height: 56px; border-radius: 12px; background: linear-gradient(135deg, light-dark(#f1f1f4, #27272d), light-dark(#e6e6ea, #2f2f33)); border: 1px solid var(--border-strong); }
.al-empty-art span:nth-child(1) { left: 4px; transform: rotate(-8deg); }
.al-empty-art span:nth-child(2) { left: 60px; transform: rotate(8deg); }
.al-empty-art span:nth-child(3) { left: 32px; top: 0; background: var(--card); box-shadow: var(--shadow-card-hover); }

/* Drawer */
.al-detail-art { margin-bottom: 22px; }
.al-desc-full { white-space: pre-line; }
.al-detail-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 28px; }

@media (max-width: 640px) {
  .al-filter-row { flex-direction: column; align-items: flex-start; gap: 6px; }
  .al-filter-label { width: auto; }
  .al-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .al-meta { flex-direction: column; align-items: flex-start; gap: 4px; }
  .pill.al-type { max-width: 100%; }
}
@media (max-width: 340px) { .al-grid { grid-template-columns: minmax(0, 1fr); } }
