/**
 * CMMC L2 Assessment Tool - Evidence UI Styles
 */

/* ==========================================
   LOGIN OVERLAY
   ========================================== */
.login-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.login-overlay.active {
    display: flex;
}

.login-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 48px;
    max-width: 400px;
    width: 90%;
    text-align: center;
}

.login-logo {
    color: var(--accent-blue);
    margin-bottom: 24px;
}

.login-card h2 {
    color: var(--text-primary);
    font-size: 24px;
    margin: 0 0 12px;
}

.login-card > p {
    color: var(--text-secondary);
    font-size: 14px;
    margin: 0 0 32px;
    line-height: 1.5;
}

.btn-google-signin-large {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 14px 24px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: white;
    color: #333;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-google-signin-large:hover {
    background: #f5f5f5;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.login-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
}

.login-feature {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-muted);
}

.login-feature span {
    font-size: 16px;
}

/* ==========================================
   ASSESSMENT SELECTOR
   ========================================== */
.assessment-selector {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
}

.selector-section {
    margin-bottom: 12px;
}

.selector-section:last-child {
    margin-bottom: 0;
}

.selector-label {
    display: block;
    font-size: 10px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.selector-row {
    display: flex;
    gap: 6px;
}

.selector-select {
    flex: 1;
    padding: 8px 10px;
    font-size: 13px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    cursor: pointer;
}

.selector-select:focus {
    outline: none;
    border-color: var(--accent-blue);
}

.btn-icon-small {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--bg-secondary);
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s;
}

.btn-icon-small:hover {
    border-color: var(--accent-blue);
    color: var(--accent-blue);
}

.current-assessment-info {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    background: var(--bg-tertiary);
    border-radius: 6px;
    margin-top: 8px;
}

.assessment-status {
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
}

.assessment-status.in_progress {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

.assessment-status.completed {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.assessment-date {
    font-size: 11px;
    color: var(--text-muted);
}

/* ==========================================
   PROFILE MODAL
   ========================================== */
.profile-modal-content {
    max-width: 400px;
}

.profile-avatar-section {
    display: flex;
    justify-content: center;
    margin-bottom: 24px;
}

.profile-avatar-large {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--border-color);
}

/* ==========================================
   FILE SCAN STATUS
   ========================================== */
.scan-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 500;
}

.scan-pending, .scan-scanning {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

.scan-clean {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.scan-infected {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.scan-error {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

/* ==========================================
   AUTH UI
   ========================================== */
.auth-container {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
}

.auth-user {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.user-info {
    flex: 1;
    min-width: 0;
}

.user-name {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-email {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.btn-google-signin {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 10px 16px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-google-signin:hover {
    background: var(--bg-tertiary);
    border-color: var(--text-muted);
}

/* ==========================================
   EVIDENCE BUTTON
   ========================================== */
.evidence-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 32px;
    height: 32px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background: var(--bg-secondary);
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s;
}

.evidence-btn:hover {
    border-color: var(--accent-blue);
    color: var(--accent-blue);
    background: rgba(59, 130, 246, 0.1);
}

.evidence-btn.has-evidence {
    border-color: var(--status-met);
    color: var(--status-met);
    background: rgba(34, 197, 94, 0.1);
}

.evidence-btn.has-evidence:hover {
    background: rgba(34, 197, 94, 0.2);
}

.evidence-count {
    position: absolute;
    top: -6px;
    right: -6px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 8px;
    background: var(--accent-blue);
    color: white;
    font-size: 10px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.evidence-btn.has-evidence .evidence-count {
    background: var(--status-met);
}

/* ==========================================
   EVIDENCE MODAL
   ========================================== */
.evidence-modal-content {
    max-width: 600px;
    width: 100%;
}

.evidence-upload-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px;
    border: 2px dashed var(--border-color);
    border-radius: 8px;
    background: var(--bg-secondary);
    cursor: pointer;
    transition: all 0.2s;
    margin-bottom: 20px;
}

.evidence-upload-area:hover,
.evidence-upload-area.drag-over {
    border-color: var(--accent-blue);
    background: rgba(59, 130, 246, 0.05);
}

.upload-icon {
    color: var(--text-muted);
    margin-bottom: 12px;
}

.evidence-upload-area:hover .upload-icon,
.evidence-upload-area.drag-over .upload-icon {
    color: var(--accent-blue);
}

.upload-text {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0 0 6px;
}

.upload-link {
    color: var(--accent-blue);
    font-weight: 500;
}

.upload-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin: 0;
}

/* ==========================================
   EVIDENCE LIST
   ========================================== */
.evidence-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 300px;
    overflow-y: auto;
}

.evidence-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-secondary);
    transition: all 0.2s;
}

.evidence-item:hover {
    border-color: var(--text-muted);
}

.evidence-icon {
    font-size: 24px;
    line-height: 1;
}

.evidence-info {
    flex: 1;
    min-width: 0;
}

.evidence-name {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.evidence-meta {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 2px;
}

.evidence-desc {
    display: block;
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.evidence-actions {
    display: flex;
    gap: 4px;
}

.btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 6px;
    background: transparent;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s;
}

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

.btn-icon.btn-danger:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

/* ==========================================
   EVIDENCE STATES
   ========================================== */
.evidence-loading,
.evidence-empty,
.evidence-error {
    padding: 24px;
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
}

.evidence-error {
    color: #ef4444;
}

/* ==========================================
   RESPONSIVE
   ========================================== */
@media (max-width: 768px) {
    .evidence-modal-content {
        margin: 16px;
        max-height: calc(100vh - 32px);
    }

    .evidence-upload-area {
        padding: 24px 16px;
    }

    .evidence-list {
        max-height: 200px;
    }

    .evidence-item {
        padding: 10px;
    }

    .auth-user {
        flex-wrap: wrap;
    }
}
