/*
 * Active A – TYPO3 Theme
 * Editorial-Style nach Screenshot
 */

/* ─────────────────────────────────────────────
   Design Tokens
   ───────────────────────────────────────────── */
:root {
  --color-primary:      #1a3366;
  --color-primary-dark: #0f2040;
  --color-accent:       #ffc200;
  --color-accent-hover: #e6af00;
  --color-text:         #1a1a1a;
  --color-text-light:   #666;
  --color-bg:           #ffffff;
  --color-bg-subtle:    #f7f7f7;
  --color-border:       #e0e0e0;

  --font-sans:   'Inter', 'Segoe UI', Arial, sans-serif;
  --font-serif:  'Lora', Georgia, 'Times New Roman', serif;

  --font-size-base: 18px;
  --line-height:    1.8;

  --max-width:     1240px;
  --content-width: 740px;

  --sp-xs: .5rem;
  --sp-sm: 1rem;
  --sp-md: 1.75rem;
  --sp-lg: 3rem;
  --radius: 6px;
}

/* ─────────────────────────────────────────────
   Reset
   ───────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html  { font-size: var(--font-size-base); scroll-behavior: smooth; }
body  {
  font-family: var(--font-serif);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: var(--line-height);
  -webkit-font-smoothing: antialiased;
}
img  { max-width: 100%; height: auto; display: block; }
a    { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ─────────────────────────────────────────────
   Header mit Logo
   ───────────────────────────────────────────── */
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--color-border);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
}
.site-logo-link {
  display: block;
  text-decoration: none !important;
}
.site-logo-img {
  height: 44px;
  width: auto;
}
.header-nav {
  font-family: var(--font-sans);
  font-size: .9rem;
}
.header-nav a {
  color: var(--color-primary);
  text-decoration: none;
  margin-left: 1.5rem;
  font-weight: 500;
}
.header-nav a:hover {
  color: var(--color-accent-hover);
}
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: var(--sp-md);
  padding-right: var(--sp-md);
}

/* ─────────────────────────────────────────────
   Post Hero: Bild links / Titel + Intro rechts
   ───────────────────────────────────────────── */
.post-hero {
  overflow: hidden;
}
.post-hero > .frame {
  display: block;
}

/* Das intro-layout wird zum Grid mit schmaleren Spalten */
.post-intro-layout {
  display: grid !important;
  grid-template-columns: 55% 45%;
  min-height: 480px;
  max-height: 580px;
  max-width: var(--max-width);
  margin: 0 auto;
}

/* Abstand zwischen Hero und Body-Text */
.post-hero {
  margin-bottom: var(--sp-lg);
}

/* Bild: linke Spalte, volle Höhe */
.post-intro-image {
  overflow: hidden;
}
.post-intro-image p {
  height: 100%;
  margin: 0;
}
.post-intro-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  border-radius: 0 !important;
  margin: 0 !important;
}
.post-intro-image .img-caption {
  display: none;
}

/* Rechte Spalte: Titel + Intro zusammen */
.post-intro-text {
  padding: 2.5rem 3.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-left: 1px solid var(--color-border);
}

/* Titel-Block (wird per JS in .post-intro-text verschoben) */
.post-hero__text {
  margin-bottom: 1.25rem;
}

/* Datum */
.post-meta__date {
  font-family: var(--font-sans);
  font-size: .82rem;
  color: var(--color-text-light);
  font-weight: 400;
  display: block;
  margin-bottom: .75rem;
}

/* Artikel-Titel */
.post-title {
  font-family: var(--font-serif);
  font-size: clamp(1.7rem, 2.8vw, 2.4rem);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-text);
  margin: 0;
}

/* Intro-Text Styling */
.post-intro-text .intro {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.65;
  color: var(--color-text);
  margin: 0;
}

/* Social Share (innerhalb Content-Elemente) */
.post-share {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin-bottom: 1rem;
}
.post-share__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--color-bg-subtle);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  transition: background .15s, color .15s;
  text-decoration: none !important;
}
.post-share__btn:hover {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}
.post-share__label {
  font-family: var(--font-sans);
  font-size: .82rem;
  color: var(--color-text-light);
  margin-left: .25rem;
}

/* ─────────────────────────────────────────────
   Artikel-Body (zentriert, schmale Spalte)
   ───────────────────────────────────────────── */
.post-body {
  padding: var(--sp-lg) var(--sp-md);
}
.post-body__inner {
  max-width: var(--content-width);
  margin: 0 auto;
}

/* ─────────────────────────────────────────────
   Typografie im Body
   ───────────────────────────────────────────── */
.post-body__inner h2,
.post-body__inner h3,
.post-body__inner h4 {
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--color-text);
  line-height: 1.3;
  margin-top: 2.25rem;
  margin-bottom: .75rem;
}
.post-body__inner h2 { font-size: 1.55rem; }
.post-body__inner h3 { font-size: 1.25rem; }
.post-body__inner h4 { font-size: 1.05rem; }

.post-body__inner p {
  margin-bottom: 1.25rem;
  font-size: 1rem;
  line-height: var(--line-height);
}
.post-body__inner ul,
.post-body__inner ol {
  padding-left: 1.5rem;
  margin-bottom: 1.25rem;
}
.post-body__inner li { margin-bottom: .4rem; }

.post-body__inner strong {
  font-weight: 700;
  color: var(--color-text);
}
.post-body__inner em { font-style: italic; }

.post-body__inner img {
  width: 100%;
  border-radius: var(--radius);
  margin: var(--sp-md) 0;
}

.post-body__inner a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* TYPO3 fluid_styled_content */
.frame-type-text,
.frame-type-textmedia,
.frame-type-bullets,
.frame-type-table {
  margin-bottom: var(--sp-sm);
}
.ce-bodytext { line-height: var(--line-height); }

/* ─────────────────────────────────────────────
   Buttons
   ───────────────────────────────────────────── */
.btn {
  display: inline-block;
  padding: .7rem 1.6rem;
  border-radius: var(--radius);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: .9rem;
  cursor: pointer;
  transition: background .2s, transform .1s;
  border: 2px solid transparent;
  text-decoration: none !important;
}
.btn-primary { background: var(--color-accent); color: var(--color-primary); }
.btn-primary:hover { background: var(--color-accent-hover); transform: translateY(-1px); }
.btn-outline  { border-color: var(--color-accent); color: var(--color-primary); background: transparent; }
.btn-outline:hover { background: var(--color-accent); color: var(--color-primary); }

/* ─────────────────────────────────────────────
   Footer
   ───────────────────────────────────────────── */
.site-footer {
  background: #fff;
  border-top: 1px solid var(--color-border);
  color: var(--color-text-light);
  padding: 1.5rem var(--sp-md);
  font-family: var(--font-sans);
  font-size: .82rem;
  margin-top: var(--sp-lg);
}
.site-footer a { color: var(--color-text-light); text-decoration: none; }
.site-footer a:hover { color: var(--color-primary); text-decoration: underline; }
.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: .75rem;
}
.footer-sep {
  color: var(--color-border);
}

/* ─────────────────────────────────────────────
   Responsive
   ───────────────────────────────────────────── */
@media (max-width: 900px) {
  .post-intro-layout {
    grid-template-columns: 1fr !important;
    min-height: auto;
    max-height: none;
  }
  .post-intro-image {
    max-height: 320px;
  }
  .post-intro-text {
    padding: 1.5rem;
  }
}
@media (max-width: 480px) {
  :root { --font-size-base: 16px; }
  .post-intro-image { max-height: 240px; }
}
