:root {
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --bg-dark: #0f172a;
    --card-bg: rgba(30, 41, 59, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-main: #f8fafc;
    --text-dim: #94a3b8;
    --success: #22c55e;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-main);
    overflow-x: hidden;
    min-height: 100vh;
}

.background-blobs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.blob {
    position: absolute;
    width: 40vw;
    height: 40vw;
    background: linear-gradient(135deg, var(--primary), #a855f7);
    filter: blur(80px);
    opacity: 0.2;
    border-radius: 50%;
    animation: move 20s infinite alternate;
}

.blob-1 {
    top: -10%;
    left: -10%;
    animation-duration: 25s;
}

.blob-2 {
    bottom: -10%;
    right: -10%;
    background: linear-gradient(135deg, #3b82f6, #06b6d4);
    animation-duration: 30s;
}

.blob-3 {
    top: 40%;
    left: 30%;
    width: 20vw;
    height: 20vw;
    background: #ec4899;
    animation-duration: 20s;
}

@keyframes move {
    from {
        transform: translate(0, 0) scale(1);
    }

    to {
        transform: translate(100px, 50px) scale(1.1);
    }
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
}

header {
    margin-bottom: 40px;
    text-align: center;
}

h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 8px;
    background: linear-gradient(to right, #fff, #94a3b8);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.subtitle {
    color: var(--text-dim);
    letter-spacing: 1px;
    text-transform: uppercase;
    font-size: 0.8rem;
}

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

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

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
}

.stat-card h3 {
    font-size: 0.9rem;
    color: var(--text-dim);
    margin-bottom: 12px;
}

.stat-card p {
    font-size: 2rem;
    font-weight: 600;
}

.user-list-section {
    background: var(--card-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 30px;
}

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

.table-container {
    overflow-x: auto;
}

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

th {
    text-align: left;
    padding: 12px 15px;
    color: var(--text-dim);
    font-weight: 600;
    border-bottom: 1px solid var(--glass-border);
}

td {
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.btn-refresh {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
}

.btn-refresh:hover {
    background: var(--primary-hover);
    transform: scale(1.05);
}

.btn-edit {
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary);
    border: 1px solid var(--primary);
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
}

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

.table-actions {
    display: flex;
    gap: 8px;
}

.btn-delete {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid #ef4444;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
}

.btn-delete:hover {
    background: #ef4444;
    color: white;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 100;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: #1e293b;
    border: 1px solid var(--glass-border);
    padding: 40px;
    border-radius: 24px;
    width: 90%;
    max-width: 400px;
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.modal.active {
    display: flex;
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal h2 {
    margin-bottom: 10px;
}

#edit-userid-display {
    color: var(--text-dim);
    margin-bottom: 25px;
}

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

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.9rem;
    color: var(--text-dim);
}

input[type="number"] {
    width: 100%;
    background: #0f172a;
    border: 1px solid var(--glass-border);
    color: white;
    padding: 12px;
    border-radius: 8px;
    font-size: 1.1rem;
    outline: none;
}

input[type="number"]:focus {
    border-color: var(--primary);
}

.modal-actions {
    display: flex;
    gap: 12px;
}

.btn-secondary {
    flex: 1;
    background: transparent;
    color: white;
    border: 1px solid var(--glass-border);
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
}

.btn-primary {
    flex: 1;
    background: var(--primary);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
}