.power-login { display: grid; min-height: 100vh; align-items: center; padding: 32px; }
.power-grid { display: grid; grid-template-columns: minmax(320px, .75fr) minmax(0, 1.25fr); gap: 14px; }
.tenant-list { display: grid; gap: 10px; }
.tenant-card { display: grid; gap: 8px; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: #fbfdfd; cursor: pointer; transition: border-color .12s, background .12s, box-shadow .12s; }
.tenant-card:hover { border-color: var(--brand); background: #f4fbfb; }
.tenant-card:focus-visible { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(13, 89, 97, .22); }
.tenant-card header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.tenant-card-actions { display: inline-flex; gap: 6px; }
.tenant-brand { display: grid; gap: 4px; padding: 10px; border-radius: 6px; color: #fff; background: var(--tenant-color, var(--brand)); }
.tenant-modules, .module-checks { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.module-checks label { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 0 10px; border: 1px solid var(--line); border-radius: 999px; background: #fff; font-weight: 800; }
.module-checks input[type="checkbox"] { inline-size: 16px; block-size: 16px; flex: 0 0 16px; margin: 0; accent-color: var(--brand); }
.repeat-block { display: grid; gap: 8px; margin-top: 12px; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius); background: #f6fbfb; }
.repeat-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)) auto; gap: 8px; align-items: end; padding: 8px; border-radius: 6px; background: #fff; }
.repeat-row.two { grid-template-columns: 180px minmax(0, 1fr) auto; }
.repeat-row label { display: grid; gap: 5px; color: var(--muted); font-size: .78rem; font-weight: 900; }
.repeat-row input { min-height: 34px; border: 1px solid var(--line); border-radius: 6px; padding: 7px 9px; }
.tenant-users-block { background: #f8fbff; }
.tenant-user-list { display: grid; gap: 8px; }
.tenant-user-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 9px 10px; border: 1px solid var(--line); border-radius: 6px; background: #fff; }
.tenant-user-row strong, .tenant-user-row span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tenant-user-row span { color: var(--muted); font-size: .78rem; font-weight: 800; }
.empty-small { padding: 10px; border: 1px dashed var(--line); border-radius: 6px; color: var(--muted); font-weight: 800; background: #fff; }
.full-button { width: 100%; margin-bottom: 10px; }
.storage-plan { overflow: auto; padding: 14px; border-radius: var(--radius); background: #102326; color: #e8f5f6; line-height: 1.55; }
.access-grid { display: grid; grid-template-columns: minmax(320px, .82fr) minmax(0, 1.18fr); gap: 14px; align-items: start; }
.access-filter-row, .access-toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.access-filter-row button { min-width: 34px; min-height: 32px; border: 1px solid var(--line); border-radius: 6px; background: #fff; font-weight: 900; }
.access-filter-row button.is-active { border-color: var(--brand); background: #dff4f4; color: var(--brand-deep); }
.access-toolbar { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(180px, auto) auto; }
.access-toolbar input, .access-toolbar select { min-height: 38px; border: 1px solid var(--line); border-radius: 6px; padding: 8px 10px; background: #fff; }
.company-access-list, .access-user-list { display: grid; gap: 10px; }
.company-access-slot { border: 1px solid var(--line); border-radius: var(--radius); background: #fbfdfd; }
.company-access-slot summary { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 12px; cursor: pointer; }
.company-access-slot summary::marker { color: var(--brand); }
.company-access-slot summary span { display: grid; gap: 3px; min-width: 0; }
.company-access-slot summary strong, .company-access-slot summary small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.company-access-slot summary small { color: var(--muted); font-weight: 800; }
.tenant-modules.compact { margin: 0 12px 10px; }
.company-slot-users { display: grid; gap: 6px; padding: 0 12px 12px; }
.company-slot-users button { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; width: 100%; min-height: 34px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 6px; background: #fff; text-align: left; font-weight: 900; }
.company-slot-users button span, .company-slot-users em { color: var(--muted); font-size: .78rem; font-weight: 800; }
.access-user-row { display: grid; gap: 8px; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: #fbfdfd; }
.access-user-row header { display: flex; gap: 10px; align-items: center; justify-content: space-between; }
.access-actions { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
.online-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; align-items: start; }
.online-panel, .session-history-panel { margin-bottom: 14px; }
.online-session-list, .session-history-list { display: grid; gap: 8px; }
.online-session-row, .session-history-row { display: grid; gap: 12px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #fbfdfd; }
.online-session-row { grid-template-columns: minmax(0, 1fr) minmax(260px, auto); }
.session-history-row { grid-template-columns: minmax(220px, 1.1fr) minmax(150px, .7fr) minmax(150px, .7fr) minmax(150px, .6fr); }
.session-history-row.is-online { border-color: rgba(13, 89, 97, .35); background: #f2fbfb; }
.online-session-row div, .session-history-row div { display: grid; gap: 3px; min-width: 0; }
.online-session-row strong, .online-session-row span, .session-history-row strong, .session-history-row span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.online-session-row span, .session-history-row span { color: var(--muted); font-size: .78rem; font-weight: 800; }
.modal-card { display: grid; gap: 14px; width: min(760px, 100%); max-height: calc(100vh - 36px); overflow: auto; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); }
.modal-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.modal-header h2 { margin: 0; }
.access-user-dialog .form-actions { margin-top: 4px; }
@media (max-width: 980px) { .power-grid, .access-grid, .access-toolbar, .repeat-row, .repeat-row.two, .online-grid, .online-session-row, .session-history-row { grid-template-columns: 1fr; } }

/* Diagnostika sekce */
.diagnostic-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}
.diagnostic-grid a {
  text-align: center;
  text-decoration: none;
}
.diagnostic-steps {
  line-height: 1.6;
  margin: 8px 0 0;
  padding-left: 22px;
}
.diagnostic-ok {
  color: #9adca2;
  font-weight: 700;
}

/* ─────────────────────────────────────────────────────────────────────────
 * Accomodeus Design System — sdílený snippet pro všechny moduly
 * Verze: 20260603
 *
 * Přidává:
 *  · Globální button systém (obdélníkové/čtvercové se zaoblenými rohy)
 *  · Status-light pattern (světelné semafory s popiskem)
 *  · Normalizaci checkboxů (16×16, brand accent, 20px gap)
 *
 * Připojuje se na konec styles.css každého modulu. Pravidla mají vysokou
 * specificity / pozdější pořadí, takže přepíší starší definice.
 * ─────────────────────────────────────────────────────────────────────── */

:root {
  --acc-brand-deep: #073f46;
  --acc-brand: #0d5961;
  --acc-brand-light: #5aaeb0;
  --acc-line: #d9e1e3;
  --acc-ink: #102326;
  --acc-muted: #617174;
  --acc-radius: 8px;
  --acc-radius-sm: 6px;
}

/* ── Buttons ───────────────────────────────────────────────────────────── */
.primary-button,
.ghost-button,
.action-button,
.danger-button,
.warning-button,
.incident-button,
.draft-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: var(--acc-radius);
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease, color 120ms ease;
  text-decoration: none;
}

.primary-button,
.action-button {
  border-color: var(--acc-brand);
  color: #ffffff;
  background: var(--acc-brand);
}
.primary-button:hover,
.action-button:hover {
  background: var(--acc-brand-deep);
  border-color: var(--acc-brand-deep);
}

.ghost-button {
  border-color: var(--acc-line);
  color: var(--acc-brand-deep);
  background: #ffffff;
}
.ghost-button:hover { border-color: var(--acc-brand); }

.danger-button {
  border-color: rgba(185, 66, 66, 0.5);
  color: #842b2b;
  background: #fff2f2;
}
.danger-button:hover { background: #ffe6e6; border-color: #b94242; }

.warning-button {
  border-color: rgba(212, 163, 23, 0.55);
  color: #7a5a00;
  background: #fdf5dd;
}
.warning-button:hover { background: #fbecb6; border-color: #d4a317; }

.incident-button {
  border-color: #7d2738;
  color: #ffffff;
  background: #7d2738;
}
.incident-button:hover { background: #5e1d2a; border-color: #5e1d2a; }

.draft-button {
  border-color: rgba(46, 143, 111, 0.55);
  color: #1d6b46;
  background: #d9f0e2;
}
.draft-button:hover { background: #c2e6cf; border-color: #2e8f6f; }

.text-button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 0;
  padding: 0;
  border: 0;
  color: #4c78b9;
  background: transparent;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}
.text-button:hover { text-decoration: underline; }

.mini-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid var(--acc-line);
  border-radius: var(--acc-radius-sm);
  color: var(--acc-brand-deep);
  background: #ffffff;
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease, color 120ms ease;
}
.mini-button:hover { border-color: var(--acc-brand); color: var(--acc-brand); }
.mini-button.is-secondary { background: #fafdfd; }

/* ── Status světla (semafor) ──────────────────────────────────────────── */
.status-light {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px 2px 6px;
  border: 1px solid currentColor;
  border-radius: var(--acc-radius-sm);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.4;
  vertical-align: middle;
  background: var(--status-bg, transparent);
  color: var(--status-fg, var(--acc-ink));
}
.status-light::before {
  content: "";
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--status-fg, currentColor);
  box-shadow: 0 0 0 2px var(--status-glow, rgba(0, 0, 0, 0.08));
}
.status-light-ok      { --status-fg: #1d6b46; --status-bg: #d9f0e2; --status-glow: rgba(46, 143, 111, 0.22); border-color: rgba(46, 143, 111, 0.45); }
.status-light-warn    { --status-fg: #8a6800; --status-bg: #fdf5dd; --status-glow: rgba(212, 163, 23, 0.22); border-color: rgba(212, 163, 23, 0.45); }
.status-light-danger  { --status-fg: #7a3a3a; --status-bg: #fdecec; --status-glow: rgba(185, 66, 66, 0.22); border-color: rgba(185, 66, 66, 0.45); }
.status-light-info    { --status-fg: #1c4b7a; --status-bg: #e3f0fa; --status-glow: rgba(76, 120, 185, 0.22); border-color: rgba(76, 120, 185, 0.45); }
.status-light-pending { --status-fg: #7a4500; --status-bg: #fcecd4; --status-glow: rgba(212, 130, 23, 0.22); border-color: rgba(212, 130, 23, 0.45); }
.status-light-idle    { --status-fg: #4f5b5e; --status-bg: #eaeeef; --status-glow: rgba(100, 110, 115, 0.18); border-color: rgba(100, 110, 115, 0.35); }

.status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 6px;
  border-radius: 50%;
  vertical-align: middle;
  background: var(--status-fg, currentColor);
  box-shadow: 0 0 0 2px var(--status-glow, rgba(0, 0, 0, 0.08));
}
.status-dot-ok      { --status-fg: #2e8f6f; --status-glow: rgba(46, 143, 111, 0.22); }
.status-dot-warn    { --status-fg: #d4a317; --status-glow: rgba(212, 163, 23, 0.22); }
.status-dot-danger  { --status-fg: #b94242; --status-glow: rgba(185, 66, 66, 0.22); }
.status-dot-info    { --status-fg: #4c78b9; --status-glow: rgba(76, 120, 185, 0.22); }
.status-dot-idle    { --status-fg: #8896a0; --status-glow: rgba(100, 110, 115, 0.18); }

/* ── Checkbox normalizace ──────────────────────────────────────────────── */
input[type="checkbox"] {
  width: 16px;
  height: 16px;
  min-height: 16px;
  margin: 0;
  accent-color: var(--acc-brand);
  cursor: pointer;
}
label.compact-check,
.compact-check {
  display: inline-flex;
  align-items: center;
  gap: 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--acc-brand-deep);
}


/* ── Firmy: vlevo rozcestník (název + předplatné), vpravo detail ─────────── */
.list-tools { display: flex; gap: 8px; padding: 0 0 10px; }
.list-tools input[type="search"] { flex: 1 1 auto; min-width: 150px; padding: 6px 10px; font-size: 12.5px; }
.list-tools select { flex: 0 0 auto; width: 170px; padding: 6px 8px; font-size: 12.5px; }

.tenant-list { display: grid; gap: 6px; }
.tenant-slot {
  display: grid; grid-template-columns: minmax(0, 1fr) auto 8px; align-items: center; gap: 12px;
  padding: 9px 12px; border: 1px solid var(--line); border-left: 3px solid transparent;
  border-radius: 10px; background: #fbfdfd; cursor: pointer;
  transition: border-color .12s, background .12s;
}
.tenant-slot:hover { background: #f2fafa; border-color: var(--brand); }
.tenant-slot:focus-visible { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(13, 89, 97, .2); }
.tenant-slot.is-active { background: #eaf6f6; border-color: var(--brand); border-left-color: var(--brand); }
.tenant-slot__main { display: grid; gap: 2px; min-width: 0; }
.tenant-slot__main strong { font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tenant-slot__price { display: grid; gap: 2px; justify-items: end; text-align: right; white-space: nowrap; }
.tenant-slot__price strong { font-size: 13.5px; font-variant-numeric: tabular-nums; }
.tenant-slot__sub { font-size: 10.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tenant-slot__state { width: 8px; height: 8px; border-radius: 50%; background: #9aa5a8; }
.tenant-slot__state.is-active { background: #1a7a4a; }
.tenant-slot__state.is-setup { background: #d69e2e; }
.tenant-slot__state.is-paused { background: #c62828; }

/* Předplatné a nabídky v detailu */
.sub-summary { display: flex; align-items: flex-end; gap: 22px; flex-wrap: wrap; padding: 12px 0 14px; }
.sub-kpi { display: grid; gap: 2px; }
.sub-kpi span { font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.sub-kpi strong { font-size: 20px; font-variant-numeric: tabular-nums; color: var(--brand-dark, #073f46); }
.sub-summary .primary-button { margin-left: auto; }
#tenant-subscription .data-table .num { text-align: right; white-space: nowrap; }
#tenant-subscription .data-table tfoot th { border-top: 2px solid var(--line); font-variant-numeric: tabular-nums; }
@media (max-width: 700px) { .list-tools { flex-direction: column; } .sub-summary .primary-button { margin-left: 0; } }


/* Detail firmy se musí vejít do svého sloupce. Globální `table { min-width: 980px }`
   je pro široké přehledy; v úzkém detailu roztahoval celou stránku o 190 px. */
.power-grid > * { min-width: 0; }
.settings-form { min-width: 0; }
#tenant-subscription { min-width: 0; }
#tenant-subscription table { min-width: 0; }
#tenant-subscription th, #tenant-subscription td { padding: 8px 10px; font-size: 12.5px; }

/* ── Prostředí firmy: náhled loga a barvy ───────────────────────────────── */
.brand-upload { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.brand-preview {
  display: flex; align-items: center; gap: 10px; min-width: 220px; min-height: 56px;
  padding: 10px 14px; border-radius: 10px; color: #fff;
  background: var(--brand); box-shadow: inset 0 0 0 1px rgba(255,255,255,.18);
}
.brand-preview img { max-height: 34px; max-width: 120px; object-fit: contain; }
.brand-preview__name { font-weight: 700; font-size: 13px; }
.brand-preview__miss { font-size: 11px; opacity: .75; }
.brand-upload__actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; flex: 1 1 240px; min-width: 0; }
.brand-upload__actions .row-meta { flex: 1 1 100%; }

/* Dialog hesla super-správce */
.power-password-card { width: min(460px, 94vw); }
.power-password-card #power-password-new { font-family: ui-monospace, Consolas, monospace; letter-spacing: .04em; }


/* ── Moduly firmy: tabulka o třech sloupcích ────────────────────────────────
   Dřív to bylo pole různě širokých štítků — nešlo to očima projet a ceny
   nebyly pod sebou. Tabulka drží sloupce zarovnané při jakékoli šířce. */
#module-checks table { min-width: 0; width: 100%; table-layout: fixed; }
#module-checks th, #module-checks td { padding: 7px 10px; font-size: 12.5px; vertical-align: middle; }
#module-checks thead th { font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em; }
.module-table__group th {
  padding-top: 12px; font-size: 10.5px; text-transform: uppercase; letter-spacing: .05em;
  color: var(--muted); background: transparent; border-bottom: 1px solid var(--line);
}
.module-table tbody tr.is-on { background: rgba(13, 89, 97, .05); }
.module-table tbody tr:hover { background: rgba(13, 89, 97, .08); }
.module-table__pick { width: 58%; }
.module-table__pick label { display: flex; align-items: flex-start; gap: 9px; cursor: pointer; }
.module-table__pick input[type="checkbox"] { width: 16px; height: 16px; margin: 1px 0 0; flex: 0 0 auto; }
.module-table__pick strong { display: block; font-weight: 600; }
.module-table__pick small { display: block; font-size: 10.5px; color: var(--muted); }
.module-table__state { width: 17%; white-space: nowrap; }
.module-table__price { width: 25%; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
@media (max-width: 700px) {
  .module-table__pick { width: 52%; }
  .module-table__state { width: 20%; }
  .module-table__price { width: 28%; }
}
.module-col-name { width: 58%; }
.module-col-state { width: 17%; }
.module-col-price { width: 25%; }

/* ── Dialog nabídky: žádné posuvníky uvnitř, nic useknutého ─────────────────
   Globální `table { min-width: 980px }` je pro široké přehledy — v dialogu
   vyrobil vodorovný posuvník a uřízl sloupce Stav i Cena. */
.offer-dialog { width: min(920px, 96vw); max-height: none; overflow: visible; }
.offer-dialog .table-wrap { overflow: visible; }
.offer-dialog table { min-width: 0; width: 100%; table-layout: fixed; }
.offer-col-name { width: 56%; }
.offer-col-state { width: 18%; }
.offer-col-price { width: 26%; }
.offer-dialog th, .offer-dialog td { padding: 6px 10px; }
/* Backdrop smí rolovat, když je dialog vyšší než okno — vnitřní scroll oblasti ne. */
.modal-backdrop { overflow-y: auto; align-items: flex-start; }
.modal-backdrop > .modal-card { margin: 18px auto; }

/* Poznámka pod polem (slug, VIP) a VIP pruh v kartě předplatného */
.field-note { display: block; margin-top: 4px; font-size: 10.5px; line-height: 1.35; color: var(--muted); font-weight: 400; }
.field-note.is-ok { color: #1a7a4a; }
.field-note.is-bad { color: #c62828; }
.link-button { background: none; border: none; padding: 0; font: inherit; color: var(--brand); text-decoration: underline; cursor: pointer; }
.vip-note {
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  margin: 4px 0 12px; padding: 10px 14px; border-radius: 10px;
  background: rgba(214, 158, 46, .12); border: 1px solid rgba(214, 158, 46, .35); font-size: 12.5px;
}


/* ═══ Online: na první pohled poznat, kdo opravdu pracuje (2026-08-10) ═══ */
.online-session-row .live-dot { display: inline-block; width: 8px; height: 8px; margin-right: 7px;
  border-radius: 50%; background: #94a3b8; vertical-align: middle; }
.online-session-row.is-live .live-dot { background: #16a34a; box-shadow: 0 0 0 3px rgba(22, 163, 74, .18); }
.online-session-row.is-recent .live-dot { background: #65a30d; }
.online-session-row.is-idle .live-dot { background: #f59e0b; }
.online-session-row.is-stale .live-dot { background: #cbd5e1; }


/* Historie přihlášení: lišta a stránkování (2026-08-10) */
.history-toolbar { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 8px; margin-bottom: 10px; }
.history-pager { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 10px;
  font-size: 12px; color: var(--muted, #64777d); }
.history-pager button[disabled] { opacity: .4; cursor: default; }
@media (max-width: 900px) { .history-toolbar { grid-template-columns: 1fr 1fr; } }


/* ═══ Bonusový modul v nabídce (2026-08-11) ═══ */
.offer-table .offer-col-bonus { width: 168px; }
.offer-table .bonus-cell { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.offer-table .bonus-months { min-height: 26px; padding: 2px 6px; font-size: 11.5px; border: 1px solid var(--line, #dce4e6); border-radius: 6px; }
.offer-table tr.is-bonus { background: #f2faf8; }
.offer-table tr.is-bonus .bonus-free { color: #0d5961; font-weight: 800; }
.offer-line--bonus { color: #0d5961; }
.offer-line--bonus strong { font-weight: 800; }

/* ═══ Popisy modulů: každý modul vlastní panel ═══
   Předchozí verze lepila všechny moduly pod sebe do jednoho sloupce a byl
   z toho nekonečný formulář, ve kterém nešlo najít konec jednoho a začátek
   druhého. */
#module-texts-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(430px, 1fr)); gap: 12px; align-items: start; }
/* Každý modul je samostatný box s viditelnou hranou a vlastní hlavičkou.
 * Dřív se karty lišily jen mezerou a při větším počtu modulů splývaly
 * v jednu plochu — na obrazovce s osmnácti moduly se v tom nedalo číst. */
.module-text-row { margin: 0; padding: 0; border: 2px solid #cfdcde; border-radius: 12px;
  background: #fff; box-shadow: 0 2px 6px rgba(9,42,46,.09); overflow: hidden; }
.module-text-row:hover { border-color: #0d5961; }
.module-text-row .mt-head { display: flex; align-items: center; gap: 6px; margin: 0;
  padding: 9px 13px; background: #eef5f6; border-bottom: 2px solid #cfdcde; }
.module-text-row .mt-fields { padding: 11px 13px 0; }
.module-text-row .mt-internal { margin: 9px 13px 12px; }
.module-text-row .mt-head strong { font-size: 14.5px; color: #0d3f45; }
.module-text-row .mt-head .row-meta { font-size: 11px; opacity: .75; }
.module-text-row .mt-fields { grid-template-columns: 1fr; gap: 7px; }
.module-text-row label { text-transform: none; letter-spacing: 0; }
.module-text-row input, .module-text-row textarea { padding: 5px 8px; min-height: 30px; border-radius: 6px; }
.module-text-row textarea { min-height: 46px; resize: vertical; }
@media (max-width: 1000px) { #module-texts-list { grid-template-columns: 1fr; } }


/* Oslovení v nabídce */
.offer-salut { display: grid; gap: 3px; margin: 0 0 10px; font-size: 11.5px; font-weight: 800; color: var(--muted, #64777d); }
.offer-salut input { min-height: 34px; padding: 6px 10px; border: 1px solid var(--line, #dce4e6); border-radius: 7px;
  font: inherit; font-size: 13px; font-weight: 600; color: var(--ink, #102326); background: #fff; }
.offer-salut .row-meta { font-weight: 500; }

.offer-salut select { min-height: 34px; padding: 6px 10px; border: 1px solid var(--line, #dce4e6); border-radius: 7px;
  font: inherit; font-size: 13px; font-weight: 600; color: var(--ink, #102326); background: #fff; }


/* ═══ Řádek nabídky: stejná výška se zapnutým i vypnutým bonusem ═══
   Rozbalovací pole s dobou bonusu se objevuje jen u zaškrtnutých položek —
   řádky bez něj byly o kus nižší a celý sloupec ceny „ustřeloval". Buňky
   proto drží pevnou minimální výšku a všechno se zarovnává na střed. */
.offer-table td { vertical-align: middle; height: 46px; }
.offer-table .bonus-cell { min-height: 34px; flex-wrap: nowrap; }
.offer-table .bonus-cell .offer-pick { flex: 0 0 auto; }
.offer-table .bonus-months { flex: 0 0 auto; width: 104px; }
/* Místo pro rozbalovací pole se drží i tam, kde zrovna není — jinak by se
   sloupec s cenou posouval podle toho, co je zaškrtnuté. */
.offer-table tr:not(.is-bonus) .bonus-cell::after { content: ""; display: block; width: 104px; }
.offer-table .offer-price { width: 92px; }
.offer-table .bonus-free { display: inline-block; min-width: 92px; text-align: right; }


/* Řádek nabídky (druhý pokus, měřeno):
   1) rozbalovací pole je v buňce VŽDY — u nezaškrtnutých jen zneviditelněné,
      takže výška řádku nekolísá podle toho, co je zapnuté,
   2) cena je v obálce pevné šířky, aby „zdarma" končilo přesně tam,
      kde u ostatních řádků končí „Kč". */
.offer-table .bonus-months.is-placeholder { visibility: hidden; }
.offer-table .price-cell { display: inline-flex; align-items: center; justify-content: flex-end; gap: 5px; width: 132px; }
.offer-table .price-cell .offer-price { width: 92px; text-align: right; }
.offer-table .price-cell .cur { width: 22px; text-align: left; color: var(--muted, #64777d); font-size: 12px; }
.offer-table .price-cell .bonus-free { width: 100%; text-align: right; padding-right: 27px; }
.offer-table tr:not(.is-bonus) .bonus-cell::after { content: none; }


/* Měřením zjištěno: vyšší byl BĚŽNÝ řádek (pole pro cenu má 38 px), zatímco
   bonusový měl na jeho místě jen text. Obálka ceny proto drží stejnou výšku
   v obou případech a řádky jsou pak přesně stejné. */
.offer-table .price-cell { height: 38px; }
.offer-table .price-cell .bonus-free { display: flex; align-items: center; justify-content: flex-end; height: 100%; }


/* Platby za moduly */
.pay-row { display: grid; grid-template-columns: minmax(0,2fr) 140px 200px auto; gap: 12px; align-items: center;
  padding: 9px 12px; border: 1px solid var(--line, #dce4e6); border-radius: 10px; margin-bottom: 6px; background: #fff; }
.pay-row.is-open { border-left: 4px solid #d97706; }
.pay-amount { font-weight: 800; text-align: right; font-variant-numeric: tabular-nums; }
.badge.is-warn { background: #fef3c7; color: #92400e; }
@media (max-width: 900px) { .pay-row { grid-template-columns: 1fr auto; } }


/* Objednávky modulů */
.ord-row { display: grid; grid-template-columns: minmax(0,2fr) 150px 130px 150px auto; gap: 12px; align-items: center;
  padding: 9px 12px; border: 1px solid var(--line, #dce4e6); border-radius: 10px; margin-bottom: 6px; background: #fff; }
.ord-vs { font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; }
.ord-amount { font-weight: 800; text-align: right; font-variant-numeric: tabular-nums; }
.ord-row .row-meta { display: block; font-weight: 500; font-family: inherit; }
@media (max-width: 1000px) { .ord-row { grid-template-columns: 1fr auto; } }


/* Interní modul */
.module-text-row.is-internal { border-color: #c9a227; background: #fffdf5; }
.module-text-row.is-internal .mt-head { background: #fdf3d8; border-bottom-color: #e2c76a; }
.module-text-row.is-changed { border-color: #0d5961; }
.module-text-row.is-changed .mt-head { background: #e2f2f3; border-bottom-color: #9cc6ca; }
#module-texts-list { gap: 14px; }
.pill--internal { background: #fef3c7; color: #92400e; }
.mt-internal { display: flex; align-items: flex-start; gap: 8px; margin-top: 8px;
  padding: 8px 10px; border-radius: 8px; background: #f7f9fa; font-size: 12.5px; line-height: 1.45; }
.mt-internal input { width: 16px; height: 16px; margin: 1px 0 0; flex: 0 0 16px; }
.mt-internal strong { color: #92400e; }


/* Odesílání e-mailů */
.mail-form { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; margin: 10px 0; }
.mail-form label { display: flex; flex-direction: column; gap: 3px; font-size: 11.5px; font-weight: 700;
  color: var(--muted, #64777d); }
.mail-form input, .mail-form select { font-size: 13px; padding: 6px 8px; }
#mail-testto { min-width: 220px; }
.pill.is-ok { background: #dcfce7; color: #15803d; }
@media (max-width: 1000px) { .mail-form { grid-template-columns: 1fr 1fr; } }


/* Odeslání nabídky */
.mail-offer { width: min(680px, 100%); }
.mail-offer-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-bottom: 10px; }
.mail-offer-grid label { display: flex; flex-direction: column; gap: 3px; font-size: 11.5px; font-weight: 700;
  color: var(--muted, #64777d); }
.mail-offer-grid .c2 { grid-column: span 2; }
.mail-offer-grid .c3 { grid-column: span 3; }
.mail-offer-grid input, .mail-offer-grid textarea { font-size: 13px; padding: 7px 9px; }
.mail-offer-grid textarea { font-family: inherit; line-height: 1.5; resize: vertical; }
@media (max-width: 640px) {
  .mail-offer-grid { grid-template-columns: 1fr; }
  .mail-offer-grid .c2, .mail-offer-grid .c3 { grid-column: span 1; }
}


/* Po splatnosti */
.dun-row { display: grid; grid-template-columns: minmax(0,1.6fr) 110px 110px 150px auto; gap: 12px; align-items: center;
  padding: 10px 13px; border: 1px solid var(--line, #dce4e6); border-radius: 10px; margin-bottom: 6px; background: #fff; }
.dun-row.is-late { border-color: #d9a441; background: #fffaf0; }
.dun-row.is-restricted { grid-template-columns: 1fr auto; border-color: #dc2626; background: #fef2f2; }
.dun-days { text-align: center; }
.dun-days strong { display: block; font-size: 20px; line-height: 1; color: #92400e; }
.dun-days span { font-size: 10.5px; color: var(--muted, #64777d); }
.dun-amount { font-weight: 800; text-align: right; font-variant-numeric: tabular-nums; }
.dun-stage { font-size: 12.5px; }
.dun-row .row-meta { display: block; font-weight: 500; }
@media (max-width: 1100px) { .dun-row { grid-template-columns: 1fr auto; } }
