/* ============================================================
   content.css  -  SDILENE styly obsahu
   Tento soubor se nacita JAK na webu (kontejner .rte),
   TAK v TinyMCE editoru (body_class="rte"), aby WYSIWYG
   presne odpovidal vyslednemu zobrazeni.
   ============================================================ */

:root {
  --eko-red: #d11f26;
  --eko-red-dark: #a3161c;
  --eko-dark: #1f2429;
  --eko-darker: #15191d;
  --eko-gray: #6b7177;
  --eko-light: #f4f6f7;
  --eko-border: #e3e6e9;
  --eko-font: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --eko-heading-font: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* ---- Obsahovy kontejner (clanky, stranky, aktuality) ---- */
.rte {
  font-family: var(--eko-font);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: #2b3035;
  word-wrap: break-word;
}

.rte > *:first-child { margin-top: 0; }
.rte > *:last-child { margin-bottom: 0; }

.rte h1, .rte h2, .rte h3, .rte h4, .rte h5, .rte h6 {
  font-family: var(--eko-heading-font);
  font-weight: 700;
  line-height: 1.2;
  color: var(--eko-dark);
  margin: 1.8rem 0 0.9rem;
}
.rte h1 { font-size: 2.1rem; }
.rte h2 {
  font-size: 1.7rem;
  padding-bottom: .4rem;
  position: relative;
}
.rte h2::after {
  content: "";
  display: block;
  width: 56px;
  height: 3px;
  background: var(--eko-red);
  margin-top: .55rem;
  border-radius: 2px;
}
.rte h3 { font-size: 1.35rem; }
.rte h4 { font-size: 1.15rem; }

.rte p { margin: 0 0 1.1rem; }

.rte a {
  color: var(--eko-red);
  text-decoration: none;
  border-bottom: 1px solid rgba(209, 31, 38, .35);
  transition: color .15s, border-color .15s;
}
.rte a:hover { color: var(--eko-red-dark); border-color: var(--eko-red-dark); }

.rte ul, .rte ol { margin: 0 0 1.1rem 1.25rem; padding-left: .75rem; }
.rte li { margin-bottom: .4rem; }

.rte ul.checklist { list-style: none; margin-left: 0; padding-left: 0; }
.rte ul.checklist li {
  position: relative;
  padding-left: 1.9rem;
  margin-bottom: .6rem;
}
.rte ul.checklist li::before {
  content: "\2714";
  position: absolute;
  left: 0;
  top: .05rem;
  color: var(--eko-red);
  font-weight: 700;
}

.rte blockquote {
  border-left: 4px solid var(--eko-red);
  background: var(--eko-light);
  margin: 1.4rem 0;
  padding: 1rem 1.25rem;
  color: #41474d;
  font-style: italic;
}

.rte img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}
.rte figure { margin: 1.4rem 0; }
.rte figure img { width: 100%; }
.rte figcaption { font-size: .9rem; color: var(--eko-gray); margin-top: .5rem; text-align: center; }

.rte table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.4rem 0;
  font-size: .98rem;
}
.rte table th, .rte table td {
  border: 1px solid var(--eko-border);
  padding: .65rem .85rem;
  text-align: left;
  vertical-align: top;
}
.rte table th { background: var(--eko-dark); color: #fff; font-weight: 600; }
.rte table tr:nth-child(even) td { background: #fafbfc; }

.rte hr { border: 0; border-top: 1px solid var(--eko-border); margin: 2rem 0; }

/* Tlacitka v obsahu (sdileno s frontendem) */
.rte .btn, .rte a.btn {
  display: inline-block;
  border-bottom: 0;
  font-weight: 600;
}
.rte .btn-eko {
  background: var(--eko-red);
  color: #fff;
  padding: .6rem 1.4rem;
  border-radius: 6px;
}
.rte .btn-eko:hover { background: var(--eko-red-dark); color: #fff; }

/* Pomocne "lead" odstavce */
.rte .lead { font-size: 1.2rem; color: #41474d; }

/* Karty vykupovanych materialu (barevne kovy) */
.rte .kovy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1rem;
  margin: 1.2rem 0 1.6rem;
}
.rte .kovy-card {
  border: 1px solid var(--eko-border);
  border-radius: 10px;
  padding: 1rem 1.1rem .6rem;
  background: #fff;
  box-shadow: 0 4px 14px rgba(0,0,0,.04);
}
.rte .kovy-card h4 {
  margin: 0 0 .6rem;
  padding-bottom: .4rem;
  border-bottom: 2px solid var(--eko-red);
  font-size: 1.05rem;
  color: var(--eko-dark);
}
.rte .kovy-card ul { list-style: none; margin: 0; padding: 0; }
.rte .kovy-card li {
  position: relative;
  padding-left: 1.15rem;
  margin-bottom: .35rem;
  font-size: .95rem;
}
.rte .kovy-card li::before {
  content: "\2013";
  position: absolute;
  left: 0;
  color: var(--eko-red);
}

/* Dokumenty / osvedceni / certifikaty ke stazeni */
.doc-list { list-style: none; margin: 0; padding: 0; }
.doc-list li { margin-bottom: .6rem; }
.doc-list a {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  padding: .55rem .9rem;
  border: 1px solid var(--eko-border);
  border-radius: 8px;
  background: #fff;
  color: var(--eko-dark);
  text-decoration: none;
  font-weight: 600;
  transition: border-color .15s, color .15s, background .15s;
}
.doc-list a:hover { border-color: var(--eko-red); color: var(--eko-red); background: #fff; }
.doc-list a i { color: var(--eko-red); font-size: 1.25rem; }

/* Kompaktni inline fotogalerie v textu */
.rte-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: .5rem;
  margin: 1.25rem 0 1.5rem;
}
.rte-gallery a { display: block; overflow: hidden; border-radius: 8px; line-height: 0; }
.rte-gallery img {
  width: 100%;
  height: 84px;
  object-fit: cover;
  border: 1px solid var(--eko-border);
  border-radius: 8px;
}
