/* ================================================================
   style.css  –  kotsch.tech
   Basis-CSS mit allen nötigen Klassen. Hier eigenes Design rein.
   ================================================================ */

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  line-height: 1.7;
  color: #1e293b;
  background: #ffffff;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }

/* ── Site Header ── */
.site-header {
  border-bottom: 1px solid #e2e8f0;
  padding: 0 1rem;
  position: sticky;
  top: 0;
  background: #fff;
  z-index: 100;
}
.site-nav {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 2rem;
  height: 60px;
}
.site-nav__logo { font-weight: 800; font-size: 1.2rem; }
.site-nav__links {
  list-style: none;
  display: flex;
  gap: 1rem;
  margin-left: auto;
}
.site-nav__links a { font-size: 0.9rem; color: #64748b; }
.site-nav__links a:hover { color: #1e293b; }

/* ── Page Layouts ── */
.page-layout {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2.5rem 1rem;
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 2.5rem;
  align-items: start;
}
.page-main--full {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2.5rem 1rem;
}

/* ── Article ── */
.article__header { margin-bottom: 2rem; }

.article__hero {
  margin: 0 0 2rem;
  border-radius: 8px;
  overflow: hidden;
}
.article__hero img {
  width: 100%;
  height: auto;
  max-height: 480px;
  object-fit: cover;
  display: block;
}
.article__body figure {
  margin: 1.5rem 0;
  border-radius: 6px;
  overflow: hidden;
}
.article__body figure img {
  width: 100%;
  height: auto;
  display: block;
}
.article__body a {
  color: #2563eb;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.article__body a:hover { color: #1d4ed8; }

.article__breadcrumb {
  font-size: 0.85rem;
  color: #94a3b8;
  margin-bottom: 0.75rem;
}
.article__breadcrumb a { color: #94a3b8; }
.article__breadcrumb a:hover { color: #1e293b; }

.article__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1rem;
}
.article__tag {
  font-size: 0.75rem;
  padding: 0.25rem 0.75rem;
  background: #f1f5f9;
  border-radius: 999px;
  color: #64748b;
}

.article__title {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

.article__meta {
  font-size: 0.85rem;
  color: #94a3b8;
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #e2e8f0;
}

.article__body { font-size: 1.05rem; color: #334155; }
.article__body h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin: 2.5rem 0 0.75rem;
  color: #0f172a;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #f1f5f9;
}
.article__body h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 1.75rem 0 0.5rem;
  color: #0f172a;
}
.article__body p { margin-bottom: 1.1rem; }
.article__body ul,
.article__body ol { padding-left: 1.5rem; margin-bottom: 1.1rem; }
.article__body li { margin-bottom: 0.35rem; }
.article__body strong { color: #0f172a; font-weight: 600; }
.article__body em { font-style: italic; }
.article__body blockquote {
  border-left: 4px solid #e2e8f0;
  padding: 0.75rem 1.25rem;
  margin: 1.5rem 0;
  color: #64748b;
  font-style: italic;
  background: #f8fafc;
  border-radius: 0 4px 4px 0;
}
.article__body code {
  background: #f1f5f9;
  padding: 0.1em 0.45em;
  border-radius: 3px;
  font-size: 0.875em;
  font-family: 'Consolas', 'Monaco', monospace;
  color: #0f172a;
}

/* ── Sidebar ── */
.sidebar { position: sticky; top: 76px; }

/* ── Article Grid (Index) ── */
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

.card {
  display: flex;
  flex-direction: column;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.25rem;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.card:hover {
  border-color: #94a3b8;
  box-shadow: 0 4px 16px rgba(0,0,0,.06);
}
.card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.6rem;
}
.card__tag {
  font-size: 0.7rem;
  padding: 0.2rem 0.6rem;
  background: #f1f5f9;
  border-radius: 999px;
  color: #64748b;
}
.card__title {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 0.5rem;
  color: #0f172a;
}
.card__desc {
  font-size: 0.875rem;
  color: #64748b;
  flex: 1;
  margin-bottom: 1rem;
  line-height: 1.55;
}
.card__meta {
  font-size: 0.8rem;
  color: #94a3b8;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px solid #f1f5f9;
}
.card__read-more { font-weight: 600; color: #475569; }

/* ── Ads ── */
.ad {
  text-align: center;
  padding: 0.5rem 1rem;
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f8fafc;
  border-top: 1px solid #f1f5f9;
  border-bottom: 1px solid #f1f5f9;
}
.ad--sidebar {
  background: transparent;
  border: none;
  min-height: 250px;
  padding: 0;
}

/* ── Footer ── */
.site-footer {
  border-top: 1px solid #e2e8f0;
  padding: 2.5rem 1rem;
  margin-top: 4rem;
  background: #f8fafc;
}
.site-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}
.site-footer__brand { font-weight: 700; font-size: 1rem; }
.site-footer__links { display: flex; gap: 1.5rem; }
.site-footer__links a { font-size: 0.875rem; color: #64748b; }
.site-footer__links a:hover { color: #1e293b; }
.site-footer__copy {
  text-align: center;
  color: #94a3b8;
  font-size: 0.8rem;
  margin-top: 1.25rem;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 1rem;
}

/* ── Responsive ── */
@media (max-width: 900px) {
  .page-layout { grid-template-columns: 1fr; }
  .sidebar { position: static; }
}
@media (max-width: 600px) {
  .article-grid { grid-template-columns: 1fr; }
  .site-nav__links { display: none; }
  .site-footer__inner { flex-direction: column; align-items: flex-start; }
}
