/*
 * egyesitokozosseg.hu — a Hadron téma testreszabása (egyesito gyerektéma)
 *
 * A régi oldal (HTML5 UP Editorial) mintájára: bal oldalon világosszürke sáv a logóval és a menüvel,
 * jobbra a tartalom; kiemelő szín: #f56a6a (Beállítások → Téma → kiemelő szín).
 * Ez a fájl utolsóként töltődik be, ezért felülírja a Hadron / Quark 2 stílusait.
 */

:root, :root[data-theme=light], :root[data-theme=dark] {
    --ek-accent: #f56a6a;
    --ek-heading: #3d4449;
    --ek-text: #4c5358;
    --ek-muted: #7f888f;
    --ek-border: rgba(210, 215, 217, 0.75);
    --ek-side-bg: #f5f6f7;
    --ek-side-bg-2: #eff1f2;
    --ek-sidebar-w: 21rem;

    --q2-bg: #ffffff;
    --q2-bg-elev: #ffffff;
    --q2-text: var(--ek-text);
    --q2-text-strong: var(--ek-heading);
    --q2-text-muted: var(--ek-muted);
    --q2-divider: var(--ek-border);
    color-scheme: light;
}

html { scroll-padding-top: 1rem; }
body { background: #fff; color: var(--ek-text); line-height: 1.7; }
#page-wrapper { display: block; }
main#start { padding: 0; margin: 0; }
h1, h2, h3, h4, h5, h6 { color: var(--ek-heading); }
a { color: var(--ek-accent); }
a:hover { color: var(--ek-accent); text-decoration: underline; }
strong, b { color: var(--ek-heading); }
blockquote {
    border-left: 3px solid var(--ek-border); margin: 0 0 1.5rem; padding: 0.5rem 0 0.5rem 1.5rem;
    font-style: italic; color: var(--ek-text); background: none;
}
hr { border: 0; border-top: 1px solid var(--ek-border); margin: 2rem 0; }
img { max-width: 100%; height: auto; }

/* ---------------------------------------------------------------- elrendezés */
.ek-layout { display: flex; min-height: 100vh; align-items: stretch; }
.ek-sidebar {
    flex: 0 0 var(--ek-sidebar-w); width: var(--ek-sidebar-w); order: 0;
    background: var(--ek-side-bg);
}
.ek-sidebar-inner {
    position: sticky; top: 0; max-height: 100vh; overflow-y: auto;
    padding: 2rem 2rem 2.5rem;
}
.ek-main { flex: 1 1 auto; min-width: 0; order: 1; padding: 0 4rem 4rem; }
.ek-content { max-width: 72rem; }
.ek-main .content-item { max-width: none; margin: 0; padding: 0; background: transparent; box-shadow: none; border: 0; }

/* ---------------------------------------------------------------- felső sáv */
.ek-topbar {
    display: flex; align-items: flex-end; gap: 1rem; flex-wrap: wrap;
    border-bottom: 5px solid var(--ek-accent);
    padding: 4rem 0 0.8rem;
    max-width: 72rem;
}
.ek-crumbs { flex: 1 1 auto; font-size: 1rem; color: var(--ek-muted); }
.ek-crumbs a { color: var(--ek-heading); text-decoration: none; border-bottom: 0; }
.ek-crumbs a:hover { color: var(--ek-accent); }
.ek-crumbs .ek-brand { font-weight: 700; font-size: 1.1rem; }
.ek-crumbs .ek-sep { margin: 0 0.35rem; color: var(--ek-muted); }
.ek-icons { list-style: none; margin: 0; padding: 0; display: flex; gap: 1.1rem; }
.ek-icons li { margin: 0; padding: 0; }
.ek-icons a { color: var(--ek-heading); font-size: 1.15rem; text-decoration: none; }
.ek-icons a:hover { color: var(--ek-accent); }
.ek-menu-toggle { display: none; }

/* ---------------------------------------------------------------- oldalsáv */
.ek-logo { display: inline-block; margin-bottom: 1.5rem; }
.ek-logo img { width: 100px; height: auto; display: block; }
.ek-major {
    display: inline-block; margin: 0 0 1.5rem; padding-bottom: 0.4rem;
    border-bottom: 3px solid var(--ek-accent);
    font-size: 1.35rem; line-height: 1.3;
}
.ek-sidebar .ek-major { font-size: 1.15rem; }
.ek-nav, .ek-side-section { padding-bottom: 2rem; margin-bottom: 2rem; border-bottom: 2px solid var(--ek-border); }
.ek-nav ul { list-style: none; margin: 0; padding: 0; }
.ek-nav li { margin: 0; padding: 0; }
.ek-nav > ul > li { border-top: 1px solid var(--ek-border); }
.ek-nav > ul > li:first-child { border-top: 0; }
.ek-nav > ul > li > a, .ek-opener {
    display: flex; align-items: center; gap: 0.6rem; width: 100%;
    padding: 0.75rem 0; background: none; border: 0; border-radius: 0; box-shadow: none;
    color: var(--ek-heading); font: inherit; font-size: 0.95rem; font-weight: 600; text-align: left;
    text-transform: uppercase; letter-spacing: 0.04em; text-decoration: none; cursor: pointer;
}
.ek-nav i { color: var(--ek-muted); width: 1.2em; text-align: center; }
.ek-opener::after {
    content: "\f078"; font-family: "Font Awesome 5 Free"; font-weight: 900; font-size: 0.75rem;
    margin-left: auto; color: var(--ek-muted); transition: transform 0.2s;
}
.ek-group.is-open > .ek-opener::after { transform: rotate(-180deg); }
.ek-opener:hover, .ek-nav > ul > li > a:hover, .ek-opener:focus-visible { color: var(--ek-accent); background: none; }
.ek-group > ul { display: none; padding: 0 0 0.9rem 0.2rem; }
.ek-group.is-open > ul { display: block; }
.ek-group > ul a { display: block; padding: 0.3rem 0; color: var(--ek-text); text-decoration: none; font-size: 0.95rem; line-height: 1.4; }
.ek-nav a:hover { color: var(--ek-accent); }
.ek-nav a.active { color: var(--ek-heading); font-weight: 700; }
.ek-nav .ek-book-open > a { color: var(--ek-heading); font-weight: 700; }
.ek-book { margin: 0.2rem 0 0.4rem 0.2rem !important; padding-left: 0.8rem !important; border-left: 2px solid var(--ek-accent); }
.ek-book a { font-size: 0.9rem !important; padding: 0.22rem 0 !important; }
.ek-book a.active { color: var(--ek-accent) !important; }

.ek-mini-posts article { margin-bottom: 1.5rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--ek-border); }
.ek-mini-posts article:last-child { border-bottom: 0; margin-bottom: 0; padding-bottom: 0; }
.ek-mini-posts p { margin: 0.8rem 0 0; font-size: 0.95rem; }
.ek-contact { list-style: none; margin: 1rem 0 0; padding: 0; }
.ek-contact li { display: flex; gap: 0.8rem; margin: 0 0 0.8rem; padding: 0.8rem 0 0; border-top: 1px solid var(--ek-border); }
.ek-contact li:first-child { border-top: 0; padding-top: 0; }
.ek-contact i { color: var(--ek-accent); margin-top: 0.3rem; width: 1.1em; }
.ek-footer p { font-size: 0.85rem; color: var(--ek-muted); margin: 0; }

/* ---------------------------------------------------------------- tartalom */
.ek-banner { display: flex; gap: 4rem; align-items: flex-start; padding: 3.5rem 0 2rem; }
.ek-banner-content { flex: 1 1 60%; min-width: 0; }
.ek-banner-image { flex: 1 1 40%; min-width: 0; }
.ek-banner-image img { width: 100%; border-radius: 0.375rem; display: block; }
.ek-page-header { margin-bottom: 1.5rem; }
.ek-page-header h1 { font-size: clamp(2.2rem, 4vw, 3.4rem); line-height: 1.15; margin: 0.2rem 0; }
.ek-pre, .ek-post-title { font-size: clamp(1.2rem, 2vw, 1.6rem); font-weight: 600; color: var(--ek-heading); margin: 0; line-height: 1.3; }
.ek-subtitle { font-size: 1.15rem; color: var(--ek-muted); margin: 0.5rem 0 0; }
.ek-text h2 { font-size: 1.6rem; margin-top: 2.5rem; }
.ek-text h3 { font-size: 1.3rem; margin-top: 2rem; }
.ek-text h4 { font-size: 1.12rem; margin-top: 1.6rem; }
.ek-text h5, .ek-text h6 { font-size: 1rem; margin-top: 1.4rem; }
.ek-text iframe, .ek-col iframe { max-width: 100%; border: 0; }
.ek-book-page .ek-text { max-width: 50rem; }

.ek-section { padding: 2.5rem 0 1rem; border-top: 2px solid var(--ek-border); }
.ek-banner + .ek-section { margin-top: 1rem; }
.ek-posts { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 2.5rem 3rem; margin-bottom: 2rem; }
.ek-post h3 { font-size: 1.2rem; margin: 1.2rem 0 0.5rem; line-height: 1.35; }
.ek-post h3 a { color: inherit; text-decoration: none; }
.ek-post h3 a:hover { color: var(--ek-accent); }
.ek-post h4 { font-size: 0.95rem; font-weight: 500; color: var(--ek-muted); margin: 0 0 0.6rem; }
.ek-post p { font-size: 0.97rem; }
.ek-image {
    display: block; position: relative; width: 100%; padding: 0; margin: 0; border: 0; background: none;
    border-radius: 0.375rem; overflow: hidden; cursor: pointer; line-height: 0;
}
.ek-image img { width: 100%; display: block; transition: transform 0.25s ease; }
.ek-image:hover img, .ek-image:focus-visible img { transform: scale(1.05); }
.ek-play {
    position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
    width: 3.4rem; height: 3.4rem; border-radius: 50%; background: rgba(0,0,0,0.55); color: #fff;
    display: flex; align-items: center; justify-content: center; font-size: 1.2rem; line-height: 1; padding-left: 0.2rem;
}
.ek-yt:hover .ek-play { background: var(--ek-accent); }

.ek-cols { display: grid; gap: 2rem 3rem; margin-bottom: 1.5rem; }
.ek-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ek-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ek-col h3 { font-size: 1.25rem; margin-top: 0; }

/* gombok (a régi oldal keretes/kitöltött gombjai) */
.ek-button, a.ek-button {
    display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
    min-height: 2.9rem; padding: 0.55rem 1.6rem; margin: 0.3rem 0.6rem 0.3rem 0;
    border-radius: 0.375rem; box-shadow: inset 0 0 0 2px var(--ek-accent);
    color: var(--ek-accent); background: transparent; text-decoration: none;
    font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; text-align: center; line-height: 1.3;
}
.ek-button:hover { background: color-mix(in oklab, var(--ek-accent) 8%, transparent); color: var(--ek-accent); text-decoration: none; }
.ek-button.primary { background: var(--ek-accent); color: #fff; box-shadow: none; }
.ek-button.primary:hover { background: color-mix(in oklab, var(--ek-accent) 88%, white 12%); color: #fff; }
.ek-button.big, .ek-button.large { font-size: 0.9rem; min-height: 3.4rem; padding-inline: 2.2rem; }
.ek-button.fit { display: flex; width: 100%; margin-right: 0; }
.ek-lapozo { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; margin: 3rem 0 1rem; padding-top: 2rem; border-top: 2px solid var(--ek-border); max-width: 50rem; }
.ek-lapozo .ek-button { margin: 0; }
.ek-lapozo [rel=next] { margin-left: auto; }

/* ---------------------------------------------------------------- videó-ablak */
/* A Quark 2 (Pico) minden <dialog>-ot teljes képernyős, flex-középre igazító rétegként formáz; ebben a
   videókeretnek kifejezett szélesség kell, különben 0 széles lesz (csak a hang hallatszik). */
dialog.ek-video {
    position: fixed; inset: 0; z-index: 2000;
    width: 100%; height: 100%; min-width: 100%; min-height: 100%; max-width: none; max-height: none;
    margin: 0; padding: 1rem; border: 0; overflow: hidden;
    background: rgba(0, 0, 0, 0.82); backdrop-filter: none;
}
dialog.ek-video:not([open]) { display: none; }
dialog.ek-video[open] { display: flex; align-items: center; justify-content: center; }
.ek-video::backdrop { background: transparent; }
.ek-video-frame {
    position: relative; flex: 0 0 auto;
    width: min(92vw, 960px, calc((100vh - 6rem) * 16 / 9));
    aspect-ratio: 16 / 9; background: #000;
}
.ek-video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.ek-video-close {
    position: absolute; right: 1rem; top: 0.75rem; background: none; border: 0; box-shadow: none;
    color: #fff; font-size: 2.4rem; line-height: 1; cursor: pointer; padding: 0.2rem 0.6rem; margin: 0;
}
.ek-video-close:hover, .ek-video-close:focus-visible { color: var(--ek-accent); background: none; }

/* ---------------------------------------------------------------- keskeny képernyő: a sáv kinyitható panel */
@media (max-width: 1100px) {
    .ek-sidebar {
        position: fixed; z-index: 1000; top: 0; bottom: 0; left: 0;
        width: min(21rem, 86vw); transform: translateX(-100%); transition: transform 0.25s ease;
        box-shadow: 0 0 1.5rem rgba(0,0,0,0.25); overflow-y: auto;
    }
    .ek-sidebar-inner { position: static; max-height: none; overflow: visible; }
    body.ek-sidebar-open .ek-sidebar { transform: none; }
    .ek-overlay { position: fixed; inset: 0; z-index: 999; background: rgba(0,0,0,0.35); }
    .ek-main { padding: 0 2rem 3rem; }
    .ek-topbar { padding-top: 1.2rem; align-items: center; }
    .ek-menu-toggle {
        display: inline-flex; align-items: center; gap: 0.5rem; order: -1;
        background: var(--ek-side-bg); border: 1px solid var(--ek-border); border-radius: 0.375rem; box-shadow: none;
        color: var(--ek-heading); font: inherit; font-weight: 600; padding: 0.45rem 0.9rem; cursor: pointer;
    }
    .ek-crumbs { flex-basis: 100%; order: 1; }
    .ek-icons { margin-left: auto; }
}
@media (max-width: 760px) {
    .ek-main { padding: 0 1rem 2.5rem; }
    .ek-banner { flex-direction: column; gap: 1.5rem; padding-top: 2rem; }
    .ek-banner-image { order: -1; width: 100%; }
    .ek-cols-2, .ek-cols-3 { grid-template-columns: minmax(0, 1fr); }
    .ek-posts { grid-template-columns: minmax(0, 1fr); }
    .ek-lapozo .ek-button { width: 100%; }
    .ek-text iframe, .ek-col iframe { width: 100%; }
}
@media print {
    .ek-sidebar, .ek-topbar, .ek-lapozo { display: none; }
    .ek-main { padding: 0; }
}

/* ---------------------------------------------------------------- felülírások a Quark 2 általános szabályai ellen */
/* ikonok: a Quark 2 minden elemre az Inter betűt állítja, a Font Awesome-nak vissza kell adni a sajátját */
i.fas, i.fa { font-family: "Font Awesome 5 Free" !important; font-weight: 900 !important; }
i.far { font-family: "Font Awesome 5 Free" !important; font-weight: 400 !important; }
i.fab { font-family: "Font Awesome 5 Brands" !important; font-weight: 400 !important; }
/* címsorok: az Inter (a Cal Sans szóközei túl keskenyek a magyar szövegben), a díszvonal nélkül */
h1, h2, h3, h4, h5, h6, .ek-major { font-family: Inter, -apple-system, "Segoe UI", Roboto, sans-serif; letter-spacing: -0.01em; }
h1, h2, h3, h4, h5, h6 { font-weight: 700; }
h1::before, h2::before, h3::before, .ek-major::before { content: none !important; display: none !important; }
.ek-nav .ek-opener, .ek-nav .ek-opener:hover { padding: 0.75rem 0 !important; margin: 0 !important; background: none !important; }
.ek-menu-toggle { margin: 0; }
.ek-image.ek-yt { padding: 0 !important; }
/* a Pico (Blades) a <nav> elemeket vízszintes flex-listának formázza: itt függőleges menü kell */
.ek-nav, .ek-nav ul, .ek-crumbs { display: block; }
.ek-nav ul { margin: 0 !important; padding: 0; }
.ek-nav li { display: block; padding: 0 !important; margin: 0; }
.ek-nav li a { margin: 0 !important; }
.ek-group > ul { display: none !important; padding: 0 0 0.9rem 0.2rem !important; }
.ek-group.is-open > ul { display: block !important; }
.ek-nav ul.ek-book { margin: 0.2rem 0 0.4rem 0.2rem !important; padding-left: 0.8rem !important; }
.ek-icons li { list-style: none; }
.ek-icons li::before, .ek-icons li::marker { content: none !important; display: none !important; }
@media (min-width: 1101px) { .ek-sidebar { align-self: stretch; min-height: 100vh; } }
