/* Custom CSS for Workspace UI Enhancements */

/* ========================================
   WORKSPACE DASHBOARD ENHANCEMENTS
   ======================================== */

.tenant-compact {
    font-size: 15px;
    line-height: 1.4;
}

.tenant-compact .page-header,
.tenant-compact .card,
.tenant-compact .navbar,
.tenant-compact .tenant-sidebar .card {
    border-radius: 4px;
}

.tenant-compact .container-xl,
.tenant-compact .page-body,
.tenant-compact .card-body,
.tenant-compact .card-header,
.tenant-compact .card-footer {
    /* padding-top: 0rem; */
    padding-bottom: 0.75rem;
}

.tenant-compact .card-body,
.tenant-compact .card-header,
.tenant-compact .card-footer {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

.tenant-compact .page-wrapper {
    padding-top: 0.75rem;
}

.tenant-compact .page-body {
    gap: 1.5rem !important;
}

.tenant-compact .nav-link,
.tenant-compact .btn {
    padding: 0.45rem 0.85rem;
    font-size: 0.9rem;
}

.tenant-compact .btn-sm {
    padding: 0.35rem 0.6rem;
    font-size: 0.85rem;
}

.tenant-compact .card-title,
.tenant-compact h1,
.tenant-compact h2,
.tenant-compact h3 {
    margin-bottom: 0.4rem;
    font-size: 1.1rem;
}

.tenant-compact h4,
.tenant-compact h5,
.tenant-compact h6 {
    margin-bottom: 0.4rem;
    font-size: 1rem;
}

.tenant-compact p,
.tenant-compact .text-secondary,
.tenant-compact .form-text {
    margin-bottom: 0.35rem;
    font-size: 0.9rem;
}

.tenant-compact .table {
    margin-bottom: 0.75rem;
}

.tenant-compact .table th,
.tenant-compact .table td {
    padding: 0.5rem 0.65rem;
    font-size: 0.875rem;
}

.tenant-compact .form-control,
.tenant-compact .form-select {
    min-height: 2.25rem;
    padding: 0.4rem 0.6rem;
    font-size: 0.9rem;
}

.tenant-compact .form-label {
    margin-bottom: 0.35rem;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.tenant-compact .input-group-text {
    padding: 0.4rem 0.6rem;
    font-size: 0.85rem;
}

.tenant-compact .badge {
    font-size: 0.75rem;
    padding: 0.3rem 0.45rem;
}

.tenant-compact .list-group-item {
    padding: 0.5rem 0.75rem;
}

.tenant-compact .page-header .card-body {
    gap: 1rem;
}

.tenant-compact .page-header .card-body .text-secondary {
    font-size: 0.9rem;
}

.tenant-compact .card-md {
    margin-top: 1rem;
    margin-bottom: 1rem;
}

.tenant-compact .navbar .container-xl,
.tenant-compact .page-header .card-body {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.tenant-compact .navbar .nav-item .dropdown-menu {
    padding: 0.4rem;
}

.tenant-compact .dropdown-item {
    padding: 0.5rem 0.65rem;
    font-size: 0.9rem;
}

.tenant-compact .compact-banner {
    background: linear-gradient(135deg, #f8fafc 0%, #eef2f6 100%);
    border: 1px solid #e2e8f0;
    margin-bottom: 1rem;
}

.tenant-compact .compact-banner .card-body {
    padding: 0.75rem 1rem;
}

.tenant-compact .compact-banner h2 {
    font-size: 1rem;
}

.tenant-compact .compact-banner .text-secondary {
    font-size: 0.85rem;
}

/* Enhanced Quick Actions Grid */
.quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

/* Enhanced Quick Action Cards */
.quick-action-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 2px solid #e9ecef;
    border-radius: 5px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.2s ease-in-out;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 160px;
}

.quick-action-card:hover {
    border-color: #30398B;
    transform: translateY(-4px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    text-decoration: none;
    color: inherit;
}

.quick-action-card .icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: #30398B;
}

.quick-action-card .title {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: #1e293b;
}

.quick-action-card .description {
    font-size: 0.875rem;
    color: #626976;
    line-height: 1.4;
}

/* Enhanced Stats Cards */
.stats-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 1px solid #e9ecef;
    border-radius: 5px;
    padding: 1.5rem;
    transition: all 0.2s ease-in-out;
}

.stats-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.stats-card .avatar {
    width: 3rem;
    height: 3rem;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.stats-card .counter {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1e293b;
    line-height: 1;
}

.stats-card .label {
    font-size: 0.875rem;
    color: #626976;
    margin-top: 0.25rem;
}

/* Enhanced Page Header */
.page-header {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 0rem;
    padding: 0.5rem;
    margin-bottom: 2rem;
    border: 1px solid #e9ecef;
}

.page-title {
    color: #1e293b;
    /* font-weight: 700; */
    margin-bottom: 0rem;
}

.page-header .text-secondary {
    color: #626976 !important;
    font-size: 1.1rem;
}

/* Enhanced Alerts */
.alert {
    border: none;
    border-radius: 0rem;
    padding: 1rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

.alert-info {
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
    color: #0c5460;
    border-left: 4px solid #467fd0;
}

/* Enhanced Recent Activity */
.recent-activity-item {
    padding: 1rem;
    border-radius: 5px;
    transition: all 0.2s ease-in-out;
    border: 1px solid transparent;
}

.recent-activity-item:hover {
    background-color: rgba(32, 107, 196, 0.05);
    border-color: #e9ecef;
}

.activity-avatar {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 5px;
    background: linear-gradient(135deg, #467fd0 0%, #3a6ea5 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

/* Enhanced Sidebar */
.workspace-sidebar {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-left: 1px solid #e9ecef;
}

.sidebar-card {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 5px;
    margin-bottom: 1.5rem;
    overflow: hidden;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

.sidebar-card .card-header {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-bottom: 1px solid #e9ecef;
    padding: 1rem 1.25rem;
}

/* ========================================
   NAVIGATION ENHANCEMENTS
   ======================================== */

/* Enhanced Navigation */
.navbar {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-bottom: 1px solid #e9ecef;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

.navbar-brand {
    font-weight: 700;
    color: #30398B !important;
}

.navbar-brand-text {
    font-size: 1.25rem;
    margin-left: 0.5rem;
}

.nav-link {
    color: #626976 !important;
    font-weight: 500;
    padding: 0 rem 1rem !important;
    border-radius: 5px;
    transition: all 0.2s ease-in-out;
    margin: 0 0.25rem;
}

.nav-link:hover {
    color: #30398B !important;
    background-color: rgba(32, 107, 196, 0.1);
}

.nav-link.active {
    color: #30398B !important;
    background-color: rgba(32, 107, 196, 0.1);
    font-weight: 600;
}

.nav-link .icon {
    margin-right: 0.5rem;
    width: 1.25rem;
    height: 1.25rem;
}

/* Enhanced Dropdowns */
.dropdown-menu {
    border: 1px solid #e9ecef;
    border-radius: 5px;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    padding: 0.5rem;
    min-width: 200px;
}

.dropdown-item {
    border-radius: 5px;
    padding: 0.75rem 1rem;
    transition: all 0.2s ease-in-out;
    display: flex;
    align-items: center;
}

.dropdown-item:hover {
    background-color: rgba(32, 107, 196, 0.1);
    color: #30398B;
}

.dropdown-item.active {
    background-color: #30398B;
    color: white;
}

.dropdown-header {
    font-weight: 600;
    color: #626976;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.5rem 1rem;
    margin-top: 0.5rem;
}

/* Enhanced User Menu */
.navbar-nav .nav-item.dropdown .nav-link {
    display: flex;
    align-items: center;
    padding: 0.5rem 1rem;
}

.avatar {
    background: background: linear-gradient(135deg, #3b82f6, #10b981);
    color: white;
    font-weight: 600;
}

/* ========================================
   BUTTON ENHANCEMENTS
   ======================================== */

/* Enhanced Button Styles */
.btn {
    border-radius: 5px;
    font-weight: 500;
    transition: all 0.2s ease-in-out;
    border: none;
    padding: 0.5rem 1rem;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.btn-primary {
    background: background: linear-gradient(135deg, #3b82f6, #10b981);
    border: none;
}

.btn-primary:hover {
    background: background: linear-gradient(135deg, #3b82f6, #10b981);
}

.btn-outline-primary {
    border: 1px solid #30398B;
    color: #30398B;
    background: transparent;
}

.btn-outline-primary:hover {
    background: #30398B;
    color: white;
    border-color: #30398B;
}

/* ========================================
   CARD ENHANCEMENTS
   ======================================== */

/* Enhanced Card Styles */
.card {
    border: 1px solid #e9ecef;
    border-radius: 5px;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    transition: all 0.2s ease-in-out;
}

.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.card-header {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-bottom: 1px solid #e9ecef;
    border-radius: 0rem 0rem 0 0 !important;
    padding: 1rem 1.25rem;
}

.card-title {
    color: #1e293b;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
}

.card-title .icon {
    color: #30398B;
}

/* ========================================
   SIDEBAR RESPONSIVE ENHANCEMENTS
   ======================================== */

/* Sidebar Caret Animation */
.sidebar-caret {
    transition: transform 0.2s ease-in-out;
}

.list-group-item[aria-expanded="true"] .sidebar-caret {
    transform: rotate(90deg);
}

/* Mobile Sidebar Enhancements */
.offcanvas-start {
    width: 280px !important;
}

.offcanvas-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.offcanvas-body .list-group-item {
    border-left: none;
    border-right: none;
    padding: 0.75rem 1rem;
    transition: all 0.2s ease-in-out;
}

.offcanvas-body .list-group-item:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.offcanvas-body .list-group-item.active {
    background-color: rgba(0, 123, 255, 0.1);
    color: #0066cc;
    border-left: 3px solid #0066cc;
}

.offcanvas-body .list-group-item .icon {
    flex-shrink: 0;
}

/* Desktop Sidebar Enhancements */
.tenant-sidebar {
    position: sticky;
    top: 2rem;
    height: fit-content;
}

.tenant-sidebar .list-group-item {
    border-left: none;
    border-right: none;
    padding: 0.5rem 0.75rem;
    transition: all 0.2s ease-in-out;
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    gap: 0.5rem;
}

.tenant-sidebar .sidebar-section-heading {
    padding: 0.5rem 0.75rem;
    font-size: 0.7rem;
    letter-spacing: 0.05em;
    color: #94a3b8;
}

.tenant-sidebar .sidebar-toggle {
    font-weight: 500;
}

.tenant-sidebar .list-group-item.sidebar-link {
    font-weight: 500;
}

.tenant-sidebar .list-group-item:hover {
    background-color: rgba(0, 0, 0, 0.05);
}

.tenant-sidebar .list-group-item.active {
    background-color: rgba(0, 123, 255, 0.1);
    color: #0066cc;
    border-left: 3px solid #0066cc;
}

.tenant-sidebar .list-group-item .icon {
    flex-shrink: 0;
    width: 16px;
    height: 16px;
}

.tenant-sidebar .list-group-item .label {
    flex-grow: 1;
}

.tenant-sidebar .sidebar-caret {
    flex-shrink: 0;
    margin-left: auto;
}

.tenant-sidebar .list-group-item.ps-5 {
    padding-left: 1.5rem !important;
}

.tenant-sidebar .list-group-item.ps-6 {
    padding-left: 1.75rem !important;
}

/* Collapse Animation Improvements */
.collapse {
    transition: height 0.3s ease-in-out;
}

.collapse.show {
    transition: height 0.3s ease-in-out;
}

/* ========================================
   MOBILE RESPONSIVENESS
   ======================================== */

@media (max-width: 1199.98px) {
    .tenant-sidebar {
        display: none !important;
    }

    .content {
        width: 100% !important;
        max-width: 100% !important;
    }
}

@media (max-width: 768px) {
    .page-header {
        padding: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .quick-actions-grid {
        grid-template-columns: 1fr;
    }

    .stats-card {
        margin-bottom: 1rem;
    }

    .navbar-brand-text {
        display: none;
    }

    .nav-link {
        padding: 0.5rem 0.75rem !important;
        margin: 0.125rem;
    }

    /* Mobile sidebar adjustments */
    .offcanvas-start {
        width: 260px !important;
    }

    .offcanvas-body .list-group-item {
        padding: 0.6rem 0.8rem;
        font-size: 0.9rem;
    }

    .offcanvas-body .list-group-item .icon {
        width: 14px;
        height: 14px;
    }

    .offcanvas-body .list-group-item .sidebar-caret {
        width: 12px;
        height: 12px;
    }
}

@media (max-width: 576px) {
    .offcanvas-start {
        width: 240px !important;
    }

    .offcanvas-body .list-group-item {
        padding: 0.5rem 0.6rem;
        font-size: 0.85rem;
    }

    .offcanvas-body .list-group-item .icon {
        width: 12px;
        height: 12px;
    }

    .offcanvas-body .list-group-item .sidebar-caret {
        width: 10px;
        height: 10px;
    }
}

/* ========================================
   ANIMATIONS & TRANSITIONS
   ======================================== */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* ========================================
   ACCESSIBILITY & FOCUS STATES
   ======================================== */

.btn:focus,
.nav-link:focus,
.dropdown-item:focus {
    outline: 2px solid #30398B;
    outline-offset: 2px;
}

/* ========================================
   LOADING STATES
   ======================================== */

.loading-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* ========================================
   SCROLLBAR ENHANCEMENTS
   ======================================== */

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #30398B;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #30398B;
}

/* ========================================
   PRINT STYLES
   ======================================== */

@media print {

    .navbar,
    .page-header .col-auto,
    .card-actions,
    .btn {
        display: none !important;
    }

    .page-header {
        background: white !important;
        border: 1px solid #ccc !important;
    }

    .card {
        border: 1px solid #ccc !important;
        box-shadow: none !important;
    }
}