/* Crown Roots Foundation — Global Styles */
@import url('https://fonts.googleapis.com/css2?family=Righteous&display=swap');

:root {
  --gold: #D4990D;
  --dark-brown: #302210;
  --accent-gold: #c9a227;
  --bg: #fafafa;
  --text: #1a1a1a;
  --text-light: #555;
  --text-muted: #888;
  --white: #ffffff;
  --border: #e0e0e0;
  --section-bg: #f5f0e1;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
}

h1, h2, h3, h4 {
  font-family: 'Righteous', system-ui, sans-serif;
  line-height: 1.2;
}

a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; }

img, svg { max-width: 100%; height: auto; }

/* Layout */
.container { max-width: 1000px; margin: 0 auto; padding: 0 20px; }

/* Navigation */
.site-nav {
  background: var(--dark-brown);
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  text-decoration: none;
}

.nav-brand img {
  height: 88px;
  width: auto;
}

.nav-brand span {
  font-family: 'Righteous', system-ui, sans-serif;
  color: var(--gold);
  font-size: 18px;
}

.nav-links {
  display: flex;
  gap: 4px;
  list-style: none;
}

.nav-links a {
  color: #ccc;
  padding: 16px 12px;
  display: block;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s;
  text-decoration: none;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--gold);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--gold);
  font-size: 24px;
  cursor: pointer;
  padding: 12px;
}

/* Hero */
.hero {
  background: var(--dark-brown);
  color: var(--white);
  text-align: center;
  padding: 60px 20px;
}

.hero h1 {
  font-size: 42px;
  color: var(--gold);
  margin-bottom: 16px;
}

.hero p {
  font-size: 18px;
  color: #ccc;
  max-width: 640px;
  margin: 0 auto;
}

.hero .logo-large {
  height: 240px;
  margin-bottom: 20px;
}

/* Stat Cards */
.stat-cards {
  display: flex;
  gap: 16px;
  margin: -30px auto 40px;
  max-width: 1000px;
  padding: 0 20px;
  position: relative;
  z-index: 10;
}

.stat-card {
  flex: 1;
  background: var(--white);
  border-left: 4px solid var(--accent-gold);
  border-radius: 6px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.stat-card .number {
  font-family: 'Righteous', system-ui, sans-serif;
  font-size: 32px;
  color: var(--text);
}

.stat-card .label {
  font-size: 14px;
  color: var(--text-light);
  margin-top: 4px;
  line-height: 1.4;
}

/* Sections */
.section {
  padding: 48px 20px;
  max-width: 1000px;
  margin: 0 auto;
}

.section h2 {
  font-size: 28px;
  margin-bottom: 16px;
  color: var(--dark-brown);
}

.section p {
  font-size: 16px;
  color: var(--text-light);
  margin-bottom: 14px;
  line-height: 1.6;
}

.section-alt {
  background: var(--section-bg);
  padding: 48px 20px;
}

.section-alt .section-inner {
  max-width: 960px;
  margin: 0 auto;
}

.section-alt h2 {
  font-size: 28px;
  margin-bottom: 16px;
  color: var(--dark-brown);
}

.section-alt p {
  font-size: 16px;
  color: var(--text-light);
  margin-bottom: 14px;
  line-height: 1.6;
}

/* Definition Box */
.definition-box {
  background: var(--section-bg);
  border-left: 4px solid var(--accent-gold);
  border-radius: 4px;
  padding: 14px 18px;
  margin: 20px 0;
  font-size: 14px;
  color: var(--text-light);
  line-height: 1.5;
}

.definition-box strong { color: var(--text); }

/* Buttons */
.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 6px;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity 0.2s;
  cursor: pointer;
  border: none;
}

.btn:hover { opacity: 0.85; text-decoration: none; }

.btn-primary { background: var(--gold); color: var(--white); }
.btn-secondary { background: var(--white); color: var(--text); border: 2px solid var(--border); }
.btn-dark { background: var(--dark-brown); color: var(--gold); }

.cta-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  margin-top: 24px;
}

/* Tables */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.data-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.data-table th {
  text-align: left;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  padding: 12px 16px;
  border-bottom: 2px solid #eee;
}

.data-table td {
  padding: 10px 16px;
  font-size: 15px;
  border-bottom: 1px solid #f0f0f0;
}

.data-table tr:last-child td { border-bottom: none; }
.data-table tr:nth-child(even) { background: #f9f9f9; }

.mountain { color: #dc2626; font-weight: 600; }
.valley { color: #2563eb; font-weight: 600; }
.worse { background: #fef2f2; }

/* Accordion */
.accordion-toggle {
  width: 100%;
  background: var(--white);
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 14px 18px;
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  text-align: left;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: border-radius 0.2s;
}

.accordion-toggle:hover { background: #f9f9f9; }
.accordion-toggle .arrow { transition: transform 0.2s; font-size: 12px; color: var(--text-muted); }
.accordion-toggle.open .arrow { transform: rotate(180deg); }
.accordion-toggle.open { border-radius: 6px 6px 0 0; border-bottom: none; }

.accordion-body {
  display: none;
  border: 1px solid #ddd;
  border-top: none;
  border-radius: 0 0 6px 6px;
  padding: 16px;
  background: var(--white);
  margin-bottom: 16px;
}

.accordion-body.open { display: block; }

/* Map */
.map-container iframe {
  width: 100%;
  height: 600px;
  border: none;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.map-caption {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 8px;
  text-align: center;
}

/* Card Grid */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin: 24px 0;
}

.card {
  background: var(--white);
  border-radius: 8px;
  padding: 24px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.card h3 {
  font-size: 18px;
  color: var(--dark-brown);
  margin-bottom: 8px;
}

.card p { font-size: 14px; color: var(--text-light); }

/* Phase badges */
.phase-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 8px;
}

.phase-mvp { background: #dcfce7; color: #166534; }
.phase-2 { background: #dbeafe; color: #1e40af; }
.phase-3 { background: #f3e8ff; color: #6b21a8; }

/* Footer */
.site-footer {
  background: var(--dark-brown);
  color: #999;
  text-align: center;
  padding: 32px 20px;
  font-size: 14px;
}

.site-footer a { color: var(--gold); }

/* CTA Banner */
.cta-banner {
  background: var(--dark-brown);
  color: var(--white);
  text-align: center;
  padding: 48px 20px;
}

.cta-banner h2 {
  color: var(--gold);
  font-size: 28px;
  margin-bottom: 12px;
}

.cta-banner p {
  color: #ccc;
  max-width: 600px;
  margin: 0 auto 24px;
}

/* Board placeholders */
.board-placeholder {
  background: var(--white);
  border: 2px dashed var(--border);
  border-radius: 8px;
  padding: 40px;
  text-align: center;
  color: var(--text-muted);
}

/* Contact form */
.contact-form {
  max-width: 500px;
}

.contact-form label {
  display: block;
  font-weight: 600;
  margin-bottom: 4px;
  margin-top: 16px;
  font-size: 14px;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 15px;
  font-family: inherit;
}

.contact-form textarea { min-height: 120px; resize: vertical; }

.contact-form .btn { margin-top: 20px; }

/* Mockup boxes */
.mockup-box {
  background: #1a1a2e;
  color: #e0e0e0;
  border-radius: 8px;
  padding: 24px;
  font-family: monospace;
  font-size: 13px;
  line-height: 1.5;
  overflow-x: auto;
  white-space: pre;
  margin: 16px 0;
}

/* Severity indicators */
.severity { display: inline-block; width: 12px; height: 12px; border-radius: 50%; margin-right: 6px; }
.severity-low { background: #22c55e; }
.severity-medium { background: #eab308; }
.severity-high { background: #f97316; }
.severity-critical { background: #ef4444; }

/* Responsive */
@media (max-width: 768px) {
  .nav-toggle { display: block; }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--dark-brown);
    flex-direction: column;
    padding: 8px 0;
    border-top: 1px solid rgba(255,255,255,0.1);
  }

  .nav-links.open { display: flex; }

  .nav-links a { padding: 12px 20px; }

  .site-nav .nav-inner { position: relative; }

  .hero { padding: 40px 20px; }
  .hero h1 { font-size: 28px; }
  .hero p { font-size: 15px; }

  .stat-cards { flex-direction: column; margin-top: -20px; }
  .stat-card .number { font-size: 24px; }
  .stat-card .label { font-size: 12px; }

  .section h2 { font-size: 22px; }

  .cta-buttons { flex-direction: column; align-items: center; }
  .btn { width: 100%; text-align: center; }

  .map-container iframe { height: 350px; }

  .data-table { min-width: 420px; font-size: 13px; }
  .data-table th { padding: 8px 10px; font-size: 10px; }
  .data-table td { padding: 8px 10px; font-size: 13px; }

  .card-grid { grid-template-columns: 1fr; }
}
