:root {
  --ar-bg: #f4f5f2;
  --ar-panel: #ffffff;
  --ar-card: #ffffff;
  --ar-ink: #121827;
  --ar-muted: #727784;
  --ar-line: #e9e3d7;
  --ar-brand: #f3c847;
  --ar-brand-dark: #8a6b00;
  --ar-green: #178f5b;
  --ar-blue: #255fcf;
  --ar-red: #b83f3f;
  --ar-shadow: 0 18px 44px rgba(31, 36, 48, .08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--ar-bg);
  color: var(--ar-ink);
  font-family: "Poppins", "Segoe UI", Arial, sans-serif;
  letter-spacing: 0;
}

button,
input,
select {
  font: inherit;
}

.ar-login {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 20px;
  background:
    linear-gradient(120deg, rgba(18, 24, 39, .84), rgba(18, 24, 39, .36)),
    radial-gradient(circle at 78% 28%, rgba(243, 200, 71, .44), transparent 30%),
    linear-gradient(135deg, #4d5867 0%, #1a2230 60%, #cab36c 100%);
}

.ar-login-card {
  width: min(460px, 100%);
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, .18);
  padding: 28px;
}

.ar-logo {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #fff7d5;
  border: 1px solid #eadb91;
  color: var(--ar-brand-dark);
  font-weight: 900;
  overflow: hidden;
  flex: 0 0 auto;
}

.ar-logo-image {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  padding: 10px;
  background: #fff;
  justify-self: start;
}

.ar-logo-wide {
  width: min(360px, 100%);
  height: 132px;
  border-radius: 8px;
  padding: 12px 16px;
}

.ar-logo-square {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  padding: 10px;
}

.ar-logo-tall {
  width: 96px;
  height: 128px;
  border-radius: 8px;
  padding: 10px;
}

.ar-logo-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.ar-eyebrow {
  margin: 0 0 6px;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--ar-brand-dark);
  font-weight: 900;
}

.ar-muted {
  color: var(--ar-muted);
  line-height: 1.45;
}

.ar-login-card h1,
.ar-topbar h1,
.ar-hero h2,
.ar-card h3 {
  margin: 0;
  line-height: 1.12;
}

.ar-login-card form {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}

.ar-login-card label {
  font-size: 13px;
  color: #4d5566;
  font-weight: 800;
}

.ar-login-card input {
  min-height: 46px;
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  padding: 0 14px;
}

.ar-login-card button,
.ar-card button,
.ar-card-head button,
.ar-action-button {
  min-height: 42px;
  border: 0;
  border-radius: 8px;
  padding: 0 16px;
  background: var(--ar-brand);
  color: #3a2d00;
  font-weight: 900;
  cursor: pointer;
}

.ar-action-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  white-space: nowrap;
}

.ar-back-button,
.ar-login-card .ar-back-button {
  width: auto;
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 18px;
  margin: 0 0 18px;
  border: 1px solid #eadb91;
  border-radius: 8px;
  background: #fff7d5;
  color: var(--ar-brand-dark);
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 10px 20px rgba(23,27,38,.08);
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease, background .16s ease;
}

.ar-back-button:before {
  content: "\2190";
  font-weight: 900;
  color: var(--ar-brand-dark);
}

.ar-back-button:hover,
.ar-login-card .ar-back-button:hover {
  border-color: var(--ar-brand);
  color: var(--ar-brand-dark);
  background: var(--ar-brand);
  box-shadow: 0 14px 26px rgba(23,27,38,.12);
  transform: translateY(-1px);
}

.ar-back-button-inline {
  margin: 0;
  flex: 0 0 auto;
}

.ar-alert {
  margin-top: 14px;
  border: 1px solid #efc5c5;
  background: #fff2f2;
  color: var(--ar-red);
  border-radius: 8px;
  padding: 12px;
  font-weight: 800;
}

.ar-alert-soft {
  border-color: #eadb91;
  background: #fff5d2;
  color: var(--ar-brand-dark);
}

.ar-ok {
  margin-top: 14px;
  border: 1px solid #b7dcbd;
  background: #e9f7ef;
  color: var(--ar-green);
  border-radius: 8px;
  padding: 12px;
  font-weight: 800;
}

.ar-dashboard-alert {
  margin: 0 0 14px;
}

.ar-assist-banner {
  margin-bottom: 14px;
  border: 1px solid #d7b23a;
  border-radius: 8px;
  background: #fff8dc;
  color: #4d3b00;
  padding: 12px 14px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 14px;
  align-items: center;
}

.ar-assist-banner strong {
  font-size: 13px;
  text-transform: uppercase;
}

.ar-assist-banner span {
  color: #6d5a18;
  font-size: 13px;
}

.ar-assist-banner a {
  grid-row: 1 / span 2;
  grid-column: 2;
  border: 1px solid #caa72c;
  border-radius: 8px;
  color: #4d3b00;
  text-decoration: none;
  padding: 8px 11px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.ar-login-extra {
  margin-top: 14px;
  border-top: 1px solid var(--ar-line);
  padding-top: 12px;
}

.ar-login-extra summary {
  cursor: pointer;
  color: var(--ar-brand-dark);
  font-weight: 900;
}

.ar-login-extra form {
  margin-top: 12px;
}

.ar-login-extra p {
  margin: 8px 0 0;
  color: var(--ar-muted);
  font-size: 13px;
  line-height: 1.4;
}

.ar-reset-hp {
  position: absolute;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.ar-result {
  margin-top: 18px;
  padding: 14px;
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  background: #fbfaf4;
  word-break: break-word;
}

.ar-admin-invite-card {
  width: min(760px, 100%);
}

.ar-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
}

.ar-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  background: #fff;
  border-right: 1px solid var(--ar-line);
  padding: 18px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.ar-sidebar a {
  width: 66px;
  min-height: 42px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  text-decoration: none;
  color: #202436;
  font-size: 11px;
  font-weight: 800;
  border: 1px solid transparent;
}

.ar-sidebar a.active {
  background: var(--ar-brand);
  border-color: var(--ar-brand);
}

.ar-main {
  padding: 22px 28px 46px;
  min-width: 0;
}

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

.ar-topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.ar-user-pill {
  border: 1px solid #eadb91;
  background: #fff7d5;
  color: var(--ar-brand-dark);
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 900;
}

.ar-hero {
  border-radius: 8px;
  color: #fff;
  padding: 26px;
  box-shadow: var(--ar-shadow);
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  gap: 18px;
  align-items: center;
  background: linear-gradient(120deg, #111827, #414a58);
}

.ar-accent-gold {
  background:
    radial-gradient(circle at 82% 22%, rgba(243, 200, 71, .34), transparent 28%),
    linear-gradient(120deg, #111827, #414a58);
}

.ar-accent-green {
  background:
    radial-gradient(circle at 82% 22%, rgba(23, 143, 91, .36), transparent 28%),
    linear-gradient(120deg, #10251d, #34463d);
}

.ar-accent-blue {
  background:
    radial-gradient(circle at 82% 22%, rgba(37, 95, 207, .34), transparent 28%),
    linear-gradient(120deg, #111827, #293d67);
}

.ar-hero p {
  color: rgba(255, 255, 255, .82);
  margin: 10px 0 0;
}

.ar-context-panel {
  margin: 18px 0;
  background: var(--ar-panel);
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  padding: 18px;
  display: grid;
  grid-template-columns: minmax(240px, .8fr) minmax(0, 1.2fr);
  gap: 16px;
  box-shadow: var(--ar-shadow);
}

.ar-context-panel h2 {
  margin: 0 0 8px;
  line-height: 1.14;
}

.ar-context-panel p {
  margin: 0;
  color: var(--ar-muted);
  line-height: 1.45;
}

.ar-context-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.ar-context-card {
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  padding: 12px;
  text-decoration: none;
  color: var(--ar-ink);
  background: #fff;
  display: grid;
  gap: 5px;
}

.ar-context-card strong {
  font-size: 14px;
}

.ar-context-card span {
  color: var(--ar-muted);
  font-size: 12px;
  line-height: 1.35;
}

.ar-context-card.active {
  border-color: #eadb91;
  background: #fff8dd;
  box-shadow: inset 0 0 0 1px rgba(243, 200, 71, .32);
}

.ar-context-crm {
  border-color: #c7d7ff;
  background: #f4f7ff;
}

.ar-kpi {
  border: 1px solid rgba(255, 255, 255, .2);
  background: rgba(255, 255, 255, .12);
  border-radius: 8px;
  padding: 16px;
}

.ar-kpi span {
  display: block;
  color: rgba(255, 255, 255, .72);
  margin-bottom: 8px;
  font-size: 12px;
  text-transform: uppercase;
  font-weight: 900;
}

.ar-kpi strong {
  font-size: 24px;
}

.ar-kpi-clickable button,
.ar-kpi-clickable a {
  width: 100%;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 0;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
}

.ar-kpi-clickable button strong,
.ar-kpi-clickable a strong {
  display: block;
}

.ar-kpi-clickable button em,
.ar-kpi-clickable a em {
  display: block;
  margin-top: 6px;
  color: rgba(255, 255, 255, .76);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}

.ar-role-tabs {
  margin: 16px 0;
  display: flex;
  gap: 9px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.ar-role-tabs a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  border-radius: 999px;
  border: 1px solid var(--ar-line);
  background: #fff;
  color: #313746;
  text-decoration: none;
  padding: 0 13px;
  white-space: nowrap;
  font-weight: 900;
  font-size: 13px;
}

.ar-role-tabs a span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #cfd3db;
}

.ar-role-tabs a.active {
  background: #fff7d5;
  border-color: #d1b43f;
  color: #3a2d00;
}

.ar-role-tabs a.active span {
  background: var(--ar-brand-dark);
}

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

.ar-card {
  background: var(--ar-panel);
  border: 1px solid #ece8df;
  border-radius: 8px;
  box-shadow: var(--ar-shadow);
  padding: 18px;
  min-width: 0;
}

.ar-card-wide {
  grid-column: span 2;
}

.ar-card-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}

.ar-card p {
  color: var(--ar-muted);
  line-height: 1.45;
}

.ar-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.ar-chip-list span {
  border: 1px solid #e7e9ef;
  background: #fafbfc;
  border-radius: 999px;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 900;
}

.ar-ops-card {
  background: linear-gradient(180deg, #fff, #fffdf7);
}

.ar-role-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  border-radius: 999px;
  border: 1px solid #eadb91;
  background: #fff7d5;
  color: var(--ar-brand-dark);
  padding: 0 11px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.ar-ops-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 14px;
  margin-top: 12px;
}

.ar-ops-grid h4,
.ar-doc-section h4 {
  margin: 0 0 10px;
  font-size: 13px;
  color: #232938;
}

.ar-clean-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ar-clean-list li {
  position: relative;
  padding-left: 18px;
  color: var(--ar-muted);
  font-size: 13px;
  line-height: 1.35;
}

.ar-clean-list li:before {
  content: "";
  position: absolute;
  left: 0;
  top: .55em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ar-brand);
  box-shadow: 0 0 0 3px rgba(243, 200, 71, .18);
}

.ar-permission-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.ar-permission-tags span {
  border: 1px solid #e7e9ef;
  background: #fff;
  border-radius: 999px;
  padding: 7px 10px;
  color: #313746;
  font-size: 12px;
  font-weight: 850;
}

.ar-step-list {
  display: grid;
  gap: 10px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.ar-step-list li {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  color: #313746;
  font-size: 13px;
  line-height: 1.3;
}

.ar-step-list li span {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #fff7d5;
  color: var(--ar-brand-dark);
  font-weight: 950;
}

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

.ar-slots button {
  background: #fafbfc;
  color: #343948;
  border: 1px solid #e7e9ef;
  min-height: 38px;
}

.ar-slots button.on {
  background: #eaf8ef;
  color: var(--ar-green);
  border-color: #b7dcbd;
}

.ar-slots button.match {
  background: #fff5bd;
  color: var(--ar-brand-dark);
  border-color: #ead15f;
}

.ar-availability-form {
  display: grid;
  gap: 9px;
  margin-top: 12px;
}

.ar-availability-form label {
  font-size: 12px;
  color: #5d6370;
  font-weight: 900;
}

.ar-availability-form input,
.ar-availability-form select {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  background: #fff;
  color: var(--ar-ink);
  padding: 0 11px;
}

.ar-personal-card {
  margin-bottom: 18px;
}

.ar-personal-page {
  max-width: 1120px;
}

.ar-personal-head-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.ar-action-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  border: 1px solid #e3dfd3;
  border-radius: 999px;
  background: #fff;
  color: #303644;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

.ar-personal-form {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.ar-password-form {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid #ece8df;
}

.ar-password-panel {
  display: grid;
  gap: 12px;
  margin-top: 18px;
  padding: 14px;
  border: 1px solid #ece8df;
  border-radius: 8px;
  background: #fffdf8;
}

.ar-password-head {
  display: grid;
  gap: 3px;
}

.ar-password-head h4 {
  margin: 0;
  color: #232938;
  font-size: 14px;
}

.ar-password-head p {
  margin: 0;
  color: #6b7280;
  font-size: 12px;
}

.ar-password-head p strong {
  color: #232938;
}

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

.ar-password-actions form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fff;
  padding: 12px;
}

.ar-password-actions strong,
.ar-password-actions span {
  display: block;
}

.ar-password-actions strong {
  color: #232938;
  font-size: 13px;
  line-height: 1.25;
}

.ar-password-actions span {
  margin-top: 2px;
  color: #6b7280;
  font-size: 12px;
  line-height: 1.25;
}

.ar-password-actions button,
.ar-password-details button[type="submit"] {
  border: 1px solid var(--ar-brand);
  border-radius: 999px;
  background: var(--ar-brand);
  color: #20242f;
  min-height: 38px;
  padding: 0 16px;
  font-weight: 900;
  cursor: pointer;
}

.ar-password-details {
  border-top: 1px solid #ece8df;
  padding-top: 10px;
}

.ar-password-details summary {
  cursor: pointer;
  color: #7a6500;
  font-size: 13px;
  font-weight: 900;
  list-style: none;
}

.ar-password-details summary::-webkit-details-marker {
  display: none;
}

.ar-password-details summary:after {
  content: "+";
  float: right;
}

.ar-password-details[open] summary:after {
  content: "-";
}

.ar-password-details .ar-password-form {
  margin-top: 10px;
  padding-top: 0;
  border-top: 0;
}

.ar-password-reset-box {
  background: #fffdf5;
  border: 1px solid #f1e4a8;
  border-radius: 8px;
  padding: 14px;
}

.ar-inline-reset-form {
  display: grid;
  gap: 10px;
}

.ar-password-generated {
  display: grid;
  gap: 6px;
  border: 1px solid #e7d168;
  border-radius: 8px;
  background: #fff8d8;
  padding: 10px;
}

.ar-password-generated label {
  color: #5d4a00;
  font-size: 12px;
  font-weight: 900;
}

.ar-password-generated label span {
  color: #756b45;
  font-weight: 700;
}

.ar-password-generated input {
  width: 100%;
  border: 1px solid #e7d168;
  border-radius: 8px;
  background: #fff;
  color: #111827;
  padding: 8px 10px;
  font: inherit;
  font-size: 16px;
  font-weight: 900;
}

.ar-force-password-card {
  max-width: 780px;
  margin: 28px auto 0;
}

.ar-force-password-head {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
}

.ar-force-password-head h2 {
  margin: 0;
  color: #101828;
  font-size: 26px;
}

.ar-force-password-head p {
  margin: 0;
  max-width: 620px;
  color: #5d6370;
}

.ar-force-password-head span {
  width: fit-content;
  border: 1px solid #f1e4a8;
  border-radius: 999px;
  background: #fffdf1;
  padding: 8px 12px;
  color: #5d4a00;
  font-weight: 800;
}

.ar-force-password-form {
  display: grid;
  gap: 14px;
  border-top: 1px solid #edf0f5;
  padding-top: 16px;
}

.ar-force-password-form > button {
  justify-self: start;
  border: 0;
  border-radius: 999px;
  background: #f9ca24;
  color: #111827;
  padding: 12px 22px;
  font-weight: 900;
  cursor: pointer;
}

.ar-personal-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 8px;
  align-items: end;
}

.ar-personal-grid > div {
  grid-column: span 3;
  min-width: 0;
}

.ar-personal-grid label {
  display: block;
  margin-bottom: 6px;
  color: #5d6370;
  font-size: 12px;
  font-weight: 900;
}

.ar-personal-grid input,
.ar-personal-grid select,
.ar-personal-grid textarea {
  width: 100%;
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  background: #fff;
  color: var(--ar-ink);
  padding: 8px 10px;
  font: inherit;
  font-size: 13px;
}

.ar-personal-grid input,
.ar-personal-grid select {
  min-height: 38px;
}

.ar-personal-grid input[readonly] {
  background: #f8f9fb;
  color: #303644;
  font-weight: 850;
}

.ar-personal-grid .select2-container .select2-selection--single {
  min-height: 38px;
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  display: flex;
  align-items: center;
}

.ar-personal-grid .select2-container--default .select2-selection--single .select2-selection__rendered {
  color: #232938;
  line-height: 36px;
}

.ar-personal-grid .select2-container--default .select2-selection--single .select2-selection__arrow {
  min-height: 38px;
}

.ar-personal-form h4 {
  margin: 4px 0 -4px;
  color: #232938;
  font-size: 14px;
}

.ar-personal-grid textarea {
  resize: vertical;
}

.ar-phone-pair {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  gap: 6px;
}

.ar-password-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 6px;
}

.ar-password-field button {
  min-height: 38px;
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  background: #fff;
  color: #303644;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.ar-login-card .ar-password-field {
  grid-template-columns: minmax(0, 1fr) auto;
}

.ar-login-card .ar-password-field input {
  min-height: 46px;
}

.ar-login-card .ar-password-field button {
  min-height: 46px;
  background: #fff;
  color: #303644;
  border: 1px solid var(--ar-line);
  padding: 0 12px;
}

.ar-foreign-city.is-hidden,
.ar-personal-grid [data-ar-cap-select].is-hidden {
  display: none;
}

.ar-personal-grid [data-ar-cap-select] {
  margin-top: 6px;
}

.ar-field-mini {
  grid-column: span 1 !important;
}

.ar-field-small {
  grid-column: span 2 !important;
}

.ar-field-medium {
  grid-column: span 3 !important;
}

.ar-field-large {
  grid-column: span 4 !important;
}

.ar-field-full,
.ar-personal-field-wide {
  grid-column: 1 / -1;
}

.ar-personal-form button,
.ar-password-form > button,
.ar-inline-reset-form > button {
  justify-self: start;
  min-height: 42px;
  border: 1px solid var(--ar-brand);
  border-radius: 999px;
  background: var(--ar-brand);
  color: #141414;
  padding: 0 18px;
  font-weight: 950;
  cursor: pointer;
}

.ar-personal-form .ar-personal-field-wide textarea {
  min-height: 76px;
}

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

.ar-form-row-single {
  grid-template-columns: 1fr;
}

.ar-calendar-picker {
  border: 1px solid #eee7d2;
  border-radius: 8px;
  background: linear-gradient(180deg, #fffdf3, #fff);
  padding: 12px;
}

.ar-calendar-head {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) 38px;
  gap: 8px;
  align-items: center;
  margin-bottom: 10px;
}

.ar-calendar-head strong {
  text-align: center;
  font-size: 15px;
  font-weight: 950;
}

.ar-calendar-head button {
  min-height: 36px;
  padding: 0;
  border: 1px solid #eadb91;
  background: #fff;
  color: var(--ar-brand-dark);
}

.ar-calendar-weekdays,
.ar-calendar-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.ar-calendar-weekdays span {
  color: #6b7280;
  font-size: 11px;
  font-weight: 900;
  text-align: center;
}

.ar-calendar-day {
  min-height: 38px;
  border: 1px solid #ece8df;
  border-radius: 8px;
  background: #fff;
  color: var(--ar-ink);
  font-weight: 900;
  cursor: pointer;
}

.ar-calendar-day:hover {
  border-color: #b7dcbd;
  background: #f1fbf5;
}

.ar-calendar-day.is-selected {
  border-color: #178f5b;
  background: #178f5b;
  color: #fff;
}

.ar-calendar-day.is-today {
  box-shadow: inset 0 0 0 2px rgba(243,200,71,.64);
}

.ar-calendar-day.is-disabled,
.ar-calendar-day.is-empty {
  cursor: default;
  opacity: .36;
  background: #f6f6f6;
}

.ar-calendar-day.is-empty {
  border-color: transparent;
  background: transparent;
}

.ar-selected-days {
  margin: 10px 0 0;
  color: var(--ar-green);
  font-size: 12px;
  font-weight: 900;
}

.ar-property-list {
  display: grid;
  gap: 9px;
}

.ar-property {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border: 1px solid #f0ece5;
  background: #fff;
  border-radius: 8px;
  padding: 12px;
}

.ar-property p {
  margin: 4px 0 0;
}

.ar-property span {
  border-radius: 999px;
  background: #fff7d5;
  color: var(--ar-brand-dark);
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 900;
}

.ar-owner-dashboard {
  align-content: start;
}

.ar-owner-list {
  display: grid;
  gap: 14px;
  max-height: 960px;
  overflow-y: auto;
  padding-right: 8px;
  scrollbar-color: #d6c376 #f7f3e6;
  scrollbar-width: thin;
}

.ar-owner-list::-webkit-scrollbar {
  width: 10px;
}

.ar-owner-list::-webkit-scrollbar-track {
  background: #f7f3e6;
  border-radius: 999px;
}

.ar-owner-list::-webkit-scrollbar-thumb {
  background: #d6c376;
  border-radius: 999px;
}

.ar-owner-property {
  border: 1px solid #ece5d6;
  border-radius: 8px;
  background: #fffdf8;
  padding: 14px;
  display: grid;
  gap: 12px;
}

.ar-owner-property-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
}

.ar-owner-property-head strong {
  color: var(--ar-ink);
  font-size: 16px;
}

.ar-owner-property-head p {
  margin: 4px 0 0;
  color: var(--ar-muted);
}

.ar-owner-property-head > span {
  border-radius: 999px;
  border: 1px solid #eadb91;
  background: #fff8dc;
  color: var(--ar-brand-dark);
  padding: 8px 11px;
  font-weight: 900;
  white-space: nowrap;
}

.ar-owner-kpis {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.ar-owner-kpis div {
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fff;
  padding: 10px;
}

.ar-owner-kpis strong {
  display: block;
  font-size: 18px;
  line-height: 1;
  color: var(--ar-ink);
}

.ar-owner-kpis span {
  display: block;
  margin-top: 5px;
  color: var(--ar-muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.ar-owner-action {
  border-left: 4px solid var(--ar-brand-primary);
  background: #fff;
  padding: 10px 12px;
}

.ar-owner-action strong,
.ar-owner-feedback > strong,
.ar-message-box strong {
  display: block;
  color: var(--ar-ink);
  font-size: 13px;
}

.ar-owner-action p {
  margin: 4px 0 0;
  color: var(--ar-muted);
}

.ar-owner-feedback {
  display: grid;
  gap: 7px;
  border-top: 1px solid #f0ece5;
  padding-top: 10px;
}

.ar-owner-feedback div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--ar-muted);
  font-size: 13px;
}

.ar-owner-feedback em {
  color: var(--ar-brand-dark);
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.ar-owner-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
}

.ar-owner-links a,
.ar-owner-links button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 128px;
  min-height: 44px;
  border: 1px solid #eadb91;
  border-radius: 999px;
  color: var(--ar-brand-dark);
  background: #fff;
  padding: 0 18px;
  font-size: 12px;
  line-height: 1;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
  box-sizing: border-box;
  white-space: nowrap;
}

.ar-message-box {
  border: 1px solid #ece5d6;
  border-radius: 8px;
  background: #fffdf8;
  padding: 13px;
  display: grid;
  gap: 4px;
}

.ar-message-box span {
  color: var(--ar-muted);
}

.ar-crm-property-card {
  display: grid;
  grid-template-columns: minmax(330px, 380px) minmax(0, 1fr);
  border-radius: 8px;
  background: #fff;
  border: 1px solid #e7e1d5;
  box-shadow: 0 14px 34px rgba(34,34,34,.12);
  overflow: hidden;
}

.ar-crm-property-side {
  background: #fffdf8;
  border-right: 1px solid #efeadf;
}

.ar-crm-property-media {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background-color: #ece8de;
  background-position: center;
  background-size: cover;
}

.ar-crm-property-media:after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.18), rgba(0,0,0,0) 44%, rgba(0,0,0,.28));
  pointer-events: none;
}

.ar-crm-ref,
.ar-photo-count {
  position: absolute;
  z-index: 1;
  border-radius: 999px;
  color: #fff;
  background: rgba(18, 24, 38, .82);
  font-size: 12px;
  font-weight: 900;
}

.ar-crm-ref {
  left: 12px;
  top: 12px;
  padding: 8px 10px;
}

.ar-photo-count {
  right: 12px;
  bottom: 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
}

.ar-photo-count svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
}

.ar-fascicolo-side {
  padding: 14px;
  display: grid;
  gap: 5px;
}

.ar-fascicolo-side strong {
  color: var(--ar-ink);
  font-size: 34px;
  line-height: 1;
}

.ar-fascicolo-side span {
  color: var(--ar-brand-dark);
  font-size: 13px;
  font-weight: 900;
}

.ar-fascicolo-side em {
  color: var(--ar-muted);
  font-size: 12px;
  font-style: normal;
}

.ar-fascicolo-missing {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.ar-fascicolo-missing small {
  flex: 0 0 100%;
  color: var(--ar-muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.ar-fascicolo-missing b,
.ar-missing-upload button {
  border-radius: 999px;
  background: #fff;
  border: 1px solid #eadb91;
  color: var(--ar-brand-dark);
  padding: 5px 8px;
  font-size: 11px;
  line-height: 1.1;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  font-family: inherit;
}

.ar-missing-upload {
  margin: 0;
}

.ar-missing-upload input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.ar-upload-confirm {
  position: fixed;
  inset: 0;
  z-index: 9990;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(10, 12, 20, .38);
}

.ar-upload-confirm[hidden] {
  display: none;
}

.ar-upload-confirm__box {
  width: min(420px, 100%);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 22px 70px rgba(10, 12, 20, .24);
  border: 1px solid rgba(143, 119, 18, .18);
  padding: 18px;
}

.ar-upload-confirm__box h3 {
  margin: 0 0 8px;
  color: var(--ar-ink);
  font-size: 20px;
  line-height: 1.2;
}

.ar-upload-confirm__box p {
  margin: 0;
  color: var(--ar-muted);
  font-size: 14px;
  line-height: 1.45;
}

.ar-upload-confirm__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

.ar-fascicolo-missing.is-complete b {
  border-color: rgba(24, 166, 95, .28);
  color: #0f7b48;
  background: #eefaf3;
}

.ar-crm-property-body {
  padding: 16px;
  display: grid;
  gap: 11px;
}

.ar-crm-property-title {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: start;
}

.ar-crm-property-title strong {
  color: var(--ar-ink);
  font-size: 18px;
  line-height: 1.2;
}

.ar-crm-property-title span {
  border-radius: 999px;
  background: #fff8dc;
  border: 1px solid #eadb91;
  color: var(--ar-brand-dark);
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.ar-crm-property-body > p {
  margin: 0;
  color: var(--ar-muted);
}

.ar-property-price-strip {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 3px;
}

.ar-property-price-strip span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #ece5d6;
  border-radius: 999px;
  background: #fffdf8;
  color: var(--ar-muted);
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  padding: 9px 12px;
}

.ar-property-price-strip strong {
  color: var(--ar-ink);
  font-size: 15px;
  font-weight: 950;
}

.ar-property-purchase-strip span {
  border-color: #a9ddc2;
  background: #eefaf3;
  color: #23704a;
}

.ar-owner-value-trend {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin-top: 13px;
  padding: 16px 18px;
  border: 1px solid #b9dfca;
  border-radius: 12px;
  background: linear-gradient(135deg, #f2fbf6, #fffdf3);
}

.ar-owner-value-trend > div:first-child {
  display: grid;
  gap: 3px;
}

.ar-owner-value-trend > div:first-child > span {
  color: #23704a;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.ar-owner-value-trend > div:first-child > strong {
  color: var(--ar-ink);
  font-size: 24px;
  font-weight: 950;
}

.ar-owner-value-trend > div:first-child > small {
  color: var(--ar-muted);
  font-size: 11px;
}

.ar-owner-value-trend-kpis {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
}

.ar-owner-value-trend-kpis span {
  display: grid;
  gap: 2px;
  border: 1px solid #e2ddcf;
  border-radius: 9px;
  background: #fff;
  color: var(--ar-muted);
  padding: 8px 10px;
  font-size: 10px;
  font-weight: 800;
}

.ar-owner-value-trend-kpis b {
  color: var(--ar-ink);
  font-size: 13px;
  font-weight: 950;
}

.ar-owner-value-trend-kpis .is-positive b { color: #168153; }
.ar-owner-value-trend-kpis .is-negative b { color: #b42318; }

@media (max-width: 760px) {
  .ar-owner-value-trend { grid-template-columns: 1fr; }
  .ar-owner-value-trend-kpis { justify-content: flex-start; }
}

.ar-owner-self-upload {
  margin-top: 14px;
}

.ar-owner-dropin-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px dashed #d8bd48;
  border-radius: 12px;
  padding: 12px 14px;
  background: linear-gradient(135deg, #fffdf5, #fff9df);
  color: var(--ar-ink);
  text-align: left;
  font-family: inherit;
  cursor: pointer;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.ar-owner-dropin-trigger:hover {
  border-color: #c59c00;
  box-shadow: 0 10px 24px rgba(142, 110, 0, .12);
  transform: translateY(-1px);
}

.ar-owner-dropin-trigger-icon {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ar-brand);
  color: #171717;
  font-size: 25px;
  font-weight: 700;
  line-height: 1;
}

.ar-owner-dropin-trigger > span:last-child { display: grid; gap: 3px; }
.ar-owner-dropin-trigger strong { font-size: 14px; font-weight: 950; }
.ar-owner-dropin-trigger small { color: var(--ar-muted); font-size: 11px; font-weight: 700; }

.ar-owner-dropin-modal[hidden] { display: none !important; }
.ar-owner-dropin-modal {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(17, 25, 42, .62);
  backdrop-filter: blur(5px);
}

.ar-owner-dropin-panel {
  width: min(580px, 100%);
  max-height: calc(100vh - 40px);
  overflow: auto;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 28px 80px rgba(0, 0, 0, .28);
  padding: 24px;
}

.ar-owner-dropin-head { display: flex; justify-content: space-between; gap: 18px; align-items: flex-start; margin-bottom: 20px; }
.ar-owner-dropin-head h3 { margin: 0 0 4px; font-size: 24px; color: var(--ar-ink); }
.ar-owner-dropin-head p { margin: 0; color: var(--ar-muted); font-size: 13px; }
.ar-owner-dropin-close { width: 38px; height: 38px; border: 0; border-radius: 50%; background: #f3f2ee; color: #303030; font-size: 22px; cursor: pointer; }
.ar-owner-dropin-field { display: grid; gap: 7px; margin-bottom: 14px; }
.ar-owner-dropin-field > span { font-size: 12px; font-weight: 900; color: var(--ar-ink); }
.ar-owner-dropin-type { width: 100%; min-height: 48px; border: 1px solid #ded9cc; border-radius: 12px; padding: 0 13px; background: #fff; color: var(--ar-ink); font: inherit; }
.ar-owner-dropzone { min-height: 210px; display: grid; place-items: center; border: 2px dashed #d8bd48; border-radius: 16px; background: #fffdf5; padding: 20px; text-align: center; cursor: pointer; transition: .2s ease; }
.ar-owner-dropzone.is-dragover { border-color: #198a5a; background: #eefaf3; transform: scale(1.01); }
.ar-owner-dropzone-icon { width: 58px; height: 58px; display: grid; place-items: center; margin: 0 auto 10px; border-radius: 16px; background: var(--ar-brand); font-size: 27px; }
.ar-owner-dropzone strong { display: block; font-size: 17px; color: var(--ar-ink); }
.ar-owner-dropzone small { display: block; margin-top: 6px; color: var(--ar-muted); font-size: 12px; }
.ar-owner-dropin-preview { width: 100%; display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 16px; align-items: center; text-align: left; }
.ar-owner-dropin-thumb { width: 112px; height: 112px; border-radius: 13px; overflow: hidden; display: grid; place-items: center; background: #f5f3ec; color: #c23535; font-size: 22px; font-weight: 950; }
.ar-owner-dropin-thumb img { width: 100%; height: 100%; object-fit: cover; }
.ar-owner-dropin-file-name { overflow: hidden; text-overflow: ellipsis; font-size: 14px; font-weight: 900; color: var(--ar-ink); }
.ar-owner-dropin-file-size { margin-top: 4px; color: var(--ar-muted); font-size: 12px; }
.ar-owner-dropin-remove { margin-top: 12px; border: 1px solid #e0d9c8; border-radius: 999px; padding: 8px 13px; background: #fff; color: #9b2d2d; font: inherit; font-size: 12px; font-weight: 900; cursor: pointer; }
.ar-owner-dropin-error { min-height: 18px; margin: 8px 0 0; color: #b42318; font-size: 12px; font-weight: 800; }
.ar-owner-dropin-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; }
.ar-owner-dropin-actions button { min-height: 44px; border-radius: 999px; padding: 0 20px; font: inherit; font-weight: 950; cursor: pointer; }
.ar-owner-dropin-cancel { border: 1px solid #ded9cc; background: #fff; color: var(--ar-ink); }
.ar-owner-dropin-submit { border: 0; background: var(--ar-brand); color: #171717; }
.ar-owner-dropin-submit:disabled { opacity: .45; cursor: not-allowed; }
.ar-owner-dropin-note { margin: 13px 0 0; color: var(--ar-muted); font-size: 11px; text-align: center; }
}

.ar-owner-personal-upload {
  margin: 12px 0 16px;
}

@media (max-width: 900px) {
  .ar-owner-dropin-panel { padding: 18px; border-radius: 16px; }
  .ar-owner-dropin-preview { grid-template-columns: 82px minmax(0, 1fr); }
  .ar-owner-dropin-thumb { width: 82px; height: 82px; }
}

.ar-fascicolo-meter {
  display: grid;
  border: 1px solid #efeadf;
  border-radius: 8px;
  background: #fffdf8;
  padding: 11px 12px;
}

.ar-fascicolo-meter strong {
  display: block;
  color: var(--ar-ink);
  font-size: 14px;
}

.ar-fascicolo-meter span {
  display: block;
  margin-top: 3px;
  color: var(--ar-muted);
  font-size: 12px;
  line-height: 1.35;
}

.ar-fascicolo-bar {
  height: 10px;
  border-radius: 999px;
  background: #e6ddbf;
  overflow: hidden;
}

.ar-fascicolo-bar span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #c99800, #18a65f);
  min-width: 3px;
}

.ar-crm-property-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.ar-crm-property-stats div {
  border: 1px solid #efeadf;
  border-radius: 8px;
  padding: 10px;
  background: #fffdf8;
}

.ar-crm-property-stats strong {
  display: block;
  color: var(--ar-ink);
  font-size: 18px;
  line-height: 1;
}

.ar-crm-property-stats span {
  display: block;
  margin-top: 5px;
  color: var(--ar-muted);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.ar-owner-market-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0;
}

.ar-owner-market-grid div {
  border: 1px solid #e4eee9;
  background: linear-gradient(180deg, #f7fffb, #ffffff);
  border-radius: 8px;
  padding: 12px;
  min-width: 0;
}

.ar-owner-market-grid span {
  display: block;
  color: #6d7582;
  font-size: 11px;
  text-transform: uppercase;
  font-weight: 950;
  margin-bottom: 6px;
}

.ar-owner-market-grid strong {
  display: block;
  color: #142033;
  font-size: 17px;
  line-height: 1.2;
}

.ar-owner-market-note {
  border: 1px solid #efe1a6;
  background: #fffaf0;
  border-radius: 8px;
  padding: 12px 14px;
  margin-bottom: 12px;
}

.ar-owner-market-note strong {
  color: #806300;
  font-size: 13px;
}

.ar-owner-market-note p {
  margin: 5px 0 0;
  font-size: 13px;
}

.ar-publication-panel {
  display: grid;
  gap: 12px;
  border: 1px solid #e4eee9;
  border-radius: 8px;
  background: linear-gradient(180deg, #fbfffd, #ffffff);
  padding: 14px;
}

.ar-publication-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
}

.ar-publication-head span,
.ar-publication-kpis span {
  display: block;
  color: #647282;
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
}

.ar-publication-head strong {
  display: block;
  margin-top: 4px;
  color: #142033;
  font-size: 20px;
  line-height: 1.15;
}

.ar-publication-head em {
  border-radius: 999px;
  background: #eef8f1;
  border: 1px solid rgba(24, 166, 95, .22);
  color: #0f7b48;
  padding: 8px 11px;
  font-size: 12px;
  font-style: normal;
  font-weight: 950;
  white-space: nowrap;
}

.ar-publication-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.ar-publication-kpis div {
  min-width: 0;
  border: 1px solid #edf0ec;
  border-radius: 8px;
  background: #fff;
  padding: 11px;
}

.ar-publication-kpis strong {
  display: block;
  margin-top: 5px;
  color: #172033;
  font-size: 22px;
  line-height: 1;
}

.ar-publication-kpis small {
  display: block;
  margin-top: 5px;
  color: #697386;
  font-size: 12px;
  font-weight: 850;
}

.ar-publication-portals {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.ar-publication-portals div {
  min-width: 0;
  border: 1px solid #efe9d8;
  border-radius: 8px;
  background: #fffdf8;
  padding: 10px;
}

.ar-publication-portals strong,
.ar-publication-portals span,
.ar-publication-portals small {
  display: block;
}

.ar-publication-portals strong {
  color: #232938;
  font-size: 13px;
}

.ar-publication-portals span {
  margin-top: 4px;
  color: #806300;
  font-size: 13px;
  font-weight: 900;
}

.ar-publication-portals small {
  margin-top: 2px;
  color: #697386;
  font-size: 12px;
  font-weight: 850;
}

.ar-publication-advice {
  border-radius: 8px;
  border: 1px solid #e4e8ef;
  background: #f7f9fc;
  padding: 12px;
}

.ar-publication-advice strong {
  display: block;
  color: #172033;
  font-size: 14px;
}

.ar-publication-advice p {
  margin: 5px 0 0;
  color: #5d6878;
  font-size: 13px;
  line-height: 1.42;
}

.ar-publication-advice.is-good {
  border-color: rgba(24, 166, 95, .25);
  background: #eefaf3;
}

.ar-publication-advice.is-attention,
.ar-publication-advice.is-warning {
  border-color: rgba(211, 159, 18, .30);
  background: #fff8e2;
}

.ar-publication-advice.is-critical {
  border-color: rgba(186, 68, 68, .26);
  background: #fff3f0;
}

.ar-publication-panel .gb-mca-panel {
  margin-top: 14px;
  border: 1px solid #d8e4ee;
  border-radius: 14px;
  background: #f8fbfd;
  padding: 16px;
}

.gb-mca-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.gb-mca-head span,
.gb-mca-kpis span,
.gb-mca-kpis small {
  display: block;
  color: #64748b;
  font-size: 12px;
  line-height: 1.35;
}

.gb-mca-head strong {
  display: block;
  margin-top: 3px;
  color: #0f172a;
  font-size: 22px;
  line-height: 1.15;
}

.gb-mca-head em {
  color: #607080;
  font-size: 13px;
  line-height: 1.45;
  max-width: 280px;
  text-align: right;
}

.gb-mca-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.gb-mca-kpis div,
.gb-mca-kpi-card {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  padding: 11px;
}

.gb-mca-kpis strong,
.gb-mca-kpi-card strong {
  display: block;
  margin-top: 4px;
  color: #1f2937;
  font-size: 14px;
  line-height: 1.25;
}

.gb-mca-kpi-card {
  width: 100%;
  text-align: left;
  font: inherit;
  cursor: pointer;
}

.gb-mca-comparable-trigger {
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.gb-mca-comparable-trigger:hover,
.gb-mca-comparable-trigger:focus {
  border-color: #ded3a1;
  background: #fffdf5;
  box-shadow: 0 10px 22px rgba(122, 100, 36, .09);
  outline: 0;
  transform: translateY(-1px);
}

.gb-mca-advice {
  margin: 12px 0 0;
  color: #475569;
  font-size: 13px;
  line-height: 1.55;
}

.gb-mca-note,
.gb-mca-modal-note {
  margin: 10px 0 0;
  border: 1px solid #dbe7ef;
  border-radius: 10px;
  background: #f8fbfd;
  color: #526173;
  font-size: 12px;
  line-height: 1.45;
  padding: 10px 11px;
}

.gb-mca-comparables {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.gb-mca-comparables div {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  padding: 10px;
}

.gb-mca-comparables strong,
.gb-mca-comparables span,
.gb-mca-comparables small {
  display: block;
  line-height: 1.3;
}

.gb-mca-comparables strong {
  color: #1f2937;
  font-size: 13px;
}

.gb-mca-comparables span {
  margin-top: 4px;
  color: #475569;
  font-size: 12px;
}

.gb-mca-comparables small {
  margin-top: 5px;
  color: #8a6f00;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.ar-fascicolo-side .gb-mca-panel.is-owner-side {
  margin-top: 18px;
  border: 1px solid #d8e4ee;
  border-radius: 14px;
  background: #f8fbfd;
  padding: 14px;
}

.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-head {
  display: block;
}

.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-head strong {
  font-size: 24px;
}

.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-head em {
  display: block;
  max-width: none;
  margin-top: 6px;
  text-align: left;
}

.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-kpis,
.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-comparables {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-kpis {
  gap: 8px;
}

.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-kpis div,
.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-comparables div {
  padding: 9px 10px;
}

.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-advice {
  font-size: 12px;
  line-height: 1.45;
}

.ar-fascicolo-side .gb-mca-panel.is-owner-side .gb-mca-comparables {
  display: none;
}

.gb-mca-modal[hidden] {
  display: none;
}

.gb-mca-modal {
  position: fixed;
  inset: 0;
  z-index: 10050;
}

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

.gb-mca-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(14, 20, 32, .44);
}

.gb-mca-modal-box {
  position: relative;
  width: min(760px, calc(100vw - 28px));
  max-height: calc(100vh - 64px);
  overflow: auto;
  margin: 32px auto;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(15, 23, 42, .28);
  padding: 18px;
}

.gb-mca-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid #edf1f5;
}

.gb-mca-modal-head span {
  display: block;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.gb-mca-modal-head strong {
  display: block;
  margin-top: 4px;
  color: #111827;
  font-size: 20px;
}

.gb-mca-modal-head button {
  width: 36px;
  height: 36px;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #fff;
  color: #111827;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.gb-mca-modal-list {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.gb-mca-modal-row {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) 120px 78px 112px;
  gap: 10px;
  align-items: center;
  border: 1px solid #edf1f5;
  border-radius: 10px;
  background: #fbfcfd;
  padding: 11px;
}

.gb-mca-modal-row strong,
.gb-mca-modal-row span,
.gb-mca-modal-row em,
.gb-mca-modal-row b {
  display: block;
  line-height: 1.3;
}

.gb-mca-modal-row strong {
  color: #111827;
  font-size: 14px;
}

.gb-mca-modal-row span,
.gb-mca-modal-row em {
  color: #64748b;
  font-size: 12px;
  font-style: normal;
}

.gb-mca-modal-row b {
  color: #1f2937;
  font-size: 13px;
  text-align: right;
}

.gb-mca-modal-note {
  margin-top: 14px;
}

@media (max-width: 760px) {
  .gb-mca-modal-row {
    grid-template-columns: 1fr;
  }

  .gb-mca-modal-row b {
    text-align: left;
  }
}

.ar-owner-documents-card {
  align-self: start;
  background: linear-gradient(180deg, #ffffff, #fffdf7);
}

.ar-owner-doc-preview-list {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.ar-owner-doc-preview {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border: 1px solid #efeadf;
  border-radius: 8px;
  padding: 10px;
  background: #fff;
}

.ar-owner-doc-preview > span {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: #fff5c8;
  color: #7c6000;
  font-size: 11px;
  font-weight: 950;
}

.ar-owner-doc-preview strong,
.ar-owner-doc-preview small {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ar-owner-doc-preview strong {
  color: var(--ar-ink);
  font-size: 13px;
}

.ar-owner-doc-preview small {
  margin-top: 3px;
  color: var(--ar-muted);
  font-size: 11px;
  font-weight: 800;
}

.ar-owner-doc-preview a,
.ar-owner-documents-open-all {
  border: 1px solid #eadb91;
  background: #fff9df;
  color: #806300;
  border-radius: 999px;
  min-height: 34px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 12px;
  font-weight: 950;
}

.ar-owner-documents-open-all {
  width: 100%;
  margin-top: 14px;
  cursor: pointer;
  font-family: inherit;
}

.ar-owner-docs-panel {
  width: min(1080px, calc(100vw - 28px));
  max-height: min(860px, calc(100vh - 28px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.ar-owner-docs-panel .ar-doc-modal-property {
  min-height: 0;
  overflow: auto;
  padding: 18px 20px 22px;
}

.ar-owner-doc-folder-section {
  margin-top: 14px;
}

.ar-owner-doc-folder-section .ar-notary-folder-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.ar-owner-folder-modal {
  z-index: 150;
}

.ar-owner-folder-browser {
  padding-top: 14px;
}

.ar-owner-appointments {
  margin-top: 16px;
  display: grid;
  gap: 8px;
}

.ar-owner-appointments h4 {
  margin: 0;
  color: var(--ar-ink);
  font-size: 14px;
}

.ar-owner-appointment {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border-top: 1px solid #f0ece5;
  padding-top: 9px;
}

.ar-owner-appointment strong {
  color: var(--ar-ink);
  font-size: 13px;
}

.ar-owner-appointment span {
  color: var(--ar-muted);
  font-size: 13px;
}

.ar-owner-appointment em {
  border-radius: 999px;
  background: #fff8dc;
  color: var(--ar-brand-dark);
  font-style: normal;
  font-size: 12px;
  font-weight: 900;
  padding: 6px 9px;
}

.ar-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(17, 24, 39, .46);
}

.ar-modal-backdrop[hidden] {
  display: none;
}

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

.ar-modal-panel {
  width: min(920px, 100%);
  max-height: min(760px, calc(100vh - 44px));
  overflow: auto;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 28px 70px rgba(17, 24, 39, .24);
  border: 1px solid #ece5d6;
}

.ar-modal-head {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  padding: 18px 20px;
  border-bottom: 1px solid #f0ece5;
  background: #fffdf8;
}

.ar-modal-head h3,
.ar-modal-head p {
  margin: 0;
}

.ar-modal-head p {
  margin-top: 4px;
  color: var(--ar-muted);
}

.ar-modal-close {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid #eadb91;
  background: #fff;
  color: var(--ar-brand-dark);
  cursor: pointer;
  font-size: 18px;
  font-weight: 900;
}

.ar-doc-modal-property {
  padding: 18px 20px 22px;
}

.ar-doc-modal-property h4 {
  margin: 0 0 12px;
  color: var(--ar-ink);
  font-size: 16px;
}

.ar-doc-folder {
  border: 1px solid #f0ece5;
  border-radius: 8px;
  margin-bottom: 12px;
  padding: 12px 14px 2px;
  background: #fff;
}

.ar-doc-folder > strong {
  display: block;
  margin-bottom: 2px;
  color: var(--ar-brand-dark);
  font-size: 13px;
  text-transform: uppercase;
}

.ar-empty {
  border: 1px dashed #d9d3c7;
  border-radius: 8px;
  padding: 16px;
  color: var(--ar-muted);
}

.ar-doc-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border-top: 1px solid #f0ece5;
  padding: 11px 0;
}

.ar-doc-row span {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: #fff7d5;
  color: var(--ar-brand-dark);
  font-weight: 900;
  font-size: 10px;
}

.ar-doc-row a,
.ar-doc-row button {
  background: #fff;
  border: 1px solid #eadb91;
  border-radius: 8px;
  color: var(--ar-brand-dark);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 64px;
  min-height: 34px;
  padding: 0 12px;
  text-decoration: none;
  font-size: 12px;
  font-weight: 900;
}

.ar-doc-row strong {
  display: block;
  overflow-wrap: anywhere;
}

.ar-doc-row small,
.ar-doc-row em {
  display: block;
  color: var(--ar-muted);
  font-size: 12px;
  font-style: normal;
  line-height: 1.35;
}

.ar-doc-row-attachment {
  margin-left: 34px;
  border: 1px dashed #eadb91;
  border-radius: 8px;
  padding: 10px;
  background: #fffdf3;
}

.ar-doc-row-attachment::before {
  content: "Allegato";
  grid-column: 1 / -1;
  color: #8a6f1e;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.ar-doc-section {
  margin-top: 14px;
}

.ar-notary-dashboard {
  display: grid;
  gap: 16px;
}

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

.ar-notary-kpis > div {
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fff;
  padding: 14px;
  min-height: 118px;
  display: grid;
  align-content: end;
  position: relative;
  overflow: hidden;
}

.ar-notary-kpis > div:after {
  content: "";
  position: absolute;
  right: -26px;
  bottom: -30px;
  width: 92px;
  height: 92px;
  border-radius: 50%;
  background: rgba(210, 173, 37, .12);
}

.ar-notary-kpis .is-todo {
  border-color: rgba(205, 69, 46, .22);
  background: #fff8f6;
}

.ar-notary-kpis .is-wait {
  border-color: rgba(220, 157, 34, .24);
  background: #fffaf0;
}

.ar-notary-kpis .is-done {
  border-color: rgba(24, 166, 95, .22);
  background: #f2fbf6;
}

.ar-notary-kpis strong {
  color: var(--ar-ink);
  font-size: 34px;
  line-height: 1;
}

.ar-notary-kpis span {
  margin-top: 8px;
  color: var(--ar-ink);
  font-size: 15px;
  font-weight: 900;
}

.ar-notary-kpis small {
  color: var(--ar-muted);
  font-size: 12px;
  font-weight: 800;
}

.ar-notary-rule {
  border: 1px solid #eadb91;
  border-radius: 8px;
  background: #fffdf4;
  padding: 13px 14px;
  display: grid;
  gap: 4px;
}

.ar-notary-rule strong {
  color: var(--ar-brand-dark);
}

.ar-notary-rule span {
  color: var(--ar-muted);
  line-height: 1.45;
}

.ar-notary-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: end;
  margin: 14px 0 4px;
}

.ar-notary-search label {
  grid-column: 1 / -1;
  color: #4b5563;
  font-size: 12px;
  font-weight: 900;
}

.ar-notary-search input {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  background: #fff;
  color: var(--ar-ink);
  padding: 0 13px;
  font: inherit;
  font-size: 13px;
}

.ar-notary-search input:focus {
  outline: 2px solid rgba(243, 200, 71, .34);
  border-color: rgba(243, 200, 71, .9);
}

.ar-notary-search button {
  min-height: 42px;
  border: 1px solid #e8d989;
  border-radius: 8px;
  background: #fff7d7;
  color: #202436;
  padding: 0 13px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.ar-notary-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.ar-notary-column {
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fffdfb;
  overflow: hidden;
}

.ar-notary-column-head {
  min-height: 88px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  border-bottom: 1px solid #f0ece5;
}

.ar-notary-column-head h4,
.ar-notary-column-head p {
  margin: 0;
}

.ar-notary-column-head h4 {
  color: var(--ar-ink);
  font-size: 18px;
}

.ar-notary-column-head p {
  margin-top: 4px;
  color: var(--ar-muted);
  font-size: 12px;
  line-height: 1.35;
}

.ar-notary-column-head strong {
  width: 38px;
  height: 38px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #fff8dc;
  color: var(--ar-brand-dark);
}

.ar-notary-list {
  display: grid;
  gap: 10px;
  padding: 12px;
  max-height: 520px;
  overflow: auto;
}

.ar-notary-search-empty[hidden] {
  display: none;
}

.ar-notary-item {
  border: 1px solid #ece5d6;
  border-radius: 8px;
  background: #fff;
  padding: 12px;
  display: grid;
  gap: 10px;
}

.ar-notary-item-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.ar-notary-item-head strong {
  display: block;
  color: var(--ar-ink);
  font-size: 14px;
  line-height: 1.25;
}

.ar-notary-item-head span,
.ar-notary-item p {
  color: var(--ar-muted);
  font-size: 12px;
  line-height: 1.35;
}

.ar-notary-item p {
  margin: 0;
}

.ar-notary-pill {
  border-radius: 999px;
  padding: 6px 8px;
  font-size: 11px;
  line-height: 1;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.ar-notary-pill-todo {
  background: #fff1ed;
  color: #a03b2b;
}

.ar-notary-pill-waiting_act {
  background: #fff8dc;
  color: var(--ar-brand-dark);
}

.ar-notary-pill-done {
  background: #eefaf3;
  color: #0f7b48;
}

.ar-notary-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ar-notary-checks span {
  border-radius: 999px;
  padding: 6px 8px;
  font-size: 11px;
  font-weight: 900;
  background: #f7f5ee;
  color: var(--ar-muted);
}

.ar-notary-checks .is-ok {
  background: #eefaf3;
  color: #0f7b48;
}

.ar-notary-checks .is-missing {
  background: #fff1ed;
  color: #a03b2b;
}

.ar-notary-docs {
  display: grid;
  gap: 7px;
}

.ar-notary-docs a {
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--ar-ink);
  font-size: 12px;
  font-weight: 800;
}

.ar-notary-docs b {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #fff7d5;
  color: var(--ar-brand-dark);
  font-size: 10px;
}

.ar-notary-docs span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ar-notary-details {
  border-top: 1px solid #f0ece5;
  padding-top: 8px;
}

.ar-notary-details summary {
  cursor: pointer;
  color: var(--ar-brand-dark);
  font-size: 12px;
  font-weight: 900;
  list-style: none;
}

.ar-notary-details summary::-webkit-details-marker {
  display: none;
}

.ar-notary-details summary:after {
  content: "+";
  float: right;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #fff8dc;
  color: var(--ar-brand-dark);
}

.ar-notary-details[open] summary:after {
  content: "-";
}

.ar-notary-workspace-open {
  justify-self: start;
  border: 1px solid var(--ar-brand);
  border-radius: 999px;
  background: var(--ar-brand);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  padding: 9px 16px;
  cursor: pointer;
}

.ar-notary-workspace-open:hover {
  background: var(--ar-brand-dark);
  border-color: var(--ar-brand-dark);
}

.ar-notary-workspace-panel {
  width: min(1320px, calc(100vw - 28px));
  height: min(900px, calc(100vh - 28px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.ar-notary-workspace-body {
  min-height: 0;
  overflow: auto;
  padding: 18px 20px 24px;
  display: grid;
  gap: 16px;
  background: #fff;
}

.ar-notary-workspace-status {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ar-notary-workspace-status span {
  border: 1px solid #eee6d7;
  border-radius: 999px;
  background: #fffdf4;
  color: var(--ar-muted);
  font-size: 12px;
  font-weight: 900;
  padding: 7px 10px;
}

.ar-notary-workspace-status span.is-ok {
  border-color: #b9dfc8;
  background: #f0fff5;
  color: #197342;
}

.ar-notary-workspace-status span.is-missing {
  border-color: #ffd6c9;
  background: #fff5f0;
  color: #b04424;
}

.ar-notary-upload-box,
.ar-notary-section {
  margin-top: 12px;
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fffdf8;
  padding: 12px;
}

.ar-notary-upload-box > strong,
.ar-notary-section h5 {
  display: block;
  margin: 0 0 10px;
  color: var(--ar-ink);
  font-size: 13px;
  font-weight: 900;
}

.ar-notary-property-specs {
  background: #ffffff;
}

.ar-notary-spec-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.ar-notary-spec-item {
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fffdf8;
  padding: 9px 10px;
  min-width: 0;
}

.ar-notary-spec-item span {
  display: block;
  color: var(--ar-muted);
  font-size: 10px;
  line-height: 1.25;
  font-weight: 900;
  text-transform: uppercase;
}

.ar-notary-spec-item strong {
  display: block;
  margin-top: 4px;
  color: var(--ar-ink);
  font-size: 12px;
  line-height: 1.35;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.ar-notary-upload-box form {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
}

.ar-notary-upload-box select,
.ar-notary-upload-box input[type="file"] {
  width: 100%;
  border: 1px solid #ece5d6;
  border-radius: 8px;
  background: #fff;
  color: var(--ar-ink);
  font-size: 12px;
  padding: 9px 10px;
}

.ar-notary-upload-box button {
  justify-self: start;
  border: 1px solid var(--ar-brand);
  border-radius: 999px;
  background: var(--ar-brand);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  padding: 9px 16px;
  cursor: pointer;
}

.ar-notary-folder-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.ar-notary-folder {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fff;
  padding: 9px 10px;
  cursor: pointer;
  text-align: left;
}

.ar-notary-folder:hover {
  border-color: #d9c05f;
  background: #fffbea;
}

.ar-notary-folder strong {
  color: var(--ar-ink);
  font-size: 12px;
  overflow-wrap: anywhere;
}

.ar-notary-folder span {
  color: var(--ar-muted);
  font-size: 11px;
  font-weight: 900;
  white-space: nowrap;
}

.ar-notary-parties {
  display: grid;
  gap: 10px;
}

.ar-notary-party-group {
  display: grid;
  gap: 8px;
}

.ar-notary-party-group h5 {
  margin-bottom: 0;
}

.ar-notary-party {
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fff;
  padding: 10px;
  display: grid;
  gap: 8px;
}

.ar-notary-party > strong {
  color: var(--ar-ink);
  font-size: 13px;
  line-height: 1.25;
}

.ar-notary-party dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin: 0;
}

.ar-notary-party dl div {
  min-width: 0;
}

.ar-notary-party dt {
  color: var(--ar-muted);
  font-size: 10px;
  font-weight: 900;
  text-transform: uppercase;
}

.ar-notary-party dd {
  margin: 1px 0 0;
  color: var(--ar-ink);
  font-size: 12px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.ar-notary-party dd a {
  color: #174b35;
  font-weight: 900;
  text-decoration: none;
}

.ar-notary-party dd a:hover {
  text-decoration: underline;
}

.ar-notary-party-note {
  border: 1px solid #eee7d2;
  border-radius: 8px;
  background: #fffdf3;
  color: #3d4350;
  padding: 8px 10px;
  font-size: 12px;
  line-height: 1.35;
}

.ar-bank-parties-card {
  background: linear-gradient(180deg, #fff, #fbfdfb);
}

.ar-bank-property-parties {
  display: grid;
  gap: 10px;
  padding-top: 12px;
  margin-top: 12px;
  border-top: 1px solid #f0ece5;
}

.ar-bank-property-parties h4 {
  margin: 0;
  color: #232938;
  font-size: 14px;
}

.ar-notary-party-docs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ar-notary-party-docs a,
.ar-notary-party-docs span {
  border: 1px solid #ece5d6;
  border-radius: 999px;
  background: #fffdf4;
  color: var(--ar-brand-dark);
  font-size: 11px;
  font-weight: 900;
  padding: 6px 8px;
  text-decoration: none;
}

.ar-notary-party-docs span {
  color: var(--ar-muted);
}

.ar-notary-wip-grid {
  display: grid;
  gap: 8px;
}

.ar-notary-wip-grid > div {
  border: 1px dashed #dccb7d;
  border-radius: 8px;
  background: #fff;
  padding: 10px;
  display: grid;
  gap: 4px;
}

.ar-notary-wip-grid strong {
  color: var(--ar-ink);
  font-size: 12px;
}

.ar-notary-wip-grid span {
  color: var(--ar-muted);
  font-size: 12px;
  line-height: 1.4;
}

.ar-notary-folder-panel {
  width: min(1180px, calc(100vw - 32px));
  height: min(820px, calc(100vh - 32px));
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
}

.ar-notary-folder-browser {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(250px, 330px) minmax(0, 1fr);
  gap: 14px;
  padding: 16px 18px 18px;
}

.ar-notary-folder-files {
  min-height: 0;
  overflow: auto;
  display: grid;
  align-content: start;
  gap: 8px;
  border-right: 1px solid #f0ece5;
  padding-right: 12px;
}

.ar-notary-folder-files button {
  width: 100%;
  border: 1px solid #ece5d6;
  border-radius: 8px;
  background: #fff;
  color: var(--ar-ink);
  text-align: left;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 5px 9px;
  align-items: center;
  padding: 9px;
  cursor: pointer;
}

.ar-notary-folder-files button:hover,
.ar-notary-folder-files button.is-active {
  border-color: #d9c05f;
  background: #fffbea;
}

.ar-notary-folder-files .ar-notary-folder-file-attachment {
  position: relative;
  margin-left: 30px;
  width: calc(100% - 30px);
  grid-template-columns: 58px minmax(0, 1fr);
  border-style: dashed;
  border-color: #eadb91;
  background: linear-gradient(180deg, #fffdf7, #fffaf0);
}

.ar-notary-folder-files .ar-notary-folder-file-attachment:before {
  content: "";
  position: absolute;
  left: -18px;
  top: -10px;
  bottom: 50%;
  width: 12px;
  border-left: 2px solid #d9c05f;
  border-bottom: 2px solid #d9c05f;
  border-bottom-left-radius: 8px;
}

.ar-notary-folder-files b {
  grid-row: span 2;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: #fff7d5;
  color: var(--ar-brand-dark);
  font-size: 10px;
}

.ar-notary-folder-files span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 900;
}

.ar-notary-folder-files small {
  color: var(--ar-muted);
  font-size: 11px;
  font-weight: 800;
}

.ar-notary-folder-files .ar-notary-folder-file-attachment small {
  grid-column: 1;
  justify-self: center;
  max-width: 64px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border-radius: 999px;
  background: #eefaf3;
  color: #0f6f47;
  font-size: 9px;
  line-height: 1;
  font-weight: 950;
  padding: 4px 6px;
}

.ar-notary-preview {
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 10px;
}

.ar-notary-preview iframe,
.ar-notary-preview img {
  width: 100%;
  height: 100%;
  min-height: 540px;
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #f7f5ee;
}

.ar-notary-preview img {
  object-fit: contain;
  padding: 10px;
}

.ar-notary-preview a {
  justify-self: end;
  border: 1px solid var(--ar-brand);
  border-radius: 999px;
  background: var(--ar-brand);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  padding: 9px 14px;
  text-decoration: none;
}

.ar-notary-preview-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.ar-notary-preview-actions a {
  justify-self: auto;
}

.ar-notary-preview-actions a:last-child {
  border-color: #174b35;
  background: #174b35;
}

.ar-inline-preview-panel {
  width: min(980px, calc(100vw - 28px));
  max-height: min(900px, calc(100vh - 28px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.ar-inline-preview-modal {
  z-index: 160;
}

.ar-inline-preview-body {
  min-height: 0;
  display: grid;
  place-items: center;
  padding: 16px 18px;
  background: #f8f6ef;
  overflow: auto;
  user-select: none;
}

.ar-inline-preview-body.is-draggable {
  cursor: grab;
}

.ar-inline-preview-body.is-dragging {
  cursor: grabbing;
}

.ar-inline-preview-body img,
.ar-inline-preview-body iframe {
  max-width: 100%;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(17, 24, 39, .16);
}

.ar-inline-preview-body img {
  width: auto;
  max-width: 100%;
  max-height: calc(100vh - 210px);
  object-fit: contain;
  transition: transform .18s ease;
  transform-origin: center center;
  will-change: transform;
}

.ar-inline-preview-body iframe {
  width: 100%;
  height: calc(100vh - 220px);
  min-height: 520px;
  border: 1px solid #e9e3d7;
}

.ar-inline-preview-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 12px 18px 16px;
  border-top: 1px solid #f0ece5;
  background: #fffdf8;
}

.ar-inline-preview-actions a,
.ar-inline-preview-actions button {
  border: 1px solid var(--ar-brand);
  border-radius: 999px;
  background: var(--ar-brand);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  padding: 9px 14px;
  text-decoration: none;
  cursor: pointer;
}

.ar-inline-preview-actions button {
  background: #fff;
  color: var(--ar-brand-dark);
}

.ar-inline-preview-actions button[hidden] {
  display: none;
}

.ar-fascicolo-summary-panel {
  width: min(780px, 100%);
}

.ar-fascicolo-summary-body {
  padding: 18px 20px 22px;
}

.ar-fascicolo-summary-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.ar-fascicolo-summary-stats span {
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fffdf8;
  padding: 12px;
  color: var(--ar-muted);
  font-size: 12px;
  font-weight: 800;
}

.ar-fascicolo-summary-stats strong {
  display: block;
  color: var(--ar-ink);
  font-size: 24px;
  line-height: 1;
  margin-bottom: 6px;
}

.ar-fascicolo-summary-list {
  display: grid;
  gap: 10px;
}

.ar-fascicolo-summary-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px 14px;
  border: 1px solid #f0ece5;
  border-radius: 8px;
  background: #fff;
  padding: 14px;
}

.ar-fascicolo-summary-item strong {
  display: block;
  color: var(--ar-ink);
  line-height: 1.25;
}

.ar-fascicolo-summary-item small {
  display: block;
  margin-top: 4px;
  color: var(--ar-muted);
  font-size: 12px;
}

.ar-fascicolo-summary-item em {
  border-radius: 999px;
  background: #fff8dc;
  border: 1px solid #eadb91;
  color: var(--ar-brand-dark);
  align-self: start;
  padding: 7px 10px;
  font-style: normal;
  font-size: 13px;
  font-weight: 900;
}

.ar-fascicolo-summary-missing {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.ar-fascicolo-summary-missing span {
  border-radius: 999px;
  background: #fff7f3;
  border: 1px solid #f0c7b8;
  color: #9a3b20;
  padding: 6px 9px;
  font-size: 12px;
  font-weight: 900;
}

.ar-doc-section h4 {
  margin: 0 0 6px;
  font-size: 13px;
  color: #4c5362;
  text-transform: uppercase;
  font-weight: 900;
  letter-spacing: .04em;
}

.ar-mini-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.ar-mini-kpis div {
  border: 1px solid #eee7d2;
  border-radius: 8px;
  padding: 10px;
}

.ar-mini-kpis strong {
  display: block;
  font-size: 22px;
}

.ar-mini-kpis span {
  color: var(--ar-muted);
  font-size: 12px;
  font-weight: 800;
}

.ar-timeline {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.ar-timeline div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border-top: 1px solid #f0ece5;
  padding-top: 8px;
}

.ar-timeline strong {
  overflow-wrap: anywhere;
}

.ar-timeline span {
  color: var(--ar-muted);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.ar-timeline.compact div {
  grid-template-columns: auto minmax(0, 1fr);
}

.ar-choice {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 34px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.84), rgba(255,255,255,.55)),
    radial-gradient(circle at 18% 0%, rgba(243,200,71,.28), transparent 34%),
    var(--ar-bg);
}

.ar-choice-card {
  width: min(1120px, 100%);
  background: rgba(255,255,255,.96);
  border: 1px solid var(--ar-line);
  border-radius: 16px;
  box-shadow: 0 24px 70px rgba(23,27,38,.12);
  padding: 28px;
  margin: 0 auto;
}

.ar-choice-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 34px;
}

.ar-choice-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.ar-choice-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.ar-choice-brand small {
  display: block;
  color: var(--ar-muted);
  font-size: 12px;
  font-weight: 700;
}

.ar-choice-brand strong {
  display: block;
  font-size: 15px;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ar-choice-card h1 {
  max-width: 780px;
  margin: 0;
  font-size: clamp(32px, 4vw, 52px);
  line-height: 1.04;
}

.ar-choice-card .ar-muted {
  max-width: 780px;
  margin: 14px 0 28px;
  font-size: 16px;
  line-height: 1.55;
}

.ar-choice-list {
  margin-top: 0;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.ar-choice-list .ar-context-card {
  min-height: 118px;
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.ar-choice-list .ar-context-card:hover {
  transform: translateY(-2px);
  border-color: rgba(128,100,0,.45);
  box-shadow: 0 15px 32px rgba(23,27,38,.1);
}

.ar-choice-list .ar-context-card strong {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 16px;
  font-weight: 950;
}

.ar-choice-list .ar-context-card strong:after {
  content: "\2192";
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #fff7d5;
  color: var(--ar-brand-dark);
  flex: 0 0 auto;
}

.ar-choice-list .ar-context-card span {
  font-size: 13px;
}

.ar-choice-list .ar-context-crm {
  background: linear-gradient(180deg,#f7faff,#edf3ff);
  border-color: #d8e2f6;
}

.ar-choice-list .ar-context-crm strong:after {
  background: #dfe9ff;
  color: #2b5cb8;
}

.ar-choice-logout {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 15px;
  margin-top: 0;
  border: 1px solid var(--ar-line);
  border-radius: 999px;
  background: #fff;
  color: #3b4250;
  font-size: 13px;
  font-weight: 850;
  text-decoration: none;
  box-shadow: 0 8px 18px rgba(23,27,38,.05);
}

.ar-choice-logout:before {
  content: "\2190";
  font-weight: 900;
  color: var(--ar-brand-dark);
}

.ar-choice-logout:hover {
  border-color: var(--ar-brand);
  color: var(--ar-brand-dark);
}

.ar-access-gateway {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(120deg, rgba(18, 24, 39, .88), rgba(18, 24, 39, .52)),
    radial-gradient(circle at 80% 20%, rgba(243, 200, 71, .38), transparent 34%),
    var(--ar-bg);
}

.ar-access-panel {
  width: min(920px, 100%);
  background: #fff;
  border: 1px solid var(--ar-line);
  border-radius: 12px;
  box-shadow: var(--ar-shadow);
  padding: 30px;
}

.ar-access-panel > .ar-back-button {
  margin-bottom: 18px;
}

.ar-access-panel h1 {
  margin: 8px 0 10px;
  font-size: clamp(30px, 5vw, 54px);
  line-height: 1.05;
}

.ar-access-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 22px;
}

.ar-access-card {
  min-height: 170px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 22px;
  padding: 20px;
  border: 1px solid #eadb91;
  border-radius: 10px;
  background: #fff9df;
  color: var(--ar-ink);
  text-decoration: none;
}

.ar-access-card strong {
  font-size: 24px;
}

.ar-access-card span {
  color: var(--ar-muted);
  line-height: 1.45;
}

.ar-access-card-dark {
  background: #161d2b;
  border-color: #161d2b;
  color: #fff;
}

.ar-access-card-dark span {
  color: rgba(255, 255, 255, .72);
}

@media (max-width: 1080px) {
  .ar-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ar-choice-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .ar-shell {
    grid-template-columns: 1fr;
  }

  .ar-sidebar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    top: auto;
    height: 64px;
    z-index: 20;
    flex-direction: row;
    justify-content: space-around;
    padding: 8px;
    border-top: 1px solid var(--ar-line);
    border-right: 0;
  }

  .ar-sidebar .ar-logo {
    display: none;
  }

  .ar-sidebar a {
    width: auto;
    min-width: 54px;
    min-height: 44px;
    padding: 0 8px;
  }

  .ar-main {
    padding: 14px 12px 86px;
  }

  .ar-choice {
    padding: 14px;
    align-items: flex-start;
  }

  .ar-choice-card {
    padding: 18px;
  }

  .ar-access-gateway {
    padding: 12px;
  }

  .ar-access-panel {
    padding: 20px;
  }

  .ar-access-actions {
    grid-template-columns: 1fr;
  }

  .ar-choice-top {
    align-items: flex-start;
    flex-direction: column;
    margin-bottom: 24px;
  }

  .ar-choice-actions,
  .ar-topbar-actions {
    justify-content: flex-start;
  }

  .ar-choice-list {
    grid-template-columns: 1fr;
  }

  .ar-choice-card h1 {
    font-size: 32px;
  }

  .ar-logo-wide {
    width: min(100%, 320px);
    height: 124px;
  }

  .ar-topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .ar-hero {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  .ar-context-panel {
    grid-template-columns: 1fr;
    padding: 14px;
  }

  .ar-grid {
    grid-template-columns: 1fr;
  }

  .ar-assist-banner {
    grid-template-columns: 1fr;
  }

  .ar-assist-banner a {
    grid-column: auto;
    grid-row: auto;
    justify-self: start;
  }

  .ar-ops-grid {
    grid-template-columns: 1fr;
  }

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

  .ar-personal-grid > div,
  .ar-field-mini,
  .ar-field-small,
  .ar-field-medium,
  .ar-field-large {
    grid-column: span 1 !important;
  }

  .ar-field-full,
  .ar-personal-field-wide {
    grid-column: 1 / -1 !important;
  }

  @media (max-width: 560px) {
    .ar-personal-grid {
      grid-template-columns: 1fr;
    }

    .ar-personal-grid > div,
    .ar-field-mini,
    .ar-field-small,
    .ar-field-medium,
    .ar-field-large,
    .ar-field-full,
    .ar-personal-field-wide {
      grid-column: 1 / -1 !important;
    }
  }

  .ar-card-wide {
    grid-column: auto;
  }

  .ar-card-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .ar-owner-property-head {
    grid-template-columns: 1fr;
  }

  .ar-owner-property-head > span {
    justify-self: start;
    white-space: normal;
  }

  .ar-owner-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ar-notary-kpis,
  .ar-notary-board {
    grid-template-columns: 1fr;
  }

  .ar-notary-search {
    grid-template-columns: 1fr;
  }

  .ar-notary-search button {
    justify-self: start;
  }

  .ar-notary-spec-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ar-notary-list {
    max-height: none;
  }

  .ar-notary-party dl {
    grid-template-columns: 1fr;
  }

  .ar-notary-folder-grid,
  .ar-notary-folder-browser {
    grid-template-columns: 1fr;
  }

  .ar-notary-folder-panel {
    width: calc(100vw - 18px);
    height: calc(100vh - 18px);
  }

  .ar-notary-folder-files {
    max-height: 210px;
    border-right: 0;
    border-bottom: 1px solid #f0ece5;
    padding-right: 0;
    padding-bottom: 10px;
  }

  .ar-notary-preview iframe,
  .ar-notary-preview img {
    min-height: 360px;
  }

  .ar-owner-feedback div {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }

  .ar-owner-feedback em {
    white-space: normal;
  }

  .ar-crm-property-card {
    grid-template-columns: 1fr;
  }

  .ar-crm-property-media {
    aspect-ratio: 1 / 1;
  }

  .ar-crm-property-title {
    grid-template-columns: 1fr;
  }

  .ar-crm-property-title span {
    justify-self: start;
    white-space: normal;
  }

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

  .ar-owner-market-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ar-publication-head,
  .ar-publication-kpis,
  .ar-publication-portals,
  .gb-mca-kpis {
    grid-template-columns: 1fr;
  }

  .ar-publication-head em {
    justify-self: start;
    white-space: normal;
  }

  .gb-mca-head {
    display: block;
  }

  .gb-mca-head em {
    display: block;
    margin-top: 8px;
    max-width: none;
    text-align: left;
  }

  .ar-owner-doc-preview {
    grid-template-columns: 38px minmax(0, 1fr);
  }

  .ar-owner-doc-preview a {
    grid-column: 2;
    justify-self: start;
  }

  .ar-owner-appointment {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .ar-owner-appointment em {
    justify-self: start;
  }

  .ar-property,
  .ar-doc-row {
    grid-template-columns: 1fr;
  }

  .ar-property span,
  .ar-doc-row a,
  .ar-doc-row button {
    justify-self: start;
  }

  .ar-form-row,
  .ar-timeline div,
  .ar-timeline.compact div {
    grid-template-columns: 1fr;
  }

  .ar-timeline span {
    white-space: normal;
  }
}

.ar-notary-folder-upload {
  display: grid;
  gap: 9px;
  margin: 0 0 14px;
  padding: 12px 14px;
  border: 1px solid #f0df9f;
  border-radius: 12px;
  background: #fffaf0;
}

.ar-notary-folder-upload label {
  color: #182336;
  font-size: 13px;
  font-weight: 900;
}

.ar-notary-folder-upload > div {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.ar-notary-folder-upload input[type="file"] {
  flex: 1 1 280px;
  min-width: 0;
  border: 1px solid #e8e0ca;
  border-radius: 10px;
  background: #fff;
  padding: 9px 10px;
  color: #4b5563;
  font-size: 13px;
  font-weight: 700;
}

.ar-notary-folder-upload button {
  border: 1px solid var(--ar-brand);
  border-radius: 999px;
  background: var(--ar-brand);
  color: #182336;
  font-size: 12px;
  font-weight: 900;
  padding: 10px 14px;
  cursor: pointer;
}

/* Notaio: upload compatto dentro cartelle visibili */
.ar-notary-folder-upload {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: stretch;
  margin: 0 18px 0;
  padding: 10px;
  border: 1px dashed #d8c773;
  border-radius: 10px;
  background: #fffdf5;
}

.ar-notary-folder-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.ar-notary-folder-dropin {
  min-width: 0;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  border: 1px solid #efe3b0;
  border-radius: 9px;
  background: #fff;
  padding: 7px 9px;
  cursor: pointer;
}

.ar-notary-folder-upload.is-dragover .ar-notary-folder-dropin,
.ar-notary-folder-dropin:hover {
  border-color: var(--ar-brand);
  background: #fff9df;
}

.ar-notary-folder-file-preview,
.ar-notary-file-thumb {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #fff2bf;
  color: var(--ar-brand-dark);
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
  border: 1px solid rgba(201, 152, 0, .24);
}

.ar-notary-folder-file-preview img,
.ar-notary-folder-file-preview canvas,
.ar-notary-file-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ar-notary-folder-file-preview.is-doc {
  background: #eef2ff;
  color: #243b6b;
}

.ar-notary-folder-dropin-text {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.ar-notary-folder-dropin-text strong,
.ar-notary-folder-dropin-text em {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ar-notary-folder-dropin-text strong {
  color: #182336;
  font-size: 12px;
  font-weight: 900;
}

.ar-notary-folder-dropin-text em {
  color: #6b7280;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

.ar-notary-folder-upload button {
  align-self: stretch;
  min-width: 82px;
  padding: 0 12px;
  border-radius: 9px;
}

.ar-notary-folder-files button {
  grid-template-columns: 34px minmax(0, 1fr);
  min-height: 46px;
  padding: 6px 8px;
  gap: 3px 8px;
}

.ar-notary-folder-files b {
  width: auto;
  height: auto;
  border-radius: 0;
  background: transparent;
  font-size: 10px;
}

.ar-notary-folder-files span:not(.ar-notary-file-thumb) {
  max-width: 100%;
  font-size: 11px;
}

.ar-notary-folder-files small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
}

@media (max-width: 720px) {
  .ar-owner-doc-folder-section .ar-notary-folder-grid {
    grid-template-columns: 1fr;
  }

  .ar-owner-docs-panel .ar-doc-modal-property {
    padding: 14px;
  }

  .ar-notary-folder-upload {
    grid-template-columns: 1fr;
    margin: 0 12px;
  }

  .ar-notary-folder-upload button {
    min-height: 38px;
  }
}
/* Notaio: allineamento upload cartella e annulla */
.ar-notary-folder-upload {
  grid-template-columns: minmax(260px, 1fr) auto auto;
  align-items: center;
  margin: 12px 18px 0;
}

.ar-notary-folder-dropin {
  min-height: 64px;
  padding: 10px 12px;
}

.ar-notary-folder-upload .ar-notary-upload-submit,
.ar-notary-folder-upload .ar-notary-upload-cancel {
  align-self: center;
  min-height: 48px;
  line-height: 1;
}

.ar-notary-folder-upload .ar-notary-upload-cancel {
  border-color: #eadb91;
  background: #fff;
  color: #7a5d00;
}

.ar-notary-folder-upload .ar-notary-upload-cancel:hover {
  background: #fff8dc;
}

@media (max-width: 720px) {
  .ar-notary-folder-upload {
    grid-template-columns: 1fr;
  }

  .ar-notary-folder-dropin {
    min-height: 72px;
  }
}
/* Notaio: documenti soggetto compatti con micro preview */
.ar-notary-party-docs {
  gap: 5px;
}

.ar-notary-party-docs .ar-notary-party-doc-chip {
  max-width: 176px;
  min-width: 0;
  min-height: 30px;
  display: inline-grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: center;
  gap: 5px;
  padding: 3px 7px 3px 3px;
  border-radius: 999px;
}

.ar-notary-party-doc-thumb {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #fff3bf;
  border: 1px solid rgba(201, 152, 0, .25);
  color: #806000;
  line-height: 1;
  flex: 0 0 auto;
}

.ar-notary-party-doc-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ar-notary-party-doc-thumb b {
  font-size: 8px;
  line-height: 1;
}

.ar-notary-party-doc-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: inherit;
}

.ar-notary-party-docs > span:not(.ar-notary-party-doc-thumb):not(.ar-notary-party-doc-name) {
  padding: 6px 8px;
}
/* Notaio: calendario sopra e board a tutta larghezza */
.ar-grid-notary > .ar-card-wide,
.ar-grid-notary > .ar-notary-dashboard,
.ar-grid-notary > .ar-notary-agenda-card {
  grid-column: 1 / -1;
}

.ar-grid-notary .ar-notary-agenda-card {
  order: 1;
}

.ar-grid-notary .ar-notary-dashboard {
  order: 2;
}

.ar-grid-notary .ar-notary-board {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 980px) {
  .ar-grid-notary .ar-notary-board {
    grid-template-columns: 1fr;
  }
}
/* Notaio: calendario richiudibile */
.ar-notary-agenda-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.ar-notary-agenda-head h3,
.ar-notary-agenda-head p {
  margin: 0;
}

.ar-notary-agenda-head p {
  margin-top: 4px;
}

.ar-notary-agenda-controls {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.ar-notary-agenda-controls button {
  min-height: 38px;
  border: 1px solid var(--ar-brand);
  border-radius: 999px;
  background: var(--ar-brand);
  color: #182336;
  padding: 0 14px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.ar-notary-agenda-controls label {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid #ece5d6;
  border-radius: 999px;
  background: #fffdf8;
  color: #4b5563;
  padding: 0 12px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.ar-notary-agenda-controls input {
  width: 16px;
  height: 16px;
  accent-color: var(--ar-brand);
}

.ar-notary-agenda-body {
  margin-top: 14px;
}

.ar-notary-agenda-body[hidden] {
  display: none;
}

@media (max-width: 760px) {
  .ar-notary-agenda-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .ar-notary-agenda-controls {
    justify-content: flex-start;
  }

  .ar-password-actions {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .ar-notary-spec-grid {
    grid-template-columns: 1fr;
  }
}
/* Notaio: evidenzia la colonna richiamata dal KPI Stato */
.ar-notary-column:target {
  border-color: var(--ar-brand);
  box-shadow: 0 0 0 3px rgba(243, 200, 71, .28), 0 18px 40px rgba(17, 24, 39, .12);
  scroll-margin-top: 18px;
}

.ar-notary-column:target .ar-notary-column-head {
  background: #fff8dc;
}
/* Notaio: popup riepilogo Da lavorare */
.ar-kpi-clickable a,
.ar-kpi-clickable button {
  text-decoration: none;
}

.ar-notary-todo-summary-modal {
  z-index: 150;
}

.ar-notary-todo-summary-panel {
  width: min(760px, calc(100vw - 32px));
  max-height: min(760px, calc(100vh - 32px));
}

.ar-notary-todo-summary-list {
  padding: 18px 20px 22px;
  display: grid;
  gap: 10px;
}

.ar-notary-todo-summary-card {
  border: 1px solid #f0d1c8;
  border-radius: 8px;
  background: #fff8f6;
  padding: 12px;
  display: grid;
  gap: 8px;
}

.ar-notary-todo-summary-card strong {
  display: block;
  color: var(--ar-ink);
  font-size: 14px;
}

.ar-notary-todo-summary-card span {
  color: var(--ar-muted);
  font-size: 12px;
}

.ar-notary-todo-summary-card p {
  margin: 0;
  color: #8a3327;
  font-size: 13px;
  font-weight: 900;
}
/* Notaio: colori e contatori pratiche per stato */
.ar-notary-column-head strong {
  width: 52px;
  height: 52px;
  font-size: 20px;
  font-weight: 950;
  box-shadow: 0 10px 24px rgba(17, 24, 39, .10);
}

.ar-notary-todo {
  border-color: rgba(205, 69, 46, .24);
  background: #fff9f7;
}

.ar-notary-todo .ar-notary-column-head {
  background: #fff3ef;
  border-bottom-color: rgba(205, 69, 46, .18);
}

.ar-notary-todo .ar-notary-column-head strong {
  background: #d84a36;
  color: #fff;
}

.ar-notary-wait {
  border-color: rgba(220, 157, 34, .26);
  background: #fffbf2;
}

.ar-notary-wait .ar-notary-column-head {
  background: #fff6df;
  border-bottom-color: rgba(220, 157, 34, .22);
}

.ar-notary-wait .ar-notary-column-head strong {
  background: #d8941f;
  color: #fff;
}

.ar-notary-done {
  border-color: rgba(24, 166, 95, .24);
  background: #f7fdf9;
}

.ar-notary-done .ar-notary-column-head {
  background: #eefaf3;
  border-bottom-color: rgba(24, 166, 95, .20);
}

.ar-notary-done .ar-notary-column-head strong {
  background: #18a65f;
  color: #fff;
}
/* Notaio: richiesta conclusione pratica */
.ar-notary-completion-request {
  border: 1px solid #eadb91;
  border-radius: 8px;
  background: #fffdf4;
  padding: 12px;
  display: grid;
  gap: 10px;
}
.ar-notary-completion-request.is-disabled { border-color: #e5e7eb; background: #f9fafb; }
.ar-notary-completion-request.is-done { border-color: rgba(24, 166, 95, .24); background: #f2fbf6; }
.ar-notary-completion-request strong { display: block; color: var(--ar-ink); font-size: 13px; }
.ar-notary-completion-request span { display: block; margin-top: 3px; color: var(--ar-muted); font-size: 12px; line-height: 1.35; }
.ar-notary-completion-request form { display: grid; gap: 9px; }
.ar-notary-completion-fields { display: grid; grid-template-columns: minmax(180px, .35fr) minmax(0, 1fr); gap: 9px; }
.ar-notary-completion-request label { color: #4b5563; font-size: 12px; font-weight: 900; }
.ar-notary-completion-request input[type="date"], .ar-notary-completion-request textarea { width: 100%; margin-top: 5px; border: 1px solid #e8e0ca; border-radius: 8px; background: #fff; color: var(--ar-ink); padding: 9px 10px; font: inherit; }
.ar-notary-completion-request textarea { min-height: 74px; resize: vertical; }
.ar-notary-completion-confirm { display: flex; gap: 8px; align-items: flex-start; line-height: 1.35; }
.ar-notary-completion-confirm input { margin-top: 2px; accent-color: var(--ar-brand); }
.ar-notary-completion-request button { justify-self: start; border: 1px solid #18a65f; border-radius: 999px; background: #18a65f; color: #fff; font-size: 12px; font-weight: 900; padding: 10px 14px; cursor: pointer; }
@media (max-width: 760px) { .ar-notary-completion-fields { grid-template-columns: 1fr; } }
/* Sidebar area notaio */
.ar-shell-notary {
  grid-template-columns: 292px minmax(0, 1fr);
  transition: grid-template-columns .22s ease;
}

.ar-shell-notary.is-sidebar-collapsed {
  grid-template-columns: 88px minmax(0, 1fr);
}

.ar-sidebar-notary {
  align-items: stretch;
  gap: 14px;
  width: 292px;
  padding: 16px 12px;
  overflow-y: auto;
  transition: width .22s ease, box-shadow .22s ease, transform .22s ease;
  z-index: 40;
}

.ar-shell-notary.is-sidebar-collapsed .ar-sidebar-notary {
  width: 88px;
  align-items: center;
}

.ar-sidebar-notary .ar-logo {
  align-self: center;
  flex-shrink: 0;
}

.ar-notary-sidebar-toggle,
.ar-notary-mobile-menu {
  border: 1px solid rgba(243, 200, 71, .62);
  background: #fff7d7;
  color: #202436;
  border-radius: 8px;
  min-height: 42px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(32, 36, 54, .08);
}

.ar-notary-sidebar-toggle {
  width: 100%;
}

.ar-notary-mobile-menu {
  display: none;
  padding: 0 14px;
}

.ar-notary-nav {
  display: grid;
  gap: 8px;
}

.ar-notary-nav a {
  position: relative;
  width: 100%;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid var(--ar-line);
  background: #fff;
  color: #202436;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

.ar-notary-nav a.active,
.ar-notary-nav a:hover {
  background: #fff5cc;
  border-color: rgba(243, 200, 71, .75);
}

.ar-notary-nav a strong {
  min-width: 24px;
  height: 24px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #e84b2a;
  color: #fff;
  font-size: 11px;
  box-shadow: 0 8px 18px rgba(232, 75, 42, .24);
}

.ar-notary-sidebar-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.ar-notary-sidebar-title strong {
  font-size: 14px;
}

.ar-notary-sidebar-title em {
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
  color: #e84b2a;
  background: #fff0ea;
  border-radius: 999px;
  padding: 5px 8px;
}

.ar-notary-sidebar-messages {
  background: #fff;
  border: 1px solid var(--ar-line);
  border-radius: 8px;
  padding: 12px;
  box-shadow: 0 12px 28px rgba(32, 36, 54, .06);
}

.ar-notary-message-list {
  display: grid;
  gap: 8px;
}

.ar-notary-message-item {
  display: grid;
  gap: 3px;
  border: 1px solid #ececf2;
  border-radius: 8px;
  padding: 9px 10px;
  background: #fbfbfd;
}

.ar-notary-message-item.is-unread {
  border-color: rgba(232, 75, 42, .3);
  background: #fff7f3;
  box-shadow: inset 4px 0 0 #e84b2a;
}

.ar-notary-message-item small,
.ar-notary-message-item span,
.ar-notary-message-empty {
  color: #737782;
  font-size: 11px;
  line-height: 1.35;
}

.ar-notary-message-item strong {
  font-size: 12px;
  color: #202436;
}

.ar-notary-message-item span {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ar-shell-notary.is-sidebar-collapsed .ar-sidebar-notary .ar-logo,
.ar-shell-notary.is-sidebar-collapsed .ar-notary-sidebar-messages {
  display: none;
}

.ar-shell-notary.is-sidebar-collapsed .ar-notary-nav a {
  width: 56px;
  height: 52px;
  justify-content: center;
  padding: 0 6px;
  text-align: center;
  font-size: 10px;
}

.ar-shell-notary.is-sidebar-collapsed .ar-notary-nav a strong {
  position: absolute;
  top: -7px;
  right: -5px;
}

.ar-notary-message-popup {
  position: fixed;
  top: 18px;
  right: 22px;
  width: min(360px, calc(100vw - 32px));
  z-index: 6000;
  display: grid;
  gap: 6px;
  padding: 16px 18px 14px;
  border-radius: 8px;
  border: 1px solid rgba(232, 75, 42, .18);
  background: #fff;
  box-shadow: 0 24px 60px rgba(32, 36, 54, .22);
  animation: arNotaryPopupIn .22s ease both;
}

.ar-notary-message-popup[hidden] {
  display: none;
}

.ar-notary-message-popup button {
  position: absolute;
  top: 8px;
  right: 10px;
  border: 0;
  background: transparent;
  font-size: 18px;
  cursor: pointer;
  color: #6f7380;
}

.ar-notary-message-popup small {
  color: #e84b2a;
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.ar-notary-message-popup strong {
  color: #202436;
  font-size: 15px;
}

.ar-notary-message-popup span {
  color: #555b66;
  font-size: 13px;
  line-height: 1.45;
}

.ar-notary-message-popup a {
  justify-self: start;
  color: #202436;
  background: #fff3c4;
  border: 1px solid rgba(243, 200, 71, .7);
  border-radius: 8px;
  padding: 8px 12px;
  text-decoration: none;
  font-size: 12px;
  font-weight: 900;
}

@keyframes arNotaryPopupIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 980px) {
  .ar-shell-notary {
    grid-template-columns: 1fr;
  }

  .ar-sidebar-notary {
    position: fixed;
    inset: 0 auto 0 0;
    width: min(300px, 86vw);
    transform: translateX(-102%);
    box-shadow: 24px 0 60px rgba(32, 36, 54, .2);
  }

  .ar-shell-notary.is-mobile-open .ar-sidebar-notary {
    transform: translateX(0);
  }

  .ar-notary-mobile-menu {
    display: inline-grid;
    place-items: center;
  }

  .ar-shell-notary.is-sidebar-collapsed .ar-sidebar-notary {
    width: min(300px, 86vw);
    align-items: stretch;
  }

  .ar-shell-notary.is-sidebar-collapsed .ar-sidebar-notary .ar-logo,
  .ar-shell-notary.is-sidebar-collapsed .ar-notary-sidebar-messages {
    display: block;
  }

  .ar-shell-notary.is-sidebar-collapsed .ar-notary-nav a {
    width: 100%;
    height: 44px;
    justify-content: space-between;
    padding: 0 12px;
    font-size: 12px;
  }
}
/* Area notaio: menu a linguetta e messaggi separati */
.ar-shell-notary.is-sidebar-collapsed {
    grid-template-columns: minmax(0, 1fr);
}

.ar-shell-notary.is-sidebar-collapsed .ar-sidebar-notary {
    position: fixed;
    inset: 0 auto 0 0;
    width: 292px;
    transform: translateX(-292px);
    z-index: 70;
    pointer-events: none;
    overflow: visible;
    align-items: stretch;
}

.ar-shell-notary.is-sidebar-collapsed .ar-sidebar-notary .ar-logo,
.ar-shell-notary.is-sidebar-collapsed .ar-notary-nav,
.ar-notary-sidebar-messages {
    display: none !important;
}

.ar-shell-notary.is-sidebar-collapsed .ar-notary-sidebar-toggle {
    position: absolute;
    left: 292px;
    top: 126px;
    width: 44px;
    min-width: 44px;
    height: 88px;
    padding: 0;
    border-radius: 0 16px 16px 0;
    pointer-events: auto;
    writing-mode: vertical-rl;
    text-orientation: mixed;
    box-shadow: 0 18px 34px rgba(32, 36, 54, .16);
}

.ar-shell-notary:not(.is-sidebar-collapsed) .ar-notary-sidebar-toggle {
    position: static;
}

.ar-shell-notary:not(.is-sidebar-collapsed) .ar-notary-sidebar-toggle span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.ar-shell-notary:not(.is-sidebar-collapsed) .ar-notary-sidebar-toggle span::after {
    content: "\2190";
    width: 22px;
    height: 22px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #173d2b;
    color: #ffffff;
    font-size: 14px;
    line-height: 1;
    box-shadow: 0 8px 18px rgba(23, 61, 43, .18);
}

.ar-notary-top-action,
.ar-notary-top-notifications summary {
    min-height: 44px;
    border: 1px solid #e8d989;
    border-radius: 14px;
    background: #fffdf1;
    color: #152016;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px;
    font-weight: 800;
    text-decoration: none;
    cursor: pointer;
}

.ar-notary-top-icon {
    width: 26px;
    height: 26px;
    border-radius: 9px;
    background: #174b35;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.ar-notary-top-badge {
    min-width: 22px;
    height: 22px;
    border-radius: 999px;
    background: #e84b2a;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
}

.ar-notary-top-notifications {
    position: relative;
}

.ar-notary-top-notifications summary::-webkit-details-marker {
    display: none;
}

.ar-notary-top-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: min(360px, calc(100vw - 32px));
    background: #fff;
    border: 1px solid var(--ar-line);
    border-radius: 14px;
    padding: 12px;
    box-shadow: 0 24px 60px rgba(32, 36, 54, .18);
    z-index: 90;
}

.ar-notary-top-dropdown-head {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}

.ar-notary-top-dropdown article {
    display: grid;
    gap: 3px;
    border: 1px solid #ececf2;
    border-radius: 10px;
    padding: 9px 10px;
    margin-top: 7px;
    background: #fbfbfd;
}

.ar-notary-top-dropdown article.is-unread {
    border-color: rgba(232, 75, 42, .28);
    box-shadow: inset 4px 0 0 #e84b2a;
    background: #fff7f3;
}

.ar-notary-top-dropdown small,
.ar-notary-top-dropdown span,
.ar-notary-top-dropdown p {
    color: #737782;
    font-size: 11px;
    line-height: 1.35;
}

.ar-notary-top-dropdown strong {
    color: #202436;
    font-size: 12px;
}

.ar-notary-top-all {
    display: inline-flex;
    margin-top: 10px;
    text-decoration: none;
    color: #174b35;
    font-weight: 900;
    font-size: 12px;
}

.ar-notary-messages-page {
    display: grid;
    gap: 18px;
}

.ar-notary-messages-hero {
    border: 1px solid rgba(23, 75, 53, .16);
    border-radius: 18px;
    padding: 24px;
    background: linear-gradient(135deg, #0f2f25, #1d6044);
    color: #fff;
    box-shadow: 0 22px 50px rgba(23, 75, 53, .18);
}

.ar-notary-messages-hero .ar-eyebrow {
    color: #f3c847;
}

.ar-notary-messages-hero h2 {
    margin: 0 0 8px;
    font-size: 30px;
}

.ar-notary-messages-hero p {
    margin: 0;
    color: rgba(255, 255, 255, .82);
}

.ar-notary-messages-grid {
    display: grid;
    gap: 12px;
}

.ar-notary-message-card {
    border: 1px solid var(--ar-line);
    border-radius: 14px;
    padding: 15px 16px;
    background: #fff;
    display: grid;
    gap: 8px;
    box-shadow: 0 12px 30px rgba(32, 36, 54, .06);
}

.ar-notary-message-card.is-unread {
    border-color: rgba(232, 75, 42, .28);
    box-shadow: inset 5px 0 0 #e84b2a, 0 12px 30px rgba(32, 36, 54, .06);
}

.ar-notary-message-card div {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
}

.ar-notary-message-card small {
    color: #737782;
    font-size: 11px;
}

.ar-notary-message-card strong {
    color: #202436;
    font-size: 15px;
}

.ar-notary-message-card p {
    margin: 0;
    color: #555b66;
    line-height: 1.5;
}

.ar-notary-message-card > span {
    justify-self: start;
    border-radius: 999px;
    background: #fff5cc;
    color: #765d00;
    padding: 5px 9px;
    font-size: 11px;
    font-weight: 900;
}

.ar-notary-messages-empty {
    border: 1px dashed var(--ar-line);
    border-radius: 14px;
    padding: 22px;
    background: #fff;
    color: #737782;
}

@media (max-width: 980px) {
    .ar-shell-notary.is-sidebar-collapsed .ar-sidebar-notary {
        width: min(300px, 86vw);
        transform: translateX(-102%);
        pointer-events: auto;
    }

    .ar-shell-notary.is-sidebar-collapsed .ar-notary-sidebar-toggle {
        position: fixed;
        left: 0;
        top: 118px;
    }

    .ar-shell-notary.is-sidebar-collapsed .ar-notary-nav {
        display: grid !important;
    }

    .ar-shell-notary.is-mobile-open .ar-sidebar-notary,
    .ar-shell-notary.is-sidebar-collapsed.is-mobile-open .ar-sidebar-notary {
        transform: translateX(0);
        pointer-events: auto;
    }

    .ar-shell-notary.is-mobile-open::before {
        content: "";
        position: fixed;
        inset: 0;
        z-index: 65;
        background: rgba(16, 24, 40, .34);
        backdrop-filter: blur(2px);
    }
}
/* Centro notifiche e messaggi notaio */
.ar-notary-notification-center {
    position: relative;
}

.ar-notary-notification-center summary {
    min-height: 48px;
    border: 1px solid #e8d989;
    border-radius: 16px;
    background: #fffdf1;
    color: #152016;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 6px 14px 6px 8px;
    cursor: pointer;
    box-shadow: 0 12px 28px rgba(32, 36, 54, .07);
}

.ar-notary-notification-center summary::-webkit-details-marker {
    display: none;
}

.ar-notary-notification-icon {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    background: #174b35;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 900;
}

.ar-notary-notification-copy {
    display: grid;
    gap: 1px;
    min-width: 0;
}

.ar-notary-notification-copy strong {
    font-size: 13px;
    line-height: 1.15;
}

.ar-notary-notification-copy em {
    color: #6f756b;
    font-size: 11px;
    font-style: normal;
    font-weight: 700;
}

.ar-notary-notification-badge {
    min-width: 22px;
    height: 22px;
    border-radius: 999px;
    background: #e84b2a;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 900;
}

.ar-notary-notification-dropdown {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: min(390px, calc(100vw - 32px));
    background: #fff;
    border: 1px solid var(--ar-line);
    border-radius: 18px;
    padding: 14px;
    box-shadow: 0 26px 70px rgba(32, 36, 54, .20);
    z-index: 110;
}

.ar-notary-notification-head {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
    padding-bottom: 10px;
    border-bottom: 1px solid #ececf2;
    margin-bottom: 8px;
}

.ar-notary-notification-head strong {
    color: #202436;
    font-size: 16px;
}

.ar-notary-notification-head span {
    color: #737782;
    font-size: 11px;
    text-align: right;
}

.ar-notary-notification-item {
    position: relative;
    display: grid;
    grid-template-columns: 74px 1fr auto;
    gap: 4px 10px;
    border: 1px solid #ececf2;
    border-left-width: 4px;
    border-radius: 8px;
    padding: 10px 11px 10px 12px;
    margin-top: 8px;
    background: #fbfbfd;
    text-decoration: none;
    color: #202436;
}

.ar-notary-notification-item.is-read {
    opacity: .74;
    border-left-color: #d7dbe5;
}

.ar-notary-notification-item.is-unread {
    opacity: 1;
    border-color: rgba(204, 54, 54, .24);
    border-left-color: #cc3636;
    background: #fff6f6;
    box-shadow: 0 8px 22px rgba(204, 54, 54, .08);
}

.ar-notary-notification-item.is-read::after,
.ar-notary-notification-item.is-unread::after {
    content: "";
    position: absolute;
    top: 11px;
    right: 10px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
}

.ar-notary-notification-item.is-read::after {
    background: #168a55;
}

.ar-notary-notification-item.is-unread::after {
    background: #cc3636;
}

.ar-notary-notification-item.is-closing {
    border-color: rgba(178, 120, 0, .30);
    border-left-color: #b27800;
    background: #fff8e6;
}

.ar-notary-notification-item.is-closing.is-unread {
    background: #fff4d1;
    box-shadow: 0 10px 24px rgba(178, 120, 0, .13);
}

.ar-notary-notification-item.is-closing::after {
    background: #f0b400;
}

.ar-notary-notification-item.is-closing::before {
    content: "In chiusura";
    grid-column: 1 / -1;
    justify-self: start;
    border: 1px solid rgba(178, 120, 0, .24);
    background: #fff;
    border-radius: 999px;
    padding: 2px 7px;
    color: #765100;
    font-size: 9px;
    font-weight: 900;
    text-transform: uppercase;
}

.ar-notary-notification-item.is-message span {
    color: #2062b3;
}

.ar-notary-notification-item.is-crm span {
    color: #174b35;
}

.ar-notary-notification-item span {
    font-size: 10px;
    font-weight: 900;
    text-transform: uppercase;
}

.ar-notary-notification-item strong {
    font-size: 13px;
    padding-right: 8px;
}

.ar-notary-notification-item.is-unread strong {
    font-weight: 900;
}

.ar-notary-notification-item small {
    color: #737782;
    font-size: 10px;
    white-space: nowrap;
}

.ar-notary-notification-item em {
    grid-column: 2 / -1;
    color: #5e6470;
    font-size: 12px;
    font-style: normal;
    line-height: 1.35;
}

.ar-notary-notification-empty {
    color: #737782;
    margin: 12px 0 4px;
    font-size: 13px;
}

.ar-notary-notification-all {
    display: inline-flex;
    margin-top: 12px;
    color: #174b35;
    font-weight: 900;
    text-decoration: none;
    font-size: 13px;
}

@media (max-width: 760px) {
    .ar-shell-notary .ar-sidebar-notary,
    .ar-shell-notary.is-sidebar-collapsed .ar-sidebar-notary {
        position: fixed;
        inset: 0 auto 0 0;
        top: 0;
        right: auto;
        bottom: 0;
        left: 0;
        width: min(300px, 86vw);
        height: 100vh;
        height: 100dvh;
        z-index: 80;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        gap: 14px;
        padding: 16px 12px;
        border-right: 1px solid var(--ar-line);
        border-top: 0;
        background: #fff;
        overflow-y: auto;
        pointer-events: auto;
        transform: translateX(-102%);
        box-shadow: 24px 0 60px rgba(32, 36, 54, .2);
    }

    .ar-shell-notary.is-mobile-open .ar-sidebar-notary,
    .ar-shell-notary.is-sidebar-collapsed.is-mobile-open .ar-sidebar-notary {
        transform: translateX(0);
    }

    .ar-shell-notary .ar-sidebar-notary .ar-logo,
    .ar-shell-notary.is-sidebar-collapsed .ar-sidebar-notary .ar-logo {
        display: flex !important;
    }

    .ar-shell-notary .ar-notary-nav,
    .ar-shell-notary.is-sidebar-collapsed .ar-notary-nav {
        display: grid !important;
    }

    .ar-shell-notary .ar-notary-nav a,
    .ar-shell-notary.is-sidebar-collapsed .ar-notary-nav a {
        position: relative;
        width: 100%;
        height: 44px;
        min-height: 44px;
        justify-content: space-between;
        padding: 0 12px;
        font-size: 12px;
    }

    .ar-shell-notary .ar-notary-nav a strong,
    .ar-shell-notary.is-sidebar-collapsed .ar-notary-nav a strong {
        position: static;
    }

    .ar-shell-notary .ar-notary-sidebar-toggle,
    .ar-shell-notary.is-sidebar-collapsed .ar-notary-sidebar-toggle {
        position: static;
        width: 100%;
        height: 42px;
        min-width: 0;
        min-height: 42px;
        padding: 0 12px;
        border-radius: 8px;
        writing-mode: horizontal-tb;
        text-orientation: mixed;
    }

    .ar-shell-notary .ar-notary-sidebar-toggle span {
        display: inline-flex;
    }

    .ar-shell-notary .ar-main {
        padding: 0 12px 28px;
    }

    .ar-shell-notary .ar-topbar {
        position: sticky;
        top: 0;
        z-index: 55;
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 10px;
        margin: 0 -12px 14px;
        padding: 10px 12px;
        background: rgba(247, 246, 241, .96);
        border-bottom: 1px solid var(--ar-line);
        backdrop-filter: blur(10px);
    }

    .ar-shell-notary .ar-topbar h1 {
        font-size: 22px;
        line-height: 1.15;
        margin: 2px 0 0;
    }

    .ar-shell-notary .ar-topbar-actions {
        width: 100%;
        display: grid;
        grid-template-columns: 44px 44px minmax(0, 1fr);
        gap: 8px;
        align-items: center;
    }

    .ar-shell-notary .ar-notary-mobile-menu {
        order: -2;
        display: grid;
        place-items: center;
        width: 44px;
        height: 44px;
        min-height: 44px;
        padding: 0;
        border-radius: 12px;
        font-size: 0;
    }

    .ar-shell-notary .ar-notary-mobile-menu::before {
        content: "\2630";
        font-size: 22px;
        line-height: 1;
    }

    .ar-shell-notary .ar-notary-notification-center {
        order: -1;
        position: relative;
    }

    .ar-shell-notary .ar-notary-notification-center summary {
        width: 44px;
        height: 44px;
        min-height: 44px;
        padding: 0;
        justify-content: center;
        border-radius: 12px;
    }

    .ar-shell-notary .ar-notary-notification-copy {
        display: none;
    }

    .ar-shell-notary .ar-notary-notification-icon {
        width: 30px;
        height: 30px;
        border-radius: 10px;
    }

    .ar-shell-notary .ar-notary-notification-badge {
        position: absolute;
        top: -6px;
        right: -6px;
        min-width: 20px;
        height: 20px;
        font-size: 10px;
    }

    .ar-shell-notary .ar-notary-notification-dropdown {
        position: fixed;
        left: 10px;
        right: 10px;
        top: 86px;
        width: auto;
        max-height: calc(100vh - 112px);
        overflow-y: auto;
        border-radius: 14px;
        z-index: 120;
    }

    .ar-shell-notary .ar-notary-notification-item {
        grid-template-columns: 1fr auto;
        gap: 4px 8px;
    }

    .ar-shell-notary .ar-notary-notification-item span {
        grid-column: 1 / 2;
    }

    .ar-shell-notary .ar-notary-notification-item strong {
        grid-column: 1 / 2;
    }

    .ar-shell-notary .ar-notary-notification-item small {
        grid-column: 2;
        grid-row: 1 / 3;
        align-self: start;
    }

    .ar-shell-notary .ar-notary-notification-item em {
        grid-column: 1 / -1;
    }

    .ar-shell-notary .ar-back-button-inline {
        min-height: 44px;
        justify-self: stretch;
        text-align: center;
    }

    .ar-shell-notary .ar-user-pill {
        grid-column: 1 / -1;
        justify-self: start;
    }

    .ar-notary-message-popup {
        top: auto;
        right: 10px;
        bottom: 12px;
        left: 10px;
        width: auto;
    }
}

.ar-notary-chat-page {
    display: grid;
    gap: 18px;
}

.ar-notary-chat-title {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: flex-end;
}

.ar-notary-chat-title h2 {
    margin: 0 0 6px;
    font-size: 30px;
    color: #101828;
}

.ar-notary-chat-title p {
    margin: 0;
    color: #737782;
}

.ar-notary-chat-title > span {
    border: 1px solid #e8d989;
    background: #fff8d7;
    border-radius: 999px;
    padding: 8px 12px;
    color: #765d00;
    font-weight: 900;
    font-size: 12px;
}

.ar-notary-chat-shell {
    min-height: 640px;
    border: 1px solid var(--ar-line);
    border-radius: 24px;
    background: #fff;
    display: grid;
    grid-template-columns: 370px minmax(0, 1fr);
    overflow: hidden;
    box-shadow: 0 24px 55px rgba(32, 36, 54, .08);
}

.ar-notary-chat-list {
    background: #fbfbf5;
    border-right: 1px solid var(--ar-line);
    padding: 18px;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.ar-notary-chat-list-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ar-notary-chat-list-head h3 {
    margin: 0 0 2px;
    font-size: 20px;
}

.ar-notary-chat-list-head span {
    color: #737782;
    font-size: 12px;
}

.ar-notary-chat-bell {
    width: 42px;
    height: 42px;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 10px 26px rgba(32, 36, 54, .10);
    color: #174b35 !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.ar-notary-chat-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.ar-notary-chat-tabs span {
    border: 1px solid var(--ar-line);
    border-radius: 12px;
    padding: 11px 10px;
    text-align: center;
    font-weight: 900;
    font-size: 12px;
    background: #fff;
}

.ar-notary-chat-tabs span.active {
    background: #101828;
    border-color: #101828;
    color: #fff;
}

.ar-notary-chat-search input {
    width: 100%;
    border: 1px solid var(--ar-line);
    border-radius: 999px;
    padding: 13px 16px;
    background: #fff;
    outline: none;
}

.ar-notary-chat-people {
    display: grid;
    gap: 6px;
    overflow: auto;
    padding-right: 2px;
}

.ar-notary-chat-item {
    width: 100%;
    border: 0;
    border-radius: 16px;
    padding: 12px;
    background: transparent;
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 12px;
    text-align: left;
    cursor: pointer;
    align-items: center;
}

.ar-notary-chat-item.active {
    background: #fff5cc;
}

.ar-notary-chat-item.is-unread {
    box-shadow: inset 4px 0 0 #e84b2a;
}

.ar-notary-chat-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #d7d8d4;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.ar-notary-chat-avatar.is-large {
    width: 54px;
    height: 54px;
    background: #174b35;
}

.ar-notary-chat-row {
    min-width: 0;
    display: grid;
    gap: 4px;
}

.ar-notary-chat-row strong {
    color: #101828;
    font-size: 15px;
}

.ar-notary-chat-row em {
    color: #737782;
    font-size: 13px;
    font-style: normal;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.ar-notary-chat-item small {
    grid-column: 2;
    color: #9aa1ad;
    font-size: 10px;
}

.ar-notary-chat-main {
    min-height: 640px;
    background: linear-gradient(180deg, #fffdf7 0%, #f7f3e9 100%);
    position: relative;
}

.ar-notary-chat-thread {
    display: none;
    min-height: 640px;
    grid-template-rows: auto 1fr auto;
}

.ar-notary-chat-thread.active {
    display: grid;
}

.ar-notary-chat-header {
    display: flex;
    gap: 14px;
    align-items: center;
    padding: 22px 24px;
    border-bottom: 1px solid var(--ar-line);
    background: rgba(255, 255, 255, .76);
}

.ar-notary-chat-header h3 {
    margin: 0 0 4px;
    color: #101828;
}

.ar-notary-chat-header p {
    margin: 0;
    color: #737782;
}

.ar-notary-chat-body {
    padding: 28px 24px;
}

.ar-notary-chat-bubble {
    max-width: min(620px, 86%);
    border-radius: 16px;
    padding: 14px 16px 10px;
    box-shadow: 0 10px 24px rgba(32, 36, 54, .08);
}

.ar-notary-chat-bubble.inbound {
    background: #fff;
}

.ar-notary-chat-bubble.outbound {
    margin-left: auto;
    margin-right: 0;
    background: #dcfce7;
    border: 1px solid #bbf7d0;
}

.ar-notary-chat-bubble p {
    margin: 0;
    color: #202436;
    line-height: 1.55;
}

.ar-notary-chat-bubble time {
    display: block;
    margin-top: 8px;
    color: #8b909a;
    font-size: 11px;
}

.ar-notary-chat-attachment {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-top: 8px;
    padding: 9px 10px;
    border: 1px solid rgba(17, 24, 39, .1);
    border-radius: 12px;
    background: #fff;
    color: #111827;
    text-decoration: none;
}

.ar-notary-chat-attachment:hover {
    color: #111827;
    border-color: rgba(17, 24, 39, .22);
}

.ar-notary-chat-attachment span:last-child {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ar-notary-chat-attachment em,
.ar-notary-chat-edited {
    font-size: 11px;
    color: #667085;
    font-style: normal;
}

.ar-area-message-deleted {
    color: #667085;
}

.ar-notary-chat-composer {
    display: grid;
    grid-template-columns: 46px 1fr 92px;
    gap: 10px;
    padding: 16px 18px;
    border-top: 1px solid var(--ar-line);
    background: #fff;
}

.ar-notary-chat-composer button,
.ar-notary-chat-composer input {
    border: 1px solid var(--ar-line);
    border-radius: 999px;
    min-height: 44px;
    background: #fff;
    padding: 0 14px;
}

.ar-notary-chat-composer button:last-child {
    background: #f3c847;
    border-color: #f3c847;
    font-weight: 900;
}

.ar-notary-chat-composer.is-readonly {
    opacity: .68;
}

.ar-notary-chat-placeholder,
.ar-notary-chat-empty {
    padding: 28px;
    color: #737782;
}

@media (max-width: 900px) {
    .ar-notary-chat-title {
        align-items: flex-start;
        flex-direction: column;
    }

    .ar-notary-chat-shell {
        grid-template-columns: 1fr;
    }

    .ar-notary-chat-list {
        border-right: 0;
        border-bottom: 1px solid var(--ar-line);
    }

    .ar-notary-chat-thread,
    .ar-notary-chat-main {
        min-height: 480px;
    }

    .ar-notary-notification-copy strong {
        max-width: 120px;
        overflow: hidden;
        white-space: nowrap;
        text-overflow: ellipsis;
    }
}

.d-none {
    display: none !important;
}

.ar-message-card {
    display: grid;
    gap: 18px;
}

.ar-message-card-full {
    min-height: calc(100vh - 180px);
}

.ar-message-card-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
}

.ar-message-card-head h2,
.ar-message-card-head h3 {
    margin: 0 0 6px;
}

.ar-message-card-head > span {
    border: 1px solid #e8d989;
    background: #fff8d7;
    border-radius: 999px;
    padding: 8px 12px;
    color: #765d00;
    font-weight: 900;
    font-size: 12px;
    white-space: nowrap;
}

.ar-area-message-shell {
    height: 680px;
    min-height: 520px;
    border: 1px solid var(--ar-line);
    border-radius: 18px;
    overflow: hidden;
    background: #fff;
    display: grid;
    grid-template-columns: 360px minmax(0, 1fr);
    box-shadow: 0 20px 45px rgba(32, 36, 54, .08);
}

.ar-area-message-shell .crm-whatsapp-sidebar {
    min-width: 0;
    min-height: 0;
    background: #fbfbf5;
    border-right: 1px solid var(--ar-line);
    display: flex;
    flex-direction: column;
}

.ar-area-message-shell .crm-whatsapp-panel-head {
    padding: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.ar-area-message-shell .crm-whatsapp-panel-head strong,
.ar-area-message-shell .crm-whatsapp-panel-head span {
    display: block;
}

.ar-area-message-shell .crm-whatsapp-panel-head strong {
    color: #101828;
    font-size: 18px;
}

.ar-area-message-shell .crm-whatsapp-panel-head span {
    color: #737782;
    font-size: 12px;
}

.ar-area-message-shell .crm-whatsapp-icon-btn {
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 50%;
    background: #fff;
    color: #174b35;
    font-weight: 900;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 20px rgba(32, 36, 54, .10);
    cursor: pointer;
}

.ar-area-message-shell .crm-message-head-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
}

.ar-area-message-shell .crm-message-tour-help {
    font-style: normal;
}

.crm-message-tour-overlay {
    position: fixed;
    inset: 0;
    z-index: 99992;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: transparent;
    pointer-events: none;
}

.crm-message-tour-card {
    position: relative;
    z-index: 99993;
    width: min(430px, 100%);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(16, 24, 40, .28);
    padding: 24px;
    color: #101828;
    pointer-events: auto;
}

.crm-message-tour-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: #f2f4f7;
    color: #101828;
    font-weight: 900;
    cursor: pointer;
}

.crm-message-tour-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    border-radius: 999px;
    background: #fff7d6;
    color: #8a6100;
    font-size: 12px;
    font-weight: 900;
    padding: 0 10px;
    margin-bottom: 12px;
}

.crm-message-tour-card h3 {
    font-size: 21px;
    line-height: 1.2;
    font-weight: 900;
    margin: 0 0 10px;
}

.crm-message-tour-card p {
    font-size: 14px;
    line-height: 1.55;
    color: #475467;
    margin: 0 0 16px;
}

.crm-message-tour-progress {
    font-size: 12px;
    font-weight: 800;
    color: #667085;
    margin-bottom: 12px;
}

.crm-message-tour-skip {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #475467;
    margin-bottom: 18px;
}

.crm-message-tour-skip input {
    width: 16px;
    height: 16px;
}

.crm-message-tour-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.crm-message-tour-actions button {
    min-height: 38px;
    border: 0;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 900;
    padding: 0 16px;
    cursor: pointer;
}

.crm-message-tour-prev {
    background: #f2f4f7;
    color: #101828;
}

.crm-message-tour-prev:disabled {
    opacity: .45;
    cursor: not-allowed;
}

.crm-message-tour-next {
    background: #101828;
    color: #fff;
}

.crm-message-tour-target {
    position: relative;
    z-index: 99991;
    outline: 3px solid #ffc107;
    outline-offset: 4px;
    border-radius: 14px;
    box-shadow: 0 0 0 8px rgba(255, 193, 7, .18), 0 0 0 9999px rgba(16, 24, 40, .42);
}

.ar-area-message-shell .crm-message-tabs {
    display: flex;
    gap: 8px;
    padding: 0 18px 12px;
}

.ar-area-message-shell .crm-message-tabs button {
    position: relative;
    border: 1px solid #101828;
    border-radius: 12px;
    background: #101828;
    color: #fff;
    min-height: 40px;
    padding: 0 14px;
    font-weight: 900;
    cursor: default;
}

.ar-area-message-shell .crm-message-tab-badge {
    display: none;
    position: absolute;
    top: -8px;
    right: -8px;
    min-width: 20px;
    height: 20px;
    border-radius: 999px;
    background: #1f8f5f;
    color: #fff;
    border: 2px solid #fff;
    font-size: 11px;
    font-weight: 900;
    line-height: 16px;
    text-align: center;
    padding: 0 5px;
}

.ar-area-message-shell .crm-message-tab-badge.is-visible {
    display: inline-block;
}

.ar-area-message-shell .crm-whatsapp-search {
    padding: 0 18px 14px;
}

.ar-area-message-shell .crm-whatsapp-search input {
    width: 100%;
    height: 44px;
    border: 1px solid var(--ar-line);
    border-radius: 999px;
    background: #fff;
    padding: 0 16px;
    outline: none;
}

.ar-area-message-shell .crm-whatsapp-users {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    padding: 6px 8px 12px;
}

.ar-area-message-shell .crm-whatsapp-user {
    width: 100%;
    border: 0;
    border-radius: 14px;
    background: transparent;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
    cursor: pointer;
}

.ar-area-message-shell .crm-whatsapp-user:hover,
.ar-area-message-shell .crm-whatsapp-user.active {
    background: #fff5cc;
}

.ar-area-message-shell .crm-whatsapp-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #d7d8d4;
    overflow: hidden;
    position: relative;
    flex: 0 0 48px;
}

.ar-area-message-shell .crm-whatsapp-avatar img,
.ar-area-message-shell .crm-whatsapp-chat-header img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ar-area-message-shell .crm-whatsapp-avatar i {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    position: absolute;
    right: 2px;
    bottom: 2px;
    background: #b8b8b8;
    border: 2px solid #fff;
}

.ar-area-message-shell .crm-whatsapp-avatar i.online {
    background: #25d366;
}

.ar-area-message-shell .crm-whatsapp-user-text {
    min-width: 0;
    flex: 1 1 auto;
}

.ar-area-message-shell .crm-whatsapp-user-text strong,
.ar-area-message-shell .crm-whatsapp-user-text em {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.ar-area-message-shell .crm-whatsapp-user-text strong {
    color: #101828;
    font-size: 15px;
    font-weight: 900;
}

.ar-area-message-shell .crm-whatsapp-user-text em {
    margin-top: 3px;
    color: #737782;
    font-size: 12px;
    font-style: normal;
}

.ar-area-message-shell .crm-whatsapp-badge {
    min-width: 24px;
    height: 24px;
    border-radius: 999px;
    background: #1f8f5f;
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 7px;
    font-size: 12px;
    font-weight: 900;
}

.ar-area-message-shell .crm-whatsapp-chat {
    min-width: 0;
    min-height: 0;
    background: linear-gradient(180deg, #fffdf7 0%, #f7f3e9 100%);
    overflow: hidden;
}

.ar-area-message-shell .crm-whatsapp-empty {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    text-align: center;
    color: #737782;
    padding: 28px;
}

.ar-area-message-shell .crm-whatsapp-empty strong {
    color: #101828;
    font-size: 22px;
    margin-bottom: 8px;
}

.ar-area-message-shell .crm-whatsapp-conversation {
    height: 100%;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.ar-area-message-shell .crm-whatsapp-chat-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: rgba(255, 255, 255, .88);
    border-bottom: 1px solid var(--ar-line);
}

.ar-area-message-shell .crm-whatsapp-chat-header img {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    flex: 0 0 46px;
}

.ar-area-message-shell .crm-whatsapp-chat-header h4 {
    margin: 0;
    color: #101828;
    font-size: 17px;
}

.ar-area-message-shell .crm-whatsapp-chat-header span {
    color: #737782;
    font-size: 12px;
}

.ar-area-message-shell .crm-whatsapp-chat-header span.is-typing {
    color: #149253;
    font-weight: 800;
}

.ar-area-message-shell .crm-whatsapp-back {
    display: none;
    border: 0;
    background: transparent;
    font-weight: 900;
    font-size: 22px;
}

.ar-area-message-shell .crm-whatsapp-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
    padding: 24px;
}

.ar-area-message-shell .crm-whatsapp-row {
    display: flex;
    margin-bottom: 12px;
}

.ar-area-message-shell .crm-whatsapp-row.mine {
    justify-content: flex-end;
}

.ar-area-message-shell .crm-whatsapp-row.theirs {
    justify-content: flex-start;
}

.ar-area-message-shell .crm-message-date-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 16px 0;
    color: #737782;
    font-size: 12px;
    font-weight: 800;
}

.ar-area-message-shell .crm-message-date-divider::before,
.ar-area-message-shell .crm-message-date-divider::after {
    display: none;
}

.ar-area-message-shell .crm-message-date-divider span {
    flex: 0 0 auto;
    border: 1px solid rgba(115, 119, 130, .16);
    border-radius: 999px;
    background: rgba(255, 255, 255, .86);
    padding: 5px 12px;
    box-shadow: 0 6px 16px rgba(32, 36, 54, .06);
}

.ar-area-message-shell .crm-whatsapp-bubble {
    max-width: 70%;
    border-radius: 16px;
    background: #fff;
    color: #101828;
    padding: 10px 12px 7px;
    box-shadow: 0 8px 22px rgba(32, 36, 54, .08);
    position: relative;
}

.ar-area-message-shell .crm-whatsapp-row.mine .crm-whatsapp-bubble {
    background: #dcf8c6;
    border-bottom-right-radius: 4px;
}

.ar-area-message-shell .crm-whatsapp-row.theirs .crm-whatsapp-bubble {
    border-bottom-left-radius: 4px;
}

.ar-area-message-shell .crm-whatsapp-text {
    font-size: 14px;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.ar-area-message-shell .crm-whatsapp-time {
    margin-top: 4px;
    color: #737782;
    font-size: 11px;
    text-align: right;
}

.ar-area-message-shell .crm-whatsapp-message-actions {
    position: absolute;
    top: -12px;
    right: 8px;
    display: none;
    gap: 4px;
    background: rgba(255, 255, 255, .96);
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    padding: 2px;
    box-shadow: 0 8px 18px rgba(32, 36, 54, .12);
}

.ar-area-message-shell .crm-whatsapp-bubble:hover .crm-whatsapp-message-actions,
.ar-area-message-shell .crm-whatsapp-bubble:focus-within .crm-whatsapp-message-actions {
    display: flex;
}

.ar-area-message-shell .crm-whatsapp-message-actions button {
    width: 26px;
    height: 26px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: #667085;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 900;
}

.ar-area-message-shell .crm-whatsapp-message-actions button:hover {
    background: #f3f4f6;
    color: #101828;
}

.ar-area-message-shell .crm-message-reactions {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 6px;
}

.ar-area-message-shell .crm-message-reactions button {
    border: 1px solid rgba(16, 24, 40, .08);
    border-radius: 999px;
    background: rgba(255, 255, 255, .72);
    color: #101828;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    min-height: 24px;
    padding: 0 7px;
    font-size: 12px;
}

.ar-area-message-shell .crm-message-reactions button.mine {
    background: #fff1bf;
    border-color: #f1c84b;
}

.ar-area-message-shell .crm-whatsapp-attachment,
.ar-area-message-shell .ar-notary-chat-attachment {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 8px;
    padding: 9px 10px;
    border: 1px solid rgba(17, 24, 39, .1);
    border-radius: 12px;
    background: rgba(255, 255, 255, .82);
    color: #111827;
    text-decoration: none;
}

.ar-area-message-shell .ar-notary-chat-attachment span:last-child {
    min-width: 0;
}

.ar-area-message-shell .ar-notary-chat-attachment strong,
.ar-area-message-shell .ar-notary-chat-attachment em {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.ar-area-message-shell .ar-notary-chat-attachment em,
.ar-area-message-shell .ar-notary-chat-edited,
.ar-area-message-shell .ar-area-message-deleted {
    color: #667085;
    font-size: 11px;
    font-style: normal;
}

.ar-area-message-shell .crm-whatsapp-compose {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    padding: 14px 18px;
    background: #fff;
    border-top: 1px solid var(--ar-line);
    position: relative;
}

.ar-area-message-shell .crm-message-actions {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    flex: 0 0 auto;
}

.ar-area-message-shell .crm-whatsapp-attach-btn {
    width: 46px;
    height: 46px;
    border: 1px solid var(--ar-line);
    border-radius: 50%;
    background: #fff;
    color: #667085;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    flex: 0 0 46px;
    margin: 0;
    font-weight: 900;
}

.ar-area-message-shell .crm-whatsapp-attach-btn.crm-message-action-toggle {
    display: none;
}

.ar-area-message-shell .crm-whatsapp-attach-btn span:not(.crm-message-emoji-trigger):not(.crm-message-icon) {
    display: none;
    position: absolute;
    top: -5px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    border-radius: 999px;
    background: #1f8f5f;
    color: #fff;
    border: 2px solid #fff;
    font-size: 10px;
    line-height: 14px;
    text-align: center;
}

.ar-area-message-shell .crm-whatsapp-attach-btn span.is-visible {
    display: inline-block;
}

.ar-area-message-shell .crm-message-icon,
.ar-area-message-shell .crm-whatsapp-icon-btn span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    line-height: 1;
}

.ar-area-message-shell .crm-whatsapp-compose textarea {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 46px;
    max-height: 130px;
    border: 1px solid var(--ar-line);
    border-radius: 18px;
    padding: 12px 14px;
    resize: none;
    outline: none;
}

.ar-area-message-shell .crm-whatsapp-compose .btn {
    min-width: 92px;
    height: 46px;
    border-radius: 999px;
    border: 0;
    background: #f3c847;
    color: #101828;
    font-weight: 900;
}

.crm-message-emoji-panel {
    position: absolute;
    left: 18px;
    bottom: calc(100% + 8px);
    z-index: 55;
    width: min(330px, calc(100vw - 36px));
    max-height: 300px;
    overflow: auto;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, .16);
    padding: 10px;
}

.crm-message-reaction-panel {
    position: fixed;
    bottom: auto;
    right: auto;
}

.crm-message-emoji-group + .crm-message-emoji-group {
    margin-top: 10px;
}

.crm-message-emoji-group strong {
    display: block;
    margin-bottom: 6px;
    color: #667085;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
}

.crm-message-emoji-group div {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 6px;
}

.crm-message-emoji-group button {
    width: 38px;
    height: 38px;
    border: 1px solid #eef2f7;
    border-radius: 10px;
    background: #f8fafc;
    font-size: 15px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.crm-message-emoji-group button:hover {
    background: #fff8df;
    border-color: #f1c84b;
}

.crm-message-dialog-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(15, 23, 42, .42);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
}

.crm-message-dialog {
    width: min(420px, 100%);
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 24px 80px rgba(15, 23, 42, .25);
    padding: 22px;
    position: relative;
    text-align: center;
}

.crm-message-dialog-close {
    position: absolute;
    top: 10px;
    right: 12px;
    border: 0;
    background: transparent;
    color: #667085;
    font-size: 24px;
    line-height: 1;
}

.crm-message-dialog-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #fff4d3;
    color: #101828;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
    font-weight: 900;
}

.crm-message-dialog h3 {
    margin: 0 0 8px;
    color: #101828;
    font-size: 19px;
}

.crm-message-dialog p {
    margin: 0 0 14px;
    color: #667085;
    font-size: 14px;
}

.ar-session-password-label,
.crm-session-password-label {
    display: block;
    margin: 0 0 6px;
    color: #344054;
    font-size: 13px;
    font-weight: 900;
    text-align: left;
}

.ar-session-password-input,
.crm-session-password-input {
    width: 100%;
    border: 1px solid #e4e7ec;
    border-radius: 10px;
    padding: 11px 12px;
    color: #101828;
    font: inherit;
    margin-bottom: 14px;
}

.crm-message-dialog textarea {
    width: 100%;
    min-height: 112px;
    border: 1px solid var(--ar-line);
    border-radius: 14px;
    padding: 12px;
    resize: vertical;
    outline: none;
    text-align: left;
    margin-bottom: 14px;
}

.crm-message-dialog-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.ar-area-message-shell .crm-whatsapp-no-results,
.ar-area-message-shell .crm-whatsapp-no-messages {
    padding: 22px;
    color: #737782;
    text-align: center;
}

@media (max-width: 900px) {
    .ar-message-card-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .ar-area-message-shell {
        grid-template-columns: 1fr;
        height: 74vh;
        min-height: 560px;
        position: relative;
    }

    .ar-area-message-shell .crm-whatsapp-sidebar {
        border-right: 0;
        height: 100%;
    }

    .ar-area-message-shell .crm-whatsapp-chat {
        display: none;
        height: 100%;
    }

    .ar-area-message-shell.is-chat-open .crm-whatsapp-sidebar {
        display: none;
    }

    .ar-area-message-shell.is-chat-open .crm-whatsapp-chat {
        display: block;
    }

    .ar-area-message-shell .crm-whatsapp-empty {
        display: none;
    }

    .ar-area-message-shell .crm-whatsapp-back {
        display: inline-flex;
    }

    .ar-area-message-shell .crm-whatsapp-message-actions {
        display: flex;
    }

    .ar-area-message-shell .crm-whatsapp-conversation {
        height: 100%;
    }

    .ar-area-message-shell .crm-whatsapp-body {
        padding: 16px 12px 128px;
    }

    .ar-area-message-shell .crm-whatsapp-compose {
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 5;
        padding-bottom: max(18px, env(safe-area-inset-bottom));
    }

    .ar-area-message-shell .crm-whatsapp-bubble {
        max-width: 86%;
    }
}

@media (max-width: 575px) {
    .ar-area-message-shell {
        margin-left: -18px;
        margin-right: -18px;
        border-left: 0;
        border-right: 0;
        border-radius: 0;
        min-height: 620px;
    }

    .ar-area-message-shell .crm-whatsapp-panel-head,
    .ar-area-message-shell .crm-whatsapp-chat-header {
        padding: 12px 14px;
    }

    .ar-area-message-shell .crm-whatsapp-compose {
        gap: 6px;
        padding-left: 10px;
        padding-right: 10px;
    }

    .ar-area-message-shell .crm-whatsapp-attach-btn.crm-message-action-toggle {
        display: inline-flex;
    }

    .ar-area-message-shell .crm-message-action-toggle.is-open .crm-message-icon {
        transform: rotate(45deg);
    }

    .ar-area-message-shell .crm-message-actions {
        position: absolute;
        left: 8px;
        bottom: calc(100% + 10px);
        z-index: 45;
        display: none;
        flex-direction: row;
        align-items: center;
        gap: 8px;
        width: max-content;
        max-width: calc(100vw - 24px);
        padding: 8px;
        border: 1px solid var(--ar-line);
        border-radius: 24px;
        background: #fff;
        box-shadow: var(--ar-shadow-soft);
    }

    .ar-area-message-shell .crm-message-actions.is-open {
        display: flex;
    }

    .ar-area-message-shell .crm-whatsapp-attach-btn,
    .ar-area-message-shell .crm-message-actions .crm-whatsapp-attach-btn {
        width: 40px;
        height: 40px;
        flex-basis: 40px;
    }

    .ar-area-message-shell .crm-whatsapp-compose textarea {
        min-height: 40px;
        padding: 10px 12px;
    }

    .ar-area-message-shell .crm-whatsapp-compose .btn {
        min-width: 70px;
        height: 40px;
    }
}
