.profile-main-wrapper {
    max-width: 1100px; /* Defina a largura máxima que você quer */
    width: 100%; /* Para telas menores */
    margin: 0 auto; /* Isso centraliza a div na tela */
    padding: 0 10px; /* Um pequeno respiro nas laterais em mobile */
    /* --- CORREÇÃO DE ESTABILIDADE MOBILE --- */
    max-width: 100vw; /* Garante que nunca exceda a janela */
    overflow-x: hidden; /* Corta qualquer pixel que vaze lateralmente */
    box-sizing: border-box;
}

.create-post-input-profile {
    width: 100%;
    border: 1px solid #3e4042;
    background-color: #18191a;
    border-radius: 8px;
    padding: 10px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    display: flex;
    gap: 15px;
    align-items: center;
}

/* Opcional: Ajuste para telas muito grandes se quiser */
@media (min-width: 1600px) {
    .profile-main-wrapper {
        max-width: 1300px;
    }
}

/* Reset básico para links */
a {
    color: inherit;
    text-decoration: none;
}

    a:hover {
        color: #ffffff; /* text-white */
    }

/* ==================================================================
   2. SEU CSS ORIGINAL (LAYOUT, SIDEBAR, GRIDS)
   ================================================================== */
.profile-main-actions .status-add {
    background-color: #2d88ff; /* primary-color */
    color: white;
}

.profile-main-actions .status-friend {
    background-color: #28a745;
    color: white;
}

.profile-main-actions .status-pending-sent {
    background-color: #ffc107;
    color: #333;
}

.profile-main-actions .status-pending-received {
    background-color: #17a2b8;
    color: white;
}

.profile-main-actions .action-friend-status:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.favorite-game-item {
    padding-bottom: 100%;
    background-size: cover;
    background-position: center;
    border-radius: 8px;
    position: relative;
    display: flex;
    align-items: flex-end;
}

.file-input-hidden-accessible {
    opacity: 0;
    width: 1px;
    height: 1px;
    position: absolute;
    z-index: -1;
    overflow: hidden;
}

.add-game-form-container input[type="text"] {
    width: 100%;
    padding: 10px;
    margin-bottom: 8px;
    border-radius: 6px;
    border: 1px solid #3e4042; /* border-color */
    background-color: #18191a; /* bg-primary */
    color: #ffffff; /* text-primary */
    box-sizing: border-box;
}

.add-game-file-label {
    display: block;
    width: 100%;
    background-color: #3a3b3c; /* bg-hover */
    color: #ffffff; /* text-primary */
    padding: 10px;
    text-align: center;
    border-radius: 6px;
    cursor: pointer;
    margin-bottom: 5px;
    border: 1px dashed #3e4042; /* border-color */
    transition: 0.2s;
    box-sizing: border-box;
    font-size: 0.9rem;
}

    .add-game-file-label:hover {
        background-color: #3e4042; /* border-color (slightly lighter than hover) */
    }

.comment-action-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.85em;
    padding: 2px 6px;
    opacity: 0.5;
    transition: all 0.2s ease;
    color: #b0b3b8; /* text-gray */
}

    .comment-action-btn:hover {
        opacity: 1;
    }

/* Estilo específico para o botão de excluir (Lixeira) */
.delete-comment-btn {
    color: #ffffff;
    padding-left: 5px;
}

    .delete-comment-btn:hover {
        color: #e53e3e; /* danger color */
    }

/* Overlay do Nome do Jogo */
.game-name-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
    color: #fff;
    padding: 25px 8px 8px;
    font-size: 0.8rem;
    font-weight: bold;
    text-shadow: 0 1px 2px black;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    pointer-events: none;
}

/* --- ESTILOS DE COMENTÁRIOS (Igual ao Feed) --- */
.comment-section {
    padding: 0px 15px;
    background-color: #242526; /* bg-secondary */
    border-top: 1px solid #3e4042; /* border-color */
}

.comment-item {
    display: flex;
    gap: 10px;
    margin-bottom: 12px;
    margin-top: 12px;
    animation: fadeIn 0.3s ease;
}

.comment-content-wrapper {
    flex: 1;
}

.comment-bubble {
    background-color: #18191a; /* bg-primary (para contraste no card) */
    padding: 10px 12px;
    border-radius: 12px;
    display: inline-block;
    min-width: 100px;
    position: relative;
    border: 1px solid #3e4042; /* border-color */
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
    font-size: 0.9em;
}

.comment-text {
    color: #ffffff; /* text-primary */
    line-height: 1.4;
    font-size: 0.95em;
    word-wrap: break-word;
}

.comment-actions-bar {
    display: flex;
    gap: 15px;
    font-size: 0.8em;
    margin-top: 4px;
    margin-left: 5px;
    color: #b0b3b8; /* text-secondary */
}

.c-action {
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    font-weight: 600;
    padding: 0;
}

    .c-action:hover {
        text-decoration: none;
        color: #ffffff;
    }

    .c-action.active {
        color: white;
    }

.comment-media img {
    max-width: 200px;
    border-radius: 8px;
    display: block;
    margin-top: 8px;
}

/* Recuo para respostas */
.comment-item.is-reply, .reply-wrapper .comment-item {
    margin-left: 40px;
}

.reply-form-container {
    margin-left: 40px;
    margin-top: 10px;
}

.comment-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
}

.gif-comment-btn {
    background: none;
    border: none;
    color: #ffffff;
    cursor: pointer;
    padding: 0 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

    .gif-comment-btn:hover {
        transform: scale(1.1);
        color: #2d88ff; /* accent */
    }

.widget-friend-item {
    position: relative;
    text-align: center;
    overflow: hidden;
    padding: 0;
    margin: 0;
}

    .widget-friend-item a {
        display: block;
        text-decoration: none;
        color: #ffffff; /* text-primary */
    }

.friend-avatar-wrapper {
    position: relative;
    padding-bottom: 100%;
    width: 100%;
}

    .friend-avatar-wrapper img {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: 8px;
    }

.friend-name-overlay {
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
    color: white;
    padding: 5px;
    font-size: 0.7rem;
    text-align: right;
    border-radius: 0 0 8px 8px;
    line-height: 1;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.profile-body {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

    .profile-body > .profile-sub-view {
        width: 100%;
    }

.profile-layout-container {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    width: 100%;
}

.left-column-wrapper {
    display: flex;
    flex-direction: column;
    flex-basis: 38%;
    flex-shrink: 0;
    align-self: stretch;
}

.sidebar-filler {
    flex-grow: 1;
    background-color: #242526; /* bg-secondary */
    border-radius: 12px;
    margin-top: 20px;
    margin-bottom: 17px;
}

.profile-feed-column {
    flex-basis: 62%;
    flex-shrink: 1; /* Permite encolher para caber na tela */
    flex-grow: 1; /* Ocupa o espaço disponível */
    min-width: 0; /* OBRIGATÓRIO: Permite que vídeos/imagens grandes encolham */
    max-width: 100%; /* Garante que não estoure o pai */
    margin-top: -18px;
    padding: 18px;
    box-sizing: border-box;
}

.full-width-posts-container {
    width: 100%;
    max-width: 900px;
    margin: auto;
}

    .full-width-posts-container .post-card {
        margin: 0 auto 20px auto;
        max-width: 100%;
    }

.widget-photo-item {
    position: relative;
}

.photo-actions-overlay {
    position: absolute;
    top: 5px;
    right: 5px;
    display: none;
    gap: 5px;
}

.post-body video,
.post-body img,
.post-image {
    max-width: 100% !important;
    height: auto !important;
    display: block;
    object-fit: cover; /* Ou contain, dependendo da preferência */
}

/* Garante que o card do post nunca seja maior que a coluna */
.post-card {
    max-width: 100%;
    overflow: hidden; /* Corta qualquer coisa que tente sair */
    box-sizing: border-box;
}

.widget-photo-item:hover .photo-actions-overlay,
.favorite-game-item:hover .photo-actions-overlay {
    display: flex;
}

.photo-action-btn {
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
}

    .photo-action-btn:hover {
        background-color: rgba(0, 0, 0, 0.8);
    }


.btn {
    background: #3a3b3c; 
    border: 1px solid #3e4042; 
    padding: 8px 12px;
    border-radius: 10px;
    cursor: pointer;
    color: #ffffff;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: background 0.2s;
}

    .btn:hover {
        background: #4e4f50;
    }

    .btn.ghost {
        background: transparent;
        border: 1px solid #3e4042;
    }


.full-width {
    width: 100%;
    margin-top: 10px;
    justify-content: center;
}

/* Modais Base */
.modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.8);
    display: none;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(2px);
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.modal-content {
    background-color: #242526;
    margin: auto;
    border: 1px solid #3e4042;
    border-radius: 16px;
    width: 90%;
    max-width: 500px;
    animation: slideIn 0.3s ease;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

@keyframes slideIn {
    from {
        transform: translateY(20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #3e4042;
    padding-bottom: 15px;
    margin-bottom: 15px;
}

    .modal-header h3 {
        margin: 0;
        color: #ffffff;
        font-size: 1.2rem;
    }

.close-modal-btn {
    color: #b0b3b8; /* muted */
    font-size: 28px;
    line-height: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.2s;
}

    .close-modal-btn:hover {
        color: white;
    }

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

/* Modal de Compartilhamento */
.share-modal-content {
    max-width: 450px;
}

.preview-box {
    background: rgba(255,255,255,0.03);
    padding: 12px;
    margin: 15px 0;
    border-radius: 8px;
    font-size: 0.9rem;
    color: #b0b3b8; /* muted */
    pointer-events: none;
    max-height: 150px;
    overflow: hidden;
    border: 1px solid #3e4042;
    display: flex;
    gap: 10px;
}

    .preview-box img {
        width: 60px;
        height: 60px;
        object-fit: cover;
        border-radius: 4px;
    }

.divider-share {
    font-size: 0.85rem;
    margin: 20px 0;
    color: #b0b3b8; /* text-secondary */
    display: flex;
    align-items: center;
    gap: 10px;
}

    .divider-share::before, .divider-share::after {
        content: '';
        flex: 1;
        height: 1px;
        background: #3e4042;
    }

.social-share-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 10px;
}

.social-icon-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    color: white;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.2s;
    text-decoration: none !important;
}

    .social-icon-btn:hover {
        transform: translateY(-3px) scale(1.1);
        opacity: 1;
        color: white;
    }

/* Cores das Redes Sociais */
.btn-whatsapp {
    background: linear-gradient(45deg, #25D366, #128C7E);
}

.btn-facebook {
    background: #1877F2;
}

.btn-twitter {
    background: #000000;
    border: 1px solid #333;
}

.btn-linkedin {
    background: #0077b5;
}

.btn-telegram {
    background: #0088cc;
}

.btn-pinterest {
    background: #bd081c;
}

.btn-reddit {
    background: #ff4500;
}

.btn-copy {
    background: #18191a; /* bg */
    border: 1px solid #3e4042;
    color: #b0b3b8;
}

/* Textarea dos Modais */
#editPostForm textarea, #sharePostForm textarea {
    width: 100%;
    min-height: 100px;
    background-color: #18191a; /* bg */
    border: 1px solid #3e4042; /* border-color */
    color: white;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 10px;
    resize: vertical;
    font-family: inherit;
    box-sizing: border-box;
}

/* Story Viewer (Lightbox) */
#story-viewer-modal {
    background-color: black;
    z-index: 9999;
}

.story-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 10000;
    background: none;
    border: none;
    color: white;
    font-size: 40px;
    cursor: pointer;
    padding: 10px;
    opacity: 0.8;
}

    .story-close-btn:hover {
        opacity: 1;
        transform: scale(1.1);
    }

.story-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10000;
    background: rgba(255,255,255,0.1);
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 15px;
    border-radius: 50%;
    transition: 0.2s;
}

    .story-nav-btn:hover {
        background: rgba(255,255,255,0.2);
    }

#story-nav-prev {
    left: 15px;
}

#story-nav-next {
    right: 15px;
}

.story-delete-btn {
    display: none;
    position: absolute;
    bottom: 20px;
    right: 20px;
    z-index: 10000;
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    padding: 10px;
    opacity: 0.7;
}

    .story-delete-btn:hover {
        opacity: 1;
        color: #e53e3e; /* danger */
    }

.story-content-wrapper {
    width: 100%;
    max-width: 450px;
    height: 100vh;
    max-height: 800px;
    background: #000;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

#story-progress-bars {
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    display: flex;
    gap: 4px;
    z-index: 1010;
}

.progress-bar-container {
    flex: 1;
    height: 3px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    overflow: hidden;
}

.progress-bar-inner div {
    height: 100%;
    width: 0%;
    background: white;
}

.story-header-info {
    position: absolute;
    top: 25px;
    left: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1010;
    color: white;
    text-shadow: 0 1px 3px rgba(0,0,0,0.8);
    pointer-events: none;
}

#story-viewer-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.5);
}

#story-viewer-name {
    font-weight: 600;
    font-size: 0.95rem;
}

#story-viewer-image, #story-viewer-video {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

#story-viewer-text {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    text-align: center;
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
    background: linear-gradient(45deg, #FF512F, #DD2476);
}


/* ==================================================================
   4. MEDIA QUERIES ORIGINAIS (LAYOUT RESPONSIVO)
   ================================================================== */
@media (max-width: 992px) {
    .profile-layout-container {
        display: flex;
        flex-direction: column;
        width: 100%;
        max-width: 100%;
        gap: 15px;
    }


    .profile-header {
        margin-bottom: 21px;
    }

    .left-column-wrapper, .profile-feed-column {
        display: block;
        flex-basis: 100%;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        margin: 0;
        padding: 0;
        box-sizing: border-box;
    }

    .profile-feed-column {
        margin-top: 0 !important;
        padding-top: 10px !important;
    }

    .sidebar-filler {
        display: none;
    }

    .profile-details-bar {
        flex-direction: column;
        align-items: center;
        padding-bottom: 20px;
        text-align: center;
    }

    .profile-picture-container {
        transform: translateY(-50px);
        margin-bottom: -40px;
    }

    .profile-name-actions {
        display: flex;
        flex-direction: row;
        justify-content: center;
        align-items: center;
        gap: 15px;
        width: 100%;
        padding: 10px 15px;
        box-sizing: border-box;
        text-align: center;
        flex-wrap: wrap;
    }

    .profile-cover-photo {
        width: 100%;
        height: 176px;
        max-width: 100vw;
        overflow: hidden;
    }

    .profile-main-actions {
        justify-content: center;
        margin-top: 0;
        flex-shrink: 0;
    }

    .profile-nav {
        display: flex; /* Ativa o modelo Flexbox */
        justify-content: center; /* Centraliza horizontalmente */
        flex-wrap: wrap; /* Permite que os botões quebrem linha se faltar espaço */
        width: 100%;
    }




        /* 1. REGRAS PARA ABA AMIGOS (#profile-friends) 
       Esconde a sidebar (Apresentação, Fotos pequenas) e mostra só a lista principal 
    */
        #profile-friends .left-column-wrapper,
        #profile-friends .profile-sidebar {
            display: none !important; /* Força o ocultamento */
        }

        #profile-friends .profile-feed-column {
            width: 100% !important; /* Estica a lista de amigos para tela toda */
            flex: 0 0 100% !important;
            max-width: 100% !important;
        }

        /* 2. REGRAS PARA ABA GALERIA (#profile-photos)
       Esconde a sidebar e mostra o grid de fotos grande 
    */
        #profile-photos .left-column-wrapper,
        #profile-photos .profile-sidebar {
            display: none !important;
        }

        #profile-photos .profile-feed-column {
            width: 100% !important;
            flex: 0 0 100% !important;
            max-width: 100% !important;
        }
    
}

/* =========================================================
   CORREÇÃO DO NOME DO ARQUIVO NO PERFIL (MOBILE)
   Igual ao Feed: joga o nome para a linha de baixo
   ========================================================= */

@media (max-width: 968px) {

    /* 1. Oculta se estiver vazio para não atrapalhar o layout */
    #profile-file-name-display:empty {
        display: none;
    }

    /* 2. Define o footer como relativo para que o texto possa se posicionar dentro dele */
    #createPostFormProfile .create-post-footer {
        position: relative;
        align-items: center;
        /* Padding padrão quando não tem arquivo */
        padding-bottom: 0;
        padding-top: 0;
        transition: padding-bottom 0.2s ease;
    }

        /* 3. MÁGICA: Se o span NÃO estiver vazio, adiciona padding extra embaixo do footer */
        #createPostFormProfile .create-post-footer:has(#profile-file-name-display:not(:empty)) {
            padding-bottom: 30px; /* Espaço reservado para o texto cair */
        }

        /* 4. Garante que os ícones e botão de publicar fiquem na mesma linha (não quebrem) */
        #createPostFormProfile .create-post-footer > div {
            flex-wrap: nowrap !important;
            gap: 5px !important;
        }

    /* 5. Posiciona o nome do arquivo na parte inferior (na área criada pelo padding-bottom) */
    #profile-file-name-display {
        position: absolute;
        bottom: 0; /* Ajuste a altura conforme necessário */
        left: 0;
        width: 100%;
        font-size: 0.85em;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        color: #b0b3b8; /* text-secondary */
        padding: 3px 12px; /* Alinhamento lateral */
        box-sizing: border-box;
        display: block;
        text-align: left;
    }
}

@media (max-width: 576px) {
    .profile-header h1 {
        font-size: 1.8rem;
    }

    .profile-action-btn {
        padding: 8px 12px;
        font-size: 0.9rem;
    }

    .profile-main-actions {
        flex-wrap: wrap;
        gap: 10px;
    }

    .create-post-footer {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .publish-button {
        width: 100%;
    }

    .post-stats {
        flex-wrap: wrap;
        gap: 5px 15px;
    }

    /* Ajuste do modal para telas pequenas */
    .modal-content {
        width: 95%;
        padding: 15px;
    }
}

.mobile-follower-badge {
    display: none;
    position: absolute;
    bottom: 10px;
    right: 15px;
    background: rgba(0, 0, 0, 0.5); /* Fundo escuro para contraste */
    color: #fff;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.85rem;
    align-items: center;
    gap: 6px;
    backdrop-filter: blur(4px);
    z-index: 5;
    border: 1px solid rgba(255,255,255,0.2);
}

/* Classe para controle do contador Desktop */
.desktop-follower-count {
    display: flex;
}

/* Regras para telas menores (Mobile) */
@media (max-width: 768px) {
    /* Mostra o badge dentro da capa */
    .mobile-follower-badge {
        display: flex;
    }
    /* Oculta o contador abaixo do nome */
    .desktop-follower-count {
        display: none !important;
    }
}

#profile-inventory .profile-layout-container {
    display: block !important;
    max-width: 1200px;
    margin: 0 auto;
}

.inv-dashboard {
    padding: 0 10px;
    border: none;
    background: transparent;
}

/* Barra de Filtros */
.inv-filter-bar {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
    border-bottom: 1px solid var(--border-color);
    justify-content: center;
}

.inv-filter-btn {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    cursor: pointer;
    white-space: nowrap;
    transition: 0.2s;
    display: flex;
    align-items: center;
    gap: 8px;
}

    .inv-filter-btn:hover {
        background: var(--bg-primary);
        color: var(--text-primary);
    }

    .inv-filter-btn.active {
        background: var(--accent);
        color: #fff;
        border-color: var(--accent);
        box-shadow: 0 0 10px rgba(var(--accent-rgb), 0.3);
    }

/* Seções */
.inv-section {
    display: none;
    animation: fadeIn 0.3s;
}

    .inv-section.active {
        display: grid;
    }

.game-card-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 10px;
}

/* --- ESTILO NOVO DO CARD (MINIMALISTA) --- */
.game-item-card {
    background: #151920;
    border: 1px solid #30363d;
    border-radius: 8px;
    padding: 0; /* Removemos o padding para a imagem colar na borda */
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: transform 0.2s, box-shadow 0.2s;
    aspect-ratio: 1/1; /* Card quadrado */
    overflow: hidden; /* Garante que a imagem não saia da borda redonda */
}

    .game-item-card:hover {
        transform: translateY(-3px);
        border-color: var(--accent);
        box-shadow: 0 4px 15px rgba(0,0,0,0.5);
        z-index: 2;
    }

/* Bordas de Raridade (Agora na borda toda ou bottom) */
.rarity-common {
    border-bottom: 3px solid #b0b3b8;
}

.rarity-rare {
    border-bottom: 3px solid #2ebdff;
}

.rarity-epic {
    border-bottom: 3px solid #d700ff;
}

/* Badge de Nível no Canto Superior Direito */
.item-lvl-badge {
    position: absolute;
    top: 4px;
    background: rgba(0,0,0,0.8);
    color: #fff;
    font-size: 0.65rem;
    padding: 2px 5px;
    border-radius: 4px;
    font-weight: 800;
    border: 1px solid rgba(255,255,255,0.2);
    z-index: 5; /* Garante que fique acima da imagem */
    pointer-events: none;
}

/* Imagem ocupando tudo */
.item-img-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .item-img-wrapper img {
        width: 100%;
        height: 100%;
        object-fit: contain; /* Ajusta sem cortar */
        padding: 8px; /* Pequena margem interna para a imagem não colar nas bordas */
        transition: transform 0.3s;
    }

.game-item-card:hover .item-img-wrapper img {
    transform: scale(1.1);
}

/* Carros (Ligeiramente retangular para caber melhor o carro de lado) */
.cars-grid {
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
}