/* ===== MODULE-SPECIFIC STYLES ===== */

/* Module Header */
.module-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.module-actions {
    display: flex;
    gap: 8px;
}

/* Filters Bar */
.filters-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 6px;
}

.filter-label {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}

.filter-select {
    padding: 6px 10px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 12px;
    outline: none;
}

/* Status indicators */
.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 6px;
}

.status-dot.active { background: var(--success); }
.status-dot.pending { background: var(--accent); }
.status-dot.overdue { background: var(--danger); }
.status-dot.completed { background: var(--info); }

/* Timeline */
.timeline {
    position: relative;
    padding-left: 24px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

.timeline-item {
    position: relative;
    padding-bottom: 20px;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -20px;
    top: 4px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary-light);
    border: 2px solid white;
    box-shadow: 0 0 0 2px var(--primary-light);
}

.timeline-item.completed::before { background: var(--success); box-shadow: 0 0 0 2px var(--success); }
.timeline-item.warning::before { background: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
.timeline-item.danger::before { background: var(--danger); box-shadow: 0 0 0 2px var(--danger); }

.timeline-content {
    background: var(--bg-card);
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-light);
}

.timeline-date {
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.timeline-text {
    font-size: 13px;
}

/* Investigation Cards */
.investigation-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
    padding: 16px;
    margin-bottom: 12px;
    transition: box-shadow 0.2s;
}

.investigation-card:hover {
    box-shadow: var(--shadow-md);
}

.investigation-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.investigation-id {
    font-size: 12px;
    font-weight: 600;
    color: var(--primary-light);
}

.investigation-body {
    margin-bottom: 10px;
}

.investigation-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.investigation-desc {
    font-size: 12px;
    color: var(--text-secondary);
}

.investigation-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-secondary);
}

/* Progress Bar */
.progress-bar {
    height: 6px;
    background: var(--border);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 8px;
}

.progress-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
}

.progress-fill.green { background: var(--success); }
.progress-fill.blue { background: var(--info); }
.progress-fill.orange { background: var(--accent); }
.progress-fill.red { background: var(--danger); }

/* Worklist table */
.worklist-status {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Audit trail */
.audit-entry {
    display: grid;
    grid-template-columns: 140px 120px 1fr 120px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-light);
    font-size: 12px;
    align-items: center;
}

.audit-entry:hover {
    background: #f8fafc;
}

.audit-timestamp {
    color: var(--text-secondary);
    font-family: 'Courier New', monospace;
    font-size: 11px;
}

.audit-user {
    font-weight: 500;
}

.audit-action {
    color: var(--text-primary);
}

.audit-module {
    color: var(--text-secondary);
}

/* Excursion Severity */
.severity-alert {
    background: #fef9e7;
    border-left: 4px solid var(--accent);
    padding: 12px 16px;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    margin-bottom: 8px;
}

.severity-action {
    background: #fdedec;
    border-left: 4px solid var(--danger);
    padding: 12px 16px;
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    margin-bottom: 8px;
}

/* Report Card */
.report-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius);
    cursor: pointer;
    transition: all 0.2s;
}

.report-card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--primary-light);
}

.report-icon {
    font-size: 32px;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-body);
    border-radius: var(--radius);
}

.report-info {
    flex: 1;
}

.report-name {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.report-desc {
    font-size: 12px;
    color: var(--text-secondary);
}

/* KPI Row */
.kpi-row {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.kpi-item {
    text-align: center;
    padding: 16px 8px;
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border-light);
}

.kpi-value {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 4px;
}

.kpi-label {
    font-size: 11px;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.kpi-target {
    font-size: 10px;
    color: var(--text-light);
    margin-top: 4px;
}

/* Compliance checks */
.compliance-check {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-bottom: 1px solid var(--border-light);
}

.compliance-check:last-child { border-bottom: none; }

.check-icon {
    font-size: 18px;
}

.check-info {
    flex: 1;
}

.check-title {
    font-size: 13px;
    font-weight: 500;
}

.check-desc {
    font-size: 11px;
    color: var(--text-secondary);
}

.check-status {
    font-size: 11px;
    font-weight: 600;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 48px 24px;
    color: var(--text-secondary);
}

.empty-state-icon {
    font-size: 48px;
    margin-bottom: 12px;
    opacity: 0.5;
}

.empty-state-text {
    font-size: 14px;
}
