/**
 * Sitewide design language (Phase 3).
 * Aligns inner pages with homepage tokens without redesigning IA.
 */

:root {
  --ee-orange: #ff8b28;
  --ee-orange-deep: #c45f10;
  --ee-orange-soft: #fff0e3;
  --ee-yellow: #ffc221;
  --ee-ink: #1a1a1a;
  --ee-muted: #5c5c5c;
  --ee-surface: #fffaf4;
  --ee-line: rgba(26, 26, 26, 0.08);
  --ee-radius: 1.125rem;
  --ee-space: clamp(3rem, 6vw, 5.5rem);
}

/* Focus visibility (A11) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
.but:focus-visible,
.accordion-button:focus-visible {
  outline: 3px solid var(--ee-orange);
  outline-offset: 3px;
}

/* Contrast: muted labels should remain readable (A10) */
.op05 {
  opacity: 0.72 !important;
}

/* Shared container alignment with homepage */
body:not(.home) .page-container .container {
  width: 100%;
  max-width: 1170px;
}

/* Section rhythm + typography polish */
.page-container .banner-content {
  padding-top: clamp(5.5rem, 12vw, 8rem) !important;
  padding-bottom: clamp(2.5rem, 6vw, 4.5rem) !important;
}

.page-container .padt250 {
  padding-top: clamp(5.5rem, 12vw, 10rem) !important;
}

.page-container .padt200,
.page-container .padt175,
.page-container .padt150 {
  padding-top: clamp(5rem, 10vw, 8rem) !important;
}

.page-container h1,
.page-container .h1 {
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.page-container .textual p,
.page-container .blog-content-container,
.page-container .description .blog-content {
  line-height: 1.7;
  color: var(--ee-ink);
}

/* Card / button consistency */
.page-container .card {
  border-radius: var(--ee-radius);
  border: 1px solid var(--ee-line);
  box-shadow: 0 1px 3px rgba(26, 26, 26, 0.06);
}

.page-container .but,
.page-container .but-orange,
.page-container .but-yellow,
.page-container .but-white {
  border-radius: 999px;
  min-height: 2.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: Fredoka, "Trebuchet MS", sans-serif;
  font-weight: 700;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

/* Blog cards: prefer image tags */
.ee-card-media {
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--ee-surface);
  border-radius: var(--ee-radius) var(--ee-radius) 0 0;
}

.ee-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ee-card-link {
  text-decoration: none !important;
  color: inherit !important;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.ee-card-link:hover,
.ee-card-link:focus-visible {
  box-shadow: 0 8px 28px rgba(26, 26, 26, 0.1);
}

/* Testimonials as quotes */
.ee-quote {
  margin: 0;
  padding: 0;
  border: 0;
}

.ee-quote p {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  line-height: 1.6;
}

.ee-quote cite {
  font-style: normal;
  font-weight: 600;
  font-size: 0.95rem;
}

/* Donate iframe */
.donate-form-container iframe {
  min-height: 720px;
  border: 0;
  display: block;
}

.donate-fallback-link {
  display: inline-block;
  margin-top: 0.75rem;
  font-weight: 600;
  color: var(--ee-orange-deep) !important;
}

/* Careers apply */
.ee-job-apply {
  display: inline-flex;
  margin-top: 0.5rem;
  font-weight: 600;
  color: var(--ee-orange-deep) !important;
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

/* Financial report list polish */
.financials a.bg-ltorange,
.financials a.bg-ltyellow {
  border-radius: 0.75rem;
  transition: background-color 0.15s ease, transform 0.15s ease;
}

.financials a.bg-ltorange:hover,
.financials a.bg-ltyellow:hover,
.financials a.bg-ltorange:focus-visible,
.financials a.bg-ltyellow:focus-visible {
  filter: brightness(0.98);
}

/* Page content measure for legal/policy pages */
.blog-page-description .blog-content-container {
  max-width: 65ch;
  margin-left: auto;
  margin-right: auto;
}

.blog-page-description .blog-content-container img {
  max-width: 100%;
  height: auto;
  border-radius: var(--ee-radius);
}

/* Share links need discernible names (page.php) */
.socialshare a {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

/* Contact form spacing */
.contacts .wpcf7 label,
.contacts .wpcf7 .wpcf7-form-control-wrap {
  display: block;
  margin-bottom: 0.35rem;
}

.contacts .wpcf7 input[type="submit"],
.contacts .wpcf7 input[type="text"],
.contacts .wpcf7 input[type="email"],
.contacts .wpcf7 textarea {
  border-radius: 0.75rem;
}

/* Our Work / Partners section rhythm */
.page-container .program .textual h2,
.page-container .banner-style2 .textual h1 {
  letter-spacing: -0.02em;
}

.page-container .program img.img-fluid {
  border-radius: var(--ee-radius);
}

/* Single post featured image */
.blog-page-description .imgcont img.borr20,
.blog-page-description .imgcont .borr20 {
  border-radius: var(--ee-radius);
  width: 100%;
  height: auto;
  display: block;
}

@media (max-width: 767px) {
  .donate-form-container iframe {
    min-height: 640px;
  }

  .page-container .padb150,
  .page-container .padb125,
  .page-container .padb100 {
    padding-bottom: clamp(2.5rem, 8vw, 4rem) !important;
  }
}
