:root {
    --primary: #FFD700;
    --primary-glow: rgba(255, 215, 0, 0.3);
    --bg: #0a0a0a;
    --card-bg: rgba(255, 255, 255, 0.05);
    --card-border: rgba(255, 255, 255, 0.1);
    --text: #f0f0f0;
    --text-muted: rgba(255, 255, 255, 0.5);
    --error: #ff4d4d;
    --success: #2ecc71;
    --gradient: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
}

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

body {
    font-family: 'Outfit', 'Inter', -apple-system, sans-serif;
    background-color: var(--bg);
    background-image: 
        radial-gradient(circle at 20% 20%, rgba(255, 215, 0, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 80% 80%, rgba(255, 165, 0, 0.05) 0%, transparent 40%);
    color: var(--text);
    line-height: 1.6;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    padding: 3rem;
    width: 100%;
    max-width: 480px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.dashboard-container {
    width: 95%;
    max-width: 1100px;
}

h1, h2, h3 {
    font-weight: 700;
    letter-spacing: -0.02em;
}

h1 { font-size: 2.2rem; margin-bottom: 2rem; background: var(--gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.4rem; }

.input-group {
    margin-bottom: 1.25rem;
}

label {
    display: block;
    margin-bottom: 0.6rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

input {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 0.9rem 1.2rem;
    color: white;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.07);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

button {
    width: 100%;
    background: var(--gradient);
    color: #000;
    border: none;
    border-radius: 12px;
    padding: 1rem;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 1rem;
}

button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -5px rgba(255, 215, 0, 0.4);
}

button:active {
    transform: translateY(0);
}

button.secondary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--card-border);
    color: var(--text);
}

button.secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
    color: var(--primary);
}

button.danger {
    background: rgba(255, 77, 77, 0.1);
    border: 1px solid rgba(255, 77, 77, 0.3);
    color: var(--error);
}

button.danger:hover {
    background: var(--error);
    color: white;
    box-shadow: 0 10px 20px -5px rgba(255, 77, 77, 0.4);
}

.alert {
    padding: 1rem;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    display: none;
    text-align: center;
}

.alert-error {
    background: rgba(255, 77, 77, 0.1);
    color: var(--error);
    border: 1px solid rgba(255, 77, 77, 0.2);
}

.api-key-box {
    background: rgba(0, 0, 0, 0.3);
    padding: 1rem 1.25rem;
    border-radius: 14px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.95rem;
    margin: 1rem 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--card-border);
}

.copy-btn {
    background: var(--primary);
    color: #000;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    width: auto;
    margin: 0;
}

.user-list {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.user-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 16px;
    border: 1px solid var(--card-border);
}

.badge {
    padding: 0.25rem 0.6rem;
    border-radius: 6px;
    font-size: 0.65rem;
    text-transform: uppercase;
    font-weight: 800;
    margin-left: 0.5rem;
}

.badge-admin {
    background: var(--gradient);
    color: #000;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--card-border);
}

.logout-link {
    color: var(--error);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: opacity 0.2s;
}

.logout-link:hover {
    opacity: 0.8;
}


/* API Keys Grid */
.keys-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 1rem;
}

.api-key-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.2rem;
    position: relative;
    transition: transform 0.2s, border-color 0.2s;
}

.api-key-item:hover {
    border-color: rgba(255, 204, 0, 0.3);
}

.key-info {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 0.5rem;
}

.key-label {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--primary);
}

.key-date {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.monospace-key {
    font-family: 'JetBrains Mono', 'Courier New', monospace;
    font-size: 0.9rem;
    word-break: break-all;
    flex: 1;
}

.danger-text {
    background: transparent;
    color: var(--error);
    border: none;
    padding: 0;
    margin-top: 0.5rem;
    font-size: 0.8rem;
    width: auto;
    cursor: pointer;
    text-decoration: underline;
    opacity: 0.7;
}

.danger-text:hover {
    background: transparent;
    opacity: 1;
}

.copy-btn.copy-success {
    background: var(--success) !important;
    color: white !important;
    border: none;
}


