/* Yönetim paneli */
body.admin { background: var(--bg); }
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: radial-gradient(900px 500px at 80% -10%, color-mix(in srgb, var(--brand) 22%, transparent), transparent 60%), var(--bg); }
.login-card { width: 100%; max-width: 400px; padding: 32px; }
.login-card .brand { margin-bottom: 22px; }
.login-card h1 { font-size: 22px; margin: 0 0 4px; letter-spacing: -.02em; }
.login-card p { color: var(--muted); margin: 0 0 20px; font-size: 14px; }
.login-card .field + .field { margin-top: 12px; }
.login-card .btn { width: 100%; margin-top: 18px; }
.login-card code { background: var(--bg-soft); padding: 2px 6px; border-radius: 6px; font-size: 12.5px; }

.shell { display: grid; grid-template-columns: 250px 1fr; min-height: 100vh; }
.side { position: sticky; top: 0; height: 100vh; overflow-y: auto; border-right: 1px solid var(--border); background: var(--surface); padding: 18px 12px; display: flex; flex-direction: column; gap: 4px; }
.side .brand { padding: 4px 8px 18px; }
.side a.nav-i { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 10px; color: var(--text-2); font-weight: 500; font-size: 14px; }
.side a.nav-i i { width: 18px; text-align: center; color: var(--muted); }
.side a.nav-i:hover { background: var(--bg-soft); text-decoration: none; color: var(--text); }
.side a.nav-i.active { background: var(--brand-soft); color: var(--brand-ink); font-weight: 600; }
.side a.nav-i.active i { color: var(--brand); }
.side .grp { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); padding: 14px 12px 4px; font-weight: 700; }
.side .bottom { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--border); display: grid; gap: 4px; }
.content { min-width: 0; }
.bar-top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 12px; padding: 14px 28px; background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); }
.bar-top h1 { margin: 0; font-size: 19px; letter-spacing: -.02em; }
.bar-top .sp { flex: 1; }
.dirty { display: none; align-items: center; gap: 8px; font-size: 13px; color: var(--warn); font-weight: 600; }
.dirty.on { display: inline-flex; }
.page { padding: 24px 28px 60px; display: grid; gap: 16px; max-width: 1200px; }
.menu-btn { display: none !important; }
@media (max-width: 900px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: fixed; z-index: 60; left: 0; top: 0; width: 260px; transform: translateX(-105%); transition: transform .2s; box-shadow: var(--shadow-lg); }
  .side.open { transform: none; }
  .menu-btn { display: inline-flex !important; }
  .bar-top, .page { padding-left: 16px; padding-right: 16px; }
}
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 1000px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .stats { grid-template-columns: 1fr; } }
.two { display: grid; grid-template-columns: 1.6fr 1fr; gap: 16px; }
@media (max-width: 1000px) { .two { grid-template-columns: 1fr; } }
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 13.5px; }
.list li:last-child { border-bottom: 0; }
.list .m { color: var(--muted); font-size: 12.5px; }
.rows { display: grid; gap: 8px; }
.row-edit { display: grid; gap: 8px; align-items: center; grid-template-columns: 1fr 1fr 120px 40px; }
.row-edit.kv2 { grid-template-columns: 1.4fr 1fr 110px 40px; }
.row-edit.hd { font-size: 12px; color: var(--muted); font-weight: 600; }
@media (max-width: 600px) { .row-edit, .row-edit.kv2 { grid-template-columns: 1fr 1fr; } .row-edit.hd { display: none; } }
.row-edit .input { height: 40px; }
.unit { position: relative; }
.unit .input { padding-right: 36px; }
.unit::after { content: attr(data-unit); position: absolute; right: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 13px; pointer-events: none; }
.chk { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; cursor: pointer; user-select: none; }
.chk input { width: 18px; height: 18px; accent-color: var(--brand); }
.preview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 700px) { .preview { grid-template-columns: 1fr; } }
.preview .box { background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; }
.preview .box .k { font-size: 12px; color: var(--muted); }
.preview .box .v { font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }
.delta-up { color: var(--ok); } .delta-down { color: var(--danger); }
table.adm { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.adm th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 600; padding: 10px 12px; border-bottom: 1px solid var(--border); background: var(--surface-2); white-space: nowrap; }
table.adm td { padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
table.adm td.r, table.adm th.r { text-align: right; font-variant-numeric: tabular-nums; }
table.adm tr:hover td { background: var(--surface-2); }
.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.toolbar .input { max-width: 320px; height: 38px; }
.pager { display: flex; gap: 8px; align-items: center; justify-content: flex-end; padding: 14px 20px; font-size: 13px; color: var(--muted); }
.tag { display: inline-block; font-size: 11.5px; font-weight: 600; padding: 2px 8px; border-radius: 99px; background: var(--bg-soft); color: var(--text-2); }
.tag.info { background: var(--info-soft); color: var(--info); } .tag.success { background: var(--ok-soft); color: var(--ok); } .tag.warning { background: var(--warn-soft); color: var(--warn); } .tag.danger { background: var(--danger-soft); color: var(--danger); }
.code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-weight: 700; letter-spacing: .05em; }
.help { font-size: 12.5px; color: var(--muted); margin: 6px 0 0; }
.hol-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.hol { display: inline-flex; align-items: center; gap: 6px; padding: 6px 6px 6px 10px; border-radius: 10px; background: var(--bg-soft); font-size: 13px; font-variant-numeric: tabular-nums; }
.hol button { border: 0; background: transparent; color: var(--muted); cursor: pointer; width: 24px; height: 24px; border-radius: 6px; }
.hol button:hover { background: var(--danger-soft); color: var(--danger); }
.mini-chart { height: 240px; position: relative; }
