:root {
  color-scheme: light;
  --background: #f4f6f8;
  --surface: #ffffff;
  --surface-soft: #f8fafc;
  --text: #182230;
  --muted: #6b7687;
  --line: #dfe5ec;
  --primary: #1e5bb8;
  --primary-soft: #eaf2ff;
  --green: #237449;
  --green-soft: #e7f6ed;
  --amber: #8b5b09;
  --amber-soft: #fff3d5;
  --red: #a5323f;
  --red-soft: #fdebed;
  --shadow: 0 12px 32px rgba(29, 43, 61, 0.14);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-width: 320px; background: var(--background); color: var(--text); }
button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.app-shell { min-height: 100vh; }
.topbar { min-height: 68px; display: grid; grid-template-columns: 280px minmax(300px, 650px) 1fr; align-items: center; gap: 24px; padding: 10px 22px; background: var(--surface); border-bottom: 1px solid var(--line); }
.brand-area { display: flex; align-items: center; gap: 10px; min-width: 0; }
.menu-toggle { width: 34px; height: 34px; flex: 0 0 auto; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); color: var(--muted); cursor: pointer; }
.menu-toggle:hover { color: var(--primary); border-color: var(--primary); }
.notification-alarm { position: relative; flex: 0 0 34px; margin-left: auto; padding:0; color:var(--primary); align-self:flex-start; order:99; }
.alarm-symbol { display:flex; align-items:center; justify-content:center; }
.alarm-symbol svg { width:19px; height:19px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.notification-alarm.overdue { border-color:#b8d6eb; color:var(--primary); background:#f2f8fd; }
.alarm-alert { display:none; position:absolute; top:-7px; left:-5px; width:16px; height:16px; border-radius:50%; background:#c52f2f; color:#fff; font-size:11px; font-weight:800; line-height:16px; }
.notification-alarm.overdue .alarm-alert { display:block; }
.alarm-count { position:absolute; top:-6px; right:-6px; min-width:18px; height:18px; padding:0 4px; border-radius:9px; background:#277fc0; color:white; font-size:10px; line-height:18px; }
.notification-alarm.overdue .alarm-count { background:#277fc0; }
.notification-panel { position:fixed; z-index:35; top:64px; right:0; bottom:0; width:min(410px,100vw); padding:17px; border-left:1px solid var(--line); background:var(--surface); box-shadow:-12px 0 28px rgba(22,42,60,.13); transform:translateX(105%); transition:transform .2s ease; overflow-y:auto; }
.notification-panel.open { transform:translateX(0); }
.notification-panel>header { display:flex; justify-content:space-between; gap:12px; padding-bottom:14px; border-bottom:1px solid var(--line); }
.notification-panel h2 { margin:0 0 4px; font-size:18px; }.notification-panel header p{margin:0;color:var(--muted);font-size:12px}.notification-list{display:grid;gap:9px;padding-top:12px}
.notification-card { position:relative; display:grid; gap:5px; padding:13px 38px 13px 14px; border:1px solid var(--line); border-left:4px solid #7daed1; background:var(--surface); cursor:pointer; }
.notification-card:hover { background:var(--surface-soft); }.notification-card.overdue{border-left-color:#c83232}.notification-card.due{border-left-color:#d39a1d}.notification-card.information{border-left-color:#5b9d72}
.notification-kind{color:var(--muted);font-size:11px;font-weight:700;text-transform:uppercase}.notification-card strong{font-size:14px}.notification-card p{margin:0;color:var(--muted);font-size:12px;line-height:1.4}.notification-dismiss{position:absolute;top:8px;right:8px;width:26px;height:26px;border:0;background:transparent;color:var(--muted);font-size:18px;cursor:pointer}
@media (max-width:950px){.notification-panel{top:0;width:100vw}.notification-alarm{display:flex!important;align-items:center;justify-content:center}}
.brand { display: flex; align-items: center; gap: 11px; color: var(--text); font-weight: 650; text-decoration: none; }
.brand-mark { display: grid; grid-template-columns: repeat(2, 9px); gap: 3px; }
.brand-mark span { width: 9px; height: 9px; background: var(--primary); }
.brand-logo { width: 39px; height: 39px; object-fit: contain; }
.global-search { position: relative; }
.global-search-shell { position: relative; min-width: 0; }
.global-search input { width: 100%; height: 42px; padding: 0 15px 0 42px; background: var(--surface-soft); border: 1px solid var(--line); border-radius: 8px; color: var(--text); outline: none; }
.global-search input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-soft); }
.search-icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 23px; }
.global-search-results { position:absolute; z-index:50; top:48px; left:0; right:0; max-height:min(520px,calc(100vh - 90px)); overflow-y:auto; padding:7px; border:1px solid #d7e2ea; border-radius:10px; background:var(--surface); box-shadow:0 16px 40px rgba(24,43,60,.18); }
.global-search-result { display:grid; grid-template-columns:24px minmax(0,1fr); align-items:start; gap:10px; width:100%; padding:10px 11px; border:0; border-radius:7px; background:transparent; color:var(--text); text-align:left; cursor:pointer; }
.global-search-result:hover,.global-search-result:focus { outline:none; background:#eef6fc; }
.global-search-result .nav-icon { margin-top:1px; color:#4386b8; }
.global-search-result strong,.global-search-result small { display:block; }
.global-search-result strong { font-size:13px; }
.global-search-result small { margin-top:3px; overflow:hidden; color:var(--muted); font-size:11px; line-height:1.35; text-overflow:ellipsis; white-space:nowrap; }
.global-search-empty { padding:20px; color:var(--muted); text-align:center; font-size:13px; }
.profile-button { justify-self: end; display: flex; align-items: center; gap: 10px; border: 0; background: transparent; color: var(--text); cursor: pointer; }
.avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--primary-soft); color: var(--primary); font-weight: 700; }
.app-body { display: grid; grid-template-columns: 218px minmax(0, 1fr); min-height: calc(100vh - 68px); }
.app-shell.sidebar-collapsed .app-body { grid-template-columns: 0 minmax(0, 1fr); }
.app-shell.sidebar-collapsed .sidebar { visibility: hidden; overflow: hidden; padding: 0; border: 0; }
.sidebar { background: linear-gradient(180deg,#fbfdff 0%,var(--surface) 150px); border-right: 1px solid var(--line); padding: 18px 12px; }
.nav-list { display: grid; gap: 4px; }
.nav-section-title { margin: 5px 12px 4px; color: #8b99a5; font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.nav-section-title.admin { margin-top: 20px; padding-top: 15px; border-top: 1px solid #e5ebf0; }
.nav-list a { position: relative; display: flex; align-items: center; gap: 11px; min-height: 42px; padding: 9px 11px; border: 1px solid transparent; border-radius: 8px; color: #62717d; text-decoration: none; transition: background-color .15s ease,color .15s ease,border-color .15s ease,transform .15s ease; }
.nav-list a:hover { border-color: #e2ebf2; background: #f5f9fc; color: #294b65; transform: translateX(1px); }
.nav-list a.active { border-color: #cfe2f0; background: #eaf4fb; color: #176fae; font-weight: 650; }
.nav-list a.active::after { content:""; position:absolute; top:9px; right:-13px; width:3px; height:24px; border-radius:3px 0 0 3px; background:#2588cf; }
.nav-icon { --nav-icon:none; display:grid; flex:0 0 20px; width:20px; height:20px; place-items:center; }
.nav-icon::before { content:""; width:20px; height:20px; background:currentColor; -webkit-mask:var(--nav-icon) center/20px 20px no-repeat; mask:var(--nav-icon) center/20px 20px no-repeat; }
.icon-model{--nav-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='7' height='7' rx='1.5'/%3E%3Crect x='14' y='3' width='7' height='7' rx='1.5'/%3E%3Crect x='3' y='14' width='7' height='7' rx='1.5'/%3E%3Cpath d='M14 17.5h7M17.5 14v7'/%3E%3C/svg%3E")}
.icon-responsibility{--nav-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='8' r='3'/%3E%3Cpath d='M3.5 20c.4-4 2.2-6 5.5-6s5.1 2 5.5 6'/%3E%3Cpath d='m16 12 2 2 3.5-4'/%3E%3C/svg%3E")}
.icon-assets{--nav-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m12 3 8 4.5-8 4.5-8-4.5L12 3Z'/%3E%3Cpath d='m4 12 8 4.5 8-4.5M4 16.5l8 4.5 8-4.5'/%3E%3C/svg%3E")}
.icon-control{--nav-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 5H6.5A1.5 1.5 0 0 0 5 6.5v13A1.5 1.5 0 0 0 6.5 21h11a1.5 1.5 0 0 0 1.5-1.5v-13A1.5 1.5 0 0 0 17.5 5H15'/%3E%3Crect x='9' y='3' width='6' height='4' rx='1'/%3E%3Cpath d='m8.5 14 2 2 5-5'/%3E%3C/svg%3E")}
.icon-ideas{--nav-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18h6M10 22h4'/%3E%3Cpath d='M8.5 14.5C6.9 13.4 6 11.6 6 9.5a6 6 0 0 1 12 0c0 2.1-.9 3.9-2.5 5-.9.7-1.5 1.5-1.5 2.5h-4c0-1-.6-1.8-1.5-2.5Z'/%3E%3C/svg%3E")}
.icon-documents{--nav-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 3h8l4 4v14H6z'/%3E%3Cpath d='M14 3v5h5M9 12h6M9 16h6'/%3E%3C/svg%3E")}
.icon-employees{--nav-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='8' r='3'/%3E%3Cpath d='M3.5 20c.4-4 2.2-6 5.5-6s5.1 2 5.5 6M16 5.5a3 3 0 0 1 0 5.5M16 14c2.8.2 4.3 2.2 4.5 5'/%3E%3C/svg%3E")}
.icon-archive{--nav-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='6' width='16' height='14' rx='2'/%3E%3Cpath d='M3 4h18v4H3zM9 12h6'/%3E%3C/svg%3E")}
.icon-import{--nav-icon:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3v12m-4-4 4 4 4-4M5 20h14'/%3E%3C/svg%3E")}
.workspace { min-width: 0; padding: 22px; }
.page-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 22px; margin-bottom: 17px; }
.page-title-row { display: flex; align-items: flex-start; gap: 11px; }
.page-heading h1 { margin: 0 0 5px; font-size: 25px; line-height: 1.2; }
.page-heading p { margin: 0; color: var(--muted); }
.heading-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.button { min-height: 38px; display: inline-flex; align-items: center; justify-content: center; padding: 0 14px; border: 1px solid var(--line); border-radius: 7px; cursor: pointer; }
.button.primary { background: var(--primary); border-color: var(--primary); color: white; }
.button.secondary { background: var(--surface); color: var(--text); }
.button:hover { filter: brightness(0.98); }
.view-controls { min-height: 39px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.tree-controls { min-height: 42px; margin: 0 0 5px; padding: 2px 7px 9px; border-bottom: 1px solid var(--line); }
.tree-controls .filter-chip { padding: 6px 9px; font-size: 13px; }
.tree-controls .result-summary { width: 100%; margin-left: 0; font-size: 12px; }
.filter-chip { padding: 7px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--muted); cursor: pointer; }
.filter-chip.active { color: var(--primary); border-color: var(--primary); background: var(--primary-soft); }
.result-summary { margin-left: auto; color: var(--muted); }
.model-surface { --tree-pane-width: 37%; display: grid; grid-template-columns: minmax(270px, var(--tree-pane-width)) 8px minmax(360px, 1fr); min-height: 620px; background: var(--surface); border: 1px solid var(--line); }
.tree-pane { min-width: 0; padding: 12px 10px 20px; }
.pane-resizer { position: relative; cursor: col-resize; background: var(--surface-soft); border-left: 1px solid var(--line); border-right: 1px solid var(--line); touch-action: none; }
.pane-resizer::after { content: ""; position: absolute; width: 2px; height: 42px; top: 50%; left: 50%; transform: translate(-50%, -50%); border-radius: 2px; background: var(--line); }
.pane-resizer:hover, .pane-resizer.dragging, .pane-resizer:focus { background: var(--primary-soft); outline: none; }
.pane-resizer:hover::after, .pane-resizer.dragging::after, .pane-resizer:focus::after { background: var(--primary); }
.pane-heading { display: flex; align-items: center; justify-content: space-between; min-height: 42px; padding: 5px 8px 12px; }
.pane-heading span { color: var(--muted); }
.process-tree { display: grid; gap: 2px; }
.tree-bulk-toggle { display: block; margin: 10px 8px 0 auto; padding: 3px 0; border: 0; background: transparent; color: var(--muted); font-size: 12px; cursor: pointer; }
.tree-bulk-toggle:hover { color: var(--primary); text-decoration: underline; }
.tree-group { min-height: 37px; display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 8px; padding: 6px 8px; color: var(--muted); font-weight: 650; }
.tree-add-button { width: 27px; height: 27px; display: grid; place-items: center; border: 0; border-radius: 6px; background: transparent; color: var(--muted); font-size: 20px; line-height: 1; cursor: pointer; opacity: 0; }
.tree-group:hover .tree-add-button, .tree-add-button:focus { opacity: 1; }
.tree-add-button:hover { background: var(--primary-soft); color: var(--primary); }
.tree-node { width: 100%; min-height: 38px; display: grid; grid-template-columns: 18px minmax(0, 1fr) auto 24px; align-items: center; gap: 7px; padding: 8px 9px; border: 0; border-radius: 6px; background: transparent; color: var(--text); text-align: left; cursor: pointer; }
.tree-node:hover { background: var(--surface-soft); }
.tree-node.selected { background: var(--primary-soft); color: var(--primary); font-weight: 650; }
.tree-node.zone { padding-left: 35px; color: var(--muted); }
.tree-node.zone.selected { color: var(--primary); }
.tree-node.dragging, .operation-row.dragging, .asset-card.dragging, .asset-row.dragging { opacity: .42; }
.tree-node.drop-before, .operation-row.drop-before, .asset-row.drop-before { box-shadow: inset 0 3px 0 var(--primary); background: var(--primary-soft); }
.asset-card.drop-before { box-shadow: -4px 0 0 var(--primary); border-color: var(--primary); }
.tree-node.drop-target-parent, .tree-group.drop-target-parent { outline: 2px dashed var(--primary); outline-offset: -2px; background: var(--primary-soft); }
.tree-group.drop-target-parent::after { content: "Переместить сюда"; margin-left: auto; color: var(--primary); font-size: 11px; }
.tree-node.process.drop-target-parent::after { content: "В этот процесс"; grid-column: 2 / -1; color: var(--primary); font-size: 11px; }
.tree-expander { width: 20px; height: 24px; display: grid; place-items: center; border-radius: 4px; cursor: pointer; }
.tree-expander:hover, .tree-expander:focus { background: rgba(30, 91, 184, 0.1); outline: none; }
.tree-marker { text-align: center; color: var(--muted); }
.tree-node.zone .node-name { overflow: visible; text-overflow: clip; white-space: normal; line-height: 1.35; }
.tree-node.zone .node-meta:empty { display: none; }
.node-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.node-meta { color: var(--muted); font-size: 12px; font-weight: 450; white-space: nowrap; }
.favorite-toggle { width: 24px; height: 24px; display: grid; place-items: center; border-radius: 5px; color: #aab5c3; font-size: 19px; line-height: 1; cursor: pointer; }
.favorite-toggle:hover, .favorite-toggle:focus { background: #fff6d8; color: #d39a00; outline: none; }
.favorite-toggle.selected { color: #f2b500; }
.detail-pane { min-width: 0; padding: 23px; }
.edit-notice { display: none; margin-bottom: 14px; padding: 10px 12px; background: var(--primary-soft); color: var(--primary); }
.editing .edit-notice { display: block; }
.editing .editable { outline: 1px dashed var(--primary); outline-offset: 3px; }
.detail-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; padding-bottom: 19px; border-bottom: 1px solid var(--line); }
.detail-title-content { min-width: 0; flex: 1; }
.eyebrow { display: block; margin-bottom: 6px; color: var(--primary); font-size: 13px; }
.breadcrumbs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 13px; color: var(--muted); font-size: 13px; }
.breadcrumbs button { border: 0; background: transparent; color: var(--primary); padding: 0; cursor: pointer; }
.detail-pane h2 { margin: 0 0 8px; font-size: 23px; }
.detail-pane p { margin: 0; color: var(--muted); line-height: 1.55; }
.entity-counters { display: flex; gap: 6px 12px; flex-wrap: wrap; margin: -1px 0 10px; color: var(--muted); font-size: 11px; }
.entity-counters span { position: relative; }
.entity-counters span + span::before { content: "·"; position: absolute; left: -8px; color: #b5bfcb; }
.role-highlights { display: grid; grid-template-columns: repeat(2, minmax(180px, 1fr)); gap: 8px; margin-top: 14px; }
.role-highlight { display: grid; gap: 3px; padding: 10px 12px; border-left: 3px solid #4b9bea; background: #edf6ff; color: #174f87; }
.role-highlight span { color: #3978b7; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; }
.role-highlight strong { font-size: 13px; line-height: 1.35; }
.target-state { margin-top: 16px; padding: 15px 17px; border-left: 3px solid var(--primary); background: var(--primary-soft); }
.target-state > span { display: block; margin-bottom: 6px; color: var(--primary); font-size: 13px; font-weight: 700; }
.target-state p { color: var(--text); font-size: 15px; }
.benefit-block { margin-top: 16px; padding: 18px 20px; border: 1px solid #b8d7f4; border-left: 5px solid var(--primary); background: linear-gradient(135deg, #eef7ff, #f8fbff); box-shadow: 0 5px 16px rgba(31, 102, 173, 0.08); }
.benefit-block > span { display: block; margin-bottom: 7px; color: var(--primary); font-size: 13px; font-weight: 750; letter-spacing: .02em; text-transform: uppercase; }
.benefit-block p { color: var(--text); font-size: 16px; font-weight: 550; line-height: 1.55; }
.badges { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 13px; }
.badge { padding: 5px 9px; border-radius: 999px; background: var(--surface-soft); color: var(--muted); font-size: 13px; }
.secondary-badges { margin-top: 10px; }
.secondary-badges .badge { padding: 3px 0; background: transparent; font-size: 11px; }
.icon-button { min-width: 35px; min-height: 35px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); color: var(--text); cursor: pointer; }
.detail-section { margin-top: 21px; }
.section-heading { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.section-heading h3 { margin: 0; font-size: 16px; }
.section-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.text-button { border: 0; background: transparent; color: var(--primary); cursor: pointer; }
.text-button.danger { color: #b43a3a; }
.entity-actions { display: flex; align-items: center; justify-content: flex-end; gap: 9px; flex-wrap: wrap; }
.entity-audit { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 24px; padding-top: 13px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; }
.table-wrapper { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 10px 9px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; line-height: 1.4; }
th { background: var(--surface-soft); color: var(--muted); font-size: 13px; font-weight: 650; }
td.role { color: var(--muted); }
.operation-row { cursor: pointer; }
.operation-row:hover { background: var(--surface-soft); }
.operation-details td { padding: 14px; background: var(--surface-soft); }
.operation-details dl { display: grid; grid-template-columns: 125px 1fr; gap: 8px 12px; margin: 0; }
.operation-details dt { color: var(--muted); }
.operation-details dd { margin: 0; }
.zone-row { cursor: pointer; outline: none; }
.zone-row:hover, .zone-row:focus-visible { background: var(--surface-soft); }
.zone-row:focus-visible { box-shadow: inset 3px 0 0 var(--primary); }
.zone-row td:first-child { min-width: 205px; }
.asset-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
.asset-card { min-height: 150px; display: grid; align-content: start; gap: 9px; padding: 13px; border: 1px solid var(--line); background: var(--surface-soft); color: var(--text); text-align: left; cursor: pointer; }
.asset-card:hover { border-color: var(--primary); }
.asset-top { display: flex; justify-content: space-between; gap: 8px; }
.asset-card small { color: var(--muted); }
.asset-description { color: var(--muted); font-size: 13px; line-height: 1.4; }
.asset-owner { font-size: 13px; }
.asset-owner span { color: var(--muted); }
.star-rating { display: inline-flex; flex: 0 0 auto; gap: 1px; white-space: nowrap; }
.star { color: #cad5e3; font-size: 17px; line-height: 1; }
.star.filled { color: #2f78d3; }
.asset-view-switch { display: flex; padding: 2px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface-soft); }
.view-button { min-height: 30px; padding: 0 10px; border: 0; border-radius: 5px; background: transparent; color: var(--muted); cursor: pointer; }
.view-button.active { background: var(--surface); color: var(--primary); box-shadow: 0 1px 3px rgba(29, 43, 61, 0.12); }
.asset-row { cursor: pointer; }
.asset-row:hover { background: var(--surface-soft); }
.responsibility-matrix { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); }
.responsibility-matrix.responsibility-count-1 { grid-template-columns: minmax(0, 1fr); }
.responsibility-matrix.responsibility-count-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.responsibility-matrix.responsibility-count-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.responsibility-matrix.responsibility-count-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.responsibility-item { min-width: 0; display: grid; align-content: start; gap: 5px; padding: 14px; border-right: 1px solid var(--line); }
.responsibility-item:last-child { border-right: 0; }
.responsibility-item > span { color: var(--primary); font-size: 12px; font-weight: 700; text-transform: uppercase; }
.responsibility-item em { min-height: 44px; color: var(--muted); font-size: 11px; font-style: normal; line-height: 1.35; }
.responsibility-item strong { font-size: 14px; line-height: 1.35; }
.responsibility-item small { color: var(--muted); line-height: 1.35; }
.responsibility-item.inherited { background: var(--surface-soft); }
.responsibility-item.inherited > span { color: var(--muted); }
.responsibility-matrix.compact { margin-top: 14px; }
.control-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 230px)); gap: 10px; margin-bottom: 19px; }
.control-summary > div { display: grid; gap: 5px; padding: 13px 15px; background: var(--surface-soft); border: 1px solid var(--line); }
.control-summary span { color: var(--muted); font-size: 13px; }
.control-section h4 { margin: 0 0 9px; font-size: 14px; }
.empty-state { padding: 32px 15px; color: var(--muted); text-align: center; }
.modal { width: min(560px, calc(100% - 32px)); border: 1px solid var(--line); border-radius: 10px; padding: 0; color: var(--text); background: var(--surface); box-shadow: var(--shadow); }
.modal::backdrop { background: rgba(20, 29, 40, 0.42); }
.modal form { padding: 20px; }
.modal-heading { display: flex; justify-content: space-between; gap: 16px; }
.modal h2 { margin: 0 0 8px; }
.muted { color: var(--muted); }
.field { display: grid; gap: 6px; margin-top: 15px; }
.field span { font-weight: 650; }
.field input, .field textarea { width: 100%; border: 1px solid var(--line); border-radius: 7px; padding: 10px 11px; color: var(--text); background: var(--surface); resize: vertical; }
.field input:focus, .field textarea:focus { outline: 3px solid var(--primary-soft); border-color: var(--primary); }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.directory-surface { min-height: 500px; background: var(--surface); border: 1px solid var(--line); }
.archive-surface { padding: 18px; }
.archive-toolbar { display: flex; justify-content: flex-end; margin-bottom: 14px; }
.archive-toolbar .field { width: min(260px, 100%); margin-top: 0; }
.lock-admin { margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--line); }
.lock-admin h2 { margin: 0 0 6px; font-size: 18px; }
.lock-admin td small { display: block; margin-top: 3px; color: var(--muted); }
.import-source { display: flex; justify-content: space-between; align-items: center; gap: 18px; padding: 18px 20px; border: 1px solid var(--line); background: var(--surface); }
.import-source h2 { margin: 4px 0 0; font-size: 18px; }
.import-summary { display: grid; grid-template-columns: repeat(7, minmax(100px, 1fr)); gap: 8px; margin: 12px 0; }
.import-summary > div { display: grid; gap: 5px; padding: 14px; border: 1px solid var(--line); background: var(--surface); }
.import-summary span { color: var(--muted); font-size: 12px; }
.import-summary strong { font-size: 22px; }
.import-section { margin-top: 12px; padding: 18px; }
.import-section h2 { margin: 0; font-size: 18px; }
.import-result { border-color: #9bc9ad; background: #f7fcf8; }
.view-controls.compact { margin: 0; }
.mapping-status, .issue-level { display: inline-flex; padding: 4px 7px; border-radius: 999px; font-size: 12px; }
.mapping-status.mapped_role, .mapping-status.mapped_employee, .issue-level.info { background: var(--primary-soft); color: var(--primary); }
.mapping-status.unresolved, .issue-level.warning { background: var(--amber-soft); color: var(--amber); }
.mapping-status.skipped { background: var(--surface-soft); color: var(--muted); }
.mapping-status.new_role, .mapping-status.mapped_override { background: var(--green-soft); color: var(--green); }
.issue-level.error { background: #fde8e8; color: #b43a3a; }
.import-mapping-table td:first-child { min-width: 200px; }
.import-mapping-table td:first-child small { display: block; margin-top: 5px; color: var(--muted); }
.import-mapping-table select, .import-mapping-table input, .import-name-correction { width: 100%; min-width: 160px; min-height: 36px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); }
.import-name-correction { min-width: 240px; }
.corrected-mark { display: block; margin-top: 4px; color: var(--green); }
.asset-dashboard { max-width: 1780px; }
.asset-kpis { display: grid; grid-template-columns: repeat(8, minmax(110px, 1fr)); gap: 9px; margin-bottom: 12px; }
.asset-kpi { min-width: 0; display: grid; gap: 7px; padding: 14px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); color: var(--text); text-align: left; cursor: pointer; }
.asset-kpi:hover, .asset-kpi.active { border-color: var(--primary); box-shadow: 0 0 0 2px var(--primary-soft); }
.asset-kpi span { min-height: 30px; color: var(--muted); font-size: 12px; line-height: 1.25; }
.asset-kpi strong { font-size: 25px; }
.asset-overview-grid { display: grid; grid-template-columns: minmax(650px, 1.7fr) minmax(310px, .7fr); gap: 12px; margin-top: 12px; }
.dashboard-panel { padding: 17px; }
.dashboard-panel h2 { margin: 0; font-size: 18px; }
.dashboard-panel .section-heading p { margin: 4px 0 0; }
.health-table th:not(:first-child), .health-table td:not(:first-child) { text-align: center; white-space: nowrap; }
.health-table td:first-child { min-width: 240px; }
.health-table button { min-width: 28px; padding: 3px 6px; border: 0; border-radius: 5px; background: transparent; color: inherit; cursor: pointer; }
.health-table button:hover { background: var(--primary-soft); color: var(--primary); }
.health-table .trend { font-size: 14px; font-weight: 750; }
.health-table .trend.improved { color: #24845b; }
.health-table .trend.worse { color: #c44752; }
.health-table .trend.stable { color: #8795a2; font-weight: 600; }
.health-process { cursor: pointer; }
.health-process:hover { background: var(--surface-soft); }
.health-process td:first-child strong { color: #24445f; }
.health-zone { background: #fbfcfe; color: var(--muted); }
.health-zone td:first-child { padding-left: 34px; }
.health-chevron, .health-zone-marker { display: inline-block; width: 21px; color: var(--primary); }
.deviation-list { display: grid; gap: 6px; }
.deviation-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px; border: 1px solid transparent; border-radius: 6px; background: var(--surface-soft); color: var(--text); text-align: left; cursor: pointer; }
.deviation-item:hover { border-color: var(--line); background: var(--surface); }
.deviation-item > span:first-child { min-width: 0; display: grid; gap: 3px; }
.deviation-item strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.deviation-item small { color: var(--muted); }
.deviation-signal { flex: 0 0 auto; padding: 4px 7px; border-radius: 999px; font-size: 11px; }
.deviation-signal.critical { background: var(--red-soft); color: var(--red); }
.deviation-signal.attention, .deviation-signal.unassessed { background: var(--amber-soft); color: var(--amber); }
.deviation-signal.good { background: var(--green-soft); color: var(--green); }
.criticality-badge { display: inline-flex; flex: 0 0 auto; padding: 4px 8px; border-radius: 999px; background: var(--badge-tint); color: var(--badge-color); font-size: 11px; font-weight: 600; white-space: nowrap; }
.asset-register { margin-top: 12px; }
.asset-mobile-register { display: none; }
.asset-filter-bar { display: grid; grid-template-columns: repeat(6, minmax(150px, 1fr)); gap: 8px; margin-bottom: 12px; }
.asset-filter-bar select { min-height: 38px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); }
.asset-dashboard-table { font-size: 13px; }
.asset-dashboard-table td { vertical-align: middle; }
.asset-dashboard-table td:first-child { min-width: 220px; }
.asset-dashboard-table td:nth-child(2) { min-width: 210px; }
.asset-dashboard-table th:last-child, .asset-dashboard-table td:last-child { white-space: nowrap; }
.asset-dashboard-table td > small { display: block; margin-top: 4px; color: var(--muted); line-height: 1.3; }
.asset-dashboard-row { cursor: pointer; }
.asset-dashboard-row:hover { background: #f7faff; }
.asset-dashboard-row.highlight-by-criticality { background: var(--criticality-tint); box-shadow: inset 3px 0 var(--criticality-line); }
.asset-dashboard-row.highlight-by-criticality:hover { filter: saturate(1.08); }
.control-warning { color: #9a7217; }
.section-inline-actions, .page-heading-actions, .health-bulk-actions { display: flex; align-items: center; gap: 12px; }
.page-heading-actions { justify-content: flex-end; flex-wrap: wrap; }
.health-bulk-actions { justify-content: flex-end; margin-top: 8px; }
.asset-settings-dialog { width: min(1050px, calc(100% - 32px)); max-width: 1050px; }
.asset-settings-dialog form { padding: 22px; }
.settings-section { margin-top: 20px; }
.settings-section h3 { margin: 0 0 8px; }
.settings-table input:not([type=color]), .settings-table textarea, .settings-table select { width: 100%; min-width: 110px; padding: 7px 8px; border: 1px solid var(--line); border-radius: 5px; background: var(--surface); color: var(--text); }
.settings-table textarea { min-width: 250px; resize: vertical; }
.settings-table input[type=color] { width: 48px; height: 34px; padding: 2px; border: 1px solid var(--line); border-radius: 5px; background: var(--surface); }
.health-rule-settings { display: grid; grid-template-columns: repeat(2, minmax(260px,1fr)); gap: 9px 16px; padding: 14px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface-soft); }
.health-rule-settings label { display: grid; grid-template-columns: minmax(190px,1fr) minmax(190px,.9fr); align-items: center; gap: 10px; }
.health-rule-settings span { font-size: 13px; }
.health-rule-settings select { width: 100%; padding: 7px 8px; border: 1px solid var(--line); border-radius: 5px; background: var(--surface); color: var(--text); }
.responsibility-page { max-width: 1600px; }
.employee-perspective { display: grid; gap: 5px; min-width: 310px; color: var(--muted); font-size: 12px; }
.employee-perspective select { min-height: 39px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); }
.responsibility-summary { display: grid; grid-template-columns: repeat(8,minmax(110px,1fr)); gap: 9px; margin-bottom: 12px; }
.responsibility-summary article { display: grid; gap: 7px; padding: 13px; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); }
.responsibility-summary span { min-height: 28px; color: var(--muted); font-size: 12px; }
.responsibility-summary strong { font-size: 24px; }
.responsibility-surface { padding: 17px; }
.responsibility-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 13px; border-bottom: 1px solid var(--line); }
.responsibility-tabs, .role-filter { display: flex; align-items: center; gap: 5px; }
.responsibility-tabs button, .role-filter button { padding: 9px 11px; border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--muted); cursor: pointer; }
.responsibility-tabs button.active { border-bottom-color: var(--primary); color: var(--primary); font-weight: 650; }
.responsibility-tabs button span { margin-left: 4px; padding: 2px 6px; border-radius: 10px; background: var(--surface-soft); font-size: 11px; }
.role-filter button { padding: 6px 9px; border: 1px solid transparent; border-radius: 5px; }
.role-filter button.active { border-color: #bcd7eb; background: var(--primary-soft); color: var(--primary); }
.responsibility-table td { vertical-align: top; }
.responsibility-table td:first-child { min-width: 210px; }
.responsibility-table td:nth-child(2) { min-width: 230px; color: var(--muted); }
.responsibility-table td:nth-child(3) { min-width: 280px; line-height: 1.45; }
.responsibility-table td > small { display: block; margin-top: 4px; color: var(--muted); }
.responsibility-role-list { display: grid; gap: 5px; min-width: 190px; }
.responsibility-role { display: grid; gap: 2px; padding: 6px 8px; border-left: 3px solid #8ab6d8; background: #f2f7fb; font-size: 12px; }
.responsibility-role small { color: var(--muted); }
.responsibility-role.role-supervisor { border-left-color: #745fa8; background: #f5f2fa; }
.responsibility-role.role-operator { border-left-color: #5b9a77; background: #f1f8f4; }
.responsibility-group-row th { padding: 10px 12px; border-top: 1px solid #cdddea; border-bottom: 1px solid #dce7ef; background: #edf4f9; color: #284e6d; text-align: left; }
.responsibility-group-row th small { float: right; min-width: 26px; padding: 2px 8px; border-radius: 10px; background: #d8e7f2; text-align: center; font-size: 11px; }
.responsibility-item-row:hover { background: #fafcff; }
.success-notice { margin: 10px 0; color: #287552; font-size: 13px; }
.control-page { max-width: 1600px; }
.control-summary-cards { display:grid;grid-template-columns:repeat(4,minmax(150px,1fr));gap:9px;margin-bottom:12px; }
.control-summary-cards button { display:grid;gap:7px;padding:14px;border:1px solid var(--line);border-radius:7px;background:var(--surface);color:var(--text);text-align:left;cursor:pointer; }
.control-summary-cards button:hover { border-color:var(--primary); }
.control-summary-cards span { color:var(--muted);font-size:12px; }.control-summary-cards strong{font-size:25px;}
.control-surface { padding:17px; }.control-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:14px;border-bottom:1px solid var(--line);}
.control-tabs{display:flex;gap:4px}.control-tabs button{padding:10px;border:0;border-bottom:2px solid transparent;background:transparent;color:var(--muted);cursor:pointer}.control-tabs button.active{border-bottom-color:var(--primary);color:var(--primary);font-weight:650}.control-tabs span{margin-left:4px;padding:2px 6px;border-radius:9px;background:var(--surface-soft);font-size:11px}
.control-filters{display:flex;gap:7px;padding-bottom:7px}.control-filters select{min-width:180px;padding:7px 8px;border:1px solid var(--line);border-radius:6px;background:var(--surface)}
.control-list{display:grid;gap:13px}.control-process-group{border:1px solid var(--line);border-radius:7px;overflow:hidden}.control-process-group>header{display:flex;align-items:center;justify-content:space-between;padding:10px 13px;background:#edf4f9}.control-process-group h3{margin:0;color:#284e6d;font-size:14px}.control-process-group>header span{padding:2px 8px;border-radius:10px;background:#d8e7f2;font-size:11px}
.control-asset-card{padding:13px;border-top:1px solid var(--line);background:var(--surface);cursor:pointer}.control-asset-card:hover{background:#f7fbfe}.control-asset-main{display:grid;grid-template-columns:minmax(300px,1fr) 210px;gap:16px}.control-asset-card h4{margin:4px 0;font-size:15px}.control-asset-card p{margin:0;color:var(--muted);font-size:12px}.control-status{font-size:11px;color:var(--muted)}.status-due .control-status{color:var(--red);font-weight:650}.control-current{display:grid;gap:3px}.control-current>span,.control-current small{color:var(--muted);font-size:11px}.control-asset-meta{display:flex;justify-content:space-between;gap:12px;margin-top:10px;padding-top:9px;border-top:1px dashed var(--line);color:var(--muted);font-size:12px}.control-card-actions{display:flex;gap:12px;margin-top:7px;justify-content:flex-end}
.control-dialog{width:min(680px,calc(100% - 24px));max-width:680px}.control-dialog form{padding:22px}.rating-field{margin:14px 0;padding:12px;border:1px solid var(--line);border-radius:7px}.assessment-stars{display:flex;align-items:center;gap:4px;margin:8px 0}.assessment-stars button{padding:2px;border:0;background:transparent;color:#cbd5de;font-size:30px;cursor:pointer}.assessment-stars button.selected{color:#2789d2}.assessment-stars .absence-rating{display:grid;grid-template-columns:auto auto;align-items:center;gap:5px;margin-right:5px;padding:6px 9px;border:1px solid #d8e0e6;border-radius:6px;color:#697784;font-size:14px}.assessment-stars .absence-rating small{font-size:11px}.assessment-stars .absence-rating.selected{border-color:#c96772;background:#fff1f2;color:#a94855}.rating-divider{width:1px;height:28px;margin:0 5px;background:var(--line)}.rating-legend{display:grid;gap:5px;padding-top:9px;border-top:1px solid var(--line);color:var(--muted);font-size:12px}.rating-legend b{display:inline-block;min-width:28px;color:#2789d2}.rating-legend .unassessed-hint{margin-top:4px;padding-top:7px;border-top:1px dashed var(--line)}.rating-legend .unassessed-hint b{color:#778692}.asset-absent{display:inline-flex;align-items:center;gap:6px;color:#a94855;font-size:12px;font-weight:650}.asset-absent .star{color:#cbd5de}.state-unknown{color:#7c8994;font-size:12px}.unplanned-stars .star.filled{color:#8e9aa5}.assessment-summary-row{cursor:pointer}.assessment-summary-row:hover{background:#f4f8fb}.assessment-summary-row small{display:block;margin-top:3px;color:var(--muted)}.assessment-detail-row td{padding:12px 16px;background:#f7f9fb}.assessment-improvement{margin-bottom:12px;padding:10px 12px;border-left:3px solid var(--primary);background:#eef6fc}.assessment-improvement p{margin:5px 0 0;line-height:1.45}.assessment-files{display:flex;flex-wrap:wrap;gap:8px 14px;margin-top:7px;color:var(--muted)}
.deviation-signal.absent{background:#fff0f1;color:#a94855}
.lifecycle-planned{display:block;width:max-content;margin-top:4px;padding:2px 7px;border-radius:999px;background:#eef1f5;color:#637180;font-size:10px;font-weight:650}
@media(max-width:1000px){.control-toolbar{align-items:flex-start;flex-direction:column}.control-filters{width:100%}.control-asset-main{grid-template-columns:1fr}.control-summary-cards{grid-template-columns:repeat(2,1fr)}}
@media(max-width:700px){.asset-detail-shell{padding:18px}.asset-detail-toolbar{grid-template-columns:1fr}.asset-detail-actions{justify-content:flex-start;flex-wrap:wrap}.asset-dashboard-detail .responsibility-matrix{grid-template-columns:repeat(2,minmax(0,1fr))}.asset-control-summary{grid-template-columns:1fr}}
.documents-page{max-width:1600px}.document-surface{padding:17px}.document-toolbar{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-bottom:8px;padding-bottom:13px;border-bottom:1px solid var(--line)}
.document-type-filters{display:flex;align-items:center;gap:7px;flex-wrap:wrap}.document-type-filters label{display:flex;align-items:center;gap:6px;padding:7px 10px;border:1px solid var(--line);border-radius:999px;background:var(--surface);color:var(--muted);font-size:12px;cursor:pointer}.document-type-filters label:has(input:checked){border-color:#9dc6e3;background:#eef7fd;color:#245d85}.document-type-filters input{accent-color:var(--primary)}.compact-filters{margin:0 0 12px}.compact-filters label{padding:5px 9px}
.document-select-filters{display:flex;gap:7px;flex:1}.document-select-filters select{min-width:160px;padding:7px 9px;border:1px solid var(--line);border-radius:6px;background:var(--surface)}.document-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(270px,1fr));gap:11px;margin-top:12px}.document-card{display:grid;align-content:start;gap:9px;min-width:0;padding:14px;border:1px solid var(--line);border-radius:8px;background:var(--surface);cursor:pointer;transition:border-color .15s ease,box-shadow .15s ease,transform .15s ease}.document-card:hover,.document-card:focus{outline:none;border-color:#9dc6e3;box-shadow:0 7px 18px rgba(35,77,108,.1);transform:translateY(-1px)}.document-card.compact-card{min-height:210px}.document-card-heading{display:flex;align-items:center;justify-content:space-between;gap:8px}.document-card h3{margin:0;font-size:15px}.document-card p{margin:0;color:var(--muted);font-size:12px;line-height:1.45}.document-card footer{display:grid;gap:5px;margin-top:auto;padding-top:9px;border-top:1px solid var(--line);color:var(--muted);font-size:11px}.document-type,.document-status{width:max-content;padding:3px 7px;border-radius:999px;font-size:10px;font-weight:700}.type-regulation{background:#e9f1fb;color:#285f9a}.type-instruction{background:#edf6ef;color:#35704a}.type-reference{background:#f2eff8;color:#68518c}.status-current{background:var(--green-soft);color:var(--green)}.status-draft{background:var(--amber-soft);color:var(--amber)}.status-archived{background:#eef1f4;color:#687681}.document-context{color:#41566a;font-size:12px}.document-context small,.documents-section td small{display:block;margin-top:3px;color:var(--muted)}.document-file-actions{display:flex;gap:12px}.document-file-actions a{color:var(--primary);font-weight:650;text-decoration:none}.document-file-actions a:hover{text-decoration:underline}
.document-modal{width:min(720px,calc(100% - 24px))}.document-zone-list{max-height:220px;overflow:auto;border:1px solid var(--line);border-radius:7px}.document-zone-list section{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:3px 12px;padding:10px 12px;border-bottom:1px solid var(--line)}.document-zone-list section:last-child{border-bottom:0}.document-zone-list section>strong{grid-column:1/-1;margin-bottom:4px;color:#284e6d;font-size:12px}.document-zone-list label{display:flex;align-items:flex-start;gap:7px;padding:5px;border-radius:5px;font-size:12px}.document-zone-list label:hover{background:var(--surface-soft)}.document-zone-list label.context-selected{background:var(--primary-soft);color:var(--primary);font-weight:650}.file-drop-zone{display:grid;place-items:center;gap:5px;min-height:112px;margin-top:13px;padding:18px;border:2px dashed #b8c9d7;border-radius:8px;background:#f8fbfd;color:#476276;text-align:center;cursor:pointer}.file-drop-zone span{color:var(--muted);font-size:12px}.file-drop-zone:hover,.file-drop-zone:focus,.file-drop-zone.drag-over{outline:none;border-color:var(--primary);background:var(--primary-soft)}.selected-file{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:8px;padding:9px 11px;border:1px solid var(--line);border-radius:6px}.selected-file span{display:grid;gap:2px}.selected-file small{color:var(--muted)}
@media(max-width:800px){.document-select-filters{width:100%;flex-direction:column}.document-select-filters select{width:100%}.document-zone-list section{grid-template-columns:1fr}.document-zone-list section>strong{grid-column:1}.document-grid{grid-template-columns:1fr}}
.document-detail-status{justify-content:flex-start;margin-bottom:12px}.document-description{margin-top:0}.document-file-summary{display:grid;grid-template-columns:minmax(220px,.7fr) minmax(260px,1.3fr);gap:10px}.document-file-summary>div{display:grid;gap:5px;padding:12px;background:var(--surface-soft);border:1px solid var(--line)}.document-file-summary span,.document-file-summary small{color:var(--muted);font-size:12px}.document-file-card .document-file-actions{margin-top:6px;padding-top:8px;border-top:1px solid var(--line)}.documents-page tbody td:first-child strong,.documents-page tbody td:first-child small{display:block}.documents-page tbody td:first-child small{margin-top:4px;color:var(--muted);line-height:1.4}@media(max-width:700px){.document-file-summary{grid-template-columns:1fr}}
@media(max-width:1100px){.responsibility-summary{grid-template-columns:repeat(4,1fr)}.responsibility-toolbar{align-items:flex-start;flex-direction:column}.role-filter{padding-bottom:8px}}
.asset-process-group th { padding: 9px 11px; background: #eef4f9; color: #284e6d; text-align: left; }
.asset-process-group th span { float: right; min-width: 26px; padding: 2px 8px; border-radius: 10px; background: #d9e8f4; text-align: center; font-size: 11px; }
.criticality { width: max-content; padding: 2px 6px; border-radius: 4px; font-size: 10px; }
.criticality-critical { background: var(--red-soft); color: var(--red) !important; }
.criticality-high { background: var(--amber-soft); color: var(--amber) !important; }
.trend { white-space: nowrap; font-size: 12px; }
.trend.improved { color: var(--green); }
.trend.worse, .control-overdue { color: var(--red); }
.trend.stable { color: var(--muted); }
.state-unknown { color: var(--muted); font-size: 12px; }
.star-rating.compact .star { font-size: 14px; }
.asset-dashboard-detail { width: min(820px, calc(100% - 24px)); max-width: none; height: 100vh; max-height: 100vh; margin: 0 0 0 auto; padding: 0; border: 0; border-left: 1px solid var(--line); box-shadow: var(--shadow); }
.asset-dashboard-detail::backdrop { background: rgba(18, 29, 43, .28); }
.asset-detail-shell { min-height: 100%; padding: 24px 26px 32px; overflow-y: auto; }
.asset-dashboard-detail .modal-heading { align-items: flex-start; margin-bottom: 16px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.asset-dashboard-detail .modal-heading h2 { margin: 5px 0 0; line-height: 1.2; }
.asset-dashboard-detail .icon-button { flex: 0 0 36px; width: 36px; min-width: 36px; height: 36px; min-height: 36px; padding: 0; font-size: 19px; line-height: 1; }
.asset-detail-toolbar { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 12px; margin-bottom: 17px; }
.asset-detail-context { min-width: 0; margin: 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.asset-detail-actions { display: flex; align-items: center; justify-content: flex-end; gap: 14px; white-space: nowrap; }
.asset-dashboard-detail .target-state { margin-top: 0; }
.asset-dashboard-detail .detail-section h3 { margin: 0 0 10px; }
.asset-dashboard-detail .responsibility-matrix { grid-template-columns: repeat(4,minmax(0,1fr)); }
.asset-dashboard-detail .responsibility-matrix.responsibility-count-1 { grid-template-columns: minmax(0,1fr); }
.asset-dashboard-detail .responsibility-matrix.responsibility-count-2 { grid-template-columns: repeat(2,minmax(0,1fr)); }
.asset-dashboard-detail .responsibility-matrix.responsibility-count-3 { grid-template-columns: repeat(3,minmax(0,1fr)); }
.asset-dashboard-detail .responsibility-item { min-width: 0; }
.asset-dashboard-detail .responsibility-item strong,.asset-dashboard-detail .responsibility-item small { overflow-wrap: anywhere; }
.asset-dashboard-detail table { table-layout: auto; }
.asset-dashboard-detail th,.asset-dashboard-detail td { vertical-align: top; }
.asset-control-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.asset-control-summary > div { display: grid; gap: 5px; padding: 12px; background: var(--surface-soft); }
.asset-control-summary span { color: var(--muted); font-size: 12px; }
.asset-comment-list { display: grid; gap: 8px; }
.asset-comment-list article { padding: 11px; border-left: 3px solid var(--line); background: var(--surface-soft); }
.asset-comment-list article strong { font-size: 12px; }
.asset-comment-list article p { margin: 6px 0 0; white-space: pre-line; line-height: 1.45; }
@media (max-width: 1050px) { .import-summary { grid-template-columns: repeat(4, minmax(100px, 1fr)); } }
.employee-table td { vertical-align: middle; }
.employee-table td:first-child { min-width: 210px; }
.employee-table td:nth-child(2) { min-width: 190px; }
.employee-table td > small { display: block; margin-top: 4px; color: var(--muted); }
.role-tags { display: flex; gap: 5px; flex-wrap: wrap; }
.role-tags > span { padding: 4px 7px; border-radius: 5px; background: var(--primary-soft); color: var(--primary); font-size: 12px; }
.sortable-role-tags > span { cursor: grab; user-select: none; }
.sortable-role-tags > span:active { cursor: grabbing; }
.sortable-role-tags > span.dragging { opacity: .42; }
.sortable-role-tags.role-drop-active { min-height: 27px; outline: 1px dashed #78a9d1; outline-offset: 3px; border-radius: 4px; }
.status { display: inline-flex; padding: 5px 8px; border-radius: 999px; font-size: 12px; white-space: nowrap; }
.status-active { background: var(--green-soft); color: var(--green); }
.status-external { background: #e8f2ff; color: #2466a8; }
.department-group { cursor: pointer; background: #f4f8fc; }
.department-group:hover { background: #eaf3fb; }
.department-group td { padding: 11px 16px !important; border-top: 1px solid #cdddea; border-bottom: 1px solid #dce7ef; }
.department-group strong { margin-right: 14px; color: #173b5c; }
.department-group span:not(.group-chevron) { color: var(--muted); font-size: 13px; }
.department-group small { float: right; min-width: 26px; padding: 2px 8px; border-radius: 10px; background: #dbeaf7; color: #315b7d; text-align: center; }
.group-chevron { display: inline-block; width: 20px; color: #50728e; font-size: 18px; }
.employee-row:hover { background: #fafcff; }
.status-dismissed { background: var(--surface-soft); color: var(--muted); }
.employee-modal { width: min(760px, calc(100% - 32px)); }
.roles-modal, .departments-modal { width: min(1040px, calc(100% - 32px)); }
.roles-modal-body { max-height: 88vh; overflow-y: auto; padding: 22px; }
.departments-modal-body { max-height: 88vh; overflow-y: auto; padding: 22px; }
.role-create-grid { display: grid; grid-template-columns: minmax(240px, 1fr) 190px auto; gap: 8px; margin: 18px 0; }
.department-create-grid { display: grid; grid-template-columns: minmax(220px, 1fr) minmax(250px, 1fr) auto; gap: 8px; margin: 18px 0; }
.role-create-grid input, .role-create-grid select, .roles-admin-table input, .roles-admin-table textarea, .roles-admin-table select { width: 100%; min-height: 38px; padding: 8px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); }
.department-create-grid input, .department-create-grid select, .departments-admin-table input, .departments-admin-table select { width: 100%; min-height: 38px; padding: 8px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); }
.roles-admin-table td:first-child { min-width: 280px; }
.roles-admin-table td:nth-child(2), .roles-admin-table td:nth-child(4) { min-width: 155px; }
.roles-admin-table textarea { display: block; margin-top: 6px; resize: vertical; }
.roles-admin-table td:nth-child(3) span, .roles-admin-table td:nth-child(3) small { display: block; white-space: nowrap; }
.roles-admin-table td:nth-child(3) small { margin-top: 4px; color: var(--muted); }
.entity-modal { width: min(720px, calc(100% - 32px)); }
.entity-modal form { max-height: min(88vh, 850px); overflow-y: auto; }
.operations-modal { width: min(980px, calc(100% - 32px)); }
.responsibility-modal { width: min(850px, calc(100% - 32px)); }
.responsibility-editor { margin-top: 17px; }
.responsibility-editor td:first-child { min-width: 155px; }
.responsibility-editor td:first-child small { display: block; margin-top: 4px; color: var(--muted); }
.responsibility-editor select { width: 100%; min-width: 190px; min-height: 38px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); }
.responsibility-editor .inherited-role { background: var(--surface-soft); }
.responsibility-editor select:disabled { color: var(--muted); opacity: 1; }
.responsibility-visibility { text-align: center; white-space: nowrap; }
.responsibility-visibility input { width: 17px; height: 17px; accent-color: var(--primary); }
.responsibility-visibility input:not(:disabled) { cursor: pointer; }
.responsibility-empty { margin-top: 12px; }
.zone-responsibility-actions { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.operations-modal-body { max-height: 88vh; overflow-y: auto; padding: 22px; }
.full-operation-list { display: grid; gap: 12px; margin-top: 18px; }
.full-operation-card { padding: 16px; border: 1px solid var(--line); background: var(--surface); }
.full-operation-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 15px; }
.full-operation-heading > div { display: flex; align-items: center; gap: 9px; }
.full-operation-heading h3 { margin: 0; font-size: 16px; }
.operation-number { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-size: 12px; font-weight: 700; }
.operation-role-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.operation-role-grid > div { display: grid; gap: 4px; padding: 10px; background: var(--surface-soft); }
.operation-role-grid span { color: var(--muted); font-size: 12px; }
.operation-role-grid strong { font-size: 13px; }
.full-operation-card dl { display: grid; grid-template-columns: 145px 1fr; gap: 8px 12px; margin: 14px 0 0; }
.full-operation-card dt { color: var(--muted); }
.full-operation-card dd { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.edit-operation { margin-top: 12px; }
.form-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-columns:has(#model-asset-type) > .field { align-self: start; }
.form-columns:has(#model-asset-type) select { height: 41px; }
.field select { width: 100%; min-height: 41px; border: 1px solid var(--line); border-radius: 7px; padding: 8px 10px; background: var(--surface); color: var(--text); }
.role-fieldset { margin-top: 16px; padding: 13px; border: 1px solid var(--line); }
.role-fieldset legend { padding: 0 5px; font-weight: 650; }
.role-table-scroll { max-height: 245px; overflow-y: auto; border: 1px solid var(--line); }
.role-select-table th { position: sticky; top: 0; z-index: 1; }
.role-select-table th, .role-select-table td { padding: 8px 10px; }
.role-select-table tbody tr:hover { background: var(--surface-soft); }
.role-select-table label { display: block; cursor: pointer; }
.role-select-table .check-column { width: 62px; text-align: center; }
.role-select-table input { width: 17px; height: 17px; cursor: pointer; }
.asset-zone-table-scroll { max-height: 270px; overflow-y: auto; border: 1px solid var(--line); }
.asset-zone-table thead th { position: sticky; top: 0; z-index: 2; }
.asset-zone-table .check-column { width: 68px; text-align: center; }
.asset-zone-table input { width: 17px; height: 17px; cursor: pointer; }
.asset-zone-table label { display: block; cursor: pointer; }
.asset-zone-table tbody tr:not(.asset-zone-group):hover { background: var(--surface-soft); }
.asset-zone-group th { position: sticky; top: 37px; z-index: 1; padding: 7px 10px; background: var(--primary-soft); color: var(--primary); text-align: left; font-size: 12px; }
.asset-types-modal { width: min(680px, calc(100% - 32px)); }
.asset-types-body { padding: 21px; }
.inline-create { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin: 17px 0 12px; }
.inline-create input, .asset-types-table input, .asset-types-table select { width: 100%; min-height: 38px; padding: 7px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.asset-types-table { max-height: 330px; overflow-y: auto; }
.form-error { min-height: 20px; margin-top: 12px !important; color: var(--red) !important; }

.suggestion-dialog { width: min(650px, calc(100% - 32px)); }
.suggestion-dialog form { display: grid; gap: 14px; }
.suggestion-context { display: grid; gap: 3px; padding: 11px 13px; border-left: 3px solid var(--primary); background: var(--primary-soft); }
.suggestion-context span, .suggestion-detail-meta span { color: var(--muted); font-size: 12px; }
.checkbox-field.important-problem { display: flex; align-items: flex-start; gap: 10px; padding: 12px; border: 1px solid #efd3a5; background: #fff9ee; }
.important-problem input { width: 18px; height: 18px; accent-color: #d98b16; }
.important-problem span { display: grid; gap: 3px; }
.important-problem small { color: var(--muted); }
.attachment-picker { display: grid; gap: 8px; outline: none; }
.attachment-drop { display: grid; place-items: center; gap: 4px; min-height: 88px; padding: 15px; border: 1.5px dashed #9fb0c1; border-radius: 8px; color: var(--muted); background: var(--surface-soft); text-align: center; cursor: pointer; transition: .15s ease; }
.attachment-drop strong { color: var(--text); font-size: 14px; }
.attachment-drop span { font-size: 12px; }
.attachment-picker:hover .attachment-drop,.attachment-picker:focus .attachment-drop,.attachment-picker.drag-active .attachment-drop { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.attachment-list { display: grid; gap: 6px; }
.attachment-item { display: grid; grid-template-columns: 26px minmax(0,1fr) 30px; align-items: center; gap: 8px; padding: 8px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.attachment-item>span:nth-child(2) { display: grid; min-width: 0; gap: 2px; }
.attachment-item strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.attachment-item small { color: var(--muted); }
.attachment-file-icon { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 5px; color: var(--primary); background: var(--primary-soft); }
.attachment-item button { width: 28px; height: 28px; border: 0; border-radius: 4px; color: var(--muted); background: transparent; cursor: pointer; font-size: 18px; }
.attachment-item button:hover { color: var(--red); background: #faecee; }
.role-members-toggle { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px 8px; width: 100%; padding: 7px 8px; border: 0; border-radius: 5px; color: var(--text); background: transparent; text-align: left; cursor: pointer; }
.role-members-toggle:hover { background: var(--primary-soft); }
.role-members-toggle small { grid-column: 1; color: var(--muted); }
.role-members-toggle i { grid-column: 2; grid-row: 1 / 3; color: var(--primary); font-style: normal; }
.admin-members-row>td { padding: 0 !important; background: var(--surface-soft); }
.admin-members { padding: 14px 18px 16px 34px; border-bottom: 1px solid var(--line); }
.admin-members-heading { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 10px; }
.admin-members-heading>div:first-child { display: flex; align-items: center; gap: 7px; }
.admin-members-heading>div:first-child span { display: grid; place-items: center; min-width: 23px; height: 23px; border-radius: 12px; color: var(--primary); background: var(--primary-soft); font-size: 12px; }
.admin-member-add { display: flex; gap: 7px; }
.admin-member-add select { min-width: 270px; min-height: 37px; padding: 7px 9px; border: 1px solid var(--line); background: var(--surface); }
.admin-member-list { display: grid; grid-template-columns: repeat(2,minmax(230px,1fr)); gap: 7px; }
.admin-member-list>div { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 5px; background: var(--surface); }
.admin-member-list>div>span { display: grid; gap: 2px; }
.admin-member-list small { color: var(--muted); }
.assessment-suggestion-box { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; margin: 12px 0 18px; padding: 16px 18px; border: 1px solid var(--line); border-left: 3px solid var(--primary); border-radius: 10px; background: var(--primary-soft); }
.assessment-suggestion-copy strong { display: block; font-size: 15px; line-height: 1.4; color: var(--text); }
.assessment-suggestion-copy p { margin: 6px 0 0; font-size: 13px; line-height: 1.5; color: var(--muted); max-width: 65ch; }
.assessment-suggestion-box #assessment-suggestion { width: auto; max-width: 100%; min-height: 40px; padding: 10px 14px; text-align: left; white-space: normal; line-height: 1.4; color: var(--primary); background: var(--surface); border: 1px solid var(--primary); border-radius: 7px; }
.assessment-suggestion-box #assessment-suggestion:hover { background: var(--primary-soft); }
.suggestion-kpis { display: grid; grid-template-columns: repeat(4,minmax(130px,1fr)); gap: 10px; margin-bottom: 15px; }
.suggestion-kpis button { display: grid; gap: 5px; padding: 14px; text-align: left; border: 1px solid var(--line); background: var(--surface); cursor: pointer; }
.suggestion-kpis button:hover { border-color: var(--primary); }
.suggestion-kpis span { color: var(--muted); }
.suggestion-kpis strong { font-size: 25px; }
.suggestion-register { padding: 16px; }
.suggestion-filter-bar { display: flex; gap: 9px; align-items: center; margin-bottom: 16px; }
.suggestion-filter-bar select { min-width: 180px; min-height: 38px; padding: 7px 9px; border: 1px solid var(--line); background: var(--surface); }
.suggestions-list { display: grid; gap: 17px; }
.suggestion-process-group { border: 1px solid var(--line); }
.suggestion-process-group>header { display: flex; align-items: center; gap: 9px; padding: 11px 13px; background: var(--surface-soft); border-bottom: 1px solid var(--line); }
.suggestion-process-group h2 { margin: 0; font-size: 16px; }
.suggestion-process-group>header span { display: grid; place-items: center; min-width: 24px; height: 24px; border-radius: 12px; color: var(--primary); background: var(--primary-soft); font-size: 12px; }
.suggestion-table-head,.suggestion-row { display: grid; grid-template-columns: 80px minmax(220px,1.5fr) minmax(190px,1fr) 170px 115px; gap: 12px; align-items: center; padding: 10px 13px; }
.suggestion-table-head { color: var(--muted); font-size: 12px; font-weight: 650; border-bottom: 1px solid var(--line); }
.suggestion-row { width: 100%; color: inherit; text-align: left; border: 0; border-bottom: 1px solid var(--line); background: var(--surface); cursor: pointer; }
.suggestion-row:last-child { border-bottom: 0; }
.suggestion-row:hover { background: var(--surface-soft); }
.suggestion-row>span { min-width: 0; }
.suggestion-text,.suggestion-object,.suggestion-author { display: grid; gap: 4px; }
.suggestion-text strong,.suggestion-text small,.suggestion-object strong { min-width: 0; white-space: normal; overflow-wrap: anywhere; }
.suggestion-text small { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; line-height: 1.4; }
.document-context,.document-table td:nth-child(3) { min-width: 0; overflow-wrap: anywhere; }
.document-process,.document-zones { display: block; }
.document-process { line-height: 1.35; }
.document-zones { margin-top: 5px; padding-left: 10px; border-left: 2px solid #cfe2f2; color: var(--muted); line-height: 1.4; }
.suggestion-row small { color: var(--muted); }
.suggestion-number i { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; color: #fff; background: #d97706; font-style: normal; font-weight: 800; }
.suggestion-status { display: inline-flex; width: fit-content; padding: 4px 8px; border-radius: 12px; font-size: 12px; font-weight: 650; }
.status-new { color: #315d9d; background: #eaf2ff; }.status-accepted { color:#6b4f00;background:#fff3c4 }.status-in_progress { color:#82520a;background:#ffead0 }.status-rejected { color:#7b4450;background:#f8e8eb }.status-completed { color:#247047;background:#e4f5eb }
.suggestion-detail { width: min(780px, calc(100% - 32px)); }
.suggestion-detail-body { max-height: 88vh; overflow-y: auto; padding: 21px; }
.suggestion-detail-meta { display: grid; gap: 5px; margin: 15px 0; padding: 12px; background: var(--surface-soft); }
.important-banner { padding: 8px 11px; color: #8a5000; background: #fff3d8; border-left: 3px solid #d97706; font-weight: 700; }
.suggestion-copy { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 14px 0; }
.suggestion-copy>div { padding: 13px; border: 1px solid var(--line); }
.suggestion-copy span { color: var(--muted); font-size: 12px; }.suggestion-copy p { margin: 7px 0 0; white-space: pre-wrap; }
.suggestion-files,.suggestion-status-form,.suggestion-history { margin-top: 18px; padding-top: 15px; border-top: 1px solid var(--line); }
.suggestion-files h3,.suggestion-status-form h3,.suggestion-history h3 { margin: 0 0 10px; font-size: 15px; }
.suggestion-file { display: inline-block; margin-right: 12px; }
.suggestion-history ol { display: grid; gap: 12px; padding: 0; list-style: none; }
.suggestion-history li { display: grid; grid-template-columns: 100px 1fr; gap: 12px; }
.suggestion-history li div { display: grid; gap: 2px; }.suggestion-history p { margin: 4px 0 0; }.suggestion-history small,.suggestion-rights-note { color: var(--muted); }

.auth-page { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: linear-gradient(145deg,#eef4f8,#f8fafc 48%,#edf5fb); }
.auth-card { width: min(430px,100%); padding: 34px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); box-shadow: 0 18px 50px rgba(31,49,68,.12); }
.auth-link { display: block; width: fit-content; margin: 14px auto 8px; }
.reset-password-dialog { width: min(520px, calc(100% - 24px)); }
.reset-password-dialog form { display: grid; gap: 14px; padding: 22px; }
.auth-card>img { width: 50px; height: 50px; object-fit: contain; margin-bottom: 18px; }
.auth-card h1 { margin: 6px 0 8px; font-size: 25px; }.auth-card>p { margin: 0 0 22px; color: var(--muted); }
.auth-card form { display: grid; gap: 14px; }.auth-card input { width: 100%; min-height: 43px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 7px; }
.password-input { position: relative; display: block; }.password-input input { padding-right: 82px; }.password-input button { position: absolute; top: 50%; right: 8px; transform: translateY(-50%); padding: 5px 7px; border: 0; color: var(--primary); background: transparent; cursor: pointer; font-size: 12px; }
.account-state { display: flex; align-items: center; justify-content: space-between; gap: 15px; }.account-state>div { display: grid; gap: 3px; }.account-state span,.account-state small { color: var(--muted); }.account-state .danger { color: var(--red); border-color: #e7bec4; }
.account-access { min-width:220px; }.account-access select { min-height:38px; padding:7px 9px; border:1px solid var(--line); background:var(--surface); }.account-actions { display:flex; flex-wrap:wrap; gap:8px; margin-top:13px; padding-top:12px; border-top:1px solid var(--line); }.temporary-password { display:grid; grid-template-columns:1fr auto; gap:5px 12px; align-items:center; margin-top:12px; padding:11px 13px; border-left:3px solid #d49422; background:#fff8e8; }.temporary-password span { grid-column:1/-1; color:#76520f; font-size:12px; }.temporary-password strong { font-family:ui-monospace,SFMono-Regular,Consolas,monospace; font-size:15px; letter-spacing:.03em; }
.profile-grid { display:grid; grid-template-columns:minmax(0,1.15fr) minmax(320px,.85fr); gap:14px; align-items:start; }.profile-column { display:grid; gap:14px; align-content:start; min-width:0; }.profile-card { padding:20px; }.profile-card h2 { margin:0 0 8px; font-size:18px; }.profile-person { display:flex; align-items:center; gap:14px; padding-bottom:17px; border-bottom:1px solid var(--line); }.profile-person h2 { margin:0; font-size:21px; }.profile-person p { margin:4px 0 0; color:var(--muted); }.profile-large-avatar { display:grid; place-items:center; flex:none; width:54px; height:54px; border-radius:50%; color:var(--primary); background:var(--primary-soft); font-size:18px; font-weight:750; }.profile-details { display:grid; grid-template-columns:170px minmax(0,1fr); gap:10px 14px; margin:18px 0; }.profile-details dt { color:var(--muted); }.profile-details dd { margin:0; font-weight:600; overflow-wrap:anywhere; }.profile-form { display:grid; gap:12px; padding-top:16px; border-top:1px solid var(--line); }.profile-form input { width:100%; min-height:41px; padding:8px 10px; border:1px solid var(--line); border-radius:6px; }.profile-role-list { display:grid; gap:8px; margin-top:16px; }.profile-role-list>div { display:flex; justify-content:space-between; gap:12px; padding:10px 11px; border:1px solid var(--line); background:var(--surface-soft); }.profile-role-list span { color:var(--muted); font-size:12px; }.profile-security>.muted { margin:0; }.profile-session { display:flex; align-items:center; justify-content:space-between; gap:16px; margin-top:20px; padding-top:16px; border-top:1px solid var(--line); }.profile-session h3 { margin:0 0 3px; font-size:15px; }.profile-session p { margin:0; font-size:13px; }.profile-session .secondary-button { flex:none; white-space:nowrap; }.profile-button.active { box-shadow:inset 0 -2px var(--primary); }
.auth-submit { width: 100%; min-height: 43px; justify-content: center; }.auth-help,.password-hint { display: block; margin-top: 15px; color: var(--muted); line-height: 1.45; }
.login-remember { display: flex; align-items: flex-start; gap: 10px; cursor: pointer; color: var(--text); }
.auth-card .login-remember input { width: 17px; min-height: 17px; margin: 2px 0 0; accent-color: var(--primary); }
.login-remember span { display: grid; gap: 2px; }.login-remember small { color: var(--muted); line-height: 1.35; }
html[data-access-level="viewer"] .edit-current-entity,html[data-access-level="viewer"] .archive-current-entity,html[data-access-level="viewer"] .add-operation-action,html[data-access-level="viewer"] .add-asset-action { display:none !important; }
html:not([data-access-level="superuser"]) .employee-page .section-actions,html:not([data-access-level="superuser"]) .employee-table [data-edit] { display:none !important; }

.icon-database::before { content:"▤"; font-size:18px; }
.database-grid { display:grid; grid-template-columns:1fr 1fr; gap:14px; align-items:start; }
.database-card { display:flex; gap:16px; padding:20px; min-height:190px; }
.database-card h2 { margin:4px 0 8px; font-size:19px; }.database-card p { margin:0; color:var(--muted); line-height:1.5; }
.database-card-icon { display:grid; place-items:center; flex:0 0 48px; height:48px; border-radius:8px; color:#167047; background:#e1f3e9; font-size:13px; font-weight:800; }.database-card-icon.backup-icon { color:var(--primary); background:var(--primary-soft); font-size:25px; }.database-card-icon.documents-export-icon{color:#a33f48;background:#fdebed}
.database-action { display:inline-flex; margin-top:18px; text-decoration:none; }.database-wide { grid-column:1/-1; display:block; min-height:0; }.database-card-head { display:flex; align-items:flex-start; justify-content:space-between; gap:18px; }
.database-settings { display:grid; grid-template-columns:minmax(170px,1fr) 130px auto; align-items:end; gap:9px; margin-top:17px; }.database-settings select,.database-settings input { width:100%; min-height:39px; padding:7px 9px; border:1px solid var(--line); border-radius:6px; background:var(--surface); }
.backup-list { display:grid; margin-top:16px; border-top:1px solid var(--line); }.backup-row { display:flex; align-items:center; justify-content:space-between; gap:16px; padding:11px 3px; border-bottom:1px solid var(--line); }.backup-row>div { display:grid; gap:3px; }.backup-row span { color:var(--muted); font-size:12px; }
.restore-card { display:grid; grid-template-columns:minmax(260px,1fr) minmax(340px,1.3fr) auto; align-items:center; gap:18px; }.restore-drop { display:grid; place-items:center; min-height:100px; padding:15px; border:1.5px dashed #9fb0c1; border-radius:8px; background:var(--surface-soft); color:var(--muted); text-align:center; cursor:pointer; }.restore-drop strong { color:var(--text); }.restore-drop.drag-active { border-color:var(--primary); background:var(--primary-soft); }.restore-selection { grid-column:2; padding:8px 11px; color:var(--primary); background:var(--primary-soft); }.danger-button { min-height:39px; padding:8px 13px; border:1px solid #d79da5; border-radius:6px; color:#9c3444; background:#fff; cursor:pointer; }.danger-button:disabled { opacity:.45; cursor:default; }.database-message { min-height:22px; color:#247047; }.database-message.error { color:var(--red); }

@media (max-width: 900px) {
  .topbar { grid-template-columns: 1fr auto; }
  .global-search-shell { grid-column: 1 / -1; grid-row: 2; }
  .app-body { grid-template-columns: 1fr; }
  .app-shell.sidebar-collapsed .app-body { grid-template-columns: 1fr; }
  .sidebar { border-right: 0; border-bottom: 1px solid var(--line); padding: 8px 12px; }
  .app-shell.sidebar-collapsed .sidebar { display: none; }
  .nav-list { grid-template-columns: repeat(auto-fit, minmax(44px, 1fr)); }
  .nav-section-title { display:none; }
  .nav-list a { justify-content: center; padding: 8px; }
  .nav-list a span:last-child { display: none; }
  .asset-kpis { grid-template-columns: repeat(4, minmax(110px, 1fr)); }
  .asset-overview-grid { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  .topbar { padding: 10px 12px; }
  .profile-name { display: none; }
  .workspace { padding: 15px 10px; }
  .page-heading { display: grid; }
  .model-surface { grid-template-columns: 1fr; }
  .tree-pane { border-right: 0; border-bottom: 1px solid var(--line); }
  .pane-resizer { display: none; }
  .asset-grid { grid-template-columns: 1fr; }
  .responsibility-matrix { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .responsibility-matrix.responsibility-count-1 { grid-template-columns: 1fr; }
  .responsibility-matrix.responsibility-count-3 .responsibility-item:last-child { grid-column: 1 / -1; }
  .responsibility-matrix .responsibility-item { border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
  .responsibility-matrix .responsibility-item:nth-child(2n),
  .responsibility-matrix .responsibility-item:last-child { border-right: 0; }
  .responsibility-matrix .responsibility-item:nth-last-child(-n + 2) { border-bottom: 0; }
  .responsibility-matrix.responsibility-count-1 .responsibility-item,
  .responsibility-matrix.responsibility-count-3 .responsibility-item:last-child { border-right: 0; border-bottom: 0; }
  .responsibility-matrix.responsibility-count-3 .responsibility-item:nth-child(2) { border-bottom: 1px solid var(--line); }
  .control-summary { grid-template-columns: 1fr; }
  .role-highlights { grid-template-columns: 1fr; }
  .form-columns { grid-template-columns: 1fr; }
  .operation-role-grid { grid-template-columns: 1fr; }
  .full-operation-card dl { grid-template-columns: 1fr; }
  .asset-kpis { grid-template-columns: repeat(2, minmax(110px, 1fr)); }
  .asset-filter-bar { grid-template-columns: 1fr; }
  .asset-dashboard-detail { width: 100%; }
  .database-grid { grid-template-columns:1fr; }.database-wide { grid-column:auto; }.database-settings,.restore-card { grid-template-columns:1fr; }.restore-selection { grid-column:auto; }
}

/* Mobile and foldable layout: touch-first without changing the desktop workspace. */
@media (max-width: 950px) {
  body { overflow-x: hidden; }
  .topbar { position: sticky; top: 0; z-index: 30; gap: 8px 12px; min-height: 60px; padding: 8px 12px; }
  .brand { min-width: 0; font-size: 14px; }
  .brand span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .brand-logo { width: 34px; height: 34px; }
  .global-search, .global-search-shell { min-width: 0; width: 100%; }
  .global-search input { height: 40px; font-size: 16px; }
  .profile-button { min-width: 42px; min-height: 42px; justify-content: flex-end; }
  .sidebar { position: sticky; top: 60px; z-index: 25; padding: 6px 8px; overflow: hidden; background: var(--surface); }
  .nav-list { display: flex; gap: 5px; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; }
  .nav-list::-webkit-scrollbar { display: none; }
  .nav-list a { flex: 0 0 auto; min-width: 48px; min-height: 46px; transform: none; }
  .nav-list a.active::after { top: auto; right: 9px; bottom: -7px; left: 9px; width: auto; height: 3px; border-radius: 3px 3px 0 0; }
  .workspace { width: 100%; padding: 14px 12px; }
  .page-heading { gap: 12px; }
  .page-heading h1 { font-size: 22px; overflow-wrap: anywhere; }
  .page-heading p { font-size: 13px; line-height: 1.4; }
  .heading-actions, .section-actions, .section-inline-actions { justify-content: flex-start; }
  .button, .secondary-button, .primary-button, .filter-chip, .text-button, select { min-height: 42px; }
  .directory-surface, .dashboard-panel, .control-surface, .suggestion-register { min-width: 0; }
  .table-wrapper { max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; }
  .table-wrapper table { width: max-content; min-width: 100%; }
  .table-wrapper th:first-child, .table-wrapper td:first-child { position: sticky; left: 0; z-index: 1; background: var(--surface); box-shadow: 1px 0 0 var(--line); }
  .table-wrapper th:first-child { z-index: 2; background: var(--surface-soft); }
  .modal, .control-dialog, .document-modal, .suggestion-dialog, .suggestion-detail,
  .employee-modal, .roles-modal, .departments-modal, .asset-settings-dialog {
    width: min(100% - 16px, 760px); max-width: calc(100% - 16px); max-height: calc(100dvh - 16px); margin: auto;
  }
  .modal form, .control-dialog form, .asset-settings-dialog form { padding: 16px; }
  .modal-heading { position: sticky; top: 0; z-index: 4; padding-bottom: 10px; background: var(--surface); }
  .modal-actions { position: sticky; bottom: 0; z-index: 4; margin: 16px -16px -16px; padding: 12px 16px; border-top: 1px solid var(--line); background: var(--surface); }
  .asset-grid, .document-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .asset-register-table { display: none; }
  .asset-mobile-register { display: grid; gap: 18px; }
  .asset-mobile-process { min-width: 0; }
  .asset-mobile-process > header { display: flex; align-items: center; gap: 9px; margin-bottom: 9px; padding: 9px 11px; border-left: 3px solid var(--primary); background: var(--surface-soft); }
  .asset-mobile-process > header h3 { min-width: 0; margin: 0; font-size: 16px; overflow-wrap: anywhere; }
  .asset-mobile-process > header span { display: grid; place-items: center; min-width: 24px; height: 24px; border-radius: 12px; color: var(--primary); background: var(--primary-soft); font-size: 12px; }
  .asset-mobile-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .asset-mobile-card { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); cursor: pointer; }
  .asset-mobile-card:active { background: var(--surface-soft); }
  .asset-mobile-card header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
  .asset-mobile-card header > div { min-width: 0; }
  .asset-mobile-card header > div > span { color: var(--muted); font-size: 11px; }
  .asset-mobile-card h3 { margin: 3px 0 0; font-size: 16px; line-height: 1.3; overflow-wrap: anywhere; }
  .asset-mobile-card .star-rating { flex: 0 0 auto; }
  .asset-mobile-zones { margin: 10px 0; color: var(--muted); font-size: 12px; line-height: 1.4; overflow-wrap: anywhere; }
  .asset-mobile-card dl { display: grid; grid-template-columns: 1fr 1fr; gap: 9px 12px; margin: 0; padding-top: 10px; border-top: 1px solid var(--line); }
  .asset-mobile-card dl div { min-width: 0; }
  .asset-mobile-card dt { color: var(--muted); font-size: 10px; font-weight: 700; text-transform: uppercase; }
  .asset-mobile-card dd { margin: 3px 0 0; font-size: 12px; line-height: 1.35; overflow-wrap: anywhere; }
  html[data-mobile-readonly] .asset-view-switch { display: none !important; }
  html[data-mobile-readonly] #document-cards, html[data-mobile-readonly] .document-grid { display: grid !important; }
  html[data-mobile-readonly] #document-table, html[data-mobile-readonly] .documents-section .table-wrapper { display: none !important; }

  /* На мобильном ответственность читается как карточки, а не как широкая таблица. */
  .responsibility-page .table-wrapper { overflow: visible; }
  .responsibility-table, .responsibility-table tbody { display: block; width: 100%; }
  .responsibility-table thead { display: none; }
  .responsibility-group-row { display: block; margin-top: 12px; }
  .responsibility-group-row:first-child { margin-top: 0; }
  .responsibility-group-row th { position: static !important; display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 10px 12px; box-shadow: none !important; background: var(--surface-soft); }
  .responsibility-item-row { display: grid; gap: 10px; margin: 8px 0; padding: 14px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); }
  .responsibility-item-row td { position: static !important; display: grid; min-width: 0 !important; padding: 0; border: 0; box-shadow: none !important; background: transparent !important; line-height: 1.45; overflow-wrap: anywhere; }
  .responsibility-item-row td::before { margin-bottom: 3px; color: var(--muted); font-size: 11px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
  .responsibility-item-row td:nth-child(2)::before { content: "Расположение"; }
  .responsibility-item-row td:nth-child(3)::before { content: "Описание / результат"; }
  .responsibility-item-row td:nth-child(4)::before { content: "Роли"; }
  .responsibility-role-list { display: flex; flex-wrap: wrap; gap: 6px; }

  /* Справочник сотрудников: подразделение остаётся заголовком, сотрудник становится карточкой. */
  .employee-table, .employee-table tbody { display: block; width: 100%; }
  .employee-table thead { display: none; }
  .employee-page .table-wrapper, .employee-table.closest-table { overflow: visible; }
  .department-group { display: block; margin-top: 12px; }
  .department-group:first-child { margin-top: 0; }
  .department-group td { position: static !important; display: flex; flex-wrap: wrap; gap: 5px 10px; align-items: center; width: 100%; padding: 11px 12px; box-shadow: none !important; background: var(--surface-soft) !important; }
  .department-group td > span:not(.group-chevron) { flex: 1 1 100%; padding-left: 20px; }
  .employee-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 12px; margin: 8px 0; padding: 14px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); }
  .employee-row td { position: static !important; display: block; min-width: 0 !important; padding: 0; border: 0; box-shadow: none !important; background: transparent !important; overflow-wrap: anywhere; }
  .employee-row td:first-child { grid-column: 1; }
  .employee-row td:nth-child(2), .employee-row td:nth-child(3), .employee-row td:nth-child(4) { grid-column: 1 / -1; }
  .employee-row td:nth-child(5) { grid-column: 2; grid-row: 1; }
  .employee-row td:last-child { display: none !important; }
  .employee-row td:nth-child(2)::before, .employee-row td:nth-child(3)::before, .employee-row td:nth-child(4)::before { display: block; margin-bottom: 4px; color: var(--muted); font-size: 11px; font-weight: 700; text-transform: uppercase; }
  .employee-row td:nth-child(2)::before { content: "Должность"; }
  .employee-row td:nth-child(3)::before { content: "Функциональные роли"; }
  .employee-row td:nth-child(4)::before { content: "Телефон"; }
  .employee-row .role-tags { display: flex; flex-wrap: wrap; gap: 5px; }
  .role-create-grid, .department-create-grid { grid-template-columns: 1fr; }
  .profile-grid { grid-template-columns: 1fr; }
  .profile-session { align-items:stretch; flex-direction:column; }.profile-session .secondary-button { width:100%; justify-content:center; }
  .suggestion-kpis { grid-template-columns: repeat(2, minmax(120px, 1fr)); }
  .suggestion-table-head { display: none; }
  .suggestion-row { grid-template-columns: 72px minmax(0, 1fr) auto; gap: 8px 10px; align-items: start; padding: 13px; }
  .suggestion-row .suggestion-object, .suggestion-row .suggestion-author { grid-column: 2 / -1; }
  .suggestion-copy { grid-template-columns: 1fr; }
  .suggestion-history li { grid-template-columns: 1fr; gap: 4px; }
  .mobile-readonly-notice { width: fit-content; margin: 0 0 10px; padding: 5px 9px; border: 1px solid #cfdce7; border-radius: 999px; background: #f4f8fb; color: #587084; font-size: 11px; font-weight: 650; }
  html[data-mobile-readonly] .tree-add-button,
  html[data-mobile-readonly] .edit-current-entity,
  html[data-mobile-readonly] .archive-current-entity,
  html[data-mobile-readonly] .add-category-process,
  html[data-mobile-readonly] .add-zone,
  html[data-mobile-readonly] .add-operation,
  html[data-mobile-readonly] .add-asset,
  html[data-mobile-readonly] .edit-operation,
  html[data-mobile-readonly] .edit-responsibilities,
  html[data-mobile-readonly] .modal-edit-operation,
  html[data-mobile-readonly] .modal-edit-roles,
  html[data-mobile-readonly] .suggestion-action,
  html[data-mobile-readonly] [data-suggestion-entity],
  html[data-mobile-readonly] .assess-control-asset,
  html[data-mobile-readonly] .schedule-control-asset,
  html[data-mobile-readonly] #unplanned-assessment,
  html[data-mobile-readonly] #add-document,
  html[data-mobile-readonly] [data-edit-document],
  html[data-mobile-readonly] [data-archive-document],
  html[data-mobile-readonly] .shared-edit-document,
  html[data-mobile-readonly] .shared-archive-document,
  html[data-mobile-readonly] .archive-dashboard-asset,
  html[data-mobile-readonly] a[href*="edit=1"],
  html[data-mobile-readonly] a[href*="schedule=1"],
  html[data-mobile-readonly] a[href*="unplanned=1"],
  html[data-mobile-readonly] a[href*="add=1"],
  html[data-mobile-readonly] #add-employee,
  html[data-mobile-readonly] #manage-departments,
  html[data-mobile-readonly] #manage-roles,
  html[data-mobile-readonly] [data-edit],
  html[data-mobile-readonly] .restore-entity,
  html[data-mobile-readonly] .force-unlock,
  html[data-mobile-readonly] .suggestion-status-form,
  html[data-mobile-readonly] #phone-form,
  html[data-mobile-readonly] #profile-password-form { display: none !important; }
  html[data-mobile-readonly] [draggable="true"] { -webkit-user-drag: none; user-select: text; cursor: pointer; }
}

/* Galaxy Z Fold inner display / small tablets. */
@media (min-width: 701px) and (max-width: 950px) {
  .workspace { padding: 12px 10px; }
  .model-surface { --tree-pane-width: 35%; grid-template-columns: minmax(235px, var(--tree-pane-width)) 6px minmax(0, 1fr); }
  .tree-pane { padding: 10px 7px 16px; }
  .detail-pane { padding: 17px; }
  .detail-pane h2 { font-size: 20px; }
  .asset-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .responsibility-matrix { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .responsibility-matrix.responsibility-count-1 { grid-template-columns: 1fr; }
  .responsibility-matrix.responsibility-count-3 .responsibility-item:last-child { grid-column: 1 / -1; }
  .asset-filter-bar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Phones and the Galaxy Z Fold cover display. */
@media (max-width: 700px) {
  .topbar { grid-template-columns: minmax(0, 1fr) auto; }
  .topbar > .global-search { grid-column: 1 / -1; grid-row: 2; }
  .brand { font-size: 13px; }
  .avatar { width: 34px; height: 34px; }
  .sidebar { top: 102px; }
  .nav-list a { padding: 8px 12px; }
  .workspace { padding: 10px 8px 18px; }
  .page-heading { margin-bottom: 12px; }
  .page-title-row { gap: 8px; }
  .menu-toggle { width: 42px; height: 42px; }
  .model-surface { min-height: 0; border-right: 0; border-left: 0; }
  .tree-pane { max-height: 46dvh; padding: 8px 6px 12px; overflow-y: auto; overscroll-behavior: contain; }
  .detail-pane { padding: 15px 10px 22px; }
  .detail-heading { display: grid; gap: 12px; padding-bottom: 14px; }
  .detail-pane h2 { font-size: 20px; }
  .breadcrumbs { gap: 5px; margin-bottom: 10px; font-size: 12px; }
  .entity-actions { justify-content: flex-start; }
  .section-heading { align-items: flex-start; flex-direction: column; }
  .section-actions { width: 100%; }
  .target-state { padding: 12px; }
  .asset-grid, .document-grid { grid-template-columns: 1fr; }
  .asset-mobile-grid { grid-template-columns: 1fr; }
  .asset-card { min-height: 0; }
  .responsibility-matrix,
  .responsibility-matrix.responsibility-count-2,
  .responsibility-matrix.responsibility-count-3,
  .responsibility-matrix.responsibility-count-4,
  .asset-dashboard-detail .responsibility-matrix { grid-template-columns: 1fr; }
  .responsibility-matrix .responsibility-item { border-right: 0; border-bottom: 1px solid var(--line); }
  .responsibility-matrix .responsibility-item:last-child { border-bottom: 0; }
  .responsibility-matrix.responsibility-count-3 .responsibility-item:last-child { grid-column: auto; }
  .asset-kpis { display: flex; gap: 8px; padding-bottom: 4px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity; }
  .asset-kpi { flex: 0 0 132px; scroll-snap-align: start; }
  .asset-filter-bar { grid-template-columns: 1fr; }
  .control-summary-cards { display: flex; overflow-x: auto; }
  .control-summary-cards button { flex: 0 0 140px; }
  .control-toolbar, .control-filters { width: 100%; }
  .control-tabs, .role-filter { max-width: 100%; overflow-x: auto; white-space: nowrap; }
  .control-filters { display: grid; grid-template-columns: 1fr; }
  .control-filters select { min-width: 0; width: 100%; }
  .control-asset-main { grid-template-columns: 1fr; }
  .control-asset-meta { align-items: flex-start; flex-direction: column; gap: 5px; }
  .control-card-actions { justify-content: flex-start; flex-wrap: wrap; }
  .assessment-stars { flex-wrap: wrap; }
  .rating-divider { display: none; }
  .assessment-suggestion-box { align-items: flex-start; flex-direction: column; }
  .profile-card { padding: 15px; }
  .profile-details { grid-template-columns: 1fr; gap: 4px; }
  .profile-details dd { margin-bottom: 8px; overflow-wrap: anywhere; }
  .database-card-head, .backup-row, .account-state { align-items: flex-start; flex-direction: column; }
  .auth-page { padding: 12px; }
  .auth-card { width: 100%; padding: 20px 16px; }
}

/* Narrow cover screens, including Fold 5+ outer displays. */
@media (max-width: 420px) {
  .brand span { max-width: 190px; }
  .topbar { padding-inline: 8px; }
  .global-search input { padding-right: 10px; }
  .sidebar { padding-inline: 5px; }
  .nav-list a { min-width: 46px; padding-inline: 11px; }
  .workspace { padding-inline: 6px; }
  .page-heading h1 { font-size: 20px; }
  .page-heading .button, .page-heading .secondary-button, .page-heading .primary-button { width: 100%; }
  .modal, .control-dialog, .document-modal, .suggestion-dialog, .suggestion-detail,
  .employee-modal, .roles-modal, .departments-modal, .asset-settings-dialog,
  .asset-dashboard-detail { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0; border: 0; border-radius: 0; }
  .asset-detail-shell, .suggestion-detail-body, .roles-modal-body, .departments-modal-body { padding: 14px 12px 22px; }
  .modal-actions { flex-direction: column-reverse; }
  .modal-actions .button, .modal-actions button { width: 100%; }
  .suggestion-kpis { grid-template-columns: 1fr 1fr; }
  .suggestion-row { grid-template-columns: 58px minmax(0, 1fr); }
  .suggestion-row > :not(.suggestion-number) { grid-column: 2; }
  .star { font-size: 16px; }
  th, td { padding: 9px 8px; }
}
.assessment-guidance { margin: 2px 0 12px; font-size: 13px; }
.assessment-guidance summary { display: flex; align-items: center; gap: 7px; width: fit-content; min-height: 32px; color: var(--primary); cursor: pointer; list-style: none; }
.assessment-guidance summary::-webkit-details-marker { display: none; }
.assessment-guidance summary>span { display: inline-grid; place-items: center; width: 19px; height: 19px; border: 1px solid currentColor; border-radius: 50%; font-weight: 700; }
.assessment-guidance summary:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 4px; }
.assessment-guidance[open]>div { margin-top: 5px; padding: 12px 14px; border-left: 3px solid var(--primary); background: var(--primary-soft); line-height: 1.5; }
.assessment-guidance p { margin: 0 0 8px; }.assessment-guidance p:last-child { margin-bottom: 0; }
#assessment-dialog .modal-heading>[data-assessment-close] { flex: 0 0 34px; align-self: flex-start; width: 34px; height: 34px; min-height: 34px; padding: 0; }
.attachment-item.attachment-item-image { grid-template-columns: minmax(0,1fr) 30px; }
.attachment-preview { grid-column: 1 / -1; display: block; width: 100%; max-height: 220px; object-fit: contain; border: 1px solid var(--line); border-radius: 8px; background: #f7f9fc; }
