/*
Theme Name: Jumuia
Theme URI: https://jumuia.example
Author: Jumuia Publishing
Author URI: https://jumuia.example
Description: Buch-Marktplatz-Theme für Jumuia Publishing – Präsentation und Verkauf der Krimireihen „Alpine Crimes" und „Blueprint". Eigener Inhaltstyp „Buch", Serien-Taxonomie, Amazon-Kauflinks, responsives Design.
Version: 1.0.0
Requires at least: 5.9
Tested up to: 6.6
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: jumuia
Tags: e-commerce, custom-logo, custom-menu, featured-images, translation-ready
*/

/* =========================================================
   1. Design-Token
   ========================================================= */
:root {
  --ink: #16181d;            /* Fast-Schwarz für Text, passend zu den Logos */
  --paper: #f7f5f0;          /* Warmes Papierweiß */
  --paper-card: #ffffff;
  --alpine: #1e3a2f;         /* Tiefes Tannengrün – Alpine Crimes */
  --alpine-light: #2e5745;
  --blueprint: #1d3a5f;      /* Tiefes Blau – Blueprint */
  --blueprint-light: #2c5688;
  --crime: #b3202c;          /* Krimi-Rot als Akzent */
  --muted: #6b6f76;
  --line: #e3e0d8;
  --shadow: 0 10px 30px rgba(22, 24, 29, 0.10);
  --radius: 6px;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-head: "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --maxw: 1180px;
}

/* =========================================================
   2. Basis
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--crime); text-decoration: none; }
a:hover, a:focus { text-decoration: underline; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-head);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin: 0 0 0.5em;
  color: var(--ink);
}

h1 { font-size: clamp(2rem, 4.5vw, 3.2rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); }
h3 { font-size: 1.25rem; }

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

.screen-reader-text {
  position: absolute !important;
  clip: rect(1px, 1px, 1px, 1px);
  width: 1px; height: 1px;
  overflow: hidden;
}

/* =========================================================
   3. Buttons
   ========================================================= */
.btn {
  display: inline-block;
  padding: 13px 30px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  background: var(--ink);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.15s ease;
}
.btn:hover, .btn:focus {
  background: transparent;
  color: var(--ink);
  text-decoration: none;
  transform: translateY(-1px);
}

.btn--crime { background: var(--crime); border-color: var(--crime); }
.btn--crime:hover, .btn--crime:focus { background: transparent; color: var(--crime); }

.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover, .btn--ghost:focus { background: var(--ink); color: #fff; }

.btn--light { background: #fff; border-color: #fff; color: var(--ink); }
.btn--light:hover, .btn--light:focus { background: transparent; color: #fff; }

/* =========================================================
   4. Header / Navigation
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(247, 245, 240, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 76px;
}

.site-branding { display: flex; align-items: center; gap: 14px; }
.site-branding .custom-logo,
.site-branding .fallback-logo { max-height: 44px; width: auto; }
.site-title {
  font-family: var(--font-head);
  font-size: 1.6rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0;
}
.site-title a { color: var(--ink); }
.site-title a:hover { text-decoration: none; color: var(--crime); }

.main-nav ul {
  display: flex;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.main-nav a {
  display: block;
  padding: 10px 14px;
  color: var(--ink);
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-radius: var(--radius);
}
.main-nav a:hover, .main-nav a:focus,
.main-nav .current-menu-item > a { color: var(--crime); text-decoration: none; }

.nav-toggle {
  display: none;
  background: none;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  padding: 8px 12px;
  font-family: var(--font-head);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  cursor: pointer;
  color: var(--ink);
}

@media (max-width: 860px) {
  .nav-toggle { display: inline-block; }
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
  }
  .main-nav.is-open { display: block; }
  .main-nav ul { flex-direction: column; padding: 12px 24px 20px; }
}

/* =========================================================
   5. Hero
   ========================================================= */
.hero {
  position: relative;
  background:
    linear-gradient(160deg, rgba(16, 20, 24, 0.92) 0%, rgba(30, 58, 47, 0.88) 100%),
    var(--ink);
  color: #fff;
  padding: clamp(70px, 12vw, 130px) 0;
  overflow: hidden;
}
.hero::after {
  /* Angedeutete Bergsilhouette */
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 90px;
  background: var(--paper);
  clip-path: polygon(0 100%, 0 65%, 12% 30%, 22% 62%, 34% 18%, 46% 58%, 58% 8%, 70% 52%, 82% 24%, 92% 60%, 100% 40%, 100% 100%);
  opacity: 1;
}
.hero h1 { color: #fff; max-width: 760px; }
.hero p.lead {
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  max-width: 640px;
  color: rgba(255, 255, 255, 0.85);
  margin: 0 0 32px;
}
.hero .hero-kicker {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: #fff;
  background: var(--crime);
  padding: 6px 14px;
  border-radius: var(--radius);
  margin-bottom: 22px;
}
.hero .hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* =========================================================
   6. Sektionen
   ========================================================= */
.section { padding: clamp(50px, 8vw, 90px) 0; }
.section--alt { background: #efece4; }
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 36px;
}
.section-head p { margin: 0; color: var(--muted); max-width: 560px; }
.section-head .more-link {
  font-family: var(--font-head);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.9rem;
  white-space: nowrap;
}

/* =========================================================
   7. Serien-Teaser
   ========================================================= */
.series-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
}
.series-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 320px;
  padding: 36px;
  border-radius: var(--radius);
  color: #fff;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease;
}
.series-card:hover { transform: translateY(-4px); }
.series-card--alpine-crimes { background: linear-gradient(160deg, #101418 0%, var(--alpine) 90%); }
.series-card--blueprint { background: linear-gradient(160deg, #101418 0%, var(--blueprint) 90%); }
.series-card h3 {
  color: #fff;
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  letter-spacing: 0.1em;
}
.series-card p { color: rgba(255,255,255,0.82); margin: 0 0 22px; }
.series-card .series-count {
  position: absolute;
  top: 26px; right: 26px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  background: rgba(255,255,255,0.14);
  padding: 6px 12px;
  border-radius: 999px;
}
.series-card a.series-link::after {
  content: "";
  position: absolute;
  inset: 0;
}

/* =========================================================
   8. Buchkarten
   ========================================================= */
.book-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 28px;
}
.book-card {
  background: var(--paper-card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.book-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.book-card .book-cover {
  position: relative;
  aspect-ratio: 2 / 3;
  background: linear-gradient(160deg, #1a1e24, #33383f);
  overflow: hidden;
}
.book-card .book-cover img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.book-card .book-cover .cover-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  color: rgba(255,255,255,0.85);
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.1rem;
  text-transform: uppercase;
  text-align: center;
  letter-spacing: 0.08em;
}
.book-card .book-body { padding: 18px 18px 22px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.book-card h3 { font-size: 1.05rem; margin: 0; }
.book-card h3 a { color: var(--ink); }
.book-card h3 a:hover { color: var(--crime); text-decoration: none; }
.book-card .book-author { color: var(--muted); font-size: 0.9rem; margin: 0; }
.book-card .book-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 10px;
}
.book-card .book-price { font-weight: 700; font-size: 1.05rem; }
.book-card .btn { padding: 8px 16px; font-size: 0.8rem; }

.series-badge {
  display: inline-block;
  align-self: flex-start;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #fff;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--muted);
}
.series-badge--alpine-crimes { background: var(--alpine); }
.series-badge--blueprint { background: var(--blueprint); }
.book-card .series-badge {
  position: absolute;
  top: 12px; left: 12px;
  z-index: 2;
}
.book-card .band-badge {
  position: absolute;
  top: 12px; right: 12px;
  z-index: 2;
  background: var(--crime);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: 999px;
}

/* =========================================================
   9. Einzelbuch
   ========================================================= */
.single-book { padding: clamp(50px, 8vw, 80px) 0; }
.book-layout {
  display: grid;
  grid-template-columns: minmax(260px, 380px) 1fr;
  gap: clamp(30px, 5vw, 70px);
  align-items: start;
}
@media (max-width: 780px) {
  .book-layout { grid-template-columns: 1fr; }
  .book-layout .book-cover-large { max-width: 320px; margin: 0 auto; }
}
.book-cover-large {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(22,24,29,0.25);
  aspect-ratio: 2 / 3;
  background: linear-gradient(160deg, #1a1e24, #33383f);
}
.book-cover-large img { width: 100%; height: 100%; object-fit: cover; }
.book-cover-large .cover-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 30px;
  color: rgba(255,255,255,0.85);
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 1.6rem;
  text-transform: uppercase;
  text-align: center;
  letter-spacing: 0.08em;
}
.book-detail .book-subtitle {
  font-size: 1.15rem;
  color: var(--muted);
  margin: -6px 0 18px;
}
.book-detail .book-author-line { color: var(--muted); margin: 0 0 20px; }
.book-detail .book-price-line {
  font-size: 1.6rem;
  font-weight: 800;
  margin: 0 0 8px;
}
.book-detail .book-price-note { color: var(--muted); font-size: 0.85rem; margin: 0 0 22px; }
.book-detail .book-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 34px; }

.book-meta-table {
  width: 100%;
  border-collapse: collapse;
  margin: 30px 0 0;
  font-size: 0.95rem;
}
.book-meta-table th, .book-meta-table td {
  text-align: left;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
}
.book-meta-table th {
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.8rem;
  color: var(--muted);
  width: 40%;
}

.book-description { margin-top: 20px; }
.book-description > h2 { margin-top: 40px; }

/* =========================================================
   10. Archiv & Blog
   ========================================================= */
.archive-header { padding: clamp(40px, 7vw, 70px) 0 0; }
.archive-header .archive-description { color: var(--muted); max-width: 680px; }

.serie-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 26px 0 0;
}
.serie-filter a {
  display: inline-block;
  padding: 8px 18px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  color: var(--ink);
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.serie-filter a:hover, .serie-filter a.is-active {
  background: var(--ink);
  color: #fff;
  text-decoration: none;
}

.post-list { display: grid; gap: 28px; }
.post-list .post-item {
  background: var(--paper-card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
}
.post-list .post-item h2 { font-size: 1.4rem; margin-bottom: 8px; }
.post-list .post-item h2 a { color: var(--ink); }
.post-list .post-item h2 a:hover { color: var(--crime); text-decoration: none; }
.post-list .post-meta { color: var(--muted); font-size: 0.85rem; margin-bottom: 12px; }

.entry-content { max-width: 760px; }
.entry-content img { border-radius: var(--radius); }

.pagination { margin: 46px 0 0; display: flex; gap: 8px; flex-wrap: wrap; }
.pagination .page-numbers {
  display: inline-block;
  padding: 8px 16px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  color: var(--ink);
  font-family: var(--font-head);
  font-weight: 700;
}
.pagination .page-numbers.current,
.pagination .page-numbers:hover { background: var(--ink); color: #fff; text-decoration: none; }

/* =========================================================
   11. CTA / Newsletter
   ========================================================= */
.cta-band {
  background: linear-gradient(160deg, var(--ink) 0%, var(--alpine) 100%);
  color: #fff;
  text-align: center;
  padding: clamp(50px, 8vw, 80px) 0;
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,0.82); max-width: 560px; margin: 0 auto 28px; }

/* =========================================================
   12. Footer
   ========================================================= */
.site-footer {
  background: var(--ink);
  color: rgba(255,255,255,0.75);
  padding: 56px 0 30px;
  margin-top: 0;
}
.site-footer a { color: #fff; }
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 36px;
  margin-bottom: 40px;
}
.site-footer h3 {
  color: #fff;
  font-size: 0.95rem;
  letter-spacing: 0.1em;
  margin-bottom: 14px;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.15);
  padding-top: 22px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.85rem;
}
.footer-nav ul { display: flex; flex-wrap: wrap; gap: 18px; list-style: none; margin: 0; padding: 0; }

/* =========================================================
   13. Suche & 404
   ========================================================= */
.search-form { display: flex; gap: 10px; max-width: 480px; }
.search-form input[type="search"] {
  flex: 1;
  padding: 12px 16px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  font-size: 1rem;
  background: #fff;
}
.error-404 { text-align: center; padding: clamp(70px, 12vw, 130px) 0; }
.error-404 .error-code {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: clamp(5rem, 15vw, 9rem);
  line-height: 1;
  color: var(--line);
}

/* =========================================================
   14. WooCommerce-Grundanpassung
   ========================================================= */
.woocommerce ul.products li.product .button,
.woocommerce a.button, .woocommerce button.button {
  background: var(--ink);
  color: #fff;
  font-family: var(--font-head);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-radius: var(--radius);
}
.woocommerce a.button:hover, .woocommerce button.button:hover {
  background: var(--crime);
  color: #fff;
}
