/* Custom Scrollbar */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: #F4F4F2; }
::-webkit-scrollbar-thumb { background: #CFCFCF; border-radius: 0; }
::-webkit-scrollbar-thumb:hover { background: #0F0F0F; }

/* Reveal on Scroll */
.reveal { opacity: 0; transform: translateY(30px); transition: all 0.8s ease-out; }
.reveal.active { opacity: 1; transform: translateY(0); }

/* Vízszintes görgetősáv elrejtése (mobil swipe-carouselhez) — Tailwindben nincs alap utility */
.scrollbar-none { -ms-overflow-style: none; scrollbar-width: none; }
.scrollbar-none::-webkit-scrollbar { display: none; }

/* Text resizer — a cikktörzs (.prose) alap betűméretét skálázza 3 fokozatban.
   A .prose belső méretei em-alapúak, így a címek/idézetek arányosan nőnek.
   Az osztály a <html>-en van (site.js + head anti-FOUC), localStorage-ban megjegyezve. */
.reading-size-1 .prose { font-size: 1.25rem; }
.reading-size-2 .prose { font-size: 1.4375rem; }
/* Aktív fokozat gombja */
[data-text-size][aria-pressed="true"] {
  background-color: #0F0F0F;
  color: #ffffff;
  border-color: #0F0F0F;
}

/* Highlight underline effect */
.highlight-text {
  background: linear-gradient(120deg, #ECECEC 0%, #ECECEC 100%);
  background-repeat: no-repeat; background-size: 100% 0.4em; background-position: 0 88%;
  transition: background-size 0.25s ease-in;
}
.highlight-text:hover { background-size: 100% 88%; }

/* FAQ details animation helpers */
details > summary { list-style: none; }
details > summary::-webkit-details-marker { display: none; }
details[open] summary ~ * { animation: sweep .5s ease-in-out; }
@keyframes sweep { 0% {opacity: 0; transform: translateY(-10px)} 100% {opacity: 1; transform: translateY(0)} }
.rotate-icon { transition: transform 0.3s ease; }
details[open] .rotate-icon { transform: rotate(180deg); }

/* FAQ accordion (hcms-faq — engine-generált GYIK blokk) */
.hcms-faq { border-top: 2px solid #0F0F0F; border-bottom: 2px solid #0F0F0F; margin: 1.5rem 0; }
.hcms-faq details + details { border-top: 1px solid #E4E4E4; }
.hcms-faq__q {
  display: flex; align-items: center; justify-content: space-between; gap: 0.75rem;
  padding: 1rem 0; cursor: pointer; font-weight: 600; color: #0F0F0F;
  transition: color 0.15s ease;
}
.hcms-faq__q:hover { color: #565656; }
.hcms-faq__icon {
  flex: 0 0 auto; width: 0.5rem; height: 0.5rem;
  border-right: 2px solid #0F0F0F; border-bottom: 2px solid #0F0F0F;
  transform: rotate(45deg); transition: transform 0.3s ease;
}
details[open] > .hcms-faq__q .hcms-faq__icon { transform: rotate(-135deg); }
.hcms-faq__a { padding: 0 0 1rem; color: #565656; }
.hcms-faq__a p { margin: 0 0 0.75rem; }
.hcms-faq__a p:last-child { margin-bottom: 0; }

/* Blockquote styling */
.quote {
  border-left: 4px solid #0F0F0F;
  background-color: #F4F4F2;
  padding: 1rem 1.5rem;
  margin: 1.5rem 0;
  font-style: italic;
  color: #262626;
  line-height: 1.6;
}
.quote p { margin: 0; }

/* Code block styling */
pre {
  background-color: #1e1e1e;
  color: #d4d4d4;
  padding: 1.25rem;
  border-radius: 8px;
  overflow-x: auto;
  margin: 1.5rem 0;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.9rem;
  line-height: 1.5;
}
pre code {
  background: none;
  padding: 0;
  color: inherit;
}
/* A sablonok prose-wrapperén lévő prose-code:* utility (sage-tint háttér + zöld szöveg)
   a <pre>-n belüli code-ra is rászivárog. Itt felülírjuk: a kódblokkban a code legyen
   átlátszó hátterű + világos (a pre öröklött színe). Az inline-kód pillek érintetlenek. */
.prose pre code {
  background-color: transparent;
  color: inherit;
  padding: 0;
}

/* Inline code */
code {
  background-color: #F0F0F0;
  color: #0F0F0F;
  padding: 0.2rem 0.4rem;
  border-radius: 3px;
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.9em;
}

/* Highlighted text (mark) */
mark {
  background-color: #fef08a;
  color: #000;
  padding: 0.1rem 0.2rem;
  border-radius: 2px;
}

/* Strikethrough */
del {
  text-decoration: line-through;
  opacity: 0.7;
}

/* Széles táblázatok a cikktörzsben — vízszintesen görgethetők, hogy ne folyjanak túl
   (a WordPress-importált <table class="has-fixed-layout"> is, ami nem .md-table). */
.prose table {
  display: block;
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.prose table.has-fixed-layout {
  table-layout: auto;
}

/* Markdown table styling */
.md-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
  font-size: 0.95rem;
  overflow-x: auto;
  display: block;
}
.md-table thead,
.prose .md-table thead {
  background-color: #1f2937 !important;
  color: #ffffff !important;
}
.md-table th,
.prose .md-table th {
  padding: 0.75rem 1rem;
  text-align: left;
  font-weight: 600;
  border: 1px solid #374151;
  color: #ffffff !important;
}
.md-table tbody tr {
  border-bottom: 1px solid #e5e7eb;
}
.md-table tbody tr:nth-child(even) {
  background-color: #f9fafb;
}
.md-table tbody tr:hover {
  background-color: #f3f4f6;
}
.md-table td {
  padding: 0.75rem 1rem;
  border: 1px solid #e5e7eb;
}

/* List styling with visible bullets */
ul {
  list-style-type: disc !important;
  padding-left: 2rem !important;
  margin: 1rem 0 !important;
}
ul li {
  display: list-item !important;
  margin: 0.5rem 0 !important;
  line-height: 1.6 !important;
}

/* Ordered list styling */
ol {
  list-style-type: decimal !important;
  padding-left: 2rem !important;
  margin: 1rem 0 !important;
}
ol li {
  display: list-item !important;
  margin: 0.5rem 0 !important;
  line-height: 1.6 !important;
}

/* Learning-path component renders its own number badges and uses a flex/grid
   layout — opt it out of the global markdown list styling above (decimal
   markers, indent, list-item display) which would otherwise duplicate the
   numbering and break the badge-beside-text layout. */
.learning-path ol,
.learning-path ul {
  list-style: none !important;
  padding-left: 0 !important;
  margin: 0 !important;
}
.learning-path li {
  display: flex !important;
  margin: 0 !important;
}

/* Plain list opt-out: hardcoded theme lists (pl. nyitóoldali hírek-ticker), amelyek
   ki akarnak lépni a fenti globális markdown ul/li stílus (disc marker, behúzás,
   li-margó, list-item display) alól. A saját Tailwind-osztályaikkal formázódnak. */
ul.list-plain {
  list-style: none !important;
  padding-left: 0 !important;
  margin: 0 !important;
}
ul.list-plain li {
  display: block !important;
  margin: 0 !important;
  line-height: normal !important;
}

/* Image figure with caption */
.img-figure {
  margin: 1.5rem 0;
  text-align: center;
}
.img-figure img {
  width: auto;
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}
.img-figure figcaption {
  margin-top: 0.5rem;
  font-size: 0.9rem;
  color: #6b7280;
  font-style: italic;
}

/* Global anchor offset so fixed nav won't cover targets */
:target {
  scroll-margin-top: 96px;
}

/* Content links styling - for internal auto-linked and regular links.
   Newspaper stílus: fekete szöveg, fekete aláhúzás, nincs kiemelő háttér. */
.prose a,
.prose-slate a {
  color: #0F0F0F;
  text-decoration: underline;
  text-decoration-color: #0F0F0F;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: all 0.2s ease;
}

.prose a:hover,
.prose-slate a:hover {
  text-decoration-thickness: 2px;
  background-color: #F0F0F0;
}
/* Callout styling (Obsidian-style) */
.callout {
  border-left: 4px solid;
  border-radius: 6px;
  padding: 1rem 1.25rem;
  margin: 1.5rem 0;
  background-color: #f8fafc;
}

.callout-title {
  font-weight: 600;
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.callout-icon {
  font-size: 1.2rem;
}

.callout-content {
  margin-top: 0.75rem;
}

.callout-content p:first-child {
  margin-top: 0;
}

.callout-content p:last-child {
  margin-bottom: 0;
}

/* Callout type specific colors */
.callout-note {
  border-left-color: #3b82f6;
  background-color: #eff6ff;
}

.callout-tip {
  border-left-color: #10b981;
  background-color: #f0fdf4;
}

.callout-info {
  border-left-color: #06b6d4;
  background-color: #ecfeff;
}

.callout-todo {
  border-left-color: #8b5cf6;
  background-color: #f5f3ff;
}

.callout-success {
  border-left-color: #22c55e;
  background-color: #f0fdf4;
}

.callout-question {
  border-left-color: #f59e0b;
  background-color: #fffbeb;
}

.callout-warning {
  border-left-color: #f59e0b;
  background-color: #fffbeb;
}

.callout-failure {
  border-left-color: #ef4444;
  background-color: #fef2f2;
}

.callout-danger {
  border-left-color: #dc2626;
  background-color: #fef2f2;
}

.callout-bug {
  border-left-color: #ec4899;
  background-color: #fdf2f8;
}

.callout-example {
  border-left-color: #6366f1;
  background-color: #eef2ff;
}

.callout-quote {
  border-left-color: #64748b;
  background-color: #f8fafc;
  font-style: italic;
}

/* Task list styling */
.task-list-item {
  list-style: none;
  position: relative;
  padding-left: 0;
}

.task-list-item input[type="checkbox"] {
  margin-right: 0.5rem;
  cursor: default;
  width: 1rem;
  height: 1rem;
  accent-color: #22c55e;
}

/* ── CTA — [cta url="..." label="..." style="button|box" text="..."] shortcode ──
   A gomb színét/hátterét a Tailwind bg-brand-terracotta / text-white osztályok adják
   (tailwind.css utoljára tölt → nyer). Itt csak a prose-aláhúzást ütjük ki és a
   layout/box-panel stílust adjuk meg saját osztályokkal (nem purge-öl a Tailwind). */
.hcms-cta {
  margin: 2rem 0;
  text-align: center;
}
/* Kétosztályos szelektor (0,2,0) — felülírja a .prose a sárga highlighter szabályt (0,1,1),
   így a CTA gomb a márka-terracotta lesz (mint a Hírlevél gomb), a site link-kiemelő érintetlen. */
.hcms-cta .hcms-cta__btn {
  display: inline-block;
  background-color: #0F0F0F; /* newspaper ink */
  color: #ffffff;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  font-size: 0.85rem;
  line-height: 1.2;
  padding: 0.9rem 1.9rem;
  border-radius: 0;
  text-decoration: none;
  transition: background-color 0.15s ease, transform 0.15s ease;
}
.hcms-cta .hcms-cta__btn:hover {
  background-color: #000000;
  color: #ffffff;
  transform: translateY(-1px);
}
.hcms-cta .hcms-cta__btn:focus-visible {
  outline: 2px solid #0F0F0F;
  outline-offset: 2px;
}
/* Box variáns — keretezett panel rövid szöveggel + gombbal */
.hcms-cta--box {
  background-color: #F4F4F2; /* brand sand */
  border: 1px solid #E4E4E4; /* brand line */
  border-radius: 0;
  padding: 1.75rem;
}
.hcms-cta__text {
  margin: 0 0 1.1rem;
  color: #262626; /* brand inkSoft */
  font-size: 1.05rem;
  line-height: 1.6;
}
@media (prefers-reduced-motion: reduce){ .reveal{ transition:none; opacity:1; transform:none; } }