:root {
  --verde: #003828;
  --verde-900: #00241a;
  --verde-800: #012c20;
  --verde-700: #0b4a39;
  --cobre: #b07038;
  --cobre-claro: #dcae7a;
  --creme: #f7f3ec;
  --areia: #eee8dd;
  --linha: rgba(0, 56, 40, 0.1);
  --muted: #5d6c65;
  --texto: #10241d;
  --risco: 16px;
  --sidebar: 272px;
  --font: "Plus Jakarta Sans", system-ui, sans-serif;
  --shadow-soft: 0 18px 40px -28px rgba(0, 36, 26, 0.45);
  --shadow-card: 0 14px 36px -22px rgba(0, 36, 26, 0.4);
}
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--font); color: var(--texto);
  background:
    radial-gradient(ellipse 80% 50% at 100% -10%, rgba(176,112,56,.08), transparent 50%),
    radial-gradient(ellipse 60% 40% at 0% 100%, rgba(0,56,40,.06), transparent 45%),
    #f3f5f4;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
img { max-width: 100%; display: block; }

/* ========== Login (hero móvel · ref. Ariane) ========== */
.login {
  min-height: 100dvh; display: flex; position: relative; overflow: hidden;
  background: var(--verde-900); color: #fff;
}
.login__photo {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center 42%;
  image-rendering: auto;
}
.login__veil {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(0,18,12,.94) 0%, rgba(0,18,12,.78) 36%, rgba(0,18,12,.35) 62%, rgba(0,18,12,.12) 100%),
    linear-gradient(180deg, rgba(0,0,0,.28) 0%, transparent 35%, rgba(0,0,0,.45) 100%);
}
.login__wrap {
  position: relative; z-index: 1; width: 100%;
  display: grid; grid-template-columns: 1.15fr 1fr; min-height: 100dvh;
}
.login__brand {
  padding: clamp(1.5rem, 4vw, 3.5rem);
  padding-bottom: clamp(1.85rem, 4.5vw, 3.75rem);
  display: flex; flex-direction: column; justify-content: space-between;
}
.login__brand img { height: 58px; width: auto; filter: drop-shadow(0 8px 18px rgba(0,0,0,.35)); }
.login__eyebrow {
  display: inline-flex; align-items: center; gap: .5rem;
  border: 1px solid rgba(255,255,255,.16); background: rgba(0,0,0,.38);
  border-radius: 99px; padding: .45rem .9rem; font-size: .68rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase; color: var(--cobre-claro);
  backdrop-filter: blur(8px);
}
.login__eyebrow svg { width: .95rem; height: .95rem; color: var(--cobre); }
.login__brand h2 {
  margin: 1.1rem 0 0; font-size: clamp(1.85rem, 3.6vw, 2.85rem);
  line-height: 1.12; font-weight: 700; letter-spacing: -.03em; max-width: 14ch;
  text-shadow: 0 12px 40px rgba(0,0,0,.35);
}
.login__brand h2 em { color: var(--cobre-claro); font-style: normal; }
.login__features {
  margin: 1.7rem 0 0; padding: 0; list-style: none;
  display: grid; grid-template-columns: 1fr 1fr; gap: .75rem;
  max-width: 34rem;
}
.login__features li {
  display: flex; align-items: flex-start; gap: .7rem;
  padding: .85rem .9rem; border-radius: 14px;
  border: 1px solid rgba(255,255,255,.1); background: rgba(0,0,0,.28);
  backdrop-filter: blur(8px);
}
.login__feat-ico {
  width: 2rem; height: 2rem; border-radius: 10px; flex: none;
  display: grid; place-items: center;
  background: rgba(176,112,56,.16); color: var(--cobre-claro);
}
.login__feat-ico svg { width: 1.05rem; height: 1.05rem; }
.login__features strong {
  display: block; font-size: .88rem; font-weight: 700; color: #fff; letter-spacing: -.01em;
}
.login__features small {
  display: block; margin-top: .2rem; font-size: .75rem; line-height: 1.35;
  color: rgba(255,255,255,.62);
}
.login__copy {
  font-size: .78rem; color: rgba(255,255,255,.42);
  margin: .85rem 0 0; padding-top: .35rem;
}

.login__panel {
  display: flex; align-items: center; justify-content: flex-end;
  padding: clamp(1rem, 3vw, 2.5rem);
}
.login__card {
  width: 100%; max-width: 420px; background: #fff; color: var(--texto);
  border-radius: 22px; padding: clamp(1.5rem, 3vw, 2.25rem);
  border: 1px solid rgba(255,255,255,.45);
  box-shadow: 0 30px 70px -24px rgba(0,0,0,.55);
  animation: scaleIn .45s ease;
}
.login__card .kicker {
  display: flex; align-items: center; gap: .55rem; margin-bottom: .7rem;
  font-size: .68rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: #8a9590;
}
.login__card .kicker i { width: 1.4rem; height: 1px; background: var(--cobre); display: inline-block; }
.login__card h1 { margin: 0; font-size: 1.65rem; letter-spacing: -.02em; color: var(--verde); }
.login__card .sub { margin: .45rem 0 1.4rem; color: var(--muted); font-size: .92rem; }

.field { margin-bottom: 1rem; }
.field label {
  display: flex; align-items: center; gap: .4rem; margin-bottom: .4rem;
  font-size: .86rem; font-weight: 600; color: var(--verde);
}
.field label svg { width: .9rem; height: .9rem; color: var(--cobre); }
.field__control { position: relative; }
.field__control > svg {
  position: absolute; left: 1rem; top: 50%; transform: translateY(-50%);
  width: 1rem; height: 1rem; color: #9aa6a0; pointer-events: none;
}
.field input, .field select, .field textarea {
  width: 100%; border: 1px solid var(--linha); background: #f7f8f7; border-radius: 14px;
  padding: .9rem 1rem; outline: none; transition: .2s;
}
.field__control input { padding-left: 2.65rem; padding-right: 2.75rem; }
.field textarea { min-height: 110px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  background: #fff; border-color: rgba(176,112,56,.55); box-shadow: 0 0 0 4px rgba(176,112,56,.14);
}
.field__eye {
  position: absolute; right: .55rem; top: 50%; transform: translateY(-50%);
  width: 2.2rem; height: 2.2rem; border: 0; border-radius: 10px; background: transparent;
  color: #9aa6a0; cursor: pointer; display: grid; place-items: center;
}
.field__eye:hover, .field__eye.is-on { color: var(--verde); background: rgba(0,56,40,.06); }
.field__eye svg { width: 1.05rem; height: 1.05rem; }
.field--check { display: flex; align-items: center; gap: .55rem; }
.field--check input { width: auto; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  min-height: 2.85rem; padding: 0 1.15rem; border-radius: 12px; border: 1px solid transparent;
  font-weight: 700; font-size: .9rem; cursor: pointer; transition: .2s;
}
.btn svg { width: 1.05rem; height: 1.05rem; }
.btn--primary {
  background: linear-gradient(135deg, var(--verde-700), var(--verde));
  color: #fff; width: 100%; min-height: 3.15rem;
  box-shadow: 0 14px 28px -16px rgba(0,56,40,.65);
}
.btn--primary:hover { filter: brightness(1.06); transform: translateY(-1px); }
.btn--cobre { background: var(--cobre); color: #fff; box-shadow: 0 10px 22px -14px rgba(176,112,56,.7); }
.btn--cobre:hover { filter: brightness(1.05); }
.btn--ghost { background: transparent; border-color: var(--linha); color: var(--verde); }
.btn--ghost:hover { background: rgba(0,56,40,.04); }
.btn--danger { background: #8f2f2f; color: #fff; }
.btn--sm { min-height: 2.2rem; padding: 0 .8rem; font-size: .8rem; }
.btn--block { width: 100%; }

.login__sep {
  display: flex; align-items: center; gap: .75rem; margin-top: 1.35rem;
  color: #a3aea8; font-size: .75rem; font-weight: 600;
}
.login__sep span { flex: 1; height: 1px; background: #e7ebe9; }
.login__sep a:hover { color: var(--verde); }

.alert {
  border-radius: 12px; padding: .85rem 1rem; margin-bottom: 1rem; font-size: .9rem; font-weight: 600;
}
.alert--error { background: #fde8e8; color: #7a1f1f; }
.alert--success { background: #e6f5ec; color: #145c36; }
.alert--info { background: #eef4f1; color: var(--verde); }

/* ========== Toasts (ref. Ariane) ========== */
.toast-host {
  pointer-events: none; position: fixed; z-index: 120;
  display: flex; flex-direction: column; gap: .65rem;
  bottom: 1.25rem; right: 1.25rem; width: min(26rem, calc(100% - 2rem));
}
.toast {
  pointer-events: auto; position: relative; overflow: hidden;
  display: grid; grid-template-columns: auto auto 1fr auto; gap: .75rem; align-items: start;
  background: rgba(255,255,255,.96); border: 1px solid rgba(0,56,40,.1);
  border-radius: 16px; padding: .95rem 1rem .95rem 1.1rem;
  box-shadow: 0 18px 40px -18px rgba(0,24,17,.4);
  backdrop-filter: blur(10px);
  animation: toastUp .35s ease;
}
.toast.is-leaving { opacity: 0; transform: translateY(8px); transition: .2s; }
.toast__accent {
  position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
}
.toast--success .toast__accent { background: var(--verde); }
.toast--error .toast__accent { background: #d64545; }
.toast--info .toast__accent { background: var(--cobre); }
.toast__ico {
  width: 2.25rem; height: 2.25rem; border-radius: 12px; display: grid; place-items: center;
}
.toast__ico svg { width: 1.1rem; height: 1.1rem; }
.toast--success .toast__ico { background: rgba(0,56,40,.1); color: var(--verde); }
.toast--error .toast__ico { background: #fde8e8; color: #b42318; }
.toast--info .toast__ico { background: rgba(176,112,56,.12); color: var(--cobre); }
.toast__label {
  margin: 0; font-size: .68rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: rgba(16,36,29,.55);
}
.toast__msg { margin: .15rem 0 0; font-size: .9rem; font-weight: 600; color: var(--texto); line-height: 1.35; }
.toast__close {
  border: 0; background: transparent; color: #8a9590; cursor: pointer;
  width: 1.8rem; height: 1.8rem; border-radius: 10px; font-size: 1.15rem; line-height: 1;
}
.toast__close:hover { background: #f3f5f4; color: var(--verde); }
.toast__bar {
  position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: rgba(0,56,40,.06);
}
.toast__bar i {
  display: block; height: 100%; width: 100%; transform-origin: left center;
  animation: toastBar linear forwards;
}
.toast--success .toast__bar i { background: var(--verde); }
.toast--error .toast__bar i { background: #d64545; }
.toast--info .toast__bar i { background: var(--cobre); }

@keyframes toastUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}
@keyframes toastBar {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}
@keyframes scaleIn {
  from { opacity: 0; transform: translateY(10px) scale(.98); }
  to { opacity: 1; transform: none; }
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

/* ========== App shell ========== */
.app { min-height: 100dvh; }
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--sidebar); z-index: 40;
  background:
    radial-gradient(circle at 20% 0%, rgba(176,112,56,.22), transparent 42%),
    linear-gradient(180deg, var(--verde-900), var(--verde-800) 45%, var(--verde));
  color: #fff; padding: 1rem .9rem; display: flex; flex-direction: column; gap: .85rem;
  box-shadow: 12px 0 40px -28px rgba(0,0,0,.55);
}
.sidebar__brand {
  padding: .55rem .65rem 1rem; border-bottom: 1px solid rgba(255,255,255,.1);
  display: grid; gap: .55rem;
}
.sidebar__brand img { height: 42px; width: auto; }
.sidebar__brand span {
  display: inline-flex; align-items: center; gap: .4rem;
  font-size: .66rem; letter-spacing: .14em; text-transform: uppercase;
  color: var(--cobre-claro); font-weight: 700;
}
.sidebar__section {
  margin: .55rem .55rem .2rem; font-size: .65rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase; color: rgba(255,255,255,.38);
}
.sidebar__nav { display: grid; gap: .28rem; flex: 1; align-content: start; }
.sidebar__link {
  display: flex; align-items: center; gap: .75rem; padding: .72rem .8rem; border-radius: 14px;
  color: rgba(255,255,255,.78); font-weight: 600; font-size: .9rem; transition: .2s;
}
.sidebar__link:hover { background: rgba(255,255,255,.07); color: #fff; }
.sidebar__link.is-active {
  background: linear-gradient(135deg, rgba(176,112,56,.28), rgba(176,112,56,.14));
  color: #fff; box-shadow: inset 0 0 0 1px rgba(176,112,56,.22);
}
.sidebar__ico {
  width: 2rem; height: 2rem; border-radius: 10px; display: grid; place-items: center;
  background: rgba(255,255,255,.08); flex: none; transition: .2s;
}
.sidebar__ico svg { width: 1.05rem; height: 1.05rem; }
.sidebar__link:hover .sidebar__ico { transform: scale(1.06); }
.sidebar__link.is-active .sidebar__ico {
  background: rgba(176,112,56,.28); color: var(--cobre-claro);
}
.sidebar__foot {
  padding: .75rem .65rem 0; border-top: 1px solid rgba(255,255,255,.1);
  display: grid; gap: .55rem;
}
.sidebar__user-mini {
  display: flex; align-items: center; gap: .65rem; padding: .45rem;
  border-radius: 14px; background: rgba(255,255,255,.05);
}
.sidebar__avatar {
  width: 2.2rem; height: 2.2rem; border-radius: 11px; flex: none;
  display: grid; place-items: center; font-size: .75rem; font-weight: 800;
  background: linear-gradient(135deg, var(--cobre), #8a5520); color: #fff;
}
.sidebar__user-mini strong { display: block; font-size: .78rem; line-height: 1.2; }
.sidebar__user-mini small { color: rgba(255,255,255,.5); font-size: .68rem; }
.sidebar__foot a { font-size: .8rem; color: rgba(255,255,255,.55); padding: .2rem .45rem; }
.sidebar__foot a:hover { color: var(--cobre-claro); }

.shell { margin-left: var(--sidebar); min-height: 100dvh; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: .9rem;
  padding: .95rem 1.35rem; background: rgba(255,255,255,.86); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--linha); box-shadow: 0 10px 30px -28px rgba(0,36,26,.35);
}
.topbar__titles { flex: 1; min-width: 0; }
.topbar__eyebrow {
  font-size: .68rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--cobre); margin-bottom: .1rem;
}
.topbar__title {
  font-weight: 780; color: var(--verde); letter-spacing: -.02em; font-size: 1.12rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.topbar__user { display: flex; align-items: center; gap: .75rem; }
.topbar__meta { text-align: right; line-height: 1.2; }
.topbar__meta strong { display: block; font-size: .86rem; color: var(--verde); }
.topbar__meta small { color: var(--muted); font-size: .72rem; }
.topbar__avatar {
  width: 2.45rem; height: 2.45rem; border-radius: 12px;
  display: grid; place-items: center; font-size: .78rem; font-weight: 800;
  background: linear-gradient(135deg, var(--verde-700), var(--verde)); color: #fff;
  box-shadow: 0 8px 18px -12px rgba(0,56,40,.7);
}
.icon-btn {
  display: none; width: 2.55rem; height: 2.55rem; border: 0; border-radius: 12px;
  background: var(--creme); color: var(--verde); cursor: pointer;
}
.content { padding: 1.35rem clamp(1rem, 2.5vw, 1.9rem) 2.8rem; }

.page-hero {
  display: flex; flex-wrap: wrap; gap: 1rem; align-items: flex-end;
  justify-content: space-between; margin-bottom: 1.35rem;
  animation: fadeUp .4s ease;
}
.page-hero h1 {
  margin: 0; font-size: clamp(1.35rem, 2.2vw, 1.7rem); color: var(--verde);
  letter-spacing: -.03em;
}
.page-hero p { margin: .35rem 0 0; color: var(--muted); max-width: 42ch; }

.cards { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 1rem; margin-bottom: 1.4rem; }
.card {
  position: relative; overflow: hidden;
  background: #fff; border: 1px solid var(--linha); border-radius: 20px;
  padding: 1.15rem 1.2rem; box-shadow: var(--shadow-card);
  animation: fadeUp .45s ease both;
}
.card:nth-child(2) { animation-delay: .05s; }
.card:nth-child(3) { animation-delay: .1s; }
.card:nth-child(4) { animation-delay: .15s; }
.card::after {
  content: ""; position: absolute; right: -20%; top: -40%; width: 120px; height: 120px;
  border-radius: 50%; background: radial-gradient(circle, rgba(176,112,56,.12), transparent 70%);
  pointer-events: none;
}
.card__top { display: flex; align-items: center; justify-content: space-between; gap: .6rem; }
.card__label { font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.card__icon {
  width: 2.35rem; height: 2.35rem; border-radius: 12px; display: grid; place-items: center;
  background: rgba(0,56,40,.07); color: var(--verde);
}
.card__icon svg { width: 1.15rem; height: 1.15rem; }
.card__icon--cobre { background: rgba(176,112,56,.12); color: var(--cobre); }
.card__value { margin-top: .55rem; font-size: 1.9rem; font-weight: 800; color: var(--verde); letter-spacing: -.03em; }
.card__hint { margin-top: .25rem; font-size: .78rem; color: var(--muted); }

.panel {
  background: #fff; border: 1px solid var(--linha); border-radius: 20px; overflow: hidden;
  box-shadow: var(--shadow-card); animation: fadeUp .5s ease;
}
.panel__head {
  display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; justify-content: space-between;
  padding: 1.05rem 1.2rem; border-bottom: 1px solid var(--linha);
  background: linear-gradient(180deg, #fcfdfc, #fff);
}
.panel__head h2 { margin: 0; font-size: 1.05rem; color: var(--verde); }
.panel__head .muted { margin: .2rem 0 0; }
.toolbar { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.toolbar input, .toolbar select {
  border: 1px solid var(--linha); border-radius: 10px; background: #fff; padding: .55rem .75rem; min-height: 2.4rem;
}

.table-wrap { overflow: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: .9rem 1.1rem; border-bottom: 1px solid var(--linha); text-align: left; font-size: .9rem; vertical-align: middle; }
th {
  font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
  background: #f8faf9; font-weight: 700;
}
tr:last-child td { border-bottom: 0; }
tr:hover td { background: #fbfcfb; }
.bar {
  display: flex; align-items: center; gap: .75rem;
}
.bar__track {
  flex: 1; height: .45rem; border-radius: 99px; background: #eef1ef; overflow: hidden;
}
.bar__fill {
  height: 100%; border-radius: inherit;
  background: linear-gradient(90deg, var(--verde), var(--cobre));
}
.thumb {
  width: 52px; height: 40px; object-fit: cover; border-radius: 8px; background: var(--areia);
}
.badge {
  display: inline-flex; align-items: center; border-radius: 99px; padding: .2rem .55rem;
  font-size: .72rem; font-weight: 700;
}
.badge--ok { background: #e6f5ec; color: #145c36; }
.badge--off { background: #f1f1f1; color: #666; }
.badge--star { background: #f8efe4; color: #8a5520; }
.actions { display: flex; gap: .4rem; flex-wrap: wrap; }

.form-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 1.2rem; }
.form-card { background: #fff; border: 1px solid var(--linha); border-radius: 20px; padding: 1.2rem; box-shadow: var(--shadow-card); }
.form-card__title {
  margin: 0 0 1rem; font-size: .72rem; font-weight: 800; letter-spacing: .12em;
  text-transform: uppercase; color: var(--cobre);
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: .85rem; }
.field-row--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.form-actions { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1rem; }
.file-field { margin: 0 0 1rem; }
.file-field__input {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.file-field__drop {
  display: grid; justify-items: center; gap: .45rem; text-align: center;
  padding: 1.35rem 1rem 1.2rem; cursor: pointer;
  border: 1.5px dashed rgba(0,56,40,.28); border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(0,56,40,.035), rgba(0,56,40,.01)),
    #fff;
  transition: border-color .2s, background .2s, box-shadow .2s;
}
.file-field__drop:hover,
.file-field.is-dragover .file-field__drop,
.file-field__input:focus-visible + .file-field__drop {
  border-color: var(--cobre);
  background: rgba(176,112,56,.06);
  box-shadow: 0 10px 28px -22px rgba(0,56,40,.45);
}
.file-field__icon {
  display: grid; place-items: center;
  width: 2.7rem; height: 2.7rem; border-radius: 14px;
  background: rgba(0,56,40,.07); color: var(--verde);
}
.file-field__icon svg { width: 1.35rem; height: 1.35rem; }
.file-field__title {
  font-size: .95rem; font-weight: 800; color: var(--verde); letter-spacing: -.01em;
}
.file-field__hint {
  font-size: .78rem; color: var(--muted); max-width: 16rem; line-height: 1.35;
}
.file-field__btn {
  display: inline-flex; align-items: center; justify-content: center;
  margin-top: .35rem; min-height: 2.35rem; padding: 0 1.05rem;
  border-radius: 999px; font-size: .8rem; font-weight: 700;
  background: var(--verde); color: #fff;
  box-shadow: 0 10px 22px -14px rgba(0,56,40,.7);
}
.file-field__drop:hover .file-field__btn { filter: brightness(1.05); }
.file-field.has-files .file-field__drop {
  border-style: solid; border-color: rgba(0,56,40,.18);
}
.file-field__status {
  margin: .55rem 0 0; font-size: .8rem; font-weight: 600; color: var(--verde);
}
.upload-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: .65rem; margin: .4rem 0 1rem;
}
.upload-card {
  display: grid; gap: .35rem; cursor: pointer;
  border: 1px solid var(--linha); border-radius: 12px; overflow: hidden; background: #f7f8f7;
}
.upload-card img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.upload-card__check {
  display: flex; align-items: center; gap: .35rem; padding: .35rem .5rem .55rem;
  font-size: .72rem; font-weight: 600; color: var(--muted);
}
.upload-card__check input { width: auto; }
.adv-paths {
  margin-top: .6rem; border: 1px dashed var(--linha); border-radius: 12px; padding: .55rem .8rem;
}
.adv-paths summary {
  cursor: pointer; font-size: .82rem; font-weight: 700; color: var(--verde);
}
.adv-paths[open] summary { margin-bottom: .7rem; }
.status-badges { display: flex; flex-wrap: wrap; gap: .45rem; align-items: center; }
@media (max-width: 640px) {
  .field-row, .field-row--3 { grid-template-columns: 1fr; }
}
.muted { color: var(--muted); font-size: .86rem; }
.empty {
  padding: 2rem 1.2rem; text-align: center; color: var(--muted);
}
.scrim { display: none; }

@media (max-width: 1100px) {
  .cards { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .form-grid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .login__wrap { grid-template-columns: 1fr; }
  .login__brand { padding-bottom: .5rem; }
  .login__features { grid-template-columns: 1fr 1fr; gap: .55rem; margin-top: 1.2rem; }
  .login__features li { padding: .7rem .75rem; }
  .login__features small { display: none; }
  .login__copy { display: none; }
  .login__panel { justify-content: center; align-items: flex-start; padding-top: 0; }
  .login__photo { object-position: center 30%; }
  .toast-host {
    left: 1rem; right: 1rem; bottom: auto; top: max(.75rem, env(safe-area-inset-top));
    width: auto;
  }
  .toast { animation-name: toastDown; }
  @keyframes toastDown {
    from { opacity: 0; transform: translateY(-12px); }
    to { opacity: 1; transform: none; }
  }
  .sidebar {
    transform: translateX(-105%); transition: transform .35s ease; width: min(86vw, 300px);
  }
  .sidebar.is-open { transform: none; }
  .shell { margin-left: 0; }
  .icon-btn { display: inline-grid; place-items: center; }
  .scrim.is-open {
    display: block; position: fixed; inset: 0; background: rgba(0,24,17,.55); z-index: 30;
  }
}
@media (max-width: 640px) {
  .cards { grid-template-columns: 1fr; }
  .topbar__meta { display: none; }
}

/* ========== Sheet / modal (não fecha ao clicar fora) ========== */
.sheet {
  position: fixed; inset: 0; z-index: 90;
  display: flex; align-items: center; justify-content: center;
  padding: 1rem; opacity: 0; pointer-events: none;
  transition: opacity .22s ease;
}
.sheet.is-open { opacity: 1; pointer-events: auto; }
.sheet__backdrop {
  position: absolute; inset: 0;
  background: rgba(0, 18, 12, .58);
  backdrop-filter: blur(4px);
}
.sheet__panel {
  position: relative; z-index: 1;
  width: min(960px, 100%);
  max-height: min(92dvh, 900px);
  display: flex; flex-direction: column;
  background: #fff; border-radius: 20px;
  box-shadow: 0 30px 80px -24px rgba(0,0,0,.5);
  overflow: hidden;
  transform: translateY(14px) scale(.98);
  transition: transform .28s ease;
}
.sheet.is-open .sheet__panel { transform: none; }
.sheet--sm .sheet__panel { width: min(520px, 100%); }
.sheet--lg .sheet__panel { width: min(1100px, 100%); }
.sheet__head {
  display: flex; align-items: center; gap: .75rem;
  padding: 1rem 1.15rem; border-bottom: 1px solid var(--linha);
  background: linear-gradient(180deg, #fcfdfc, #fff); flex: none;
}
.sheet__head h2 {
  margin: 0; flex: 1; font-size: 1.05rem; color: var(--verde); letter-spacing: -.02em;
}
.sheet__body {
  padding: 1.15rem; overflow: auto; flex: 1; min-height: 0;
}
.sheet__frame {
  width: 100%; height: min(78dvh, 760px); border: 0; display: block; background: #f7f8f7;
}
.sheet__close {
  width: 2.4rem; height: 2.4rem; border: 0; border-radius: 12px;
  background: var(--creme); color: var(--verde); cursor: pointer;
  font-size: 1.35rem; line-height: 1; display: grid; place-items: center;
  text-decoration: none; flex: none;
}
.sheet__close:hover { background: rgba(0,56,40,.1); color: var(--verde); }
body.sheet-open { overflow: hidden; }

.embed-page {
  margin: 0; background: #f3f5f4; min-height: 100%;
  padding: 1rem;
}
.embed-page .form-grid { margin: 0; }
@media (max-width: 900px) {
  .sheet { padding: .5rem; align-items: flex-end; }
  .sheet__panel {
    width: 100%; max-height: 94dvh; border-radius: 18px 18px 10px 10px;
  }
  .sheet__frame { height: min(82dvh, 720px); }
}
