:root {
  --bg: #0a0d14; --bg2: #0f131c; --panel: #131925; --panel2: #182031; --line: #222c3f; --line2: #2d3a52;
  --text: #e6eaf2; --muted: #8b97ad; --dim: #5d6a82;
  --accent: #5865f2; --accent2: #7b86ff; --green: #3ecf8e; --red: #f25c66; --yellow: #f5b94a; --blue: #4aa8ff;
  --radius: 12px; --mono: ui-monospace, SFMono-Regular, "Cascadia Code", Consolas, Menlo, monospace;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--text); font: 14px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--accent2); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0; font-weight: 650; letter-spacing: -.01em; }
h1 { font-size: 22px; } h2 { font-size: 16px; } h3 { font-size: 14px; }
.muted { color: var(--muted); } .dim { color: var(--dim); } .mono { font-family: var(--mono); }
.right { margin-left: auto; } .nowrap { white-space: nowrap; }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.hidden { display: none !important; }

/* Layout */
.app { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
.side { background: var(--bg2); border-right: 1px solid var(--line); padding: 18px 12px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px 18px; font-weight: 700; font-size: 17px; }
.brand .logo-img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1px var(--line2), 0 0 14px rgba(56, 130, 255, .35); }
.brand .logo { width: 30px; height: 30px; border-radius: 9px; background: linear-gradient(135deg, var(--accent), #8b5cf6); display: grid; place-items: center; font-size: 16px; }
.nav-title { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--dim); padding: 14px 12px 6px; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 8px; color: var(--muted); font-weight: 500; }
.nav a:hover { background: var(--panel); color: var(--text); text-decoration: none; }
.nav a.active { background: var(--panel2); color: var(--text); box-shadow: inset 2px 0 0 var(--accent); }
.nav .count { margin-left: auto; background: var(--red); color: #fff; border-radius: 999px; font-size: 11px; padding: 0 7px; }
.userbox { margin-top: auto; border-top: 1px solid var(--line); padding: 12px 6px 0; display: flex; align-items: center; gap: 10px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--panel2); object-fit: cover; display: grid; place-items: center; font-weight: 700; flex: none; }
.main { padding: 28px 32px 60px; max-width: 1280px; width: 100%; min-width: 0; }
.page-head { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head .sub { color: var(--muted); }
.btn.burger { display: none; }

/* Components */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.card > h2 { margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, 1fr); } .g3 { grid-template-columns: repeat(3, 1fr); } .g4 { grid-template-columns: repeat(4, 1fr); }
.stat .label { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.stat .value { font-size: 26px; font-weight: 700; margin-top: 4px; letter-spacing: -.02em; }
.stat .hint { color: var(--dim); font-size: 12px; margin-top: 2px; }
.btn { appearance: none; border: 1px solid var(--line2); background: var(--panel2); color: var(--text); padding: 8px 14px; border-radius: 8px; font: inherit; font-weight: 550; cursor: pointer; display: inline-flex; align-items: center; gap: 7px; transition: .12s; white-space: nowrap; }
.btn:hover { border-color: var(--dim); background: #1d2740; text-decoration: none; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent2); border-color: var(--accent2); }
.btn.green { background: rgba(62, 207, 142, .14); border-color: rgba(62, 207, 142, .4); color: var(--green); }
.btn.green:hover { background: rgba(62, 207, 142, .24); }
.btn.danger { background: rgba(242, 92, 102, .12); border-color: rgba(242, 92, 102, .4); color: var(--red); }
.btn.danger:hover { background: rgba(242, 92, 102, .22); }
.btn.yellow { background: rgba(245, 185, 74, .12); border-color: rgba(245, 185, 74, .4); color: var(--yellow); }
.btn.ghost { background: transparent; }
.btn.sm { padding: 4px 10px; font-size: 12.5px; border-radius: 7px; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--panel2); color: var(--muted); border: 1px solid var(--line2); }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.badge.green { color: var(--green); background: rgba(62, 207, 142, .1); border-color: rgba(62, 207, 142, .3); }
.badge.red { color: var(--red); background: rgba(242, 92, 102, .1); border-color: rgba(242, 92, 102, .3); }
.badge.yellow { color: var(--yellow); background: rgba(245, 185, 74, .1); border-color: rgba(245, 185, 74, .3); }
.badge.blue { color: var(--blue); background: rgba(74, 168, 255, .1); border-color: rgba(74, 168, 255, .3); }
.badge.plain::before { display: none; }
.badge.pulse::before { animation: pulse 1.4s infinite; }
@keyframes pulse { 50% { opacity: .3; } }
.tbl { width: 100%; border-collapse: collapse; }
.tbl th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--dim); font-weight: 600; padding: 8px 12px; border-bottom: 1px solid var(--line); }
.tbl td { padding: 11px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tbody tr:hover { background: rgba(255, 255, 255, .02); }
.tbl-wrap { overflow-x: auto; }
.empty { text-align: center; color: var(--muted); padding: 40px 10px; }
.empty .big { font-size: 34px; margin-bottom: 6px; }

/* Forms */
.field { display: flex; flex-direction: column; gap: 5px; margin-bottom: 14px; }
.field > label, .lbl { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.field .help { font-size: 12px; color: var(--dim); }
.input, select, textarea { width: 100%; background: var(--bg); border: 1px solid var(--line2); border-radius: 8px; color: var(--text); padding: 9px 12px; font: inherit; outline: none; }
.input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(88, 101, 242, .2); }
textarea { font-family: var(--mono); font-size: 13px; resize: vertical; min-height: 90px; }
.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.switch input { width: 38px; height: 22px; appearance: none; background: var(--line2); border-radius: 999px; position: relative; cursor: pointer; transition: .15s; margin: 0; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; background: #fff; border-radius: 50%; transition: .15s; }
.switch input:checked { background: var(--accent); }
.switch input:checked::after { left: 19px; }
.radio-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.radio-card { border: 1px solid var(--line2); border-radius: 10px; padding: 10px 12px; cursor: pointer; background: var(--bg); display: flex; gap: 8px; align-items: flex-start; }
.radio-card:has(input:checked) { border-color: var(--accent); background: rgba(88, 101, 242, .1); }
.radio-card input { margin-top: 3px; accent-color: var(--accent); }
.env-row { display: grid; grid-template-columns: 1fr 1.4fr auto; gap: 8px; margin-bottom: 8px; }

/* Tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; overflow-x: auto; }
.tabs a { padding: 10px 16px; color: var(--muted); font-weight: 600; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tabs a:hover { color: var(--text); text-decoration: none; }
.tabs a.active { color: var(--text); border-color: var(--accent); }

/* Konsole */
.console-box { background: #07090e; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.console { height: 440px; overflow-y: auto; padding: 12px 14px; font: 12.5px/1.55 var(--mono); }
.console .ln { white-space: pre-wrap; word-break: break-word; }
.console .ln .ts { color: var(--dim); margin-right: 10px; user-select: none; }
.console .ln.err .tx { color: #ff8d95; }
.console .ln.panel .tx { color: var(--blue); }
.console-input { display: flex; border-top: 1px solid var(--line); }
.console-input span { padding: 10px 0 10px 14px; color: var(--green); font-family: var(--mono); }
.console-input input { flex: 1; background: transparent; border: 0; color: var(--text); padding: 10px 14px 10px 8px; font: 13px var(--mono); outline: none; }
.console-tools { display: flex; gap: 8px; padding: 8px 12px; border-bottom: 1px solid var(--line); background: var(--bg2); align-items: center; }
canvas.spark { width: 100%; height: 60px; display: block; margin-top: 8px; }

/* Dateimanager */
.crumbs { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-family: var(--mono); font-size: 13px; }
.crumbs a { padding: 2px 6px; border-radius: 6px; }
.crumbs a:hover { background: var(--panel2); text-decoration: none; }
.dropzone { border: 2px dashed var(--line2); border-radius: var(--radius); padding: 14px; text-align: center; color: var(--muted); margin-bottom: 14px; transition: .15s; }
.dropzone.over { border-color: var(--accent); background: rgba(88, 101, 242, .08); color: var(--text); }
.editor { width: 100%; min-height: 420px; font-family: var(--mono); font-size: 13px; line-height: 1.5; tab-size: 2; white-space: pre; }
.progress { height: 8px; background: var(--bg); border-radius: 999px; overflow: hidden; border: 1px solid var(--line); }
.progress > i { display: block; height: 100%; background: linear-gradient(90deg, var(--accent), var(--accent2)); border-radius: 999px; }

/* Tickets */
.msg { display: flex; gap: 12px; margin-bottom: 14px; }
.msg .bubble { background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; flex: 1; white-space: pre-wrap; word-break: break-word; }
.msg.admin .bubble { background: rgba(88, 101, 242, .1); border-color: rgba(88, 101, 242, .35); }
.msg .meta { font-size: 12px; color: var(--dim); margin-bottom: 3px; }

/* Modal / Toast */
.backdrop { position: fixed; inset: 0; background: rgba(3, 5, 9, .7); backdrop-filter: blur(3px); display: grid; place-items: center; z-index: 50; padding: 16px; }
.modal { background: var(--panel); border: 1px solid var(--line2); border-radius: 14px; padding: 22px; width: 100%; max-width: 520px; max-height: 92vh; overflow-y: auto; box-shadow: 0 30px 80px rgba(0, 0, 0, .6); }
.modal.wide { max-width: 900px; }
.modal h2 { margin-bottom: 16px; font-size: 18px; }
.modal .actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; }
#toasts { position: fixed; right: 18px; bottom: 18px; display: flex; flex-direction: column; gap: 8px; z-index: 100; }
.toast { background: var(--panel2); border: 1px solid var(--line2); border-left: 3px solid var(--accent); padding: 10px 16px; border-radius: 8px; box-shadow: 0 10px 30px rgba(0, 0, 0, .5); animation: slide .2s; max-width: 380px; }
.toast.err { border-left-color: var(--red); } .toast.ok { border-left-color: var(--green); }
@keyframes slide { from { transform: translateY(10px); opacity: 0; } }

/* Login */
.login { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: radial-gradient(900px 500px at 50% -10%, rgba(88, 101, 242, .22), transparent), var(--bg); }
.login .box { width: 100%; max-width: 420px; text-align: center; }
.login .logo-big { width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 18px; background: linear-gradient(135deg, var(--accent), #8b5cf6); display: grid; place-items: center; font-size: 32px; }
.login ul { text-align: left; color: var(--muted); padding-left: 18px; margin: 18px 0; }
.btn.discord { background: #5865f2; border-color: #5865f2; color: #fff; padding: 12px 20px; width: 100%; justify-content: center; font-size: 15px; }
.btn.discord:hover { background: #6b77ff; }
.alert { padding: 10px 14px; border-radius: 8px; margin-bottom: 14px; border: 1px solid; }
.alert.err { background: rgba(242, 92, 102, .1); border-color: rgba(242, 92, 102, .35); color: #ff9aa1; }
.alert.ok { background: rgba(62, 207, 142, .1); border-color: rgba(62, 207, 142, .35); color: var(--green); }
.alert.info { background: rgba(74, 168, 255, .08); border-color: rgba(74, 168, 255, .3); color: var(--blue); }
.bot-card { display: flex; flex-direction: column; gap: 10px; cursor: pointer; transition: .12s; }
.bot-card:hover { border-color: var(--accent); transform: translateY(-1px); }
.lang { font-size: 12px; color: var(--muted); }

@media (max-width: 980px) {
  .app { grid-template-columns: minmax(0, 1fr); }
  .side { position: fixed; z-index: 40; left: 0; top: 0; width: 260px; transform: translateX(-100%); transition: .2s; }
  .side.open { transform: none; box-shadow: 0 0 0 100vmax rgba(0, 0, 0, .6); }
  .btn.burger { display: inline-flex; }
  .main { padding: 18px 16px 50px; }
  .g3, .g4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) { .g2, .g3, .g4 { grid-template-columns: 1fr; } .env-row { grid-template-columns: 1fr; } }

/* ===== Shop / Bestellseite ===== */
body.shop { background: radial-gradient(1000px 520px at 50% -8%, rgba(88, 101, 242, .22), transparent) no-repeat, var(--bg); min-height: 100vh; }
.shop-wrap { max-width: 1040px; margin: 0 auto; padding: 0 20px; }
.shop-nav { border-bottom: 1px solid var(--line); background: rgba(15, 19, 28, .75); backdrop-filter: blur(8px); position: sticky; top: 0; z-index: 5; }
.shop-nav .shop-wrap { height: 64px; }
.shop-nav .brand { padding: 0; color: var(--text); }
.shop-nav .brand:hover { text-decoration: none; }
.hero { text-align: center; padding: 64px 0 36px; max-width: 720px; margin: 0 auto; }
.hero h1 { font-size: 40px; line-height: 1.15; margin: 16px 0 14px; letter-spacing: -.02em; }
.hero p { font-size: 16px; }
.features { margin: 20px 0 40px; }
.order-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; align-items: start; scroll-margin-top: 80px; }
.steps { color: var(--muted); padding-left: 20px; margin: 0; display: flex; flex-direction: column; gap: 8px; }
@media (max-width: 800px) { .order-grid { grid-template-columns: 1fr; } .hero h1 { font-size: 30px; } .g3.features { grid-template-columns: 1fr; } }
