
/* =========================================================
   MUSICALWORLD — ANÚNCIO DE COMPOSIÇÃO NO FEED

   Arquivo:
   css/index/anuncio-composicao.css

   Responsabilidades:

   - Estilizar exclusivamente os anúncios de composição.
   - Manter identidade visual própria para esse tipo de anúncio.
   - Tornar o card visualmente clicável.
   - Destacar a área de identidade como acesso ao perfil.
   - Manter o áudio independente da navegação do card.
   - Controlar a descrição em duas linhas com expansão.
   - Identificar visualmente o anúncio como composição.
   - Adaptar o card para desktop, tablet e mobile.
   - Não alterar os anúncios de artistas ou estabelecimentos.
   ========================================================= */


/* =========================================================
   CARD PRINCIPAL
   ========================================================= */

.anuncio-composicao {

    position: relative;

    width: 100%;

    background: #ffffff;

    border: 1px solid #e7eaf0;

    border-radius: 24px;

    overflow: hidden;

    box-sizing: border-box;

    /* O espaçamento entre anúncios é controlado pelo feed. */
    margin-bottom: 0;

    color: #172033;

    cursor: pointer;

    transition:
        border-color 0.18s ease,
        box-shadow 0.18s ease,
        transform 0.18s ease;

}


.anuncio-composicao:hover {

    border-color: #ddd8f8;

    box-shadow:
        0 10px 28px rgba(23, 32, 51, 0.07);

}


.anuncio-composicao:focus-visible {

    outline: none;

    border-color: #6d4aff;

    box-shadow:
        0 0 0 3px rgba(109, 74, 255, 0.16);

}


/* =========================================================
   INDICADOR DE COMPOSIÇÃO
   ========================================================= */

.anuncio-composicao__indicador {

    position: absolute;

    top: 16px;

    right: 18px;

    width: 34px;

    height: 34px;

    display: flex;

    align-items: center;

    justify-content: center;

    box-sizing: border-box;

    border-radius: 10px;

    background: #f0f3ff;

    border: 1px solid #dfe5ff;

    color: #4f6bff;

    pointer-events: none;

}


.anuncio-composicao__indicador-icone {

    width: 17px;

    height: 17px;

    display: block;

}


/* =========================================================
   CABEÇALHO
   ========================================================= */

.anuncio-composicao__cabecalho {

    width: 100%;

    padding: 18px 68px 0 20px;

    box-sizing: border-box;

}


/* =========================================================
   IDENTIDADE DO COMPOSITOR
   ========================================================= */

.anuncio-composicao__identidade {

    display: flex;

    align-items: center;

    gap: 12px;

    min-width: 0;

    width: fit-content;

    max-width: 100%;

    color: inherit;

    text-decoration: none;

    border-radius: 12px;

    padding: 4px 6px 4px 4px;

    margin: -4px 0 -4px -4px;

    cursor: pointer;

    transition:
        background-color 0.16s ease;

}


.anuncio-composicao__identidade:hover {

    background: #f7f5ff;

}


.anuncio-composicao__identidade:focus-visible {

    outline: none;

    background: #f5f3ff;

    box-shadow:
        0 0 0 2px rgba(109, 74, 255, 0.22);

}


.anuncio-composicao__avatar {

    width: 44px;

    height: 44px;

    min-width: 44px;

    border-radius: 50%;

    object-fit: cover;

    display: flex;

    align-items: center;

    justify-content: center;

    background: #f0edff;

    color: #6d4aff;

    font-family: "Sora", sans-serif;

    font-size: 18px;

    font-weight: 600;

}


.anuncio-composicao__avatar--sem-foto {

    border: 1px solid #e5e0ff;

}


.anuncio-composicao__identidade-info {

    display: flex;

    flex-direction: column;

    gap: 2px;

    min-width: 0;

}


.anuncio-composicao__nome {

    font-family: "Manrope", sans-serif;

    font-size: 14px;

    line-height: 20px;

    font-weight: 700;

    color: #172033;

    white-space: nowrap;

    overflow: hidden;

    text-overflow: ellipsis;

}


.anuncio-composicao__tipo {

    font-family: "Manrope", sans-serif;

    font-size: 12px;

    line-height: 18px;

    font-weight: 500;

    color: #7b8496;

}


/* =========================================================
   CONTEÚDO
   ========================================================= */

.anuncio-composicao__conteudo {

    padding: 18px 20px 20px;

    box-sizing: border-box;

}


/* =========================================================
   RÓTULO
   ========================================================= */

.anuncio-composicao__rotulo {

    display: inline-flex;

    align-items: center;

    margin-bottom: 7px;

    font-family: "Manrope", sans-serif;

    font-size: 11px;

    line-height: 16px;

    font-weight: 700;

    letter-spacing: 0.04em;

    text-transform: uppercase;

    color: #6d4aff;

}


/* =========================================================
   TÍTULO
   ========================================================= */

.anuncio-composicao__titulo {

    margin: 0;

    font-family: "Sora", sans-serif;

    font-size: 23px;

    line-height: 30px;

    font-weight: 700;

    color: #172033;

    word-break: break-word;

}


/* =========================================================
   TAGS
   ========================================================= */

.anuncio-composicao__tags {

    display: flex;

    flex-wrap: wrap;

    align-items: center;

    gap: 7px;

    margin-top: 12px;

}


.anuncio-composicao__tag {

    display: inline-flex;

    align-items: center;

    min-height: 28px;

    padding: 5px 10px;

    box-sizing: border-box;

    border-radius: 999px;

    background: #f5f3ff;

    border: 1px solid #e8e3ff;

    color: #5d43d8;

    font-family: "Manrope", sans-serif;

    font-size: 11px;

    line-height: 16px;

    font-weight: 700;

}


/* =========================================================
   ÁREA COMERCIAL
   ========================================================= */

.anuncio-composicao__comercial {

    display: flex;

    flex-wrap: wrap;

    align-items: center;

    gap: 8px;

    margin-top: 14px;

}


.anuncio-composicao__valor {

    font-family: "Manrope", sans-serif;

    font-size: 14px;

    line-height: 20px;

    font-weight: 800;

    color: #172033;

}


.anuncio-composicao__negociavel {

    display: inline-flex;

    align-items: center;

    min-height: 25px;

    padding: 4px 9px;

    box-sizing: border-box;

    border-radius: 999px;

    background: #eef8f2;

    color: #28764b;

    font-family: "Manrope", sans-serif;

    font-size: 11px;

    line-height: 16px;

    font-weight: 700;

}


/* =========================================================
   PLAYER DE ÁUDIO
   ========================================================= */

.anuncio-composicao__audio {

    width: 100%;

    margin-top: 18px;

    cursor: default;

}


.anuncio-composicao__player {

    display: block;

    width: 100%;

    height: 46px;

    margin: 0;

}


.anuncio-composicao__audio-sem-arquivo {

    width: 100%;

    min-height: 52px;

    display: flex;

    align-items: center;

    padding: 12px 14px;

    box-sizing: border-box;

    margin-top: 18px;

    border-radius: 14px;

    background: #f7f8fb;

    border: 1px solid #eceef3;

    color: #7b8496;

    font-family: "Manrope", sans-serif;

    font-size: 12px;

    line-height: 18px;

    cursor: default;

}


/* =========================================================
   DESCRIÇÃO
   ========================================================= */

.anuncio-composicao__descricao {

    margin-top: 16px;

    font-family: "Manrope", sans-serif;

    font-size: 13px;

    line-height: 21px;

    font-weight: 500;

    color: #596274;

    white-space: pre-line;

    word-break: break-word;

    cursor: pointer;

    overflow: hidden;

    display: -webkit-box;

    -webkit-box-orient: vertical;

    -webkit-line-clamp: 2;

    line-clamp: 2;

    max-height: 42px;

    transition:
        color 0.16s ease;

}


.anuncio-composicao__descricao:hover {

    color: #424b5c;

}


.anuncio-composicao__descricao:focus-visible {

    outline: none;

    border-radius: 6px;

    box-shadow:
        0 0 0 2px rgba(109, 74, 255, 0.18);

}


.anuncio-composicao__descricao--expandida {

    display: block;

    -webkit-line-clamp: unset;

    line-clamp: unset;

    max-height: none;

}


/* =========================================================
   AÇÕES

   O botão "Ver composição" foi removido porque agora
   o card inteiro abre a composição.
   ========================================================= */

.anuncio-composicao__acoes {

    display: none;

}


.anuncio-composicao__botao {

    display: none;

}


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 768px) {

    .anuncio-composicao {

        border-radius: 20px;

        /* Espaçamento controlado pelo feed. */
        margin-bottom: 0;

    }


    .anuncio-composicao__indicador {

        top: 14px;

        right: 15px;

        width: 32px;

        height: 32px;

        border-radius: 9px;

    }


    .anuncio-composicao__indicador-icone {

        width: 16px;

        height: 16px;

    }


    .anuncio-composicao__cabecalho {

        padding: 16px 58px 0 16px;

    }


    .anuncio-composicao__conteudo {

        padding: 16px;

    }


    .anuncio-composicao__titulo {

        font-size: 21px;

        line-height: 28px;

    }


    .anuncio-composicao__tags {

        gap: 6px;

        margin-top: 10px;

    }


    .anuncio-composicao__tag {

        min-height: 27px;

        padding: 5px 9px;

        font-size: 10px;

        line-height: 15px;

    }


    .anuncio-composicao__comercial {

        margin-top: 12px;

    }


    .anuncio-composicao__audio {

        margin-top: 15px;

    }


    .anuncio-composicao__player {

        height: 44px;

    }


    .anuncio-composicao__descricao {

        margin-top: 14px;

        font-size: 12px;

        line-height: 19px;

        max-height: 38px;

    }

}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 480px) {

    .anuncio-composicao {

        border-radius: 18px;

        /* Espaçamento controlado pelo feed. */
        margin-bottom: 0;

    }


    .anuncio-composicao__indicador {

        top: 12px;

        right: 13px;

        width: 30px;

        height: 30px;

        border-radius: 9px;

    }


    .anuncio-composicao__indicador-icone {

        width: 15px;

        height: 15px;

    }


    .anuncio-composicao__cabecalho {

        padding: 13px 53px 0 14px;

    }


    .anuncio-composicao__conteudo {

        padding: 13px 14px 15px;

    }


    .anuncio-composicao__identidade {

        gap: 10px;

    }


    .anuncio-composicao__avatar {

        width: 38px;

        height: 38px;

        min-width: 38px;

        font-size: 16px;

    }


    .anuncio-composicao__nome {

        font-size: 13px;

        line-height: 18px;

    }


    .anuncio-composicao__tipo {

        font-size: 11px;

        line-height: 16px;

    }


    .anuncio-composicao__rotulo {

        margin-bottom: 5px;

        font-size: 10px;

        line-height: 15px;

    }


    .anuncio-composicao__titulo {

        font-size: 18px;

        line-height: 24px;

    }


    .anuncio-composicao__tags {

        gap: 5px;

        margin-top: 9px;

    }


    .anuncio-composicao__tag {

        min-height: 24px;

        padding: 4px 8px;

        font-size: 10px;

        line-height: 14px;

    }


    .anuncio-composicao__comercial {

        margin-top: 10px;

        gap: 7px;

    }


    .anuncio-composicao__valor {

        font-size: 13px;

        line-height: 19px;

    }


    .anuncio-composicao__negociavel {

        min-height: 23px;

        padding: 3px 8px;

        font-size: 10px;

        line-height: 15px;

    }


    .anuncio-composicao__audio {

        margin-top: 13px;

    }


    .anuncio-composicao__player {

        height: 42px;

    }


    .anuncio-composicao__audio-sem-arquivo {

        min-height: 46px;

        padding: 10px 12px;

        margin-top: 13px;

        border-radius: 12px;

        font-size: 11px;

        line-height: 17px;

    }


    .anuncio-composicao__descricao {

        margin-top: 12px;

        font-size: 12px;

        line-height: 18px;

        max-height: 36px;

    }

}

