:root {
  --bg: #0b0f17;
  --panel: #121a28;
  --panel-2: #0f1624;
  --text: #e7ecf3;
  --muted: #9aa7bd;
  --line: rgba(255, 255, 255, 0.1);
  --focus: rgba(255, 255, 255, 0.22);
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  --radius: 18px;
  --ok: #73e6b6;
  --err: #ff8a8a;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  font: 14px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
}

.bg {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(900px 450px at 15% 10%, rgba(68, 138, 255, 0.2), transparent 60%),
    radial-gradient(900px 450px at 85% 20%, rgba(179, 0, 255, 0.18), transparent 60%),
    radial-gradient(900px 450px at 50% 95%, rgba(0, 200, 160, 0.12), transparent 60%);
  pointer-events: none;
}

.shell {
  width: min(980px, calc(100% - 32px));
  margin: 24px auto;
  position: relative;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.topbar h1 {
  margin: 0;
  font-size: 18px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.topbar nav {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.muted {
  color: var(--muted);
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03));
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
}

.pad {
  padding: 16px;
}

.btn,
button,
input[type="submit"] {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  padding: 10px 13px;
  cursor: pointer;
}

.btn:hover,
button:hover,
input[type="submit"]:hover {
  background: rgba(255, 255, 255, 0.12);
}

.btn.subtle {
  text-decoration: none;
  display: inline-flex;
}

.grid {
  display: grid;
  gap: 14px;
}

.grid.two {
  grid-template-columns: 320px 1fr;
}

@media (max-width: 850px) {
  .grid.two {
    grid-template-columns: 1fr;
  }
}

input[type="text"],
input[type="password"],
input[type="email"],
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.2);
  color: var(--text);
  padding: 11px 12px;
}

label {
  display: block;
  margin-bottom: 7px;
  color: var(--muted);
}

.row {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.row > * {
  margin: 0;
}

.project-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.project-list li {
  margin: 8px 0;
}

.project-list a {
  display: block;
  color: var(--text);
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  background: rgba(0, 0, 0, 0.15);
}

.project-list a:hover {
  background: rgba(0, 0, 0, 0.25);
}

.app {
  overflow: hidden;
}

.composer {
  padding: 14px 16px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.1);
}

.composer select {
  width: auto;
  min-width: 125px;
}

.toolbar {
  padding: 10px 16px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  gap: 10px;
}

.filters {
  display: inline-flex;
  gap: 7px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(0, 0, 0, 0.12);
}

.chip {
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 7px 10px;
  text-decoration: none;
  display: inline-block;
}

.chip.active {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}

.todo-list {
  list-style: none;
  margin: 0;
  padding: 10px;
  max-height: 58vh;
  overflow-y: auto;
}

.item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 9px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 14px;
  margin: 8px 0;
  padding: 9px 12px;
  background: rgba(0, 0, 0, 0.15);
}

.item.done strong {
  text-decoration: line-through;
  opacity: 0.65;
}

.item small {
  color: var(--muted);
}

.priority {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 11px;
  border: 1px solid var(--line);
  margin-right: 6px;
}

.priority.p-longterm {
  background: rgba(255, 255, 255, 0.07);
}

.priority.p-low {
  background: rgba(105, 193, 255, 0.2);
}

.priority.p-medium {
  background: rgba(115, 230, 182, 0.2);
}

.priority.p-high {
  background: rgba(255, 188, 87, 0.2);
}

.priority.p-critical {
  background: rgba(255, 112, 112, 0.25);
  border-color: rgba(255, 112, 112, 0.5);
}

.inline-form {
  display: inline;
}

.flash {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 12px;
  background: rgba(255, 255, 255, 0.06);
}

.flash.success {
  border-color: rgba(115, 230, 182, 0.4);
}

.flash.error {
  border-color: rgba(255, 138, 138, 0.45);
}

.page-foot {
  margin-top: 12px;
  color: var(--muted);
  font-size: 12px;
  padding: 0 4px;
}
