:root {
  color-scheme: dark;
  --bg: #090d13;
  --bg-deep: #030405;
  --panel: #111720;
  --panel-soft: #17212a;
  --ink: #f7fafc;
  --muted: #9aabc1;
  --line: rgba(255, 255, 255, 0.12);
  --accent: #d6b36a;
  --accent-strong: #f0ca78;
  --cyan: #24c6dc;
  --soft: rgba(214, 179, 106, 0.12);
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.34);
  --site-header-height: 94px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100dvh;
  background:
    radial-gradient(circle at 18% 0%, rgba(36, 198, 220, 0.16), transparent 30%),
    linear-gradient(145deg, var(--bg-deep), var(--bg) 48%, #111923);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent 70%);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 78px;
  border-bottom: 1px solid var(--line);
  background: rgba(3, 7, 13, 0.84);
  backdrop-filter: blur(18px);
  padding: 12px clamp(18px, 4vw, 54px);
}

.brand {
  display: inline-flex;
  align-items: center;
  color: var(--ink);
  font-weight: 800;
  font-size: 1.05rem;
  text-decoration: none;
  text-transform: uppercase;
}

.brand img {
  width: clamp(150px, 16vw, 220px);
  height: auto;
  object-fit: contain;
}

.header-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.header-nav a {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
}

.header-nav a:hover,
.header-nav a.active {
  color: var(--accent-strong);
}

.nav-image-link {
  isolation: isolate;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: clamp(108px, 7.4vw, 134px);
  height: 42px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(14, 21, 32, 0.96), rgba(4, 8, 14, 0.98)),
    radial-gradient(circle at 86% 16%, rgba(214, 179, 106, 0.18), transparent 34%);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.18);
  color: var(--ink);
  padding: 0 18px;
  transition: border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.nav-image-link::before,
.nav-image-link::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.nav-image-link::before {
  background:
    linear-gradient(135deg, transparent 0 58%, rgba(255, 255, 255, 0.06) 58% 63%, transparent 63%),
    linear-gradient(135deg, transparent 0 72%, rgba(214, 179, 106, 0.12) 72% 75%, transparent 75%);
  opacity: 0.72;
}

.nav-image-link::after {
  border-radius: inherit;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), inset 0 -22px 32px rgba(0, 0, 0, 0.24);
}

.nav-image-link span {
  position: relative;
  z-index: 1;
  color: currentColor;
  font-size: 0.84rem;
  font-weight: 900;
  line-height: 1;
  overflow: visible;
  text-align: center;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.54);
  text-transform: uppercase;
  white-space: nowrap;
}

.nav-image-button {
  appearance: none;
  cursor: pointer;
  font: inherit;
  padding: 0 18px;
}

.passwords-menu {
  position: relative;
}

.passwords-menu::after {
  content: "";
  position: absolute;
  right: 0;
  top: 100%;
  width: 100%;
  height: 12px;
}

.passwords-trigger {
  min-width: clamp(108px, 7.4vw, 134px);
}

.passwords-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 20;
  display: grid;
  gap: 8px;
  min-width: 170px;
  overflow: hidden;
  border: 1px solid rgba(214, 179, 106, 0.26);
  border-radius: 8px;
  background: rgba(6, 10, 16, 0.98);
  box-shadow: var(--shadow);
  max-height: 0;
  opacity: 0;
  padding: 0 8px;
  pointer-events: none;
  transform: translateY(-8px);
  transition: max-height 180ms ease, opacity 160ms ease, padding 160ms ease, transform 160ms ease;
}

.passwords-menu:hover .passwords-dropdown,
.passwords-menu:focus-within .passwords-dropdown,
.passwords-menu.is-open .passwords-dropdown {
  max-height: 190px;
  opacity: 1;
  padding: 8px;
  pointer-events: auto;
  transform: translateY(0);
}

.passwords-menu.force-closed .passwords-dropdown {
  max-height: 0;
  opacity: 0;
  padding: 0 8px;
  pointer-events: none;
  transform: translateY(-8px);
}

.passwords-dropdown .nav-image-link {
  width: 100%;
  min-width: 146px;
  height: 38px;
}

.nav-image-link:hover,
.nav-image-link.active {
  border-color: rgba(214, 179, 106, 0.68);
  color: var(--accent-strong);
  box-shadow: 0 14px 34px rgba(214, 179, 106, 0.1);
  transform: translateY(-1px);
}

.nav-button {
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 700;
  padding: 0;
}

.nav-button:hover {
  color: var(--accent-strong);
}

.app-shell {
  min-height: calc(100dvh - var(--site-header-height));
}

.app-page {
  display: none;
}

.app-page.active {
  display: block;
}

.workspace {
  display: grid;
  gap: 24px;
  margin: 0 auto;
  max-width: 1360px;
  padding: 34px clamp(18px, 4vw, 54px) 54px;
}

#home .workspace {
  align-content: center;
  min-height: calc(100dvh - var(--site-header-height));
  padding-top: 18px;
  padding-bottom: 18px;
}

.hero-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(230px, 330px);
  gap: 28px;
  min-height: 255px;
  overflow: hidden;
  position: relative;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(120deg, rgba(17, 23, 32, 0.96), rgba(3, 4, 5, 0.9)),
    linear-gradient(90deg, transparent, rgba(214, 179, 106, 0.16));
  box-shadow: var(--shadow);
  padding: clamp(26px, 5vw, 54px);
}

.hero-panel::after {
  content: "LH7";
  position: absolute;
  right: -20px;
  bottom: -54px;
  color: rgba(255, 255, 255, 0.035);
  font-size: clamp(7rem, 18vw, 16rem);
  font-weight: 900;
  line-height: 1;
}

.remote-hero::after {
  content: "RDP";
}

.sicom-hero::after {
  content: "SICOM";
}

.etce-hero::after {
  content: "E-TCE";
}

.crj-hero::after {
  content: "CRJ";
}

.admin-hero::after {
  content: "CONTROLE";
  font-size: clamp(5rem, 14vw, 12rem);
}

.home-hero::after {
  content: none;
}

.home-hero {
  grid-template-columns: 1fr;
  min-height: 330px;
  place-items: center;
}

.home-hero .hero-copy {
  width: min(100%, 1100px);
  max-width: 1100px;
}

.remote-hero .hero-copy h1 {
  font-size: clamp(2.8rem, 6vw, 4.9rem);
  line-height: 1;
}

.remote-helper-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  max-width: 760px;
  margin-top: 30px;
  border: 1px solid rgba(214, 179, 106, 0.24);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  padding: 14px;
}

.remote-helper-card div {
  display: grid;
  gap: 4px;
}

.remote-helper-card strong {
  color: var(--accent-strong);
  font-size: 0.9rem;
}

.remote-helper-card span {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.45;
}

.remote-helper-download {
  flex: 0 0 auto;
  min-width: 160px;
  min-height: 40px;
}

#admin .admin-hero .hero-copy h1 {
  font-size: clamp(2.55rem, 6.2vw, 5.45rem);
}

.hero-copy,
.hero-status {
  position: relative;
  z-index: 1;
}

.hero-copy h1 {
  margin: 0 0 16px;
  font-size: clamp(2.8rem, 8vw, 6.4rem);
  font-weight: 900;
  letter-spacing: 0;
  line-height: 0.9;
  text-transform: uppercase;
}

.home-tech-art {
  display: block;
  width: min(100%, 1040px);
  aspect-ratio: 5.3 / 1;
  border: 1px solid rgba(214, 179, 106, 0.32);
  border-radius: 8px;
  box-shadow: 0 20px 58px rgba(0, 0, 0, 0.28);
  margin: 8px auto 20px;
  object-fit: cover;
  object-position: center;
}

.home-hero .hero-copy > .eyebrow,
.home-hero .hero-copy > p:last-child {
  width: min(100%, 1040px);
  margin-left: auto;
  margin-right: auto;
}

.hero-copy .hero-text,
.hero-copy p:last-child {
  max-width: 720px;
  color: var(--muted);
  font-size: 1.04rem;
  line-height: 1.65;
}

.home-hero .hero-copy > p:last-child {
  max-width: none;
  white-space: nowrap;
}

.hero-status {
  align-self: end;
  display: grid;
  gap: 8px;
  border-left: 3px solid var(--accent);
  background: rgba(255, 255, 255, 0.045);
  padding: 18px;
}

.hero-art-card {
  align-self: stretch;
  align-content: center;
  justify-items: center;
  min-height: 215px;
  border-left: 0;
  border-top: 3px solid var(--accent);
  padding: clamp(24px, 3vw, 34px);
  text-align: center;
}

.hero-status strong {
  font-size: clamp(1.3rem, 2vw, 1.7rem);
  line-height: 1.15;
}

.hero-status small {
  color: var(--muted);
  font-size: 0.96rem;
  font-weight: 700;
  line-height: 1.35;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent-strong);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h2 {
  margin-bottom: 0;
  font-size: 1.25rem;
}

h3 {
  margin-bottom: 10px;
  font-size: 1.1rem;
}

.tool-layout {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.home-access {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 360px);
  gap: 22px;
  align-items: stretch;
}

.home-copy-panel,
.home-auth-actions {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(17, 23, 32, 0.86);
  box-shadow: var(--shadow);
  padding: 24px;
}

.home-copy-panel p:last-child {
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 0;
}

.home-auth-actions {
  display: grid;
  gap: 12px;
  align-content: center;
}

.tool-sidebar,
.tool-panel,
.result-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(17, 23, 32, 0.86);
  box-shadow: var(--shadow);
}

.tool-sidebar {
  position: sticky;
  top: 100px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  gap: 18px;
  max-height: calc(100vh - 124px);
  overflow: hidden;
  padding: 20px;
}

.tool-nav {
  display: grid;
  gap: 10px;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 8px;
  scrollbar-color: rgba(214, 179, 106, 0.7) rgba(255, 255, 255, 0.06);
  scrollbar-width: thin;
}

.tool-tab {
  display: grid;
  gap: 4px;
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--ink);
  cursor: pointer;
  padding: 13px 14px;
  text-align: left;
  font: inherit;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.tool-tab:hover {
  border-color: rgba(214, 179, 106, 0.45);
  transform: translateY(-1px);
}

.tool-tab span {
  color: var(--accent-strong);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.tool-tab strong {
  font-size: 0.92rem;
}

.tool-tab.active {
  border-color: rgba(214, 179, 106, 0.75);
  background: linear-gradient(135deg, rgba(214, 179, 106, 0.18), rgba(36, 198, 220, 0.1));
}

.tool-stack {
  display: grid;
  gap: 24px;
}

.tool-panel {
  display: grid;
  grid-template-columns: minmax(230px, 0.72fr) minmax(340px, 1.28fr);
  gap: 24px;
  padding: 24px;
}

.tool-copy p {
  color: var(--muted);
  line-height: 1.6;
}

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

.file-drop {
  display: grid;
  gap: 10px;
  min-height: 112px;
  border: 1px dashed rgba(214, 179, 106, 0.45);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  padding: 16px;
}

.file-drop.is-dragover {
  border-color: rgba(36, 198, 220, 0.75);
  background: rgba(36, 198, 220, 0.08);
}

.file-drop.wide,
.input-field {
  grid-column: 1 / -1;
}

.file-drop span,
.input-field span {
  font-weight: 800;
}

input[type="file"],
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="date"],
select {
  width: 100%;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="date"],
select {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(3, 7, 13, 0.62);
  color: var(--ink);
  font: inherit;
  padding: 0 12px;
}

input[type="file"] {
  color: var(--muted);
}

input::file-selector-button {
  border: 0;
  border-radius: 6px;
  background: var(--accent);
  color: #111827;
  cursor: pointer;
  font-weight: 800;
  margin-right: 10px;
  padding: 9px 12px;
}

.folder-picker-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.folder-picker-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  border: 0;
  border-radius: 6px;
  background: var(--accent);
  color: #111827;
  cursor: pointer;
  font-weight: 900;
  padding: 9px 14px;
}

.folder-picker-button:hover {
  background: var(--accent-strong);
}

.folder-picker-status {
  color: #b6c9e6;
  font-size: 0.88rem;
  font-weight: 700;
}

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

.input-field {
  display: grid;
  gap: 8px;
}

.field-help {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.45;
}

.pdf-merge-toolbar {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
  font-weight: 800;
  padding: 12px;
}

.pdf-merge-list {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 14px;
}

.pdf-merge-card {
  position: relative;
  display: grid;
  gap: 12px;
  min-height: 300px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.025));
  cursor: grab;
  padding: 14px;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.pdf-merge-card.dragging {
  opacity: 0.58;
}

.pdf-merge-card.drag-over,
.pdf-merge-card:hover {
  border-color: rgba(214, 179, 106, 0.65);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.2);
  transform: translateY(-1px);
}

.pdf-merge-preview {
  height: 160px;
  overflow: hidden;
  border: 1px solid rgba(214, 179, 106, 0.28);
  border-radius: 8px;
  background: rgba(3, 7, 13, 0.78);
}

.pdf-merge-preview iframe {
  width: 100%;
  height: 220px;
  border: 0;
  background: #fff;
  transform: translateY(-6px);
}

.pdf-order {
  position: absolute;
  top: 24px;
  left: 24px;
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(214, 179, 106, 0.7);
  border-radius: 999px;
  background: rgba(3, 7, 13, 0.88);
  color: var(--accent-strong);
  font-weight: 900;
}

.pdf-merge-meta {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.pdf-merge-meta strong,
.pdf-merge-meta small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pdf-merge-meta small {
  color: var(--muted);
  font-weight: 700;
}

.pdf-merge-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.pdf-merge-actions .secondary-button {
  min-height: 38px;
  padding: 0 10px;
}

.merge-order-help {
  grid-column: 1 / -1;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  grid-column: 1 / -1;
  gap: 12px;
  justify-content: flex-end;
  padding-top: 4px;
}

.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 8px;
  padding: 0 20px;
  font: inherit;
  font-weight: 900;
  text-decoration: none;
}

.primary-button {
  border: 1px solid var(--accent);
  background: linear-gradient(135deg, var(--accent-strong), var(--accent));
  color: #07111f;
  cursor: pointer;
}

.primary-button:disabled {
  cursor: wait;
  opacity: 0.72;
}

.secondary-button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.secondary-button {
  border: 1px solid rgba(214, 179, 106, 0.45);
  background: rgba(255, 255, 255, 0.04);
  color: var(--accent-strong);
}

.status-pill {
  justify-self: start;
  border: 1px solid rgba(36, 198, 220, 0.45);
  border-radius: 999px;
  background: rgba(36, 198, 220, 0.12);
  color: #a8f4ff;
  font-size: 0.82rem;
  font-weight: 900;
  padding: 8px 12px;
  text-align: center;
}

.hero-art-card .status-pill {
  justify-self: center;
  font-size: 0.92rem;
  padding: 10px 16px;
}

.hidden {
  display: none !important;
}

.result-panel {
  display: grid;
  gap: 18px;
  padding: 24px;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 10px;
}

.summary-item {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  padding: 12px;
}

.summary-item strong {
  display: block;
  color: var(--ink);
  font-size: 1.12rem;
  overflow-wrap: anywhere;
}

.summary-item span {
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.log-output {
  max-height: 260px;
  overflow: auto;
  border: 1px solid rgba(36, 198, 220, 0.22);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.36);
  color: #d7e4f5;
  font-size: 0.8rem;
  line-height: 1.45;
  margin: 0;
  padding: 14px;
  white-space: pre-wrap;
}

.remote-shell {
  display: grid;
  gap: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(17, 23, 32, 0.86);
  box-shadow: var(--shadow);
  padding: 24px;
}

.remote-search-panel {
  display: grid;
  grid-template-columns: minmax(180px, 0.38fr) minmax(320px, 1fr);
  gap: 22px;
  align-items: end;
}

.search-box {
  position: relative;
}

.search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  z-index: 1;
  color: var(--accent-strong);
  font-size: 1.25rem;
  font-weight: 900;
  transform: translateY(-50%);
}

.search-box input {
  width: 100%;
  min-height: 58px;
  border: 1px solid rgba(214, 179, 106, 0.38);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03)),
    rgba(3, 7, 13, 0.76);
  color: var(--ink);
  font-size: 1rem;
  font-weight: 700;
  outline: none;
  padding: 0 54px 0 48px;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.search-box input:focus {
  border-color: var(--accent-strong);
  box-shadow: 0 0 0 4px rgba(214, 179, 106, 0.14);
}

.search-box input::-webkit-search-cancel-button {
  appearance: none;
}

.search-clear,
#clearRemoteSearch,
#clearSicomSearch {
  position: absolute;
  right: 12px;
  top: 50%;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  cursor: pointer;
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1;
  transform: translateY(-50%);
}

.search-clear:hover,
#clearRemoteSearch:hover,
#clearSicomSearch:hover {
  color: var(--accent-strong);
}

.suggestion-panel {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  left: 0;
  z-index: 6;
  display: grid;
  gap: 6px;
  border: 1px solid rgba(214, 179, 106, 0.28);
  border-radius: 8px;
  background: rgba(8, 12, 18, 0.98);
  box-shadow: var(--shadow);
  padding: 8px;
}

.suggestion-item {
  display: grid;
  gap: 2px;
  width: 100%;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  padding: 10px 12px;
  text-align: left;
}

.suggestion-item:hover,
.suggestion-item:focus {
  background: rgba(214, 179, 106, 0.12);
}

.suggestion-item span {
  font-weight: 800;
}

.suggestion-item small {
  color: var(--muted);
  font-weight: 700;
}

.remote-results-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  padding-top: 4px;
}

.remote-total {
  border: 1px solid rgba(36, 198, 220, 0.35);
  border-radius: 999px;
  background: rgba(36, 198, 220, 0.1);
  color: #a8f4ff;
  font-size: 0.82rem;
  font-weight: 900;
  padding: 8px 12px;
  white-space: nowrap;
}

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

.online-workspace {
  max-width: 1580px;
  padding-top: 28px;
}

.online-dashboard {
  display: grid;
  gap: 18px;
}

.online-dashboard-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.online-dashboard-head h1 {
  margin: 0 0 6px;
  font-size: clamp(2rem, 4vw, 3.1rem);
  line-height: 1;
}

.online-dashboard-head p {
  color: var(--muted);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.45;
  margin: 0;
}

.online-dashboard-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
  min-width: 320px;
}

.online-head-total,
.online-last-updated {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
  padding: 0 12px;
  white-space: nowrap;
}

.online-head-total {
  border-color: rgba(36, 198, 220, 0.34);
  background: rgba(36, 198, 220, 0.1);
  color: #a8f4ff;
}

.online-last-updated b {
  color: var(--ink);
  margin-left: 5px;
}

.online-filter-grid {
  display: grid;
  grid-template-columns: minmax(260px, 1.35fr) repeat(4, minmax(145px, 0.75fr)) auto;
  gap: 12px;
  align-items: end;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.025)),
    rgba(17, 23, 32, 0.82);
  box-shadow: 0 16px 46px rgba(0, 0, 0, 0.2);
  padding: 14px;
}

.online-filter-grid .input-field {
  gap: 6px;
}

.online-filter-grid .input-field span {
  color: var(--muted);
  font-size: 0.76rem;
}

.online-filter-grid input,
.online-filter-grid select {
  min-height: 48px;
  border-color: rgba(255, 255, 255, 0.13);
  background: rgba(3, 7, 13, 0.72);
}

.online-filter-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.online-filter-actions .primary-button,
.online-filter-actions .secondary-button {
  min-height: 48px;
}

.online-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 14px;
}

.online-stat-card {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  min-height: 104px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.025)),
    rgba(17, 23, 32, 0.84);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.18);
  color: var(--ink);
  padding: 16px;
}

.online-stat-card.online-tone-ok,
.online-stat-card.online-tone-warn,
.online-stat-card.online-tone-bad,
.online-stat-card.online-tone-muted,
.online-stat-card.online-tone-neutral {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.025)),
    rgba(17, 23, 32, 0.84);
}

.online-stat-icon {
  display: inline-grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  background: rgba(154, 171, 193, 0.12);
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 1000;
}

.online-stat-card.online-tone-ok .online-stat-icon {
  background: rgba(66, 215, 125, 0.16);
  color: #b8ffd4;
}

.online-stat-card.online-tone-warn .online-stat-icon {
  background: rgba(240, 202, 120, 0.18);
  color: var(--accent-strong);
}

.online-stat-card.online-tone-bad .online-stat-icon {
  background: rgba(255, 107, 107, 0.16);
  color: #ffc3c3;
}

.online-stat-card span:not(.online-stat-icon),
.online-stat-card small {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.online-stat-card strong {
  display: block;
  color: var(--ink);
  font-size: 1.65rem;
  line-height: 1.05;
  margin: 4px 0;
}

.online-table-wrap {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(17, 23, 32, 0.86);
  box-shadow: var(--shadow);
}

.online-table-scroll {
  overflow: auto;
}

.online-table {
  width: 100%;
  min-width: 980px;
  border-collapse: separate;
  border-spacing: 0;
}

.online-table th,
.online-table td {
  border-bottom: 1px solid rgba(255, 255, 255, 0.075);
  padding: 13px 12px;
  text-align: left;
  vertical-align: middle;
}

.online-table th {
  color: #c8d7eb;
  font-size: 0.74rem;
  text-transform: uppercase;
  white-space: nowrap;
}

.online-table .online-module-head {
  color: var(--accent-strong);
  text-align: center;
}

.online-table td strong,
.online-table td small {
  display: block;
}

.online-table td small {
  color: var(--muted);
  font-weight: 700;
  margin-top: 4px;
}

.online-table tbody tr:hover {
  background: rgba(214, 179, 106, 0.055);
}

.online-status,
.online-module,
.online-version-cell {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 900;
  min-height: 34px;
  padding: 6px 10px;
  white-space: nowrap;
}

.online-status {
  border-radius: 999px;
}

.online-module-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.online-version-cell {
  gap: 7px;
  width: 100%;
  min-width: 108px;
  background: rgba(3, 7, 13, 0.38);
}

.online-version-cell i,
.online-table-footer .dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: currentColor;
}

.online-tone-ok {
  border-color: rgba(66, 215, 125, 0.42);
  background: rgba(66, 215, 125, 0.12);
  color: #b8ffd4;
}

.online-tone-warn {
  border-color: rgba(240, 202, 120, 0.5);
  background: rgba(240, 202, 120, 0.13);
  color: var(--accent-strong);
}

.online-tone-bad {
  border-color: rgba(255, 107, 107, 0.45);
  background: rgba(255, 107, 107, 0.12);
  color: #ffc3c3;
}

.online-tone-muted,
.online-tone-neutral {
  border-color: rgba(154, 171, 193, 0.28);
  background: rgba(154, 171, 193, 0.08);
  color: var(--muted);
}

.online-table-footer {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.075);
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
  padding: 14px;
}

.online-table-footer span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.online-table-footer .ok {
  color: #42d77d;
}

.online-table-footer .warn {
  color: var(--accent-strong);
}

.online-table-footer .bad {
  color: #ff6b6b;
}

.online-table-footer .muted {
  color: var(--muted);
}

.online-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-weight: 800;
}

.online-pagination > div {
  display: flex;
  align-items: center;
  gap: 8px;
}

.remote-card,
.sicom-card {
  display: grid;
  gap: 12px;
  align-content: start;
  align-items: start;
  min-height: 236px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background:
    linear-gradient(155deg, rgba(255, 255, 255, 0.075), rgba(255, 255, 255, 0.025)),
    rgba(255, 255, 255, 0.035);
  padding: 18px;
}

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

.remote-card-top {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.client-kind,
.client-note {
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  padding: 6px 9px;
  text-transform: uppercase;
}

.remote-card h3 {
  margin-bottom: 0;
  font-size: 1rem;
  line-height: 1.35;
}

.sicom-card h3 {
  margin-bottom: 0;
  font-size: 1.05rem;
  line-height: 1.35;
}

.sicom-credentials {
  display: grid;
  gap: 10px;
  align-content: start;
}

.sicom-credential {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(214, 179, 106, 0.18);
  border-radius: 8px;
  background: rgba(3, 7, 13, 0.26);
  padding: 12px;
}

.sicom-credential-head {
  display: flex;
  justify-content: flex-start;
}

.sicom-env {
  border: 1px solid rgba(36, 198, 220, 0.36);
  border-radius: 999px;
  background: rgba(36, 198, 220, 0.1);
  color: #a8f4ff;
  font-size: 0.72rem;
  font-weight: 900;
  padding: 5px 9px;
  text-transform: uppercase;
}

.sicom-meta {
  display: grid;
  gap: 4px;
  border: 1px solid rgba(214, 179, 106, 0.22);
  border-radius: 8px;
  background: rgba(3, 7, 13, 0.36);
  padding: 12px;
}

.sicom-meta span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  text-transform: uppercase;
}

.sicom-meta strong {
  color: var(--accent-strong);
  font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
  font-size: 1rem;
}

.sicom-card p {
  color: var(--muted);
  line-height: 1.45;
  margin-bottom: 0;
}

.client-note {
  justify-self: start;
  color: #a8f4ff;
}

.remote-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: auto;
}

.remote-actions .primary-button,
.remote-actions .secondary-button {
  min-height: 40px;
  padding: 0 12px;
  text-align: center;
}

.sicom-actions {
  margin-top: auto;
}

.sicom-credential .sicom-actions {
  margin-top: 0;
}

.open-vault-site {
  grid-column: 1 / -1;
}

.empty-state {
  border: 1px dashed rgba(214, 179, 106, 0.4);
  border-radius: 8px;
  color: var(--muted);
  margin: 0;
  padding: 18px;
  text-align: center;
}

.narrow-workspace {
  max-width: 780px;
}

.auth-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(17, 23, 32, 0.9);
  box-shadow: var(--shadow);
  padding: clamp(24px, 5vw, 42px);
}

.auth-title-art {
  display: block;
  width: min(100%, 440px);
  margin: 0 0 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.24);
}

.login-heading-art {
  width: min(100%, 550px);
  margin: 4px 0 26px;
}

.login-brand-art {
  width: min(100%, 390px);
  margin: 8px auto 32px;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  object-fit: contain;
}

.auth-panel h1 {
  margin-bottom: 22px;
  font-size: clamp(2.2rem, 6vw, 4.6rem);
  line-height: 0.95;
  text-transform: uppercase;
}

.auth-form {
  display: grid;
  gap: 14px;
}

#register .register-workspace {
  align-content: center;
  max-width: 720px;
  min-height: calc(100dvh - var(--site-header-height));
  padding-top: 14px;
  padding-bottom: 14px;
}

#register .register-panel {
  padding: clamp(24px, 3vw, 34px);
}

#register .register-form {
  gap: 10px;
}

#register .form-row {
  grid-template-columns: 1fr;
  gap: 10px;
}

#register .input-field {
  gap: 6px;
}

#register input[type="text"],
#register input[type="email"],
#register input[type="password"] {
  min-height: 42px;
}

#register .password-meter {
  margin-top: 2px;
}

.password-policy-help {
  color: #b6c9e6;
  margin-top: -1px;
}

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

.check-field {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.45;
}

.check-field input {
  margin-top: 4px;
}

.form-message {
  min-height: 24px;
  color: var(--accent-strong);
  font-weight: 800;
  margin: 16px 0 0;
}

.toast-stack {
  position: fixed;
  right: clamp(14px, 2vw, 28px);
  bottom: clamp(14px, 2vw, 28px);
  z-index: 80;
  display: grid;
  gap: 10px;
  width: min(390px, calc(100vw - 28px));
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: start;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-left: 6px solid var(--cyan);
  border-radius: 8px;
  background: rgba(9, 13, 19, 0.96);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.34);
  color: var(--ink);
  padding: 13px 13px 13px 14px;
  animation: toast-enter 180ms ease-out both;
  will-change: transform, opacity;
}

.toast.is-leaving {
  animation: toast-leave 620ms ease-in forwards;
  pointer-events: none;
}

.toast strong {
  display: block;
  color: var(--ink);
  font-size: 0.88rem;
  margin-bottom: 3px;
}

.toast span {
  display: block;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.35;
}

.toast button {
  width: 30px;
  height: 30px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-weight: 900;
}

.toast button:hover {
  border-color: rgba(214, 179, 106, 0.5);
  color: var(--accent-strong);
}

.toast.success {
  border-left-color: #42d77d;
}

.toast.error {
  border-left-color: #ff6b6b;
}

.toast.warning {
  border-left-color: var(--accent-strong);
}

.toast.info {
  border-left-color: var(--cyan);
}

@keyframes toast-enter {
  from {
    opacity: 0;
    transform: translateY(14px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes toast-leave {
  from {
    opacity: 1;
    transform: translateY(0);
  }

  to {
    opacity: 0;
    transform: translateY(-28px);
  }
}

.mfa-panel {
  display: grid;
  gap: 14px;
  margin-top: 22px;
  border-top: 1px solid var(--line);
  padding-top: 22px;
}

.mfa-panel h2 {
  margin-bottom: 0;
}

.mfa-help {
  color: var(--muted);
  line-height: 1.55;
  margin-bottom: 0;
}

.mfa-secret {
  display: grid;
  justify-items: center;
  gap: 8px;
  border: 1px dashed rgba(214, 179, 106, 0.45);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--accent-strong);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 0.86rem;
  overflow-wrap: anywhere;
  padding: 12px;
}

.mfa-qr {
  width: min(260px, 100%);
  height: auto;
  border: 8px solid #fff;
  border-radius: 8px;
  background: #fff;
}

.mfa-manual-secret {
  width: 100%;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.28);
  color: var(--accent-strong);
  padding: 10px;
  text-align: center;
}

.password-meter {
  height: 8px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
}

.password-meter span {
  display: block;
  width: 12%;
  height: 100%;
  border-radius: inherit;
  background: #cf4f4f;
  transition: width 160ms ease, background 160ms ease;
}

.password-meter span.medium {
  background: var(--accent-strong);
}

.password-meter span.strong {
  background: #37d67a;
}

.admin-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
  gap: 22px;
  align-items: start;
}

.admin-maintenance {
  margin-top: 22px;
}

.muted-line {
  color: var(--muted);
  line-height: 1.45;
  margin: 6px 0 0;
}

.admin-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}

.admin-tab {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
  cursor: pointer;
  font-weight: 900;
  padding: 0 16px;
  text-transform: uppercase;
}

.admin-tab.active {
  border-color: rgba(214, 179, 106, 0.72);
  color: var(--accent-strong);
  background: rgba(214, 179, 106, 0.1);
}

.maintenance-content {
  display: grid;
  gap: 16px;
}

.maintenance-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.76fr) minmax(360px, 1.24fr);
  gap: 16px;
  align-items: start;
}

.vault-maintenance-grid {
  grid-template-columns: 1fr;
}

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

.admin-form-card,
.admin-record-card {
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(3, 7, 13, 0.24);
  padding: 14px;
}

.admin-form-card h3,
.admin-record-card h3 {
  margin: 0;
  font-size: 1rem;
}

.admin-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.client-search-panel {
  align-items: center;
}

.compact-search {
  min-height: 58px;
}

.inline-editor {
  display: grid;
  gap: 12px;
  border: 1px solid rgba(36, 198, 220, 0.32);
  border-radius: 8px;
  background: rgba(36, 198, 220, 0.075);
  padding: 14px;
}

.inline-editor .eyebrow {
  margin-bottom: 0;
}

.online-admin-card {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.018)),
    rgba(3, 7, 13, 0.28);
}

.online-admin-modules {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.online-module-editor {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 8px;
  background: rgba(3, 7, 13, 0.26);
  padding: 12px;
}

.online-module-row {
  display: grid;
  grid-template-columns: 0.8fr 1.1fr 0.9fr 0.9fr auto;
  gap: 10px;
  align-items: end;
}

.online-active-check {
  align-self: end;
  min-height: 44px;
}

.token-once-card {
  border-color: rgba(36, 198, 220, 0.42);
  background: rgba(36, 198, 220, 0.08);
}

.token-once-value {
  overflow-wrap: anywhere;
  border: 1px dashed rgba(214, 179, 106, 0.45);
  border-radius: 8px;
  background: rgba(3, 7, 13, 0.44);
  color: var(--accent-strong);
  font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
  font-size: 0.94rem;
  font-weight: 800;
  padding: 12px;
}

.admin-record-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.admin-record-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.admin-record-meta span {
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  padding: 5px 9px;
}

.maintenance-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(160px, 0.55fr) 86px auto;
  gap: 10px;
  align-items: end;
}

.maintenance-row.wide {
  grid-template-columns: minmax(0, 1fr) 92px auto;
}

.maintenance-row.url-row {
  grid-template-columns: 130px minmax(0, 1fr) auto auto;
}

.maintenance-row .mini-check {
  justify-content: center;
  min-height: 42px;
}

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

.vault-switcher .admin-tab {
  width: 100%;
}

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

.credential-pill {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(214, 179, 106, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  padding: 10px;
}

.config-readonly {
  color: var(--muted);
  font-weight: 800;
  line-height: 1.45;
}

.admin-toolbar {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(220px, 360px);
  gap: 16px;
  align-items: end;
}

.compact-toolbar {
  grid-template-columns: minmax(160px, 1fr) auto;
}

.admin-users,
.audit-list,
.sector-access-list,
.session-list {
  display: grid;
  gap: 12px;
}

.audit-list {
  max-height: min(620px, 62vh);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding-right: 8px;
  scrollbar-color: rgba(214, 179, 106, 0.7) rgba(255, 255, 255, 0.06);
  scrollbar-width: thin;
}

.tool-nav::-webkit-scrollbar,
.audit-list::-webkit-scrollbar {
  width: 10px;
}

.tool-nav::-webkit-scrollbar-track,
.audit-list::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.06);
  border-radius: 999px;
}

.tool-nav::-webkit-scrollbar-thumb,
.audit-list::-webkit-scrollbar-thumb {
  background: rgba(214, 179, 106, 0.72);
  border: 2px solid rgba(17, 23, 32, 0.88);
  border-radius: 999px;
}

.tool-nav::-webkit-scrollbar-thumb:hover,
.audit-list::-webkit-scrollbar-thumb:hover {
  background: rgba(238, 202, 126, 0.9);
}

.audit-more-actions {
  display: flex;
  justify-content: center;
  padding: 4px 0 2px;
}

.audit-more-actions .secondary-button {
  width: min(100%, 280px);
}

.admin-user-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.72fr);
  gap: 16px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  padding: 16px;
}

.admin-user-card h3 {
  margin: 10px 0 6px;
}

.admin-user-card p,
.admin-user-card small {
  color: var(--muted);
  overflow-wrap: anywhere;
}

.admin-permission-overview {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.permission-super-note {
  border: 1px solid rgba(36, 198, 220, 0.35);
  border-radius: 8px;
  background: rgba(36, 198, 220, 0.1);
  color: #a8f4ff;
  font-size: 0.86rem;
  font-weight: 800;
  line-height: 1.4;
  padding: 10px;
}

.permission-summary-block {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 8px;
  background: rgba(3, 7, 13, 0.22);
  padding: 11px;
}

.permission-summary-block strong {
  display: block;
  color: var(--ink);
  font-size: 0.92rem;
}

.permission-summary-block span {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.35;
}

.permission-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.permission-chip,
.permission-empty {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border: 1px solid rgba(214, 179, 106, 0.36);
  border-radius: 999px;
  background: rgba(214, 179, 106, 0.1);
  color: var(--accent-strong) !important;
  font-size: 0.78rem !important;
  font-weight: 900 !important;
  padding: 5px 9px;
}

.permission-empty {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted) !important;
}

.permission-technical {
  color: var(--muted);
  font-size: 0.82rem;
}

.permission-technical summary {
  cursor: pointer;
  color: var(--accent-strong);
  font-weight: 900;
}

.permission-technical small {
  display: block;
  margin-top: 6px;
  line-height: 1.45;
}

.access-editor {
  display: grid;
  gap: 10px;
  margin-top: 14px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.access-editor > span {
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.access-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.mini-check {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 800;
  padding: 7px 10px;
}

.mini-check input {
  accent-color: var(--accent-strong);
}

.sector-access-card {
  display: grid;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  padding: 14px;
}

.sector-access-card strong {
  display: block;
  margin-bottom: 4px;
}

.sector-access-card small {
  color: var(--muted);
  overflow-wrap: anywhere;
}

.admin-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-self: start;
}

.self-protection {
  grid-column: 1 / -1;
  justify-self: stretch;
  border: 1px solid rgba(36, 198, 220, 0.35);
  border-radius: 8px;
  background: rgba(36, 198, 220, 0.1);
  color: #a8f4ff;
  font-size: 0.82rem;
  font-weight: 800;
  line-height: 1.4;
  max-width: 100%;
  padding: 10px;
}

.admin-actions .secondary-button {
  min-height: 42px;
  padding: 0 10px;
}

.audit-item {
  display: grid;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  padding: 12px;
}

.audit-item-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.audit-result {
  border: 1px solid rgba(36, 198, 220, 0.35);
  border-radius: 999px;
  background: rgba(36, 198, 220, 0.1);
  color: #a8f4ff !important;
  font-size: 0.76rem !important;
  font-weight: 900;
  padding: 5px 9px;
  white-space: nowrap;
}

.audit-meta {
  display: grid;
  gap: 4px;
}

.audit-meta span {
  color: var(--muted);
  font-size: 0.82rem;
  overflow-wrap: anywhere;
}

.audit-meta b {
  color: #c8d7eb;
}

.session-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
  padding: 12px;
}

.session-item strong {
  display: block;
  margin-bottom: 4px;
}

.session-item span {
  color: var(--muted);
  display: block;
  font-size: 0.8rem;
  overflow-wrap: anywhere;
}

@media (max-width: 980px) {
  .tool-layout,
  .home-access,
  .hero-panel,
  .tool-panel,
  .remote-search-panel,
  .online-dashboard-head,
  .admin-layout,
  .admin-user-card,
  .admin-toolbar,
  .maintenance-grid,
  .maintenance-row,
  .maintenance-row.wide,
  .maintenance-row.url-row,
  .online-filter-grid,
  .online-module-row {
    grid-template-columns: 1fr;
  }

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

  .tool-sidebar {
    position: static;
    max-height: none;
  }

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

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

  .online-pagination {
    align-items: stretch;
    flex-direction: column;
  }

  .online-dashboard-head {
    flex-direction: column;
  }

  .online-dashboard-actions {
    justify-content: flex-start;
    min-width: 0;
  }

  .home-hero .hero-copy > p:last-child {
    white-space: normal;
  }

  .remote-helper-card {
    max-width: none;
  }
}

@media (max-width: 680px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .header-nav {
    width: 100%;
    justify-content: space-between;
  }

  .brand img {
    width: 170px;
    height: auto;
  }

  .nav-image-link {
    width: calc(50% - 8px);
    min-width: 138px;
    height: 44px;
  }

  .workspace {
    padding: 22px 16px 36px;
  }

  .upload-grid,
  .summary-grid,
  .remote-grid,
  .sicom-grid,
  .online-stats,
  .remote-actions,
  .pdf-merge-list,
  .form-row,
  .admin-actions,
  .vault-switcher {
    grid-template-columns: 1fr;
  }

  .online-filter-actions {
    grid-template-columns: 1fr;
  }

  .remote-helper-card {
    align-items: stretch;
    flex-direction: column;
  }

  .remote-helper-download {
    width: 100%;
  }

  .pdf-merge-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .pdf-merge-actions {
    grid-template-columns: 1fr;
  }

  .remote-results-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .actions {
    justify-content: stretch;
  }

  .primary-button,
  .secondary-button {
    width: 100%;
  }
}
