/* ─── YahYah Artistas — Mosaico livre (linhas justificadas) ─────────────────── */

/*
 * Layout "justified gallery" (tipo Flickr/Google Fotos): o JS
 * (assets/script.js) agrupa as fotos em linhas usando a proporção REAL de
 * cada uma, e cada linha estica (flex-grow) pra preencher exatamente 100%
 * da largura — nunca sobra espaço, nunca precisa de rolagem, e como o
 * quadro já nasce parecido com o formato da foto (não um molde fixo), o
 * corte fica mínimo. Este CSS só define a aparência; o JS monta as
 * `.yah-art-row` dinamicamente.
 */

.yah-art-grid {
    display: block;
}

.yah-art-row {
    display: flex;
    gap: 4px;
    margin-bottom: 4px;
}

.yah-art-tile {
    position: relative;
    overflow: hidden;
    height: 100%;
    background: #0d0d0d;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.yah-art-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block !important;
}

/* ─── Hover / destaque ──────────────────────────────────────────────────────── */
/* O card cresce e fica por cima dos vizinhos — sem cursor de "clique", já
   que não leva a lugar nenhum, só dá destaque à foto. Como o quadro escala
   inteiro (não só a imagem dentro dele), não introduz corte extra: a foto
   continua exatamente na mesma proporção que já tinha em repouso. */

.yah-art-tile:hover,
.yah-art-tile:focus-visible,
.yah-art-tile.is-active {
    transform: scale(1.25);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(195, 158, 82, 0.7);
    outline: none;
    z-index: 20;
}

/* Overlay gradiente + nome */

.yah-art-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        transparent 45%,
        rgba(0, 0, 0, 0.85) 100%
    );
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: flex-start;
    gap: 8px;
    padding: 16px;
    opacity: 0;
    /* Enquanto escondido, os links de Spotify/YouTube não devem ser
       clicáveis (senão um toque no celular, antes de revelar o card,
       podia acidentalmente abrir o link). */
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.yah-art-tile:hover .yah-art-overlay,
.yah-art-tile:focus-visible .yah-art-overlay,
.yah-art-tile.is-active .yah-art-overlay {
    opacity: 1;
    pointer-events: auto;
}

.yah-art-name {
    /* min-width:0 evita o bug clássico de flexbox onde o texto nunca
       quebra linha e acaba sendo cortado pelo overflow:hidden do tile. */
    min-width: 0;
    width: 100%;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #fff;
    line-height: 1.25;
    word-wrap: break-word;
    transform: translateY(8px);
    transition: transform 0.3s ease;
}

.yah-art-tile:hover .yah-art-name,
.yah-art-tile:focus-visible .yah-art-name,
.yah-art-tile.is-active .yah-art-name {
    transform: translateY(0);
}

/* Links de Spotify/YouTube */

.yah-art-links {
    display: flex;
    gap: 8px;
    transform: translateY(8px);
    transition: transform 0.3s ease;
}

.yah-art-tile:hover .yah-art-links,
.yah-art-tile:focus-visible .yah-art-links,
.yah-art-tile.is-active .yah-art-links {
    transform: translateY(0);
}

.yah-art-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    flex-shrink: 0;
    transition: background 0.2s ease, color 0.2s ease;
}

.yah-art-link:hover,
.yah-art-link:focus-visible {
    background: #c39e52;
    color: #0d0d0d;
    outline: none;
}

/* ─── Responsive ────────────────────────────────────────────────────────────── */

@media (max-width: 600px) {
    .yah-art-tile:hover,
    .yah-art-tile:focus-visible,
    .yah-art-tile.is-active {
        transform: scale(1.1);
    }
}
