/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #333;
    line-height: 1.6;
}

/* Login Screen */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    padding: 40px;
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.login-header {
    margin-bottom: 30px;
}

.login-header i {
    font-size: 3rem;
    color: #667eea;
    margin-bottom: 15px;
}

.login-header h1 {
    color: #333;
    margin-bottom: 10px;
    font-size: 2rem;
}

.login-header p {
    color: #666;
    font-size: 1rem;
}

.login-form {
    text-align: left;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    width: 100%;
    justify-content: center;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
}

.btn-success {
    background: #28a745;
    color: white;
}

.btn-success:hover {
    background: #218838;
}

.login-footer {
    margin-top: 20px;
    text-align: center;
}

.login-footer a {
    color: #667eea;
    text-decoration: none;
}

.login-footer a:hover {
    text-decoration: underline;
}

/* Admin Panel Layout */
.admin-panel {
    display: flex;
    min-height: 100vh;
    background: #f8f9fa;
}

/* Sidebar */
.sidebar {
    width: 250px;
    background: linear-gradient(180deg, #2c3e50 0%, #34495e 100%);
    color: white;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease;
}

.sidebar-header {
    padding: 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-header i {
    font-size: 2rem;
    margin-bottom: 10px;
    color: #667eea;
}

.sidebar-header h2 {
    font-size: 1.2rem;
    font-weight: 600;
}

.sidebar-menu {
    flex: 1;
    list-style: none;
    padding: 20px 0;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    border-left: 3px solid transparent;
}

.menu-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

.menu-item.active {
    background: rgba(102, 126, 234, 0.2);
    border-left-color: #667eea;
}

.menu-item i {
    font-size: 1.1rem;
    width: 20px;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Main Content */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Header */
.header {
    background: white;
    padding: 20px 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.sidebar-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: #333;
}

.header h1 {
    color: #333;
    font-size: 1.8rem;
    font-weight: 600;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #666;
}

.user-info i {
    font-size: 1.5rem;
}

/* Content */
.content {
    flex: 1;
    padding: 30px;
    overflow-y: auto;
}

.section {
    display: none;
}

.section.active {
    display: block;
}

/* Dashboard */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.stat-content h3 {
    font-size: 2rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 5px;
}

.stat-content p {
    color: #666;
    font-size: 0.9rem;
}

/* Cards */
.card {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    margin-bottom: 20px;
}

.card-header {
    padding: 20px 25px;
    border-bottom: 1px solid #e9ecef;
}

.card-header h3 {
    color: #333;
    font-size: 1.2rem;
    font-weight: 600;
}

.card-body {
    padding: 25px;
}

/* Section Headers */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
}

.section-header h2 {
    color: #333;
    font-size: 1.8rem;
    font-weight: 600;
}

/* Filters */
.filters {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.search-input, .filter-select {
    padding: 10px 15px;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    font-size: 0.9rem;
    transition: border-color 0.3s ease;
}

.search-input {
    flex: 1;
    min-width: 200px;
}

.filter-select {
    min-width: 150px;
}

.search-input:focus, .filter-select:focus {
    outline: none;
    border-color: #667eea;
}

/* Tables */
.table-container {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    background: #f8f9fa;
    padding: 15px 20px;
    text-align: left;
    font-weight: 600;
    color: #333;
    border-bottom: 2px solid #e9ecef;
}

.data-table td {
    padding: 15px 20px;
    border-bottom: 1px solid #e9ecef;
    vertical-align: middle;
}

.data-table tr:hover {
    background: #f8f9fa;
}

.text-center {
    text-align: center;
}

/* Status Badges */
.status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.status-success {
    background: #d4edda;
    color: #155724;
}

.status-warning {
    background: #fff3cd;
    color: #856404;
}

.status-danger {
    background: #f8d7da;
    color: #721c24;
}

.status-info {
    background: #d1ecf1;
    color: #0c5460;
}

/* Upload Section */
.upload-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.upload-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

.upload-card h3 {
    color: #333;
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.upload-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Category Tabs */
.category-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.tab-btn {
    padding: 10px 20px;
    border: 2px solid #4a5568;
    background: transparent;
    color: #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.tab-btn:hover {
    background: #4a5568;
    color: #ffffff;
}

.tab-btn.active {
    background: #667eea;
    border-color: #667eea;
    color: #ffffff;
}

.category-content {
    display: none;
}

.category-content.active {
    display: block;
}

/* Modals */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal {
    background: white;
    border-radius: 15px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h3 {
    color: #333;
    font-size: 1.3rem;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
}

.modal-body {
    padding: 25px;
}

.modal-footer {
    padding: 20px 25px;
    border-top: 1px solid #e9ecef;
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loading-spinner {
    text-align: center;
    color: #667eea;
}

.loading-spinner i {
    font-size: 3rem;
    margin-bottom: 15px;
}

.loading-spinner p {
    font-size: 1.1rem;
    font-weight: 500;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
}

.toast {
    background: white;
    border-radius: 10px;
    padding: 15px 20px;
    margin-bottom: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 300px;
    animation: slideIn 0.3s ease;
}

.toast.success {
    border-left: 4px solid #28a745;
}

.toast.error {
    border-left: 4px solid #dc3545;
}

.toast.warning {
    border-left: 4px solid #ffc107;
}

.toast.info {
    border-left: 4px solid #17a2b8;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Legal Documents Styles */
.legal-documents-container {
    padding: 20px 0;
}

.legal-documents-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.legal-document-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 24px;
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
}

.legal-document-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.document-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e1e5e9;
}

.document-header h4 {
    color: #2c3e50;
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.document-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.document-info {
    margin-bottom: 16px;
}

.document-info p {
    margin-bottom: 8px;
    color: #555;
    font-size: 0.9rem;
}

.document-info a {
    color: #3498db;
    text-decoration: none;
}

.document-info a:hover {
    text-decoration: underline;
}

.document-preview h5 {
    color: #34495e;
    margin-bottom: 8px;
    font-size: 1rem;
    font-weight: 600;
}

.content-preview {
    background: #f8f9fa;
    padding: 12px;
    border-radius: 6px;
    border-left: 4px solid #3498db;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.5;
    max-height: 100px;
    overflow: hidden;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
    border-radius: 6px;
}

.btn-outline {
    background: transparent;
    border: 1px solid #3498db;
    color: #3498db;
}

.btn-outline:hover {
    background: #3498db;
    color: white;
}

/* Responsive Legal Documents */
@media (max-width: 768px) {
    .document-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .document-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    .legal-document-card {
        padding: 16px;
    }
}

/* Activity List */
.activity-list {
    max-height: 300px;
    overflow-y: auto;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px 0;
    border-bottom: 1px solid #e9ecef;
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: white;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.activity-content {
    flex: 1;
}

.activity-content h4 {
    color: #333;
    font-size: 0.9rem;
    margin-bottom: 2px;
}

.activity-content p {
    color: #666;
    font-size: 0.8rem;
}

/* Enhanced Mobile Responsive Design */
@media (max-width: 1024px) {
    .sidebar {
        width: 220px;
    }
    
    .content {
        padding: 25px;
    }
    
    .header {
        padding: 15px 25px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}

@media (max-width: 768px) {
    /* Sidebar Mobile Behavior */
    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 280px;
        transform: translateX(-100%);
        z-index: 1000;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    }

    .sidebar.open {
        transform: translateX(0);
    }
    
    /* Sidebar overlay for mobile */
    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 999;
        display: none;
    }
    
    .sidebar-overlay.active {
        display: block;
    }

    .sidebar-toggle {
        display: block;
        background: none;
        border: none;
        font-size: 1.5rem;
        cursor: pointer;
        color: #333;
        padding: 8px;
        border-radius: 4px;
        transition: background-color 0.2s;
    }
    
    .sidebar-toggle:hover {
        background-color: #f0f0f0;
    }

    /* Main content adjustments */
    .main-content {
        width: 100%;
    }
    
    .content {
        padding: 15px;
    }
    
    .header {
        padding: 15px 20px;
        position: sticky;
        top: 0;
        z-index: 100;
    }

    /* Dashboard responsive */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .stat-card {
        padding: 20px;
    }
    
    .stat-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .stat-content h3 {
        font-size: 1.5rem;
    }

    /* Filters responsive */
    .filters {
        flex-direction: column;
        gap: 10px;
    }

    .search-input, .filter-select {
        width: 100%;
        min-width: auto;
    }

    /* Section headers */
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .section-header h2 {
        font-size: 1.5rem;
    }

    /* Tables responsive */
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .data-table {
        min-width: 600px;
    }
    
    .data-table th,
    .data-table td {
        padding: 12px 15px;
        font-size: 0.9rem;
    }

    /* Cards responsive */
    .card {
        margin-bottom: 15px;
    }
    
    .card-header,
    .card-body {
        padding: 20px;
    }
    
    .card-header h3 {
        font-size: 1.1rem;
    }

    /* Upload section responsive */
    .upload-container {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .upload-card {
        padding: 20px;
    }

    /* Modals responsive */
    .modal {
        width: 95%;
        margin: 10px;
        max-height: 95vh;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 20px;
    }
    
    .modal-footer {
        flex-direction: column;
        gap: 10px;
    }
    
    .modal-footer .btn {
        width: 100%;
    }

    /* Toast notifications mobile */
    .toast-container {
        top: 10px;
        right: 10px;
        left: 10px;
    }
    
    .toast {
        min-width: auto;
        width: 100%;
    }

    /* Login screen mobile */
    .login-container {
        padding: 15px;
    }
    
    .login-card {
        padding: 30px 25px;
        border-radius: 15px;
    }
    
    .login-header h1 {
        font-size: 1.8rem;
    }
    
    .login-header i {
        font-size: 2.5rem;
    }

    /* Category tabs mobile */
    .category-tabs {
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .tab-btn {
        padding: 8px 16px;
        font-size: 0.9rem;
    }

    /* Activity list mobile */
    .activity-item {
        padding: 12px 0;
    }
    
    .activity-icon {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }
    
    .activity-content h4 {
        font-size: 0.85rem;
    }
    
    .activity-content p {
        font-size: 0.75rem;
    }

    /* User management mobile */
    .user-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .user-avatar,
    .user-avatar-placeholder {
        width: 35px;
        height: 35px;
    }
    
    .user-name {
        font-size: 0.9rem;
    }
    
    .user-id {
        font-size: 0.75rem;
    }

    /* Empty state mobile */
    .empty-state {
        padding: 40px 15px;
    }
    
    .empty-icon {
        font-size: 48px;
    }
    
    .empty-state h3 {
        font-size: 20px;
    }
    
    .empty-state p {
        font-size: 14px;
    }
    
    .empty-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .empty-actions .btn {
        width: 100%;
        max-width: 200px;
    }

    /* Form controls mobile */
    .form-control {
        padding: 10px 14px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    .btn {
        padding: 12px 20px;
        font-size: 16px;
    }

    /* Input groups mobile */
    .input-group {
        flex-direction: column;
    }
    
    .input-group input {
        border-radius: 8px;
        border-right: 1px solid #ddd;
        margin-bottom: 8px;
    }
    
    .input-group button {
        border-radius: 8px;
        border-left: 1px solid #ddd;
        width: 100%;
    }
}

@media (max-width: 480px) {
    /* Extra small screens */
    .content {
        padding: 10px;
    }
    
    .header {
        padding: 12px 15px;
    }
    
    .header h1 {
        font-size: 1.5rem;
    }
    
    .sidebar {
        width: 260px;
    }
    
    .login-card {
        padding: 25px 20px;
    }
    
    .login-header h1 {
        font-size: 1.6rem;
    }
    
    .login-header i {
        font-size: 2rem;
    }
    
    .stat-card {
        padding: 15px;
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .stat-icon {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
    
    .stat-content h3 {
        font-size: 1.3rem;
    }
    
    .card-header,
    .card-body {
        padding: 15px;
    }
    
    .modal {
        width: 98%;
        margin: 5px;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 15px;
    }
    
    .data-table th,
    .data-table td {
        padding: 10px 12px;
        font-size: 0.85rem;
    }
    
    .upload-card {
        padding: 15px;
    }
    
    .tab-btn {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
    
    .empty-state {
        padding: 30px 10px;
    }
    
    .empty-icon {
        font-size: 40px;
    }
    
    .empty-state h3 {
        font-size: 18px;
    }
    
    .empty-state p {
        font-size: 13px;
    }
}

/* Landscape mobile orientation */
@media (max-width: 768px) and (orientation: landscape) {
    .login-container {
        padding: 10px;
    }
    
    .login-card {
        padding: 20px;
        max-width: 350px;
    }
    
    .modal {
        max-height: 90vh;
    }
    
    .sidebar {
        width: 250px;
    }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    .menu-item {
        padding: 18px 20px;
    }
    
    .btn {
        padding: 14px 24px;
        min-height: 44px;
    }
    
    .sidebar-toggle {
        padding: 12px;
        min-height: 44px;
        min-width: 44px;
    }
    
    .modal-close {
        padding: 12px;
        min-height: 44px;
        min-width: 44px;
    }
    
    .tab-btn {
        padding: 12px 20px;
        min-height: 44px;
    }
    
    .form-control {
        padding: 12px 16px;
        min-height: 44px;
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .sidebar-header i,
    .login-header i {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
}

/* Legal Documents Styles */
.legal-documents-container {
    padding: 20px 0;
}

.legal-documents-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.legal-document-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 24px;
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
}

.legal-document-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.document-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e1e5e9;
}

.document-header h4 {
    color: #2c3e50;
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.document-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.document-info {
    margin-bottom: 16px;
}

.document-info p {
    margin-bottom: 8px;
    color: #555;
    font-size: 0.9rem;
}

.document-info a {
    color: #3498db;
    text-decoration: none;
}

.document-info a:hover {
    text-decoration: underline;
}

.document-preview h5 {
    color: #34495e;
    margin-bottom: 8px;
    font-size: 1rem;
    font-weight: 600;
}

.content-preview {
    background: #f8f9fa;
    padding: 12px;
    border-radius: 6px;
    border-left: 4px solid #3498db;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.5;
    max-height: 100px;
    overflow: hidden;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
    border-radius: 6px;
}

.btn-outline {
    background: transparent;
    border: 1px solid #3498db;
    color: #3498db;
}

.btn-outline:hover {
    background: #3498db;
    color: white;
}

/* Responsive Legal Documents */
@media (max-width: 768px) {
    .document-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .document-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    .legal-document-card {
        padding: 16px;
    }
}

/* Utility Classes */
.hidden {
    display: none !important;
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-5 { margin-bottom: 3rem; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.mt-5 { margin-top: 3rem; }

/* Input Group Styles for Upload Buttons */
.input-group {
    display: flex;
    align-items: stretch;
    width: 100%;
}

.input-group input {
    flex: 1;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    border-right: none;
}

.input-group button {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    border-left: 1px solid #ddd;
    white-space: nowrap;
    padding: 8px 12px;
    font-size: 0.9rem;
    min-width: 120px;
}

.input-group button:hover {
    background-color: #5a6268;
    border-color: #545b62;
}

.input-group button i {
    margin-right: 5px;
}

/* Responsive input groups */
@media (max-width: 768px) {
    .input-group {
        flex-direction: column;
    }
    
    .input-group input {
        border-radius: 4px;
        border-right: 1px solid #ddd;
        margin-bottom: 5px;
    }
    
    .input-group button {
        border-radius: 4px;
        border-left: 1px solid #ddd;
        width: 100%;
    }
}

/* Legal Documents Styles */
.legal-documents-container {
    padding: 20px 0;
}

.legal-documents-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.legal-document-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 24px;
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
}

.legal-document-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.document-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e1e5e9;
}

.document-header h4 {
    color: #2c3e50;
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.document-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.document-info {
    margin-bottom: 16px;
}

.document-info p {
    margin-bottom: 8px;
    color: #555;
    font-size: 0.9rem;
}

.document-info a {
    color: #3498db;
    text-decoration: none;
}

.document-info a:hover {
    text-decoration: underline;
}

.document-preview h5 {
    color: #34495e;
    margin-bottom: 8px;
    font-size: 1rem;
    font-weight: 600;
}

.content-preview {
    background: #f8f9fa;
    padding: 12px;
    border-radius: 6px;
    border-left: 4px solid #3498db;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.5;
    max-height: 100px;
    overflow: hidden;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
    border-radius: 6px;
}

.btn-outline {
    background: transparent;
    border: 1px solid #3498db;
    color: #3498db;
}

.btn-outline:hover {
    background: #3498db;
    color: white;
}

/* Responsive Legal Documents */
@media (max-width: 768px) {
    .document-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .document-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    .legal-document-card {
        padding: 16px;
    }
}

/* User Management Styles */
.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.user-avatar-placeholder {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
}

.user-name {
    font-weight: 500;
    color: #333;
}

.user-id {
    font-size: 12px;
    color: #666;
    font-family: monospace;
}

.badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
}

.badge-primary {
    background: #007bff;
    color: white;
}

.badge-secondary {
    background: #6c757d;
    color: white;
}

.badge-success {
    background: #28a745;
    color: white;
}

.badge-danger {
    background: #dc3545;
    color: white;
}

.badge-warning {
    background: #ffc107;
    color: #212529;
}

/* Empty State Styles */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.empty-icon {
    font-size: 64px;
    color: #ddd;
    margin-bottom: 20px;
}

.empty-state h3 {
    color: #333;
    margin-bottom: 10px;
    font-size: 24px;
}

.empty-state p {
    color: #666;
    margin-bottom: 30px;
    font-size: 16px;
    line-height: 1.5;
}

.empty-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Edit User Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Legal Documents Styles */
.legal-documents-container {
    padding: 20px 0;
}

.legal-documents-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.legal-document-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 24px;
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
}

.legal-document-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.document-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e1e5e9;
}

.document-header h4 {
    color: #2c3e50;
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.document-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.document-info {
    margin-bottom: 16px;
}

.document-info p {
    margin-bottom: 8px;
    color: #555;
    font-size: 0.9rem;
}

.document-info a {
    color: #3498db;
    text-decoration: none;
}

.document-info a:hover {
    text-decoration: underline;
}

.document-preview h5 {
    color: #34495e;
    margin-bottom: 8px;
    font-size: 1rem;
    font-weight: 600;
}

.content-preview {
    background: #f8f9fa;
    padding: 12px;
    border-radius: 6px;
    border-left: 4px solid #3498db;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.5;
    max-height: 100px;
    overflow: hidden;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
    border-radius: 6px;
}

.btn-outline {
    background: transparent;
    border: 1px solid #3498db;
    color: #3498db;
}

.btn-outline:hover {
    background: #3498db;
    color: white;
}

/* Responsive Legal Documents */
@media (max-width: 768px) {
    .document-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .document-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    .legal-document-card {
        padding: 16px;
    }
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px 12px 0 0;
}

.modal-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.modal-body {
    padding: 24px;
}

.modal-footer {
    padding: 20px 24px;
    border-top: 1px solid #e0e0e0;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    background: #f8f9fa;
    border-radius: 0 0 12px 12px;
}

.form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.form-control {
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
    background: white;
}

.form-control:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-control:read-only {
    background: #f8f9fa;
    color: #666;
    cursor: not-allowed;
}

.form-control select {
    cursor: pointer;
}

/* Responsive modal */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        margin: 20px;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 16px;
    }
    
    .modal-footer {
        flex-direction: column;
    }
    
    .modal-footer .btn {
        width: 100%;
    }
}

/* Legal Documents Styles */
.legal-documents-container {
    padding: 20px 0;
}

.legal-documents-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.legal-document-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 24px;
    border: 1px solid #e1e5e9;
    transition: all 0.3s ease;
}

.legal-document-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.document-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e1e5e9;
}

.document-header h4 {
    color: #2c3e50;
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.document-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.document-info {
    margin-bottom: 16px;
}

.document-info p {
    margin-bottom: 8px;
    color: #555;
    font-size: 0.9rem;
}

.document-info a {
    color: #3498db;
    text-decoration: none;
}

.document-info a:hover {
    text-decoration: underline;
}

.document-preview h5 {
    color: #34495e;
    margin-bottom: 8px;
    font-size: 1rem;
    font-weight: 600;
}

.content-preview {
    background: #f8f9fa;
    padding: 12px;
    border-radius: 6px;
    border-left: 4px solid #3498db;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.5;
    max-height: 100px;
    overflow: hidden;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
    border-radius: 6px;
}

.btn-outline {
    background: transparent;
    border: 1px solid #3498db;
    color: #3498db;
}

.btn-outline:hover {
    background: #3498db;
    color: white;
}

/* Responsive Legal Documents */
@media (max-width: 768px) {
    .document-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .document-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    .legal-document-card {
        padding: 16px;
    }
}
