/*
  SDG Header v0.4
  Header/footer system for redesigned SDG pages.
*/

.sdg-skip-link {
  position: fixed;
  left: 18px;
  top: 18px;
  z-index: 2000;
  transform: translateY(-140%);
  transition: transform .16s ease;
  background: #fff;
  color: #142846 !important;
  border: 2px solid #7b2538;
  border-radius: 999px;
  padding: 10px 16px;
  font-weight: 900;
  text-decoration: none !important;
  box-shadow: 0 16px 40px rgba(20,40,70,.22);
}

.sdg-skip-link:focus {
  transform: translateY(0);
}

.sdg-style :where(a, button, input, select, textarea, summary):focus-visible,
.sdg-site-header :where(a, button):focus-visible {
  outline: 3px solid rgba(185,154,94,.95);
  outline-offset: 4px;
}

.sdg-site-header {
  --sdg-header-bg: rgba(13, 26, 44, .78);
  --sdg-header-border: rgba(255, 255, 255, .14);
  --sdg-header-text: rgba(255,255,255,.88);
  --sdg-header-strong: #fff;
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--sdg-header-bg);
  border-bottom: 1px solid var(--sdg-header-border);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  transition: background .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.admin-bar .sdg-site-header { top: 32px; }

.sdg-site-header.is-scrolled,
body:not(.home) .sdg-site-header {
  --sdg-header-bg: rgba(251, 247, 239, .96);
  --sdg-header-border: rgba(20, 40, 70, .14);
  --sdg-header-text: #24344e;
  --sdg-header-strong: #142846;
  box-shadow: 0 8px 30px rgba(20,40,70,.10);
}

.sdg-site-header__inner {
  width: min(100% - 42px, 1180px);
  min-height: 82px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.sdg-site-header__brand { display: inline-flex; align-items: center; gap: 14px; color: var(--sdg-header-strong); text-decoration: none !important; }

.sdg-site-header__mark,
.sdg-site-header__logo-wrap {
  width: 56px;
  height: 56px;
  flex: 0 0 56px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #fbf7ef;
  border: 1px solid rgba(185,154,94,.68);
  box-shadow: 0 5px 18px rgba(8,21,37,.18), inset 0 0 0 3px rgba(185,154,94,.08);
  color: #142846;
  overflow: hidden;
}
.sdg-site-header__mark { font-family: "Cormorant Garamond", Georgia, serif; font-weight: 700; font-size: 1.25rem; line-height: 1; }
.sdg-site-header__logo {
  width: 68%;
  height: 68%;
  object-fit: contain;
  padding: 0;
}
.sdg-site-header__name { display: grid; gap: 1px; }
.sdg-site-header__title { color: var(--sdg-header-strong); font-family: "Cormorant Garamond", Georgia, serif; font-weight: 700; font-size: 1.35rem; letter-spacing: -.02em; line-height: 1; }
.sdg-site-header__tagline { color: var(--sdg-header-text); font-size: .72rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; line-height: 1; }

.sdg-site-header__nav { display: flex; align-items: center; gap: 22px; margin-left: auto; }
.sdg-site-header__nav a { color: var(--sdg-header-text); font-size: .82rem; font-weight: 850; letter-spacing: .06em; text-transform: uppercase; text-decoration: none !important; transition: color .2s ease; }
.sdg-site-header__nav a:hover, .sdg-site-header__nav a:focus, .sdg-site-header__nav .current-menu-item > a, .sdg-site-header__nav .current_page_item > a, .sdg-site-header__nav .is-current > a { color: var(--sdg-header-strong); }
.sdg-site-header__nav .is-current > a { text-decoration: underline !important; text-decoration-thickness: 2px !important; text-underline-offset: 7px; }
.sdg-site-header__nav ul { display: flex; align-items: center; gap: 22px; margin: 0; padding: 0; list-style: none; }
.sdg-site-header__nav li { margin: 0; padding: 0; list-style: none; }
.sdg-site-header__cta { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 11px 18px; border-radius: 999px; background: #7b2538; color: #fff !important; font-size: .82rem; font-weight: 900; letter-spacing: .05em; text-transform: uppercase; text-decoration: none !important; white-space: nowrap; box-shadow: 0 10px 24px rgba(123,37,56,.22); }
.sdg-visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.sdg-site-header__toggle {
  display: none;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid var(--sdg-header-border);
  border-radius: 999px;
  background: rgba(255,255,255,.10);
  color: var(--sdg-header-strong);
  line-height: 1;
  cursor: pointer;
}
.sdg-site-header__toggle-icon {
  width: 20px;
  height: 16px;
  display: grid;
  align-content: space-between;
}
.sdg-site-header__toggle-icon > span {
  display: block;
  width: 20px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform-origin: center;
  transition: transform .18s ease, opacity .18s ease;
}
.sdg-site-header.is-open .sdg-site-header__toggle-icon > span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.sdg-site-header.is-open .sdg-site-header__toggle-icon > span:nth-child(2) { opacity: 0; }
.sdg-site-header.is-open .sdg-site-header__toggle-icon > span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.sdg-style.sdg-page-footer,
.sdg-page-footer {
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  background: #081525;
  color: rgba(255,255,255,.76);
  padding: clamp(56px, 8vw, 92px) 0;
  border-top: 6px solid #7b2538;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08);
}
.sdg-style.sdg-page-footer h3,
.sdg-page-footer h3 { color: #fff; }
.sdg-page-footer .sdg-footer-logo { width: min(220px, 80%); max-height: 96px; object-fit: contain; object-position: left center; margin-bottom: 18px; }
.sdg-page-footer a { color: inherit; text-decoration: none !important; }
.sdg-page-footer a:hover { color: #fff; }
.sdg-page-footer .sdg-small { color: rgba(255,255,255,.58); }

.sdg-donation-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(360px, 440px); gap: clamp(28px, 6vw, 72px); align-items: start; }
.sdg-donation-card { background: var(--sdg-paper); border: 1px solid var(--sdg-line); border-radius: var(--sdg-radius-lg); box-shadow: 0 10px 28px rgba(20,40,70,.07); padding: clamp(22px, 3vw, 34px); }
.sdg-donation-card iframe, .sdg-donation-card givebutter-widget, .sdg-donation-card gb-widget { max-width: 100%; }

.sdg-embed-frame { background: var(--sdg-paper); border: 1px solid var(--sdg-line); border-radius: var(--sdg-radius-lg); box-shadow: var(--sdg-shadow-soft); overflow: hidden; }
.sdg-calendar-frame { aspect-ratio: 4 / 3; min-height: 520px; }
.sdg-calendar-frame iframe { width: 100%; height: 100%; min-height: 520px; border: 0; display: block; }
.sdg-signout-card { overflow: hidden; }
.sdg-signout-card :where(input, select, textarea) { max-width: 100%; }

.sdg-cf7-card .wpcf7 form { display: grid; gap: 18px; }
.sdg-cf7-card fieldset { border: 1px solid var(--sdg-line); border-radius: 18px; padding: 22px; margin: 0 0 18px; background: rgba(255,255,255,.45); }
.sdg-cf7-card legend { color: var(--sdg-navy); font-family: "Cormorant Garamond", Georgia, serif; font-size: 1.65rem; font-weight: 700; padding: 0 8px; }
.sdg-cf7-card label { display: grid; gap: 7px; color: var(--sdg-navy); font-weight: 800; }
.sdg-cf7-card .contact-form-row { margin-bottom: 14px; }
.sdg-cf7-card input[type="text"],
.sdg-cf7-card input[type="email"],
.sdg-cf7-card input[type="tel"],
.sdg-cf7-card textarea,
.sdg-cf7-card select { width: 100%; border: 1px solid var(--sdg-line); border-radius: 14px; padding: 12px 14px; background: #fff; color: var(--sdg-ink); font: inherit; }
.sdg-cf7-card textarea { min-height: 150px; resize: vertical; }
.sdg-cf7-card input[type="submit"] { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 13px 22px; border: 1px solid var(--sdg-wine); border-radius: 999px; background: var(--sdg-wine); color: #fff; font-size: .92rem; font-weight: 800; letter-spacing: .02em; line-height: 1; cursor: pointer; }
.sdg-cf7-card .wpcf7-list-item { margin-left: 0; display: block; }
.sdg-cf7-card .wpcf7-not-valid-tip { color: var(--sdg-wine); font-weight: 800; margin-top: 6px; }
.sdg-cf7-card .wpcf7-response-output { border-radius: 14px; padding: 12px 14px !important; margin: 12px 0 0 !important; }

@media (max-width: 1040px) {
  .sdg-site-header__inner { min-height: 74px; }
  .sdg-site-header__toggle { display: inline-grid; place-items: center; }
  .sdg-site-header__nav { position: absolute; inset: 74px 16px auto 16px; display: none; padding: 22px; border-radius: 22px; background: rgba(251,247,239,.98); border: 1px solid rgba(20,40,70,.14); box-shadow: 0 24px 60px rgba(20,40,70,.20); }
  .sdg-site-header.is-open .sdg-site-header__nav { display: block; }
  .sdg-site-header__nav ul { display: grid; gap: 16px; }
  .sdg-site-header__nav a { color: #142846; font-size: .9rem; }
  .sdg-site-header__cta { display: none; }
  .sdg-donation-layout { grid-template-columns: 1fr; }
  .sdg-donation-card { max-width: 560px; }
}

@media (max-width: 782px) { .admin-bar .sdg-site-header { top: 46px; } }

@media (max-width: 560px) {
  .sdg-site-header__inner { width: min(100% - 28px, 1180px); }
  .sdg-site-header__tagline { display: none; }
  .sdg-site-header__title { font-size: 1.1rem; }
  .sdg-site-header__mark, .sdg-site-header__logo-wrap { width: 46px; height: 46px; flex-basis: 46px; }
  .sdg-site-header__logo { width: 66%; height: 66%; padding: 0; }
  .sdg-calendar-frame, .sdg-calendar-frame iframe { min-height: 420px; }
  .sdg-cf7-card fieldset { padding: 18px; }
}


/* Contact page */
.sdg-style .sdg-hero--contact {
  min-height: 390px;
  padding-top: clamp(72px, 8vw, 100px);
  padding-bottom: clamp(52px, 6vw, 72px);
}
.sdg-style .sdg-hero--contact::after {
  height: 18%;
}
.sdg-style .sdg-hero--contact h1 {
  max-width: 760px;
  font-size: clamp(3.25rem, 6.5vw, 6.5rem);
}
.sdg-style .sdg-contact-section {
  padding-top: clamp(56px, 7vw, 92px);
}
.sdg-style .sdg-contact-layout {
  display: grid;
  grid-template-columns: minmax(250px, .7fr) minmax(0, 1.3fr);
  gap: clamp(34px, 6vw, 78px);
  align-items: start;
}
.sdg-style .sdg-contact-intro {
  max-width: 440px;
}
.sdg-style .sdg-contact-intro h2 {
  font-size: clamp(2.7rem, 4.5vw, 4.8rem);
}
.sdg-style .sdg-contact-intro a {
  color: var(--sdg-wine);
  font-weight: 800;
  text-underline-offset: .16em;
}
.sdg-style .sdg-cf7-card {
  min-width: 0;
  padding: clamp(24px, 4vw, 46px);
}
.sdg-style .sdg-cf7-card .wpcf7 form,
.sdg-style .sdg-cf7-form {
  display: grid;
  gap: clamp(22px, 3vw, 34px);
}
.sdg-style .sdg-cf7-section {
  display: grid;
  gap: 16px;
  padding: 0 0 clamp(22px, 3vw, 32px);
  border: 0;
  border-bottom: 1px solid var(--sdg-line);
  margin: 0;
  background: transparent;
}
.sdg-style .sdg-cf7-section:last-of-type {
  padding-bottom: 0;
  border-bottom: 0;
}
.sdg-style .sdg-cf7-section h3 {
  margin: 0;
  font-size: clamp(1.8rem, 2.6vw, 2.45rem);
}
.sdg-style .sdg-cf7-section__intro {
  max-width: 680px;
  margin: -8px 0 2px;
  color: var(--sdg-muted);
  font-size: .96rem;
}
.sdg-style .sdg-cf7-grid {
  display: grid;
  gap: 16px;
}
.sdg-style .sdg-cf7-grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.sdg-style .sdg-cf7-grid--location {
  grid-template-columns: minmax(0, 1fr) minmax(90px, .34fr) minmax(110px, .42fr);
}
.sdg-style .sdg-cf7-field {
  display: grid;
  align-content: start;
  gap: 7px;
  min-width: 0;
}
.sdg-style .sdg-cf7-field label {
  display: grid;
  gap: 7px;
  color: var(--sdg-navy);
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .055em;
  text-transform: uppercase;
}
.sdg-style .sdg-cf7-field .wpcf7-form-control-wrap {
  display: block;
}
.sdg-style .sdg-cf7-card input[type="text"],
.sdg-style .sdg-cf7-card input[type="email"],
.sdg-style .sdg-cf7-card input[type="tel"],
.sdg-style .sdg-cf7-card textarea,
.sdg-style .sdg-cf7-card select {
  min-height: 48px;
  border-radius: 11px;
  padding: 11px 13px;
  border-color: rgba(20,40,70,.23);
  box-shadow: inset 0 1px 2px rgba(20,40,70,.04);
}
.sdg-style .sdg-cf7-card textarea {
  min-height: 180px;
}
.sdg-style .sdg-cf7-card :where(input, textarea, select):focus {
  border-color: var(--sdg-gold);
  outline: 3px solid rgba(185,154,94,.22);
  outline-offset: 1px;
}
.sdg-style .sdg-form-help {
  display: block;
  margin: -2px 0 0;
  color: var(--sdg-muted);
  font-size: .82rem;
}
.sdg-style .sdg-cf7-checks {
  display: grid;
  gap: 10px;
}
.sdg-style .sdg-cf7-check {
  border: 1px solid var(--sdg-line);
  border-radius: 13px;
  padding: 13px 15px;
  background: rgba(255,255,255,.62);
}
.sdg-style .sdg-cf7-check .wpcf7-list-item label {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  color: var(--sdg-ink);
  font-size: .94rem;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.4;
  text-transform: none;
}
.sdg-style .sdg-cf7-check input[type="checkbox"] {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  margin: .12em 0 0;
  accent-color: var(--sdg-wine);
}
.sdg-style .sdg-cf7-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}
.sdg-style .sdg-cf7-card input[type="submit"] {
  min-width: 150px;
}

@media (max-width: 900px) {
  .sdg-style .sdg-contact-layout {
    grid-template-columns: 1fr;
  }
  .sdg-style .sdg-contact-intro {
    max-width: 720px;
  }
}

@media (max-width: 620px) {
  .sdg-style .sdg-hero--contact {
    min-height: 330px;
    padding-top: 58px;
    padding-bottom: 48px;
  }
  .sdg-style .sdg-hero--contact h1 {
    font-size: clamp(2.85rem, 14vw, 4.5rem);
  }
  .sdg-style .sdg-cf7-grid--2 {
    grid-template-columns: 1fr;
  }
  .sdg-style .sdg-cf7-grid--location {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .sdg-style .sdg-cf7-field--city {
    grid-column: 1 / -1;
  }
  .sdg-style .sdg-cf7-card {
    padding: 22px 18px;
  }
  .sdg-style .sdg-cf7-card input[type="submit"] {
    width: 100%;
  }
}
