/* kazeem agboola - yoruba batik art: responsives Layout */

:root {
  --ink: #4a4d51;
  --muted: #6b6f73;
  --link: #4f7278;
  --link-hover: #2f4a4f;
  --accent: #f39200;
  --line: #c5d1d1;
  --paper: #ffffff;
  --bg: #eef2f2;
  --maxw: 860px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: Verdana, "DejaVu Sans", Geneva, sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
}

img { max-width: 100%; height: auto; }

a { color: var(--link); text-decoration: none; }
a:hover, a:focus-visible { color: var(--link-hover); text-decoration: underline; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.noscript { margin: 0; padding: .75rem 1rem; text-align: center; background: #fff8e6; }

/* ---------- Kopfbereich ---------- */

.site-header {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 12px 16px 0;
  position: relative;
}
.brand { display: block; line-height: 0; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; background: var(--paper); }
.brand img { width: 100%; }

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0 clamp(.75rem, 2.4vw, 1.75rem);
}
.site-nav a {
  display: block;
  padding: .85rem .1rem .6rem;
  color: var(--muted);
  letter-spacing: .14em;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover, .site-nav a:focus-visible { color: var(--ink); text-decoration: none; border-bottom-color: var(--line); }
.site-nav a.active { color: var(--ink); font-weight: bold; border-bottom-color: var(--accent); }

.nav-toggle { display: none; }

/* ---------- Inhalt ---------- */

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

.content {
  background: rgba(255, 255, 255, .94);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: clamp(1rem, 4vw, 2.25rem);
  overflow-wrap: break-word;
}
.content::after { content: ""; display: block; clear: both; }

/* Ueberschriften aus den alten Texten (<b>intro</b> am Anfang) */
.content > b:first-child,
.ueberschrift {
  display: block;
  font-size: 1.35rem;
  font-weight: normal;
  letter-spacing: .12em;
  color: var(--ink);
  margin-bottom: .25rem;
}
.ueberschrift { text-align: center; }

.content p { margin: 0 0 1em; }
.content img { max-width: 100%; height: auto; }

/* Bild im Portrait: rechts umflossen, mobil zentriert */
.content a[style*="float:right"] { margin: 0 0 1rem 1.25rem; }
.content a[style*="float:right"] img { border: 1px solid var(--line); border-radius: 3px; }

/* ---------- Altlast-Tabellen flexibel machen ---------- */

.content table {
  width: 100% !important;
  max-width: 100%;
  height: auto !important;
  table-layout: auto !important;
  border-collapse: collapse;
}
.content td { width: auto !important; height: auto !important; vertical-align: top; }
.content td, .content th { font-size: inherit; line-height: inherit; color: inherit; }
.content font { font-size: inherit; }

/* Formulare (Kontakt, Bestellung, Kaufen) */
.content input[type="text"],
.content input[type="email"],
.content input[type="tel"],
.content input.var300,
.content textarea,
.content select {
  width: 100% !important;
  max-width: 100%;
  min-height: 2.5rem;
  padding: .45rem .6rem;
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 1px solid #a9b4b4;
  border-radius: 4px;
}
.content input[name="valcode"] { width: 7em !important; display: inline-block; }
.content textarea { min-height: 8rem; }
.content input:focus, .content textarea:focus, .content select:focus { background: #fffbea; border-color: var(--accent); }
.content input[type="submit"], .content input[type="button"], .content button, .log_button {
  font: inherit;
  padding: .55rem 1.4rem;
  color: #fff;
  background: var(--link);
  border: 0;
  border-radius: 4px;
  cursor: pointer;
}
.content input[type="submit"]:hover, .content input[type="button"]:hover, .content button:hover { background: var(--link-hover); }
.content input[type="checkbox"], .content input[type="radio"] { width: auto !important; min-height: 0; margin-right: .4rem; }

/* Suchfeld der Chronik */
.content form[action="ausstellung.php"] { display: flex !important; flex-wrap: wrap; gap: .5rem; align-items: center; margin-bottom: 1.25rem; }
.content form[action="ausstellung.php"] input[type="text"] { width: auto !important; flex: 1 1 12rem; }

/* ---------- Galerie ---------- */

/* alte Rundungs-Elemente ausblenden, Karten neu gestalten */
b.o21, b.o22, b.o23, b.o24, b.u21, b.u22, b.u23, b.u24 { display: none; }
.content div[style*="width:450px"] { width: 100% !important; margin: 0 0 1.5rem !important; }
.content .content2 {
  display: block;
  padding: 1rem 1.1rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 6px;
}
.content .content2 table { border-collapse: separate; }
.content .content2 td { padding: .25rem .2rem; }
.content .content2 img { border: 1px solid var(--line); border-radius: 3px; }
.content img[style*="float:right"] { max-width: min(220px, 45%) !important; float: right; margin: .15rem 0 .75rem 1rem; }
.content .content2 td img:not([style*="float:right"]) { max-width: 100% !important; }
.content .spalte { font-size: inherit; }
.content .spalte b { font-weight: bold; }
/* Kaufen-Link als Button */
.content .content2 td[style*="text-align: right"] a {
  display: inline-block;
  padding: .3rem 1rem;
  color: #fff;
  background: var(--link);
  border-radius: 4px;
}
.content .content2 td[style*="text-align: right"] a:hover { background: var(--link-hover); text-decoration: none; }

/* ---------- Fuss ---------- */

.site-footer { max-width: var(--maxw); margin: 0 auto; padding: 1.25rem 16px 2rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: .25rem 1.25rem; font-size: .8rem; }
.site-footer a { color: var(--muted); }
.stat { position: absolute; left: -9999px; }

/* ---------- Cookie-Hinweis ---------- */

.cookie-note {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 50;
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: center;
  padding: .75rem 1rem;
  font-size: .85rem;
  line-height: 1.45;
  color: #404040;
  background: #efefef;
  border-top: 1px solid #d4d4d4;
}
.cookie-note[hidden] { display: none; }
.cookie-note p { margin: 0; }
.cookie-note button { flex: none; min-width: 5rem; padding: .5rem 1.2rem; font: inherit; color: #fff; background: #000; border: 0; cursor: pointer; }

/* ---------- Startseite: Grafik in der Inhaltskarte ---------- */

.start { text-align: center; }
.start img { display: block; margin: 0 auto; width: min(100%, 420px); height: auto; mix-blend-mode: multiply; }

/* ---------- Tablet / Handy ---------- */

@media (max-width: 720px) {
  body { font-size: 1.0625rem; }

  .site-header { padding-top: 8px; }

  /* Menue einklappen (nur mit Javascript, sonst bleibt es offen sichtbar) */
  .js .nav-toggle {
    display: flex;
    align-items: center;
    gap: .6rem;
    width: 100%;
    margin-top: .5rem;
    padding: .7rem 1rem;
    font: inherit;
    letter-spacing: .14em;
    color: var(--ink);
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 6px;
    cursor: pointer;
  }
  .nav-toggle-bar { display: none; }
  .js .nav-toggle-bar { display: block; width: 1.25rem; height: 2px; background: currentColor; box-shadow: 0 6px 0 currentColor, 0 -6px 0 currentColor; }
  .js .nav-toggle-bar + .nav-toggle-bar, .js .nav-toggle-bar + .nav-toggle-bar + .nav-toggle-bar { display: none; }
  .nav-toggle-label { margin-left: auto; }

  .js .site-nav { display: none; }
  .js .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; margin-top: .5rem; background: var(--paper); border: 1px solid var(--line); border-radius: 6px; }
  .site-nav li + li { border-top: 1px solid var(--line); }
  .site-nav a { padding: .85rem 1rem; border-bottom: 0; border-left: 3px solid transparent; }
  .site-nav a.active { border-left-color: var(--accent); }

  .page { padding: 0 10px; margin-top: 10px; }
  .site-header { padding-left: 10px; padding-right: 10px; }

  .content a[style*="float:right"] { float: none !important; display: block; margin: 0 auto 1rem; text-align: center; }

  /* Formulare untereinander */
  .content form td { display: block; width: 100% !important; text-align: left; }
  .content form tr { display: block; margin-bottom: .6rem; }

  /* Galeriekarten: Preis / Kaufen untereinander nicht noetig, Bilder nebeneinander bleiben */
  .content .content2 { padding: .75rem; }

}

@media (max-width: 480px) {
  .cookie-note { gap: .6rem; padding: .6rem .75rem; font-size: .78rem; }
  .cookie-note button { min-width: 3.5rem; padding: .45rem .8rem; }
}

@media (prefers-reduced-motion: no-preference) {
  .site-nav a { transition: color .15s, border-color .15s; }
}

@media print {
  .site-nav, .nav-toggle, .cookie-note, .site-footer, .stat { display: none !important; }
  body { background: #fff; }
  .content { border: 0; padding: 0; }
}

/* =====================================================================
   CMS-Markup (Textseiten, Chronik, Galerie, Formulare)
   ===================================================================== */

.page-title {
  margin: 0 0 1rem;
  font-size: 1.35rem;
  font-weight: normal;
  letter-spacing: .12em;
  color: var(--ink);
}
.text { line-height: 1.75; }
.text a { text-decoration: underline; }
.address { margin-bottom: 1.5rem; }
.form-title { margin: 1.5rem 0 .5rem; font-size: 1.05rem; font-weight: normal; letter-spacing: .06em; }
.notice { padding: .7rem 1rem; margin: 1rem 0; background: #fff8e6; border: 1px solid #f0d9a0; border-radius: 6px; }
.notice.ok { background: #eaf6ee; border-color: #b9dcc6; }

/* Chronik */
.news-search { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin: 0 0 1.25rem; }
.news-search label { flex: 0 0 auto; font-size: .85rem; color: var(--muted); }
.news-search input[type="search"] { flex: 1 1 12rem; min-height: 2.5rem; padding: .45rem .6rem; font: inherit; border: 1px solid #a9b4b4; border-radius: 4px; background: #fff; }
.news-search button, .shop-form button, .contact-form button, .btn {
  font: inherit; padding: .55rem 1.3rem; color: #fff; background: var(--link); border: 0; border-radius: 4px; cursor: pointer; text-decoration: none; display: inline-block;
}
.btn { color: #fff; }
.btn:hover, .news-search button:hover, .shop-form button:hover, .contact-form button:hover { background: var(--link-hover); text-decoration: none; }
.pager { display: flex; flex-wrap: wrap; gap: .3rem; margin: 0 0 1.25rem; font-size: .9rem; }
.pager a, .pager .current { min-width: 2.2rem; padding: .3rem .6rem; text-align: center; border: 1px solid var(--line); border-radius: 4px; background: #fff; }
.pager a:hover { border-color: var(--accent); text-decoration: none; }
.pager .current { color: #fff; background: var(--link); border-color: var(--link); }
.pager .gap { padding: .3rem .2rem; color: var(--muted); }
.entry { margin: 0 0 1.75rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--line); }
.entry:last-child { border-bottom: 0; }
.entry-dates { margin: 0; font-size: 1rem; font-weight: bold; }
.entry-title { margin: .1rem 0 .4rem; font-size: 1rem; font-weight: bold; }
.entry-body::after { content: ""; display: block; clear: both; }
.entry-body img { border: 1px solid var(--line); border-radius: 3px; margin: .35rem .35rem .35rem 0; }

/* Galerie */
.works { display: grid; gap: 1.5rem; }
.work { padding: 1rem 1.1rem; background: var(--paper); border: 1px solid var(--line); border-radius: 6px; }
.work h2 { margin: 0 0 .75rem; font-size: 1rem; text-align: center; }
.work-imgs { display: flex; flex-wrap: wrap; gap: .75rem; justify-content: center; margin-bottom: .75rem; }
.work-imgs a { display: block; line-height: 0; }
.work-imgs img { display: block; width: auto; height: auto; max-width: 100%; max-height: 320px; border: 1px solid var(--line); border-radius: 3px; }
.work-imgs.two a { flex: 1 1 40%; text-align: center; }
.work-imgs.two img { margin: 0 auto; }
.work-text::after { content: ""; display: block; clear: both; }
.work-buy { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; justify-content: space-between; margin-top: .75rem; padding-top: .75rem; border-top: 1px solid var(--line); }
.work-buy .price { font-weight: bold; }
.work-buy .sold { font-weight: bold; color: #b3261e; }
.work-buy .buy { padding: .35rem 1.1rem; color: #fff; background: var(--link); border-radius: 4px; }
.work-buy .buy:hover { background: var(--link-hover); text-decoration: none; }

/* Kaufen / Bestellung */
.buy-item { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 1.25rem; align-items: flex-start; }
.buy-item img { display: block; max-width: 220px; max-height: 260px; border: 1px solid var(--line); border-radius: 3px; }
.buy-item h2 { margin: 0 0 .4rem; font-size: 1.05rem; }
.buy-item > div { flex: 1 1 14rem; }
.sum { display: grid; grid-template-columns: max-content 1fr; gap: .5rem 1.25rem; margin: 0 0 1rem; align-items: center; }
.sum dt { margin: 0; color: var(--muted); }
.sum dd { margin: 0; }
.sum select, .shop-form select { width: 100%; max-width: 22rem; min-height: 2.5rem; padding: .4rem .5rem; font: inherit; color: var(--ink); background: #fff; border: 1px solid #a9b4b4; border-radius: 4px; }
.form-actions { margin: 1rem 0 0; }
.inline-form { display: inline; margin: 0; }
.content button.linklike { padding: 0; color: var(--link); background: none; border: 0; border-radius: 0; text-decoration: underline; }
.content button.linklike:hover { background: none; color: var(--link-hover); }

/* Kontakt-/Bestellformular */
.contact-form { max-width: 34rem; }
.frow { margin: 0 0 1rem; }
.frow label { display: block; margin: 0 0 .25rem; font-size: .95rem; }
.frow label.check { display: flex; gap: .5rem; align-items: center; }
.frow .req { color: #b3261e; }
.content .frow input.short { width: 6em !important; }
.frow.has-error input, .frow.has-error textarea { border-color: #b3261e; }
.ferror { margin: .3rem 0 0; font-size: .85rem; color: #b3261e; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

@media (max-width: 720px) {
  .sum { grid-template-columns: 1fr; gap: .15rem; }
  .sum dd { margin-bottom: .6rem; }
  .work { padding: .75rem; }
  .work-imgs.two a { flex-basis: 45%; }
  .buy-item img { max-width: 100%; }
  .contact-form { max-width: none; }
}

/* E-Mail-Adresse als Bild (siehe inc/mailprotect.php): so gross wie der umgebende Text */
.text img.mailimg, .content img.mailimg, img.mailimg { height: 1.25em; width: auto; max-width: none; vertical-align: -0.229em; border: 0; }
