/* Page-wide styles (body, content, footer). Header styles live in header.css. */
body {
  margin: 0;
  /* small green leaves tiled behind every page (transparent around the leaves, so the
     pale green colour shows through). The image is drawn smaller than its real size so
     it stays sharp on high-resolution screens; change 338px to resize the leaves.
     Change ?v= whenever bg-leaves.png is replaced so browsers and Cloudflare load
     the new picture. */
  background: #f3f8f4 url("../img/bg-leaves.png?v=3") repeat left top / 338px 338px;
  color: #1d2b24;
  font-family: "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
}

/* White background for pages that set $bodyClass = 'page-white'
   (only shows where the leaf pattern hasn't loaded yet) */
body.page-white { background-color: #fff; }

/* Parent button stays highlighted while on one of its sub-pages */
.ecf-has-sub.is-current > .ecf-parent { background: #fff; font-weight: 600; }

.ecf-main {
  max-width: 1100px;
  margin: 0 auto;
  padding: 32px 24px 64px;
}
.ecf-main h1 { font-family: Georgia, "Times New Roman", serif; color: #3d7c57; line-height: 1.2; }

/* Rounded green border around every page's content (opened in header.php,
   closed in footer.php), same green as the menu bar */
.ecf-box {
  background: rgba(255, 255, 255, .95);   /* keeps text readable over the leaf background */
  box-shadow: 0 8px 24px rgba(29, 43, 36, .15);
  border: 3px solid #3d7c57;
  border-radius: 28px;
  padding: 32px 40px 40px;
}
.ecf-box > :first-child,
.ecf-box > :first-child h1 { margin-top: 0; }
@media (max-width: 760px) {
  .ecf-box { border-radius: 20px; padding: 20px 18px 24px; }
}

/* Text pages: comfortable line length, larger opening paragraph */
.ecf-text { max-width: 820px; }
.ecf-text p { margin: 0 0 16px; }
.ecf-text .ecf-section-title { font-size: 26px; margin: 36px 0 12px; }

/* Home page tagline: big white text on a patterned green panel */
.ecf-tagline {
  margin: 24px 0 8px;
  padding: 56px 40px;
  border-radius: 20px;
  text-align: center;
  color: #fff;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(28px, 4.2vw, 46px);
  line-height: 1.2;
  background-color: #3d7c57;
  background-image:
    radial-gradient(circle at 30% 30%, rgba(217, 251, 232, .22) 2px, transparent 2.6px),
    radial-gradient(circle at 70% 70%, rgba(217, 251, 232, .14) 3px, transparent 3.6px);
  background-size: 14px 14px, 23px 23px;
  box-shadow: 4px 4px 0 #1d2b24;
}
@media (max-width: 760px) {
  .ecf-tagline { padding: 36px 20px; }
}

/* List with green check marks (e.g. eligibility requirements) */
.ecf-checklist { list-style: none; margin: 0 0 16px; padding: 0; }
.ecf-checklist li {
  position: relative;
  padding: 14px 18px 14px 52px;
  margin-bottom: 12px;
  background: #e6f2ea;
  border-radius: 12px;
}
.ecf-checklist li::before {
  content: "";
  position: absolute;
  left: 16px; top: 16px;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: #3d7c57 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 6.2 L5 8.5 L9.5 3.5' stroke='white' stroke-width='1.8' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 14px no-repeat;
}
.ecf-lead { font-size: 21px; line-height: 1.5; color: #3d7c57; font-family: Georgia, "Times New Roman", serif; }

.ecf-footer {
  text-align: center;
  padding: 10px 24px;
  margin: 0 auto 24px;
  max-width: max-content;
  background: rgba(255, 255, 255, .92);
  border-radius: 999px;
  font-size: 14px;
}
.ecf-footer p { margin: 0; }
.ecf-footer a { color: #3d7c57; }

/* ---------- Staff & Board page (board.php) ---------- */

.ecf-people-hero h1 {
  font-size: clamp(44px, 8vw, 96px);
  line-height: 1;
  letter-spacing: -1px;
  margin: 8px 0 12px;
}
.ecf-people-intro { font-size: 20px; font-weight: 600; margin: 0 0 28px; }

/* Patterned stripe under the heading, in the site's green and mint */
.ecf-band {
  height: 52px;
  margin-bottom: 36px;
  border-radius: 6px;
  background-color: #3d7c57;
  background-image:
    radial-gradient(circle at 30% 30%, rgba(217, 251, 232, .45) 2px, transparent 2.6px),
    radial-gradient(circle at 70% 70%, rgba(217, 251, 232, .25) 3px, transparent 3.6px);
  background-size: 14px 14px, 23px 23px;
}

/* Person cards: one column */
.ecf-people {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  max-width: 860px;
}
.ecf-person { background: #e6f2ea; border-radius: 6px; }

.ecf-person-top {
  display: grid;
  grid-template-columns: 130px 1fr auto;
  align-items: center;
  gap: 24px;
  padding: 12px 22px 12px 12px;
  list-style: none;
}
summary.ecf-person-top { cursor: pointer; }
summary.ecf-person-top::-webkit-details-marker { display: none; }

.ecf-photo {
  width: 130px; height: 130px;
  border-radius: 50%;
  overflow: hidden;
  display: grid;
  place-items: center;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 44px;
}
.ecf-photo img { width: 100%; height: 100%; object-fit: cover; }
.ecf-tone-0 { background: #3d7c57; color: #fff; }   /* site green   */
.ecf-tone-1 { background: #d9fbe8; color: #1d2b24; } /* menu mint    */
.ecf-tone-2 { background: #a51e36; color: #fff; }   /* logo red     */
.ecf-tone-3 { background: #8cc3a3; color: #1d2b24; } /* light green  */

.ecf-person-info p { margin: 0; line-height: 1.45; }
.ecf-person h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 28px;
  font-weight: 400;
  line-height: 1.15;
  margin: 0 0 6px;
}
.ecf-person-title { font-weight: 600; }
.ecf-person-contact { margin-top: 10px !important; }
.ecf-person-contact a { color: inherit; text-decoration: none; }
.ecf-person-contact a:hover { color: #3d7c57; text-decoration: underline; }

.ecf-person-chevron {
  width: 14px; height: 14px;
  align-self: end;
  margin-bottom: 14px;
  transition: transform .2s ease;
}
.ecf-person[open] .ecf-person-chevron { transform: rotate(180deg); }
.ecf-person-more { margin-top: 10px !important; font-size: 14px; color: #3d7c57; text-decoration: underline; }
.ecf-person[open] .ecf-person-more { display: none; }
.ecf-person-bio { padding: 4px 28px 22px; }
.ecf-person-bio p { margin: 0 0 12px; }
.ecf-person-bio p:last-child { margin-bottom: 0; }

.ecf-section-title {
  font-family: Georgia, "Times New Roman", serif;
  color: #3d7c57;
  font-size: 36px;
  line-height: 1.2;
  margin: 48px 0 16px;
}
.ecf-section-intro { max-width: 860px; margin: -4px 0 24px; }

@media (max-width: 760px) {
  .ecf-person-top { grid-template-columns: 90px 1fr auto; gap: 16px; }
  .ecf-photo { width: 90px; height: 90px; font-size: 32px; }
  .ecf-person h3 { font-size: 24px; }
  .ecf-person-bio { padding: 4px 18px 18px; }
}

/* ---------- History page (history.php) ---------- */
.ecf-history {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 40px;
  align-items: start;
  margin-top: 24px;
}
.ecf-history.no-photo { grid-template-columns: minmax(0, 1fr); max-width: 760px; }
.ecf-history-photo { margin: 0; }
.ecf-history-photo img {
  display: block;
  max-width: 100%;             /* never larger than the photo's own size */
  height: auto;
  border-radius: 20px;
  box-shadow: 4px 4px 0 #1d2b24;
}
.ecf-history-photo figcaption { margin-top: 10px; font-size: 14px; font-style: italic; color: #4a5a52; }
.ecf-history-photo figcaption span { font-style: normal; font-size: 13px; }
.ecf-history-text p { margin: 0 0 16px; }

@media (max-width: 760px) {
  .ecf-history { grid-template-columns: minmax(0, 1fr); gap: 24px; }
}

/* ---------- Donate page (donate.php) ---------- */
.ecf-donate-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 28px;
  align-items: center;
  margin: 24px 0 8px;
  padding: 24px 28px;
  background: #e6f2ea;
  border-radius: 20px;
}
.ecf-donate-card img { width: 120px; height: 120px; border-radius: 16px; background: #fff; }
.ecf-donate-card h2 {
  font-family: Georgia, "Times New Roman", serif;
  color: #3d7c57;
  font-size: 26px;
  line-height: 1.2;
  margin: 0 0 8px;
}

/* Mint button, same look as the menu buttons */
.ecf-button {
  display: inline-block;
  padding: 10px 28px;
  font-size: 17px;
  font-weight: 600;
  color: #1d2b24;
  text-decoration: none;
  background: #d9fbe8;
  border: 1px solid #1d2b24;
  border-radius: 10px;
  box-shadow: 2px 2px 0 #1d2b24;
  transition: background .15s ease, transform .1s ease, box-shadow .1s ease;
}
.ecf-button:hover, .ecf-button:focus-visible { background: #b8f0d0; }
.ecf-button:active { transform: translate(2px, 2px); box-shadow: 0 0 0 #1d2b24; }

/* Green Donate button that gently pulses to draw attention */
.ecf-button-donate {
  padding: 12px 36px;
  font-size: 19px;
  color: #fff;
  background: #3d7c57;
  border-radius: 16px;
  animation: ecf-pulse 1.6s ease-in-out infinite;
}
.ecf-button-donate:hover,
.ecf-button-donate:focus-visible { background: #2f6646; animation-play-state: paused; }
@keyframes ecf-pulse {
  0%, 100% { background-color: #3d7c57; box-shadow: 2px 2px 0 #1d2b24, 0 0 0 0 rgba(61, 124, 87, .55); }
  50%      { background-color: #4f9c6f; box-shadow: 2px 2px 0 #1d2b24, 0 0 0 12px rgba(61, 124, 87, 0); }
}
/* No animation for visitors who have asked their device to reduce motion */
@media (prefers-reduced-motion: reduce) {
  .ecf-button-donate { animation: none; }
}

.ecf-address { font-style: normal; margin: 0 0 16px; padding-left: 16px; border-left: 3px solid #3d7c57; }

@media (max-width: 760px) {
  .ecf-donate-card { grid-template-columns: 1fr; justify-items: start; padding: 20px; }
  .ecf-donate-card img { width: 90px; height: 90px; }
}

/* ---------- Contact page: social media cells (contact.php) ---------- */
.ecf-social {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
}
.ecf-social li { display: flex; }
.ecf-social a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  box-sizing: border-box;
  width: 100%;
  padding: 22px 8px 18px;
  text-align: center;
  text-decoration: none;
  color: #1d2b24;
  background: #e6f2ea;
  border: 1px solid #1d2b24;
  border-radius: 16px;
  box-shadow: 3px 3px 0 #1d2b24;
  transition: background .15s ease, transform .1s ease, box-shadow .1s ease;
}
.ecf-social a:hover,
.ecf-social a:focus-visible { background: #d9fbe8; outline: none; }
.ecf-social a:active { transform: translate(3px, 3px); box-shadow: 0 0 0 #1d2b24; }

.ecf-social-icon {
  display: grid;
  place-items: center;
  width: 64px; height: 64px;
  margin-bottom: 6px;
  border-radius: 50%;
  color: #fff;
}
.ecf-social-icon svg { width: 30px; height: 30px; }
/* Each network's own color so the symbols are easy to recognize */
.ecf-social-facebook  .ecf-social-icon { background: #1877f2; }
.ecf-social-instagram .ecf-social-icon { background: linear-gradient(45deg, #f9a825, #e1306c 50%, #833ab4); }
.ecf-social-linkedin  .ecf-social-icon { background: #0a66c2; }
.ecf-social-youtube   .ecf-social-icon { background: #ff0000; }
.ecf-social-x         .ecf-social-icon { background: #000; }

.ecf-social-name { font-family: Georgia, "Times New Roman", serif; font-size: 20px; color: #3d7c57; }
.ecf-social-handle { font-size: 12px; line-height: 1.4; color: #4a5a52; overflow-wrap: anywhere; }

/* Contact details under the social cells */
.ecf-contact-info .ecf-section-title { font-size: 26px; margin: 40px 0 16px; }
.ecf-contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.ecf-contact-grid > div {
  padding: 18px 22px;
  background: #e6f2ea;
  border-radius: 16px;
  border-left: 5px solid #3d7c57;
}
.ecf-contact-grid h3 {
  margin: 0 0 6px;
  font-size: 14px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #3d7c57;
}
.ecf-contact-grid p,
.ecf-contact-grid address { margin: 0; font-style: normal; font-size: 17px; line-height: 1.5; }
.ecf-contact-grid a { color: #1d2b24; font-weight: 600; text-decoration: none; }
.ecf-contact-grid a:hover { color: #3d7c57; text-decoration: underline; }

/* ---------- Media page: latest social posts (media.php) ---------- */
.ecf-feed {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.ecf-post {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  color: #1d2b24;
  text-decoration: none;
  background: #e6f2ea;
  border: 1px solid #1d2b24;
  border-radius: 16px;
  box-shadow: 3px 3px 0 #1d2b24;
  transition: transform .1s ease, box-shadow .1s ease;
}
.ecf-post:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 #1d2b24; }
.ecf-post img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; display: block; background: #fff; }
.ecf-post-body { padding: 14px 16px 16px; display: flex; flex-direction: column; flex: 1; }
.ecf-post-body p { margin: 0 0 10px; font-size: 15px; line-height: 1.5; }
.ecf-post-date { font-size: 13px !important; color: #3d7c57; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.ecf-post-more { margin-top: auto !important; margin-bottom: 0 !important; color: #3d7c57; font-weight: 600; }
.ecf-feed-follow { margin: 14px 0 0; }
.ecf-feed-follow a { color: #3d7c57; font-weight: 600; }
.ecf-feed-empty {
  padding: 24px;
  background: #e6f2ea;
  border-radius: 16px;
  text-align: center;
}
.ecf-feed-empty p { margin: 0 0 14px; }
.ecf-section-sm { font-size: 26px; margin-top: 36px; }

/* ---------- Events page (events.php) ---------- */
.ecf-events { list-style: none; margin: 24px 0 0; padding: 0; }
.ecf-event {
  display: flex;
  gap: 22px;
  align-items: flex-start;
  padding: 22px;
  margin-bottom: 18px;
  background: #e6f2ea;
  border-radius: 16px;
}
/* Calendar-style date badge */
.ecf-event-date {
  flex: 0 0 76px;
  text-align: center;
  background: #fff;
  border: 2px solid #3d7c57;
  border-radius: 14px;
  overflow: hidden;
}
.ecf-event-month {
  display: block;
  padding: 3px 0;
  background: #3d7c57;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.ecf-event-day {
  display: block;
  padding: 4px 0 6px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 32px;
  line-height: 1.1;
  color: #3d7c57;
}
.ecf-event-body h2 { margin: 0 0 4px; font-family: Georgia, "Times New Roman", serif; font-size: 24px; color: #3d7c57; }
.ecf-event-body p { margin: 0 0 10px; }
.ecf-event-when { font-weight: 600; }
.ecf-event-place { color: #4a5a52; }
.ecf-event-text a { color: #3d7c57; font-weight: 600; }
@media (max-width: 760px) {
  .ecf-event { gap: 14px; padding: 16px; }
  .ecf-event-date { flex-basis: 60px; }
  .ecf-event-day { font-size: 26px; }
}

/* ---------- Members area (login.php, forms.php) ---------- */
.ecf-login { max-width: 420px; margin: 0 auto; }
.ecf-login form { display: flex; flex-direction: column; gap: 6px; margin-top: 20px; }
.ecf-login label { font-weight: 600; }
.ecf-login input {
  font: inherit;
  padding: 10px 12px;
  margin-bottom: 10px;
  border: 1px solid #9db8a8;
  border-radius: 10px;
}
.ecf-login input:focus { outline: 2px solid #3d7c57; outline-offset: 1px; border-color: #3d7c57; }
.ecf-login button { align-self: flex-start; margin-top: 6px; cursor: pointer; font-family: inherit; }
.ecf-login-error { padding: 12px 16px; background: #fdecec; color: #8a1f1f; border-radius: 10px; }
.ecf-login-help { margin-top: 24px; font-size: 15px; }
.ecf-login-help a, .ecf-member-bar a { color: #3d7c57; }

.ecf-member-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 8px 8px 8px 16px;
  margin-bottom: 20px;
  background: #e6f2ea;
  border-radius: 999px;
  font-size: 15px;
}
.ecf-member-bar form { margin: 0; }
.ecf-member-logout {
  font: inherit;
  padding: 6px 16px;
  color: #fff;
  background: #3d7c57;
  border: 0;
  border-radius: 999px;
  cursor: pointer;
}
.ecf-member-logout:hover { background: #2c6243; }

.ecf-files { list-style: none; margin: 24px 0 0; padding: 0; }
.ecf-files li { margin-bottom: 12px; }
.ecf-file {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 16px;
  color: #1d2b24;
  text-decoration: none;
  background: #e6f2ea;
  border-radius: 14px;
  transition: background .15s ease;
}
.ecf-file:hover, .ecf-file:focus-visible { background: #d3ecdc; }
.ecf-file-type {
  flex: 0 0 52px;
  padding: 10px 0;
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  background: #3d7c57;
  border-radius: 8px;
}
.ecf-file-pdf { background: #b3261e; }
.ecf-file-doc, .ecf-file-docx { background: #2b579a; }
.ecf-file-xls, .ecf-file-xlsx, .ecf-file-csv { background: #217346; }
.ecf-file-ppt, .ecf-file-pptx { background: #c43e1c; }
.ecf-file-link { background: #3d7c57; font-size: 12px; }
.ecf-link-row { display: flex; align-items: center; gap: 10px; }
.ecf-link-row .ecf-file { flex: 1; min-width: 0; }
.ecf-link-actions { flex-wrap: nowrap; }
.ecf-link-actions button:disabled { opacity: .35; cursor: default; background: transparent; }
.ecf-admin-add .ecf-wide { flex-basis: 100%; }
.ecf-file-info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ecf-file-title { font-weight: 600; font-size: 17px; }
.ecf-file-meta { font-size: 14px; color: #4a5a52; }
.ecf-file-get { font-weight: 600; color: #3d7c57; white-space: nowrap; }
@media (max-width: 760px) {
  .ecf-file-get { display: none; }
}

/* Member links, notices and the Manage members page (account.php, members-admin.php) */
.ecf-member-links { display: flex; gap: 16px; margin-left: auto; }
.ecf-member-links a { color: #3d7c57; font-weight: 600; }
.ecf-notice { padding: 12px 16px; background: #dff3e6; color: #1d4d33; border-radius: 10px; }
.ecf-notice small { color: #4a5a52; }
.ecf-hint { font-size: 14px; font-weight: 400; color: #4a5a52; }
.ecf-back { margin: 0 0 8px; font-size: 15px; }
.ecf-back a { color: #3d7c57; }

.ecf-admin-add { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px 16px; }
.ecf-admin-add div { display: flex; flex-direction: column; gap: 4px; flex: 1 1 200px; }
.ecf-admin-add label { font-weight: 600; }
.ecf-admin-add input[type="text"] { font: inherit; padding: 9px 12px; border: 1px solid #9db8a8; border-radius: 10px; }
.ecf-admin-add input[type="text"]:focus { outline: 2px solid #3d7c57; outline-offset: 1px; }
.ecf-admin-add .ecf-check { flex-basis: 100%; display: flex; align-items: center; gap: 8px; font-weight: 400; }
.ecf-admin-add button { cursor: pointer; font-family: inherit; }

.ecf-member-list { list-style: none; margin: 16px 0 0; padding: 0; }
.ecf-member-list li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  padding: 12px 16px;
  margin-bottom: 10px;
  background: #e6f2ea;
  border-radius: 14px;
}
.ecf-member-info { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.ecf-member-meta { flex-basis: 100%; font-size: 14px; color: #4a5a52; }
.ecf-tag { padding: 1px 10px; font-size: 12px; font-weight: 700; color: #fff; background: #3d7c57; border-radius: 999px; }
.ecf-tag-you { background: #6b7d73; }
.ecf-member-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.ecf-member-actions form { margin: 0; }
.ecf-member-actions button {
  font: inherit;
  font-size: 14px;
  padding: 5px 14px;
  color: #1d2b24;
  background: #fff;
  border: 1px solid #9db8a8;
  border-radius: 999px;
  cursor: pointer;
}
.ecf-member-actions button:hover { background: #d3ecdc; }
.ecf-member-actions .ecf-danger { color: #8a1f1f; border-color: #e0b4b4; }
.ecf-member-actions .ecf-danger:hover { background: #fdecec; }
@media (max-width: 760px) {
  .ecf-member-bar { flex-wrap: wrap; border-radius: 16px; }
  .ecf-member-links { margin-left: 0; }
  .ecf-link-row { flex-wrap: wrap; gap: 6px; }
  .ecf-link-row .ecf-file { flex-basis: 100%; }
  .ecf-link-actions { justify-content: flex-end; width: 100%; }
}
