:root {
  --bg: #06080e;
  --card: rgba(10, 14, 24, 0.9);
  --line: rgba(148, 163, 184, 0.25);
  --ink: #e8eef7;
  --muted: #8ea0bf;
  --cyan: #00f5ff;
  --indigo: #6366f1;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100dvh;
  color: var(--ink);
  font-family: "Noto Sans", system-ui, sans-serif;
  background:
    radial-gradient(ellipse at top, rgba(99, 102, 241, 0.2), transparent 52%),
    radial-gradient(ellipse at right, rgba(0, 245, 255, 0.1), transparent 45%),
    linear-gradient(180deg, #0a0d14 0%, #06080e 100%);
}

.artists-header {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(10px);
  background: rgba(6, 8, 14, 0.8);
  border-bottom: 1px solid var(--line);
}

.artists-header__inner {
  width: min(1180px, 92vw);
  margin-inline: auto;
  padding: 1rem 0 1.1rem;
}

.artists-back {
  display: inline-flex;
  text-decoration: none;
  color: #b6f7ff;
  border: 1px solid rgba(0, 245, 255, 0.35);
  border-radius: 999px;
  padding: 0.42rem 0.9rem;
  font-size: 0.86rem;
  font-weight: 700;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.artists-back:hover {
  border-color: rgba(0, 245, 255, 0.6);
  box-shadow: 0 0 18px rgba(0, 245, 255, 0.2);
}

.artists-header h1 {
  margin: 0.8rem 0 0.2rem;
  font-family: "Permanent Marker", cursive;
  font-size: clamp(2rem, 5.3vw, 3rem);
  color: #fff;
  text-shadow: 3px 3px 0 #0e1220, 0 0 22px rgba(0, 245, 255, 0.15);
  font-weight: 400;
}

.artists-header p {
  margin: 0;
  color: var(--muted);
}

.artists-main {
  width: min(1180px, 92vw);
  margin: 1.25rem auto 2rem;
}

.artists-toolbar {
  display: grid;
  grid-template-columns: auto minmax(0, 420px) auto;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1rem;
}

.artists-search-label {
  font-size: 0.9rem;
  color: var(--muted);
}

#artistSearch {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(12, 16, 28, 0.9);
  color: var(--ink);
  padding: 0.72rem 0.82rem;
  font: inherit;
}

#artistSearch:focus {
  outline: none;
  border-color: rgba(0, 245, 255, 0.6);
  box-shadow: 0 0 0 3px rgba(0, 245, 255, 0.16);
}

#artistsCount {
  justify-self: end;
  color: var(--muted);
  font-size: 0.9rem;
}

.artists-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 0.95rem;
}

.artist-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: linear-gradient(170deg, rgba(13, 18, 30, 0.96), rgba(8, 10, 18, 0.95));
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.artist-card:hover {
  transform: translateY(-3px);
  border-color: rgba(0, 245, 255, 0.45);
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.42), 0 0 24px rgba(0, 245, 255, 0.1);
}

.artist-card__media {
  position: relative;
  aspect-ratio: 4 / 3;
  background: #0d1323;
}

.artist-card__badge {
  position: absolute;
  top: 0.55rem;
  left: 0.55rem;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  padding: 0.22rem 0.52rem;
  border-radius: 999px;
  font-size: 0.67rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  color: #04210f;
  background: linear-gradient(135deg, #1ed760, #1db954);
  box-shadow: 0 5px 14px rgba(29, 185, 84, 0.35);
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

.artist-card__badge.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.artist-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.artist-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 0.85rem 0.9rem 1rem;
}

.artist-card__name {
  margin: 0 0 0.45rem;
  font-size: 1rem;
  line-height: 1.25;
  color: #fff;
}

.artist-card__bio {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.48;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.artist-card__links {
  margin-top: auto;
  padding-top: 0.7rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.7rem;
}

.artist-card__wiki {
  display: inline-flex;
  align-items: center;
  color: #dffcff;
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  border: 1px solid rgba(0, 245, 255, 0.38);
  border-radius: 999px;
  padding: 0.3rem 0.62rem;
  background: rgba(0, 245, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  width: fit-content;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.artist-card__spotify {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  width: fit-content;
  text-decoration: none;
  color: #06131a;
  background: linear-gradient(135deg, #1ed760, #1db954);
  border-radius: 999px;
  padding: 0.33rem 0.72rem;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  box-shadow: 0 6px 18px rgba(29, 185, 84, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: transform 0.15s ease, filter 0.2s ease, box-shadow 0.2s ease;
}

.artist-card__spotify:hover {
  filter: brightness(1.07);
  transform: translateY(-1px);
  box-shadow: 0 9px 22px rgba(29, 185, 84, 0.4), 0 0 16px rgba(29, 185, 84, 0.25);
}

.artist-card__spotify:active {
  transform: translateY(0) scale(0.98);
}

.artist-card__spotify-icon {
  width: 0.86rem;
  height: 0.86rem;
  fill: currentColor;
}

.artist-card__wiki:hover {
  color: #fff;
  border-color: rgba(0, 245, 255, 0.72);
  box-shadow: 0 0 18px rgba(0, 245, 255, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.artist-card__spotify[aria-disabled="true"] {
  background: linear-gradient(135deg, #2b3a34, #222e2a);
  color: #93a39e;
  box-shadow: none;
  cursor: default;
  transform: none;
  filter: none;
}

.artist-card__wiki[aria-disabled="true"] {
  color: #74849f;
  border-color: rgba(116, 132, 159, 0.35);
  background: rgba(116, 132, 159, 0.08);
  box-shadow: none;
  cursor: default;
}

@media (max-width: 760px) {
  .artists-toolbar {
    grid-template-columns: 1fr;
  }

  #artistsCount {
    justify-self: start;
  }
}

.artist-modal[hidden] {
  display: none;
}

.artist-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
}

.artist-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 6, 12, 0.72);
  backdrop-filter: blur(4px);
}

.artist-modal__card {
  position: relative;
  width: min(920px, 92vw);
  max-height: 86dvh;
  overflow: auto;
  margin: 7dvh auto 0;
  border-radius: 18px;
  border: 1px solid rgba(0, 245, 255, 0.26);
  background: linear-gradient(170deg, rgba(13, 18, 30, 0.98), rgba(8, 10, 18, 0.97));
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.45), 0 0 24px rgba(0, 245, 255, 0.1);
  padding: 1rem 1rem 1.15rem;
}

.artist-modal__close {
  position: sticky;
  top: 0.35rem;
  margin-left: auto;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: rgba(10, 16, 28, 0.88);
  color: #e8eef7;
  font-size: 1.2rem;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.artist-modal__header {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 1rem;
  align-items: center;
}

.artist-modal__img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid var(--line);
}

.artist-modal__meta h2 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.35rem, 2.8vw, 2rem);
}

.artist-modal__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.artist-modal__link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  border-radius: 999px;
  border: 1px solid rgba(0, 245, 255, 0.35);
  background: rgba(0, 245, 255, 0.08);
  color: #dffcff;
  padding: 0.35rem 0.75rem;
  font-size: 0.78rem;
  font-weight: 800;
}

.artist-modal__section {
  margin-top: 1rem;
}

.artist-modal__section h3 {
  margin: 0 0 0.45rem;
  color: #b6f7ff;
  font-size: 0.95rem;
}

.artist-modal__bio {
  margin: 0;
  color: #d7e2f7;
  line-height: 1.6;
  white-space: pre-line;
}

.artist-modal__disc {
  margin: 0;
  padding-left: 1.1rem;
  color: #c8d6ef;
  line-height: 1.55;
}
