:root {
  color-scheme: light;
  --bg: #f6f7f9;
  --panel: #ffffff;
  --line: #d9dee7;
  --text: #1d2433;
  --muted: #657286;
  --accent: #1d6f5f;
  --accent-dark: #15594d;
  --danger: #b42318;
  --shadow: 0 14px 34px rgba(34, 44, 64, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
textarea,
select {
  font: inherit;
}

button {
  border: 0;
  border-radius: 6px;
  background: var(--accent);
  color: white;
  cursor: pointer;
  font-weight: 700;
  min-height: 38px;
  padding: 0 14px;
}

button.secondary {
  background: #e8ecef;
  color: var(--text);
}

button.danger {
  background: var(--danger);
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--text);
  padding: 10px 11px;
}

textarea {
  min-height: 86px;
  resize: vertical;
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px 1fr;
}

.sidebar {
  background: #1f2937;
  color: #f8fafc;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.brand {
  font-size: 20px;
  font-weight: 800;
}

.sidebar button,
.board-list button {
  width: 100%;
}

.board-list {
  display: grid;
  gap: 8px;
}

.board-list button {
  background: transparent;
  color: #f8fafc;
  border: 1px solid rgba(255, 255, 255, 0.18);
  text-align: left;
}

.board-list button.active {
  background: rgba(255, 255, 255, 0.13);
}

.content {
  padding: 22px;
  overflow: auto;
}

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

.topbar h1 {
  margin: 0;
  font-size: 25px;
}

.tabs {
  display: flex;
  gap: 8px;
}

.tabs button {
  background: #dde5ec;
  color: var(--text);
}

.tabs button.active {
  background: var(--accent);
  color: white;
}

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

.auth {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.auth-card {
  width: min(430px, 100%);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 24px;
}

.auth-card h1 {
  margin: 0 0 18px;
}

.form {
  display: grid;
  gap: 10px;
}

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

.row > * {
  flex: 1;
}

.message {
  min-height: 22px;
  color: var(--danger);
}

.kanban {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(290px, 1fr);
  gap: 14px;
  align-items: start;
  overflow-x: auto;
  padding-bottom: 12px;
}

.column {
  background: #eef2f5;
  border: 1px solid var(--line);
  border-radius: 8px;
  min-height: 520px;
  padding: 12px;
}

.column h2 {
  font-size: 16px;
  margin: 0 0 10px;
}

.task {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
  box-shadow: 0 8px 22px rgba(34, 44, 64, 0.05);
}

.task strong {
  word-break: break-word;
}

.task p {
  margin: 0;
  color: var(--muted);
  white-space: pre-wrap;
  word-break: break-word;
}

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

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  padding: 16px;
}

.files {
  display: grid;
  gap: 10px;
}

.file-item,
.notification {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 12px;
}

.notification.unread {
  border-color: var(--accent);
}

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

  .sidebar {
    position: static;
  }

  .topbar,
  .row {
    align-items: stretch;
    flex-direction: column;
  }

  .tabs {
    overflow-x: auto;
  }

  .kanban {
    grid-auto-columns: minmax(260px, 86vw);
  }
}
