/* ===================================
   EWALD FAMILY FOUNDATION - REDESIGN CSS
   UPDATED VERSION: Force override with !important, fixed spacing  standardized CTA
   =================================== */

/* CONTAINER LAYOUT - WIDER DESIGN */
.ewald-container {
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 30px;
}

.ewald-homepage-wrapper {
  background-color: #f8f6f3;
}

/* ===== HERO SECTION ===== */
.ewald-hero {
  background-size: cover !important;
  background-position: center center !important;
  background-repeat: no-repeat !important;
  padding: 120px 30px !important;
  text-align: center;
  position: relative;
  overflow: hidden;
  min-height: 600px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ewald-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1;
}

.ewald-hero-overlay {
  display: none;
}

.ewald-hero-content {
  position: relative;
  z-index: 2;
  max-width: 850px;
  margin: 0 auto;
}

.ewald-hero-title {
  font-size: 3.75rem;
  font-weight: 700;
  color: #ffffff;
  margin: 0 0 25px 0 !important;
  line-height: 1.2;
  letter-spacing: -1px;
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
}

.ewald-hero-subtitle {
  font-size: 1.35rem;
  color: #ffffff;
  margin: 0 0 20px 0 !important;
  line-height: 1.6;
  font-weight: 400;
  text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.4);
}

.ewald-button-group {
  display: flex !important;
  gap: 20px !important;
  justify-content: center !important;
  flex-wrap: wrap !important;
  margin-top: 60px !important; /* REVISED: Pushes hero buttons down away from subtext */
}

/* ===== BUTTONS - GLOBAL STYLES ===== */
.ewald-btn {
  display: inline-block !important;
  padding: 16px 40px !important; /* REVISED: Standardized button padding */
  border-radius: 6px !important;
  font-size: 1.05rem !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  transition: all 0.3s ease !important;
  border: none !important;
  cursor: pointer !important;
  line-height: 1.5 !important;
  text-align: center !important;
  letter-spacing: 0.3px !important;
  color: #ffffff !important;
  margin-top: 25px !important; /* REVISED: Pushes buttons away from preceding paragraph text */
}

.ewald-button-group .ewald-btn {
  margin-top: 0 !important; /* Keeps button group elements aligned without double margin */
}

.ewald-btn a {
  color: #ffffff !important;
  text-decoration: none !important;
}

.ewald-btn-primary {
  background-color: #8b3a3a !important;
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(139, 58, 58, 0.25) !important;
}

.ewald-btn-primary:hover,
.ewald-btn-primary:focus {
  background-color: #6b2c2c !important;
  box-shadow: 0 6px 16px rgba(139, 58, 58, 0.35) !important;
  transform: translateY(-2px) !important;
}

.ewald-btn-primary a {
  color: #ffffff !important;
  text-decoration: none !important;
}

.ewald-btn-secondary {
  background-color: #8b3a3a !important;
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(139, 58, 58, 0.25) !important;
}

.ewald-btn-secondary:hover,
.ewald-btn-secondary:focus {
  background-color: #6b2c2c !important;
  box-shadow: 0 6px 16px rgba(139, 58, 58, 0.35) !important;
  transform: translateY(-2px) !important;
}

.ewald-btn-secondary a {
  color: #ffffff !important;
  text-decoration: none !important;
}

.ewald-btn-large {
  padding: 18px 48px !important;
  font-size: 1.1rem !important;
}

.ewald-btn-icon {
  margin-left: 8px;
  font-weight: 700;
  display: none;
}

/* ===== IMPACT SECTION ===== */
.ewald-impact {
  background-color: #f8f6f3;
  padding: 120px 30px 60px 30px !important;
}

.ewald-impact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
  align-items: center;
}

.ewald-impact-image {
  order: -1;
}

.ewald-impact-content {
  padding: 0 20px;
  text-align: left !important;
}

.ewald-impact-prefix,
.ewald-history-prefix {
  font-size: 0.875rem;
  font-weight: 600;
  color: #8b3a3a;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 12px !important;
  text-align: left !important;
}

/* ===== SECTION TITLES  TEXT ===== */
.ewald-section-title {
  font-size: 2.75rem;
  font-weight: 700;
  color: #1e293b;
  margin: 0 0 20px 0 !important;
  line-height: 1.2;
  letter-spacing: -0.5px;
  text-align: left !important;
}

.ewald-section-subtitle {
  font-size: 1.1rem;
  color: #64748b;
  font-weight: 400;
  line-height: 1.6;
  text-align: left !important;
}

.ewald-section-text {
  font-size: 1.1rem;
  color: #475569;
  line-height: 1.7;
  margin: 20px 0 !important;
  font-weight: 400;
  text-align: left !important;
}

/* ===== IMAGES  FIGURES ===== */
.ewald-figure {
  margin: 0;
  padding: 0;
}

.ewald-img-responsive {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
}

/* ===== PILLARS SECTION ===== */
.ewald-pillars {
  background-color: #f8f6f3;
  padding: 0px 30px 140px 30px !important;
}

.ewald-pillars-header {
  text-align: center !important;
  margin-bottom: 60px !important;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

.ewald-pillars-header .ewald-section-title,
.ewald-pillars-header .ewald-section-subtitle {
  text-align: center !important;
  margin-left: auto;
  margin-right: auto;
}

.ewald-pillars-grid {
  display: flex;
  flex-wrap: nowrap;
  gap: 15px;
  width: 100%;
  justify-content: space-between;
}

.ewald-pillar-card {
  background-color: #ffffff;
  border-radius: 8px;
  border-left: 5px solid #8b3a3a;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  text-align: center;
  position: relative;
  overflow: hidden;
  flex: 1;
  min-width: 0;
}

.ewald-pillar-card:hover {
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12);
  transform: translateY(-8px);
  border-left-color: #6b2c2c;
}

.ewald-pillar-image {
  width: 100%;
  height: 180px;
  overflow: hidden;
  background-color: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  padding: 0;
}

.ewald-pillar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.ewald-pillar-card:hover .ewald-pillar-img {
  transform: scale(1.05);
}

.ewald-pillar-icon {
  width: 65px;
  height: 65px;
  margin: 25px auto 15px auto;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(139, 58, 58, 0.08);
  border-radius: 50%;
  transition: all 0.3s ease;
  flex-shrink: 0;
}

.ewald-pillar-card:hover .ewald-pillar-icon {
  background-color: rgba(139, 58, 58, 0.12);
  transform: scale(1.1);
}

.ewald-pillar-icon svg {
  width: 100%;
  height: 100%;
  color: #8b3a3a;
  opacity: 0.85;
}

.ewald-pillar-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1e293b;
  margin: 0 0 12px 0 !important;
  line-height: 1.3;
  padding: 0 10px;
}

.ewald-pillar-text {
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.6;
  font-weight: 400;
  margin: 0 !important;
  padding: 0 10px 25px 10px;
  text-align: center !important;
}

/* ===== HISTORY SECTION ===== */
.ewald-history {
  background-color: #f8f6f3;
  padding: 90px 30px !important;
}

.ewald-history-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 70px;
  align-items: center;
}

.ewald-history-content {
  padding: 0 20px;
  text-align: left !important;
}

/* ===== CTA GRANTS SECTION ===== */
.ewald-cta-grants {
  background-color: #8B3A3A !important;
  padding: 55px 30px !important; /* REVISED: Reduced section padding to eliminate white space */
  text-align: center !important;
  position: relative;
  overflow: hidden;
}

.ewald-cta-grants::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.3;
}

.ewald-cta-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  margin: 0 auto;
}

.ewald-cta-title {
  font-size: 2.75rem;
  font-weight: 700;
  color: #FFFFFF !important;
  margin: 0 0 15px 0 !important;
  line-height: 1.2;
}

.ewald-cta-text {
  font-size: 1.15rem;
  color: #FFFFFF !important;
  margin: 0 0 20px 0 !important; /* REVISED: Tight spacing above button */
  line-height: 1.6;
}

.ewald-cta-grants .ewald-btn-primary {
  background-color: #ffffff !important;
  color: #8b3a3a !important;
  padding: 16px 40px !important; /* REVISED: Matches standard button dimensions */
  margin-top: 0 !important;
  box-shadow: 0 4px 12px rgba(139, 58, 58, 0.15) !important;
}

.ewald-cta-grants .ewald-btn-primary:hover,
.ewald-cta-grants .ewald-btn-primary:focus {
  background-color: #f0f0f0 !important;
  color: #6b2c2c !important;
}

.ewald-cta-grants .ewald-btn-primary a {
  color: #8b3a3a !important;
  text-decoration: none !important;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1200px) {
  .ewald-container {
    padding: 0 25px;
  }

  .ewald-hero {
    padding: 100px 25px !important;
  }

  .ewald-hero-title {
    font-size: 3.2rem;
  }

  .ewald-section-title {
    font-size: 2.4rem;
  }

  .ewald-pillars-grid {
    gap: 12px;
  }

  .ewald-impact-grid,
  .ewald-history-grid {
    gap: 50px;
  }
}

@media (max-width: 1024px) {
  .ewald-container {
    padding: 0 20px;
  }

  .ewald-hero {
    padding: 80px 20px !important;
    min-height: 450px;
  }

  .ewald-hero-title {
    font-size: 2.8rem;
  }

  .ewald-section-title {
    font-size: 2.2rem;
  }

  .ewald-impact-grid,
  .ewald-history-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .ewald-impact-image {
    order: 0;
  }

  .ewald-pillars-grid {
    flex-wrap: wrap;
    gap: 12px;
  }

  .ewald-pillar-card {
    flex: 0 0 calc(33.333% - 8px);
  }

  .ewald-pillar-image {
    height: 150px;
  }

  .ewald-pillar-title {
    font-size: 1.15rem;
  }

  .ewald-pillar-text {
    font-size: 0.85rem;
    padding: 0 12px 20px 12px;
  }
}

@media (max-width: 768px) {
  .ewald-container {
    padding: 0 15px;
  }

  .ewald-hero {
    padding: 60px 15px !important;
    min-height: 380px;
  }

  .ewald-hero-title {
    font-size: 2.2rem;
  }

  .ewald-hero-subtitle {
    font-size: 1.15rem;
  }

  .ewald-button-group {
    flex-direction: column !important;
    gap: 12px !important;
    margin-top: 35px !important;
  }

  .ewald-btn {
    width: 100% !important;
    padding: 14px 30px !important;
  }

  .ewald-impact,
  .ewald-pillars,
  .ewald-history {
    padding: 60px 15px !important;
  }

  .ewald-cta-grants {
    padding: 45px 15px !important;
  }

  .ewald-section-title {
    font-size: 2rem;
  }

  .ewald-section-subtitle {
    font-size: 1rem;
  }

  .ewald-pillars-grid {
    flex-direction: column;
    gap: 20px;
  }

  .ewald-pillar-card {
    flex: none;
    width: 100%;
  }

  .ewald-pillar-image {
    height: 140px;
  }

  .ewald-pillar-icon {
    width: 55px;
    height: 55px;
    margin: 18px auto 12px auto;
  }

  .ewald-pillar-title {
    font-size: 1.05rem;
  }

  .ewald-pillar-text {
    font-size: 0.8rem;
    line-height: 1.5;
  }

  .ewald-cta-title {
    font-size: 2rem;
  }

  .ewald-cta-text {
    font-size: 1rem;
  }

  .ewald-impact-content,
  .ewald-history-content {
    padding: 0;
  }
}

@media (max-width: 480px) {
  .ewald-container {
    padding: 0 12px;
  }

  .ewald-hero {
    padding: 40px 12px !important;
    min-height: 320px;
  }

  .ewald-hero-title {
    font-size: 1.75rem;
  }

  .ewald-hero-subtitle {
    font-size: 1rem;
  }

  .ewald-btn {
    padding: 12px 24px !important;
    font-size: 0.95rem !important;
  }

  .ewald-impact,
  .ewald-pillars,
  .ewald-history {
    padding: 45px 12px !important;
  }

  .ewald-cta-grants {
    padding: 35px 12px !important;
  }

  .ewald-section-title {
    font-size: 1.75rem;
  }

  .ewald-section-text {
    font-size: 0.95rem;
  }

  .ewald-pillars-grid {
    flex-direction: column;
    gap: 20px;
  }

  .ewald-pillar-card {
    flex: none;
    width: 100%;
  }

  .ewald-pillar-image {
    height: 120px;
  }

  .ewald-pillar-icon {
    width: 50px;
    height: 50px;
    margin: 15px auto 10px auto;
  }

  .ewald-pillar-title {
    font-size: 1rem;
  }

  .ewald-pillar-text {
    font-size: 0.75rem;
    padding: 0 10px 15px 10px;
  }

  .ewald-cta-title {
    font-size: 1.5rem;
  }

  .ewald-cta-text {
    font-size: 0.95rem;
  }

  .ewald-impact-prefix,
  .ewald-history-prefix {
    font-size: 0.75rem;
  }
}

/* ===== ACCESSIBILITY ===== */
.ewald-btn:focus-visible {
  outline: 3px solid #8b3a3a !important;
  outline-offset: 2px !important;
}

.ewald-pillar-card:focus-within {
  box-shadow: 0 0 0 3px rgba(139, 58, 58, 0.2) !important;
}

/* ===== UTILITY CLASSES ===== */
.ewald-homepage-wrapper p {
  margin: 0;
}

.ewald-homepage-wrapper a {
  color: inherit;
  text-decoration: none;
}.wp-block-uagb-advanced-heading h1,.wp-block-uagb-advanced-heading h2,.wp-block-uagb-advanced-heading h3,.wp-block-uagb-advanced-heading h4,.wp-block-uagb-advanced-heading h5,.wp-block-uagb-advanced-heading h6,.wp-block-uagb-advanced-heading p,.wp-block-uagb-advanced-heading div{word-break:break-word}.wp-block-uagb-advanced-heading .uagb-heading-text{margin:0}.wp-block-uagb-advanced-heading .uagb-desc-text{margin:0}.wp-block-uagb-advanced-heading .uagb-separator{font-size:0;border-top-style:solid;display:inline-block;margin:0 0 10px 0}.wp-block-uagb-advanced-heading .uagb-highlight{color:#f78a0c;border:0;transition:all .3s ease}.uag-highlight-toolbar{border-left:0;border-top:0;border-bottom:0;border-radius:0;border-right-color:#1e1e1e}.uag-highlight-toolbar .components-button{border-radius:0;outline:none}.uag-highlight-toolbar .components-button.is-primary{color:#fff}.wp-block-uagb-advanced-heading.uagb-block-19cabb0f.wp-block-uagb-advanced-heading .uagb-desc-text{margin-bottom: 15px;}.wp-block-uagb-advanced-heading.uagb-block-19cabb0f.wp-block-uagb-advanced-heading .uagb-highlight{font-style: normal;font-weight: Default;background: #007cba;color: #fff;-webkit-text-fill-color: #fff;}.wp-block-uagb-advanced-heading.uagb-block-19cabb0f.wp-block-uagb-advanced-heading .uagb-highlight::-moz-selection{color: #fff;background: #007cba;-webkit-text-fill-color: #fff;}.wp-block-uagb-advanced-heading.uagb-block-19cabb0f.wp-block-uagb-advanced-heading .uagb-highlight::selection{color: #fff;background: #007cba;-webkit-text-fill-color: #fff;}.uag-blocks-common-selector{z-index:var(--z-index-desktop) !important}@media(max-width: 976px){.uag-blocks-common-selector{z-index:var(--z-index-tablet) !important}}@media(max-width: 767px){.uag-blocks-common-selector{z-index:var(--z-index-mobile) !important}}