/* Mississippi Foundation For A Better Life — single-page styles */

:root {
  --color-primary: #1e3a5f;
  --color-primary-dark: #152a45;
  --color-accent: #3d8b6e;
  --color-accent-light: #4da67f;
  --color-earth: #8b6914;
  --color-bg: #f8faf9;
  --color-bg-alt: #eef4f1;
  --color-surface: #ffffff;
  --color-text: #1a2332;
  --color-text-muted: #5a6578;
  --color-border: #d8e2dc;
  --color-warning-bg: #fef9ec;
  --color-warning-border: #e8c547;
  --color-warning-text: #6b5a12;
  --font-heading: "DM Sans", system-ui, sans-serif;
  --font-body: "Source Sans 3", system-ui, sans-serif;
  --shadow-sm: 0 1px 3px rgba(30, 58, 95, 0.08);
  --shadow-md: 0 4px 20px rgba(30, 58, 95, 0.1);
  --shadow-lg: 0 12px 40px rgba(30, 58, 95, 0.12);
  --radius: 12px;
  --radius-lg: 20px;
  --header-height: 72px;
  --max-width: 1140px;
  --transition: 0.25s ease;
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--color-text);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--color-accent);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 9999;
  padding: 0.75rem 1.25rem;
  background: var(--color-primary);
  color: #fff;
  border-radius: var(--radius);
  font-weight: 600;
}

.skip-link:focus {
  top: 1rem;
}

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

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--header-height);
  background: transparent;
  transition: background var(--transition), box-shadow var(--transition);
}

.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.97);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(8px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--color-text);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1.2;
}

.site-header:not(.is-scrolled) .brand {
  color: #fff;
}

.brand img {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

.brand span {
  max-width: 200px;
}

.nav-desktop {
  display: none;
  list-style: none;
  gap: 1.75rem;
}

.nav-desktop a {
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--color-text-muted);
}

.site-header:not(.is-scrolled) .nav-desktop a {
  color: rgba(255, 255, 255, 0.9);
}

.nav-desktop a:hover,
.nav-desktop a.is-active {
  color: var(--color-accent);
}

.site-header:not(.is-scrolled) .nav-desktop a.is-active {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: transparent;
  border: none;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--color-primary);
  border-radius: 2px;
  transition: var(--transition);
}

.site-header:not(.is-scrolled) .nav-toggle span {
  background: #fff;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.nav-mobile {
  display: none;
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  background: var(--color-surface);
  box-shadow: var(--shadow-md);
  padding: 1rem 1.25rem 1.5rem;
  list-style: none;
}

.nav-mobile.is-open {
  display: block;
}

.nav-mobile li + li {
  border-top: 1px solid var(--color-border);
}

.nav-mobile a {
  display: block;
  padding: 0.875rem 0;
  font-weight: 600;
  color: var(--color-text);
}

@media (min-width: 900px) {
  .nav-desktop {
    display: flex;
  }

  .nav-toggle,
  .nav-mobile {
    display: none !important;
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: var(--radius);
  border: 2px solid transparent;
  cursor: pointer;
  transition: var(--transition);
}

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

.btn-primary:hover {
  background: var(--color-accent-light);
  border-color: var(--color-accent-light);
  color: #fff;
}

.btn-outline {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.85);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
}

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

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

/* Hero */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  padding: calc(var(--header-height) + 3rem) 0 4rem;
  background: linear-gradient(
      135deg,
      rgba(30, 58, 95, 0.92) 0%,
      rgba(30, 58, 95, 0.78) 50%,
      rgba(61, 139, 110, 0.75) 100%
    ),
    url("https://images.unsplash.com/photo-1582213782179-e0d53f98f2ca?w=1920&q=80")
      center / cover no-repeat;
  color: #fff;
}

.hero-content {
  max-width: 720px;
}

.hero-badge {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  margin-bottom: 1.25rem;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 999px;
  backdrop-filter: blur(4px);
}

.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 1rem;
}

.hero-tagline {
  font-size: clamp(1.125rem, 2.5vw, 1.375rem);
  font-weight: 500;
  opacity: 0.95;
  margin-bottom: 1.25rem;
}

.hero-summary {
  font-size: 1.0625rem;
  opacity: 0.9;
  margin-bottom: 2rem;
  max-width: 600px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* Organization credentials (footer, about, contact) */
.org-credentials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.5rem 1rem;
  text-align: center;
  font-size: 0.875rem;
  font-weight: 600;
}

.org-credentials .divider {
  opacity: 0.45;
  display: none;
}

@media (min-width: 640px) {
  .org-credentials .divider {
    display: inline;
  }
}

.org-credentials--section {
  margin: 2.5rem auto 0;
  max-width: 900px;
  padding: 1.25rem 1.5rem;
  background: var(--color-primary);
  color: #fff;
  border-radius: var(--radius);
}

.org-credentials-list {
  list-style: none;
  font-size: 0.9375rem;
  line-height: 1.7;
}

.org-credentials-list li + li {
  margin-top: 0.25rem;
}

.org-credentials-list--footer {
  margin-top: 1.25rem;
  opacity: 0.9;
}

.org-credentials-list--footer li {
  font-size: 0.875rem;
}

.contact-item.org-credentials-block .org-credentials-list {
  color: var(--color-text);
}

.footer-credentials {
  margin-bottom: 2rem;
  padding: 1.25rem 1.5rem;
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.org-credentials--footer {
  color: rgba(255, 255, 255, 0.95);
  font-size: 0.8125rem;
}

@media (min-width: 768px) {
  .org-credentials--footer {
    font-size: 0.875rem;
  }
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.85);
}

.footer-bottom a:hover {
  color: var(--color-accent-light);
}

/* Sections */
.section {
  padding: 5rem 0;
}

.section-alt {
  background: var(--color-bg-alt);
}

.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 3rem;
}

.section-label {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 0.5rem;
}

.section-header h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.75rem, 3.5vw, 2.25rem);
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 0.75rem;
}

.section-header p {
  color: var(--color-text-muted);
}

/* Cards grid */
.cards-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .cards-grid.cols-2 {
    grid-template-columns: repeat(2, 1fr);
  }

  .cards-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 640px) {
  .cards-grid.cols-5 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 900px) {
  .cards-grid.cols-5 {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1100px) {
  .cards-grid.cols-5 {
    grid-template-columns: repeat(5, 1fr);
  }
}

.card {
  background: var(--color-surface);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.card-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-bg-alt);
  border-radius: 10px;
  margin-bottom: 1rem;
  color: var(--color-accent);
}

.card h3 {
  font-family: var(--font-heading);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 0.5rem;
}

.card p {
  font-size: 0.9375rem;
  color: var(--color-text-muted);
}

/* About layout */
.about-intro {
  display: grid;
  gap: 2.5rem;
  align-items: center;
  margin-bottom: 3rem;
}

@media (min-width: 768px) {
  .about-intro {
    grid-template-columns: 1fr 1fr;
  }
}

.about-intro img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4/3;
  object-fit: cover;
}

.about-intro p {
  color: var(--color-text-muted);
  margin-bottom: 1rem;
}

.leadership-grid {
  display: grid;
  gap: 1.25rem;
  margin-top: 2.5rem;
}

@media (min-width: 640px) {
  .leadership-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.leader-card {
  text-align: center;
  padding: 1.5rem;
  background: var(--color-surface);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
}

.leader-card h4 {
  font-family: var(--font-heading);
  font-size: 1.0625rem;
  color: var(--color-primary);
  margin-bottom: 0.25rem;
}

.leader-card .role {
  font-size: 0.875rem;
  color: var(--color-accent);
  font-weight: 600;
}

/* Alert box */
.alert-box {
  background: var(--color-warning-bg);
  border: 2px solid var(--color-warning-border);
  border-radius: var(--radius);
  padding: 1.5rem 1.75rem;
  margin-bottom: 2.5rem;
}

.alert-box h3 {
  font-family: var(--font-heading);
  font-size: 1.125rem;
  color: var(--color-warning-text);
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.alert-box p {
  color: var(--color-text);
  font-size: 0.9375rem;
}

/* FAQ */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  margin-bottom: 0.75rem;
  overflow: hidden;
}

.faq-item summary {
  padding: 1.125rem 1.5rem;
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--color-primary);
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  float: right;
  font-size: 1.25rem;
  color: var(--color-accent);
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item .faq-answer {
  padding: 0 1.5rem 1.25rem;
  color: var(--color-text-muted);
  font-size: 0.9375rem;
}

/* Contact */
.contact-grid {
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr 1.2fr;
  }
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-item h4 {
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-accent);
  margin-bottom: 0.35rem;
}

.contact-item p,
.contact-item a {
  color: var(--color-text);
  font-size: 1rem;
}

.contact-form {
  background: var(--color-surface);
  padding: 2rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--color-border);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 0.35rem;
  color: var(--color-text);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  background: var(--color-bg);
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--color-accent);
  background: var(--color-surface);
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.form-message {
  display: none;
  margin-top: 1rem;
  padding: 1rem;
  border-radius: var(--radius);
  font-size: 0.9375rem;
}

.form-message.is-visible {
  display: block;
}

.form-message.success {
  background: #e8f5ef;
  color: #1a5c3a;
  border: 1px solid #3d8b6e;
}

.form-message.info {
  background: var(--color-bg-alt);
  color: var(--color-text);
  border: 1px solid var(--color-border);
}

/* Policies */
.policies-section {
  padding: 4rem 0;
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
}

.policy-block {
  max-width: 800px;
  margin: 0 auto 1rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  overflow: hidden;
}

.policy-block summary {
  padding: 1rem 1.25rem;
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--color-primary);
  cursor: pointer;
  background: var(--color-bg-alt);
}

.policy-block .policy-content {
  padding: 1.25rem 1.5rem;
  font-size: 0.9375rem;
  color: var(--color-text-muted);
}

.policy-block .policy-content h4 {
  font-family: var(--font-heading);
  color: var(--color-primary);
  margin: 1rem 0 0.5rem;
  font-size: 1rem;
}

.policy-block .policy-content h4:first-child {
  margin-top: 0;
}

.policy-block .policy-content p {
  margin-bottom: 0.75rem;
}

/* Footer */
.site-footer {
  background: var(--color-primary-dark);
  color: rgba(255, 255, 255, 0.85);
  padding: 3rem 0 1.5rem;
}

.footer-grid {
  display: grid;
  gap: 2rem;
  margin-bottom: 2.5rem;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr;
  }
}

.footer-brand .brand {
  color: #fff;
  margin-bottom: 1rem;
}

.footer-brand p {
  font-size: 0.9375rem;
  opacity: 0.85;
  max-width: 320px;
}

.footer-col h4 {
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 1rem;
  color: #fff;
}

.footer-col ul {
  list-style: none;
}

.footer-col li + li {
  margin-top: 0.5rem;
}

.footer-col a {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.9375rem;
}

.footer-col a:hover {
  color: var(--color-accent-light);
}

.footer-bottom {
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  text-align: center;
  font-size: 0.8125rem;
  opacity: 0.75;
}

.footer-bottom p + p {
  margin-top: 0.35rem;
}
