/**
 * ABHO Documents Styles
 *
 * Estilos para upload, visualização e gerenciamento de documentos
 * na área do membro (My Account / perfil).
 *
 * Depende de: main.css (variáveis CSS)
 *
 * @package ABHO
 * @since 1.0.0
 */

/* ========================================
   DOCUMENT LIST
   ======================================== */

.abho-documents {
    max-width: 800px;
}

.abho-documents__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--abho-spacing-lg);
    padding-bottom: var(--abho-spacing-sm);
    border-bottom: 2px solid var(--abho-gray-200, #e5e7eb);
}

.abho-documents__title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--abho-gray-900, #1a1a1a);
}

.abho-documents__count {
    font-size: 0.875rem;
    color: var(--abho-gray-500);
}

/* ========================================
   DOCUMENT ITEM
   ======================================== */

.abho-document {
    display: flex;
    align-items: flex-start;
    gap: var(--abho-spacing-md);
    padding: var(--abho-spacing-md);
    margin-bottom: var(--abho-spacing-sm);
    background-color: var(--abho-white, #fff);
    border: 1px solid var(--abho-gray-200, #e5e7eb);
    border-radius: var(--abho-border-radius);
    transition: border-color var(--abho-transition);
}

.abho-document:hover {
    border-color: var(--abho-primary);
}

.abho-document__icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f0f6fc;
    border-radius: var(--abho-border-radius);
    font-size: 1.25rem;
}

.abho-document__info {
    flex: 1;
    min-width: 0;
}

.abho-document__name {
    font-weight: 500;
    font-size: 0.9375rem;
    color: var(--abho-gray-900, #1a1a1a);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.abho-document__meta {
    font-size: 0.8125rem;
    color: var(--abho-gray-500);
    margin-top: 2px;
}

.abho-document__status {
    flex-shrink: 0;
    align-self: center;
}

/* Status badges */
.abho-document__status--pending {
    color: #856404;
    background-color: #fff3cd;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.abho-document__status--approved {
    color: #155724;
    background-color: #d4edda;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.abho-document__status--rejected {
    color: #721c24;
    background-color: #f8d7da;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.abho-document__actions {
    flex-shrink: 0;
    display: flex;
    gap: var(--abho-spacing-xs, 4px);
}

/* ========================================
   DOCUMENT UPLOAD ZONE
   ======================================== */

.abho-upload-zone {
    position: relative;
    padding: var(--abho-spacing-xl, 32px);
    border: 2px dashed var(--abho-gray-300);
    border-radius: var(--abho-border-radius);
    text-align: center;
    cursor: pointer;
    transition: border-color var(--abho-transition), background-color var(--abho-transition);
}

.abho-upload-zone:hover,
.abho-upload-zone.is-dragover {
    border-color: var(--abho-primary);
    background-color: #f0f6fc;
}

.abho-upload-zone__icon {
    font-size: 2rem;
    color: var(--abho-gray-400, #9ca3af);
    margin-bottom: var(--abho-spacing-sm);
}

.abho-upload-zone__text {
    color: var(--abho-gray-500);
    font-size: 0.9375rem;
}

.abho-upload-zone__text strong {
    color: var(--abho-primary);
}

.abho-upload-zone__hint {
    font-size: 0.8125rem;
    color: var(--abho-gray-400, #9ca3af);
    margin-top: var(--abho-spacing-xs, 4px);
}

.abho-upload-zone__input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

/* ========================================
   UPLOAD PROGRESS
   ======================================== */

.abho-upload-progress {
    margin-top: var(--abho-spacing-md);
}

.abho-upload-progress__bar {
    height: 6px;
    background-color: var(--abho-gray-200, #e5e7eb);
    border-radius: 3px;
    overflow: hidden;
}

.abho-upload-progress__fill {
    height: 100%;
    background-color: var(--abho-primary);
    border-radius: 3px;
    transition: width 0.3s ease;
}

.abho-upload-progress__text {
    font-size: 0.8125rem;
    color: var(--abho-gray-500);
    margin-top: 4px;
    text-align: right;
}

/* ========================================
   REQUIRED DOCUMENTS CHECKLIST
   ======================================== */

.abho-required-docs {
    margin-top: var(--abho-spacing-lg);
    padding: var(--abho-spacing-md);
    background-color: #fefcf3;
    border: 1px solid #ffeeba;
    border-radius: var(--abho-border-radius);
}

.abho-required-docs__title {
    font-weight: 600;
    font-size: 0.9375rem;
    margin-bottom: var(--abho-spacing-sm);
}

.abho-required-docs__item {
    display: flex;
    align-items: center;
    gap: var(--abho-spacing-sm);
    padding: 4px 0;
    font-size: 0.875rem;
}

.abho-required-docs__item--done {
    color: var(--abho-success);
}

.abho-required-docs__item--missing {
    color: var(--abho-error);
}

/* ========================================
   REJECTION NOTE
   ======================================== */

.abho-document__rejection {
    margin-top: var(--abho-spacing-sm);
    padding: var(--abho-spacing-sm);
    background-color: #fff5f5;
    border-left: 3px solid var(--abho-error);
    border-radius: 0 var(--abho-border-radius) var(--abho-border-radius) 0;
    font-size: 0.8125rem;
    color: #721c24;
}

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 600px) {
    .abho-document {
        flex-wrap: wrap;
    }

    .abho-document__actions {
        width: 100%;
        justify-content: flex-end;
        margin-top: var(--abho-spacing-sm);
    }

    .abho-documents__header {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--abho-spacing-xs, 4px);
    }
}
