/* System Modules: the dashboard "My Modules" panel (v3 ModuleAccessPanel) and the User Details tab. */

.map-panel-divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, #d8dee8, transparent);
    margin: 16px 0 18px;
}

.map-panel-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.map-panel-title {
    margin: 0;
    font-size: 1rem;
    font-weight: 700;
    color: #1f2a37;
}

.map-panel-hint {
    margin: 0 0 14px;
    font-size: .82rem;
    color: #6b7280;
}

.map-card-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.map-card {
    display: grid;
    grid-template-columns: 44px 1fr;
    grid-template-areas: "icon body" "actions actions";
    gap: 8px 12px;
    padding: 14px;
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 0 2px 8px rgba(15, 23, 42, .06);
}

.map-card--active {
    border-color: var(--cmms-primary, #0066cc);
    background: linear-gradient(145deg, #f0f7ff 0%, #e8f2ff 100%);
    box-shadow: 0 4px 14px rgba(0, 102, 204, .15);
}

.map-card-icon {
    grid-area: icon;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    border-radius: 8px;
    background: rgba(0, 102, 204, .12);
}

.map-card-body {
    grid-area: body;
    min-width: 0;
}

.map-card-name {
    font-weight: 700;
    font-size: .95rem;
    color: #111827;
    margin-bottom: 6px;
}

.map-card-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.map-badge {
    display: inline-block;
    font-size: .68rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 999px;
}

.map-badge--current {
    background: var(--cmms-primary, #0066cc);
    color: #fff;
}

.map-badge--default {
    background: #fef3c7;
    color: #92400e;
}

.map-badge--missing {
    background: #fee2e2;
    color: #991b1b;
}

.map-card-actions {
    grid-area: actions;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 4px;
}

.map-btn {
    text-transform: none;
    font-weight: 700;
    min-width: 72px;
}

.map-btn-default {
    min-width: 96px;
    background: #fff;
}

/* User Details ▸ System Modules tab */
.usm-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: end;
}

.usm-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.usm-empty {
    border: 1px dashed #cbd5e1;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    color: #6b7280;
    font-size: .9rem;
}

@media (max-width: 959px) {
    .usm-row {
        grid-template-columns: 1fr;
    }
}
