/* todo.css — /todo/ (To-Do List → CutDone converter). Loaded ONLY on
   /todo/index.html, so nothing here touches main.css or any other page.
   Reuses main.css custom properties (--color-*, --shadow-card, .wrap,
   .btn*, .section*) so this page still looks like CutDone. A few small
   component styles (.chip-ish mode toggle, .btn-text) are duplicated here
   from build.css rather than loading that file, since build.css documents
   itself as build.html-only. */

.btn-text {
  display: inline-block;
  background: none;
  border: none;
  color: var(--color-muted);
  text-decoration: underline;
  cursor: pointer;
  padding: 8px 4px;
  font: inherit;
}
.btn-text:hover { color: var(--color-ink); }

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---- Hero ---- */
.todo-hero {
  padding: 44px 0 8px;
  text-align: center;
}
.todo-hero h1 { font-size: 32px; margin: 0 0 12px; letter-spacing: -0.01em; max-width: 760px; margin-left: auto; margin-right: auto; }
.todo-hero .sub { color: var(--color-muted); font-size: 17px; margin: 0 auto 14px; max-width: 560px; }
.todo-hero .trust-line { font-size: 13.5px; color: var(--color-muted); font-weight: 600; }

/* ---- Converter tool card ---- */
.todo-tool {
  padding: 28px 0 60px;
}
.todo-tool-card {
  background: var(--color-paper);
  border: 1px solid var(--color-line);
  border-radius: 18px;
  box-shadow: var(--shadow-card);
  padding: 24px;
  max-width: 720px;
  margin: 0 auto;
}
.todo-step-title {
  font-size: 15px;
  font-weight: 700;
  margin: 0 0 10px;
}
.todo-step + .todo-step {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--color-line);
}

.todo-textarea-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.todo-textarea {
  width: 100%;
  min-height: 160px;
  resize: vertical;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1.5px solid var(--color-line);
  font-size: 15px;
  font-family: inherit;
  line-height: 1.5;
  background: var(--color-bg);
}
.todo-textarea:focus { outline: none; border-color: var(--color-accent); }
.todo-textarea-hint { font-size: 13px; color: var(--color-muted); margin: 0; }
.todo-example-btn { align-self: flex-start; }

/* ---- Mode toggle (In Order / Any Order) ---- */
.todo-mode-toggle { display: flex; gap: 10px; flex-wrap: wrap; }
.todo-mode-btn {
  flex: 1;
  min-width: 200px;
  text-align: left;
  border: 1.5px solid var(--color-line);
  border-radius: 12px;
  background: var(--color-paper);
  padding: 12px 14px;
  cursor: pointer;
  font: inherit;
}
.todo-mode-btn:hover { border-color: var(--color-accent); }
.todo-mode-btn.is-selected { border-color: var(--color-ink); background: var(--color-bg-alt); }
.todo-mode-title { display: block; font-weight: 700; font-size: 14px; }
.todo-mode-desc { display: block; color: var(--color-muted); font-size: 12.5px; margin-top: 2px; }

#todo-btn-convert { width: 100%; text-align: center; margin-top: 6px; }
.todo-convert-error { color: var(--color-accent); font-size: 13.5px; margin: 8px 0 0; }

/* ---- Result preview + actions ---- */
.todo-result { margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--color-line); }
.todo-preview-wrap {
  background: var(--color-bg);
  border-radius: 12px;
  padding: 16px;
  overflow-x: auto;
}
.todo-preview-wrap svg { max-width: 100%; height: auto; display: block; margin: 0 auto; }
.todo-result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}
.todo-result-actions .btn { flex: 1; min-width: 160px; text-align: center; }

/* ---- Why CutDone ---- */
.todo-why h2 { font-size: 28px; max-width: 640px; }
.todo-why p { max-width: 640px; color: var(--color-muted); font-size: 16px; }

/* ---- Comparison table ---- */
.todo-compare-table-wrap { overflow-x: auto; margin: 20px 0 28px; }
.todo-compare-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 520px;
  background: var(--color-paper);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}
.todo-compare-table th, .todo-compare-table td {
  text-align: left;
  padding: 12px 16px;
  font-size: 14.5px;
  border-bottom: 1px solid var(--color-line);
}
.todo-compare-table th {
  background: var(--color-bg-alt);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.todo-compare-table tr:last-child td { border-bottom: none; }
.todo-compare-both {
  background: var(--color-accent-soft);
  border-radius: 14px;
  padding: 18px 22px;
  max-width: 640px;
}
.todo-compare-both h3 { margin: 0 0 8px; font-size: 18px; }
.todo-compare-both p { margin: 0; color: var(--color-ink); font-size: 15px; }

/* ---- Use cases ---- */
.todo-usecase-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}
.todo-usecase-card {
  background: var(--color-paper);
  border: 1px solid var(--color-line);
  border-radius: 14px;
  box-shadow: var(--shadow-card);
  padding: 16px;
}
.todo-usecase-card h3 { margin: 0 0 6px; font-size: 16px; }
.todo-usecase-card p { margin: 0 0 10px; color: var(--color-muted); font-size: 13.5px; }
.todo-usecase-load {
  border: none;
  background: var(--color-ink);
  color: var(--color-paper);
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
}
.todo-usecase-load:hover { background: var(--color-accent); }

/* ---- Q&A ---- */
.todo-qa-list { display: grid; gap: 16px; max-width: 720px; }
.todo-qa-item h3 { font-size: 15.5px; margin: 0 0 4px; }
.todo-qa-item p { margin: 0; color: var(--color-muted); font-size: 14.5px; }

/* ---- Internal links ---- */
.todo-links-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  padding: 0;
  margin: 0;
  list-style: none;
}
.todo-links-list a { color: var(--color-ink); font-weight: 600; font-size: 14.5px; }
.todo-links-list a:hover { color: var(--color-accent); }

@media (max-width: 640px) {
  .todo-tool-card { padding: 18px; }
  .todo-result-actions .btn { min-width: 100%; }
}
