* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: 'Roboto', -apple-system, sans-serif;
  background: #0f0f0f; color: #f1f1f1;
  min-height: 100vh; display: flex; flex-direction: column;
}
a { color: inherit; }

header {
  background: #181818;
  border-bottom: 1px solid #3f3f3f;
  padding: 10px 24px;
  display: flex; align-items: center; gap: 24px;
  position: sticky; top: 0; z-index: 50;
}
header h1 {
  font-size: 22px; font-weight: 800; color: #ff0000;
  cursor: pointer; white-space: nowrap; letter-spacing: 0.5px;
}
.search-wrap { flex: 1; display: flex; justify-content: center; }
#searchInput {
  width: 100%; max-width: 640px;
  background: #121212; border: 1px solid #3f3f3f;
  color: #f1f1f1; padding: 10px 16px;
  border-radius: 20px; font-size: 14px; font-family: inherit;
  transition: border-color .15s;
}
#searchInput:focus { outline: none; border-color: #ff0000; }
.header-link {
  color: #aaa; text-decoration: none; font-size: 14px;
  padding: 6px 12px; border-radius: 6px;
  transition: background .15s, color .15s; white-space: nowrap;
}
.header-link:hover { background: #3f3f3f; color: #fff; }

.admin-banner {
  background: #272727; border-bottom: 1px solid #3f3f3f;
  padding: 10px 24px;
  display: flex; align-items: center; gap: 16px;
  font-size: 14px; color: #f1f1f1;
}
.admin-banner span { flex: 1; }
.admin-banner .banner-actions { display: flex; gap: 8px; }
.admin-banner button {
  background: #3f3f3f; color: #f1f1f1; border: none;
  padding: 6px 14px; border-radius: 6px; cursor: pointer;
  font-size: 13px; font-family: inherit;
}
.admin-banner button:hover { background: #555; }
.admin-banner button.primary { background: #ff0000; }
.admin-banner button.primary:hover { background: #cc0000; }

.layout { display: grid; grid-template-columns: 240px 1fr; flex: 1; min-height: 0; position: relative; }

main { padding: 24px; overflow-y: auto; }

.empty-state {
  text-align: center; color: #666;
  padding: 80px 20px; font-size: 14px;
}

.modal-bg {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.7); display: none;
  align-items: center; justify-content: center; z-index: 100;
}
.modal-bg.visible { display: flex; }
.modal {
  background: #272727; border-radius: 12px; padding: 24px;
  max-width: 400px; width: 90%;
}
.modal p { margin-bottom: 16px; }
.modal-actions { display: flex; gap: 8px; justify-content: flex-end; }
.modal-actions button {
  background: #3f3f3f; color: #f1f1f1; border: none;
  padding: 10px 20px; border-radius: 6px; cursor: pointer;
  font-size: 14px;
}
.modal-actions button:hover { background: #555; }
.modal-actions button.primary { background: #aa0000; }
.modal-actions button.primary:hover { background: #ff0000; }

.toast {
  position: fixed; bottom: 24px; left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #272727; color: #f1f1f1;
  padding: 10px 16px; border-radius: 8px;
  border: 1px solid #3f3f3f;
  font-size: 13px; opacity: 0;
  transition: opacity .2s, transform .2s;
  pointer-events: none; z-index: 200;
}
.toast.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
