/* Responsible Care - styl sladeny s originalem (www.responsiblecare.cz):
   fonty Raleway/Roboto, barva #004164, ikony Font Awesome (samohostovane). */

:root {
  --rc-primary: #004164;
  --rc-primary-hover: #003856;
  --rc-text: #0a0a0a;
  --rc-bg: #fefefe;
  --rc-border: #cacaca;
  --rc-accent-green: #1e6843;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Roboto", Arial, sans-serif;
  font-size: 16px;
  color: var(--rc-text);
  background: var(--rc-bg);
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: "Raleway", "Roboto", sans-serif;
  font-weight: 400;
  color: var(--rc-text);
  line-height: 1.4;
}
h1 { font-size: 2.625rem; margin: 0 0 1rem; }
h2 { font-size: 1.9rem; margin: 1.5rem 0 0.75rem; }
h3 { font-size: 1.4rem; margin: 1rem 0 0.5rem; }

a { color: var(--rc-primary); text-decoration: none; cursor: pointer; }
a:hover, a:focus { color: var(--rc-primary-hover); text-decoration: underline; }

hr { border: 0; border-top: 1px solid var(--rc-border); margin: 1.25rem 0; }

/* ---- Hlavicka ---- */
.rc-topbar {
  background: var(--rc-bg);
}
/* rozmery shodne s originalem: logo vlevo (absolutne), pruh menu odsazen o 280 px, 1px linka pod nim */
.rc-topbar-inner {
  max-width: 75rem;
  margin: 0 auto;
  padding: 0 15px;
  position: relative;
}
.rc-logo { position: absolute; left: 15px; top: 8px; display: block; z-index: 1; }
.rc-logo img { height: 56px; width: auto; display: block; }
.rc-bar {
  margin-left: 280px;
  background: var(--rc-bg);
  border-bottom: 1px solid #8fb9c3;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.rc-nav { display: flex; list-style: none; margin: 0; padding: 0; }
.rc-nav a, .rc-account a {
  display: block;
  padding: 16px 16px 14.96px;
  font-size: 16px;
  line-height: 1;
  color: var(--rc-primary);
}
.rc-nav a:hover, .rc-account a:hover { text-decoration: none; }
.rc-nav li.active a { border-bottom: 2px solid #8fb9c3; padding-bottom: 16.96px; }
.rc-nav .fa, .rc-account .fa { color: var(--rc-primary); }
.rc-account { display: block; }
.rc-account-name { color: #555; }

.rc-progress {
  background: #eef3f7;
  border: 1px solid var(--rc-border);
  border-radius: 4px;
  color: var(--rc-primary);
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
}
.rc-progress[hidden] { display: none; }
.rc-form-busy { opacity: 0.6; pointer-events: none; }
.rc-btn:disabled { opacity: 0.6; cursor: wait; }
.rc-flash { max-width: 75rem; margin: 1rem auto 0; padding: 0 1rem; }
.rc-flash .rc-alert { margin-bottom: 0; }

/* ---- Hlavni obsah ---- */
.rc-main {
  max-width: 75rem;
  margin: 2rem auto 1.5rem;
  padding: 2rem 15px 0;
}

.rc-intro h1 { color: var(--rc-text); }

.rc-quicklinks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.25rem 0;
}
.rc-quicklink {
  background: #fff;
  border: 1px solid var(--rc-border);
  border-radius: 4px;
  padding: 0.6rem 1rem;
  font-weight: 600;
  color: var(--rc-primary);
}
.rc-quicklink:hover { background: var(--rc-primary); color: #fff; text-decoration: none; }

.rc-file-list { list-style: none; padding: 0; margin: 0; }
.rc-file-list li {
  position: relative;
  padding: 0.5rem 0 0.5rem 1.3rem;
}
.rc-file-list li::before {
  content: "";
  position: absolute;
  left: 0.15rem;
  top: 1rem;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--rc-accent-green);
}
.rc-bold { font-weight: 700; }
/* obycejne odrazkove seznamy (uvod, materialy ke stazeni) jako v originale */
.rc-doc-list { list-style: disc; margin: 0 0 16px 20px; padding: 0; }
.rc-doc-list li { margin: 0; }
.rc-main h1.rc-h1-tight { margin-bottom: 8px; }
.rc-intro p { margin: 0 0 16px; }

/* ---- Seznam spolecnosti (jako v originale) ---- */
.rc-company-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 6px;
}
.rc-company-list { margin-top: 2rem; display: flow-root; }
.rc-company-thumb {
  width: 32.3px;
  height: 2.5rem;
  flex: none;
  margin-right: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.rc-company-thumb img { width: 1.5rem; height: 2rem; object-fit: contain; }
.rc-company-item h2 {
  margin: 6px 0 8px;
  font-size: 1.5rem;
}
.rc-company-item h2 a { color: var(--rc-primary); }

/* ---- Ukazky dobre praxe (karty, 2 sloupce) ---- */
.rc-success-grid {
  display: flex;
  flex-wrap: wrap;
  margin: 0;
}
.rc-success-card {
  width: 50%;
  padding: 16px;
  box-sizing: border-box;
}
.rc-success-content {
  position: relative;
  box-sizing: border-box;
  height: 100%;
  border: 1px solid #5b80b2;
  border-radius: 3px;
  padding: 16px;
}
.rc-success-content:hover { background-color: #effaff; }
.rc-success-content h3 { font-size: 31px; line-height: 43.4px; margin: 0 0 8px; }
.rc-success-author { margin: 16px 0 0; line-height: 24px; }
.rc-success-download { position: absolute; right: 16px; bottom: 16px; line-height: 24px; }
.rc-success-download .fa { margin-left: 0; }

@media (max-width: 48rem) {
  .rc-success-card { width: 100%; }
}

/* ---- Profil spolecnosti ---- */
.rc-rc-status { display: flex; gap: 1rem; align-items: flex-start; margin: 0.75rem 0 1.25rem; }
.rc-rc-status img { width: 64px; height: 64px; flex: none; }
.rc-years ul.no-bullet { list-style: none; padding-left: 0; }
ul.rc-years { list-style: none; padding-left: 0; }
ul.rc-years > li { margin-bottom: 0.75rem; }
ul.rc-years > li > ul { list-style: none; padding-left: 1rem; }

/* chybova stranka 404 */
.rc-notfound { display: flex; gap: 24px; align-items: flex-start; padding-top: 16px; }
.rc-notfound-icon { color: #8fb9c3; flex: none; }
.rc-notfound h1 { margin-bottom: 16px; }
.rc-notfound code { background: #f1f1f1; padding: 1px 6px; border-radius: 3px; word-break: break-all; }
.rc-notfound-links .button { margin: 0 10px 0 0; }
@media (max-width: 40rem) { .rc-notfound { flex-direction: column; } }

/* Verejna stranka spolecnosti - rozmery shodne s originalem (Foundation) */
.rc-company-detail h2 { font-size: 35px; line-height: 49px; margin: 0 0 8px; }
.rc-company-detail p { margin: 0 0 16px; }
.rc-company-detail .rc-rc-status { gap: 30px; margin: 0; align-items: flex-start; }
.rc-company-detail .rc-rc-status > img { width: 70px; height: auto; align-self: flex-start; margin: 15px 0 16px; }
.rc-company-detail .rc-rc-status > div { margin-bottom: 15px; flex: 1 1 0; min-width: 0; }
.rc-company-detail .rc-rc-status > div > p { margin: 0 0 16px; }
.rc-company-detail .rc-rc-status ul { margin: 0 0 16px 20px; padding: 0; list-style: disc; }
.rc-company-detail ul.rc-years { margin: 0 0 16px; padding: 0; list-style: none; }
.rc-company-detail ul.rc-years > li { margin: 0; }
.rc-company-detail .h3 { font-family: Raleway, Roboto, sans-serif; font-size: 31px; line-height: 43.4px; margin: 0 0 8px; }
.rc-company-detail ul.rc-years > li > ul { margin: 0 0 16px 36px; padding: 0; list-style: disc; }

/* ---- Matice vykazu (Aktivni spolecnosti) ---- */
.rc-matrix-toolbar {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin: 1rem 0 0.5rem;
}
.rc-matrix-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  background: var(--rc-primary);
  color: #fff;
  border: none;
  border-radius: 3px;
  cursor: pointer;
}
.rc-matrix-btn:hover { background: var(--rc-primary-hover); }

.rc-matrix-wrap {
  overflow: auto;
  max-height: 70vh;
  margin: 0 0 1.5rem;
  border: 1px solid var(--rc-border);
}
table.rc-matrix-table {
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
  white-space: nowrap;
}
table.rc-matrix-table th, table.rc-matrix-table td {
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid var(--rc-border);
  text-align: left;
}
table.rc-matrix-table th {
  background: #f5f5f5;
  font-weight: 700;
  position: sticky;
  top: 0;
  z-index: 2;
}
table.rc-matrix-table .rc-matrix-year { width: 5rem; }
table.rc-matrix-table .rc-matrix-company {
  width: 18rem;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  position: sticky;
  left: 0;
  background: var(--rc-bg);
  box-shadow: 2px 0 4px rgba(0, 0, 0, 0.08);
  z-index: 1;
}
table.rc-matrix-table th.rc-matrix-company {
  background: #f5f5f5;
  z-index: 3;
}
table.rc-matrix-table tbody .rc-matrix-company { font-size: 0.85rem; }
table.rc-matrix-table .rc-matrix-year a { color: var(--rc-primary); }
table.rc-matrix-table .rc-matrix-year a.rc-matrix-unpublished,
table.rc-matrix-table .rc-matrix-year a.rc-matrix-unpublished:hover {
  color: #8fa5b3;
}
.rc-matrix-unpublished .fa { font-size: 0.8rem; }

table.rc-matrix-table tbody tr:hover td {
  background: #eef3f7;
}
table.rc-matrix-table tbody tr:hover td.rc-matrix-company {
  background: #eef3f7;
}

/* ---- Tabulky (spravcovske/administrace) ---- */
table.rc-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  margin: 1rem 0;
}
table.rc-table th, table.rc-table td {
  border: 1px solid var(--rc-border);
  padding: 0.5rem 0.6rem;
  text-align: left;
  vertical-align: top;
}
table.rc-table th { background: #eef3f7; }

.rc-filterbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
  background: #fff;
  border: 1px solid var(--rc-border);
  padding: 0.75rem;
  border-radius: 4px;
}

.rc-form label { display: block; font-weight: 600; margin: 0.6rem 0 0.2rem; }
.rc-form input[type=text], .rc-form input[type=password], .rc-form input[type=number],
.rc-form input[type=date], .rc-form select, .rc-form textarea {
  width: 100%;
  max-width: 480px;
  padding: 0.45rem 0.55rem;
  border: 1px solid var(--rc-border);
  border-radius: 3px;
  font-family: inherit;
  font-size: 1rem;
}
.rc-form textarea { max-width: 100%; }
.rc-btn {
  display: inline-block;
  background: var(--rc-primary);
  color: #fff;
  border: none;
  padding: 0.55rem 1.1rem;
  border-radius: 3px;
  font-size: 1rem;
  cursor: pointer;
}
.rc-btn:hover { background: var(--rc-primary-hover); color: #fff; text-decoration: none; }
.rc-btn.rc-btn-secondary { background: #6b7885; }
.rc-btn.rc-btn-danger { background: #b0202a; }

.rc-badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  font-size: 0.8rem;
  background: #e6f4ea;
  color: var(--rc-accent-green);
}
.rc-badge.rc-badge-off { background: #f4e6e6; color: #a33; }

.rc-alert {
  padding: 0.75rem 1rem;
  border-radius: 4px;
  margin-bottom: 1rem;
}
.rc-alert { position: relative; padding-right: 2.5rem; }
.rc-alert-close {
  position: absolute;
  top: 50%;
  right: 0.75rem;
  transform: translateY(-50%);
  background: none;
  border: 0;
  padding: 0 0.25rem;
  font-size: 1.5rem;
  line-height: 1;
  color: inherit;
  opacity: 0.6;
  cursor: pointer;
}
.rc-alert-close:hover { opacity: 1; }
.rc-profile-table { border-collapse: collapse; margin: 1rem 0; }
.rc-profile-table th { text-align: left; padding: 0.5rem 1rem 0.5rem 0; }
.rc-profile-table td { padding: 0.5rem 1.5rem 0.5rem 0; }
.rc-alert-error { background: #fdecec; border: 1px solid #f2b8b8; color: #8a1f1f; }
.rc-alert-ok { background: #eaf7ec; border: 1px solid #b7e2bd; color: #1e6b2e; }

.rc-tree-group { margin: 0.5rem 0 0.5rem 0; }
.rc-tree-group > .rc-tree-title { font-weight: 700; margin-top: 1rem; }
.rc-indicator-row { display: flex; justify-content: space-between; gap: 1rem; padding: 0.3rem 0; border-bottom: 1px dashed var(--rc-border); }
.rc-indicator-value { font-weight: 600; white-space: nowrap; }

/* ---- Bocni menu administrace (Sprava/Hodnotitel) ---- */
.rc-layout-with-sidebar {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  align-items: flex-start;
}
.rc-sidebar {
  background: var(--rc-primary);
  color: var(--rc-bg);
  padding: 1rem 0.5rem 1rem 1rem;
  flex: 0 0 280px;
  border-radius: 3px;
}
.rc-sidebar h5 {
  color: var(--rc-bg);
  font-size: 1.25rem;
  font-weight: 400;
  margin: 1rem 0 0.5rem;
}
.rc-sidebar h5:first-child { margin-top: 0; }
.rc-sidebar ul { list-style: none; margin: 0; padding: 0; }
.rc-sidebar li { margin: 0; }
.rc-sidebar li a { display: block; padding: 8px 8px 8px 12px; }
.rc-sidebar h5 a { display: inline; padding: 0; }
.rc-sidebar a { color: var(--rc-bg); }
.rc-sidebar a:hover { color: #cfe3f0; text-decoration: underline; }
.rc-content { flex: 1 1 0; min-width: 0; }

/* ---- Paticka (dle originalu: absolutne u spodku stranky, pruh 8px #8fb9c3) ---- */
html { position: relative; min-height: 100%; }
body { margin-bottom: 14rem; }
.rc-footer {
  position: absolute;
  bottom: 0.5rem;
  left: 0;
  width: 100%;
  height: 7rem;
  margin: 0;
  padding-top: 1.65rem;
  font-size: 110%;
  line-height: 1.5;
  color: #060334;
  border-top: solid 0.5rem #8fb9c3;
}
.rc-footer-inner {
  max-width: 75rem;
  margin: 0 auto;
  padding: 0 15px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}
.rc-footer-inner img { max-height: 4rem; max-width: 100%; height: auto; display: block; }


/* ---- Detail vykazu, nahravani priloh (tridy dle originalu) ---- */
table.shrink { width: auto; border-collapse: collapse; margin: 0 0 1rem; }
table.shrink th { text-align: left; font-weight: 700; padding: 0.5rem 0.625rem 0.625rem; }
table.shrink td { padding: 0.5rem 0.625rem 0.625rem; }
table.shrink thead, table.shrink tbody { border: 1px solid #f1f1f1; background-color: #fefefe; }
table.shrink thead { background-color: #f8f8f8; color: #0a0a0a; }
table.shrink thead td, table.shrink thead th { text-align: left; font-weight: 700; padding: 0.5rem 0.625rem 0.625rem; }
table.shrink tbody tr { background-color: #fefefe; border-bottom: 1px solid #f1f1f1; }
table.shrink td.number { text-align: right; }
.rc-assess .disabled { color: #8a8a8a; cursor: not-allowed; }
.rc-assess .fa-info-circle { color: var(--rc-primary); cursor: help; }


.button {
  display: inline-block;
  padding: 0.85em 1em;
  margin: 0 1rem 1rem 0;
  font-family: inherit;
  font-size: 0.9rem;
  line-height: 1;
  border: 1px solid transparent;
  border-radius: 0;
  cursor: pointer;
  text-align: center;
  background: var(--rc-primary);
  color: var(--rc-bg);
}
.button:hover, .button:focus { background: var(--rc-primary-hover); color: var(--rc-bg); text-decoration: none; }
.button.secondary { background: #767676; }
.button.secondary:hover { background: #5e5e5e; }

fieldset.fieldset { border: 1px solid var(--rc-border); padding: 1.25rem; margin: 1rem 0; }
fieldset.fieldset legend { padding: 0 0.1875rem; }
.holder { margin-bottom: 1rem; }
.help-text { margin: 0.25rem 0 0; font-size: 0.8125rem; color: #555; }
.asterisk { color: #b0202a; }

/* ---- Editor vykazu ---- */
.callout { border: 1px solid #cacaca; background: #fff; padding: 1rem; margin: 0 0 1rem; }
.callout.primary { background: #c2e9ff; border-color: rgba(10,10,10,0.25); }
.callout .fa-info-circle { float: left; margin-right: 0.75rem; color: var(--rc-primary); }
.callout > div { margin-left: 2.5rem; }
input.number { width: 7em; max-width: 7em; text-align: right; padding: 2px 8px; border: 1px solid var(--rc-border); border-radius: 0; font-family: inherit; font-size: 1rem; }
input.number[readonly] { background: #f1f1f1; }
input.number.error { border-color: #b0202a; background: #fdecec; }
td.comparison .error { color: #b0202a; font-weight: 700; }
td.comparison .warning { color: #c77700; font-weight: 700; }
.button.success { background: #3adb76; color: #0a0a0a; }
.button.success:hover { background: #22bb5b; color: #0a0a0a; }
.show-for-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

/* ---- Tabulky vykazu a editoru - pravidla prevzata z puvodniho webu ---- */
table.report { width: auto; border-collapse: collapse; margin: 0 0 2rem; }
table.report thead, table.report tbody { border: 1px solid #f1f1f1; background-color: #fefefe; }
table.report thead { background-color: #444; color: #fefefe; }
table.report thead th { padding: 8px 10px 10px; text-align: center; font-weight: 700; }
table.report thead tr:hover { background-color: inherit; color: inherit; }
table.report tbody tr { background-color: #fefefe; border-bottom: 1px solid #f1f1f1; }
table.report tbody th, table.report tbody td { padding: 0.125rem 0.65rem 0.125rem 0.25rem; text-align: left; vertical-align: top; }
table.report tbody th { font-weight: 400; }
table.report tbody tr.group_header { font-variant: small-caps; background-color: #ddd; }
table.report tbody tr.group_header th { font-weight: 700; }
table.report tbody tr.group_header .subdued { font-variant: normal; }
table.report tbody tr.group_header.secondary { background-color: #eee; }
table.report tbody tr.group_header:hover, table.report tbody tr:hover { background-color: #dfd; }
table.report tbody tr.group_header:focus-within, table.report tbody tr:focus-within { background-color: #ffd; }
table.report td.text-right { text-align: right; }
table.report td.text-center, table.report th.text-center { text-align: center; }
.subdued { color: #666; }
div#report .previous { color: #999; font-size: 0.875rem; }
div#report td.comparison, div#report td.measure { font-size: 0.875rem; }
input.number[readonly] { background: #f3f3f3; color: #666; border-color: #cacaca; }

/* ---- Nahravani priloh - vyber / pretazeni souboru ---- */
.rc-upload-card { border: 1px solid var(--rc-border); border-radius: 8px; padding: 1rem 1.25rem; margin: 0 0 1rem; background: #fff; max-width: 46rem; }
.rc-upload-card h3 { margin: 0 0 0.25rem; font-size: 1.25rem; }
.rc-upload-card .help-text { margin: 0 0 0.75rem; }
.rc-upload-current { display: flex; align-items: center; gap: 0.9rem; padding: 0.75rem 1rem; background: #f3f8fb; border: 1px solid #d5e6ee; border-radius: 6px; margin-bottom: 0.75rem; }
.rc-upload-icon { font-size: 1.8rem; color: #b0202a; }
.rc-upload-info { flex: 1 1 auto; min-width: 0; }
.rc-upload-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rc-upload-meta { color: #666; font-size: 0.875rem; }
.rc-upload-current .button { margin: 0; }
.rc-drop { position: relative; border: 2px dashed #8fb9c3; border-radius: 8px; background: #f7fbfd; text-align: center; padding: 1.75rem 1rem; cursor: pointer; transition: background 0.15s, border-color 0.15s; }
.rc-drop[hidden] { display: none; }
.rc-drop:hover, .rc-drop:focus-visible { background: #eef6fa; border-color: var(--rc-primary); outline: none; }
.rc-drop.dragover { background: #dcedf5; border-color: var(--rc-primary); border-style: solid; }
.rc-drop.has-file { border-style: solid; border-color: #1e6843; background: #f1f8f4; }
.rc-drop input[type=file] { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.rc-drop-prompt .fa-cloud-upload-alt { font-size: 2.2rem; color: var(--rc-primary); margin-bottom: 0.4rem; }
.rc-drop-hint { color: #666; font-size: 0.8125rem; margin-top: 0.2rem; }
.rc-drop-file[hidden], .rc-drop-prompt[hidden] { display: none; }
.rc-drop-file { display: inline-flex; align-items: center; gap: 0.6rem; max-width: 100%; }
.rc-drop-file .fa { font-size: 1.4rem; }
.rc-drop-file .fa-file-pdf { color: #b0202a; }
.rc-drop-file .fa-file-excel, .rc-upload-icon.fa-file-excel { color: #1e6843; }
.rc-drop-file .fa-file-word, .rc-upload-icon.fa-file-word { color: #2b579a; }
.rc-drop-filename { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 24rem; }
.rc-drop-filesize { color: #666; font-size: 0.875rem; }
.rc-drop-clear { background: none; border: 0; font-size: 1.5rem; line-height: 1; color: #555; cursor: pointer; padding: 0 0.3rem; }
.rc-drop-clear:hover { color: #b0202a; }
.rc-drop-error { margin-top: 0.6rem; color: #8a1f1f; background: #fdecec; border: 1px solid #f2b8b8; border-radius: 4px; padding: 0.4rem 0.7rem; display: inline-block; }
.rc-drop-error[hidden] { display: none; }
.rc-drop-note { margin: 0.75rem 0 0; font-size: 0.8125rem; color: #555; }
.text-center { text-align: center; }

/* ---- Sprava spolecnosti (seznam, formular) - dle originalu ---- */
.rc-admin-page h2 { font-size: 35px; margin: 0 0 8px; line-height: 1.4; }
.text-right { text-align: right; }
table.shrink.hover tbody tr:hover { background-color: #f9f9f9; }
table.shrink.hover tbody td, table.shrink.hover tbody th { vertical-align: middle; }
a.action { padding: 0 6px; }
a.action .fa { margin-right: 2px; }
.fa.green { color: #3adb76; }
.fa.red { color: #dc3b53; }
ul.no-bullet { list-style: none; margin: 0 0 1rem; padding: 0; }

.crispy-form .grid-x { display: flex; flex-flow: row wrap; margin: 0 -15px; }
.crispy-form fieldset.fieldset { flex: 0 0 auto; width: calc(50% - 30px); margin: 18px 15px; padding: 20px; border: 1px solid #cacaca; min-width: 0; }
@media (max-width: 63.99em) { .crispy-form fieldset.fieldset { width: calc(100% - 30px); } }
.crispy-form fieldset.fieldset legend { padding: 0 3px; margin-left: -3px; font-size: 16px; line-height: 24px; }
.crispy-form .holder { margin: 0; }
.crispy-form label { display: block; font-size: 14px; line-height: 1.8; color: #0a0a0a; margin: 0; }
.crispy-form .holder.checkbox label { display: inline-block; margin: 0 16px 0 8px; }
.crispy-form input[type=text], .crispy-form input[type=url], .crispy-form input[type=number], .crispy-form input[type=email],
.crispy-form select, .crispy-form textarea {
  display: block; width: 100%; height: 39px; margin: 0 0 16px; padding: 8px;
  font-family: inherit; font-size: 16px; line-height: 24px; color: #0a0a0a;
  background-color: #fefefe; border: 1px solid #cacaca; border-radius: 5px;
  box-shadow: inset 0 1px 2px rgba(10,10,10,.1);
}
.crispy-form textarea { height: auto; }
.crispy-form select {
  border-radius: 0; box-shadow: none; padding-right: 24px; appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' version='1.1' width='32' height='24' viewBox='0 0 32 24'><polygon points='0,0 32,0 16,24' style='fill: rgb%28138, 138, 138%29'></polygon></svg>");
  background-size: 9px 6px; background-position: right -16px center; background-origin: content-box; background-repeat: no-repeat;
}
.crispy-form input:focus, .crispy-form select:focus, .crispy-form textarea:focus {
  outline: none; border-color: #8a8a8a; background-color: #fefefe; box-shadow: 0 0 5px #cacaca;
}
.crispy-form input[type=checkbox] { display: inline-block; width: 13px; height: 13px; margin: 0 0 16px; box-shadow: none; }
.crispy-form .help-text { margin: -8px 0 16px; font-size: 13px; font-style: italic; line-height: 1.6; color: #0a0a0a; }
.crispy-form .asterisk { color: inherit; }
.crispy-form #div_id_awards ul { list-style: none; margin: 0 0 16px; padding: 0; }
.crispy-form #div_id_awards li label { display: block; margin: 0; }
.crispy-form #div_id_awards li input[type=checkbox] { margin: 0 8px 0 0; }
.crispy-form .form-error { display: block; margin-top: -12px; margin-bottom: 16px; font-size: 12px; font-weight: 700; color: #dc3b53; }
.crispy-form .holder.has-error input, .crispy-form .holder.has-error select { border-color: #dc3b53; background-color: #f9ecea; }
.crispy-form .button-holder { margin: 0; }
.crispy-form .button { margin: 0 0 16px; }
.crispy-form .button.secondary { margin-left: 16px; }
#company_delete_form button { cursor: pointer; }
/* svisle (zdola nahoru) psane popisky sloupcu, aby zbylo misto pro akce */
table.shrink thead td.rc-vhead { vertical-align: bottom; padding-left: 4px; padding-right: 4px; }
td.rc-vhead span { display: block; writing-mode: vertical-rl; transform: rotate(180deg); white-space: nowrap; margin: 0 auto; }
table.shrink.hover td a.action { white-space: nowrap; }
table.shrink.hover td a.action .fa { margin-right: 2px; }
table.shrink.hover td:last-child { white-space: nowrap; }

/* ---- Sprava rocniku (formulare bez crispy obalu) ---- */
.rc-year-form label { display: block; font-size: 14px; line-height: 1.8; color: #0a0a0a; margin: 0; }
.rc-year-form input[type=text], .rc-year-form input[type=number] {
  display: block; width: 100%; height: 39px; margin: 0 0 16px; padding: 8px;
  font-family: inherit; font-size: 16px; line-height: 24px; color: #0a0a0a;
  background-color: #fefefe; border: 1px solid #cacaca; border-radius: 5px;
  box-shadow: inset 0 1px 2px rgba(10,10,10,.1);
}
.rc-year-form input:focus { outline: none; border-color: #8a8a8a; box-shadow: 0 0 5px #cacaca; }
.rc-year-form .form-error { display: block; margin-top: -12px; margin-bottom: 16px; font-size: 12px; font-weight: 700; color: #dc3b53; }
.rc-year-form .button { margin: 0 0 16px; }
.rc-year-form .button.secondary { margin-left: 4px; }
.callout.warning { background: #fff3d9; border-color: rgba(10,10,10,.25); }
.callout.warning .fa-pull-left { float: left; margin-right: 0.3em; }
#pwd_reset_link {
  display: block; width: 100%; height: 39px; margin: 0 0 16px; padding: 8px;
  font-family: inherit; font-size: 16px; line-height: 24px; color: #0a0a0a;
  background-color: #fefefe; border: 1px solid #cacaca; border-radius: 5px;
  box-shadow: inset 0 1px 2px rgba(10,10,10,.1);
}

/* ---- Prirazeni indikatoru k typu spolecnosti ---- */
table#indicators { width: 100%; border-collapse: collapse; margin: 0 0 16px; }
table#indicators thead, table#indicators tbody { border: 1px solid #f1f1f1; background-color: #fefefe; }
table#indicators thead { background-color: #f8f8f8; }
table#indicators thead tr, table#indicators tr.header { background-color: #444; color: #fff; }
table#indicators th, table#indicators td { padding: 8px 10px 10px; text-align: left; vertical-align: middle; }
table#indicators thead td, table#indicators th { font-weight: 700; }
table#indicators tbody td { font-weight: 400; }
table#indicators tbody tr { background-color: #fefefe; border-bottom: 1px solid #f1f1f1; }
table#indicators tbody tr.header { background-color: #444; }
table#indicators tbody tr.computed { background-color: #f9f9f9; color: #222; }
table#indicators tbody tr.computed th { font-style: italic; }
table#indicators tbody tr.inactive th { text-decoration: line-through; }
table#indicators input[type=checkbox] { margin: 0 0 16px; }

/* sloupce typu spolecnosti: stejne siroke, nazvy v zahlavi pod uhlem 45 stupnu */
table#indicators { table-layout: fixed; }
table#indicators thead th:first-child, table#indicators tr.header th:first-child { width: 34%; }
table#indicators thead td:nth-child(2), table#indicators tr.header th:nth-child(2) { width: 56px; }
table#indicators tbody td:nth-child(2) { width: 56px; }
table#indicators th.rc-rot { position: relative; height: 110px; padding: 0; vertical-align: bottom; overflow: visible; }
table#indicators th.rc-rot > div {
  position: absolute; left: calc(50% - 8px); bottom: 10px;
  transform-origin: 0 100%; transform: rotate(-45deg);
  white-space: nowrap; line-height: 1.2; font-weight: 700;
}
table#indicators td.chk { text-align: center; }

/* formular s jednim fieldsetem pres celou sirku (Sprava souboru) */
.crispy-form.wide-fieldset fieldset.fieldset { width: auto; margin: 18px 0; }
.crispy-form input[type=file] { display: block; margin: 0 0 16px; }

/* zvyrazneni aktualni polozky postranniho menu */
.rc-sidebar li.active { margin: 0 -0.5rem 0 -1rem; background: rgba(255,255,255,0.18); border-left: 4px solid #8fb9c3; }
.rc-sidebar li.active a { font-weight: 700; padding-left: 24px; }

/* ---- Statistiky ---- */
#stats_table > table { width: 100%; border-collapse: collapse; margin: 0 0 16px; }
#stats_table > table th, #stats_table > table td { padding: 8px 10px 10px; text-align: left; vertical-align: middle; }
#stats_table > table th { font-weight: 700; }
#stats_table > table th.sublevel { padding-left: 16px; font-size: 14px; font-weight: 400; }
#stats_table select {
  display: inline-block; margin: 0; padding: 8px 24px 8px 8px; width: 100%; height: 39px;
  font-family: inherit; font-size: 16px; line-height: 24px; color: #0a0a0a;
  background-color: #fefefe; border: 1px solid #cacaca; border-radius: 0; appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' version='1.1' width='32' height='24' viewBox='0 0 32 24'><polygon points='0,0 32,0 16,24' style='fill: rgb%28138, 138, 138%29'></polygon></svg>");
  background-size: 9px 6px; background-position: right -16px center; background-origin: content-box; background-repeat: no-repeat;
}
.download_link .button { margin: 0 0 16px; }
table.stats_results { width: auto; border-collapse: collapse; margin: 0 0 16px; font-size: 14px; line-height: 1.5; }
table.stats_results thead { border: 1px solid #f1f1f1; background-color: #f8f8f8; }
table.stats_results tbody { border: 1px solid #f1f1f1; background-color: #fefefe; }
table.stats_results thead th { padding: 8px 10px 10px; text-align: center; font-weight: 700; background-color: #333; color: #fefefe; }
table.stats_results tbody tr { border-bottom: 1px solid #f1f1f1; background-color: #fefefe; }
table.stats_results tbody th { padding: 8px 10px 10px; text-align: left; font-weight: 700; background-color: rgba(220,220,220,0.6); }
table.stats_results tbody td { padding: 8px 10px 10px; }
table.stats_results td.number { text-align: right; background-color: rgba(220,220,220,0.3); }
table.stats_results tr.sum { background-color: rgba(0,100,255,0.1); font-style: italic; }
table.stats_results td.sum { background-color: rgba(0,100,255,0.1); font-style: italic; }
/* siroke tabulky: posouvani do stran, prvni sloupec zustava videt */
.rc-scroll-x { overflow-x: auto; max-width: 100%; }
.rc-scroll-x table.stats_results thead th:first-child { position: sticky; left: 0; z-index: 2; }
.rc-scroll-x table.stats_results tbody th { position: sticky; left: 0; z-index: 1; background-color: #eaeaea; }
.rc-matrix-btn:disabled, .rc-matrix-btn:disabled:hover { background: #c4cbd0; color: #f4f6f7; cursor: default; }
/* seznamy spravy: akce se nelamou, popisky sloupcu svisle */
table.shrink td:last-child a { white-space: nowrap; }
table.shrink td:last-child { white-space: nowrap; }
/* sloupec akci: odkazy se nelamou a mezi nimi je presne 10 px */
td.actions { white-space: nowrap; font-size: 0; }
td.actions a, td.actions a.action { display: inline-block; font-size: 16px; padding: 0; }
td.actions a + a { margin-left: 10px; }
td.nowrap { white-space: nowrap; }
.pw-reset-user { margin: 0 0 4px; }

/* profil uzivatele / zastupce spolecnosti */
.mb-1 { margin-bottom: 1rem; }
table.my_reports tbody tr { background-color: #fefefe; border-bottom: 1px solid #f1f1f1; }
table.my_reports a.open_year { font-weight: 700; }
table.shrink + form { margin-top: 0; }

/* rezim po prihlaseni (mimo verejne stranky): obsah pres celou sirku do Full HD, svisly posuvnik vzdy */
html.rc-wide { overflow-y: scroll; }
html.rc-wide .rc-main {
  max-width: none;
  margin: 2rem 0 1.5rem;
  padding-top: 0;
  /* levy okraj obsahu = levy okraj loga; menu je vlevo od obsahu, a teprve kdyz se tam nevejde, obsah se posune doprava */
  padding-left: max(1rem, calc(max(0px, (100% - 75rem) / 2) + 1rem - 304px));
  /* pravy okraj obsahu = pravy okraj napisu "Muj ucet"; siroky obsah se rozsiri doprava (viz footer.asp, max. 1920 px) */
  padding-right: max(1rem, calc(max(0px, (100% - 75rem) / 2) + 1rem));
}
/* vyhrazeny sloupec menu, kdyz se menu nezobrazuje (obsah zacina stale ve stejnem miste) */
.rc-sidebar-spacer { flex: 0 0 280px; min-height: 1px; }
@media (max-width: 47.99rem) { .rc-sidebar-spacer { display: none; } }
.rc-flash.rc-flash-inline { max-width: none; margin: 0 0 1rem; padding: 0; }
.ml-1 { margin-left: 1rem; }

/* prihlaseni (dle originalu) */
.text-center { text-align: center; }
.login_div { margin: 0 auto; width: fit-content; max-width: 100%; }
table.login_table { margin: 0 auto 1rem; border-collapse: collapse; }
table.login_table th { text-align: left; font-weight: 400; padding: 0.5rem 1rem 0.5rem 0; white-space: nowrap; }
table.login_table td { padding: 0.5rem 0; }
table.login_table input[type=text], table.login_table input[type=password] {
  width: 22rem; max-width: 100%; height: 39px; margin: 0; padding: 8px; font-family: inherit; font-size: 16px;
  background: #fefefe; border: 1px solid #cacaca; border-radius: 5px; box-shadow: inset 0 1px 2px rgba(10,10,10,.1);
}
table.login_table button.button { margin: 0; }
table.login_table a.small { font-size: 0.875rem; }

/* ---- Cookie lista ---- */
.rc-cookie-bar[hidden] { display: none; }
.rc-cookie-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 1000;
  background: #fefefe; border-top: 4px solid #8fb9c3;
  box-shadow: 0 -2px 12px rgba(10,10,10,.18);
  max-height: 80vh; overflow-y: auto;
}
.rc-cookie-inner {
  max-width: 75rem; margin: 0 auto; padding: 16px 15px;
  display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap;
}
.rc-cookie-text { flex: 1 1 32rem; font-size: 0.95rem; line-height: 1.5; }
.rc-cookie-text p { margin: 4px 0 8px; }
.rc-cookie-text details { font-size: 0.875rem; }
.rc-cookie-text summary { cursor: pointer; color: var(--rc-primary); }
.rc-cookie-table { border-collapse: collapse; margin: 8px 0 0; font-size: 0.8125rem; }
.rc-cookie-table th, .rc-cookie-table td { text-align: left; padding: 4px 12px 4px 0; vertical-align: top; }
.rc-cookie-buttons { display: flex; gap: 10px; flex: 0 0 auto; flex-wrap: wrap; }
.rc-cookie-buttons .button { margin: 0; white-space: nowrap; }
.rc-cookie-link { color: inherit; text-decoration: underline; }

/* ---- Prepinac bocniho menu (jen na mobilu) ---- */
.rc-sidebar-toggle { display: none; }

/* ============================================================
   Responzivni zobrazeni (mobily a uzke tablety)
   ============================================================ */
@media (max-width: 47.99rem) {
  h1 { font-size: 2rem; line-height: 1.25; }
  h2 { font-size: 1.6rem; line-height: 1.3; }
  h3 { font-size: 1.3rem; }

  /* zahlavi: logo nahore, pod nim jeden radek ikon menu + ucet vpravo */
  .rc-topbar-inner { padding: 0 10px; }
  .rc-logo { position: static; display: block; padding: 8px 5px 2px; }
  .rc-logo img { height: 44px; }
  .rc-bar { margin-left: 0; flex-wrap: nowrap; }
  .rc-nav a, .rc-account a { padding: 14px 12px 12.96px; white-space: nowrap; }
  .rc-nav li.active a { padding-bottom: 14.96px; }
  .rc-nav span:not(.fa) { display: none; }
  .rc-nav .fa { font-size: 1.15rem; }

  /* obsah */
  .rc-main { margin-top: 1rem; padding: 1.25rem 15px 0; }
  html.rc-wide .rc-main { margin-top: 1rem; padding: 0 15px; }
  .rc-flash { padding: 0 15px; }
  .rc-layout-with-sidebar { gap: 1rem; }
  .rc-sidebar { flex: 1 1 100%; box-sizing: border-box; }
  .rc-content { flex: 1 1 100%; }

  /* bocni menu: sbalene, rozbaleni tlacitkem */
  .rc-sidebar-toggle {
    display: block; width: 100%; margin: -1rem -0.5rem -1rem -1rem; width: calc(100% + 1.5rem);
    padding: 12px 16px; background: transparent; border: 0; color: var(--rc-bg);
    font: inherit; font-size: 1.1rem; text-align: left; cursor: pointer;
  }
  .rc-sidebar-toggle::after { content: "\25BE"; float: right; }
  .rc-sidebar.open .rc-sidebar-toggle::after { content: "\25B4"; }
  .rc-sidebar-menu { display: none; padding-top: 1.5rem; }
  .rc-sidebar.open .rc-sidebar-menu { display: block; }

  /* siroke tabulky se posouvaji do stran */
  table.rc-table, table.shrink:not(.stats_results), table#indicators, table.report {
    display: block; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch;
  }

  /* verejne stranky */
  .rc-company-item h2 { font-size: 1.25rem; }
  .rc-company-detail h2 { font-size: 1.75rem; line-height: 1.3; }
  .rc-company-detail .rc-rc-status { gap: 16px; }
  .rc-company-detail .rc-rc-status > img { width: 56px; }
  .rc-company-detail .h3 { font-size: 1.5rem; line-height: 1.3; }
  .rc-company-detail ul.rc-years > li > ul { margin-left: 24px; }
  .rc-success-card { padding: 6px 0; }
  .rc-success-content h3 { font-size: 1.5rem; line-height: 1.3; }
  .rc-success-download { position: static; margin-top: 8px; text-align: right; }
  .rc-notfound { flex-direction: column; gap: 8px; }
  .rc-notfound-links .button { margin-bottom: 8px; }

  /* prihlaseni */
  table.login_table, table.login_table tbody, table.login_table tr,
  table.login_table th, table.login_table td { display: block; }
  table.login_table th { padding: 0.5rem 0 0; white-space: normal; }
  table.login_table input[type=text], table.login_table input[type=password] { width: 100%; box-sizing: border-box; }

  /* formulare */
  .crispy-form fieldset.fieldset { width: calc(100% - 30px); padding: 12px; margin: 12px 15px; }
  .crispy-form .button.secondary { margin-left: 0; margin-right: 0; }

  /* cookie lista */
  .rc-cookie-inner { padding: 10px 12px; gap: 10px; }
  .rc-cookie-text { flex-basis: 100%; font-size: 0.85rem; }
  .rc-cookie-buttons { width: 100%; }
  .rc-cookie-buttons .button { flex: 1 1 0; padding: 12px 8px; white-space: normal; }

  /* paticka */
  .rc-footer-inner { gap: 12px; }
  .rc-footer-inner img { max-height: 3rem; }
}

/* matice vykazu na mobilu: uzsi sloupec se spolecnosti, aby bylo videt vice let */
@media (max-width: 47.99rem) {
  table.rc-matrix-table .rc-matrix-company { width: 8.5rem; }
  table.rc-matrix-table tbody .rc-matrix-company { font-size: 0.75rem; }
  table.rc-matrix-table th, table.rc-matrix-table td { padding: 0.5rem 0.5rem; }
  table.rc-matrix-table .rc-matrix-year { width: 4rem; }
}

/* stredni sirka (tablet): v menu kratke popisky bez ikon (jako v originale) a tabulky se posouvaji do stran */
.rc-nav-short { display: none; }
@media (min-width: 48rem) and (max-width: 63.99rem) {
  .rc-nav .fa { display: none; }
  .rc-nav-long { display: none; }
  .rc-nav-short { display: inline; }
  table.rc-table, table.shrink:not(.stats_results), table#indicators, table.report {
    display: block; max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch;
  }
}
@media (min-width: 48rem) and (max-width: 63.99rem) {
  .rc-bar { margin-left: 222px; }
  .rc-nav a, .rc-account a { padding-left: 12px; padding-right: 12px; white-space: nowrap; }
}
@media (min-width: 48rem) and (max-width: 63.99rem) {
  .rc-nav a, .rc-account a { padding-left: 8px; padding-right: 8px; }
  .rc-bar { margin-left: 215px; }
}
@media (min-width: 64rem) and (max-width: 71.99rem) {
  .rc-nav .fa { display: none; }
  .rc-nav-long { display: none; }
  .rc-nav-short { display: inline; }
  .rc-nav a, .rc-account a { white-space: nowrap; }
}

/* ---- Pristupnost: odkaz "Preskocit na obsah" a viditelny fokus ---- */
.rc-skip {
  position: absolute; left: -9999px; top: 8px; z-index: 2000;
  background: var(--rc-primary); color: var(--rc-bg); padding: 8px 14px; border-radius: 3px;
}
.rc-skip:focus { left: 8px; color: var(--rc-bg); text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 2px solid #5b80b2; outline-offset: 2px;
}
