/* =========================================================================
   FAKTURÁK — designový systém v1
   Inspirace: alesfodor.wixsite.com/umenidreva-af (řemeslnické dřevěné téma).
   Tmavé téma s přírodní paletou. PDF má vlastní CSS uvnitř pdf.blade.php.
   ========================================================================= */

/* Hulk Rukopis — ruční brandové písmo (verzálky + ČJ diakritika + čísla),
   postavené z předloh grafika. Slouží na wordmarky (názvy modulů/sekcí). */
@font-face {
  font-family: 'Hulk Rukopis';
  src: url('/fonts/HulkRukopis.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

:root {
  /* --- Pozadí a povrchy --- */
  --bg: #1c1612;            /* tmavá hlína / lesní podlaha */
  --surface: #2a221c;        /* karty, formuláře — teplejší hnědá */
  --surface-2: #231b16;      /* alternativní řádky tabulky */
  --surface-hover: #33291f;
  --border: #3d342c;
  --border-light: #2f2620;

  /* --- Text --- */
  --text: #f0e6d8;           /* krémová */
  --text-strong: #fff5e6;    /* nadpisy */
  --muted: #9a8a78;          /* sekundární text, labely */
  --muted-2: #6b5e4f;        /* terciární */

  /* --- Akcent (medová zlatá) --- */
  --primary: #c89b3c;
  --primary-dark: #a07d2a;
  --primary-light: #dfb558;
  --primary-bg: rgba(200, 155, 60, 0.12);
  --primary-bg-hover: rgba(200, 155, 60, 0.2);

  /* --- Stavové barvy --- */
  --ok: #7a9a5a;             /* lesní zelená */
  --ok-bg: rgba(122, 154, 90, 0.15);
  --ok-border: rgba(122, 154, 90, 0.4);
  --check: #6db33f;          /* svěží zelená pro zaškrtávátka (výraznější než --ok) */

  --warning: #d4a648;        /* jantar */
  --warning-bg: rgba(212, 166, 72, 0.15);
  --warning-border: rgba(212, 166, 72, 0.4);

  --danger: #b8654a;         /* rezavá červená */
  --danger-bg: rgba(184, 101, 74, 0.15);
  --danger-border: rgba(184, 101, 74, 0.4);

  /* --- Tvary --- */
  --radius: 6px;
  --radius-lg: 10px;
  --shadow: 0 2px 4px rgba(0,0,0,.3), 0 6px 18px rgba(0,0,0,.2);
  --shadow-lg: 0 4px 8px rgba(0,0,0,.4), 0 12px 32px rgba(0,0,0,.3);

  /* --- Typografie --- */
  --font-heading: 'Enriqueta', 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* =========================================================================
   Topbar + nav
   ========================================================================= */

.topbar {
  background: linear-gradient(to bottom, #221a14, #1c1612);
  border-bottom: 1px solid var(--border);
  padding: 0 32px;
  display: flex;
  align-items: center;
  gap: 32px;
  height: 72px;
}

/* Hlavička jako jeden celek: topbar + lišta Oblíbené. Sticky/roluje řeší
   TENHLE wrapper → lišta se vždy veze s topbarem (je uvnitř). Default = drží
   nahoře; stránka může nechat hlavičku odjet pryč i s lištou přes
   @section('entete_class', 'entete-volna'). */
.entete { position: sticky; top: 0; z-index: 100; backdrop-filter: blur(8px); }
.entete-volna { position: static; }
/* Editor Tabulky si vypíná sticky přes `.entete-scroll { position:static !important }`
   (záhlaví odroluje). `static` ale ruší z-index a dropdown menu loga pak prohrává
   s lištou editoru (backdrop-filter dělá stacking context). `relative` se v toku
   chová stejně jako static (odroluje), jen z-index zase platí. Specifičtější
   selektor přebije inline !important pravidlo stránky. */
div.entete.entete-scroll { position: relative !important; }

/* Lišta Oblíbené — kompaktní, hned pod topbarem (jen admin shell). */
.fav {
  display: flex; align-items: center; gap: 4px;
  padding: 0 32px; height: 30px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  overflow-x: auto; scrollbar-width: none;
}
.fav::-webkit-scrollbar { display: none; }
.fav-label {
  display: flex; align-items: center; flex: 0 0 auto; padding-right: 6px;
}
.fav-label .hv { color: var(--primary); font-size: 14px; line-height: 1; }
/* Wrapper bez vlastního boxu → chipy jsou přímé prvky lišty (jako dřív);
   slouží jen JS drag&dropu jako kontejner. */
.fav-items { display: contents; }
/* Vlastní třída (ne .chip) — globální .chip je pilulka s rámečkem/radiusem. */
.fav .fav-chip { display: inline-flex; align-items: center; flex: 0 0 auto; }
.fav .chip-link {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 0 3px 0 7px; height: 30px;
  color: var(--text); text-decoration: none; font-size: 13px;
  white-space: nowrap; border-bottom: 2px solid transparent;
  transition: color .15s, border-color .15s;
}
.fav .chip-link:hover { color: var(--primary-light); border-bottom-color: var(--primary); }
.fav .chip-link .ico { display: inline-flex; color: var(--muted); }
.fav .chip-link:hover .ico { color: var(--primary-light); }
.fav .chip-link .ico svg { width: 14px; height: 14px; display: block; }
.fav .chip-link .chip-titul { line-height: 1; }
/* Odebrání — × se ukáže až při najetí na chip (jinak skryté, ať je lišta čistá). */
.fav .chip-x-form { display: flex; margin: 0; }
.fav .chip-x {
  appearance: none; -webkit-appearance: none; border-radius: 0;
  background: none; border: none; cursor: pointer;
  color: var(--muted-2); font-size: 15px; line-height: 1;
  padding: 0; width: 0; opacity: 0; overflow: hidden;
  transition: opacity .12s, color .12s, width .12s;
}
/* × se NEukazuje na hover (žádné zvětšení chipu) — jen v režimu úprav níže. */
.fav .chip-x:hover { color: var(--danger); opacity: 1; }

/* Tlačítko Upravit (vpravo) — zapne přetahování položek a změnu pořadí. */
.fav-upravit {
  flex: 0 0 auto; margin-left: auto;
  appearance: none; -webkit-appearance: none;   /* pryč nativní zaoblené rohy */
  background: none; border: 1px solid transparent; border-radius: 0;
  color: var(--muted-2); font-size: 12px; cursor: pointer;
  padding: 2px 8px; transition: color .12s, border-color .12s;
}
.fav-upravit:hover { color: var(--muted); border-color: var(--border); }
.fav.edit-mode .fav-upravit { color: var(--primary-light); border-color: var(--primary); }

/* Úchyt přetažení — jen v režimu úprav; v něm chip nenaviguje a × svítí. */
.chip-grip { display: none; color: var(--muted-2); font-size: 12px; cursor: grab; padding-left: 4px; }
.fav.edit-mode .chip-grip { display: inline-flex; }
.fav.edit-mode .fav-chip { cursor: grab; }
.fav.edit-mode .chip-link { pointer-events: none; }
.fav.edit-mode .chip-x { opacity: .65; width: 16px; padding: 0 4px 0 1px; }
.fav-chip.dragging { opacity: .4; }

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--text-strong);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 0.5px;
}

.brand-logo {
  height: 58px;
  width: auto;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.3));
}

/* Drobečková navigace v topbaru: Hulk | logo modulu */
.brand-group {
  display: flex;
  align-items: center;
  gap: 20px;
}
.brand-sep {
  flex: 0 0 auto;
  width: 2px;
  height: 40px;
  background: rgba(255, 255, 255, 0.6);
  border-radius: 1px;
}
.brand-modul {
  display: flex;
  align-items: center;
  text-decoration: none;
}
/* Drobeček (sekce/modul) — název v ručním brandovém písmu */
.brand-modul-text {
  font-family: 'Hulk Rukopis', var(--font-heading);
  font-weight: 400;
  font-size: 30px;
  line-height: 1;
  color: var(--text-strong);
  letter-spacing: 0.5px;
}
a.brand-modul-text { text-decoration: none; transition: color .15s; }
a.brand-modul-text:hover { color: var(--primary-light); }

/* =========================================================================
   Logo → menu platformy (dropdown z registru, úzký seznam)
   ========================================================================= */
.logo-wrap { position: relative; display: flex; align-items: center; }
.brand-toggle { background: none; border: 1px solid transparent; cursor: pointer;
  gap: 6px; padding: 2px 6px; border-radius: 8px; }
.brand-toggle:hover { background: var(--surface); border-color: var(--border); }
.brand-caret { color: var(--muted); font-size: 12px; line-height: 1; transition: transform .15s; }
.brand-toggle.open .brand-caret { transform: rotate(180deg); }
.brand-toggle.open { background: var(--surface); border-color: var(--border); }

.logo-menu { position: absolute; top: calc(100% + 8px); left: 0; z-index: 200; display: none;
  min-width: 228px; max-width: 264px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px;
  box-shadow: 0 18px 50px rgba(0,0,0,.55); padding: 6px; }
.logo-menu.open { display: block; }
.logo-menu .lm-sep { border-top: 1px solid var(--border); margin: 6px 4px; }

.lm-home { display: flex; align-items: center; gap: 8px; padding: 8px 9px; border-radius: 8px;
  color: var(--text); text-decoration: none; font-weight: 600; font-size: 14px; }
.lm-home:hover { background: var(--surface-hover); color: var(--text); text-decoration: none; }
.lm-home-sub { color: var(--muted); font-weight: 400; font-size: 12px; }

.lm-grp { display: flex; align-items: center; gap: 7px; padding: 5px 9px; border-radius: 8px; }
.lm-grp-nm { font-family: var(--font-heading); color: var(--primary-light); font-size: 15px; letter-spacing: .3px; }
/* Klikací nadpis sekce (celý řádek vede na pod-rozcestník). */
a.lm-grp { text-decoration: none; }
a.lm-grp.lm-grp-clic:hover { background: var(--surface-hover); }
.lm-grp-chev { margin-left: auto; color: var(--muted-2); font-size: 15px; line-height: 1; }
a.lm-grp.lm-grp-clic:hover .lm-grp-chev { color: var(--primary-light); }

.lm-item { display: flex; align-items: center; gap: 9px; padding: 7px 9px; border-radius: 8px;
  color: var(--text); text-decoration: none; font-size: 14px; }
.lm-item:hover { background: var(--surface-hover); color: var(--text); text-decoration: none; }
.lm-ico { width: 20px; height: 20px; flex: none; font-size: 16px; line-height: 1; color: var(--primary-light);
  display: inline-flex; align-items: center; justify-content: center; }
.lm-ico svg { width: 18px; height: 18px; display: block; }
.lm-nm { font-weight: 600; }
.lm-item.is-current { background: rgba(200, 155, 60, .14); }
.lm-item.is-current .lm-nm { color: var(--primary-light); }
.lm-tag { margin-left: auto; font-size: 10px; color: var(--bg); background: var(--primary);
  border-radius: 999px; padding: 1px 7px; font-weight: 700; }
.lm-tag-soon { background: var(--muted-2); }
.lm-item.is-soon { opacity: .5; cursor: default; }

/* =========================================================================
   Účtové menu (avatar vpravo) — sloučené Oblíbené · Profil · Odhlásit
   ========================================================================= */
.acct { position: relative; display: inline-flex; align-items: center; }
.acct-btn { display: inline-flex; align-items: center; gap: 8px; background: none;
  border: 1px solid transparent; border-radius: 999px; padding: 3px 8px 3px 4px; cursor: pointer; }
.acct-btn:hover, .acct[data-dropdown].open .acct-btn { background: var(--surface); border-color: var(--border); }
.acct-avatar { width: 32px; height: 32px; border-radius: 50%; flex: none;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: var(--bg); font-weight: 700; font-size: 13px; letter-spacing: .5px;
  display: inline-flex; align-items: center; justify-content: center; }
.acct-caret { color: var(--muted); font-size: 11px; line-height: 1; }

.acct-menu { display: none; position: absolute; top: calc(100% + 8px); right: 0; z-index: 200;
  min-width: 232px; background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; box-shadow: 0 18px 50px rgba(0,0,0,.55); padding: 6px; }
.acct[data-dropdown].open .acct-menu { display: block; }
.acct-head { padding: 8px 11px 6px; }
.acct-nm { font-weight: 700; color: var(--text-strong); }
.acct-em { color: var(--muted); font-size: 12px; }
.acct-menu hr { border: none; border-top: 1px solid var(--border); margin: 6px 4px; }
.acct-menu form { margin: 0; padding: 0; background: none; border: none; box-shadow: none; }
.acct-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 11px;
  border-radius: 8px; background: none; border: none; text-align: left; font: inherit; font-size: 14px;
  color: var(--text); text-decoration: none; cursor: pointer; }
.acct-item:hover { background: var(--surface-hover); color: var(--text); text-decoration: none; }
.acct-item .ic { width: 18px; text-align: center; flex: none; color: var(--primary-light); }
.acct-logout { color: var(--danger); }
.acct-logout .ic { color: var(--danger); }

.topnav {
  display: flex;
  gap: 28px;
  margin-left: auto;
  align-items: center;
}

.topnav a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 500;
  font-size: 15px;
  padding: 8px 4px;
  position: relative;
  transition: color .15s;
}

.topnav a:hover { color: var(--text); }

.topnav a::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -2px;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width .2s, left .2s;
}
.topnav a:hover::after {
  width: 100%;
  left: 0;
}
/* Aktivní položka lišty modulu (vykresluje shell z registru, třída is-current). */
.topnav a.is-current { color: var(--text); font-weight: 600; }
.topnav a.is-current::after { width: 100%; left: 0; }

/* =========================================================================
   Container & layout helpers
   ========================================================================= */

.container {
  max-width: 1080px;
  margin: 32px auto 64px;
  padding: 0 32px;
}
/* Širší varianta pro stránky s rozsáhlými tabulkami (seznam faktur) */
.container.container-wide { max-width: min(1560px, 95vw); }

/* Rám statického editoru (Nábytkář/Nářez/Kladení) — iframe přes celou plochu
   pod topbarem. Editor uvnitř má vlastní UI a scroll. */
.editor-ramec-main { max-width: none; margin: 0; padding: 0; }
.editor-ramec {
  display: block;
  width: 100%;
  height: calc(100vh - 120px);
  min-height: 560px;
  border: 0;
  background: var(--bg);
}

h1, h2, h3 {
  font-family: var(--font-heading);
  color: var(--text-strong);
  font-weight: 700;
  letter-spacing: 0.2px;
}

h1 {
  margin: 0 0 24px;
  font-size: 30px;
  line-height: 1.2;
}

h2 {
  margin: 0 0 12px;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.3px;
}

p { margin: 0 0 12px; }
p:last-child { margin-bottom: 0; }

.muted { color: var(--muted); }
.small { font-size: 13px; }
.mono { font-family: var(--font-mono); font-size: 14px; letter-spacing: 0; }

a { color: var(--primary-light); text-decoration: none; }
a:hover { color: var(--primary); text-decoration: underline; }

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  gap: 16px;
  flex-wrap: wrap;
}
.page-header h1 { margin: 0; }
.page-header .actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
/* Titul stránky (z drobečku) — shell ho kreslí nad obsahem jako H1, protože
   velký drobeček končí na úrovni modulu. Dědí základní h1 (30px, font-heading). */
.page-title { margin: 0 0 20px; }

/* Chybové stránky (403/404/419/429) v plném shellu — stejná vizuální řeč
   jako solo karta v errors/minimal (ta zůstává pro 500/503 bez DB). */
.chyba-hero { text-align: center; padding: 56px 16px 72px; }
.chyba-hero .chyba-kod {
  font-family: 'Hulk Rukopis', var(--font-heading);
  font-size: 110px; line-height: 1;
  color: var(--primary-light);
  margin: 0 0 .25rem;
}
.chyba-hero .chyba-titulek { margin: 0 0 .5rem; }
.chyba-hero .chyba-popis { color: var(--muted); margin: 0 auto 1.6rem; max-width: 52ch; }
.chyba-hero .chyba-akce { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

form.inline { display: inline; margin: 0; padding: 0; background: none; border: none; box-shadow: none; }

/* =========================================================================
   Card
   ========================================================================= */

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  margin-bottom: 20px;
  box-shadow: var(--shadow);
}

.card h2 {
  font-family: var(--font-heading);
  font-size: 16px;
  text-transform: none;
  letter-spacing: 0.3px;
  color: var(--text-strong);
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-light);
}

.card-action {
  background: linear-gradient(135deg, rgba(200,155,60,.08), var(--surface));
  border-left: 3px solid var(--primary);
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.card-wide { grid-column: 1 / -1; }

.card dl.kv {
  margin: 0;
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 6px 18px;
  font-size: 14px;
}
.card dl.kv dt {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 500;
  align-self: center;
}
.card dl.kv dd { margin: 0; color: var(--text); }

/* =========================================================================
   Form
   ========================================================================= */

.form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  box-shadow: var(--shadow);
}

fieldset { border: none; padding: 0; margin: 0 0 28px 0; }
fieldset:last-of-type { margin-bottom: 16px; }

legend {
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 16px;
  color: var(--text-strong);
  margin-bottom: 16px;
  padding: 0 0 8px;
  border-bottom: 1px solid var(--border-light);
  width: 100%;
}

label {
  display: block;
  margin-bottom: 16px;
  flex: 1;
}

label > span {
  display: block;
  font-size: 12px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--muted);
  margin-bottom: 6px;
}

input[type="text"],
input[type="email"],
input[type="number"],
input[type="password"],
input[type="date"],
input[type="search"],
select,
textarea {
  width: 100%;
  padding: 10px 12px;
  font-size: 15px;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color .15s, box-shadow .15s, background .15s;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--primary);
  background: var(--surface);
  box-shadow: 0 0 0 3px var(--primary-bg);
}

input::placeholder, textarea::placeholder { color: var(--muted-2); }

textarea { resize: vertical; font-family: var(--font-body); }

select {
  cursor: pointer;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path fill='%239a8a78' d='M6 8L0 0h12z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 10px;
  padding-right: 36px;
  appearance: none;
}

.row { display: flex; gap: 16px; }
.row > label { flex: 1; }
.row > label.grow { flex: 2; }

code {
  background: var(--surface-2);
  color: var(--primary-light);
  padding: 2px 6px;
  border-radius: 3px;
  font-family: var(--font-mono);
  font-size: 13px;
}

small { font-size: 12px; color: var(--muted); }

.form-actions {
  display: flex;
  gap: 12px;
  margin-top: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--border-light);
}

/* =========================================================================
   Tlačítka
   ========================================================================= */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  font-family: var(--font-body);
  cursor: pointer;
  text-decoration: none;
  transition: background .15s, border-color .15s, color .15s, transform .05s;
  line-height: 1.3;
}

.btn:hover {
  background: var(--surface-hover);
  border-color: var(--muted-2);
  color: var(--text-strong);
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--primary);
  color: #1c1612;
  border-color: var(--primary);
  font-weight: 600;
}
.btn-primary:hover {
  background: var(--primary-light);
  border-color: var(--primary-light);
  color: #1c1612;
}

.btn-secondary {
  background: transparent;
  color: var(--primary-light);
  border-color: var(--primary);
}
.btn-secondary:hover {
  background: var(--primary-bg);
  color: var(--primary-light);
  border-color: var(--primary-light);
}

.btn-ghost {
  background: transparent;
  border-color: transparent;
  color: var(--muted);
}
.btn-ghost:hover {
  background: var(--surface-hover);
  color: var(--text);
}

.btn:disabled, .btn[disabled] {
  opacity: 0.4;
  cursor: not-allowed;
}

.btn-danger {
  color: var(--danger);
}
.btn-danger:hover {
  background: var(--danger-bg);
  border-color: var(--danger-border);
  color: var(--danger);
}

.btn-icon {
  background: none;
  border: none;
  color: var(--muted-2);
  font-size: 20px;
  cursor: pointer;
  line-height: 1;
  padding: 6px 10px;
  border-radius: var(--radius);
  transition: background .15s, color .15s;
}
.btn-icon:hover { color: var(--danger); background: var(--danger-bg); }

/* =========================================================================
   Filtry / chips
   ========================================================================= */

.filters {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.chip {
  display: inline-block;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 500;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  text-decoration: none;
  transition: all .15s;
}
.chip:hover { background: var(--surface-hover); color: var(--text); text-decoration: none; }
.chip-on {
  background: var(--primary-bg);
  color: var(--primary-light);
  border-color: var(--primary);
}

.filter-bar {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
  align-items: stretch;
  background: none;
  border: none;
  padding: 0;
  box-shadow: none;
}
.filter-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}
.vlastni-label { color: var(--muted); font-size: 13px; }
.filter-bar select {
  width: auto;
  min-width: 180px;
  padding: 8px 36px 8px 12px;
  font-size: 13px;
}
.vlastni-obdobi {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.vlastni-obdobi input[type="date"] {
  width: auto;
  padding: 8px 12px;
  font-size: 13px;
}
.vlastni-pomlcka { color: var(--muted); }

/* Měna / kurz ve formuláři */
.kurz-input-group { display: flex; gap: 8px; align-items: stretch; }
.kurz-input-group input { flex: 1; }
.kurz-input-group .btn { white-space: nowrap; }

/* Pravidelné opakování ve formuláři faktury */
.opakovani-box {
  margin-top: 18px;
  padding: 16px 18px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.check-inline {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}
.check-inline input[type="checkbox"] { width: auto; margin: 0; }
.check-inline span { margin: 0; }
.opakovani-box .hint { margin: 12px 0 0; font-size: 12px; color: var(--muted); }

/* =========================================================================
   Tabulka
   ========================================================================= */

.table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.table th, .table td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-light);
  vertical-align: middle;
}
.table thead th {
  background: var(--surface-2);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--muted);
  font-weight: 600;
}
.table tbody tr:last-child td { border-bottom: none; }
.table tbody tr { transition: background .12s; }
.table tbody tr:hover { background: var(--surface-2); }

.table td a {
  color: var(--primary-light);
  text-decoration: none;
  font-weight: 500;
}
.table td a:hover {
  color: var(--primary);
  text-decoration: underline;
}

.table .num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-family: var(--font-mono);
  font-size: 13.5px;
  white-space: nowrap;
}
.table tfoot td {
  background: var(--surface-2);
  font-weight: 600;
  border-top: 1px solid var(--border);
}

.table .actions { text-align: right; white-space: nowrap; }
.table .actions > a,
.table .actions > form.inline { margin-left: 14px; }
.table .actions > a:first-child { margin-left: 0; }
.row-archived td { color: var(--muted-2); }
.row-archived td a { color: var(--muted); }

.link {
  color: var(--primary-light);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
}
.link:hover { color: var(--primary); text-decoration: underline; }

/* <button class="link"> — vizuálně jako textový odkaz */
button.link {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  cursor: pointer;
  font-family: inherit;
}
.link-danger { color: var(--danger); }
.link-danger:hover { color: var(--danger); }

/* =========================================================================
   Badge / stav
   ========================================================================= */

.badge {
  display: inline-block;
  padding: 3px 10px;
  font-size: 10px;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-weight: 700;
  margin-left: 4px;
}
.badge-muted {
  background: var(--surface-2);
  color: var(--muted);
  border: 1px solid var(--border);
}
.badge-proforma {
  background: rgba(122, 154, 90, 0.10);
  color: var(--ok);
  border: 1px solid rgba(122, 154, 90, 0.35);
  font-size: 9px;
}
.badge-ok {
  background: rgba(122, 154, 90, 0.12);
  color: var(--ok);
  border: 1px solid rgba(122, 154, 90, 0.35);
}
.row-proforma td { color: var(--muted); font-style: italic; }
.row-proforma td a { color: var(--muted); }

.stav {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  font-family: var(--font-body);
  white-space: nowrap;
}
.stav-vystaveno  { background: var(--warning-bg); color: var(--warning); border: 1px solid var(--warning-border); }
.stav-zaplaceno  { background: var(--ok-bg);     color: var(--ok);     border: 1px solid var(--ok-border); }
.stav-stornovano { background: var(--danger-bg); color: var(--danger); border: 1px solid var(--danger-border); text-decoration: line-through; }
.stav-po-splatnosti { background: var(--danger-bg); color: var(--danger); border: 1px solid var(--danger-border); }

/* =========================================================================
   Flash zprávy
   ========================================================================= */

.flash {
  padding: 12px 16px;
  border-radius: var(--radius);
  margin-bottom: 16px;
  font-size: 14px;
}
.flash-ok  { background: var(--ok-bg);     color: var(--ok);     border: 1px solid var(--ok-border); }
.flash-err { background: var(--danger-bg); color: var(--danger); border: 1px solid var(--danger-border); }

/* =========================================================================
   Empty state
   ========================================================================= */

.empty {
  padding: 56px 24px;
  text-align: center;
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
}
.empty p { margin: 0 0 20px 0; color: var(--muted); font-size: 16px; }

/* =========================================================================
   Položky faktury (formulář) — inline tabulka inputs
   ========================================================================= */

.table-polozky { box-shadow: none; }
.table-polozky thead th {
  background: transparent;
  border-bottom: 1px solid var(--border);
}
.table-polozky tbody tr:hover { background: transparent; }
.table-polozky input {
  padding: 8px 10px;
  font-size: 14px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  font-family: var(--font-body);
}
.table-polozky tbody tr:hover input,
.table-polozky tbody tr input:focus {
  background: var(--bg);
}
.table-polozky tbody tr input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px var(--primary-bg);
}
.num-input input, .num-cell {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-family: var(--font-mono);
}
.unit-input { width: 100px; }
.num-input { width: 140px; }
.cena-celkem {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-weight: 500;
  padding: 10px 16px;
  color: var(--text-strong);
}
.actions-cell { text-align: left; padding: 14px 16px; }
.total-cell { font-size: 17px; padding: 14px 16px; font-family: var(--font-mono); }
.total-cell strong {
  font-size: 22px;
  color: var(--primary-light);
  font-family: var(--font-heading);
  font-weight: 700;
}

/* =========================================================================
   ARES action button
   ========================================================================= */

.ares-action {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding-bottom: 16px;
}
.htmx-indicator {
  opacity: 0;
  transition: opacity .2s;
  color: var(--muted);
  font-size: 13px;
  padding-bottom: 12px;
}
.htmx-request .htmx-indicator { opacity: 1; }
.htmx-request.htmx-indicator { opacity: 1; }

/* =========================================================================
   Inline form (např. označit zaplaceno)
   ========================================================================= */

.inline-form {
  display: flex;
  gap: 16px;
  align-items: flex-end;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  background: none;
  border: none;
  box-shadow: none;
}
.inline-form label { margin: 0; min-width: 180px; }
.inline-form input, .inline-form select { padding: 9px 12px; }

/* =========================================================================
   Login (auth) — samostatný layout
   ========================================================================= */

.auth-page {
  background: var(--bg);
  background-image:
    radial-gradient(ellipse at top, rgba(200,155,60,.08), transparent 50%),
    radial-gradient(ellipse at bottom, rgba(122,154,90,.06), transparent 50%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}
.auth-container {
  width: 100%;
  max-width: 420px;
  padding: 24px;
}
.auth-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  box-shadow: var(--shadow-lg);
}
.auth-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border-light);
}
.auth-logo {
  height: 88px;
  width: auto;
  max-width: 100%;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,.35));
}
.checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 16px;
}
.checkbox input { margin: 0; width: auto; }

/* =========================================================================
   Statistické karty (faktury overview)
   ========================================================================= */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 22px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.stat-card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--muted-2);
}
.stat-vystaveno::before    { background: var(--primary); }
.stat-zaplaceno::before    { background: var(--ok); }
.stat-po-splatnosti::before{ background: var(--danger); }
.stat-stornovano::before   { background: var(--muted); }

.stat-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--muted);
  font-weight: 600;
  margin-bottom: 8px;
}

.stat-value {
  font-family: var(--font-heading);
  font-size: 26px;
  font-weight: 700;
  color: var(--text-strong);
  letter-spacing: 0.3px;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.stat-value .kc {
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  margin-left: 4px;
}

.stat-meta {
  font-size: 12px;
  color: var(--muted);
  margin-top: 6px;
}

/* Dashboard */
.dashboard-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.dashboard-hero h1 { margin: 0; }
.dashboard-hero-text .muted { margin: 4px 0 0 0; }
.btn-lg { padding: 14px 26px; font-size: 16px; }
.stats-grid-2 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.stat-card-link {
  text-decoration: none;
  display: block;
  transition: border-color .15s, transform .15s;
}
.stat-card-link:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  text-decoration: none;
}

/* DPH obrat — 12měsíční ukazatel */
.dph-card { margin-bottom: 24px; }
.dph-head { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 8px; }
.dph-head h2 { margin: 0; }
.dph-period { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.dph-amounts { display: flex; align-items: baseline; gap: 10px; margin: 10px 0 12px; }
.dph-value { font-family: var(--font-heading); font-size: 28px; font-weight: 700; color: var(--text-strong); font-variant-numeric: tabular-nums; }
.dph-of { color: var(--muted); font-size: 14px; }
.dph-bar { height: 12px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.dph-bar-fill { height: 100%; border-radius: 999px; transition: width .3s; }
.dph-meta { font-size: 13px; color: var(--text); margin-top: 10px; }
.dph-ok   .dph-bar-fill { background: var(--ok); }
.dph-warn .dph-bar-fill { background: var(--warning); }
.dph-over .dph-bar-fill { background: var(--danger); }
.dph-over { border-color: var(--danger); }
.dph-warn { border-color: var(--warning); }

.chart-card { padding-top: 20px; }
.chart-card h2 { border-bottom: none; padding-bottom: 0; margin-bottom: 14px; }
.chart-card canvas { width: 100% !important; max-height: 280px; }

/* Inline „Zaplacena" v řádku /faktury tabulky */
.inline-pay {
  display: flex;
  gap: 6px;
  align-items: center;
  margin: 0;
  padding: 0;
  background: none;
  border: none;
  box-shadow: none;
}
.inline-pay input[type="date"] {
  padding: 4px 8px;
  font-size: 12.5px;
  width: auto;
  min-width: 130px;
}
.btn-sm {
  padding: 5px 12px;
  font-size: 12.5px;
  font-weight: 600;
}

.rozpocet-link {
  display: inline-block;
  padding: 8px 14px;
  background: var(--primary-bg);
  color: var(--primary-light);
  border: 1px solid var(--primary);
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 500;
  font-size: 14px;
}
.rozpocet-link:hover {
  background: var(--primary-bg-hover);
  color: var(--text-strong);
  text-decoration: none;
}

/* =========================================================================
   Selection & scrollbar
   ========================================================================= */

::selection {
  background: var(--primary-bg);
  color: var(--text-strong);
}

::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb {
  background: var(--surface);
  border: 3px solid var(--bg);
  border-radius: 6px;
}
::-webkit-scrollbar-thumb:hover { background: var(--border); }

/* =========================================================================
   Responzivní layout (mobil / tablet)
   ========================================================================= */

/* Burger tlačítko — na desktopu skryté, ukáže se až na mobilu */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 38px;
  margin-left: auto;
  padding: 0;
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 0 auto;
  background: var(--text);
}

@media (max-width: 760px) {
  body { font-size: 14px; }

  /* Topbar — brand vlevo, burger vpravo; navigace = plovoucí panel pod topbarem */
  .topbar { height: auto; min-height: 56px; padding: 8px 16px; gap: 10px; }
  .brand-logo { height: 34px; }
  .nav-toggle { display: flex; }
  .topnav {
    display: none;
    position: absolute;
    top: 100%;
    left: auto;
    right: 0;
    width: 60%;
    min-width: 200px;
    max-width: 280px;
    flex-direction: column;
    gap: 0;
    margin: 0;
    background: #1c1612;
    border: 1px solid var(--border);
    border-top: none;
    border-bottom-left-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 4px 16px 10px;
    z-index: 99;
  }
  .topnav.open { display: flex; }
  .topnav a { padding: 13px 4px; border-top: 1px solid var(--border); font-size: 16px; text-align: left; }
  .topnav a:first-child { border-top: none; }
  .topnav a::after { display: none; }

  /* Obsah — menší okraje */
  .container { margin: 16px auto 40px; padding: 0 14px; }

  /* Hlavička stránky — nadpis a akce pod sebe */
  .page-header { flex-direction: column; align-items: stretch; gap: 12px; }
  .page-header .actions, .actions { flex-wrap: wrap; }

  /* Formuláře — pole pod sebe, menší padding */
  .form { padding: 18px 16px; }
  .row { flex-direction: column; gap: 0; }
  .row > label, .row > label.grow { flex: 1; }

  /* Filtr — selecty na plnou šířku */
  .filter-bar select, .filter-row select { min-width: 0; width: 100%; }
  .filter-row { width: 100%; }
  .vlastni-obdobi { flex-wrap: wrap; }
  .vlastni-obdobi input[type="date"] { flex: 1; }

  /* === Tabulky → kartičky (jen svislý scroll, žádné přetékání do stran) === */
  .table { display: block; border: none; background: none; box-shadow: none; }
  .table thead { display: none; }
  .table tbody { display: block; }
  .table tr {
    display: block;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    margin-bottom: 12px;
    padding: 4px 14px;
  }
  .table td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    padding: 8px 0;
    border-bottom: 1px solid var(--border-light);
    text-align: right;
    white-space: normal;
  }
  .table tr td:last-child { border-bottom: none; }
  .table td[data-label]::before {
    content: attr(data-label);
    font-weight: 600;
    color: var(--muted);
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: .5px;
    text-align: left;
    flex-shrink: 0;
  }
  .table .num { text-align: right; }
  /* V kartičkách nezalamovat částky, štítky stavu ani jmenovky sloupců */
  .table td.num,
  .table td[data-label]::before { white-space: nowrap; }
  .table .stav, .table .badge { white-space: nowrap; }
  .table td > .stav, .table td > .badge { flex-shrink: 0; }

  /* Buňky akcí — celá šířka, ovládací prvky vedle sebe / pod sebe */
  .table td.actions {
    display: block;
    text-align: left;
    white-space: normal;
    padding-top: 10px;
  }
  .table td.actions > a,
  .table td.actions > form.inline { margin: 0 14px 0 0; }
  .inline-pay { flex-wrap: wrap; margin-bottom: 6px; }

  /* Součtové řádky (tfoot) */
  .table tfoot { display: block; }
  .table tfoot tr { display: block; }
  .table tfoot td { display: flex; justify-content: space-between; }

  /* Editovatelná tabulka položek — řádek = kartička; jmenovka NAD polem */
  .table-polozky tr.polozka-row {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 8px 12px 10px;
    margin-bottom: 12px;
    overflow: hidden; /* obalí floatované buňky */
  }
  .table-polozky td {
    display: block;
    text-align: left;
    border-bottom: none;
    padding: 6px 0;
  }
  .table-polozky td[data-label]::before {
    display: block;
    margin-bottom: 5px;
  }
  .table-polozky input { width: 100%; flex: none; text-align: left; }

  /* Množství + Jednotka vedle sebe na jednom řádku */
  .table-polozky td.pol-mn { float: left; width: 48%; }
  .table-polozky td.pol-jed { float: right; width: 48%; }
  .table-polozky td.pol-cena { clear: both; }

  /* Cena za jednotku zarovnaná doprava */
  .table-polozky td.pol-cena input { text-align: right; }

  /* Celkem — výrazný řádek oddělený čárou: popis vlevo, částka vpravo */
  .table-polozky td.cena-celkem {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    border-top: 2px solid var(--border);
    margin-top: 8px;
    padding-top: 12px;
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-light);
  }
  .table-polozky td.cena-celkem::before {
    margin-bottom: 0;
    align-self: baseline;
    font-size: 13px;
    color: var(--muted);
  }

  .table-polozky td.actions { text-align: right; padding-top: 8px; }
  .table-polozky tfoot td { display: block; }

  /* Mřížky karet — jistota jednoho sloupce na úzké šířce */
  .cards-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .stats-grid, .stats-grid-2 { grid-template-columns: 1fr; }
  h1 { font-size: 24px; }
  .form { padding: 16px 12px; }
  .page-header .actions .btn,
  .form-actions .btn,
  .page-header .actions form.inline,
  .page-header .actions form.inline .btn { width: 100%; }
}

/* ─── Verze + prostředí (2.0) ─────────────────────────────── */
.env-banner {
  text-align: center;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .03em;
  padding: 5px 12px;
  color: #1c1612;
  background: var(--warning);
}
.env-banner-local { background: var(--muted); color: var(--text-strong); }

.appfoot {
  max-width: 1100px;
  margin: 40px auto 24px;
  padding: 16px 24px 0;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
}
.appfoot .env-tag {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .04em;
  padding: 1px 7px;
  border-radius: 999px;
  color: #1c1612;
  background: var(--warning);
}

/* =========================================================================
   UX-1 — rychlé vystavení faktury (combobox klienta, Pokročilé, dialog)
   ========================================================================= */

/* Combobox výběru klienta */
.combo { position: relative; display: flex; flex-wrap: wrap; gap: 8px; align-items: stretch; }
.combo .combo-input { flex: 1; min-width: 220px; }
.combo .combo-add { white-space: nowrap; }
.combo .input-err { border-color: var(--danger); box-shadow: 0 0 0 3px var(--danger-bg); }
.combo-list {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 30;
  margin: 0;
  padding: 4px;
  list-style: none;
  max-height: 280px;
  overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .45);
}
.combo-list li {
  padding: 8px 10px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
}
.combo-list li.active,
.combo-list li:hover { background: var(--primary-bg); color: var(--text-strong); }

/* Rozbalovací „Pokročilé" pole ve formuláři */
details.advanced {
  margin-top: 18px;
  border-top: 1px dashed var(--border);
  padding-top: 6px;
}
details.advanced > summary {
  cursor: pointer;
  list-style: none;
  padding: 8px 0;
  font-weight: 600;
  color: var(--primary-light);
  user-select: none;
}
details.advanced > summary::-webkit-details-marker { display: none; }
details.advanced > summary::before { content: "▸ "; color: var(--muted); }
details.advanced[open] > summary::before { content: "▾ "; }
details.advanced > summary .muted { font-weight: 400; }
details.advanced > .row:first-of-type { margin-top: 8px; }

/* Dialog „Nový klient" */
dialog.dialog {
  border: none;
  background: transparent;
  padding: 0;
  max-width: 640px;
  width: calc(100% - 32px);
}
dialog.dialog::backdrop { background: rgba(0, 0, 0, .55); }
.dialog-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 26px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .5);
}
.dialog-card h2 { margin: 0 0 16px; }
.dialog-card .form-actions { margin-top: 20px; }

/* =========================================================================
   UX-2 — hledání, řazení, hromadné akce v /faktury
   ========================================================================= */

.search-input {
  width: 100%;
  max-width: 420px;
  font-size: 15px;
}

/* Řaditelné hlavičky tabulky */
.table th .sort-link {
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.table th .sort-link:hover { color: var(--primary-light); }
.table th .sort-link.active { color: var(--primary); }

/* Sloupec s checkboxy pro hromadné akce */
.table .bulk-col { width: 34px; text-align: center; padding-left: 10px; padding-right: 4px; }
.table .bulk-col input { cursor: pointer; }

/* Indikátor odeslání e-mailem */
.sent-mark {
  margin-left: 6px;
  color: var(--ok);
  font-size: 13px;
  cursor: default;
}

/* Lišta hromadných akcí */
.bulk-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 0 0 16px;
  padding: 10px 16px;
  background: var(--surface);
  border: 1px solid var(--primary);
  border-radius: var(--radius);
  box-shadow: 0 6px 18px rgba(0, 0, 0, .25);
}
.bulk-bar[hidden] { display: none; }   /* atribut hidden musí přebít display:flex */
.bulk-bar .bulk-info { color: var(--muted); margin-right: 4px; }
.bulk-bar .bulk-info strong { color: var(--text-strong); }

/* Hlavička seznamu faktur 2×2: vlevo titulek + filtry, vpravo akce + výběr období. */
.faktury-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 14px 24px;
  margin-bottom: 18px;
}
.faktury-head h1 { margin: 0; }
.fh-left { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.fh-right { display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
.fh-filters { display: flex; flex-wrap: wrap; gap: 8px; }
.fh-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px; }
.fh-period { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; }
.fh-filters select { width: auto; min-width: 130px; max-width: 200px; }
.faktury-head .search-wrap { display: flex; align-items: center; }
.faktury-head .search-input { width: 240px; }
@media (max-width: 760px) {
  .faktury-head { flex-direction: column; }
  .fh-right { align-items: stretch; width: 100%; }
  .fh-actions, .fh-period { justify-content: flex-start; }
  .fh-filters select, .faktury-head .search-input { width: 100%; max-width: none; flex: 1 1 100%; }
}

/* Přehled: statistické karty v úzkém levém sloupci, graf vyplní zbytek */
.overview-row { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 18px; }
.overview-row .stats-grid { flex: 0 0 320px; grid-template-columns: 1fr; gap: 10px; margin: 0; align-content: start; }
.overview-row .chart-card { flex: 1; min-width: 0; margin: 0; }
.overview-row .chart-wrap { height: 300px; }
@media (max-width: 900px) {
  .overview-row { flex-direction: column; }
  .overview-row .stats-grid { flex: auto; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
  .overview-row .chart-wrap { height: 220px; }
}

/* Karta grafu: čistý graf přes celou kartu (bez nadpisu a legendy) */
.chart-card { display: flex; }
/* Pevná výška grafu (Chart.js responsive container) — graf vyplní kartu */
.chart-wrap { flex: 1; min-width: 0; position: relative; height: 260px; }
@media (max-width: 760px) {
  .chart-wrap { height: 200px; }
}

/* =========================================================================
   Výběr období ve stylu Clockify (daterange)
   ========================================================================= */
.daterange { position: relative; display: inline-flex; align-items: stretch; }
.dr-main {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--bg); color: var(--text);
  border: 1px solid var(--border); border-radius: var(--radius) 0 0 var(--radius);
  padding: 8px 12px; font: inherit; font-size: 13px; cursor: pointer; white-space: nowrap;
}
.dr-ico { opacity: .8; }
.dr-nav {
  background: var(--bg); color: var(--text);
  border: 1px solid var(--border); border-left: none;
  padding: 0 10px; font-size: 16px; line-height: 1; cursor: pointer;
}
.dr-nav:last-child { border-radius: 0 var(--radius) var(--radius) 0; }
.dr-main:hover, .dr-nav:hover { border-color: var(--primary); color: var(--primary-light); }

.dr-pop {
  position: absolute; top: calc(100% + 6px); right: 0; z-index: 50;
  display: flex;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: 0 16px 40px rgba(0, 0, 0, .5);
  overflow: hidden;
}
.dr-pop[hidden] { display: none; }
.dr-presets {
  display: flex; flex-direction: column; gap: 2px;
  padding: 8px; min-width: 170px;
  border-right: 1px solid var(--border); background: var(--surface-2);
}
.dr-presets button {
  text-align: left; background: none; border: none; color: var(--text);
  padding: 8px 12px; border-radius: 6px; font: inherit; font-size: 13px; cursor: pointer;
}
.dr-presets button:hover { background: var(--primary-bg); color: var(--text-strong); }
.dr-presets button.active { background: var(--primary-bg); color: var(--primary); font-weight: 600; }

.dr-cals { display: flex; gap: 20px; padding: 14px 16px; }
.dr-month-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.dr-month-head .dr-mlabel { flex: 1; text-align: center; font-size: 13px; font-weight: 600; color: var(--text-strong); }
.dr-mnav { background: none; border: none; color: var(--muted); font-size: 16px; line-height: 1; cursor: pointer; padding: 0 6px; }
.dr-mnav:hover { color: var(--primary); }
.dr-grid { border-collapse: collapse; }
.dr-grid th { color: var(--muted); font-size: 11px; font-weight: 600; padding: 4px 0; width: 32px; }
.dr-grid td { padding: 1px; }
.dr-grid td button {
  width: 32px; height: 30px; background: none; border: none;
  color: var(--text); font: inherit; font-size: 12px; cursor: pointer; border-radius: 6px;
}
.dr-grid td button:hover { background: var(--primary-bg); }
.dr-grid td.dr-out button { color: var(--muted-2); }
.dr-grid td.dr-today button { box-shadow: inset 0 0 0 1px var(--border); }
.dr-grid td.in-range button { background: var(--primary-bg); border-radius: 0; }
.dr-grid td.range-end button { background: var(--primary); color: #1c1612; border-radius: 6px; }
@media (max-width: 760px) {
  .dr-pop { flex-direction: column; left: auto; right: 0; }
  .dr-presets { flex-direction: row; flex-wrap: wrap; border-right: none; border-bottom: 1px solid var(--border); }
  .dr-cals { flex-direction: column; gap: 14px; }
}

/* Kompaktní statistické karty na seznamu faktur (dashboard zůstává velký) */
.stats-compact {
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.stats-compact .stat-card { padding: 9px 14px; }
.stats-compact .stat-label { margin-bottom: 2px; }
.stats-compact .stat-value { font-size: 19px; }
.stats-compact .stat-meta { margin-top: 1px; font-size: 11px; }

.hidden-form { display: none; }

/* HTMX loading indikátor (sdílí .htmx-indicator) — drobný spinner u hledání */
#list-spin { margin-left: 8px; color: var(--muted); }

/* =========================================================================
   UX-3 — toasty, dropdown „⋯ Více", focus, loading
   ========================================================================= */

/* Toasty (úspěšná potvrzení) */
.toast-wrap {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: min(420px, calc(100vw - 32px));
}
.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--ok-border);
  border-left: 4px solid var(--ok);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .45);
  font-size: 14px;
  animation: toast-in .25s ease;
}
.toast span { flex: 1; color: var(--text-strong); }
.toast-x {
  background: none; border: none; cursor: pointer;
  color: var(--muted); font-size: 18px; line-height: 1; padding: 0 2px;
}
.toast-x:hover { color: var(--text-strong); }
.toast-leaving { animation: toast-out .3s ease forwards; }
@keyframes toast-in { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }
@keyframes toast-out { to { opacity: 0; transform: translateX(20px); } }

/* Dropdown „⋯ Více" */
.dropdown { position: relative; display: inline-block; }
.dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 40;
  min-width: 190px;
  display: none;
  flex-direction: column;
  padding: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .45);
}
.dropdown.open .dropdown-menu { display: flex; }
.dropdown-menu a,
.dropdown-menu button {
  display: block;
  width: 100%;
  text-align: left;
  padding: 9px 12px;
  border-radius: 6px;
  background: none;
  border: none;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
}
.dropdown-menu form { margin: 0; }
.dropdown-menu a:hover,
.dropdown-menu button:hover { background: var(--primary-bg); color: var(--text-strong); }
.dropdown-menu .menu-danger { color: var(--danger); }
.dropdown-menu .menu-danger:hover { background: var(--danger-bg); color: var(--danger); }

/* Viditelný focus pro ovládání klávesnicí */
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.btn:focus-visible { outline-offset: 3px; }

/* Ztlumení výsledků během HTMX dotazu */
#filter-form.htmx-request ~ #vysledky { opacity: .55; transition: opacity .12s ease; }

/* Detail faktury: sekundární akce jako samostatná tlačítka na široké obrazovce
   (display:contents → splynou s flexem .actions), dropdown „⋯ Více" jen na úzké. */
.actions-secondary { display: contents; }
.actions-overflow { display: none; }
@media (max-width: 760px) {
  .actions-secondary { display: none; }
  .actions-overflow { display: inline-block; }
}

/* =========================================================================
   2.4 — Detail faktury: kopírovací tlačítka + náhled PDF v modalu
   ========================================================================= */

/* Kopírovací tlačítko u hodnoty (VS, účet, IBAN, částka) */
.copy-btn {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  border-radius: 6px;
  padding: 1px 7px;
  margin-left: 6px;
  font-size: 12px;
  line-height: 1.4;
  cursor: pointer;
  vertical-align: middle;
  transition: background .12s ease, color .12s ease, border-color .12s ease;
}
.copy-btn:hover { color: var(--text); border-color: var(--primary); }
.copy-btn.copied { color: var(--ok); border-color: var(--ok); }
/* Dlouhé hodnoty (IBAN) se zalomí uvnitř karty místo přetečení přes okraj. */
.card dl.kv dd { overflow-wrap: anywhere; }

/* Náhled PDF v modalu */
dialog.pdf-dialog {
  border: 1px solid var(--border);
  background: var(--surface);
  padding: 0;
  border-radius: 12px;
  width: min(900px, 94vw);
  height: min(90vh, 1100px);
  max-width: 94vw;
  overflow: hidden;
}
dialog.pdf-dialog::backdrop { background: rgba(0, 0, 0, .6); }
.pdf-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
}
.pdf-dialog-head strong { font-size: 15px; }
.pdf-dialog-actions { display: flex; gap: 8px; }
.pdf-dialog-frame {
  width: 100%;
  height: calc(100% - 54px);
  border: 0;
  display: block;
  background: #fff;
}

/* =========================================================================
   2.5 — Akční dashboard: blok „Vyžaduje pozornost"
   ========================================================================= */
.akce-card { border-left: 3px solid var(--primary); }
.akce-list { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.akce-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 4px;
  border-bottom: 1px solid var(--border);
}
.akce-item:last-child { border-bottom: 0; }
.akce-ico { flex: 0 0 auto; font-size: 15px; line-height: 1; width: 20px; text-align: center; }
.akce-ico-red { color: #d06a5a; }
.akce-ico-blue { filter: grayscale(.1); }
.akce-ico-amber { filter: grayscale(.05); }
.akce-text { flex: 1 1 auto; min-width: 0; }
.akce-text .mono { white-space: nowrap; }
.akce-item .btn { flex: 0 0 auto; }
@media (max-width: 560px) {
  .akce-item { flex-wrap: wrap; gap: 6px 10px; }
  .akce-item .btn { margin-left: 32px; }
}

/* =========================================================================
   2.6 — Automatické upomínky: checkbox řádek + trojice polí
   ========================================================================= */
.check-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 10px 0;
  cursor: pointer;
}
/* Globální zelené checkboxy + radio napříč celou platformou Hulk (svěží zelená). */
input[type="checkbox"],
input[type="radio"] {
  accent-color: var(--check);
}
.check-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  flex: 0 0 auto;
  accent-color: var(--check);
}
.check-row > span { line-height: 1.4; }
.check-row small { display: block; margin-top: 2px; }
.form-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 6px;
}
@media (max-width: 640px) {
  .form-grid-3 { grid-template-columns: 1fr; }
}

/* =========================================================================
   Platforma Hulk — rozcestník modulů (shell v0.1)
   Aditivní blok; nezasahuje do stávajících Fakturák tříd.
   ========================================================================= */

.rozcestnik-head { margin: 8px 0 28px; }
.rozcestnik-head h1 {
  font-family: var(--font-heading);
  color: var(--text-strong);
  font-size: 30px;
  margin: 0 0 4px;
}
.rozcestnik-head .muted { color: var(--muted); margin: 0; }

/* Velké dlaždice sekcí (CRM, Dílna) — horní část hlavního rozcestníku */
.sekce-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 22px;
  margin-bottom: 40px;
}
.sekce-kachle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
  min-height: 168px;
  background: linear-gradient(135deg, var(--surface), var(--surface-2));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px 30px;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--shadow);
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.sekce-kachle:hover {
  border-color: var(--primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}
.sekce-head {
  display: flex;
  align-items: center;
  gap: 16px;
}
.sekce-logo {
  height: 58px;
  width: auto;
  max-width: 100%;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.3));
}
.sekce-ikona { font-size: 44px; line-height: 1; }
/* Gold čárová ikona sekce (CRM, Dílna) — o něco větší než u modulů */
.sekce-ikona-svg {
  flex: 0 0 auto;
  width: 46px; height: 46px;
  color: var(--primary-light);
}
.sekce-ikona-svg svg { width: 100%; height: 100%; display: block; }
.sekce-nazev {
  font-family: 'Hulk Rukopis', var(--font-heading);
  font-weight: 400;
  font-size: 44px;
  color: var(--text-strong);
  letter-spacing: 0.5px;
}
.sekce-cleny { color: var(--muted); font-size: 15px; }
.sekce-kachle-disabled { opacity: .55; cursor: default; box-shadow: none; }
.sekce-kachle-disabled:hover { border-color: var(--border); transform: none; box-shadow: none; }

/* Skupiny malých dlaždic pod velkými — stejné 2sloupcové rozvržení jako
   .sekce-grid, aby skupina sedla pod svou velkou dlaždici. Uvnitř každé
   skupiny běží běžná .modul-grid → dlaždice si drží svou velikost. */
.sekce-skupiny {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 22px;
  align-items: start;
}

/* Nadpis plochého výpisu „Všechny moduly" pod sekcemi */
.rozcestnik-vse-nadpis {
  font-family: var(--font-heading);
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  margin: 0 0 16px;
}

.modul-skupina { margin-bottom: 32px; }
.modul-skupina-nadpis {
  font-family: var(--font-heading);
  color: var(--primary-light);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  margin: 0 0 14px;
}

.modul-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px;
}

.modul-kachle {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--shadow);
  transition: border-color .15s, transform .15s, box-shadow .15s;
  position: relative;
  min-height: 132px;
}
.modul-kachle:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.modul-ikona { font-size: 34px; line-height: 1; }
/* Gold čárová SVG ikona modulu (currentColor) */
.modul-ikona-svg {
  display: block;
  width: 40px; height: 40px;
  color: var(--primary-light);
  margin-bottom: 4px;
}
.modul-ikona-svg svg { width: 100%; height: 100%; display: block; }
.modul-logo {
  align-self: flex-start;
  height: 46px;          /* pevná výška = loga různého poměru sednou do jedné linky */
  width: auto;
  max-width: 100%;
  object-fit: contain;
  margin-bottom: 8px;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,.3));
}
/* Název modulu = wordmark v ručním brandovém písmu */
.modul-nazev {
  font-family: 'Hulk Rukopis', var(--font-heading);
  font-weight: 400;
  font-size: 30px;
  line-height: 1.05;
  letter-spacing: 0.5px;
  color: var(--text-strong);
}
.modul-popis { color: var(--muted); font-size: 14px; }

.modul-kachle-disabled {
  opacity: 0.55;
  cursor: default;
  box-shadow: none;
}
.modul-kachle-disabled:hover {
  border-color: var(--border);
  transform: none;
  box-shadow: none;
}

.modul-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: var(--warning);
  background: var(--warning-bg);
  border: 1px solid var(--warning-border);
  border-radius: 999px;
  padding: 3px 9px;
}

/* (Topbar hvězda ⭐ + popover oblíbených zrušeny — přidání/odebrání je teď
   v účtovém menu (.acct), výpis v liště pod záhlavím (.fav). Mrtvé styly
   .hvezda/.oblibene-* odstraněny.) */

/* =========================================================================
   MOBILNÍ OBÁLKA SHELLU (≤760px) — topbar bez hamburgeru (avatar zůstává),
   spodní lišta ovládání modulu, full-width sheety. Je až na konci souboru,
   takže přebíjí starší @media(760px) pravidla (.topnav dropdown apod.).
   ========================================================================= */
.modul-bar { display: none; }   /* desktop: skrytá; mobil ji zapne níž */

@media (max-width: 760px) {
  /* --- Topbar kompaktní; drobeček = jen aktuální modul --- */
  .topbar { min-height: 52px; }
  .brand-group { gap: 8px; min-width: 0; flex: 1 1 auto; overflow: hidden; }
  .brand-toggle { padding: 2px 4px; }
  .brand-caret { display: none; }
  .brand-group > .brand-sep { display: none; }
  .brand-group > .brand-modul { display: none; }
  .brand-group > .brand-modul:last-child { display: inline-flex; min-width: 0; }
  .brand-modul-text { font-size: 18px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

  /* --- Mobil: logo = menu platformy, avatar = účet. Lišta modulu se sbalí
         do burgeru (.nav-collapsed, řeší JS) na jakékoli šířce. --- */
  .nav-toggle { display: none !important; }   /* starý hamburger pryč */
  .topnav {
    position: static; display: flex; flex-direction: row; align-items: center;
    width: auto; min-width: 0; max-width: none; margin: 0 0 0 auto; padding: 0;
    gap: 0; background: none; border: none; box-shadow: none;
  }
  .topnav .acct { display: inline-flex; }

  /* --- Menu platformy (logo), účet i menu modulu = full-width sheet --- */
  .logo-menu, .acct-menu, .modul-menu {
    position: fixed; left: 0; right: 0; top: 52px; width: auto;
    min-width: 0; max-width: none; border-radius: 0 0 14px 14px;
    max-height: calc(100vh - 52px); overflow-y: auto;
  }
  .logo-menu .lm-item, .logo-menu .lm-home, .acct-item, .modul-menu .mm-item { padding: 12px 14px; font-size: 15px; }

  /* --- Oblíbené = vodorovný scroll-strip --- */
  .fav-items { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .fav-items::-webkit-scrollbar { height: 0; }
  .fav-chip { flex: 0 0 auto; }

  /* --- Spodní lišta modulu (jen ovládací prvky přes section); když ji modul
         použije, dá si obsah dost spodního paddingu sám. --- */
  .modul-bar {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 120;
    min-height: 58px; padding-bottom: env(safe-area-inset-bottom, 0);
    background: var(--surface-2); border-top: 1px solid var(--border);
    box-shadow: 0 -6px 20px rgba(0,0,0,.3); align-items: stretch;
  }
  /* default = nav taby (registrová lišta modulu) */
  .modul-bar .mb-tab {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 3px; color: var(--muted); text-decoration: none; font-size: 11px; padding: 6px 2px; min-width: 0;
  }
  .modul-bar .mb-tab .mb-ic { font-size: 19px; line-height: 1; }
  .modul-bar .mb-tab .mb-lbl { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
  .modul-bar .mb-tab.is-current { color: var(--primary-light); }
  /* pomocné třídy pro modulový override (@section('modul_dolni_lista')):
     toolbar / nástroje editoru — modul si je naskládá vodorovně, scroll. */
  .modul-bar.is-toolbar { gap: 7px; padding: 0 9px; overflow-x: auto; justify-content: flex-start; }
  .modul-bar.is-toolbar::-webkit-scrollbar { height: 0; }
}

/* =========================================================================
   Lišta modulu → burger, když se nevejde (JS přidá .nav-collapsed na .topbar).
   Platí na jakékoli šířce (desktop i mobil). Burger otevírá menu se stejnými
   položkami jako lišta. Reuse globálního [data-dropdown] handleru.
   ========================================================================= */
.topnav > a { white-space: nowrap; }   /* aby šlo měřit přetečení (nezalamovat) */
.modul-menu-wrap { position: relative; display: inline-flex; align-items: center; }
.modul-burger { display: none; flex-direction: column; justify-content: center; gap: 4px;
  width: 38px; height: 34px; padding: 0; background: none; border: 1px solid transparent;
  border-radius: 8px; cursor: pointer; }
.modul-burger:hover { background: var(--surface); border-color: var(--border); }
.modul-burger span { display: block; height: 2px; width: 18px; margin: 0 auto; background: var(--text); border-radius: 2px; }
.modul-burger:hover span { background: var(--primary-light); }

.modul-menu {
  display: none; position: absolute; top: calc(100% + 8px); right: 0; z-index: 200;
  min-width: 200px; background: var(--surface); border: 1px solid var(--border);
  border-radius: 12px; box-shadow: 0 18px 50px rgba(0,0,0,.55); padding: 6px;
}
.modul-menu-wrap[data-dropdown].open .modul-menu { display: block; }
.modul-menu .mm-item { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 8px;
  color: var(--text); text-decoration: none; font-size: 14px; white-space: nowrap; }
.modul-menu .mm-item:hover { background: var(--surface-hover); color: var(--text); text-decoration: none; }
.modul-menu .mm-item.is-current { background: rgba(200, 155, 60, .14); color: var(--primary-light); }
.modul-menu .mm-ic { width: 20px; height: 20px; flex: none; color: var(--primary-light);
  display: inline-flex; align-items: center; justify-content: center; }
.modul-menu .mm-ic svg { width: 18px; height: 18px; display: block; }

/* Sbaleno: skryj inline lištu + nápovědu, ukaž burger. */
.nav-collapsed .topnav > a { display: none; }
.nav-collapsed .np-help { display: none; }
.nav-collapsed .modul-burger { display: inline-flex; }
