/* =========================================================================
   onlinegames.hu — szerkezet
   Fejléc, bal oldali kategóriasáv, tartalom, jobb oldali hirdetési sáv, lábléc.
   ========================================================================= */

/* ---------- Fejléc ---------- */
.topbar {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 10px 20px;
    background: linear-gradient(100deg, var(--blue-light), var(--blue));
    box-shadow: 0 2px 12px rgba(18, 58, 86, .22);
}

.brand { display: flex; align-items: center; gap: 4px; flex: none; }
.brand svg { height: 38px; width: auto; display: block; }
.brand__word {
    font-family: var(--display);
    font-weight: 800;
    font-size: 27px;
    line-height: 1;
    letter-spacing: -.5px;
    -webkit-text-stroke: 5px var(--ink);
    paint-order: stroke fill;
    text-shadow: 0 3px 0 var(--ink-deep);
}
.brand__word i { color: #fff; font-style: normal; }
.brand__word b { color: var(--yellow); font-weight: inherit; }
.brand__word s { color: var(--red); font-size: 18px; text-decoration: none; }

.search {
    flex: 1;
    max-width: 520px;
    display: flex;
    align-items: center;
    gap: 9px;
    background: var(--surface);
    border-radius: 999px;
    padding: 9px 16px;
    box-shadow: inset 0 0 0 3px rgba(18, 58, 86, .14);
}
.search input {
    border: 0; background: none; outline: 0; width: 100%;
    font: inherit; font-weight: 600; color: var(--text);
}
.search input::placeholder { color: var(--muted); font-weight: 600; }

.topbar__actions { display: flex; gap: 8px; margin-left: auto; }

.menu-toggle {
    display: none;
    width: 40px; height: 40px; border-radius: 12px;
    background: rgba(255, 255, 255, .9);
    color: var(--ink);
    align-items: center; justify-content: center;
    flex: none;
}
.menu-toggle svg { width: 22px; height: 22px; }

/* ---------- Váz ---------- */
.shell {
    display: grid;
    grid-template-columns: var(--rail-w) minmax(0, 1fr);
    gap: 20px;
    width: 100%;
    padding: 20px 20px 0;
}
.shell--ads { grid-template-columns: var(--rail-w) minmax(0, 1fr) var(--ads-w); }

main { min-width: 0; padding-bottom: 40px; }
section { margin-bottom: 30px; }

/* ---------- Bal oldali kategóriasáv ---------- */
.rail {
    background: var(--surface);
    border-radius: var(--r-card);
    padding: 12px;
    box-shadow: var(--shadow);
    align-self: start;
    position: sticky;
    top: 78px;
}
.rail h2 {
    font-size: 12px; letter-spacing: 1.4px; text-transform: uppercase;
    color: var(--muted); margin: 16px 8px 6px; font-weight: 700;
}
.rail a {
    display: flex; align-items: center; gap: 9px;
    padding: 6px 9px; border-radius: 10px;
    font-weight: 700; font-size: 14px;
    transition: background .14s;
}
.rail a:hover { background: var(--surface-2); }
.rail a.is-active { background: var(--blue); color: #fff; }
.rail .ic {
    width: 26px; height: 26px; flex: none; border-radius: 8px;
    display: grid; place-items: center; font-size: 14px; line-height: 1;
}
.rail a.is-active .ic { background: rgba(255, 255, 255, .22) !important; }
.rail__count { margin-left: auto; font-size: 11.5px; color: var(--muted); font-weight: 700; }
.rail a.is-active .rail__count { color: rgba(255, 255, 255, .8); }

/* ---------- Jobb oldali hirdetési sáv ---------- */
.adrail {
    align-self: start;
    position: sticky;
    top: 78px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ---------- Szekciófejlécek ---------- */
.sec-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.sec-head h2 { font-weight: 800; font-size: 23px; letter-spacing: -.2px; }
.sec-head a { font-weight: 800; font-size: 13.5px; color: var(--blue); margin-left: auto; }

/* ---------- Lábléc ---------- */
.site-footer { background: var(--ink); color: #BFD8E8; margin-top: 30px; }
.site-footer__inner {
    padding: 28px 20px;
    display: grid;
    gap: 22px;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}
.site-footer h3 { color: #fff; font-size: 15px; margin-bottom: 8px; }
.site-footer a { display: block; padding: 3px 0; font-size: 13.5px; }
.site-footer a:hover { color: #fff; }
.site-footer__bar {
    border-top: 1px solid rgba(255, 255, 255, .12);
    padding: 12px 20px;
    text-align: center;
    font-size: 12.5px;
}

/* ---------- Töréspontok ---------- */
@media (max-width: 1279px) {
    .shell--ads { grid-template-columns: var(--rail-w) minmax(0, 1fr); }
    .adrail { display: none; }
}

@media (max-width: 900px) {
    .shell,
    .shell--ads { grid-template-columns: 1fr; padding: 14px 12px 0; }
    .rail { display: none; }
    .rail.is-open {
        display: block; position: fixed; top: 0; left: 0; bottom: 0;
        width: 260px; z-index: 70; border-radius: 0; overflow-y: auto;
    }
    .menu-toggle { display: flex; }
    .topbar { flex-wrap: wrap; }
    .topbar__actions { width: 100%; margin-left: 0; }
    main { padding-bottom: 90px; }
    .rail-overlay {
        position: fixed; inset: 0; background: rgba(14, 46, 69, .5); z-index: 60;
    }
}

@media (max-width: 560px) {
    .brand__word { font-size: 22px; -webkit-text-stroke-width: 4px; }
    .brand svg { height: 32px; }
}
