:root {
    --primary-color: #ff8000;
    --primary-hover: #e67300;
    --bg-dark: #0f0f12;
    --card-bg: rgba(255, 255, 255, 0.05);
    --text-main: #ffffff;
    --text-muted: #a0a0a0;
    --glass-border: rgba(255, 255, 255, 0.1);
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    width: 90%;
    max-width: 1000px;
    padding: 40px 20px;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    text-align: center;
    background: linear-gradient(90deg, #fff, var(--primary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 700;
}

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

.card {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 24px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 128, 0, 0.3);
}

.card h2 {
    margin-top: 0;
    font-size: 1.25rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 10px;
}

.card p {
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

.btn-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
}

.btn {
    display: block;
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    text-decoration: none;
    text-align: center;
    font-weight: 600;
    transition: background 0.2s ease;
    cursor: pointer;
    box-sizing: border-box;
}

.btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn.primary {
    background: var(--primary-color);
}

.btn.primary:hover {
    background: var(--primary-hover);
}

/* Admin Styles */
.login-container {
    max-width: 400px;
    margin: 0 auto;
    text-align: center;
}

.input-group {
    margin-bottom: 20px;
    text-align: left;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-muted);
}

input[type="password"], input[type="text"] {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid var(--glass-border);
    background: rgba(0, 0, 0, 0.3);
    color: white;
    box-sizing: border-box;
}

.admin-layout {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 20px;
    height: 80vh;
}

.sidebar {
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 20px;
    overflow-y: auto;
}

.sidebar h3 {
    font-size: 1rem;
    margin-bottom: 15px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.dataset-item {
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s;
    margin-bottom: 5px;
}

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

.dataset-item.active {
    background: var(--primary-color);
    color: white;
}

.main-content {
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 24px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.command-list {
    flex-grow: 1;
}

.command-row {
    display: grid;
    grid-template-columns: 1fr 2fr 100px;
    gap: 10px;
    align-items: center;
    padding: 10px;
    border-bottom: 1px solid var(--glass-border);
}

.command-row:last-child {
    border-bottom: none;
}

.actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.btn-sm {
    padding: 6px 10px;
    font-size: 0.8rem;
}

.hidden {
    display: none !important;
}

.loader {
    border: 2px solid #f3f3f3;
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    animation: spin 1s linear infinite;
    display: inline-block;
    margin-right: 10px;
    vertical-align: middle;
}

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