:root {
  --navy-950: #001b3a;
  --navy-900: #002f63;
  --navy-800: #0a467a;
  --navy-700: #145b91;
  --blue-100: #eaf3fb;
  --green-600: #17a84d;
  --green-100: #e8f7ed;
  --amber-600: #d9830d;
  --amber-100: #fff4df;
  --red-600: #c73939;
  --red-100: #feeeee;
  --ink-900: #182534;
  --ink-700: #425466;
  --ink-500: #6c7b8b;
  --line: #dce4eb;
  --surface: #ffffff;
  --canvas: #f4f7fa;
  --shadow: 0 14px 36px rgba(8, 36, 66, .08);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --sidebar-width: 270px;
  font-family: Montserrat, "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink-900); background: var(--canvas); font-size: 15px; line-height: 1.5; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: var(--navy-800); text-decoration: none; }
a:hover { color: var(--navy-900); }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: .55rem; font-size: clamp(1.9rem, 3vw, 2.65rem); line-height: 1.1; letter-spacing: -.035em; }
h2 { margin-bottom: .35rem; font-size: 1.35rem; letter-spacing: -.02em; }
h3 { margin-bottom: .3rem; font-size: 1rem; }
p { color: var(--ink-700); }
small { color: var(--ink-500); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.mobile-only { display: none !important; }

.eyebrow { display: inline-block; margin-bottom: .55rem; color: var(--navy-700); font-size: .72rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.eyebrow--light { color: #a9d7ff; }
.back-link { display: block; margin-bottom: 1rem; color: var(--ink-500); font-size: .88rem; font-weight: 700; }
.text-link { font-weight: 750; }

.btn { display: inline-flex; min-height: 44px; align-items: center; justify-content: center; gap: .45rem; padding: .68rem 1.05rem; border: 1px solid transparent; border-radius: 11px; cursor: pointer; font-weight: 750; transition: transform .15s ease, box-shadow .15s ease, background .15s ease; }
.btn:hover { transform: translateY(-1px); }
.btn--primary { color: #fff; background: var(--navy-900); box-shadow: 0 7px 18px rgba(0, 47, 99, .18); }
.btn--primary:hover { color: #fff; background: var(--navy-800); }
.btn--secondary { color: var(--navy-900); border-color: #c7d5e2; background: #fff; }
.btn--secondary:hover { background: var(--blue-100); }
.btn--warning { color: #7a4700; border-color: #f0c77e; background: var(--amber-100); }
.btn--ghost { color: var(--ink-700); background: transparent; }
.btn--block { width: 100%; }
.btn--small { min-height: 36px; padding: .45rem .75rem; font-size: .82rem; }
.btn-link { padding: .35rem 0; border: 0; color: #b9cce0; background: transparent; cursor: pointer; font-size: .82rem; }
.button-row { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; }

.form-control, select { width: 100%; min-height: 46px; padding: .7rem .8rem; border: 1px solid #cbd7e1; border-radius: 10px; outline: none; color: var(--ink-900); background: #fff; transition: border .15s, box-shadow .15s; }
.form-control:focus, select:focus { border-color: var(--navy-700); box-shadow: 0 0 0 4px rgba(20, 91, 145, .1); }
.form-control:disabled { color: var(--ink-500); background: #f0f3f6; }
.form-control--textarea { min-height: 116px; resize: vertical; }
.field-group { display: flex; flex-direction: column; gap: .38rem; }
.field-group label { color: var(--ink-700); font-size: .82rem; font-weight: 750; }
.field-help { color: var(--ink-500); font-size: .72rem; }
.field-help ul { margin: .25rem 0 0; padding-left: 1rem; }
.field-error, .errorlist { margin: 0; padding: 0; list-style: none; color: var(--red-600); font-size: .76rem; font-weight: 650; }
.field-grid { display: grid; gap: 1rem; }
.field-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.field-grid--3 { grid-template-columns: 1.4fr .7fr 1fr; }
.stack-md > * + * { margin-top: .85rem; }
.stack-lg > * + * { margin-top: 1.15rem; }
.password-field { position: relative; }
.password-field .form-control { padding-right: 4.8rem; }
.password-toggle { position: absolute; top: 50%; right: .5rem; transform: translateY(-50%); padding: .35rem .5rem; border: 0; color: var(--navy-700); background: transparent; cursor: pointer; font-size: .72rem; font-weight: 800; }

.alert { padding: .85rem 1rem; border: 1px solid; border-radius: 12px; font-size: .87rem; }
.alert ul { margin: .4rem 0 0; }
.alert--error { color: #842727; border-color: #f2baba; background: var(--red-100); }
.alert--success { color: #0f6630; border-color: #a9deba; background: var(--green-100); }
.alert--warning { color: #774607; border-color: #f2cf91; background: var(--amber-100); }
.alert--info { color: var(--navy-800); border-color: #bdd6eb; background: var(--blue-100); }
.message-stack { display: grid; gap: .6rem; margin-bottom: 1rem; }

/* Autenticação */
.auth-body { min-height: 100vh; background: #fff; }
.auth-shell { display: grid; min-height: 100vh; grid-template-columns: minmax(420px, 1.1fr) minmax(420px, .9fr); }
.auth-brand { position: relative; display: flex; min-height: 100vh; flex-direction: column; justify-content: space-between; overflow: hidden; padding: 3.2rem clamp(2rem, 6vw, 6rem); color: #fff; background: radial-gradient(circle at 80% 20%, rgba(31, 123, 192, .52), transparent 35%), linear-gradient(145deg, var(--navy-950), var(--navy-900) 62%, #074e75); }
.auth-brand::after { position: absolute; right: -18%; bottom: -28%; width: 620px; height: 620px; border: 1px solid rgba(255,255,255,.12); border-radius: 50%; content: ""; }
.brand-lockup { display: inline-flex; flex-direction: column; align-items: flex-start; color: #fff; }
.brand-word { font-size: 1.65rem; font-weight: 750; letter-spacing: -.06em; }
.brand-product { color: #a9c9e8; font-size: .66rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.brand-lockup--large .brand-word { font-size: 2rem; }
.auth-brand-copy { position: relative; z-index: 1; max-width: 650px; margin: auto 0; }
.auth-brand-copy h1 { max-width: 600px; font-size: clamp(2.5rem, 5vw, 4.8rem); font-weight: 650; }
.auth-brand-copy p { max-width: 540px; color: #d3e2f0; font-size: 1.1rem; }
.auth-orbit { position: absolute; right: 10%; bottom: 12%; width: 180px; height: 180px; opacity: .35; }
.auth-orbit span { position: absolute; inset: 0; border: 1px solid #63c6ff; border-radius: 50%; }
.auth-orbit span:nth-child(2) { inset: 28px; border-color: #74d497; }
.auth-orbit span:nth-child(3) { inset: 62px; background: rgba(255,255,255,.12); }
.auth-panel { display: grid; place-items: center; padding: 2rem; background: #f8fafc; }
.auth-card { width: min(100%, 470px); padding: clamp(1.5rem, 4vw, 3rem); border: 1px solid var(--line); border-radius: var(--radius-lg); background: #fff; box-shadow: var(--shadow); }
.auth-card__header { margin-bottom: 1.8rem; }
.auth-card__header h2 { font-size: 1.8rem; }
.auth-card__header p { margin-bottom: 0; }
.auth-card__header--center { text-align: center; }
.auth-footer { margin-top: 1.5rem; padding-top: 1.25rem; border-top: 1px solid var(--line); text-align: center; color: var(--ink-500); font-size: .84rem; }
.auth-footer a { font-weight: 800; }
.success-mark { display: grid; width: 58px; height: 58px; place-items: center; margin: 0 auto 1.2rem; border-radius: 50%; color: #fff; background: var(--green-600); font-size: 1.6rem; font-weight: 800; }

/* Estrutura interna */
.app-body { min-height: 100vh; }
.sidebar { position: fixed; z-index: 40; inset: 0 auto 0 0; display: flex; width: var(--sidebar-width); flex-direction: column; padding: 1.8rem 1.1rem 1rem; color: #fff; background: linear-gradient(180deg, var(--navy-950), var(--navy-900)); }
.sidebar .brand-lockup { margin: 0 .65rem 2.5rem; }
.nav-list { display: flex; flex: 1; flex-direction: column; gap: .28rem; }
.nav-item { position: relative; display: flex; min-height: 44px; align-items: center; gap: .75rem; padding: .62rem .72rem; border-radius: 10px; color: #c5d6e7; font-size: .88rem; font-weight: 650; }
.nav-item:hover { color: #fff; background: rgba(255,255,255,.08); }
.nav-item.is-active { color: #fff; background: rgba(255,255,255,.13); box-shadow: inset 3px 0 0 #47c777; }
.nav-icon { display: grid; width: 24px; place-items: center; color: #9ab9d6; font-size: 1.1rem; }
.nav-count { margin-left: auto; padding: .08rem .42rem; border-radius: 20px; color: var(--navy-950); background: #c8e4fb; font-size: .68rem; font-weight: 850; }
.nav-count--warning { color: #633700; background: #ffd797; }
.nav-section { margin: 1.5rem .72rem .45rem; color: #7799b8; font-size: .63rem; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
.sidebar-footer { display: flex; align-items: center; justify-content: space-between; gap: .65rem; padding: 1rem .6rem 0; border-top: 1px solid rgba(255,255,255,.12); }
.user-mini { display: flex; min-width: 0; align-items: center; gap: .6rem; }
.user-mini > span:last-child { display: flex; min-width: 0; flex-direction: column; }
.user-mini strong, .user-mini small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-mini strong { max-width: 120px; font-size: .75rem; }
.user-mini small { max-width: 120px; color: #8fabc5; font-size: .65rem; }
.avatar { display: grid; width: 38px; height: 38px; flex: 0 0 auto; place-items: center; border-radius: 12px; color: var(--navy-900); background: #e5f2fc; font-size: .75rem; font-weight: 850; }
.avatar--small { width: 32px; height: 32px; border-radius: 10px; font-size: .66rem; }
.sidebar-backdrop { display: none; }
.app-shell { min-height: 100vh; margin-left: var(--sidebar-width); }
.topbar { position: sticky; z-index: 30; top: 0; display: flex; height: 70px; align-items: center; justify-content: space-between; padding: 0 clamp(1rem, 3vw, 2.4rem); border-bottom: 1px solid var(--line); background: rgba(255,255,255,.93); backdrop-filter: blur(12px); }
.topbar-title { font-size: .92rem; font-weight: 800; }
.topbar-actions { display: flex; align-items: center; gap: .75rem; }
.icon-button { position: relative; display: grid; width: 38px; height: 38px; place-items: center; border: 1px solid var(--line); border-radius: 11px; color: var(--ink-700); background: #fff; cursor: pointer; }
.button-dot { position: absolute; top: 7px; right: 7px; width: 7px; height: 7px; border: 2px solid #fff; border-radius: 50%; background: var(--red-600); }
.main-content { width: min(100%, 1500px); margin: 0 auto; padding: clamp(1.25rem, 3vw, 2.5rem); }
.page-heading { margin-bottom: 1.7rem; }
.page-heading p { max-width: 760px; margin-bottom: 0; }
.page-heading--split { display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5rem; }
.content-section { margin-top: 2.2rem; }
.section-heading, .card-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.section-heading h2, .card-heading h2 { margin-bottom: 0; }
.section-heading .eyebrow, .card-heading .eyebrow { margin-bottom: .25rem; }

.metric-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 1rem; }
.metric-grid--compact { grid-template-columns: repeat(3, minmax(0, 260px)); }
.metric-card { display: flex; min-height: 120px; align-items: center; gap: 1rem; padding: 1.25rem; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface); box-shadow: 0 5px 18px rgba(8,36,66,.035); }
.metric-card > div { display: flex; flex-direction: column; }
.metric-card small { color: var(--ink-500); font-size: .73rem; font-weight: 750; text-transform: uppercase; }
.metric-card strong { margin: .15rem 0; font-size: 1.75rem; line-height: 1.05; }
.metric-card span:last-child { color: var(--ink-500); font-size: .7rem; }
.metric-icon { display: grid; width: 46px; height: 46px; flex: 0 0 auto; place-items: center; border-radius: 14px; font-size: 1.2rem; font-weight: 850; }
.metric-icon--blue { color: var(--navy-800); background: var(--blue-100); }
.metric-icon--green { color: #117d3a; background: var(--green-100); }
.metric-icon--amber { color: #a86100; background: var(--amber-100); }
.metric-icon--red { color: var(--red-600); background: var(--red-100); }
.metric-card--hero { color: #fff; border-color: transparent; background: linear-gradient(135deg, var(--navy-950), var(--navy-800)); }
.metric-card--hero small, .metric-card--hero span:last-child { color: #b6d0e8; }

.form-card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.form-card { position: relative; display: flex; min-height: 240px; flex-direction: column; padding: 1.35rem; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; }
.form-card::before { position: absolute; top: 0; left: 0; width: 100%; height: 4px; background: var(--navy-700); content: ""; }
.form-card--confidential::before { background: var(--green-600); }
.form-card__top, .form-card__footer { display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.form-card h3 { margin-top: 1.2rem; font-size: 1.2rem; }
.form-card p { flex: 1; font-size: .85rem; }
.form-card__footer { padding-top: 1rem; border-top: 1px solid #edf1f4; color: var(--ink-500); font-size: .72rem; }
.form-badge, .privacy-badge, .role-chip { display: inline-flex; padding: .24rem .5rem; border-radius: 20px; color: var(--navy-800); background: var(--blue-100); font-size: .64rem; font-weight: 800; }
.privacy-badge { color: #0c7735; background: var(--green-100); }
.role-chip { color: #674100; background: var(--amber-100); }

.table-card { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: .9rem 1rem; border-bottom: 1px solid #edf1f4; text-align: left; vertical-align: middle; }
th { color: var(--ink-500); background: #f8fafb; font-size: .67rem; letter-spacing: .06em; text-transform: uppercase; }
td { font-size: .82rem; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: #fbfcfd; }
.table-subtitle, .user-cell small { display: block; margin-top: .15rem; }
.table-action { text-align: right; white-space: nowrap; }
.table-action a { font-size: .75rem; font-weight: 800; }
.user-cell { display: flex; align-items: center; gap: .65rem; }
.user-cell > span:last-child { min-width: 0; }

.status { display: inline-flex; align-items: center; gap: .3rem; padding: .27rem .55rem; border-radius: 20px; font-size: .66rem; font-weight: 800; }
.status::before { width: 6px; height: 6px; border-radius: 50%; background: currentColor; content: ""; }
.status--submitted, .status--approved { color: #11743a; background: var(--green-100); }
.status--draft, .status--pending { color: #9b5b00; background: var(--amber-100); }
.status--reopened { color: var(--navy-700); background: var(--blue-100); }
.status--rejected { color: #a62f2f; background: var(--red-100); }
.empty-state { display: grid; min-height: 270px; place-items: center; align-content: center; padding: 2rem; border: 1px dashed #c4d1dd; border-radius: var(--radius-md); text-align: center; background: rgba(255,255,255,.58); }
.empty-state > span { display: grid; width: 50px; height: 50px; place-items: center; margin-bottom: .8rem; border-radius: 15px; color: var(--navy-700); background: var(--blue-100); font-size: 1.25rem; }
.empty-state h3 { margin: 0; }
.empty-state p { margin: .25rem 0 0; }
.empty-state--small { min-height: 180px; }
.empty-inline { padding: 2rem 1rem; color: var(--ink-500); text-align: center; }

.filter-bar { display: flex; align-items: flex-end; gap: .8rem; margin-bottom: 1.25rem; padding: 1rem; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; }
.filter-field { display: flex; min-width: 210px; flex-direction: column; gap: .3rem; }
.filter-field label { color: var(--ink-500); font-size: .66rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.filter-field select { min-height: 42px; padding: .55rem .7rem; }

/* Formulário */
.form-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; margin-bottom: 1.4rem; }
.form-hero > div:first-child { max-width: 830px; }
.confidential-note { display: flex; max-width: 330px; align-items: center; gap: .75rem; padding: .9rem 1rem; border: 1px solid #a9dec0; border-radius: 13px; color: #0b6630; background: var(--green-100); }
.confidential-note > span { font-size: 1.1rem; }
.confidential-note div { display: flex; flex-direction: column; }
.confidential-note small { color: #397c53; }
.evaluation-form { display: grid; grid-template-columns: 250px minmax(0, 1fr); align-items: start; gap: 1.2rem; }
.form-progress-card { position: sticky; top: 90px; padding: 1rem; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; }
.progress-heading { display: flex; justify-content: space-between; font-size: .72rem; font-weight: 800; }
.progress-track { height: 7px; margin: .7rem 0 1rem; overflow: hidden; border-radius: 20px; background: #e9eef2; }
.progress-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--navy-700), var(--green-600)); transition: width .2s; }
.section-index { display: flex; flex-direction: column; gap: .15rem; }
.section-index a { display: flex; align-items: center; gap: .55rem; padding: .45rem .35rem; border-radius: 8px; color: var(--ink-500); font-size: .68rem; line-height: 1.25; }
.section-index a:hover { color: var(--navy-800); background: var(--blue-100); }
.section-index span { display: grid; width: 25px; height: 25px; flex: 0 0 auto; place-items: center; border-radius: 7px; color: var(--navy-700); background: var(--blue-100); font-size: .58rem; font-weight: 850; }
.form-main { min-width: 0; }
.form-section-card { margin-bottom: 1rem; padding: clamp(1rem, 2.5vw, 1.75rem); scroll-margin-top: 90px; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; }
.metadata-card { border-top: 4px solid var(--navy-700); }
.section-number { margin-bottom: .42rem; color: var(--navy-700); font-size: .67rem; font-weight: 850; letter-spacing: .09em; text-transform: uppercase; }
.form-section-card > p { font-size: .84rem; }
.question-stack { display: grid; gap: .8rem; margin-top: 1.2rem; }
.question-card { padding: 1.15rem; border: 1px solid #e0e7ed; border-radius: 13px; background: #fbfcfd; }
.question-card--error { border-color: #e9a5a5; background: #fffafa; }
.question-heading { display: flex; gap: .8rem; margin-bottom: 1rem; }
.question-heading h3 { display: flex; align-items: center; gap: .5rem; margin-bottom: .25rem; }
.question-heading h3 small { padding: .15rem .4rem; border-radius: 20px; background: #eef2f5; font-size: .6rem; font-weight: 650; }
.question-heading p { margin: 0; font-size: .84rem; }
.question-number { display: grid; width: 30px; height: 30px; flex: 0 0 auto; place-items: center; border-radius: 9px; color: #fff; background: var(--navy-900); font-size: .72rem; font-weight: 850; }
.rating-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: .45rem; }
.rating-option { position: relative; display: flex; min-height: 92px; flex-direction: column; align-items: center; justify-content: center; gap: .25rem; padding: .5rem; border: 1px solid #d7e0e7; border-radius: 10px; cursor: pointer; text-align: center; background: #fff; transition: .15s; }
.rating-option:hover { border-color: var(--navy-700); }
.rating-option input, .choice-option input { position: absolute; opacity: 0; pointer-events: none; }
.rating-option:has(input:checked) { border-color: var(--navy-700); background: var(--blue-100); box-shadow: inset 0 0 0 1px var(--navy-700); }
.rating-option--na:has(input:checked) { border-color: var(--amber-600); background: var(--amber-100); box-shadow: inset 0 0 0 1px var(--amber-600); }
.rating-value { display: grid; width: 28px; height: 28px; place-items: center; border-radius: 8px; color: var(--navy-800); background: var(--blue-100); font-weight: 850; }
.rating-label { color: var(--ink-700); font-size: .62rem; line-height: 1.2; }
.choice-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: .55rem; }
.choice-option { position: relative; display: flex; min-height: 50px; align-items: center; justify-content: center; padding: .65rem; border: 1px solid #d5dfe7; border-radius: 10px; cursor: pointer; text-align: center; background: #fff; font-size: .78rem; font-weight: 750; }
.choice-option:has(input:checked) { color: var(--navy-900); border-color: var(--navy-700); background: var(--blue-100); box-shadow: inset 0 0 0 1px var(--navy-700); }
.score-grid { display: grid; grid-template-columns: repeat(11, minmax(44px, 1fr)); gap: .4rem; }
.score-option { position: relative; display: grid; min-height: 54px; place-items: center; border: 1px solid #d5dfe7; border-radius: 10px; cursor: pointer; background: #fff; font-weight: 850; }
.score-option input { position: absolute; opacity: 0; pointer-events: none; }
.score-option:has(input:checked) { color: var(--navy-900); border-color: var(--navy-700); background: var(--blue-100); box-shadow: inset 0 0 0 1px var(--navy-700); }
.conditional-other { margin-top: .8rem; }
.conditional-other label { display: block; margin-bottom: .35rem; color: var(--ink-700); font-size: .72rem; font-weight: 750; }
.form-actions { position: sticky; z-index: 20; bottom: 1rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 1rem; padding: 1rem 1.2rem; border: 1px solid #b9c8d5; border-radius: 14px; background: rgba(255,255,255,.96); box-shadow: 0 14px 35px rgba(8,36,66,.16); backdrop-filter: blur(12px); }
.form-actions > div:first-child { display: flex; flex-direction: column; }

/* Detalhe */
.detail-summary { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1px; margin-bottom: 1rem; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--line); }
.detail-summary > div { display: flex; min-height: 90px; flex-direction: column; justify-content: center; padding: 1rem; background: #fff; }
.detail-summary small { margin-bottom: .35rem; font-size: .66rem; font-weight: 800; text-transform: uppercase; }
.detail-summary strong { font-size: .85rem; }
.admin-action-card { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; padding: 1rem 1.2rem; border: 1px solid #f0ca87; border-radius: var(--radius-md); background: var(--amber-100); }
.admin-action-card p { margin: 0; color: #7a5720; font-size: .8rem; }
.detail-sections { display: grid; gap: 1rem; }
.detail-card { padding: 1.3rem; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; }
.answer-row { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(200px, .6fr); align-items: start; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid #edf1f4; }
.answer-row:last-child { border-bottom: 0; }
.answer-row > div { display: flex; gap: .65rem; }
.answer-row > div > span { display: grid; width: 26px; height: 26px; flex: 0 0 auto; place-items: center; border-radius: 8px; color: var(--navy-700); background: var(--blue-100); font-size: .65rem; font-weight: 850; }
.answer-row h3 { margin-bottom: .2rem; font-size: .86rem; }
.answer-row p { margin: 0; font-size: .76rem; }
.answer-row > strong { color: var(--ink-700); font-size: .82rem; font-weight: 650; }

/* Dashboard */
.dashboard-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin-top: 1rem; }
.dashboard-card { min-width: 0; padding: 1.25rem; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; }
.dashboard-card--wide { grid-column: span 2; }
.bar-list { display: grid; gap: .9rem; }
.bar-row > div:first-child { display: flex; justify-content: space-between; gap: 1rem; margin-bottom: .3rem; font-size: .78rem; }
.bar-track { height: 9px; overflow: hidden; border-radius: 20px; background: #e9eef2; }
.bar-track span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--navy-700), #3b8fc4); }
.bar-row small { font-size: .62rem; }
.distribution-chart { display: flex; height: 220px; align-items: flex-end; justify-content: space-around; gap: .7rem; padding-top: 1rem; }
.distribution-column { display: grid; height: 100%; flex: 1; grid-template-rows: 20px 1fr 20px; text-align: center; }
.distribution-column > div { position: relative; height: 100%; overflow: hidden; border-radius: 8px 8px 3px 3px; background: #edf2f6; }
.distribution-column > div span { position: absolute; right: 0; bottom: 0; left: 0; min-height: 3px; border-radius: inherit; background: var(--navy-700); }
.distribution-column strong { font-size: .7rem; }
.distribution-column small { align-self: end; font-weight: 850; }
.summary-list { display: grid; gap: .65rem; }
.summary-list > div { display: flex; align-items: center; justify-content: space-between; padding: .65rem .75rem; border-radius: 9px; background: #f5f8fa; font-size: .78rem; }
.summary-list strong { display: grid; width: 30px; height: 30px; place-items: center; border-radius: 8px; color: var(--navy-800); background: var(--blue-100); }
.score-pill, .delta { display: inline-flex; min-width: 48px; justify-content: center; padding: .25rem .45rem; border-radius: 20px; color: #0f7037; background: var(--green-100); font-size: .7rem; font-weight: 850; }
.score-pill--attention, .delta--negative { color: #a02e2e; background: var(--red-100); }
.attention-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
.attention-card { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .9rem 1rem; border: 1px solid #ead0d0; border-radius: 12px; background: #fffafa; }
.attention-card div { display: flex; flex-direction: column; }
.attention-card span:not(.score-pill) { color: var(--ink-500); font-size: .68rem; }

/* Administração */
.admin-form { display: grid; gap: 1rem; }
.settings-card { padding: 1.35rem; border: 1px solid var(--line); border-radius: var(--radius-md); background: #fff; }
.settings-card__heading { margin-bottom: 1.2rem; }
.settings-card__heading p { margin-bottom: 0; font-size: .82rem; }
.switch-row { display: flex; align-items: flex-start; gap: .75rem; margin-top: 1.2rem; padding: .9rem; border-radius: 11px; background: #f6f8fa; cursor: pointer; }
.switch-row input { width: 18px; height: 18px; margin-top: .15rem; }
.switch-row span { display: flex; flex-direction: column; }
.profile-field { max-width: 480px; margin-bottom: 1rem; }
.permission-table { overflow: hidden; border: 1px solid var(--line); border-radius: 12px; }
.permission-row { display: grid; grid-template-columns: minmax(260px, 2fr) repeat(4, minmax(80px, .5fr)); align-items: center; min-height: 62px; border-bottom: 1px solid var(--line); }
.permission-row:last-child { border-bottom: 0; }
.permission-row > * { padding: .65rem .8rem; text-align: center; }
.permission-row > div:first-child { display: flex; flex-direction: column; text-align: left; }
.permission-row input { width: 18px; height: 18px; accent-color: var(--navy-700); }
.permission-row--header { min-height: 42px; color: var(--ink-500); background: #f7f9fa; font-size: .64rem; font-weight: 850; text-transform: uppercase; }
.permission-row--header span:first-child { text-align: left; }
.sticky-save { position: sticky; z-index: 20; bottom: 1rem; display: flex; justify-content: flex-end; gap: .7rem; padding: .8rem; border: 1px solid var(--line); border-radius: 13px; background: rgba(255,255,255,.96); box-shadow: var(--shadow); }

.notification-list { display: grid; gap: .65rem; }
.notification-item { display: flex; align-items: flex-start; gap: .85rem; padding: 1rem; border: 1px solid var(--line); border-radius: 13px; color: inherit; background: #fff; }
.notification-item.is-unread { border-color: #aac9e2; box-shadow: inset 4px 0 0 var(--navy-700); }
.notification-symbol { display: grid; width: 36px; height: 36px; flex: 0 0 auto; place-items: center; border-radius: 11px; font-weight: 850; }
.notification-symbol--info { color: var(--navy-700); background: var(--blue-100); }
.notification-symbol--success { color: #0e7437; background: var(--green-100); }
.notification-symbol--warning { color: #9a5900; background: var(--amber-100); }
.notification-item p { margin: .15rem 0; font-size: .8rem; }
.notification-item small { font-size: .65rem; }
.error-page { display: grid; min-height: 65vh; place-items: center; align-content: center; text-align: center; }
.error-page > span { color: #b9c7d3; font-size: 5rem; font-weight: 850; }

@media (max-width: 1180px) {
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .form-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rating-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .detail-summary { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .mobile-only { display: grid !important; }
  .sidebar { transform: translateX(-100%); transition: transform .2s ease; }
  .sidebar.is-open { transform: translateX(0); }
  .sidebar-backdrop { position: fixed; z-index: 35; inset: 0; background: rgba(0, 20, 42, .45); }
  .sidebar.is-open + .sidebar-backdrop { display: block; }
  .app-shell { margin-left: 0; }
  .auth-shell { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .auth-panel { min-height: 100vh; }
  .evaluation-form { grid-template-columns: 1fr; }
  .form-progress-card { position: relative; top: auto; }
  .section-index { display: none; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .dashboard-card--wide { grid-column: auto; }
  .permission-table { overflow-x: auto; }
  .permission-row { min-width: 720px; }
  .score-grid { grid-template-columns: repeat(6, minmax(44px, 1fr)); }
}

@media (max-width: 680px) {
  .main-content { padding: 1rem; }
  .topbar { height: 60px; }
  .page-heading--split, .form-hero, .form-actions, .admin-action-card { align-items: stretch; flex-direction: column; }
  .metric-grid, .metric-grid--compact, .form-card-grid, .field-grid--2, .field-grid--3, .attention-grid { grid-template-columns: 1fr; }
  .metric-card { min-height: 95px; }
  .filter-bar { align-items: stretch; flex-direction: column; }
  .filter-field { min-width: 0; }
  .rating-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rating-option { min-height: 82px; }
  .score-grid { grid-template-columns: repeat(4, minmax(44px, 1fr)); }
  .detail-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .answer-row { grid-template-columns: 1fr; }
  .form-actions { position: static; }
  .form-actions .button-row .btn { flex: 1; }
  .auth-panel { padding: .8rem; }
  .auth-card { padding: 1.35rem; border-radius: 18px; }
}
