/* MyMesh x Spotify: card "ouvindo agora" no perfil e pagina de configuracao */
.mm-spotify { display: none; margin: 10px 0 0; width: 100%; max-width: 262px; position: relative; z-index: 30; } /* acima do que vem depois (abas do perfil) quando o menu abre */
.mm-spotify.is-visible { display: block; }
.mm-spotify__card {
  position: relative; display: flex; align-items: center; gap: 8px; min-width: 0; text-align: left;
  padding: 6px 8px 12px 6px; border-radius: 14px; color: #fff;
  /* vidro (estilo Apple): fundo translucido + desfoque + saturacao, borda de luz e brilho interno */
  background: linear-gradient(135deg, rgba(255, 255, 255, .20) 0%, rgba(255, 255, 255, .06) 55%, rgba(255, 255, 255, .12) 100%), rgba(28, 32, 56, .62);
  -webkit-backdrop-filter: blur(22px) saturate(180%); backdrop-filter: blur(22px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, .28);
  box-shadow: 0 8px 24px rgba(8, 10, 24, .26), inset 0 1px 0 rgba(255, 255, 255, .45), inset 0 -1px 0 rgba(255, 255, 255, .08);
  transition: transform .2s ease, box-shadow .2s ease;
}
.mm-spotify__card:hover { transform: translateY(-1px); box-shadow: 0 12px 28px rgba(8, 10, 24, .32), inset 0 1px 0 rgba(255, 255, 255, .55), inset 0 -1px 0 rgba(255, 255, 255, .1); }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .mm-spotify__card { background: rgba(30, 34, 60, .88); } /* sem suporte a desfoque: fundo mais opaco para manter a leitura */
}

/* capa (ou logo, quando nao ha capa) */
.mm-spotify__cover, .mm-spotify__tile {
  position: relative; flex: 0 0 36px; width: 36px; height: 36px; border-radius: 9px; overflow: visible;
  background: rgba(255, 255, 255, .14); display: block; box-shadow: 0 3px 10px rgba(0, 0, 0, .3);
}
.mm-spotify__cover img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 9px; }
.mm-spotify__tile { display: flex; align-items: center; justify-content: center; }
.mm-spotify__tile svg { width: 20px; height: 20px; fill: #1ed760; }
.mm-spotify__badge {
  position: absolute; right: -4px; bottom: -4px; width: 16px; height: 16px; border-radius: 50%;
  background: #101224; display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .35);
}
.mm-spotify__badge svg { width: 16px; height: 16px; fill: #1ed760; display: block; }
.mm-spotify__cover[hidden], .mm-spotify__tile[hidden] { display: none; }

.mm-spotify__meta { display: flex; flex-direction: column; justify-content: center; min-width: 0; flex: 1 1 auto; line-height: 1.25; }
.mm-spotify .mm-spotify__label {
  font-size: 8px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #3cf27e; margin: 0 0 1px; text-shadow: 0 1px 2px rgba(0, 0, 0, .35);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.mm-spotify .mm-spotify__title, .mm-spotify p.mm-spotify__artist, .mm-spotify p.mm-spotify__note {
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; margin: 0; text-align: left;
}
.mm-spotify .mm-spotify__title { font-size: 12px; font-weight: 700; color: #fff !important; text-shadow: 0 1px 2px rgba(0, 0, 0, .35); }
.mm-spotify a.mm-spotify__title:hover { text-decoration: underline; }
.mm-spotify p.mm-spotify__artist, .mm-spotify p.mm-spotify__note { font-size: 10px; font-weight: 500; color: rgba(255, 255, 255, .82) !important; text-shadow: 0 1px 2px rgba(0, 0, 0, .3); }
.mm-spotify__action {
  align-self: flex-start; margin-top: 4px; padding: 3px 10px; border: 0; border-radius: 999px; cursor: pointer;
  font-size: 10px; font-weight: 700; color: #0b0d1a; background: #3cf27e; transition: filter .15s ease;
}
.mm-spotify__action:hover { filter: brightness(1.1); }
.mm-spotify__action[disabled] { opacity: .6; cursor: default; }
.mm-spotify .mm-spotify__title[hidden], .mm-spotify p[hidden], .mm-spotify__action[hidden], .mm-spotify__label[hidden] { display: none; }

/* onda animada (apenas visual) */
.mm-eq { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 2px; height: 15px; margin-left: 0; }
.mm-eq i { display: block; width: 2.5px; height: 100%; background: #1ed760; border-radius: 2px; transform: scaleY(.3); }
.mm-eq i:nth-child(1) { height: 55%; } .mm-eq i:nth-child(2) { height: 85%; } .mm-eq i:nth-child(3) { height: 100%; }
.mm-eq i:nth-child(4) { height: 70%; } .mm-eq i:nth-child(5) { height: 45%; }
.mm-spotify.is-playing .mm-eq i { animation: mm-eq 1.1s ease-in-out infinite; transform: none; }
.mm-spotify.is-playing .mm-eq i:nth-child(2) { animation-delay: -.5s; animation-duration: .9s; }
.mm-spotify.is-playing .mm-eq i:nth-child(3) { animation-delay: -.2s; animation-duration: 1.2s; }
.mm-spotify.is-playing .mm-eq i:nth-child(4) { animation-delay: -.8s; animation-duration: 1s; }
.mm-spotify.is-playing .mm-eq i:nth-child(5) { animation-delay: -.35s; animation-duration: .8s; }
.mm-eq[hidden] { display: none; }
@keyframes mm-eq { 0%, 100% { transform: scaleY(.35); } 50% { transform: scaleY(1); } }

/* menu "..." */
.mm-spotify__menu { position: static; flex: 0 0 auto; } /* o menu suspenso ancora no card, abaixo dele */
.mm-spotify__more {
  width: 20px; height: 20px; padding: 0; border: 0; border-radius: 50%; cursor: pointer; color: rgba(255, 255, 255, .85);
  background: transparent; display: flex; align-items: center; justify-content: center; transition: background .15s ease, color .15s ease;
}
.mm-spotify__more:hover, .mm-spotify__more[aria-expanded="true"] { background: rgba(255, 255, 255, .22); color: #fff; }
.mm-spotify__more svg { width: 14px; height: 14px; fill: currentColor; }
.mm-spotify__pop {
  position: absolute; right: 0; top: calc(100% + 6px); z-index: 40; min-width: 150px; padding: 4px; border-radius: 12px;
  background: rgba(28, 32, 56, .68); -webkit-backdrop-filter: blur(22px) saturate(180%); backdrop-filter: blur(22px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, .28); box-shadow: 0 12px 28px rgba(8, 10, 24, .35), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.mm-spotify__pop[hidden] { display: none; }
.mm-spotify__pop a { display: block; padding: 6px 9px; border-radius: 8px; font-size: 10px; font-weight: 500; color: #fff !important; text-decoration: none; text-align: left; }
.mm-spotify__pop a:hover, .mm-spotify__pop a:focus { background: rgba(255, 255, 255, .2); }
.mm-spotify__pop a[hidden] { display: none; }

/* barra de progresso */
.mm-spotify__progress { position: absolute; left: 8px; right: 8px; bottom: 5px; height: 2px; border-radius: 2px; background: rgba(255, 255, 255, .22); overflow: hidden; }
.mm-spotify__progress i { display: block; height: 100%; width: 0; border-radius: 3px; background: linear-gradient(90deg, #3cf27e, #c4ffd9); }
.mm-spotify__progress[hidden] { display: none; }

@media (prefers-reduced-motion: reduce) {
  .mm-spotify.is-playing .mm-eq i { animation: none; transform: scaleY(.75); }
  .mm-spotify__card, .mm-spotify__action { transition: none; }
  .mm-spotify__card:hover { transform: none; }
}
@media (max-width: 480px) {
  .mm-spotify { max-width: 100%; margin-left: auto; margin-right: auto; width: fit-content; min-width: 210px; }
  /* fundo da pagina e claro no celular: reforca o tom do vidro para o texto branco continuar legivel */
  .mm-spotify__card { background: linear-gradient(135deg, rgba(255, 255, 255, .16) 0%, rgba(255, 255, 255, .04) 60%, rgba(255, 255, 255, .1) 100%), rgba(28, 32, 56, .62); }
}

/* pagina de configuracao */
.mm-spotify-settings .mm-sp-status { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.mm-spotify-settings .mm-sp-status svg { width: 28px; height: 28px; fill: #1ed760; }
.mm-spotify-settings .mm-sp-flash { padding: 10px 14px; border-radius: 8px; margin-bottom: 14px; font-size: 13px; }
.mm-spotify-settings .mm-sp-flash.ok { background: rgba(30, 215, 96, .12); color: #14803a; }
.mm-spotify-settings .mm-sp-flash.err { background: rgba(220, 53, 69, .1); color: #b02a37; }
.mm-spotify-settings .mm-sp-row { margin-bottom: 14px; }
.mm-spotify-settings .mm-sp-note { font-size: 12px; opacity: .7; margin-top: 14px; }

/* CLX: linha de explicacao nas sugestoes e pagina de configuracao */
.wow_side_usrs .mm-clx-reason { display: block; margin-top: 2px; font-size: 11.5px; line-height: 1.3; color: #8b91a5; }
.mm-clx-settings h5 { margin: 18px 0 8px; font-weight: 600; }
.mm-clx-settings .mm-clx-check { display: flex; gap: 8px; align-items: center; margin: 10px 0 0; font-weight: 500; }
.mm-clx-settings .mm-clx-goals { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px 14px; }
.mm-clx-settings .mm-clx-goals label { display: flex; gap: 8px; align-items: center; font-weight: 400; margin: 0; }
.mm-clx-settings #mm-clx-msg { margin-left: 10px; font-weight: 500; }
.wow_side_usrs .mm-clx-dismiss { margin-left: 4px; color: #b3b8c8; text-decoration: none; font-size: 14px; line-height: 1; }
.wow_side_usrs .mm-clx-dismiss:hover { color: #6b7185; }
