/* EKODI Church approved layout: one first-screen masthead, one selected destination.
   A site-local presentation layer only: no auth, storage or broadcast state changes. */
:root{--church-content-width:1120px}

/* Keep header, content, footer on the same centered grid without replacing the church identity. */
.site-header{
  position:sticky!important;
  top:0;
  min-height:84px;
  width:100%;
  padding-inline:max(18px,calc((100% - var(--church-content-width))/2))!important;
  background:#fbfaf6!important;
  color:#173730!important;
  border-bottom:1px solid rgba(23,55,48,.14)!important;
  box-shadow:0 4px 22px rgba(20,45,35,.04);
  z-index:100!important;
}
.site-header .brand,.site-header nav>a{color:#173730!important}
.site-header .daily-verse{min-width:0;flex:1 1 170px;max-width:345px}
.site-header nav{gap:clamp(6px,.9vw,15px)!important;flex:0 1 auto}
.site-header nav>a{font-size:clamp(12px,1vw,14px)!important;font-weight:650!important;white-space:nowrap}
.site-header nav>a:hover,.site-header nav>a:focus-visible{
  color:#0e4235!important;
  text-decoration:underline;
  text-underline-offset:5px;
}
.site-header nav>a:focus-visible,.hero .overview-grid a:focus-visible{
  outline:2px solid #886526!important;
  outline-offset:3px;
}
.site-header .menu-button{color:#173730!important}
.site-header .menu-button span{background:#173730!important}

/* The large hero is the homepage, not a second header above every destination. */
.hero{min-height:calc(100svh - 84px)!important}
.hero .overview-grid{
  width:min(840px,100%)!important;
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
}
.hero .overview-grid a{min-height:74px!important}
.hero .overview-grid a strong{font-size:clamp(15px,1.5vw,18px)!important;overflow-wrap:normal!important;word-break:keep-all!important}
body:has(main :target) .hero{display:none!important}

/* Show dated worship material only when requested. This avoids repeating the
   bulletin/PPT panel above every selected section while keeping its full role-gated editor. */
.church-weekly-focus{display:none!important}
.church-weekly-focus:target,.church-weekly-focus:has(:target){display:block!important}
.church-weekly-inner{max-width:var(--church-content-width)}
#weekly-worship,#online,#about,#worship,#community,#partner-news,#location{
  scroll-margin-top:96px;
}

/* Online has exactly two destinations: existing YouTube worship and EKODI Live.
   Daily devotion has one canonical dedicated page, not a duplicate homepage form. */
#online .online-triad--broadcast{
  width:min(var(--church-content-width),100%);
  margin:clamp(20px,3vw,42px) auto 0;
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:18px;
}
#online .online-triad--broadcast .ministry-card{
  min-height:430px;
  border-radius:16px;
}
#online .online-head,#online .giving-strip{max-width:var(--church-content-width);margin-inline:auto}
.church-footer-inner{max-width:var(--church-content-width)!important}

@media(max-width:1100px) and (min-width:801px){
  .site-header{gap:8px!important;padding-inline:16px!important}
  .site-header .daily-verse{font-size:11px!important;flex-basis:90px}
  .site-header nav{gap:6px!important}
  .site-header nav>a{font-size:12px!important}
}
@media(max-width:800px){
  .site-header{padding-inline:18px!important}
  .site-header nav.open{
    top:100%!important;
    left:0!important;
    right:0!important;
    padding:12px 18px 18px!important;
    background:#fbfaf6!important;
    color:#173730!important;
    box-shadow:0 14px 30px rgba(13,39,29,.16);
    gap:3px!important;
    border-bottom:1px solid rgba(23,55,48,.15);
  }
  .site-header nav.open>a{
    display:flex;
    align-items:center;
    min-height:44px;
    padding:9px 12px!important;
    text-align:left!important;
    font-size:16px!important;
    font-weight:700!important;
    color:#173730!important;
  }
  .site-header .menu-button{min-width:44px;min-height:44px;display:grid;place-items:center}
  /* Content-first mobile layout: never vertically center a viewport-height hero.
     A tall mobile viewport must not create blank space above the greeting. */
  .hero{
    display:block!important;
    height:auto!important;
    min-height:0!important;
    padding:clamp(18px,3vw,28px) 18px 32px!important;
  }
  .hero-content{width:min(680px,100%);padding:0!important}
  .hero .eyebrow{margin-top:0}
  .hero .overview-grid{margin-top:24px!important}
  .hero .overview-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  .hero .overview-grid a{min-height:64px!important}
  #online .online-triad--broadcast{grid-template-columns:1fr}
  #online .online-triad--broadcast .ministry-card{min-height:0;padding:25px 20px}
  #online .online-triad--broadcast .media-card{padding-bottom:30px}
  .church-weekly-focus{padding:22px 14px}
}
@media(max-width:420px){
  .site-header{padding-inline:14px!important}
  .hero .overview-grid{gap:8px!important}
  .hero .overview-grid a{padding:12px 7px!important;min-height:60px!important}
  .hero .overview-grid a strong{font-size:16px!important;line-height:1.3}
}
@media(prefers-reduced-motion:reduce){
  .hero .overview-grid a{transition:none!important}
}

/* Church-owned schedule panel; public federation is strictly read-only. */
.church-shared-schedule{max-width:1120px;margin-inline:auto;padding:clamp(22px,3vw,40px) 22px!important;background:transparent}
.church-shared-schedule-head{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.church-shared-schedule-head h2{font-family:'Gowun Batang',serif;font-size:clamp(23px,2.6vw,32px);margin:0;line-height:1.45}
.church-shared-schedule-head>a{color:#245b46;font-size:.85rem;font-weight:750;text-underline-offset:3px}
.church-shared-schedule>p{color:#59695f;font-size:.85rem;line-height:1.6;margin:7px 0 16px}
.church-shared-schedule ol{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
.church-shared-schedule ol>li{min-width:0;border:1px solid #ddd9cd;border-radius:13px;background:#fffdf8;padding:13px 15px;display:grid;align-content:start;gap:5px}
.church-shared-schedule .church-shared-link{font-size:.95rem;line-height:1.5;font-weight:750;color:#173730;overflow-wrap:anywhere}
.church-shared-schedule .church-shared-meta{font-size:.78rem;line-height:1.55;color:#59695f;overflow-wrap:break-word}
.church-shared-schedule ol>.church-shared-empty{grid-column:1/-1;color:#59695f;font-size:.85rem}
@media(max-width:720px){.church-shared-schedule{padding-inline:18px!important}.church-shared-schedule ol{grid-template-columns:minmax(0,1fr)}}
