/* Base Styles - Reset, Typography, Layout */

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

html,
body {
    height: 100vh;
    min-height: 0;
    overflow: hidden;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #181a20 !important;
    color: #e0e0e0 !important;
    line-height: 1.6;
}

/* Admin Container */
.admin-container {
    height: 100vh;
    min-height: 0;
    display: flex;
}

/* Main Content */
.main-content {
    flex: 1 1 0%;
    display: flex;
    flex-direction: column;
    height: 100vh;
    min-height: 0;
    transition: margin-left 0.3s cubic-bezier(.4, 2, .6, 1);
    background: #181a20 !important;
    padding-bottom: 0;
    border-radius: 0 !important;
}

.sidebar~.main-content {
    margin-left: 70px;
}

/* Header kaldırıldı - Sidebar'da logout var */

/* Content */
.content {
    flex: 1 1 0%;
    display: flex;
    flex-direction: column;
    height: 100vh;
    min-height: 0;
}

.content-section {
    display: none;
    flex: 1;
    height: 100vh;
    /* Header kaldırıldı */
    overflow: hidden;
    background: #1a1d23;
    color: #e0e0e0;
    padding: 20px;
}

.content-section.active {
    display: block !important;
    flex: 1;
    height: 100vh;
    /* Header kaldırıldı */
    overflow-y: auto;
    background: #1a1d23;
    color: #e0e0e0;
    padding: 20px;
}

/* Dark theme scrollbar for content sections */
.content-section::-webkit-scrollbar {
    width: 8px;
}

.content-section::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.content-section::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

.content-section::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

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

.section-header h2 {
    font-size: 28px;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

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

.btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

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

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

/* Table Container */
.table-container {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    background: #23272f !important;
    border-radius: 4px !important;
    border: 2px dashed #333 !important;
    color: #e0e0e0 !important;
}

/* Dark theme scrollbar for table containers */
.table-container::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.table-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

.table-container::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

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

.data-table th,
.data-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #34495e;
    color: #e0e0e0;
}

.data-table th {
    background: #2c3e50;
    font-weight: 600;
    color: #ffffff;
}

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

/* Empty State */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
    color: #7f8c8d;
    height: 100%;
    width: 100%;
    box-sizing: border-box;
    background: #23272f;
    border-radius: 12px;
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 16px;
    color: #3498db;
}

.empty-state p {
    margin: 0 0 16px 0;
    font-size: 14px;
}

/* Error State */
.error-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
    color: #7f8c8d;
    height: 100%;
    width: 100%;
    box-sizing: border-box;
    background: #23272f;
    border-radius: 12px;
}

.error-state i {
    font-size: 48px;
    margin-bottom: 16px;
    color: #e74c3c;
}

.error-state p {
    margin: 0 0 16px 0;
    font-size: 14px;
}

.error-state button {
    padding: 8px 16px;
    background: #3498db;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s ease;
}

.error-state button:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

/* Bot Users Section - Dark Theme */
#bot-users {
    background: #151821 !important;
    color: #e0e0e0 !important;
    padding: 20px !important;
    border: none !important;
}

#bot-users * {
    color: #e0e0e0 !important;
}

#bot-users .section-header {
    background: linear-gradient(135deg, rgba(26, 29, 35, 0.8), rgba(44, 62, 80, 0.4)) !important;
    border: 1px solid #2c3e50 !important;
    border-radius: 16px;
    padding: 25px 30px;
    margin-bottom: 30px;
    backdrop-filter: blur(15px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

#bot-users .btn-primary {
    background: linear-gradient(135deg, #3498db, #2980b9) !important;
    color: #ffffff !important;
    border: none !important;
}

#bot-users .btn-secondary {
    background: #34495e !important;
    color: #e0e0e0 !important;
    border: 1px solid #2c3e50 !important;
}

/* Header Actions - Enhanced Dark Theme */
.header-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

#bot-users .header-actions {
    background: rgba(30, 35, 40, 0.4) !important;
    padding: 15px 20px !important;
    border-radius: 16px;
    border: 1px solid #2c3e50;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

#bot-users .header-actions .btn {
    background: linear-gradient(135deg, #34495e, #2c3e50) !important;
    color: #e0e0e0 !important;
    border: 1px solid #34495e !important;
    padding: 12px 20px;
    border-radius: 12px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    font-weight: 500;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

#bot-users .header-actions .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

#bot-users .header-actions .btn:hover::before {
    left: 100%;
}

#bot-users .header-actions .btn:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

#bot-users .header-actions .btn-warning {
    background: linear-gradient(135deg, #f39c12, #e67e22) !important;
    color: #ffffff !important;
    border-color: #f39c12 !important;
}

#bot-users .header-actions .btn-warning:hover {
    background: linear-gradient(135deg, #e67e22, #d35400) !important;
    box-shadow: 0 8px 25px rgba(243, 156, 18, 0.4);
}

#bot-users .header-actions .btn-success {
    background: linear-gradient(135deg, #27ae60, #2ecc71) !important;
    color: #ffffff !important;
    border-color: #27ae60 !important;
}

#bot-users .header-actions .btn-success:hover {
    background: linear-gradient(135deg, #229954, #27ae60) !important;
    box-shadow: 0 8px 25px rgba(39, 174, 96, 0.4);
}

#bot-users .header-actions .btn-info {
    background: linear-gradient(135deg, #3498db, #2980b9) !important;
    color: #ffffff !important;
    border-color: #3498db !important;
}

#bot-users .header-actions .btn-info:hover {
    background: linear-gradient(135deg, #2980b9, #1f4e79) !important;
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.4);
}

/* Bot Stat Items - Enhanced Dark Theme */
#bot-users .stat-item {
    background: linear-gradient(135deg, #1a1f24, #2c3e50) !important;
    border-radius: 16px;
    padding: 25px 20px;
    text-align: center;
    border: 1px solid #34495e !important;
    box-shadow:
        0 8px 25px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

#bot-users .stat-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3498db, #9b59b6, #e74c3c, #f39c12);
    border-radius: 16px 16px 0 0;
}

#bot-users .stat-item:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.6),
        0 0 20px rgba(52, 152, 219, 0.3) !important;
    border-color: #3498db !important;
    background: linear-gradient(135deg, #1e2429, #34495e) !important;
}

#bot-users .stat-item .stat-number {
    display: block;
    font-size: 2.8rem;
    font-weight: 700;
    color: #ffffff !important;
    margin-bottom: 12px;
    text-shadow:
        0 2px 4px rgba(0, 0, 0, 0.5),
        0 0 10px rgba(52, 152, 219, 0.3);
    background: linear-gradient(135deg, #3498db, #74b9ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

#bot-users .stat-item .stat-label {
    font-size: 0.85rem;
    color: #bdc3c7 !important;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

#bot-users .section-header h2 {
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Bot Stats Cards - Enhanced Dark Theme */
.bot-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
    padding: 15px;
    background: rgba(30, 35, 40, 0.6) !important;
    border-radius: 16px;
    border: 1px solid #2c3e50;
    backdrop-filter: blur(10px);
}

.bot-stat-card {
    background: linear-gradient(135deg, #1a1f24, #2c3e50) !important;
    border-radius: 16px;
    padding: 25px 20px;
    text-align: center;
    border: 1px solid #34495e !important;
    box-shadow:
        0 8px 25px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.bot-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3498db, #9b59b6, #e74c3c, #f39c12);
    border-radius: 16px 16px 0 0;
}

.bot-stat-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow:
        0 15px 35px rgba(0, 0, 0, 0.6),
        0 0 20px rgba(52, 152, 219, 0.3) !important;
    border-color: #3498db !important;
    background: linear-gradient(135deg, #1e2429, #34495e) !important;
}

.bot-stat-card .stat-number {
    display: block;
    font-size: 2.8rem;
    font-weight: 700;
    color: #ffffff !important;
    margin-bottom: 12px;
    text-shadow:
        0 2px 4px rgba(0, 0, 0, 0.5),
        0 0 10px rgba(52, 152, 219, 0.3);
    background: linear-gradient(135deg, #3498db, #74b9ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bot-stat-card .stat-label {
    font-size: 0.85rem;
    color: #bdc3c7 !important;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

/* Bot Filters - Enhanced Dark Theme */
.bot-filters {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
    padding: 20px;
    background: linear-gradient(135deg, rgba(26, 29, 35, 0.8), rgba(44, 62, 80, 0.4)) !important;
    border-radius: 16px;
    border: 1px solid #2c3e50;
    backdrop-filter: blur(15px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.bot-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.filter-btn {
    background: linear-gradient(135deg, #34495e, #2c3e50) !important;
    color: #e0e0e0 !important;
    border: 1px solid #34495e !important;
    padding: 12px 18px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 500;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.filter-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.filter-btn:hover::before {
    left: 100%;
}

.filter-btn:hover {
    background: linear-gradient(135deg, #3498db, #2980b9) !important;
    border-color: #3498db !important;
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.4);
    color: #ffffff !important;
}

.filter-btn.active {
    background: linear-gradient(135deg, #3498db, #2980b9) !important;
    border-color: #3498db !important;
    box-shadow:
        0 6px 20px rgba(52, 152, 219, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    color: #ffffff !important;
    transform: translateY(-2px);
}

.filter-btn i {
    transition: transform 0.3s ease;
}

.filter-btn:hover i,
.filter-btn.active i {
    transform: scale(1.1);
}

.search-box {
    position: relative;
    max-width: 320px;
    min-width: 250px;
}

.search-box input {
    background: linear-gradient(135deg, #2c3e50, #34495e) !important;
    border: 1px solid #34495e !important;
    color: #e0e0e0 !important;
    padding: 14px 45px 14px 18px;
    border-radius: 12px;
    width: 100%;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow:
        inset 0 2px 4px rgba(0, 0, 0, 0.2),
        0 2px 8px rgba(0, 0, 0, 0.1);
}

.search-box input::placeholder {
    color: #7f8c8d !important;
    font-weight: 400;
}

.search-box input:focus {
    outline: none !important;
    border-color: #3498db !important;
    background: linear-gradient(135deg, #34495e, #3498db) !important;
    box-shadow:
        0 0 0 3px rgba(52, 152, 219, 0.2),
        inset 0 2px 4px rgba(0, 0, 0, 0.2),
        0 4px 15px rgba(52, 152, 219, 0.3) !important;
    transform: translateY(-1px);
}

.search-box i {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #7f8c8d !important;
    font-size: 16px;
    transition: all 0.3s ease;
}

.search-box input:focus+i {
    color: #3498db !important;
    transform: translateY(-50%) scale(1.1);
}

/* Bot Container */
#bot-users-container {
    background: #1e2328 !important;
    border-radius: 12px;
    min-height: 400px;
    border: 1px solid #2c3e50 !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5) !important;
}

#bot-users-container * {
    background-color: transparent !important;
}

#bot-users-container .loading-state,
#bot-users-container .empty-state,
#bot-users-container .error-state {
    background: #1e2328 !important;
    color: #7f8c8d !important;
}

/* Bot Cards Grid */
.bot-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px;
}

/* Bot Card */
.bot-card {
    background: linear-gradient(145deg, #1e2328, #2c3e50) !important;
    border-radius: 12px;
    padding: 20px;
    border: 1px solid #2c3e50 !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4) !important;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    color: #e0e0e0 !important;
}

.bot-card * {
    color: inherit !important;
    background: transparent !important;
}

.bot-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.6) !important;
    border-color: #3498db !important;
    background: linear-gradient(145deg, #252a32, #34495e) !important;
}

.bot-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #3498db, #9b59b6, #e74c3c);
}

/* Pool badge visibility + style (override global transparent backgrounds) */
.pool-badge {
    display: inline-block !important;
    background: #0d6efd !important;
    color: #ffffff !important;
    padding: 2px 6px !important;
    border-radius: 10px !important;
    font-size: 10px !important;
    line-height: 1 !important;
}

/* Bot Header */
.bot-header {
    display: flex;
    align-items: flex-start;
    /* Align to top for larger image */
    margin-bottom: 15px;
    gap: 15px;
}

.bot-avatar {
    width: 100px;
    /* Increased size */
    height: 120px;
    /* Rectangular aspect ratio */
    border-radius: 8px;
    /* Rounded corners, not circle */
    background: linear-gradient(135deg, #3498db, #9b59b6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 24px;
    margin-right: 0;
    /* Handled by gap */
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
    overflow: hidden;
    /* Ensure image stays inside */
    flex-shrink: 0;
    /* Prevent shrinking */
}

.bot-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.bot-info h3 {
    color: #ffffff !important;
    margin: 0 0 5px 0;
    font-size: 16px;
    font-weight: 600;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.bot-info .bot-details {
    color: #bdc3c7 !important;
    font-size: 13px;
    display: flex;
    gap: 15px;
}

.bot-info .bot-details * {
    color: #bdc3c7 !important;
}

.bot-details span {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Bot Status */
.bot-status {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}



/* Bot Bio */
.bot-bio {
    color: #95a5a6 !important;
    font-size: 14px;
    line-height: 1.4;
    margin: 15px 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    background: rgba(52, 73, 94, 0.2) !important;
    padding: 10px !important;
    border-radius: 8px !important;
    border-left: 3px solid #3498db !important;
}

/* Bot Actions */
.bot-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.bot-action-btn {
    flex: 1;
    padding: 8px 12px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.bot-action-btn.edit {
    background: rgba(52, 152, 219, 0.2);
    color: #3498db;
    border: 1px solid rgba(52, 152, 219, 0.3);
}

.bot-action-btn.edit:hover {
    background: rgba(52, 152, 219, 0.3);
    border-color: #3498db;
}

.bot-action-btn.media {
    background: rgba(155, 89, 182, 0.2);
    color: #9b59b6;
    border: 1px solid rgba(155, 89, 182, 0.3);
}

.bot-action-btn.media:hover {
    background: rgba(155, 89, 182, 0.3);
    border-color: #9b59b6;
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(155, 89, 182, 0.4);
}

.bot-action-btn.delete {
    background: rgba(231, 76, 60, 0.2);
    color: #e74c3c;
    border: 1px solid rgba(231, 76, 60, 0.3);
}

.bot-action-btn.delete:hover {
    background: rgba(231, 76, 60, 0.3);
    border-color: #e74c3c;
}

/* Loading State */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: #7f8c8d !important;
    background: #1e2328 !important;
    border-radius: 12px;
}

.loading-state i {
    font-size: 48px;
    margin-bottom: 20px;
    color: #3498db !important;
    animation: pulse 2s ease-in-out infinite;
}

.loading-state p {
    font-size: 16px;
    margin: 0;
    color: #7f8c8d !important;
}

@keyframes pulse {
    0% {
        opacity: 0.6;
    }

    50% {
        opacity: 1;
    }

    100% {
        opacity: 0.6;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .bot-filters {
        flex-direction: column;
        align-items: stretch;
    }

    .search-box {
        max-width: 100%;
    }

    .bot-grid {
        grid-template-columns: 1fr;
        padding: 15px;
    }

    .bot-stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Bot Users - Additional Dark Theme Fixes */
#bot-users input,
#bot-users textarea,
#bot-users select {
    background: #2c3e50 !important;
    border: 1px solid #34495e !important;
    color: #e0e0e0 !important;
    border-radius: 8px !important;
    padding: 10px !important;
}

#bot-users input::placeholder,
#bot-users textarea::placeholder {
    color: #7f8c8d !important;
}

#bot-users input:focus,
#bot-users textarea:focus,
#bot-users select:focus {
    outline: none !important;
    border-color: #3498db !important;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2) !important;
}

#bot-users .modal {
    background: #1e2328 !important;
    border: 1px solid #2c3e50 !important;
}

#bot-users .modal-header {
    background: #2c3e50 !important;
    border-bottom: 1px solid #34495e !important;
}

#bot-users .modal-header h3 {
    color: #ffffff !important;
}

#bot-users .modal-body {
    background: #1e2328 !important;
}

/* Bot Users - Remove any white backgrounds */
#bot-users .card,
#bot-users .panel,
#bot-users .container,
#bot-users .wrapper {
    background: transparent !important;
}

/* Force dark theme for any remaining elements */
#bot-users .text-dark {
    color: #e0e0e0 !important;
}

#bot-users .bg-white,
#bot-users .bg-light {
    background: #1e2328 !important;
}

#bot-users .border {
    border-color: #2c3e50 !important;
}

#bot-users h1,
#bot-users h2,
#bot-users h3,
#bot-users h4,
#bot-users h5,
#bot-users h6 {
    color: #ffffff !important;
}

#bot-users p,
#bot-users span,
#bot-users div {
    color: #e0e0e0 !important;
}

#bot-users strong,
#bot-users b {
    color: #ffffff !important;
}

/* Bot Media Archive - Dark Theme */
.bot-media-archive {
    background: #1e2328 !important;
    color: #e0e0e0 !important;
    min-height: 500px;
    max-height: 70vh;
    overflow-y: auto;
}

.media-upload-section {
    background: rgba(44, 62, 80, 0.3) !important;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
    border: 1px solid #34495e;
}

.media-upload-section h4 {
    color: #ffffff !important;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.upload-area {
    border: 2px dashed #34495e;
    border-radius: 12px;
    background: rgba(52, 73, 94, 0.2) !important;
    transition: all 0.3s ease;
}

.upload-placeholder {
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.upload-placeholder:hover {
    background: rgba(52, 152, 219, 0.1) !important;
    border-color: #3498db;
}

.upload-placeholder i {
    font-size: 2.5rem;
    color: #3498db !important;
    margin-bottom: 15px;
}

.upload-placeholder p {
    color: #e0e0e0 !important;
    font-size: 16px;
    font-weight: 500;
    margin: 10px 0;
}

.upload-placeholder small {
    color: #7f8c8d !important;
    font-size: 13px;
}

.upload-loading {
    padding: 40px 20px;
    text-align: center;
    background: rgba(52, 152, 219, 0.1) !important;
}

.upload-loading i {
    font-size: 2rem;
    color: #3498db !important;
    margin-bottom: 15px;
}

.upload-loading p {
    color: #3498db !important;
    font-weight: 500;
}

.media-gallery-section {
    background: rgba(30, 35, 40, 0.6) !important;
    border-radius: 12px;
    padding: 20px;
    border: 1px solid #2c3e50;
}

.media-gallery-section h4 {
    color: #ffffff !important;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.media-gallery {
    min-height: 200px;
}

.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
}

.media-item {
    background: linear-gradient(135deg, #2c3e50, #34495e) !important;
    border-radius: 12px;
    padding: 10px;
    border: 1px solid #34495e;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.media-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    border-color: #3498db !important;
}

.media-preview {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    background: #1a1d23;
}

.media-preview img,
.media-preview video {
    width: 100%;
    height: 120px;
    object-fit: cover;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.media-preview img:hover,
.media-preview video:hover {
    transform: scale(1.05);
}

.media-overlay {
    position: absolute;
    top: 5px;
    right: 5px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.media-item:hover .media-overlay {
    opacity: 1;
}

.delete-media-btn {
    background: rgba(231, 76, 60, 0.9) !important;
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    color: #ffffff !important;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.delete-media-btn:hover {
    background: #e74c3c !important;
    transform: scale(1.1);
}

.media-caption {
    color: #bdc3c7 !important;
    font-size: 12px;
    margin-top: 8px;
    padding: 5px 8px;
    background: rgba(52, 73, 94, 0.5) !important;
    border-radius: 6px;
    word-wrap: break-word;
}

.media-date {
    color: #7f8c8d !important;
    font-size: 11px;
    margin-top: 5px;
    text-align: center;
}

.empty-media-state {
    text-align: center;
    padding: 60px 20px;
    color: #7f8c8d !important;
}

.empty-media-state i {
    font-size: 3rem;
    color: #34495e !important;
    margin-bottom: 20px;
}

.empty-media-state p {
    color: #7f8c8d !important;
    font-size: 16px;
    margin: 10px 0;
}

.empty-media-state small {
    color: #5d6d7e !important;
    font-size: 13px;
}

/* Upload Success Message */
.upload-success {
    animation: slideInRight 0.3s ease, fadeOut 0.3s ease 2.7s;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

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

@keyframes fadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

/* Media Preview Modal */
.modal .media-preview-modal {
    background: #1e2328 !important;
    border-radius: 12px;
    text-align: center;
}

.modal .media-preview-modal img,
.modal .media-preview-modal video {
    border-radius: 8px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .media-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 10px;
    }

    .media-preview img,
    .media-preview video {
        height: 100px;
    }

    .upload-placeholder {
        padding: 30px 15px;
    }

    .upload-placeholder i {
        font-size: 2rem;
    }
}

/* Custom Scrollbar Variables */
:root {
    --text-muted: #9ca3af;
    --text-danger: #ef4444;
    --text-primary: #ffffff;
    --text-secondary: #9ca3af;
    --primary-color: #3498db;
    --secondary-color: #e74c3c;
    --success-color: #2ecc71;
    --error-color: #e74c3c;
    --border-color: #404040;
    --card-bg: #2a2a2a;

    --scrollbar-thumb-color: rgba(255, 255, 255, 0.2);
    --scrollbar-thumb-hover-color: rgba(255, 255, 255, 0.3);

    --modal-overlay-bg: rgba(0, 0, 0, 0.7);
    --modal-content-bg: #1f2937;
}