:root {
  --deep: rgb(44, 94, 173);
  --mid: rgb(21, 145, 220);
  --light: rgb(75, 184, 250);
  --pale: rgb(196, 226, 245);
  --white: #ffffff;
  --text-dark: #16324a;
  --text-muted: #5b7c9a;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  min-height: 100vh;
  font-family:
    "Segoe UI",
    system-ui,
    -apple-system,
    sans-serif;
  background: linear-gradient(
    135deg,
    var(--deep) 0%,
    var(--mid) 45%,
    var(--light) 100%
  );
  padding: 22px;
}

.app {
  width: 100%;
  max-width: 1300px;
  margin: 0 auto;
  height: calc(100vh - 44px);
  display: flex;
  flex-direction: column;
}

.header {
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(6px);
  color: var(--white);
  padding: 18px 26px;
  border-radius: 18px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  flex-shrink: 0;
}

.header-left h1 {
  font-size: 22px;
  font-weight: 700;
}

.header-left p {
  font-size: 12.5px;
  color: var(--pale);
  margin-top: 2px;
}

.progress-wrap {
  min-width: 220px;
  flex: 1;
  max-width: 320px;
}

.progress-bar-bg {
  background: rgba(255, 255, 255, 0.25);
  border-radius: 10px;
  height: 8px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background: var(--white);
  width: 0%;
  border-radius: 10px;
  transition: width 0.35s ease;
}

.progress-label {
  font-size: 11.5px;
  color: var(--pale);
  margin-top: 6px;
  display: flex;
  justify-content: space-between;
}

.board {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  min-height: 0;
}

.column {
  background: var(--white);
  border-radius: 18px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  min-height: 0;
  box-shadow: 0 20px 45px rgba(21, 60, 120, 0.25);
}

.column-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  flex-shrink: 0;
}

.column-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-dark);
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.col-todo .dot {
  background: var(--deep);
}
.col-monitor .dot {
  background: var(--mid);
}
.col-next .dot {
  background: var(--light);
}

.count-badge {
  background: var(--pale);
  color: var(--deep);
  font-size: 11.5px;
  font-weight: 700;
  padding: 2px 9px;
  border-radius: 20px;
}

.input-row {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
  flex-shrink: 0;
}

.input-row input[type="text"] {
  flex: 1;
  border: 2px solid var(--pale);
  border-radius: 10px;
  padding: 9px 11px;
  font-size: 13.5px;
  color: var(--text-dark);
  outline: none;
  min-width: 0;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.input-row input[type="text"]:focus {
  border-color: var(--light);
  box-shadow: 0 0 0 3px rgba(75, 184, 250, 0.2);
}

.add-btn {
  background: linear-gradient(135deg, var(--mid), var(--deep));
  color: var(--white);
  border: none;
  border-radius: 10px;
  padding: 0 14px;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  flex-shrink: 0;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
  box-shadow: 0 6px 14px rgba(44, 94, 173, 0.3);
}

.add-btn:hover {
  transform: translateY(-2px);
}
.add-btn:active {
  transform: translateY(0px);
}

.task-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
  overflow: visible;
}

.task-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #f6fbff;
  border: 1.5px solid var(--pale);
  border-radius: 12px;
  padding: 10px 12px;
  animation: slideIn 0.25s ease;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.checkbox {
  width: 20px;
  height: 20px;
  min-width: 20px;
  border-radius: 50%;
  border: 2px solid var(--light);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  background: var(--white);
  margin-top: 1px;
}

.checkbox.checked {
  background: linear-gradient(135deg, var(--mid), var(--deep));
  border-color: var(--deep);
}

.checkbox svg {
  width: 11px;
  height: 11px;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.checkbox.checked svg {
  opacity: 1;
}

.task-text {
  flex: 1;
  font-size: 13.5px;
  line-height: 1.35;
  color: var(--text-dark);
  word-break: break-word;
  transition: color 0.2s ease;
}

.task-text.done {
  color: var(--text-muted);
  text-decoration: line-through;
}

.delete-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 14px;
  padding: 2px 5px;
  border-radius: 8px;
  transition: all 0.2s ease;
  line-height: 1;
  flex-shrink: 0;
}

.delete-btn:hover {
  background: #ffe3e3;
  color: #d64545;
}

.empty-state {
  text-align: center;
  padding: 24px 10px;
  color: var(--text-muted);
  font-size: 12.5px;
}

.empty-state .icon {
  font-size: 28px;
  margin-bottom: 6px;
}

.notification-modal {
  position: fixed;
  bottom: 22px;
  right: 22px;
  z-index: 10;
  max-width: min(360px, calc(100vw - 44px));
  transform: translateY(-20px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.notification-modal[aria-hidden="false"] {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.notification-content {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 14px;
  color: var(--text-dark);
  background: var(--white);
  border-left: 4px solid var(--mid);
  border-radius: 10px;
  box-shadow: 0 12px 28px rgba(21, 60, 120, 0.25);
  font-size: 13px;
}

.notification-content strong {
  white-space: nowrap;
}

.notification-modal.error .notification-content {
  border-left-color: #d64545;
}

.notification-content button {
  margin-left: auto;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

@media (max-width: 900px) {
  .app {
    height: auto;
  }
  .board {
    grid-template-columns: 1fr;
  }
  body {
    overflow-y: auto;
  }
}
