:root { --primary: #2563eb; --success: #16a34a; --warning: #ca8a04; --bg: #f1f5f9; }
body { font-family: sans-serif; background: var(--bg); margin: 0; padding: 20px; }
button { cursor: pointer; }
a { text-decoration: none; }

.hidden { display: none !important; }

.container { max-width: 800px; margin: 0 auto; }
.top-bar { background: white; padding: 15px; display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; border-radius: 8px; }
.top-bar-actions { display: flex; align-items: center; gap: 12px; }
.user-pill { font-size: 0.95rem; color: #475569; }
.btn-secondary { background: #e2e8f0; color: #1e293b; border: none; padding: 10px 16px; border-radius: 6px; }
.btn-primary { background: var(--primary); color: white; border: none; padding: 10px 16px; border-radius: 6px; }
.btn-danger { background: #dc2626; color: white; border: none; padding: 10px 16px; border-radius: 6px; }
.status-message { margin-top: 12px; font-size: 0.95rem; }
.status-error { color: #b91c1c; }
.status-success { color: #15803d; }

/* Home Menu Grid */
.menu-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 20px; }
.menu-card { background: white; padding: 30px; border-radius: 12px; text-align: center; box-shadow: 0 4px 6px rgba(0,0,0,0.05); transition: transform 0.2s; color: #333; }
.menu-card:hover { transform: translateY(-5px); box-shadow: 0 10px 15px rgba(0,0,0,0.1); }
.menu-icon { font-size: 3rem; margin-bottom: 15px; display: block; }
.menu-title { font-weight: bold; font-size: 1.2rem; display: block; }

/* Existing Card Styles */
.card { background: white; padding: 15px; margin-bottom: 15px; border-radius: 8px; box-shadow: 0 2px 4px rgba(0,0,0,0.1); }
.card-header { display: flex; justify-content: space-between; font-weight: bold; font-size: 1.2rem; cursor: pointer; }
.card-body { display: none; margin-top: 15px; border-top: 1px solid #eee; padding-top: 15px; }
.card-body.open { display: block; }

/* Table Styles */
table { width: 100%; border-collapse: collapse; margin-top: 20px; }
th, td { border: 1px solid #ddd; padding: 12px; text-align: left; }
th { background-color: #f8fafc; }
input, select { padding: 10px; margin: 5px 0; border: 1px solid #ddd; border-radius: 4px; width: 100%; box-sizing: border-box; }

/* Tablet Specifics */
.row { display: flex; justify-content: space-between; align-items: center; padding: 10px 0; border-bottom: 1px solid #eee; }
.progress-bar { width: 100px; height: 10px; background: #eee; border-radius: 5px; overflow: hidden; }
.fill { height: 100%; background: var(--warning); width: 0%; }
.btn-pick { background: var(--primary); color: white; border: none; padding: 8px 15px; border-radius: 5px; }

/* Modal */
.modal { display: none; position: fixed; top:0; left:0; width:100%; height:100%; background:rgba(0,0,0,0.5); justify-content:center; align-items:center; }
.modal-content { background: white; padding: 20px; border-radius: 10px; width: 90%; max-width: 400px; }
.stepper { display: flex; gap: 10px; align-items: center; margin: 10px 0; }
.step-btn { padding: 10px 20px; font-size: 1.2rem; background: #eee; border:none; border-radius: 4px;}

.auth-shell {
    min-height: calc(100vh - 40px);
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-card {
    width: 100%;
    max-width: 420px;
    background: white;
    border-radius: 14px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
    padding: 32px;
}

.auth-card h1 {
    margin-top: 0;
    margin-bottom: 8px;
}

.auth-card p {
    color: #64748b;
    margin-bottom: 20px;
}

.form-grid {
    display: grid;
    gap: 14px;
}

.users-layout {
    max-width: 1200px;
}

.users-grid {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 20px;
}

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

.users-table td,
.users-table th {
    vertical-align: top;
}

.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
}

.badge-admin { background: #dbeafe; color: #1d4ed8; }
.badge-user { background: #dcfce7; color: #15803d; }
.badge-active { background: #dcfce7; color: #166534; }
.badge-inactive { background: #fee2e2; color: #b91c1c; }

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

@media (max-width: 900px) {
    .menu-grid,
    .users-grid {
        grid-template-columns: 1fr;
    }

    .top-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
}
