/* CalFresh Calculator - Main Stylesheet */
:root {
  --primary: #059669;
  --primary-dark: #047857;
  --primary-light: #d1fae5;
  --secondary: #1e40af;
  --secondary-light: #dbeafe;
  --accent: #f59e0b;
  --text: #111827;
  --text-light: #6b7280;
  --bg: #f9fafb;
  --white: #ffffff;
  --border: #e5e7eb;
  --shadow: 0 1px 3px rgba(0,0,0,0.1);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-lg: 0 10px 30px rgba(0,0,0,0.1);
  --radius: 12px;
  --max-width: 1200px;
}

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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--text);
  line-height: 1.7;
  background: var(--bg);
}

a { color: var(--primary); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--primary-dark); }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1.5rem; }

/* ===== HEADER ===== */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
}
.logo {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.logo span { color: var(--text); }

nav { display: flex; align-items: center; gap: 1.75rem; }
nav a {
  color: var(--text-light);
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s;
}
nav a:hover { color: var(--primary); }
nav .btn-cta {
  background: var(--primary);
  color: var(--white);
  padding: 0.5rem 1.25rem;
  border-radius: 8px;
  font-weight: 600;
}
nav .btn-cta:hover { background: var(--primary-dark); color: var(--white); }

.mobile-toggle { display: none; background: none; border: none; font-size: 1.5rem; cursor: pointer; color: var(--text); }

/* ===== HERO ===== */
.hero {
  background: linear-gradient(135deg, #065f46 0%, #059669 50%, #10b981 100%);
  color: var(--white);
  padding: 4rem 1.5rem;
  text-align: center;
}
.hero h1 { font-size: 2.5rem; font-weight: 800; margin-bottom: 1rem; line-height: 1.2; }
.hero p { font-size: 1.15rem; opacity: 0.9; max-width: 640px; margin: 0 auto 2rem; }

/* ===== CALCULATOR ===== */
.calc-section {
  padding: 3rem 1.5rem;
  background: var(--white);
}
.calc-card {
  max-width: 800px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.5rem;
  box-shadow: var(--shadow-lg);
}
.calc-card h2 { font-size: 1.5rem; margin-bottom: 1.5rem; text-align: center; color: var(--text); }

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}
@media (max-width: 600px) { .form-grid { grid-template-columns: 1fr; } }

.form-group { display: flex; flex-direction: column; gap: 0.4rem; }
.form-group label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
}
.form-group select, .form-group input {
  padding: 0.7rem 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 1rem;
  transition: border-color 0.2s;
  background: var(--white);
}
.form-group select:focus, .form-group input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(5,150,105,0.1);
}

.btn-calculate {
  display: block;
  width: 100%;
  margin-top: 1.5rem;
  padding: 0.9rem;
  background: var(--primary);
  color: var(--white);
  border: none;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-calculate:hover { background: var(--primary-dark); }

.result-box {
  margin-top: 1.5rem;
  padding: 1.5rem;
  background: var(--primary-light);
  border: 1px solid #6ee7b7;
  border-radius: 8px;
  display: none;
}
.result-box.active { display: block; }
.result-box h3 { color: var(--primary-dark); margin-bottom: 0.5rem; }
.result-box .amount { font-size: 2rem; font-weight: 800; color: var(--primary); }
.result-box p { color: var(--text-light); margin-top: 0.5rem; font-size: 0.9rem; }

/* ===== STATES GRID ===== */
.states-section { padding: 3rem 1.5rem; }
.states-section h2 { font-size: 1.75rem; text-align: center; margin-bottom: 0.5rem; }
.states-section .subtitle { text-align: center; color: var(--text-light); margin-bottom: 2rem; }
.states-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
  max-width: var(--max-width);
  margin: 0 auto;
}
.state-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.state-card:hover { box-shadow: var(--shadow-md); border-color: var(--primary); transform: translateY(-2px); }
.state-card .state-icon { font-size: 1.5rem; }
.state-card .state-name { font-weight: 600; font-size: 0.95rem; }

/* ===== BLOG SECTION ===== */
.blog-section { padding: 3rem 1.5rem; background: var(--white); }
.blog-section h2 { font-size: 1.75rem; text-align: center; margin-bottom: 0.5rem; }
.blog-section .subtitle { text-align: center; color: var(--text-light); margin-bottom: 2rem; }
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
}
.blog-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: all 0.2s;
}
.blog-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.blog-card .card-img {
  height: 180px;
  background: linear-gradient(135deg, var(--primary-light), var(--secondary-light));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-size: 2rem;
}
.blog-card .card-body { padding: 1.25rem; }
.blog-card .card-category {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--primary);
  margin-bottom: 0.5rem;
}
.blog-card .card-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 0.5rem; line-height: 1.3; }
.blog-card .card-title a { color: var(--text); }
.blog-card .card-title a:hover { color: var(--primary); }
.blog-card .card-excerpt { font-size: 0.875rem; color: var(--text-light); line-height: 1.5; margin-bottom: 1rem; }
.blog-card .card-meta { display: flex; justify-content: space-between; font-size: 0.8rem; color: #9ca3af; }

.view-all {
  display: block;
  text-align: center;
  margin-top: 2rem;
  font-weight: 600;
  color: var(--primary);
}
.view-all:hover { text-decoration: underline; }

/* ===== STATE PAGE ===== */
.state-hero {
  background: linear-gradient(135deg, #065f46, #059669);
  color: var(--white);
  padding: 3rem 1.5rem;
  text-align: center;
}
.state-hero h1 { font-size: 2.25rem; margin-bottom: 0.5rem; }
.state-hero p { opacity: 0.9; max-width: 600px; margin: 0 auto; }

.state-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
}
.state-content h2 { font-size: 1.5rem; margin: 2rem 0 1rem; color: var(--text); }
.state-content h3 { font-size: 1.2rem; margin: 1.5rem 0 0.75rem; color: var(--primary-dark); }
.state-content p { margin-bottom: 1rem; color: var(--text-light); }
.state-content ul { margin: 0.75rem 0 1rem 1.5rem; color: var(--text-light); }
.state-content ul li { margin-bottom: 0.4rem; }

.info-card {
  background: var(--primary-light);
  border: 1px solid #6ee7b7;
  border-radius: var(--radius);
  padding: 1.5rem;
  margin: 1.5rem 0;
}
.info-card h3 { color: var(--primary-dark); margin-top: 0; margin-bottom: 0.75rem; }

/* ===== FOOTER ===== */
.site-footer {
  background: #111827;
  color: #9ca3af;
  padding: 3rem 1.5rem 1.5rem;
  margin-top: 3rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  max-width: var(--max-width);
  margin: 0 auto;
}
.footer-col h4 { color: var(--white); font-size: 1rem; margin-bottom: 1rem; }
.footer-col a { display: block; color: #9ca3af; font-size: 0.9rem; margin-bottom: 0.5rem; }
.footer-col a:hover { color: var(--white); }
.footer-bottom {
  max-width: var(--max-width);
  margin: 2rem auto 0;
  padding-top: 1.5rem;
  border-top: 1px solid #374151;
  text-align: center;
  font-size: 0.85rem;
}

/* ===== BLOG PAGE ===== */
.blog-page-header {
  background: linear-gradient(135deg, #1e3a5f, #1e40af);
  color: var(--white);
  padding: 3rem 1.5rem;
  text-align: center;
}
.blog-page-header h1 { font-size: 2.25rem; margin-bottom: 0.5rem; }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .hero h1 { font-size: 1.75rem; }
  .hero p { font-size: 1rem; }
  .calc-card { padding: 1.5rem; }
  .states-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
  .blog-grid { grid-template-columns: 1fr; }
  nav { display: none; }
  .mobile-toggle { display: block; }
}
