/* Homepage only: carry the poster's neutral black and red into the directory. */
body.theme-dark[data-page="overview"] {
  background: #101011;
  min-height: 100svh;
  padding-bottom: calc(64px + env(safe-area-inset-bottom));
}

#overview {
  gap: 0;
  padding-bottom: 24px;
  background: #101011;
}

#overview .welcome-poster-card::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 20px;
  background: linear-gradient(transparent, #241014);
  pointer-events: none;
}

#overview .task-links {
  position: relative;
  isolation: isolate;
  width: calc(100% - 40px);
  margin: 0 auto;
  padding-top: 24px;
  gap: 12px;
}

#overview .task-links::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0 -20px auto;
  height: 140px;
  background: linear-gradient(#241014, rgba(36, 16, 20, 0));
  pointer-events: none;
}

body.theme-dark #overview .task-links > a {
  grid-template-columns: minmax(0, 1fr) 18px;
  grid-template-rows: 24px 26px;
  align-content: space-between;
  gap: 10px;
  min-height: clamp(78px, 12.3svh, 104px);
  padding: 15px 17px;
  background: #1c1b1e;
  border: 1px solid #323034;
  border-radius: 12px;
  box-shadow: none;
  color: #f5f2f2;
}

body.theme-dark #overview .task-links > a > .icon {
  grid-column: 1 / -1;
  width: 24px;
  height: 24px;
  color: #f03a43;
  stroke-width: 1.6;
}

#overview .task-links strong {
  font-size: 18px;
  line-height: 26px;
  font-weight: 550;
  letter-spacing: .025em;
}

body.theme-dark #overview .task-arrow {
  color: #8e878c;
  font-size: 18px;
  line-height: 26px;
  font-weight: 400;
}

body.theme-dark #overview .task-links > a.is-selected {
  background: linear-gradient(120deg, #b71929, #8c1221);
  border-color: #c12a38;
}

body.theme-dark #overview .task-links > a.is-selected > .icon,
body.theme-dark #overview .is-selected .task-arrow {
  color: #fff3f3;
}

body.theme-dark #overview .task-links > a:hover {
  background: #282327;
  border-color: #65545b;
  transform: translateY(-1px);
}

body.theme-dark #overview .task-links > a.is-selected:hover {
  background: #bc2030;
  border-color: #e53b49;
}

body.theme-dark #overview .task-links > a:focus-visible {
  outline: 2px solid #fa5962;
  outline-offset: 4px;
}

body.theme-dark[data-page="overview"] .mobile-nav {
  background: rgba(16, 16, 17, .98);
  border-color: #2d292c;
  box-shadow: none;
}

body.theme-dark[data-page="overview"] .mobile-nav a {
  color: #a29b9f;
  font-size: 12px;
}

body.theme-dark[data-page="overview"] .mobile-nav a.active {
  color: #f0444d;
}

body.theme-dark[data-page="overview"] .mobile-nav a > .icon {
  width: 21px;
  height: 21px;
  stroke-width: 1.6;
}

@media (max-width: 370px), (max-height: 700px) {
  #overview { padding-bottom: 16px; }
  #overview .task-links { width: calc(100% - 32px); padding-top: 16px; gap: 10px; }
  #overview .task-links::before { inset-inline: -16px; }
  body.theme-dark #overview .task-links > a {
    min-height: 78px;
    grid-template-rows: 20px 24px;
    padding: 11px 14px;
    gap: 8px;
  }
  body.theme-dark #overview .task-links > a > .icon { width: 20px; height: 20px; }
  #overview .task-links strong { font-size: 17px; line-height: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  #overview .task-links > a { transition: none; }
}

/* Immediate finger/keyboard press feedback; the chosen card stays red on return. */
body.theme-dark #overview .task-links > a:active {
  background: linear-gradient(120deg, #b71929, #8c1221);
  border-color: #c12a38;
  color: #fff3f3;
  transform: none;
}
body.theme-dark #overview .task-links > a:active > .icon,
body.theme-dark #overview .task-links > a:active .task-arrow { color: #fff3f3; }
