/*
 * style_PostCard.css - Estilos exclusivos para o card de post do feed
 * GaragemGMC 2026
 */

/* ============================================
   CARD DO POST
   ============================================ */
.post-card {
    background: #121212;
    margin-bottom: 15px;
    border-top: 1px solid #222;
    border-bottom: 1px solid #222;
}

/* Header do Post */
.post-header {
    display: flex;
    align-items: center;
    padding: 12px;
}

.post-avatar-frame {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    padding: 2px;
    background: conic-gradient(#28a745, #161616);
    margin-right: 10px;
    flex-shrink: 0;
}

.post-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #000;
    display: block;
}

.post-header-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex: 1;
    min-width: 0;
}

.car-name-link {
    font-weight: bold;
    color: #fff;
    font-size: 0.95rem;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.car-badge {
    font-size: 0.65rem;
    color: #d35400;
    background: rgba(211, 84, 0, 0.1);
    padding: 2px 6px;
    border-radius: 12px;
}

.pilot-name-link {
    color: #aaa;
    font-size: 0.7rem;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
}

.pilot-name-link strong {
    color: #d35400;
}

.bl-rank {
    background: #dc3545;
    color: #fff;
    font-size: 0.6rem;
    padding: 2px 6px;
    border-radius: 12px;
}

.post-dot {
    color: #555;
    font-size: 0.6em;
}

/* Opções do post */
.post-options {
    position: relative;
}

.post-options-btn {
    background: none;
    border: none;
    color: #888;
    cursor: pointer;
    padding: 5px;
}

.post-options-menu {
    position: absolute;
    right: 0;
    top: 25px;
    background: #1a1a1a;
    border: 1px solid #333;
    border-radius: 8px;
    z-index: 100;
    min-width: 120px;
}

.post-options-menu button {
    display: block;
    width: 100%;
    padding: 10px;
    background: none;
    border: none;
    color: #fff;
    text-align: left;
    cursor: pointer;
}

.post-options-menu button:hover {
    background: #333;
}

.post-options-menu button.danger {
    color: #dc3545;
}

/* Ações do Post */
.post-actions-bar {
    display: flex;
    justify-content: space-between;
    padding: 10px 12px;
}

.actions-left {
    display: flex;
    gap: 15px;
}

.actions-right {
    display: flex;
    gap: 15px;
}

.action-btn {
    background: none;
    border: none;
    color: #fff;
    font-size: 1.1rem;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 5px;
}

.like-btn:hover {
    color: #e74c3c;
}

.like-btn.liked i {
    color: #e74c3c;
    font-weight: 900;
    animation: pulse 0.3s ease-in-out;
}

.comment-btn:hover {
    color: #3498db;
}

.share-btn {
    color: #aaa;
}

.share-btn:hover {
    color: #3498db;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

/* Legenda */
.post-caption {
    padding: 0 12px 12px 12px;
    font-size: 0.9em;
    color: #ccc;
    line-height: 1.4;
}

.caption-author {
    font-weight: bold;
    color: #fff;
    margin-right: 5px;
}

/* Área de Comentários */
.comments-preview-area {
    padding: 0 12px;
    margin-bottom: 15px;
}

.view-all-comments {
    display: block;
    color: #999;
    font-size: 0.75em;
    text-decoration: none;
    margin-top: 8px;
    transition: color 0.2s;
}

.view-all-comments:hover {
    color: #ccc;
}

.full-comments-area {
    display: none;
    padding: 15px 0;
    border-top: 1px solid #222;
    background: #111;
}

.comment-form-box {
    display: flex;
    gap: 10px;
    align-items: center;
    width: 100%;
    padding: 0 15px;
}

.comment-form-box input[type="text"] {
    flex: 1;
    padding: 10px;
    border-radius: 20px;
    border: 1px solid #333;
    background: #0d0d0d;
    color: #fff;
    font-size: 0.85rem;
}

.comment-form-box input[type="text"]:focus {
    outline: none;
    border-color: #d35400;
}

.btn-comment-action {
    background: none !important;
    border: none !important;
    cursor: pointer;
    padding: 0;
    transition: color 0.2s;
    font-size: 1.1em;
    color: #d35400;
}

.btn-comment-action:hover {
    color: #e67e22;
}

/* Lista de Comentários */
.comments-list {
    max-height: 250px;
    overflow-y: auto;
    margin-bottom: 15px;
    padding: 0 15px;
}

.comment-item {
    display: flex;
    gap: 10px;
    margin-bottom: 12px;
    align-items: flex-start;
}

.comment-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #333;
    flex-shrink: 0;
}

.comment-bubble {
    background: #1a1a1a;
    padding: 8px 12px;
    border-radius: 12px;
    border: 1px solid #2a2a2a;
    flex: 1;
    min-width: 0;
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 4px;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;
}

.comment-author {
    color: #d35400;
    font-weight: bold;
    font-size: 0.8rem;
}

.comment-text {
    color: #ccc;
    font-size: 0.85rem;
    line-height: 1.3;
    word-wrap: break-word;
}

.comment-time {
    color: #666;
    font-size: 0.65rem;
}

/* ============================================
   AJUSTES MOBILE - CARD DO POST
   ============================================ */

/* Garantir largura total do card */
.post-card {
    width: 100%;
    overflow: hidden;
}

/* Ajustes no header do post */
.post-header {
    padding: 12px;
    gap: 10px;
}

/* Avatar responsivo */
.post-avatar-frame {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
}

/* Nome do carro com ellipsis */
.car-name-link {
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
}

/* Ações do post */
.post-actions-bar {
    padding: 10px 12px;
}

.action-btn {
    font-size: 1rem;
    gap: 5px;
}

/* Legenda */
.post-caption {
    padding: 0 12px 12px 12px;
    font-size: 0.85rem;
    word-wrap: break-word;
}

/* Formulário de comentário */
.comment-form-box {
    padding: 10px 12px;
    gap: 8px;
}

.comment-form-box input[type="text"] {
    font-size: 0.85rem;
    padding: 8px 12px;
}

/* Mobile pequeno */
@media (max-width: 480px) {
    .post-header {
        padding: 10px;
    }
    
    .post-avatar-frame {
        width: 35px;
        height: 35px;
    }
    
    .car-name-link {
        font-size: 0.85rem;
    }
    
    .post-caption {
        font-size: 0.8rem;
    }
    
    .action-btn {
        font-size: 0.9rem;
    }
}