/* style.css */
* { box-sizing: border-box; margin: 0; padding: 0; font-family: 'Segoe UI', Roboto, Helvetica, sans-serif; }
body { background-color: #0a0a0a; color: #f0f0f0; display: flex; justify-content: center; align-items: center; min-height: 100vh; padding: 20px 12px; overflow-x: hidden; }

/* TELA DE APRESENTAÇÃO E HOME UNIFICADAS */
#splash-screen {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    background-color: #0a0a0a;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.svg-container {
    width: 100vw;
    max-width: 100vw;
    height: auto;
    display: block;
}

.s-line {
    stroke-dasharray: 2500;
    stroke-dashoffset: 2500;
    animation: drawSLine 3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes drawSLine {
    0% { stroke-dashoffset: 2500; }
    100% { stroke-dashoffset: 0; }
}

.letter-onoro {
    stroke-dasharray: 800;
    stroke-dashoffset: 800;
    opacity: 0;
    animation: drawLetter 0.25s ease-out forwards;
}

.letter-o1 { animation-delay: 3.00s; }
.letter-n  { animation-delay: 3.10s; }
.letter-o2 { animation-delay: 3.20s; }
.letter-r  { animation-delay: 3.30s; }
.letter-o3 { animation-delay: 3.40s; }

@keyframes drawLetter {
    0% { stroke-dasharray: 800; opacity: 0; }
    15% { opacity: 1; }
    100% { stroke-dashoffset: 0; opacity: 1; }
}

.home-buttons-container {
    margin-top: 40px;
    width: 100%;
    max-width: 320px;
    opacity: 0;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    gap: 14px;
    animation: fadeInButtons 0.8s ease-out 3s forwards;
}

@keyframes fadeInButtons {
    to {
        opacity: 1;
        pointer-events: auto;
    }
}

button, .btn-jogar-principal, .btn-como-jogar-principal, .btn-mini-step, .btn-mini-play {
    border-radius: 8px !important;
}

.btn-jogar-principal {
    background-color: #ff0055 !important;
    color: #ffffff !important;
    border: none;
    padding: 16px 20px;
    font-size: 16px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s, background-color 0.2s;
    box-shadow: 0 4px 15px rgba(255, 0, 85, 0.4);
}
.btn-jogar-principal:hover {
    background-color: #ff2a70 !important;
    transform: scale(1.02);
}

.btn-como-jogar-principal {
    background-color: #0a0a0a !important;
    color: #ff0055 !important;
    border: 2px solid #ff0055 !important;
    padding: 14px 20px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s, background-color 0.2s;
}
.btn-como-jogar-principal:hover {
    background-color: #1a050d !important;
    transform: scale(1.02);
}

.container { 
    background: #141414; 
    padding: 30px 20px; 
    border-radius: 18px; 
    width: 100%; 
    max-width: 520px; 
    box-shadow: 0 10px 30px rgba(0,0,0,0.8); 
    border: 1px solid #222; 
    text-align: center; 
    overflow: hidden; 
}

.tela { display: none; }
.tela.ativa { display: block; animation: fadeIn 0.4s ease; }

@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.logo-header {
    width: calc(100% + 40px);
    max-width: none;
    margin-left: -20px;
    margin-right: -20px;
    height: auto;
    margin-bottom: 20px;
    display: block;
    object-fit: cover;
}

p { color: #888; margin-bottom: 20px; font-size: 14px; line-height: 1.5; }

button { background: #fff; color: #000; border: none; padding: 14px 20px; font-size: 15px; font-weight: 700; cursor: pointer; transition: all 0.2s; width: 100%; margin-bottom: 12px; }
button:hover:not(:disabled) { transform: scale(1.02); background: #e0e0e0; }
button:disabled { background: #333; color: #666; cursor: not-allowed; }

.btn-secundario { background: #222; color: #fff; border: 1px solid #333; }
.btn-secundario:hover:not(:disabled) { background: #333; }

.campo-config { text-align: left; margin-bottom: 15px; position: relative; }
.campo-config label { display: block; font-size: 13px; color: #aaa; margin-bottom: 6px; }
select, input[type="text"] { width: 100%; padding: 12px; border-radius: 8px; border: 1px solid #333; background: #0f0f0f; color: #fff; font-size: 15px; outline: none; transition: border 0.2s; }
select:focus, input[type="text"]:focus { border-color: #666; }

/* ETIQUETA NOVO! */
.etiqueta-novo-badge {
    position: absolute;
    top: -8px;
    right: 8px;
    background-color: #ff0055;
    color: #ffffff;
    font-size: 9px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
    z-index: 10;
    box-shadow: 0 2px 5px rgba(0,0,0,0.5);
    letter-spacing: 0.5px;
    pointer-events: none;
    text-transform: uppercase;
}

/* AUTOCOMPLETE */
.autocomplete-list {
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: #1c1c1c; border: 1px solid #333; border-top: none;
    border-radius: 0 0 8px 8px; max-height: 220px; overflow-y: auto;
    z-index: 100; box-shadow: 0 8px 16px rgba(0,0,0,0.5); display: none;
}

.autocomplete-item {
    display: flex; align-items: center; padding: 10px 12px;
    cursor: pointer; transition: background 0.2s; border-bottom: 1px solid #282828;
}
.autocomplete-item:hover { background: #2a2a2a; }
.autocomplete-item img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; margin-right: 12px; }
.autocomplete-item span { font-size: 14px; font-weight: 600; color: #fff; }

/* CARREGAMENTO ROSA PADRÃO #ff0055 */
.loading-container { width: 100%; background: #222; border-radius: 8px; height: 8px; margin: 10px 0 8px 0; overflow: hidden; }
.loading-bar { height: 100%; background: #ff0055; width: 0%; transition: width 0.1s linear; }

/* GRID E CARDS DE ÁLBUNS */
.grid-albuns { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 12px; max-height: 300px; overflow-y: auto; padding: 6px; }
.card-clicavel { position: relative; border-radius: 8px; overflow: hidden; cursor: pointer; aspect-ratio: 1 / 1; width: 100%; box-shadow: 0 0 0 2px #ff0055; transition: filter 0.2s, transform 0.12s, box-shadow 0.2s; display: flex; flex-direction: column; }
.card-clicavel:active { transform: scale(0.95); }
.card-clicavel.inativo { filter: grayscale(1) brightness(0.35); box-shadow: 0 0 0 2px #2a2a2a; }
.card-album img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card-album .nome-card { position: absolute; left: 0; right: 0; bottom: 0; background: linear-gradient(transparent, rgba(0,0,0,0.9)); color: #fff; font-size: 10px; font-weight: 700; line-height: 1.25; text-align: center; padding: 16px 5px 6px; }

.card-especial { background: #ff0055; display: flex; align-items: center; justify-content: center; }
.card-especial .nome-card-central { color: #fff; font-weight: 800; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; text-align: center; line-height: 1.4; }

.grid-artistas { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 12px; max-height: 320px; overflow-y: auto; padding: 4px; margin-bottom: 15px; }
.card-artista { background: #1a1a1a; border-radius: 8px; padding: 10px; cursor: pointer; border: 2px solid transparent; transition: all 0.2s; display: flex; flex-direction: column; align-items: center; position: relative; overflow: hidden; }
.card-artista:hover:not(.carregando) { border-color: #ff0055; transform: translateY(-2px); background: #222; }
.card-artista .thumb-wrapper { position: relative; width: 70px; height: 70px; margin-bottom: 8px; }
.card-artista img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; box-shadow: 0 4px 10px rgba(0,0,0,0.5); transition: filter 0.3s; }
.card-artista.carregando img { filter: brightness(0.3) grayscale(0.5); }
.card-artista .overlay-carregando { display: none; position: absolute; top: 0; left: 0; right: 0; bottom: 0; border-radius: 50%; background: rgba(0,0,0,0.6); align-items: center; justify-content: center; flex-direction: column; }
.card-artista.carregando .overlay-carregando { display: flex; }
.card-artista .badge-baixado { display: none; position: absolute; bottom: 2px; right: 2px; background: #1db954; color: #fff; width: 20px; height: 20px; border-radius: 50%; font-size: 12px; font-weight: bold; align-items: center; justify-content: center; border: 2px solid #141414; box-shadow: 0 2px 5px rgba(0,0,0,0.5); }
.card-artista.baixado .badge-baixado { display: flex; }
.card-artista .mini-barra-bg { width: 80%; height: 6px; background: #333; border-radius: 3px; overflow: hidden; }
.card-artista .mini-barra-fill { height: 100%; width: 0%; background: #ff0055; transition: width 0.1s linear; }
.card-artista .nome-artista { font-size: 12px; font-weight: 600; color: #fff; word-break: break-word; line-height: 1.2; }

/* CAIXAS DEITADAS PARA PLAYLISTS */
.grid-playlists-horizontal { display: flex; flex-direction: column; gap: 10px; max-height: 320px; overflow-y: auto; padding: 4px; margin-bottom: 15px; }
.card-playlist-horizontal { background: #1a1a1a; border-radius: 8px; padding: 8px 12px; cursor: pointer; border: 2px solid transparent; transition: all 0.2s; display: flex; align-items: center; gap: 12px; position: relative; overflow: hidden; }
.card-playlist-horizontal:hover:not(.carregando) { border-color: #ff0055; background: #222; }
.card-playlist-horizontal .thumb-wrapper-playlist { position: relative; width: 48px; height: 48px; flex-shrink: 0; }
.card-playlist-horizontal img { width: 100%; height: 100%; border-radius: 6px; object-fit: cover; box-shadow: 0 2px 8px rgba(0,0,0,0.5); transition: filter 0.3s; }
.card-playlist-horizontal.carregando img { filter: brightness(0.3) grayscale(0.5); }
.card-playlist-horizontal .overlay-carregando-playlist { display: none; position: absolute; top: 0; left: 0; right: 0; bottom: 0; border-radius: 6px; background: rgba(0,0,0,0.6); align-items: center; justify-content: center; flex-direction: column; }
.card-playlist-horizontal.carregando .overlay-carregando-playlist { display: flex; }
.card-playlist-horizontal .badge-baixado-playlist { display: none; position: absolute; bottom: -2px; right: -2px; background: #1db954; color: #fff; width: 16px; height: 16px; border-radius: 50%; font-size: 10px; font-weight: bold; align-items: center; justify-content: center; border: 2px solid #141414; }
.card-playlist-horizontal.baixado .badge-baixado-playlist { display: flex; }
.card-playlist-horizontal .mini-barra-bg { width: 80%; height: 5px; background: #333; border-radius: 3px; overflow: hidden; }
.card-playlist-horizontal .mini-barra-fill { height: 100%; width: 0%; background: #ff0055; transition: width 0.1s linear; }
.card-playlist-horizontal .nome-playlist { font-size: 13px; font-weight: 600; color: #fff; word-break: break-word; line-height: 1.3; flex: 1; text-align: left; }

.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.85); display: none; justify-content: center; align-items: center; z-index: 1000; padding: 20px; }
.modal-overlay.ativo { display: flex; }
.modal-content { background: #1c1c1c; border: 1px solid #333; padding: 24px; border-radius: 12px; width: 100%; max-width: 380px; text-align: center; }

.btn-modo-classico:disabled,
.btn-modo-vazado:disabled {
    background-color: #222 !important;
    color: #666 !important;
    border-color: #333 !important;
    cursor: not-allowed !important;
}

.btn-modo-classico {
    background-color: #ff0055 !important;
    color: #ffffff !important;
    border: none !important;
}
.btn-modo-classico:hover:not(:disabled) {
    background-color: #ff2a70 !important;
}

.btn-modo-vazado {
    background-color: #1c1c1c !important;
    color: #ff0055 !important;
    border: 2px solid #ff0055 !important;
}
.btn-modo-vazado:hover:not(:disabled) {
    background-color: #28101a !important;
}

.modo-opcao-container {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    position: relative;
}

.modo-opcao-container button {
    margin-bottom: 0 !important;
    flex: 1;
}

.btn-help-info {
    width: 44px !important;
    height: 44px !important;
    min-width: 44px;
    padding: 0 !important;
    margin-bottom: 0 !important;
    background: #282828 !important;
    color: #ff0055 !important;
    border: 1px solid #333 !important;
    border-radius: 8px !important;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

.tooltip-explicacao {
    display: none;
    position: absolute;
    bottom: 110%;
    left: 50%;
    transform: translateX(-50%);
    background: #000;
    color: #eee;
    border: 1px solid #ff0055;
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: normal;
    line-height: 1.4;
    width: 260px;
    z-index: 1050;
    box-shadow: 0 4px 15px rgba(0,0,0,0.8);
    text-align: left;
    pointer-events: none;
}

.btn-help-info:hover .tooltip-explicacao,
.btn-help-info.ativo .tooltip-explicacao {
    display: block;
}

.status-bar { display: flex; justify-content: space-between; font-size: 14px; font-weight: bold; margin-bottom: 15px; color: #aaa; }
.pontos-gradiente { color: #ff0055; font-size: 18px; font-weight: bold; }

.tempo-container { width: 100%; background: #222; border-radius: 8px; height: 8px; margin-bottom: 10px; overflow: hidden; }
.tempo-barra { height: 100%; background: #fff; width: 100%; transition: width 0.05s linear; }
.tempo-texto { font-family: monospace; font-size: 16px; margin-bottom: 20px; color: #ddd; }

.player-minimalista {
    background: #0d0d0d;
    border: 1px solid #282828;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 15px;
}

.visualizador-ondas {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    height: 48px;
    margin-bottom: 12px;
    width: 100%;
}

.barra-onda {
    width: 4px;
    height: 6px;
    background: #333;
    border-radius: 2px;
    transition: height 0.05s ease, background 0.2s;
}

.visualizador-ondas.ativo .barra-onda {
    background: #ff0055;
}

.linha-trecho-container {
    width: 100%;
    height: 4px;
    background: #222;
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 16px;
}

.linha-trecho-progresso {
    height: 100%;
    width: 0%;
    background: #ff0055;
    transition: width 0.05s linear;
}

.controles-minimalistas {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.btn-mini-step {
    width: 44px;
    height: 44px;
    background: #1a1a1a;
    border: 1px solid #333;
    color: #fff;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0; margin: 0;
}

.btn-mini-play {
    flex: 1;
    height: 44px;
    background: #fff;
    color: #000;
    font-size: 14px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 0; padding: 0 15px;
}

.grid-opcoes-musica {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.btn-opcao-marcar {
    background: #1a1a1a;
    color: #fff;
    border: 1px solid #333;
    padding: 12px 14px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    text-align: left;
    transition: background 0.2s, border-color 0.2s;
    word-break: break-word;
    margin-bottom: 0;
}

.btn-opcao-marcar:hover:not(:disabled) {
    background: #282828;
    border-color: #ff0055;
}

#resultado { margin-top: 15px; font-size: 15px; font-weight: 600; min-height: 24px; }
.nome-revelado { color: #fff; font-size: 16px; margin-top: 5px; font-weight: bold; display: block; }

.grid-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; text-align: left; margin-bottom: 15px; }
.card-stat { background: #1a1a1a; padding: 12px; border-radius: 8px; border: 1px solid #2a2a2a; }
.card-stat .label { font-size: 11px; color: #888; text-transform: uppercase; }
.card-stat .val { font-size: 14px; font-weight: bold; color: #fff; margin-top: 4px; word-break: break-word; }

.historico-container { text-align: left; background: #0f0f0f; border: 1px solid #2a2a2a; border-radius: 8px; max-height: 220px; overflow-y: auto; margin-bottom: 20px; padding: 8px; }
.item-historico { display: flex; align-items: center; gap: 12px; padding: 8px; border-bottom: 1px solid #1a1a1a; border-radius: 6px; cursor: pointer; transition: background 0.2s; }
.item-historico:hover { background: #1f1f1f; }
.item-historico img { width: 42px; height: 42px; border-radius: 6px; object-fit: cover; }
.item-historico .info-track { flex: 1; overflow: hidden; }
.item-historico .title { font-size: 13px; font-weight: bold; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-historico .status { font-size: 11px; margin-top: 2px; }
.status-acerto { color: #1db954; }
.status-erro { color: #ff4d4d; }

.btn-voltar-topo { width: auto; background: transparent; color: #888; border: 1px solid #333; padding: 6px 14px; font-size: 12px; margin-bottom: 15px; border-radius: 8px; }
.btn-voltar-topo:hover { background: #1a1a1a; color: #fff; transform: none; }

.add-deezer-box { display: flex; gap: 8px; margin-bottom: 12px; position: relative; }
.add-deezer-box input { flex: 1; }
.add-deezer-box button { width: auto; margin-bottom: 0; padding: 0 16px; font-size: 13px; }

.how-to-play-card {
    background: #0f0f0f;
    border: 1px solid #282828;
    border-radius: 12px;
    padding: 18px;
    text-align: left;
    margin-bottom: 20px;
}

.how-to-play-card h3 {
    color: #ff0055;
    margin-bottom: 12px;
    font-size: 18px;
}

.how-to-play-card ul {
    list-style: none;
    padding-left: 0;
}

.how-to-play-card li {
    font-size: 14px;
    color: #ccc;
    margin-bottom: 10px;
    line-height: 1.4;
}

@media (max-width: 480px) {
    .home-buttons-container {
        max-width: 240px !important;
        margin-top: 24px !important;
        gap: 10px !important;
    }

    .btn-jogar-principal {
        padding: 12px 16px !important;
        font-size: 14px !important;
        border-radius: 8px !important;
    }

    .btn-como-jogar-principal {
        padding: 10px 16px !important;
        font-size: 13px !important;
        border-radius: 8px !important;
    }

    .btn-mini-play {
        font-size: 11px !important;
        white-space: nowrap !important;
        padding: 0 6px !important;
        gap: 4px !important;
    }

    .btn-mini-step {
        width: 38px !important;
        height: 44px !important;
        flex-shrink: 0 !important;
    }

    .controles-minimalistas {
        gap: 6px !important;
    }

    .grid-albuns { grid-template-columns: repeat(3, 1fr); gap: 8px; }
    .visualizador-ondas { gap: 2px; }
    .barra-onda { width: 3px; }
}

@keyframes fadeIn {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

.trofeu-animado {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    animation: fadeIn 1s ease-in-out forwards;
}
/* Seletor de Idioma */
#seletor-idioma button {
    transition: all 0.2s ease;
    font-weight: 700;
}
#seletor-idioma button.idioma-ativo {
    background-color: #ff0055 !important;
    border-color: #ff0055 !important;
    color: #ffffff !important;
}
