/* Yönvm Central Admin — v2 */
:root {
    --bg: #0b1120;
    --surface: #151f32;
    --surface2: #1c2942;
    --border: #2a3a55;
    --text: #e8edf5;
    --muted: #8b9cb8;
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --success: #22c55e;
    --warning: #eab308;
    --danger: #ef4444;
    --sidebar-w: 240px;
    --radius: 10px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Segoe UI', system-ui, sans-serif; background: var(--bg); color: var(--text); min-height: 100vh; font-size: 14px; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

.layout { display: flex; min-height: 100vh; }
.sidebar { width: var(--sidebar-w); background: var(--surface); border-right: 1px solid var(--border); padding: 1.25rem 0; flex-shrink: 0; position: fixed; height: 100vh; overflow-y: auto; }
.sidebar .brand { padding: 0 1.25rem 1.5rem; font-size: 1.25rem; font-weight: 700; color: #fff; border-bottom: 1px solid var(--border); margin-bottom: 1rem; }
.sidebar .brand span { color: var(--primary); }
.sidebar nav a { display: flex; align-items: center; gap: 0.6rem; padding: 0.65rem 1.25rem; color: var(--muted); transition: .15s; }
.sidebar nav a:hover, .sidebar nav a.active { background: var(--surface2); color: #fff; text-decoration: none; border-left: 3px solid var(--primary); }
.sidebar .nav-section { padding: 0.75rem 1.25rem 0.35rem; font-size: 0.7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }

.main { margin-left: var(--sidebar-w); flex: 1; padding: 1.5rem 2rem; }
.page-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; flex-wrap: wrap; gap: 1rem; }
.page-header h1 { font-size: 1.5rem; font-weight: 600; }
.page-header .sub { color: var(--muted); font-size: 0.85rem; margin-top: 0.25rem; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; }
.stat-card .label { color: var(--muted); font-size: 0.8rem; margin-bottom: 0.35rem; }
.stat-card .value { font-size: 1.75rem; font-weight: 700; }
.stat-card .value.blue { color: var(--primary); }
.stat-card .value.green { color: var(--success); }
.stat-card .value.yellow { color: var(--warning); }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; margin-bottom: 1.25rem; }
.card h2 { font-size: 1rem; margin-bottom: 1rem; font-weight: 600; }

table { width: 100%; border-collapse: collapse; }
th, td { padding: 0.75rem 0.5rem; text-align: left; border-bottom: 1px solid var(--border); }
th { color: var(--muted); font-size: 0.75rem; text-transform: uppercase; letter-spacing: .04em; font-weight: 600; }
tr:hover td { background: rgba(255,255,255,.02); }

.badge { display: inline-block; padding: 0.2rem 0.55rem; border-radius: 20px; font-size: 0.72rem; font-weight: 600; }
.badge.active { background: rgba(34,197,94,.15); color: var(--success); }
.badge.suspended { background: rgba(234,179,8,.15); color: var(--warning); }
.badge.revoked { background: rgba(239,68,68,.15); color: var(--danger); }
.badge.starter { background: rgba(59,130,246,.15); color: var(--primary); }
.badge.enterprise { background: rgba(168,85,247,.15); color: #c084fc; }

.btn { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.55rem 1rem; border-radius: 8px; border: none; cursor: pointer; font-size: 0.875rem; font-weight: 500; text-decoration: none; transition: .15s; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-hover); color: #fff; text-decoration: none; }
.btn-ghost { background: var(--surface2); color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--border); text-decoration: none; color: #fff; }
.btn-danger { background: rgba(239,68,68,.15); color: var(--danger); }
.btn-sm { padding: 0.3rem 0.65rem; font-size: 0.8rem; }
.btn-group { display: flex; gap: 0.5rem; flex-wrap: wrap; }

label { display: block; margin-bottom: 0.3rem; color: var(--muted); font-size: 0.8rem; font-weight: 500; }
input, select, textarea { width: 100%; padding: 0.6rem 0.75rem; margin-bottom: 1rem; background: var(--bg); border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-size: 0.9rem; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(59,130,246,.2); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-row-3 { grid-template-columns: 1fr 1fr 1fr; }
@media(max-width:768px) { .form-row, .form-row-3 { grid-template-columns: 1fr; } .sidebar { display: none; } .main { margin-left: 0; } }

.alert { padding: 0.85rem 1rem; border-radius: 8px; margin-bottom: 1rem; display: flex; align-items: center; gap: 0.5rem; }
.alert-ok { background: rgba(34,197,94,.12); border: 1px solid rgba(34,197,94,.3); color: var(--success); }
.alert-err { background: rgba(239,68,68,.12); border: 1px solid rgba(239,68,68,.3); color: var(--danger); }
.alert-info { background: rgba(59,130,246,.12); border: 1px solid rgba(59,130,246,.3); color: var(--primary); }

code, .code { background: var(--bg); padding: 0.15rem 0.45rem; border-radius: 5px; font-family: Consolas, monospace; font-size: 0.85rem; border: 1px solid var(--border); }
.code-block { background: var(--bg); border: 1px solid var(--border); border-radius: 8px; padding: 1rem; font-family: Consolas, monospace; font-size: 0.82rem; overflow-x: auto; margin: 0.75rem 0; white-space: pre-wrap; }

.upload-zone { border: 2px dashed var(--border); border-radius: var(--radius); padding: 2rem; text-align: center; color: var(--muted); transition: .2s; }
.upload-zone:hover { border-color: var(--primary); background: rgba(59,130,246,.05); }

.docs-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media(max-width:900px) { .docs-grid { grid-template-columns: 1fr; } }
.doc-item { background: var(--surface2); border-radius: 8px; padding: 1rem; }
.doc-item h3 { font-size: 0.9rem; margin-bottom: 0.5rem; }
.doc-item p { color: var(--muted); font-size: 0.82rem; line-height: 1.5; }

.login-page { display: flex; align-items: center; justify-content: center; min-height: 100vh; background: linear-gradient(135deg, #0b1120, #1a2744); }
.login-card { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 2rem; width: 100%; max-width: 400px; }
.login-card h1 { margin-bottom: 0.25rem; }
.login-card .sub { color: var(--muted); margin-bottom: 1.5rem; }

.empty { text-align: center; padding: 2rem; color: var(--muted); }
