/* Palette and components follow the CentralMods release ReadMe. */
:root {
  --bg: #0b0711; --panel: #140e1f; --ink: #eae6ff; --ink-soft: #e8dbff; --muted: #bcb4d9;
  --brand: #9b4dff; --brand-2: #d65bff; --link: #b085ff;
  --ok: #5ad67d; --warn: #ffd166; --err: #ff6b6b;
  --border: #2a1f3f; --chip: #201631; --field: #100a19;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--ink); font: 15px/1.6 Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Top bar */
.topbar { position: sticky; top: 0; z-index: 50; background: rgba(11,7,17,.78); -webkit-backdrop-filter: blur(14px) saturate(1.2); backdrop-filter: blur(14px) saturate(1.2); border-bottom: 1px solid var(--border); color: var(--ink); }
.topbar::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px; background: linear-gradient(90deg, transparent, rgba(155,77,255,.7) 30%, rgba(214,91,255,.7) 70%, transparent); pointer-events: none; }
.topbar-inner { max-width: 1100px; margin: 0 auto; padding: 10px 20px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.topbar-inner.center { justify-content: center; }
.logo-img { height: 52px; width: auto; display: block; filter: drop-shadow(0 2px 12px rgba(155,77,255,.35)); }
nav { display: flex; align-items: center; gap: 6px; margin-left: auto; flex-wrap: wrap; }
nav a { color: var(--muted); font-weight: 600; padding: 6px 12px; border-radius: 999px; transition: color .2s, background .2s; }
nav a:hover { color: var(--ink); background: rgba(255,255,255,.06); text-decoration: none; }
nav form { margin: 0; }
nav button.link { color: var(--muted); font-weight: 600; padding: 6px 12px; border-radius: 999px; }
nav button.link:hover { color: var(--ink); background: rgba(255,255,255,.06); filter: none; }
.who { display: flex; align-items: center; gap: 8px; background: rgba(255,255,255,.05); border: 1px solid var(--border); color: var(--ink-soft); padding: 4px 12px 4px 4px; border-radius: 999px; font-size: 13px; font-weight: 600; }
.who img { width: 28px; height: 28px; border-radius: 50%; }

/* Hero */
.hero { background:
    radial-gradient(1000px 300px at 80% -50%, rgba(155,77,255,.25), transparent 60%),
    radial-gradient(800px 260px at 20% -40%, rgba(214,91,255,.18), transparent 60%);
  border-bottom: 1px solid var(--border); }
.hero .wrap { text-align: center; padding-bottom: 32px; }
.hero p { color: var(--ink-soft); max-width: 720px; margin: 8px auto 0; }

.wrap { max-width: 1100px; margin: 0 auto; padding: 28px 20px; }
h1 { font-size: 32px; line-height: 1.15; margin: 8px 0 6px; }
h2 { font-size: 20px; margin: 28px 0 12px; color: var(--ink-soft); }
h3 { font-size: 16px; margin: 0 0 4px; color: var(--ink-soft); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.error { color: var(--err); }

.card { background: linear-gradient(180deg, rgba(255,255,255,.02), transparent 40%), var(--panel); border: 1px solid var(--border); border-radius: 16px; padding: 18px 20px; margin-bottom: 16px; }
.card h2 { margin-top: 0; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 16px; }
.chip { background: var(--chip); padding: 6px 12px; border: 1px solid var(--border); border-radius: 999px; color: var(--muted); font-size: 13px; }
.chip strong { color: var(--ink); }
.chip.ok { border-color: rgba(90,214,125,.35); color: var(--ok); }

/* Buttons */
.btn, button { display: inline-block; background: linear-gradient(140deg, var(--brand), var(--brand-2)); color: #fff; border: 0; border-radius: 10px; padding: 9px 18px; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; box-shadow: 0 4px 12px rgba(155,77,255,.3); }
.btn:hover, button:hover { filter: brightness(1.1); text-decoration: none; }
.btn.ghost, button.ghost { background: transparent; border: 1px solid var(--border); color: var(--ink); box-shadow: none; }
.btn.ghost:hover { border-color: var(--brand); }
button.link { background: none; box-shadow: none; padding: 0; color: var(--link); font-weight: 500; }
button.small, .btn.small { padding: 5px 12px; font-size: 13px; }
button.danger { background: #b3261e; box-shadow: none; }
button:disabled { opacity: .5; cursor: default; }
.btn.patreon { font-size: 16px; padding: 13px 26px; margin-top: 8px; }

/* Login */
.login { max-width: 460px; margin: 40px auto; text-align: center; padding: 32px 28px; }
.login .logo-img { height: 96px; margin: 0 auto 8px; }

/* Status / callouts */
.callout { display: flex; gap: 12px; align-items: center; padding: 12px 16px; border-radius: 12px; margin: 0 0 8px; }
.callout.ok { background: rgba(90,214,125,.1); border: 1px solid rgba(90,214,125,.25); }
.callout.warn { background: rgba(255,209,102,.1); border: 1px solid rgba(255,209,102,.25); }

/* Download list */
.files { display: grid; gap: 12px; }
.file { display: flex; align-items: center; gap: 16px; margin: 0; }
.file-main { flex: 1; min-width: 0; }
.file .desc { margin: 4px 0 6px; white-space: pre-line; color: var(--muted); }
.file .meta { margin: 0; color: var(--muted); font-size: 13px; overflow-wrap: anywhere; }
.file.locked { opacity: .55; }
.ver { font-size: 12px; font-weight: 600; color: var(--ink); background: var(--chip); border: 1px solid var(--border); border-radius: 999px; padding: 1px 8px; vertical-align: 2px; }

/* Forms */
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.grid .wide, .grid .check { grid-column: 1 / -1; }
label { display: flex; flex-direction: column; gap: 4px; color: var(--muted); font-size: 13px; }
label.check { flex-direction: row; align-items: center; gap: 8px; color: var(--ink); }
input, select, textarea { background: var(--field); color: var(--ink); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; font: inherit; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); }
input[type=file] { padding: 6px; }
progress { width: 240px; vertical-align: middle; accent-color: var(--brand); }
form.inline { display: inline; }

/* Tables */
table { width: 100%; border-collapse: collapse; background: var(--panel); border: 1px solid var(--border); border-radius: 16px; overflow: hidden; font-size: 14px; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
th { color: var(--ink-soft); font-weight: 600; }
td.num, th.num { text-align: right; }
td.actions { display: flex; gap: 6px; justify-content: flex-end; }
td.actions form { margin: 0; }
.pill { font-size: 12px; padding: 2px 10px; border-radius: 999px; border: 1px solid var(--border); background: #1a1129; color: var(--muted); }
.pill.on { color: var(--ok); border-color: rgba(90,214,125,.4); }
.danger h2 { color: var(--err); }

footer { color: var(--muted); font-size: 13px; text-align: center; padding: 24px 20px; border-top: 1px solid var(--border); margin-top: 28px; }

@media (max-width: 700px) {
  .grid { grid-template-columns: 1fr; }
  .file { flex-direction: column; align-items: stretch; }
  .file .btn { text-align: center; }
  table { display: block; overflow-x: auto; }
  .logo-img { height: 40px; }
  h1 { font-size: 26px; }
}

/* Links back to the main site, footer, YouTube */
nav a.home { color: var(--ink-soft); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 18px; }
.login .small { margin: 18px 0 0; }
footer { display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between; align-items: center; max-width: 1100px; margin: 28px auto 0; text-align: left; }
footer .links { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 4px; }
footer a { color: var(--muted); }
footer a:hover { color: var(--ink); }
.yt { display: inline-flex; color: #ff3d3d; opacity: .85; margin-left: 8px; transition: opacity .2s, transform .2s; }
.yt:hover { opacity: 1; transform: scale(1.12); }

@media (max-width: 700px) {
  .topbar-inner { padding: 8px 14px; gap: 8px; }
  nav { gap: 2px; }
  nav a, nav button.link { padding: 5px 9px; font-size: 13px; }
  .who { display: none; }
  footer { justify-content: center; text-align: center; }
  .hero-actions .btn { flex: 1 1 100%; text-align: center; }
}
