/* ===========================================
   Siskiyou Child Care Council
   Clean, warm, professional nonprofit design
   =========================================== */

:root {
  --primary:       #1f6f6a;
  --primary-dark:  #154e4b;
  --primary-light: #e8f4f2;
  --accent:        #e8902a;
  --accent-light:  #fff4e6;
  --ink:           #1a2724;
  --ink-soft:      #4b5e59;
  --bg:            #f7f9f7;
  --surface:       #ffffff;
  --border:        #d5e5e1;
  --radius-sm:     8px;
  --radius:        12px;
  --radius-lg:     20px;
  --shadow-sm:     0 1px 3px rgba(0,0,0,.07), 0 1px 2px rgba(0,0,0,.05);
  --shadow:        0 4px 16px rgba(0,0,0,.1);
  --max-w:         1400px;
}

/* ---- Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.7;
  font-size: 1rem;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); }
a:hover { color: var(--primary-dark); }

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.25;
  margin: 0 0 .6em;
  color: var(--ink);
}
h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.35rem, 2.5vw, 1.8rem); }
h3 { font-size: 1.15rem; }
h4 { font-size: 1rem; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
address { font-style: normal; line-height: 1.9; }

/* ---- Container ---- */
.container {
  width: min(var(--max-w), calc(100% - 2.5rem));
  margin: 0 auto;
}

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  text-decoration: none;
  border-radius: 9999px;
  padding: .65rem 1.4rem;
  font-weight: 600;
  font-size: .95rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease, color .15s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(0,0,0,.16); }
.btn-primary { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }
.btn-outline { background: transparent; color: var(--primary); border-color: var(--primary); }
.btn-outline:hover { background: var(--primary-light); color: var(--primary); }
.btn-white { background: #fff; color: var(--primary); border-color: #fff; }
.btn-white:hover { background: var(--primary-light); border-color: var(--primary-light); color: var(--primary); }

/* ---- Header ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.97);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.header-inner {
  display: flex;
  align-items: center;
  height: 68px;
  gap: 1rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: .65rem;
  text-decoration: none;
  color: var(--ink);
  flex-shrink: 0;
  margin-right: auto;
}
.brand:hover { color: var(--primary); }
.brand-logo {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: .8rem;
  color: #fff;
  letter-spacing: .03em;
  flex-shrink: 0;
}
.brand-name {
  font-weight: 700;
  font-size: .95rem;
  line-height: 1.25;
  max-width: 200px;
}
.nav-list {
  display: flex;
  align-items: center;
  gap: .2rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-list a {
  display: block;
  padding: .45rem .8rem;
  border-radius: 8px;
  text-decoration: none;
  font-size: .95rem;
  font-weight: 600;
  color: var(--ink-soft);
  transition: background .15s, color .15s;
  white-space: nowrap;
}
.nav-list a:hover,
.nav-list a:focus-visible {
  background: var(--primary-light);
  color: var(--primary);
}
.nav-list a.active {
  background: var(--primary);
  color: #fff;
}
.menu-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  padding: 10px 8px;
  flex-shrink: 0;
}
.menu-btn span {
  display: block;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
}

/* ---- Home Hero ---- */
.hero {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 65%, #28917f 100%);
  color: #fff;
  padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(2.5rem, 6vw, 4.5rem);
}
.hero-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2.5rem;
  align-items: start;
}
.hero-tag {
  display: inline-block;
  background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.3);
  border-radius: 9999px;
  padding: .3rem .85rem;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  margin-bottom: 1rem;
  color: rgba(255,255,255,.9);
}
.hero h1 {
  color: #fff;
  margin-bottom: .75rem;
  max-width: 20ch;
}
.hero-lead {
  font-size: 1.05rem;
  color: rgba(255,255,255,.85);
  max-width: 56ch;
  margin-bottom: 1.75rem;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
}
.hero-card {
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.22);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.75rem;
  min-width: 230px;
  color: #fff;
  font-size: .92rem;
  line-height: 1.7;
}
.hero-card strong {
  display: block;
  font-size: 1rem;
  margin-bottom: .6rem;
}
.hero-card a { color: rgba(255,255,255,.85); text-decoration: none; }
.hero-card a:hover { color: #fff; }

/* ---- Services section (home) ---- */
.services {
  padding: 4rem 0;
  background: var(--surface);
}
.section-header { margin-bottom: 2rem; }
.section-header h2 { margin: 0; }
.section-header p {
  color: var(--ink-soft);
  margin: .4rem 0 0;
  font-size: 1.02rem;
}
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.service-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-top: 4px solid var(--primary);
  border-radius: var(--radius);
  padding: 1.75rem 1.5rem;
  text-decoration: none;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: .4rem;
  transition: transform .15s ease, box-shadow .15s ease;
}
.service-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  color: var(--ink);
}
.service-card:nth-child(2) { border-top-color: var(--accent); }
.service-card:nth-child(3) { border-top-color: #5a9b7a; }
.service-icon { font-size: 2rem; margin-bottom: .25rem; }
.service-card h3 { font-size: 1.15rem; margin: 0; color: var(--primary-dark); }
.service-card p { font-size: .91rem; color: var(--ink-soft); margin: 0; flex-grow: 1; }
.service-cta { margin-top: .75rem; font-weight: 700; font-size: .88rem; color: var(--primary); }

/* ---- About strip (home) ---- */
.about-strip {
  padding: 4rem 0;
  background: var(--primary-light);
  border-top: 1px solid rgba(31,111,106,.15);
  border-bottom: 1px solid rgba(31,111,106,.15);
}
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}
.about-img { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); }
.about-img img { width: 100%; height: auto; }

/* ---- Contact section (home) ---- */
.contact-section {
  padding: 4rem 0;
  background: var(--surface);
}
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}
.contact-block h3 {
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--primary-dark);
  border-bottom: 2px solid var(--primary-light);
  padding-bottom: .35rem;
  margin-bottom: .65rem;
}
.contact-block p { font-size: .93rem; color: var(--ink-soft); }
.contact-block a { color: var(--primary); font-weight: 600; }

/* ---- Programs grid (home) ---- */
.programs-section { padding: 4rem 0; }
.programs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(195px, 1fr));
  gap: .6rem;
  margin-top: 1.5rem;
}
.program-card {
  display: block;
  padding: .8rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
  font-size: .88rem;
  color: var(--ink-soft);
  transition: background .15s, border-color .15s, color .15s;
}
.program-card:hover {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary);
}
.program-card.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

/* ---- Page header (interior pages) ---- */
.page-header {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  color: #fff;
  padding: 2.25rem 0 2rem;
}
.page-breadcrumb {
  font-size: .8rem;
  margin-bottom: .55rem;
  color: rgba(255,255,255,.7);
}
.page-breadcrumb a { color: rgba(255,255,255,.8); text-decoration: none; }
.page-breadcrumb a:hover { text-decoration: underline; color: #fff; }
.page-breadcrumb span { margin: 0 .4rem; }
.page-header h1 {
  color: #fff;
  margin-bottom: .4rem;
  font-size: clamp(1.6rem, 3.5vw, 2.3rem);
}
.page-header .lede {
  color: rgba(255,255,255,.82);
  font-size: 1rem;
  max-width: 64ch;
  margin: 0;
}

/* ---- Page content layout ---- */
.page-content { padding: 3rem 0 4.5rem; }
.content-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 3rem;
  align-items: start;
}

/* ---- Prose ---- */
.prose > * + * { margin-top: .85em; }
.prose h2 {
  margin-top: 1.75em;
  padding-bottom: .4rem;
  border-bottom: 2px solid var(--border);
  font-size: 1.35rem;
}
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 1.3em; font-size: 1.1rem; color: var(--primary-dark); }
.prose h3:first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.5em; margin: 0 0 1em; }
.prose li { margin-bottom: .3em; }
.prose a:not(.btn):not(.download-link) { color: var(--primary); font-weight: 500; text-underline-offset: 2px; }
.prose strong { color: var(--ink); }

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: .9rem;
  margin: .5rem 0 1.25rem;
}
.prose th {
  background: var(--primary-light);
  color: var(--primary-dark);
  font-weight: 700;
  text-align: left;
  padding: .55rem .85rem;
  border: 1px solid var(--border);
}
.prose td {
  padding: .5rem .85rem;
  border: 1px solid var(--border);
}
.prose tr:nth-child(even) td { background: #fafcfb; }

/* ---- Sidebar ---- */
.sidebar { display: flex; flex-direction: column; gap: 1.25rem; }
.sidebar-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow-sm);
}
.sidebar-card h3 {
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--ink-soft);
  margin-bottom: .75rem;
  padding-bottom: .4rem;
  border-bottom: 2px solid var(--primary-light);
}
.sidebar-card p { font-size: .9rem; color: var(--ink-soft); }
.sidebar-card address { font-size: .9rem; color: var(--ink-soft); }
.sidebar-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: .3rem;
}
.sidebar-links a {
  display: block;
  padding: .45rem .6rem;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 600;
  font-size: .88rem;
  color: var(--ink-soft);
  transition: background .12s, color .12s;
}
.sidebar-links a:hover { background: var(--primary-light); color: var(--primary); }

/* ---- Download list ---- */
.download-list {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: .5rem;
}
.download-link {
  display: flex;
  align-items: center;
  gap: .7rem;
  padding: .75rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
  color: var(--primary);
  font-size: .91rem;
  transition: background .15s, border-color .15s;
}
.download-link:hover {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-dark);
}
.download-link::before {
  content: \'\u2193\';
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  background: var(--primary);
  color: #fff;
  border-radius: 6px;
  font-size: .82rem;
  flex-shrink: 0;
}

/* ---- Content image ---- */
.content-img {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  margin: 1.5rem 0;
}
.content-img img { width: 100%; height: auto; }

/* ---- Info / callout cards ---- */
.info-card {
  background: var(--primary-light);
  border: 1px solid rgba(31,111,106,.2);
  border-left: 4px solid var(--primary);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1.25rem;
  font-size: .93rem;
}
.info-card h3 { color: var(--primary-dark); margin-bottom: .5rem; font-size: .95rem; }
.info-card a { color: var(--primary-dark); font-weight: 600; }

/* ---- Survey card (UPK) ---- */
.survey-box {
  background: var(--accent-light);
  border: 1px solid rgba(232,144,42,.3);
  border-radius: var(--radius-lg);
  padding: 2.25rem 2rem;
  text-align: center;
  margin: 1.5rem 0;
}
.survey-box h2 { font-size: 1.5rem; }
.survey-box p { color: var(--ink-soft); max-width: 50ch; margin: 0 auto .75rem; }
.survey-or { font-size: 1.1rem; font-weight: 700; color: var(--ink-soft); margin: 1.25rem 0; }
.survey-images {
  display: flex;
  gap: 1.5rem;
  margin-top: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
}
.survey-images .content-img { margin: 0; max-width: 340px; flex: 1; }

/* ---- Location card ---- */
.location-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: .5rem;
  box-shadow: var(--shadow-sm);
}
.location-card h3 { margin: 0; font-size: 1rem; color: var(--primary-dark); }
.location-card p { margin: 0; font-size: .9rem; color: var(--ink-soft); }
.location-card a { color: var(--primary); font-weight: 600; }

/* ---- Footer ---- */
.site-footer {
  background: #1a2724;
  color: rgba(255,255,255,.75);
  padding: 3.5rem 0 0;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1fr 1fr;
  gap: 2.5rem;
  padding-bottom: 3rem;
}
.footer-brand { font-size: 1rem; font-weight: 700; color: #fff; margin-bottom: .6rem; }
.site-footer p { margin: 0 0 .5em; font-size: .88rem; }
.site-footer a { color: rgba(255,255,255,.72); text-decoration: none; }
.site-footer a:hover { color: #fff; }
.footer-heading {
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: rgba(255,255,255,.45);
  margin: 0 0 .8rem;
}
.footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: .35rem;
}
.footer-links li a { font-size: .88rem; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding: 1.25rem 0;
  font-size: .8rem;
  color: rgba(255,255,255,.4);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* ---- Responsive ---- */
@media (max-width: 980px) {
  .services-grid { grid-template-columns: 1fr 1fr; }
  .about-grid { grid-template-columns: 1fr; }
  .about-img { order: -1; max-width: 520px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}

@media (max-width: 760px) {
  .menu-btn { display: flex; }
  .nav-list {
    display: none;
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    align-items: stretch;
    padding: .5rem .75rem .75rem;
    gap: .2rem;
    box-shadow: var(--shadow);
  }
  .nav-list.open { display: flex; }
  .nav-list a { text-align: left; padding: .55rem .75rem; }
  .hero-inner { grid-template-columns: 1fr; }
  .hero-card { display: none; }
  .content-layout { grid-template-columns: 1fr; }
  .sidebar { order: -1; }
  .services-grid { grid-template-columns: 1fr; }
}

@media (max-width: 540px) {
  .container { width: min(var(--max-w), calc(100% - 1.5rem)); }
  .hero-actions .btn { width: 100%; justify-content: center; }
  .programs-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.75rem; }
  .footer-bottom { flex-direction: column; gap: .5rem; text-align: center; }
}

/* ============================================================
   Accessibility Widget
   ============================================================ */

.a11y-trigger {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9000;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  border: 2px solid rgba(255,255,255,.3);
  box-shadow: 0 4px 16px rgba(0,0,0,.25);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  transition: transform .15s ease, background .15s ease, box-shadow .15s ease;
}
.a11y-trigger:hover,
.a11y-trigger:focus-visible {
  transform: scale(1.08);
  background: var(--primary-dark);
  box-shadow: 0 6px 22px rgba(0,0,0,.3);
}

.a11y-panel {
  position: fixed;
  bottom: 5.5rem;
  right: 1.5rem;
  z-index: 8999;
  width: 270px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px rgba(0,0,0,.18);
  padding: 1.1rem 1.25rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: .75rem;
  transform-origin: bottom right;
  transition: opacity .18s ease, transform .18s ease;
}
.a11y-panel[hidden] {
  display: none;
}
.a11y-panel-title {
  font-weight: 800;
  font-size: .9rem;
  color: var(--ink);
  margin: 0 0 .1rem;
  letter-spacing: .01em;
}
.a11y-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
}
.a11y-row-label {
  font-size: .85rem;
  font-weight: 600;
  color: var(--ink-soft);
  flex-shrink: 0;
}
.a11y-btn-group {
  display: flex;
  gap: .3rem;
}
.a11y-btn {
  padding: .3rem .6rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg);
  color: var(--ink);
  font-weight: 700;
  font-size: .82rem;
  cursor: pointer;
  transition: background .12s, border-color .12s, color .12s;
}
.a11y-btn:hover,
.a11y-btn.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

/* Toggle switch */
.a11y-toggle {
  position: relative;
  width: 40px;
  height: 22px;
  border-radius: 11px;
  border: none;
  background: #ccc;
  cursor: pointer;
  flex-shrink: 0;
  transition: background .2s ease;
  appearance: none;
  -webkit-appearance: none;
}
.a11y-toggle::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0,0,0,.2);
  transition: transform .2s ease;
}
.a11y-toggle[aria-checked="true"] {
  background: var(--primary);
}
.a11y-toggle[aria-checked="true"]::after {
  transform: translateX(18px);
}
.a11y-toggle:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* ---- a11y body states ---- */
body.a11y-high-contrast {
  --primary:        #005249;
  --primary-dark:   #003530;
  --primary-light:  #c0e8e3;
  --ink:            #000;
  --ink-soft:       #111;
  --bg:             #f0f0f0;
  --surface:        #fff;
  --border:         #555;
}
body.a11y-focus-rings *:focus {
  outline: 3px solid var(--accent) !important;
  outline-offset: 2px !important;
}
body.a11y-dyslexia {
  font-family: 'OpenDyslexic', 'Comic Sans MS', 'Arial', sans-serif !important;
  letter-spacing: .04em;
  word-spacing: .12em;
  line-height: 1.9 !important;
}
body.a11y-reduce-motion *,
body.a11y-reduce-motion *::before,
body.a11y-reduce-motion *::after {
  animation: none !important;
  transition: none !important;
}

@media (max-width: 540px) {
  .a11y-panel {
    right: .75rem;
    bottom: 5rem;
    width: calc(100vw - 1.5rem);
    max-width: 270px;
  }
  .a11y-trigger {
    right: .75rem;
    bottom: .75rem;
  }
}
