/* ============================================================
   autorenmagazin.de — v2.css
   Magazin-Optik-Variante: Fraunces Display, Bento-Grids,
   Editorial-Hierarchie. Lädt main.css als Basis, ergänzt
   Magazin-spezifische Komponenten und Token-Overrides.
   ============================================================ */

/* === Lokale Fraunces (variable, latin + latin-ext, DSGVO-konform) === */

@font-face {
  font-family: 'Fraunces';
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url('/assets/fonts/fraunces-italic-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Fraunces';
  font-style: italic;
  font-weight: 400 700;
  font-display: swap;
  src: url('/assets/fonts/fraunces-italic-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/assets/fonts/fraunces-roman-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/assets/fonts/fraunces-roman-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* === Token-Overrides === */

:root {
  --font-serif: 'Fraunces', 'Iowan Old Style', 'Apple Garamond', Georgia, Baskerville, serif;
  /* Zweite Akzentfarbe (warmes Beige als Magazin-Sekundär) */
  --cream: #f5ead6;
  --cream-deep: #e8d8b7;
  /* Wider container für Magazin-Bento */
  --measure-mag: 76rem;
}

/* === Body-Tuning === */

body.mag-v2 {
  background: var(--bg);
}

body.mag-v2 h1,
body.mag-v2 h2,
body.mag-v2 h3 {
  font-family: var(--font-serif);
  font-feature-settings: "ss01" 1, "ss02" 1;  /* Fraunces stylistic alternates */
}

/* Hero-Section */
.mag-hero {
  padding: var(--s-8) 0 var(--s-16);
  border-bottom: 1px solid var(--rule);
}
.mag-hero .container { max-width: var(--measure-mag); }
.mag-kicker {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--s-3);
}
.mag-kicker::before { content: "— "; color: var(--text-muted); }

.mag-hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-8);
}
@media (min-width: 960px) {
  .mag-hero-grid { grid-template-columns: 1.6fr 1fr; gap: var(--s-12); }
}

/* Featured Story (groß, links) */
.mag-feature {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
}
.mag-feature .image-wrap {
  aspect-ratio: 16 / 10;
  background: var(--bg-soft);
  overflow: hidden;
  border-radius: 4px;
  margin-bottom: var(--s-4);
}
.mag-feature .image-wrap img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform 0.5s ease;
}
.mag-feature:hover .image-wrap img { transform: scale(1.02); }
.mag-feature .rubrik-tag {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--s-3);
}
.mag-feature h1 {
  font-family: var(--font-serif);
  font-size: clamp(1.875rem, 4.5vw, 3.75rem);
  line-height: 1.05;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 var(--s-3);
}
.mag-feature .subtitle {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.0625rem, 1.6vw, 1.375rem);
  line-height: 1.4;
  color: var(--text-muted);
  margin: 0 0 var(--s-4);
}
.mag-feature .read-meta {
  font-family: var(--font-sans);
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Sekundär-Stories (rechts, gestapelt) */
.mag-secondary {
  display: flex;
  flex-direction: column;
  gap: var(--s-8);
}
.mag-secondary-item {
  display: block;
  text-decoration: none;
  color: inherit;
  padding-top: var(--s-6);
  border-top: 1px solid var(--rule);
}
.mag-secondary-item:first-child { border-top: none; padding-top: 0; }
.mag-secondary-item .image-wrap {
  aspect-ratio: 3 / 2;
  background: var(--bg-soft);
  overflow: hidden;
  border-radius: 4px;
  margin-bottom: var(--s-3);
}
.mag-secondary-item .image-wrap img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.mag-secondary-item .rubrik-tag {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  display: block;
  margin-bottom: var(--s-2);
}
.mag-secondary-item h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.125rem, 1.6vw, 1.4375rem);
  line-height: 1.2;
  font-weight: 600;
  margin: 0 0 var(--s-2);
}
.mag-secondary-item .excerpt {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin: 0;
}
.mag-secondary-item:hover h2 { color: var(--accent); }

/* === Section-Wrapper === */

.mag-section {
  padding: var(--s-16) 0;
  border-bottom: 1px solid var(--rule);
}
.mag-section .container { max-width: var(--measure-mag); }
.mag-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--s-4);
  margin-bottom: var(--s-8);
}
.mag-section-head h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin: 0;
}
.mag-section-head .more {
  font-family: var(--font-sans);
  font-size: 0.875rem;
  text-decoration: none;
  color: var(--accent);
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
}

/* === Cover-Strip (Diese Woche im Regal) === */
.mag-cover-strip {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--s-6);
}
@media (min-width: 640px) { .mag-cover-strip { grid-template-columns: repeat(4, 1fr); } }
.mag-cover-card {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease;
}
.mag-cover-card:hover { transform: translateY(-4px); }
.mag-cover-card .cover {
  aspect-ratio: 2 / 3;
  background: var(--cream);
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(26, 26, 46, 0.18), 0 2px 4px rgba(26, 26, 46, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--s-2);
}
.mag-cover-card .cover img { max-width: 100%; max-height: 100%; object-fit: contain; }
.mag-cover-card .title {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.25;
}
.mag-cover-card .author {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* === Bento-Grid (Themenwelten) === */

.mag-bento {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-4);
}
@media (min-width: 720px) {
  .mag-bento {
    grid-template-columns: repeat(6, 1fr);
    grid-auto-rows: minmax(180px, auto);
  }
}
.mag-bento-card {
  position: relative;
  padding: var(--s-6);
  border-radius: 6px;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 180px;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.mag-bento-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(26, 26, 46, 0.12);
}
.mag-bento-card .label {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.7;
}
.mag-bento-card .title {
  font-family: var(--font-serif);
  font-size: clamp(1.25rem, 2vw, 1.875rem);
  line-height: 1.15;
  font-weight: 600;
  margin: var(--s-2) 0 var(--s-2);
}
.mag-bento-card .desc {
  font-size: 0.95rem;
  line-height: 1.5;
  opacity: 0.8;
  margin: 0;
}

/* Bento-Größen */
@media (min-width: 720px) {
  .mag-bento-card.size-xl { grid-column: span 4; grid-row: span 2; padding: var(--s-8); }
  .mag-bento-card.size-l  { grid-column: span 3; }
  .mag-bento-card.size-m  { grid-column: span 2; }
  .mag-bento-card.size-s  { grid-column: span 2; }
}

/* Bento-Farb-Varianten */
.mag-bento-card.bg-cream    { background: var(--cream); }
.mag-bento-card.bg-cream-deep { background: var(--cream-deep); }
.mag-bento-card.bg-violet   { background: var(--accent); color: white; }
.mag-bento-card.bg-violet .label { color: rgba(255,255,255,0.9); }
.mag-bento-card.bg-soft     { background: var(--accent-soft); }
.mag-bento-card.bg-dark     { background: var(--text); color: var(--bg); }
.mag-bento-card.bg-dark .label { color: rgba(250,250,247,0.85); }
.mag-bento-card.bg-card     { background: var(--bg-card); border: 1px solid var(--rule); }

.mag-bento-card.size-xl .title { font-size: clamp(1.875rem, 3vw, 2.75rem); }

/* === Markus' Kolumne === */

.mag-column {
  display: grid;
  gap: var(--s-8);
  grid-template-columns: 1fr;
  align-items: start;
}
@media (min-width: 720px) { .mag-column { grid-template-columns: 240px 1fr; } }
.mag-column-portrait {
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  background: var(--accent-soft);
  overflow: hidden;
  display: grid;
  place-items: center;
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 4rem;
  color: var(--accent);
}
.mag-column-portrait img { width: 100%; height: 100%; object-fit: cover; }
.mag-column-byline {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--s-2);
}
.mag-column h2 {
  font-family: var(--font-serif);
  font-size: clamp(1.875rem, 3.2vw, 2.75rem);
  line-height: 1.1;
  margin: 0 0 var(--s-3);
}
.mag-column h2 a { color: inherit; text-decoration: none; }
.mag-column .lead {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.25rem;
  line-height: 1.4;
  color: var(--text-muted);
  margin: 0 0 var(--s-6);
  max-width: 38rem;
}
.mag-column .more-list {
  list-style: none;
  padding: 0;
  margin: var(--s-6) 0 0;
  border-top: 1px solid var(--rule);
}
.mag-column .more-list li {
  padding: var(--s-3) 0;
  border-bottom: 1px solid var(--rule);
  font-family: var(--font-sans);
  font-size: 0.95rem;
}
.mag-column .more-list a { color: var(--text); text-decoration: none; }
.mag-column .more-list a:hover { color: var(--accent); }
.mag-column .more-list .date {
  display: inline-block;
  width: 110px;
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* === Redaktions-Liste (4×2 Grid, kompakter) === */

.mag-editor-list {
  display: grid;
  gap: var(--s-8) var(--s-6);
  grid-template-columns: 1fr;
}
@media (min-width: 560px) { .mag-editor-list { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .mag-editor-list { grid-template-columns: repeat(4, 1fr); } }
.mag-editor-item {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
}
.mag-editor-item .image-wrap {
  aspect-ratio: 4 / 3;
  background: var(--bg-soft);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: var(--s-3);
  transition: transform 0.2s ease;
}
.mag-editor-item:hover .image-wrap { transform: translateY(-2px); }
.mag-editor-item .image-wrap img {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.mag-editor-item .rubrik-tag {
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--s-1);
}
.mag-editor-item h3 {
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  line-height: 1.25;
  margin: 0 0 var(--s-1);
  font-weight: 600;
}
.mag-editor-item:hover h3 { color: var(--accent); }
.mag-editor-item .excerpt {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.45;
  margin: 0;
  /* Auf 2 Zeilen begrenzen für Layout-Konsistenz */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.mag-editor-item .date {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: var(--s-2);
}

/* Header etwas dezenter für Magazin-Modus */
body.mag-v2 .site-header .container { min-height: 72px; }
body.mag-v2 .brand { font-size: 1.375rem; letter-spacing: -0.01em; }
