:root {
  color-scheme: dark;
  --navy: #24343e;
  --steel: #455d6e;
  --gold: #c5a87c;
  --background: #24343e;
  --surface: #2b3e49;
  --surface-raised: #334b5b;
  --sidebar: #1d2c35;
  --text: #f7f8fa;
  --muted: #c0cbd3;
  --border: #50616d;
  --soft: #3a4f5e;
  --radius: 13px;
  font-family: "Open Sans", "Segoe UI", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
  background: var(--background);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .5; cursor: not-allowed; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: 27px; line-height: 1.25; font-weight: 600; letter-spacing: -.6px; overflow-wrap: anywhere; }
h1:focus { outline: none; }
h2 { font-size: 16px; line-height: 1.4; font-weight: 600; }
h3 { font-size: 14px; font-weight: 600; }
svg { width: 18px; height: 18px; vertical-align: middle; flex-shrink: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.app-shell { display: grid; grid-template-columns: 252px minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: var(--sidebar); padding: 20px 18px; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; min-height: 680px; isolation: isolate; }
.sidebar::before { content: ""; position: absolute; inset: 40% 0 0; z-index: -1; background: url("../assets/padrao-mrd.png") 35% 100% / 620px auto no-repeat; opacity: .12; pointer-events: none; }
.brand { display: flex; flex-direction: column; align-items: center; gap: 28px; padding: 36px 20px 28px; }
.brand img { display: block; width: 156px; max-width: 100%; height: auto; }
.brand > span { letter-spacing: 2.4px; color: var(--gold); font-size: 11px; font-weight: 600; }
nav { display: flex; flex-direction: column; gap: 7px; margin-top: 12px; }
nav button { display: flex; align-items: center; gap: 11px; padding: 12px 15px; background: transparent; color: var(--muted); border: 1px solid transparent; border-radius: 9px; width: 100%; text-align: left; }
nav button:hover { color: var(--text); background: var(--surface); }
nav button[aria-current="page"] { background: var(--steel); color: white; border-color: #607787; }
nav button[aria-current="page"] svg { color: var(--gold); }
.sidebar-foot { margin-top: auto; display: flex; gap: 11px; align-items: center; padding: 20px 8px 8px; border-top: 1px solid var(--border); }
.sidebar-foot strong { display: block; font-size: 12px; font-weight: 500; }
.sidebar-foot small { display: block; font-size: 11px; color: var(--muted); margin-top: 4px; }
.avatar { display: grid; place-items: center; width: 35px; height: 35px; border: 1px solid var(--border); border-radius: 50%; color: var(--gold); flex-shrink: 0; font-size: 12px; }
.workspace { min-width: 0; display: flex; flex-direction: column; }
.topbar { padding: 19px 30px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; gap: 15px; flex-wrap: wrap; background: var(--surface); }
.breadcrumb { color: var(--muted); font-size: 12px; }
.breadcrumb > span:first-child { padding: 0 8px; color: var(--gold); }
.topbar-controls { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.demo-badge { display: inline-flex; align-items: center; gap: 6px; color: #e5cda6; border: 1px solid #7c6d55; background: #3c3e3b; padding: 5px 9px; border-radius: 6px; font-size: 11px; font-weight: 600; }
.demo-badge svg { width: 14px; height: 14px; }
.profile-label select { border: 1px solid var(--border); background: var(--surface); color: var(--text); font-size: 12px; padding: 6px 9px; border-radius: 6px; max-width: 100%; }
.content { width: 100%; max-width: 1480px; margin: 0 auto; padding: 30px; display: flex; flex-direction: column; gap: 22px; flex: 1; }
.page-heading { display: flex; gap: 18px; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; }
.page-heading p { margin-top: 8px; color: var(--muted); }
.page-heading > div, .list-item > div { min-width: 0; }
.content p, .content dd, .content h3, .content td, .content .list-meta { overflow-wrap: anywhere; }
.kicker { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 1.6px; color: var(--gold); margin-bottom: 9px; }
.hero { position: relative; isolation: isolate; padding: 6px 0 2px; }
.hero::after { content: ""; position: absolute; right: 0; top: -15px; bottom: -10px; width: 260px; background: url("../assets/padrao-mrd.png") center / cover no-repeat; z-index: -1; opacity: .07; pointer-events: none; }
.actions { display: flex; gap: 9px; flex-wrap: wrap; align-items: center; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 7px; min-height: 39px; padding: 8px 13px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); font-weight: 500; text-decoration: none; }
.button:hover { background: var(--soft); }
.button.primary { background: var(--gold); border-color: var(--gold); color: #24343e; font-weight: 600; }
.button.primary:hover { background: #d7bd96; }
.button.ghost { background: transparent; }
.text-button { display: inline-flex; align-items: center; gap: 5px; border: 0; background: transparent; color: var(--gold); padding: 5px 0; font-weight: 500; text-align: left; min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.text-button:hover { text-decoration: underline; }
.card { padding: 22px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); min-width: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.card-head > svg { color: var(--gold); }
.metrics { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 15px; }
.metric-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--muted); font-size: 12px; }
.metric-heading svg { color: var(--gold); }
.metric-value { font-size: 32px; line-height: 1.3; font-weight: 600; margin: 10px 0 4px; font-variant-numeric: tabular-nums; }
.muted, .note { color: var(--muted); }
.note { font-size: 12px; }
.split { display: grid; grid-template-columns: minmax(0,1.45fr) minmax(0,1fr); gap: 22px; align-items: start; }
.stack { display: flex; flex-direction: column; gap: 22px; }
.inventory-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.inventory-record .check { color: var(--text); }
.badge { display: inline-flex; align-items: center; gap: 6px; border-radius: 20px; background: var(--soft); color: var(--text); padding: 4px 9px; font-size: 11px; line-height: 1.35; font-weight: 500; }
.badge.gold { background: #47493f; color: #eed8b8; }
.badge.outline { border: 1px solid var(--border); background: transparent; color: var(--muted); }
.dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex-shrink: 0; }
.list-item { display: flex; gap: 12px; justify-content: space-between; align-items: flex-start; padding: 15px 0; border-bottom: 1px solid var(--border); }
.list-item:first-child { padding-top: 0; }
.list-item:last-child { border-bottom: 0; padding-bottom: 0; }
.list-item .text-button { color: var(--text); padding: 0; }
.list-item .text-button:hover { color: var(--gold); }
.list-meta { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; margin-top: 6px; font-size: 12px; color: var(--muted); }
.gap-top { margin-top: 16px; }
.gap-small { margin-top: 6px; }
.callout { display: flex; gap: 10px; align-items: flex-start; padding: 13px 15px; border-radius: 9px; background: var(--surface-raised); font-size: 12px; border-left: 2px solid var(--gold); }
.callout > svg { color: var(--gold); margin-top: 1px; }
.callout.error { border: 1px solid var(--gold); }
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; }
.field { display: flex; flex-direction: column; gap: 7px; color: var(--muted); font-size: 12px; min-width: 0; flex: 1; }
.toolbar .field { min-width: 140px; }
.toolbar .field.grow { min-width: 190px; flex: 2; }
input:not([type="checkbox"]), textarea, .field select { width: 100%; min-width: 0; color: var(--text); background: var(--sidebar); border: 1px solid var(--border); border-radius: 7px; padding: 10px 11px; }
input::placeholder, textarea::placeholder { color: #a4b4c1; opacity: 1; }
textarea { resize: vertical; min-height: 100px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 17px; }
.full { grid-column: 1/-1; }
.form-error { font-size: 12px; color: #f4ddbb; border-left: 2px solid var(--gold); padding-left: 9px; }
.check { display: flex; align-items: flex-start; gap: 9px; font-size: 12px; }
.check input { accent-color: var(--gold); margin-top: 3px; width: 15px; height: 15px; flex-shrink: 0; }
.table-wrap { overflow-x: auto; max-width: 100%; }
table { width: 100%; border-collapse: collapse; font-size: 12px; }
th { color: var(--muted); font-weight: 500; text-align: left; padding: 0 12px 13px; border-bottom: 1px solid var(--border); }
td { padding: 15px 12px; border-bottom: 1px solid var(--border); vertical-align: middle; }
td strong { font-weight: 500; }
th:first-child, td:first-child { padding-left: 0; }
tbody tr:last-child td { border-bottom: 0; }
.table-action { text-align: right; }
.device-name { display: flex; gap: 11px; align-items: center; min-width: 150px; }
.device-glyph { padding: 10px; border-radius: 8px; background: var(--surface-raised); color: var(--gold); flex-shrink: 0; }
.device-name small { display: block; color: var(--muted); margin-top: 3px; font-size: 11px; }
.empty { text-align: center; padding: 28px 10px; color: var(--muted); }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 17px; margin: 0; }
.detail-grid dt { color: var(--muted); font-size: 12px; }
.detail-grid dd { margin: 4px 0 0; overflow-wrap: anywhere; }
hr { border: 0; border-top: 1px solid var(--border); margin: 20px 0; }
.timeline { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 16px; }
.timeline li { display: flex; gap: 11px; font-size: 12px; }
.timeline strong { font-size: 11px; font-weight: 500; color: var(--gold); }
.timeline p { margin-top: 3px; overflow-wrap: anywhere; }
.timeline-mark { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); margin-top: 6px; flex-shrink: 0; }
.routines { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; }
.routine { display: flex; flex-direction: column; gap: 11px; text-align: left; border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; background: var(--surface); color: var(--text); }
.routine > svg { color: var(--gold); }
.routine small { color: var(--muted); font-size: 12px; }
.routine strong { font-size: 14px; font-weight: 500; }
.routine[aria-pressed="true"] { border: 2px solid var(--gold); padding: 17px; background: var(--surface-raised); }
.steps { display: flex; flex-direction: column; gap: 18px; list-style: none; padding: 0; margin: 20px 0 0; }
.steps li { display: flex; gap: 12px; align-items: center; font-size: 12px; }
.step-number { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: var(--soft); color: var(--muted); flex-shrink: 0; }
.steps li.done .step-number { background: var(--surface-raised); color: var(--gold); }
.steps li.current .step-number { background: var(--gold); color: var(--navy); }
.steps small { color: var(--muted); display: block; margin-top: 4px; font-size: 11px; }
progress { display: block; border: 0; width: 100%; height: 6px; border-radius: 5px; background: var(--soft); color: var(--gold); appearance: none; }
progress::-webkit-progress-bar { background: var(--soft); border-radius: 5px; }
progress::-webkit-progress-value { background: var(--gold); border-radius: 5px; }
progress::-moz-progress-bar { background: var(--gold); border-radius: 5px; }
.session { background: var(--sidebar); padding: 17px; border: 1px solid var(--border); border-radius: var(--radius); }
.session-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 15px; font-size: 12px; }
.desktop { min-height: 230px; background: var(--steel); border-radius: 9px; display: grid; place-items: center; padding: 22px; margin-bottom: 15px; }
.desktop-window { width: min(100%,340px); padding: 24px; background: var(--surface); border: 1px solid var(--border); border-radius: 9px; }
.window-dots { display: flex; gap: 5px; margin-bottom: 16px; }
.window-dots span { width: 6px; height: 6px; border-radius: 50%; background: var(--gold); }
footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; border-top: 1px solid var(--border); padding: 15px 30px; font-size: 11px; color: var(--muted); }
.toast { position: fixed; bottom: 20px; right: 20px; max-width: min(470px,calc(100% - 40px)); padding: 14px 18px; color: var(--text); background: var(--sidebar); border: 1px solid var(--gold); border-radius: 10px; box-shadow: 0 8px 22px #0003; font-size: 12px; z-index: 5; }
@media(min-width:1600px) { .content { padding: 40px; gap: 26px; } }
@media(max-width:1100px) {
  .app-shell { grid-template-columns: 220px minmax(0,1fr); }
  .sidebar { padding-left: 12px; padding-right: 12px; }
  .brand { padding-left: 20px; padding-right: 20px; }
  .content { padding: 24px; gap: 18px; }
  .split { grid-template-columns: minmax(0,1.2fr) minmax(0,1fr); gap: 18px; }
  .card { padding: 18px; }
  .topbar { padding: 16px 24px; }
}
@media(max-width:950px) {
  .inventory-list { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; }
  .routines { grid-template-columns: 1fr; }
  .routine { display: grid; grid-template-columns: 24px 1fr; gap: 6px 11px; }
  .routine small { grid-column: 2; }
}
@media(max-width:760px) {
  .app-shell { display: block; }
  .sidebar { position: relative; height: auto; min-height: 0; padding: 18px; }
  .sidebar::before { display: none; }
  .brand { flex-direction: row; justify-content: space-between; padding: 8px 8px 16px; gap: 25px; }
  .brand img { width: 142px; }
  .brand > span { font-size: 10px; }
  nav { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 5px; }
  nav button { flex-direction: column; padding: 10px 5px; font-size: 11px; gap: 7px; }
  .sidebar-foot { display: none; }
  .topbar { padding: 14px 18px; }
  .content { padding: 22px 18px; }
  .topbar-controls { gap: 8px; }
  .metrics { gap: 9px; }
  .metrics .card { padding: 14px; }
  .metric-heading > svg { display: none; }
  .metric-value { font-size: 27px; }
  h1 { font-size: 24px; }
}
@media(max-width:500px) {
  .sidebar { padding: 12px; }
  .brand { flex-direction: column; align-items: flex-start; gap: 15px; padding: 13px 9px; }
  nav { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .content { padding: 20px 14px; }
  .topbar { padding: 13px 14px; }
  .topbar-controls { width: 100%; }
  .profile-label { min-width: 0; width: 100%; }
  .profile-label select { width: 100%; }
  .metrics { grid-template-columns: 1fr; }
  .metrics .card { display: grid; grid-template-columns: 1fr auto; gap: 5px 12px; }
  .metric-value { grid-column: 2; grid-row: 1/3; margin: 0; align-self: center; }
  .form-grid, .detail-grid { grid-template-columns: 1fr; }
  .full { grid-column: auto; }
  .list-item { flex-wrap: wrap; }
  .card { padding: 15px; }
  .toolbar .field { min-width: 100%; }
  .button { min-height: 44px; }
  input:not([type="checkbox"]), select, textarea { font-size: 16px; }
  footer { padding: 15px 14px; }
}
@media(prefers-reduced-motion:reduce) { * { scroll-behavior: auto !important; } }
.preline { white-space: pre-wrap; } .page-heading .actions { max-width: 100%; } .timeline { max-height: 75vh; overflow-y: auto; padding-right: 8px; } a.button:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }

.mesh-id { max-width: 230px; overflow-wrap: anywhere; font-size: 10px; }
summary { cursor: pointer; font-weight: 600; }

.login-body { min-height: 100vh; display: grid; place-items: center; padding: 28px 16px; } .login-card { width: min(100%, 480px); } .login-logo { display: block; max-width: 100%; height: auto; margin: 0 auto 24px; } .login-card h1 { margin-top: 12px; } .login-card [hidden] { display: none; }

