/*
Theme Name: Rainbows of Joy
Theme URI: https://rainbowsofjoy.ca
Author: Rainbows of Joy Foundation
Author URI: https://rainbowsofjoy.ca
Description: A warm, joyful theme for the Rainbows of Joy Foundation — supporting children and youth living with Autism Spectrum Disorder and other special needs.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: rainbows-of-joy
Tags: non-profit, charity, accessibility-ready, custom-colors, custom-logo, featured-images, responsive-layout
*/

/* =====================================================
   IMPORTS & CSS CUSTOM PROPERTIES
   ===================================================== */

@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800&family=Fraunces:ital,opsz,wght@0,9..144,400;0,9..144,700;1,9..144,400&display=swap');

:root {
  --color-navy:      #1a2744;
  --color-orange:    #FF6B35;
  --color-yellow:    #FFD23F;
  --color-teal:      #4ECDC4;
  --color-blue:      #5B9CF6;
  --color-lavender:  #C9A8FF;
  --color-green:     #7AE582;
  --color-bg:        #ffffff;
  --color-bg-soft:   #f9f9f9;
  --color-bg-warm:   #FFF8F5;
  --color-text:      #1a2744;
  --color-muted:     #555555;
  --color-border:    #f0f0f0;

  --font-display:    'Fraunces', Georgia, serif;
  --font-body:       'Nunito', system-ui, sans-serif;

  --radius-sm:  8px;
  --radius-md:  16px;
  --radius-lg:  24px;
  --radius-pill: 28px;

  --max-width: 1100px;
  --section-pad: 72px 32px;
}

/* =====================================================
   RESET & BASE
   ===================================================== */

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-bg);
}

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

a { color: inherit; text-decoration: none; }
a:hover { color: var(--color-orange); }
a:focus-visible {
  outline: 3px solid var(--color-orange);
  outline-offset: 2px;
  border-radius: 2px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* =====================================================
   UTILITY
   ===================================================== */

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 32px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-orange);
  margin-bottom: 10px;
  display: block;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 4vw, 34px);
  font-weight: 700;
  color: var(--color-navy);
  line-height: 1.2;
  margin-bottom: 12px;
}

.section-sub {
  font-size: 16px;
  color: var(--color-muted);
  max-width: 480px;
  margin-bottom: 40px;
}

.btn {
  display: inline-block;
  padding: 13px 28px;
  border-radius: var(--radius-pill);
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font-body);
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease;
  border: none;
}
.btn:hover { transform: translateY(-1px); opacity: 0.92; }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--color-orange); color: #fff; }
.btn-secondary { background: transparent; color: var(--color-navy); border: 2px solid var(--color-navy); }

/* =====================================================
   NAVIGATION
   ===================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #fff;
  border-bottom: 1px solid var(--color-border);
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px;
  max-width: var(--max-width);
  margin: 0 auto;
  gap: 24px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.nav-logo-text {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--color-navy);
}
.nav-logo img { width: 36px; height: 36px; }

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
  flex: 1;
  justify-content: center;
}
.nav-links a {
  font-size: 13px;
  font-weight: 600;
  color: #555;
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--color-orange); }

.nav-cta {
  background: var(--color-orange);
  color: #fff;
  padding: 9px 20px;
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
  transition: opacity 0.15s;
}
.nav-cta:hover { color: #fff; opacity: 0.9; }

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  color: var(--color-navy);
}
.nav-toggle svg { width: 24px; height: 24px; }

@media (max-width: 768px) {
  .nav-links { display: none; flex-direction: column; gap: 0; }
  .nav-links.is-open {
    display: flex;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: #fff;
    border-bottom: 1px solid var(--color-border);
    padding: 12px 0;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  }
  .nav-links.is-open li a { display: block; padding: 12px 32px; font-size: 15px; }
  .nav-toggle { display: block; }
  .nav-cta { display: none; }
}

/* =====================================================
   HERO
   ===================================================== */

.hero {
  background: #fff;
  padding: 64px 32px 0;
  text-align: center;
  overflow: hidden;
}

.hero-rainbow {
  display: flex;
  justify-content: center;
  gap: 3px;
  width: 240px;
  margin: 0 auto 48px;
}
.hero-rainbow span {
  height: 7px;
  flex: 1;
  border-radius: 4px;
}

.hero-eyebrow {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-orange);
  margin-bottom: 16px;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(36px, 6vw, 52px);
  font-weight: 700;
  line-height: 1.12;
  color: var(--color-navy);
  max-width: 620px;
  margin: 0 auto 20px;
}

.hero-sub {
  font-size: 17px;
  color: var(--color-muted);
  max-width: 520px;
  margin: 0 auto 36px;
}

.hero-btns {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 56px;
}

.hero-stats {
  background: var(--color-navy);
  color: #fff;
  display: flex;
  justify-content: center;
  border-radius: 16px 16px 0 0;
  padding: 28px 40px;
  max-width: 640px;
  margin: 0 auto;
}

.hero-stat {
  flex: 1;
  text-align: center;
  border-right: 1px solid rgba(255,255,255,0.15);
  padding: 0 24px;
}
.hero-stat:last-child { border-right: none; }

.hero-stat-num {
  font-family: var(--font-display);
  font-size: 32px;
  font-weight: 700;
  color: var(--color-yellow);
}

.hero-stat-label {
  font-size: 12px;
  color: rgba(255,255,255,0.65);
  font-weight: 600;
  margin-top: 4px;
}

@media (max-width: 600px) {
  .hero-title { font-size: 34px; }
  .hero-stats { padding: 20px 16px; }
  .hero-stat { padding: 0 12px; }
  .hero-stat-num { font-size: 22px; }
}

/* =====================================================
   PROGRAMS
   ===================================================== */

.programs-section { padding: var(--section-pad); background: #fff; }

.programs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.program-card {
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border);
  overflow: hidden;
  transition: box-shadow 0.2s, transform 0.2s;
}
.program-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(26,39,68,0.10);
}

.program-card-bar { height: 6px; }
.program-card-body { padding: 24px; }

.program-icon { font-size: 28px; margin-bottom: 14px; }

.program-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--color-navy);
  margin-bottom: 8px;
}

.program-desc {
  font-size: 13px;
  color: #666;
  line-height: 1.7;
  margin-bottom: 16px;
}

.program-link {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-orange);
}
.program-link:hover { color: var(--color-navy); }

/* =====================================================
   MISSION BAND
   ===================================================== */

.mission-section { padding: 0 32px 72px; }

.mission-inner {
  background: var(--color-bg-warm);
  border-radius: var(--radius-lg);
  padding: 56px 48px;
  display: flex;
  gap: 48px;
  align-items: center;
  max-width: var(--max-width);
  margin: 0 auto;
}

.mission-text { flex: 1; }
.mission-text p { font-size: 16px; color: var(--color-muted); line-height: 1.8; margin-bottom: 24px; }
.mission-link { font-size: 14px; font-weight: 700; color: var(--color-orange); }

.mission-quote { flex: 0 0 280px; }

.quote-card {
  background: var(--color-navy);
  color: #fff;
  border-radius: var(--radius-md);
  padding: 28px;
}

.quote-text {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 17px;
  line-height: 1.6;
  color: #fff;
  margin-bottom: 16px;
}

.quote-by {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-yellow);
  letter-spacing: 1px;
  text-transform: uppercase;
}

@media (max-width: 768px) {
  .mission-inner { flex-direction: column; padding: 32px 24px; }
  .mission-quote { flex: none; width: 100%; }
}

/* =====================================================
   TESTIMONIALS
   ===================================================== */

.testimonials-section { background: var(--color-bg-soft); padding: var(--section-pad); }

.testimonials-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.testimonial-card {
  background: #fff;
  border-radius: var(--radius-md);
  padding: 24px;
  border-left: 4px solid var(--color-teal);
}

.testimonial-text {
  font-size: 14px;
  color: #333;
  line-height: 1.8;
  margin-bottom: 14px;
  font-style: italic;
}

.testimonial-by {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-navy);
  display: flex;
  align-items: center;
  gap: 6px;
}

.testimonial-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-teal);
  flex-shrink: 0;
}

@media (max-width: 600px) {
  .testimonials-grid { grid-template-columns: 1fr; }
}

/* =====================================================
   PHOTO GRID
   ===================================================== */

.photos-section { padding: var(--section-pad); }

.photo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  border-radius: var(--radius-md);
  overflow: hidden;
}

.photo-cell { border-radius: 8px; overflow: hidden; background: #e8e8e8; }
.photo-cell img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.3s ease; }
.photo-cell:hover img { transform: scale(1.03); }

@media (max-width: 600px) {
  .photo-grid { grid-template-columns: 1fr 1fr; }
}

/* =====================================================
   DONATE BAND
   ===================================================== */

.donate-section { padding: 0 32px 72px; }

.donate-inner {
  background: var(--color-navy);
  border-radius: var(--radius-lg);
  padding: 56px 48px;
  text-align: center;
  max-width: var(--max-width);
  margin: 0 auto;
}

.donate-inner h2 {
  font-family: var(--font-display);
  font-size: clamp(26px, 4vw, 36px);
  font-weight: 700;
  color: #fff;
  margin-bottom: 12px;
}

.donate-inner > p {
  font-size: 16px;
  color: rgba(255,255,255,0.7);
  margin-bottom: 32px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.donate-amounts {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.donate-amt {
  background: rgba(255,255,255,0.1);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.3);
  padding: 10px 22px;
  border-radius: var(--radius-pill);
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font-body);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.donate-amt:hover,
.donate-amt.is-active {
  background: var(--color-yellow);
  color: var(--color-navy);
  border-color: var(--color-yellow);
}

.donate-btn-wrap { margin-top: 8px; }

.donate-note {
  font-size: 12px;
  color: rgba(255,255,255,0.4);
  margin-top: 16px;
}

/* =====================================================
   FOOTER
   ===================================================== */

.site-footer {
  background: var(--color-navy);
  color: rgba(255,255,255,0.7);
  padding: 40px 32px;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-logo {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: #fff;
}

.footer-links {
  display: flex;
  gap: 20px;
  list-style: none;
  font-size: 13px;
  flex-wrap: wrap;
}
.footer-links a:hover { color: var(--color-yellow); }

.footer-copy { font-size: 12px; color: rgba(255,255,255,0.4); }

@media (max-width: 600px) {
  .footer-inner { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }
}

/* =====================================================
   WORDPRESS CORE CLASSES
   ===================================================== */

.wp-block-image { margin-bottom: 1.5rem; }
.alignleft { float: left; margin-right: 1.5rem; margin-bottom: 1rem; }
.alignright { float: right; margin-left: 1.5rem; margin-bottom: 1rem; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; }

.entry-content h1, .entry-content h2, .entry-content h3,
.entry-content h4, .entry-content h5, .entry-content h6 {
  font-family: var(--font-display);
  color: var(--color-navy);
  margin: 1.5rem 0 0.75rem;
  line-height: 1.25;
}
.entry-content h1 { font-size: 2.25rem; }
.entry-content h2 { font-size: 1.875rem; }
.entry-content h3 { font-size: 1.5rem; }
.entry-content p { margin-bottom: 1.25rem; color: var(--color-muted); }
.entry-content ul, .entry-content ol { margin: 0 0 1.25rem 1.5rem; color: var(--color-muted); }
.entry-content li { margin-bottom: 0.5rem; }
.entry-content a { color: var(--color-orange); text-decoration: underline; }
.entry-content a:hover { color: var(--color-navy); }
.entry-content blockquote {
  border-left: 4px solid var(--color-teal);
  margin: 1.5rem 0;
  padding: 16px 24px;
  background: var(--color-bg-soft);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  color: var(--color-navy);
}
