/* EnerGym weboldal. A színek, a lekerekítés és a betűk az adminból jönnek (CSS változók).
   Nincs színátmenet: minden felület egyszínű. */

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--color-bg);
    color: var(--color-text);
    font-family: var(--font);
    font-size: var(--font-size);
    line-height: 1.6;
}

main { flex: 1 0 auto; }

img { max-width: 100%; display: block; }
a { color: var(--color-primary); }
a:hover { color: var(--color-primary-hover); }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .6em; }
h1 { font-size: 2.4rem; }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }

:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 2px; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 780px; }

/* ---------- Fejléc ---------- */
.site-header { position: relative; background: var(--color-header-bg); border-bottom: 1px solid var(--color-border); }
.sticky-header .site-header { position: sticky; top: 0; z-index: 50; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 66px; padding-top: 8px; padding-bottom: 8px; }

.brand { display: inline-flex; align-items: center; text-decoration: none; color: var(--color-text); }
.brand img { height: var(--logo-h); width: auto; }
.brand-text { font-size: 1.6rem; font-weight: 800; letter-spacing: .02em; }
.brand-accent { color: var(--color-primary); }

.nav { display: flex; align-items: center; gap: 22px; }
.nav a { color: var(--color-text); text-decoration: none; padding: 6px 0; border-bottom: 2px solid transparent; }
.nav a:hover { color: var(--color-primary); }
.nav a.active { color: var(--color-primary); border-bottom-color: var(--color-primary); }

.lang { display: inline-flex; border: 1px solid var(--color-border); border-radius: var(--radius); overflow: hidden; }
.lang a { padding: 4px 10px; font-size: .85rem; font-weight: 700; border-bottom: 0; }
.lang a.active { background: var(--color-primary); color: var(--color-on-primary); }

.nav-toggle { display: none; background: transparent; border: 1px solid var(--color-border); border-radius: var(--radius); padding: 10px; cursor: pointer; }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--color-text); }
.nav-toggle span + span { margin-top: 5px; }

/* ---------- Gombok ---------- */
.btn {
    display: inline-block;
    background: var(--color-primary);
    color: var(--color-on-primary);
    border: 2px solid var(--color-primary);
    border-radius: var(--radius);
    padding: 12px 24px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}
.btn:hover { background: var(--color-primary-hover); border-color: var(--color-primary-hover); color: var(--color-on-primary); }
.btn-outline { background: transparent; color: var(--color-primary); }
.btn-outline:hover { background: var(--color-primary); color: var(--color-on-primary); }

/* ---------- Nyitókép ---------- */
.hero { position: relative; display: flex; align-items: center; min-height: var(--hero-h); background: var(--color-surface); overflow: hidden; border-bottom: 1px solid var(--color-border); }
.hero-content { position: relative; z-index: 3; width: 100%; padding-top: 48px; padding-bottom: 48px; }
.hero-content h1 { font-size: 3rem; max-width: 18ch; }
.hero-content p { font-size: 1.2rem; max-width: 52ch; color: var(--color-muted); }
.hero-center .hero-content { text-align: center; }
.hero-center .hero-content h1, .hero-center .hero-content p { margin-left: auto; margin-right: auto; }

.hero.has-slides .hero-content h1 { color: #ffffff; }
.hero.has-slides .hero-content p { color: #e9ecef; }
.hero-shade { position: absolute; inset: 0; background: rgba(0, 0, 0, .5); z-index: 2; }

.slider { position: absolute; inset: 0; z-index: 1; }
.slide { position: absolute; inset: 0; margin: 0; opacity: 0; transition: opacity .7s ease; }
.slide.active { opacity: 1; }
.slide img { width: 100%; height: 100%; object-fit: cover; }
.slide figcaption {
    position: absolute; left: 20px; bottom: 54px; z-index: 4;
    background: rgba(16, 19, 22, .78); color: #ffffff;
    padding: 6px 12px; border-radius: var(--radius); font-size: .9rem;
}
.slider-btn {
    position: absolute; top: 50%; transform: translateY(-50%); z-index: 5;
    width: 44px; height: 44px; border: 0; cursor: pointer;
    background: rgba(16, 19, 22, .72); color: #ffffff; font-size: 1.6rem; line-height: 1;
    border-radius: var(--radius);
}
.slider-btn:hover { background: var(--color-primary); color: var(--color-on-primary); }
.slider-btn.prev { left: 14px; }
.slider-btn.next { right: 14px; }
.slider-dots { position: absolute; left: 0; right: 0; bottom: 16px; z-index: 5; display: flex; justify-content: center; gap: 8px; }
.slider-dots button { width: 12px; height: 12px; padding: 0; border: 0; cursor: pointer; background: rgba(255, 255, 255, .55); border-radius: var(--radius); }
.slider-dots button.active { background: var(--color-primary); }

/* ---------- Szekciók ---------- */
.section { padding: 64px 0; }
.section.alt { background: var(--color-surface); border-top: 1px solid var(--color-border); border-bottom: 1px solid var(--color-border); }
.prose p:last-child { margin-bottom: 0; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose table { border-collapse: collapse; width: 100%; margin: 1em 0; }
.prose th, .prose td { border: 1px solid var(--color-border); padding: 8px 10px; text-align: left; }
.lead { font-size: 1.1rem; color: var(--color-muted); }

.cards { display: grid; gap: 20px; }
.cols-2 { grid-template-columns: repeat(2, 1fr); }
.cols-3 { grid-template-columns: repeat(3, 1fr); }
.cols-4 { grid-template-columns: repeat(4, 1fr); }
.card { background: var(--color-bg); border: 1px solid var(--color-border); border-top: 3px solid var(--color-primary); border-radius: var(--radius); padding: 22px; }
.section.alt .card { background: var(--color-bg); }
.card h3 { margin-bottom: .4em; }
.card p { color: var(--color-muted); }

/* ---------- Árak ---------- */
.price-group { margin-top: 1.6em; font-size: 1.3rem; color: var(--color-primary); }
.price-table { width: 100%; border-collapse: collapse; margin: 0 0 1.2em; }
.price-table th { text-align: left; color: var(--color-muted); font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; padding: 8px 12px; border-bottom: 2px solid var(--color-border); }
.price-table td { padding: 14px 12px; border-bottom: 1px solid var(--color-border); vertical-align: top; }
.price-table .p-price { text-align: right; white-space: nowrap; font-weight: 800; font-size: 1.1rem; }
.price-table .p-name { font-weight: 700; }
.price-table .p-note { color: var(--color-muted); font-size: .9rem; }
.price-table tr.featured td { background: var(--color-surface); }
.price-table tr.featured td:first-child { border-left: 4px solid var(--color-primary); }
.empty { color: var(--color-muted); }
.more { margin-top: 1.4em; }

/* ---------- Elérhetőség ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 28px; align-items: start; }
.c-item { margin-bottom: 18px; }
.c-label { color: var(--color-muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; }
.contact-map iframe { width: 100%; height: 340px; border: 1px solid var(--color-border); border-radius: var(--radius); }

.notfound { text-align: center; }
.notfound h1 { font-size: 5rem; color: var(--color-primary); }

/* ---------- Lábléc ---------- */
.site-footer { background: var(--color-footer-bg); border-top: 1px solid var(--color-border); color: var(--color-muted); }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 28px; padding-bottom: 28px; flex-wrap: wrap; }
.footer-brand { font-weight: 800; font-size: 1.2rem; color: var(--color-text); }
.copy { font-size: .85rem; }
.fb-link { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; color: var(--color-text); text-decoration: none; border: 1px solid var(--color-border); border-radius: var(--radius); }
.fb-link:hover { color: var(--color-on-primary); background: var(--color-primary); border-color: var(--color-primary); }

/* ---------- Mobil ---------- */
@media (max-width: 800px) {
    h1 { font-size: 2rem; }
    .hero-content h1 { font-size: 2.2rem; }
    .section { padding: 44px 0; }
    .nav-toggle { display: inline-block; }
    .brand img { height: min(var(--logo-h), 56px); }
    .nav {
        display: none; position: absolute; left: 0; right: 0; top: 100%;
        flex-direction: column; align-items: flex-start; gap: 6px;
        background: var(--color-header-bg); border-bottom: 1px solid var(--color-border);
        padding: 14px 20px 18px;
    }
    .nav.open { display: flex; }
    .cols-2, .cols-3, .cols-4 { grid-template-columns: 1fr; }
    .contact-grid { grid-template-columns: 1fr; }
    .slider-btn { display: none; }   /* mobilon érintéssel és pöttyökkel lapozható */
}

@media (prefers-reduced-motion: reduce) {
    .slide { transition: none; }
    html { scroll-behavior: auto; }
}
