:root { color-scheme: light; --canvas: #f4f5f8; --panel: #fff; --ink: #182742; --muted: #465774; --line: #d6deeb; --gold: #ffcd78; --navy: #122344; }
:root[data-theme="escuro"] { color-scheme: dark; --canvas: #101727; --panel: #1b2740; --ink: #f1f4fb; --muted: #c1cee4; --line: #435674; }
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--canvas); color: var(--ink); font: 16px/1.5 system-ui,sans-serif; }
.shell { min-height: 100vh; display: grid; grid-template-columns: 210px minmax(0,1fr); }
aside { background: var(--navy); color: white; padding: 24px 16px; }
.brand { color: var(--gold); font-weight: 850; font-size: 1.55rem; margin-bottom: 16px; }
.login .brand { color: var(--ink); }
nav { display: grid; gap: 6px; margin-bottom: 20px; }
nav button, aside .secondary { text-align: left; background: transparent; color: #fff; border-color: #617697; }
nav button[aria-current] { color: var(--navy); background: var(--gold); border-color: var(--gold); }
#main { padding: clamp(14px,3vw,36px); min-width: 0; }
header { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 16px; }
h1,h2,h3,p { margin: 0 0 10px; }
h1 { font-size: clamp(25px,4vw,38px); }
h2 { font-size: 1.2rem; }
#identity, small { color: var(--muted); }
.panel,.metric,.card { padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.panel + .panel { margin-top: 12px; }
.login { min-height: 100vh; display: grid; place-items: center; padding: 16px; }
.login .panel { width: min(100%,410px); padding: 28px; }
label { display: grid; align-content: start; gap: 4px; font-weight: 650; }
.login label { margin-bottom: 12px; }
input,select,textarea,button { font: inherit; min-height: 44px; border-radius: 7px; }
input,select,textarea { width: 100%; min-width: 0; border: 1px solid var(--line); padding: 8px; background: var(--panel); color: var(--ink); }
button { cursor: pointer; background: var(--navy); color: white; border: 1px solid var(--navy); padding: 7px 12px; font-weight: 650; }
.secondary { background: var(--panel); color: var(--ink); border-color: var(--line); }
.fields,.metrics { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,190px),1fr)); gap: 10px; }
.metrics { margin-bottom: 16px; }
.metric strong { display: block; font-size: 1.5rem; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.table { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
td,th { padding: 8px 12px; border-bottom: 1px solid var(--line); }
#notification { position: fixed; bottom: 14px; left: 50%; transform: translateX(-50%); width: min(92vw,520px); z-index: 3; border-radius: 8px; padding: 12px; background: var(--navy); color: white; }
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px,280px); gap: 12px; overflow-x: auto; padding-bottom: 9px; }
.column { padding: 10px; border: 1px solid var(--line); border-radius: 10px; min-height: 140px; }
.card { margin-bottom: 8px; overflow-wrap: anywhere; }
.card[data-urgent="true"] { border-left: 5px solid #ce7334; }
.card[data-late="true"] { border-left: 5px solid #cb4655; }
summary { cursor: pointer; padding: 10px 0; }
button:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible { outline: 3px solid #b16a18; outline-offset: 2px; }
@media(max-width:700px) { .shell{display:block} aside{padding:12px} nav{display:flex;overflow-x:auto;margin-bottom:8px} nav button{white-space:nowrap} }
@media print { aside,#notification,.actions,button { display:none !important } .shell { display:block } #main { padding:0 } }
