/* Copyright Ayers Electronics Inc. All rights reserved. */
/* The one song or title row (js/track-row.js). The list look: a bordered row on the control's own
   ground, a thumbnail, the title over one fact line, then Options or the NOW mark. The album look: a
   ruled line with the place, the title and its length, then Play and Options. A song's link line sits
   between the face and the buttons. The row's buttons are
   the info screen's icon buttons, all one size; the air between parts is margin, never a flex gap. */

.track-row {
  display: flex;
  align-items: center;
  box-sizing: border-box;
}
.track-row > * + * {
  margin-left: 8px;
}
.track-row-face {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  min-width: 0;
  min-height: var(--info-button-h);
  padding: 0;
  border: 0;
  background: none;
  color: var(--on-panel);
  text-align: left;
}
.track-row-face > * + * {
  margin-left: 12px;
}
.track-row .icon-btn {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: var(--info-button-h);
  height: var(--info-button-h);
  padding: 0;
  border: 1px solid var(--border-soft);
}
.track-row-title {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: var(--type-body);
}
.track-row.now .track-row-title {
  color: var(--accent-text);
  font-weight: 600;
}

/* The list look. */
.track-row.list {
  padding: 8px 12px 8px 8px;
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  background: var(--control-fill);
}
.track-row.list.held {
  border-color: var(--accent);
}
.track-row-thumb {
  flex: none;
  width: var(--info-button-h);
  height: var(--info-button-h);
  object-fit: cover;
  border-radius: var(--radius-small);
  background: var(--panel);
}
.track-row-thumb[data-missing="1"] {
  visibility: hidden;
}
.track-row-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.track-row.list .track-row-title {
  font-weight: 600;
}
.track-row-fact {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: var(--type-label);
  color: var(--muted);
}
/* A song's artist and album beside the face, each a link to its page (js/track-links.js). */
.track-row-links {
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: var(--type-label);
  color: var(--muted);
}
.track-row-now {
  flex: none;
  padding: 2px 6px;
  border-radius: var(--radius-small);
  background: var(--accent);
  color: var(--on-accent);
  font-size: var(--type-micro);
  font-weight: 600;
  letter-spacing: 0.08em;
}

/* The album look. */
.track-row.album {
  padding: 8px 12px 8px 0;
  border-bottom: 1px solid var(--border-soft);
}
.track-row-number {
  flex: none;
  width: 28px;
  text-align: right;
  color: var(--muted);
  font-size: var(--type-label);
}
.track-row.album .track-row-title {
  flex: 1 1 auto;
}
.track-row-length {
  flex: none;
  color: var(--muted);
  font-size: var(--type-label);
}
