:root {
  --bg-1: #f3f7fb;
  --bg-2: #dce7f0;
  --panel: #ffffff;
  --ink: #14252e;
  --ink-soft: #4b636e;
  --line: #c2d3dc;
  --brand: #0f6a6f;
  --brand-strong: #0a4c50;
  --accent: #2f6d8a;
  --ok: #2f8f5a;
  --bad: #bf3d31;
  --muted: #8d99a3;
}

.db-save-toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 2400;
  max-width: min(86vw, 460px);
  padding: 10px 14px;
  border: 1px solid #7dc2a4;
  border-radius: 10px;
  background: #e9fff3;
  color: #1f5f43;
  font-weight: 700;
  box-shadow: 0 8px 24px rgba(10, 55, 42, 0.2);
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.35s ease, transform 0.35s ease;
  pointer-events: none;
}

.db-save-toast.ok {
  border-color: #7dc2a4;
  background: #e9fff3;
  color: #1f5f43;
  box-shadow: 0 8px 24px rgba(10, 55, 42, 0.2);
}

.db-save-toast.err {
  border-color: #e2a2a2;
  background: #fff0f0;
  color: #8f1f1f;
  box-shadow: 0 8px 24px rgba(109, 26, 26, 0.24);
}

.db-save-toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "IBM Plex Sans", sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(circle at 12% 8%, #ffffffcc, transparent 34%),
    radial-gradient(circle at 90% 0%, #ffffff88, transparent 40%),
    linear-gradient(135deg, var(--bg-1), var(--bg-2));
}

.local-login-backdrop {
  position: fixed;
  inset: 0;
  z-index: 2600;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background:
    radial-gradient(circle at 12% 8%, #ffffffcc, transparent 34%),
    radial-gradient(circle at 90% 0%, #ffffff88, transparent 40%),
    linear-gradient(135deg, var(--bg-1), var(--bg-2));
}

.local-login-backdrop[hidden] {
  display: none !important;
}

.local-login-card {
  width: min(420px, 94vw);
  border: 1px solid #9db8c8;
  border-radius: 14px;
  background: #f7fcff;
  box-shadow: 0 24px 54px rgba(8, 26, 39, 0.28);
  padding: 1rem;
  display: grid;
  gap: 0.8rem;
}

.local-login-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.local-login-logo {
  width: 74px;
  height: 74px;
  object-fit: contain;
}

.local-login-brand h1 {
  margin: 0;
  font-size: 2rem;
  letter-spacing: 0.03em;
  color: #123f52;
}

.local-login-brand p,
.local-login-status {
  margin: 0;
  color: #2c5668;
  font-size: 0.9rem;
}

.local-login-card label {
  display: grid;
  gap: 0.25rem;
  color: #2f5667;
  font-weight: 700;
}

.local-login-card input {
  min-height: 40px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0 0.62rem;
  color: #163d4f;
  background: #ffffff;
  font-size: 0.95rem;
}

.local-login-status.err {
  color: #a33126;
  font-weight: 700;
}

.local-login-status.ok {
  color: #176b47;
  font-weight: 700;
}

.local-login-submit {
  justify-self: end;
  min-width: 120px;
}

.role-home-shell {
  place-items: center;
}

.role-home-hero {
  width: min(560px, 94vw);
}

.role-home-card {
  display: grid;
  gap: 0.75rem;
  justify-items: center;
  text-align: center;
  padding: 1.2rem;
}

.role-home-card h1,
.role-home-card h2,
.role-home-card p {
  margin: 0;
}

.role-home-card h1 {
  font-size: 2.2rem;
  color: #123f52;
}

.role-home-card h2 {
  font-size: 1.15rem;
  color: #0f4b63;
}

.role-home-card p {
  color: #2c5668;
}

.role-home-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.55rem;
  margin-top: 0.4rem;
}

.role-home-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0.55rem 0.85rem;
  text-decoration: none;
}

.role-home-actions .secondary-btn.role-home-link {
  color: #ffffff;
}

.app-shell {
  width: min(1280px, 96vw);
  margin: 1.4rem auto 2.2rem;
  display: grid;
  gap: 1rem;
  flex: 1 0 auto;
}

.global-footer {
  width: min(1280px, 96vw);
  margin: 0 auto 1rem;
  padding: 0.55rem 0.9rem;
  border-top: 1px solid #c4d6df;
  color: #46616d;
  font-size: 0.82rem;
  text-align: center;
}

.hero {
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 1rem 1.1rem 1.15rem;
  background: linear-gradient(160deg, #ffffffde, #f2f7fbe8);
}

.hero-head {
  display: grid;
  gap: 0.12rem;
  margin-bottom: 0.35rem;
}

.hero-head-side {
  margin-bottom: 0.18rem;
}

.brand-topline {
  display: grid;
  gap: 0.18rem;
  justify-items: start;
}

.brand-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
}

.brand-logo {
  width: 116px;
  height: 116px;
  object-fit: contain;
  display: block;
}

.brand {
  margin: 0;
  font-size: 2rem;
  letter-spacing: 0.02em;
  line-height: 1;
}

.hero-focus {
  display: grid;
  grid-template-columns: minmax(220px, 0.9fr) minmax(0, 2.1fr);
  gap: 0.75rem;
  align-items: start;
}

.focus-nav {
  display: grid;
  gap: 0.55rem;
  align-content: start;
}

.focus-tabs {
  display: grid;
  gap: 0.45rem;
}

.focus-intro-card,
.focus-info-card,
.focus-access-card {
  border: 1px solid #c4d5e0;
  border-radius: 11px;
  padding: 0.55rem;
  background: #f6f9fc;
  display: grid;
  gap: 0.45rem;
}

.focus-info-card,
.focus-access-card {
  background: transparent;
  border: 0;
  border-radius: 11px;
  padding: 0;
  gap: 0;
  box-shadow: none;
  overflow: hidden;
}

.focus-intro-title {
  margin: 0;
  font-size: 0.92rem;
  color: #184451;
  font-weight: 700;
  line-height: 1.28;
  text-align: center;
}

.focus-intro-note {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.focus-nav .focus-tab {
  min-height: 48px;
  text-align: center;
  border: 1px solid #8fb0c3 !important;
  border-radius: 10px;
  background: #e7f0f7 !important;
  color: #124c64 !important;
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  padding: 0.55rem 0.68rem;
  box-shadow: none;
}

.focus-nav .focus-tab:hover {
  transform: none;
  background: #d8e7f1 !important;
  border-color: #7da4ba !important;
}

.focus-nav .focus-tab.active {
  border-color: #0b6654 !important;
  background: linear-gradient(140deg, #118a70, #0d725b) !important;
  color: #ffffff !important;
}

.focus-card-title {
  margin: 0;
  font-size: 1rem;
  color: #1a4b61;
  font-weight: 700;
  text-align: center;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.focus-info-card > .focus-card-title,
.focus-access-card > .focus-card-title {
  margin: 0;
  padding: 0.45rem 0.55rem;
  border-radius: 11px 11px 0 0;
  border: 0;
  background: #2e6c88;
  color: #f4faff;
}

.focus-info-card > .focus-tabs,
.focus-access-card > .focus-role-buttons {
  border: 2px solid #4a7f99;
  border-top: 0;
  border-radius: 0 0 11px 11px;
  background: #f6f9fc;
  padding: 0.55rem;
}

.focus-practice-card > .focus-practice-body {
  border: 2px solid #4a7f99;
  border-top: 0;
  border-radius: 0 0 11px 11px;
  background: #f6f9fc;
  padding: 0.55rem;
  display: grid;
  gap: 0.45rem;
}

.focus-practice-summary {
  margin: 0;
  min-height: 44px;
  border: 2px solid #b88d2b;
  border-radius: 9px;
  background: #edf5fa;
  box-shadow: inset 0 0 0 1px #e8d6ab;
  color: #214f63;
  font-size: 0.8rem;
  line-height: 1.3;
  padding: 0.5rem;
}

.focus-practice-active-chip {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin: 0 0 0.42rem;
  min-height: 28px;
  padding: 0.18rem 0.5rem;
  border-radius: 9px;
  border: 1px solid #b18a2f;
  background: #b88d2b;
  color: #fff5d6;
  font-weight: 700;
  font-size: 0.76rem;
  letter-spacing: 0.025em;
  text-transform: uppercase;
  text-align: center;
}

.focus-practice-summary.err {
  color: #9a372b;
}

.focus-practice-summary-line {
  display: grid;
  grid-template-columns: 124px minmax(0, 1fr);
  align-items: baseline;
  column-gap: 0.36rem;
  margin: 0;
}

.focus-practice-summary-label {
  display: block;
  color: #45697a;
  font-weight: 400;
  white-space: nowrap;
}

.focus-practice-summary-value {
  display: block;
  min-width: 0;
  color: #111111;
  font-weight: 700;
  word-break: break-word;
}

.focus-practice-summary.err .focus-practice-summary-label,
.focus-practice-summary.err .focus-practice-summary-value {
  color: #9a372b;
}

.focus-practice-summary.err .focus-practice-active-chip {
  border-color: #9a372b;
  background: linear-gradient(160deg, #c66f63, #a4473d);
  color: #fff2ef;
}

.focus-practice-body .role {
  min-height: 40px;
  font-size: 0.86rem;
  text-align: center;
  text-transform: uppercase;
  border: 1px solid #8fb0c3;
  border-radius: 10px;
  background: #e3edf6;
  color: #124c64;
  box-shadow: none;
}

.focus-practice-body .role:hover {
  transform: none;
  background: #d2e3ef;
  border-color: #739ab0;
}

.focus-role-buttons {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.45rem;
  min-width: 0;
  width: 100%;
  max-width: 100%;
}

.focus-role-buttons .role {
  min-height: 40px;
  font-size: 0.86rem;
  text-align: center;
  text-transform: uppercase;
  border: 1px solid #8fb0c3;
  border-radius: 10px;
  background: #e3edf6;
  color: #124c64;
  box-shadow: none;
  min-width: 0;
  width: 100%;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.focus-role-buttons .role:not(.disabled):hover {
  transform: none;
  background: #d2e3ef;
  border-color: #739ab0;
}

.focus-role-buttons .role.active {
  border-color: #0b6654;
  background: linear-gradient(140deg, #118a70, #0d725b);
  color: #ffffff;
}

.test-user-switch-panel {
  margin-top: 0.18rem;
  border: 1px dashed #aac2d2;
  border-radius: 10px;
  background: #eef5fb;
  padding: 0.42rem 0.46rem;
  display: grid;
  gap: 0.34rem;
  min-width: 0;
  width: 100%;
  max-width: 100%;
}

.test-user-switch-label {
  margin: 0;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: #2f5f75;
}

.test-user-switch-select {
  min-height: 34px;
  border: 1px solid #8fb0c3;
  border-radius: 9px;
  background: #ffffff;
  color: #1f5268;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.28rem 0.44rem;
  min-width: 0;
  width: 100%;
  max-width: 100%;
  display: block;
}

.test-user-switch-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.34rem;
  min-width: 0;
  width: 100%;
  max-width: 100%;
}

.test-user-switch-btn {
  min-height: 34px;
  border-radius: 9px;
  min-width: 0;
  width: 100%;
  max-width: 100%;
}

.test-user-switch-meta {
  margin: 0;
  font-size: 0.72rem;
  color: #3f6578;
  line-height: 1.24;
}

.focus-detail {
  border: 1px solid #bfd3dd;
  border-radius: 14px;
  padding: 0.75rem;
  background: linear-gradient(175deg, #ffffff, #f6fbfd);
  min-height: 360px;
}

.focus-detail.is-empty {
  align-self: stretch;
}

.focus-detail.scopo-placeholder-active {
  background: #fff7bd;
}

.focus-pane {
  display: none !important;
  gap: 0.55rem;
}

.focus-pane.active {
  display: grid !important;
}

#paneScopo.active,
#paneLegacy.active {
  min-height: 320px;
  align-content: center;
  justify-items: center;
  text-align: center;
}

.scopo-placeholder-text {
  margin: 0;
  font-size: clamp(3rem, 8vw, 6.2rem);
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #6a5600;
}

.focus-pane h2 {
  margin: 0;
  font-size: 1.02rem;
  color: #103f4f;
}

#paneLineePerito {
  gap: 0.34rem;
  align-content: start;
}

#paneLineePerito h2 {
  margin: 0 0 0.26rem;
  font-size: 1.5rem;
  line-height: 1.12;
  color: #0f3f52;
}

#paneLineePerito .linee-lead {
  margin: 0 0 0.2rem;
  font-size: 0.95rem;
  line-height: 1.4;
  color: #2a5161;
}

#paneLineePerito .focus-section-title {
  margin: 0.52rem 0 0.1rem;
  font-size: 1.04rem;
  line-height: 1.2;
  color: #103f4f;
  font-weight: 700;
}

#paneLineePerito .focus-sub {
  margin: 0;
  font-size: 0.91rem;
  line-height: 1.38;
  color: #2f5260;
}

#paneLineePerito strong {
  color: #103f4f;
  font-weight: 700;
}

#paneLineePerito .linee-signature {
  margin: 0.72rem 0 0;
  margin-bottom: 42px;
  justify-self: end;
  text-align: right;
  font-family: "Palace Script MT", "Brush Script MT", "Segoe Script", "Lucida Handwriting", cursive;
  font-size: clamp(2rem, 4.6vw, 2.45rem);
  line-height: 1;
  letter-spacing: 0.012em;
  color: #2f4658;
  opacity: 0.95;
  transform: rotate(-12deg);
  transform-origin: right bottom;
}

#paneLegacy {
  gap: 0.22rem;
  align-content: start;
}

#paneLegacy h2 {
  margin: 0 0 0.18rem;
  font-size: 1.42rem;
  line-height: 1.12;
  color: #0f3f52;
}

#paneLegacy .focus-section-title {
  margin: 0.46rem 0 0.08rem;
  font-size: 1.02rem;
  line-height: 1.2;
  color: #103f4f;
  font-weight: 700;
}

#paneLegacy .focus-sub {
  margin: 0;
  font-size: 0.89rem;
  line-height: 1.28;
  color: #2f5260;
}

#paneLegacy .focus-list {
  margin: 0.06rem 0 0.14rem;
  padding-left: 1.02rem;
  gap: 0.16rem;
}

#paneLegacy .focus-list li {
  margin: 0;
  line-height: 1.24;
}

#paneNormativa h2 {
  text-align: right;
}

#paneNormativa .norm-lead {
  text-align: center;
}

.norm-lead {
  margin: 0;
  font-size: 0.82rem;
  color: #234958;
}

.norm-admin-bar {
  margin-top: 0.42rem;
  display: grid;
  grid-template-columns: auto minmax(160px, 210px) minmax(140px, 1fr) auto;
  align-items: center;
  gap: 0.38rem;
}

.norm-admin-label {
  color: #1f4d61;
  font-size: 0.76rem;
  font-weight: 700;
}

.norm-profile-select {
  height: 32px;
  border: 1px solid #93b0c2;
  border-radius: 8px;
  padding: 0 0.45rem;
  background: #eef5fa;
  color: #124b62;
  font-size: 0.76rem;
  font-weight: 600;
}

.norm-profile-meta {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  color: #2d5d71;
  font-size: 0.74rem;
  font-weight: 600;
}

.norm-add-source-btn {
  min-height: 34px;
  padding: 0.36rem 0.78rem;
  border: 1px solid #0f7a6f;
  border-radius: 10px;
  background: linear-gradient(140deg, #118a70, #0d725b);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 700;
  box-shadow: none;
}

.norm-add-source-btn:hover {
  transform: none;
  background: linear-gradient(140deg, #0f7f67, #0c6a55);
  border-color: #0b6654;
}

.norm-class-switch {
  margin-top: 0.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.42rem;
}

.norm-class-switch .norm-class-btn {
  min-width: 150px;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.32rem;
  border: 1px solid #87a8bc;
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
  background: #e8f1f7;
  color: #114b62;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1;
  transform: none;
  box-shadow: none;
}

.norm-class-switch .norm-class-btn:hover {
  background: #d9e9f3;
  border-color: #6f96ac;
}

.norm-class-switch .norm-class-btn.active {
  border-color: #0b6654;
  background: linear-gradient(140deg, #118a70, #0d725b);
  color: #ffffff;
}

.norm-class-label {
  white-space: nowrap;
}

.norm-class-count {
  font-weight: 600;
  opacity: 0.9;
}

.norm-weight-note {
  margin: 0.3rem auto 0;
  max-width: 940px;
  padding: 0 0.2rem;
  text-align: center;
  font-size: 0.79rem;
  line-height: 1.34;
  color: #284f61;
  font-style: normal;
}

.norm-weight-note-line2 {
  display: inline-block;
  white-space: nowrap;
}

.focus-sub {
  margin: 0;
  font-size: 0.9rem;
  color: #3e5b67;
}

.focus-list {
  margin: 0;
  padding-left: 1rem;
  display: grid;
  gap: 0.36rem;
  color: #214756;
}

.norm-matrix-wrap {
  margin-top: 0.56rem;
  border: 1px solid #b8ced9;
  border-radius: 11px;
  overflow: hidden;
  background: #fbfeff;
}

.norm-matrix-wrap.is-empty-class .norm-matrix {
  display: none;
}

.norm-category-empty {
  padding: 0.9rem 0.7rem;
  text-align: center;
  color: #2b5160;
  font-size: 0.8rem;
  font-weight: 600;
  background: #f4f9fc;
  border-top: 1px solid #d5e4ec;
}

.norm-matrix {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.norm-matrix th,
.norm-matrix td {
  padding: 0.4rem 0.45rem;
  border-bottom: 1px solid #d6e3ea;
  vertical-align: top;
  font-size: 0.75rem;
}

.norm-matrix th {
  text-align: center;
  font-weight: 700;
  color: #123f4f;
  background: #eaf3f7;
}

/* Tech Elegante: applicata solo quando la tabella ha classe .norm-matrix-tech-elegant.
   Rollback immediato: rimuovere la classe da index.html. */
.norm-matrix.norm-matrix-tech-elegant thead th {
  font-family: "IBM Plex Mono", monospace;
  text-transform: uppercase;
  letter-spacing: 0.045em;
  font-weight: 600;
  color: #1a485c;
  border-bottom: 1px solid #c5d8e3;
}

.norm-matrix.norm-matrix-tech-elegant thead .norm-head-main th {
  font-size: 0.72rem;
  background: #deebf3;
  padding-top: 0.34rem;
  padding-bottom: 0.34rem;
}

.norm-matrix.norm-matrix-tech-elegant thead .norm-head-sub th {
  font-size: 0.68rem;
  color: #2b5b70;
  background: #ebf4f9;
  padding-top: 0.3rem;
  padding-bottom: 0.3rem;
}

.norm-matrix.norm-matrix-tech-elegant thead th + th {
  border-left: 1px solid #cbdee8;
}

/* Corpo tabella: vintage solo su prima colonna (AMBITO).
   Fonte/Estremi/Norma/Rubrica restano in font UI per leggibilità. */
.norm-matrix.norm-matrix-tech-elegant tbody .norm-object-cell,
.norm-matrix.norm-matrix-tech-elegant tbody .norm-object-cell .norm-toggle {
  font-family: "IBM Plex Mono", monospace;
  letter-spacing: 0.012em;
}

.norm-matrix.norm-matrix-tech-elegant tbody .norm-object-cell .norm-toggle {
  font-weight: 600;
}

.norm-matrix tbody tr:last-child td {
  border-bottom: none;
}

.norm-col-object {
  width: 34%;
}

.norm-col-source-base {
  width: calc(16% + 3ch);
}

.norm-col-source-items {
  width: calc(20% - 3ch);
}

.norm-col-concept {
  width: 24%;
}

.norm-col-weight {
  width: 6%;
}

.norm-object-cell {
  color: #124c64;
  font-weight: 700;
}

.norm-base-cell {
  color: #2d505f;
  font-weight: 400;
  text-align: center;
}

.norm-warning-inline {
  display: inline-block;
  margin-right: 0;
  font-size: 1.8rem;
  line-height: 1;
}

.norm-base-main,
.norm-base-sub {
  display: block;
  line-height: 1.2;
}

.norm-detail-cell {
  color: #2e4f5e;
  font-weight: 400;
  text-align: left;
}

.norm-matrix tbody tr:not(.norm-child-row) > td:nth-child(3) {
  text-align: center;
}

.norm-concept-cell {
  color: #395c6b;
  font-weight: 400;
}

.norm-matrix td.norm-weight-cell {
  text-align: center;
  color: #2f5362;
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1;
}

.norm-rubrica-top {
  display: block;
  font-weight: 600;
  line-height: 1.2;
}

.norm-rubrica-sub {
  display: block;
  margin-top: 0.06rem;
  line-height: 1.22;
}

.norm-rubrica-l1 {
  display: block;
  padding-inline-start: 14px;
  line-height: 1.24;
}

.norm-rubrica-l2 {
  display: block;
  padding-inline-start: 28px;
  margin-top: 0.05rem;
  line-height: 1.24;
}

.norm-danger-word {
  color: #c62828;
  font-weight: 700;
}

.norm-object-main,
.norm-object-sub {
  display: block;
  line-height: 1.18;
}

.norm-origin-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.05em;
  margin-right: 0.34rem;
  padding: 0.05rem 0.32rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-family: "IBM Plex Sans", sans-serif;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.15;
  vertical-align: middle;
  text-transform: uppercase;
}

.norm-origin-eu {
  background: #e8f2f9;
  border-color: #94b6cb;
  color: #1b5269;
}

.norm-origin-it {
  background: #eaf4ec;
  border-color: #98bfa1;
  color: #245f3a;
}

.norm-object-sub {
  margin-top: 0.04rem;
  font-size: inherit;
  font-weight: inherit;
  color: inherit;
}

.norm-toggle {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: #124c64;
  font-size: 0.75rem;
  font-weight: 700;
  text-align: left;
  box-shadow: none;
}

.norm-toggle > span:first-child {
  min-width: 0;
}

.norm-toggle:hover {
  background: transparent;
  color: #0b3d4f;
  transform: none;
}

.norm-chevron {
  font-size: 0.72rem;
  color: #325c6b;
  line-height: 1;
  transition: transform 130ms ease;
}

.norm-toggle[aria-expanded="true"] .norm-chevron {
  transform: rotate(180deg);
}

.norm-detail-list {
  display: grid;
  gap: 0.22rem;
  justify-items: center;
  text-align: center;
}

.norm-detail-list[hidden] {
  display: none;
}

.norm-child-row td {
  background: transparent;
}

.norm-parent-open td,
.norm-child-row.norm-child-open td {
  background: #eaf4f8;
}

.norm-child-row .norm-child-source-cell,
.norm-child-row .norm-detail-cell,
.norm-child-row .norm-concept-cell {
  padding-top: 0.32rem;
  padding-bottom: 0.32rem;
}

.norm-child-row .norm-child-source-cell {
  padding-left: 0.52rem;
  text-align: left;
}

.norm-child-row .norm-child-article-cell {
  text-align: center;
}

.norm-matrix td a {
  color: #124c64;
  font-weight: 400;
}

.norm-art-break {
  display: block;
  line-height: 1.18;
}

.norm-matrix td a:hover {
  color: #0b3d4f;
}

.norm-detail-inline {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.42rem;
  width: 100%;
  max-width: 100%;
}

.norm-detail-source-box {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.norm-detail-source-title {
  font-size: 0.66rem;
  letter-spacing: 0.015em;
  text-transform: none;
  color: #2f5667;
  font-weight: 700;
  white-space: nowrap;
}

.norm-source-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  min-height: 22px;
  border-radius: 999px;
  border: 1px solid #acc3d2;
  background: #edf5fa;
  color: #15495f;
  font-size: 0.62rem;
  font-weight: 700;
  line-height: 1;
  padding: 0.12rem 0.3rem;
  white-space: nowrap;
}

.norm-source-btn.is-official {
  background: #e9f4f1;
  border-color: #a2c5bc;
}

.norm-source-btn.is-annotated {
  background: #f2f6fa;
  border-color: #b6cad7;
}

.norm-source-btn.is-editor {
  background: #f7f2ea;
  border-color: #d5bda3;
  color: #6f4723;
  min-width: 28px;
  padding: 0.1rem 0.22rem;
}

.norm-source-btn:hover {
  transform: none;
  filter: brightness(0.97);
}

.norm-link-light {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.14);
  flex-shrink: 0;
}

.norm-link-light.is-green {
  background: #28a263;
}

.norm-link-light.is-red {
  background: #c94a42;
}

.norm-source-workspace {
  margin-top: 0.56rem;
  border: 1px solid #b8ced9;
  border-radius: 11px;
  background: #f7fcff;
  padding: 0.5rem;
  display: grid;
  gap: 0.45rem;
}

.norm-source-workspace-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.norm-source-workspace-head h3 {
  margin: 0;
  font-size: 0.86rem;
  color: #184a5f;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.norm-source-workspace-close {
  min-height: 28px;
  border-radius: 8px;
  border: 1px solid #b9ccd8;
  background: #eef4f8;
  color: #1e4f63;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.18rem 0.55rem;
}

.norm-source-workspace-close:hover {
  transform: none;
  background: #e4edf3;
}

.norm-source-workspace-note {
  margin: 0;
  color: #31596a;
  font-size: 0.76rem;
}

.norm-source-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 0.46rem;
}

.norm-source-card {
  border: 1px solid #c6d8e2;
  border-radius: 10px;
  background: #ffffff;
  padding: 0.45rem 0.5rem 0.52rem;
  display: grid;
  gap: 0.34rem;
}

.norm-source-card-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 0.4rem;
}

.norm-source-card-title {
  margin: 0;
  color: #143f53;
  font-size: 0.82rem;
  line-height: 1.22;
}

.norm-source-card-kind {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  border-radius: 999px;
  border: 1px solid #b7ccd8;
  background: #edf5fa;
  color: #1b4c61;
  font-size: 0.66rem;
  font-weight: 700;
  padding: 0.06rem 0.42rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.norm-source-card-kind.is-official {
  background: #e7f3ef;
  border-color: #a7c8be;
}

.norm-source-card-kind.is-annotated {
  background: #eff4f8;
  border-color: #b9ccd8;
}

.norm-source-card-close {
  border: none;
  background: transparent;
  color: #446877;
  font-size: 1rem;
  line-height: 1;
  padding: 0 0.1rem;
}

.norm-source-card-close:hover {
  transform: none;
  color: #1f4f63;
}

.norm-source-card-meta {
  margin: 0;
  color: #2f5565;
  font-size: 0.73rem;
  line-height: 1.3;
}

.norm-source-card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  margin: 0;
  color: #2b5667;
  font-size: 0.72rem;
}

.norm-source-card-disclaimer {
  margin: 0;
  border: 1px solid #e4c7ad;
  background: #fff4e8;
  color: #8b4f1f;
  border-radius: 8px;
  padding: 0.26rem 0.38rem;
  font-size: 0.71rem;
  font-weight: 600;
  line-height: 1.28;
}

.norm-source-card-hint {
  margin: 0;
  border: 1px solid #c9d9e4;
  background: #f1f8fc;
  color: #2d5b6e;
  border-radius: 8px;
  padding: 0.24rem 0.38rem;
  font-size: 0.71rem;
  font-weight: 600;
  line-height: 1.28;
}

.norm-source-textarea {
  width: 100%;
  min-height: 172px;
  border: 1px solid #b8ccd8;
  border-radius: 9px;
  background: #fafdff;
  color: #153f51;
  font-size: 0.75rem;
  line-height: 1.35;
  padding: 0.44rem 0.52rem;
  resize: vertical;
  font-family: "IBM Plex Sans", sans-serif;
}

.norm-source-textarea.is-readonly {
  background: #f5f9fc;
}

.norm-source-card-actions {
  display: flex;
  justify-content: end;
}

.norm-source-save-btn {
  min-height: 30px;
  border-radius: 8px;
  border: 1px solid #0e7a6b;
  background: #118a70;
  color: #ffffff;
  font-size: 0.73rem;
  font-weight: 700;
  padding: 0.22rem 0.62rem;
}

.norm-source-save-btn:hover {
  transform: none;
  background: #0f7762;
}

.norm-weight-open-btn {
  all: unset;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.22rem;
  width: auto;
  min-height: 26px;
  padding: 0.1rem 0.18rem;
  position: relative;
  left: -1px;
  font: inherit;
  color: #124c64;
  text-transform: inherit;
  letter-spacing: inherit;
  border: 1px solid #aac1cf;
  border-radius: 8px;
  background: #eef5f9;
  box-shadow: inset 0 1px 0 #ffffff;
}

.norm-weight-open-btn:hover {
  color: #0b3d4f;
  border-color: #89a9bb;
  background: #e4eef4 !important;
  box-shadow: inset 0 1px 0 #f8fcff;
  transform: none !important;
}

.norm-weight-open-btn:active {
  background: #dbe8f0 !important;
}

.norm-weight-open-btn:focus-visible {
  outline: 2px solid rgba(15, 122, 111, 0.35);
  outline-offset: 1px;
  border-radius: 8px;
}

.weight-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1500;
  background: rgba(10, 34, 48, 0.42);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.weight-modal-backdrop[hidden] {
  display: none !important;
}

.weight-modal {
  width: min(1020px, 96vw);
  max-height: 90vh;
  border: 1px solid #9cb9c9;
  border-radius: 14px;
  background: #f6fbff;
  box-shadow: 0 20px 44px rgba(10, 32, 47, 0.28);
  display: grid;
  gap: 0.6rem;
  padding: 0.8rem 0.82rem 0.7rem;
  color: #173f52;
}

.add-source-modal {
  width: min(1120px, 96vw);
}

.source-editor-modal {
  width: min(980px, 92vw);
}

.source-editor-kind-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.source-editor-kind-btn {
  min-height: 30px;
  border-radius: 999px;
  border: 1px solid #a8c0cf;
  background: #edf5fa;
  color: #1d4f63;
  font-size: 0.73rem;
  font-weight: 700;
  padding: 0.18rem 0.66rem;
}

.source-editor-kind-btn.active {
  border-color: #0f7f6d;
  background: #e8f4f0;
  color: #105747;
}

.source-editor-textarea {
  min-height: min(54vh, 520px);
}

.source-editor-actions {
  display: flex;
  justify-content: end;
}

.weight-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
}

.weight-modal-head h3 {
  margin: 0;
  font-size: 0.98rem;
  color: #12495f;
}

.weight-modal-close {
  min-height: 34px;
  padding: 0.38rem 0.72rem;
  border: 1px solid #8eacbd;
  border-radius: 999px;
  background: #e8f2f8;
  color: #164a5f;
  font-size: 0.76rem;
  font-weight: 700;
  box-shadow: none;
}

.weight-modal-close:hover {
  transform: none;
  background: #dbeaf3;
  border-color: #789db0;
}

.weight-modal-subtitle {
  margin: 0;
  color: #2d586b;
  font-size: 0.8rem;
}

.weight-filter-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 0.36rem;
}

.weight-filter-btn {
  min-height: 30px;
  padding: 0.3rem 0.64rem;
  border: 1px solid #89aabc;
  border-radius: 999px;
  background: #e9f3f9;
  color: #124b62;
  font-size: 0.72rem;
  font-weight: 700;
  box-shadow: none;
}

.weight-filter-btn:hover {
  transform: none;
  background: #dbeaf4;
  border-color: #7098af;
}

.weight-filter-btn.active {
  border-color: #0b6654;
  background: linear-gradient(140deg, #118a70, #0d725b);
  color: #ffffff;
}

.weight-modal-table-wrap {
  border: 1px solid #b8ced9;
  border-radius: 10px;
  overflow: auto;
  max-height: 62vh;
  background: #ffffff;
}

.weight-modal-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.weight-modal-table th,
.weight-modal-table td {
  border-bottom: 1px solid #d7e5ee;
  padding: 0.38rem 0.42rem;
  vertical-align: top;
  font-size: 0.74rem;
}

.weight-modal-table th {
  background: #e8f3fa;
  color: #15485d;
  font-weight: 700;
  text-align: left;
}

.weight-modal-table th:nth-child(1),
.weight-modal-table td:nth-child(1) {
  width: 7%;
  text-align: center;
}

.weight-modal-table th:nth-child(2),
.weight-modal-table td:nth-child(2) {
  width: 12%;
}

.weight-modal-table th:nth-child(3),
.weight-modal-table td:nth-child(3) {
  width: 24%;
}

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

.weight-modal-table th:nth-child(5),
.weight-modal-table td:nth-child(5) {
  width: 29%;
}

.weight-modal-table th:nth-child(6),
.weight-modal-table td:nth-child(6) {
  width: 8%;
  text-align: center;
}

.weight-modal-weight {
  font-size: 1.05rem;
  line-height: 1;
}

.weight-modal-note-2 {
  display: block;
  margin-top: 0.06rem;
  color: #335f73;
}

.weight-go-btn {
  min-height: 28px;
  border: 1px solid #7fa3b7;
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  background: #e8f2f8;
  color: #12495f;
  font-size: 0.7rem;
  font-weight: 700;
  box-shadow: none;
}

.weight-go-btn:hover {
  transform: none;
  background: #d8e9f3;
  border-color: #6994aa;
}

.weight-modal-empty {
  padding: 0.8rem;
  text-align: center;
  font-size: 0.78rem;
  color: #31596b;
}

.add-source-form {
  display: grid;
  gap: 0.55rem;
}

.add-source-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.42rem;
}

.add-source-grid label {
  display: grid;
  gap: 0.22rem;
  color: #2b5568;
  font-size: 0.72rem;
  font-weight: 600;
}

.add-source-grid input,
.add-source-grid select {
  min-height: 32px;
  border: 1px solid #9ab6c7;
  border-radius: 8px;
  padding: 0 0.42rem;
  color: #154c62;
  background: #f4f9fd;
  font-size: 0.73rem;
}

.add-source-details-box {
  border: 1px solid #bfd2df;
  border-radius: 10px;
  padding: 0.45rem;
  background: #f9fcff;
  display: grid;
  gap: 0.4rem;
}

.add-source-details-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.add-source-details-head h4 {
  margin: 0;
  color: #1d4d63;
  font-size: 0.8rem;
}

.add-details-list {
  display: grid;
  gap: 0.36rem;
}

.add-detail-row {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 2fr 2fr 2fr 1fr auto;
  gap: 0.3rem;
  align-items: center;
}

.add-detail-row input,
.add-detail-row select {
  min-height: 30px;
  border: 1px solid #a1bbcb;
  border-radius: 8px;
  padding: 0 0.38rem;
  font-size: 0.72rem;
  color: #164b60;
  background: #f5faff;
}

.add-detail-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.26rem;
}

.add-detail-upload {
  min-height: 30px;
  border: 1px solid #9bb4c3;
  border-radius: 999px;
  background: #edf5fa;
  color: #285d72;
  padding: 0.2rem 0.5rem;
  font-size: 0.7rem;
  font-weight: 700;
  box-shadow: none;
}

.add-detail-upload:hover {
  transform: none;
  background: #deebf3;
  border-color: #7ba0b2;
}

.add-detail-remove {
  min-height: 30px;
  border: 1px solid #9bb4c3;
  border-radius: 999px;
  background: #edf5fa;
  color: #285d72;
  padding: 0.2rem 0.5rem;
  font-size: 0.7rem;
  font-weight: 700;
  box-shadow: none;
}

.add-detail-remove:hover {
  transform: none;
  background: #deebf3;
  border-color: #7ba0b2;
}

.add-source-actions {
  display: flex;
  justify-content: flex-end;
}

.add-source-status {
  margin: 0;
  border-radius: 8px;
  padding: 0.34rem 0.5rem;
  font-size: 0.73rem;
  font-weight: 600;
}

.add-source-status.ok {
  background: #e8f6ef;
  color: #226847;
  border: 1px solid #a8d3b7;
}

.add-source-status.err {
  background: #fdecec;
  color: #8e2f2f;
  border: 1px solid #dfb3b3;
}

.norm-jump-highlight td {
  background: #dbecf7 !important;
}

body.weight-modal-open {
  overflow: hidden;
}

.panel {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--panel);
  padding: 0.95rem;
}

.panel h2 {
  margin: 0;
  font-size: 1.05rem;
}

.panel-sub {
  margin: 0.2rem 0 0;
  font-size: 0.88rem;
  color: var(--ink-soft);
}

.catalog-status {
  margin: 0.45rem 0 0;
  font-size: 0.82rem;
  color: #234958;
  font-weight: 600;
}

.catalog-status.ok {
  color: #226a45;
}

.catalog-status.err {
  color: #9a352a;
}

.role-panel {
  display: grid;
  gap: 0.7rem;
}

.role-buttons {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
}

button,
input,
textarea {
  font-family: "IBM Plex Sans", sans-serif;
}

button {
  border: none;
  border-radius: 11px;
  padding: 0.65rem 0.8rem;
  background: var(--brand);
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  transition: transform 120ms ease, background 120ms ease;
}

button:hover {
  transform: translateY(-1px);
  background: var(--brand-strong);
}

button:disabled {
  cursor: not-allowed;
  transform: none;
}

.role {
  min-height: 42px;
}

.role-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.role.active {
  background: linear-gradient(130deg, #0f7d67, #0c6b58);
}

.role.disabled {
  background: #dce4e8;
  color: #4a5f68;
}

.role.disabled:hover {
  background: #d0dbe0;
}

.upload-panel {
  display: grid;
  gap: 0.85rem;
}

.concessionario-shell {
  width: min(1600px, 97vw);
  margin: 0.45rem auto 1.2rem;
}

.concessionario-hero {
  padding: 0.82rem 0.92rem 0.98rem;
}

.concessionario-focus {
  grid-template-columns: minmax(220px, 0.78fr) minmax(0, 2.35fr);
  gap: 0.65rem;
  align-items: start;
}

.concessionario-left {
  gap: 0.46rem;
}

.concessionario-back-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: end;
  margin-right: 0.04rem;
  width: fit-content;
  min-height: 40px;
  min-width: 40px;
  padding: 0;
  text-decoration: none;
  line-height: 1;
  font-size: 2rem;
  color: #0f6d61;
  background: transparent;
  border: none;
}

.concessionario-finish-link {
  justify-self: stretch;
  width: 100%;
  min-width: 0;
  min-height: 42px;
  padding: 0.45rem 0.6rem;
  border: 2px solid #8d2118;
  border-radius: 10px;
  background: #c0392b;
  color: #ffffff;
  box-shadow: 0 3px 0 rgba(117, 26, 18, 0.78), 0 10px 20px rgba(117, 26, 18, 0.16);
  cursor: pointer;
  font-size: 0.92rem;
  line-height: 1.15;
  font-weight: 800;
  text-align: center;
  letter-spacing: 0;
}

.concessionario-finish-link:hover {
  background: #a82f24;
  color: #ffffff;
  transform: translateY(-1px);
}

.concessionario-finish-link:active {
  transform: translateY(1px);
  box-shadow: 0 1px 0 rgba(117, 26, 18, 0.86), 0 5px 12px rgba(117, 26, 18, 0.14);
}

.concessionario-back-link:hover {
  color: #0b5a51;
}

.concessionario-back-link.concessionario-finish-link:hover {
  color: #ffffff;
}

.concessionario-back-link:focus-visible {
  outline: 2px solid rgba(15, 109, 97, 0.35);
  outline-offset: 2px;
  border-radius: 6px;
}

.anagrafica-nav-btn {
  min-height: 40px;
  width: 100%;
  display: inline-flex;
  position: relative;
  align-items: center;
  justify-content: center;
  border: 1px solid #8fb0c3;
  border-radius: 10px;
  background: #e7f0f7;
  color: #124c64;
  font-weight: 700;
  font-size: 0.9rem;
  text-align: center;
  padding: 0.45rem 0.58rem;
  letter-spacing: 0.005em;
}

.anagrafica-nav-emoji {
  position: absolute;
  left: 0.64rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2.2rem;
  line-height: 1;
  font-family: "Segoe UI Emoji", "Noto Color Emoji", "Apple Color Emoji", sans-serif;
}

.anagrafica-nav-label {
  display: block;
  width: 100%;
  text-align: center;
}

.anagrafica-nav-btn:hover {
  transform: none;
  background: #d8e7f1;
  border-color: #7da4ba;
}

.anagrafica-nav-btn.active {
  border-color: #0b6654;
  background: linear-gradient(140deg, #118a70, #0d725b);
  color: #ffffff;
}

.concessionario-sections-card {
  border: 1px solid #b9ccda;
  border-radius: 11px;
  background: #f6f9fc;
  box-shadow: inset 0 1px 0 #ffffff, 0 1px 0 #e5edf3;
  padding: 0.5rem;
  display: grid;
  gap: 0.42rem;
  align-content: start;
}

.concessionario-practice-card {
  border: 1px solid #b9ccda;
  border-radius: 11px;
  background: #f6f9fc;
  box-shadow: inset 0 1px 0 #ffffff, 0 1px 0 #e5edf3;
  padding: 0.5rem;
  display: grid;
  gap: 0.42rem;
  align-content: start;
}

.practice-switch-btn {
  min-height: 40px;
  border: 1px solid #9bb6c7;
  border-radius: 9px;
  background: #e8f1f7;
  color: #164c63;
  font-weight: 700;
  font-size: 0.84rem;
  letter-spacing: 0.01em;
}

.practice-switch-btn:hover {
  background: #dce9f2;
  border-color: #86a9bd;
}

.concessionario-sections-title {
  margin: 0;
  padding: 0.34rem 0.5rem;
  font-size: 0.94rem;
  color: #f4faff;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  text-align: center;
  border: 1px solid #2a5f78;
  border-radius: 8px;
  background: #2e6c88;
}

.concessionario-anagrafica-block {
  display: grid;
  gap: 0.34rem;
  margin-bottom: 0.16rem;
  border: 2px solid #4a7f99;
  border-radius: 10px;
  background: #f8fbfd;
  padding: 0.36rem;
}

.section-nav-list {
  display: grid;
  gap: 0.52rem;
}

.section-nav-item {
  display: grid;
  gap: 0.18rem;
  border: 2px solid #4a7f99;
  border-radius: 10px;
  background: #f8fbfd;
  padding: 0.42rem 0.4rem 0.5rem;
  transition: border-color 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

.section-nav-item.is-active {
  border-color: #4a7f99;
  background: #f8fbfd;
  box-shadow: none;
}

.section-nav-btn {
  width: 100%;
  min-height: 38px;
  display: inline-flex;
  position: relative;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 0.45rem 0.58rem;
  border-radius: 9px;
  border: 1px solid #a7bfce;
  background: #ecf3f8;
  color: #124c64;
  font-weight: 700;
  font-size: 0.83rem;
  line-height: 1.2;
}

.section-nav-emoji {
  position: absolute;
  left: 0.64rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2.2rem;
  line-height: 1;
  font-family: "Segoe UI Emoji", "Noto Color Emoji", "Apple Color Emoji", sans-serif;
}

.section-nav-label {
  display: block;
  width: 100%;
  text-align: center;
}

.section-nav-btn:hover {
  transform: none;
  background: #dfeaf3;
  border-color: #8fb0c3;
}

.section-nav-btn.active {
  border-color: #0b6654;
  background: linear-gradient(140deg, #118a70, #0d725b);
  color: #ffffff;
}

.section-nav-meta {
  font-size: 0.76rem;
  color: #2a4f5e;
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.26rem;
  padding: 0.08rem 0.1rem 0.12rem;
}

.section-nav-progress {
  width: 100%;
  height: 4px;
  border-radius: 999px;
  background: #dc6f60;
  overflow: hidden;
}

.section-nav-progress-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #cf3d2a;
  transition: width 180ms ease-out;
}

.section-nav-empty {
  margin: 0;
  font-size: 0.8rem;
  color: #3a5b67;
}

.comune-document-monitor-panel[hidden] {
  display: none !important;
}

.comune-document-monitor-panel {
  display: grid;
  gap: 0.75rem;
}

.comune-upload-dashboard-panel[hidden] {
  display: none !important;
}

#comunePracticeContextPanel[hidden],
#comuneSnapshotPanel[hidden] {
  display: none !important;
}

.comune-upload-dashboard-panel {
  display: grid;
  gap: 0.72rem;
}

.comune-dashboard-summary {
  display: grid;
}

.comune-dashboard-summary-card {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.45rem;
  padding: 0.72rem;
  border: 1px solid #b7cad8;
  border-radius: 8px;
  background: #f5fafd;
}

.comune-dashboard-summary-card div {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.comune-dashboard-summary-card strong {
  color: #0c5566;
  font-size: 1.18rem;
}

.comune-dashboard-summary-card span {
  color: #355967;
  font-size: 0.82rem;
}

.comune-dashboard-sortbar {
  display: grid;
  grid-template-columns: repeat(3, minmax(150px, 1fr));
  gap: 0.45rem;
  align-items: end;
  padding: 0.58rem;
  border: 1px solid #cbb67f;
  border-radius: 8px;
  background: #fffdf7;
}

.comune-dashboard-sortbar label {
  display: grid;
  gap: 0.22rem;
  color: #6f521c;
  font-size: 0.78rem;
  font-weight: 800;
}

.comune-dashboard-sortbar select {
  min-height: 34px;
  border: 1px solid #b6873b;
  border-radius: 8px;
  padding: 0 0.5rem;
  background: #ffffff;
  color: #153b4b;
  font: inherit;
  font-weight: 700;
}

.comune-dashboard-table-wrap {
  overflow-x: auto;
  border: 1px solid #bdd0dc;
  border-radius: 8px;
  background: #ffffff;
}

.comune-dashboard-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 900px;
  font-size: 0.84rem;
}

.comune-dashboard-table th,
.comune-dashboard-table td {
  padding: 0.52rem 0.58rem;
  border-bottom: 1px solid #d9e7ef;
  text-align: left;
  vertical-align: middle;
}

.comune-dashboard-table th {
  color: #063e54;
  background: #e7f1f7;
  font-weight: 800;
}

.comune-dashboard-table tbody tr:last-child td {
  border-bottom: none;
}

.comune-dashboard-row-ok {
  background: #f2fbf6;
}

.comune-dashboard-row-warn {
  background: #fffaf0;
}

.comune-dashboard-row-bad {
  background: #fff4f2;
}

.comune-dashboard-progress {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: #dc6f60;
  overflow: hidden;
  margin-bottom: 0.22rem;
}

.comune-dashboard-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #2f8f5a;
}

.comune-dashboard-table small {
  display: block;
  color: #466775;
  font-size: 0.76rem;
}

.comune-dashboard-detail-btn {
  min-height: 32px;
  padding: 0.28rem 0.62rem;
  font-size: 0.78rem;
}

.comune-document-summary {
  display: grid;
}

.comune-document-summary-card {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.35rem 0.7rem;
  align-items: center;
  padding: 0.72rem;
  border: 1px solid #b7cad8;
  border-radius: 8px;
  background: #f5fafd;
}

.comune-document-summary-card div {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.comune-document-summary-card strong {
  color: #0c5566;
  font-size: 1.18rem;
}

.comune-document-summary-card span {
  color: #355967;
  font-size: 0.82rem;
}

.comune-document-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
}

.comune-document-toolbar[hidden] {
  display: none !important;
}

.comune-document-toolbar .secondary-btn {
  min-height: 34px;
  padding: 0.32rem 0.7rem;
  font-size: 0.8rem;
}

.comune-document-sections {
  display: grid;
  gap: 0.7rem;
}

.comune-document-section {
  border: 1px solid #9fbed0;
  border-radius: 8px;
  background: #ffffff;
  overflow: hidden;
}

.comune-document-section-head {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 0.62rem 0.72rem;
  color: #0d465c;
  background: #e7f1f7;
  font-weight: 700;
}

.comune-document-section-title {
  flex: 1 1 auto;
  min-width: 0;
}

.comune-document-section-count {
  flex: 0 0 auto;
  color: #315b69;
  font-size: 0.82rem;
}

.comune-document-section-toggle {
  flex: 0 0 auto;
}

.comune-document-progress {
  margin: 0.45rem 0.72rem 0;
}

.comune-document-row-list {
  display: grid;
  gap: 0.5rem;
  padding: 0.7rem;
}

.comune-document-row {
  display: grid;
  gap: 0.32rem;
  padding: 0.58rem 0.65rem;
  border: 1px solid #c0d3dd;
  border-left-width: 5px;
  border-radius: 8px;
  background: #fbfdff;
}

.comune-document-row summary::-webkit-details-marker,
.comune-document-section summary::-webkit-details-marker {
  display: none;
}

.comune-document-row.is-complete {
  border-left-color: #2f8f5a;
}

.comune-document-row.is-missing {
  border-left-color: #bf3d31;
}

.comune-document-row-head {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  justify-content: space-between;
  cursor: pointer;
}

.comune-document-row-head div {
  display: grid;
  gap: 0.14rem;
}

.comune-document-row-head strong {
  color: #0b4b63;
  font-family: "IBM Plex Mono", monospace;
}

.comune-document-row-head span {
  color: #1b4050;
}

.comune-document-chip-list {
  display: inline-flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.25rem;
}

.comune-document-chip {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 0.16rem 0.48rem;
  font-size: 0.76rem;
  font-weight: 700;
}

.comune-document-chip.ok {
  background: #e5f7ed;
  color: #1f704a;
}

.comune-document-chip.warn {
  background: #fff0ee;
  color: #a73327;
}

.comune-document-chip.info {
  background: #e8f1fa;
  color: #215a78;
}

.comune-document-row-meta {
  margin: 0;
  color: #496775;
  font-size: 0.82rem;
}

.comune-document-row-detail {
  display: grid;
  gap: 0.45rem;
  padding-top: 0.18rem;
}

.comune-document-annotation {
  display: grid;
  gap: 0.3rem;
  border: 1px solid #c5d8e1;
  border-radius: 8px;
  background: #f4f9fc;
  padding: 0.5rem 0.58rem;
}

.comune-document-annotation strong {
  color: #0f4d63;
}

.comune-document-annotation p {
  margin: 0;
  color: #365d6d;
}

.comune-document-annotation dl {
  margin: 0;
  display: grid;
  grid-template-columns: minmax(160px, 0.34fr) minmax(0, 1fr);
  gap: 0.24rem 0.5rem;
}

.comune-document-annotation dt {
  color: #345b6b;
  font-weight: 700;
}

.comune-document-annotation dd {
  margin: 0;
  color: #173f50;
}

.comune-document-file-list {
  margin: 0;
  padding-left: 1rem;
  display: grid;
  gap: 0.25rem;
  color: #2d5364;
  font-size: 0.84rem;
}

.comune-document-file-list li {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #e1edf3;
  padding-top: 0.25rem;
}

.comune-document-file-list a {
  flex: 0 0 auto;
  color: #0f6a6f;
  font-weight: 700;
  text-decoration: none;
}

.comune-document-file-list a:hover {
  text-decoration: underline;
}

.concessionario-main {
  display: grid;
  gap: 0.58rem;
  align-content: start;
}

.concessionario-main .panel {
  padding: 0.72rem 0.82rem;
  border-radius: 14px;
}

.concessionario-main .panel[hidden],
.concessionario-main .anagrafica-panel[hidden],
.concessionario-main .upload-panel[hidden],
.concessionario-main #logPanel[hidden],
.concessionario-main #catalogStatusWrap[hidden],
.concessionario-main #debugIdentityControls[hidden] {
  display: none !important;
}

.anagrafica-panel {
  display: grid;
  gap: 0.55rem;
}

.anagrafica-head {
  display: grid;
  gap: 0.12rem;
}

.anagrafica-head h2 {
  margin: 0;
  font-size: 1.02rem;
}

.anagrafica-sub {
  margin: 0;
  color: #355b6b;
  font-size: 0.82rem;
}

.anagrafica-panel .catalog-status {
  margin: 0;
}

.anagrafica-panel .catalog-status.ok {
  color: #1f6a46;
}

.anagrafica-panel .catalog-status.err {
  color: #9a372b;
}

.anagrafica-form {
  display: grid;
  gap: 0.5rem;
}

.anagrafica-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.42rem;
}

.anagrafica-grid label,
.anagrafica-form > label {
  display: grid;
  gap: 0.2rem;
  color: #2f5566;
  font-size: 0.78rem;
}

.anagrafica-grid input,
.anagrafica-grid select,
.anagrafica-grid textarea,
.anagrafica-form > label input,
.anagrafica-form > label textarea {
  min-height: 34px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0.35rem 0.5rem;
  color: #163d4f;
  background: #f8fcff;
  font-size: 0.8rem;
}

.anagrafica-grid textarea,
.anagrafica-form > label textarea {
  resize: vertical;
}

.anagrafica-grid .span-2 {
  grid-column: span 2;
}

.anagrafica-grid .span-4 {
  grid-column: 1 / -1;
}

.anagrafica-block {
  border: 1px solid #c8d9e3;
  border-radius: 10px;
  padding: 0.45rem 0.5rem;
  background: #fbfdff;
  display: grid;
  gap: 0.36rem;
}

.anagrafica-block h3 {
  margin: 0;
  font-size: 0.86rem;
  color: #1a4d62;
}

.anagrafica-block-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.anagrafica-inline-btn {
  min-height: 30px;
  padding: 0.28rem 0.56rem;
  border-radius: 8px;
  border: 1px solid #9ab7c8;
  background: #eff6fb;
  color: #17475c;
  font-size: 0.75rem;
  font-weight: 700;
}

.anagrafica-inline-btn:hover {
  background: #dcecf7;
}

.anagrafica-hint {
  margin: 0;
  color: #355b6b;
  font-size: 0.76rem;
}

.anagrafica-contact-warning {
  margin: 0;
  padding: 0.3rem 0.42rem;
  border: 1px solid #d7b79d;
  border-radius: 8px;
  background: #fff6ea;
  color: #874d1c;
  font-size: 0.75rem;
  line-height: 1.35;
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
}

.anagrafica-contact-warning-btn {
  min-height: 26px;
  padding: 0.18rem 0.48rem;
  border: 1px solid #c68d5f;
  border-radius: 7px;
  background: #ffe8cf;
  color: #6a3a12;
  font-size: 0.73rem;
  font-weight: 700;
}

.anagrafica-contact-warning-btn:hover {
  background: #ffdcb3;
}

.anagrafica-contacts-list {
  display: grid;
  gap: 0.42rem;
}

.anagrafica-contact-card {
  border: 1px solid #bfd1dd;
  border-radius: 9px;
  background: #f7fbff;
  padding: 0.4rem 0.46rem;
  display: grid;
  gap: 0.34rem;
}

.anagrafica-contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr auto;
  gap: 0.38rem;
  align-items: end;
}

.anagrafica-contact-grid label {
  display: grid;
  gap: 0.18rem;
  color: #2f5566;
  font-size: 0.76rem;
}

.anagrafica-contact-grid input,
.anagrafica-contact-grid select {
  min-height: 32px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0.3rem 0.46rem;
  color: #163d4f;
  background: #f8fcff;
  font-size: 0.79rem;
}

.anagrafica-contact-remove {
  min-height: 32px;
  padding: 0.34rem 0.56rem;
  border: 1px solid #d7b1ab;
  border-radius: 8px;
  background: #fff3f1;
  color: #9a372b;
  font-size: 0.74rem;
  font-weight: 700;
}

.anagrafica-contact-remove:hover {
  background: #ffe7e4;
}

.anagrafica-contact-note {
  margin: 0;
  color: #5b7382;
  font-size: 0.72rem;
}

.anagrafica-doc-grid {
  margin-top: 0.25rem;
}

.anagrafica-file-meta {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.8rem;
  font-size: 0.75rem;
  color: #355b6b;
}

.anagrafica-file-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0.12rem 0.44rem;
  border: 1px solid #c6d8e1;
  border-radius: 999px;
  background: #f3f9fd;
}

.anagrafica-warning {
  grid-column: 1 / -1;
  margin: 0;
  padding: 0.34rem 0.48rem;
  border: 1px solid #e0bcbc;
  border-radius: 8px;
  background: #fff2f1;
  color: #9a372b;
  font-size: 0.76rem;
  font-weight: 600;
}

.checkbox-inline {
  display: inline-flex !important;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.78rem;
}

.checkbox-inline input[type="checkbox"] {
  width: 15px;
  height: 15px;
}

.anagrafica-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.anagrafica-actions button {
  min-height: 34px;
  padding: 0.45rem 0.75rem;
  font-size: 0.8rem;
}

.test-panel {
  display: grid;
  gap: 0.7rem;
}

.top-nav-panel.top-nav-panel--solo {
  grid-template-columns: 1fr;
  gap: 0.2rem;
  padding-top: 0.56rem;
  padding-bottom: 0.56rem;
  justify-items: center;
}

.top-nav-panel.top-nav-panel--solo .top-nav-text {
  grid-column: 1 / -1;
  width: 100%;
  display: grid;
  justify-items: center;
  text-align: center;
}

.top-nav-panel.top-nav-panel--solo .top-nav-title {
  font-size: 1.14rem;
  width: 100%;
  margin: 0 auto;
  text-align: center;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.top-nav-panel.top-nav-panel--solo .top-nav-sub {
  font-size: 0.86rem;
}

.concessionario-main .test-panel {
  gap: 0.4rem;
}

.practice-context-panel {
  display: grid;
  gap: 0.48rem;
}

.practice-context-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}

.practice-context-head h2 {
  margin: 0;
  font-size: 1.02rem;
}

.practice-context-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.38rem;
}

.practice-context-item {
  border: 1px solid #c8d8e3;
  border-radius: 9px;
  background: #f7fbfe;
  padding: 0.36rem 0.46rem;
  display: grid;
  gap: 0.1rem;
  min-height: 56px;
}

.practice-context-item-wide {
  grid-column: 1 / -1;
}

.ctx-label {
  color: #5e7584;
  font-size: 0.72rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  text-align: center;
}

.ctx-value {
  color: #0f3f57;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.26;
  word-break: break-word;
  text-align: center;
}

.practice-context-item-wide .ctx-value {
  text-align: center;
}

#ctxConcessionario {
  display: block;
  text-align: center;
  font-size: clamp(1.64rem, 2.5vw, 2rem);
  line-height: 1.12;
  font-weight: 500;
}

.test-head-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.65rem;
}

.test-head-tools {
  display: inline-flex;
  align-items: center;
  gap: 0.44rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.test-role-label {
  color: #285367;
  font-size: 0.75rem;
  font-weight: 700;
  white-space: nowrap;
}

.test-role-select {
  min-height: 30px;
  border: 1px solid #93b0c2;
  border-radius: 8px;
  padding: 0 0.44rem;
  background: #eef5fa;
  color: #13485e;
  font-size: 0.76rem;
  font-weight: 600;
}

.test-head-row h2 {
  margin: 0;
  font-size: 1.08rem;
  line-height: 1.15;
}

.test-head-note {
  margin: 0;
  color: #285367;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}

.concessionario-main .test-grid {
  gap: 0.4rem;
}

.concessionario-main .test-grid label {
  gap: 0.22rem;
  font-size: 0.8rem;
}

.concessionario-main .test-grid input,
.concessionario-main .test-grid select {
  height: 36px;
  border-radius: 9px;
  padding: 0 0.55rem;
}

.concessionario-main .test-actions {
  gap: 0.35rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.concessionario-main .test-actions button {
  min-height: 36px;
  padding: 0.5rem 0.66rem;
  font-size: 0.84rem;
}

.concessionario-main .catalog-status {
  margin: 0.16rem 0 0;
}

.test-active-practice-info {
  margin: 0;
  padding: 0.42rem 0.52rem;
  border: 1px solid #c9d9e3;
  border-radius: 9px;
  background: #f6fbff;
  color: #204c60;
  font-size: 0.8rem;
}

.concessionario-main .test-list {
  gap: 0.34rem;
}

.concessionario-main .test-list li {
  padding: 0.45rem 0.55rem;
  gap: 0.4rem;
}

.concessionario-main .test-item-main {
  gap: 0.08rem;
}

.concessionario-main .test-item-title {
  font-size: 0.86rem;
}

.concessionario-main .test-item-meta {
  font-size: 0.76rem;
}

.concessionario-main .test-item-actions button {
  padding: 0.38rem 0.52rem;
  font-size: 0.75rem;
}

.concessionario-main .panel-head {
  gap: 0.58rem;
}

.concessionario-main .panel-sub {
  margin-top: 0.12rem;
  font-size: 0.84rem;
}

.concessionario-main .controls {
  gap: 0.45rem;
}

.concessionario-main .controls label {
  gap: 0.24rem;
  font-size: 0.8rem;
  text-align: center;
}

.concessionario-main .controls .id-static-value {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 0.44rem 0.34rem;
  background: #f4f9fc;
  color: #173949;
  font-size: 0.75rem;
  line-height: 1.12;
  text-align: center;
  font-family: "IBM Plex Mono", monospace;
  letter-spacing: -0.018em;
  white-space: nowrap;
  cursor: default;
  user-select: text;
}

.perito-shell {
  width: min(1640px, 97vw);
}

.perito-back-link {
  min-height: 34px;
  min-width: 54px;
  padding: 0.3rem 0.44rem;
  font-size: 0.76rem;
  font-weight: 700;
  border: 1px solid #9eb7c6;
  border-radius: 9px;
  background: #edf4f9;
  color: #1b4d63;
  line-height: 1.1;
}

.perito-back-link:hover {
  background: #e0ebf3;
  color: #123f53;
}

.comune-exit-link {
  cursor: pointer;
  min-width: 72px;
  width: auto;
  padding: 0.35rem 0.72rem;
  background: #657c8a;
  color: #ffffff;
  border-color: #506775;
}

.comune-exit-link:hover {
  background: #526a78;
  color: #ffffff;
}

.perito-main {
  gap: 0.66rem;
}

.perito-side-card {
  gap: 0.48rem;
}

.perito-side-note {
  margin: 0;
  line-height: 1.34;
  color: #2f5668;
}

.perito-side-generate {
  min-height: 36px;
  font-size: 0.82rem;
}

.perito-selection-panel {
  display: grid;
  gap: 0.46rem;
}

.perito-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.45rem;
}

.perito-grid .perito-span-2 {
  grid-column: span 2;
}

.comune-practice-choice-field {
  color: #7a5a1f;
  font-weight: 700;
}

.comune-practice-choice-field input[type="search"],
.comune-practice-choice-field select {
  border: 1px solid #b6873b;
  background: #fffdf7;
  box-shadow: 0 0 0 1px rgba(182, 135, 59, 0.12);
}

.comune-practice-choice-field input[type="search"]:focus,
.comune-practice-choice-field select:focus {
  outline: 2px solid rgba(182, 135, 59, 0.24);
  border-color: #9f7228;
}

.perito-grid input[type="search"],
.perito-grid select {
  height: 36px;
  border-radius: 9px;
  padding: 0 0.55rem;
}

.perito-id-value {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 0.44rem 0.34rem;
  background: #f4f9fc;
  color: #173949;
  font-size: 0.74rem;
  line-height: 1.12;
  text-align: center;
  font-family: "IBM Plex Mono", monospace;
  letter-spacing: -0.018em;
  white-space: nowrap;
  cursor: default;
  user-select: text;
}

.perito-actions {
  grid-column: span 2;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.35rem;
}

.perito-actions button {
  min-height: 36px;
  padding: 0.5rem 0.66rem;
  font-size: 0.82rem;
}

.perito-status {
  margin-top: 0.14rem;
}

.perito-editor-panel {
  display: grid;
  gap: 0.52rem;
}

.perito-convalida-layout {
  display: grid;
  grid-template-columns: minmax(270px, 320px) minmax(0, 1fr);
  gap: 0.7rem;
  align-items: start;
}

.perito-convalida-nav {
  display: grid;
  gap: 0.46rem;
}

.perito-convalida-decision-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.36rem;
  align-items: center;
}

.perito-convalida-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  border: 1px solid #a9bfcc;
  border-radius: 999px;
  padding: 0.2rem 0.48rem;
  font-size: 0.77rem;
  font-weight: 700;
  color: #244d5e;
  background: #eef5f9;
}

.perito-convalida-chip.ok {
  border-color: #6bb69a;
  color: #0b6a53;
  background: #e8f7f1;
}

.perito-convalida-chip.alert {
  border-color: #d28f84;
  color: #a33524;
  background: #fff0ec;
}

.perito-convalida-chip.warn {
  border-color: #d8ba72;
  color: #875f0e;
  background: #fff6de;
}

.perito-convalida-chip.pending {
  border-color: #9caeb9;
  color: #4a6170;
  background: #eef3f6;
}

.perito-anomalie-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.4rem 0.7rem;
}

.perito-feedback-toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.4rem 0.7rem;
}

.perito-feedback-right {
  display: grid;
  justify-items: end;
  align-items: start;
  gap: 0.2rem;
  min-width: min(780px, 100%);
}

.perito-feedback-actions {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 0.28rem;
}

.perito-feedback-channel-field {
  display: inline-grid;
  gap: 0.12rem;
  font-size: 0.68rem;
  font-weight: 700;
  color: #2f5870;
  margin-right: 0.12rem;
}

.perito-feedback-channel-field select {
  min-width: 168px;
  min-height: 31px;
  padding: 0.28rem 0.5rem;
  border: 1px solid #9db5c4;
  border-radius: 10px;
  background: #f6fbff;
  color: #123a52;
  font-size: 0.75rem;
  font-weight: 700;
}

.perito-feedback-actions .perito-convalida-btn,
.perito-feedback-actions .secondary-btn {
  min-height: 31px;
  padding: 0.3rem 0.56rem;
  font-size: 0.76rem;
}

.perito-feedback-actions .perito-feedback-regenerate-btn {
  background: #e6c77a;
  border-color: #c59b3a;
  color: #3f2f12;
}

.perito-feedback-actions .perito-feedback-regenerate-btn:hover {
  background: #ddbb67;
  border-color: #b78d30;
  color: #32240c;
}

.perito-feedback-actions .perito-feedback-create-email-btn {
  border-color: #217f83;
  background: #e1f3f4;
  color: #0e4f58;
}

.perito-feedback-actions .perito-feedback-create-email-btn:hover {
  background: #cbeaed;
  border-color: #186f74;
  color: #0a434a;
}

.perito-feedback-actions .perito-feedback-confirm-sent-btn {
  border-color: #2b8a4a;
  background: #e7f6eb;
  color: #15522f;
}

.perito-feedback-actions .perito-feedback-confirm-sent-btn:hover {
  background: #d8f0df;
  border-color: #23753f;
  color: #0f3f23;
}

.perito-feedback-status-inline {
  margin: 0;
  width: 100%;
  text-align: left;
  min-height: 1.2rem;
  white-space: pre-line;
}

.perito-feedback-sender-box {
  width: 100%;
  border: 1px solid #bfd1db;
  border-radius: 10px;
  background: #f2f8fc;
  padding: 0.34rem 0.5rem;
  display: grid;
  gap: 0.14rem;
}

.perito-feedback-sender-line {
  margin: 0;
  font-size: 0.76rem;
  color: #18485f;
}

.perito-feedback-sender-line strong {
  font-weight: 800;
}

#peritoFeedbackSenderEmail.is-missing {
  color: #962f22;
  font-weight: 800;
}

.perito-feedback-sender-meta {
  margin: 0;
  font-size: 0.72rem;
  color: #2d5c72;
}

.perito-feedback-sender-meta.err {
  color: #9c3326;
}

.perito-feedback-sendlog-info {
  margin: 0;
  font-size: 0.7rem;
  color: #3b6376;
}

.perito-feedback-sender-reminder {
  margin: 0;
  font-size: 0.72rem;
  color: #19485f;
}

.perito-feedback-layout {
  display: grid;
  grid-template-columns: minmax(300px, 0.95fr) minmax(0, 1.05fr);
  gap: 0.62rem;
  align-items: start;
}

.perito-feedback-blocks {
  display: grid;
  gap: 0.34rem;
  max-height: 680px;
  overflow: auto;
  padding-right: 0.12rem;
}

.perito-feedback-block {
  border: 1px solid #abc2d0;
  border-radius: 10px;
  background: #f8fcff;
  padding: 0.45rem 0.52rem;
  display: grid;
  gap: 0.24rem;
}

.perito-feedback-block-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.3rem;
}

.perito-feedback-block-main {
  display: inline-flex;
  align-items: baseline;
  min-width: 0;
  gap: 0.42rem;
}

.perito-feedback-block-code {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.73rem;
  color: #2f5a6d;
  background: #edf5fa;
  border: 1px solid #c6d6e0;
  border-radius: 999px;
  padding: 0.08rem 0.42rem;
  white-space: nowrap;
}

.perito-feedback-block-title {
  font-size: 0.84rem;
  font-weight: 700;
  color: #103f55;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.perito-feedback-block-right {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.28rem;
}

.perito-feedback-block-section {
  font-size: 0.72rem;
  color: #46697a;
  white-space: nowrap;
}

.perito-feedback-state {
  border-radius: 999px;
  border: 1px solid #aec2ce;
  padding: 0.14rem 0.5rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.perito-feedback-state.state-open,
.perito-feedback-state.state-excluded {
  border-color: #d89b92;
  background: #fff0ec;
  color: #9f3527;
}

.perito-feedback-state.state-waiting {
  border-color: #d8ba72;
  background: #fff6de;
  color: #875f0e;
}

.perito-feedback-state.state-closed,
.perito-feedback-state.state-selected,
.perito-feedback-state.state-archived {
  border-color: #8ec4ad;
  background: #e9f8f1;
  color: #136543;
}

.perito-feedback-block-meta {
  margin: 0;
  font-size: 0.75rem;
  color: #244f63;
}

.perito-feedback-block-body {
  border: 1px solid #c6d7e2;
  border-radius: 8px;
  background: #ffffff;
  overflow: hidden;
}

.perito-feedback-block-body summary {
  list-style: none;
  cursor: pointer;
  padding: 0.32rem 0.44rem;
  font-size: 0.75rem;
  font-weight: 700;
  color: #1f4f66;
  background: #f6fbff;
}

.perito-feedback-block-body summary::-webkit-details-marker {
  display: none;
}

.perito-feedback-block-body pre {
  margin: 0;
  white-space: pre-wrap;
  padding: 0.35rem 0.44rem 0.44rem;
  font-size: 0.75rem;
  line-height: 1.36;
  color: #183f52;
  background: #ffffff;
  border-top: 1px dashed #cadbe5;
}

.perito-feedback-editor-wrap {
  border: 1px solid #b7cad8;
  border-radius: 10px;
  background: #f5f9fc;
  padding: 0.5rem 0.56rem;
  display: grid;
  gap: 0.36rem;
}

.perito-feedback-field {
  display: grid;
  gap: 0.2rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: #1f4e62;
}

.perito-feedback-field input,
.perito-feedback-field textarea {
  width: 100%;
  border: 1px solid #9fb9c9;
  border-radius: 9px;
  background: #ffffff;
  color: #163f50;
  font-size: 0.82rem;
  font-family: "IBM Plex Sans", sans-serif;
  padding: 0.5rem 0.56rem;
  line-height: 1.38;
}

.perito-feedback-field input {
  min-height: 35px;
}

.perito-feedback-field textarea {
  min-height: 460px;
  resize: vertical;
}

.perito-anomalie-actions {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.28rem;
}

.perito-anomalie-actions .perito-convalida-btn,
.perito-anomalie-actions .secondary-btn {
  min-height: 31px;
  padding: 0.3rem 0.56rem;
  font-size: 0.76rem;
}

.perito-anomalie-filter-active {
  border-color: #6f9db4 !important;
  background: #dcecf5 !important;
  color: #124f6d !important;
}

.perito-anomalie-list {
  display: grid;
  gap: 0.4rem;
}

.perito-anomalie-row {
  border: 1px solid #a9c0cf;
  border-radius: 10px;
  background: #f8fcff;
  overflow: hidden;
}

.perito-anomalie-row-head {
  list-style: none;
  cursor: pointer;
  padding: 0.46rem 0.56rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.38rem;
  align-items: center;
}

.perito-anomalie-row-head::-webkit-details-marker {
  display: none;
}

.perito-anomalie-row-main {
  display: inline-flex;
  align-items: baseline;
  gap: 0.44rem;
  min-width: 0;
}

.perito-anomalie-row-code {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.73rem;
  color: #2f5a6d;
  background: #edf5fa;
  border: 1px solid #c6d6e0;
  border-radius: 999px;
  padding: 0.08rem 0.42rem;
  white-space: nowrap;
}

.perito-anomalie-row-title {
  font-size: 0.86rem;
  font-weight: 700;
  color: #103f55;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.perito-anomalie-row-right {
  display: inline-flex;
  align-items: center;
  gap: 0.34rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.perito-anomalie-row-section {
  font-size: 0.72rem;
  color: #46697a;
  white-space: nowrap;
}

.perito-anomalie-state {
  border-radius: 999px;
  border: 1px solid #aec2ce;
  padding: 0.14rem 0.5rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.perito-anomalie-state.state-open {
  border-color: #d89b92;
  background: #fff0ec;
  color: #9f3527;
}

.perito-anomalie-state.state-resolved {
  border-color: #8ec4ad;
  background: #e9f8f1;
  color: #136543;
}

.perito-anomalie-state.state-neutral {
  border-color: #b9cbd6;
  background: #eef4f8;
  color: #476272;
}

.perito-anomalie-row-body {
  padding: 0 0.56rem 0.56rem;
  display: grid;
  gap: 0.34rem;
}

.perito-anomalie-row-meta {
  margin: 0;
  font-size: 0.75rem;
  color: #2f586b;
}

.perito-anomalie-note-block {
  border: 1px solid #c3d5e1;
  border-radius: 8px;
  background: #f5fafd;
  overflow: hidden;
}

.perito-anomalie-note-block summary {
  cursor: pointer;
  list-style: none;
  padding: 0.36rem 0.46rem;
  color: #1b4f66;
  font-size: 0.76rem;
  font-weight: 700;
}

.perito-anomalie-note-block summary::-webkit-details-marker {
  display: none;
}

.perito-anomalie-note-content {
  margin: 0;
  white-space: pre-wrap;
  padding: 0.34rem 0.46rem 0.46rem;
  font-size: 0.76rem;
  line-height: 1.36;
  color: #204a5f;
  border-top: 1px dashed #cadbe5;
}

.perito-anomalie-subtimeline {
  display: grid;
  gap: 0.2rem;
}

.perito-anomalie-subtitle {
  margin: 0;
  font-size: 0.74rem;
  font-weight: 700;
  color: #2d5669;
}

.perito-anomalie-events {
  margin: 0;
  padding-left: 1.04rem;
  display: grid;
  gap: 0.16rem;
}

.perito-anomalie-events li {
  display: grid;
  gap: 0.05rem;
}

.perito-anomalie-event-meta {
  font-size: 0.7rem;
  color: #4d6d7d;
}

.perito-anomalie-event-text {
  font-size: 0.75rem;
  color: #1f4658;
}

.perito-anomalie-empty {
  margin: 0;
  font-size: 0.74rem;
  color: #557180;
}

@media (max-width: 960px) {
  .perito-anomalie-row-head {
    grid-template-columns: 1fr;
  }

  .perito-anomalie-row-right {
    justify-content: flex-start;
  }

  .perito-feedback-layout {
    grid-template-columns: 1fr;
  }

  .perito-feedback-block-head {
    grid-template-columns: 1fr;
  }

  .perito-feedback-block-right {
    justify-content: flex-start;
  }
}

.perito-convalida-subrows {
  display: grid;
  gap: 0.18rem;
}

.perito-convalida-subrow {
  margin: 0;
  font-size: 0.8rem;
  color: #315669;
}

.perito-convalida-actions {
  margin-top: 0.42rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.32rem;
}

.perito-convalida-alert-action {
  border-style: dashed;
}

.perito-convalida-alert-action.notes {
  border-color: #86a8be;
  background: #e9f2f8;
  color: #1a4f69;
}

.perito-convalida-alert-action.email {
  border-color: #c08b7f;
  background: #fcebe7;
  color: #8e3f2e;
}

.perito-convalida-note-panel {
  margin-top: 0.38rem;
  padding: 0.46rem 0.56rem;
  border: 1px solid #b7cad8;
  border-radius: 10px;
  background: #f5f9fc;
  display: grid;
  gap: 0.32rem;
}

.perito-convalida-note-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.22rem 0.5rem;
}

.perito-convalida-note-title {
  margin: 0;
  font-size: 0.8rem;
  font-weight: 800;
  color: #1b4f66;
}

.perito-convalida-note-meta {
  margin: 0;
  font-size: 0.72rem;
  color: #45697a;
}

.perito-convalida-note-panel textarea {
  width: 100%;
  min-height: 150px;
  border: 1px solid #aec4d1;
  border-radius: 9px;
  padding: 0.5rem 0.56rem;
  background: #ffffff;
  color: #173f52;
  font-family: "IBM Plex Sans", sans-serif;
  font-size: 0.81rem;
  line-height: 1.38;
  resize: vertical;
}

.perito-convalida-note-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.32rem;
}

.perito-convalida-note-status {
  margin: 0;
  font-size: 0.74rem;
  color: #32586b;
}

.perito-convalida-note-actions .secondary-btn {
  min-height: 32px;
  padding: 0.32rem 0.58rem;
  font-size: 0.77rem;
}

.perito-convalida-readonly {
  grid-column: 1 / -1;
  margin-top: 0.34rem;
  padding: 0.46rem 0.58rem;
  border: 1px solid #b7cad8;
  border-radius: 9px;
  background: #f4f9fd;
}

.perito-convalida-readonly-title {
  margin: 0 0 0.2rem;
  font-size: 0.8rem;
  font-weight: 800;
  color: #1c4d66;
}

.perito-convalida-readonly-source {
  margin: 0 0 0.26rem;
  font-size: 0.76rem;
  color: #325b6e;
}

.perito-convalida-readonly-fields {
  display: grid;
  gap: 0.14rem;
}

.perito-convalida-readonly-field {
  margin: 0;
  font-size: 0.77rem;
  color: #1f4152;
  line-height: 1.3;
}

.perito-convalida-readonly-attachments-title {
  margin: 0.34rem 0 0.16rem;
  font-size: 0.76rem;
  font-weight: 700;
  color: #2a5468;
}

.perito-convalida-readonly-attachments {
  margin: 0;
  padding-left: 1.12rem;
  display: grid;
  gap: 0.1rem;
}

.perito-convalida-readonly-attachments li {
  font-size: 0.75rem;
  color: #305b70;
}

.perito-convalida-readonly-attachments a {
  color: #0f5f8f;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.perito-convalida-readonly-stamp {
  margin: 0.32rem 0 0;
  font-size: 0.72rem;
  color: #45697a;
}

.perito-convalida-readonly-empty {
  margin: 0;
  font-size: 0.75rem;
  color: #506876;
}

.perito-convalida-readonly-assets {
  background: #f2f8fc;
}

.perito-convalida-assets-registers {
  display: grid;
  gap: 0.44rem;
}

.perito-convalida-assets-actions {
  margin: 0.08rem 0 0.42rem;
}

.perito-convalida-assets-export-label {
  margin: 0 0 0.28rem;
  font-size: 0.75rem;
  font-weight: 700;
  color: #194f67;
}

.perito-convalida-assets-export-buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.32rem;
}

.perito-convalida-assets-export-btn {
  min-height: 31px;
  border-radius: 9px;
  border: 1px solid #88a9bd;
  background: #e3eff7;
  color: #0f4f6c;
  font-size: 0.76rem;
  font-weight: 800;
  padding: 0.32rem 0.64rem;
}

.perito-convalida-assets-export-btn:hover {
  background: #d4e7f3;
}

.perito-convalida-assets-export-format-btn {
  min-height: 31px;
  border-radius: 9px;
  border: 1px solid #88a9bd;
  background: #f3f8fc;
  color: #0f4f6c;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.32rem 0.56rem;
  min-width: 58px;
}

.perito-convalida-assets-export-format-btn:hover {
  background: #e4eff7;
}

.perito-convalida-assets-register {
  border: 1px solid #b8ccd9;
  border-radius: 9px;
  background: #ffffff;
  padding: 0.46rem 0.54rem;
}

.perito-convalida-assets-register-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.28rem 0.56rem;
  margin-bottom: 0.3rem;
}

.perito-convalida-assets-register-title {
  margin: 0;
  font-size: 0.79rem;
  font-weight: 800;
  color: #184c63;
}

.perito-convalida-assets-register-updated {
  margin: 0;
  font-size: 0.72rem;
  color: #4e6b7a;
}

.perito-convalida-assets-register-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.16rem 0.52rem;
  margin-bottom: 0.34rem;
}

.perito-convalida-assets-register-meta p {
  margin: 0;
  font-size: 0.74rem;
  color: #234d60;
  line-height: 1.28;
}

.perito-convalida-assets-register-note {
  grid-column: 1 / -1;
  font-weight: 700;
}

.perito-convalida-assets-table-wrap {
  overflow: auto;
  border: 1px solid #c3d6e2;
  border-radius: 8px;
  background: #fdfeff;
}

.perito-convalida-assets-table {
  width: max-content;
  min-width: 0;
  max-width: none;
  border-collapse: collapse;
  font-size: 0.73rem;
  table-layout: auto;
}

.perito-convalida-assets-table th,
.perito-convalida-assets-table td {
  border: 1px solid #c4d5e1;
  padding: 0.26rem 0.34rem;
  vertical-align: top;
}

.perito-convalida-assets-table th {
  background: #e9f3f9;
  color: #164a60;
  text-transform: uppercase;
  font-size: 0.67rem;
  letter-spacing: 0.02em;
}

.perito-convalida-assets-head-main {
  text-transform: none !important;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  text-align: left;
  font-weight: 800;
  padding-left: 0.58rem !important;
}

.perito-convalida-assets-head-sub {
  text-transform: none !important;
  font-size: 0.69rem;
  font-weight: 700;
  color: #184c62 !important;
  background: #eef6fb !important;
  text-align: center;
}

.perito-convalida-assets-head-blank {
  width: 9ch;
  min-width: 9ch;
  max-width: 9ch;
  background: #f5fbff !important;
  border-right-color: #b8cddd !important;
}

.perito-convalida-assets-row-desc-cell {
  font-weight: 800;
  color: #0f3f56;
  line-height: 1.35;
  background: #fbfdff;
  font-size: 0.95rem;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.perito-convalida-assets-row-indent-cell {
  width: 9ch;
  min-width: 9ch;
  max-width: 9ch;
  background: #f5fbff;
  border-right-color: #b8cddd;
}

.perito-convalida-assets-row-detail-cell {
  white-space: nowrap;
  color: #214f64;
  line-height: 1.28;
  text-align: center;
  background: #f5fbff;
  font-size: 0.89rem;
}

.perito-convalida-assets-row-detail-cell.is-num {
  text-align: right;
  padding-right: 0.5rem;
}

.perito-convalida-assets-row-detail-cell.is-center {
  text-align: center;
}

.perito-convalida-assets-head-sub.col-date {
  width: 10.8ch;
  min-width: 10.8ch;
  max-width: 10.8ch;
  padding-left: 2px !important;
  padding-right: 2px !important;
}

.perito-convalida-assets-row-detail-cell.col-date {
  width: 10.8ch;
  min-width: 10.8ch;
  max-width: 10.8ch;
  text-align: center;
  padding-left: 2px;
  padding-right: 2px;
}

.perito-convalida-assets-head-sub.col-percent {
  width: calc(5ch + 4px);
  min-width: calc(5ch + 4px);
  max-width: calc(5ch + 4px);
  padding-left: 6px !important;
  padding-right: 6px !important;
}

.perito-convalida-assets-row-detail-cell.col-percent {
  width: calc(5ch + 4px);
  min-width: calc(5ch + 4px);
  max-width: calc(5ch + 4px);
  text-align: center;
  padding-left: 6px;
  padding-right: 6px;
}

.perito-convalida-assets-head-sub.col-money {
  width: 12ch;
  min-width: 12ch;
  max-width: 12ch;
  padding-left: 0.3ch !important;
  padding-right: 0.3ch !important;
}

.perito-convalida-assets-row-detail-cell.col-money {
  width: 12ch;
  min-width: 12ch;
  max-width: 12ch;
  padding-left: 0.3ch;
  padding-right: 0.3ch;
}

.perito-convalida-assets-row-detail-cell.col-money.is-num {
  padding-right: 0.35ch !important;
}

.perito-convalida-assets-head-sub.col-uso {
  width: calc(2.8ch + 4px);
  min-width: calc(2.8ch + 4px);
  padding-left: 6px !important;
  padding-right: 6px !important;
}

.perito-convalida-assets-row-detail-cell.col-uso {
  width: calc(2.8ch + 4px);
  min-width: calc(2.8ch + 4px);
  padding-left: 6px;
  padding-right: 6px;
}

.perito-convalida-assets-head-sub.col-rileva {
  width: calc(4.6ch + 4px);
  min-width: calc(4.6ch + 4px);
  padding-left: 6px !important;
  padding-right: 6px !important;
}

.perito-convalida-assets-row-detail-cell.col-rileva {
  width: calc(4.6ch + 4px);
  min-width: calc(4.6ch + 4px);
  padding-left: 6px;
  padding-right: 6px;
  text-align: center;
}

.perito-convalida-assets-head-sub.col-title {
  width: calc(9ch + 8px);
  min-width: calc(9ch + 8px);
  max-width: calc(9ch + 8px);
  padding-left: 6px !important;
  padding-right: 6px !important;
}

.perito-convalida-assets-row-detail-cell.col-title {
  width: calc(9ch + 8px);
  min-width: calc(9ch + 8px);
  max-width: calc(9ch + 8px);
  padding-left: 6px;
  padding-right: 6px;
  text-align: center;
}

.perito-usage-indicator {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.perito-usage-indicator.usage-pill {
  width: 0.94rem;
  height: 0.66rem;
  border-radius: 999px;
  border: 1px solid transparent;
}

.perito-usage-indicator.usage-green {
  background: #57b08a;
  border-color: #3f9773;
}

.perito-usage-indicator.usage-red {
  background: #cf6356;
  border-color: #b2493d;
}

.perito-usage-indicator.usage-gray {
  background: #8f9fac;
  border-color: #728594;
}

.perito-usage-indicator.usage-x {
  color: #132434;
  font-weight: 900;
  font-size: 0.84rem;
  line-height: 1;
}

.perito-usage-indicator.usage-emoji {
  font-size: 0.88rem;
  line-height: 1;
}

.perito-convalida-assets-empty-cell {
  text-align: center;
  color: #5c7584;
  font-style: italic;
}

.perito-convalida-assets-table tfoot td {
  background: #eef7fc;
  color: #184c62;
  font-weight: 700;
  line-height: 1.3;
}

.perito-convalida-btn {
  min-height: 32px;
  border-radius: 9px;
  border: 1px solid #9fb8c9;
  background: #edf4f9;
  color: #124c64;
  font-size: 0.79rem;
  font-weight: 700;
  padding: 0.34rem 0.6rem;
}

.perito-convalida-btn:hover {
  transform: none;
  background: #deebf3;
}

.perito-convalida-btn.active-ok {
  border-color: #6bb69a;
  background: #dff4eb;
  color: #0b6a53;
}

.perito-convalida-btn.active-alert {
  border-color: #d28f84;
  background: #ffe8e3;
  color: #a33524;
}

.perito-alert-email-modal {
  width: min(940px, 96vw);
}

.perito-alert-email-modal textarea {
  width: 100%;
  min-height: 210px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0.52rem 0.56rem;
  color: #163d4f;
  background: #ffffff;
  font-size: 0.82rem;
  font-family: "IBM Plex Sans", sans-serif;
  line-height: 1.4;
  resize: vertical;
}

.perito-editor-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.42rem;
}

.perito-editor-toolbar button {
  min-height: 36px;
  padding: 0.5rem 0.72rem;
  font-size: 0.82rem;
}

.perito-sub-note {
  margin: 0;
  font-size: 0.82rem;
  color: #315669;
}

.perito-editor {
  min-height: 440px;
  max-height: 68vh;
  overflow: auto;
  border: 1px solid #bfd2de;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: inset 0 1px 0 #eef5f9;
  padding: 0.9rem 0.95rem;
  line-height: 1.42;
  font-size: 0.9rem;
  color: #163747;
  user-select: text;
}

.perito-editor:empty::before {
  content: "Seleziona una perizia e premi GENERA PERIZIA.";
  color: #69808d;
}

.perito-empty-note {
  margin: 0;
  color: #5f7683;
  font-style: italic;
}

.perito-editor h1 {
  margin: 0 0 0.52rem;
  font-size: 1.2rem;
  color: #12465c;
}

.perito-editor h3 {
  margin: 0.8rem 0 0.22rem;
  font-size: 0.98rem;
  color: #1a4f62;
}

.perizia-front-block {
  margin: 0 0 0.6rem;
  padding: 0 0 0.52rem;
  border-bottom: 1px dashed #c8d7df;
}

.perizia-main-title {
  margin: 0 0 0.52rem;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.perizia-heading-centered {
  margin: 0.52rem 0 0.22rem;
  text-align: center;
  font-size: 1.08rem;
  color: #12465c;
}

.perizia-front-block p {
  margin: 0.08rem 0 0.34rem;
}

.perito-module-meta {
  margin: 0.14rem 0 0.28rem;
  color: #2a5364;
  font-size: 0.84rem;
}

.perito-module-block {
  margin-top: 0.62rem;
  padding-top: 0.38rem;
  border-top: 1px dashed #c8d7df;
}

.perito-module-block p {
  margin: 0.1rem 0 0.42rem;
}

.perito-module-section {
  margin: 0;
  color: #456676;
  font-size: 0.8rem;
  font-style: italic;
}

.perizia-section-divider {
  margin: 1.1rem 0 0.46rem;
  display: flex;
  align-items: center;
  gap: 0.9rem;
  color: #3a6070;
}

.perizia-word-page-break {
  display: none;
  margin: 0;
  padding: 0;
  height: 0;
}

.perizia-section-divider::before,
.perizia-section-divider::after {
  content: "";
  flex: 1;
  border-top: 1px dashed #000000;
}

.perizia-section-divider span {
  display: inline-block;
  padding: 0.24rem 0.96rem;
  border: 1px dashed #000000;
  border-radius: 999px;
  font-size: 1.11rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: #f5fbff;
}

.perizia-row-cards {
  margin-top: 0.5rem;
  display: grid;
  gap: 0.56rem;
}

.perizia-row-card {
  border: 1px solid #c5d8e3;
  border-radius: 12px;
  background: transparent;
  padding: 0.56rem 0.62rem;
  display: grid;
  gap: 0.28rem;
}

.perizia-row-title {
  margin: 0;
  color: #144a60;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  text-align: center;
}

.perizia-row-meta {
  margin: 0;
  color: #2d5b6d;
  font-size: 0.8rem;
}

.perizia-row-content {
  display: grid;
  gap: 0.16rem;
}

.perizia-row-content p {
  margin: 0.08rem 0;
}

.perizia-row-empty {
  margin: 0;
  color: #57707d;
  font-style: italic;
}

.perizia-row-files {
  margin-top: 0.12rem;
}

.perizia-row-list {
  margin: 0.1rem 0 0.15rem 1.05rem;
  padding: 0;
}

.perizia-row-list li {
  margin: 0.04rem 0;
  line-height: 1.35;
}

.perizia-sub-row {
  border: 1px dashed #c3d6e0;
  border-radius: 10px;
  background: #ffffff;
  padding: 0.32rem 0.42rem;
  margin: 0.2rem 0 0.34rem;
}

.perizia-assets-register {
  display: grid;
  gap: 0.36rem;
}

.perizia-assets-meta {
  margin-top: 0.14rem;
  color: #3c5f6e;
  font-size: 0.78rem;
}

.perizia-assets-table-wrap {
  overflow-x: auto;
  border: 0.5px solid #c2d4df;
  border-radius: 8px;
  background: #ffffff;
}

.perizia-assets-table {
  width: 100%;
  min-width: 1120px;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.perizia-assets-table th,
.perizia-assets-table td {
  border: 0.5px solid #c2d4df;
  padding: 0.28rem 0.34rem;
  vertical-align: top;
}

.perizia-assets-table th {
  background: #eef6fb;
  color: #154b61;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 0.73rem;
}

.perizia-assets-table td.is-num {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.perizia-assets-table td.is-center {
  text-align: center;
  white-space: nowrap;
}

.perizia-assets-empty-cell {
  text-align: center;
  color: #5b7482;
  font-style: italic;
}

.perizia-assets-notes-row td {
  background: #f8fcff;
  color: #2f596b;
  font-size: 0.79rem;
}

.perizia-assets-table tfoot td {
  background: #eff7fb;
  color: #154b61;
  font-weight: 700;
}

.perito-autosave-info {
  font-size: 0.8rem;
  white-space: nowrap;
}

.perito-autosave-info.ok {
  color: #226a45;
}

.perito-autosave-info.err {
  color: #9a352a;
}

.test-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.6rem;
  align-items: end;
}

.test-grid label {
  display: grid;
  gap: 0.35rem;
  color: var(--ink-soft);
  font-size: 0.82rem;
}

.test-grid input,
.test-grid select {
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 0.6rem;
  color: var(--ink);
  background: #ffffff;
}

.test-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem;
}

.secondary-btn {
  background: #657b88;
}

.secondary-btn:hover {
  background: #4f6470;
}

.test-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.45rem;
}

.test-list li {
  border: 1px solid #cfdde4;
  border-radius: 10px;
  padding: 0.55rem;
  background: #f9fcfe;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.5rem;
  align-items: center;
}

.test-item-main {
  display: grid;
  gap: 0.15rem;
}

.test-item-title {
  font-weight: 700;
  font-size: 0.9rem;
}

.test-item-meta {
  font-size: 0.8rem;
  color: var(--ink-soft);
}

.test-item-actions {
  display: inline-flex;
  gap: 0.4rem;
}

.test-item-actions button {
  padding: 0.42rem 0.6rem;
  border-radius: 9px;
  font-size: 0.77rem;
}

.practice-modal-backdrop,
.practice-picker-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(12, 34, 47, 0.42);
}

.practice-modal-backdrop[hidden],
.practice-picker-backdrop[hidden] {
  display: none !important;
}

.practice-modal {
  width: min(1240px, 97vw);
  max-height: 90vh;
  border: 1px solid #a8c1cf;
  border-radius: 14px;
  background: #f7fcff;
  box-shadow: 0 22px 48px rgba(8, 26, 39, 0.3);
  padding: 0.75rem 0.8rem;
  display: grid;
  gap: 0.56rem;
  color: #173f52;
}

.practice-picker-modal {
  width: min(920px, 96vw);
  max-height: 90vh;
  border: 1px solid #a8c1cf;
  border-radius: 14px;
  background: #f7fcff;
  box-shadow: 0 22px 48px rgba(8, 26, 39, 0.3);
  padding: 0.75rem 0.8rem;
  display: grid;
  gap: 0.56rem;
  color: #173f52;
}

.practice-modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.practice-modal-head h3 {
  margin: 0;
  font-size: 1.02rem;
  color: #123f52;
}

.practice-picker-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.practice-picker-head h3 {
  margin: 0;
  font-size: 1.02rem;
  color: #123f52;
}

.master-data-head {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.5rem;
}

.master-data-head.master-data-head-draggable {
  cursor: move;
}

.master-data-head.master-data-head-draggable button {
  cursor: pointer;
}

.master-data-head.master-data-head-draggable.is-dragging {
  cursor: grabbing;
}

.master-data-head h3 {
  grid-column: 2;
  justify-self: center;
  text-align: center;
  letter-spacing: 0.02em;
}

.master-data-head #btnMasterDataClose {
  grid-column: 3;
  justify-self: end;
}

.master-data-close-btn {
  grid-column: 3;
  justify-self: end;
  width: auto;
  min-width: 94px;
  max-width: 128px;
  padding: 0.42rem 0.78rem;
}

.master-data-back-btn {
  grid-column: 1;
  justify-self: start;
}

.master-data-modal.is-dragging {
  user-select: none;
}

.practice-picker-sub {
  margin: 0;
  color: #2c5668;
  font-size: 0.82rem;
}

.practice-picker-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.45rem;
}

.practice-picker-grid label,
.practice-picker-practice-label {
  display: grid;
  gap: 0.2rem;
  color: #2f5667;
  font-size: 0.79rem;
  font-weight: 700;
}

.practice-picker-grid input[type="search"],
.practice-picker-grid select,
.practice-picker-practice-label select {
  min-height: 36px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0 0.55rem;
  color: #163d4f;
  background: #ffffff;
  font-size: 0.82rem;
}

.practice-picker-practice-label select {
  min-height: 260px;
  padding: 0.4rem 0.5rem;
}

.practice-picker-preview {
  border: 1px solid #c2d4df;
  border-radius: 9px;
  background: #f8fcff;
  padding: 0.5rem 0.56rem;
  color: #214c60;
  font-size: 0.8rem;
  line-height: 1.32;
  min-height: 56px;
}

.concessionario-login-modal {
  width: min(520px, 94vw);
}

.concessionario-login-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.55rem;
}

.concessionario-login-grid label {
  display: grid;
  gap: 0.25rem;
  color: #2f5667;
  font-size: 0.82rem;
  font-weight: 700;
}

.concessionario-login-grid input {
  min-height: 38px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0 0.58rem;
  color: #163d4f;
  background: #ffffff;
  font-size: 0.9rem;
}

.practice-picker-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.45rem;
}

.practice-picker-footer button {
  min-height: 36px;
  padding: 0.46rem 0.76rem;
  font-size: 0.82rem;
}

.practice-create-modal {
  width: min(980px, 96vw);
}

.practice-edit-modal {
  width: min(980px, 96vw);
}

.practice-create-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.42rem 0.52rem;
  align-items: end;
}

.practice-create-grid label {
  display: grid;
  gap: 0.2rem;
  color: #2f5667;
  font-size: 0.79rem;
  font-weight: 700;
}

.practice-create-grid select,
.practice-create-grid input[type="text"],
.practice-create-grid input[type="date"],
.practice-create-grid input[type="email"] {
  min-height: 36px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0 0.55rem;
  color: #163d4f;
  background: #ffffff;
  font-size: 0.82rem;
}

.practice-edit-fields input[readonly] {
  background: #eff5f9;
  color: #2b5364;
}

.practice-create-grid .secondary-btn {
  min-height: 36px;
  padding: 0.42rem 0.7rem;
  font-size: 0.8rem;
}

.practice-create-fields {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.practice-create-fields > label {
  min-width: 0;
}

.practice-create-span-2 {
  grid-column: 1 / -1;
}

.master-data-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1760;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(12, 34, 47, 0.5);
  overflow-y: auto;
}

.master-record-editor-backdrop {
  z-index: 1810;
  background: rgba(10, 26, 38, 0.62);
}

.master-data-backdrop[hidden] {
  display: none !important;
}

.master-data-modal {
  width: min(1180px, 97vw);
  max-height: 90vh;
  border: 1px solid #a8c1cf;
  border-radius: 14px;
  background: #f7fcff;
  box-shadow: 0 22px 48px rgba(8, 26, 39, 0.3);
  padding: 0.75rem 0.8rem;
  display: grid;
  gap: 0.56rem;
  color: #173f52;
  overflow-y: auto;
}

.master-data-modal.master-data-modal-floating {
  position: absolute;
  margin: 0;
  max-width: calc(100vw - 1.4rem);
  max-height: calc(100vh - 1.4rem);
  resize: both;
  overflow: auto;
}

.master-data-modal.master-data-modal-floating-ready {
  left: 50%;
  top: 50%;
  transform: none;
}

.master-data-launcher-modal {
  width: min(760px, 94vw);
}

.master-data-switch {
  display: grid;
  grid-template-columns: repeat(3, minmax(150px, 180px));
  justify-content: center;
  justify-items: stretch;
  gap: 0.56rem;
}

.master-data-switch-btn {
  width: 100%;
  min-height: 38px;
  padding: 0.42rem 0.68rem;
  border: 1px solid #9cb6c7;
  border-radius: 9px;
  background: #e8f1f7;
  color: #164c63;
  font-weight: 700;
  font-size: 0.8rem;
  text-align: center;
}

.master-data-switch-btn:hover {
  transform: none;
  background: #dce9f2;
  border-color: #86a9bd;
}

.master-data-switch-btn.active {
  border-color: #0b6654;
  background: linear-gradient(140deg, #118a70, #0d725b);
  color: #ffffff;
}

.master-data-section {
  display: grid;
  gap: 0.46rem;
}

.master-data-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.master-data-search-label {
  margin: 0;
  color: #24556b;
  font-size: 0.78rem;
  font-weight: 700;
}

#masterComuneSearchInput,
#masterPeritiSearchInput,
#masterPeritiPageSizeSelect {
  min-height: 34px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0 0.55rem;
  color: #163d4f;
  background: #ffffff;
  font-size: 0.8rem;
}

.master-data-periti-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.46rem 0.7rem;
}

.master-data-periti-search-wrap {
  display: grid;
  gap: 0.2rem;
  min-width: min(100%, 440px);
  flex: 1 1 360px;
}

.master-data-periti-page-size-wrap {
  display: grid;
  gap: 0.2rem;
  min-width: 96px;
}

.master-data-periti-pagination {
  display: inline-flex;
  align-items: center;
  gap: 0.36rem;
}

#masterPeritiPageInfo {
  min-width: 170px;
  text-align: center;
  color: #24556b;
  font-size: 0.78rem;
  font-weight: 700;
}

.master-data-sortable {
  cursor: pointer;
  user-select: none;
}

.master-data-add-btn {
  min-width: 34px;
  min-height: 34px;
  border: 1px solid #89a8bb;
  border-radius: 9px;
  background: #e5eef5;
  color: #184f65;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
  padding: 0;
}

.master-data-add-btn:hover {
  transform: none;
  border-color: #0b6654;
  background: #d8e6ef;
}

.master-data-comune-nav-wrap {
  border: 1px solid #b7cad7;
  border-radius: 10px;
  background: #edf4f9;
  padding: 0.48rem 0.52rem;
}

.master-data-comune-nav-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.master-data-comune-nav-title {
  margin: 0;
  color: #1a4f66;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.master-data-comune-nav {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.45rem;
}

.master-data-comune-nav-btn {
  min-height: 34px;
  padding: 0.35rem 0.42rem;
  border: 1px solid #9cb6c7;
  border-radius: 8px;
  background: #e8f1f7;
  color: #1d4f64;
  font-size: 0.76rem;
  font-weight: 700;
  text-align: center;
}

.master-data-comune-nav-btn:hover {
  transform: none;
  background: #dbe8f1;
  border-color: #87a8ba;
}

.master-data-comune-nav-btn.active {
  border-color: #0b6654;
  background: linear-gradient(140deg, #118a70, #0d725b);
  color: #ffffff;
}

.master-data-comune-step-pane[hidden] {
  display: none !important;
}

.master-data-section[hidden] {
  display: none !important;
}

.master-data-section h4 {
  margin: 0.1rem 0 0;
  font-size: 0.87rem;
  color: #154e64;
}

.master-data-heading-note {
  font-weight: 400;
  font-size: 0.79rem;
  color: #42697a;
}

.master-data-note {
  margin: 0;
  color: #2d5a6d;
  font-size: 0.8rem;
}

.master-data-note strong {
  color: #123f52;
}

.master-data-note code {
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.76rem;
  color: #123f52;
  background: #eaf3f7;
  border-radius: 4px;
  padding: 0 0.2rem;
}

.master-data-table-wrap {
  border: 1px solid #bfd1dc;
  border-radius: 10px;
  background: #ffffff;
  overflow: auto;
  max-height: 22vh;
}

.master-data-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 820px;
}

.master-data-table th,
.master-data-table td {
  padding: 0.38rem 0.46rem;
  border-bottom: 1px solid #d5e3eb;
  vertical-align: top;
  font-size: 0.76rem;
  color: #234a5a;
  text-align: left;
  white-space: nowrap;
}

.master-data-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #eaf3f7;
  color: #123f52;
  font-weight: 700;
}

.master-data-table tbody tr:last-child td {
  border-bottom: none;
}

.master-actions-col {
  width: 72px;
}

.master-actions-cell {
  text-align: center !important;
  white-space: nowrap;
}

.master-row-edit-btn {
  min-width: 32px;
  min-height: 28px;
  border: 1px solid #9fb6c5;
  border-radius: 8px;
  background: #edf3f8;
  color: #1f5267;
  font-size: 0.95rem;
  line-height: 1;
  padding: 0;
}

.master-row-edit-btn:hover {
  transform: none;
  border-color: #0b6654;
  background: #e0ebf3;
}

.master-comune-open-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  width: 100%;
  min-width: 100%;
  border: 1px solid #9fb6c5;
  border-radius: 8px;
  padding: 0.28rem 0.5rem;
  background: #edf3f8;
  color: #0f5f78;
  font-size: 0.78rem;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  text-decoration: none;
  transition: color 120ms ease, background-color 120ms ease, border-color 120ms ease;
}

.master-comune-open-icon {
  flex: 0 0 auto;
  font-size: 0.92rem;
  line-height: 1;
}

.master-comune-open-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.master-comune-open-btn:hover {
  color: #0a4f64;
  border-color: #0b6654;
  background: #e0ebf3;
  transform: none;
}

.master-comune-open-btn:focus-visible {
  border-color: #0b6654;
  background: #e0ebf3;
  color: #0a4f64;
  outline: 2px solid rgba(15, 95, 120, 0.22);
  outline-offset: 2px;
  transform: none;
}

.master-data-table tbody tr.master-row-selected td {
  background: #eef6fb;
}

#masterDataPeritoBackdrop .master-data-table th:nth-child(2),
#masterDataPeritoBackdrop .master-data-table td:nth-child(2) {
  width: 21ch;
  min-width: 21ch;
  max-width: 21ch;
  font-family: "IBM Plex Mono", monospace;
  padding-right: calc(0.46rem + 2ch);
}

#masterDataPeritoBackdrop .master-data-table td:nth-child(2) {
  overflow: hidden;
  text-overflow: clip;
}

.master-data-empty {
  color: #6a7f8a;
  font-style: italic;
}

.master-record-editor-modal {
  width: min(920px, 96vw);
}

.master-record-editor-form {
  display: grid;
  gap: 0.6rem;
  overflow-y: auto;
  max-height: calc(90vh - 96px);
  padding-right: 0.2rem;
}

.master-record-editor-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.48rem 0.56rem;
}

.master-record-editor-grid.is-perito-layout {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.48rem 0.56rem;
}

.master-record-editor-grid.is-perito-layout .master-record-field {
  flex: 0 1 auto;
}

.master-record-editor-grid.is-perito-layout .master-record-field.is-wide {
  flex: 0 0 100%;
  max-width: 100% !important;
}

.master-record-editor-grid.is-perito-layout .master-record-line-break {
  flex: 0 0 100%;
  height: 0;
  margin: 0;
  padding: 0;
}

.master-record-section {
  grid-column: 1 / -1;
  width: 100%;
  margin-top: 0.12rem;
  border: 1px solid #bfd1dc;
  border-radius: 9px;
  background: #e9f2f8;
  color: #1b4f66;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 0.32rem 0.56rem;
}

.master-record-field {
  display: grid;
  gap: 0.2rem;
}

.master-record-field label {
  color: #2d5568;
  font-size: 0.78rem;
  font-weight: 700;
}

.master-record-field input:not([type="checkbox"]),
.master-record-field select,
.master-record-field textarea {
  min-height: 34px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0.36rem 0.52rem;
  color: #163d4f;
  background: #ffffff;
  font-size: 0.8rem;
  width: 100%;
}

.master-record-field textarea {
  min-height: 86px;
  resize: vertical;
}

.master-record-field.is-wide {
  grid-column: 1 / -1;
}

.master-record-field.is-check {
  align-self: end;
}

.master-record-field.is-check label {
  display: inline-flex;
  align-items: center;
  gap: 0.36rem;
  font-weight: 600;
}

.master-record-field.is-check input[type="checkbox"] {
  min-height: 16px;
}

.master-record-field.is-readonly input,
.master-record-field.is-readonly select,
.master-record-field.is-readonly textarea {
  background: #edf4f8;
  color: #3d5f6f;
}

@media (max-width: 640px) {
  .master-data-switch {
    grid-template-columns: 1fr;
    gap: 0.42rem;
  }

  .master-data-comune-nav {
    grid-template-columns: 1fr;
  }

  .master-record-editor-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 920px) {
  .master-data-modal.master-data-modal-floating {
    position: relative;
    left: auto !important;
    top: auto !important;
    resize: none;
    max-width: min(1180px, 97vw);
    max-height: 90vh;
  }

  .master-data-head.master-data-head-draggable {
    cursor: default;
  }
}

.practice-modal-toolbar {
  display: grid;
  grid-template-columns: auto minmax(280px, 1fr) auto;
  gap: 0.45rem;
  align-items: center;
}

.practice-modal-search-label {
  margin: 0;
  color: #2f5667;
  font-size: 0.82rem;
  font-weight: 700;
}

.practice-modal-toolbar input[type="search"] {
  min-height: 36px;
  border: 1px solid #aec3d0;
  border-radius: 9px;
  padding: 0 0.55rem;
  color: #163d4f;
  background: #ffffff;
  font-size: 0.82rem;
}

.practice-modal-table-wrap {
  border: 1px solid #bfd1dc;
  border-radius: 10px;
  background: #ffffff;
  overflow: auto;
  max-height: 58vh;
}

.practice-modal-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 980px;
}

.practice-modal-table th,
.practice-modal-table td {
  padding: 0.42rem 0.48rem;
  border-bottom: 1px solid #d5e3eb;
  vertical-align: top;
  font-size: 0.79rem;
  color: #234a5a;
}

.practice-modal-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #eaf3f7;
  color: #123f52;
  font-weight: 700;
  text-align: left;
}

.practice-modal-table tbody tr:last-child td {
  border-bottom: none;
}

.practice-actions-cell {
  white-space: nowrap;
}

.practice-actions-row {
  display: inline-flex;
  gap: 0.34rem;
  white-space: nowrap;
}

.practice-actions-cell button {
  min-height: 29px;
  padding: 0.3rem 0.48rem;
  font-size: 0.74rem;
  border-radius: 8px;
}

.practice-modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem;
}

.practice-modal-footer span {
  color: #2d5567;
  font-size: 0.79rem;
  font-weight: 700;
  min-width: 110px;
  text-align: center;
}

.danger-btn {
  background: #b34438;
}

.danger-btn:hover {
  background: #9a342a;
}

.top-nav-panel {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.75rem;
  align-items: center;
}

.back-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  border-radius: 11px;
  padding: 0 0.85rem;
  text-decoration: none;
  font-weight: 700;
  color: #ffffff;
  background: var(--brand);
}

.back-link:hover {
  background: var(--brand-strong);
}

.top-nav-text {
  display: grid;
  gap: 0.15rem;
}

.top-nav-title {
  margin: 0;
  font-size: 1.2rem;
}

.top-nav-sub {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.panel-head {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 0.8rem;
  align-items: start;
}

.controls {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
}

.controls label {
  display: grid;
  gap: 0.35rem;
  color: var(--ink-soft);
  font-size: 0.82rem;
}

.controls input {
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 0.6rem;
  color: var(--ink);
}

.controls button {
  grid-column: 1 / -1;
}

.sections {
  display: grid;
  gap: 0.65rem;
}

.doc-section {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f8fbfc;
  overflow: hidden;
}

.doc-section summary {
  list-style: none;
  cursor: default;
  user-select: none;
  padding: 0.7rem 0.8rem;
  background: linear-gradient(90deg, #e7eff3, #eef5f8);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 0.55rem;
  align-items: center;
  font-weight: 700;
}

.doc-section summary::-webkit-details-marker {
  display: none;
}

.doc-section-title {
  min-width: 0;
}

.doc-section-title-line {
  display: block;
  line-height: 1.2;
}

.doc-section-title-line + .doc-section-title-line {
  margin-top: 0.1rem;
}

.section-expand-toggle {
  min-height: 30px;
  border-radius: 999px;
  border: 1px solid #8bb2c7;
  background: #eaf3f9;
  color: #124c64;
  font-size: 0.74rem;
  font-weight: 700;
  padding: 0.25rem 0.58rem;
  white-space: nowrap;
}

.section-expand-toggle:hover {
  transform: none;
  background: #dbeaf4;
  border-color: #78a4bc;
}

.section-count {
  display: inline-flex;
  gap: 0.45rem;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  color: #2c5563;
  font-weight: 600;
  font-size: 0.82rem;
}

.count-total {
  color: #234b58;
  font-weight: 700;
}

.count-detail {
  color: #748f9d;
  font-weight: 500;
}

.count-ok {
  color: var(--ok);
  font-weight: 700;
}

.count-bad {
  color: var(--bad);
  font-weight: 700;
}

.doc-rows {
  display: grid;
  gap: 0.3rem;
  padding: 0.7rem;
}

.doc-row {
  border: 2px solid #7ea8bf;
  border-radius: 12px;
  padding: 0.21rem 0.18rem;
  background: #ffffff;
  display: grid;
  gap: 0.3rem;
}

.row-toggle {
  width: 100%;
  border: 1px solid #c9d8e1;
  border-radius: 10px;
  padding: 0.42rem 0.52rem 0.42rem 0.18rem;
  background: #f6fbfe;
  color: #113f52;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 0.5rem;
  align-items: center;
  text-align: left;
}

.row-toggle:hover {
  transform: none;
  background: #eef7fc;
  border-color: #afc8d6;
}

.row-toggle-main {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
}

.semaforo {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  border: 1px solid #7d8d98;
  flex-shrink: 0;
}

.semaforo.rosso {
  background: var(--bad);
}

.semaforo.verde {
  background: var(--ok);
}

.semaforo.grigio {
  background: var(--muted);
}

.doc-title {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.2;
}

.doc-meta,
.doc-desc {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.82rem;
}

.doc-meta {
  color: #2b5160;
  font-size: 0.74rem;
}

.doc-meta-label {
  color: #345b6a;
}

.doc-meta-value {
  color: #234a5a;
}

.meta-obbligo-value {
  color: #a86f2b;
  font-weight: 700;
}

.doc-meta-sep {
  color: #6b8794;
}

.row-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 19rem;
  max-width: 100%;
  border-radius: 999px;
  border: 1px solid #b8cad5;
  padding: 0.17rem 0.54rem;
  font-size: 0.73rem;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
  text-transform: none;
}

.row-status-badge.rosso {
  background: #fdecea;
  color: #9f3127;
  border-color: #e4b6b1;
}

.row-status-badge.verde {
  background: #e8f7ef;
  color: #216d45;
  border-color: #b8dcc8;
}

.row-status-badge.grigio {
  background: #edf2f5;
  color: #586b77;
  border-color: #c3d0d8;
}

.row-status-badge.status-to-complete {
  background: #fff3e6;
  color: #9b4f1e;
  border-color: #e5c6a8;
}

.row-status-badge.status-alert {
  background: #ffe7e7;
  color: #b31d26;
  border-color: #e7b1b6;
}

.row-status-badge.status-completed {
  background: #e7f6ee;
  color: #1f6b46;
  border-color: #b8dbc8;
}

.row-status-badge.status-perito-convalidato {
  background: #dcf5e7;
  color: #14633f;
  border-color: #97d1b4;
}

.row-status-badge.status-concessionario-completato {
  background: #e8f4fb;
  color: #1f5f86;
  border-color: #aacfe3;
}

.row-status-badge.status-na-confirmed {
  background: #5b7286;
  color: #ffffff;
  border-color: #3f576c;
}

.row-status-badge.status-na-pending {
  background: #f4efe8;
  color: #7f5f3b;
  border-color: #dacbb9;
}

.row-status-group {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.35rem;
  min-width: 0;
}

.row-note-quick-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  min-width: 0;
}

.row-note-quick-wrap.none,
.row-note-quick-wrap.draft {
  display: none;
}

.row-note-quick {
  width: 30px;
  min-width: 30px;
  height: 28px;
  border-radius: 999px;
  border: 1px solid #b8cad5;
  padding: 0;
  font-size: 0.86rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  user-select: none;
}

.row-note-quick:hover {
  transform: none;
}

.row-note-quick:focus-visible {
  outline: 2px solid #3d7f9f;
  outline-offset: 2px;
}

.row-note-quick.none {
  border-color: #c4d1d9;
  background: #eef3f6;
  color: #7f93a1;
}

.row-note-quick.draft {
  border-color: #d4b06e;
  background: #fff4df;
  color: #8f6215;
}

.row-note-quick.saved {
  border-color: #7ea8bf;
  background: #e8f2f8;
  color: #1a546f;
}

.row-note-quick-meta {
  display: none;
  font-size: 0.67rem;
  color: #5f7f8e;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 12.2rem;
}

.row-note-quick-wrap.saved .row-note-quick-meta {
  color: #365f72;
}

.row-note-quick-wrap.draft .row-note-quick-meta {
  color: #946218;
}

@media (max-width: 1120px) {
  .row-note-quick-meta {
    display: none;
  }
}

.row-chevron {
  font-size: 0.8rem;
  color: #315b6a;
  font-weight: 700;
}

.row-details {
  display: grid;
  gap: 0.42rem;
  padding: 0.08rem 0.08rem 0.04rem;
}

.row-details[hidden] {
  display: none !important;
}

.row-detail-info {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "meta chip"
    "warn warn"
    "desc desc";
  gap: 0.22rem 0.5rem;
  align-items: start;
}

.subconcession-warning-banner {
  grid-area: warn;
  margin: 0.1rem 0 0.2rem;
  padding: 0.38rem 0.6rem;
  border: 2px solid #c1372f;
  border-radius: 8px;
  background: #fff1f1;
  color: #b1120a;
  font-weight: 800;
  font-size: clamp(0.72rem, 1.25vw, 1rem);
  line-height: 1.25;
  text-align: left;
}

.row-chip {
  grid-area: chip;
  justify-self: end;
  align-self: start;
  border: 1px solid #c1d4db;
  border-radius: 999px;
  padding: 0.14rem 0.48rem;
  font-size: 0.75rem;
  color: #204857;
  background: #f4fafc;
  white-space: nowrap;
  width: fit-content;
}

.row-workflow-box {
  display: grid;
  grid-template-columns: auto auto minmax(120px, 1fr);
  gap: 0.4rem;
  align-items: center;
  border: 1px solid #c7d7e1;
  border-radius: 9px;
  background: #f7fbff;
  padding: 0.32rem 0.46rem;
}

.row-workflow-label {
  font-size: 0.74rem;
  color: #2d5463;
  font-weight: 700;
  white-space: nowrap;
}

.row-workflow-select {
  min-height: 30px;
  border: 1px solid #99b6c7;
  border-radius: 8px;
  padding: 0 0.42rem;
  background: #ffffff;
  color: #18465a;
  font-size: 0.75rem;
  font-weight: 600;
}

.row-workflow-stamp {
  margin: 0;
  justify-self: end;
  text-align: right;
  color: #3a6070;
  font-size: 0.72rem;
  line-height: 1.2;
}

.row-workflow-box-concessionario {
  grid-template-columns: auto auto minmax(180px, 1fr);
}

.row-workflow-callout {
  border-color: #c5a164;
  background: linear-gradient(180deg, #fff8e8, #fff2db);
  box-shadow: inset 0 1px 0 #fffdfa;
}

.row-complete-label {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  font-size: 0.75rem;
  color: #244f61;
  font-weight: 700;
  white-space: nowrap;
}

.row-complete-checkbox {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: #0f7d67;
  cursor: pointer;
}

.row-complete-checkbox:disabled {
  cursor: not-allowed;
}

.row-complete-text {
  line-height: 1.1;
}

.row-workflow-callout .row-complete-text {
  color: #7d5620;
}

.row-unfreeze-btn {
  min-height: 30px;
  border-radius: 999px;
  padding: 0.26rem 0.62rem;
  background: linear-gradient(135deg, #1a8c63, #167552);
  color: #ffffff;
  font-size: 0.73rem;
  font-weight: 700;
  white-space: nowrap;
}

.row-unfreeze-btn:hover {
  transform: none;
  background: linear-gradient(135deg, #157a56, #126544);
}

.row-workflow-callout .row-workflow-stamp {
  color: #745d3e;
}

.row-frozen .note-box textarea:disabled {
  background: #f1f5f8;
  color: #5f7480;
}

.row-frozen .upload-box {
  background: #f2f7fa;
  border-style: solid;
}

.row-frozen .upload-toolbar button:disabled,
.row-frozen .file-actions button.danger:disabled {
  opacity: 0.62;
}

.doc-meta {
  grid-area: meta;
}

.doc-desc {
  grid-area: desc;
  display: grid;
  gap: 0.08rem;
  text-align: left;
  color: #2f6d8a;
  font-weight: 600;
  line-height: 1.25;
}

.doc-desc-label {
  display: block;
  color: #1d6686;
  font-weight: 800;
}

.doc-desc-body {
  display: block;
  color: #2f6d8a;
}

.row-controls {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 0.55rem;
  align-items: end;
}

.row-controls > * {
  min-width: 0;
}

.na-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.12rem;
  align-items: start;
}

.na-box {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 0.25rem 0.45rem;
  font-size: 0.8rem;
  color: #234352;
}

.na-text {
  display: inline-flex;
  align-items: center;
  gap: 0.22rem;
  line-height: 1.2;
}

.na-lead {
  color: #234352;
  font-weight: 500;
}

.na-text strong {
  color: #183c4b;
  font-weight: 700;
}

.na-hint-inline {
  display: block;
  padding-left: 1.55rem;
  font-size: 0.78rem;
  color: #3d5f6f;
}

.na-hint-inline.na-hint-warning {
  padding-left: 0;
  color: #8a5d1f;
  font-weight: 700;
}

.urban-simple-chooser {
  display: flex;
  align-items: center;
  gap: 0.34rem;
}

.note-box {
  display: grid;
  gap: 0.3rem;
}

.initial-act-fields {
  border: 1px solid #c8d8e3;
  border-radius: 10px;
  background: #f8fcff;
  padding: 0.45rem 0.52rem;
  display: grid;
  gap: 0.42rem;
}

.initial-act-head {
  font-size: 0.8rem;
  color: #2b5d73;
  letter-spacing: 0.01em;
}

.initial-act-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.36rem;
}

.initial-act-grid label {
  display: grid;
  gap: 0.2rem;
  font-size: 0.76rem;
  color: #3f5f6f;
  font-weight: 600;
}

.initial-act-grid label.span-2 {
  grid-column: span 2;
}

.initial-act-grid input,
.initial-act-grid textarea {
  min-height: 34px;
  border: 1px solid #e7dcc2;
  border-radius: 8px;
  padding: 0.38rem 0.48rem;
  background: #fffef7;
  color: #234352;
}

.initial-act-grid label.is-compact,
.initial-act-grid label.is-date {
  justify-self: start;
}

.initial-act-grid label.is-compact input {
  width: min(100%, 18ch);
}

.initial-act-grid label.is-date input {
  width: min(100%, 16ch);
}

.initial-act-grid label.is-wide-row {
  grid-column: 1 / -1;
  justify-self: stretch;
}

.doc-row-initial-concession .row-controls {
  grid-template-columns: 1fr;
  align-items: start;
}

.doc-row-consequence .row-controls {
  grid-template-columns: 1fr;
  align-items: start;
}

.doc-row-planimetry .row-controls {
  grid-template-columns: 1fr;
  align-items: start;
}

.doc-row-urban .row-controls {
  grid-template-columns: 1fr;
  align-items: start;
  gap: 0.36rem;
}

.doc-row-urban .row-detail-info {
  gap: 0.16rem 0.42rem;
}

.doc-row-urban .note-box textarea {
  min-height: 40px;
  padding: 0.36rem 0.5rem;
}

.doc-row-urban .upload-box {
  padding: 0.28rem 0.4rem;
}

.doc-row-urban .upload-toolbar {
  gap: 0.34rem;
}

.doc-row-canone .row-controls {
  grid-template-columns: 1fr;
  align-items: start;
  gap: 0.36rem;
}

.doc-row-canone .row-detail-info {
  gap: 0.16rem 0.42rem;
}

.doc-row-canone .note-box textarea {
  min-height: 40px;
  padding: 0.36rem 0.5rem;
}

.doc-row-canone .upload-box {
  padding: 0.28rem 0.4rem;
}

.doc-row-canone .upload-toolbar {
  gap: 0.34rem;
}

.doc-row-free-entries .row-controls {
  grid-template-columns: 1fr;
  align-items: start;
}

.doc-row-investment-declaration .row-controls {
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  gap: 0.28rem;
}

.doc-row-investment-declaration .note-box {
  width: 100%;
}

.doc-row-s3-002-investments .row-controls {
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  gap: 0.28rem;
}

.doc-row-s3-002-investments .note-box {
  width: 100%;
}

.doc-row-s4-006-accounting,
.doc-row-s4-balance {
  border-color: #7ea8bf;
}

.doc-row-s4-006-accounting.has-uploaded-file,
.doc-row-s4-balance.has-uploaded-file {
  border-color: #83bd91;
  background: #eaf7ee;
}

.doc-row-s4-006-accounting.has-uploaded-file .row-toggle,
.doc-row-s4-balance.has-uploaded-file .row-toggle {
  background: #eaf7ee;
  border-color: #9ccca8;
}

.doc-row-s4-006-accounting.has-uploaded-file .upload-box,
.doc-row-s4-balance.has-uploaded-file .upload-box {
  background: #f3fbf5;
  border-color: #9ccca8;
}

.doc-row-s4-006-accounting .row-controls,
.doc-row-s4-balance .row-controls {
  align-items: start;
}

.doc-row-s4-006-accounting .doc-title,
.doc-row-s4-balance .doc-title {
  font-size: 1.06rem;
}

.doc-row-s4-006-accounting .doc-meta,
.doc-row-s4-balance .doc-meta {
  font-size: 0.9rem;
}

.doc-row-s4-006-accounting .note-box label,
.doc-row-s4-balance .note-box label {
  font-size: 0.9rem;
}

.doc-row-s4-006-accounting .note-box textarea,
.doc-row-s4-006-accounting .upload-toolbar,
.doc-row-s4-006-accounting .counter,
.doc-row-s4-006-accounting .files-list,
.doc-row-s4-balance .note-box textarea,
.doc-row-s4-balance .upload-toolbar,
.doc-row-s4-balance .counter,
.doc-row-s4-balance .files-list {
  font-size: 1rem;
}

.accounting-guide-card {
  width: 100%;
  box-sizing: border-box;
}

.doc-row-assets-register:not(.doc-row-investment-declaration) .row-controls {
  position: relative;
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
}

.doc-row-assets-register:not(.doc-row-investment-declaration) .note-box {
  width: 100%;
}

.assets-register-guide-card {
  width: 100%;
  box-sizing: border-box;
}

.doc-row-assets-register:not(.doc-row-investment-declaration) .row-controls > .upload-box {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip-path: inset(50%);
}

.s3-002-investments-box {
  width: 100%;
}

.s3-002-investment-head {
  grid-template-columns: max-content max-content minmax(0, 1fr) max-content;
}

.s3-002-investment-fields {
  grid-template-columns: minmax(190px, 1fr) minmax(170px, 0.85fr) minmax(0, 1.6fr);
  align-items: end;
}

.s3-002-investment-fields .investment-field.is-date,
.s3-002-investment-fields .investment-field.is-amount {
  grid-column: auto;
}

.s3-002-investment-fields .investment-field.is-desc {
  grid-column: 1 / -1;
}

.s3-002-grid-footer {
  align-items: center;
}

.s3-002-grid-footer .investment-grid-summary {
  margin-left: auto;
}

.initial-act-grid textarea {
  min-height: 58px;
  resize: vertical;
}

.initial-act-actions {
  display: flex;
  align-items: center;
  gap: 0.46rem;
  flex-wrap: wrap;
}

.initial-act-actions .secondary-btn {
  min-height: 32px;
  padding: 0.32rem 0.62rem;
  background: #b6873b;
  border-color: #b6873b;
  color: #ffffff;
}

.initial-act-actions .secondary-btn:hover {
  background: #9e742f;
  border-color: #9e742f;
}

.initial-act-status {
  font-size: 0.75rem;
  color: #4f5d67;
}

.initial-act-status.ok {
  color: #1f6b46;
}

.initial-act-status.warn {
  color: #8a5d1f;
}

.initial-act-status.err {
  color: #9a3529;
}

.initial-act-anomalies {
  margin: 0;
  font-size: 0.74rem;
  color: #8a5d1f;
  font-weight: 700;
}

.consequence-act-fields {
  border: 1px solid #c8d8e3;
  border-radius: 10px;
  background: #f8fcff;
  padding: 0.45rem 0.52rem;
  display: grid;
  gap: 0.45rem;
}

.consequence-act-head {
  font-size: 0.8rem;
  color: #2b5d73;
  letter-spacing: 0.01em;
}

.consequence-act-help {
  margin: 0;
  font-size: 0.74rem;
  color: #3f5f6f;
  font-weight: 600;
}

.consequence-slots-wrap {
  display: grid;
  gap: 0.38rem;
}

.consequence-slot-card {
  border: 1px solid #c8d8e3;
  border-radius: 9px;
  background: #ffffff;
  padding: 0.36rem 0.42rem;
  display: grid;
  gap: 0.34rem;
}

.consequence-slot-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
}

.ghost-btn {
  min-height: 28px;
  padding: 0.2rem 0.5rem;
  border: 1px solid #cbb67f;
  border-radius: 8px;
  background: #fff5dc;
  color: #7b5d22;
  font-size: 0.72rem;
  font-weight: 700;
}

.ghost-btn:hover:not(:disabled) {
  background: #f8eac6;
}

.ghost-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.consequence-slot-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.34rem;
}

.consequence-slot-grid label {
  display: grid;
  gap: 0.2rem;
  font-size: 0.75rem;
  color: #3f5f6f;
  font-weight: 600;
}

.consequence-slot-grid label.span-2 {
  grid-column: span 2;
}

.consequence-slot-grid input,
.consequence-slot-grid select,
.consequence-slot-grid textarea {
  min-height: 34px;
  border: 1px solid #e7dcc2;
  border-radius: 8px;
  padding: 0.36rem 0.48rem;
  background: #fffef7;
  color: #234352;
}

.consequence-slot-grid label.is-slot-kind,
.consequence-slot-grid label.is-compact,
.consequence-slot-grid label.is-date {
  justify-self: start;
}

.consequence-slot-grid label.is-slot-kind select {
  width: min(100%, 17ch);
}

.consequence-slot-grid label.is-compact input {
  width: min(100%, 18ch);
}

.consequence-slot-grid label.is-date input {
  width: min(100%, 16ch);
}

.consequence-slot-grid label.is-wide-row {
  grid-column: 1 / -1;
  justify-self: stretch;
}

.consequence-slot-grid textarea {
  min-height: 56px;
  resize: vertical;
}

.consequence-slot-anomalies {
  margin: 0;
  font-size: 0.73rem;
  color: #8a5d1f;
  font-weight: 700;
}

.consequence-act-actions {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.consequence-act-status {
  font-size: 0.75rem;
  color: #4f5d67;
}

.consequence-act-status.ok {
  color: #1f6b46;
}

.consequence-act-status.warn {
  color: #8a5d1f;
}

.consequence-act-status.err {
  color: #9a3529;
}

.urban-row-fields {
  border: 1px solid #c8d8e3;
  border-radius: 10px;
  background: #f8fcff;
  padding: 0.42rem 0.5rem;
  display: grid;
  gap: 0.36rem;
}

.urban-row-head {
  font-size: 0.78rem;
  color: #2b5d73;
  letter-spacing: 0.01em;
}

.urban-row-help {
  margin: 0;
  font-size: 0.73rem;
  color: #4e6875;
}

.urban-cards-wrap {
  display: grid;
  gap: 0.36rem;
}

.urban-card {
  border: 1px solid #dbe7ef;
  border-radius: 10px;
  background: #ffffff;
  padding: 0.3rem 0.36rem;
  display: grid;
  gap: 0.24rem;
}

.urban-card.open {
  border-color: #7fa7bf;
  box-shadow: 0 0 0 1px #d4e5ef inset;
}

.urban-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.34rem;
}

.urban-card-toggle {
  appearance: none;
  border: 1px solid #b7cfdd;
  border-left: 4px solid #2f6f8c;
  border-radius: 8px;
  background: #eef6fb;
  color: #214a5d;
  width: 100%;
  min-height: 38px;
  padding: 0.28rem 0.44rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 0.46rem;
  text-align: left;
  cursor: pointer;
}

.urban-card-toggle:hover {
  background: #e5f0f7;
}

.urban-card-summary {
  display: grid;
  gap: 0.02rem;
  min-width: 0;
}

.urban-card-summary-main {
  font-size: 0.83rem;
  font-weight: 800;
  color: #1f4e63;
  letter-spacing: 0.01em;
}

.urban-card-summary-title {
  font-size: 0.76rem;
  color: #4f6471;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.urban-card-pill {
  font-size: 0.67rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  border-radius: 999px;
  padding: 0.14rem 0.42rem;
  border: 1px solid #b6c8d4;
  background: #eef2f5;
  color: #3f5865;
}

.urban-card-pill.ok {
  border-color: #7db594;
  background: #edf8f1;
  color: #255f3c;
}

.urban-card-pill.warn {
  border-color: #d5bd89;
  background: #fff7e8;
  color: #8a5d1f;
}

.urban-card-pill.info {
  border-color: #b6c8d4;
  background: #eef2f5;
  color: #3f5865;
}

.urban-card-chevron {
  font-size: 0.72rem;
  color: #2f6279;
}

.urban-card-body {
  display: grid;
  gap: 0.24rem;
}

.urban-card-top .ghost-btn {
  min-height: 32px;
  padding: 0.2rem 0.56rem;
}

.urban-card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.34rem;
}

.urban-card-grid label {
  display: grid;
  gap: 0.18rem;
  font-size: 0.74rem;
  color: #3f5f6f;
  font-weight: 600;
}

.urban-card-grid input,
.urban-card-grid select,
.urban-card-grid textarea {
  min-height: 32px;
  border: 1px solid #e7dcc2;
  border-radius: 8px;
  padding: 0.34rem 0.46rem;
  background: #fffef7;
  color: #234352;
}

.urban-card-grid label.is-compact,
.urban-card-grid label.is-date {
  justify-self: start;
}

.urban-card-grid label.is-compact input,
.urban-card-grid label.is-compact select {
  width: min(100%, 20ch);
}

.urban-card-grid label.is-date input {
  width: min(100%, 16ch);
}

.urban-card-grid label.is-wide-row {
  grid-column: 1 / -1;
  justify-self: stretch;
}

.urban-card-grid label.span-2 {
  grid-column: span 2;
}

.urban-card-grid textarea {
  min-height: 52px;
  resize: vertical;
}

.urban-card-warning {
  margin: 0;
  font-size: 0.73rem;
  color: #8a5d1f;
  font-weight: 700;
}

.urban-card-attachments {
  border: 1px dashed #bfd6e4;
  border-radius: 8px;
  background: #f8fcff;
  padding: 0.34rem;
  display: grid;
  gap: 0.28rem;
}

.urban-card-attachments-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
}

.urban-card-attachments-head strong {
  font-size: 0.74rem;
  color: #235268;
}

.urban-card-attachment-hint {
  font-size: 0.72rem;
  color: #4f6875;
}

.urban-card-attachments-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.42rem;
  flex-wrap: wrap;
  text-align: right;
}

.urban-row-actions {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.urban-row-actions .secondary-btn {
  min-height: 31px;
  padding: 0.3rem 0.68rem;
}

.urban-row-status {
  font-size: 0.75rem;
  color: #4f5d67;
}

.urban-row-status.ok {
  color: #1f6b46;
}

.urban-row-status.warn {
  color: #8a5d1f;
}

.urban-row-status.err {
  color: #9a3529;
}

.canone-row-fields {
  border: 1px solid #c8d8e3;
  border-radius: 10px;
  background: #f8fcff;
  padding: 0.34rem 0.46rem;
  display: grid;
  gap: 0.26rem;
}

.canone-row-head {
  font-size: 0.76rem;
  color: #2b5d73;
  letter-spacing: 0.01em;
}

.canone-row-top {
  display: flex;
  align-items: end;
  gap: 2px;
  flex-wrap: wrap;
}

.canone-row-label {
  display: grid;
  gap: 0.16rem;
  font-size: 0.74rem;
  color: #3f5f6f;
  font-weight: 600;
}

.canone-row-label input {
  min-height: 30px;
  border: 1px solid #e7dcc2;
  border-radius: 8px;
  padding: 0.3rem 0.42rem;
  background: #fffef7;
  color: #234352;
  width: min(100%, 15ch);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.canone-row-top .secondary-btn {
  min-height: 30px;
  min-width: 0;
  padding: 0.26rem 0.62rem;
  background: #b6873b;
  border-color: #b6873b;
  color: #ffffff;
  letter-spacing: 0.01em;
}

.canone-row-top .secondary-btn:hover {
  background: #9e742f;
  border-color: #9e742f;
}

.canone-row-status-row {
  display: block;
}

.canone-row-status {
  display: block;
  font-size: 0.73rem;
  color: #4f5d67;
  line-height: 1.2;
  margin-top: 0;
}

.canone-row-status.ok {
  color: #1f6b46;
}

.canone-row-status.warn {
  color: #8a5d1f;
}

.canone-row-status.err {
  color: #9a3529;
}

.planimetry-fields {
  border: 1px solid #c8d8e3;
  border-radius: 10px;
  background: #f8fcff;
  padding: 0.45rem 0.52rem;
  display: grid;
  gap: 0.42rem;
}

.planimetry-head {
  font-size: 0.8rem;
  color: #2b5d73;
  letter-spacing: 0.01em;
}

.planimetry-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.36rem;
}

.planimetry-grid label {
  display: grid;
  gap: 0.2rem;
  font-size: 0.76rem;
  color: #3f5f6f;
  font-weight: 600;
}

.planimetry-grid input,
.planimetry-grid select,
.planimetry-grid textarea {
  min-height: 34px;
  border: 1px solid #e7dcc2;
  border-radius: 8px;
  padding: 0.38rem 0.48rem;
  background: #fffef7;
  color: #234352;
}

.planimetry-grid label.is-compact,
.planimetry-grid label.is-date {
  justify-self: start;
}

.planimetry-grid label.is-compact input,
.planimetry-grid label.is-compact select {
  width: min(100%, 18ch);
}

.planimetry-grid label.is-date input {
  width: min(100%, 16ch);
}

.planimetry-grid label.is-wide-row {
  grid-column: 1 / -1;
  justify-self: stretch;
}

.planimetry-grid label.required {
  color: #8a5d1f;
}

.planimetry-grid label.required::after {
  content: " *";
  color: #a43f32;
  font-weight: 700;
}

.planimetry-grid textarea {
  min-height: 56px;
  resize: vertical;
}

.planimetry-actions {
  display: flex;
  align-items: center;
  gap: 0.46rem;
  flex-wrap: wrap;
}

.planimetry-actions .secondary-btn {
  min-height: 32px;
  padding: 0.32rem 0.62rem;
  background: #b6873b;
  border-color: #b6873b;
  color: #ffffff;
}

.planimetry-actions .secondary-btn:hover {
  background: #9e742f;
  border-color: #9e742f;
}

.planimetry-status {
  font-size: 0.75rem;
  color: #4f5d67;
}

.planimetry-status.ok {
  color: #1f6b46;
}

.planimetry-status.warn {
  color: #8a5d1f;
}

.planimetry-status.err {
  color: #9a3529;
}

.planimetry-anomalies {
  margin: 0;
  font-size: 0.74rem;
  color: #8a5d1f;
  font-weight: 700;
}

.free-entries-box {
  border: 1px solid #c8d8e3;
  border-radius: 10px;
  background: #f8fcff;
  padding: 0.45rem 0.52rem;
  display: grid;
  gap: 0.42rem;
}

.s3-xtra-guide-card {
  width: 100%;
  box-sizing: border-box;
}

.s3-xtra-free-entries-box {
  border-radius: 8px;
  padding: 0.6rem;
  gap: 0.58rem;
}

.s3-xtra-free-entries-box.has-data {
  border-color: #b9ddc7;
  background: #f1fbf4;
}

.s3-xtra-free-entries-box .free-entries-wrap {
  gap: 0.58rem;
}

.s3-xtra-free-entries-box .free-entry-card {
  border-radius: 8px;
  padding: 0.72rem;
  gap: 0.58rem;
}

.s3-xtra-free-entries-box .free-entry-card.has-data {
  border-color: #b9ddc7;
  background: #fbfffd;
}

.s3-xtra-free-entries-box .free-entry-top strong {
  color: #17495e;
  font-size: 1.12rem;
  font-weight: 700;
  line-height: 1.18;
}

.s3-xtra-free-entries-box .free-entry-card label {
  color: #305b6c;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.18;
}

.s3-xtra-free-entries-box .free-entry-card textarea {
  min-height: 76px;
  border-color: #c9d9e2;
  background: #ffffff;
  color: #123443;
  font-size: 1.02rem;
  line-height: 1.28;
}

.s3-xtra-free-entries-box .free-entry-card.has-data textarea {
  background: #ffffff;
}

.s3-xtra-free-entries-box .free-entry-actions .secondary-btn,
.s3-xtra-free-entries-box .free-entries-footer .secondary-btn {
  min-height: 38px;
  padding: 0.38rem 0.75rem;
  font-size: 1rem;
  border-radius: 7px;
  font-weight: 700;
}

.s3-xtra-free-entries-box .free-entry-actions .counter,
.s3-xtra-free-entries-box .free-entry-status {
  color: #335262;
  font-size: 1rem;
  font-weight: 600;
}

.s3-xtra-free-entries-box .free-entry-status.ok {
  color: #236a45;
}

.s3-xtra-free-entries-box .free-entry-status.warn {
  color: #8a5d1f;
}

.s3-xtra-free-entries-box .free-entry-status.err {
  color: #9a3529;
}

.s3-xtra-free-entries-box .free-entry-top .ghost-btn {
  min-height: 34px;
  padding: 0.28rem 0.55rem;
  font-size: 0.94rem;
  border-radius: 7px;
  line-height: 1;
}

.s3-xtra-free-entries-box .files-list li {
  font-size: 0.96rem;
}

.free-entries-head {
  font-size: 0.8rem;
  color: #2b5d73;
  letter-spacing: 0.01em;
}

.free-entries-help {
  margin: 0;
  font-size: 0.74rem;
  color: #3f5f6f;
  font-weight: 600;
}

.free-entries-wrap {
  display: grid;
  gap: 0.42rem;
}

.free-entry-card {
  border: 1px solid #c8d8e3;
  border-radius: 9px;
  background: #ffffff;
  padding: 0.4rem 0.45rem;
  display: grid;
  gap: 0.34rem;
}

.free-entry-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
}

.free-entry-card label {
  display: grid;
  gap: 0.2rem;
  font-size: 0.76rem;
  color: #3f5f6f;
  font-weight: 600;
}

.free-entry-card textarea {
  min-height: 56px;
  border: 1px solid #e7dcc2;
  border-radius: 8px;
  padding: 0.36rem 0.48rem;
  background: #fffef7;
  color: #234352;
  resize: vertical;
}

.free-entry-actions {
  display: flex;
  align-items: center;
  gap: 0.44rem;
  flex-wrap: wrap;
}

.free-entry-status {
  font-size: 0.75rem;
  color: #4f5d67;
}

.free-entry-status.ok {
  color: #1f6b46;
}

.free-entry-status.warn {
  color: #8a5d1f;
}

.free-entry-status.err {
  color: #9a3529;
}

.free-entries-footer {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.free-entries-summary {
  font-size: 0.8rem;
  color: #335262;
  font-weight: 600;
}

.investment-grid-box {
  border: 1px solid #c8d8e3;
  border-radius: 8px;
  background: #f8fcff;
  padding: 0.6rem;
  display: grid;
  gap: 0.58rem;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
  container-type: inline-size;
}

.investment-guide-card {
  border: 1px solid #ecd28a;
  border-radius: 7px;
  background: #fff8d8;
  color: #4d431f;
  padding: 0.48rem 0.65rem;
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  align-items: center;
  gap: 0.65rem;
}

.investment-guide-card strong {
  font-size: 1.06rem;
  font-weight: 600;
  color: #573f12;
  white-space: nowrap;
}

.investment-guide-card p {
  margin: 0;
  font-size: 1.04rem;
  line-height: 1.34;
  min-width: 0;
  overflow-wrap: anywhere;
  border-left: 1px solid rgba(168, 119, 37, 0.34);
  padding-left: 0.74rem;
}

.investment-guide-card p strong {
  white-space: normal;
}

.accounting-balance-guide-card p {
  display: grid;
  gap: 0.05rem;
}

.accounting-balance-guide-card .accounting-guide-line {
  display: block;
  line-height: 1.26;
}

.investment-grid-status {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
}

.investment-grid-status.info {
  color: #2f6178;
}

.investment-grid-status.ok {
  color: #236a45;
}

.investment-grid-status.warn {
  color: #8a5d1f;
}

.investment-grid-status.err {
  color: #9a3529;
}

.investment-cards-wrap {
  display: grid;
  gap: 0.7rem;
}

.investment-asset-card {
  border: 1px solid #c8d8e3;
  border-radius: 8px;
  background: #ffffff;
  padding: 0.72rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.72rem;
  align-items: start;
  min-width: 0;
}

.investment-asset-card.is-saved {
  border-color: #9cc5b0;
  background: #fbfffd;
}

.investment-asset-card.is-empty {
  border-color: #b8c4ca;
  background: #e3e9ec;
}

.investment-asset-card.is-valued {
  border-color: #b9ddc7;
  background: #f1fbf4;
}

.investment-asset-card.is-filling {
  border-color: #ecd99a;
  background: #fffbea;
}

.investment-asset-card.is-live-filling {
  border-color: #ead27b;
  background: #fff7cf;
}

.investment-asset-card.is-empty .investment-asset-docs {
  border-color: #c3ccd1;
  background: #e9eef1;
}

.investment-asset-card.is-empty .investment-asset-head strong,
.investment-asset-card.is-empty .investment-field span,
.investment-asset-card.is-empty .investment-asset-docs-head strong,
.investment-asset-card.is-empty .investment-asset-docs-head span {
  color: #48606b;
}

.investment-asset-card.is-valued .investment-asset-docs {
  background: #f6fcf8;
}

.investment-asset-card.is-filling .investment-asset-docs {
  background: #fffdf2;
}

.investment-asset-card.is-live-filling .investment-asset-docs {
  background: #fff9dd;
}

.investment-asset-head {
  display: grid;
  grid-template-columns: max-content max-content minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.6rem;
  align-content: center;
}

.investment-asset-head strong {
  color: #17495e;
  font-size: 1.12rem;
  font-weight: 700;
  line-height: 1.18;
}

.investment-asset-chip {
  justify-self: start;
  border: 1px solid #d8c4a2;
  border-radius: 999px;
  background: #fff7ea;
  color: #8a5d1f;
  padding: 0.15rem 0.45rem;
  font-size: 0.86rem;
  font-weight: 600;
  text-transform: uppercase;
}

.investment-asset-chip.ok {
  border-color: #b8d9c5;
  background: #eaf7ee;
  color: #236a45;
}

.investment-asset-chip.warn {
  border-color: #e1c279;
  background: #fff5d9;
  color: #8a5d1f;
}

.investment-asset-doc-summary {
  min-width: 0;
  color: #3d6374;
  font-size: 0.96rem;
  font-weight: 600;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.investment-row-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.investment-row-actions button {
  min-height: 34px;
  padding: 0.28rem 0.55rem;
  font-size: 0.94rem;
  border-radius: 7px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.investment-row-save-btn {
  border-color: #8ec5a6;
  background: #e9f7ef;
  color: #174f3a;
  font-weight: 700;
}

.investment-row-save-btn:hover:not(:disabled) {
  border-color: #75b891;
  background: #d8f0e2;
  color: #123f2f;
}

.investment-remove-btn {
  justify-self: start;
  min-height: 26px;
  padding: 0.14rem 0.34rem;
  font-size: 0.78rem;
  border-radius: 6px;
}

.investment-asset-fields {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.48rem 0.68rem;
  min-width: 0;
}

.investment-field {
  display: grid;
  gap: 0.16rem;
  min-width: 0;
}

.investment-field.is-desc {
  grid-column: 1 / span 3;
}

.investment-field.is-location {
  grid-column: 1 / span 3;
}

.investment-field.is-proof {
  grid-column: 4 / span 3;
}

.investment-field span {
  color: #305b6c;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.18;
}

.investment-field input,
.investment-field select,
.investment-field textarea {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  border: 1px solid #c9d9e2;
  border-radius: 5px;
  background: #ffffff;
  color: #123443;
  padding: 0.36rem 0.48rem;
  font: inherit;
  font-size: 1.02rem;
  min-height: 38px;
  height: 38px;
  line-height: 1.22;
}

.investment-field .investment-amount-input {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.investment-field input.investment-longtext-input {
  white-space: nowrap;
}

.investment-field textarea {
  display: block;
  min-height: 38px;
  height: 38px;
  line-height: 1.22;
  resize: none;
}

.investment-field textarea.investment-longtext-input {
  overflow: hidden;
  max-height: 180px;
}

.investment-field textarea.investment-longtext-input:focus {
  overflow: auto;
}

.s3-002-period-warning {
  width: min(100%, 760px);
  justify-self: center;
  margin: -0.22rem auto 0;
  padding: 0.34rem 0.48rem;
  border-radius: 7px;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.28;
  text-align: center;
}

.s3-002-period-warning.ok {
  border: 1px solid #b8d9c5;
  background: #eaf7ee;
  color: #236a45;
}

.s3-002-period-warning.warn {
  border: 1px solid #e2a2a2;
  background: #fff0f0;
  color: #9a3529;
}

.s3-002-investments-box .investment-grid-status.err {
  width: min(100%, 820px);
  justify-self: center;
  padding: 0.42rem 0.55rem;
  border: 1px solid #e2a2a2;
  border-radius: 7px;
  background: #fff0f0;
  text-align: center;
  line-height: 1.3;
}

.investment-asset-docs {
  grid-column: 1 / -1;
  border: 1px dashed #bdd3df;
  border-radius: 6px;
  background: #f6fbfd;
  padding: 0.12rem 0.14rem;
  display: grid;
  gap: 0.08rem;
  min-width: 0;
  align-self: stretch;
  align-content: start;
  overflow: hidden;
}

.investment-asset-main-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  justify-content: flex-end;
  border-top: 1px solid #d8e5ec;
  padding-top: 0.68rem;
}

.investment-asset-main-actions button {
  min-height: 40px;
  padding: 0.42rem 0.82rem;
  font-size: 1rem;
  border-radius: 7px;
  font-weight: 700;
}

.investment-documents-btn {
  background: #0d777d;
  border-color: #0d777d;
  color: #ffffff;
}

.investment-documents-btn:hover:not(:disabled) {
  background: #095f64;
  border-color: #095f64;
}

.investment-revaluation-btn {
  border-color: #bf9d51;
  background: #fff8e4;
  color: #674815;
}

.investment-revaluation-btn:hover:not(:disabled) {
  border-color: #a88538;
  background: #fff0c7;
}

.investment-revaluation-btn.active {
  border-color: #2f8b61;
  background: #ecf7ee;
  color: #1e5f40;
}

.investment-documents-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(12, 33, 45, 0.24);
}

.investment-documents-modal {
  position: fixed;
  left: 50%;
  top: 9vh;
  transform: translateX(-50%);
  width: min(1040px, calc(100vw - 32px));
  max-height: min(780px, calc(100vh - 56px));
  border: 1px solid #86b9d1;
  border-radius: 10px;
  background: #f8fcff;
  box-shadow: 0 22px 60px rgba(10, 33, 45, 0.28);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  overflow: hidden;
}

.s3-002-documents-modal {
  resize: both;
  min-width: min(720px, calc(100vw - 32px));
  min-height: min(520px, calc(100vh - 56px));
}

.investment-documents-modal-head {
  cursor: move;
  user-select: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid #c8d8e3;
  background: #eaf4f9;
}

.investment-documents-modal-title {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.investment-documents-modal-title h3 {
  margin: 0;
  color: #123f55;
  font-size: 1.55rem;
  font-weight: 800;
  line-height: 1.18;
}

.investment-documents-modal-title p {
  margin: 0;
  color: #476b7b;
  font-size: 0.9rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.investment-documents-modal-body {
  min-height: 0;
  overflow: auto;
  padding: 1rem;
}

.investment-documents-modal-body .investment-asset-docs {
  border-style: solid;
  border-color: #c6dce8;
  background: #ffffff;
  padding: 0.8rem;
  gap: 0.65rem;
}

.investment-documents-modal-body .investment-asset-docs-head {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.28rem;
}

.investment-documents-modal-body .investment-asset-docs-head strong {
  font-size: 1.08rem;
}

.investment-documents-modal-body .investment-asset-docs-head span {
  max-width: 920px;
  color: #3f6375;
  font-size: 0.94rem;
  font-weight: 600;
  line-height: 1.34;
  white-space: pre-line;
}

.investment-documents-modal-body .investment-evidence-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.investment-documents-modal-body .investment-evidence-row {
  padding: 0.52rem;
  border-radius: 8px;
  gap: 0.35rem 0.5rem;
}

.investment-documents-modal-body .investment-evidence-info strong {
  font-size: 0.98rem;
}

.investment-documents-modal-body .investment-evidence-info small {
  font-size: 0.82rem;
}

.investment-documents-modal-body .investment-evidence-actions button,
.investment-documents-modal-body .investment-file-actions button {
  width: 32px;
  min-width: 32px;
  height: 32px;
  min-height: 32px;
  font-size: 0.92rem;
}

.s3-002-documents-modal .investment-evidence-actions .investment-evidence-upload-btn {
  width: auto;
  min-width: 96px;
  padding: 0.32rem 0.62rem;
  white-space: nowrap;
}

.s3-002-documents-modal .investment-file-actions button {
  width: auto;
  min-width: 62px;
  padding: 0.3rem 0.52rem;
}

.s3-002-evidence-row.is-required.is-missing {
  border-color: #e2a2a2;
  background: #fff0f0;
}

.investment-documents-modal-body .investment-evidence-files-list li {
  padding: 0.3rem 0.38rem;
  font-size: 0.84rem;
}

.investment-documents-modal-empty {
  margin: 0;
  color: #8a5d1f;
  font-weight: 700;
}

.investment-documents-modal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.9rem;
  padding: 0.75rem 1rem;
  border-top: 1px solid #c8d8e3;
  background: #f1f8fb;
}

.investment-documents-modal-status {
  margin: 0;
  min-width: 0;
  color: #2f6178;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.3;
  white-space: pre-line;
}

.investment-documents-modal-status.ok {
  color: #236a45;
}

.investment-documents-modal-status.warn {
  color: #8a5d1f;
}

.investment-documents-modal-status.err {
  color: #9a3529;
  background: #fff1ee;
  border: 1px solid #e0a59d;
  border-radius: 7px;
  padding: 0.45rem 0.55rem;
}

.investment-documents-modal-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.investment-documents-modal-actions button {
  min-height: 38px;
  padding: 0.38rem 0.75rem;
  font-size: 0.94rem;
  border-radius: 7px;
  font-weight: 700;
}

.investment-documents-auto-na-btn {
  border-color: #b99548;
  background: #fff7dd;
  color: #654714;
}

.investment-documents-auto-na-btn:hover:not(:disabled) {
  border-color: #a17f34;
  background: #ffefbf;
}

.investment-documents-verify-btn {
  background: #0d777d;
  border-color: #0d777d;
  color: #ffffff;
}

.investment-documents-verify-btn:hover:not(:disabled) {
  background: #095f64;
  border-color: #095f64;
}

.investment-revaluation-modal {
  width: min(1080px, calc(100vw - 32px));
  min-width: min(760px, calc(100vw - 32px));
  min-height: min(520px, calc(100vh - 56px));
  border-color: #d1b16b;
  background: #fffdf7;
  resize: both;
  overflow: hidden;
}

.investment-revaluation-modal-head {
  background: #fff4cf;
  border-bottom-color: #e0c783;
}

.investment-revaluation-guide {
  margin: 0 0 0.75rem;
  padding: 0.72rem 0.82rem;
  border: 1px solid #e0c783;
  border-radius: 8px;
  background: #fff9e7;
  color: #604515;
  font-size: 0.96rem;
  font-weight: 700;
  line-height: 1.36;
  white-space: pre-line;
}

.investment-revaluation-form {
  display: grid;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.investment-revaluation-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  width: fit-content;
  color: #21495d;
  font-size: 1rem;
  font-weight: 800;
}

.investment-revaluation-toggle input {
  width: 18px;
  height: 18px;
  accent-color: #0d777d;
}

.investment-revaluation-fields {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

.investment-revaluation-field {
  display: grid;
  gap: 0.22rem;
  min-width: 0;
  color: #2b5d73;
  font-size: 0.88rem;
  font-weight: 800;
}

.investment-revaluation-field span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.investment-revaluation-field input,
.investment-revaluation-field textarea {
  min-width: 0;
  width: 100%;
  border: 1px solid #b9cfdb;
  border-radius: 7px;
  padding: 0.44rem 0.5rem;
  background: #ffffff;
  color: #173f53;
  font-size: 0.94rem;
  font-weight: 650;
}

.investment-revaluation-field textarea {
  min-height: 78px;
  resize: vertical;
}

.investment-revaluation-field-revaluation_notes_concessionario {
  grid-column: 1 / -1;
}

.investment-revaluation-field-revaluation_notes_concessionario textarea {
  min-height: 96px;
}

.investment-revaluation-field input:disabled,
.investment-revaluation-field textarea:disabled {
  background: #eef3f6;
  color: #6d8290;
}

.investment-revaluation-docs {
  border-color: #e0c783;
  background: #ffffff;
}

.investment-revaluation-evidence-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.investment-revaluation-reuse {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.45rem;
  align-items: center;
  padding: 0.38rem;
  border: 1px dashed #d5b267;
  border-radius: 7px;
  background: #fff9e7;
}

.investment-revaluation-reuse select {
  min-width: 0;
  width: 100%;
  border: 1px solid #d0b778;
  border-radius: 6px;
  padding: 0.36rem 0.44rem;
  color: #604515;
  font-weight: 650;
}

.investment-revaluation-reuse-btn {
  border-color: #bf9d51;
  background: #fff8e4;
  color: #674815;
  white-space: nowrap;
}

.investment-revaluation-save-draft-btn {
  border-color: #bf9d51;
  background: #fff8e4;
  color: #674815;
}

@media (max-width: 760px) {
  .investment-revaluation-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .investment-revaluation-evidence-list {
    grid-template-columns: 1fr;
  }

  .investment-revaluation-reuse {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .investment-revaluation-fields {
    grid-template-columns: 1fr;
  }
}

.investment-asset-docs-head {
  display: grid;
  gap: 0.02rem;
}

.investment-asset-docs-head strong {
  color: #21495d;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.08;
}

.investment-asset-docs-head span {
  color: #5b7483;
  font-size: 0.7rem;
  font-weight: 500;
  line-height: 1.08;
}

.investment-asset-actions {
  display: flex;
  align-items: center;
  gap: 0.12rem;
  flex-wrap: wrap;
}

.investment-asset-actions .secondary-btn {
  min-height: 26px;
  padding: 0.18rem 0.34rem;
  font-size: 0.7rem;
  border-radius: 6px;
}

.investment-asset-actions .investment-pdf-icon-btn {
  width: 27px;
  min-width: 27px;
  height: 20px;
  min-height: 20px;
  padding: 0;
  font-size: 0.66rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.investment-files-list li.investment-asset-doc-empty {
  grid-template-columns: 1fr;
  background: #f3f8fc;
  color: #5f7684;
  font-style: italic;
  font-size: 0.7rem;
  padding: 0.1rem 0.14rem;
}

.investment-files-list li {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.12rem;
  align-items: center;
  padding: 0.1rem 0.12rem;
  border-radius: 6px;
  font-size: 0.72rem;
}

.investment-files-list li > :first-child {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  overflow-wrap: normal;
  word-break: normal;
}

.investment-evidence-docs {
  gap: 0.07rem;
}

.investment-evidence-locked {
  display: flex;
  align-items: center;
  gap: 0.18rem;
  min-width: 0;
  color: #5f7684;
  font-size: 0.72rem;
}

.investment-evidence-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.07rem 0.1rem;
  min-width: 0;
}

.investment-evidence-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  gap: 0.04rem 0.08rem;
  align-items: center;
  min-width: 0;
  padding: 0.08rem 0.1rem;
  border: 1px solid #c8d8e3;
  border-radius: 5px;
  background: #ffffff;
}

.investment-evidence-row.is-complete {
  border-color: #b7dbc6;
  background: #f3fbf6;
}

.investment-evidence-row.is-missing {
  border-color: #e5d0aa;
  background: #fffaf0;
}

.investment-evidence-row.is-na {
  border-color: #d6c7a3;
  background: #fbf7e8;
}

.investment-evidence-info {
  display: grid;
  min-width: 0;
  gap: 0.01rem;
}

.investment-evidence-info strong {
  color: #21495d;
  font-size: 0.76rem;
  font-weight: 500;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.investment-evidence-info small {
  color: #5f7684;
  font-size: 0.68rem;
  line-height: 1.08;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.investment-evidence-actions {
  display: flex;
  align-items: center;
  gap: 0.05rem;
}

.investment-evidence-actions button {
  width: 24px;
  min-width: 24px;
  height: 24px;
  min-height: 24px;
  padding: 0;
  border-radius: 5px;
  font-size: 0.78rem;
  line-height: 1;
}

.investment-evidence-icon-btn,
.investment-asset-actions .investment-pdf-icon-btn {
  border-color: #9fc9df;
  background: #e8f5fb;
  color: #17495e;
}

.investment-evidence-icon-btn:hover:not(:disabled),
.investment-asset-actions .investment-pdf-icon-btn:hover:not(:disabled) {
  border-color: #7eb6d1;
  background: #d8edf7;
  color: #10384a;
}

.investment-evidence-na-btn.active {
  background: #ecf7ee;
  border-color: #9cc5b0;
  color: #236a45;
}

.investment-evidence-files-list {
  grid-column: 1 / -1;
  margin-top: 0.02rem;
}

.investment-evidence-files-list li {
  padding: 0.06rem 0.08rem;
  font-size: 0.68rem;
}

.investment-evidence-legacy {
  grid-column: 1 / -1;
  display: grid;
  gap: 0.04rem;
  border: 1px dashed #d2b889;
  border-radius: 5px;
  padding: 0.06rem;
  background: #fffaf0;
}

.investment-evidence-legacy > strong {
  color: #8a5d1f;
  font-size: 0.58rem;
}

.investment-evidence-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10020;
  padding: 1rem;
  background: rgba(12, 33, 45, 0.32);
}

.investment-evidence-modal {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(520px, 96vw);
  border: 1px solid #9ec4d7;
  border-radius: 8px;
  background: #f8fcff;
  box-shadow: 0 18px 48px rgba(10, 33, 45, 0.24);
  padding: 0.7rem;
  display: grid;
  gap: 0.55rem;
}

.investment-evidence-modal-head {
  cursor: move;
  user-select: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}

.investment-evidence-modal-head strong {
  color: #173f53;
}

.investment-evidence-reason-label {
  display: grid;
  gap: 0.18rem;
  color: #2b5d73;
  font-weight: 700;
}

.investment-evidence-reason-label textarea {
  min-height: 92px;
  border: 1px solid #b9cfdb;
  border-radius: 7px;
  padding: 0.42rem 0.5rem;
  resize: vertical;
}

.investment-evidence-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.4rem;
}

.investment-evidence-save-btn {
  border-color: #0d777d;
  background: #0d777d;
  color: #fff;
}

.investment-evidence-save-btn:hover:not(:disabled) {
  background: #095f64;
}

.investment-file-info {
  display: grid;
  gap: 0;
  min-width: 0;
}

.investment-file-info strong,
.investment-file-info small {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  line-height: 1.05;
}

.investment-file-info small {
  color: #6d8290;
  font-size: 0.68rem;
}

.investment-file-actions {
  gap: 0.08rem;
}

.investment-file-actions button {
  width: 24px;
  min-width: 24px;
  height: 24px;
  min-height: 24px;
  padding: 0;
  border-radius: 5px;
  font-size: 0.78rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.investment-grid-footer {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.investment-grid-footer button {
  min-height: 40px;
  padding: 0.42rem 0.82rem;
  font-size: 1rem;
  border-radius: 7px;
}

.investment-grid-summary {
  margin: 0;
  color: #335262;
  font-size: 1rem;
  font-weight: 600;
}

@container (max-width: 900px) {
  .investment-asset-card {
    grid-template-columns: 1fr;
  }

  .investment-asset-docs {
    grid-column: 1 / -1;
  }

  .investment-asset-head {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .investment-row-actions {
    justify-content: flex-start;
  }

  .investment-asset-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .investment-field.is-desc,
  .investment-field.is-location,
  .investment-field.is-proof {
    grid-column: auto;
  }

  .s3-002-investment-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .s3-002-investment-fields .investment-field.is-desc {
    grid-column: 1 / -1;
  }

  .s3-002-grid-footer .investment-grid-summary {
    margin-left: 0;
    width: 100%;
  }
}

@container (max-width: 640px) {
  .investment-asset-card {
    grid-template-columns: 1fr;
  }

  .investment-asset-head,
  .investment-asset-fields,
  .investment-asset-docs {
    grid-column: 1;
  }

  .investment-asset-fields {
    grid-template-columns: 1fr;
  }

  .investment-field.is-desc,
  .investment-field.is-location,
  .investment-field.is-proof {
    grid-column: auto;
  }

  .s3-002-investment-fields {
    grid-template-columns: 1fr;
  }

  .s3-002-investment-fields .investment-field.is-desc,
  .s3-002-investment-fields .investment-field.is-date,
  .s3-002-investment-fields .investment-field.is-amount {
    grid-column: auto;
  }

  .investment-evidence-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .investment-documents-modal-body .investment-evidence-list {
    grid-template-columns: 1fr;
  }

  .investment-documents-modal-title h3 {
    font-size: 1.28rem;
  }

  .investment-documents-modal-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .investment-documents-modal-actions {
    justify-content: flex-start;
  }
}

.assets-method-box {
  border: 1px solid #c8d8e3;
  border-radius: 8px;
  background: #f8fcff;
  padding: 0.6rem;
  display: grid;
  gap: 0.58rem;
  width: 100%;
  box-sizing: border-box;
}

.assets-method-head {
  display: grid;
  gap: 0.2rem;
  color: #2b5d73;
}

.assets-method-head strong {
  font-size: 1.06rem;
  color: #123f55;
  font-weight: 700;
}

.assets-method-head p {
  margin: 0;
  color: #345f72;
  font-size: 1.04rem;
  font-weight: 600;
  line-height: 1.34;
  white-space: pre-line;
}

.assets-method-list {
  display: flex;
  align-items: stretch;
  gap: 0.42rem;
  flex-wrap: wrap;
}

.assets-method-card {
  appearance: none;
  border: 1px solid #b9cdda;
  border-radius: 7px;
  background: #ffffff;
  color: #21495d;
  min-height: 34px;
  padding: 0.28rem 0.55rem;
  font-size: 0.94rem;
  font-weight: 800;
  line-height: 1.1;
  cursor: pointer;
}

.assets-method-card.active {
  border-color: #2f7aa0;
  background: #eaf5fa;
  color: #123f55;
  box-shadow: 0 0 0 1px rgba(47, 122, 160, 0.18);
}

.assets-method-card:hover:not(:disabled) {
  border-color: #6fa3bd;
  background: #f0f8fb;
}

.assets-method-panel {
  border: 1px solid #d4e4ec;
  border-radius: 8px;
  background: #ffffff;
  padding: 0.56rem 0.62rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.65rem;
}

.assets-method-panel-text {
  display: grid;
  gap: 0.16rem;
  min-width: 0;
}

.assets-method-panel-text strong {
  font-size: 1rem;
  color: #1d4f66;
}

.assets-method-panel-text p {
  margin: 0;
  font-size: 0.96rem;
  color: #3f5f6f;
  line-height: 1.28;
  font-weight: 600;
}

.assets-method-action {
  min-height: 38px;
  padding: 0.4rem 0.72rem;
  white-space: nowrap;
  font-size: 1rem;
  font-weight: 800;
}

.assets-method-action.assets-method-action-review {
  border: 1px solid #b48a36;
  background: linear-gradient(135deg, #c89a3d 0%, #af7e2a 100%);
  color: #fff9ed;
  box-shadow: 0 4px 11px rgba(126, 87, 25, 0.26);
}

.assets-method-action.assets-method-action-review:hover {
  background: linear-gradient(135deg, #d3a649 0%, #bc8930 100%);
}

.assets-method-action.assets-method-action-pulse {
  animation: assets-method-review-pulse 1.25s ease-in-out 8;
}

.assets-method-inline-hint {
  margin: 0.02rem 0 0;
  font-size: 0.72rem;
  line-height: 1.28;
  color: #7b5615;
  font-weight: 700;
}

.assets-method-inline-hint.subtle {
  color: #8c6a2a;
  font-weight: 600;
}

.assets-method-inline-hint.ok {
  color: #236845;
  font-weight: 700;
}

@keyframes assets-method-review-pulse {
  0% {
    box-shadow: 0 4px 11px rgba(126, 87, 25, 0.24);
    transform: translateY(0);
  }

  50% {
    box-shadow: 0 0 0 4px rgba(207, 162, 74, 0.22), 0 6px 14px rgba(126, 87, 25, 0.3);
    transform: translateY(-1px);
  }

  100% {
    box-shadow: 0 4px 11px rgba(126, 87, 25, 0.24);
    transform: translateY(0);
  }
}

.assets-method-hint {
  margin: 0;
  border: 1px solid #d4e3ea;
  border-radius: 7px;
  background: #eef7fb;
  padding: 0.42rem 0.52rem;
  font-size: 0.96rem;
  color: #2f6781;
  font-weight: 600;
  line-height: 1.28;
}

.assets-method-files {
  border: 1px dashed #bdd3df;
  border-radius: 8px;
  background: #ffffff;
  padding: 0.5rem 0.55rem;
  display: grid;
  gap: 0.42rem;
}

.assets-method-files-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.assets-method-files-head strong {
  color: #1d4f66;
  font-size: 1rem;
}

.assets-method-files-head span {
  color: #335262;
  font-size: 0.9rem;
  font-weight: 700;
}

.assets-method-files-empty {
  margin: 0;
  color: #5b7380;
  font-size: 0.96rem;
}

.assets-method-file-list {
  margin-top: 0;
}

.assets-acquired-card {
  border: 1px solid #b9ddc7;
  border-radius: 8px;
  background: #f1fbf4;
  padding: 0.72rem;
  display: grid;
  gap: 0.72rem;
  width: 100%;
  box-sizing: border-box;
}

.assets-acquired-head {
  display: grid;
  gap: 0.18rem;
}

.assets-acquired-head strong {
  font-size: 1.12rem;
  color: #174f3a;
  font-weight: 700;
  line-height: 1.18;
}

.assets-acquired-head p {
  margin: 0;
  color: #245a41;
  font-size: 1.04rem;
  font-weight: 600;
  line-height: 1.34;
}

.assets-acquired-summary {
  display: grid;
  grid-template-columns: repeat(5, minmax(118px, 1fr));
  gap: 0.38rem;
}

.assets-acquired-summary-item {
  min-width: 0;
  border: 1px solid #c7e2d0;
  border-radius: 7px;
  background: #fbfffd;
  padding: 0.42rem 0.48rem;
  display: grid;
  gap: 0.08rem;
}

.assets-acquired-summary-item span {
  color: #305b6c;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.18;
}

.assets-acquired-summary-item strong {
  color: #123443;
  font-size: 1.02rem;
  line-height: 1.22;
  overflow-wrap: anywhere;
}

.assets-acquired-summary-item.ok strong {
  color: #196a45;
}

.assets-acquired-summary-item.warn strong {
  color: #a25d12;
}

.assets-acquired-preview {
  border: 1px dashed #a8d0b7;
  border-radius: 8px;
  background: #fbfffd;
  padding: 0.5rem 0.55rem;
  display: grid;
  gap: 0.24rem;
}

.assets-acquired-preview > span {
  color: #174f3a;
  font-size: 1rem;
  font-weight: 700;
}

.assets-acquired-preview ul {
  margin: 0;
  padding-left: 1.05rem;
  display: grid;
  gap: 0.12rem;
}

.assets-acquired-preview li,
.assets-acquired-preview p {
  margin: 0;
  color: #315b6e;
  font-size: 0.96rem;
  line-height: 1.3;
  font-weight: 500;
}

.assets-acquired-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.42rem;
}

.assets-acquired-btn {
  min-height: 38px;
  padding: 0.4rem 0.72rem;
  font-size: 1rem;
  font-weight: 700;
}

.assets-acquired-remove {
  border-color: #bc6a5e;
  background: #fff0ed;
  color: #8f2f25;
}

.assets-acquired-remove:hover:not(:disabled) {
  border-color: #a94e42;
  background: #ffe4df;
}

.assets-acquired-verify.needs-review {
  border-color: #b48a36;
  background: linear-gradient(135deg, #c89a3d 0%, #af7e2a 100%);
  color: #fff9ed;
  box-shadow: 0 4px 11px rgba(126, 87, 25, 0.22);
}

.assets-upload-source-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1930;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
  background: rgba(10, 29, 42, 0.46);
}

.assets-upload-source-modal-backdrop[hidden] {
  display: none !important;
}

.assets-upload-source-modal {
  width: min(760px, 96vw);
  border: 1px solid #a8bfcc;
  border-radius: 12px;
  background: #f7fbfe;
  box-shadow: 0 20px 48px rgba(8, 25, 38, 0.34);
  padding: 0.74rem 0.8rem;
  display: grid;
  gap: 0.5rem;
  color: #133f52;
}

.assets-upload-source-modal-head {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.44rem;
  align-items: center;
}

.assets-upload-source-modal-head h3 {
  margin: 0;
  font-size: 1rem;
  letter-spacing: 0.01em;
}

.assets-upload-source-action-btn {
  width: 98px;
  height: 42px;
  border: 1px solid #527082;
  border-radius: 12px;
  background: #607a8c;
  color: #ffffff;
  font-size: 0.93rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 5px 10px rgba(25, 59, 80, 0.18);
  transition: background-color 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.assets-upload-source-action-btn:hover {
  background: #6d8799;
  border-color: #4f6e80;
  box-shadow: 0 6px 12px rgba(25, 59, 80, 0.22);
}

.assets-upload-source-action-btn:focus-visible {
  outline: 2px solid #2f7aa0;
  outline-offset: 2px;
}

.assets-upload-source-modal-subtitle {
  margin: 0;
  font-size: 0.8rem;
  color: #2f5e72;
}

.assets-upload-source-total {
  border: 1px solid #bfd2de;
  border-radius: 9px;
  background: #ffffff;
  padding: 0.48rem 0.58rem;
  display: grid;
  gap: 0.16rem;
}

.assets-upload-source-total.invalid {
  border-color: #b85b47;
  box-shadow: 0 0 0 1px rgba(184, 91, 71, 0.18);
}

.assets-upload-source-total-label {
  font-size: 0.76rem;
  font-weight: 700;
  color: #21495d;
}

.assets-upload-source-total-input {
  border: 1px solid #9db9ca;
  border-radius: 8px;
  padding: 0.38rem 0.5rem;
  font-size: 0.88rem;
  color: #10354a;
  background: #f9fdff;
}

.assets-upload-source-total-input:focus-visible {
  outline: 2px solid #2f7aa0;
  outline-offset: 1px;
}

.assets-upload-source-total-help {
  font-size: 0.72rem;
  color: #3f667a;
  line-height: 1.3;
}

.assets-upload-source-total-error {
  min-height: 1.05em;
  font-size: 0.72rem;
  color: #9b3323;
  font-weight: 700;
}

.assets-upload-source-options {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr);
  column-gap: 0.52rem;
  row-gap: 0.42rem;
  align-items: stretch;
}

.assets-upload-source-option {
  width: 170px;
  height: 92px;
  border: 1px solid #1e678d;
  border-radius: 9px;
  background: linear-gradient(135deg, #1e89b6 0%, #1f6e9c 100%);
  padding: 0.34rem 0.6rem;
  font-size: 1.005rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  color: #ffffff;
  white-space: pre-line;
  line-height: 1.22;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 12px rgba(19, 74, 102, 0.16);
  transition: background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.assets-upload-source-option:hover {
  background: linear-gradient(135deg, #2498c8 0%, #2279aa 100%);
  border-color: #195f81;
  box-shadow: 0 0 0 1px rgba(28, 112, 151, 0.24), 0 8px 15px rgba(20, 70, 96, 0.22);
}

.assets-upload-source-option:focus-visible {
  outline: 2px solid #2f7aa0;
  outline-offset: 2px;
}

.assets-upload-source-option.active {
  border-color: #175775;
  box-shadow: 0 0 0 1px rgba(23, 87, 117, 0.34), 0 8px 16px rgba(13, 52, 74, 0.28);
  background: linear-gradient(135deg, #1b6f97 0%, #175e82 100%);
}

.assets-upload-source-description {
  border: 1px solid #c8d8e3;
  border-radius: 10px;
  background: #ffffff;
  padding: 0.5rem 0.62rem;
  display: grid;
  align-content: center;
  gap: 0.1rem;
  color: #21495d;
  min-height: 92px;
}

.assets-upload-source-description.active {
  border-color: #c8d8e3;
  box-shadow: none;
  background: #ffffff;
}

.assets-upload-source-desc-label {
  font-size: 0.8rem;
  letter-spacing: 0.01em;
}

.assets-upload-source-ext {
  font-size: 0.74rem;
  color: #3c6172;
  font-weight: 700;
}

.assets-upload-source-help {
  font-size: 0.75rem;
  color: #486676;
  line-height: 1.32;
  white-space: pre-line;
}

@media (max-width: 760px) {
  .assets-upload-source-options {
    grid-template-columns: minmax(0, 1fr);
  }

  .assets-upload-source-option {
    width: 100%;
    height: auto;
    min-height: 72px;
    text-align: left;
    justify-content: flex-start;
  }

  .assets-upload-source-description {
    min-height: 0;
  }
}

.assets-upload-source-modal-note {
  margin: 0;
  font-size: 0.74rem;
  color: #2f5e72;
  line-height: 1.35;
}

.assets-upload-source-modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 0.4rem;
}

.assets-import-feedback-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1965;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
  background: rgba(10, 29, 42, 0.5);
}

.assets-import-feedback-backdrop[hidden] {
  display: none !important;
}

.assets-import-feedback-modal {
  width: min(760px, 96vw);
  border: 1px solid #a8bfcc;
  border-radius: 12px;
  background: #f7fbfe;
  box-shadow: 0 20px 48px rgba(8, 25, 38, 0.34);
  padding: 0.74rem 0.8rem;
  display: grid;
  gap: 0.54rem;
  color: #173f52;
}

.assets-import-feedback-modal.is-info {
  border-color: #a8bfcc;
}

.assets-import-feedback-modal.is-ok {
  border-color: #86c7a8;
  box-shadow: 0 20px 48px rgba(24, 85, 53, 0.28);
}

.assets-import-feedback-modal.is-warn {
  border-color: #d7be84;
  box-shadow: 0 20px 48px rgba(105, 74, 24, 0.28);
}

.assets-import-feedback-modal.is-err {
  border-color: #d9aba6;
  box-shadow: 0 20px 48px rgba(113, 31, 31, 0.28);
}

.assets-import-feedback-head {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.44rem;
  align-items: center;
}

.assets-import-feedback-head h3 {
  margin: 0;
  font-size: 1rem;
  letter-spacing: 0.01em;
}

.assets-import-feedback-subtitle {
  margin: 0;
  font-size: 0.82rem;
  color: #2e6076;
  font-weight: 600;
}

.assets-import-feedback-progress-wrap {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.5rem;
  align-items: center;
}

.assets-import-feedback-progress {
  height: 13px;
  border: 1px solid #b7cad6;
  border-radius: 999px;
  background: #eaf3f8;
  overflow: hidden;
}

.assets-import-feedback-progress span {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #2d92be 0%, #1e759f 100%);
  transition: width 0.24s ease;
}

.assets-import-feedback-modal.is-ok .assets-import-feedback-progress span {
  background: linear-gradient(90deg, #2f9462 0%, #23784e 100%);
}

.assets-import-feedback-modal.is-warn .assets-import-feedback-progress span {
  background: linear-gradient(90deg, #c59a45 0%, #a97f2f 100%);
}

.assets-import-feedback-modal.is-err .assets-import-feedback-progress span {
  background: linear-gradient(90deg, #c3655b 0%, #aa4b42 100%);
}

.finish-verify-backdrop {
  position: fixed;
  inset: 0;
  z-index: 2650;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(16, 38, 49, 0.42);
}

.finish-verify-backdrop[hidden] {
  display: none !important;
}

.finish-verify-modal {
  width: min(760px, 94vw);
  max-height: 90vh;
  overflow: auto;
  display: grid;
  gap: 0.75rem;
  border: 1px solid #9fbdcc;
  border-radius: 12px;
  background: #f8fcff;
  color: #123b4d;
  box-shadow: 0 24px 58px rgba(4, 27, 40, 0.32);
  padding: 0.95rem;
}

.finish-verify-head {
  position: sticky;
  top: -0.95rem;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  gap: 0.7rem;
  align-items: center;
  padding: 0.35rem 0 0.7rem;
  border-bottom: 1px solid #c6d8e2;
  background: #f8fcff;
}

.finish-verify-head h3 {
  margin: 0;
  color: #0d465c;
}

.finish-verify-body {
  display: grid;
  gap: 0.72rem;
}

.finish-verify-message {
  margin: 0;
  border: 1px solid #b7cad8;
  border-radius: 8px;
  background: #eef6fb;
  padding: 0.7rem;
  line-height: 1.45;
}

.finish-verify-message.ok {
  border-color: #8fc6a7;
  background: #edf9f2;
}

.finish-verify-message.warn,
.finish-verify-alert {
  border-color: #e2b1a8;
  background: #fff3f0;
}

.finish-verify-alert {
  margin: 0;
  border-width: 1px;
  border-style: solid;
  border-radius: 8px;
  color: #9a2d22;
  padding: 0.58rem 0.7rem;
  font-weight: 700;
}

.finish-verify-alert span {
  display: inline-block;
  margin-top: 0.22rem;
  font-weight: 600;
}

.finish-verify-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.55rem;
}

.finish-verify-grid div {
  display: grid;
  gap: 0.1rem;
  border: 1px solid #b7cad8;
  border-radius: 8px;
  background: #ffffff;
  padding: 0.55rem;
}

.finish-verify-grid strong {
  color: #0b6170;
  font-size: 1.28rem;
}

.finish-verify-grid span {
  color: #3b5e6d;
  font-size: 0.82rem;
}

.finish-verify-progress {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: #df6d60;
}

.finish-verify-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: #2f8f5a;
}

.finish-verify-last {
  margin: 0;
  color: #426270;
}

.finish-verify-details {
  border: 1px solid #c0d3dd;
  border-radius: 8px;
  background: #ffffff;
  padding: 0.55rem 0.68rem;
}

.finish-verify-details summary {
  cursor: pointer;
  color: #0d4a62;
  font-weight: 700;
}

.finish-verify-details ul {
  margin: 0.45rem 0 0;
  padding-left: 1.1rem;
  color: #244b5d;
}

.finish-verify-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.55rem;
}

.finish-verify-actions-top {
  flex: 0 0 auto;
  flex-wrap: wrap;
}

.assets-import-feedback-percent {
  min-width: 44px;
  text-align: right;
  font-size: 0.84rem;
  color: #1f5268;
  font-weight: 800;
}

.assets-import-feedback-detail {
  margin: 0;
  font-size: 0.77rem;
  color: #325e71;
  line-height: 1.36;
  white-space: pre-line;
}

.assets-import-feedback-list {
  margin: 0;
  padding-left: 1.1rem;
  display: grid;
  gap: 0.22rem;
  color: #224e62;
  font-size: 0.77rem;
}

.assets-import-feedback-list li {
  line-height: 1.33;
}

.assets-import-feedback-list li.is-critical {
  color: #a0302a;
  font-weight: 800;
}

.assets-import-feedback-footer {
  display: flex;
  justify-content: flex-end;
  gap: 0.4rem;
}

.assets-import-feedback-footer.hidden {
  display: none;
}

.assets-import-feedback-primary {
  min-width: 178px;
  min-height: 42px;
  border: 1px solid #b48a36;
  border-radius: 12px;
  background: linear-gradient(135deg, #c89a3d 0%, #af7e2a 100%);
  color: #fff9ed;
  font-size: 0.92rem;
  font-weight: 800;
  box-shadow: 0 6px 12px rgba(108, 74, 22, 0.24);
}

.assets-import-feedback-primary:hover {
  background: linear-gradient(135deg, #d3a649 0%, #bc8930 100%);
}

.assets-grid-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1950;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
  background: rgba(10, 29, 42, 0.5);
}

.assets-grid-modal-backdrop[hidden] {
  display: none !important;
}

.assets-grid-modal {
  width: min(1500px, 98vw);
  max-height: 94vh;
  min-width: min(1200px, 92vw);
  min-height: 460px;
  border: 1px solid #9fb9c9;
  border-radius: 12px;
  background: #f7fbfe;
  box-shadow: 0 24px 58px rgba(8, 25, 38, 0.36);
  padding: 0.66rem 0.72rem;
  display: grid;
  gap: 0.48rem;
  color: #133f52;
  overflow: hidden;
  resize: both;
}

.assets-grid-modal.is-fullscreen {
  width: 99vw;
  max-width: 99vw;
  max-height: 96vh;
  min-width: 99vw;
  min-height: 96vh;
  border-radius: 10px;
  resize: none;
}

.assets-grid-modal-head {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  align-items: center;
  gap: 0.44rem;
}

.assets-grid-modal-head h3 {
  margin: 0;
  text-align: center;
  font-size: 1rem;
  letter-spacing: 0.01em;
}

.assets-grid-modal-status {
  margin: 0;
  font-size: 0.79rem;
  color: #2f5e72;
}

.assets-grid-modal-status.ok {
  color: #1f6b46;
}

.assets-grid-modal-status.warn {
  color: #8a5d1f;
}

.assets-grid-modal-status.err {
  color: #9a3529;
}

.assets-grid-modal-status.info {
  color: #2f5e72;
}

.assets-grid-review-gate {
  border: 1px solid #d8bf83;
  border-radius: 10px;
  background: #fff8e9;
  padding: 0.45rem 0.55rem;
  display: grid;
  gap: 0.26rem;
}

.assets-grid-review-label {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  font-size: 0.8rem;
  color: #604617;
  font-weight: 700;
}

.assets-grid-review-checkbox {
  width: 16px;
  height: 16px;
  accent-color: #bb8c31;
}

.assets-grid-review-stamp {
  margin: 0;
  font-size: 0.75rem;
  color: #8b6824;
  white-space: pre-line;
}

.assets-grid-review-stamp.ok {
  color: #235f3f;
}

.assets-grid-review-stamp.warn {
  color: #8b6824;
}

.assets-grid-meta {
  display: grid;
  grid-template-columns: minmax(220px, 260px) 1fr minmax(110px, 140px);
  gap: 0.38rem 0.44rem;
  align-items: end;
}

.assets-grid-meta label {
  display: grid;
  gap: 0.18rem;
  font-size: 0.76rem;
  color: #2f5668;
  font-weight: 700;
}

.assets-grid-meta label.span-2 {
  grid-column: 1 / -1;
}

.assets-grid-meta input,
.assets-grid-meta textarea {
  min-height: 34px;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  border: 1px solid #adc4d1;
  border-radius: 8px;
  background: #ffffff;
  color: #173f51;
  padding: 0.35rem 0.5rem;
  font-size: 0.81rem;
}

.assets-grid-meta textarea {
  resize: vertical;
}

.assets-grid-table-wrap {
  border: 1px solid #b7ccda;
  border-radius: 10px;
  background: #ffffff;
  overflow: auto;
  max-height: 58vh;
}

.assets-grid-modal.is-fullscreen .assets-grid-table-wrap {
  max-height: 68vh;
}

.assets-grid-table {
  width: max-content;
  min-width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}

.assets-grid-table th,
.assets-grid-table td {
  border: 0.5px solid #cddae2;
  padding: 0;
  vertical-align: middle;
}

.assets-grid-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #dce8f0;
  color: #1b4b62;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  font-weight: 700;
  white-space: nowrap;
  padding: 0.3rem 0.82rem 0.3rem 0.32rem;
}

.assets-col-resizer {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 9px;
  cursor: col-resize;
}

.assets-col-resizer::after {
  content: "";
  position: absolute;
  top: 20%;
  right: 3px;
  width: 1px;
  height: 60%;
  background: #8aa6b9;
}

.assets-grid-table td input,
.assets-grid-table td select,
.assets-grid-table td textarea {
  width: 100%;
  min-height: 30px;
  border: 0;
  border-radius: 0;
  background: #ffffff;
  color: #153b4e;
  padding: 0.26rem 0.38rem;
  font-size: 0.78rem;
}

.assets-grid-table td input:focus,
.assets-grid-table td select:focus,
.assets-grid-table td textarea:focus {
  outline: 1px solid #6fa2bf;
  outline-offset: -1px;
  background: #f6fbff;
}

.assets-grid-table td textarea {
  resize: vertical;
  line-height: 1.3;
}

.assets-grid-table td.assets-cell-money input {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.assets-grid-table td.assets-cell-percent input {
  text-align: center;
}

.assets-grid-table td.assets-cell-note textarea {
  min-height: 34px;
}

.assets-grid-table td.assets-cell-note {
  min-width: 190px;
}

.assets-grid-table tr.assets-row-invalid td {
  background: #fff6f4;
}

.assets-grid-table td.assets-actions-cell {
  text-align: center;
  background: #f3f8fc;
  padding: 0.1rem;
}

.assets-grid-table td.assets-order-cell {
  text-align: center;
  background: #f3f8fc;
  padding: 0.08rem;
}

.assets-grid-table td.assets-order-cell .assets-move-btn {
  display: block;
  width: 100%;
  min-height: 22px;
  padding: 0.08rem 0.2rem;
  font-size: 0.8rem;
  line-height: 1;
}

.assets-grid-table td.assets-actions-cell .ghost-btn {
  min-height: 28px;
  font-size: 0.72rem;
}

.assets-grid-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.assets-grid-summary {
  margin: 0;
  font-size: 0.78rem;
  color: #305b6c;
  font-weight: 600;
}

.assets-grid-summary.warn {
  color: #9a3529;
}

.assets-grid-actions {
  display: inline-flex;
  gap: 0.42rem;
  flex-wrap: wrap;
}

.assets-grid-actions .secondary-btn {
  min-height: 34px;
  padding: 0.42rem 0.72rem;
  font-size: 0.8rem;
}

body.assets-grid-modal-open {
  overflow: hidden;
}

body.assets-upload-source-modal-open {
  overflow: hidden;
}

body.assets-import-feedback-modal-open {
  overflow: hidden;
}

.note-box label {
  font-size: 0.78rem;
  color: var(--ink-soft);
}

.note-box textarea {
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.45rem 0.55rem;
  resize: vertical;
}

.upload-box {
  border: 1px dashed #b8cbd4;
  border-radius: 10px;
  padding: 0.36rem 0.45rem;
  background: #f8fcfe;
  display: grid;
  gap: 0;
  align-content: start;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  box-sizing: border-box;
}

.row-controls .upload-box {
  width: 100%;
}

.upload-toolbar {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.upload-purpose {
  color: #a86f2b;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.01em;
}

.counter {
  font-size: 0.8rem;
  color: #335262;
  font-weight: 600;
}

.files-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.35rem;
}

.files-list:empty {
  display: none;
}

.upload-box .files-list:not(:empty) {
  margin-top: 0.35rem;
}

.upload-status {
  margin: 0.34rem 0 0;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.25;
  display: block;
  width: 100%;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.upload-status.info {
  color: #2f6178;
}

.upload-status.ok {
  color: #236a45;
}

.upload-status.err {
  color: #933d33;
}

.files-list li {
  border: 1px solid #d2e0e7;
  border-radius: 9px;
  padding: 0.42rem;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.5rem;
  align-items: center;
  font-size: 0.82rem;
  min-width: 0;
  max-width: 100%;
}

.files-list li > :first-child {
  min-width: 0;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.files-list li.file-empty-row {
  grid-template-columns: 1fr;
  color: #5f7684;
  font-style: italic;
  background: #f3f8fc;
}

.file-actions {
  display: inline-flex;
  gap: 0.35rem;
}

.file-actions button {
  padding: 0.35rem 0.52rem;
  border-radius: 8px;
  font-size: 0.74rem;
  background: #13606d;
}

.file-actions button.secondary {
  background: #6f8591;
}

.file-actions button.danger {
  background: #b7493d;
}

#logBox {
  margin: 0;
  max-height: 220px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f5fafc;
  color: #123443;
  padding: 0.7rem;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.78rem;
}

@media (max-width: 1040px) {
  .brand-topline {
    gap: 0.2rem;
  }

  .brand-logo {
    width: 84px;
    height: 84px;
  }

  .hero-focus {
    grid-template-columns: 1fr;
  }

  .concessionario-focus {
    grid-template-columns: 1fr;
  }

  .concessionario-sections-card {
    order: 2;
  }

  .concessionario-shell {
    width: min(1280px, 96vw);
    margin: 0.75rem auto 1.2rem;
  }

  .perito-shell {
    width: min(1280px, 96vw);
  }

  .anagrafica-grid {
    grid-template-columns: 1fr;
  }

  .anagrafica-contact-grid {
    grid-template-columns: 1fr;
  }

  .anagrafica-grid .span-2,
  .anagrafica-grid .span-4 {
    grid-column: auto;
  }

  .test-head-row {
    flex-direction: column;
    align-items: start;
    gap: 0.2rem;
  }

  .role-buttons,
  .focus-role-buttons {
    grid-template-columns: 1fr;
  }

  .focus-detail {
    min-height: 0;
  }

  .norm-matrix {
    table-layout: auto;
  }

  .norm-matrix th,
  .norm-matrix td {
    font-size: 0.8rem;
  }

  .norm-weight-note-line2 {
    white-space: normal;
  }

  .norm-source-cards {
    grid-template-columns: 1fr;
  }

  .norm-source-workspace-head {
    flex-direction: column;
    align-items: start;
  }

  .investment-asset-fields {
    grid-template-columns: 1fr;
  }

  .investment-asset-card {
    grid-template-columns: 1fr;
  }

  .investment-guide-card {
    grid-template-columns: 1fr;
    gap: 0.28rem;
  }

  .investment-guide-card p {
    border-left: 0;
    border-top: 1px solid rgba(168, 119, 37, 0.34);
    padding-left: 0;
    padding-top: 0.38rem;
  }

  .investment-field.is-desc,
  .investment-field.is-location,
  .investment-field.is-proof {
    grid-column: auto;
  }

  .investment-asset-head {
    grid-template-columns: 1fr;
  }

  .investment-asset-docs {
    grid-column: 1;
  }

  .investment-evidence-list {
    grid-template-columns: 1fr;
  }

  .investment-remove-btn {
    justify-self: start;
  }

  .norm-detail-inline {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 0.32rem;
  }

  .norm-detail-source-box {
    justify-content: flex-start;
  }

  .source-editor-modal {
    width: min(980px, 96vw);
  }

  .source-editor-kind-switch {
    flex-wrap: wrap;
  }

  .norm-admin-bar {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .add-source-grid {
    grid-template-columns: 1fr;
  }

  .add-detail-row {
    grid-template-columns: 1fr;
  }

  .panel-head {
    grid-template-columns: 1fr;
  }

  .top-nav-panel {
    grid-template-columns: 1fr;
  }

  .test-grid {
    grid-template-columns: 1fr;
  }

  .perito-grid {
    grid-template-columns: 1fr;
  }

  .perito-grid .perito-span-2 {
    grid-column: auto;
  }

  .perito-actions {
    grid-column: auto;
    grid-template-columns: 1fr;
  }

  .perito-convalida-layout {
    grid-template-columns: 1fr;
  }

  .perito-editor {
    min-height: 320px;
    max-height: none;
  }

  .test-actions {
    grid-template-columns: 1fr;
  }

  .practice-modal {
    width: min(1240px, 99vw);
    max-height: 94vh;
    padding: 0.65rem 0.62rem;
  }

  .practice-picker-modal {
    width: min(920px, 99vw);
    max-height: 94vh;
    padding: 0.65rem 0.62rem;
  }

  .practice-create-modal {
    width: min(980px, 99vw);
  }

  .practice-edit-modal {
    width: min(980px, 99vw);
  }

  .practice-picker-grid {
    grid-template-columns: 1fr;
    gap: 0.32rem;
  }

  .practice-create-grid {
    grid-template-columns: 1fr;
    gap: 0.32rem;
  }

  .practice-create-span-2 {
    grid-column: auto;
  }

  .practice-picker-practice-label select {
    min-height: 220px;
  }

  .practice-picker-footer {
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .practice-modal-toolbar {
    grid-template-columns: 1fr;
    gap: 0.32rem;
  }

  .practice-modal-footer {
    justify-content: space-between;
    flex-wrap: wrap;
  }

  .test-list li {
    grid-template-columns: 1fr;
  }

  .controls {
    grid-template-columns: 1fr;
  }

  .practice-context-grid {
    grid-template-columns: 1fr;
  }

  .practice-context-item-wide {
    grid-column: auto;
  }

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

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

  .initial-act-grid {
    grid-template-columns: 1fr;
  }

  .initial-act-grid label.span-2 {
    grid-column: auto;
  }

  .consequence-slot-grid {
    grid-template-columns: 1fr;
  }

  .consequence-slot-grid label.span-2 {
    grid-column: auto;
  }

  .urban-card-grid {
    grid-template-columns: 1fr;
  }

  .urban-card-grid label.span-2 {
    grid-column: auto;
  }

  .urban-row-actions {
    justify-content: flex-start;
  }

  .canone-row-top {
    align-items: stretch;
    gap: 2px;
  }

  .canone-row-label {
    width: 100%;
  }

  .canone-row-label input {
    width: 100%;
  }

  .planimetry-grid {
    grid-template-columns: 1fr;
  }

  .assets-method-list {
    display: grid;
    grid-template-columns: 1fr;
  }

  .assets-method-panel {
    grid-template-columns: 1fr;
  }

  .assets-method-action {
    justify-self: start;
  }

  .assets-acquired-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .assets-acquired-actions {
    justify-content: flex-start;
  }

  .assets-grid-modal {
    width: min(99vw, 99vw);
    max-height: 96vh;
    min-width: 99vw;
    min-height: 76vh;
    padding: 0.55rem 0.52rem;
    resize: none;
  }

  .assets-grid-meta {
    grid-template-columns: 1fr;
  }

  .free-entry-actions {
    justify-content: flex-start;
  }

  .row-workflow-box-concessionario {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .row-head {
    grid-template-columns: auto 1fr;
  }

  .row-chip {
    grid-column: 1 / -1;
    width: fit-content;
  }

  .doc-section summary {
    grid-template-columns: 1fr;
    gap: 0.28rem;
  }

  .section-expand-toggle,
  .section-count {
    justify-self: start;
  }
}
