/*
Theme Name:  Kapelle mit Kultur
Theme URI:   https://www.kapelle-mit-kultur.de
Description: Modernes, minimalistisches Theme für Kapelle mit Kultur Osthelden e.V. — Editorial-Stil, warm und einladend.
Author:      Kapelle mit Kultur Osthelden e.V.
Version:     1.0.0
License:     GNU General Public License v2 or later
Text Domain: kapelle
*/

/* ── Reset ──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }

/* ── Design Tokens ──────────────────────────────────── */
:root {
  --cream:    #F6F3ED;
  --cream2:   #EDE9E1;
  --white:    #FDFCFA;
  --ink:      #1A1714;
  --ink2:     #3D3830;
  --ink3:     #7A736A;
  --terra:    #B85934;
  --terra-l:  #D4896A;
  --terra-bg: #F5E9E3;
  --gold:     #C4963A;
  --border:   #DDD9D2;
  --nav-h:    64px;
  --shadow:   0 2px 20px rgba(26,23,20,.07);
  --shadow-l: 0 8px 48px rgba(26,23,20,.12);
  --r:        10px;
  --fd: 'Playfair Display', Georgia, serif;
  --fb: 'Outfit', -apple-system, sans-serif;
}

/* ── Base ───────────────────────────────────────────── */
body {
  font-family: var(--fb);
  background: var(--cream);
  color: var(--ink);
  line-height: 1.65;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ── Typography ─────────────────────────────────────── */
h1, h2, h3, h4, h5 {
  font-family: var(--fd);
  line-height: 1.1;
  color: var(--ink);
}
h1 { font-size: clamp(2.4rem, 5.5vw, 4.4rem); font-weight: 700; }
h2 { font-size: clamp(1.8rem, 3.8vw, 3rem);   font-weight: 700; }
h3 { font-size: clamp(1.2rem, 2.2vw, 1.6rem); font-weight: 500; }
h4 { font-size: 1.15rem; font-weight: 600; }
p  { color: var(--ink2); font-weight: 300; line-height: 1.82; margin-bottom: 1.1em; }
p:last-child { margin-bottom: 0; }
strong { font-weight: 600; color: var(--ink); }
em { font-style: italic; }

/* ── Utility ─────────────────────────────────────────── */
.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 5%;
}
.section { padding: 88px 0; }
.section-head { margin-bottom: 52px; }
.section-head .tag { display: block; margin-bottom: 10px; }
.section-head p { max-width: 560px; font-size: 1.05rem; margin-top: 12px; }

.tag {
  font-size: .72rem; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--terra);
  display: inline-flex; align-items: center; gap: 8px;
}
.tag::before {
  content: ''; width: 22px; height: 1.5px;
  background: currentColor; display: block; flex-shrink: 0;
}

.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 26px; border-radius: 50px;
  font-family: var(--fb); font-size: .88rem; font-weight: 500;
  cursor: pointer; transition: all .22s; border: none;
  text-decoration: none;
}
.btn-primary { background: var(--terra); color: white; }
.btn-primary:hover { background: var(--ink); transform: translateY(-2px); box-shadow: 0 6px 24px rgba(184,89,52,.3); }
.btn-outline { background: transparent; color: var(--terra); border: 1.5px solid var(--terra); }
.btn-outline:hover { background: var(--terra); color: white; transform: translateY(-2px); }

/* ── Fade-in ─────────────────────────────────────────── */
.fi {
  opacity: 0; transform: translateY(26px);
  transition: opacity .75s ease, transform .75s ease;
}
.fi.in { opacity: 1; transform: none; }

/* ── NAV ─────────────────────────────────────────────── */
.site-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: var(--nav-h);
  background: rgba(246,243,237,.92);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, box-shadow .3s;
}
.site-nav.scrolled {
  border-bottom-color: var(--border);
  box-shadow: 0 2px 20px rgba(26,23,20,.06);
}
.site-nav .nav-inner {
  height: 100%; display: flex; align-items: center;
  justify-content: space-between;
}
.site-nav .nav-brand {
  display: flex; align-items: center; gap: 11px;
  font-family: var(--fd); font-size: 1.1rem; font-weight: 700; color: var(--ink);
}
.site-nav .nav-brand svg { flex-shrink: 0; }
.site-nav .nav-brand .sub {
  display: block; font-family: var(--fb); font-size: .68rem;
  font-weight: 300; color: var(--ink3); margin-top: -2px; letter-spacing: .03em;
}
.nav-menu {
  display: flex; align-items: center; gap: 22px;
}
.nav-menu a {
  font-size: .72rem; font-weight: 400; color: var(--ink3);
  text-transform: uppercase; letter-spacing: .05em;
  transition: color .2s; position: relative;
  white-space: nowrap;
}
.nav-menu a::after {
  content: ''; position: absolute; bottom: -3px; left: 0; right: 0;
  height: 1px; background: var(--terra);
  transform: scaleX(0); transition: transform .2s; transform-origin: left;
}
.nav-menu a:hover { color: var(--ink); }
.nav-menu a:hover::after { transform: scaleX(1); }
.nav-menu a.current-menu-item { color: var(--terra); }
.nav-menu a.current-menu-item::after { transform: scaleX(1); }

.nav-toggle {
  display: none; background: none; border: none;
  cursor: pointer; padding: 4px;
}
@media (max-width: 860px) {
  .nav-menu {
    display: none; flex-direction: column; align-items: flex-start; gap: 0;
    position: absolute; top: var(--nav-h); left: 0; right: 0;
    background: var(--white); padding: 10px 5% 18px;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 8px 24px rgba(26,23,20,.08);
  }
  .nav-menu.open { display: flex; }
  .nav-menu a { display: block; width: 100%; padding: 11px 0; border-bottom: 1px solid var(--border); font-size: .85rem; }
  .nav-menu li:last-child a { border-bottom: none; }
  .nav-toggle { display: flex; }
}

/* ── HERO (front page) ───────────────────────────────── */
.hero {
  min-height: 100vh; padding-top: var(--nav-h);
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 60px; align-items: center;
  position: relative; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 60% 70% at 85% 35%, rgba(184,89,52,.09) 0%, transparent 65%),
    radial-gradient(ellipse 40% 50% at 5%  80%, rgba(196,150,58,.06) 0%, transparent 60%);
}
.hero-text { padding: 60px 0 60px 5%; }
.hero-text h1 { margin: 18px 0 22px; }
.hero-text h1 em { font-style: italic; color: var(--terra); }
.hero-text .lead { font-size: 1.08rem; max-width: 480px; margin-bottom: 38px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-visual {
  display: flex; align-items: center; justify-content: center;
  padding-right: 5%;
}
.hero-visual svg { width: min(420px, 100%); height: auto; }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; min-height: auto; gap: 0; }
  .hero-visual { order: -1; padding: 60px 5% 0; }
  .hero-visual svg { width: min(220px, 50vw); margin: 0 auto; }
  .hero-text { padding: 32px 5% 60px; text-align: center; }
  .hero-text .lead { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
}

/* ── LATEST POSTS (home) ─────────────────────────────── */
.home-posts { background: var(--white); }
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}
.post-card {
  background: var(--cream); border: 1px solid var(--border);
  border-radius: var(--r); overflow: hidden;
  transition: transform .3s, box-shadow .3s;
  display: flex; flex-direction: column;
}
.post-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-l); }
.post-card .card-img {
  height: 200px; overflow: hidden; background: var(--cream2);
}
.post-card .card-img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s ease;
}
.post-card:hover .card-img img { transform: scale(1.04); }
.post-card .card-body {
  padding: 26px 28px 28px;
  flex: 1; display: flex; flex-direction: column;
  border-top: 3px solid var(--terra);
}
.post-card .card-meta {
  font-size: .75rem; color: var(--ink3); margin-bottom: 10px;
}
.post-card h3 { font-size: 1.2rem; margin-bottom: 12px; }
.post-card h3 a { transition: color .2s; }
.post-card h3 a:hover { color: var(--terra); }
.post-card p { font-size: .9rem; flex: 1; }
.post-card .read-more {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 18px; font-size: .82rem; font-weight: 500;
  color: var(--terra); transition: gap .2s;
}
.post-card .read-more:hover { gap: 10px; }
.no-posts { color: var(--ink3); font-size: 1rem; padding: 40px 0; }

/* ── SINGLE POST / PAGE ──────────────────────────────── */
.site-main { padding-top: var(--nav-h); }
.page-hero {
  background: var(--ink); padding: 72px 0 56px;
  position: relative; overflow: hidden;
}
.page-hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 60% 80% at 80% 50%, rgba(184,89,52,.15) 0%, transparent 65%);
}
.page-hero .tag { color: var(--terra-l); }
.page-hero .tag::before { background: var(--terra-l); }
.page-hero h1 { color: white; margin-top: 14px; max-width: 720px; }
.page-hero .page-meta { color: rgba(255,255,255,.45); font-size: .85rem; margin-top: 16px; }

/* post thumbnail in hero */
.post-thumb-hero {
  width: 100%; max-height: 480px; overflow: hidden;
}
.post-thumb-hero img {
  width: 100%; height: 480px; object-fit: cover;
}

.content-wrap {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 64px; align-items: start;
  padding: 64px 0 96px;
}
@media (max-width: 900px) {
  .content-wrap { grid-template-columns: 1fr; gap: 48px; }
}

/* ── Entry content ───────────────────────────────────── */
.entry-content h2,
.entry-content h3,
.entry-content h4 { margin: 1.8em 0 .7em; }
.entry-content p { margin-bottom: 1.3em; }
.entry-content ul, .entry-content ol {
  margin: 1em 0 1.3em 1.5em;
  color: var(--ink2); font-weight: 300; line-height: 1.8;
}
.entry-content ul { list-style: disc; }
.entry-content ol { list-style: decimal; }
.entry-content li { margin-bottom: .4em; }
.entry-content blockquote {
  border-left: 3px solid var(--terra);
  margin: 1.8em 0; padding: 16px 24px;
  background: var(--terra-bg); border-radius: 0 var(--r) var(--r) 0;
  font-family: var(--fd); font-size: 1.15rem; font-style: italic; color: var(--ink);
}
.entry-content blockquote p { color: var(--ink); margin: 0; }
.entry-content img {
  border-radius: var(--r); margin: 1.5em 0;
  box-shadow: var(--shadow);
}
.entry-content a { color: var(--terra); border-bottom: 1px solid var(--terra-bg); transition: border-color .2s; }
.entry-content a:hover { border-color: var(--terra); }
.entry-content hr { border: none; border-top: 1px solid var(--border); margin: 2em 0; }
.entry-content .wp-block-gallery { margin: 1.5em 0; }
.entry-content figure figcaption { font-size: .82rem; color: var(--ink3); text-align: center; margin-top: 8px; }

/* ── Sidebar ─────────────────────────────────────────── */
.sidebar { position: sticky; top: calc(var(--nav-h) + 28px); }
.widget {
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--r); padding: 28px; margin-bottom: 20px;
}
.widget-title {
  font-family: var(--fd); font-size: 1.05rem; font-weight: 700;
  color: var(--ink); margin-bottom: 18px; padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.widget ul { list-style: none; }
.widget ul li {
  padding: 9px 0; border-bottom: 1px solid var(--border);
  font-size: .88rem; color: var(--ink2);
}
.widget ul li:last-child { border-bottom: none; padding-bottom: 0; }
.widget ul li a { transition: color .2s; }
.widget ul li a:hover { color: var(--terra); }
.widget_recent_entries .post-date { display: block; font-size: .75rem; color: var(--ink3); margin-top: 3px; }

/* ── ARCHIVE / BLOG ──────────────────────────────────── */
.archive-wrap { padding: 64px 0 96px; }
.archive-list { display: flex; flex-direction: column; gap: 20px; max-width: 780px; }
.archive-item {
  display: grid; grid-template-columns: 100px 1fr;
  gap: 24px; align-items: start;
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--r); padding: 24px 28px;
  transition: border-color .25s, box-shadow .25s;
}
.archive-item:hover { border-color: var(--terra-l); box-shadow: var(--shadow); }
.archive-item .ai-date {
  font-family: var(--fd); text-align: center;
}
.archive-item .ai-day { font-size: 2rem; font-weight: 700; color: var(--terra); line-height: 1; }
.archive-item .ai-month { font-size: .72rem; color: var(--ink3); text-transform: uppercase; letter-spacing: .08em; font-weight: 500; }
.archive-item h3 { font-size: 1.15rem; margin-bottom: 8px; }
.archive-item h3 a:hover { color: var(--terra); }
.archive-item p { font-size: .9rem; margin: 0; }

@media (max-width: 600px) {
  .archive-item { grid-template-columns: 1fr; gap: 10px; }
  .archive-item .ai-date { display: flex; gap: 8px; align-items: baseline; }
  .archive-item .ai-day { font-size: 1.4rem; }
}

/* ── Pagination ──────────────────────────────────────── */
.pagination {
  display: flex; gap: 8px; justify-content: center;
  margin-top: 52px; flex-wrap: wrap;
}
.pagination a, .pagination span {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; border-radius: 50%;
  font-size: .88rem; font-weight: 500;
  border: 1.5px solid var(--border);
  background: var(--white); color: var(--ink2);
  transition: all .2s;
}
.pagination a:hover { border-color: var(--terra); color: var(--terra); }
.pagination .current { background: var(--terra); color: white; border-color: var(--terra); }

/* ── FOOTER ──────────────────────────────────────────── */
.site-footer { background: var(--ink); }
.footer-main {
  padding: 56px 0 44px;
  display: grid; grid-template-columns: 1.4fr 1fr 1fr;
  gap: 48px;
}
.footer-brand-col .fb-logo {
  font-family: var(--fd); font-size: 1.35rem;
  color: rgba(255,255,255,.75); margin-bottom: 14px;
}
.footer-brand-col p {
  font-size: .85rem; color: rgba(255,255,255,.38); line-height: 1.75;
  margin: 0;
}
.footer-col h4 {
  font-family: var(--fb); font-size: .72rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: .1em;
  color: rgba(255,255,255,.32); margin-bottom: 16px;
}
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul li a {
  font-size: .85rem; color: rgba(255,255,255,.45);
  transition: color .2s;
}
.footer-col ul li a:hover { color: rgba(255,255,255,.85); }
.footer-col address {
  font-style: normal; font-size: .85rem;
  color: rgba(255,255,255,.4); line-height: 1.8;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.07);
  padding: 20px 0;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
}
.footer-bottom p {
  font-size: .75rem; color: rgba(255,255,255,.22); margin: 0;
}
.footer-bottom a { color: rgba(255,255,255,.35); transition: color .2s; font-size: .75rem; }
.footer-bottom a:hover { color: rgba(255,255,255,.7); }

@media (max-width: 720px) {
  .footer-main { grid-template-columns: 1fr; gap: 32px; }
}

/* ── EVENTS (Veranstaltungen) ────────────────────────── */
.events-list { display: flex; flex-direction: column; gap: 14px; max-width: 760px; }
.event-item {
  display: grid; grid-template-columns: 80px 1fr;
  gap: 20px; align-items: start;
  background: var(--white); border: 1px solid var(--border);
  border-radius: var(--r); padding: 20px 24px;
  transition: border-color .2s, box-shadow .2s;
}
.event-item:hover { border-color: var(--terra-l); box-shadow: var(--shadow); }
.ev-date { text-align: center; }
.ev-day   { font-family: var(--fd); font-size: 1.9rem; font-weight: 700; color: var(--terra); line-height: 1; }
.ev-month { font-size: .7rem; color: var(--ink3); text-transform: uppercase; letter-spacing: .08em; font-weight: 500; }
.ev-body strong { display: block; font-family: var(--fd); font-size: 1.05rem; margin-bottom: 4px; }
.ev-body .ev-meta { font-size: .83rem; color: var(--ink3); }
.ev-loc {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: .74rem; font-weight: 500; color: var(--terra);
  background: var(--terra-bg); padding: 3px 10px; border-radius: 50px; margin-top: 7px;
}
.ev-group-label {
  font-size: .74rem; font-weight: 600; color: var(--ink3);
  text-transform: uppercase; letter-spacing: .1em;
  padding: 14px 0 4px;
}

/* ── Gutenberg alignment ─────────────────────────────── */
.alignwide  { margin-left: -5%; margin-right: -5%; }
.alignfull  { margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); width: 100vw; }
.aligncenter{ text-align: center; }
.alignright { float: right; margin: 0 0 1em 1.5em; }
.alignleft  { float: left;  margin: 0 1.5em 1em 0; }

/* ── Responsive misc ─────────────────────────────────── */
@media (max-width: 600px) {
  .section { padding: 60px 0; }
  .content-wrap { padding: 40px 0 64px; }
}

/* ── No-posts hint ───────────────────────────────────── */
.no-posts-hint {
  text-align: center; padding: 64px 20px;
  max-width: 480px; margin: 0 auto;
}
.no-posts-hint .nph-icon { font-size: 3rem; margin-bottom: 18px; }
.no-posts-hint h3 { font-size: 1.5rem; margin-bottom: 12px; }
.no-posts-hint p { font-size: .95rem; color: var(--ink3); }

/* ── Kontakt church grid ─────────────────────────────── */
.kontakt-church-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 24px;
}
.church-block { font-size: .88rem; color: var(--ink2); line-height: 1.85; }
.church-block strong { display: block; color: var(--ink); font-weight: 600; margin-bottom: 4px; }
.church-block a { color: var(--terra); }
@media (max-width: 600px) { .kontakt-church-grid { grid-template-columns: 1fr; } }
