:root { --bg: #0b1020; --text: #e6e8ee; --muted: #a0a7b8; --card: #12172a; --accent: #4f46e5; --danger: #ef4444; }
* { box-sizing: border-box; }
body { margin: 0; font-family: ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial; background: var(--bg); color: var(--text); }
.topbar { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; background: #0a0f1e; border-bottom: 1px solid #1b2140; position: sticky; top: 0; z-index: 10; }
.brand a { color: var(--text); text-decoration: none; font-weight: 700; letter-spacing: .2px; }
.nav a { color: var(--muted); text-decoration: none; margin-left: 12px; }
.nav a:hover { color: var(--text); }
.container { max-width: 1000px; margin: 24px auto; padding: 0 16px; }
h1, h2 { margin: 8px 0 16px; }
.panel { background: var(--card); border: 1px solid #202748; border-radius: 8px; padding: 16px; }
.btn { display: inline-block; padding: 8px 12px; background: var(--accent); color: white; border-radius: 6px; text-decoration: none; border: 0; cursor: pointer; }
.btn.secondary { background: #374151; }
.btn.danger { background: var(--danger); }
label { display: block; margin-bottom: 10px; }
input[type=text], select, input[type=color] { width: 100%; background: #0f1428; color: var(--text); border: 1px solid #232a4e; border-radius: 6px; padding: 8px; }
.hint { color: var(--muted); font-size: .9em; }
.card-list { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.card { background: var(--card); border: 1px solid #202748; padding: 14px; border-radius: 8px; }
.card-title { font-weight: 700; margin-bottom: 8px; }
.card-meta { color: var(--muted); font-size: .9em; margin-bottom: 10px; }
.card-actions .btn { margin-right: 8px; }
.flashes { list-style: none; padding: 0; }
.flash { padding: 10px; margin-bottom: 8px; border-radius: 6px; background: #0f1428; border: 1px solid #232a4e; }
.flash.success { border-color: #2f855a; }
.flash.error { border-color: #c53030; }
.board-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.sound-btn { position: relative; background: var(--btn-color, var(--accent)); color: white; border: 0; border-radius: 16px; padding: 16px; min-height: 100px; cursor: pointer; font-weight: 700; letter-spacing: .2px; box-shadow: inset 0 -4px 0 rgba(0,0,0,.15); display: flex; align-items: center; justify-content: center; user-select: none; }
.sound-btn:active { transform: translateY(1px); box-shadow: inset 0 -2px 0 rgba(0,0,0,.25); }
.sound-btn .label { display: block; text-align: center; }
.sound-btn:focus-visible { outline: 2px solid rgba(255,255,255,.5); outline-offset: 3px; }
.sound-btn .stop-one { position: absolute; top: 50%; right: 10px; transform: translateY(-50%); border: 0; border-radius: 999px; width: 36px; height: 36px; background: rgba(0,0,0,.28); color: white; font-size: 16px; line-height: 36px; text-align: center; cursor: pointer; box-shadow: 0 0 0 1px rgba(255,255,255,.18) inset; }
.sound-btn .stop-one:hover { background: rgba(0,0,0,.35); }
.two-col { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 800px) { .two-col { grid-template-columns: 1.5fr 1fr; } }
.sortable { list-style: none; padding: 0; border: 1px dashed #2a315c; border-radius: 8px; background: #0f1428; }
.sortable-item { display: grid; grid-template-columns: 24px 1fr auto auto auto; gap: 8px; align-items: center; padding: 8px 10px; border-bottom: 1px solid #141a34; }
.sortable-item:last-child { border-bottom: 0; }
.drag-handle { cursor: grab; color: #7b83a5; }
.item-label { font-weight: 600; }
.item-path { color: #9aa3c7; }
.inline { display: inline; }
.inline .btn { padding: 6px 10px; font-size: .95em; }
.files { list-style: none; padding: 0; }
.files li { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid #141a34; }
.footer { color: var(--muted); text-align: center; padding: 24px 0; }

/* Admin edit form visual tweaks */
.edit-panel { background: transparent; border: 1px dashed #2a315c; border-radius: 8px; padding: 10px; }
.edit-panel .two-col { grid-template-columns: 1fr 1fr; }
.edit-panel label { margin-bottom: 6px; }
.edit-panel .btn { margin-top: 6px; }
