:root{
  /* Palette (aus Screenshot-Farbbereichen abgeleitet) */
  --header-top: #225180;
  --header-mid: #2e6daa;
  --header-bot: #3d7ebd;

  --nav-bg: #2d557b;
  --nav-bg-2: #244a6e;
  --nav-active: #32608c;

  --page-bg: #f4f4f4;
  --surface: #ffffff;
  --border: #cfcfcf;

  --text: #222222;
  --muted: #666666;
  --heading: #709abf; /* H1/H2 Blau */

  --link: #1a4f8a;
  --link-hover: #0f3f73;

  --shadow: 0 2px 10px rgba(0,0,0,.08);
  --radius: 6px;
  --max: 1200px; /* breiter, aber klassisch */
  --focus: 0 0 0 3px rgba(50,96,140,.28);
}

*{ box-sizing:border-box; }
html,body{ height:100%; }
body{
  margin:0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--page-bg);
  color: var(--text);
  line-height: 1.6;
}

a{ color: var(--link); text-underline-offset: 3px; }
a:hover{ color: var(--link-hover); }
img{ max-width:100%; height:auto; display:block; }

.container{
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 16px;
}

.skip-link{
  position:absolute; left:-9999px; top:10px;
  background: #fff; color:#000;
  padding:.5rem .75rem; z-index: 1000;
  border-radius: 999px;
}
.skip-link:focus{ left:10px; outline:none; box-shadow: var(--focus); }

.header{
  background: linear-gradient(to bottom, var(--header-top) 0%, var(--header-mid) 55%, var(--header-bot) 100%);
  color: #fff;
}
.header-topline{
  padding: 6px 0 0;
  font-size: 13px;
  opacity: .95;
}
.header-main{
  display:flex;
  align-items:center;
  gap: 18px;
  padding: 18px 0 18px;
}
.logo{
  width: 120px;
  height: auto;
}
.site-title{
  font-size: 34px;
  font-weight: 700;
  letter-spacing: .2px;
  margin: 0;
  line-height: 1.1;
}
.site-subtitle{
  margin: 6px 0 0;
  font-size: 14px;
  opacity: .95;
}

.navbar{
  background: linear-gradient(to bottom, var(--nav-bg) 0%, var(--nav-bg-2) 100%);
  border-top: 1px solid rgba(255,255,255,.25);
}
.nav{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
  padding: 0;
  margin: 0;
  list-style: none;
}
.nav a{
  display:inline-block;
  padding: 10px 12px;
  color: #fff;
  text-decoration: none;
  font-size: 14px;
  border-radius: 3px;
}
.nav a:hover{
  background: rgba(255,255,255,.12);
}
.nav a[aria-current="page"]{
  background: linear-gradient(to bottom, var(--nav-active), rgba(255,255,255,.08));
}

.main{
  background: var(--surface);
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.content{
  padding: 18px 16px 26px;
}

h1,h2,h3{
  color: var(--heading);
  margin: 0 0 10px;
  line-height: 1.2;
}
h1{ font-size: 32px; }
h2{ font-size: 22px; margin-top: 18px; }
h3{ font-size: 18px; margin-top: 16px; }

p{ margin: 10px 0; color: #333; }
.muted{ color: var(--muted); }

.float-right{
  float:right;
  margin: 6px 0 12px 18px;
  width: min(320px, 42%);
  border: 1px solid var(--border);
  padding: 4px;
  background: #fff;
}
.clearfix::after{ content:""; display:block; clear:both; }

.card{
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 14px;
  background: #fff;
}

.table-wrap{
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow:auto;
  background:#fff;
}
table{
  width:100%;
  border-collapse: collapse;
  min-width: 520px;
}
th,td{ padding: 9px 10px; text-align:left; }
thead th{
  background: #f3f6f9;
  border-bottom: 1px solid var(--border);
  color:#3b6f9b;
}
tbody tr{ border-bottom: 1px solid #e7e7e7; }
tbody tr:last-child{ border-bottom: 0; }

.term-item{
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 12px;
  background:#fff;
  margin-top: 10px;
}
.term-head{
  display:flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.term-head strong{ color:#2b557c; }
.term-head small{ color: var(--muted); }

.rich img{
  margin-top: 10px;
  border: 1px solid var(--border);
  padding: 4px;
  background:#fff;
  max-height: 420px;
  object-fit: cover;
}

.footer{
  background:#f5f5f5;
  border-top: 1px solid var(--border);
}
.footer .container{
  padding: 12px 16px 18px;
  font-size: 13px;
  color: var(--muted);
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.footer a{ color: var(--muted); text-decoration:none; }
.footer a:hover{ color:#333; text-decoration: underline; }
.footer .links{ display:flex; gap: 12px; flex-wrap: wrap; }

.cookie{
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 14px;
  z-index: 200;
  width: min(900px, calc(100% - 24px));
  display:none;
}
.cookie-inner{
  background:#fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 10px 26px rgba(0,0,0,.12);
  padding: 14px 14px;
  display:flex;
  align-items:flex-start;
  justify-content: space-between;
  gap: 14px;
}
.cookie-actions{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content:flex-end;
}
.cookie button{
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 999px;
  padding: 8px 12px;
  cursor:pointer;
  font-weight: 700;
}
.cookie button.primary{
  background: var(--nav-active);
  border-color: #1f4e73;
  color:#fff;
}
.cookie button:focus{ outline:none; box-shadow: var(--focus); }

.notice{
  margin-top: 12px;
  border: 1px dashed #9db9d5;
  background: #f3f8fd;
  border-radius: var(--radius);
  padding: 10px 12px;
  color:#234d79;
  font-size: 14px;
}

@media (max-width: 760px){
  .header-main{ flex-direction: column; align-items:flex-start; padding: 14px 0 14px; }
  .logo{ width: 110px; }
  .site-title{ font-size: 26px; }
  .float-right{ float:none; width: 100%; margin: 10px 0 12px; }
  .cookie-inner{ flex-direction: column; }
}

@media (prefers-reduced-motion: reduce){
  *{ transition:none !important; animation:none !important; }
}

/* Responsive nav toggle */
.nav-toggle{
  display:none;
  border: 1px solid rgba(255,255,255,.45);
  background: rgba(255,255,255,.12);
  color:#fff;
  padding: 8px 10px;
  border-radius: 4px;
  cursor:pointer;
  font-weight: 700;
}
.nav-toggle:focus{ outline:none; box-shadow: var(--focus); }

h4{
  color: var(--heading);
  margin: 14px 0 8px;
  font-size: 16px;
}

@media (max-width: 760px){
  .navbar .container{
    display:flex;
    align-items:center;
    justify-content: space-between;
    gap: 10px;
    padding-top: 6px;
    padding-bottom: 6px;
  }
  .nav-toggle{ display:inline-block; }
  .nav{
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin-top: 6px;
    display:none;
  }
  .nav[data-open="true"]{ display:flex; }
  .nav li{ width:100%; }
  .nav a{
    border-radius: 0;
    padding: 11px 12px;
  }
}

/* Predigtplan month grouping */
.table-wrap.no-frame{
  border: none;
  border-radius: 0;
  background: transparent;
}

/* On the Gottesdienste page: let the predigtplan table fit mobile screens better */
#predigtplaene table{ min-width: 0; }
#predigtplaene th:first-child,
#predigtplaene td:first-child{ width: 140px; white-space: nowrap; }

.month-block{
  background: #f3f6f9;
  border-left: 4px solid #3b6f9b;
  padding: 10px 12px;
  margin: 12px 0;
  border-radius: 6px;
}
.month-title{
  font-weight: 800;
  color: #2c5e86;
  margin-bottom: 8px;
  letter-spacing: .2px;
}
.month-block table{
  background: #fff;
}

/* Predigtplan month separators (Gottesdienste) */
#predigtplaene .table-wrap{
  border: none;
  border-radius: 0;
  background: transparent;
}


/* Predigtplan month separators */

/* Predigtplan month separators (Gottesdienste) - high visibility */
#predigtplaene .month-row td{
  background: #d8e7f6;          /* clearly different from white rows */
  color: #1f4f77;
  font-weight: 800;
  border-top: 2px solid #a9c4de;
  border-bottom: 2px solid #a9c4de;
  padding-top: 10px;
  padding-bottom: 10px;
}
#predigtplaene .month-row td::before{
  content: "▸ ";
  color: #2c5e86;
}
