:root {
  color-scheme: dark;
  --bg: #0b1018;
  --bg-grid: rgba(255, 255, 255, 0.025);
  --panel: #111824;
  --panel-strong: #151f2d;
  --panel-soft: #0e1621;
  --line: rgba(168, 184, 204, 0.16);
  --line-strong: rgba(168, 184, 204, 0.28);
  --text: #ecf2f8;
  --muted: #91a0b4;
  --muted-strong: #b8c3d1;
  --green: #55d690;
  --blue: #6ba8ff;
  --yellow: #f5c15c;
  --red: #ff6d73;
  --purple: #a88dff;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
  --radius: 8px;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background:
    linear-gradient(var(--bg-grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--bg-grid) 1px, transparent 1px),
    var(--bg);
  background-size: 18px 18px;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 18% 4%, rgba(107, 168, 255, 0.12), transparent 30%),
    radial-gradient(circle at 92% 0%, rgba(85, 214, 144, 0.08), transparent 28%),
    transparent;
}

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

button {
  cursor: pointer;
}

code {
  padding: 2px 6px;
  color: #dce8f6;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid var(--line);
  border-radius: 6px;
}

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

.loader {
  width: 28px;
  height: 28px;
  border: 2px solid rgba(255, 255, 255, 0.16);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.auth-card {
  width: min(100%, 460px);
  padding: 28px;
  background: rgba(17, 24, 36, 0.94);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.setup-card {
  width: min(100%, 620px);
}

.brand-row,
.sidebar-brand,
.board-header,
.meta-strip,
.member-strip,
.task-name-cell,
.row-actions,
.profile-card,
.member-chip,
.progress-card {
  display: flex;
  align-items: center;
}

.brand-row {
  gap: 14px;
  margin-bottom: 18px;
}

.logo-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: #081119;
  font-weight: 900;
  background: var(--green);
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-radius: 8px;
  box-shadow:
    inset -4px -4px 0 rgba(0, 0, 0, 0.16),
    0 0 0 4px rgba(85, 214, 144, 0.12);
}

.logo-mark.small {
  width: 32px;
  height: 32px;
  font-size: 0.85rem;
}

.brand-logo {
  display: block;
  object-fit: contain;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 7px;
}

.auth-logo {
  width: 148px;
  max-width: 46vw;
  max-height: 58px;
  padding: 4px 8px;
}

.sidebar-logo {
  width: 136px;
  max-height: 44px;
  padding: 3px 7px;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--green);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(1.8rem, 4vw, 2.7rem);
  letter-spacing: 0;
}

h2 {
  margin-bottom: 0;
  font-size: 1.35rem;
  letter-spacing: 0;
}

.auth-copy,
.muted-copy {
  color: var(--muted);
  line-height: 1.6;
}

.setup-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.setup-list span {
  padding: 12px;
  color: var(--muted-strong);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.auth-form,
.task-form {
  display: grid;
  gap: 14px;
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted-strong);
  font-size: 0.78rem;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  color: var(--text);
  background: #0c121c;
  border: 1px solid var(--line);
  border-radius: 7px;
  outline: none;
}

input,
select {
  min-height: 38px;
  padding: 0 11px;
}

textarea {
  min-height: 96px;
  padding: 11px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(85, 214, 144, 0.66);
  box-shadow: 0 0 0 3px rgba(85, 214, 144, 0.12);
}

.primary-button,
.secondary-button,
.ghost-button,
.google-button,
.filter-pill,
.icon-button,
.link-button {
  border: 0;
  border-radius: 7px;
  transition:
    transform 0.15s ease,
    border-color 0.15s ease,
    background 0.15s ease;
}

.primary-button,
.secondary-button,
.ghost-button,
.google-button {
  min-height: 38px;
  padding: 0 14px;
  font-weight: 800;
}

.primary-button {
  color: #061018;
  background: var(--green);
  box-shadow: inset -3px -3px 0 rgba(0, 0, 0, 0.12);
}

.secondary-button {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--line);
}

.ghost-button,
.google-button {
  color: var(--text);
  background: transparent;
  border: 1px solid var(--line);
}

.primary-button:hover,
.secondary-button:hover,
.ghost-button:hover,
.google-button:hover,
.filter-pill:hover {
  transform: translateY(-1px);
  border-color: var(--line-strong);
}

.google-button {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 18px 0 16px;
}

.google-dot {
  width: 13px;
  height: 13px;
  background:
    linear-gradient(90deg, #4285f4 50%, #34a853 0) top / 100% 50% no-repeat,
    linear-gradient(90deg, #fbbc05 50%, #ea4335 0) bottom / 100% 50% no-repeat;
  border-radius: 50%;
}

.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 0.8rem;
}

.divider::before,
.divider::after {
  flex: 1;
  height: 1px;
  content: "";
  background: var(--line);
}

.link-button {
  margin-top: 16px;
  padding: 0;
  color: var(--blue);
  background: transparent;
}

.auth-mode-note,
.auth-hint {
  color: var(--muted-strong);
  line-height: 1.5;
}

.auth-mode-note {
  margin: 16px 0;
  padding: 11px 12px;
  background: rgba(85, 214, 144, 0.08);
  border: 1px solid rgba(85, 214, 144, 0.24);
  border-radius: var(--radius);
}

.auth-hint {
  margin: 14px 0 0;
  font-size: 0.82rem;
}

.message {
  margin: 14px 0;
  padding: 11px 12px;
  color: var(--muted-strong);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.message.success {
  color: #bff6d4;
  border-color: rgba(85, 214, 144, 0.34);
}

.message.error {
  color: #ffbec0;
  border-color: rgba(255, 109, 115, 0.35);
}

.workspace-shell {
  display: grid;
  min-height: 100vh;
  grid-template-columns: 260px minmax(0, 1fr);
}

.sidebar {
  position: sticky;
  top: 0;
  display: flex;
  height: 100vh;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px;
  background: rgba(9, 14, 22, 0.88);
  border-right: 1px solid var(--line);
}

.sidebar-brand {
  gap: 10px;
  color: var(--text);
  font-size: 1.1rem;
  font-weight: 900;
  text-decoration: none;
}

.workspace-name {
  display: grid;
  gap: 4px;
  margin: 24px 0;
  padding: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.workspace-name span,
.profile-card span,
.member-chip i,
.progress-card span {
  color: var(--muted);
  font-size: 0.78rem;
  font-style: normal;
}

.side-nav {
  display: grid;
  gap: 8px;
}

.side-nav button {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  padding: 0 12px;
  color: var(--muted-strong);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius);
  text-align: left;
}

.side-nav button.active,
.side-nav button:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--line);
}

.nav-icon,
.tiny-pixel {
  width: 13px;
  height: 13px;
  background: var(--blue);
  border: 2px solid rgba(255, 255, 255, 0.25);
  box-shadow: inset -2px -2px 0 rgba(0, 0, 0, 0.2);
}

.nav-icon.grid {
  background:
    linear-gradient(90deg, transparent 40%, rgba(0, 0, 0, 0.24) 0 60%, transparent 0),
    linear-gradient(transparent 40%, rgba(0, 0, 0, 0.24) 0 60%, transparent 0),
    var(--green);
}

.nav-icon.document {
  position: relative;
  background: var(--blue);
}

.nav-icon.document::after {
  position: absolute;
  right: 2px;
  bottom: 2px;
  width: 5px;
  height: 5px;
  content: "";
  background: rgba(0, 0, 0, 0.24);
  border-top: 1px solid rgba(255, 255, 255, 0.34);
  border-left: 1px solid rgba(255, 255, 255, 0.34);
}

.nav-icon.target {
  position: relative;
  background: var(--purple);
  border-radius: 50%;
}

.nav-icon.target::before,
.nav-icon.target::after {
  position: absolute;
  inset: 3px;
  content: "";
  border: 1px solid rgba(5, 11, 18, 0.42);
  border-radius: 50%;
}

.nav-icon.target::after {
  inset: 5px;
  background: rgba(5, 11, 18, 0.38);
}

.profile-card {
  position: relative;
  overflow: hidden;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(18px);
}

.profile-card::before {
  position: absolute;
  inset: 0;
  z-index: 0;
  content: "";
  pointer-events: none;
  border-radius: inherit;
  opacity: 0.9;
}

.profile-card > * {
  position: relative;
  z-index: 1;
}

.profile-card.giorgi-frame {
  background:
    linear-gradient(135deg, rgba(245, 193, 92, 0.18), rgba(255, 255, 255, 0.045) 48%),
    rgba(255, 255, 255, 0.035);
  border-color: rgba(245, 193, 92, 0.42);
  box-shadow:
    0 16px 38px rgba(245, 193, 92, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.profile-card.giorgi-frame::before {
  background:
    linear-gradient(90deg, rgba(245, 193, 92, 0.42), transparent 34%),
    radial-gradient(circle at 18% 20%, rgba(245, 193, 92, 0.18), transparent 42%);
}

.profile-card.salome-frame {
  background:
    linear-gradient(135deg, rgba(107, 168, 255, 0.18), rgba(255, 255, 255, 0.045) 48%),
    rgba(255, 255, 255, 0.035);
  border-color: rgba(107, 168, 255, 0.46);
  box-shadow:
    0 16px 38px rgba(107, 168, 255, 0.09),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.profile-card.salome-frame::before {
  background:
    linear-gradient(90deg, rgba(107, 168, 255, 0.42), transparent 34%),
    radial-gradient(circle at 18% 20%, rgba(107, 168, 255, 0.18), transparent 42%);
}

.profile-card > div:not(.avatar) {
  min-width: 0;
  flex: 1;
}

.profile-card span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.seat-switcher {
  width: 100%;
}

.avatar {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  color: #081119;
  font-size: 0.78rem;
  font-weight: 900;
  background: var(--yellow);
  border-radius: 8px;
  box-shadow: inset -3px -3px 0 rgba(0, 0, 0, 0.15);
}

.avatar.mini {
  width: 30px;
  height: 30px;
}

.avatar.green {
  background: var(--green);
}

.avatar.yellow {
  background: var(--yellow);
}

.avatar.blue {
  background: var(--blue);
}

.board-page {
  padding: 22px;
}

.board-header {
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}

.board-actions {
  display: flex;
  align-items: end;
  gap: 10px;
  flex-wrap: wrap;
}

.search-field {
  width: min(360px, 42vw);
}

.meta-strip {
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
  padding: 12px;
  background: rgba(17, 24, 36, 0.72);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.progress-card {
  gap: 10px;
}

.tiny-pixel.done {
  background: var(--green);
}

.member-strip {
  gap: 8px;
  flex-wrap: wrap;
}

.member-chip {
  gap: 8px;
  padding: 6px 8px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.member-chip.online {
  border-color: rgba(85, 214, 144, 0.34);
  box-shadow: 0 0 0 3px rgba(85, 214, 144, 0.08);
}

.filter-bar {
  display: flex;
  align-items: end;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.filter-pill {
  min-height: 38px;
  padding: 0 13px;
  color: var(--muted-strong);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
}

.filter-pill.active {
  color: var(--text);
  border-color: rgba(85, 214, 144, 0.38);
  background: rgba(85, 214, 144, 0.11);
}

.task-board {
  display: grid;
  gap: 18px;
  overflow: visible;
}

.task-section {
  --workflow-rgb: 113, 139, 172;
  --workflow-accent: #9db6d8;
  --workflow-soft: rgba(var(--workflow-rgb), 0.14);
  --workflow-border: rgba(var(--workflow-rgb), 0.24);
  position: relative;
  overflow: visible;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.018)),
    rgba(13, 19, 29, 0.62);
  border: 1px solid var(--workflow-border);
  border-radius: 14px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.045),
    0 18px 46px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.task-section::before {
  position: absolute;
  inset: 0;
  pointer-events: none;
  content: "";
  border-radius: inherit;
  background:
    linear-gradient(90deg, rgba(var(--workflow-rgb), 0.1), transparent 34%),
    radial-gradient(circle at 14% 0%, rgba(var(--workflow-rgb), 0.13), transparent 36%);
}

.section-todo {
  --workflow-rgb: 116, 143, 178;
  --workflow-accent: #9fb9da;
  --workflow-border: rgba(116, 143, 178, 0.28);
}

.section-working {
  --workflow-rgb: 238, 158, 71;
  --workflow-accent: #f0b36c;
  --workflow-border: rgba(238, 158, 71, 0.34);
}

.section-done {
  --workflow-rgb: 76, 207, 166;
  --workflow-accent: #7ddfc8;
  --workflow-border: rgba(76, 207, 166, 0.3);
}

.is-done-section {
  margin-top: 4px;
}

.task-section-header {
  position: relative;
  z-index: 1;
  display: flex;
  min-height: 64px;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px 16px;
  background:
    linear-gradient(90deg, rgba(var(--workflow-rgb), 0.11), rgba(8, 13, 21, 0.34) 42%),
    rgba(8, 13, 21, 0.34);
  border-bottom: 1px solid rgba(var(--workflow-rgb), 0.18);
}

.task-section .eyebrow {
  color: var(--workflow-accent);
  text-shadow: 0 0 18px rgba(var(--workflow-rgb), 0.28);
}

.task-section-header h2 {
  margin: 2px 0 0;
  font-size: 1rem;
}

.section-meta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-count {
  padding: 6px 9px;
  color: var(--workflow-accent);
  font-size: 0.78rem;
  font-weight: 800;
  background: rgba(var(--workflow-rgb), 0.08);
  border: 1px solid rgba(var(--workflow-rgb), 0.18);
  border-radius: 999px;
}

.section-toggle {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  color: var(--text);
  background: rgba(8, 13, 21, 0.62);
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 900;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.task-section-body {
  position: relative;
  z-index: 1;
  padding: 14px;
}

.task-card-list {
  display: grid;
  gap: 14px;
}

.section-collapsed-note,
.section-empty {
  position: relative;
  z-index: 1;
  margin: 14px;
  padding: 14px;
  color: var(--muted);
  background: rgba(8, 13, 21, 0.34);
  border: 1px solid rgba(168, 184, 204, 0.12);
  border-radius: 12px;
}

.section-empty {
  display: grid;
  justify-items: center;
  gap: 8px;
  text-align: center;
}

.section-empty strong {
  color: var(--text);
}

.task-section .tiny-pixel {
  background: rgb(var(--workflow-rgb));
  box-shadow:
    inset -2px -2px 0 rgba(0, 0, 0, 0.22),
    0 0 16px rgba(var(--workflow-rgb), 0.22);
}

.task-row {
  display: grid;
  grid-template-columns: minmax(240px, 1.8fr) 150px 130px 140px 150px minmax(180px, 1.2fr) auto;
  gap: 10px;
  align-items: center;
  min-height: 72px;
  position: relative;
  margin: 0;
  padding: 12px;
  overflow: visible;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 13px 30px rgba(0, 0, 0, 0.18);
  transition:
    background 0.3s ease,
    border-color 0.3s ease,
    box-shadow 0.3s ease,
    transform 0.3s ease;
}

.task-row > * {
  min-width: 0;
}

.task-row:hover {
  transform: translateY(-1px);
}

.task-row:has(.task-options-wrap.is-open) {
  z-index: 40;
}

.task-row.is-done {
  opacity: 0.92;
}

.task-row.is-complete .task-title-button {
  color: #b9c7d5;
  text-decoration: line-through;
}

.workflow-surface {
  --workflow-rgb: 116, 143, 178;
  --workflow-accent: #9fb9da;
  --workflow-border: rgba(var(--workflow-rgb), 0.34);
  --workflow-glow: rgba(var(--workflow-rgb), 0.14);
  isolation: isolate;
  background:
    linear-gradient(135deg, rgba(var(--workflow-rgb), 0.15), rgba(14, 20, 30, 0.76) 48%, rgba(9, 14, 22, 0.86)),
    rgba(13, 19, 29, 0.78);
  border-color: var(--workflow-border);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 0 1px rgba(var(--workflow-rgb), 0.045),
    0 14px 34px var(--workflow-glow);
  backdrop-filter: blur(14px) saturate(1.12);
  -webkit-backdrop-filter: blur(14px) saturate(1.12);
}

.workflow-surface::before {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  content: "";
  border-radius: inherit;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.07), transparent 28%),
    radial-gradient(circle at 8% 0%, rgba(var(--workflow-rgb), 0.2), transparent 42%);
  opacity: 0.78;
  transition:
    opacity 0.3s ease,
    background 0.3s ease;
}

.workflow-surface > * {
  position: relative;
  z-index: 1;
}

.workflow-to-do {
  --workflow-rgb: 116, 143, 178;
  --workflow-accent: #9fb9da;
  --workflow-border: rgba(116, 143, 178, 0.36);
  --workflow-glow: rgba(116, 143, 178, 0.12);
}

.workflow-in-progress {
  --workflow-rgb: 238, 158, 71;
  --workflow-accent: #f0b36c;
  --workflow-border: rgba(238, 158, 71, 0.42);
  --workflow-glow: rgba(238, 158, 71, 0.16);
}

.workflow-done {
  --workflow-rgb: 76, 207, 166;
  --workflow-accent: #7ddfc8;
  --workflow-border: rgba(76, 207, 166, 0.38);
  --workflow-glow: rgba(76, 207, 166, 0.14);
}

.task-row.workflow-surface:hover {
  border-color: rgba(var(--workflow-rgb), 0.58);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 0 0 1px rgba(var(--workflow-rgb), 0.07),
    0 18px 42px rgba(var(--workflow-rgb), 0.2);
}

.task-row.workflow-surface .complete-toggle.checked {
  background: rgb(var(--workflow-rgb));
  border-color: rgba(255, 255, 255, 0.34);
  box-shadow:
    inset -2px -2px 0 rgba(0, 0, 0, 0.2),
    0 0 18px rgba(var(--workflow-rgb), 0.24);
}

.assignee-surface {
  isolation: isolate;
  backdrop-filter: blur(14px) saturate(1.16);
  -webkit-backdrop-filter: blur(14px) saturate(1.16);
}

.assignee-surface::before {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  content: "";
  border-radius: inherit;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 26%),
    radial-gradient(circle at 8% 0%, var(--assignee-glow), transparent 42%);
  opacity: 0.78;
  transition:
    opacity 0.3s ease,
    background 0.3s ease;
}

.assignee-surface > * {
  position: relative;
  z-index: 1;
}

.assignee-neutral {
  --assignee-glow: rgba(168, 184, 204, 0.08);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.045), rgba(13, 19, 29, 0.78)),
    rgba(13, 19, 29, 0.78);
  border-color: var(--line);
}

.assignee-giorgi {
  --assignee-glow: rgba(255, 139, 41, 0.23);
  background:
    linear-gradient(135deg, rgba(255, 139, 41, 0.2), rgba(64, 29, 10, 0.42) 46%, rgba(13, 18, 27, 0.78)),
    rgba(13, 19, 29, 0.78);
  border-color: rgba(255, 151, 55, 0.5);
  box-shadow:
    inset 0 1px 0 rgba(255, 235, 210, 0.11),
    0 0 0 1px rgba(255, 139, 41, 0.06),
    0 14px 34px rgba(255, 116, 23, 0.13);
}

.assignee-salome {
  --assignee-glow: rgba(76, 157, 255, 0.24);
  background:
    linear-gradient(135deg, rgba(58, 133, 255, 0.2), rgba(12, 39, 89, 0.46) 48%, rgba(13, 18, 27, 0.78)),
    rgba(13, 19, 29, 0.78);
  border-color: rgba(83, 169, 255, 0.48);
  box-shadow:
    inset 0 1px 0 rgba(218, 238, 255, 0.1),
    0 0 0 1px rgba(76, 157, 255, 0.06),
    0 14px 34px rgba(48, 128, 255, 0.14);
}

.task-row.assignee-giorgi:hover {
  background:
    linear-gradient(135deg, rgba(255, 154, 54, 0.26), rgba(79, 34, 11, 0.48) 46%, rgba(15, 20, 29, 0.82)),
    rgba(15, 21, 30, 0.82);
  border-color: rgba(255, 174, 75, 0.64);
  box-shadow:
    inset 0 1px 0 rgba(255, 239, 220, 0.14),
    0 0 0 1px rgba(255, 139, 41, 0.09),
    0 18px 42px rgba(255, 116, 23, 0.18);
}

.task-row.assignee-salome:hover {
  background:
    linear-gradient(135deg, rgba(76, 157, 255, 0.26), rgba(13, 47, 106, 0.54) 48%, rgba(15, 20, 29, 0.82)),
    rgba(15, 21, 30, 0.82);
  border-color: rgba(104, 187, 255, 0.64);
  box-shadow:
    inset 0 1px 0 rgba(224, 242, 255, 0.14),
    0 0 0 1px rgba(76, 157, 255, 0.09),
    0 18px 42px rgba(48, 128, 255, 0.2);
}

.task-collapse-row {
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
}

.task-collapse-button {
  display: flex;
  width: 100%;
  min-height: 48px;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  color: var(--muted-strong);
  background: transparent;
  border: 0;
  text-align: left;
}

.task-collapse-button strong {
  color: var(--text);
}

.task-collapse-button em {
  margin-left: auto;
  color: var(--muted);
  font-size: 0.78rem;
  font-style: normal;
}

.collapse-symbol {
  display: grid;
  width: 24px;
  height: 24px;
  flex: 0 0 auto;
  place-items: center;
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  border-radius: 6px;
  font-weight: 900;
}

.task-name-cell {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.complete-toggle {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  cursor: pointer;
  background: #0c121c;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  box-shadow: inset -2px -2px 0 rgba(0, 0, 0, 0.22);
}

.complete-toggle.checked {
  position: relative;
  background: var(--green);
  border-color: rgba(255, 255, 255, 0.34);
}

.complete-toggle.checked::after {
  position: absolute;
  top: 2px;
  left: 6px;
  width: 5px;
  height: 10px;
  content: "";
  border: solid #071016;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.task-title-button {
  min-width: 0;
  overflow: hidden;
  padding: 0;
  color: var(--text);
  background: transparent;
  border: 0;
  font-weight: 800;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.task-title-wrap {
  display: grid;
  min-width: 0;
  gap: 6px;
}

.task-status-chip {
  width: fit-content;
  padding: 3px 7px;
  font-size: 0.68rem;
  font-weight: 900;
  line-height: 1;
  background: rgba(8, 13, 21, 0.46);
  border: 1px solid rgba(168, 184, 204, 0.15);
  border-radius: 999px;
}

.done-action {
  min-height: 32px;
  margin-left: auto;
  padding: 0 12px;
  color: #c4f5d7;
  background:
    linear-gradient(135deg, rgba(85, 214, 144, 0.16), rgba(8, 13, 21, 0.58)),
    rgba(8, 13, 21, 0.58);
  border: 1px solid rgba(85, 214, 144, 0.32);
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(85, 214, 144, 0.08);
}

.done-action:hover {
  border-color: rgba(85, 214, 144, 0.5);
  box-shadow: 0 12px 26px rgba(85, 214, 144, 0.13);
}

.task-row select,
.task-row input {
  min-height: 34px;
  font-size: 0.86rem;
  background: rgba(8, 13, 21, 0.7);
  border-color: rgba(203, 216, 232, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
  backdrop-filter: blur(8px);
  transition:
    background 0.3s ease,
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}

.task-notes-cell {
  display: flex;
  min-height: 34px;
  min-width: 0;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  color: var(--muted-strong);
  background: rgba(8, 13, 21, 0.7);
  border: 1px solid rgba(203, 216, 232, 0.18);
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
  backdrop-filter: blur(8px);
  transition:
    background 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.task-notes-cell.is-expanded {
  border-color: rgba(var(--workflow-rgb), 0.34);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.055),
    0 0 0 1px rgba(var(--workflow-rgb), 0.05);
}

.task-notes-cell.is-empty .notes-preview {
  color: var(--muted);
}

.notes-preview {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  color: #d9e4ef;
  font-size: 0.86rem;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.note-toggle {
  display: inline-flex;
  min-height: 26px;
  flex: 0 0 auto;
  align-items: center;
  gap: 5px;
  padding: 0 7px;
  color: var(--workflow-accent);
  background: rgba(var(--workflow-rgb), 0.08);
  border: 1px solid rgba(var(--workflow-rgb), 0.2);
  border-radius: 7px;
  font-size: 0.72rem;
  font-weight: 900;
  white-space: nowrap;
}

.note-toggle:hover {
  background: rgba(var(--workflow-rgb), 0.13);
  border-color: rgba(var(--workflow-rgb), 0.34);
}

.note-chevron {
  font-size: 0.8rem;
  line-height: 1;
}

.task-note-expansion {
  grid-column: 1 / -1;
  margin-top: -2px;
  padding: 12px 14px;
  overflow: hidden;
  color: #dce7f2;
  background:
    linear-gradient(135deg, rgba(var(--workflow-rgb), 0.1), rgba(8, 13, 21, 0.68)),
    rgba(8, 13, 21, 0.68);
  border: 1px solid rgba(var(--workflow-rgb), 0.2);
  border-radius: 12px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 12px 28px rgba(0, 0, 0, 0.18);
  animation: noteExpand 0.28s ease both;
}

.task-note-expansion p {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.55;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

@keyframes noteExpand {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.assignee-select.assignee-tone-giorgi {
  border-color: rgba(255, 166, 77, 0.26);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.035),
    0 0 0 1px rgba(255, 166, 77, 0.04);
}

.assignee-select.assignee-tone-salome {
  border-color: rgba(103, 181, 255, 0.26);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.035),
    0 0 0 1px rgba(103, 181, 255, 0.04);
}

.status-select,
.priority-select {
  font-weight: 800;
}

.tone-to-do {
  color: #cfe0f2;
  border-color: rgba(116, 143, 178, 0.34);
}

.tone-in-progress {
  color: #ffe1b8;
  border-color: rgba(238, 158, 71, 0.42);
}

.tone-done {
  color: #c9f8ed;
  border-color: rgba(76, 207, 166, 0.4);
}

.task-status-chip.tone-to-do,
.status-select.tone-to-do {
  background:
    linear-gradient(135deg, rgba(116, 143, 178, 0.16), rgba(8, 13, 21, 0.54)),
    rgba(8, 13, 21, 0.58);
}

.task-status-chip.tone-in-progress,
.status-select.tone-in-progress {
  background:
    linear-gradient(135deg, rgba(238, 158, 71, 0.2), rgba(8, 13, 21, 0.54)),
    rgba(8, 13, 21, 0.58);
}

.task-status-chip.tone-done,
.status-select.tone-done {
  background:
    linear-gradient(135deg, rgba(76, 207, 166, 0.17), rgba(8, 13, 21, 0.54)),
    rgba(8, 13, 21, 0.58);
}

.tone-high {
  color: #ffd0d2;
  border-color: rgba(255, 109, 115, 0.32);
}

.tone-medium {
  color: #ffe2a3;
  border-color: rgba(245, 193, 92, 0.32);
}

.tone-low {
  color: #c7d7f8;
  border-color: rgba(107, 168, 255, 0.28);
}

.row-actions {
  display: flex;
  gap: 6px;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.icon-button {
  min-height: 30px;
  padding: 0 9px;
  color: var(--muted-strong);
  background: rgba(8, 13, 21, 0.56);
  border: 1px solid var(--line);
  backdrop-filter: blur(8px);
}

.icon-button.danger {
  color: #ffb6b8;
}

.icon-button.restore {
  color: #dbe8ff;
  border-color: rgba(107, 168, 255, 0.24);
}

.task-options-wrap {
  position: relative;
  display: inline-flex;
  z-index: 45;
}

.task-menu-button {
  min-width: 34px;
  padding: 0 8px;
  letter-spacing: 1px;
}

.task-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 60;
  display: grid;
  width: max-content;
  min-width: 118px;
  padding: 6px;
  background: rgba(10, 15, 23, 0.94);
  border: 1px solid rgba(255, 109, 115, 0.22);
  border-radius: 10px;
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(14px);
}

.task-menu .icon-button {
  justify-content: center;
  width: 100%;
  min-width: 96px;
}

.modal-danger-slot,
.modal-submit-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-submit-actions {
  margin-left: auto;
}

.empty-state {
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 46px 20px;
  color: var(--muted);
  text-align: center;
}

.empty-state strong {
  color: var(--text);
}

.page-heading h1 {
  margin-bottom: 4px;
}

.page-subtitle {
  margin: 5px 0 0;
  color: var(--muted);
}

.notes-workspace {
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
}

.notes-list-panel,
.note-editor-panel,
.goal-card {
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.018)),
    rgba(13, 19, 29, 0.72);
  border: 1px solid rgba(168, 184, 204, 0.18);
  border-radius: 14px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.055),
    0 18px 46px rgba(0, 0, 0, 0.22);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.notes-list-panel,
.note-editor-panel {
  min-height: 620px;
  padding: 14px;
}

.panel-header,
.note-editor-top,
.note-editor-footer,
.goal-card header,
.goal-card footer,
.goal-progress-row {
  display: flex;
  align-items: center;
}

.panel-header {
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.notes-search {
  width: 100%;
  margin-bottom: 12px;
}

.notes-list {
  display: grid;
  max-height: 540px;
  gap: 10px;
  overflow: auto;
  padding-right: 4px;
}

.note-card {
  display: grid;
  gap: 9px;
  padding: 12px;
  background:
    linear-gradient(135deg, rgba(107, 168, 255, 0.08), rgba(11, 17, 26, 0.72)),
    rgba(11, 17, 26, 0.72);
  border: 1px solid rgba(168, 184, 204, 0.16);
  border-radius: 12px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition:
    transform 0.25s ease,
    background 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.note-card:hover {
  transform: translateY(-1px);
  border-color: rgba(107, 168, 255, 0.32);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    0 14px 28px rgba(24, 72, 130, 0.14);
}

.note-card.selected {
  background:
    linear-gradient(135deg, rgba(107, 168, 255, 0.16), rgba(168, 141, 255, 0.12) 44%, rgba(11, 17, 26, 0.76)),
    rgba(11, 17, 26, 0.78);
  border-color: rgba(141, 153, 255, 0.56);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.09),
    0 0 0 1px rgba(168, 141, 255, 0.08),
    0 18px 36px rgba(91, 116, 255, 0.18);
}

.note-card-main {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  gap: 10px;
  padding: 0;
  color: inherit;
  background: transparent;
  border: 0;
  text-align: left;
}

.note-icon {
  position: relative;
  display: block;
  width: 28px;
  height: 30px;
  background:
    linear-gradient(135deg, rgba(107, 168, 255, 0.9), rgba(168, 141, 255, 0.72)),
    var(--blue);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 7px;
  box-shadow:
    inset -3px -3px 0 rgba(0, 0, 0, 0.18),
    0 0 16px rgba(107, 168, 255, 0.14);
}

.note-icon::after {
  position: absolute;
  right: 4px;
  bottom: 4px;
  left: 5px;
  height: 2px;
  content: "";
  background: rgba(4, 12, 20, 0.42);
  box-shadow: 0 -6px 0 rgba(4, 12, 20, 0.3);
}

.note-card-copy {
  display: grid;
  min-width: 0;
  gap: 5px;
}

.note-card-copy strong {
  overflow: hidden;
  color: var(--text);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.note-card-copy em {
  display: -webkit-box;
  overflow: hidden;
  color: var(--muted);
  font-size: 0.83rem;
  font-style: normal;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.note-card.is-expanded .note-card-copy em {
  display: block;
  overflow: visible;
  white-space: normal;
}

.note-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: var(--muted);
  font-size: 0.76rem;
}

.category-tag {
  padding: 4px 7px;
  color: #dfeaff;
  background: rgba(107, 168, 255, 0.1);
  border: 1px solid rgba(107, 168, 255, 0.2);
  border-radius: 999px;
  font-weight: 800;
}

.note-card-toggle {
  justify-self: start;
  min-height: 26px;
  padding: 0 8px;
  color: var(--blue);
  background: rgba(107, 168, 255, 0.08);
  border: 1px solid rgba(107, 168, 255, 0.2);
  border-radius: 7px;
  font-size: 0.72rem;
  font-weight: 900;
}

.note-editor-panel {
  display: grid;
  grid-template-rows: auto auto minmax(320px, 1fr) auto;
  gap: 12px;
  background:
    linear-gradient(135deg, rgba(107, 168, 255, 0.08), rgba(168, 141, 255, 0.055) 42%, rgba(13, 19, 29, 0.78)),
    rgba(13, 19, 29, 0.78);
}

.note-editor-top {
  gap: 12px;
}

.note-title-field {
  flex: 1;
}

.note-category-field {
  width: 170px;
}

.note-title-input {
  min-height: 44px;
  font-size: 1.2rem;
  font-weight: 900;
}

.format-toolbar {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  padding: 9px;
  background: rgba(8, 13, 21, 0.46);
  border: 1px solid rgba(168, 184, 204, 0.14);
  border-radius: 12px;
}

.format-toolbar button,
.toolbar-select,
.toolbar-color {
  min-height: 32px;
  color: var(--muted-strong);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid var(--line);
  border-radius: 7px;
  font-size: 0.78rem;
  font-weight: 900;
}

.format-toolbar button {
  padding: 0 10px;
}

.format-toolbar button:hover,
.toolbar-select:hover {
  color: var(--text);
  border-color: rgba(107, 168, 255, 0.34);
  background: rgba(107, 168, 255, 0.08);
}

.toolbar-select {
  width: auto;
  min-width: 126px;
}

.toolbar-color {
  width: 38px;
  padding: 3px;
}

.note-body-input {
  min-height: 100%;
  max-height: 52vh;
  overflow: auto;
  padding: 16px;
  color: #e7f0fa;
  background: rgba(8, 13, 21, 0.62);
  border-color: rgba(168, 184, 204, 0.16);
  line-height: 1.65;
  resize: vertical;
}

.note-editor-footer {
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 0.82rem;
}

.autosave-status {
  color: #c7f2de;
}

.danger-subtle {
  color: #ffb6b8;
}

.compact-empty {
  margin: 0;
}

.empty-editor {
  place-items: center;
}

.goal-tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.goals-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.goal-card {
  position: relative;
  display: grid;
  gap: 14px;
  min-height: 230px;
  padding: 16px;
  overflow: visible;
  background:
    linear-gradient(135deg, rgba(107, 168, 255, 0.12), rgba(168, 141, 255, 0.08) 44%, rgba(13, 19, 29, 0.82)),
    rgba(13, 19, 29, 0.82);
  transition:
    transform 0.28s ease,
    border-color 0.28s ease,
    box-shadow 0.28s ease;
}

.goal-card:hover {
  transform: translateY(-2px);
  border-color: rgba(141, 153, 255, 0.44);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 20px 44px rgba(84, 96, 205, 0.18);
}

.goal-card.completed {
  background:
    linear-gradient(135deg, rgba(85, 214, 144, 0.12), rgba(76, 207, 166, 0.06) 42%, rgba(13, 19, 29, 0.82)),
    rgba(13, 19, 29, 0.82);
  border-color: rgba(85, 214, 144, 0.28);
}

.goal-card header {
  justify-content: flex-start;
  gap: 8px;
}

.goal-status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--purple);
  box-shadow: 0 0 18px rgba(168, 141, 255, 0.4);
}

.goal-status-dot.done {
  background: var(--green);
  box-shadow: 0 0 18px rgba(85, 214, 144, 0.36);
}

.goal-status {
  color: var(--muted-strong);
  font-size: 0.78rem;
  font-weight: 900;
}

.goal-card h2 {
  font-size: 1.15rem;
}

.goal-card p {
  margin: 0;
  color: var(--muted-strong);
  line-height: 1.55;
}

.goal-card footer {
  justify-content: space-between;
  color: var(--muted);
  font-size: 0.82rem;
}

.goal-card-menu {
  position: relative;
  z-index: 20;
  margin-left: auto;
}

.goal-progress-row {
  gap: 10px;
}

.goal-progress-row span {
  min-width: 42px;
  color: #dfe7ff;
  font-weight: 900;
}

.goal-progress-track {
  position: relative;
  flex: 1;
  height: 10px;
  overflow: hidden;
  background: rgba(8, 13, 21, 0.72);
  border: 1px solid rgba(168, 184, 204, 0.14);
  border-radius: 999px;
}

.goal-progress-track i {
  display: block;
  width: var(--goal-progress);
  height: 100%;
  background: linear-gradient(90deg, var(--blue), var(--purple));
  border-radius: inherit;
  box-shadow: 0 0 18px rgba(107, 168, 255, 0.35);
  animation: progressRise 0.8s ease both;
}

@keyframes progressRise {
  from {
    width: 0;
  }
}

.goal-menu {
  border-color: rgba(168, 141, 255, 0.24);
}

.goal-menu .icon-button {
  min-width: 116px;
}

.goal-empty {
  grid-column: 1 / -1;
}

.passcode-modal {
  background:
    linear-gradient(135deg, rgba(107, 168, 255, 0.1), rgba(168, 141, 255, 0.06) 45%, rgba(17, 24, 36, 0.94)),
    rgba(17, 24, 36, 0.94);
}

.passcode-modal.has-error {
  border-color: rgba(255, 109, 115, 0.48);
  box-shadow:
    0 0 0 1px rgba(255, 109, 115, 0.08),
    var(--shadow);
}

.pin-input {
  min-height: 48px;
  text-align: center;
  font-size: 1.4rem;
  font-weight: 900;
  letter-spacing: 0.3rem;
}

.passcode-error {
  margin: -4px 0 0;
  color: #ffb6b8;
  font-size: 0.86rem;
  font-weight: 800;
}

.goal-detail-card {
  background:
    linear-gradient(135deg, rgba(107, 168, 255, 0.08), rgba(168, 141, 255, 0.055) 46%, rgba(17, 24, 36, 0.9)),
    rgba(17, 24, 36, 0.9);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(2, 5, 8, 0.64);
  backdrop-filter: blur(8px);
  z-index: 20;
}

.modal-card {
  width: min(100%, 620px);
  max-height: min(760px, 92vh);
  overflow: auto;
  padding: 22px;
  background: var(--panel);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.task-detail-card {
  position: relative;
  overflow: auto;
  background: rgba(17, 24, 36, 0.84);
  transition:
    background 0.3s ease,
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}

.task-detail-card.assignee-giorgi {
  background:
    linear-gradient(135deg, rgba(255, 139, 41, 0.17), rgba(49, 24, 12, 0.42) 48%, rgba(17, 24, 36, 0.86)),
    rgba(17, 24, 36, 0.86);
}

.task-detail-card.assignee-salome {
  background:
    linear-gradient(135deg, rgba(58, 133, 255, 0.18), rgba(13, 38, 88, 0.44) 48%, rgba(17, 24, 36, 0.86)),
    rgba(17, 24, 36, 0.86);
}

.task-detail-card label,
.task-detail-card input,
.task-detail-card select,
.task-detail-card textarea,
.task-detail-card button,
.task-detail-card header {
  position: relative;
  z-index: 1;
}

.small-modal {
  width: min(100%, 460px);
}

.modal-card header,
.task-form footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.modal-card header {
  margin-bottom: 18px;
}

.icon-close {
  width: 34px;
  height: 34px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  border-radius: 7px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.mobile-label {
  display: none;
}

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

  .sidebar {
    position: relative;
    height: auto;
    gap: 16px;
  }

  .sidebar-top {
    display: grid;
    gap: 14px;
  }

  .workspace-name {
    margin: 0;
  }

  .side-nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .profile-card {
    align-items: start;
  }

  .board-header,
  .meta-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .board-actions,
  .search-field {
    width: 100%;
  }

  .board-actions > * {
    flex: 1;
  }

  .table-head {
    display: none;
  }

  .task-board {
    gap: 18px;
  }

  .task-section-body {
    padding: 14px;
  }

  .task-card-list {
    gap: 16px;
  }

  .task-row {
    grid-template-columns: 1fr;
    gap: 9px;
    padding: 16px;
    border-radius: 14px;
  }

  .task-row > * {
    padding: 0;
  }

  .task-name-cell {
    align-items: flex-start;
    margin-bottom: 6px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(168, 184, 204, 0.12);
  }

  .task-title-wrap {
    gap: 7px;
  }

  .task-title-button {
    white-space: normal;
  }

  .task-row select,
  .task-row input {
    width: 100%;
    min-height: 40px;
  }

  .task-notes-cell {
    width: 100%;
    min-height: 40px;
  }

  .task-note-expansion {
    margin-top: 0;
    padding: 12px;
  }

  .mobile-label {
    display: block;
    margin-top: 2px;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
  }

  .row-actions {
    gap: 8px;
    justify-content: stretch;
    margin-top: 8px;
  }

  .row-actions button {
    flex: 1;
    min-height: 36px;
  }

  .task-options-wrap {
    flex: 1;
  }

  .task-menu {
    right: 0;
    left: 0;
  }

  .notes-workspace {
    grid-template-columns: 1fr;
  }

  .notes-list-panel,
  .note-editor-panel {
    min-height: auto;
  }

  .notes-list {
    max-height: 360px;
  }

  .goals-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .board-page,
  .sidebar,
  .auth-shell {
    padding: 14px;
  }

  .auth-card,
  .modal-card {
    padding: 18px;
  }

  .board-actions,
  .filter-bar,
  .form-grid {
    display: grid;
    grid-template-columns: 1fr;
  }

  .side-nav {
    grid-template-columns: 1fr;
  }

  .task-board {
    gap: 20px;
  }

  .task-section {
    border-radius: 16px;
  }

  .task-section-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
    padding: 14px;
  }

  .section-meta {
    width: 100%;
    justify-content: space-between;
  }

  .task-section-body {
    padding: 14px;
  }

  .task-card-list {
    gap: 18px;
  }

  .task-row {
    min-height: auto;
    padding: 16px;
  }

  .task-name-cell {
    flex-wrap: wrap;
  }

  .done-action {
    width: 100%;
    margin-left: 30px;
  }

  .task-form footer,
  .modal-submit-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .modal-submit-actions {
    width: 100%;
    margin-left: 0;
  }

  .modal-danger-slot {
    width: 100%;
  }

  .modal-danger-slot .icon-button {
    width: 100%;
  }

  .note-editor-top,
  .note-editor-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .note-category-field {
    width: 100%;
  }

  .format-toolbar {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .format-toolbar button,
  .toolbar-select,
  .toolbar-color {
    width: 100%;
  }

  .toolbar-select {
    grid-column: 1 / -1;
  }

  .toolbar-color {
    min-width: 100%;
  }

  .note-body-input {
    max-height: 48vh;
  }

  .goal-card {
    min-height: auto;
  }
}
