/* Compact cards for personal and attendance directories. */
#view-colaboradores .inventory-products-grid,
#view-asistencia .inventory-provider-grid {
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 360px), 360px));
    justify-content: start;
    align-items: start;
}

#view-colaboradores .collaborator-directory-card,
#view-asistencia .attendance-card,
#view-asistencia .attendance-card-sin-marcar {
    padding: 14px;
    gap: 10px;
    border-radius: 18px;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.055);
}

#view-colaboradores .collaborator-directory-card:hover,
#view-asistencia .attendance-card:hover,
#view-asistencia .attendance-card-sin-marcar:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.09);
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-head,
#view-asistencia .attendance-card .inventory-provider-shell-head,
#view-asistencia .attendance-card-sin-marcar .inventory-provider-shell-head {
    gap: 10px;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-media,
#view-asistencia .attendance-card .attendance-welcome-media,
#view-asistencia .attendance-card-sin-marcar .attendance-welcome-media {
    width: 56px;
    height: 56px;
    min-width: 56px;
    border-radius: 16px;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-copy,
#view-asistencia .attendance-welcome-head > div:last-child {
    min-width: 0;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-copy strong,
#view-asistencia .attendance-welcome-head strong {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-height: 1.2;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-meta,
#view-asistencia .attendance-card .inventory-provider-shell-meta,
#view-asistencia .attendance-card-sin-marcar .inventory-provider-shell-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-meta span,
#view-asistencia .attendance-card .inventory-provider-shell-meta span,
#view-asistencia .attendance-card-sin-marcar .inventory-provider-shell-meta span {
    min-width: 0;
    display: grid;
    justify-content: initial;
    gap: 3px;
    padding: 7px 9px;
    border-radius: 10px;
    font-size: 0.74rem;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-meta strong,
#view-asistencia .attendance-card .inventory-provider-shell-meta strong,
#view-asistencia .attendance-card-sin-marcar .inventory-provider-shell-meta strong {
    min-width: 0;
    overflow-wrap: anywhere;
    text-align: left;
    font-size: 0.78rem;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-summary {
    gap: 6px;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-summary > div {
    padding: 9px 10px;
    border-radius: 11px;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-actions,
#view-asistencia .attendance-card .inventory-provider-shell-footer {
    gap: 6px;
}

#view-colaboradores .collaborator-directory-card .inventory-product-shell-actions .btn.small,
#view-asistencia .attendance-card .inventory-provider-shell-footer .btn.small {
    padding: 7px 10px;
    border-radius: 9px;
    font-size: 0.76rem;
}

/* Destructive action stays visible without the large red glow. */
#view-colaboradores .collaborator-directory-card .btn.danger.subtle,
#view-asistencia .attendance-card .btn.danger.subtle {
    color: #dc2626;
    background: #fff;
    border: 1px solid #dc2626;
    box-shadow: none;
}

#view-colaboradores .collaborator-directory-card .btn.danger.subtle:hover,
#view-asistencia .attendance-card .btn.danger.subtle:hover {
    color: #b91c1c;
    background: #fff;
    border-color: #dc2626;
    box-shadow: none;
}

body[data-theme="dark"] #view-colaboradores .collaborator-directory-card,
body[data-theme="dark"] #view-asistencia .attendance-card,
body[data-theme="dark"] #view-asistencia .attendance-card-sin-marcar {
    box-shadow: 0 8px 20px rgba(2, 8, 20, 0.18);
}

body[data-theme="dark"] #view-colaboradores .collaborator-directory-card:hover,
body[data-theme="dark"] #view-asistencia .attendance-card:hover,
body[data-theme="dark"] #view-asistencia .attendance-card-sin-marcar:hover {
    box-shadow: 0 12px 24px rgba(2, 8, 20, 0.24);
}

body[data-theme="dark"] #view-colaboradores .collaborator-directory-card .btn.danger.subtle,
body[data-theme="dark"] #view-asistencia .attendance-card .btn.danger.subtle {
    color: #f87171;
    background: transparent;
    border-color: #dc2626;
}

body[data-theme="dark"] #view-colaboradores .collaborator-directory-card .btn.danger.subtle:hover,
body[data-theme="dark"] #view-asistencia .attendance-card .btn.danger.subtle:hover {
    color: #f87171;
    background: transparent;
    border-color: #dc2626;
}

@media (max-width: 760px) {
    #view-colaboradores .inventory-products-grid,
    #view-asistencia .inventory-provider-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    #view-colaboradores .collaborator-directory-card .inventory-product-shell-meta,
    #view-asistencia .attendance-card .inventory-provider-shell-meta,
    #view-asistencia .attendance-card-sin-marcar .inventory-provider-shell-meta {
        grid-template-columns: 1fr;
    }
}
