/* ==========================================================================
   The Hyde Foundation – static site styles
   ========================================================================== */

:root {
  --purple: #8d2ba0;          /* headings / accents */
  --purple-btn: #8b55b3;      /* buttons */
  --purple-btn-hover: #7a3fa6;
  --purple-soft: #ece0f7;     /* pills / chips */
  --ink: #111111;             /* main headings */
  --text: #4d4d4d;            /* body copy */
  --nav: #333333;
  --line: #4f6bd8;            /* short divider under mission */
  --grey-1: #f7f7f7;          /* hero */
  --grey-2: #f5f5f5;          /* impact section */
  --grey-3: #f6f6f5;          /* about section */
  --page-bg: #f6f7fb;         /* resources page */
  --max: 1200px;
  --radius: 22px;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-sub: "Roboto", system-ui, sans-serif;
  --font-nav: "Poppins", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--purple); }
a:hover { color: var(--purple-btn-hover); }
h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.2; color: var(--ink); }
p { margin: 0 0 1em; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.skip-link { position: absolute; left: -999px; top: 0; background: #fff; padding: 8px 12px; z-index: 100; }
.skip-link:focus { left: 8px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 16px;
  line-height: 1;
  color: #fff;
  background: var(--purple-btn);
  padding: 14px 34px;
  border-radius: 100px;
  text-decoration: none;
  transition: background .2s, transform .2s;
}
.btn:hover { background: var(--purple-btn-hover); color: #fff; transform: translateY(-1px); }

/* ---------- Header ---------- */
.site-header { background: #fff; position: relative; z-index: 50; }
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 112px; gap: 24px;
}
.logo img { height: 88px; width: auto; }

.nav-toggle { display: none; }
.nav-toggle-label { display: none; cursor: pointer; padding: 10px; }
.nav-toggle-label span,
.nav-toggle-label span::before,
.nav-toggle-label span::after {
  display: block; width: 26px; height: 2px; background: var(--nav);
  position: relative; transition: transform .2s, background .2s;
}
.nav-toggle-label span::before,
.nav-toggle-label span::after { content: ""; position: absolute; left: 0; }
.nav-toggle-label span::before { top: -8px; }
.nav-toggle-label span::after { top: 8px; }

.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 34px; }
.main-nav a {
  font-family: var(--font-nav);
  font-size: 16px;
  color: var(--nav);
  text-decoration: none;
  padding: 6px 0;
  position: relative;
}
.main-nav a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 0;
  background: var(--purple); transition: width .2s;
}
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--purple); }
.main-nav a:hover::after, .main-nav a[aria-current="page"]::after { width: 100%; }

@media (max-width: 1024px) {
  .nav-toggle-label { display: block; }
  .main-nav {
    position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; box-shadow: 0 12px 24px rgba(0,0,0,.08);
    max-height: 0; overflow: hidden; transition: max-height .3s ease;
  }
  .main-nav ul { flex-direction: column; gap: 0; padding: 8px 20px 16px; }
  .main-nav li { border-bottom: 1px solid #eee; }
  .main-nav li:last-child { border-bottom: 0; }
  .main-nav a { display: block; padding: 14px 0; }
  .main-nav a::after { display: none; }
  .nav-toggle:checked ~ .main-nav { max-height: 480px; }
  .nav-toggle:checked + .nav-toggle-label span { background: transparent; }
  .nav-toggle:checked + .nav-toggle-label span::before { transform: translateY(8px) rotate(45deg); }
  .nav-toggle:checked + .nav-toggle-label span::after { transform: translateY(-8px) rotate(-45deg); }
  .logo img { height: 72px; }
  .site-header .container { min-height: 96px; }
}

/* ---------- Footer ---------- */
.site-footer { background: #fff; border-top: 1px solid #eee; padding: 56px 0 40px; text-align: center; }
.social { list-style: none; margin: 0 0 28px; padding: 0; display: flex; justify-content: center; gap: 14px; }
.social a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--purple-soft); color: var(--purple);
  transition: background .2s, color .2s;
}
.social a:hover { background: var(--purple); color: #fff; }
.social svg { width: 20px; height: 20px; fill: currentColor; }
.footer-bottom {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px;
  font-family: var(--font-nav); font-size: 14px; color: #666;
  border-top: 1px solid #eee; padding-top: 24px;
}
.footer-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; }
.footer-nav a { color: #555; text-decoration: none; }
.footer-nav a:hover { color: var(--purple); }
@media (max-width: 768px) {
  .footer-bottom { flex-direction: column; text-align: center; }
  .footer-nav ul { justify-content: center; }
}

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ==========================================================================
   Home
   ========================================================================== */
.eyebrow { font-size: 18px; font-weight: 400; color: var(--ink); text-transform: uppercase; letter-spacing: .02em; margin-bottom: 10px; }
.section-title { font-size: clamp(34px, 5vw, 52px); font-weight: 700; color: var(--ink); }
.sub-purple { font-family: var(--font-sub); font-weight: 600; color: var(--purple); }

.hero { background: var(--grey-1); padding: 20px 0; }
.hero .container { display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 40px; }
.hero h1 { font-size: clamp(38px, 5.5vw, 55px); font-weight: 700; line-height: 1.15; margin-bottom: 8px; }
.hero .lead { font-size: clamp(19px, 2.2vw, 24px); color: var(--ink); line-height: 1.45; margin-bottom: 36px; }
.hero-figure { margin: 0; text-align: center; }
.hero-figure img { margin: 0 auto; max-height: 560px; width: auto; }
.hero-figure figcaption { font-family: var(--font-nav); font-size: 14px; font-style: italic; color: #555; margin-top: 8px; }
.hero-figure a { text-decoration: none; }

.mission { padding: 80px 0 40px; }
.mission .container { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; }
.mission h2.sub-purple { font-size: 32px; }
.mission .statement { font-size: 24px; font-weight: 700; color: var(--ink); line-height: 1.4; }
.divider { width: 70px; height: 3px; background: var(--line); border: 0; margin: 26px 0; }
.mission h3.sub-purple { font-size: 24px; margin: 0; }
.mission h3.sub-purple + h3.sub-purple { margin-bottom: 12px; }

.services { padding: 20px 0 65px; text-align: center; }
.services .section-title { margin-bottom: 40px; }
.services-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; text-align: left; }
.service h3 { font-size: 24px; }
.service p { font-size: 16px; }
.service.inquiries { background: var(--grey-2); border-radius: 16px; padding: 28px; color: var(--ink); }
.service.inquiries h3 { font-family: var(--font-body); font-weight: 700; color: var(--ink); }

.benefits { padding: 30px 0 80px; }
.benefits .container { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: center; }
.benefits img { border-radius: var(--radius); width: 100%; object-fit: cover; }
.benefits h2 { font-size: clamp(28px, 3.5vw, 32px); }
.benefits ul { margin: 0; padding-left: 20px; font-family: var(--font-sub); color: #000; }
.benefits li { margin-bottom: 8px; }

.projects { padding: 20px 0 70px; text-align: center; }
.projects .section-title { margin-bottom: 28px; }
.project-chip {
  display: inline-flex; align-items: center; gap: 14px;
  background: #fff; border-radius: 100px; padding: 10px 12px 10px 20px;
  box-shadow: 0 10px 30px rgba(0,0,0,.08);
}
.project-chip img { height: 34px; width: auto; }
.project-chip span {
  background: var(--purple-soft); color: var(--ink); font-weight: 700; font-size: 16px;
  padding: 8px 16px; border-radius: 100px;
}

.impact { background: var(--grey-2); padding: 65px 0; }
.impact .container { display: grid; grid-template-columns: 1fr 1.1fr 1fr; gap: 40px; align-items: start; }
.impact .section-title { line-height: 1.1; }
.impact .tagline { font-size: 24px; color: var(--ink); line-height: 1.4; }
.impact img { border-radius: var(--radius); width: 100%; object-fit: cover; }
.impact h3 { font-size: 28px; font-weight: 700; }
.impact p { color: var(--ink); }

/* ==========================================================================
   Inner pages
   ========================================================================== */
.page-hero-image {
  background-size: cover; background-position: center;
  min-height: 300px; display: flex; align-items: center; justify-content: center;
  position: relative; text-align: center;
}
.page-hero-image::before { content: ""; position: absolute; inset: 0; background: rgba(60, 10, 80, .15); }
.page-hero-image h1 {
  position: relative; color: #fff; text-transform: uppercase; letter-spacing: .04em;
  font-size: clamp(26px, 3.5vw, 36px); font-weight: 700; margin: 0;
  text-shadow: 0 2px 12px rgba(0,0,0,.25);
}

.about-story { background: var(--grey-3); padding: 70px 0 90px; }
.about-story .container { display: grid; grid-template-columns: 1fr 1.1fr; gap: 50px; align-items: start; }
.about-story h2 { color: var(--purple); font-size: clamp(28px, 3.5vw, 36px); font-family: var(--font-sub); }

.page-intro { padding: 40px 0 10px; }
.page-intro h1 { color: var(--purple); font-size: clamp(30px, 4vw, 40px); font-family: var(--font-sub); font-weight: 600; }

.gallery { padding: 20px 0 80px; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.card { background: #fff; }
.card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 6px; margin-bottom: 16px; }
.card h3 { font-size: 20px; color: var(--purple); font-family: var(--font-sub); font-weight: 600; }
.card p { font-size: 15px; }

/* Resources */
.resources-page { background: var(--page-bg); padding: 50px 0 80px; }
.resources-page h1 { color: var(--purple); font-family: var(--font-sub); font-weight: 600; font-size: clamp(28px, 3.5vw, 36px); }
.resources-page > .container > p { margin-bottom: 30px; }
.resources-page h2 { font-size: 22px; margin: 34px 0 16px; }
.res-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.res-card {
  background: #fff; border-radius: 14px; padding: 22px;
  box-shadow: 0 4px 18px rgba(20, 20, 60, .06); font-size: 15px;
}
.res-card .tag {
  display: inline-block; font-size: 11px; background: #e6f1fb; color: #2b4a73;
  padding: 3px 10px; border-radius: 100px; margin-bottom: 10px;
}
.res-card h3 { color: var(--purple); font-size: 17px; font-family: var(--font-sub); font-weight: 600; }
.res-card a { color: #2d55c6; text-decoration: none; }
.res-card a:hover { text-decoration: underline; }

/* Contact */
.contact { padding: 70px 0 100px; }
.contact .box { max-width: 720px; margin: 0 auto; text-align: center; }
.contact h1 { color: var(--purple); font-family: var(--font-sub); font-weight: 600; font-size: clamp(28px, 3.5vw, 38px); }
.contact address { font-style: normal; font-size: 18px; color: var(--ink); line-height: 1.7; margin-top: 24px; }
.contact address a { color: var(--ink); text-decoration: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .impact .container { grid-template-columns: 1fr 1fr; }
  .impact .impact-head { grid-column: 1 / -1; }
  .gallery-grid, .res-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .hero .container, .mission .container, .benefits .container,
  .about-story .container, .impact .container { grid-template-columns: 1fr; }
  .hero { padding: 40px 0; }
  .hero-figure img { max-height: 420px; }
  .mission { padding: 56px 0 24px; }
  .mission .container { gap: 20px; }
  .services-grid, .gallery-grid, .res-grid { grid-template-columns: 1fr; }
  .project-chip { flex-direction: column; border-radius: 24px; padding: 16px; }
}
