/*
Theme Name: Musikalisches Quartett – Presswerk
Theme URI: https://www.musikalisches-quartett.de
Author: Andreas
Description: Presswerk-Redesign für das Musikalische Quartett – helle, sachliche Optik mit großen Cover-Flächen. Testversion zur Überprüfung von Layout und Funktion.
Version: 0.4.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: mqp
*/

/* ---------- Schriften: lokal statt über fonts.googleapis.com ----------
   Dateien liegen im Theme-Ordner unter /fonts/<schrift>/. Falls dein
   Theme-Verzeichnis anders heißt oder die Dateien woanders liegen, die
   Pfade in den url()-Angaben unten entsprechend anpassen. */
@font-face{
  font-family:'Space Grotesk';
  src:url('fonts/space-grotesk/space-grotesk-400.woff2') format('woff2');
  font-weight:400; font-style:normal; font-display:swap;
}
@font-face{
  font-family:'Space Grotesk';
  src:url('fonts/space-grotesk/space-grotesk-500.woff2') format('woff2');
  font-weight:500; font-style:normal; font-display:swap;
}
@font-face{
  font-family:'Space Grotesk';
  src:url('fonts/space-grotesk/space-grotesk-700.woff2') format('woff2');
  font-weight:700; font-style:normal; font-display:swap;
}
@font-face{
  font-family:'IBM Plex Sans';
  src:url('fonts/ibm-plex-sans/ibm-plex-sans-400.woff2') format('woff2');
  font-weight:400; font-style:normal; font-display:swap;
}
@font-face{
  font-family:'IBM Plex Sans';
  src:url('fonts/ibm-plex-sans/ibm-plex-sans-500.woff2') format('woff2');
  font-weight:500; font-style:normal; font-display:swap;
}
@font-face{
  font-family:'IBM Plex Sans';
  src:url('fonts/ibm-plex-sans/ibm-plex-sans-600.woff2') format('woff2');
  font-weight:600; font-style:normal; font-display:swap;
}
@font-face{
  font-family:'IBM Plex Mono';
  src:url('fonts/ibm-plex-mono/ibm-plex-mono-400.woff2') format('woff2');
  font-weight:400; font-style:normal; font-display:swap;
}
@font-face{
  font-family:'IBM Plex Mono';
  src:url('fonts/ibm-plex-mono/ibm-plex-mono-500.woff2') format('woff2');
  font-weight:500; font-style:normal; font-display:swap;
}

:root{
  --bg:#171613; --ink:#f2efe6; --sub:#a39c8d; --line:#332f28; --accent:#e2735f; --panel:#1f1e1a;
}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]){
    --bg:#171613; --ink:#f2efe6; --sub:#a39c8d; --line:#332f28; --accent:#e2735f; --panel:#1f1e1a;
  }
}
:root[data-theme="dark"]{
  --bg:#171613; --ink:#f2efe6; --sub:#a39c8d; --line:#332f28; --accent:#e2735f; --panel:#1f1e1a;
}

*{box-sizing:border-box;}
html,body{margin:0;padding:0;}
body{
  background:var(--bg); color:var(--ink);
  font-family:'IBM Plex Sans', sans-serif;
  -webkit-font-smoothing:antialiased;
}
a{ color:inherit; }
img{ max-width:100%; display:block; }
.wrap{ max-width:960px; margin:0 auto; padding:0 1.25rem; }
.mono{ font-family:'IBM Plex Mono', monospace; }
.screen-reader-text{ position:absolute; left:-9999px; }

/* ---------- HEADER ---------- */
header.site-header{ border-bottom:1px solid var(--line); position:sticky; top:0; background:var(--bg); z-index:10; }
.header-inner{ display:flex; align-items:center; justify-content:space-between; gap:1rem; padding:1rem 0; flex-wrap:wrap; }
.mark{ font-family:'Space Grotesk', sans-serif; font-weight:700; font-size:1.1rem; letter-spacing:-.01em; white-space:nowrap; text-decoration:none; }
.mark span{ color:var(--accent); }
nav.primary-menu ul{ list-style:none; display:flex; gap:1.4rem; margin:0; padding:0; flex-wrap:wrap; }
nav.primary-menu a{ text-decoration:none; font-size:.85rem; color:var(--sub); }
nav.primary-menu a:hover, nav.primary-menu .current-menu-item > a{ color:var(--ink); }

.search-box{ display:flex; align-items:center; gap:.4rem; border:1px solid var(--line); padding:.4rem .6rem; font-size:.78rem; color:var(--sub); }
.search-box input[type="search"]{ border:none; background:none; outline:none; color:var(--ink); font-family:inherit; font-size:.8rem; width:9rem; }
.search-box button{ background:none; border:none; color:var(--sub); cursor:pointer; padding:0; font-size:.9rem; }

/* ---------- PAGE HEAD ---------- */
.page-head{ padding:2.4rem 0 1.4rem; }
.eyebrow{ font-size:.72rem; color:var(--sub); margin:0 0 .6rem; }
.page-head h1{ font-family:'Space Grotesk', sans-serif; font-weight:500; font-size:clamp(1.5rem,4vw,2.1rem); line-height:1.25; margin:0 0 .8rem; max-width:24ch; }
.page-head p.lede{ color:var(--sub); font-size:.92rem; line-height:1.6; max-width:60ch; }

/* ---------- SECTIONS ---------- */
.section{ padding:2.4rem 0; border-top:1px solid var(--line); }
.section:first-child{ border-top:none; }
.section-head{ display:flex; justify-content:space-between; align-items:baseline; margin-bottom:1.4rem; flex-wrap:wrap; gap:.4rem;}
.section-head h1, .section-head h2{ font-family:'Space Grotesk', sans-serif; font-weight:500; font-size:1.15rem; margin:0; }
.section-head .see-all{ font-size:.78rem; color:var(--sub); text-decoration:none; }

/* ---------- ROUND CARDS (Loop) ---------- */
.season-label{ font-size:.75rem; color:var(--sub); margin:0 0 1rem; padding-top:1.6rem; border-top:1px solid var(--line); }
.season-label:first-of-type{ border-top:none; padding-top:0; }
.round-grid{ display:grid; grid-template-columns:repeat(auto-fill,minmax(200px,1fr)); gap:1.4rem; }
.round-card{ border:1px solid var(--line); }
.round-card a.round-link{ text-decoration:none; color:inherit; display:block; }
.round-swatch{ display:flex; aspect-ratio:16/9; background:var(--panel); overflow:hidden; }
/* Direkte Kinder statt "img", damit sowohl eine Flip-Karte (.flip-card,
   wenn Interpret/Albumtitel bekannt sind) als auch ein einfaches Bild
   (.round-swatch__plain, wenn nicht) gleich groß eingepasst werden. */
.round-swatch > *{ width:50%; height:100%; }
.round-swatch.single > *{ width:100%; }
.round-swatch__plain{ object-fit:contain; }

/* ---------- Cover-Flip (Interpret/Albumtitel aus dem Medientitel) ---------- */
.flip-card{ perspective:800px; }
.flip-card__inner{
  position:relative;
  width:100%; height:100%;
  transition:transform .5s ease;
  transform-style:preserve-3d;
}
.flip-card:hover .flip-card__inner{ transform:rotateY(180deg); }
.flip-card__face{
  position:absolute; inset:0;
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  gap:.15rem;
  backface-visibility:hidden;
  -webkit-backface-visibility:hidden;
}
.flip-card__face--front img{ width:100%; height:100%; object-fit:contain; }
.flip-card__face--back{
  background:var(--panel);
  transform:rotateY(180deg);
  padding:.6rem;
  text-align:center;
}
.flip-card__title{ font-size:.78rem; font-weight:600; color:var(--ink); line-height:1.5; }
.round-body{ padding:.9rem 1rem 1.1rem; }
.round-curator{ font-size:.7rem; color:var(--sub); margin-bottom:.35rem; }
.round-title{ font-size:.92rem; font-weight:600; line-height:1.4; margin-bottom:.3rem; }
.round-vs{ width:1.6rem; height:0; border-top:1px solid var(--sub); margin:.4rem 0; }

.feed-status{ text-align:center; font-size:.75rem; color:var(--sub); padding:1.6rem 0; grid-column:1/-1; }
.feed-status.done{ opacity:.6; }
.feed-status.error{ color:var(--accent); }

/* ---------- SINGLE / PAGE CONTENT ---------- */
.entry-header{ padding:2.2rem 0 1rem; }
.entry-header h1{ font-family:'Space Grotesk', sans-serif; font-weight:500; font-size:clamp(1.4rem,4vw,2rem); margin:0 0 .5rem; }
.entry-meta{ font-size:.78rem; color:var(--sub); }
.entry-thumbnail{ margin-bottom:1.6rem; }
.entry-content{ padding-bottom:3rem; font-size:.95rem; line-height:1.75; max-width:70ch; }
.entry-content img{ margin:1rem 0; }
.entry-content table{ width:100%; border-collapse:collapse; font-size:.85rem; margin:1.4rem 0; }
.entry-content table th, .entry-content table td{ text-align:left; padding:.55rem .7rem; border-top:1px solid var(--line); }
.entry-content table th{ font-family:'IBM Plex Mono', monospace; font-size:.72rem; color:var(--sub); font-weight:500; }
.entry-content a{
	color:var(--accent);
	text-decoration:none;
	font-weight:bold;
}
.entry-content a:hover{
	color:#880808;
}

/* ---------- SINGLE / PAGE TABLE ---------- */
.entry-content table tbody tr:nth-child(even){
  background:#800000;
}

/* ---------- ENTRY TAGS (Bands) ---------- */
.entry-tags{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:.6rem;
  margin:0 0 2rem;
  padding-top:1.4rem;
  border-top:1px solid var(--line);
}
.entry-tags__label{
  font-size:.72rem;
  color:var(--sub);
}
.entry-tags a{
  display:inline-block;
  padding:.3rem .7rem;
  border:1px solid var(--line);
  font-size:.78rem;
  text-decoration:none;
  color:var(--ink);
}
.entry-tags a:hover{
  border-color:var(--accent);
  color:var(--accent);
}

/* ---------- POST NAVIGATION ---------- */
.post-navigation{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:1rem;
  margin:2rem 0 3rem;
  padding-top:1.6rem;
  border-top:1px solid var(--line);
}
.post-navigation a,
.post-navigation a:hover,
.post-navigation a:visited{
  text-decoration:none;
}
.post-navigation a{
  display:block;
  padding:1rem 1.2rem;
  border:1px solid var(--line);
  font-size:.85rem;
  line-height:1.5;
  color:var(--ink);
  transition:border-color .15s ease, color .15s ease;
}
.post-navigation a:hover{ border-color:var(--accent); color:var(--accent); }
.post-navigation__older{ text-align:right; }
.post-navigation__older a{ margin-left:auto; }
@media (max-width:560px){
  .post-navigation{ grid-template-columns:1fr; }
  .post-navigation__older{ text-align:left; }
}
/* ---------- SUB-MENU ---------- */
nav.primary-menu li{ position:relative; }

nav.primary-menu .sub-menu{
  display:none;
  position:absolute;
  top:100%;
  left:0;
  min-width:190px;
  margin:0;
  padding:.4rem 0;
  list-style:none;
  background:var(--bg);
  border:1px solid var(--line);
  z-index:20;
}
nav.primary-menu li:hover > .sub-menu,
nav.primary-menu li:focus-within > .sub-menu{
  display:block;
}
nav.primary-menu .sub-menu li{ display:block; }
nav.primary-menu .sub-menu a{
  display:block;
  padding:.55rem 1rem;
  font-size:.78rem;
  white-space:nowrap;
  color:var(--sub);
}
nav.primary-menu .sub-menu a:hover{ color:var(--ink); }
/* ---------- FOOTER ---------- */
footer.site-footer{ border-top:1px solid var(--line); padding:2.2rem 0 2.6rem; }
.footer-grid{ display:flex; justify-content:space-between; gap:2rem; flex-wrap:wrap; }
.footer-col h3{ font-size:.75rem; text-transform:uppercase; letter-spacing:.04em; color:var(--sub); margin:0 0 .8rem; font-weight:500;}
.footer-col ul{ list-style:none; margin:0; padding:0; }
.footer-col a{ display:block; text-decoration:none; font-size:.85rem; margin-bottom:.5rem; }
.footer-col a:hover{ color:var(--accent); }
.footer-bottom{ margin-top:2rem; padding-top:1.2rem; border-top:1px solid var(--line); font-size:.74rem; color:var(--sub); display:flex; justify-content:space-between; flex-wrap:wrap; gap:.5rem;}


/* ---------- Bilder im Beitrag ---------- */
.entry-images{ display:grid; grid-template-columns:1fr 1fr; gap:1rem; align-items:start; margin:0 0 1.6rem; }
.entry-images.single{ grid-template-columns:1fr; max-width:480px; }
.entry-images img{ width:50%; height:auto; margin:0; }
/* Test: Bilder bleiben durch die reduzierte Breite (50%) auch auf schmalen
   Bildschirmen nebeneinander. Bei Bedarf einfach wieder einkommentieren:
@media (max-width:560px){ .entry-images{ grid-template-columns:1fr; } }
*/

/* ---------- Beitragsarchiv ---------- */
.archive-list{ display:block; }
.archive-entry{ padding:2.2rem 0; border-top:1px solid var(--line); }
.archive-entry:first-child{ padding-top:0; border-top:none; }
.archive-entry .entry-header{ padding:0 0 1rem; }
.archive-entry .entry-header h2{
  font-family:'Space Grotesk', sans-serif; font-weight:500;
  font-size:clamp(1.25rem,3vw,1.7rem); line-height:1.3; margin:0 0 .4rem;
}
.archive-entry .entry-header h2 a{ text-decoration:none; color:inherit; }
.archive-entry .entry-header h2 a:hover{ color:var(--accent); }
.archive-entry .entry-images{ margin-bottom:1.4rem; }

.pagination{
  display:flex; gap:.5rem; justify-content:center; flex-wrap:wrap;
  margin:2.5rem 0; font-family:'IBM Plex Mono', monospace; font-size:.8rem;
}
.pagination .page-numbers{
  padding:.4rem .7rem; border:1px solid var(--line); color:var(--sub); text-decoration:none;
}
.pagination .page-numbers.current,
.pagination .page-numbers:hover{ color:var(--ink); border-color:var(--accent); }

/* ---------- Band-Übersicht: Sprungnavigation ---------- */
.band-jumpnav{
  display:flex;
  flex-wrap:wrap;
  gap:.3rem;
  margin:0 0 2rem;
  padding-bottom:1.4rem;
  border-bottom:1px solid var(--line);
}
.band-jumpnav a,
.band-jumpnav span{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:1.3rem;
  height:1.3rem;
  padding:0 .1rem;
  font-size:.7rem;
}
.band-jumpnav a{ color:var(--sub); text-decoration:none; }
.band-jumpnav a:hover{ color:var(--accent); }
.band-jumpnav span{ color:var(--line); }

/* ---------- Band-Übersicht: Liste ---------- */
.band-index{
  column-count:3;
  column-gap:2.5rem;
}
.band-group{
  break-inside:avoid-column;
  margin-bottom:1.8rem;
}
.band-group__letter{
  font-size:.8rem;
  color:var(--accent);
  margin-bottom:.6rem;
  padding-bottom:.3rem;
  border-bottom:1px solid var(--line);
}
.band-group__list{ list-style:none; margin:0; padding:0; }
.band-group__list li{ margin-bottom:.45rem; }
.band-group__list a{
  text-decoration:none;
  font-weight:700;
  font-size:.88rem;
  color:var(--ink);
}
.band-group__list a:hover{ color:var(--accent); }
.band-group__count{
  margin-left:.3rem;
  font-size:.7rem;
  color:var(--sub);
}

@media (max-width:760px){
  .band-index{ column-count:2; }
}
@media (max-width:480px){
  .band-index{ column-count:1; }
}

/* ---------- Statistik ---------- */
.stat-group{ margin-bottom:2.6rem; }
.stat-group:last-child{ margin-bottom:0; }
.stat-group__title{
  font-family:'Space Grotesk', sans-serif;
  font-weight:500;
  font-size:1.1rem;
  margin:0 0 .6rem;
}
.stat-group__text{
  color:var(--sub);
  font-size:.88rem;
  line-height:1.6;
  max-width:60ch;
  margin:0 0 .9rem;
}
.stat-group__text:last-of-type{ margin-bottom:1.4rem; }
.stat-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(160px,1fr));
  gap:1.5rem;
}
.stat-card{
  border:1px solid var(--line);
  padding:1.4rem 1rem;
  text-align:center;
}
.stat-card__value{
  font-size:2rem;
  line-height:1;
  color:var(--accent);
  margin-bottom:.5rem;
}
.stat-card__label{
  font-size:.8rem;
  color:var(--sub);
}