:root {
  --blue: #1e6571;
  --blue-dark: #134b55;
  --blue-soft: #e8f0ee;
  --red: #d73542;
  --ink: #17272b;
  --muted: #5c6a6e;
  --line: #d9dedb;
  --page: #f3f2ed;
  --surface: #fff;
  --sidebar: #14272c;
  --shadow: 0 16px 42px rgba(20, 39, 44, .1);
  font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html[data-layout="compact"] table td, html[data-layout="compact"] table th { padding-top: .45rem; padding-bottom: .45rem; }
[hidden] { display: none !important; }
html { min-width: 320px; min-height: 100%; scroll-behavior: smooth; }
body { min-width: 320px; min-height: 100vh; margin: 0; color: var(--ink); background: var(--page); font-size: 16px; line-height: 1.5; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: var(--blue-dark); }
a:hover, a:focus-visible { color: var(--red); }

.skip-link { position: fixed; z-index: 100; top: .5rem; left: .5rem; padding: .65rem 1rem; color: #fff; background: var(--red); transform: translateY(-150%); }
.skip-link:focus { transform: translateY(0); }
.portal-shell { display: grid; min-height: 100vh; grid-template-columns: 270px minmax(0, 1fr); }
.portal-sidebar { position: sticky; z-index: 20; top: 0; display: flex; height: 100vh; padding: 1.35rem 1rem; flex-direction: column; color: #e5eeeb; background: var(--sidebar); }
.portal-sidebar::before { position: absolute; inset: 0 0 auto; height: 4px; background: var(--red); content: ""; }
.brand { display: flex; margin: .25rem .35rem .6rem; align-items: center; gap: .8rem; color: #fff; text-decoration: none; }
.brand:hover, .brand:focus-visible { color: #fff; }
.brand__mark { display: grid; width: 43px; height: 43px; place-items: center; border: 2px solid #8eb8bc; border-radius: 50%; color: #fff; font-size: 14px; font-weight: 800; letter-spacing: -.03em; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 20px; line-height: 1.05; }
.brand small { margin-top: .25rem; color: #aebfc0; font-size: 13px; }
.portal-home { display: flex; min-height: 40px; margin: 0 .35rem 1.1rem; padding: .45rem .6rem; align-items: center; gap: .7rem; border-radius: 5px; color: #cbd7d6; font-size: 14px; font-weight: 650; text-decoration: none; }
.portal-home svg { flex: 0 0 20px; }
.portal-home:hover, .portal-home:focus-visible { color: #fff; background: rgba(255,255,255,.07); }
.portal-home:focus-visible { outline: 2px solid #8eb8bc; outline-offset: 2px; }
.auth-screen { display: grid; min-height: 100vh; padding: clamp(1.25rem, 5vw, 4rem); place-items: center; background: linear-gradient(145deg, var(--sidebar), #1f4f58); }
.auth-card { width: min(520px, 100%); padding: clamp(1.5rem, 5vw, 3rem); border-top: 4px solid var(--red); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); }
.auth-brand { display: flex; margin-bottom: 2.2rem; align-items: center; gap: .8rem; color: var(--ink); text-decoration: none; }
.auth-brand:hover, .auth-brand:focus-visible { color: var(--ink); }
.auth-brand .brand__mark { color: #fff; background: var(--sidebar); }
.auth-brand strong, .auth-brand small { display: block; }
.auth-brand strong { font-size: 20px; line-height: 1.05; }
.auth-brand small { margin-top: .25rem; color: var(--muted); font-size: 13px; }
.auth-card h1 { margin: .4rem 0 .9rem; font-size: clamp(2rem, 6vw, 3rem); line-height: 1.06; letter-spacing: -.04em; }
.auth-card > p { color: var(--muted); }
.local-login { display: grid; margin-top: 1.4rem; gap: .55rem; }
.local-login button { width: 100%; margin-top: .45rem; }
.alternative-login { display: grid; margin-top: 1.2rem; gap: .7rem; text-align: center; }
.alternative-login > span { display: flex; align-items: center; gap: .7rem; color: var(--muted); font-size: 13px; }
.alternative-login > span::before, .alternative-login > span::after { height: 1px; flex: 1; background: var(--line); content: ""; }
.microsoft-login { width: 100%; }
.auth-note { padding: .75rem .9rem; border-left: 3px solid var(--blue); background: var(--blue-soft); font-size: 14px; }
.button--secondary { color: var(--blue-dark); background: #fff; }
.button--secondary:hover, .button--secondary:focus-visible { color: #fff; background: var(--blue); }
.pending-details { display: grid; margin: 1.4rem 0; gap: .65rem; }
.pending-details div { display: grid; padding: .8rem; border: 1px solid var(--line); border-radius: 7px; }
.pending-details dt { color: var(--muted); font-size: 13px; }
.pending-details dd { margin: 0; font-weight: 750; overflow-wrap: anywhere; }
.portal-nav { display: grid; gap: .28rem; }
.portal-nav a { display: flex; min-height: 45px; padding: .65rem .85rem; align-items: center; border-left: 3px solid transparent; border-radius: 0 6px 6px 0; color: #d6e2e1; font-weight: 650; text-decoration: none; }
.portal-nav a:hover, .portal-nav a:focus-visible { color: #fff; background: rgba(255, 255, 255, .07); outline: none; }
.portal-nav a[aria-current="page"] { border-left-color: var(--red); color: #fff; background: rgba(30, 101, 113, .5); }
.account-summary { display: grid; margin-top: auto; padding: .85rem; border: 1px solid rgba(255,255,255,.15); border-radius: 8px; color: #cbd7d6; font-size: 13px; }
.account-summary strong { color: #fff; }
.account-summary span { margin-top: .15rem; overflow-wrap: anywhere; }
.account-summary button { min-height: 39px; margin-top: .75rem; border: 1px solid #587175; border-radius: 5px; color: #fff; background: transparent; font-weight: 700; cursor: pointer; }
.account-summary button:hover, .account-summary button:focus-visible { background: rgba(255,255,255,.1); }

.portal-workspace { min-width: 0; }
.portal-topbar { position: sticky; z-index: 10; top: 0; display: flex; min-height: 72px; padding: .75rem clamp(1rem, 3vw, 2.4rem); align-items: center; gap: 1rem; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.96); }
.portal-topbar > div { display: grid; }
.portal-topbar strong { font-size: 16px; }
.eyebrow { color: var(--blue-dark); font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.environment-badge { margin-left: auto; padding: .3rem .55rem; border: 1px solid #d9b986; border-radius: 999px; color: #755017; background: #fff8e8; font-size: 12px; font-weight: 750; }
.mobile-menu { display: none; min-height: 40px; padding: .45rem .75rem; border: 1px solid var(--line); border-radius: 6px; color: var(--ink); background: #fff; font-weight: 700; }
.sidebar-backdrop { display: none; }
main { width: min(1320px, 100%); min-height: calc(100vh - 72px); margin: 0 auto; padding: clamp(1.5rem, 4vw, 3rem); outline: none; }
.status-message { margin: 0 0 1.3rem; padding: .85rem 1rem; border-left: 4px solid var(--blue); color: var(--blue-dark); background: var(--blue-soft); }
.status-message[data-kind="error"] { border-left-color: var(--red); color: #862631; background: #fbeaec; }
.portal-view[hidden] { display: none; }
.view-heading { display: flex; margin-bottom: 1.7rem; align-items: end; justify-content: space-between; gap: 1rem; }
.view-heading h1 { margin: .25rem 0 0; font-size: clamp(2rem, 4vw, 3.25rem); line-height: 1.06; letter-spacing: -.04em; }
.view-heading h1::after { display: block; width: 48px; height: 3px; margin-top: .8rem; background: var(--red); content: ""; }
.view-intro { max-width: 760px; margin: -1rem 0 1.6rem; color: var(--muted); font-size: 17px; }
.button { display: inline-flex; min-height: 44px; padding: .65rem 1rem; align-items: center; justify-content: center; border: 1px solid var(--blue); border-radius: 7px; font-weight: 750; text-decoration: none; cursor: pointer; }
.button--primary { color: #fff; background: var(--blue); }
.button--primary:hover, .button--primary:focus-visible { color: #fff; background: var(--blue-dark); }

.summary-grid { display: grid; margin-bottom: 1.3rem; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.summary-card, .surface, .plan-card { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 8px 24px rgba(20, 39, 44, .06); }
.summary-card { display: grid; min-height: 145px; padding: 1.2rem; align-content: start; }
.summary-card span { color: var(--muted); font-size: 14px; font-weight: 700; }
.summary-card strong { margin: .35rem 0 .25rem; font-size: clamp(1.7rem, 3vw, 2.25rem); line-height: 1.05; }
.summary-card small { margin-top: auto; color: var(--muted); font-size: 13px; }
.dashboard-grid, .requests-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.3rem; }
.surface { padding: clamp(1rem, 2vw, 1.45rem); }
.surface h2 { margin: 0 0 1rem; font-size: 21px; }
.surface__heading { display: flex; margin-bottom: .5rem; align-items: baseline; justify-content: space-between; gap: 1rem; }
.surface__heading h2 { margin: 0; }
.surface__heading a { font-size: 14px; font-weight: 700; }
.compact-list article { display: flex; padding: 1rem 0; align-items: center; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--line); }
.compact-list article:last-child { border-bottom: 0; }
.compact-list div, .compact-list b { display: grid; }
.compact-list b { justify-items: end; font-size: 16px; }
.compact-list small { color: var(--muted); font-size: 13px; font-weight: 400; }
.empty-state { margin: 0; padding: 1.2rem 0; color: var(--muted); }

.plans-grid { display: grid; gap: 1.3rem; }
.plan-card { overflow: hidden; }
.plan-card > header { display: flex; padding: clamp(1.2rem, 3vw, 1.8rem); align-items: start; justify-content: space-between; gap: 1.5rem; border-bottom: 1px solid var(--line); }
.plan-card h2 { margin: .7rem 0 .25rem; font-size: 24px; }
.plan-card header p { margin: 0; color: var(--muted); }
.plan-price { display: grid; flex: 0 0 auto; justify-items: end; }
.plan-price strong { font-size: 25px; }
.plan-price span { color: var(--muted); font-size: 13px; }
.plan-card dl { display: grid; margin: 0; padding: 1rem clamp(1.2rem, 3vw, 1.8rem); grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; background: #fafbf9; }
.plan-card dl div { display: grid; }
.plan-card dt { color: var(--muted); font-size: 13px; }
.plan-card dd { margin: 0; font-weight: 700; }
.plan-settings { padding: clamp(1.2rem, 3vw, 1.8rem); }
.plan-settings h3 { margin: 0 0 .7rem; font-size: 18px; }
.setting-row { display: flex; min-height: 66px; padding: .65rem 0; align-items: center; justify-content: space-between; gap: 1rem; border-top: 1px solid var(--line); }
.setting-row > div:first-child { display: grid; }
.setting-row small { color: var(--muted); font-size: 13px; }
.setting-value { font-weight: 750; }
.setting-control { display: flex; gap: .45rem; }
.setting-control input { width: min(230px, 38vw); min-height: 41px; padding: .5rem .65rem; border: 1px solid #b9c6c4; border-radius: 6px; }
.setting-control button { min-height: 41px; padding: .5rem .8rem; border: 1px solid var(--blue); border-radius: 6px; color: var(--blue-dark); background: #fff; font-weight: 750; cursor: pointer; }
.setting-control button:hover, .setting-control button:focus-visible { color: #fff; background: var(--blue); }
.setting-control button:disabled { opacity: .65; cursor: wait; }

.status-pill { display: inline-flex; width: fit-content; padding: .24rem .52rem; border-radius: 999px; color: #45575a; background: #eef1ef; font-size: 12px; font-weight: 800; }
.status-pill--aktivni, .status-pill--uhrazena, .status-pill--odpovezeno { color: #18552f; background: #e2f3e7; }
.status-pill--novy, .status-pill--vystavena { color: #224f77; background: #e4eff8; }
.status-pill--resi_se { color: #755017; background: #fff1ce; }
.status-pill--po_splatnosti { color: #8c2330; background: #fbe3e6; }
.table-wrap { padding: 0; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 1rem 1.15rem; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
th { color: var(--muted); background: #fafbf9; font-size: 13px; letter-spacing: .03em; text-transform: uppercase; }
tbody tr:last-child td { border-bottom: 0; }
.document-list { padding: .4rem 1.25rem; }
.document-list article { display: grid; padding: 1rem 0; align-items: center; grid-template-columns: auto 1fr auto; gap: 1rem; border-bottom: 1px solid var(--line); }
.document-list article:last-child { border-bottom: 0; }
.document-list article > div:nth-child(2) { display: grid; }
.document-list article span { color: var(--muted); font-size: 14px; }
.document-icon { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 7px; color: #fff; background: var(--red); font-size: 11px; font-weight: 900; }

form label { display: block; margin: .9rem 0 .35rem; font-weight: 750; }
form label span { color: var(--muted); font-size: 13px; font-weight: 400; }
form input, form select, form textarea { width: 100%; min-height: 45px; padding: .65rem .75rem; border: 1px solid #b9c6c4; border-radius: 6px; color: var(--ink); background: #fff; }
form textarea { min-height: 145px; resize: vertical; }
form input:focus, form select:focus, form textarea:focus, .setting-control input:focus { border-color: var(--blue); outline: 3px solid rgba(30,101,113,.16); }
form .button { margin-top: 1rem; }
.form-status { min-height: 1.5rem; margin: .65rem 0 0; color: var(--muted); }
.profile-details { max-width: 900px; margin: 0; }
.profile-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem 1rem; }
.profile-details dt { color: var(--muted); font-size: 13px; }
.profile-details dd { margin: .3rem 0 0; font-weight: 750; overflow-wrap: anywhere; }
.request-list { display: grid; gap: .8rem; }
.request-card { padding: 1rem 0; border-bottom: 1px solid var(--line); }
.request-card:first-child { padding-top: 0; }
.request-card:last-child { border-bottom: 0; }
.request-card > div { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.request-card time { color: var(--muted); font-size: 13px; }
.request-card h3 { margin: .7rem 0 .25rem; font-size: 17px; }
.request-card p { margin: 0; color: var(--muted); }
.request-card blockquote { display: grid; margin: .85rem 0 0; padding: .7rem .85rem; border-left: 3px solid var(--blue); color: var(--ink); background: var(--blue-soft); }

@media (max-width: 1050px) {
  .summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 780px) {
  .portal-shell { display: block; }
  .portal-sidebar { position: fixed; left: 0; width: min(300px, 88vw); padding-top: 1.2rem; transform: translateX(-105%); transition: transform .2s ease; box-shadow: var(--shadow); }
  .sidebar-open .portal-sidebar { transform: translateX(0); }
  .sidebar-backdrop { position: fixed; z-index: 15; inset: 0; display: block; border: 0; background: rgba(20,39,44,.38); opacity: 0; pointer-events: none; transition: opacity .2s ease; }
  .sidebar-open .sidebar-backdrop { opacity: 1; pointer-events: auto; }
  .mobile-menu { display: inline-flex; }
  .portal-topbar { min-height: 66px; }
  main { padding: 1.3rem 1rem 2.5rem; }
  .dashboard-grid, .requests-grid { grid-template-columns: 1fr; }
  .profile-grid { grid-template-columns: 1fr; }
  .view-heading { align-items: start; }
  .view-heading .button { flex: 0 0 auto; }
  .plan-card > header { display: grid; }
  .plan-price { justify-items: start; }
}

@media (max-width: 540px) {
  .environment-badge { display: none; }
  .summary-grid { grid-template-columns: 1fr; }
  .summary-card { min-height: 120px; }
  .view-heading { display: grid; }
  .plan-card dl { grid-template-columns: 1fr 1fr; }
  .setting-row { display: grid; }
  .setting-control input { width: 100%; }
  .setting-control { display: grid; grid-template-columns: 1fr auto; }
  th, td { padding: .8rem; }
  .document-list article { grid-template-columns: auto 1fr; }
  .document-list article > span { grid-column: 2; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}

/* Customer workspace controls and document detail. */
#companyPicker { min-width: 0; margin-left: auto; max-width: 380px; }
#companyPicker label { font-size: 12px; color: var(--muted); }
#selectedCompany { width: 100%; min-width: 0; min-height: 44px; padding: .5rem; border: 1px solid var(--line); border-radius: 6px; background: #fff; }
#refreshPortal { margin-left: auto; }
#companyPicker:not([hidden]) + #refreshPortal { margin-left: 0; }
td small, .document-list small { display: block; color: var(--muted); font-size: 13px; }
#contractSettingsList { margin-top: 1.3rem; }
#documentDetailHeading { overflow-wrap: anywhere; }
.summary-card strong, .portal-topbar strong { overflow-wrap: anywhere; }
.summary-card strong { line-height: 1.25; }
.request-card p, .request-card blockquote { white-space: pre-wrap; overflow-wrap: anywhere; }
button:disabled { cursor: wait; opacity: .65; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
@media (max-width: 780px) { .portal-topbar { flex-wrap: wrap; } #companyPicker { flex-basis: 100%; max-width: none; order: 4; } }
@media (max-width: 540px) { #refreshPortal { padding: .4rem .6rem; } }

/* Match the administration document workspace; keep touch layouts readable. */
[data-view="dokumenty"] .customer-documents, [data-view="dokumenty"] .document-detail { margin-bottom: 1.2rem; }
[data-view="dokumenty"] .document-tabs { display: flex; gap: .5rem; flex-wrap: wrap; padding: .8rem 0 1rem; border-bottom: 1px solid var(--line); }
[data-view="dokumenty"] .document-tabs button { border: 1px solid var(--line); border-radius: 6px; background: #fff; padding: .65rem .8rem; cursor: pointer; color: var(--blue-dark); font: inherit; font-size: 14px; }
[data-view="dokumenty"] .document-tabs button[aria-pressed="true"] { background: var(--blue-dark); color: #fff; border-color: var(--blue-dark); }
[data-view="dokumenty"] .document-filters { display: grid; grid-template-columns: minmax(140px, 1fr) minmax(180px, 2fr) minmax(170px, 1fr); gap: 1rem; margin: 1rem 0; }
[data-view="dokumenty"] .document-filters > div { min-width: 0; }
[data-view="dokumenty"] .document-filters label { margin: 0 0 .35rem; font-size: 13px; font-weight: 650; }
[data-view="dokumenty"] .document-filters input, [data-view="dokumenty"] .document-filters select { width: 100%; min-width: 0; padding: .65rem; border-color: var(--line); font: inherit; }
[data-view="dokumenty"] .document-source { color: var(--muted); font-size: 14px; overflow-wrap: anywhere; }
[data-view="dokumenty"] .document-link { padding: 0; border: 0; background: none; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; font: inherit; font-weight: 750; text-align: left; color: var(--blue-dark); overflow-wrap: anywhere; }
[data-view="dokumenty"] .document-description { display: block; margin-top: .4rem; max-width: 320px; min-width: 150px; }
[data-view="dokumenty"] .documents-table { font-size: 13px; }
[data-view="dokumenty"] .documents-table .numeric, [data-view="dokumenty"] .document-detail .numeric { white-space: nowrap; text-align: right; }
[data-view="dokumenty"] .documents-table .overdue { color: #9c3021; font-weight: 700; margin-top: .35rem; }
[data-view="dokumenty"] .document-detail { scroll-margin-top: 1rem; }
[data-view="dokumenty"] .document-detail h2 { margin: .35rem 0; }
[data-view="dokumenty"] .document-detail dt { color: var(--muted); font-size: 13px; }
[data-view="dokumenty"] .document-detail dd { margin: .3rem 0 0; font-weight: 750; overflow-wrap: anywhere; }
[data-view="dokumenty"] #documentDetailDescription { white-space: pre-wrap; overflow-wrap: anywhere; }
[data-view="dokumenty"] #documentDetailTotal { font-weight: 750; }
[data-view="dokumenty"] .inline-button { border: 1px solid var(--line); border-radius: 5px; padding: .4rem .65rem; color: var(--blue-dark); background: #fff; cursor: pointer; white-space: nowrap; font: inherit; }
[data-view="dokumenty"] .inline-button:hover { background: var(--blue-soft); }
[data-view="dokumenty"] .inline-button:disabled { cursor: default; }
[data-view="dokumenty"] .document-pagination { display: flex; align-items: center; flex-wrap: wrap; gap: .75rem; margin-block: .85rem; font-size: 14px; }
[data-view="dokumenty"] .customer-attachments summary { cursor: pointer; color: var(--blue-dark); font-weight: 750; }
@media (min-width: 781px) and (max-width: 1050px) {
  [data-view="dokumenty"] .document-filters { grid-template-columns: 1fr; }
}
@media (max-width: 780px) {
  [data-view="dokumenty"] .document-filters { grid-template-columns: 1fr; }
  [data-view="dokumenty"] .customer-documents > .surface__heading, [data-view="dokumenty"] .document-detail > .surface__heading { align-items: flex-start; gap: .75rem; flex-wrap: wrap; }
  [data-view="dokumenty"] .inline-button, [data-view="dokumenty"] .document-link { min-height: 44px; }
  [data-view="dokumenty"] .documents-table { min-width: 0; width: 100%; }
  [data-view="dokumenty"] .documents-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  [data-view="dokumenty"] #documentRows { display: block; }
  [data-view="dokumenty"] #documentRows tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); padding: .4rem; border-bottom: 1px solid var(--line); }
  [data-view="dokumenty"] #documentRows td { display: block; min-width: 0; border: 0; overflow-wrap: anywhere; }
  [data-view="dokumenty"] #documentRows td:first-child, [data-view="dokumenty"] #documentRows td:last-child { grid-column: 1 / -1; }
  [data-view="dokumenty"] #documentRows td[data-label]::before { display: block; margin-bottom: .3rem; content: attr(data-label); color: var(--muted); font-size: 12px; font-weight: 700; }
  [data-view="dokumenty"] #documentRows .numeric { text-align: left; white-space: normal; }
  [data-view="dokumenty"] .document-description { min-width: 0; }
}

/* Company administration follows the admin customer detail and access preview. */
.account-summary > a { margin-top: .55rem; color: #e5eeeb; font-weight: 700; }
.account-summary > a[aria-current="page"] { text-decoration-thickness: 2px; }
#companySectionTabs { display: flex; gap: .35rem; padding: .35rem; margin-bottom: 1.5rem; border: 1px solid var(--line); border-radius: 10px; background: var(--blue-soft); }
#companySectionTabs button { flex: 0 1 190px; min-width: 0; min-height: 44px; padding: .85rem 1rem; border: 0; border-radius: 7px; background: transparent; color: var(--blue-dark); font: inherit; font-weight: 700; cursor: pointer; }
#companySectionTabs button[aria-selected="true"] { background: var(--blue-dark); color: #fff; box-shadow: 0 2px 5px #162b2f1a; }
[data-view="firma"] .surface, [data-view="ucet"] .surface { margin-bottom: 1.25rem; }
[data-view="firma"] .inline-button, [data-view="ucet"] .inline-button { border: 1px solid var(--line); border-radius: 5px; padding: .4rem .65rem; color: var(--blue-dark); background: #fff; cursor: pointer; font: inherit; }
[data-view="firma"] .inline-button:hover { background: var(--blue-soft); }
[data-view="firma"] .muted, [data-view="ucet"] .muted { color: var(--muted); font-size: 14px; }
.company-filters, [data-view="firma"] .form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.company-filters label, #companyTemporaryAccess > label { display: block; margin-bottom: .35rem; font-size: 13px; font-weight: 650; }
.company-filters input, .company-filters select, #companyTemporaryPassword { width: 100%; min-width: 0; min-height: 44px; padding: .65rem; border: 1px solid var(--line); border-radius: 6px; background: #fff; font: inherit; }
#companyUserFields { min-width: 0; margin: 0; padding: 0; border: 0; }
.company-choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
[data-view="firma"] .company-choice { display: flex; align-items: flex-start; gap: .75rem; margin: .5rem 0; padding: .8rem; border: 1px solid var(--line); border-radius: 7px; background: var(--blue-soft); cursor: pointer; }
[data-view="firma"] .company-choice input { flex: 0 0 20px; width: 20px; min-height: 20px; height: 20px; margin: .2rem 0 0; padding: 0; accent-color: var(--blue-dark); }
[data-view="firma"] .company-choice span { min-width: 0; color: var(--ink); font-size: 15px; overflow-wrap: anywhere; }
.company-choice small { display: block; color: var(--muted); font-size: 13px; font-weight: 400; }
#companyUserEditor { scroll-margin-top: 110px; }
#companyAccessReview { margin-top: 1.3rem; border-top: 1px solid var(--line); }
#companyTemporaryAccess { border-left: 4px solid var(--blue-dark); }
#companyTemporaryPassword { max-width: 460px; font-family: Consolas, monospace; }
#companyHistoryMore { margin-top: 1rem; }
[data-view="ucet"] .surface { max-width: 800px; }
[data-view="ucet"] form { max-width: 540px; }
#companyStatus:empty, #ownAccountStatus:empty { display: none; }
#companyStatus, #ownAccountStatus { margin-bottom: 1rem; }
@media (max-width: 1050px) {
  #companySectionTabs { flex-wrap: wrap; }
  #companySectionTabs button { flex: 1 1 40%; }
  .company-choices { grid-template-columns: 1fr; }
}
@media (max-width: 780px) {
  .company-filters, [data-view="firma"] .form-grid { grid-template-columns: 1fr; }
  [data-view="firma"] .surface__heading { align-items: flex-start; flex-wrap: wrap; }
  [data-view="firma"] .inline-button { min-height: 44px; }
  #companyUsersPanel table:has(#companyUsersRows) thead, #companyBranchesPanel thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  #companyUsersRows, #companyBranchesRows { display: block; }
  #companyUsersRows tr, #companyBranchesRows tr { display: grid; grid-template-columns: 1fr; padding: .5rem 0; border-bottom: 1px solid var(--line); }
  #companyUsersRows td, #companyBranchesRows td { display: block; border: 0; min-width: 0; overflow-wrap: anywhere; }
  #companyUsersRows td[data-label]::before, #companyBranchesRows td[data-label]::before { display: block; margin-bottom: .25rem; content: attr(data-label); color: var(--muted); font-size: 12px; font-weight: 700; }
}
:root .customer-configurator-frame { display: block; width: 100%; min-height: 800px; border: 0; }
#savedServices { display:grid; gap:1.3rem; margin-bottom:1.3rem; }
#savedServices:empty { display:none; }
#savedServices h2, #savedServices td { overflow-wrap:anywhere; }
#savedServices .surface dl { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:1rem; }
#savedServices .surface dt { color:var(--muted); font-size:13px; }
#savedServices .surface dd { margin:.4rem 0 0; font-weight:700; }
#savedServices .plan-card > p { padding:0 1.5rem; }
@media (max-width:700px) {
  #savedServices table, #savedServices tbody, #savedServices tr, #savedServices td { display:block; width:100%; min-width:0; }
  #savedServices thead { display:none; }
  #savedServices td { padding:.45rem 1rem; border:0; }
  #savedServices tr { padding:.6rem 0; border-bottom:1px solid var(--line); }
  #savedServices td:last-child::before { content:'Měsíčně bez DPH: '; color:var(--muted); }
  #savedServices .surface dl { grid-template-columns:1fr; }
}
