/* Base styles */
* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; line-height: 1.6; color: #333; background: #fff; }
a { color: #2563eb; text-decoration: none; }
a:hover { text-decoration: underline; }

/* Container */
.container { max-width: 960px; margin: 0 auto; padding: 0 1rem; }

/* Header */
.site-header { background: linear-gradient(135deg, #4f46e5, #7c3aed); color: white; padding: 1.5rem 0; }
.site-header h1 { font-size: 1.75rem; margin: 0; }
.site-header .tagline { font-size: 1rem; margin: 0.5rem 0 0; opacity: 0.9; }
.main-nav { display: flex; gap: 1.5rem; margin-top: 1rem; flex-wrap: wrap; }
.main-nav a { color: white; font-weight: 500; }

/* Calculator Section */
.calculator-section { padding: 2rem 0; }
.calculator-section h2 { font-size: 1.5rem; margin-top: 0; }
.input-area { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 2rem; }
.input-area label { font-weight: 500; }
#donation-amount { padding: 0.75rem; font-size: 1rem; border: 2px solid #d1d5db; border-radius: 6px; }
#donation-amount:focus { outline: 2px solid #4f46e5; }
.presets { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.preset-btn { background: #f3f4f6; border: 1px solid #d1d5db; border-radius: 9999px; padding: 0.5rem 1rem; cursor: pointer; }
.preset-btn:hover { background: #e5e7eb; }
.preset-btn.active { background: #4f46e5; color: white; }
.help-text { font-size: 0.875rem; color: #6b7280; margin: 0; }

/* Results Grid */
.impact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; margin-top: 1.5rem; }
.impact-card { background: #f9fafb; border-radius: 8px; padding: 1.25rem; text-align: center; border: 1px solid #e5e7eb; }
.impact-icon { font-size: 2rem; margin-bottom: 0.5rem; }
.impact-value { font-size: 1.5rem; font-weight: 600; color: #4f46e5; margin: 0.25rem 0; }
.impact-detail { font-size: 0.875rem; color: #6b7280; margin: 0; }

/* Organizations Section */
.organizations-section { padding: 2rem 0; border-top: 1px solid #e5e7eb; }
.organizations-section h2 { font-size: 1.5rem; }
.org-cards { display: grid; gap: 1.5rem; }
.org-card { background: #f9fafb; border-radius: 8px; padding: 1.5rem; border: 1px solid #e5e7eb; }
.org-card h3 { margin-top: 0; font-size: 1.25rem; }
.org-description { color: #6b7280; margin: 0.5rem 0; }
.org-stats { list-style: none; padding: 0; margin: 1rem 0; }
.org-stats li { margin-bottom: 0.5rem; }
.details-btn { background: none; border: none; color: #2563eb; cursor: pointer; padding: 0; font-size: 0.9rem; }
.details-btn[aria-expanded='true'] { font-weight: 600; }

/* Examples Section */
.examples-section { padding: 2rem 0; border-top: 1px solid #e5e7eb; }
.examples-section h2 { font-size: 1.5rem; }
.scenario-gallery { display: grid; gap: 1rem; }
.scenario-card { background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 8px; padding: 1.25rem; }
.scenario-card h3 { margin-top: 0; color: #14532d; }
.scenario-card ul { padding-left: 1.25rem; margin: 0.5rem 0 0; }

/* Tools Section */
.tools-section { padding: 2rem 0; border-top: 1px solid #e5e7eb; border-bottom: 1px solid #e5e7eb; }
.tools-section h2 { font-size: 1.5rem; }
.tool-buttons { display: flex; gap: 1rem; flex-wrap: wrap; margin: 1.5rem 0; }
.tool-btn { display: flex; align-items: center; gap: 0.5rem; padding: 0.75rem 1.25rem; border-radius: 6px; cursor: pointer; }
.tool-btn.primary { background: #4f46e5; color: white; border: none; }
.tool-btn.secondary { background: #f3f4f6; color: #374151; border: 1px solid #d1d5db; }
.tool-btn:hover { opacity: 0.9; }
.btn-icon { font-size: 1.25rem; }

/* Help Section */
.help-section { padding: 2rem 0; background: #f9fafb; border-radius: 8px; margin-bottom: 2rem; }
.help-section h2 { font-size: 1.5rem; margin-top: 0; }
.help-content p { margin: 0.75rem 0; }

/* Footer */
.site-footer { background: #f3f4f6; padding: 1.5rem 0; font-size: 0.875rem; }
.site-footer a { color: #4b5563; }
.footer-nav { display: flex; gap: 1.5rem; margin-top: 0.5rem; }

/* Responsive */
@media (max-width: 600px) {
  .site-header h1 { font-size: 1.5rem; }
  .main-nav { justify-content: center; }
  .input-area { align-items: center; }
  .presets { justify-content: center; }
  .impact-grid { grid-template-columns: 1fr; }
  .tool-buttons { flex-direction: column; }
  .scenario-card { padding: 1rem; }
}



/* 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;
}
