:root {
  --bg: #f8f9f5;
  --surface: #ffffff;
  --text: #1a1c18;
  --text-muted: #4a4f44;
  --primary: #2e5e3e;
  --primary-light: #4a8060;
  --primary-dark: #1b3d27;
  --accent: #c47a2b;
  --accent-light: #e8a95c;
  --border: #d4d9cf;
  --shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
  --radius: 8px;
  --font: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--primary-dark);
  font-weight: 700;
  font-size: 1.25rem;
}

.brand-icon {
  color: var(--primary);
}

.site-nav {
  display: flex;
  gap: 20px;
}

.site-nav a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
}

.site-nav a:hover { color: var(--primary); }

/* Intro */
.intro {
  padding: 48px 0 24px;
}

.intro h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  line-height: 1.2;
  color: var(--primary-dark);
  margin-bottom: 12px;
}

.intro p {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 640px;
}

/* Repair picker */
.repair-picker {
  padding: 24px 0;
}

.repair-picker h2 {
  font-size: 1.25rem;
  margin-bottom: 16px;
  color: var(--text);
}

.repair-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}

.repair-card {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
  text-align: left;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--text);
}

.repair-card:hover {
  border-color: var(--primary-light);
  box-shadow: var(--shadow);
}

.repair-card.active {
  border-color: var(--primary);
  background: #f0f7f2;
}

.repair-card .card-icon {
  font-size: 1.5rem;
  display: block;
  margin-bottom: 8px;
}

.repair-card .card-label {
  font-weight: 600;
  display: block;
}

.repair-card .card-count {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 4px;
  display: block;
}

/* Checklist area */
.checklist-area {
  padding: 16px 0 48px;
}

.checklist-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 16px;
}

.checklist-header h2 {
  font-size: 1.5rem;
  color: var(--primary-dark);
}

.checklist-sub {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 2px;
}

.checklist-actions {
  display: flex;
  gap: 8px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.15s, border-color 0.15s;
  text-decoration: none;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover { background: var(--primary-dark); }

.btn-outline {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text);
}

.btn-outline:hover { border-color: var(--primary-light); }

.btn-small {
  padding: 6px 12px;
  font-size: 0.85rem;
  background: var(--primary);
  color: #fff;
}

.btn-small:hover { background: var(--primary-dark); }

/* Progress */
.progress-bar {
  height: 8px;
  background: var(--border);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 8px;
}

.progress-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 4px;
  transition: width 0.3s ease;
  width: 0%;
}

.progress-text {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

/* Checklist columns */
.checklist-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 24px;
}

.checklist-col {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
}

.checklist-col h3 {
  font-size: 1rem;
  color: var(--primary-dark);
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.item-list {
  list-style: none;
}

.item-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}

.item-list li:last-child { border-bottom: none; }

.item-list li.checked .item-label {
  text-decoration: line-through;
  color: var(--text-muted);
}

.item-list input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--primary);
  flex-shrink: 0;
}

.item-list .item-label {
  font-size: 0.95rem;
  flex: 1;
}

.item-list .item-remove {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 1.1rem;
  padding: 0 4px;
  line-height: 1;
}

.item-list .item-remove:hover { color: #c0392b; }

.add-item {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.add-item input {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 0.9rem;
  background: var(--bg);
}

.add-item input:focus {
  outline: 2px solid var(--primary-light);
  outline-offset: 0;
}

/* Details */
details {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 12px;
  box-shadow: var(--shadow);
}

details summary {
  font-weight: 600;
  cursor: pointer;
  color: var(--primary-dark);
  font-size: 0.95rem;
}

details[open] summary { margin-bottom: 12px; }

details ul, details ol {
  padding-left: 20px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

details li { margin-bottom: 6px; }

.gotchas li { color: var(--accent); }

/* Supporting */
.supporting {
  padding: 32px 0 48px;
}

.supporting h2 {
  font-size: 1.25rem;
  color: var(--primary-dark);
  margin-bottom: 12px;
}

.supporting h3 {
  font-size: 1.1rem;
  color: var(--text);
  margin: 24px 0 8px;
}

.supporting p {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 12px;
  max-width: 720px;
}

.supporting ol, .supporting ul {
  padding-left: 20px;
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.supporting li { margin-bottom: 6px; }

.last-updated {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 24px;
}

/* Footer */
.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 24px 0;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.site-footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.site-footer a {
  color: var(--primary);
  text-decoration: none;
}

.site-footer a:hover { text-decoration: underline; }

.footer-links {
  display: flex;
  gap: 16px;
}

/* Print */
@media print {
  .site-header, .site-footer, .repair-picker, .checklist-actions, .add-item, .item-remove, .btn { display: none !important; }
  .checklist-area { display: block !important; }
  body { background: #fff; }
  .checklist-col { box-shadow: none; border: 1px solid #ccc; }
}

/* Responsive */
@media (max-width: 640px) {
  .checklist-header { flex-direction: column; }
  .checklist-actions { width: 100%; }
  .checklist-actions .btn { flex: 1; justify-content: center; }
  .repair-cards { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .checklist-columns { grid-template-columns: 1fr; }
}



/* Factory-injected deployment helpers. The AI owns the site design above this block. */
.ad-unit {
  width: min(100%, 720px);
  min-height: 120px;
  margin: 24px auto;
  display: block;
}

.legal-page {
  width: min(900px, calc(100% - 32px));
  margin: 40px auto;
}

.factory-fallback-nav {
  width: min(900px, calc(100% - 32px));
  margin: 24px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  font-size: 0.95rem;
}

.factory-fallback-nav a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
