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

:root{
    --bg: #050807;
    --bg-soft: #0a0f0d;
    --panel: rgba(13, 18, 16, 0.95);
    --panel-2: rgba(17, 24, 21, 0.98);
    --panel-3: rgba(10, 14, 13, 0.90);
    --line: rgba(255,255,255,0.06);
    --line-strong: rgba(28, 215, 158, 0.22);
    --text: #f2f7f5;
    --muted: #8ca39a;
    --primary: #18d19a;
    --primary-2: #0fae80;
    --primary-soft: rgba(24, 209, 154, 0.12);
    --success: #22c55e;
    --danger: #ef4444;
    --warning: #f59e0b;
    --shadow: 0 16px 40px rgba(0,0,0,.40);
    --radius: 18px;
}

html, body { min-height: 100%; }

body {
    font-family: "Segoe UI", Arial, sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top center, rgba(24,209,154,.08), transparent 22%),
        radial-gradient(circle at right top, rgba(24,209,154,.04), transparent 18%),
        linear-gradient(180deg, #040605 0%, #0a0f0d 100%);
    min-height: 100vh;
}

a { color: inherit; text-decoration: none; }

.layout { display: flex; min-height: 100vh; }

.sidebar {
    width: 280px;
    background: rgba(7, 10, 9, 0.98);
    border-right: 1px solid rgba(255,255,255,0.04);
    padding: 24px 18px;
    position: sticky;
    top: 0;
    height: 100vh;
}

.brand {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 28px;
    padding: 14px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
    border: 1px solid rgba(255,255,255,0.05);
    box-shadow: 0 8px 30px rgba(0,0,0,.22);
}

.brand-logo {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--primary), #0aa57c);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    color: #03110b;
    box-shadow: 0 0 18px rgba(24,209,154,.25);
    overflow: hidden;
}
.brand-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.brand-text h2 { font-size: 19px; line-height: 1.1; color: #fff; }
.brand-text p { color: var(--muted); font-size: 12px; margin-top: 5px; }

.nav-section-title {
    font-size: 11px;
    color: #6f867d;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin: 18px 10px 10px;
}

.nav { display: flex; flex-direction: column; gap: 8px; }

.nav a {
    padding: 13px 14px;
    border-radius: 14px;
    color: #dbe8e3;
    border: 1px solid transparent;
    transition: .2s ease;
    font-weight: 600;
    background: transparent;
}

.nav a:hover,
.nav a.active {
    background: linear-gradient(180deg, rgba(24,209,154,.12), rgba(24,209,154,.05));
    border-color: rgba(24,209,154,.16);
    color: #ffffff;
    transform: translateX(2px);
    box-shadow: 0 6px 18px rgba(0,0,0,.15), inset 0 0 0 1px rgba(24,209,154,.05);
}

.main { flex: 1; padding: 30px; }

.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.page-title h1 { font-size: 32px; font-weight: 800; margin-bottom: 8px; letter-spacing: -.5px; }
.page-title p { color: var(--muted); font-size: 15px; }

.userbox {
    display: flex;
    align-items: center;
    gap: 14px;
    background: linear-gradient(180deg, rgba(17,23,21,.98), rgba(10,14,13,.98));
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 18px;
    padding: 10px 14px;
    box-shadow: var(--shadow);
}
.userbox:hover { border-color: rgba(24,209,154,.18); }
.userbox img {
    width: 48px; height: 48px; border-radius: 50%; object-fit: cover;
    border: 2px solid rgba(24,209,154,.18);
}
.userbox .meta { display: flex; flex-direction: column; gap: 4px; }
.userbox .meta strong { font-size: 15px; }
.userbox .meta span { color: var(--muted); font-size: 12px; }

.card-grid { display: grid; grid-template-columns: repeat(4, minmax(180px, 1fr)); gap: 18px; margin-bottom: 22px; }

.card,
.panel {
    background: linear-gradient(180deg, rgba(15,20,18,.98), rgba(9,12,11,.98));
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.card:hover,.panel:hover{ border-color: rgba(24,209,154,.13); }
.card { padding: 20px; }

.stat-card { position: relative; overflow: hidden; }
.stat-card::after {
    content: "";
    position: absolute; right: -18px; bottom: -30px;
    width: 100px; height: 100px; border-radius: 999px;
    background: rgba(24,209,154,.10); filter: blur(8px);
}
.stat-label { color: var(--muted); font-size: 13px; margin-bottom: 12px; }
.stat-value { font-size: 32px; font-weight: 800; color: #fff; }

.panel { padding: 22px; margin-bottom: 20px; }
.panel h3 { margin-bottom: 16px; font-size: 18px; }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th {
    text-align: left; font-size: 13px; color: #c1d0ca;
    padding: 14px 12px; border-bottom: 1px solid rgba(255,255,255,0.05);
}
td {
    padding: 14px 12px; border-bottom: 1px solid rgba(255,255,255,0.035); vertical-align: middle;
}
tr:hover td { background: rgba(255,255,255,0.012); }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-group.full { grid-column: 1 / -1; }
label { color: #f0f3f3; font-size: 14px; font-weight: 600; }

input[type="text"],
input[type="number"],
textarea {
    width: 100%;
    background: #0a0e0d;
    color: #f8f8f8;
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 14px;
    padding: 13px 14px;
    outline: none;
    transition: .2s ease;
}
textarea { min-height: 130px; resize: vertical; }
input:focus,textarea:focus {
    border-color: rgba(24,209,154,.38);
    box-shadow: 0 0 0 4px rgba(24,209,154,.09);
}

.btn,button {
    border: none; border-radius: 12px; padding: 11px 16px;
    font-weight: 700; cursor: pointer; transition: .18s ease;
}
.btn-primary,button {
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    color: #04110d; box-shadow: 0 10px 24px rgba(24,209,154,.16);
}
.btn-primary:hover,button:hover {
    transform: translateY(-1px);
    filter: brightness(1.05);
    box-shadow: 0 14px 26px rgba(24,209,154,.22);
}
.btn-success { background: linear-gradient(135deg, #22c55e, #16a34a); color: #fff; }
.btn-danger { background: linear-gradient(135deg, #ef4444, #dc2626); color: #fff; }
.inline-form { display: inline-block; margin-right: 8px; margin-bottom: 6px; }

.badge {
    display: inline-flex; align-items: center; gap: 7px; padding: 8px 11px; border-radius: 999px;
    font-size: 12px; font-weight: 700; border: 1px solid transparent;
}
.badge.success { background: rgba(34,197,94,.12); color: #86efac; border-color: rgba(34,197,94,.22); }
.badge.danger { background: rgba(239,68,68,.12); color: #fca5a5; border-color: rgba(239,68,68,.22); }


.form-help { color: var(--muted); font-size: 12px; margin-top: 4px; display:block; }
.alert {
    border-radius: 14px; padding: 14px 16px; margin-bottom: 16px;
    border: 1px solid rgba(24,209,154,.15); background: rgba(24,209,154,.07); color: #d9fff3;
}

.profile-row { display: flex; align-items: center; gap: 12px; }
.profile-row img {
    width: 42px; height: 42px; border-radius: 50%; object-fit: cover;
    border: 2px solid rgba(24,209,154,.14);
}
.status-dot {
    width: 11px; height: 11px; border-radius: 50%; display: inline-block; vertical-align: middle;
    box-shadow: 0 0 10px currentColor;
}
.status-dot.green { background: var(--success); color: var(--success); }
.status-dot.red { background: var(--danger); color: var(--danger); }
.username-with-status { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; }
.quick-links { display: flex; flex-wrap: wrap; gap: 12px; }
.quick-links a {
    padding: 12px 14px; border-radius: 14px; background: rgba(255,255,255,0.025);
    border: 1px solid rgba(255,255,255,0.05); transition: .2s ease;
}
.quick-links a:hover {
    background: rgba(24,209,154,.08); border-color: rgba(24,209,154,.18); transform: translateY(-1px);
}

.hero-user { display: grid; grid-template-columns: 350px 1fr; gap: 20px; margin-top: 10px; }
.profile-card {
    background: linear-gradient(180deg, rgba(18,22,22,.96), rgba(11,14,14,.96));
    border: 1px solid rgba(255,255,255,0.05); border-radius: 22px; box-shadow: var(--shadow); overflow: hidden;
}
.profile-cover {
    height: 120px;
    background: linear-gradient(135deg, rgba(24,209,154,.24), rgba(7,7,7,.15)), linear-gradient(135deg, #123b33, #0b1010);
}
.profile-body { padding: 0 22px 22px; text-align: center; margin-top: -42px; }
.profile-body img {
    width: 88px; height: 88px; border-radius: 50%; object-fit: cover; border: 4px solid #0c0f10;
    box-shadow: 0 0 0 2px rgba(24,209,154,.18);
}
.profile-body h3 { margin-top: 14px; font-size: 22px; }
.profile-body p { color: var(--muted); margin-top: 6px; font-size: 14px; }
.profile-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 18px; }
.mini-box {
    background: rgba(255,255,255,0.025); border: 1px solid rgba(255,255,255,0.045); border-radius: 16px; padding: 14px;
}
.mini-box strong { display: block; font-size: 18px; margin-bottom: 6px; }
.mini-box span { color: var(--muted); font-size: 13px; }
.content-stack { display: flex; flex-direction: column; gap: 20px; }
.info-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.info-item {
    background: rgba(255,255,255,0.025); border: 1px solid rgba(255,255,255,0.045); border-radius: 16px; padding: 16px;
}
.info-item small { display: block; color: var(--muted); margin-bottom: 6px; font-size: 12px; }
.info-item strong { font-size: 15px; color: #fff; }
.section-title { font-size: 19px; margin-bottom: 14px; }

.chart-box { overflow: hidden; }
.chart-legend { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 16px; color: var(--muted); font-size: 13px; }
.chart-wrap {
    width: 100%;
    min-height: 280px;
    height: 280px;
    padding: 14px 8px 8px;
    overflow: hidden;
}
.bar-chart {
    height: 100%;
    display: grid;
    grid-template-columns: repeat(7, minmax(0,1fr));
    gap: 14px;
    align-items: end;
}
.bar-item {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: end;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
.bar-track {
    width: 100%;
    max-width: 56px;
    height: 210px;
    display: flex;
    align-items: end;
    justify-content: center;
    background: linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.03));
    border: 1px solid rgba(255,255,255,0.04);
    border-radius: 16px;
    padding: 8px;
}
.bar-fill {
    width: 100%;
    border-radius: 12px;
    background: linear-gradient(180deg, rgba(24,209,154,1), rgba(13,149,112,1));
    box-shadow: 0 0 18px rgba(24,209,154,.15);
    min-height: 12px;
}
.bar-count { font-size: 12px; color: #d7e6e0; font-weight: 700; }
.bar-label { font-size: 12px; color: var(--muted); white-space: nowrap; }

@media (max-width: 1200px) { .hero-user { grid-template-columns: 1fr; } }
@media (max-width: 1100px) {
    .card-grid { grid-template-columns: repeat(2, minmax(180px, 1fr)); }
    .form-grid { grid-template-columns: 1fr; }
    .info-list { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
    .layout { flex-direction: column; }
    .sidebar { width: 100%; height: auto; position: relative; }
    .topbar { flex-direction: column; align-items: flex-start; }
    .card-grid { grid-template-columns: 1fr; }
    .main { padding: 18px; }
    .chart-wrap { height: 240px; min-height: 240px; }
    .bar-chart { gap: 8px; }
}


.upload-dropzone {
    position: relative;
    width: 100%;
    min-height: 180px;
    border-radius: 20px;
    border: 2px dashed rgba(24,209,154,.22);
    background: linear-gradient(180deg, rgba(255,255,255,.02), rgba(255,255,255,.01));
    transition: .18s ease;
    cursor: pointer;
}

.upload-dropzone:hover,
.upload-dropzone.dragover {
    border-color: rgba(24,209,154,.45);
    background: linear-gradient(180deg, rgba(24,209,154,.08), rgba(24,209,154,.03));
    box-shadow: 0 0 0 4px rgba(24,209,154,.08);
}

.upload-dropzone-inner {
    min-height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    flex-direction: column;
    gap: 10px;
    padding: 24px;
}

.upload-icon {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    font-weight: 800;
    color: #dcfff5;
    background: linear-gradient(135deg, rgba(24,209,154,.26), rgba(24,209,154,.10));
    border: 1px solid rgba(24,209,154,.18);
}

.upload-dropzone strong {
    font-size: 17px;
}

.upload-dropzone span,
.form-help,
.upload-file-name {
    color: var(--muted);
    font-size: 13px;
}

.store-thumb {
    width: 62px;
    height: 62px;
    border-radius: 14px;
    object-fit: cover;
    display: block;
    border: 1px solid rgba(255,255,255,.08);
    background: rgba(255,255,255,.03);
}
