
/* ================================
   GLOBAL RESET
================================ */
* {
    box-sizing: border-box;
}

/* ================================
   SIDEBAR
================================ */
:root {
    --sidebar-width: 240px;
}

.sidebar {
    height: 100vh;
    background: #000000;
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    padding-top: 20px;
    overflow-y: auto;
    z-index: 1000;
}

.sidebar a {
    color: #ccc;
    text-decoration: none;
    display: block;
    padding: 10px 20px;
    font-size: 15px;
}

.sidebar a:hover {
    background-color: rgba(255,255,255,0.1);
    color: #ff00cc;
}

.sidebar a.active {
    color: #ff00cc;
    background-color: rgba(255,255,255,0.08);
}

.sidebar-footer {
    color: #999;
    font-size: 12px;
    text-align: center;
    border-top: 1px solid #333;
    padding: 10px;
}

/* ================================
   MAIN CONTENT
================================ */
.main-content {
    margin-left: 240px;              /* EXACT sidebar width */
    padding: 24px 24px 24px 24px;    /* controlled padding */
    background-color: #f8f9fa;
    min-height: 100vh;
}


/* ================================
   HEADER BANNER
================================ */
.overlay-text {
    background: linear-gradient(to right, #573b8a, #ff00cc);
    border-radius: 14px;
    color: white;
    text-align: center;
    padding: 25px;
    margin-bottom: 30px;
    width: 100%;
}

/* ================================
   CARDS
================================ */
.card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 0 10px rgba(0,0,0,0.08);
    transition: all 0.3s ease-in-out;
    padding: 20px;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 0 20px rgba(0,0,0,0.15);
}

.card-title {
    font-size: 1rem;
    font-weight: 600;
    color: #573b8a;
}

/* ================================
   BUTTONS
================================ */
.btn-primary {
    background-color: #573b8a;
    border: none;
}

.btn-primary:hover {
    background-color: #6d44b8;
}

/* ================================
   TABLES
================================ */
.table thead {
    background-color: #573b8a;
    color: white;
}

/* ================================
   ROLE MANAGER GRID (IMPORTANT)
================================ */
.role-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px 20px;
    margin-top: 10px;
}

.role-grid label {
    display: flex;
    align-items: center;
    font-size: 14px;
    font-weight: 500;
}

/* ================================
   MOBILE FIX
================================ */
@media (max-width: 991px) {
    .sidebar {
        position: relative;
        width: 100%;
        height: auto;
    }

    .main-content {
        margin-left: 0;
        width: 100%;
    }
}
/* ================================
   Role Manager – Modules wrap fix
================================ */

/* Allow wrapping inside table cells */
.table td,
.table th {
    white-space: normal !important;
    vertical-align: top;
}

/* Specifically handle long module lists */
.modules-cell {
    max-width: 420px;          /* adjust if needed */
    word-break: break-word;
    overflow-wrap: anywhere;
    line-height: 1.5;
}
