:root {
  --bg: #eef2f6;
  --panel: #ffffff;
  --panel-soft: #f7f9fc;
  --line: #d9e1ea;
  --line-strong: #a8b4c2;
  --text: #182230;
  --muted: #667085;
  --graphite: #2f3642;
  --blue: #102a4c;
  --teal: #1d5fae;
  --teal-soft: #eaf2ff;
  --green: #2f855a;
  --green-soft: #e7f6ee;
  --amber: #b7791f;
  --amber-soft: #fff4dc;
  --red: #b42318;
  --red-soft: #fff1f0;
  --shadow: 0 18px 45px rgba(16, 42, 76, 0.09);
  --shadow-soft: 0 8px 24px rgba(24, 34, 48, 0.06);
  --radius: 8px;
  --font: "Segoe UI", Arial, sans-serif;
  --serif: "Times New Roman", Times, serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 1080px;
  min-height: 100vh;
  background:
    linear-gradient(180deg, #f7f9fc 0%, var(--bg) 340px),
    var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  letter-spacing: 0;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.app-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 12px 22px;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 1px 0 rgba(16, 42, 76, 0.03);
  backdrop-filter: blur(12px);
}

.brand {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  width: auto;
  min-width: 190px;
  padding: 6px 8px;
  border: 0;
  border-radius: var(--radius);
  background: transparent;
  color: var(--blue);
  text-align: left;
}

.brand:hover {
  background: #f1f5f9;
}

.brand img {
  width: 38px;
  height: 38px;
  object-fit: contain;
}

.brand strong {
  display: block;
  font-size: 15px;
  line-height: 1.1;
}

.brand small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
}

.nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
}

.nav-link {
  width: auto;
  min-height: 36px;
  padding: 8px 13px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: var(--graphite);
  text-align: center;
  white-space: nowrap;
  font-weight: 700;
}

.nav-link:hover {
  background: #f1f5f9;
}

.nav-link.active {
  background: var(--teal-soft);
  border-color: #bad4f7;
  color: var(--blue);
  font-weight: 700;
  box-shadow: inset 0 -2px 0 var(--teal);
}

.profile-button {
  margin-left: auto;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--panel-soft);
  color: var(--text);
}

.profile-button:hover,
.profile-button.active {
  border-color: var(--line-strong);
  background: #ffffff;
}

.profile-button.active {
  border-color: #bad4f7;
  background: var(--teal-soft);
}

.profile-avatar {
  display: block;
  position: relative;
  width: 32px;
  height: 32px;
  overflow: hidden;
  border-radius: 50%;
  background: #a8abad;
}

.profile-avatar img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.profile-avatar span {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
}

.profile-avatar.has-photo::before,
.profile-avatar.has-photo::after,
.profile-avatar.has-initials::before,
.profile-avatar.has-initials::after {
  display: none;
}

.profile-avatar::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 9px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #ffffff;
  transform: translateX(-50%);
}

.profile-avatar::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -5px;
  width: 27px;
  height: 17px;
  border-radius: 16px 16px 4px 4px;
  background: #ffffff;
  transform: translateX(-50%);
}

.workspace {
  min-width: 0;
  padding: 22px 28px 42px;
}

.file-mode-screen {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: 24px;
  background: var(--bg);
}

.file-mode-card {
  width: min(620px, 100%);
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}

.file-mode-card img {
  width: 56px;
  height: 56px;
  object-fit: contain;
}

.file-mode-card h1 {
  margin: 8px 0 10px;
  color: var(--blue);
  font-size: 28px;
}

.file-mode-card p {
  max-width: 54ch;
  color: var(--muted);
  line-height: 1.55;
}

.file-mode-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0 12px;
}

.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
}

.topbar.topbar-compact {
  align-items: center;
  margin-bottom: 14px;
}

.topbar.topbar-empty {
  display: none;
  margin-bottom: 0;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--text);
  line-height: 1.2;
}

h1 {
  font-size: 28px;
  font-weight: 760;
}

h2 {
  font-size: 20px;
  font-weight: 750;
}

h3 {
  font-size: 16px;
  font-weight: 740;
}

.top-actions,
.action-row,
.inline-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.top-actions {
  justify-content: flex-end;
}

.list-page.has-trash-corner {
  position: relative;
  padding-bottom: 52px;
}

.list-trash-corner {
  position: absolute;
  right: 0;
  bottom: 0;
  display: flex;
  justify-content: flex-end;
  margin-top: 0;
}

.list-trash-corner .trash-icon-btn {
  box-shadow: 0 1px 1px rgba(24, 34, 48, 0.04);
}

.list-trash-corner .trash-count-badge {
  top: -6px;
  right: -6px;
}

.view {
  min-width: 0;
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.panel.pad {
  padding: 20px;
}

.panel-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
}

.panel-body {
  padding: 18px;
}

.muted {
  color: var(--muted);
}

.small {
  font-size: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 36px;
  padding: 8px 13px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--text);
  font-weight: 650;
  text-decoration: none;
  box-shadow: 0 1px 1px rgba(24, 34, 48, 0.04);
  transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.btn:hover {
  border-color: var(--blue);
  box-shadow: var(--shadow-soft);
  transform: translateY(-1px);
}

.btn:disabled,
.btn:disabled:hover {
  border-color: var(--line);
  background: #f5f7fa;
  color: #98a2b3;
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}

.btn.primary {
  border-color: var(--blue);
  background: var(--blue);
  color: #ffffff;
}

.btn.accent {
  border-color: var(--teal);
  background: var(--teal);
  color: #ffffff;
}

.btn.ghost {
  border-color: transparent;
  background: transparent;
}

.btn.danger {
  border-color: #f0b8b2;
  background: var(--red-soft);
  color: var(--red);
}

.btn.small-btn {
  min-height: 30px;
  padding: 5px 9px;
  font-size: 12px;
}

.grid {
  display: grid;
  gap: 16px;
}

.dashboard-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.two-col {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.three-col {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.metric {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow-soft);
}

.metric span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.metric strong {
  display: block;
  margin-top: 10px;
  color: var(--blue);
  font-size: 32px;
  line-height: 1;
}

.table-wrap {
  width: 100%;
  overflow-x: auto;
}

.list-mode-note {
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 13px;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 10px 11px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  text-align: left;
}

th {
  background: #f1f5f9;
  color: var(--blue);
  border-bottom: 1px solid #cbd5e1;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.access-names {
  min-width: 190px;
  color: var(--text);
}

.access-names span {
  display: block;
  line-height: 1.35;
  white-space: nowrap;
}

.access-names span + span {
  margin-top: 3px;
}

tr:last-child td {
  border-bottom: 0;
}

.status-pill,
.completion-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 750;
  white-space: nowrap;
}

.status-pill.work {
  background: var(--amber-soft);
  color: var(--amber);
}

.status-pill.done {
  background: var(--green-soft);
  color: var(--green);
}

.status-pill.pause {
  background: #edf2f7;
  color: #475467;
}

.completion-pill {
  background: #edf2f7;
  color: #475467;
}

.completion-pill.complete {
  background: var(--green-soft);
  color: var(--green);
}

.searchbar {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 220px 180px;
  gap: 10px;
  margin-bottom: 14px;
}

.field {
  display: grid;
  gap: 6px;
}

.field label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 20px;
  color: #344054;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.field .hint {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.checkbox-field {
  align-content: start;
}

.plain-check {
  justify-content: flex-start !important;
  min-height: 32px;
  padding: 7px 9px;
  border: 1px solid #101828;
  border-radius: 4px;
  background: #fff;
  text-transform: none !important;
}

.plain-check:focus-within {
  border-color: var(--teal);
  box-shadow: 0 0 0 1px var(--teal);
}

.plain-check input {
  width: 18px;
  height: 18px;
  margin-left: 6px;
}

.seal-checkbox-field {
  align-content: start;
}

.compact-check {
  min-height: 30px;
  justify-content: flex-start !important;
  gap: 8px;
  padding: 4px 8px;
  font-size: 13px !important;
}

.compact-check input {
  flex: 0 0 auto;
  width: 15px;
  height: 15px;
  margin: 0;
}

.calculation-toggle-field {
  gap: 2px;
}

.calculation-toggle {
  display: inline-flex !important;
  align-items: center;
  justify-content: flex-start !important;
  width: fit-content;
  min-height: 24px !important;
  gap: 8px;
  color: #344054 !important;
  font-size: 13px !important;
  font-weight: 650 !important;
  line-height: 1.25 !important;
  text-transform: none !important;
}

.calculation-toggle input {
  flex: 0 0 auto;
  width: 15px;
  height: 15px;
  margin: 0;
  accent-color: var(--blue);
}

.seal-checkbox-field .hint {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.report-fill-sheet .seal-checkbox-field {
  align-content: start;
}

.report-fill-title .title-status-field,
.report-fill-title .seal-checkbox-field {
  align-content: start;
  gap: 5px;
}

.report-fill-title .title-status-field select,
.report-fill-title .seal-checkbox-field .compact-check {
  height: 38px;
  min-height: 38px;
}

.report-fill-sheet .seal-checkbox-field .compact-check {
  display: flex;
  align-items: center;
  justify-content: flex-start !important;
  width: 100%;
  min-height: 30px;
  padding: 3px 8px;
  border: 1px solid #000000;
  border-radius: 0;
  color: #000000;
  font-family: var(--serif);
  font-size: 12pt !important;
  font-weight: 700;
  line-height: 1.15;
  box-shadow: none;
}

.report-fill-sheet .seal-checkbox-field .compact-check:focus-within {
  border-color: var(--teal);
  box-shadow: inset 0 0 0 1px rgba(29, 95, 174, 0.42);
}

.report-fill-sheet .seal-checkbox-field .compact-check input {
  width: 14px;
  height: 14px;
  margin: 0 8px 0 0;
}

.report-fill-sheet .seal-checkbox-field .compact-check span {
  display: inline-block;
  line-height: 1.15;
}

.report-fill-sheet .seal-checkbox-field .hint {
  margin-top: 0;
  font-family: var(--serif);
  font-size: 9pt;
  line-height: 1.15;
}

.report-fill-sheet .calculation-toggle-field {
  gap: 0;
}

.report-fill-sheet .calculation-toggle-field .calculation-toggle {
  display: inline-flex !important;
  width: fit-content;
  min-height: 18px !important;
  gap: 6px;
  color: #475467 !important;
  font-family: var(--serif);
  font-size: 10.5pt !important;
  font-weight: 400 !important;
  line-height: 1.15 !important;
}

.report-fill-sheet .calculation-toggle-field .calculation-toggle input {
  width: 12px;
  height: 12px;
  margin: 0;
}

.report-fill-sheet .title-status-field select {
  margin-top: 0;
}

.form-section {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.form-section h3 {
  margin: 0;
  color: var(--blue);
  font-size: 15px;
  line-height: 1.25;
  text-transform: uppercase;
}

.check-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.check-card {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  min-height: 44px;
  padding: 10px 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--text);
  font-weight: 700;
  line-height: 1.35;
}

.check-card input {
  width: 16px;
  min-height: 16px;
  margin-top: 2px;
  accent-color: var(--teal);
}

.reference-table-block {
  display: grid;
  gap: 6px;
  margin-top: 4px;
}

.reference-table-title,
.table-caption {
  margin: 0 0 8px;
  color: #344054;
  font-size: 13px;
  font-weight: 750;
}

.report-static-text {
  margin: 8px 0 10px;
  color: #000000;
  font-family: var(--serif);
  font-size: 14pt;
  line-height: 1.15;
  text-align: justify;
  text-indent: 1.25cm;
}

.reference-table {
  min-width: 760px;
}

.reference-table th,
.reference-table td {
  font-size: 14px;
  line-height: 1.35;
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.checkbox-grid label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--text);
  font-weight: 700;
  line-height: 1.35;
}

.checkbox-grid input {
  width: 16px;
  min-height: 16px;
  margin-top: 2px;
  accent-color: var(--teal);
}

.normative-report-preview {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.normative-report-preview h3 {
  margin: 0 0 10px;
}

.normative-report-preview ol {
  margin: 0;
  padding-left: 24px;
}

.normative-report-preview li + li {
  margin-top: 6px;
}

.technical-state-note {
  display: grid;
  gap: 4px;
  margin-top: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfdff;
}

.technical-state-note p {
  margin: 0;
  line-height: 1.45;
}

.defect-editor {
  margin-top: 0;
}

.defect-group {
  gap: 12px;
}

.defect-header-wrap {
  margin-top: 14px;
}

.defect-group-list {
  margin-top: 0;
}

.defect-group .defect-table thead {
  display: none;
}

.defect-group .table-wrap {
  overflow-x: visible;
}

.defect-table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
}

.defect-table th,
.defect-table td {
  padding: 8px;
  font-size: 12px;
  line-height: 1.28;
}

.defect-table th {
  background: #f3fafb;
  color: #123054;
  text-transform: none;
}

.defect-table th:nth-child(1),
.defect-table td:nth-child(1) {
  width: 52px;
  text-align: center;
}

.defect-table th:nth-child(2),
.defect-table td:nth-child(2) {
  width: 14%;
}

.defect-table th:nth-child(3),
.defect-table td:nth-child(3) {
  width: 17%;
}

.defect-table th:nth-child(4),
.defect-table td:nth-child(4) {
  width: 20%;
}

.defect-table th:nth-child(5),
.defect-table td:nth-child(5) {
  width: 15%;
}

.defect-table th:nth-child(7),
.defect-table td:nth-child(7) {
  width: 38px;
  text-align: center;
}

.defect-table input,
.defect-table textarea {
  min-height: 34px;
  padding: 7px 8px;
  font-size: 12px;
}

.defect-table textarea {
  min-height: 56px;
}

.defect-table th .defect-header-input {
  width: 100%;
  min-height: 38px;
  padding: 2px 4px;
  border: 1px solid transparent;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: 800;
  line-height: 1.18;
  text-align: center;
  resize: vertical;
  box-shadow: none;
}

.defect-table th .defect-header-input:focus {
  border-color: var(--teal);
  background: #ffffff;
  box-shadow: inset 0 0 0 1px var(--teal);
}

.defect-group-title-row td {
  padding: 6px 8px;
  background: #ffffff;
  text-align: center;
}

.defect-group-title-row input {
  min-height: 30px;
  border-color: transparent;
  background: transparent;
  font-weight: 800;
  text-align: center;
}

.defect-group-title-row input:focus {
  border-color: var(--teal);
  background: #ffffff;
}

.defect-photo-cell {
  display: grid;
  gap: 6px;
  align-content: start;
  min-height: 76px;
  padding: 5px;
  border: 1px dashed transparent;
  border-radius: 6px;
}

.defect-photo-cell img {
  width: 100%;
  max-height: 120px;
  object-fit: cover;
  border: 1px solid var(--line);
  border-radius: 6px;
}

.defect-photo-list {
  display: grid;
  gap: 8px;
}

.defect-photo-item {
  position: relative;
}

.defect-photo-item img {
  display: block;
}

.defect-photo-remove {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 24px;
  height: 24px;
  background: rgba(255, 255, 255, 0.94);
}

.file-chip {
  justify-content: center;
  min-height: 28px;
  padding: 4px 8px;
}

.file-drop-zone.file-drop-active,
.field.file-drop-active,
.document-field.file-drop-active {
  background: #f0f7ff;
  outline: 2px dashed #7ab7ff;
  outline-offset: 3px;
  box-shadow: inset 0 0 0 1px rgba(29, 95, 174, 0.18);
}

.file-drop-zone.file-drop-active {
  border-color: #7ab7ff;
}

.visually-hidden-file {
  position: absolute;
  width: 1px;
  min-height: 1px;
  height: 1px;
  padding: 0;
  border: 0;
  opacity: 0;
  pointer-events: none;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #ffffff;
  color: #344054;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.icon-btn.danger {
  border-color: #f3b6b0;
  color: var(--red);
}

.trash-icon-btn {
  position: relative;
  flex: 0 0 auto;
  width: 40px;
  min-width: 40px;
  height: 38px;
  min-height: 38px;
  padding: 0;
  border-color: #b9c9de;
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--blue);
  box-shadow: 0 1px 1px rgba(24, 34, 48, 0.04);
  transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.trash-icon-btn:hover,
.trash-icon-btn:focus-visible {
  border-color: var(--teal);
  background: var(--teal-soft);
  box-shadow: var(--shadow-soft);
  transform: translateY(-1px);
}

.trash-can-icon {
  position: relative;
  display: block;
  width: 20px;
  height: 22px;
}

.trash-can-icon::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 1px;
  width: 10px;
  height: 5px;
  border: 2px solid currentColor;
  border-bottom: 0;
  border-radius: 6px 6px 0 0;
}

.trash-can-icon::after {
  content: "";
  position: absolute;
  left: 2px;
  top: 7px;
  width: 16px;
  height: 13px;
  border: 2px solid currentColor;
  border-top-width: 2px;
  border-radius: 2px 2px 4px 4px;
}

.trash-can-icon span {
  position: absolute;
  z-index: 1;
  top: 11px;
  width: 2px;
  height: 7px;
  border-radius: 999px;
  background: currentColor;
}

.trash-can-icon span:nth-child(1) {
  left: 6px;
}

.trash-can-icon span:nth-child(2) {
  left: 9px;
}

.trash-can-icon span:nth-child(3) {
  left: 12px;
}

.trash-count-badge {
  position: absolute;
  top: -7px;
  right: -7px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--teal);
  color: #ffffff;
  font-size: 11px;
  font-weight: 800;
  line-height: 18px;
  box-shadow: 0 0 0 2px #ffffff;
}

.remove-icon-btn {
  flex: 0 0 26px;
  width: 26px;
  min-width: 26px;
  height: 26px;
  min-height: 26px;
  padding: 0;
  border-color: #f3b6b0;
  background: #ffffff;
  color: var(--red);
  font-size: 16px;
  font-weight: 400;
  line-height: 1;
  box-shadow: none;
}

.remove-icon-btn:hover,
.remove-icon-btn:focus-visible {
  background: var(--red-soft);
  border-color: #ee9f97;
}

.compact-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

input,
select,
textarea {
  width: 100%;
  min-height: 38px;
  padding: 9px 10px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #ffffff;
  color: var(--text);
  outline: none;
}

textarea {
  min-height: 112px;
  resize: vertical;
  line-height: 1.45;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(29, 95, 174, 0.14);
}

.check-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: #e5e7eb;
  color: #98a2b3;
  font-size: 12px;
  font-weight: 900;
}

.check-dot.ready {
  background: var(--green);
  color: #ffffff;
}

.editor-grid {
  display: grid;
  grid-template-columns: 168px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
}

.editor-grid > aside.panel {
  position: sticky;
  top: 66px;
  z-index: 25;
  display: block;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 8px 24px rgba(17, 33, 52, 0.08);
}

.editor-grid > aside.panel .panel-header {
  align-items: center;
  gap: 8px;
  padding: 8px 9px;
  border-bottom: 1px solid var(--line);
}

.editor-grid > aside.panel .panel-header h2 {
  font-size: 18px;
  line-height: 1;
}

.editor-grid > aside.panel .panel-header .small {
  display: none;
}

.editor-grid > aside.panel .check-dot {
  width: 16px;
  height: 16px;
  font-size: 10px;
}

.editor-grid > .panel:last-child .panel-body {
  overflow-x: hidden;
  background: #edf2f5;
}

.report-fill-sheet {
  width: 420mm;
  max-width: none;
  min-height: 297mm;
  margin: 0 auto;
  padding: 20mm 20mm 15mm;
  border: 1px solid #cfd6dd;
  background: #ffffff;
  color: #000000;
  font-family: var(--serif);
  font-size: 14pt;
  line-height: 1.15;
  box-shadow: 0 12px 32px rgba(17, 33, 52, 0.12);
  zoom: 0.9;
}

.report-fill-sheet * {
  letter-spacing: 0;
}

.report-fill-sheet .form-grid {
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
}

.report-fill-title .form-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.report-fill-sheet .field {
  gap: 5px;
}

.report-fill-sheet .field label {
  display: block;
  min-height: 0;
  color: #000000;
  font-family: var(--serif);
  font-size: 14pt;
  font-weight: 700;
  line-height: 1.15;
  text-transform: none;
}

.report-fill-sheet .field label .check-dot {
  display: none;
}

.report-fill-sheet input:not([type="file"]):not([type="checkbox"]),
.report-fill-sheet select,
.report-fill-sheet textarea {
  min-height: 30px;
  padding: 3px 4px;
  border: 1px solid #000000;
  border-radius: 0;
  background: #ffffff;
  color: #000000;
  font-family: var(--serif);
  font-size: 14pt;
  line-height: 1.15;
  box-shadow: none;
}

.report-fill-sheet input:not([type="file"]):not([type="checkbox"]),
.report-fill-sheet select {
  border-color: #000000;
}

.report-fill-sheet textarea {
  min-height: 44px;
  overflow: hidden;
  resize: none;
  text-align: justify;
}

.report-fill-sheet textarea[data-field] {
  text-indent: 1.25cm;
}

.report-fill-sheet input:focus,
.report-fill-sheet select:focus,
.report-fill-sheet textarea:focus {
  border-color: var(--teal);
  background: #ffffff;
  box-shadow: inset 0 0 0 1px rgba(29, 95, 174, 0.42);
}

.report-fill-sheet .subsection,
.report-fill-sheet .row-card,
.report-fill-sheet .photo-card,
.report-fill-sheet .technical-state-note,
.report-fill-sheet .climate-rose-block,
.report-fill-sheet .climate-metric {
  border-radius: 0;
  box-shadow: none;
}

.report-fill-sheet .subsection {
  padding: 0;
  border: 0;
  background: transparent;
  font-family: var(--serif);
}

.report-fill-sheet .subsection h3,
.report-fill-sheet .form-section h3 {
  color: #000000;
  font-family: var(--serif);
  font-size: 14pt;
  line-height: 1.15;
  text-indent: 1.25cm;
  text-transform: none;
}

.report-fill-sheet p {
  margin: 0 0 6px;
}

.report-fill-sheet .subsection p:not(.muted),
.report-fill-sheet .technical-state-note p {
  text-align: justify;
  text-indent: 1.25cm;
}

.report-fill-sheet .muted {
  color: #000000;
}

.report-fill-sheet .normative-report-preview {
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid #000000;
}

.report-fill-sheet .normative-report-preview h3 {
  font-family: var(--serif);
  font-size: 14pt;
  font-weight: 700;
}

.report-fill-sheet .normative-report-preview ol,
.report-fill-sheet .normative-report-preview p {
  font-family: var(--serif);
  font-size: 14pt;
  line-height: 1.15;
}

.report-fill-sheet .table-wrap {
  overflow-x: visible;
}

.report-fill-sheet .compact-table,
.report-fill-sheet .reference-table,
.report-fill-sheet .report-preview-table,
.report-fill-sheet .defect-table {
  width: 100%;
  min-width: 0;
  border-collapse: collapse;
  table-layout: fixed;
  color: #000000;
  font-family: var(--serif);
  font-size: 14pt;
  line-height: 1.15;
}

.report-fill-sheet .report-preview-table.is-narrow {
  width: 72%;
}

.report-fill-sheet .report-preview-table.is-wide {
  width: 100%;
  min-width: 0;
}

.report-fill-sheet .compact-table th,
.report-fill-sheet .compact-table td,
.report-fill-sheet .reference-table th,
.report-fill-sheet .reference-table td,
.report-fill-sheet .report-preview-table th,
.report-fill-sheet .report-preview-table td,
.report-fill-sheet .defect-table th,
.report-fill-sheet .defect-table td {
  padding: 5px 6px;
  border: 1px solid #000000;
  color: #000000;
  vertical-align: middle;
}

.report-fill-sheet .compact-table th,
.report-fill-sheet .reference-table th,
.report-fill-sheet .report-preview-table th,
.report-fill-sheet .defect-table th {
  background: #e8f1fb;
  color: var(--blue);
  font-weight: 700;
  text-align: center;
  text-transform: none;
}

.report-fill-sheet .compact-table input:not([type="file"]):not([type="checkbox"]),
.report-fill-sheet .compact-table select,
.report-fill-sheet .compact-table textarea,
.report-fill-sheet .defect-table input:not([type="file"]):not([type="checkbox"]),
.report-fill-sheet .defect-table textarea {
  min-height: 24px;
  padding: 2px 3px;
  border: 1px solid #000000;
  background: #ffffff;
  font-size: 14pt;
  line-height: 1.15;
  text-indent: 0;
}

.report-fill-sheet .compact-table input:focus,
.report-fill-sheet .compact-table select:focus,
.report-fill-sheet .compact-table textarea:focus,
.report-fill-sheet .defect-table input:focus,
.report-fill-sheet .defect-table textarea:focus {
  border-color: var(--teal);
  background: #ffffff;
  box-shadow: inset 0 0 0 1px var(--teal);
}

.report-fill-sheet .compact-table th:empty,
.report-fill-sheet .compact-table td:has(> button[data-action="remove-row"]),
.report-fill-sheet .compact-table td:has(> button[data-action="remove-defect-row"]),
.report-fill-sheet .defect-group-action-cell {
  width: 0 !important;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  overflow: visible;
}

.report-fill-sheet .compact-table td:has(> button[data-action="remove-row"]),
.report-fill-sheet .compact-table td:has(> button[data-action="remove-defect-row"]),
.report-fill-sheet .defect-group-action-cell {
  position: relative;
}

.report-fill-sheet .compact-table td:has(> button[data-action="remove-row"]) > button,
.report-fill-sheet .compact-table td:has(> button[data-action="remove-defect-row"]) > button {
  position: absolute;
  top: 50%;
  left: 12px;
  z-index: 2;
  transform: translateY(-50%);
  white-space: nowrap;
}

.report-fill-sheet .defect-group-actions {
  position: absolute;
  top: 50%;
  left: 12px;
  z-index: 3;
  display: flex;
  gap: 6px;
  transform: translateY(-50%);
  font-family: var(--font);
  white-space: nowrap;
}

.report-fill-sheet .table-title,
.report-fill-sheet .table-caption,
.report-fill-sheet .reference-table-title {
  margin: 12px 0 8px;
  color: #000000;
  font-family: var(--serif);
  font-size: 11pt;
  font-weight: 400;
  text-indent: 1.25cm;
}

.report-fill-sheet .report-static-text {
  margin: 8px 0 10px;
  font-family: var(--serif);
  font-size: 14pt;
  line-height: 1.15;
  text-align: justify;
  text-indent: 1.25cm;
}

.report-fill-sheet .row-card {
  padding: 0;
  border: 0;
  background: transparent;
}

.report-fill-sheet .row-card-header {
  margin-bottom: 6px;
  font-family: var(--serif);
}

.report-fill-sheet .result-table-toolbar {
  align-items: flex-end;
  font-family: var(--font);
}

.report-fill-sheet .result-table-toolbar label {
  font-family: var(--font);
}

.report-fill-sheet .result-table-toolbar label span {
  font-family: var(--font);
  font-size: 12px;
}

.report-fill-sheet .result-table-actions {
  justify-content: flex-end;
  font-family: var(--font);
}

.report-fill-sheet .result-custom-table th textarea,
.report-fill-sheet .result-custom-table td textarea {
  width: 100%;
  min-height: 36px;
  border: 0;
  text-align: left;
}

.report-fill-sheet .result-custom-table th textarea {
  background: transparent;
  font-weight: 700;
  text-align: center;
}

.report-fill-sheet .result-custom-table th textarea:focus,
.report-fill-sheet .result-custom-table td textarea:focus {
  border: 1px solid var(--teal);
}

.report-fill-sheet .action-row {
  font-family: var(--font);
}

.report-fill-sheet .photo-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px 12px;
}

.report-fill-sheet .photo-card {
  padding: 0;
  border: 0;
  background: transparent;
  text-align: center;
}

.report-fill-sheet .photo-card img {
  aspect-ratio: 16 / 10;
  border-radius: 0;
  object-fit: cover;
}

.report-fill-sheet .photo-card input {
  border: 0;
  text-align: center;
  font-size: 11pt;
}

.report-fill-sheet .defect-header-wrap {
  margin-top: 10px;
  padding-right: 150px;
  overflow: visible;
}

.report-fill-sheet .defect-group-title-row td {
  background: #ffffff;
  text-align: center;
}

.report-fill-sheet .defect-group-title-row input {
  border: 0;
  background: transparent;
  font-weight: 700;
  text-align: center;
}

.report-fill-sheet .defect-group-title-row input:focus {
  border: 1px solid var(--teal);
  box-shadow: inset 0 0 0 1px var(--teal);
}

.report-fill-sheet .defect-table th .defect-header-input {
  min-height: 34px;
  padding: 0 2px;
  border: 0;
  background: transparent;
  color: var(--blue);
  font-family: var(--serif);
  font-size: 11pt;
  font-weight: 700;
  line-height: 1.1;
  text-align: center;
}

.report-fill-sheet .defect-table th .defect-header-input:focus {
  border: 1px solid var(--teal);
  background: #ffffff;
  box-shadow: inset 0 0 0 1px var(--teal);
}

.report-fill-sheet .defect-photo-cell img {
  border-radius: 0;
}

.section-list {
  display: grid;
  gap: 4px;
  padding: 6px;
}

.section-tab {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr) 29px;
  align-items: center;
  gap: 4px;
  width: 100%;
  min-height: 30px;
  padding: 5px 6px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: transparent;
  color: #344054;
  font-size: 12px;
  line-height: 1.2;
  text-align: left;
  white-space: normal;
}

.section-label {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 4px;
  min-width: 0;
}

.section-label.no-number {
  grid-template-columns: minmax(0, 1fr);
}

.section-number {
  min-width: 12px;
  color: var(--blue);
  font-weight: 850;
  line-height: 1.15;
  text-align: right;
  white-space: nowrap;
}

.section-title {
  min-width: 0;
  line-height: 1.15;
  overflow-wrap: normal;
}

.section-label.appendix-label .section-title {
  white-space: nowrap;
}

.section-label.appendix-label.accreditation-label .section-title {
  white-space: normal;
}

.section-tab.active {
  border-color: #bad4f7;
  background: var(--teal-soft);
  color: var(--blue);
  font-weight: 760;
}

.section-tab.appendix-add-tab {
  border-style: dashed;
  border-color: #b7c4d6;
  color: var(--blue);
  font-weight: 760;
}

.check-dot.plus {
  background: var(--teal);
  color: #ffffff;
  font-size: 16px;
  line-height: 16px;
}

.section-percent {
  justify-self: end;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

.editor-download-actions {
  display: grid;
  gap: 6px;
  padding: 8px 6px 6px;
  border-top: 1px solid var(--line);
}

.editor-export-btn {
  width: 100%;
  min-height: 34px;
  padding: 7px 8px;
  border-radius: var(--radius);
  color: #ffffff;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.15;
  text-align: center;
}

.editor-export-btn.pdf {
  border-color: var(--red);
  background: var(--red);
}

.editor-export-btn.doc {
  border-color: var(--blue);
  background: var(--blue);
}

.editor-export-btn:hover {
  filter: brightness(0.94);
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.form-grid .full {
  grid-column: 1 / -1;
}

.subsection {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel-soft);
}

.extra-appendix-editor {
  gap: 16px;
}

.appendix-page-list {
  display: grid;
  gap: 18px;
  justify-items: center;
}

.appendix-report-title {
  display: grid;
  gap: 4px;
  justify-items: center;
  width: min(100%, 760px);
  margin-bottom: 2px;
  color: #000000;
  font-family: "Times New Roman", Times, serif;
  font-size: 14pt;
  line-height: 1.15;
  text-align: center;
}

.appendix-report-title strong {
  font-size: 16pt;
}

.appendix-page-preview {
  display: grid;
  gap: 8px;
  justify-items: center;
  width: min(100%, 760px);
  padding: 10px;
  border: 1px solid #cfd8e3;
  background: #f8fafc;
}

.appendix-page-preview.landscape {
  width: min(100%, 940px);
}

.appendix-page-preview img {
  display: block;
  max-width: 100%;
  max-height: 720px;
  object-fit: contain;
  border: 1px solid #111827;
  background: #ffffff;
}

.appendix-page-missing {
  display: grid;
  place-items: center;
  min-height: 180px;
  width: 100%;
  border: 1px dashed #94a3b8;
  color: var(--muted);
  font-family: Arial, sans-serif;
  font-size: 14px;
}

.appendix-page-number {
  justify-self: start;
  color: var(--muted);
  font-family: Arial, sans-serif;
  font-size: 12px;
  font-weight: 700;
}

.climate-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.climate-metric {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
}

.climate-metric span {
  color: var(--muted);
  font-size: 12px;
}

.climate-metric strong {
  font-size: 15px;
  line-height: 1.25;
}

.climate-rose-block {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
}

.climate-rose-image {
  width: min(100%, 320px);
  aspect-ratio: 1 / 1;
  object-fit: contain;
}

.table-title {
  margin: 0 0 8px;
  color: var(--blue);
  font-weight: 700;
}

.report-table-wrap {
  margin-top: 10px;
}

.report-preview-table {
  margin: 0 auto;
}

.report-preview-table.is-narrow {
  width: min(100%, 880px);
}

.report-preview-table.is-wide {
  width: 100%;
  min-width: 720px;
}

.row-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
}

.row-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.expert-seal-toggle {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.expert-seal-toggle .compact-check {
  width: fit-content;
}

.repeat-list {
  display: grid;
  gap: 10px;
}

.compact-table input,
.compact-table select,
.compact-table textarea {
  min-height: 32px;
  padding: 7px 8px;
}

.compact-table textarea {
  min-height: 64px;
}

.result-table-card {
  gap: 12px;
}

.result-table-toolbar {
  align-items: flex-end;
  flex-wrap: wrap;
}

.result-table-toolbar label {
  display: grid;
  gap: 4px;
  min-width: 120px;
  font-weight: 700;
}

.result-table-toolbar label span {
  color: var(--muted);
  font-size: 12px;
}

.result-table-title-field {
  flex: 1 1 360px;
}

.result-table-toolbar input[type="number"] {
  max-width: 90px;
}

.result-table-actions {
  justify-content: flex-end;
  flex-wrap: wrap;
}

.section-block-list {
  margin-top: 14px;
}

.section-text-block .form-grid {
  grid-template-columns: minmax(0, 1fr);
}

.section-block-remove-row {
  display: flex;
  justify-content: flex-end;
}

.visual-subsection-list {
  display: grid;
  gap: 10px;
}

.visual-subsection-block {
  display: grid;
  gap: 10px;
  padding: 10px;
  border: 1px solid #d9e3ee;
  border-radius: 8px;
  background: #f8fbff;
}

.visual-subsection-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.visual-subsection-actions strong {
  color: var(--ink);
  font-size: 13px;
}

.visual-subsection-add-row {
  justify-content: flex-end;
}

.section-block-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
  padding-top: 0;
}

.block-add-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 8px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: #ffffff;
  color: #1d2939;
  font-weight: 800;
  cursor: pointer;
}

.block-add-button.text {
  border-color: #b9d6ff;
  color: var(--blue);
}

.block-add-button.table {
  border-color: #bfe8c9;
  color: var(--green);
}

.block-add-icon {
  position: relative;
  display: inline-grid;
  width: 24px;
  height: 24px;
  border: 2px solid currentColor;
  border-radius: 6px;
}

.text-icon {
  align-content: center;
  gap: 3px;
  padding: 4px;
}

.text-icon i {
  display: block;
  height: 2px;
  border-radius: 99px;
  background: currentColor;
}

.table-icon {
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  padding: 4px;
}

.table-icon i {
  border-radius: 2px;
  background: currentColor;
}

.result-custom-table th textarea {
  min-height: 44px;
  font-weight: 700;
  text-align: center;
}

.result-custom-table td textarea {
  min-height: 72px;
}

.preview-image {
  max-width: 260px;
  max-height: 180px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  object-fit: cover;
}

.preview-image.seal-preview {
  width: 150px;
  height: 150px;
  object-fit: contain;
  background: #fff;
}

.preview-image.signature-preview {
  width: 260px;
  height: 96px;
  object-fit: contain;
  background: #fff;
}

.document-field {
  gap: 8px;
}

.document-meta {
  color: var(--muted);
  font-size: 12px;
}

.document-preview-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.document-preview-strip img {
  width: 70px;
  height: 96px;
  border: 1px solid var(--line);
  border-radius: 6px;
  object-fit: cover;
  background: #ffffff;
}

.accreditation-docs-field {
  gap: 10px;
}

.accreditation-docs-header,
.accreditation-doc-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.accreditation-docs-header label {
  margin: 0;
}

.accreditation-doc-list {
  display: grid;
  gap: 10px;
}

.accreditation-doc-card {
  display: grid;
  gap: 9px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfdff;
}

.accreditation-doc-title-row strong {
  color: var(--blue);
  font-size: 13px;
}

.accreditation-doc-grid {
  display: grid;
  grid-template-columns: minmax(180px, 220px);
  gap: 10px;
}

.accreditation-doc-grid label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.accreditation-doc-grid input {
  width: 100%;
}

.accreditation-doc-empty {
  padding: 12px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  color: var(--muted);
  background: #ffffff;
}

.accreditation-select-field {
  max-width: 680px;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.structure-photo-drop {
  display: grid;
  gap: 12px;
  border: 1px dashed transparent;
  border-radius: 8px;
  padding: 0;
}

.photo-card {
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
}

.photo-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--line);
}

.empty {
  display: grid;
  place-items: center;
  min-height: 220px;
  padding: 24px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: var(--panel-soft);
  text-align: center;
}

.empty strong {
  display: block;
  margin-bottom: 8px;
  color: var(--blue);
  font-size: 18px;
}

.create-start-panel {
  min-height: min(520px, calc(100vh - 250px));
  display: grid;
  place-items: center;
}

.big-create-button {
  width: min(520px, 100%);
  min-height: 260px;
  display: grid;
  place-items: center;
  gap: 10px;
  padding: 34px;
  border: 2px dashed #9acfd6;
  border-radius: 8px;
  background: #f5fbfc;
  color: var(--blue);
  text-align: center;
  cursor: pointer;
}

.big-create-button:hover,
.big-create-button:focus-visible {
  border-color: var(--teal);
  background: #eefafa;
  outline: none;
}

.big-create-icon {
  position: relative;
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--teal);
  color: #ffffff;
}

.big-create-icon::before,
.big-create-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  border-radius: 999px;
  background: currentColor;
  transform: translate(-50%, -50%);
}

.big-create-icon::before {
  width: 40px;
  height: 6px;
}

.big-create-icon::after {
  width: 6px;
  height: 40px;
}

.big-create-button strong {
  font-size: 24px;
}

.big-create-button small {
  max-width: 360px;
  color: var(--muted);
  font-size: 14px;
}

.toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 20;
  min-width: 260px;
  max-width: 420px;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: var(--blue);
  color: #ffffff;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: 0.18s ease;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.delete-confirm-toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 30;
  display: grid;
  gap: 12px;
  min-width: 280px;
  max-width: min(420px, calc(100vw - 32px));
  padding: 14px;
  border: 1px solid #f0b8b2;
  border-radius: 8px;
  background: #ffffff;
  color: var(--text);
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: 0.18s ease;
}

.delete-confirm-toast[hidden] {
  display: none;
}

.delete-confirm-toast.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.delete-confirm-message {
  color: var(--blue);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
}

.delete-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.delete-confirm-actions .btn {
  justify-content: center;
}

.auth-mode .nav-list,
.auth-mode .profile-button {
  display: none;
}

.auth-layout {
  display: grid;
  width: min(100%, 532px);
  min-height: calc(100vh - 230px);
  margin: 0 auto;
  align-items: center;
}

.auth-hero,
.auth-card {
  padding: 24px;
}

.auth-hero img {
  width: 64px;
  height: 64px;
  object-fit: contain;
  margin-bottom: 18px;
}

.auth-hero h2,
.auth-card h2 {
  margin-bottom: 12px;
  color: var(--blue);
}

.auth-hero p {
  max-width: 64ch;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.auth-note {
  margin-top: 24px;
  padding: 14px;
  border: 1px solid #bad4f7;
  border-radius: var(--radius);
  background: var(--teal-soft);
}

.auth-note strong,
.auth-note span {
  display: block;
}

.auth-note span {
  margin-top: 6px;
  color: #344054;
}

.auth-card {
  display: grid;
  gap: 12px;
  align-content: start;
  min-height: 500px;
}

.auth-card label,
.auth-mini-form label,
.invite-form label {
  display: grid;
  gap: 6px;
  color: var(--blue);
  font-weight: 750;
}

.auth-card input,
.auth-mini-form input,
.invite-form input,
.invite-form select {
  width: 100%;
  min-height: 38px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 8px 10px;
  background: #fff;
  color: var(--text);
}

.auth-card input:focus,
.auth-mini-form input:focus,
.invite-form input:focus,
.invite-form select:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(29, 95, 174, 0.14);
}

.auth-submit {
  margin-top: 4px;
}

.auth-switch {
  margin: 8px 0 0;
  color: var(--muted);
  text-align: center;
  font-size: 15px;
}

.auth-link {
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--teal);
  cursor: pointer;
  font: inherit;
  font-weight: 850;
}

.auth-link:hover {
  color: var(--blue);
  text-decoration: underline;
}

.user-chip {
  display: grid;
  gap: 2px;
  min-height: 36px;
  padding: 6px 11px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 1px 0 rgba(16, 42, 76, 0.04);
}

.user-chip span {
  color: var(--blue);
  font-weight: 800;
  line-height: 1.05;
}

.user-chip small {
  color: var(--muted);
  font-size: 11px;
}

.profile-page {
  display: grid;
  gap: 16px;
}

.profile-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  min-height: 210px;
  padding: 24px;
  border: 1px solid #d7e1ee;
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(16, 42, 76, 0.98), rgba(29, 95, 174, 0.92)),
    var(--blue);
  color: #ffffff;
  box-shadow: var(--shadow);
}

.profile-hero-main {
  display: flex;
  align-items: center;
  gap: 22px;
  min-width: 0;
}

.panel-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.profile-avatar-editor {
  display: grid;
  gap: 8px;
  justify-items: center;
  color: var(--teal);
  font-weight: 800;
  cursor: pointer;
}

.profile-hero-avatar {
  color: #dbeafe;
}

.profile-avatar-editor:hover span:last-child {
  color: #ffffff;
  text-decoration: underline;
}

.profile-avatar-large,
.team-avatar {
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: linear-gradient(135deg, #64748b, #1d5fae);
  color: #ffffff;
  font-weight: 850;
  flex: 0 0 auto;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
}

.profile-avatar-large {
  width: 106px;
  height: 106px;
  font-size: 34px;
}

.team-avatar {
  width: 48px;
  height: 48px;
  font-size: 15px;
  border-color: var(--line);
  box-shadow: none;
}

.profile-avatar-large img,
.team-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-identity {
  min-width: 0;
}

.profile-title-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.profile-title-line .eyebrow {
  margin: 0;
  color: #bfdbfe;
}

.profile-identity h2 {
  color: #ffffff;
  font-size: 30px;
}

.profile-identity p {
  margin: 8px 0 0;
  color: #dbeafe;
  font-size: 16px;
  font-weight: 650;
}

.profile-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.profile-hero-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 10px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.1);
  color: #eff6ff;
  font-weight: 700;
}

.profile-hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 9px;
  min-width: 280px;
}

.profile-hero-actions .btn {
  border-color: rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.96);
}

.profile-hero-actions .btn.primary {
  border-color: #ffffff;
  background: #ffffff;
  color: var(--blue);
}

.profile-hero-actions .btn.danger {
  border-color: rgba(255, 255, 255, 0.34);
  background: rgba(255, 241, 240, 0.96);
}

.user-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 850;
  white-space: nowrap;
}

.user-status-pill.active {
  background: #e7f6ee;
  color: #246b49;
}

.user-status-pill.work {
  background: #eaf2ff;
  color: #1d5fae;
}

.user-status-pill.vacation {
  background: #fff4dc;
  color: #946013;
}

.user-status-pill.blocked {
  background: #fff1f0;
  color: #b42318;
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.profile-stat {
  min-height: 92px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: var(--shadow-soft);
}

.profile-stat span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.profile-stat strong {
  display: block;
  margin-top: 10px;
  color: var(--blue);
  font-size: 24px;
  line-height: 1.15;
}

.profile-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(340px, 0.65fr);
  gap: 16px;
  align-items: start;
}

.profile-section {
  box-shadow: var(--shadow-soft);
}

.auth-mini-form,
.invite-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 10px;
  align-items: end;
}

.profile-form,
.profile-password-row {
  display: grid;
  gap: 12px;
  align-items: end;
}

.profile-form {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.profile-password-row {
  grid-template-columns: 1fr;
}

.profile-form label,
.profile-password-row label {
  display: grid;
  gap: 6px;
  color: var(--blue);
  font-weight: 750;
}

.profile-form label span,
.profile-password-row label span {
  font-size: 12px;
  text-transform: uppercase;
}

.profile-form input,
.profile-form select,
.profile-password-row input {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 8px 11px;
  background: #ffffff;
  color: var(--text);
}

.profile-form input:focus,
.profile-form select:focus,
.profile-password-row input:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(29, 95, 174, 0.14);
}

.profile-section-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 16px;
}

.minimal-profile-page {
  max-width: 860px;
}

.minimal-profile-card {
  width: 100%;
}

.minimal-profile-form {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.profile-readonly-form {
  align-items: stretch;
}

.profile-readonly-field {
  display: grid;
  gap: 7px;
  min-height: 64px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 12px;
  background: #f8fafc;
}

.profile-readonly-field span {
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.profile-readonly-field strong {
  align-self: end;
  color: var(--text);
  font-size: 15px;
  line-height: 1.25;
}

.minimal-profile-role {
  margin-top: 6px;
  color: var(--muted);
  font-size: 14px;
}

.minimal-profile-role strong {
  color: var(--blue);
}

.profile-settings-button {
  width: 36px;
  height: 36px;
  font-size: 18px;
}

.profile-title-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.profile-logout-button {
  border-color: var(--red);
  background: var(--red);
  color: #ffffff;
}

.profile-logout-button:hover,
.profile-logout-button:focus-visible {
  border-color: #b42318;
  background: #b42318;
  color: #ffffff;
}

.profile-settings-panel {
  display: grid;
  gap: 18px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.profile-settings-group {
  display: grid;
  gap: 12px;
}

.profile-settings-title h3 {
  margin: 2px 0 0;
  color: var(--blue);
  font-size: 18px;
}

.account-create-form {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr)) auto;
  gap: 10px;
  align-items: end;
}

.account-create-form label {
  display: grid;
  gap: 6px;
  color: var(--blue);
  font-weight: 750;
}

.account-create-form label span {
  font-size: 12px;
  text-transform: uppercase;
}

.account-create-form input,
.account-create-form select {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 8px 11px;
  background: #ffffff;
  color: var(--text);
}

.account-create-form input:focus,
.account-create-form select:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(29, 95, 174, 0.14);
}

.report-access-block {
  display: grid;
  gap: 14px;
  margin-bottom: 18px;
  padding-bottom: 4px;
}

.report-access-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.access-count {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  background: #eef6ff;
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.report-access-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 7px;
}

.access-user-check {
  gap: 0;
  min-height: 64px;
  padding: 12px;
  color: var(--text);
  cursor: default;
  transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.access-user-check,
.responsible-expert-card {
  width: 100%;
  box-sizing: border-box;
}

.access-user-check:hover {
  border-color: var(--line);
  box-shadow: none;
}

.access-user-check.selected {
  border-color: var(--line);
  background: #ffffff;
}

.access-user-check.system-access {
  border-color: var(--line);
  background: #ffffff;
}

.access-user-check.locked {
  background: #ffffff;
  cursor: default;
}

.access-row-header,
.responsible-expert-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px;
  align-items: center;
  gap: 14px;
  width: 100%;
}

.access-user-check input.access-check-input,
.responsible-expert-check {
  justify-self: end;
  width: 34px;
  min-width: 34px;
  min-height: 34px;
  height: 34px;
  margin: 0;
  accent-color: #0d6efd;
  cursor: pointer;
}

.responsible-expert-role {
  max-width: calc(100% - 48px);
}

.access-user-check.locked input.access-check-input,
.access-user-check input.access-check-input:disabled {
  accent-color: #c4ccd8;
  cursor: not-allowed;
}

.access-user-main,
.responsible-expert-main {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.access-user-main strong,
.responsible-expert-main strong {
  overflow: hidden;
  color: #000000;
  font-size: 16px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.access-user-main small,
.responsible-expert-main small {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.responsible-experts-title {
  margin-bottom: 12px;
}

.profile-account-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.profile-account-list div {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 0;
}

.profile-account-list span {
  color: var(--muted);
  font-weight: 700;
}

.profile-account-list strong {
  color: var(--blue);
  text-align: right;
}

.profile-muted-count {
  align-self: center;
  color: var(--muted);
  font-weight: 800;
}

.employee-list,
.invite-list {
  display: grid;
  gap: 10px;
}

.employee-card,
.invite-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 1px 0 rgba(16, 42, 76, 0.03);
}

.employee-card {
  justify-content: flex-start;
}

.employee-card .inline-actions {
  margin-left: auto;
}

.employee-card.inactive,
.invite-card.used {
  opacity: 0.72;
}

.employee-card strong,
.employee-card span,
.employee-card small,
.invite-card code,
.invite-card span,
.invite-card small {
  display: block;
}

.employee-card strong {
  color: var(--blue);
}

.employee-details {
  min-width: min(520px, 100%);
  display: grid;
  gap: 3px;
}

.presence-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 10px;
  border-radius: 999px;
  font-weight: 850;
}

.presence-pill.online {
  background: var(--green-soft);
  color: var(--green);
}

.presence-pill.offline {
  background: #eef2f6;
  color: #526071;
}

.employee-rename {
  display: grid;
  grid-template-columns: minmax(220px, 360px) auto;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
}

.employee-rename input {
  width: 100%;
  min-height: 34px;
  padding: 6px 9px;
  border: 1px solid var(--line-strong);
  border-radius: 7px;
  background: #ffffff;
  color: var(--text);
  font: inherit;
}

.employee-rename input:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(29, 95, 174, 0.14);
}

.admin-user-management {
  padding-top: 4px;
}

.admin-user-card {
  display: grid;
  gap: 12px;
}

.admin-user-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.admin-user-card-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.admin-user-fields {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.admin-user-fields label {
  display: grid;
  gap: 6px;
  color: var(--blue);
  font-weight: 750;
}

.admin-user-fields label span {
  font-size: 12px;
  text-transform: uppercase;
}

.admin-user-fields input {
  width: 100%;
  min-height: 38px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 8px 10px;
  background: #ffffff;
  color: var(--text);
}

.admin-user-fields input:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(29, 95, 174, 0.14);
}

.employee-card span,
.invite-card span {
  color: var(--text);
}

.employee-card small,
.invite-card small {
  color: var(--muted);
}

.invite-card code {
  padding: 6px 8px;
  border-radius: var(--radius);
  background: var(--panel-soft);
  color: var(--blue);
  font-weight: 800;
}

@media (max-width: 1280px) {
  .auth-layout,
  .profile-content-grid {
    grid-template-columns: 1fr;
  }

  .profile-hero {
    align-items: flex-start;
    flex-direction: column;
  }

  .profile-hero-actions {
    justify-content: flex-start;
    min-width: 0;
    width: 100%;
  }

  .profile-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .auth-mini-form,
  .invite-form,
  .profile-form,
  .profile-password-row {
    grid-template-columns: 1fr;
  }
}

.directory-tabs,
.nested-tabbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.directory-tab,
.nested-tab {
  min-height: 36px;
  padding: 7px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  color: #344054;
  font-weight: 750;
  cursor: pointer;
}

.directory-tab.active,
.nested-tab.active {
  border-color: #bad4f7;
  background: var(--teal-soft);
  color: var(--blue);
  box-shadow: inset 0 -2px 0 var(--teal);
}

.nested-tabbar.compact {
  margin-bottom: 4px;
}

.nested-tabbar.compact .nested-tab {
  min-height: 32px;
  padding: 5px 10px;
  font-size: 12px;
}

.directory-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

.dir-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
}

.report-frame {
  width: 100%;
  min-height: 600px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #ffffff;
  overflow: auto;
}

.report-sheet {
  width: 210mm;
  min-height: 297mm;
  margin: 20px auto;
  padding: 16mm;
  background: #ffffff;
  color: #000000;
  font-family: var(--serif);
  font-size: 14pt;
  line-height: 1.25;
  box-shadow: 0 0 0 1px var(--line), 0 10px 30px rgba(17, 33, 52, 0.12);
}

@media (max-width: 1700px) {
  .report-fill-sheet {
    zoom: 0.78;
  }
}

@media (max-width: 1450px) {
  .report-fill-sheet {
    zoom: 0.68;
  }
}

@media (max-width: 1180px) {
  body {
    min-width: 0;
    width: 100%;
  }

  .app-shell {
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
    overflow-x: clip;
  }

  .sidebar {
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
    gap: 8px;
    width: 100%;
    min-width: 0;
    padding: 10px 14px;
  }

  .brand {
    min-width: 0;
    width: 100%;
  }

  .nav-list {
    min-width: 0;
  }

  .workspace {
    width: 100%;
    min-width: 0;
    padding: 16px 14px 32px;
  }

  .topbar {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .top-actions {
    justify-content: flex-start;
  }

  .view {
    min-width: 0;
  }

  .profile-button {
    justify-self: start;
    margin-left: 0;
  }

  .report-fill-sheet {
    zoom: 0.62;
  }

  .dashboard-grid,
  .three-col,
  .photo-grid,
  .account-create-form,
  .admin-user-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .climate-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .check-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 720px) {
  .delete-confirm-toast {
    right: 16px;
    bottom: 16px;
    left: 16px;
    min-width: 0;
    max-width: none;
  }

  body {
    font-size: 13px;
  }

  .sidebar {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px 10px;
    padding: 8px 10px;
  }

  .brand {
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 8px;
    padding: 4px 0;
  }

  .brand img {
    width: 34px;
    height: 34px;
  }

  .brand strong {
    font-size: 14px;
  }

  .brand small {
    display: none;
  }

  .profile-button {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    width: 40px;
    height: 40px;
    margin-left: 0;
  }

  .profile-avatar {
    width: 30px;
    height: 30px;
  }

  .profile-title-actions {
    justify-content: flex-start;
  }

  .admin-user-card-header {
    display: grid;
  }

  .admin-user-card-actions {
    justify-content: space-between;
  }

  .admin-user-fields {
    grid-template-columns: minmax(0, 1fr);
  }

  .nav-list {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: nowrap;
    gap: 6px;
    min-width: 0;
    margin: 0 -2px;
    padding: 2px 2px 4px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .nav-list::-webkit-scrollbar {
    display: none;
  }

  .nav-link {
    flex: 0 0 auto;
    min-height: 40px;
    padding: 8px 11px;
    font-size: 13px;
  }

  .workspace {
    padding: 14px 10px 28px;
  }

  .topbar {
    gap: 10px;
    margin-bottom: 14px;
  }

  .dashboard-grid,
  .two-col,
  .three-col,
  .photo-grid,
  .climate-metric-grid,
  .checkbox-grid,
  .profile-stats,
  .profile-form,
  .account-create-form,
  .report-access-grid,
  .profile-password-row,
  .profile-section-actions,
  .searchbar,
  .form-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .top-actions,
  .panel-header,
  .profile-hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .top-actions .btn,
  .panel-header .btn,
  .profile-hero-actions .btn {
    width: 100%;
    justify-content: center;
  }

  .panel.pad,
  .panel-body,
  .panel-header {
    padding: 12px;
  }

  .searchbar input,
  .searchbar select,
  .searchbar .btn,
  input:not([type="checkbox"]):not([type="radio"]),
  select,
  textarea {
    width: 100%;
    min-height: 42px;
    font-size: 16px;
  }

  h1 {
    font-size: 22px;
  }

  h2 {
    font-size: 18px;
  }

  .table-wrap {
    margin: 0 -2px;
    padding-bottom: 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .table-wrap table {
    min-width: 720px;
  }

  .conclusion-list-table {
    min-width: 0 !important;
    border-collapse: separate;
    border-spacing: 0 10px;
  }

  .conclusion-list-table thead {
    display: none;
  }

  .conclusion-list-table tbody,
  .conclusion-list-table tr,
  .conclusion-list-table td {
    display: block;
    width: 100%;
  }

  .conclusion-list-table tr {
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: var(--shadow-soft);
  }

  .conclusion-list-table td {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 8px;
    padding: 6px 0;
    border-bottom: 0;
  }

  .conclusion-list-table td::before {
    content: attr(data-label);
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
  }

  .conclusion-list-table .access-names {
    min-width: 0;
  }

  .conclusion-list-table .access-names span {
    white-space: normal;
  }

  .conclusion-list-table td[data-label="Действия"] {
    display: block;
    padding-top: 10px;
  }

  .conclusion-list-table td[data-label="Действия"]::before,
  .conclusion-list-table td.conclusion-actions-empty {
    display: none;
  }

  .conclusion-list-table .inline-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .conclusion-list-table .inline-actions .btn {
    width: 100%;
    justify-content: center;
  }

  .inline-actions {
    gap: 6px;
  }

  .inline-actions .btn.small-btn {
    min-height: 34px;
    padding: 7px 10px;
  }

  .editor-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .editor-grid > aside.panel {
    position: static;
  }

  .section-list {
    display: flex;
    gap: 6px;
    padding: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .section-list::-webkit-scrollbar {
    display: none;
  }

  .section-tab {
    flex: 0 0 215px;
    min-height: 48px;
    padding: 7px 8px;
  }

  .editor-download-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .editor-grid > .panel:last-child .panel-body {
    overflow-x: auto;
  }

  .report-fill-sheet {
    width: 100%;
    min-height: auto;
    margin: 0;
    padding: 14px;
    font-size: 15px;
    zoom: 1;
  }

  .report-fill-title .form-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .report-fill-sheet .field label,
  .report-fill-sheet .subsection h3,
  .report-fill-sheet .form-section h3,
  .report-fill-sheet .report-static-text,
  .report-fill-sheet .compact-table,
  .report-fill-sheet .reference-table,
  .report-fill-sheet .report-preview-table,
  .report-fill-sheet .defect-table,
  .report-fill-sheet input:not([type="file"]):not([type="checkbox"]),
  .report-fill-sheet select,
  .report-fill-sheet textarea {
    font-size: 15px;
  }

  .report-fill-sheet input:not([type="file"]):not([type="checkbox"]),
  .report-fill-sheet select,
  .report-fill-sheet textarea {
    min-height: 42px;
    padding: 8px 9px;
  }

  .report-fill-sheet textarea {
    min-height: 92px;
  }

  .report-fill-sheet .table-wrap {
    overflow-x: auto;
  }

  .report-fill-sheet .compact-table,
  .report-fill-sheet .reference-table,
  .report-fill-sheet .report-preview-table,
  .report-fill-sheet .defect-table {
    min-width: 720px;
  }

  .report-fill-sheet .photo-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .report-fill-sheet .defect-header-wrap {
    padding-right: 0;
    overflow-x: auto;
  }

  .report-fill-sheet .defect-group-action-cell {
    width: auto !important;
    min-width: 150px;
    padding: 6px;
    border-left: 1px solid #000000;
  }

  .report-fill-sheet .defect-group-actions {
    position: static;
    flex-wrap: wrap;
    transform: none;
    white-space: normal;
  }

  .report-fill-sheet .compact-table td:has(> button[data-action="remove-row"]) > button,
  .report-fill-sheet .compact-table td:has(> button[data-action="remove-defect-row"]) > button {
    position: static;
    transform: none;
    white-space: normal;
  }
}

@media print {
  body {
    min-width: 0;
    background: #ffffff;
  }

  .app-shell,
  .toast,
  .delete-confirm-toast {
    display: none;
  }
}
