:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #1a1a1a;
    --bg-tertiary: #2a2a2a;
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --text-muted: #808080;
    --accent-primary: #00d4ff;
    --accent-secondary: #7c3aed;
    --border-color: #333333;
    --success-color: #10b981;
    --error-color: #ef4444;
    --warning-color: #f59e0b;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    min-height: 100vh;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(0, 212, 255, 0.1) 0%, transparent 50%);
}

.admin-container {
    max-width: 1200px;
    margin: 0 auto;
    background: var(--bg-secondary);
    min-height: 100vh;
    border-left: 1px solid var(--border-color);
    border-right: 1px solid var(--border-color);
}

.admin-header {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-lg);
    border-bottom: 1px solid var(--border-color);
}

.admin-header h1 {
    font-size: 1.8em;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.admin-header nav a {
    color: white;
    text-decoration: none;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 500;
    backdrop-filter: blur(10px);
}

.admin-header nav a:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
    transform: translateY(-1px);
}

.admin-main {
    padding: 30px;
    display: grid;
    gap: 30px;
}

.config-section, .status-section, .presets-section {
    background: var(--bg-tertiary);
    border-radius: 16px;
    padding: 30px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.config-section:hover, .status-section:hover, .presets-section:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

.config-section h2, .status-section h2, .presets-section h2 {
    color: var(--text-primary);
    margin-bottom: 25px;
    font-size: 1.5em;
    font-weight: 600;
    border-bottom: 2px solid var(--accent-primary);
    padding-bottom: 12px;
    letter-spacing: -0.01em;
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.9em;
    letter-spacing: 0.02em;
}

.form-group input, .form-group select, .form-group textarea {
    width: 100%;
    padding: 14px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    font-size: 1em;
    color: var(--text-primary);
    transition: all 0.3s ease;
    font-family: inherit;
    backdrop-filter: blur(10px);
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.1);
    background: var(--bg-tertiary);
}

.form-group input::placeholder, .form-group textarea::placeholder {
    color: var(--text-muted);
}

.toggle-btn {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85em;
    font-weight: 500;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.toggle-btn:hover {
    transform: translateY(-50%) translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 212, 255, 0.3);
}

.form-group:has(input[type="password"]) {
    position: relative;
}

.form-group:has(input[type="password"]) input {
    padding-right: 80px;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 30px;
}

.btn {
    padding: 14px 28px;
    border: none;
    border-radius: 10px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    backdrop-filter: blur(10px);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--border-color);
    transform: translateY(-2px);
}

.btn-small {
    padding: 8px 16px;
    font-size: 0.9em;
}

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

.status-item {
    text-align: center;
    padding: 25px;
    background: var(--bg-secondary);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.status-item:hover {
    transform: translateY(-2px);
    border-color: var(--accent-primary);
}

.status-item h3 {
    color: var(--text-primary);
    margin-bottom: 12px;
    font-size: 1.2em;
    font-weight: 600;
}

.status-indicator {
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.9em;
    background: var(--bg-tertiary);
    color: var(--text-muted);
    display: inline-block;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.status-indicator.success {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
    border-color: rgba(16, 185, 129, 0.3);
}

.status-indicator.error {
    background: rgba(239, 68, 68, 0.1);
    color: var(--error-color);
    border-color: rgba(239, 68, 68, 0.3);
}

.presets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.preset-item {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 25px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.preset-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-primary);
}

.preset-item h4 {
    color: var(--text-primary);
    margin-bottom: 12px;
    font-size: 1.2em;
    font-weight: 600;
}

.preset-item p {
    color: var(--text-secondary);
    font-size: 0.9em;
    margin-bottom: 20px;
    line-height: 1.6;
}

.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 24px;
    border-radius: 12px;
    color: white;
    font-weight: 600;
    z-index: 1000;
    animation: slideIn 0.3s ease;
    max-width: 300px;
    box-shadow: var(--shadow-xl);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.notification.success {
    background: rgba(16, 185, 129, 0.9);
    border-color: rgba(16, 185, 129, 0.3);
}

.notification.error {
    background: rgba(239, 68, 68, 0.9);
    border-color: rgba(239, 68, 68, 0.3);
}

.notification.info {
    background: rgba(59, 130, 246, 0.9);
    border-color: rgba(59, 130, 246, 0.3);
}

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

@media (max-width: 768px) {
    .admin-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .admin-main {
        padding: 20px;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .status-grid {
        grid-template-columns: 1fr;
    }
    
    .presets-grid {
        grid-template-columns: 1fr;
    }
    
    .notification {
        left: 20px;
        right: 20px;
        max-width: none;
    }
}