* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --primary: #ff6600;
    --secondary: #ff8800;
    --dark: #0a0500;
    --darker: #050200;
}

body {
    font-family: 'Rajdhani', sans-serif;
    background: linear-gradient(135deg, #1a0a00 0%, #0a0500 100%);
    color: #fff;
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 280px;
    background: rgba(20, 10, 5, 0.9);
    border-right: 2px solid var(--primary);
    padding: 30px 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-logo {
    text-align: center;
    padding: 0 20px 30px;
    border-bottom: 1px solid rgba(255, 102, 0, 0.2);
    margin-bottom: 30px;
}

.sidebar-logo h2 {
    font-size: 2rem;
    color: var(--primary);
    text-shadow: 0 0 20px var(--primary);
}

.sidebar-logo span {
    color: #fff;
}

.sidebar-logo p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
    margin-top: 5px;
}

.sidebar-nav {
    padding: 0 15px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    border-radius: 10px;
    margin-bottom: 10px;
    transition: all 0.3s;
    font-size: 1.1rem;
    font-weight: 600;
}

.nav-item .icon {
    font-size: 1.5rem;
}

.nav-item:hover, .nav-item.active {
    background: rgba(255, 102, 0, 0.2);
    color: var(--primary);
    border-left: 4px solid var(--primary);
}

.nav-item.logout {
    margin-top: 50px;
    border-top: 1px solid rgba(255, 102, 0, 0.2);
    padding-top: 25px;
}

.nav-item.logout:hover {
    background: rgba(255, 0, 0, 0.2);
    color: #ff6666;
    border-left-color: #ff6666;
}

/* Main Content */
.main-content {
    margin-left: 280px;
    flex: 1;
    padding: 30px;
}

.top-header {
    background: rgba(20, 10, 5, 0.8);
    border: 2px solid var(--primary);
    border-radius: 15px;
    padding: 20px 30px;
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left h3 {
    color: var(--primary);
    font-size: 1.5rem;
}

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

.time {
    color: rgba(255, 255, 255, 0.6);
}

.btn-view-site {
    padding: 10px 25px;
    background: var(--primary);
    color: #000;
    text-decoration: none;
    font-weight: 700;
    border-radius: 5px;
    transition: all 0.3s;
}

.btn-view-site:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 102, 0, 0.5);
}

/* Dashboard */
.dashboard h1 {
    font-size: 3rem;
    margin-bottom: 30px;
    color: var(--primary);
    text-shadow: 0 0 20px var(--primary);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.stat-card {
    background: rgba(20, 10, 5, 0.8);
    border: 2px solid var(--primary);
    border-radius: 15px;
    padding: 30px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.3s;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(255, 102, 0, 0.4);
}

.stat-icon {
    font-size: 3rem;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    color: rgba(255, 255, 255, 0.6);
    font-size: 1rem;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
    gap: 30px;
}

.dashboard-card {
    background: rgba(20, 10, 5, 0.8);
    border: 2px solid var(--primary);
    border-radius: 15px;
    padding: 30px;
    overflow: hidden;
}

.dashboard-card h2 {
    color: var(--primary);
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.dashboard-card canvas {
    max-height: 300px;
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
}

table thead {
    background: rgba(255, 102, 0, 0.2);
}

table th {
    padding: 15px;
    text-align: left;
    color: var(--primary);
    font-weight: 700;
}

table td {
    padding: 15px;
    border-bottom: 1px solid rgba(255, 102, 0, 0.1);
}

table tr:hover {
    background: rgba(255, 102, 0, 0.05);
}

.badge {
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

.badge.active {
    background: rgba(0, 255, 0, 0.2);
    color: #00ff00;
}

.badge.inactive {
    background: rgba(255, 0, 0, 0.2);
    color: #ff6666;
}

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

.login-box {
    background: rgba(20, 10, 5, 0.9);
    border: 2px solid var(--primary);
    border-radius: 20px;
    padding: 50px;
    max-width: 450px;
    width: 100%;
    box-shadow: 0 0 50px rgba(255, 102, 0, 0.3);
}

.login-box h1 {
    text-align: center;
    color: var(--primary);
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 0 0 20px var(--primary);
}

.subtitle {
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 40px;
}

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

.form-group label {
    display: block;
    color: var(--primary);
    margin-bottom: 8px;
    font-weight: 600;
}

.form-group input, .form-group textarea, .form-group select {
    width: 100%;
    padding: 15px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 102, 0, 0.3);
    border-radius: 8px;
    color: #fff;
    font-size: 1rem;
    transition: all 0.3s;
}

.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 20px rgba(255, 102, 0, 0.3);
}

button[type="submit"], .btn-primary {
    width: 100%;
    padding: 18px;
    background: var(--primary);
    border: none;
    border-radius: 8px;
    color: #000;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 1px;
}

button[type="submit"]:hover, .btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 102, 0, 0.5);
}

.error {
    background: rgba(255, 0, 0, 0.2);
    border: 1px solid #ff0000;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    color: #ff6666;
}

.alert.success {
    background: rgba(0, 255, 0, 0.2);
    border: 1px solid #00ff00;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    color: #00ff00;
}

.back-link {
    text-align: center;
    margin-top: 20px;
}

.back-link a {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    transition: all 0.3s;
}

.back-link a:hover {
    color: var(--primary);
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.page-header h1 {
    font-size: 3rem;
    color: var(--primary);
}

/* Table Card */
.table-card {
    background: rgba(20, 10, 5, 0.8);
    border: 2px solid var(--primary);
    border-radius: 15px;
    padding: 30px;
    overflow-x: auto;
}

.btn-delete {
    padding: 8px 20px;
    background: rgba(255, 0, 0, 0.2);
    border: 1px solid #ff0000;
    color: #ff6666;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    transition: all 0.3s;
}

.btn-delete:hover {
    background: #ff0000;
    color: #fff;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    overflow-y: auto;
}

.modal-content {
    background: rgba(20, 10, 5, 0.95);
    border: 2px solid var(--primary);
    border-radius: 20px;
    margin: 50px auto;
    padding: 40px;
    max-width: 700px;
    width: 90%;
}

.modal-content h2 {
    color: var(--primary);
    margin-bottom: 30px;
    font-size: 2rem;
}

.close {
    color: var(--primary);
    float: right;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
}

.close:hover {
    color: #fff;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* Settings Page */
.settings-card {
    background: rgba(20, 10, 5, 0.5);
    border: 2px solid var(--primary);
    padding: 40px;
}

.settings-card h2 {
    color: var(--primary);
    margin-bottom: 30px;
    font-size: 1.8rem;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.info-item {
    background: rgba(255, 102, 0, 0.05);
    border: 1px solid rgba(255, 102, 0, 0.2);
    padding: 20px;
    text-align: center;
}

.info-label {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.info-value {
    color: var(--primary);
    font-size: 1.2rem;
    font-weight: 700;
}

/* Edit Button */
.btn-edit {
    padding: 8px 15px;
    background: rgba(0, 150, 255, 0.2);
    border: 1px solid rgba(0, 150, 255, 0.5);
    color: #0096ff;
    text-decoration: none;
    font-weight: 600;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-block;
    margin-right: 10px;
}

.btn-edit:hover {
    background: rgba(0, 150, 255, 0.3);
    transform: translateY(-2px);
}

/* Badge colors for bot status */
.badge.online {
    background: rgba(0, 255, 0, 0.2);
    border-color: rgba(0, 255, 0, 0.5);
    color: #0f0;
}

.badge.offline {
    background: rgba(255, 0, 0, 0.2);
    border-color: rgba(255, 0, 0, 0.5);
    color: #f00;
}


/* Dashboard Enhancements */
.top-downloads-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 400px;
    overflow-y: auto;
}

.top-downloads-list::-webkit-scrollbar {
    width: 6px;
}

.top-downloads-list::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
}

.top-downloads-list::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 10px;
}

.top-download-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: rgba(255, 102, 0, 0.05);
    border: 1px solid rgba(255, 102, 0, 0.2);
    border-radius: 10px;
    transition: all 0.3s ease;
}

.top-download-item:hover {
    background: rgba(255, 102, 0, 0.1);
    transform: translateX(5px);
}

.top-download-item .rank {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #ff6600, #ff8800);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
    color: white;
}

.top-download-item .download-info {
    flex: 1;
}

.top-download-item .download-title {
    font-weight: 600;
    color: white;
    margin-bottom: 3px;
}

.top-download-item .download-version {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.6);
}

.top-download-item .download-count {
    font-size: 1.2rem;
    font-weight: 700;
    color: #ff6600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.activity-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
}

.activity-list::-webkit-scrollbar {
    width: 6px;
}

.activity-list::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
}

.activity-list::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 10px;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
    background: rgba(255, 102, 0, 0.05);
    border-radius: 8px;
    transition: all 0.3s ease;
}

.activity-item:hover {
    background: rgba(255, 102, 0, 0.1);
}

.activity-icon {
    width: 10px;
    height: 10px;
    margin-top: 5px;
}

.activity-icon i {
    font-size: 0.5rem;
    color: #ff6600;
}

.activity-content {
    flex: 1;
}

.activity-user {
    font-weight: 600;
    color: white;
    margin-bottom: 2px;
}

.activity-action {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 3px;
}

.activity-time {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
}

canvas {
    max-height: 300px;
}
