/*
Theme Name: die stadtredaktion
Theme URI: https://diestadtredaktion.at
Author: die stadtredaktion
Description: Eigenes Theme für die stadtredaktion – ein unabhängiges Nachrichtenmedium.
Version: 2.6
License: GNU General Public License v2 or later
Text Domain: diestadtredaktion
*/

/* ============================================================
   DESIGN TOKENS  (overridden at runtime via Customizer)
   ============================================================ */
:root {
  /* Colors */
  --color-primary:      #042C53;
  --color-accent:       #185FA5;
  --color-accent-light: #378ADD;
  --color-accent-pale:  #B5D4F4;
  --color-bg:           #f4f2ed;

  /* Fonts – global */
  --font-display: 'Playfair Display', serif;
  --font-ui:      'Barlow', sans-serif;
  --font-body:    'Source Serif 4', serif;

  /* Fonts – per element */
  --font-header: 'Playfair Display', serif;
  --font-title:  'Playfair Display', serif;
  --font-hook:   'Source Serif 4', serif;

  /* Sizes – mobile */
  --size-title:        28px;
  --size-article:      17px;
  --size-hook:         19px;
  --size-header:       30px;
  --size-card-title:   22px;
  --size-card-excerpt: 14px;

  /* Sizes – desktop (≥ 900px), overridden in media query */
  --size-title-lg:   38px;
  --size-article-lg: 18px;
  --size-header-lg:  48px;

  /* Hero card gradient */
  --hero-grad-opacity: 0.92;
  --hero-grad-reach:   75%;

  /* Spacing */
  --lh-title:   1.2;
  --ls-title:   0em;
  --lh-hook:    1.45;
  --ls-hook:    0em;
  --lh-body:    1.75;
  --ls-body:    0em;
  --ls-header: -0.03em;
}

/* ============================================================
   READING PROGRESS BAR
   ============================================================ */
#reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 3px;
  background: var(--color-accent);
  z-index: 200;
  transition: width 0.1s linear;
  pointer-events: none;
}

.admin-bar #reading-progress {
  top: 46px;
}

@media screen and (max-width: 600px) {
  .admin-bar #reading-progress {
    top: 0;
  }
}

@media screen and (min-width: 783px) {
  .admin-bar #reading-progress {
    top: 32px;
  }
}

/* ============================================================
   RESET & BASE
   ============================================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: var(--font-ui);
  background: var(--color-bg);
  color: #1a1a1a;
  line-height: 1.6;
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

/* ============================================================
   TYPOGRAPHY
   ============================================================ */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  line-height: 1.2;
}

/* ============================================================
   TOP BAR
   ============================================================ */
.site-date {
  display: none;
  background: var(--color-bg);
  color: var(--color-primary);
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: center;
  padding: 6px 16px;
  border-bottom: 1px solid var(--color-accent-pale);
}

.nav-date {
  flex: 1;
  text-align: center;
  font-family: var(--font-ui);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
}

/* ============================================================
   MASTHEAD & NAV
   ============================================================ */
.masthead {
  background: var(--color-primary);
  padding: 16px 16px 0;
}

.masthead-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.site-name {
  font-family: var(--font-header);
  font-size: var(--size-header);
  font-weight: 900;
  color: #fff;
  letter-spacing: var(--ls-header);
  line-height: 1;
}

.site-tagline {
  display: none;
  font-size: 11px;
  color: var(--color-accent-pale);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin-bottom: 20px;
}

.main-nav {
  width: 100%;
  border-top: 1px solid rgba(255,255,255,0.15);
  margin-top: 12px;
  position: relative;
}

.nav-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 6px 0;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 20px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  margin: 6px 0;
}

.search-toggle {
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(255,255,255,0.85);
  padding: 6px;
  display: flex;
  align-items: center;
  transition: color 0.15s;
  line-height: 0;
}

.search-toggle:hover { color: #fff; }

.search-bar {
  width: 100%;
  padding: 10px 0 14px;
}

.search-bar[hidden] { display: none; }

.search-bar form {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.search-input-row {
  display: flex;
  gap: 6px;
}

.search-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.search-filters select {
  flex: 1;
  min-width: 120px;
  padding: 7px 10px;
  font-family: var(--font-ui);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: 2px;
  color: rgba(255,255,255,0.85);
  cursor: pointer;
  outline: none;
}

.search-filters select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpolyline points='1,1 5,5 9,1' fill='none' stroke='rgba(255,255,255,0.7)' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 28px;
}

.search-filters select:focus {
  background-color: rgba(255,255,255,0.2);
  border-color: rgba(255,255,255,0.45);
}

.search-filters option {
  background: var(--color-primary);
  color: #fff;
  text-transform: none;
  letter-spacing: 0;
  font-weight: 400;
}


.search-input-row input[type="search"] {
  flex: 1;
  padding: 9px 12px;
  font-family: var(--font-ui);
  font-size: 14px;
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: 2px;
  color: #fff;
  outline: none;
}

.search-bar input[type="search"]::placeholder { color: rgba(255,255,255,0.55); }

.search-bar input[type="search"]:focus {
  background: rgba(255,255,255,0.22);
  border-color: rgba(255,255,255,0.5);
}

.search-bar button[type="submit"] {
  padding: 9px 16px;
  background: rgba(255,255,255,0.18);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 2px;
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
}

.search-bar button[type="submit"]:hover { background: rgba(255,255,255,0.28); }

.nav-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.2s, opacity 0.2s;
}

.main-nav.is-open .nav-toggle span:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}
.main-nav.is-open .nav-toggle span:nth-child(2) {
  opacity: 0;
}
.main-nav.is-open .nav-toggle span:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

.main-nav ul {
  list-style: none;
  display: none;
  flex-direction: column;
  width: 100%;
  padding-bottom: 8px;
}

.main-nav.is-open ul {
  display: flex;
}

.main-nav ul li a {
  display: block;
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 12px 14px;
  border-bottom: 3px solid transparent;
  transition: border-color 0.15s, background 0.15s;
}

.main-nav ul li a:hover,
.main-nav ul li.current-menu-item a,
.main-nav ul li.current_page_item a {
  border-bottom-color: #fff;
  background: rgba(255,255,255,0.08);
}

.main-nav ul .sub-menu li a,
.main-nav ul .sub-menu li a:hover,
.main-nav ul .sub-menu li.current-menu-item a,
.main-nav ul .sub-menu li.current_page_item a {
  border-bottom: none;
}

/* Sub-menu — mobile */
.main-nav ul li.menu-item-has-children {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
}
.main-nav ul li.menu-item-has-children > a {
  flex: 1;
}
/* Hidden by default on mobile even when nav is open */
.main-nav.is-open .sub-menu {
  display: none;
}
/* Shown when JS toggles .sub-is-open on the parent li */
.main-nav li.sub-is-open > .sub-menu {
  display: flex;
  flex-direction: column;
  flex-basis: 100%;
  background: rgba(0,0,0,0.18);
  padding: 4px 0 4px 12px;
  width: 100%;
}
.main-nav ul .sub-menu li a {
  font-size: 11px;
  padding: 8px 14px;
  text-transform: none;
  letter-spacing: normal;
  font-weight: 500;
}

/* Arrow toggle button (mobile only) */
.sub-menu-toggle {
  background: none;
  border: none;
  color: rgba(255,255,255,0.65);
  cursor: pointer;
  padding: 0 14px;
  display: flex;
  align-items: center;
  line-height: 0;
  flex-shrink: 0;
}
.sub-menu-toggle svg {
  transition: transform 0.2s;
}
.sub-is-open > .sub-menu-toggle {
  color: #fff;
}
.sub-is-open > .sub-menu-toggle svg {
  transform: rotate(180deg);
}

/* ============================================================
   CONTENT AREA
   ============================================================ */
.content-area {
  max-width: 1100px;
  margin: 0 auto;
  padding: 20px 16px;
}

/* ============================================================
   SECTION HEADER
   ============================================================ */
.section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.section-header h2 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
  white-space: nowrap;
}

.section-header .line {
  flex: 1;
  height: 2px;
  background: var(--color-accent);
}

.section-header .see-all {
  font-size: 11px;
  color: var(--color-accent);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: color 0.15s;
}

.section-header .see-all:hover {
  color: var(--color-primary);
}

/* ============================================================
   FEATURED GRID — mobile: single column stack
   ============================================================ */
.featured-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.featured-side {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.featured-side .card-excerpt {
  display: none;
}

/* ============================================================
   ARTICLE CARDS
   ============================================================ */
.card {
  background: #fff;
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s;
  position: relative;
}

.card:hover {
  transform: translateY(-2px);
}

.card-overlay-link {
  position: absolute;
  inset: 0;
  z-index: 2;
}

.card-thumbnail {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16/9;
  object-fit: cover;
  object-position: top;
}

.card-thumbnail-hero {
  display: block;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}

.card-hero {
  min-height: 280px;
}

.card-hero .card-body {
  flex: none;
  margin-top: auto;
  position: relative;
  z-index: 1;
}

.card-hero--img .card-body {
  background: linear-gradient(
    to top,
    rgba(4,44,83, var(--hero-grad-opacity)) 0%,
    rgba(4,44,83, calc(var(--hero-grad-opacity) * 0.7)) var(--hero-grad-reach),
    transparent 100%
  );
}

.card-hero--img .card-headline {
  color: #fff;
}

.card-hero--img .card-excerpt {
  color: rgba(255,255,255,0.85);
}

.card-hero--img .card-meta {
  color: rgba(255,255,255,0.65);
}

.card-hero--img .card-meta a.author {
  color: var(--color-accent-pale);
}


.card-body {
  padding: 14px 16px 18px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-category {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 2px;
  color: #fff;
}

.card-category.national,
.card-category.international,
.card-category.start         { background: var(--color-accent); }

.card-headline {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.25;
  color: #0c1a2e;
  margin-bottom: 8px;
}


.card-headline-lg { font-size: var(--size-card-title); }
.card-headline-md { font-size: calc(var(--size-card-title) - 5px); }
.card-headline-sm { font-size: calc(var(--size-card-title) - 7px); }

.card-excerpt {
  font-family: var(--font-body);
  font-size: var(--size-card-excerpt);
  color: #444;
  line-height: 1.6;
  margin-bottom: 10px;
  flex: 1;
}

.card-meta {
  font-size: 11px;
  color: #888;
  letter-spacing: 0.03em;
  flex: 1;
  min-width: 0;
}

.card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px 8px;
  margin-top: auto;
  padding-top: 10px;
}

.card-footer .card-category {
  flex-shrink: 0;
}

/* No hook: keep the title directly underneath the image at the top of the
   body, and let the footer sink to the bottom (its default margin-top: auto).
   Detected via the headline sitting directly before the footer (no
   .card-excerpt between them). Hero keeps its own overlay layout. */
.card:not(.card-hero) .card-body:has(.card-headline + .card-footer) .card-headline,
.strip-card-body:has(.card-headline + .card-footer) .card-headline {
  margin-top: 0;
}

.card-meta .author {
  color: var(--color-accent);
  font-weight: 600;
}

/* ============================================================
   STRIP GRID — mobile: single column
   ============================================================ */
.section-divider {
  height: 92px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
}
.divider-line {
  display: block;
  border-top: 1px dotted var(--color-primary);
}

.strip-section {
  background: var(--color-bg);
  padding: 0 0 28px;
  position: relative;
}


.author-header {
  padding: 32px 0 24px;
  border-bottom: 2px solid #e0ddd6;
  margin-bottom: 28px;
}

.author-name {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 8px;
}

.author-bio {
  font-family: var(--font-body);
  font-size: 15px;
  color: #555;
  line-height: 1.6;
  max-width: 600px;
}

.card-meta a.author {
  color: var(--color-accent);
  font-weight: 600;
  text-decoration: none;
}

.card-meta a.author:hover {
  text-decoration: underline;
}

.strip-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-bottom: 0;
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
}

.strip-card {
  background: #fff;
  border-radius: 4px;
  overflow: hidden;
  border-top: 3px solid var(--color-accent);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s;
  position: relative;
}

.strip-card.international {
  border-top-color: var(--color-primary);
}

.strip-card:hover {
  transform: translateY(-2px);
}


.strip-card .card-thumbnail {
  display: block;
  width: 100%;
  height: 180px;
}

.strip-card-body {
  padding: 12px 14px 14px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* ============================================================
   FOOTER — mobile: single column
   ============================================================ */
.site-footer {
  background: var(--color-primary);
  color: var(--color-accent-pale);
  margin-top: 36px;
  padding: 24px 16px 16px;
  font-size: 13px;
  font-family: var(--font-footer);
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
}

.footer-name {
  font-family: var(--font-footer);
  font-size: 22px;
  font-weight: 900;
  color: #fff;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-logo {
  position: absolute;
  transform: translate(-50%, -50%);
  height: var(--footer-logo-height, 22px);
  width: auto;
  object-fit: contain;
  z-index: 1;
  user-select: none;
}
.customize-preview .footer-logo {
  cursor: grab;
}
.customize-preview .footer-logo:active {
  cursor: grabbing;
}

.footer-description {
  font-family: var(--font-footer);
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  line-height: 1.5;
  margin-bottom: 20px;
}

.footer-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

.footer-col h4 {
  font-family: var(--font-footer);
  color: #fff;
  font-weight: 600;
  margin-bottom: 10px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.footer-col ul {
  list-style: none;
}

.footer-col ul li {
  margin-bottom: 7px;
}

.footer-col ul li a {
  color: #85B7EB;
  transition: color 0.15s;
}

.footer-col ul li a:hover {
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 14px;
  color: #85B7EB;
  font-size: 11px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.footer-copy-row {
  display: flex;
  align-items: center;
  gap: 12px;
}


.footer-legal-links {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0;
}

.footer-legal-links li + li::before {
  content: '·';
  margin: 0 6px;
}

.footer-legal-links li a {
  color: #85B7EB;
  transition: color 0.15s;
}

.footer-legal-links li a:hover {
  color: #fff;
}

/* ============================================================
   PAGINATION
   ============================================================ */
.nav-links {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 8px 0 32px;
  font-size: 13px;
  font-weight: 600;
}

.nav-links a,
.nav-links span {
  padding: 6px 12px;
  border-radius: 3px;
  color: var(--color-accent);
  border: 1px solid #d0ccc4;
  transition: background 0.15s, color 0.15s;
}

.nav-links a:hover {
  background: var(--color-accent);
  color: #fff;
  border-color: var(--color-accent);
}

.nav-links .current {
  background: var(--color-accent);
  color: #fff;
  border-color: var(--color-accent);
}

/* ============================================================
   SINGLE POST
   ============================================================ */
.single-article {
  max-width: 720px;
  margin: 0 auto;
}

.single-header {
  margin-bottom: 20px;
}

.single-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 14px;
}

.single-categories .card-category {
  margin-bottom: 0;
}

.single-header a.card-category {
  text-decoration: none;
  cursor: pointer;
}

.single-header a.card-category:hover {
  opacity: 0.8;
}

.single-textsorte-eyebrow {
  margin: 0 0 6px;
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.single-textsorte-eyebrow a {
  color: inherit;
  text-decoration: none;
}

.single-textsorte-eyebrow a:hover {
  text-decoration: underline;
}

@keyframes fadeSlideIn {
  from {
    opacity: 0;
    transform: translateX(-18px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.single-title {
  font-family: var(--font-title);
  font-size: var(--size-title);
  font-weight: 900;
  color: #0c1a2e;
  line-height: var(--lh-title);
  letter-spacing: var(--ls-title);
  margin-bottom: 14px;
}

.single-hook {
  font-family: var(--font-hook);
  font-size: var(--size-hook);
  font-weight: 600;
  color: #2a2a2a;
  line-height: var(--lh-hook);
  letter-spacing: var(--ls-hook);
  margin: 14px 0 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid #e0ddd6;
}

.single-title .char,
.single-hook .char {
  display: inline-block;
  animation: fadeSlideIn 0.35s ease both;
}

.single-image {
  margin-bottom: 28px;
  border-radius: 4px;
  overflow: hidden;
}

.single-thumbnail {
  width: 100%;
  height: auto;
  display: block;
}

.single-content {
  font-family: var(--font-body);
  font-size: var(--size-article);
  line-height: var(--lh-body);
  letter-spacing: var(--ls-body);
  color: #222;
  overflow-wrap: break-word;
  word-break: break-word;
}

.single-content p {
  margin-bottom: 1.4em;
}

.single-content h2,
.single-content h3,
.single-content h4 {
  font-family: var(--font-display);
  color: #0c1a2e;
  margin: 1.8em 0 0.6em;
  line-height: 1.25;
}

.single-content h2 { font-size: 22px; }
.single-content h3 { font-size: 19px; }
.single-content h4 { font-size: 16px; }

.single-content a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 2px;
  overflow-wrap: break-word;
  word-break: break-word;
}

.single-content a:hover {
  color: var(--color-primary);
}

.single-content blockquote {
  border-left: 3px solid var(--color-accent);
  margin: 1.6em 0;
  padding: 0.6em 0 0.6em 20px;
  color: #555;
  font-style: italic;
}

.single-content img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  margin: 1.4em 0;
}

.single-content ul,
.single-content ol {
  padding-left: 1.4em;
  margin-bottom: 1.4em;
}

.single-content li {
  margin-bottom: 0.4em;
}

/* Style presets (TinyMCE styleselect) */
.single-content .article-lead {
  font-size: 19px;
  font-weight: 600;
  line-height: 1.55;
  color: #0c1a2e;
}

.single-content .article-pullquote {
  font-family: var(--font-display);
  font-size: 21px;
  font-style: italic;
  font-weight: 700;
  color: var(--color-accent);
  border-left: 3px solid var(--color-accent-light);
  padding: 0.5em 0 0.5em 20px;
  margin: 1.6em 0;
  line-height: 1.35;
}

.single-content .article-infobox {
  background: #eaf2fb;
  border-left: 3px solid var(--color-accent);
  padding: 14px 18px;
  font-family: var(--font-ui);
  font-size: 15px;
  line-height: 1.55;
  color: var(--color-primary);
  margin: 1.6em 0;
  border-radius: 0 3px 3px 0;
}

.single-content .article-caption {
  font-family: var(--font-ui);
  font-size: 13px;
  color: #777;
  font-style: italic;
  line-height: 1.4;
}

.share-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid #e0ddd6;
}


.share-btn {
  display: inline-block;
  padding: 7px 14px;
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 2px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  text-decoration: none;
}

.share-copy {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #fff;
  color: var(--color-accent);
  border-color: var(--color-accent);
}
.share-copy .share-icon {
  display: inline-flex;
  align-items: center;
}
.share-copy:hover { background: var(--color-accent); color: #fff; }
.share-copy.copied { background: var(--color-accent); color: #fff; }

.share-linkedin,
.share-instagram {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.share-linkedin {
  background: #fff;
  color: #0a66c2;
  border-color: #0a66c2;
}
.share-linkedin:hover { background: #0a66c2; color: #fff; }

.share-instagram {
  background: #fff;
  color: #c13584;
  border-color: #c13584;
}
.share-instagram:hover { background: #c13584; color: #fff; }

.footer-social {
  display: flex;
  align-items: center;
  gap: 14px;
}

.footer-social-link {
  color: #85B7EB;
  display: flex;
  align-items: center;
  transition: color 0.15s;
}

.footer-social-link:hover { color: #fff; }

.single-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 40px;
}

.single-nav-item {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 14px 16px;
  border: 1px solid #e0ddd6;
  border-radius: 4px;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
}

.single-nav-item:hover {
  background: #f9f8f5;
  border-color: var(--color-accent-light);
}

.single-nav-arrow {
  font-size: 18px;
  font-weight: 400;
  color: var(--color-accent);
  line-height: 1;
}

.single-nav-label {
  font-family: var(--font-ui);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.single-nav-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1.3;
}

.single-nav-next {
  text-align: right;
}

.single-nav-next:only-child {
  grid-column: 2;
}

@media (max-width: 599px) {
  .single-nav-title { display: none; }

  /* Card background matches the gradient so no white bleeds through */
  .card-hero--img { background: var(--color-primary); }

  /* Image in flow, natural proportions */
  .card-hero--img .card-thumbnail-hero {
    position: relative;
    inset: auto;
    width: 100%;
    height: auto;
  }

  /* Card body: text pinned to bottom; gradient covers only the image overlap zone */
  .card-hero--img .card-body {
    flex: 1;
    justify-content: flex-end;
    margin-top: -140px;
    padding-top: 60px;
    background: linear-gradient(
      to bottom,
      transparent 0%,
      rgba(4, 44, 83, 0.75) 30%,
      rgba(4, 44, 83, 0.97) 44%,
      rgba(4, 44, 83, 0.97) 100%
    );
  }

  /* Prevent excerpt from growing; remove auto-margin so flex-end pins all text to the bottom */
  .card-hero--img .card-excerpt { flex: none; }
  .card-hero--img .card-footer  { margin-top: 0; }

  .footer-inner {
    display: grid;
    grid-template-columns: auto auto 1fr;
    grid-template-areas:
      "name logo ."
      "desc desc desc"
      "cols cols cols"
      "bottom bottom bottom";
    row-gap: 8px;
  }
  .footer-name {
    grid-area: name;
    margin-bottom: 0;
  }
  .footer-description {
    grid-area: desc;
    margin-bottom: 12px;
  }
  .footer-cols {
    grid-area: cols;
    margin-bottom: 12px;
  }
  .footer-bottom { grid-area: bottom; }
  .footer-logo {
    grid-area: logo;
    position: static;
    transform: none;
    height: var(--footer-logo-height, 22px);
    align-self: center;
    margin-left: 12px;
  }
}

/* ============================================================
   RELATED ARTICLES
   ============================================================ */
.related-section {
  margin-top: 48px;
  padding-top: 28px;
  border-top: 2px solid #e0ddd6;
}

.related-grid {
  display: flex;
  flex-direction: row;
  width: 100%;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  gap: 12px;
  margin-top: 16px;
  padding-bottom: 4px;
  scrollbar-width: none;
}

.related-grid::-webkit-scrollbar {
  display: none;
}

.related-card {
  background: #fff;
  border-radius: 4px;
  border-top: 3px solid var(--color-accent);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform 0.2s;
  min-height: 180px;
  flex: 0 0 72vw;
  scroll-snap-align: start;
}

.related-card:hover {
  transform: translateY(-2px);
}

.related-card-img {
  width: 100%;
  height: 100px;
  object-fit: cover;
  display: block;
}

.related-card-body {
  padding: 10px 12px 12px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.related-card-title {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: #0c1a2e;
  line-height: 1.3;
  margin-bottom: 6px;
}

.related-card-hook {
  font-family: var(--font-body);
  font-size: 12px;
  color: #555;
  line-height: 1.5;
  flex: 1;
  margin-bottom: 8px;
}

.related-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
}

/* ============================================================
   LEGAL PAGES
   ============================================================ */
.legal-page {
  max-width: 720px;
  margin: 0 auto;
}

.legal-title {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 900;
  color: #0c1a2e;
  margin-bottom: 32px;
  padding-bottom: 16px;
  border-bottom: 2px solid #e0ddd6;
}

.legal-section {
  margin-bottom: 32px;
}

.legal-section h2 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: #0c1a2e;
  margin-bottom: 12px;
}

.legal-section p,
.legal-section li {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: #333;
  margin-bottom: 10px;
}

.legal-section ul {
  padding-left: 1.4em;
  margin-bottom: 10px;
}

.legal-section a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-section a:hover { color: var(--color-primary); }

.legal-content h2 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: #0c1a2e;
  margin: 32px 0 12px;
}

.legal-content h2:first-child { margin-top: 0; }

.legal-content p,
.legal-content li {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: #333;
  margin-bottom: 10px;
}

.legal-content ul,
.legal-content ol {
  padding-left: 1.4em;
  margin-bottom: 10px;
}

.legal-content a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-content a:hover { color: var(--color-primary); }

/* ============================================================
   404
   ============================================================ */
.not-found {
  max-width: 520px;
  margin: 60px auto;
  text-align: center;
  padding: 0 16px;
}

.not-found-code {
  font-family: var(--font-display);
  font-size: 96px;
  font-weight: 900;
  color: #e0ddd6;
  line-height: 1;
  margin-bottom: 8px;
}

.not-found-title {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 700;
  color: #0c1a2e;
  margin-bottom: 12px;
}

.not-found-text {
  font-size: 15px;
  color: #666;
  margin-bottom: 28px;
}

.not-found-search {
  display: flex;
  gap: 6px;
  margin-bottom: 20px;
}

.not-found-search input[type="search"] {
  flex: 1;
  padding: 10px 14px;
  font-family: var(--font-ui);
  font-size: 14px;
  border: 1px solid #ccc;
  border-radius: 2px;
  outline: none;
  color: #1a1a1a;
}

.not-found-search input[type="search"]:focus {
  border-color: var(--color-accent);
}

.not-found-search button {
  padding: 10px 18px;
  background: var(--color-accent);
  color: #fff;
  border: none;
  border-radius: 2px;
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
}

.not-found-search button:hover { background: var(--color-primary); }

.not-found-home {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.not-found-home:hover { color: var(--color-primary); }

/* ============================================================
   SEARCH RESULTS
   ============================================================ */
.no-results {
  font-family: var(--font-body);
  font-size: 16px;
  color: #666;
  padding: 24px 0;
}

/* ============================================================
   AUTORENÜBERSICHT
   ============================================================ */

.author-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin: 32px auto;
  max-width: 1100px;
}

.author-card {
  background: #fff;
  border-radius: 6px;
  border-top: 3px solid var(--color-accent);
  padding: 32px 24px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: transform 0.2s;
}

.author-card:hover {
  transform: translateY(-3px);
}

.author-card-avatar {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--color-accent);
  background: var(--color-accent-pale);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  flex-shrink: 0;
}

.author-card-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.author-card-avatar-initials {
  font-family: var(--font-display);
  font-size: 36px;
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1;
}

.author-card-name {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 10px;
}

.author-card-bio {
  font-family: var(--font-body);
  font-size: 14px;
  color: #555;
  line-height: 1.6;
  margin-bottom: 16px;
  flex-grow: 1;
}

.author-card-meta {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.author-card-stat {
  font-family: var(--font-ui);
  font-size: 13px;
  color: #666;
  background: var(--color-bg);
  padding: 4px 10px;
  border-radius: 3px;
}

.author-card-stat strong {
  color: var(--color-primary);
  font-weight: 600;
}

.author-card-link {
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 600;
  color: var(--color-accent);
  text-decoration: none;
  border: 1.5px solid var(--color-accent);
  padding: 6px 16px;
  border-radius: 3px;
  transition: background 0.15s, color 0.15s;
  display: inline-block;
  margin-top: auto;
}

.author-card-link:hover {
  background: var(--color-accent);
  color: #fff;
}

.section-header-h1 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: var(--color-primary);
  white-space: nowrap;
}

/* ============================================================
   TABLET  ≥ 600px — side cards go side by side
   ============================================================ */
@media (min-width: 600px) {
  .featured-side {
    flex-direction: row;
  }

  .strip-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    overflow-x: visible;
    scroll-snap-type: none;
  }

  .related-card {
    flex: none;
    min-height: 300px;
  }

  .related-card-img {
    height: 160px;
  }

  .related-card-body {
    padding: 14px 16px 16px;
  }

  .related-card-title {
    font-size: 16px;
    margin-bottom: 8px;
  }

  .related-card-hook {
    font-size: 13px;
    margin-bottom: 12px;
  }

  .author-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ============================================================
   TABLET ONLY 600–899px — fix side card proportions
   ============================================================ */
@media (min-width: 600px) and (max-width: 899px) {
  .featured-side .card {
    flex: 1;
    min-width: 0;
  }

  .featured-side .card-thumbnail {
    height: 180px;
    aspect-ratio: unset;
    object-fit: cover;
  }

  .featured-side .card-body {
    flex: 1;
  }

  .featured-side .card-footer {
    margin-top: auto;
    padding-top: 10px;
  }
}

/* ============================================================
   DESKTOP  ≥ 900px — full layout
   ============================================================ */
@media (min-width: 900px) {
  .site-date {
    display: block;
    font-size: 12px;
  }

  .nav-date {
    display: none;
  }

  .masthead {
    padding: 20px 32px 0;
  }

  .site-name {
    font-size: var(--size-header-lg);
  }

  .site-tagline {
    display: block;
  }

  .nav-toggle {
    display: none;
  }

  .nav-top {
    position: absolute;
    right: 0;
    top: 0;
    height: 100%;
    width: auto;
    padding: 0;
  }

  .main-nav ul {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    width: 100%;
    max-width: 700px;
    margin: 0 auto;
    padding-bottom: 0;
  }

  .main-nav ul > li {
    flex: 1;
  }

  .main-nav ul li a {
    font-size: 13px;
    padding: 14px 0;
    text-align: center;
  }

  .main-nav ul li.menu-item-has-children {
    position: relative;
  }

  .sub-menu-toggle {
    display: none;
  }

  .main-nav ul .sub-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    flex-direction: column;
    background: var(--color-primary);
    width: auto;
    min-width: 160px;
    padding: 4px 0;
    z-index: 100;
    border-top: 2px solid var(--color-accent-light);
    border-radius: 0 0 6px 6px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.28);
  }

  .main-nav ul li:hover > .sub-menu {
    display: flex;
  }

  .main-nav ul .sub-menu li a {
    font-size: 13px;
    padding: 9px 20px;
    text-transform: none;
    font-weight: 500;
    letter-spacing: 0.02em;
    color: rgba(255,255,255,0.82);
    border-bottom: none;
    white-space: nowrap;
    transition: background 0.18s, color 0.18s, transform 0.18s;
  }

  .main-nav ul .sub-menu li a:hover {
    background: rgba(255,255,255,0.1);
    color: #fff;
    border-bottom-color: transparent;
    transform: translateX(4px);
  }

  .content-area {
    padding: 40px 24px;
  }

  .section-header h2 {
    font-size: 20px;
  }

  .featured-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    height: calc(100dvh - 280px);
    min-height: 400px;
  }

  .featured-side {
    flex-direction: column;
    gap: 20px;
    height: 100%;
    min-height: 0;
  }

  .featured-side .card {
    flex: 1;
    min-height: 120px;
  }

  /* Image always shows; it flexes into whatever room is left above the
     text, so it never depends on viewport height / display aspect ratio. */
  .featured-side .card-thumbnail {
    display: block;
    flex: 1 1 0;
    aspect-ratio: unset;
    min-height: 72px;
    height: 0;
    object-fit: cover;
  }

  .featured-side .card:has(.card-thumbnail) .card-body {
    flex: none;
  }


  .card-hero {
    min-height: 0;
  }

  .strip-card .card-thumbnail {
    height: 160px;
    object-fit: cover;
    object-position: top;
  }

  .strip-card--no-img .strip-card-body {
    flex: none;
    margin-top: auto;
  }

  .card-body {
    padding: 16px 18px 20px;
  }

  .card-headline-lg { font-size: calc(var(--size-card-title) + 4px); }
  .card-headline-md { font-size: calc(var(--size-card-title) - 4px); }

  .strip-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }

  .author-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .section-divider {
    height: 116px;
  }

  .strip-section {
    padding: 0 0 36px;
  }

  .strip-card-body {
    padding: 14px 16px 16px;
  }

  .single-title {
    font-size: var(--size-title-lg);
  }

  .single-content {
    font-size: var(--size-article-lg);
  }

  .site-footer {
    margin-top: 48px;
    padding: 36px 32px 20px;
  }

  .footer-name {
    font-size: 26px;
    margin-bottom: 8px;
  }

  .footer-description {
    font-size: 14px;
    margin-bottom: 24px;
  }

  .footer-cols {
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 28px;
  }

  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
  }
}

/* ── Article Footer Note ─────────────────────────────────────── */

.article-footer-note {
  color:       var(--article-note-color,      #888888);
  font-family: var(--article-note-font,       'Source Serif 4', serif);
  font-size:   var(--article-note-size,       14px);
  font-style:  var(--article-note-style,      italic);
  text-align:  var(--article-note-align,      left);
  margin-top:  var(--article-note-margin-top, 24px);
  margin-bottom: 0;
  line-height: 1.5;
}
