/*
Theme Name: IT Kernsache
Theme URI: https://it.kernsache.eu
Template: twentytwentyfive
Description: Child Theme für IT Kernsache - Europäische Open-Source-Beratung
Version: 1.0
*/

/* ===== Globale Basis ===== */
:root {
  --ik-blue: #003d99;
  --ik-blue-light: #0055cc;
  --ik-amber: #f5a623;
  --ik-amber-dark: #d4861a;
  --ik-gray-light: #f4f6fb;
  --ik-text: #1a1a2e;
}

body {
  color: var(--ik-text);
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
}

/* ===== Headings ===== */
h1, h2, h3, h4 {
  color: var(--ik-blue);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

/* ===== Hero-Bereich ===== */
.has-base-2-background-color {
  background: linear-gradient(135deg, #f0f5ff 0%, #e8f0fe 100%) !important;
  padding: 60px 40px !important;
  border-radius: 12px;
  margin-bottom: 40px;
}

/* ===== Buttons ===== */
.wp-block-button__link {
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: all 0.2s ease;
}

.has-luminous-vivid-amber-background-color.wp-block-button__link {
  background: var(--ik-amber) !important;
  color: #fff !important;
  border-radius: 6px !important;
  padding: 14px 28px !important;
}
.has-luminous-vivid-amber-background-color.wp-block-button__link:hover {
  background: var(--ik-amber-dark) !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(245,166,35,0.4);
}

.is-style-outline .wp-block-button__link {
  border: 2px solid var(--ik-blue) !important;
  color: var(--ik-blue) !important;
  border-radius: 6px !important;
  padding: 12px 28px !important;
  background: transparent !important;
}
.is-style-outline .wp-block-button__link:hover {
  background: var(--ik-blue) !important;
  color: #fff !important;
}

/* ===== Spalten / Feature-Cards ===== */
.wp-block-columns .wp-block-column {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 24px;
  box-shadow: 0 2px 8px rgba(0,61,153,0.06);
  transition: box-shadow 0.2s ease;
}
.wp-block-columns .wp-block-column:hover {
  box-shadow: 0 6px 20px rgba(0,61,153,0.12);
}
.wp-block-columns .wp-block-column h3 {
  font-size: 1.1rem;
  margin-bottom: 10px;
}

/* ===== Separator ===== */
.wp-block-separator {
  border-color: #d0daf0 !important;
  margin: 40px auto !important;
}

/* ===== Site Header ===== */
.wp-block-site-title a,
.wp-block-site-title {
  color: var(--ik-blue) !important;
  font-weight: 800 !important;
  font-size: 1.4rem !important;
}

/* ===== Navigation ===== */
.wp-block-navigation a {
  color: var(--ik-blue) !important;
  font-weight: 600;
}
.wp-block-navigation a:hover {
  color: var(--ik-amber) !important;
  text-decoration: none;
}

/* ===== Listen auf Leistungsseite ===== */
.wp-block-list li {
  padding: 4px 0;
  line-height: 1.7;
}

/* ===== Footer ===== */
.wp-block-template-part footer {
  background: var(--ik-blue) !important;
  color: #fff !important;
  padding: 30px 40px !important;
}
.wp-block-template-part footer a {
  color: #a0b8e8 !important;
}
.wp-block-template-part footer a:hover {
  color: var(--ik-amber) !important;
}

/* Seitentitel auf Homepage ausblenden */
.page-id-11 .wp-block-post-title,
.page-id-11 h1.entry-title,
.home .wp-block-post-title {
  display: none !important;
}

/* Footer Demo-Navigationen ausblenden */
footer .wp-block-navigation:not(:first-child) {
  display: none !important;
}

/* Professioneller Footer */
.wp-block-template-part[data-type="wp_template_part"] footer,
footer.wp-block-template-part {
  background: #0a1628 !important;
  color: #a0b4d0 !important;
  padding: 40px !important;
}
footer h2 a, footer .wp-block-site-title a {
  color: #ffffff !important;
}
footer p { color: #a0b4d0 !important; }
footer a { color: #a0b4d0 !important; }
footer a:hover { color: #f5a623 !important; }

/* Tagline im Footer schöner */
.wp-block-site-tagline {
  color: #6b8ab0 !important;
  font-size: 0.9rem !important;
}


/* ===== Post Meta Bar ===== */
.ik-post-meta-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: 0.875rem;
  color: #6b7c99;
  padding: 12px 0 24px 0;
  border-bottom: 1px solid #e2e8f0;
  margin-bottom: 28px;
}
.ik-post-meta-bar a { color: #003d99; text-decoration: none; }
.ik-post-meta-bar a:hover { color: #f5a623; }
.ik-post-views { font-weight: 500; }

/* ===== Author Box ===== */
.ik-author-box {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  background: #f4f6fb;
  border: 1px solid #dde3f0;
  border-left: 4px solid #003d99;
  border-radius: 10px;
  padding: 24px;
  margin-top: 48px;
}
.ik-author-avatar { border-radius: 50%; flex-shrink: 0; }
.ik-author-info { display: flex; flex-direction: column; gap: 4px; }
.ik-author-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #6b7c99;
  font-weight: 600;
}
.ik-author-name {
  font-size: 1rem;
  font-weight: 700;
  color: #003d99 !important;
  text-decoration: none;
}
.ik-author-name:hover { color: #f5a623 !important; }
.ik-author-bio {
  font-size: 0.9rem;
  color: #4a5568;
  line-height: 1.6;
  margin: 4px 0 0 0;
}
@media (max-width: 600px) {
  .ik-author-box { flex-direction: column; }
}

/* ===== BLOG KARTEN-LAYOUT ===== */

.ik-blog-main {
  width: 100%;
}

.ik-blog-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 20px 60px;
}

.ik-blog-header {
  text-align: center;
  margin-bottom: 48px;
  padding-bottom: 32px;
  border-bottom: 2px solid #e2e8f0;
}

.ik-blog-title {
  color: #003d99;
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.ik-blog-subtitle {
  color: #6b7c99;
  font-size: 1.05rem;
  max-width: 600px;
  margin: 0 auto;
}

/* Grid */
.ik-blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  margin-bottom: 48px;
}

@media (max-width: 900px) {
  .ik-blog-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 580px) {
  .ik-blog-grid { grid-template-columns: 1fr; }
}

/* Karte */
.ik-blog-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 8px rgba(0,61,153,0.06);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.ik-blog-card:hover {
  box-shadow: 0 8px 24px rgba(0,61,153,0.14);
  transform: translateY(-3px);
}

/* Karten-Bild */
.ik-card-image-link {
  display: block;
  overflow: hidden;
  aspect-ratio: 16/9;
  background: #f0f5ff;
}

.ik-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
  display: block;
}

.ik-blog-card:hover .ik-card-image {
  transform: scale(1.04);
}

.ik-card-image-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #e8f0fe 0%, #f0f5ff 100%);
  aspect-ratio: 16/9;
}

.ik-placeholder-icon {
  font-size: 2.5rem;
  opacity: 0.4;
}

/* Karten-Body */
.ik-card-body {
  padding: 20px 22px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.ik-card-title {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 12px;
  color: #1a1a2e;
}

.ik-card-title a {
  color: #1a1a2e;
  text-decoration: none;
}

.ik-card-title a:hover {
  color: #003d99;
}

/* Meta: Avatar + Author + Views + Datum */
.ik-card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.78rem;
  color: #6b7c99;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #f0f4f8;
}

.ik-card-author {
  display: flex;
  align-items: center;
  gap: 6px;
}

.ik-card-avatar {
  border-radius: 50% !important;
  width: 24px !important;
  height: 24px !important;
  flex-shrink: 0;
}

.ik-card-author a {
  color: #003d99;
  text-decoration: none;
  font-weight: 600;
}

.ik-card-author a:hover { color: #f5a623; }

.ik-card-views {
  display: flex;
  align-items: center;
  gap: 4px;
  color: #6b7c99;
}

.ik-card-date { color: #9aabb9; }

/* Excerpt */
.ik-card-excerpt {
  font-size: 0.875rem;
  color: #4a5568;
  line-height: 1.6;
  flex: 1;
  margin-bottom: 16px;
}

.ik-card-excerpt p { margin: 0; }

/* Mehr Lesen */
.ik-card-readmore {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.875rem;
  font-weight: 700;
  color: #003d99;
  text-decoration: none;
  margin-top: auto;
  transition: color 0.15s ease;
}

.ik-card-readmore:hover { color: #f5a623; }

/* Pagination */
.ik-blog-pagination .nav-links {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
}

.ik-blog-pagination .page-numbers {
  padding: 8px 16px;
  border: 1px solid #d0daf0;
  border-radius: 6px;
  color: #003d99;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
}

.ik-blog-pagination .page-numbers.current {
  background: #003d99;
  color: #fff;
  border-color: #003d99;
}

.ik-blog-pagination .page-numbers:hover:not(.current) {
  background: #f0f5ff;
}

/* Mehr lesen - Screen-Reader-Text ausblenden */
.wp-block-read-more a :last-child { display: none; }

/* Query block Grid 3 Spalten erzwingen */
.wp-block-post-template.is-flex-container.columns-3 {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 28px !important;
  list-style: none !important;
  padding: 0 !important;
  margin: 0 0 48px !important;
}
@media (max-width: 900px) {
  .wp-block-post-template.is-flex-container.columns-3 {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}
@media (max-width: 580px) {
  .wp-block-post-template.is-flex-container.columns-3 {
    grid-template-columns: 1fr !important;
  }
}
/* Karte volle Höhe */
.wp-block-post-template .ik-blog-card {
  height: 100%;
  display: flex;
  flex-direction: column;
}
/* Featured Image in Karte */
.wp-block-post-featured-image a,
.wp-block-post-featured-image {
  display: block;
}
.wp-block-post-featured-image img {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  border-radius: 12px 12px 0 0 !important;
  display: block;
  transition: transform 0.3s ease;
}
.ik-blog-card:hover .wp-block-post-featured-image img {
  transform: scale(1.04);
}
/* Card-Meta Zeile */
.ik-card-meta .wp-block-post-author-name,
.ik-card-meta .wp-block-post-date,
.ik-card-meta .wp-block-avatar img {
  font-size: 0.78rem !important;
}
.ik-card-meta .wp-block-avatar img {
  border-radius: 50% !important;
  width: 24px !important;
  height: 24px !important;
}
