/*
 * Egyházközségek Network — reusable parish presentation layer.
 * The same scoped rules work inside Oxygen Shortcode elements and Gutenberg.
 * Variables may be overridden by a centrally managed Oxygen design system.
 */
.ek-parish-card,
.ek-parish-home {
  --ek-ink: #172435;
  --ek-muted: #52616c;
  --ek-primary: #205b39;
  --ek-primary-soft: #edf5ef;
  --ek-border: #dfe7e0;
  --ek-cream: #fbf8f1;
  color: var(--ek-ink);
  font-family: inherit;
  box-sizing: border-box;
}
.ek-parish-card *,
.ek-parish-home * { box-sizing: border-box; }
.ek-parish-card a,
.ek-parish-home a { color: var(--ek-primary); text-decoration-thickness: 1px; text-underline-offset: .14em; }
.ek-parish-card a:focus-visible,
.ek-parish-home a:focus-visible { outline: 3px solid var(--ek-primary); outline-offset: 3px; }

.ek-parish-card {
  width: 100%;
  padding: clamp(1rem, 3vw, 1.75rem);
  border: 1px solid var(--ek-border);
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 8px 28px rgba(21, 51, 31, .05);
  margin-block: 1rem 1.5rem;
}
.ek-parish-card__title { font-size: clamp(1.12rem, 2.2vw, 1.45rem); line-height: 1.25; margin: 0 0 1.1rem; }
.ek-parish-card .ek-parish-card__details {
  display: grid;
  grid-template-columns: minmax(9rem, 13rem) minmax(0, 1fr);
  gap: .65rem 1.15rem;
  margin: 0;
}
.ek-parish-card .ek-parish-card__details dt { font-weight: 650; color: var(--ek-muted); }
.ek-parish-card .ek-parish-card__details dd { margin: 0; line-height: 1.55; overflow-wrap: anywhere; }
.ek-parish-card .ek-profile__links { margin: 1.4rem 0 0; padding-top: 1rem; border-top: 1px solid var(--ek-border); }
.ek-parish-card .ek-profile__website {
  text-decoration: none;
  background: var(--ek-primary-soft);
  color: var(--ek-primary);
  border: 1px solid #a4c5b1;
  border-radius: 6px;
  padding: .52rem .8rem;
  font-weight: 600;
  font-size: .9rem;
  line-height: 1.35;
  width: auto;
  max-width: 100%;
  text-align: center;
  overflow-wrap: anywhere;
}
.ek-parish-card .ek-profile__website:hover { background: #deede2; }

.ek-parish-home { width: 100%; margin: 0 auto 2rem; max-width: 1160px; }
.ek-parish-home__hero {
  padding: clamp(1.25rem, 5vw, 3rem);
  background: linear-gradient(120deg, var(--ek-cream) 0%, #eaf1e9 100%);
  border-left: 5px solid var(--ek-primary);
  border-radius: 12px;
}
.ek-parish-home__eyebrow {
  color: var(--ek-primary);
  font-size: .79rem;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  margin: 0 0 .75rem;
}
.ek-parish-home__hero h1 {
  font-size: clamp(1.65rem, 4vw, 2.6rem);
  line-height: 1.18;
  letter-spacing: -.025em;
  max-width: 25ch;
  margin: 0 0 .65rem;
  color: var(--ek-ink);
}
.ek-parish-home__lead { font-size: clamp(1rem, 2vw, 1.13rem); margin: .65rem 0 0; line-height: 1.6; }
.ek-parish-home__location { color: var(--ek-muted); margin: .9rem 0 0; font-size: .93rem; }
.ek-parish-home__main { display: grid; gap: clamp(1.3rem, 3vw, 2rem); padding-block: clamp(1.3rem, 3vw, 2rem); }
.ek-parish-home__section h2 { color: var(--ek-ink); font-size: clamp(1.15rem, 2vw, 1.45rem); margin: 0 0 1rem; line-height: 1.25; }
.ek-parish-home__facts {
  background: #fff;
  border: 1px solid var(--ek-border);
  border-radius: 12px;
  padding: clamp(1rem, 2.8vw, 1.5rem);
}
.ek-parish-home__facts dl { display: grid; grid-template-columns: minmax(10rem, 14rem) minmax(0, 1fr); gap: .55rem 1rem; margin: 0; }
.ek-parish-home__facts dt { font-weight: 650; color: var(--ek-muted); }
.ek-parish-home__facts dd { margin: 0; overflow-wrap: anywhere; white-space: normal; line-height: 1.55; }
.ek-parish-home__inline-link { display: inline-block; margin-top: 1.1rem; font-size: .92rem; font-weight: 600; }
.ek-parish-home__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: .8rem; }
.ek-parish-home__card {
  min-width: 0;
  border: 1px solid var(--ek-border);
  background: #fff;
  border-radius: 10px;
  padding: 1rem;
  box-shadow: 0 4px 14px rgba(21, 51, 31, .03);
}
.ek-parish-home__card h3 { font-size: 1.07rem; margin: .3rem 0 .55rem; font-weight: 650; line-height: 1.4; }
.ek-parish-home__card h3 a { text-decoration: none; }
.ek-parish-home__card h3 a:hover { text-decoration: underline; }
.ek-parish-home__card p { color: var(--ek-muted); margin: .35rem 0 0; font-size: .94rem; line-height: 1.55; }
.ek-parish-home__card time { color: var(--ek-primary); font-weight: 650; font-size: .89rem; }
.ek-parish-home__thumb {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: min(30vh, 240px);
  aspect-ratio: auto;
  object-fit: contain;
  border-radius: 6px;
  margin: 0 auto .65rem;
}
@media (max-width: 620px) {
  .ek-parish-card .ek-parish-card__details,
  .ek-parish-home__facts dl { grid-template-columns: minmax(0, 1fr); gap: .18rem; }
  .ek-parish-card .ek-parish-card__details dd,
  .ek-parish-home__facts dd { margin-bottom: .75rem; }
  .ek-parish-card .ek-profile__website { display: inline-flex; align-items: center; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  .ek-parish-card *, .ek-parish-home * { animation: none !important; transition: none !important; }
}

/* Structured parish, filia, subsidiary service and foundation links. */
.ek-parish-card .ek-related,
.ek-parish-home__related .ek-related,
.ek-foundation-details {
  margin-top: 1.35rem;
  padding-top: 1.1rem;
  border-top: 1px solid var(--ek-border, #dfe7e0);
}
.ek-related__section { margin-block: .65rem 1.1rem; }
.ek-related__section:last-child { margin-bottom: 0; }
.ek-related__section h3 { font-size: clamp(1rem, 1.7vw, 1.18rem); margin: 0 0 .45rem; line-height: 1.35; }
.ek-related__section ul { list-style: disc; padding-inline-start: 1.25rem; margin: .4rem 0 0; }
.ek-related__section li { margin-block: .3rem; overflow-wrap: anywhere; }
.ek-related__section p { margin: 0; }
.ek-related a { text-decoration-thickness: 1px; text-underline-offset: .13em; }
.ek-related a:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
.ek-foundation-details dl { display: grid; grid-template-columns: minmax(10rem, 13rem) minmax(0,1fr); gap: .4rem 1rem; }
.ek-foundation-details dt { font-weight: 650; }
.ek-foundation-details dd { margin: 0; overflow-wrap: anywhere; }
@media(max-width:620px){ .ek-foundation-details dl { grid-template-columns: 1fr; gap: .15rem; } .ek-foundation-details dd { margin-bottom: .65rem; } }

/* Native weekly Mass/liturgy table, shared by profiles and sub-site homepages. */
.ek-mass-schedule { margin-block:1rem 1.4rem; min-width:0; }
.ek-mass-schedule h3 { font-size:clamp(1.05rem,2vw,1.3rem); line-height:1.3; margin:0 0 .8rem; }
.ek-mass-schedule__scroll { overflow-x:auto; max-width:100%; border:1px solid var(--ek-border, #dfe7e0); border-radius:8px; }
.ek-mass-schedule__scroll:focus-visible { outline:2px solid var(--ek-primary,#205b39); outline-offset:3px; }
.ek-mass-schedule table { width:100%; min-width:460px; margin:0; border-collapse:collapse; font-size:.93rem; }
.ek-mass-schedule caption { padding:.55rem .75rem; text-align:left; font-size:.82rem; color:var(--ek-muted,#52616c); }
.ek-mass-schedule thead { background:var(--ek-primary-soft,#edf5ef); }
.ek-mass-schedule th,.ek-mass-schedule td { padding:.6rem .7rem; text-align:left; border-bottom:1px solid var(--ek-border,#dfe7e0); vertical-align:top; overflow-wrap:anywhere; }
.ek-mass-schedule thead th { font-weight:700; }
.ek-mass-schedule tbody th { font-weight:650; white-space:nowrap; }
.ek-mass-schedule tbody tr:last-child th,.ek-mass-schedule tbody tr:last-child td { border-bottom:0; }
.ek-mass-schedule__notes { line-height:1.65; margin-top:.9rem; white-space:normal; overflow-wrap:anywhere; }
.ek-parish-home__facts .ek-mass-schedule { margin-top:.2rem; }

/* Optional WordPress featured/default photo. No image = no occupied space. */
.ek-parish-card__media, .ek-parish-home__media { margin:0 0 1.25rem; padding:0; }
.ek-parish-card__image, .ek-parish-home__featured-image {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: min(55vh, 480px);
  aspect-ratio: auto;
  object-fit: contain;
  border-radius: 10px;
  margin-inline: auto;
}
.ek-parish-card__media + .ek-parish-card__title { margin-top:.5rem; }
.ek-parish-home__media { margin:clamp(.7rem,2vw,1.25rem) 0 0; }
@media(max-width:620px){
 .ek-parish-card__image,.ek-parish-home__featured-image { max-height: min(38vh, 280px); }
 .ek-parish-home__thumb { max-height: min(28vh, 190px); }
}

/* Parish website pages — scoped, responsive, distinct from the central directory. */
.ek-parish-home__navigation { margin-block: .25rem 1.1rem; }
.ek-parish-home__nav-grid {
  display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,220px),1fr));
  gap:.8rem;
}
.ek-parish-home__nav-card {
  display:flex; flex-direction:column; gap:.45rem; min-width:0;
  border:1px solid var(--ek-border,#dfe7e0); border-radius:10px;
  padding:1rem 1.15rem; background:#fff; text-decoration:none !important;
  box-shadow:0 3px 12px rgba(21,51,31,.035);
  transition:background .15s ease,border-color .15s ease;
}
.ek-parish-home__nav-card strong { font-size:1.03rem; line-height:1.35; font-weight:650; }
.ek-parish-home__nav-card span { color:var(--ek-muted,#52616c); font-size:.88rem; line-height:1.5; }
.ek-parish-home__nav-card:hover {
  background:var(--ek-primary-soft,#edf5ef);
  border-color:var(--ek-primary,#205b39);
}
.ek-parish-home__nav-card:focus-visible {
  outline:3px solid var(--ek-primary,#205b39); outline-offset:3px;
}
@media(prefers-reduced-motion:reduce) {
  .ek-parish-home__nav-card { transition:none; }
}

/* Compact sub-site menu usable inside a shared Oxygen header or Post Content. */
.ek-parish-site-nav {
  --ek-ink: #172435;
  --ek-primary: #205b39;
  --ek-primary-soft: #edf5ef;
  --ek-border: #dfe7e0;
  width: 100%;
  margin-block: .75rem 1.25rem;
  padding: .55rem;
  border: 1px solid var(--ek-border);
  border-radius: 10px;
  background: #fff;
  box-sizing: border-box;
}
.ek-parish-site-nav * { box-sizing: border-box; }
.ek-parish-site-nav__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: center;
  gap: .3rem .45rem;
}
.ek-parish-site-nav__links a {
  display: inline-flex;
  padding: .43rem .7rem;
  font: inherit;
  font-size: .9rem;
  font-weight: 550;
  line-height: 1.35;
  border-radius: 6px;
  max-width: 100%;
  min-width: 0;
  color: var(--ek-ink);
  text-decoration: none;
  overflow-wrap: anywhere;
}
.ek-parish-site-nav__links a:hover,
.ek-parish-site-nav__links a[aria-current="page"] {
  background: var(--ek-primary-soft);
  color: var(--ek-primary);
}
.ek-parish-site-nav__links a[aria-current="page"] { font-weight: 700; }
.ek-parish-site-nav__links a:focus-visible,
.ek-parish-site-back a:focus-visible {
  outline: 3px solid var(--ek-primary); outline-offset: 3px;
}
.ek-parish-site-nav__links .ek-parish-site-nav__home {
  color: var(--ek-primary);
  font-weight: 700;
}
.ek-parish-site-back { margin-block: 1.3rem 1.8rem; }
.ek-parish-site-back a {
  display: inline-flex;
  align-items: center;
  border-radius: 6px;
  padding: .45rem .7rem;
  font-size: .93rem;
  font-weight: 600;
  background: var(--ek-primary-soft, #edf5ef);
  color: var(--ek-primary, #205b39);
  text-decoration: none;
}
@media (max-width: 620px) {
  .ek-parish-site-nav { padding: .4rem; }
  .ek-parish-site-nav__links { gap: .12rem .18rem; }
  .ek-parish-site-nav__links a { padding: .45rem .55rem; font-size: .87rem; }
}

/* Uploaded Gutenberg images on parish pages retain their intrinsic ratio. */
.ek-parish-site-content img,
.ek-parish-home .wp-block-image img,
.ek-parish-home .wp-block-gallery img,
.ek-parish-card .wp-block-image img {
  max-width: 100%;
  height: auto;
  aspect-ratio: auto;
  object-fit: contain;
}
/* Limit unusually tall inline content photos without cropping them. */
.ek-parish-site-content .wp-block-image img,
.ek-parish-home .wp-block-image img {
  max-height: min(75vh, 760px);
  width: auto;
}

/* Rich community details: optional sections and consent-gated member cards. */
.ek-community-profile__sections {
  display: grid;
  gap: 1rem;
  margin-block: 1.1rem 1.4rem;
  min-width: 0;
}
.ek-community-profile__section {
  min-width: 0;
  padding: clamp(.85rem,2vw,1.2rem);
  border: 1px solid var(--ek-border,#dfe7e0);
  border-radius: 10px;
  background: #fff;
}
.ek-community-profile__section h3 {
  margin: 0 0 .6rem;
  font-size: clamp(1rem,2vw,1.15rem);
  line-height: 1.4;
}
.ek-community-profile__section p {
  margin: .4rem 0;
  line-height: 1.65;
  overflow-wrap: anywhere;
}
.ek-community-members__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(min(100%,205px),1fr));
  gap: .75rem;
}
.ek-community-members__card {
  border: 1px solid var(--ek-border,#dfe7e0);
  border-radius: 8px;
  padding: .85rem 1rem;
  min-width: 0;
  background: var(--ek-primary-soft,#f5f9f6);
}
.ek-community-members__card h4 {
  margin:0 0 .3rem;
  font-size: 1rem;
  overflow-wrap: anywhere;
}
.ek-community-members__role { font-weight: 600; }
.ek-community-members__task { font-size: .93rem; }
.ek-community-home__details { margin-block: 1rem; }
.ek-community-home__details .ek-community-profile__sections { margin: 0; }
@media(max-width:620px) {
  .ek-community-profile__sections { gap: .75rem; }
  .ek-community-members__grid { grid-template-columns: 1fr; }
}

/* Foundation profile: voluntary donations and bank account, preserving line breaks. */
.ek-foundation-details__section,
.ek-foundation-details__bank {
  margin-block: 1.15rem;
  padding: clamp(.7rem,2vw,1.1rem);
  border: 1px solid var(--ek-border,#dfe7e0);
  border-radius: 10px;
  min-width: 0;
}
.ek-foundation-details__section h3,
.ek-foundation-details__bank h3 {
  font-size: clamp(1rem,2vw,1.18rem);
  margin: 0 0 .75rem;
  line-height: 1.35;
}
.ek-foundation-details__section p {
  margin: 0;
  line-height: 1.65;
  overflow-wrap: anywhere;
}
.ek-foundation-details__bank {
  background: var(--ek-primary-soft,#edf5ef);
}
.ek-foundation-details__bank dd {
  overflow-wrap: anywhere;
  font-variant-numeric: tabular-nums;
}
@media (max-width:620px) {
  .ek-foundation-details__bank dl { grid-template-columns:1fr; }
  .ek-foundation-details__bank dt { margin-top:.45rem; }
}

/* Virtual persely: opt-in banking instructions and offsite provider links. */
.ek-donation-box {
  --ek-border:#dfe7e0; --ek-primary:#205b39;
  width:100%;max-width:100%;min-width:0;box-sizing:border-box;
  margin-block:1.3rem;
  padding:clamp(.9rem,2.5vw,1.5rem);
  border:1px solid var(--ek-border);border-radius:12px;
  background:#fff;
}
.ek-donation-box *{box-sizing:border-box}
.ek-donation-box h2{margin:0 0 .8rem;font-size:clamp(1.16rem,2.4vw,1.45rem)}
.ek-donation-box h3{margin:0 0 .75rem;font-size:clamp(1rem,2vw,1.16rem)}
.ek-donation-box__purpose{line-height:1.6;overflow-wrap:anywhere}
.ek-donation-box__bank,.ek-donation-box__online{
  padding:clamp(.65rem,2vw,1rem);margin-top:1rem;
  border:1px solid var(--ek-border);border-radius:9px;
}
.ek-donation-box__bank dl{
  display:grid;grid-template-columns:minmax(8rem,12rem) minmax(0,1fr);
  gap:.6rem 1rem;min-width:0;margin:.75rem 0;
}
.ek-donation-box__bank dt{font-weight:650}
.ek-donation-box__bank dd{
  margin:0;min-width:0;overflow-wrap:anywhere;user-select:text;
  font-variant-numeric:tabular-nums;
}
.ek-donation-box__checkout,.ek-donation-box__copy{
  display:inline-flex;align-items:center;justify-content:center;
  max-width:100%;min-height:2.65rem;padding:.5rem .85rem;
  font:inherit;font-size:.93rem;font-weight:650;
  border:1px solid var(--ek-primary);border-radius:7px;
  background:#fff;color:var(--ek-primary);text-decoration:none;
  cursor:pointer;white-space:normal;text-align:center;
}
.ek-donation-box__copy[hidden]{display:none}
.ek-donation-box__checkout{background:var(--ek-primary);color:#fff}
.ek-donation-box__checkout:hover{color:#fff;text-decoration:underline}
.ek-donation-box a:focus-visible,.ek-donation-box button:focus-visible{
  outline:3px solid var(--ek-primary);outline-offset:3px;
}
.ek-donation-box__provider,.ek-donation-box__notice{
  margin:.65rem 0 0;font-size:.83rem;line-height:1.5;color:#52616c;
  overflow-wrap:anywhere;
}
@media(max-width:620px){
  .ek-donation-box__bank dl{grid-template-columns:1fr;gap:.15rem}
  .ek-donation-box__bank dd{margin-bottom:.5rem}
}

/* Optional social media links: compact, accessible and responsive; no embeds. */
.ek-social-links {
  --ek-social-border: var(--ek-border,#dfe7e0);
  --ek-social-accent: var(--ek-primary,#205b39);
  box-sizing:border-box;
  max-width:100%;min-width:0;
  margin-block:1.15rem;
  padding:clamp(.85rem,2vw,1.1rem);
  border:1px solid var(--ek-social-border);
  border-radius:10px;
  background:#fff;
}
.ek-social-links__title {
  font-size:clamp(1rem,2vw,1.15rem);
  margin:0 0 .85rem;
}
.ek-social-links__list {
  display:flex;
  flex-wrap:wrap;
  align-items:flex-start;
  gap:.55rem;
  list-style:none;
  margin:0;
  padding:0;
}
.ek-social-links__list li { margin:0;padding:0;max-width:100%; }
.ek-social-links__link {
  display:inline-flex;
  align-items:center;
  min-height:2.5rem;
  max-width:100%;
  padding:.4rem .8rem;
  border:1px solid var(--ek-social-border);
  border-radius:7px;
  color:var(--ek-social-accent);
  background:var(--ek-primary-soft,#edf5ef);
  text-decoration:none;
  line-height:1.35;
  font-size:.92rem;
  font-weight:600;
  overflow-wrap:anywhere;
}
.ek-social-links__link:hover { text-decoration:underline; }
.ek-social-links__link:focus-visible {
  outline:3px solid var(--ek-social-accent);
  outline-offset:3px;
}
.ek-social-links .screen-reader-text {
  position:absolute;
  width:1px;height:1px;
  padding:0;margin:-1px;
  overflow:hidden;clip:rect(0,0,0,0);
  white-space:nowrap;border:0;
}
@media(max-width:480px) {
  .ek-social-links__list {gap:.4rem}
  .ek-social-links__link {min-height:2.65rem;padding:.45rem .65rem}
}

/* Current pastoral offices and community entrustments on parish profiles. */
.ek-pastoral-care{
  --ek-border:var(--ek-border,#dfe7e0);
  box-sizing:border-box;max-width:100%;min-width:0;
  margin-block:1.1rem;
  padding:clamp(.85rem,2vw,1.25rem);
  border:1px solid #dfe7e0;
  border-radius:10px;background:#fff;
}
.ek-pastoral-care h2{
  margin:0 0 .85rem;
  font-size:clamp(1.08rem,2.2vw,1.26rem);
}
.ek-pastoral-care dl{
  display:grid;
  grid-template-columns:minmax(9rem,12rem) minmax(0,1fr);
  column-gap:1rem;row-gap:.7rem;
  margin:0;
}
.ek-pastoral-care dt{font-weight:650;line-height:1.5}
.ek-pastoral-care dd{margin:0;line-height:1.5;overflow-wrap:anywhere}
.ek-pastoral-period{color:#52616c;font-size:.88rem}
.ek-pastoral-care a:focus-visible{outline:3px solid #205b39;outline-offset:3px}
@media(max-width:560px){
  .ek-pastoral-care dl{grid-template-columns:1fr;row-gap:.15rem}
  .ek-pastoral-care dt:not(:first-child){margin-top:.6rem}
}

/*
 * The WordPress/Oxygen foundation title may be rendered outside the native
 * Template Content Area. Keep the profile card 20px from both screen edges
 * even when a manually authored Oxygen Single has a full-width content node.
 * Do not add a second gutter inside an already constrained template shell.
 */
body.single-ek_foundation .ek-foundation-details.ek-parish-card {
  box-sizing: border-box;
  width: min(calc(100% - 40px), 1160px);
  max-width: 1160px;
  margin-inline: auto;
}
body.single-ek_foundation .bde-themeless-template-content-area .ek-foundation-details.ek-parish-card,
body.single-ek_foundation .ek-design-shell .ek-foundation-details.ek-parish-card {
  width: 100%;
  max-width: 100%;
}

/* Display each Mass hour on its own line, even when a day has three services. */
.ek-mass-schedule__time-slot { display:block; margin-block:.12rem; white-space:nowrap; }
.ek-mass-schedule__time-slot .ek-online-mise__schedule-link { display:inline-block; margin-inline-start:.4rem; white-space:normal; }
