:root {
  --green-dark:  #1e3d18;
  --green:       #2d5a27;
  --green-light: #4a7c43;
  --green-pale:  #e8f0e6;
  --bg:          #f7f5ef;
  --surface:     #ffffff;
  --text:        #2c2c2c;
  --text-muted:  #666;
  --border:      #d8d3c8;
  --checked-bg:  #f0f0f0;
  --checked-fg:  #aaa;
  --shadow:      0 2px 8px rgba(0,0,0,0.08);
  --radius:      8px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
}

/* ── Header ── */
header {
  background: var(--green-dark);
  padding: 0.75rem 1.5rem;
  position: sticky;
  top: 0;
  z-index: 10;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}

.site-title {
  color: #fff;
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.site-title:hover { color: var(--green-pale); }

/* ── Main ── */
main {
  max-width: 860px;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
}

/* ── Home ── */
.home h1 {
  font-size: 1.8rem;
  color: var(--green-dark);
  margin-bottom: 0.5rem;
}

.lead {
  color: var(--text-muted);
  margin-bottom: 2rem;
}

.category { margin-bottom: 2.5rem; }

.category h2 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  padding-bottom: 0.4rem;
  border-bottom: 2px solid var(--green-pale);
}

/* ── Cards ── */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.75rem;
}

.card {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem;
  text-decoration: none;
  color: var(--text);
  transition: box-shadow 0.15s, border-color 0.15s, transform 0.1s;
}

.card:hover {
  box-shadow: var(--shadow);
  border-color: var(--green-light);
  transform: translateY(-1px);
}

.card-icon { font-size: 1.6rem; line-height: 1; flex-shrink: 0; }

.card-body h3 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--green-dark);
  margin-bottom: 0.2rem;
}

.card-body p {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ── Single list page ── */
.back-link {
  display: inline-block;
  color: var(--green-light);
  text-decoration: none;
  font-size: 0.85rem;
  margin-bottom: 1rem;
}
.back-link:hover { color: var(--green); }

.list-title-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.list-icon { font-size: 2rem; }

.list-page h1 {
  font-size: 1.8rem;
  color: var(--green-dark);
}

.list-description {
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.reset-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.35rem 0.8rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  cursor: pointer;
  margin-bottom: 1.5rem;
  transition: background 0.15s, color 0.15s;
}
.reset-btn:hover { background: var(--green-pale); color: var(--green); border-color: var(--green-light); }

/* ── List content ── */
.list-content h2 {
  font-size: 1.1rem;
  color: var(--green-dark);
  margin: 2rem 0 0.5rem;
  padding-bottom: 0.3rem;
  border-bottom: 2px solid var(--green-pale);
}

.list-content h3 {
  font-size: 0.95rem;
  color: var(--text-muted);
  font-weight: 600;
  margin: 1.2rem 0 0.3rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.list-content ul {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 0.1rem 1rem;
}

/* non-task list items (regular bullets) */
.list-content ul > li:not(:has(input[type="checkbox"])) {
  padding: 0.25rem 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  display: list-item;
  list-style: disc;
  margin-left: 1.2rem;
}

.list-content ul > li:has(input[type="checkbox"]) {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0.3rem 0.4rem;
  border-radius: 4px;
  transition: background 0.1s;
  cursor: pointer;
}

.list-content ul > li:has(input[type="checkbox"]):hover {
  background: var(--green-pale);
}

.list-content ul > li.checked {
  background: var(--checked-bg);
  color: var(--checked-fg);
  text-decoration: line-through;
}

.list-content input[type="checkbox"] {
  width: 1rem;
  height: 1rem;
  flex-shrink: 0;
  accent-color: var(--green);
  cursor: pointer;
  margin-top: 0.1rem;
}

/* ── Print ── */
@media print {
  header, .back-link, .reset-btn { display: none; }
  body { background: white; color: black; }
  .list-content input[type="checkbox"] { -webkit-print-color-adjust: exact; }
  .list-content ul { display: block; }
  .list-content ul > li:has(input[type="checkbox"]) { break-inside: avoid; }
}

/* ── Responsive ── */
@media (max-width: 540px) {
  .card-grid { grid-template-columns: 1fr; }
  .list-content ul { grid-template-columns: 1fr; }
  main { padding: 1.5rem 1rem 3rem; }
}
