/**
 * yt_aicommerceoptimizer — Frontend-Design für modulgenerierten Content
 * (Ratgeber-Artikel, Kategorie-/Marken-Texte). Geladen per Hook auf den Content-Seiten.
 * Externe Datei statt Inline-<style>, weil PrestaShop <style> aus CMS-Inhalten filtert.
 * Scoped auf die Marker-Klassen -> kein Leaken ins restliche Theme. Developer: Andreas Lerch
 */
.ytai-article, .ytai-cat-content, .ytai-brand-content { line-height: 1.65; }

.ytai-article h2, .ytai-cat-content h2, .ytai-brand-content h2 {
  margin: 1.7em 0 .55em; padding-bottom: .25em; border-bottom: 2px solid #e2e8f0;
}
.ytai-article h3, .ytai-cat-content h3, .ytai-brand-content h3 { margin: 1.35em 0 .4em; }
.ytai-article p, .ytai-cat-content p, .ytai-brand-content p { margin: 0 0 1em; }
.ytai-article ul, .ytai-article ol,
.ytai-cat-content ul, .ytai-cat-content ol,
.ytai-brand-content ul, .ytai-brand-content ol { margin: 0 0 1.1em 1.3em; }
.ytai-article li, .ytai-cat-content li, .ytai-brand-content li { margin: .25em 0; }

/* Vergleichs-/Übersichtstabellen */
.ytai-article table, .ytai-cat-content table, .ytai-brand-content table {
  width: 100%; border-collapse: collapse; margin: 1.3em 0; font-size: .96em;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
}
.ytai-article th, .ytai-article td,
.ytai-cat-content th, .ytai-cat-content td,
.ytai-brand-content th, .ytai-brand-content td {
  padding: 11px 15px; border: 1px solid #e2e8f0; text-align: left; vertical-align: top; line-height: 1.5;
}
.ytai-article thead th, .ytai-cat-content thead th, .ytai-brand-content thead th {
  background: #0d9488; color: #fff; font-weight: 600; border-color: #0d9488;
}
.ytai-article tbody tr:nth-child(even),
.ytai-cat-content tbody tr:nth-child(even),
.ytai-brand-content tbody tr:nth-child(even) { background: #f7fafc; }
.ytai-article tbody th, .ytai-article tbody td:first-child,
.ytai-cat-content tbody th, .ytai-cat-content tbody td:first-child,
.ytai-brand-content tbody th, .ytai-brand-content tbody td:first-child {
  font-weight: 600; background: #eef2f7; white-space: nowrap;
}

/* FAQ-Akkordeon (gemeinsame Klassen) */
.ytai-cat-faq, .ytai-article-faq { margin-top: 2.2em; }
.ytai-cat-faq > h2, .ytai-article-faq > h2 { margin-bottom: .6em; }
.ytai-faq-item {
  border: 1px solid #e2e8f0; border-radius: 8px; margin: .5em 0; padding: .1em .95em; background: #fff;
}
.ytai-faq-item summary { cursor: pointer; font-weight: 600; padding: .7em 0; list-style: none; }
.ytai-faq-item summary::-webkit-details-marker { display: none; }
.ytai-faq-item summary:before {
  content: "\002B"; display: inline-block; width: 1.1em; color: #0d9488; font-weight: 700;
}
.ytai-faq-item[open] summary:before { content: "\2212"; }
.ytai-faq-item .ytai-faq-a { padding: .1em 0 .9em 1.1em; color: #334155; }

/* „Passende Produkte, Marken & Behandlungen"-Block (statisch, unter dem Artikel) */
.ytai-article-related { margin-top: 2.4em; border-top: 2px solid #e2e8f0; padding-top: 1.2em; }
.ytai-article-related h2 { border: 0; margin: 0 0 .6em; }
.ytai-article-related h3 { margin: 1em 0 .5em; font-size: 1.05em; }
.ytai-rel-group { margin-bottom: 1.1em; }
.ytai-rel-cards { display: flex; flex-wrap: wrap; gap: 12px; }
.ytai-rel-card {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  width: 132px; padding: 12px; border: 1px solid #e2e8f0; border-radius: 10px;
  text-decoration: none; color: #1f2937; background: #fff; text-align: center;
  transition: box-shadow .15s, border-color .15s;
}
.ytai-rel-card:hover { border-color: #0d9488; box-shadow: 0 2px 8px rgba(13,148,136,.15); }
.ytai-rel-card img { max-width: 100%; max-height: 64px; object-fit: contain; }
.ytai-rel-card span { font-size: .85em; font-weight: 600; line-height: 1.25; }
.ytai-rel-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ytai-rel-chip {
  display: inline-block; padding: 6px 14px; border-radius: 16px; background: #eef2f7;
  color: #0d9488; font-weight: 600; font-size: .9em; text-decoration: none; border: 1px solid #dfe7ef;
}
.ytai-rel-chip:hover { background: #0d9488; color: #fff; }

/* Ratgeber-Übersicht (Hub-Seite) + Rückverlinkung Kategorie → Ratgeber */
.ytai-cat-articles { margin-top: 2.2em; border-top: 2px solid #e2e8f0; padding-top: 1.2em; }
.ytai-cat-articles > h2 { border: 0; margin: 0 0 .7em; }
.ytai-ratgeber-hub .ytai-hub-list, .ytai-cat-articles .ytai-hub-list { display: grid; gap: 12px; }
.ytai-hub-item {
  display: block; padding: 14px 16px; border: 1px solid #e2e8f0; border-radius: 10px;
  text-decoration: none; background: #fff; color: #1f2937;
  transition: box-shadow .15s, border-color .15s;
}
.ytai-hub-item:hover { border-color: #0d9488; box-shadow: 0 2px 8px rgba(13,148,136,.15); }
.ytai-hub-item strong { display: block; color: #0d9488; font-size: 1.05em; margin-bottom: 3px; }
.ytai-hub-item span { display: block; font-size: .9em; color: #475569; line-height: 1.45; }

/* Responsive: Tabelle stackt auf schmalen Screens */
@media (max-width: 640px) {
  .ytai-article table, .ytai-article thead, .ytai-article tbody, .ytai-article th, .ytai-article td, .ytai-article tr,
  .ytai-cat-content table, .ytai-cat-content thead, .ytai-cat-content tbody, .ytai-cat-content th, .ytai-cat-content td, .ytai-cat-content tr,
  .ytai-brand-content table, .ytai-brand-content thead, .ytai-brand-content tbody, .ytai-brand-content th, .ytai-brand-content td, .ytai-brand-content tr { display: block; }
  .ytai-article thead, .ytai-cat-content thead, .ytai-brand-content thead { display: none; }
  .ytai-article tbody td:first-child, .ytai-cat-content tbody td:first-child, .ytai-brand-content tbody td:first-child {
    white-space: normal; background: #0d9488; color: #fff;
  }
}
