/**
 * B2Bc Platform - White Glass + Soft Blue Background
 * 3rd District Negros Occidental
 */

/* Root Variables - White Glass + Soft Blue Theme */
:root {
    --bg-dark: linear-gradient(135deg, #E0F2FE 0%, #BAE6FD 100%);
    --glass-bg: rgba(255, 255, 255, 0.6);
    --glass-border: rgba(255, 255, 255, 0.45);
    --glass-shadow: 0 8px 32px 0 rgba(15, 23, 42, 0.12);
    --accent-blue: #3B82F6;
    --accent-purple: #60A5FA;
    --accent-cyan: #0EA5E9;
    --text-primary: #0F172A;
    --text-secondary: #334155;
    --neon-glow: 0 0 20px rgba(59, 130, 246, 0.22);
}

/* Body */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--bg-dark);
    min-height: 100vh;
    color: var(--text-primary);
    position: relative;
}

.glass-body {
    background: var(--bg-dark);
    position: relative;
}

.glass-body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 30%, rgba(59, 130, 246, 0.14) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(96, 165, 250, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(14, 165, 233, 0.08) 0%, transparent 40%);
    pointer-events: none;
    z-index: 0;
}

/* Glass Card Base */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    box-shadow: var(--glass-shadow);
    position: relative;
    z-index: 1;
}

/* Navigation */
.glass-nav {
    background: rgba(255, 255, 255, 0.55) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(59, 130, 246, 0.18);
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.08);
}

.glass-nav .navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--text-primary) !important;
}

.glass-nav .nav-link {
    color: var(--text-primary) !important;
    font-weight: 500;
    padding: 0.75rem 1.25rem !important;
    border-radius: 12px;
    transition: all 0.3s ease;
    margin: 0 0.25rem;
}

.glass-nav .nav-link:hover {
    background: rgba(59, 130, 246, 0.15);
    color: var(--accent-blue) !important;
    box-shadow: var(--neon-glow);
}

.glass-nav .nav-link.active {
    background: rgba(59, 130, 246, 0.2);
    color: var(--accent-blue) !important;
    box-shadow: var(--neon-glow);
}

/* Hero Section */
.hero-section {
    padding-top: 88px;
    position: relative;
}

.glass-hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.hero-content {
    padding: 1.5rem 1.75rem;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: var(--glass-shadow);
}

.hero-content h1 {
    color: var(--text-primary);
    font-weight: 800;
}

.hero-content p {
    color: var(--text-secondary);
}

/* Location Badge */
.location-badge {
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    color: var(--text-primary);
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 1.5rem;
    box-shadow: var(--neon-glow);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 20px rgba(59, 130, 246, 0.5); }
    50% { box-shadow: 0 0 30px rgba(59, 130, 246, 0.8); }
}

/* Category Filter Buttons */
.btn-glass {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 50px;
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(15, 23, 42, 0.08);
}

.btn-glass:hover {
    background: rgba(59, 130, 246, 0.15);
    transform: translateY(-2px);
    box-shadow: var(--neon-glow);
    color: var(--accent-blue);
    border-color: var(--accent-blue);
}

.btn-glass.active {
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    color: var(--text-primary);
    font-weight: 600;
    border-color: transparent;
    box-shadow: var(--neon-glow);
}

.btn-glass-sm {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(59, 130, 246, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 50px;
    color: var(--accent-blue);
    text-decoration: none;
    font-size: 0.875rem;
    transition: all 0.3s ease;
}

.btn-glass-sm:hover {
    background: rgba(59, 130, 246, 0.2);
    color: var(--accent-blue);
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.4);
}

/* Map Container */
.map-container {
    padding: 1rem;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: var(--glass-shadow);
    overflow: hidden;
}

#map {
    height: 500px;
    width: 100%;
    border-radius: 16px;
    border: 1px solid rgba(59, 130, 246, 0.1);
}

/* Custom Map Marker */
.custom-marker {
    filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.5));
}

.city-marker .city-label {
    background: rgba(59, 130, 246, 0.9);
    color: var(--text-primary);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
    box-shadow: var(--neon-glow);
    backdrop-filter: blur(10px);
}

.map-popup {
    text-align: center;
    min-width: 200px;
}

.map-popup h6 {
    color: var(--accent-blue);
    font-weight: 600;
}

/* Stats */
.stat-item {
    text-align: center;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 16px;
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    transition: all 0.3s ease;
}

.stat-item:hover {
    background: rgba(59, 130, 246, 0.15);
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.3);
}

.stat-item h3 {
    color: var(--accent-blue);
    font-weight: 700;
    font-size: 2rem;
    text-shadow: var(--neon-glow);
}

.stat-item small {
    color: var(--text-secondary);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 1px;
}

/* Business Card */
.business-card {
    overflow: hidden;
    transition: all 0.3s ease;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
}

.business-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(59, 130, 246, 0.3);
    border-color: var(--accent-cyan);
}

.business-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.35);
}

.business-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.business-card:hover .business-image img {
    transform: scale(1.1);
}

.badge-category {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    box-shadow: var(--neon-glow);
}

.business-info {
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(10px);
}

.business-info h5 {
    color: var(--text-primary);
    font-weight: 600;
}

.business-info .text-muted {
    color: var(--text-secondary) !important;
}

/* Business Detail Page */
.business-header .glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
}

.business-header h1 {
    color: var(--text-primary);
    font-weight: 700;
}

.business-logo {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border: 4px solid rgba(59, 130, 246, 0.3);
    box-shadow: var(--neon-glow);
}

/* Product Card */
.product-card {
    overflow: hidden;
    transition: all 0.3s ease;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(59, 130, 246, 0.3);
    border-color: var(--accent-cyan);
}

.product-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.35);
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.badge-featured {
    position: absolute;
    top: 10px;
    left: 10px;
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    color: var(--text-primary);
    padding: 0.35rem 0.75rem;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 600;
    box-shadow: 0 0 15px rgba(251, 191, 36, 0.5);
}

.badge-sale {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: var(--text-primary);
    padding: 0.35rem 0.75rem;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 600;
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.5);
}

.product-info {
    background: rgba(255, 255, 255, 0.45);
    backdrop-filter: blur(10px);
}

.product-info h6 {
    color: var(--text-primary);
    font-weight: 600;
}

.product-info .price {
    color: var(--accent-blue);
    font-size: 1.1rem;
    font-weight: 700;
}

.product-info input[type="number"] {
    max-width: 80px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: var(--text-primary);
}

.product-info input[type="number"]:focus {
    background: rgba(255, 255, 255, 0.9);
    border-color: var(--accent-blue);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
}

/* Footer */
.glass-footer {
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(20px);
    border-top: 1px solid rgba(59, 130, 246, 0.2);
    color: var(--text-primary);
}

.glass-footer h5 {
    color: var(--text-primary);
}

.glass-footer .text-muted {
    color: var(--text-secondary) !important;
}

/* Role Dashboard Layout */
.role-shell {
    min-height: 100vh;
    position: relative;
}

.role-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 260px;
    padding: 1.25rem;
    overflow-y: auto;
    background: rgba(255, 255, 255, 0.65);
    border-right: 1px solid var(--glass-border);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
    z-index: 1000;
    transition: transform 0.25s ease;
}

.role-sidebar .brand {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 1.1rem;
    margin-bottom: 1.25rem;
}

.role-sidebar .role-title {
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0.8rem;
}

.role-nav-link {
    display: block;
    text-decoration: none;
    color: var(--text-primary);
    padding: 0.65rem 0.8rem;
    border-radius: 10px;
    margin-bottom: 0.35rem;
    transition: all 0.2s ease;
}

.role-nav-link:hover {
    background: rgba(59, 130, 246, 0.12);
    color: var(--accent-blue);
}

.role-switch-link {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(14, 165, 233, 0.12));
    border: 1px solid rgba(59, 130, 246, 0.25);
    font-weight: 600;
    color: var(--accent-blue);
}

.role-switch-link:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.25), rgba(14, 165, 233, 0.2));
    border-color: rgba(59, 130, 246, 0.4);
    color: var(--accent-blue);
    transform: translateX(2px);
}

.role-divider {
    height: 1px;
    background: rgba(59, 130, 246, 0.15);
    margin: 0.75rem 0.4rem;
}

.role-section-title {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--accent-blue);
    padding: 0.4rem 0.8rem;
    margin-top: 0.25rem;
}

.role-nav-link.active {
    background: rgba(59, 130, 246, 0.2);
    color: var(--accent-blue);
    font-weight: 600;
}

.role-main {
    margin-left: 260px;
    padding: 1.5rem;
    transition: margin-left 0.25s ease, width 0.25s ease;
}

.role-sidebar-toggle {
    position: fixed;
    top: 0.75rem;
    left: 272px;
    width: 38px;
    height: 38px;
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.8);
    color: var(--text-primary);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.14);
    z-index: 1200;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: left 0.25s ease, background 0.2s ease;
}

.role-sidebar-toggle:hover {
    background: rgba(59, 130, 246, 0.15);
}

.role-shell.sidebar-collapsed .role-sidebar {
    transform: translateX(-110%);
}

.role-shell.sidebar-collapsed .role-main {
    margin-left: 0 !important;
    width: 100% !important;
}

.role-shell.sidebar-collapsed .role-sidebar-toggle {
    left: 0.75rem;
}

/* Glass Tables (Global) */
.table-responsive {
    border: 1px solid rgba(59, 130, 246, 0.18);
    border-radius: 14px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.45);
}

.table {
    margin-bottom: 0;
    color: var(--text-primary);
    background: transparent;
}

.table > :not(caption) > * > * {
    background-color: transparent !important;
    border-bottom-color: rgba(15, 23, 42, 0.14);
}

.table thead th {
    background: rgba(59, 130, 246, 0.12) !important;
    color: var(--text-primary);
    font-weight: 700;
}

.table tbody tr:hover {
    background: rgba(59, 130, 246, 0.08);
}

@media (max-width: 991px) {
    .role-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 220px;
        overflow-y: auto;
        border-right: 1px solid var(--glass-border);
        border-bottom: none;
        display: block;
        padding: 1rem;
    }

    .role-sidebar .brand,
    .role-sidebar .role-title {
        margin-bottom: 0.65rem;
    }

    .role-sidebar .role-nav-link {
        margin-bottom: 0.35rem;
        text-align: left;
        padding: 0.6rem 0.65rem;
        font-size: 0.9rem;
    }

    .role-main {
        margin-left: 220px;
        padding: 1rem;
    }

    .role-sidebar-toggle {
        left: 232px;
    }

    .table-responsive {
        border-radius: 12px;
    }
}

@media (min-width: 992px) {
    .role-shell .role-sidebar-toggle {
        display: none !important;
    }
}

@media (max-width: 767px) {
    .role-sidebar {
        position: fixed !important;
        top: 0;
        left: 0;
        bottom: 0;
        width: 185px !important;
        overflow-y: auto;
        border-right: 1px solid var(--glass-border);
        border-bottom: none;
        padding: 0.75rem;
        z-index: 1100;
    }

    .role-sidebar .brand {
        font-size: 1rem;
    }

    .role-sidebar .role-title {
        font-size: 0.75rem;
    }

    .role-sidebar .role-nav-link {
        text-align: left;
        font-size: 0.86rem;
        padding: 0.5rem 0.6rem;
        margin-bottom: 0.25rem;
    }

    .role-main {
        margin-left: 185px !important;
        width: calc(100% - 185px);
        padding: 0.85rem;
    }

    .role-sidebar-toggle {
        left: 194px;
    }

    .table {
        font-size: 0.875rem;
    }

    .table thead th,
    .table tbody td {
        padding: 0.55rem 0.5rem;
        vertical-align: middle;
        white-space: nowrap;
    }

    .table-responsive {
        -webkit-overflow-scrolling: touch;
    }

    .table .btn,
    .table .btn-glass-sm,
    .table .form-select,
    .table .form-control {
        font-size: 0.8rem;
        min-height: 34px;
    }

    .table .d-flex.gap-2 {
        gap: 0.35rem !important;
    }
}

/* Responsive Design */
@media (max-width: 991px) {
    .hero-section {
        padding-top: 80px;
    }
    
    .hero-content {
        margin-bottom: 2rem;
    }
    
    #map {
        height: 350px;
    }
}

@media (max-width: 767px) {
    .hero-content h1 {
        font-size: 2rem;
    }
    
    #map {
        height: 300px;
    }
    
    .btn-glass {
        padding: 0.6rem 1.2rem;
        font-size: 0.9rem;
    }
}

/* Loading Animation */
@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

.loading {
    background: linear-gradient(90deg, rgba(59,130,246,0.1) 25%, rgba(59,130,246,0.2) 50%, rgba(59,130,246,0.1) 75%);
    background-size: 1000px 100%;
    animation: shimmer 2s infinite;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.4);
}

::-webkit-scrollbar-thumb {
    background: rgba(59, 130, 246, 0.3);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(59, 130, 246, 0.5);
}

/* Form Controls */
input.form-control,
select.form-select,
textarea.form-control {
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: var(--text-primary);
}

input.form-control:focus,
select.form-select:focus,
textarea.form-control:focus {
    background: rgba(255, 255, 255, 0.92);
    border-color: var(--accent-blue);
    color: var(--text-primary);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.3);
}

input.form-control::placeholder,
textarea.form-control::placeholder {
    color: var(--text-secondary);
}

select.form-select option {
    background: #E0F2FE;
    color: var(--text-primary);
}

/* Badges */
.badge {
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    color: var(--text-primary);
}

.badge.bg-success {
    background: linear-gradient(135deg, #10b981, #059669) !important;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.4);
}

.badge.bg-primary {
    background: linear-gradient(135deg, var(--accent-blue), var(--accent-purple)) !important;
    box-shadow: var(--neon-glow);
}

.badge.bg-warning {
    background: linear-gradient(135deg, #fbbf24, #f59e0b) !important;
    box-shadow: 0 0 15px rgba(251, 191, 36, 0.4);
}

.badge.bg-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626) !important;
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.4);
}

/* Alert */
.alert {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 16px;
    backdrop-filter: blur(10px);
    color: var(--text-primary);
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.3);
}

.alert-danger {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
}

.alert-info {
    background: rgba(6, 182, 212, 0.1);
    border-color: rgba(6, 182, 212, 0.3);
}

/* Role Layout Override: Left Navigation (final) */
.role-shell .role-sidebar {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    bottom: 0 !important;
    width: 260px !important;
    border-right: 1px solid var(--glass-border) !important;
    border-bottom: none !important;
    display: block;
    max-height: none;
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
    z-index: 1350;
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.28);
    transition: transform 0.25s ease, opacity 0.2s ease;
}

.role-shell .role-sidebar .role-nav-section {
    margin-top: 0.55rem;
    padding-top: 0.45rem;
    border-top: 1px dashed rgba(59, 130, 246, 0.2);
}

.role-shell .role-sidebar .role-nav-section-title {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: #2563eb;
    margin-bottom: 0.3rem;
}

.role-shell .role-main {
    margin-left: 260px !important;
    width: calc(100% - 260px) !important;
}

.role-shell .role-sidebar-toggle {
    display: none !important;
    position: fixed;
    top: 0.9rem;
    left: 272px;
    right: auto;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(59, 130, 246, 0.35);
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.22), rgba(224, 242, 254, 0.98));
    color: #0f172a;
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.22);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1405;
}

.role-shell .role-sidebar-toggle:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.35), rgba(191, 219, 254, 0.98));
    transform: translateY(-1px);
}

.role-shell .role-sidebar-toggle:active {
    transform: translateY(0);
}

.role-shell::after {
    content: '';
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.28);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    z-index: 1325;
    display: none;
}

.role-shell:not(.sidebar-collapsed)::after {
    opacity: 1;
    pointer-events: auto;
}

.role-shell.sidebar-collapsed .role-sidebar {
    transform: translateX(-110%);
    opacity: 0;
    pointer-events: none;
}

.role-shell.sidebar-collapsed .role-main {
    margin-left: 0 !important;
    width: 100% !important;
}

.role-shell.sidebar-collapsed .role-sidebar-toggle {
    left: 0.75rem;
    right: auto;
}

/* Ensure Bootstrap modal appears above role sidebar/overlay layers */
.modal {
    z-index: 2100 !important;
}

.modal-backdrop {
    z-index: 2090 !important;
}

@media (max-width: 991px) {
    .role-shell .role-sidebar {
        width: 100vw !important;
    }

    .role-shell .role-main {
        margin-left: 0 !important;
        width: 100% !important;
    }

    .role-shell .role-sidebar-toggle {
        display: inline-flex !important;
        left: auto;
        right: 0.8rem;
        width: 42px;
        height: 42px;
    }

    .role-shell::after {
        display: block;
    }

    .role-shell.sidebar-collapsed .role-sidebar-toggle {
        left: 0.75rem;
        right: auto;
    }
    
    /* ===== NOTIFICATION BELL STYLES - MOBILE ===== */
    
    .notification-bell-container {
        position: absolute;
        top: 1rem;
        right: 1rem;
        z-index: 1000;
        display: flex;
        align-items: center;
    }
    
    .notification-bell-btn {
        position: relative;
        background: white;
        border: 1px solid #d1d5db;
        color: #374151;
        width: 44px;
        height: 44px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.2s ease;
        font-size: 1.25rem;
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    }
    
    .notification-bell-btn:hover {
        background: #f9fafb;
        border-color: #9ca3af;
        box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
    }
    
    .notification-bell-btn:active {
        transform: scale(0.95);
    }
    
    .notification-bell-btn.has-notifications {
        animation: bell-pulse 2s ease-in-out infinite;
    }
    
    @keyframes bell-pulse {
        0%, 100% {
            box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
        }
        50% {
            box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
        }
    }
    
    .notification-badge {
        position: absolute;
        top: -2px;
        right: -2px;
        background: #ef4444;
        color: white;
        border-radius: 50%;
        min-width: 20px;
        height: 20px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 0.7rem;
        font-weight: 700;
        border: 2px solid white;
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
        padding: 0 4px;
    }
    
    .notification-dropdown {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 1055;
        display: none;
        align-items: center;
        justify-content: center;
        padding: 20px;
    }
    
    .notification-dropdown.show {
        display: flex;
    }
    
    .notification-dropdown::before {
        content: '';
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.7);
        z-index: -1;
    }
    
    .notification-modal {
        background: #ffffff;
        border-radius: 16px;
        box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.05), 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
        width: 100%;
        max-width: 500px;
        max-height: 650px;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        animation: modalSlideDown 0.3s ease-out;
    }
    
    @keyframes modalSlideDown {
        from {
            opacity: 0;
            transform: translateY(-20px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
    
    .notification-header {
        padding: 24px;
        border-bottom: 1px solid #f3f4f6;
        display: flex;
        justify-content: space-between;
        align-items: center;
        background: #ffffff;
    }
    
    .notification-header h6 {
        margin: 0;
        font-weight: 600;
        font-size: 1.125rem;
        color: #111827;
    }
    
    .notification-header-actions {
        display: flex;
        gap: 8px;
        align-items: center;
    }
    
    .mark-all-read-btn {
        background: #f3f4f6;
        border: 1px solid #e5e7eb;
        color: #374151;
        cursor: pointer;
        font-size: 0.8rem;
        padding: 8px 16px;
        border-radius: 8px;
        transition: all 0.2s ease;
        display: flex;
        align-items: center;
        gap: 6px;
        font-weight: 500;
    }
    
    .mark-all-read-btn:hover {
        background: #e5e7eb;
        border-color: #d1d5db;
    }
    
    .close-modal-btn {
        background: #fee2e2;
        border: 1px solid #fecaca;
        color: #dc2626;
        cursor: pointer;
        font-size: 1.1rem;
        padding: 8px;
        border-radius: 8px;
        transition: all 0.2s ease;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 38px;
        height: 38px;
    }
    
    .close-modal-btn:hover {
        background: #fecaca;
        border-color: #fca5a5;
    }
    
    .notification-list {
        flex: 1;
        overflow-y: auto;
        max-height: 380px;
    }
    
    .notification-list::-webkit-scrollbar {
        width: 6px;
    }
    
    .notification-list::-webkit-scrollbar-track {
        background: transparent;
    }
    
    .notification-list::-webkit-scrollbar-thumb {
        background: rgba(59, 130, 246, 0.3);
        border-radius: 3px;
    }
    
    .notification-list::-webkit-scrollbar-thumb:hover {
        background: rgba(59, 130, 246, 0.5);
    }
    
    .notification-item {
        padding: 14px 16px;
        border-bottom: 1px solid rgba(59, 130, 246, 0.08);
        display: flex;
        gap: 12px;
        align-items: flex-start;
        cursor: pointer;
        transition: all 0.25s ease;
        background: transparent;
        position: relative;
    }
    
    .notification-item:hover {
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.06) 0%, rgba(224, 242, 254, 0.04) 100%);
        padding-left: 18px;
    }
    
    .notification-item.unread {
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.08) 0%, rgba(224, 242, 254, 0.06) 100%);
    }
    
    .notification-item.unread:hover {
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.12) 0%, rgba(224, 242, 254, 0.08) 100%);
    }
    
    .notification-icon {
        flex-shrink: 0;
        width: 42px;
        height: 42px;
        border-radius: 12px;
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.12) 0%, rgba(96, 165, 250, 0.08) 100%);
        display: flex;
        align-items: center;
        justify-content: center;
        color: var(--accent-blue);
        font-size: 1.1rem;
    }
    
    .notification-item.unread .notification-icon {
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.22) 0%, rgba(96, 165, 250, 0.15) 100%);
        box-shadow: 0 0 14px rgba(59, 130, 246, 0.25);
    }
    
    .notification-content {
        flex: 1;
        min-width: 0;
    }
    
    .notification-title {
        font-weight: 600;
        font-size: 0.95rem;
        color: var(--text-primary);
        margin-bottom: 4px;
        word-break: break-word;
        line-height: 1.3;
    }
    
    .notification-message {
        font-size: 0.85rem;
        color: var(--text-secondary);
        line-height: 1.45;
        margin-bottom: 6px;
        word-break: break-word;
    }
    
    .notification-time {
        font-size: 0.75rem;
        color: #A0AEC0;
        font-weight: 500;
    }
    
    .notification-indicator {
        position: absolute;
        right: 8px;
        top: 50%;
        transform: translateY(-50%);
        width: 7px;
        height: 7px;
        border-radius: 50%;
        background: var(--accent-blue);
        box-shadow: 0 0 10px rgba(59, 130, 246, 0.6);
        animation: indicator-pulse 2s ease-in-out infinite;
    }
    
    @keyframes indicator-pulse {
        0%, 100% {
            box-shadow: 0 0 10px rgba(59, 130, 246, 0.6);
        }
        50% {
            box-shadow: 0 0 16px rgba(59, 130, 246, 0.8);
        }
    }
    
    .notification-empty {
        padding: 40px 20px;
        text-align: center;
        color: var(--text-secondary);
    }
    
    .notification-empty i {
        font-size: 2.5rem;
        color: #CBD5E1;
        margin-bottom: 12px;
    }
    
    .notification-empty p {
        margin: 0;
        font-size: 0.9rem;
    }
    
    .notification-footer {
        padding: 20px 24px;
        border-top: 1px solid #f3f4f6;
        text-align: center;
        background: #ffffff;
    }
    
    .view-all-link {
        color: #3b82f6;
        text-decoration: none;
        font-size: 0.9rem;
        font-weight: 600;
        transition: all 0.2s ease;
        display: inline-block;
        padding: 8px 16px;
        border-radius: 8px;
    }
    
    .view-all-link:hover {
        background: #eff6ff;
        text-decoration: none;
    }
    
    .notification-loading {
        padding: 40px 20px;
        text-align: center;
        color: var(--text-secondary);
        font-size: 0.9rem;
    }
    
    /* Tablet responsive */
    @media (max-width: 768px) {
        .notification-modal {
            max-width: 450px;
        }
        
        .notification-list {
            max-height: 350px;
        }
        
        .mark-all-read-btn span {
            display: none;
        }
    }
    
    /* Mobile responsive */
    @media (max-width: 576px) {
        .notification-dropdown {
            padding: 16px;
        }
        
        .notification-modal {
            max-width: 100%;
            width: 100%;
            max-height: 90vh;
        }
        
        .notification-list {
            max-height: 300px;
        }
        
        .notification-header {
            padding: 14px 16px;
        }
        
        .notification-header h6 {
            font-size: 1rem;
            margin: 0;
        }
        
        .notification-item {
            padding: 10px 12px;
        }
        
        .mark-all-read-btn span {
            display: none;
        }
        
        .close-modal-btn {
            width: 32px;
            height: 32px;
            font-size: 0.9rem;
        }
        
        .notification-footer {
            padding: 10px 16px;
        }
        
        .notification-empty {
            padding: 30px 20px;
        }
    }
    
    /* Dark mode support */
    @media (prefers-color-scheme: dark) {
        .notification-dropdown {
            background: rgba(15, 23, 42, 0.9);
        }
    }
}

/* ===== NOTIFICATION BELL STYLES - PC/DESKTOP ===== */
@media (min-width: 992px) {
    .notification-bell-container {
        position: absolute;
        top: 1.5rem;
        right: 1.5rem;
        z-index: 1000;
        display: flex;
        align-items: center;
    }
    
    .notification-bell-btn {
        position: relative;
        background: rgba(255, 255, 255, 0.65);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border: 1px solid rgba(59, 130, 246, 0.25);
        color: var(--accent-blue);
        width: 42px;
        height: 42px;
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        transition: all 0.3s ease;
        font-size: 1.15rem;
        box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
    }
    
    .notification-bell-btn:hover {
        background: rgba(59, 130, 246, 0.15);
        border-color: var(--accent-blue);
        box-shadow: 0 6px 16px rgba(59, 130, 246, 0.25);
        transform: translateY(-2px);
    }
    
    .notification-bell-btn:active {
        transform: translateY(0);
    }
    
    .notification-bell-btn.has-notifications {
        animation: bell-pulse-desktop 2s ease-in-out infinite;
    }
    
    @keyframes bell-pulse-desktop {
        0%, 100% {
            box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
        }
        50% {
            box-shadow: 0 6px 20px rgba(59, 130, 246, 0.35);
        }
    }
    
    .notification-badge {
        position: absolute;
        top: -4px;
        right: -4px;
        background: linear-gradient(135deg, #ef4444, #dc2626);
        color: white;
        border-radius: 50%;
        min-width: 18px;
        height: 18px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 0.65rem;
        font-weight: 700;
        border: 2px solid rgba(255, 255, 255, 0.9);
        box-shadow: 0 2px 8px rgba(239, 68, 68, 0.4);
        padding: 0 4px;
    }
    
    .notification-dropdown {
        position: absolute;
        top: calc(100% + 12px);
        right: 0;
        width: 400px;
        max-height: 550px;
        z-index: 1055;
        display: none;
        flex-direction: column;
        animation: dropdownFadeIn 0.25s ease-out;
    }
    
    .notification-dropdown.show {
        display: flex;
    }
    
    @keyframes dropdownFadeIn {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
    
    .notification-dropdown::before {
        content: '';
        position: absolute;
        top: -8px;
        right: 16px;
        width: 0;
        height: 0;
        border-left: 8px solid transparent;
        border-right: 8px solid transparent;
        border-bottom: 8px solid rgba(255, 255, 255, 0.95);
        filter: drop-shadow(0 -2px 4px rgba(0, 0, 0, 0.08));
    }
    
    .notification-modal {
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(59, 130, 246, 0.2);
        border-radius: 16px;
        box-shadow: 0 10px 40px rgba(15, 23, 42, 0.15), 0 0 0 1px rgba(255, 255, 255, 0.5);
        width: 100%;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }
    
    .notification-header {
        padding: 16px 20px;
        border-bottom: 1px solid rgba(59, 130, 246, 0.12);
        display: flex;
        justify-content: space-between;
        align-items: center;
        background: rgba(59, 130, 246, 0.05);
    }
    
    .notification-header h6 {
        margin: 0;
        font-weight: 700;
        font-size: 1rem;
        color: var(--text-primary);
        letter-spacing: 0.02em;
    }
    
    .notification-header-actions {
        display: flex;
        gap: 8px;
        align-items: center;
    }
    
    .mark-all-read-btn {
        background: rgba(59, 130, 246, 0.1);
        border: 1px solid rgba(59, 130, 246, 0.25);
        color: var(--accent-blue);
        cursor: pointer;
        font-size: 0.75rem;
        padding: 6px 12px;
        border-radius: 8px;
        transition: all 0.25s ease;
        display: flex;
        align-items: center;
        gap: 5px;
        font-weight: 600;
    }
    
    .mark-all-read-btn:hover {
        background: rgba(59, 130, 246, 0.2);
        border-color: var(--accent-blue);
        box-shadow: 0 2px 8px rgba(59, 130, 246, 0.2);
    }
    
    .close-modal-btn {
        background: rgba(239, 68, 68, 0.1);
        border: 1px solid rgba(239, 68, 68, 0.25);
        color: #dc2626;
        cursor: pointer;
        font-size: 0.9rem;
        padding: 6px;
        border-radius: 8px;
        transition: all 0.25s ease;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
    }
    
    .close-modal-btn:hover {
        background: rgba(239, 68, 68, 0.2);
        border-color: #dc2626;
        box-shadow: 0 2px 8px rgba(239, 68, 68, 0.2);
    }
    
    .notification-list {
        flex: 1;
        overflow-y: auto;
        max-height: 380px;
    }
    
    .notification-list::-webkit-scrollbar {
        width: 5px;
    }
    
    .notification-list::-webkit-scrollbar-track {
        background: transparent;
    }
    
    .notification-list::-webkit-scrollbar-thumb {
        background: rgba(59, 130, 246, 0.25);
        border-radius: 3px;
    }
    
    .notification-list::-webkit-scrollbar-thumb:hover {
        background: rgba(59, 130, 246, 0.4);
    }
    
    .notification-item {
        padding: 14px 16px;
        border-bottom: 1px solid rgba(59, 130, 246, 0.08);
        display: flex;
        gap: 12px;
        align-items: flex-start;
        cursor: pointer;
        transition: all 0.25s ease;
        background: transparent;
        position: relative;
    }
    
    .notification-item:hover {
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.08) 0%, rgba(224, 242, 254, 0.05) 100%);
        padding-left: 18px;
    }
    
    .notification-item.unread {
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.1) 0%, rgba(224, 242, 254, 0.08) 100%);
    }
    
    .notification-item.unread:hover {
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.15) 0%, rgba(224, 242, 254, 0.1) 100%);
    }
    
    .notification-icon {
        flex-shrink: 0;
        width: 38px;
        height: 38px;
        border-radius: 10px;
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.12) 0%, rgba(96, 165, 250, 0.08) 100%);
        display: flex;
        align-items: center;
        justify-content: center;
        color: var(--accent-blue);
        font-size: 1rem;
    }
    
    .notification-item.unread .notification-icon {
        background: linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(96, 165, 250, 0.15) 100%);
        box-shadow: 0 0 12px rgba(59, 130, 246, 0.25);
    }
    
    .notification-content {
        flex: 1;
        min-width: 0;
    }
    
    .notification-title {
        font-weight: 600;
        font-size: 0.875rem;
        color: var(--text-primary);
        margin-bottom: 3px;
        word-break: break-word;
        line-height: 1.3;
    }
    
    .notification-message {
        font-size: 0.8rem;
        color: var(--text-secondary);
        line-height: 1.4;
        margin-bottom: 5px;
        word-break: break-word;
    }
    
    .notification-time {
        font-size: 0.7rem;
        color: #94a3b8;
        font-weight: 500;
    }
    
    .notification-indicator {
        position: absolute;
        right: 10px;
        top: 50%;
        transform: translateY(-50%);
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: var(--accent-blue);
        box-shadow: 0 0 8px rgba(59, 130, 246, 0.6);
        animation: indicator-pulse-desktop 2s ease-in-out infinite;
    }
    
    @keyframes indicator-pulse-desktop {
        0%, 100% {
            box-shadow: 0 0 8px rgba(59, 130, 246, 0.6);
        }
        50% {
            box-shadow: 0 0 12px rgba(59, 130, 246, 0.8);
        }
    }
    
    .notification-empty {
        padding: 40px 20px;
        text-align: center;
        color: var(--text-secondary);
    }
    
    .notification-empty i {
        font-size: 2.5rem;
        color: #cbd5e1;
        margin-bottom: 12px;
    }
    
    .notification-empty p {
        margin: 0;
        font-size: 0.875rem;
    }
    
    .notification-footer {
        padding: 14px 20px;
        border-top: 1px solid rgba(59, 130, 246, 0.12);
        text-align: center;
        background: rgba(59, 130, 246, 0.03);
    }
    
    .view-all-link {
        color: var(--accent-blue);
        text-decoration: none;
        font-size: 0.825rem;
        font-weight: 600;
        transition: all 0.25s ease;
        display: inline-block;
        padding: 6px 14px;
        border-radius: 8px;
    }
    
    .view-all-link:hover {
        background: rgba(59, 130, 246, 0.12);
        text-decoration: none;
        box-shadow: 0 2px 8px rgba(59, 130, 246, 0.15);
    }
    
    .notification-loading {
        padding: 40px 20px;
        text-align: center;
        color: var(--text-secondary);
        font-size: 0.875rem;
    }
}

@media (max-width: 767px) {
    .role-shell .role-sidebar-toggle {
        right: 0.6rem;
        left: auto;
        top: 0.6rem;
        width: 36px;
        height: 36px;
        border-radius: 11px;
    }

    .role-shell.sidebar-collapsed .role-sidebar-toggle {
        left: 0.6rem;
        right: auto;
    }
    
    /* Mobile Table Responsiveness */
    .table-responsive {
        border-radius: 10px;
        -webkit-overflow-scrolling: touch;
    }
    
    .table {
        font-size: 0.75rem;
        white-space: nowrap;
    }
    
    .table thead th {
        padding: 0.5rem 0.35rem !important;
        font-size: 0.7rem;
        font-weight: 700;
    }
    
    .table tbody td {
        padding: 0.4rem 0.35rem !important;
        font-size: 0.75rem;
        vertical-align: middle;
    }
    
    /* Allow text wrapping for specific columns */
    .table tbody td:first-child,
    .table thead th:first-child {
        max-width: 70px;
        word-break: break-word;
        white-space: normal;
    }
    
    .table tbody td:nth-child(2),
    .table thead th:nth-child(2) {
        max-width: 80px;
        word-break: break-word;
        white-space: normal;
    }
    
    /* Make action buttons smaller */
    .table .btn,
    .table .btn-glass-sm {
        padding: 0.25rem 0.5rem;
        font-size: 0.65rem;
        min-height: 28px;
    }
    
    .table .btn i,
    .table .btn-glass-sm i {
        margin-right: 0.25rem;
    }
    
    /* Form controls in tables */
    .table .form-control,
    .table .form-select {
        padding: 0.25rem 0.35rem;
        font-size: 0.75rem;
        height: 28px;
    }
    
    .table input[type="number"] {
        max-width: 60px;
    }
    
    /* Flexbox utilities in tables */
    .table .d-flex {
        flex-wrap: wrap;
        gap: 0.25rem;
    }
    
    .table .gap-2 {
        gap: 0.25rem !important;
    }
    
    /* Status badges in tables */
    .table .badge {
        padding: 0.3rem 0.6rem;
        font-size: 0.65rem;
    }
    
    /* Hide certain columns on very small devices */
    @media (max-width: 480px) {
        .table tbody td:nth-child(n+4),
        .table thead th:nth-child(n+4) {
            display: none;
        }
        
        .table {
            font-size: 0.7rem;
        }
        
        .table thead th,
        .table tbody td {
            padding: 0.3rem 0.25rem !important;
        }
    }
}
