/* mylist-screen.css */

.mylist-root {
    display: none;
    flex-direction: column;
    position: absolute;
    inset: 0;
    width: 100dvw;
    height: 100dvh;
    padding: 48px 3.5% 48px 3.5%;
    box-sizing: border-box;
    background: #0b0b0f;
    z-index: 6;
    color: #fff;
}

.mylist-header {
    margin-bottom: 32px;
}

.mylist-title {
    font-size: 32px;
    font-weight: 700;
    margin: 0;
    display: none;
}


.mylist-grid {
    display: grid;
    position: relative;
    grid-template-columns: repeat(auto-fill, minmax(10vw, 100px));
    gap: 16px;
    align-items: center;
    justify-content: flex-start;
    box-sizing: border-box;
    scroll-behavior: smooth;
    padding-bottom: 44px;
}


.mylist-root #nav-home {
    display: none;
}

.mylist-grid .card {
    position: relative !important;
    width: 100%;
    scroll-margin: 100px;
    height: auto;
    display: flex;
    margin: 0;
    /*     flex: 0 0 180px; */
    aspect-ratio: 2 / 3;
    border-radius: 8px;
    background-size: cover;
    background-position: center;
    background-color: #1a1a22;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}


.mylist-grid .card .cov {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, transparent 50%);
}

.mylist-grid .card .card-title {
    position: absolute;
    left: 10px;
    right: 10px;
    bottom: 10px;
    font-size: clamp(0.7em, 1.2vw, 0.9em);
    font-weight: 600;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.mylist-grid .card .card-rating {
    position: absolute;
    top: 8px;
    right: 8px;
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(0, 0, 0, 0.6);
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

.mylist-grid .card .star {
    color: #f5c518;
}

/* ── Botão de remover (opcional, aparece no hover/focus) ── */
.mylist-grid .card .card-remove-btn {
    position: absolute;
    top: 8px;
    left: 8px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.mylist-grid .card.focused .card-remove-btn {
    opacity: 1;
}

/* ── Estados de loading/vazio ── */
.mylist-loading,
.mylist-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    gap: 12px;
    color: #9a9aa5;
    text-align: center;
}

.mylist-root .mylist-empty {
    height: auto;
    width: auto;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.mylist-empty-sub {
    font-size: 14px;
    color: #6b6b76;
}

.mylist-loading .spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #2a2a33;
    border-top-color: #fff;
    border-radius: 50%;
    animation: mylist-spin 0.8s linear infinite;
}

@keyframes mylist-spin {
    to {
        transform: rotate(360deg);
    }
}