/* Napex Karbantartás — belső adminfelület
   Visszafogott, funkcionális stílus: meleg-semleges papír háttér,
   mély tinta szöveg, petrol-zöld akcent (energetikai hangulat). */

/* ===== Megjelenés (skin) =====
   ALAP = Hűvös (data-skin nélkül). A [data-skin="warm|slate|dark"] felülírja.
   A felhasználó a Profil oldalon választ; a preferencia localStorage-ban (napexAppearance). */
/* A MÁSODLAGOS SZÖVEGEK WCAG AA-SZINTEN (#63). A sidebar szürkéi 2,55:1-en, a
   kártyacímkék 2,97:1-en álltak — mindkettő az AA (4,5:1) alatt. Megrendelői
   döntés: vállaljuk az AA-t.

   A KÜLÖNBSÉG SZEMRE ALIG LÁTSZIK (retina kijelzőn sem), a mérés viszont a
   duplájára javul — épp ezért olcsó. A 2,55:1 nem a szép irodai monitoron
   zavaró, hanem napfényben, laptop-kijelzőn és gyengébb látással.

   Az árnyalatot bőrönként MEGTARTOTTUK: az alap hideg (#5d6878), a meleg bőr
   meleg (#5f5a50), a hideg bőr a sajátja (#5d6470) — egyetlen közös szürke
   mindhármat elszíntelenítené.

   A TARTALOM másodlagos szövegei NEM kaptak új fix színt: a `var(--muted)`-re
   állnak, ami bőrönként már létezett és mind a négyben AA (4,68–6,40:1). Az
   első nekifutásom ide egy hardkódolt `#667085`-öt írt — az a slate bőr
   `--muted`-jének kézi másolata volt, és a SÖTÉT bőrben 3,71:1-re rontotta le
   ugyanazt a szöveget, amit világosban javított. Egy közös fix szürke a két
   mód közül mindig az egyiket elrontja; a bőr-változó nem. */
:root {
    --bg:        #f4f7fb;
    --surface:   #ffffff;
    --ink:       #16233a;
    --muted:     #5a6b85;
    --line:      #dbe3ee;
    --accent:    #1668d8;   /* hűvös kék */
    --accent-d:  #0f2a5a;
    --accent-2:  #20e0c6;   /* türkiz */
    --danger:    #c0392b;
    --danger-bg: #fbeceb;
    --ok-bg:     #e7f3ee;
    --ok-ink:    #0b5447;
    --err-bg:    #fbeceb;
    --err-ink:   #8f2f2f;
    --radius:    10px;
    --shadow:    0 1px 2px rgba(16,41,74,.05), 0 4px 16px rgba(16,41,74,.05);
    --sans:      ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --mono:      ui-monospace, "SFMono-Regular", "Cascadia Code", Menlo, Consolas, monospace;

    /* Sidebar-változók (hűvös alap) */
    --sb-bg:#e9eef4; --sb-text:#3c4759; --sb-ink:#16233a; --sb-muted:#5d6878;
    --sb-line:#d3dce7; --sb-hair:rgba(16,41,74,.08); --sb-hover:rgba(22,104,216,.06);
    --sb-accent:#1668d8; --sb-accent-bg:rgba(22,104,216,.12); --sb-accent-text:#134e9e;

    --surface-2:#f7f9fc;

    /* Űrlapmezők (2026-10-26): EGY forrás minden beviteli mezőnek (ld. „Űrlapmezők: globális alap”).
       A bőrök csak ezeket írják felül; a lapok a méretet és a szélességet adják meg. */
    --mezo-hatter:    var(--surface);
    --mezo-keret:     var(--line);
    --mezo-kerekites: 8px;
    --mezo-fokusz:    rgba(22,104,216,.18);
}
/* a fókuszgyűrű a bőr kiemelőszínéből (a meleg bőrön terrakotta, nem kék) — ahol a böngésző tudja */
@supports (color: color-mix(in srgb, red 50%, transparent)) {
    :root { --mezo-fokusz: color-mix(in srgb, var(--accent) 22%, transparent); }
}

/* Meleg (Claude) skin */
:root[data-skin="warm"]{
    --bg:#f5f3ee; --ink:#2a2622; --muted:#6b6259; --line:#e6dfd2;
    --accent:#bb5535; --accent-d:#a2472a;
    --shadow:0 1px 2px rgba(60,50,40,.05), 0 4px 16px rgba(60,50,40,.05);
    --sb-bg:#ece6db; --sb-text:#4a443b; --sb-ink:#2a2622; --sb-muted:#5f5a50;
    --sb-line:#ddd5c7; --sb-hair:rgba(0,0,0,.07); --sb-hover:rgba(28,36,33,.05);
    --sb-accent:#c96442; --sb-accent-bg:rgba(201,100,66,.12); --sb-accent-text:#983f24;
}
/* Semleges slate skin */
:root[data-skin="slate"]{
    --bg:#f7f8fa; --ink:#1a2230; --muted:#616b80; --line:#e4e7ec;
    --accent:#2563eb; --accent-d:#1d4ed8;
    --sb-bg:#eef0f3; --sb-text:#3a4250; --sb-ink:#1a2230; --sb-muted:#5d6470;
    --sb-line:#e0e3e8; --sb-hair:rgba(26,34,48,.08); --sb-hover:rgba(37,99,235,.06);
    --sb-accent:#2563eb; --sb-accent-bg:rgba(37,99,235,.10); --sb-accent-text:#1d4ed8;
}
/* Dark skin — az egész ERP; a monitoring navy-jével összhangban */
:root[data-skin="dark"]{
    /* A NATÍV VEZÉRLŐK nem a mi CSS-ünkből élnek. A dátum- és időmező belső
       szerkesztője, a naptár-ikon, a legördülő lista és a görgetősáv a böngésző
       saját rajza — az `color-scheme` nélkül ezek VILÁGOSAN maradnak akkor is,
       ha a mező hátterét sötétre állítjuk. Ez a lap sötét, a mező sötét, a
       benne lévő dátum viszont fehér dobozban ült. */
    color-scheme: dark;
    --bg:#0a1424; --surface:#0f1d33; --ink:#e6ecf5; --muted:#8a99b3; --line:#1f3350;
    /* a mezők: a kártyánál sötétebb háttér — ez volt eddig is a sötét bőr mezője (a globális sötét
       mezőszabály a .field és a kereső saját, áttetsző felülírását a specificitásával elnyomta) */
    --mezo-hatter:#0c1a30; --mezo-keret:var(--line);
    --accent:#3d82f0; --accent-d:#2c6be0;
    --danger:#ff6b6b; --danger-bg:rgba(255,92,108,.12);
    --ok-bg:rgba(15,179,160,.14); --ok-ink:#4fe0c6; --err-bg:rgba(255,92,108,.12); --err-ink:#ff9aa4;
    --shadow:0 1px 2px rgba(0,0,0,.30), 0 8px 24px rgba(0,0,0,.35);
    --sb-bg:#081124; --sb-text:#c3cdda; --sb-ink:#ffffff; --sb-muted:#93a1b8;
    --sb-line:#16233a; --sb-hair:rgba(255,255,255,.08); --sb-hover:rgba(255,255,255,.05);
    --sb-accent:#3d82f0; --sb-accent-bg:rgba(61,130,240,.16); --sb-accent-text:#ffffff;
    /* A karbantartás-sablonok `var(--surface-2, #f7f9fc)`-t írnak; a változó
       eddig SEHOL nem létezett, tehát sötét bőrön is a világos tartalék jött. */
    --surface-2:#16273f;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--sans);
    color: var(--ink);
    background: var(--bg);
    background-image: radial-gradient(circle at 1px 1px, rgba(28,36,33,.035) 1px, transparent 0);
    background-size: 22px 22px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

.wrap { width: 100%; max-width: 1040px; margin: 0 auto; padding: 0 24px; }

/* --- Top bar --- */
.topbar {
    background: var(--ink);
    border-bottom: 3px solid var(--accent);
}
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; min-height: 60px; flex-wrap: wrap; gap: 6px 16px; padding-top: 8px; padding-bottom: 8px; }
.brand { color: #fff; text-decoration: none; font-weight: 600; font-size: 1.05rem; letter-spacing: .2px; }
.brand-mark { color: var(--accent); margin-right: 6px; }
.brand-sub { color: #aeb8b3; font-weight: 400; }
.mainnav { display: flex; gap: 3px; flex-wrap: wrap; align-items: center; }
.navsep { width: 1px; align-self: stretch; min-height: 20px; background: rgba(255,255,255,.18); margin: 0 7px; }
.mainnav a {
    color: #cfd6d2; text-decoration: none; font-size: .85rem;
    padding: 6px 10px; border-radius: 7px; white-space: nowrap;
}
.mainnav a:hover { background: rgba(255,255,255,.08); color: #fff; }
.mainnav a.active { background: var(--accent); color: #fff; }
.mainnav a.disabled { opacity: .4; pointer-events: none; }

/* --- Page head --- */
main { padding: 32px 0 48px; }
/* flex-wrap: a sok gombos fejléc (pl. az ajánlaté) keskeny képernyőn a cím alá tördel, nem lóg ki a lapról (2026-10-27) */
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; margin-bottom: 22px; gap: 16px; }
h1 { font-size: 1.5rem; margin: 0; letter-spacing: -.3px; }
.muted { color: var(--muted); margin: 4px 0 0; font-size: .9rem; }

/* --- Card / table --- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; padding: 22px; }
.card > :first-child { margin-top: 0; }
.card > :last-child { margin-bottom: 0; }
table.data { width: 100%; border-collapse: collapse; font-size: .92rem; }
table.data thead th {
    text-align: left; font-size: .73rem; text-transform: uppercase; letter-spacing: .6px;
    color: var(--muted); font-weight: 600; padding: 13px 16px;
    background: #faf9f5; border-bottom: 1px solid var(--line);
}
table.data tbody td { padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.data tbody tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover { background: #faf9f4; }
.strong { font-weight: 600; }
.num { text-align: right; }
.mono { font-family: var(--mono); font-size: .85rem; color: var(--muted); }
th.actions, td.actions { text-align: right; white-space: nowrap; }
/* Zárolt sor a generikus lefúró nézetben: kiadott irat, nem szerkeszthető. */
.gd-zarolt { font-size: .8rem; color: var(--muted); cursor: help; }

/* --- Buttons --- */
.btn {
    display: inline-block; cursor: pointer; font: inherit; font-size: .9rem;
    padding: 8px 14px; border-radius: 8px; border: 1px solid var(--line);
    background: var(--surface); color: var(--ink); text-decoration: none; line-height: 1.2;
    transition: background .12s, border-color .12s;
}
.btn:hover { background: #f0eee8; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-d); border-color: var(--accent-d); }
.btn-sm { padding: 5px 10px; font-size: .82rem; }
.btn-danger { color: var(--danger); border-color: #e7cdcd; background: var(--danger-bg); }
.btn-danger:hover { background: #f6dede; }
form.inline { display: inline; margin-left: 6px; }

/* --- Alerts --- */
.alert { padding: 11px 15px; border-radius: 8px; margin-bottom: 18px; font-size: .92rem; border: 1px solid transparent; }
.alert-success { background: var(--ok-bg); color: var(--ok-ink); border-color: #c7e3d7; }
.alert-error { background: var(--err-bg); color: var(--err-ink); border-color: #eccaca; }

/* --- Empty state --- */
.empty { text-align: center; padding: 56px 20px; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }
.empty p { color: var(--muted); margin: 0 0 16px; }

/* --- Űrlapmezők: globális alap (2026-10-26) ---
   Eddig CSAK a .field konténerbe tett mezőnek volt stílusa; ami rácsba, táblába vagy sorba került (az OETP-
   adatlap, az érintésvédelmi lap, a szerződés táblái…), a böngésző alapmezője lett — vékony fekete keret,
   szögletes sarok, más betűméret —, és minden lap vagy külön pótolta, vagy elfelejtette.
   Ez az alap MINDEN szöveges mezőre, legördülőre és szövegdobozra érvényes, de a :where() miatt NULLA a
   specificitása: bármelyik meglévő, célzott szabály (.field, a tömör táblázatos szerkesztők, a monitoring
   saját felülete, a nyilvános lapok) felülírja. Az új lapoknak így elég a szélességet megadni. */
:where(input:not([type=checkbox], [type=radio], [type=file], [type=range], [type=color], [type=hidden],
                 [type=submit], [type=button], [type=reset], [type=image]), select, textarea) {
    box-sizing: border-box; max-width: 100%;
    padding: 7px 10px;
    font: inherit; font-size: .95rem; line-height: normal; color: var(--ink);
    background: var(--mezo-hatter); border: 1px solid var(--mezo-keret); border-radius: var(--mezo-kerekites);
}
/* Minimális magasság SZÁNDÉKOSAN nincs: a tömör táblázatos szerkesztők (karbantartás, mérőlap) csak a margót és a
   magasságot adják meg, a min-height-et nem — egy alap-minimum az ő soraikat nyújtaná meg. A `line-height: normal`
   azért kell, mert a `font: inherit` a törzs nagyobb sormagasságát is áthozná: a már formázott lapok (ahol a
   sablon csak a margót adja meg) mezői 3–12 px-szel megnőnének. */
:where(textarea) { resize: vertical; }
/* Táblázatcellában tömör: sűrű, soronként szerkesztett képernyők (érintésvédelmi mérőlap, iratlista…) — a
   mező magassága itt a böngésző alapjáé marad (~20 px), csak a keret, a sarok és a színek egységesek; a
   legördülő a saját belső térköze miatt függőleges margó nélkül ugyanilyen magas. */
:where(td, th) :where(input:not([type=checkbox], [type=radio], [type=file], [type=range], [type=color], [type=hidden],
                                [type=submit], [type=button], [type=reset], [type=image]), textarea) {
    padding: 1px 5px; font-size: .85rem; line-height: 1.2; border-radius: 6px;
}
:where(td, th) :where(select) { padding: 0 4px; font-size: .85rem; line-height: 1.2; border-radius: 6px; }
/* Tömör mezők sűrű, nem táblázatos listákhoz (pl. az érintésvédelmi ellenőrzőlista: tételenként egy döntés
   és egy megjegyzés) — a konténerre tett osztály; a lap saját, célzott szabálya továbbra is felülírja. */
.mezok-tomor :where(input:not([type=checkbox], [type=radio], [type=file], [type=range], [type=color], [type=hidden],
                               [type=submit], [type=button], [type=reset], [type=image]), select, textarea) {
    padding: 4px 8px; font-size: .88rem; line-height: 1.25; border-radius: 6px;
}
:where(input, textarea)::placeholder { color: var(--muted); opacity: 1; }
/* letiltva: halványítás NÉLKÜL — a rendszer számolta értékek (pl. az érintésvédelmi lap dátumai) olvashatók maradjanak */
:where(input, select, textarea):disabled { background: var(--surface-2); color: var(--muted); cursor: not-allowed; }
:where(input:not([type=checkbox], [type=radio], [type=file], [type=range], [type=color]), select, textarea):focus {
    border-color: var(--accent); box-shadow: 0 0 0 3px var(--mezo-fokusz);
}

/* --- Form --- */
.form-card { padding: 26px; max-width: 720px; }
.field { margin-bottom: 18px; }
.field label { display: block; font-size: .85rem; font-weight: 600; margin-bottom: 6px; }
.req { color: var(--danger); }
.field input:not([type=checkbox]):not([type=radio]):not([type=file]), .field select, .field textarea {
    width: 100%; box-sizing: border-box; font: inherit; font-size: 1rem; color: var(--ink);
    min-height: 44px; padding: 11px 13px; border: 1px solid var(--mezo-keret); border-radius: var(--mezo-kerekites);
    background: var(--mezo-hatter);
}
.field textarea { min-height: 72px; }
.field input:focus, .field select:focus, .field textarea:focus {
    outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--mezo-fokusz);
}
.field textarea { resize: vertical; }
.field-error { color: var(--danger); font-size: .82rem; margin: 6px 0 0; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; align-items: end; }
/* A címke lehet egy- vagy kétsoros ("Beszerzési nettó egységár" vs "Haszon %"),
   és blokk-elemként lejjebb tolja a saját mezőjét — így a két beviteli mező
   elcsúszik egymáshoz képest. Alulra igazítva a MEZŐK kerülnek egy vonalba,
   a címke pedig fölöttük tördelődik. A .form-grid ugyanezt csinálja (align-items: end),
   ez csak kiterjeszti az általános űrlap párosaira. */
.grid-2 > .field { display: flex; flex-direction: column; justify-content: flex-end; }
.form-actions { display: flex; gap: 10px; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); }

/* --- Footer --- */
.footer { color: var(--muted); font-size: .82rem; padding: 24px; border-top: 1px solid var(--line); margin-top: 8px; }

@media (max-width: 640px) {
    .grid-2 { grid-template-columns: 1fr; }
    .mainnav a.disabled { display: none; }
    table.data { font-size: .85rem; }
}

/* --- Tag / badge (státusz jelzők a listákban) --- */
.tag { display: inline-block; font-size: .76rem; font-weight: 600; padding: 2px 9px; border-radius: 999px; line-height: 1.5; }
.tag-on  { background: var(--ok-bg); color: var(--ok-ink); }
.tag-off { background: #efece4; color: var(--muted); }
.tag-base { background: #e9eff5; color: #1d4e74; }
/* Figyelmeztető és lejárt jelzés (2026-11-18, az irat kelte: Napex\IratDatum) */
.tag-warn { background: #fdf3dc; color: #7a5300; }
.tag-err  { background: var(--err-bg); color: var(--err-ink); }
/* Hosszabb, akár többsoros jelző (a tulajdoni lap / térképmásolat beadhatósága, 2026-11-18): a 999 px-es kapszula két
   sorba törve ellipszis lett (mobil, PV26/129) — itt enyhe lekerekítésű téglalap. */
.tag.tag-jelzo { border-radius: 6px; }
.checkrow { display: flex; align-items: center; gap: 9px; }
.checkrow input { width: 16px; height: 16px; }
.checkrow label { margin: 0; font-weight: 500; }
.checks { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }
.checkset { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.checkset .checkline { display: flex; align-items: center; gap: 7px; }
.checkset .checkline input { width: auto; min-height: 0; }

/* --- Felhasználó-doboz a fejlécben --- */
.userbox { display: flex; align-items: center; gap: 12px; }
.userbox-name { color: #cfd6d2; font-size: .85rem; }
.userbox-logout {
    color: #fff; text-decoration: none; font-size: .82rem;
    padding: 6px 11px; border: 1px solid rgba(255,255,255,.25); border-radius: 7px;
}
.userbox-logout:hover { background: rgba(255,255,255,.10); }

/* --- Bejelentkező oldal --- */
.auth-body { background: var(--ink); }
.auth-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.auth-card {
    width: 100%; max-width: 380px; background: var(--surface);
    border-radius: var(--radius); box-shadow: var(--shadow); padding: 30px 28px;
}
.auth-brand { font-weight: 600; font-size: 1.1rem; margin-bottom: 18px; color: var(--ink); }
.auth-card h1 { font-size: 1.25rem; margin: 0 0 4px; }
.auth-card .muted { margin-top: 0; }
.auth-card form { margin-top: 18px; }
.btn-block { width: 100%; text-align: center; margin-top: 6px; }

/* --- Lefúró részletek nézet --- */
.breadcrumb { font-size: .85rem; color: var(--muted); margin-bottom: 14px; }
.breadcrumb a { color: var(--accent); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.crumb-sep { margin: 0 7px; color: var(--line); }
.crumb-current { color: var(--ink); font-weight: 600; }

.detail-summary { padding: 8px 20px; margin-bottom: 24px; }
.summary-row { display: flex; gap: 16px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.summary-row:last-child { border-bottom: 0; }
.summary-label { flex: 0 0 200px; color: var(--muted); font-size: .9rem; }
.summary-value { font-weight: 500; min-width: 0; overflow-wrap: anywhere; }
/* Telefonon a 200 px-es címkeoszlop mellett ~90 px maradt az értéknek: a hosszú szó (POD-kód,
   „Energiatároló”) a kártyán túlra lógott, és a kártya levágta. Keskeny képernyőn a címke az érték fölé kerül. */
@media (max-width: 640px) {
    .summary-row { flex-direction: column; gap: 2px; }
    .summary-label { flex: none; }
}

.child-section { margin-bottom: 26px; }
.child-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; }
.child-head-actions { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
.child-toolbar { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: -2px 0 10px; }
.child-toolbar > .muted { font-size: .86rem; margin-right: 2px; }
/* A gombsor alatti egysoros jelzés (pl. meddig adható be az igénybejelentő): többsoros is lehet, ezért nem pirula */
.child-toolbar-jelzes { margin: -4px 0 10px; }
.child-toolbar-jelzes .tag { border-radius: 8px; white-space: normal; font-size: .84rem; }
.child-head h2 { font-size: 1.05rem; margin: 0; letter-spacing: -.2px; }
.child-empty { padding: 18px 20px; color: var(--muted); font-size: .9rem; }

/* --- Lenyíló navigáció --- */
.navgroup { position: relative; }
.navgroup-btn {
    font: inherit; font-size: .85rem; cursor: pointer;
    background: none; border: none; color: #cfd6d2;
    padding: 6px 10px; border-radius: 7px; white-space: nowrap; display: inline-flex; align-items: center; gap: 5px;
}
.navgroup-btn:hover { background: rgba(255,255,255,.08); color: #fff; }
.navgroup-btn.active { color: #fff; }
.navgroup-btn .caret { font-size: .7em; opacity: .7; }
.navgroup-menu {
    position: absolute; top: 100%; left: 0; z-index: 100; margin-top: 8px;
    min-width: 210px; background: #fff; border: 1px solid #dde1e8; border-radius: 9px;
    box-shadow: 0 8px 24px rgba(0,0,0,.16); padding: 6px; display: none;
}
/* Láthatatlan híd a gomb és a menü között, hogy a kurzor ne "essen ki" hover közben */
.navgroup-menu::before {
    content: ""; position: absolute; left: 0; right: 0; top: -10px; height: 10px;
}
.navgroup.open .navgroup-menu, .navgroup:hover .navgroup-menu { display: block; }
.navgroup-menu a {
    display: block; padding: 9px 12px; border-radius: 6px; white-space: nowrap;
    color: #2a3340; text-decoration: none; font-size: .88rem;
}
.navgroup-menu a:hover { background: #eef1f5; }
.navgroup-menu a.active { background: var(--accent); color: #fff; font-weight: 600; }

/* --- Munkalap-áttekintő --- */
.ov-filter { display: flex; align-items: flex-end; gap: 14px; flex-wrap: wrap; }
.ov-filter .field { margin: 0; }
.ov-sum { display: flex; gap: 10px; flex-wrap: wrap; margin: 16px 0 22px; }
.ov-sum .box { border: 1px solid #dde1e8; border-radius: 9px; padding: 9px 14px; min-width: 120px; }
.ov-sum .box .k { font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.ov-sum .box .v { font-weight: 800; font-size: 1.05rem; color: var(--ink); }
.ov-day { border: 1px solid #dde1e8; border-radius: 10px; margin-bottom: 16px; overflow: hidden; }
/* A dátumsor VIZUÁLIS ELVÁLASZTÓ: sötét háttérrel a hosszú listában is látszik,
   hol kezdődik az új munkanap. A szín a skin változójából jön, nem beégetve —
   a „warm" témán ugyanígy sötét marad, csak meleg árnyalatban. */
.ov-day-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
    background: var(--accent-d); padding: 11px 15px; border-bottom: 1px solid var(--accent-d); }
.ov-day-head .d { font-weight: 800; color: #fff; }
.ov-day-head .s { color: #fff; font-size: .9rem; }
.ov-day-head .tag { background: rgba(0,0,0,.18); color: #fff; border-color: transparent; }
.ov-day-head .ov-edit { color: #fff; opacity: .85; }
.ov-day-head .ov-edit:hover { background: rgba(255,255,255,.15); opacity: 1; }
.ov-stop { padding: 11px 15px; border-bottom: 1px solid #f0f1f4; }
.ov-stop:last-child { border-bottom: none; }
.ov-stop-head { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.ov-stop-head .nm { font-weight: 700; }
.ov-stop-head .meta { font-size: .8rem; color: var(--muted); }
.ov-work { border-left: 3px solid var(--accent); padding: 7px 0 7px 11px; margin: 9px 0 9px 6px; }
.ov-work .wh { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.ov-work .wh .t { font-variant-numeric: tabular-nums; color: #444; }
.ov-work .wh .amt { font-weight: 700; white-space: nowrap; }
.ov-work .desc { font-size: .9rem; margin: 2px 0; }
.ov-sub { font-size: .82rem; color: #555; margin: 3px 0 0 4px; }
/* #40 komment/2 — a munkához rendelt berendezés az áttekintőben. A hiányt is
   kiírjuk, csak halványabban: az üres hely nem közöl semmit. */
.ov-asset { display: inline-block; font-size: .78rem; font-weight: 600; padding: 1px 7px;
    border-radius: 999px; background: var(--ok-bg); color: var(--ok-ink); white-space: nowrap; }
.ov-asset .mono { font-weight: 400; font-family: var(--mono); font-size: .95em; opacity: .8; }
.ov-asset-none { background: transparent; color: var(--muted); font-weight: 400;
    border: 1px dashed var(--line); }
.ov-sub .row { display: flex; justify-content: space-between; gap: 8px; padding: 2px 0; }
.ov-actions { margin-top: 4px; }
.ov-edit { font-size: .78rem; text-decoration: none; color: #2563a8; font-weight: 600; padding: 2px 6px; border-radius: 5px; }
.ov-edit:hover { background: #eaf1fa; }
.ov-add { font-size: .78rem; color: #0f7a4f; }
.ov-empty { color: var(--muted); font-style: italic; padding: 8px 0; }
.ov-park { border-left: 3px solid var(--accent); padding: 8px 0 8px 12px; margin: 10px 0 10px 4px; background: #fbfcfe; border-radius: 0 6px 6px 0; }
.ov-park > .wh { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.ov-park > .wh .t { font-variant-numeric: tabular-nums; color: #444; }
.ov-park > .wh .amt { font-weight: 700; white-space: nowrap; }
.ov-park > .desc { font-size: .92rem; font-weight: 700; margin: 2px 0 4px; }
.ov-park .ov-work { border-left: 2px solid #e2e6ee; margin: 6px 0 6px 4px; padding: 4px 0 4px 10px; }
.ov-park .ov-work .desc { font-weight: 400; font-size: .88rem; }
.ov-warn { color: #b45309; font-weight: 700; background: #fff4e5; padding: 1px 7px; border-radius: 5px; }
.ov-flash { background: #fff4e5; border: 1px solid #f0c98a; color: #92400e; padding: 9px 14px; border-radius: 8px; margin: 0 0 14px; font-size: .9rem; }
.ov-partners { padding: 14px 16px; margin-bottom: 14px; }
.ov-blk-title { font-size: 1rem; margin: 0 0 8px; }
.ov-ptbl { width: 100%; border-collapse: collapse; font-size: .88rem; }
.ov-ptbl th { text-align: left; color: var(--muted); font-weight: 600; padding: 4px 8px; border-bottom: 1px solid #eceef2; }
.ov-ptbl td { padding: 5px 8px; border-bottom: 1px solid #f4f5f8; }
.ov-ptbl td.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ov-edit-time { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 4px 0 8px; font-size: .82rem; }
/* A `.lbl` most már <label for>: a rá kattintás a mezőt fókuszálja, tehát
   vízszintesen megnöveli a célfelületet anélkül, hogy a lap magasabb lenne.
   A `cursor: pointer` mondja meg, hogy ez tényleg kattintható. */
.ov-edit-time .lbl, .ov-workers .lbl { color: var(--muted); padding: 4px 0; }
/* A `cursor: pointer` CSAK a valódi <label for>-okra. A „Munkatársak:" és a
   „Munkaidő:" <span> maradt (az utóbbi két mezőre — kezdés és zárás — vonatkozik,
   oda egyetlen `for` nem mutathat értelmesen). Ha rájuk is kézre váltana a
   kurzor, kattinthatóságot ígérnénk, ami nincs. */
label.lbl { cursor: pointer; }
.ov-edit-time button { border: 1px solid #cfd6e4; background: #f3f6fb; color: #2563a8; border-radius: 6px; font-weight: 600; cursor: pointer; font-size: .8rem; }
.ov-edit-time button:hover { background: #eaf1fa; }

/* ---- A BEÁGYAZOTT SZERKESZTŐK KATTINTHATÓ MÉRETE ------------------------
   A korábbi szabály CSAK az `input[type=time]`-ot stílusozta, a legördülő és a
   szám-mező kimaradt belőle — azok a böngésző alapértelmezésén maradtak:

       helyszín (select)   160×19 px      km (number)   80×21 px
       Mentés (button)      66×23 px      érkezés        112×28 px

   A WCAG 2.2 AA (2.5.8) minimuma 24×24, a projekt saját szabványa pedig
   `min-height: 44px` (`.field input`, fent). Ezek tehát a ház szabványának a
   felét sem érték el, és a méret KESZKENY KÉPERNYŐN SEM változott: terepen,
   tableten ugyanaz a 19 pixel.

   Ugyanezen a lapon a „+ új megálló" űrlap (`.ov-mat-form`) már 27–32 px volt,
   mert az MINDEN mezőjét stílusozza — vagyis a lap önmagával sem volt
   összhangban: az ÚJ felvétel mezői nagyobbak voltak, mint a szerkesztéséi.

   A 32 px szándékos középút: bőven a WCAG-minimum fölött, és megegyezik azzal,
   ami ezen a lapon már amúgy is a legnagyobb. A teljes 44 px itt megkétszerezné
   a lap magasságát — ez sűrű, soronként szerkesztett képernyő. */
.ov-edit-time input:not([type=hidden]),
.ov-edit-time select,
.ov-edit-time button,
.ov-wadd input, .ov-wadd select, .ov-wadd button,
.ov-mat-form input:not([type=hidden]), .ov-mat-form select, .ov-mat-form button {
    min-height: 32px;
    padding: 4px 8px;
    border: 1px solid var(--mezo-keret);
    border-radius: 6px;
    font-size: .82rem;
}
/* A szám-mezőnél a pörgető nyilak elveszik a helyet a beírt értéktől. */
.ov-edit-time input[type=number], .ov-mat-form input[type=number] { padding-right: 4px; }
.ov-workers { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 0 0 10px; font-size: .82rem; }
.ov-workers .lbl { color: var(--muted); }
.ov-wtag { display: inline-flex; align-items: center; gap: 4px; background: #eef2f8; border: 1px solid #e0e6ef; border-radius: 999px; padding: 2px 4px 2px 10px; }
.ov-wtag form { display: inline; margin: 0; }
/* 17×17 volt — a lap legkisebb kattintható eleme, és egy TÖRLŐ gomb.
   A WCAG 2.2 AA minimuma 24×24; egy elvétett kattintás itt munkatársat távolít
   el (megerősítő kérdés van, de a téves célzás akkor is bosszantó). */
.ov-x { border: none; background: #d9534f; color: #fff; width: 24px; height: 24px; line-height: 22px; border-radius: 50%; font-size: .78rem; cursor: pointer; padding: 0; flex: none; }
.ov-x:hover { background: #c9302c; }
.ov-wadd { display: inline-flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.ov-wadd select, .ov-wadd input[type=text] { padding: 3px 6px; border: 1px solid var(--mezo-keret); border-radius: 6px; font-size: .8rem; }
.ov-wadd button { padding: 3px 10px; border: 1px solid #cfd6e4; background: #f3f6fb; color: #0f7a4f; border-radius: 6px; font-weight: 600; cursor: pointer; font-size: .8rem; }

/* ---- Munkalap-áttekintő SÖTÉT MÓDBAN -------------------------------------
   A fenti `ov-` szabályok végig beégetett világos színekkel készültek. Sötét
   bőrön ez nem "kicsit halványabb": a `.ov-park` háttere #fbfcfe maradt,
   miközben a szöveg színe a témából jött (#e6ecf5) — vagyis FEHÉR SZÖVEG
   FEHÉR HÁTTÉREN, ~1.1:1 kontraszttal. A park-kártya, azon belül a megrendelő
   és a munkadíj gyakorlatilag eltűnt.

   Ezért a párokat EGYÜTT kell mozgatni: ahol a hátteret sötétítjük, ott a rá
   írt beégetett sötét szöveget (pl. a `.t` #444-esét) is világosítani kell,
   különben csak a hiba iránya fordul meg. */
:root[data-skin="dark"] .ov-park { background: rgba(255,255,255,.035); }
:root[data-skin="dark"] .ov-park > .wh .t,
:root[data-skin="dark"] .ov-work .wh .t,
:root[data-skin="dark"] .ov-sub { color: var(--muted); }
:root[data-skin="dark"] .ov-park .ov-work { border-left-color: var(--line); }

:root[data-skin="dark"] .ov-sum .box,
:root[data-skin="dark"] .ov-day { border-color: var(--line); }
:root[data-skin="dark"] .ov-stop { border-bottom-color: var(--line); }
:root[data-skin="dark"] .ov-ptbl th,
:root[data-skin="dark"] .ov-ptbl td { border-bottom-color: var(--line); }

:root[data-skin="dark"] .ov-edit { color: #7fb0ff; }
:root[data-skin="dark"] .ov-edit:hover { background: rgba(61,130,240,.16); }
:root[data-skin="dark"] .ov-add { color: #5fd39a; }
:root[data-skin="dark"] .ov-day-head .ov-edit { color: #fff; }

:root[data-skin="dark"] .ov-edit-time button,
:root[data-skin="dark"] .ov-wadd button {
    background: rgba(255,255,255,.06); border-color: var(--line);
}
:root[data-skin="dark"] .ov-edit-time button { color: #7fb0ff; }
:root[data-skin="dark"] .ov-wadd button { color: #5fd39a; }

/* A munkatárs-címke ugyanaz a hiba volt, mint a park-kártya: világos pirula,
   a téma világos szövegével. */
:root[data-skin="dark"] .ov-wtag {
    background: rgba(255,255,255,.07); border-color: var(--line);
}

/* A figyelmeztetés VILÁGOS csempe volt sötét lapon — olvasható, de vakít, és
   fontosabbnak látszik a valóságosnál. */
:root[data-skin="dark"] .ov-warn { background: rgba(180,83,9,.22); color: #f0b26b; }
:root[data-skin="dark"] .ov-flash {
    background: rgba(180,83,9,.16); border-color: rgba(240,201,138,.32); color: #f0c98a;
}
.ov-wadd button:hover { background: #eaf6ef; }

/* Nyomtatás (pl. garanciális riport) */
@media print {
    .topbar, .sidebar, .sidebar-toggle, .app-topbar, .sidebar-backdrop, .footer, .no-print, .page-head .no-print { display: none !important; }
    main { padding: 0; }
    .card { box-shadow: none; border: none; padding: 0; }
    table.data { font-size: 11px; }
}

/* ===== Bal oldali sáv-menü (sidebar) ===== */
.app-shell { display: flex; align-items: stretch; min-height: 100vh; }
/* Light sidebar — a színek a --sb-* skin-változókból jönnek (ld. :root + [data-skin]). */
.sidebar {
    flex: 0 0 250px; width: 250px;
    background: var(--sb-bg); color: var(--sb-text);
    display: flex; flex-direction: column;
    transition: margin-left .2s ease;
    position: sticky; top: 0; height: 100vh; overflow-y: auto;
    border-right: 1px solid var(--sb-line);
}
.app-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
body.nav-collapsed .sidebar { margin-left: -250px; }

.sidebar .brand { display: flex; align-items: center; gap: 8px; padding: 16px 18px; color: var(--sb-ink); text-decoration: none; font-weight: 700; font-size: 1.05rem; border-bottom: 1px solid var(--sb-hair); }
.sidebar .brand-mark { color: var(--sb-accent); font-size: 1.2rem; }
.sidebar .brand-sub { color: var(--sb-muted); font-weight: 500; }

.sidenav { flex: 1 1 auto; padding: 8px 0 16px; }
.sidenav-group { margin-top: 10px; }
.sidenav-label { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; box-sizing: border-box; background: none; border: 0; cursor: pointer; padding: 8px 18px 4px; font-size: .7rem; letter-spacing: .06em; text-transform: uppercase; color: var(--sb-muted); font-family: inherit; text-align: left; }
.sidenav-label:hover { color: var(--sb-ink); }
.sidenav-caret { font-size: .7rem; transition: transform .15s ease; }
.sidenav-group.collapsed .sidenav-caret { transform: rotate(-90deg); }
.sidenav-group.collapsed .sidenav-items { display: none; }
body.nav-collapsed .sidenav-group.collapsed .sidenav-items { display: block; }
.sidenav-link { display: block; padding: 8px 18px; color: var(--sb-text); text-decoration: none; font-size: .92rem; border-left: 3px solid transparent; }
.sidenav-link:hover { background: var(--sb-hover); color: var(--sb-ink); }
.sidenav-link.active { background: var(--sb-accent-bg); color: var(--sb-accent-text); border-left-color: var(--sb-accent); font-weight: 600; }

.sidebar-user { border-top: 1px solid var(--sb-hair); padding: 12px 18px; }
.sidebar-user .su-name { color: var(--sb-ink); font-weight: 600; font-size: .9rem; margin-bottom: 6px; }
.sidebar-user .su-links { display: flex; flex-wrap: wrap; gap: 4px 12px; }
.sidebar-user .su-links a { color: var(--sb-muted); text-decoration: none; font-size: .82rem; }
.sidebar-user .su-links a:hover { color: var(--sb-ink); text-decoration: underline; }
.sidebar-user .push-enable { margin-top: 10px; width: 100%; padding: 7px 10px; border: 1px solid var(--sb-line); background: rgba(255,255,255,.5); color: var(--sb-text); border-radius: 8px; font-size: .82rem; font-weight: 600; cursor: pointer; }
.sidebar-user .push-enable:hover { background: #fff; color: var(--sb-ink); }
.sidebar-user .push-enable:disabled { opacity: .6; cursor: default; }

/* ===== Dark skin — komponens-felülírások (a beégetett világos színekhez) ===== */
:root[data-skin="dark"] body{ background-image: radial-gradient(circle at 1px 1px, rgba(255,255,255,.03) 1px, transparent 0); }
:root[data-skin="dark"] table.data thead th{ background:#12233d; }
:root[data-skin="dark"] table.data tbody tr:hover{ background:rgba(255,255,255,.04); }
:root[data-skin="dark"] .btn:hover{ background:rgba(255,255,255,.06); }
:root[data-skin="dark"] .btn-danger{ border-color:rgba(255,107,107,.40); background:rgba(255,92,108,.12); }
:root[data-skin="dark"] .btn-danger:hover{ background:rgba(255,92,108,.20); }
/* Beviteli mezők sötét témában.
   NEM `.field`-re szűrve: a táblázatos szerkesztők (topológia, mérőlap, panel-
   összevonás) az inputokat cellákba teszik, nem `.field` konténerbe. Ott a
   böngésző fehér alapértelmezett háttere maradt, a szöveg viszont a világos
   --ink-et örökölte a body-ból — fehér alapon halványszürke, alig olvasható.
   A gombokat (submit/button/reset) kihagyjuk: azoknak saját .btn stílusuk van. */
:root[data-skin="dark"] input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=hidden]):not([type=submit]):not([type=button]):not([type=reset]),
:root[data-skin="dark"] select,
:root[data-skin="dark"] textarea{ background:var(--mezo-hatter); color:var(--ink); border-color:var(--mezo-keret); }
/* A helyőrző halványabb, de sötét alapon is olvasható marad. */
:root[data-skin="dark"] input::placeholder,
:root[data-skin="dark"] textarea::placeholder{ color:var(--muted); opacity:1; }
:root[data-skin="dark"] .tag-off{ background:rgba(255,255,255,.07); color:var(--muted); }
:root[data-skin="dark"] .tag-base{ background:rgba(61,130,240,.16); color:#9dc0ff; }
:root[data-skin="dark"] .tag-warn{ background:rgba(255,186,73,.14); color:#ffcf7a; }
:root[data-skin="dark"] .alert-success{ border-color:rgba(79,224,198,.35); }
:root[data-skin="dark"] .alert-error{ border-color:rgba(255,154,164,.35); }
:root[data-skin="dark"] .sidebar-toggle:hover{ background:rgba(255,255,255,.06); }

/* ===== Megjelenés-választó a Profil oldalon ===== */
.appearance-picker{ display:flex; flex-wrap:wrap; gap:12px; margin:4px 0 0; }
.appearance-opt{ cursor:pointer; border:1px solid var(--line); border-radius:12px; padding:12px; width:150px; background:var(--surface); box-shadow:var(--shadow); transition:border-color .12s, transform .08s; }
.appearance-opt:hover{ transform:translateY(-1px); }
.appearance-opt input{ position:absolute; opacity:0; pointer-events:none; }
.appearance-opt.sel{ border-color:var(--accent); box-shadow:0 0 0 2px var(--accent) inset, var(--shadow); }
.appearance-swatch{ height:46px; border-radius:8px; border:1px solid rgba(0,0,0,.06); position:relative; overflow:hidden; }
.appearance-swatch i{ position:absolute; left:0; top:0; bottom:0; width:34%; display:block; }
.appearance-name{ margin-top:8px; font-weight:600; font-size:.9rem; color:var(--ink); }
.appearance-desc{ font-size:.76rem; color:var(--muted); }

.app-topbar { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--line); background: var(--surface); position: sticky; top: 0; z-index: 30; }
.sidebar-toggle { background: transparent; border: 1px solid var(--line); border-radius: 8px; width: 38px; height: 36px; font-size: 1.1rem; cursor: pointer; color: var(--ink); line-height: 1; }
.sidebar-toggle:hover { background: rgba(0,0,0,.04); }
.app-topbar-title { font-weight: 600; color: var(--muted); font-size: .95rem; }
/* Tulajdonosi nézet: menü helyett név + kilépés a sáv jobb szélén. */
.tulaj-user { margin-left: auto; display: flex; align-items: center; gap: 14px; font-size: .9rem; color: var(--muted); }
.tulaj-user a { font-weight: 600; }
.app-main .wrap { margin: 0 auto; padding-top: 22px; }
.sidebar-backdrop { display: none; }

@media (max-width: 900px) {
    .sidebar { position: fixed; left: 0; top: 0; height: 100vh; z-index: 80; margin-left: 0; transform: translateX(-100%); transition: transform .2s ease; box-shadow: 0 0 40px rgba(0,0,0,.4); }
    body.nav-open .sidebar { transform: translateX(0); }
    .sidebar-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 70; }
    body.nav-open .sidebar-backdrop { display: block; }
    .app-shell { display: block; }
}

/* ===== Lista szűrés + rendezés ===== */
.list-toolbar { display: flex; align-items: flex-end; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.list-filter { flex: 0 0 320px; max-width: 100%; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; font-size: .92rem; }
.list-count { color: var(--muted); font-size: .85rem; }
table.sortable th.th-sort { cursor: pointer; user-select: none; white-space: nowrap; }
table.sortable th.th-sort:hover { color: var(--ink); }
.sort-caret { margin-left: 4px; font-size: .72em; opacity: .5; }
table.sortable th.th-sort.sorted .sort-caret::after { content: '▲'; }
table.sortable th.th-sort.sorted[data-dir="desc"] .sort-caret::after { content: '▼'; }

/* ===== Akadálymentes fókuszkeret ===== */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible,
textarea:focus-visible, [tabindex]:focus-visible, summary:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}
/* A lekerekített körvonal a linknek, a gombnak és a többi NEM mezőnek. A mezőnek saját sarka van: a 4 px
   fókuszkor ráíródott, és a 8 px-es mező sarka „ugrott”. */
a:focus-visible, button:focus-visible, summary:focus-visible, [tabindex]:not(input, select, textarea):focus-visible { border-radius: 4px; }
/* A szöveges mezők, legördülők és szövegdobozok fókusza a saját keretük + gyűrűjük (fent, „Űrlapmezők”):
   mellette a külső körvonal kettőzött jel volna. A jelölőnégyzet, a rádió, a fájlválasztó és a gomb a
   körvonalat tartja. A célzott (osztályos) mezőszabályok a saját fókuszukat tartják (pl. a táblázatos
   szerkesztők belső körvonala): a specificitásuk ezzel egyenlő, és a lap stílusa később jön. */
input:not([type=checkbox], [type=radio], [type=file], [type=range], [type=color], [type=submit], [type=button],
          [type=reset], [type=image]):focus-visible,
select:focus-visible, textarea:focus-visible { outline: none; }

/* ===== Dupla-beküldés: foglalt gomb ===== */
.btn.is-busy, button.is-busy { opacity: .65; cursor: progress; }

/* ===== Toast üzenetek ===== */
/* A doboz a felső sáv ALATT (57 px a ragadós fejléc), és maga nem fogja el a kattintást (2026-11-21): korábban a 16 px-en
   ülő doboz az elhalványult (átlátszó) üzenettel együtt a helyén maradt, és letakarta a csengőt — mobilon a teljes felső
   sávot, a menügombbal együtt —, így egy elfogadás vagy aláírás utáni lapon semmi nem reagált fent. Az üzenetet az app.js
   az elhalványulás után ki is veszi. */
.toast-wrap { position: fixed; top: 68px; right: 16px; z-index: 200; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 12px; min-width: 240px; max-width: 380px;
    padding: 12px 14px; border-radius: 10px; background: var(--surface);
    border: 1px solid var(--line); box-shadow: 0 10px 30px rgba(28,36,33,.18);
    font-size: .92rem; animation: toast-in .2s ease; }
.toast-success { border-left: 4px solid var(--accent); }
.toast-error { border-left: 4px solid var(--danger); }
.toast-msg { flex: 1 1 auto; }
.toast-close { background: transparent; border: 0; font-size: 1.15rem; line-height: 1; cursor: pointer; color: var(--muted); padding: 0 2px; }
.toast-close:hover { color: var(--ink); }
.toast-hide { opacity: 0; transform: translateX(10px); transition: opacity .3s ease, transform .3s ease; pointer-events: none; }
@keyframes toast-in { from { opacity: 0; transform: translateX(12px); } to { opacity: 1; transform: none; } }
@media (max-width: 600px) { .toast-wrap { left: 12px; right: 12px; } .toast { max-width: none; } }

/* ===== Ragadós (sticky) táblafejléc a listákon ===== */
.card:has(> table.data) { overflow: visible; }
table.data thead th {
    /* 57 px: ennyi a ragadós fejléc valódi magassága (mérve). A korábbi 54 három
       pixellel a fejléc alá csúsztatta a táblafejlécet. */
    position: sticky; top: 57px; z-index: 4;
    background: #f0efe8; box-shadow: inset 0 -1px 0 var(--line);
}
/* Vízszintesen görgethető riport-kártyákban a sticky fejléc belelógna az első sorba,
   ezért ott kikapcsoljuk. */
.no-sticky-thead table.data thead th { position: static; top: auto; box-shadow: none; }

/* ===== Sáv-menü: ikon + felirat, és mini (összecsukott) változat ===== */
.sidenav-link { display: flex; align-items: center; gap: 10px; }
.sidenav-link .ico { flex: 0 0 22px; width: 22px; text-align: center; font-size: 1.02rem; }
.sidenav-link .lbl { flex: 1 1 auto; }
/* Olvasatlan-számláló a menüpont mellett (levelező, 2026-11-02); összecsukott sávnál az ikon sarkán. */
.sidenav-link { position: relative; }
.sidenav-link .nav-jelzo { flex: 0 0 auto; min-width: 18px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: #fff;
    font-size: .72rem; font-weight: 700; line-height: 18px; text-align: center; }
body.nav-collapsed .sidenav-link .nav-jelzo { position: absolute; top: 3px; right: 8px; min-width: 16px; padding: 0 4px; line-height: 16px; font-size: .66rem; }

body.nav-collapsed .sidebar { margin-left: 0; width: 66px; flex-basis: 66px; }
body.nav-collapsed .sidebar .brand { justify-content: center; padding: 16px 0; }
body.nav-collapsed .sidebar .brand-text { display: none; }
body.nav-collapsed .sidenav-label { display: none; }
body.nav-collapsed .sidenav-group { margin-top: 6px; padding-top: 6px; border-top: 1px solid rgba(255,255,255,.06); }
body.nav-collapsed .sidenav-link { justify-content: center; padding: 10px 0; border-left: 0; gap: 0; }
body.nav-collapsed .sidenav-link.active { border-left: 0; box-shadow: inset 3px 0 0 #38bdf8; }
body.nav-collapsed .sidenav-link .lbl { display: none; }
body.nav-collapsed .sidebar-user { text-align: center; padding: 12px 6px; }
body.nav-collapsed .sidebar-user .su-name { display: none; }
body.nav-collapsed .sidebar-user .su-links { flex-direction: column; align-items: center; gap: 6px; }

/* mobilon a mini-sáv nem érvényes (ott off-canvas a teljes menü) */
@media (max-width: 900px) {
    body.nav-collapsed .sidebar { width: 250px; flex-basis: 250px; }
    body.nav-collapsed .sidebar .brand { justify-content: flex-start; padding: 16px 18px; }
    body.nav-collapsed .sidebar .brand-text { display: inline; }
    body.nav-collapsed .sidenav-label { display: block; }
    body.nav-collapsed .sidenav-link { justify-content: flex-start; padding: 8px 18px; gap: 10px; }
    body.nav-collapsed .sidenav-link .lbl { display: inline; }
    body.nav-collapsed .sidebar-user { text-align: left; padding: 12px 18px; }
    body.nav-collapsed .sidebar-user .su-name { display: block; }
    body.nav-collapsed .sidebar-user .su-links { flex-direction: row; align-items: center; }
    table.data thead th { position: static; }
}

/* ===== Nyomtatás finomítás ===== */
@media print {
    @page { margin: 14mm; }
    body { background: #fff; }
    .toast-wrap { display: none !important; }
    table.data thead th { position: static; background: #eee; }
    table.data, table.data th, table.data td { border-color: #999 !important; }
}

/* ===== Garancia ügyek + fotó-előnézet ===== */
.wc-badge { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .78rem; font-weight: 600; background: #e7f0ff; color: #1e40af; }
.wc-badge-final { background: var(--ok-bg); color: var(--ok-ink); }
.wc-badge-reject { background: var(--danger-bg); color: #b3261e; }
:root[data-skin="dark"] .wc-badge { background: rgba(61,130,240,.16); color: #9dc0ff; }
:root[data-skin="dark"] .wc-badge-reject { color: var(--danger); }
.wc-num { font-weight: 700; }
.wc-info > div { padding: 3px 0; }
.wc-photos { display: flex; flex-wrap: wrap; gap: 8px; }
.wc-photo img { width: 110px; height: 110px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); display: block; }
.wc-timeline { display: flex; flex-direction: column; gap: 10px; }
.wc-tl-item { display: flex; gap: 12px; }
.wc-tl-when { flex: 0 0 130px; color: var(--muted); font-size: .82rem; }
.wc-tl-body { flex: 1 1 auto; }
.ph-thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.ph-thumb { position: relative; }
.ph-thumb img { width: 84px; height: 84px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); display: block; }
.ph-del { position: absolute; top: -6px; right: -6px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: var(--danger); color: #fff; cursor: pointer; line-height: 1; }
.ph-note { font-size: .82rem; color: var(--muted); margin-top: 4px; }

/* ===== Lapozó ===== */
.pager { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 14px; }
.pager .pager-cur { background: var(--accent); color: #fff; border-color: var(--accent); pointer-events: none; }
.pager .pager-dots { color: var(--muted); padding: 0 4px; }
.list-per { margin-left: auto; color: var(--muted); font-size: .9rem; }
.list-per a { margin: 0 3px; }
.list-per strong { margin: 0 3px; color: var(--accent); }

/* ===== Kép-galéria (lightbox) ===== */
.lb-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.9); z-index: 1000; display: flex; align-items: center; justify-content: center; }
.lb-img { max-width: 92vw; max-height: 86vh; object-fit: contain; border-radius: 6px; }
.lb-close { position: absolute; top: 10px; right: 16px; font-size: 2.2rem; line-height: 1; background: none; border: 0; color: #fff; cursor: pointer; }
.lb-nav { position: absolute; top: 50%; transform: translateY(-50%); font-size: 2.4rem; background: rgba(0,0,0,.35); border: 0; color: #fff; cursor: pointer; padding: 6px 16px; border-radius: 8px; }
.lb-prev { left: 10px; } .lb-next { right: 10px; }

/* Szerveroldali kereső a listán */
.list-search { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.list-search input[type=search], .list-search select {
    box-sizing: border-box; min-height: 44px; padding: 8px 11px;
    border: 1px solid var(--mezo-keret); border-radius: var(--mezo-kerekites); font: inherit; color: var(--ink);
    background: var(--mezo-hatter);
}
.list-search input[type=search] { min-width: 240px; flex: 1 1 240px; }
.list-search select { flex: 0 1 auto; }
@media (max-width: 720px) {
    .list-search { width: 100%; }
    .list-search input[type=search], .list-search select, .list-search .btn, .list-search button {
        flex: 1 1 100%; width: 100%; min-width: 0;
    }
}

/* ===== Árajánlat-modul űrlap-rács ===== */
/* Egy sorba kerülő mezők BEVITELI RÉSZE igazodjon, akkor is, ha az egyik címke
   két sorba tördel (pl. „Kategória (üresen minden kategóriára vonatkozik)" az
   „Adattípus" mellett). A `.field` maga rácselem, ezért benne kell a címke
   fölé tolni a helyet: a mező a doboz aljára kerül, így a két beviteli mező
   egy vonalban áll. Enélkül a hosszabb címkéjű oszlop lecsúszik (#52). */
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 18px; align-items: end; }
.form-grid > .field { display: flex; flex-direction: column; justify-content: flex-end; }
/* a display:flex különben felülírná a hidden attribútumot: a rejtettnek szánt mező látszott, a mentés
   viszont eldobta az értékét (2026-11-11, a felülvizsgálat leválasztási módja) */
.form-grid > .field[hidden] { display: none; }
/* Az egy sorba kerülő mezők CÍMKÉJE két sor magas helyet kap. Az `align-items:end`
   csak akkor igazít, ha a doboz alja közös — a beviteli mezők viszont így is
   elcsúsznak, mert az egysoros címke rövidebb dobozt ad. Két sor a rácsban álló
   mezőkre elég: a hosszabb magyarázatok is elférnek, a rövidek pedig ugyanonnan
   indulnak. (#52) */
.form-grid > .field { grid-column: 1 / -1; }
.form-grid > .field.half { grid-column: span 1; }
@media (max-width: 680px) {
    .form-grid { grid-template-columns: 1fr; }
    .form-grid > .field.half { grid-column: 1 / -1; }
}
.block-title { font-size: 1.05rem; font-weight: 600; margin: 0 0 12px; }
.checkline { display: flex; gap: 8px; align-items: flex-start; cursor: pointer; line-height: 1.4; }
.checkline input { margin-top: 3px; }
.data.tight td { padding: 5px 8px; }
.section-row td { padding-top: 10px !important; }
@media (max-width: 820px) {
    .grid-2 { grid-template-columns: 1fr !important; }
}

/* Soron belüli szerkesztő mezők az ajánlat tételeknél */
.inp-sm { width: 72px; padding: 4px 6px; text-align: right; }
.inp-md { width: 104px; padding: 4px 6px; text-align: right; }

/* ===== Árajánlat-szerkesztő elrendezés ===== */
.quote-cols { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
.quote-cols > div { min-width: 0; }   /* engedjük zsugorodni, hogy ne lógjon át a jobb oszlopra */
.quote-lines-wrap { overflow-x: auto; }
@media (max-width: 1000px) { .quote-cols { grid-template-columns: 1fr; } }
.quote-lines { font-size: .9rem; }
.quote-lines th, .quote-lines td { padding: 8px 10px; vertical-align: middle; }
.quote-lines td.num, .quote-lines th.num { white-space: nowrap; }   /* nettó/bruttó/haszon egy sorban */
.quote-lines .unit { margin-left: 4px; }
/* A tételsor „mentve” / hibaüzenete asztalon a gombok bal oldalán lebeg, nem foglal helyet (2026-10-28): elhalványulva
   is ott maradna, és az első mentés után ~46 px-szel szélesítené a gombok oszlopát — az egész tábla átrendeződne.
   Telefonon (kártyás nézet) a gombok fölött marad, a sorban. */
@media (min-width: 721px) {
    .quote-lines td.actions { position: relative; }
    .quote-lines td.actions .livesave-hely { position: absolute; right: calc(100% - 2px); top: 50%; transform: translateY(-50%); z-index: 1; pointer-events: none; }
    .quote-lines td.actions .livesave-status { display: block; margin: 0; padding: 2px 6px; border-radius: 6px; background: var(--surface); white-space: nowrap; }
    .quote-lines td.actions .livesave-status.is-error { white-space: normal; width: max-content; max-width: 16rem; box-shadow: var(--shadow); }
}
.quote-sum td { white-space: nowrap; padding: 6px 8px; }
.quote-sum td:last-child { text-align: right; }

/* ===== Árajánlat: széles nézet + ragadós összegzés-sáv ===== */
.wrap-wide { max-width: 1320px; }
/* szélesebb (a monitoring-dashboard, 2026-10-08): több fér el, de nem nyúlik szét — a felhasználó
   1480 px-et túl szélesnek találta, 1180 px-et kért */
.wrap-xl { max-width: 1180px; }
.quote-summary {
    position: sticky; top: 53px; z-index: 20;
    display: flex; flex-wrap: wrap; align-items: center; gap: 8px 24px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
    box-shadow: var(--shadow); padding: 12px 18px; margin-bottom: 14px;
}
.qs-item { display: flex; flex-direction: column; line-height: 1.2; }
.qs-item[hidden] { display: none; }   /* a display:flex különben felülírná a hidden attribútumot */
.qs-label { font-size: .7rem; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.qs-val { font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.qs-strong .qs-val { font-size: 1.12rem; color: var(--accent); }
.qs-muted .qs-label, .qs-muted .qs-val { color: var(--muted); font-weight: 500; }
.qs-sep { width: 1px; align-self: stretch; background: var(--line); margin: 2px 2px; }
@media (max-width: 700px) { .quote-summary { gap: 6px 14px; } .qs-sep { display: none; } }

/* Árajánlat státusz-bannerek */
.notice { border-radius: var(--radius); padding: 10px 14px; margin-bottom: 14px; font-size: .9rem; border: 1px solid; }
.notice-lock { background: #f4f1fb; border-color: #d9cef0; color: #5b4a8a; }
.notice-warn { background: #fff7e6; border-color: #f0dca0; color: #8a6d1a; }
.wc-badge-exp { background: #fff0f0; border: 1px solid #f0caca; color: #a23; border-radius: 999px; padding: 1px 8px; font-size: .75rem; margin-left: 4px; }
:root[data-skin="dark"] .wc-badge-exp { background: rgba(255,92,108,.14); border-color: rgba(255,107,107,.35); color: #ff9aa4; }

/* Széles listák (pl. Termékek katalógus) tömörebb megjelenése */
.wrap-wide .data { font-size: .9rem; }
.wrap-wide .data th, .wrap-wide .data td { padding: 7px 9px; }
/* A projektlista tömör nézete (2026-11-18): kisebb betű, kétsoros sávok — így elfér az iratok beadhatósága, a bekérő
   és az ajánlat állása is. A cellák szerkezete a régi (stack2); csak a méretek kisebbek. */
.lista-tomor table.data { font-size: .84rem; }
.lista-tomor .cust-addr, .lista-tomor .stack2 .s2b { font-size: .76rem; }
.lista-tomor .tag { font-size: .72rem; padding: 1px 7px; }
/* a gombok két sorban: fent a „Megnyitás”, alatta a „Szerkesztés” és a „Törlés” — így a sáv két sor magas, mint a többi
   cella (a #listTable alapszabálya hármat tesz egymás alá) */
@media (min-width: 721px) {   /* csak asztalon: a mobil kártyán a gombok teljes szélességűek maradnak */
    .lista-tomor #listTable td.actions { white-space: nowrap; vertical-align: middle; }
    .lista-tomor #listTable td.actions .btn { padding: 2px 6px; font-size: .74rem; }
    .lista-tomor #listTable td.actions > a.btn:first-child { display: block; width: 100%; margin: 0 0 4px; }
    .lista-tomor #listTable td.actions > a.btn + a.btn { display: inline-block; width: auto; margin: 0 4px 0 0; }
    .lista-tomor #listTable td.actions > form.inline { display: inline-block; margin: 0; }
    .lista-tomor #listTable td.actions > form.inline .btn { width: auto; }
}
.lista-tomor .irat-sor { display: block; white-space: nowrap; line-height: 1.55; }
.lista-tomor .irat-sor + .irat-sor { margin-top: 2px; }
/* asztalon a cellák sorai egy-egy sorra vágva (a teljes szöveg a `title`-ben): így a sáv két sor magas marad */
@media (min-width: 721px) {
    .lista-tomor .stack2, .lista-tomor .cust-name, .lista-tomor .cust-addr { max-width: 10.5em; }
    .lista-tomor #listTable th:first-child, .lista-tomor #listTable td:first-child { padding-left: 6px; padding-right: 0; }
    .lista-tomor #listTable thead th { font-size: .68rem; letter-spacing: .02em; padding-left: 7px; padding-right: 7px; }
    .lista-tomor #listTable tbody td { padding-left: 7px; padding-right: 7px; }
    /* ha keskeny a képernyő (oldalsávval 1440 px alatt), a kártyán belül görgethető — nem vágódik le a gombok oszlopa */
    .card.lista-tomor { overflow-x: auto; }
    .lista-tomor .stack2 > span, .lista-tomor .cust-name, .lista-tomor .cust-addr { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
}
@media (max-width: 720px) {
    .lista-tomor .irat-sor { white-space: normal; }
}

/* ===== Hibajegy / RMA modul ===== */
.tk-dash { display: flex; gap: 12px; flex-wrap: wrap; }
.tk-stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 16px; min-width: 96px; }
.tk-stat .n { display: block; font-size: 1.5rem; font-weight: 700; color: var(--ink); }
.tk-stat .l { font-size: .78rem; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.tk-prio { display: inline-block; border-radius: 999px; padding: 1px 9px; font-size: .78rem; font-weight: 600; }
.prio-1 { background: #eef1f4; color: #5a6470; }
.prio-2 { background: #e4eefb; color: #1f5fa8; }
.prio-3 { background: #fdeede; color: #8f5215; }
.prio-4 { background: #fde4e4; color: #b02a2a; }
.tk-rma { display: inline-block; background: #ece3fb; color: #6b3fb0; border-radius: 999px; padding: 1px 8px; font-size: .72rem; font-weight: 700; margin-left: 6px; }
.tk-meta { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 10px 22px; margin-bottom: 6px; }
.tk-meta .k { display: block; font-size: .72rem; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.tk-meta .v { font-weight: 600; }
.tk-sub { font-size: .95rem; margin: 14px 0 4px; color: var(--ink); }
.tk-text { white-space: pre-wrap; line-height: 1.55; margin: 0; }
.tk-timeline { display: flex; flex-direction: column; gap: 10px; }
.tk-entry { border: 1px solid var(--line); border-left: 3px solid #cfd6df; border-radius: 8px; padding: 9px 12px; }
.tk-entry.internal { border-left-color: #c8b6ec; background: #faf8fe; }
.tk-entry-head { display: flex; gap: 10px; align-items: center; font-size: .85rem; margin-bottom: 4px; }
.tk-internal { background: #ece3fb; color: #6b3fb0; border-radius: 999px; padding: 0 7px; font-size: .7rem; font-weight: 700; }
.tk-entry-body { white-space: pre-wrap; line-height: 1.5; }

.auth-alt { text-align: center; margin-top: 14px; font-size: .9rem; }
.auth-alt a { color: var(--brand, #1f6f4a); text-decoration: none; }
.auth-alt a:hover { text-decoration: underline; }

/* ===== Csoportfejléc a részletlap tábláiban (2026-11-20, a Dokumentumtár szekciói: _generic/detail.php `csoportKulcs`) ===== */
/* a projekt ütemei (2026-11-20): az ütem fejléce a szekciók fölött */
table.data tr.gd-focsoport th {
    background: var(--sb-accent-bg); color: var(--ink); font-size: .95rem; font-weight: 700;
    text-align: left; padding: 10px 12px; border-top: 2px solid var(--accent);
}
table.data tr.gd-focsoport + tr.gd-csoport th { padding-top: 6px; }
table.data tr.gd-csoport th {
    text-align: left; padding: 14px 10px 6px; background: transparent; border-bottom: 2px solid var(--line);
    font-size: .8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--ink);
}
table.data tr.gd-csoport:first-child th { padding-top: 6px; }
.gd-csoport-db {
    display: inline-block; min-width: 1.5em; margin-left: 6px; padding: 0 6px; border-radius: 999px; background: var(--surface-2);
    color: var(--muted); font-size: .75rem; font-weight: 600; text-align: center; letter-spacing: 0;
}

/* ===== Sáv a részletlapon (2026-11-25, a projektlap OETP-szekciója: _generic/detail.php `sav`) =====
   A felhasználó: „az OETP pályázati szekciót a fő projekten belül hátterét átszínezném … kicsit sötétebb kékre”. A szín a bőr
   kiemelőszínéből és a lap hátteréből keverve: világos bőrön a lapnál sötétebb kék, a sötét bőrön a lapnál kékebb, világosabb
   tónus — a kártyák (fehér / sötét felület) kiválnak belőle. A sávban a halvány szöveg a tintához közelít (a kevert háttéren
   a bőr `--muted`-je az AA alá esne). `color-mix` nélkül a fix tartalék színek. */
:root { --sav-oetp-hatter: #d9e6f7; --sav-oetp-keret: #aec8ee; --sav-oetp-halvany: #46556d; }
:root[data-skin="dark"] { --sav-oetp-hatter: #132849; --sav-oetp-keret: #24467c; --sav-oetp-halvany: #b3c0d4; }
@supports (color: color-mix(in srgb, red 50%, transparent)) {
    :root, :root[data-skin="dark"] {
        --sav-oetp-hatter:  color-mix(in srgb, var(--accent) 13%, var(--bg));
        --sav-oetp-keret:   color-mix(in srgb, var(--accent) 38%, var(--line));
        --sav-oetp-halvany: color-mix(in srgb, var(--muted) 55%, var(--ink));
    }
    :root[data-skin="dark"] { --sav-oetp-hatter: color-mix(in srgb, var(--accent) 17%, var(--bg)); }
}
.gd-sav { border-radius: var(--radius); padding: 14px 14px 1px; margin-bottom: 26px; }
.gd-sav > .child-section:last-child { margin-bottom: 14px; }
.gd-sav-oetp { background: var(--sav-oetp-hatter); border: 1px solid var(--sav-oetp-keret); --muted: var(--sav-oetp-halvany); }
@media (max-width: 720px) { .gd-sav { padding: 10px 8px 1px; } }
/* az OETP-ütem fejléce a megosztott táblákban (Dokumentumtár, eszközök …) ugyanabban a színben: ez az ütem az OETP-é */
table.data tr.gd-focsoport.gd-focsoport-oetp th { background: var(--sav-oetp-hatter); border-top-color: var(--sav-oetp-keret); }
/* a galéria ütem-fejléce (2026-11-25, a fotók ütemenként): a rács teljes szélességében, mint a táblák főcsoportja */
.gallery .gal-csoport { grid-column: 1 / -1; background: var(--sb-accent-bg); color: var(--ink); font-size: .95rem; font-weight: 700;
    padding: 8px 12px; border-top: 2px solid var(--accent); border-radius: 6px; }
.gallery .gal-csoport.gd-focsoport-oetp { background: var(--sav-oetp-hatter); border-top-color: var(--sav-oetp-keret); }

/* ===== Listák mobil kártyás nézete (.cards-mobile) ===== */
@media (max-width: 720px) {
    .cards-mobile thead { display: none; }
    .cards-mobile, .cards-mobile tbody, .cards-mobile tr, .cards-mobile td { display: block; width: 100%; }
    .cards-mobile tr {
        border: 1px solid var(--line); border-radius: 12px; margin-bottom: 12px;
        padding: 10px 14px; background: var(--surface); box-shadow: 0 1px 3px rgba(0,0,0,.05);
    }
    .cards-mobile td {
        border: none !important; padding: 5px 0; display: flex; align-items: baseline;
        justify-content: space-between; gap: 14px; text-align: right;
        overflow-wrap: anywhere;   /* hosszú érték (dátum, cím) a kártyán belül törjön */
    }
    /* A CÍMKE IS TÖRHET (2026-11-18): `flex: 0 0 auto` mellett a hosszú címke („Születési hely • idő / adószám”) nem tört,
       és az értéket kitolta a kártyából (PV26/129, mobil). Most legfeljebb a sor fele, utána új sorban folytatódik. */
    .cards-mobile td::before {
        content: attr(data-label); font-weight: 600; color: var(--muted);
        text-align: left; flex: 0 1 auto; max-width: 50%; font-size: .82rem; text-transform: uppercase; letter-spacing: .02em;
        overflow-wrap: normal;   /* a címke csak szóhatáron törjön („BEADHAT-Ó” ne legyen); az érték bárhol */
    }
    .cards-mobile td:empty { display: none; }
    .cards-mobile td[data-label=""]::before { display: none; }
    .cards-mobile td.strong {
        font-size: 1.12rem; padding-bottom: 8px; margin-bottom: 4px; border-bottom: 1px solid var(--line) !important;
        flex-direction: column; align-items: stretch; text-align: left; gap: 2px;
    }
    .cards-mobile td.strong::before { text-align: left; }
    .cards-mobile td.actions {
        flex-direction: column; align-items: stretch; gap: 6px; padding-top: 10px;
        margin-top: 4px; border-top: 1px solid var(--line) !important;
    }
    .cards-mobile td.actions::before { display: none; }
    .cards-mobile td.actions .btn,
    .cards-mobile td.actions form.inline,
    .cards-mobile td.actions form.inline .btn { width: 100%; text-align: center; }
    .cards-mobile td.actions form.inline { margin-left: 0; }   /* a 6 px-es asztali térköz a teljes szélességű gombot kitolná */
    /* a csoportfejléc nem kártya, hanem cím a kártyák fölött */
    .cards-mobile tr.gd-focsoport { border: 0; box-shadow: none; background: transparent; padding: 14px 0 0; margin: 0; }
    .cards-mobile tr.gd-focsoport th { display: block; border-radius: 8px; }
    .cards-mobile tr.gd-csoport { border: 0; box-shadow: none; background: transparent; padding: 10px 2px 2px; margin-bottom: 6px; }
    .cards-mobile tr.gd-csoport th { display: block; padding: 0; border: 0; }
}


/* ===== Raktár / Készlet ===== */
.wh-balance { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.wh-balance-label { font-size: .8rem; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
.wh-balance-value { font-size: 2rem; font-weight: 800; color: var(--ink); }
.wh-balance-value small { font-size: 1rem; font-weight: 600; color: var(--muted); }
.wh-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.wh-btns { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.wh-btns .btn { flex: 1 1 auto; min-width: 120px; }
@media (max-width: 720px) {
    .wh-actions { grid-template-columns: 1fr; }
    .wh-btns .btn { flex: 1 1 100%; }
}

/* --- Új arculat (logók) --- */
.auth-logo{display:block;max-width:300px;width:82%;height:auto;margin:0 auto 6px}
.sidebar .brand-logo{height:30px;width:auto;display:block;flex:0 0 auto}
.app-topbar .brand-logo{height:24px;width:auto;vertical-align:middle;margin-right:8px}

/* ===== Sor-művelet menü (kebab) – asztali lenyíló, mobilon inline ===== */
.row-menu { position: relative; display: inline-block; }
.row-menu-pop { display: none; position: absolute; right: 0; top: calc(100% + 4px); background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); z-index: 50; min-width: 190px; padding: 5px; }
.row-menu.open .row-menu-pop { display: block; }
.row-menu-pop a, .row-menu-pop button { display: flex; align-items: center; gap: 8px; width: 100%; box-sizing: border-box; text-align: left; padding: 8px 11px; background: none; border: none; border-radius: 7px; font: inherit; color: var(--ink); cursor: pointer; text-decoration: none; white-space: nowrap; }
.row-menu-pop a:hover, .row-menu-pop button:hover { background: var(--bg); }
.row-menu-pop form { margin: 0; }
@media (max-width: 720px) {
    .row-menu, .row-menu-pop { display: block; position: static; }
    .row-menu-toggle { display: none; }
    .row-menu-pop { box-shadow: none; border: none; padding: 0; min-width: 0; background: none; }
    .row-menu-pop a, .row-menu-pop button { width: 100%; justify-content: center; text-align: center; border: 1px solid var(--line); border-radius: var(--radius); margin-top: 6px; padding: 9px; }
}

/* Szűrő/kereső gombok azonos magasak a velük egy sorban lévő mezőkkel */
.list-search .btn, .list-search button,
.list-toolbar .btn, .list-toolbar button,
.ov-filter .btn, .ov-filter button { min-height: 44px; box-sizing: border-box; }

/* ---- PV projekt fotó-galéria + lightbox (#3) ---- */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin: 8px 0; }
.gal-item { margin: 0; border: 1px solid #e6e8ee; border-radius: 10px; overflow: hidden; background: #fff; display: flex; flex-direction: column; }
.gal-link { display: block; aspect-ratio: 4 / 3; overflow: hidden; background: #f2f3f6; cursor: zoom-in; }
.gal-link img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gal-pdf { display: flex; align-items: center; justify-content: center; aspect-ratio: 4 / 3; background: #f2f3f6; color: #b23b3b; text-decoration: none; font-weight: 600; font-size: .9rem; }
.gal-item figcaption { padding: 6px 8px; font-size: .78rem; }
.gal-type { display: block; font-weight: 600; color: #333; }
.gal-cap { display: block; color: #777; }
.gal-actions { display: flex; gap: 8px; margin-top: 4px; flex-wrap: wrap; }
.gal-lightbox { position: fixed; inset: 0; z-index: 1000; background: rgba(0,0,0,.88); display: none; flex-direction: column; align-items: center; justify-content: center; padding: 24px; }
.gal-lightbox:not([hidden]) { display: flex; }
.gal-lightbox .gal-full { max-width: 96vw; max-height: 86vh; object-fit: contain; border-radius: 6px; }
.gal-fullcap { color: #fff; margin-top: 12px; font-size: .9rem; text-align: center; max-width: 90vw; }
.gal-close { position: absolute; top: 14px; right: 18px; width: 40px; height: 40px; border: none; border-radius: 50%; background: rgba(255,255,255,.15); color: #fff; font-size: 1.5rem; line-height: 1; cursor: pointer; }
.gal-close:hover { background: rgba(255,255,255,.28); }

/* ---- Lista: műveleti gombok egymás alá, kompakt oszlop (#1) ---- */
#listTable td.actions { white-space: normal; vertical-align: top; }
#listTable td.actions .btn { display: block; width: 100%; margin: 0 0 4px; text-align: center; }
#listTable td.actions form.inline { display: block; margin: 0 0 4px; }
#listTable td.actions form.inline .btn { width: 100%; margin: 0; }

/* ---- Megrendelő + cím egy cellában, kitűzés (#1/#2) ---- */
.cust-name { font-weight: 600; }
.cust-addr { color: var(--muted); font-size: .82rem; margin-top: 2px; }
.pin-toggle { border: none; background: none; cursor: pointer; font-size: 1.05rem; line-height: 1; padding: 2px 4px; border-radius: 6px; filter: grayscale(1); opacity: .45; }
.pin-toggle:hover { background: #eef1f6; opacity: .8; }
.pin-toggle.is-pinned { filter: none; opacity: 1; }
tr.row-pinned td { background: #fffdf4; }

/* Kétsoros összevont lista-cella (Típus/Méret, Elosztó/POD, Eng./Kiv.) */
.stack2 { display: flex; flex-direction: column; line-height: 1.25; }
.stack2 .s2a { color: #23262e; }
.stack2 .s2b { color: var(--muted); font-size: .82rem; }
/* A `.s2a` beégetett #23262e-je sötét bőrön majdnem fekete a sötét táblán —
   1.12:1. A `.s2b` szürkéje véletlenül átment, ezért csak a felső sor tűnt el:
   a listában a „Kivitelezés · Naperőmű" olvashatatlan volt, a méret alatta nem. */
:root[data-skin="dark"] .stack2 .s2a { color: var(--ink); }
/* Fehér szöveg az `--accent`-en 3,72:1 volt a sötét bőrben. Nem magát az
   `--accent`-et sötétítjük, mert azt SZÖVEGSZÍNKÉNT is használjuk sötét
   háttéren (hivatkozás, aktív menüpont) — ott a sötétítés rontana. Csak a
   gomb háttere kap saját értéket: 4,81:1, hover 5,76:1. */
:root[data-skin="dark"] .btn-primary { background: #2f6fd6; border-color: #2f6fd6; }
:root[data-skin="dark"] .btn-primary:hover { background: #2a63c0; border-color: #2a63c0; }

/* Ugyanaz a csapda, csak késleltetve: kitűzött sor nélkül nem látszik, de egy
   kitűzés azonnal FEHÉR sort adna a sötét táblában, a téma világos szövegével. */
:root[data-skin="dark"] tr.row-pinned td { background: rgba(240,201,138,.10); }

/* ---- Kötelező-fotó sticky figyelmeztetés (#2) ---- */
/* NEM ragadós: a lap tetején, a tartalom élén áll. Ragadósan végig a képernyőn
   maradt, ott takart valamit (előbb a menüt, majd a táblafejléceket), és
   használat közben zavaró volt — a figyelmeztetés attól még elér a címzettjéhez,
   hogy csak a lap tetején látszik. */
.photo-alert { position: static; display: flex; align-items: flex-start; gap: 10px; flex-wrap: wrap; background: #fdecec; border: 1px solid #f0b6b6; border-left: 4px solid #d9534f; border-radius: 10px; padding: 10px 14px; margin: 0 0 14px; box-shadow: 0 2px 8px rgba(0,0,0,.06); }
.photo-alert .pa-ico { font-size: 1.1rem; line-height: 1.35; }
.photo-alert .pa-body { flex: 1 1 220px; min-width: 0; }
.photo-alert .pa-text { color: #a12d2d; display: block; margin-bottom: 5px; }
.photo-alert .pa-list { display: flex; flex-wrap: wrap; gap: 5px; }
.photo-alert .pa-chip { background: #fff; border: 1px solid #eab6b6; color: #9a3535; border-radius: 999px; padding: 2px 9px; font-size: .8rem; font-weight: 600; }
.photo-alert .pa-btn { flex: 0 0 auto; align-self: center; background: #d9534f; color: #fff; text-decoration: none; font-weight: 600; font-size: .85rem; padding: 7px 12px; border-radius: 8px; white-space: nowrap; }
.photo-alert .pa-btn:hover { background: #c9302c; }
/* Kicsinyítő gomb + minimalizált (ikon) állapot — #12 */
.photo-alert .pa-toggle { position: absolute; top: 6px; right: 8px; background: transparent; border: 0; color: #a12d2d; font-size: 1.15rem; line-height: 1; cursor: pointer; padding: 0 6px; border-radius: 6px; }
.photo-alert .pa-toggle:hover { background: rgba(217,83,79,.14); }
.photo-alert .pa-count { display: none; background: #d9534f; color: #fff; border-radius: 999px; font-size: .74rem; font-weight: 700; padding: 1px 7px; }
.photo-alert.pa-min { display: inline-flex; width: auto; align-items: center; gap: 7px; padding: 7px 11px; cursor: pointer; }
.photo-alert.pa-min .pa-body, .photo-alert.pa-min .pa-btn, .photo-alert.pa-min .pa-toggle { display: none; }
.photo-alert.pa-min .pa-count { display: inline-block; }
:root[data-skin="dark"] .photo-alert { background: rgba(217,83,79,.14); border-color: rgba(217,83,79,.5); }
:root[data-skin="dark"] .photo-alert .pa-text { color: #ff9aa4; }
:root[data-skin="dark"] .photo-alert .pa-chip { background: rgba(255,255,255,.06); border-color: rgba(217,83,79,.4); color: #ffb3bb; }

/* Galéria lightbox lapozás (nyilak + számláló) */
.gal-lightbox .gal-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 46px; height: 46px; border: none; border-radius: 50%; background: rgba(255,255,255,.15); color: #fff; font-size: 1.9rem; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.gal-lightbox .gal-nav:hover { background: rgba(255,255,255,.3); }
.gal-lightbox .gal-prev { left: 14px; }
.gal-lightbox .gal-next { right: 14px; }
.gal-lightbox .gal-counter { color: #cfd3da; margin-top: 6px; font-size: .82rem; }
@media (max-width: 600px) { .gal-lightbox .gal-nav { width: 40px; height: 40px; font-size: 1.5rem; } }

/* Garancialevél – berendezés-választó */
.wf-group { margin: 8px 0; border: 1px solid #eceef2; border-radius: 10px; overflow: hidden; }
.wf-role { background: #f5f6f9; padding: 6px 12px; font-weight: 700; font-size: .85rem; color: #3a3f4a; }
.wf-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-top: 1px solid #f2f3f6; cursor: pointer; }
.wf-item:first-of-type { border-top: none; }
.wf-item:hover { background: #fafbfd; }
.wf-item input { width: 18px; height: 18px; }
.wf-item .wf-name { flex: 1; }
.wf-item .wf-count { color: var(--muted); font-size: .82rem; white-space: nowrap; }

/* ===== Húzd-és-ejtsd fájlmező (#39) =====
   A .dropzone burkoló mindig kimegy; a .dz-on osztályt a dropzone.js teszi rá,
   ha a böngésző tudja a DataTransfer-t. Enélkül a natív input látszik. */
.dropzone.dz-on > input[type="file"] {
    /* Nem display:none — a rejtett input így is fókuszálható és kattintható. */
    position: absolute; width: 1px; height: 1px;
    opacity: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.dropzone.dz-on {
    display: block; position: relative;
    border: 2px dashed var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    padding: 18px 16px;
    text-align: center;
    transition: border-color .12s, background .12s;
}
.dropzone.dz-on:hover { border-color: var(--accent); }
.dropzone.dz-over {
    border-color: var(--accent);
    background: var(--bg); /* tartalék, ha a color-mix nincs meg */
    background: color-mix(in srgb, var(--accent) 8%, var(--surface));
}
.dropzone.dz-has { border-style: solid; border-color: var(--accent); }
.dz-hint { margin: 0 0 8px; color: var(--muted); font-size: .9rem; }
.dz-pick { cursor: pointer; }
.dz-list {
    margin: 10px 0 0; font-size: .88rem; color: var(--ink);
    font-family: var(--mono); word-break: break-all;
}
.dz-err { margin: 8px 0 0; font-size: .85rem; color: var(--danger); }
/* A fájlmező magyarázata és a képek előkészítésének állapota (2026-11-24, irat-kepek.js). */
.dz-sugo { margin: 6px 0 0; font-size: .85rem; color: var(--muted); }
.dz-allapot { margin: 6px 0 0; font-size: .9rem; color: var(--ink); overflow-wrap: anywhere; }
.dz-allapot.is-hiba { color: var(--danger); font-weight: 600; }

/* Élő mentés visszajelzése (public/assets/livesave.js). Közösben, mert több
   modul használja; a #47 sűrű táblázata a saját sablonjában felülírja a méretet. */
.livesave-status { font-size: .72rem; color: var(--muted); opacity: 0; transition: opacity .15s; margin-right: 5px; }
.livesave-status.is-on { opacity: 1; }
.livesave-status.is-error { color: var(--danger); font-weight: 700; opacity: 1; }
.livesave-hely { display: inline-block; min-width: 0; }


/* ===== STAGING-FIGYELMEZTETÉS =====================================
   A staging adatbázis prod-dumpból jön, valódi adatokkal: a két felület
   ránézésre MEGKÜLÖNBÖZTETHETETLEN. Volt már, hogy a monitoring rendszert
   hittük elromlottnak, miközben a staging példányt néztük.

   A sáv SZÁNDÉKOSAN NEM BEZÁRHATÓ és nem görgethető el: egy elrejthető
   figyelmeztetés az első bosszankodáskor eltűnne, és onnantól nem védene
   semmitől. Nyomtatásban viszont nincs rá szükség. */
.stg-sav {
    position: sticky; top: 0; z-index: 2000;
    display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
    padding: 6px 16px;
    background: #b3261e; color: #fff;
    font-size: .84rem; line-height: 1.4;
    box-shadow: 0 1px 6px rgba(0,0,0,.25);
}
.stg-sav strong { letter-spacing: .08em; }
.stg-sav code {
    margin-left: auto;
    background: rgba(255,255,255,.18); padding: 1px 8px; border-radius: 4px;
    font-size: .8rem;
}
/* A bal oldali menü fejléce a sáv ALÁ kerüljön, ne fölé. */
body.staging .sidebar { top: 0; }
@media print { .stg-sav { display: none; } }
@media (max-width: 720px) {
    /* Folyó szövegként, nem rácsban: flexben a három elem négy sorra esett
       szét, és a figyelmeztetés a képernyő nyolcadát elvette. */
    .stg-sav { display: block; font-size: .76rem; padding: 5px 12px; line-height: 1.35; }
    .stg-sav strong { margin-right: 6px; }
    .stg-sav span { display: inline; }
    .stg-sav code { margin-left: 6px; display: inline; font-size: .72rem; }
}


/* ===== PARTNERVÁLASZTÓ KERESÉSSEL (projektűrlap) ==================
   Több száz partnernél a legördülő kezelhetetlen; a keresés szerveroldali.
   Az „Új partner" a találatok TETEJÉN van: aki idáig eljutott, annak ez a
   következő lépése, és a lista aljára görgetni épp itt bosszantó. */
.pvp-valaszto { position: relative; }
.pvp-talalatok {
    position: absolute; left: 0; right: 0; z-index: 30;
    max-height: 340px; overflow-y: auto;
    background: var(--surface); border: 1px solid var(--line); border-radius: 8px;
    box-shadow: 0 6px 20px rgba(0,0,0,.12); margin-top: 4px;
}
.pvp-sor {
    display: block; width: 100%; text-align: left; cursor: pointer;
    padding: 9px 13px; border: 0; border-bottom: 1px solid var(--line);
    background: transparent; color: inherit; font: inherit;
}
.pvp-sor:last-child { border-bottom: 0; }
.pvp-sor:hover, .pvp-sor:focus { background: rgba(37,99,235,.08); outline: none; }
.pvp-sor strong { display: block; font-size: .92rem; }
.pvp-sor span { display: block; color: var(--muted); font-size: .8rem; margin-top: 1px; }
/* Az új-partner sor elválik a találatoktól: nem partner, hanem művelet. */
.pvp-uj-sor { background: rgba(37,99,235,.06); border-bottom: 2px solid var(--line); }
.pvp-nincs { padding: 10px 13px; color: var(--muted); font-size: .86rem; }
.pvp-kivalasztva { margin: 6px 0 0; font-size: .88rem; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.pvp-uj input { margin-bottom: 8px; }
.pvp-sug { color: var(--muted); font-size: .82rem; line-height: 1.5; margin: 2px 0 8px; }

/* ===== Sötét mód: a maradék beégetett világos hátterek (#63) ==================
   A HIBAMINTA: egy szabály beégetett VILÁGOS hátteret ír, a rá kerülő szöveg
   színe viszont a TÉMÁBÓL jön. Világos bőrön összeáll; sötéten fehér szöveg
   lesz fehér háttéren. A legrosszabb megtalált eset a `.ov-park` volt: 1.19:1.

   MIÉRT ÁTTETSZŐ RÉTEG, ÉS NEM ÚJ FIX SZÍN. Az `rgba(255,255,255,.0x)` ráúszik
   arra, ami alatta van, ezért a felület sötét marad, és egy későbbi
   téma-módosítás sem billenti át — a fix hex épp ettől romlana el újra.

   ── A) csoport: NINCS SAJÁT SZÖVEGSZÍNÜK ───────────────────────────────────
   Ezeknél a szöveg a témából jön, tehát sötét bőrön MOST IS majdnem-fehéren
   ülnek egy világos folton. Hogy a söprés nem fogta meg őket, az azért van,
   mert az érintett állapot (hover, nyitott menü) a mérés pillanatában nem állt
   elő — NEM azért, mert jó. A `:hover`-re a söprés elvileg sem tud ránézni. */
:root[data-skin="dark"] .navgroup-menu { background: var(--surface, #1b2130); border-color: rgba(255,255,255,.12); }
:root[data-skin="dark"] .navgroup-menu a:hover { background: rgba(255,255,255,.07); }
:root[data-skin="dark"] .ov-edit-time button:hover { background: rgba(255,255,255,.09); }
:root[data-skin="dark"] .ov-wadd button:hover { background: rgba(255,255,255,.09); }
:root[data-skin="dark"] .tk-entry.internal { background: rgba(160,130,230,.12); border-left-color: #8b6fd0; }
:root[data-skin="dark"] .gal-item { background: rgba(255,255,255,.04); border-color: rgba(255,255,255,.12); }
:root[data-skin="dark"] .gal-link { background: rgba(255,255,255,.06); }
:root[data-skin="dark"] .pin-toggle:hover { background: rgba(255,255,255,.09); }
:root[data-skin="dark"] .wf-item:hover { background: rgba(255,255,255,.06); }

/* ── B) csoport: MA OLVASHATÓ, de ugyanaz a csapda ────────────────────────────
   Ezek saját szövegszínt is állítanak, tehát önmagukban konzisztensek — csak
   világos csempék egy sötét lapon: vakítanak, és fontosabbnak látszanak a
   valóságosnál. A kockázat, hogy egy későbbi téma-módosítás bármelyiket
   átbillenti az A) csoportba. A háttér itt a szín ÁTTETSZŐ változata, a szöveg
   pedig a sötét háttérhez igazított világosabb árnyalat. */
:root[data-skin="dark"] .notice-lock { background: rgba(140,110,220,.14); border-color: rgba(140,110,220,.45); color: #c7b6f0; }
:root[data-skin="dark"] .notice-warn { background: rgba(230,180,40,.13); border-color: rgba(230,180,40,.45); color: #f0d68a; }
:root[data-skin="dark"] .prio-1 { background: rgba(255,255,255,.07); color: #b6bfcc; }
:root[data-skin="dark"] .prio-2 { background: rgba(90,160,230,.16); color: #9ec6f0; }
:root[data-skin="dark"] .prio-3 { background: rgba(230,170,60,.16); color: #f0c980; }
:root[data-skin="dark"] .prio-4 { background: rgba(220,70,70,.18); color: #ff9aa4; }
:root[data-skin="dark"] .tk-rma,
:root[data-skin="dark"] .tk-internal { background: rgba(140,110,220,.18); color: #c7b6f0; }
:root[data-skin="dark"] .gal-pdf { background: rgba(255,255,255,.06); color: var(--muted); }
:root[data-skin="dark"] .wf-role { background: rgba(255,255,255,.06); color: var(--muted); }
:root[data-skin="dark"] .sidebar-user .push-enable:hover { background: rgba(255,255,255,.12); color: var(--sb-ink); }

/* ── Nyelvválasztó (templates/_nyelvvalaszto.php) ─────────────────────────── */
.nyelv-valaszto { display: inline-flex; gap: 2px; padding: 2px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface, transparent); vertical-align: middle; }
.nyelv-valaszto a { padding: 4px 9px; border-radius: 999px; font: 600 11px/1 Inter, system-ui, sans-serif; letter-spacing: .06em; color: var(--muted); text-decoration: none; }
.nyelv-valaszto a:hover { color: var(--text); }
.nyelv-valaszto a.aktiv { background: var(--blue, #1E88FF); color: #fff; }
/* A belépő kártyán a jobb felső sarokban, a logó fölött. */
.auth-card > .nyelv-valaszto { display: flex; width: max-content; margin: 0 0 6px auto; }

/* ===== Számla a számla-háttérből (report.php?view=szamla) ===== */
.szh-kartya { margin-bottom: 16px; max-width: 760px; }
.szh-cim { font-size: 1.05rem; margin: 0 0 12px; }
.szh-racs { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; font-size: .93rem; }
.szh-racs .k { color: var(--muted); }
.szh-racs .e { min-width: 0; overflow-wrap: anywhere; }
.szh-osszeg { display: flex; flex-wrap: wrap; gap: 8px 26px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); }
.szh-osszeg > div { display: flex; flex-direction: column; gap: 2px; font-variant-numeric: tabular-nums; }
.szh-osszeg .muted { font-size: .8rem; }
.szh-osszeg .vegso b { font-size: 1.12rem; }
.szh-ket { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 18px; margin-top: 14px; }
#szh-telj[readonly] { background: var(--bg); color: var(--ink); cursor: default; }   /* számolt mező (Áfa tv. 58. §) */
.szh-sug { font-size: .84rem; margin: 8px 0 0; }
.szh-gombok { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.szh-cimzettek { display: flex; flex-direction: column; gap: 6px; }
.szh-megerosit { margin-top: 18px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; }
@media (max-width: 520px) { .szh-racs { grid-template-columns: 1fr; gap: 2px; } .szh-racs .k { margin-top: 6px; } }
.szh-kartya .btn:disabled { opacity: .5; cursor: not-allowed; }

/* ===== Dokumentum-aláíró (alairas.php) ===== */
.al-fejgombok { display: flex; flex-wrap: wrap; gap: 8px; }
.al-bevezeto { max-width: 760px; margin: 0 0 14px; font-size: .9rem; }
.al-cim { font-size: 1.05rem; margin: 0 0 10px; }
.al-sug { font-size: .85rem; margin: 6px 0 0; }
.al-sor { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 10px; }
.al-sor form { margin: 0; }
.al-ket { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 16px; }
.al-kepracs { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; margin-bottom: 16px; }
.al-kepkartya input[type=file] { max-width: 100%; font-size: .85rem; }
.al-kepelonezet { height: 120px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--line);
    border-radius: 8px; background-color: #fff;
    background-image: conic-gradient(#e9ecf1 25%, #fff 0 50%, #e9ecf1 0 75%, #fff 0); background-size: 16px 16px; }
.al-kepelonezet img { max-width: 90%; max-height: 104px; }
.al-rajzolo { max-width: 760px; margin-bottom: 16px; }
.al-pad { width: 100%; height: 180px; border: 1.5px dashed var(--line); border-radius: 10px; background: #fff; touch-action: none; display: block; }
.al-beallitas { max-width: 760px; }
.al-valaszto { max-width: 760px; }
.al-ejto { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 34px 16px;
    border: 2px dashed var(--line); border-radius: 12px; cursor: pointer; text-align: center; }
.al-ejto.rajta { border-color: var(--accent); background: var(--bg); }
.al-ejto input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.al-ejto-cim { font-weight: 600; }
/* a ragadós sáv az alkalmazás 57 px-es ragadós fejléce ALATT áll meg (mint a táblafejlécek); a nagy
   eszköztár nem ragad: top: 0-val a fejléc alá csúszott, és a lapozáshoz a sáv kell */
.al-plusz { position: sticky; top: 57px; z-index: 20; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px;
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
    padding: 8px 12px; margin: 12px auto 0; max-width: 900px; }
.al-plusz-cel { font-size: .9rem; }
.al-plusz-gombok { display: flex; gap: 6px; flex-wrap: wrap; }
.al-oldal-cel .al-oldal-fej span { color: var(--accent); font-weight: 600; }
.al-elem.uj { box-shadow: 0 0 0 5px rgba(22,104,216,.35); }
.al-elem { transition: box-shadow .4s; }
.al-eszk-sor { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; margin-bottom: 8px; }
.al-eszk-sor label { display: flex; gap: 6px; align-items: center; font-size: .9rem; }
.al-info { font-size: .9rem; }
.al-oldalak { display: flex; flex-direction: column; align-items: center; gap: 18px; margin: 16px 0; }
.al-oldal { max-width: 100%; }
.al-oldal-fej { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap;
    font-size: .85rem; color: var(--muted); margin-bottom: 6px; }
.al-lap { position: relative; background: #fff; box-shadow: 0 1px 6px rgba(0,0,0,.18); max-width: 100%; }
.al-lap canvas { display: block; width: 100%; height: 100%; }
.al-elem { position: absolute; border: 1.5px dashed rgba(22,104,216,.85); cursor: move; touch-action: none; box-sizing: border-box; }
.al-elem.mozog { border-style: solid; }
.al-elem img { width: 100%; height: 100%; display: block; pointer-events: none; user-select: none; -webkit-user-drag: none; }
.al-elem-cimke { position: absolute; left: -1px; top: -16px; font: 600 10px/14px system-ui, sans-serif; background: rgba(22,104,216,.9);
    color: #fff; padding: 0 5px; border-radius: 3px; white-space: nowrap; pointer-events: none; }
.al-elem-torol { position: absolute; top: -10px; right: -10px; width: 20px; height: 20px; border-radius: 50%; border: none;
    background: #b3261e; color: #fff; font: 700 13px/20px system-ui, sans-serif; cursor: pointer; padding: 0; }
.al-elem-fogo { position: absolute; right: -6px; bottom: -6px; width: 12px; height: 12px; background: #1668d8; border-radius: 3px; cursor: nwse-resize; }
.al-mentes { max-width: 900px; margin: 0 auto 24px; }
/* a hidden attribútum a lap saját elemein mindig nyerjen (a .checkline display: flex-e felülírná) */
#al-valaszto[hidden], #al-munka[hidden], #al-rajzolo[hidden], #al-dig-sor[hidden], #al-figy[hidden], #al-kesz[hidden], #al-hiba[hidden],
#al-konv[hidden], #al-hiba-valaszto[hidden], #al-plusz[hidden] { display: none !important; }
#al-hiba-valaszto { margin: 10px 0 0; }
.al-meretek { display: grid; grid-template-columns: max-content minmax(70px, 120px) minmax(70px, 120px); gap: 8px 12px; align-items: center; margin-bottom: 16px; }
.al-meretek label { margin: 0; font-size: .9rem; }
.al-meretek > span { font-size: .8rem; }
#al-konv { margin: 8px 0 0; }

/* Új levél jelzése (2026-11-18): a felső sáv ✉️ jelzője és a felugró jelzés (assets/levelek-jelzo.js) */
.topbar-levelek { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 999px;
  color: var(--ink); text-decoration: none; font-size: .95rem; }
.topbar-levelek:hover { background: var(--surface-2); }
.topbar-levelek[hidden] { display: none; }
.topbar-levelek-szam { min-width: 18px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: #fff; font-size: .75rem;
  font-weight: 700; line-height: 18px; text-align: center; }
.lv-toastok { position: fixed; right: 16px; bottom: 16px; z-index: 1000; display: flex; flex-direction: column; gap: 8px;
  max-width: min(380px, calc(100vw - 32px)); pointer-events: none; }   /* a doboz nem, csak az üzenetek kattinthatók */
.lv-toastok > * { pointer-events: auto; }
.lv-toast { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 10px 12px; background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 8px; box-shadow: 0 6px 20px rgba(0, 0, 0, .15);
  text-decoration: none; font-size: .9rem; }
.lv-toast strong { grid-column: 1; overflow-wrap: anywhere; }
.lv-toast span { grid-column: 1; color: var(--muted); overflow-wrap: anywhere; }
.lv-toast-x { grid-column: 2; grid-row: 1 / span 2; align-self: start; border: 0; background: none; color: var(--muted); font-size: 1.2rem;
  line-height: 1; cursor: pointer; padding: 0 2px; }

/* „Teendők és értesítések” sáv (2026-11-19, assets/teendok.js): a felső sáv 🔔 gombja, a jobb szél füle, a sáv, a felugró */
.topbar-teendok { margin-left: 6px; display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border: 0; border-radius: 999px;
  background: none; color: var(--ink); font: inherit; font-size: 1rem; cursor: pointer; }
.topbar-teendok:hover, .topbar-teendok[aria-expanded="true"] { background: var(--surface-2); }
.app-topbar-title + .topbar-teendok, .topbar-levelek[hidden] + .topbar-teendok { margin-left: auto; }
.topbar-teendok-szam, .tsav-ful-szam { min-width: 18px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: #fff;
  font-size: .75rem; font-weight: 700; line-height: 18px; text-align: center; font-style: normal; }
.topbar-teendok-szam.piros, .tsav-ful-szam.piros { background: var(--danger); }
.topbar-teendok-szam[hidden], .tsav-ful-szam[hidden] { display: none; }
.tsav-ful { position: fixed; right: 0; top: 42%; z-index: 900; display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 10px 5px; border: 1px solid var(--line); border-right: 0; border-radius: 10px 0 0 10px; background: var(--surface);
  color: var(--muted); font: inherit; font-size: .8rem; box-shadow: var(--shadow); cursor: pointer; }
.tsav-ful span { writing-mode: vertical-rl; transform: rotate(180deg); letter-spacing: .04em; }
.tsav-ful:hover { color: var(--ink); border-color: var(--accent); }
body.tsav-nyitva .tsav-ful { display: none; }
.tsav-hatter { position: fixed; inset: 0; z-index: 2001; background: rgba(10, 20, 40, .18); }
/* a sáv a staging-sáv (z-index 2000) fölött: különben a fejléce a × gombbal alá kerül */
.tsav { position: fixed; top: 0; right: 0; bottom: 0; z-index: 2002; width: min(400px, 100vw); display: flex; flex-direction: column;
  background: var(--surface); color: var(--ink); border-left: 1px solid var(--line); box-shadow: -8px 0 28px rgba(0, 0, 0, .16);
  transform: translateX(100%); transition: transform .2s ease; padding-bottom: env(safe-area-inset-bottom, 0px); }
.tsav.nyitva { transform: none; }
.tsav[hidden] { display: none; }
.tsav-fej { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 14px 16px 10px;
  padding-top: calc(14px + env(safe-area-inset-top, 0px)); border-bottom: 1px solid var(--line); }
.tsav-x { border: 0; background: none; color: var(--muted); font-size: 1.5rem; line-height: 1; cursor: pointer; padding: 0 4px; }
.tsav-x:hover { color: var(--ink); }
.tsav-lapok { display: flex; gap: 4px; padding: 8px 12px 0; border-bottom: 1px solid var(--line); }
.tsav-lapok button { flex: 1 1 0; min-width: 0; padding: 8px 6px; border: 0; border-bottom: 2px solid transparent; background: none; color: var(--muted);
  font: inherit; font-size: .9rem; cursor: pointer; white-space: nowrap; }
.tsav-lapok button[aria-selected="true"] { color: var(--ink); border-bottom-color: var(--accent); font-weight: 600; }
.tsav-lap-szam:not(:empty) { margin-left: 4px; padding: 0 6px; border-radius: 999px; background: var(--surface-2); font-size: .75rem; }
.tsav-test { flex: 1 1 auto; overflow-y: auto; padding: 12px 14px 20px; display: flex; flex-direction: column; gap: 8px; }
.tsav-test[hidden] { display: none; }
.tsav-ures { color: var(--muted); font-size: .9rem; margin: 6px 2px; }
.tsav-kartya { display: grid; gap: 4px; padding: 10px 12px; border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 8px;
  background: var(--surface); }
.tsav-kartya.tsav-f-bekero, .tsav-toast.tsav-f-bekero { border-left-color: #2e9e6b; }
.tsav-kartya.tsav-f-ajanlat, .tsav-toast.tsav-f-ajanlat { border-left-color: #b8860b; }
.tsav-kartya.tsav-f-statusz, .tsav-toast.tsav-f-statusz,
.tsav-kartya.tsav-f-projekt, .tsav-toast.tsav-f-projekt { border-left-color: var(--muted); }
.tsav-k-fej { display: flex; align-items: baseline; gap: 6px; min-width: 0; font-size: .82rem; color: var(--muted); }
.tsav-projekt { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; color: var(--ink); }
.tsav-ido { flex: 0 0 auto; font-variant-numeric: tabular-nums; }
.tsav-szoveg { color: var(--ink); text-decoration: none; font-size: .92rem; overflow-wrap: anywhere; }
.tsav-szoveg:hover { text-decoration: underline; }
.tsav-k-lab { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.tsav-szereplo { color: var(--muted); font-size: .8rem; overflow-wrap: anywhere; }
.tsav-nyugta { flex: 0 0 auto; padding: 3px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface-2); color: var(--ink);
  font: inherit; font-size: .8rem; cursor: pointer; }
.tsav-nyugta:hover { border-color: var(--accent); }
.tsav-mind { align-self: flex-end; margin-top: 4px; }
.tsav-csoport { margin: 8px 0 0; font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.tsav-csoport span { margin-left: 4px; font-weight: 400; }
.tsav-csoport.tsav-cs-lejart { color: var(--danger); }
.tsav-csoport.tsav-cs-ma { color: #a76300; }
.tsav-teendo { display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: start; padding: 8px 10px; border: 1px solid var(--line);
  border-radius: 8px; background: var(--surface); }
.tsav-teendo.tsav-cs-lejart { border-color: var(--danger); background: var(--danger-bg); }
.tsav-teendo.tsav-cs-ma { border-color: #e2b45a; }
.tsav-teendo.tsav-kesz-folyamatban { opacity: .45; }
.tsav-pipa { width: 26px; height: 26px; border: 1.5px solid var(--line); border-radius: 50%; background: var(--surface); color: transparent;
  font-size: .9rem; line-height: 1; cursor: pointer; padding: 0; }
.tsav-pipa:hover, .tsav-pipa:focus-visible { border-color: var(--accent); color: var(--accent); }
.tsav-t-torzs { min-width: 0; display: grid; gap: 2px; }
.tsav-t-projekt { font-size: .82rem; font-weight: 600; color: var(--ink); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tsav-t-projekt:hover { text-decoration: underline; }
.tsav-t-cim { margin: 0; font-size: .9rem; overflow-wrap: anywhere; }
.tsav-t-meta { color: var(--muted); font-size: .78rem; }
.tsav-uj { display: grid; gap: 6px; margin-top: 10px; padding: 10px; border: 1px dashed var(--line); border-radius: 8px; background: var(--surface-2); }
.tsav-uj input { width: 100%; min-width: 0; }
.tsav-uj-sor { display: flex; gap: 6px; align-items: center; }
.tsav-uj-sor input { flex: 1 1 auto; }
.tsav-uj-hiba { margin: 0; color: var(--danger); font-size: .85rem; }
.tsav-toastok { z-index: 2003; }
.tsav-toast { grid-template-columns: 1fr auto; }
.tsav-toast-gombok { grid-column: 1 / -1; display: flex; gap: 6px; margin-top: 6px; }
@media (max-width: 720px) {
  .tsav-ful { display: none; }
  .tsav { width: 100vw; }
}
/* az elfogadott ajánlat gombjai a sávban, a teendőn és a felugrón (2026-11-19): projektté alakítás, adatbekérő */
.tsav-ajanlat-gombok { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 4px; }
.tsav-ajanlat-gombok .btn { white-space: nowrap; }
.tsav-ajanlat-valasz { margin: 0; flex: 1 1 100%; font-size: .85rem; color: var(--ok-ink); }
.tsav-ajanlat-valasz.figyel { color: #a76300; }

/* A partnerrel megosztás kapcsolója (2026-11-24 este, Napex\Iratatadas\Megosztas — csak párosított projekten látszik) */
.gd-megosztva{border-color:#9fd3b4;background:#eef8f2;color:#1f6b42}
.gd-nem-megosztva{border-color:#e3c98f;background:#fdf6e6;color:#7a5512}
