:root {
    --brand: #8e0225;
    --brand-dark: #650017;
    --brand-soft: rgba(142, 2, 37, 0.08);
    --ink: #1b1c1c;
    --muted: #6b7785;
    --line: #e5e2e1;
    --card: #ffffff;
}

/** ---- Contador de comentarios ---- */
.comments-count {
    font-weight: 600;
    font-size: 1.05rem;
    color: var(--ink);
}

.comments-count i {
    color: var(--brand);
}

/** ---- Feed ---- */
.feed-card {
    background: var(--card);
    border-radius: 18px;
    box-shadow: 0 10px 30px rgba(20, 25, 40, .06);
    padding: 6px 0;
    margin-bottom: 18px;
    overflow: hidden;
}

.comment-item {
    display: flex;
    gap: 14px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--line);
    transition: background .15s ease;
}

.comment-item:last-child {
    border-bottom: none;
}

.comment-item:hover {
    background: #FAFBFC;
}

.avatar {
    flex: 0 0 auto;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    object-fit: cover;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 600;
    font-size: .95rem;
}

.comment-body {
    flex: 1 1 auto;
    min-width: 0;
}

.comment-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    column-gap: 6px;
    line-height: 1.3;
}

.comment-name {
    font-weight: 600;
    color: var(--ink);
    font-size: .95rem;
}

.comment-loc {
    color: var(--muted);
    font-size: .84rem;
}

.dot::before {
    content: "·";
    color: var(--muted);
    margin: 0 2px;
}

.comment-date {
    color: var(--muted);
    font-size: .84rem;
    margin-left: auto;
    white-space: nowrap;
    flex: 0 0 auto;
}

.comment-text {
    margin-top: 4px;
    font-size: .92rem;
    color: #2C3644;
    line-height: 1.5;
    word-wrap: break-word;
    text-align: justify;
}

.comment-photo {
    margin-top: 10px;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid var(--line);
    max-height: 280px;
    background-color: #171c23;
}

.comment-photo img {
    width: 100%;
    height: 100%;
    max-height: 280px;
    object-fit: contain;
    display: block;
}

.comment-photo-img {
    cursor: pointer;
    transition: opacity .15s ease;
}

.comment-photo-img:hover {
    opacity: .9;
}

#commentPhotoModal .modal-body img {
    max-height: 85vh;
    width: auto;
    max-width: 100%;
}

/** ---- Estados vacío / error ---- */
.cmt-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 3rem 1rem;
    text-align: center;
    color: var(--muted);
    background: var(--card);
    border-radius: 18px;
    box-shadow: 0 10px 30px rgba(20, 25, 40, .06);
}

.cmt-empty .material-symbols-outlined {
    font-size: 2.5rem;
    color: var(--brand);
}

.cmt-empty p {
    margin: 0;
    font-size: 0.9rem;
}

/** ---- Botón cargar más ---- */
.load-more-wrap {
    text-align: center;
    margin-top: 6px;
}

.load-more-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 1.75rem;
    border-radius: 9999px;
    border: 1.5px solid var(--brand);
    background: transparent;
    color: var(--brand);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.load-more-btn:hover {
    background: var(--brand);
    color: #fff;
}

.load-more-btn .fa-spinner {
    display: none;
}

/** ---- Skeleton (estado de carga) ---- */
.skeleton-item {
    display: flex;
    gap: 14px;
    padding: 18px 20px;
}

.sk {
    background: linear-gradient(90deg, #EEF0F2 25%, #F6F7F8 37%, #EEF0F2 63%);
    background-size: 400% 100%;
    animation: shimmer 1.4s ease infinite;
    border-radius: 8px;
}

@keyframes shimmer {
    0% { background-position: 100% 0; }
    100% { background-position: 0 0; }
}

.sk-avatar {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    flex: 0 0 auto;
}

.sk-line {
    height: 10px;
    margin-bottom: 8px;
}

.end-marker {
    text-align: center;
    color: var(--muted);
    font-size: .84rem;
    padding: 18px 0 4px;
}

/** ================================
    RESPONSIVE
    ================================ */
@media (max-width: 768px) {
    .feed-card {
        border-radius: 14px;
    }

    .comment-item {
        padding: 14px 16px;
        gap: 10px;
    }

    .avatar {
        width: 40px;
        height: 40px;
        font-size: .85rem;
    }

    .comment-name {
        font-size: .9rem;
    }

    .comment-text {
        font-size: .88rem;
    }

    .comment-photo,
    .comment-photo img {
        max-height: 220px;
    }
}

@media (max-width: 480px) {
    #content-comments {
        padding-left: 0;
        padding-right: 0;
    }

    .dot::before {
        content: none;
    }

    .feed-card {
        border-radius: 0;
        margin-bottom: 10px;
        box-shadow: none;
        border-top: 1px solid var(--line);
        border-bottom: 1px solid var(--line);
    }

    .comment-date {
        margin-left: 0;
    }

    .comment-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
    }

    .avatar {
        width: 36px;
        height: 36px;
        font-size: .8rem;
    }

    .comment-item {
        padding: 12px 14px;
        gap: 8px;
    }

    .comment-text {
        font-size: .86rem;
    }

    .comment-photo {
        max-height: 220px;
        margin-left: -14px;
        margin-right: -14px;
        border-left: none;
        border-right: none;
    }

    .comment-photo img {
        max-height: 220px;
    }

    .load-more-wrap {
        padding: 0 14px;
        margin-top: 1.5rem;
    }

    .load-more-btn {
        width: 100%;
        padding: 10px 0;
        font-size: 15px;
    }
}