/* Enhanced Portal Organization Styles */

.hidden {
    display: none !important;
}

/* Global Styles */
.portal-organization-management {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Statistics Cards */
.stats-card {
    border: none !important;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
    transition: all 0.3s ease;
    border-radius: 0.75rem !important;
}

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

.stats-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.stats-number {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 0.25rem;
}

.stats-label {
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0;
}

/* Organization Cards */
.organization-card {
    border: none !important;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    border-radius: 1rem !important;
    overflow: hidden;
}

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

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

.card .card-header {
    background:  #343a40  ;
    border-bottom: 1px solid #dee2e6 !important;
    padding: 1.25rem;
    color: #f8f9fa ;
}

.organization-avatar {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}

.organization-card .card-body {
    padding: 1.5rem;
}

.organization-card .card-footer {
    background-color: #fff !important;
    border-top: 1px solid #f1f3f4 !important;
    padding: 1rem 1.5rem;
}

/* Quick Stats in Cards */
.stat-item {
    text-align: center;
}

.stat-item .stat-number {
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 0.25rem;
}

.stat-item .stat-label {
    font-size: 0.75rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 500;
}

/* Contact Information */
.contact-info {
    border-top: 1px solid #f1f3f4;
    padding-top: 1rem;
    margin-top: 1rem;
}

.contact-info .fa {
    width: 16px;
    text-align: center;
}

/* Search and Filter Bar */
.search-filter-bar {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

.search-filter-bar .input-group-text {
    background-color: #e9ecef;
    border-color: #343a40;
}

/* Empty State */
.empty-state {
    max-width: 400px;
    margin: 0 auto;
    padding: 3rem 1rem;
}

.empty-state .fa {
    opacity: 0.3;
}

/* Button Enhancements */
.btn {
    border-radius: 0.5rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
    transition: all 0.2s ease;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: #0056b3;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 123, 255, 0.3);
}

.btn-primary:hover {
    background:  #0056b3 ;
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.4);
}

.btn-success {
    background: linear-gradient(45deg, #1e7e34, #1e7e34);
    border: none;
    box-shadow: 0 2px 4px rgba(40, 167, 69, 0.3);
}

.btn-success:hover {
    background: linear-gradient(45deg, #1e7e34, #155724);
    box-shadow: 0 4px 8px rgba(40, 167, 69, 0.4);
}

/* Modal Enhancements */
.modal-content {
    border: none;
    border-radius: 1rem;
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.175);
}

.modal-header {
    background-color: #343a40;
    border-bottom: 1px solid #dee2e6;
    border-radius: 1rem 1rem 0 0;
    padding: 1.5rem;
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    color: #f8f9fa; 
    /* #2c3e50   #343a40 */
}

.modal-body {
    padding: 2rem;
    background-color: #ffffff;
}

.modal-footer {
    background-color: #f8f9fa;
    border-top: 1px solid #dee2e6;
    border-radius: 0 0 1rem 1rem;
    padding: 1rem 2rem;
}

/* Form Enhancements */
.form-control, .form-select {
    border-radius: 0.5rem;
    border: 1px solid #e0e0e0;
    padding: 0.75rem 1rem;
    transition: all 0.2s ease;
}

.form-control:focus, .form-select:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.form-label {
    font-weight: 600;
    color: #495057;
    margin-bottom: 0.5rem;
}

/* Badge Enhancements */
.badge {
    padding: 0.5rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 0.5rem;
}

/* Table Enhancements */
.table {
    border-radius: 0.5rem;
    overflow: hidden;
}

.table thead th {
    background-color: #343a40;
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
    color: #495057;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    padding: 1rem;
}

.table tbody td {
    padding: 1rem;
    vertical-align: middle;
}

.table-hover tbody tr:hover {
    /* background-color: rgba(0, 123, 255, 0.05); */
}

/* User Avatar */
.user-avatar {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Navigation Tabs */
.nav-tabs {
    border-bottom: 2px solid #e9ecef;
}

.nav-tabs .nav-link {
    border: none;
    color: #6c757d;
    font-weight: 600;
    padding: 1rem 1.5rem;
    margin-bottom: -2px;
    border-radius: 0.5rem 0.5rem 0 0;
    transition: all 0.2s ease;
}

.nav-tabs .nav-link:hover {
    color: #007bff;
    background-color: #f8f9fa;
    border-color: transparent;
}

.nav-tabs .nav-link.active {
    color: #007bff;
    background-color: #fff;
    border-bottom: 2px solid #007bff;
}

/* Progress Bar */
.progress {
    height: 8px;
    border-radius: 4px;
    background-color: #e9ecef;
}

.progress-bar {
    border-radius: 4px;
    background: linear-gradient(45deg, #007bff, #0056b3);
}

/* Info Groups for Detail View */
.info-group {
    margin-bottom: 1.5rem;
}

.info-group .form-label {
    font-size: 0.875rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.info-group .info-value {
    font-size: 1rem;
    font-weight: 500;
    color: #495057;
    line-height: 1.5;
}

/* Breadcrumb */
.breadcrumb {
    background-color: transparent;
    padding: 0;
    margin-bottom: 2rem;
}

.breadcrumb-item {
    font-size: 0.875rem;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    color: #6c757d;
    font-weight: 600;
}

.breadcrumb-item.active {
    color: #007bff;
    font-weight: 600;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .stats-number {
        font-size: 2rem;
    }
    
    .organization-card .card-body {
        padding: 1rem;
    }
    
    .organization-card .card-footer {
        padding: 0.75rem 1rem;
    }
    
    .stat-item .stat-number {
        font-size: 1.5rem;
    }
    
    .modal-body {
        padding: 1.5rem;
    }
    
    .nav-tabs .nav-link {
        padding: 0.75rem 1rem;
        font-size: 0.875rem;
    }
}

@media (max-width: 576px) {
    .stats-card .card-body {
        padding: 1rem;
    }
    
    .stats-number {
        font-size: 1.75rem;
    }
    
    .organization-avatar {
        width: 40px;
        height: 40px;
    }
    
    .btn-group .btn {
        margin-bottom: 0.25rem;
    }
}

/* Animation Classes */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate3d(0, 30px, 0);
    }
    to {
        opacity: 1;
        transform: translate3d(0, 0, 0);
    }
}

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

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.loading::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .stats-card {
        background-color: #dedede;
        color: #e2e8f0;
    }
    
    .organization-card {
        background-color: #dedede;
        color: #e2e8f0;
    }
    
    .organization-card .card-header {
        background: linear-gradient(135deg, #dedede 0%, #dedede 100%) !important;
        border-bottom-color: #4a5568 !important;
    }
    
    /* .modal-content {
        background-color: #dedede;
        color: #e2e8f0;
    } */
    
    /* .modal-header {
        background: linear-gradient(135deg, #dedede 0%, #dedede 100%);
        border-bottom-color: #4a5568;
    } */
    
    .form-control, .form-select {
        background-color: #ffffff;
        border-color: #4a5568;
        color: #343a40;
    }
    
    .table {
        color: #212529;
    }
    
    .table thead th {
        background-color: #4a5568;
        border-bottom-color: #4a5568;
        color: #e2e8f0;
    }
}

/* Print Styles */
@media print {
    .btn, .modal, .stats-card:hover, .organization-card:hover {
        transform: none !important;
        box-shadow: none !important;
    }
    
    .organization-card .card-footer {
        display: none;
    }
}