/* ---------- Tipografia (IBM Plex, alojada localmente) ---------- */
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-sans-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-sans-latin-500-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-sans-latin-600-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-sans-latin-700-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Serif";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-serif-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Serif";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../assets/fonts/ibm-plex-serif-latin-600-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --primary: #b45309;
  --primary-dark: #92400e;
  --primary-light: #fef3c7;
  --bg: #f7f4ef;
  --card: #ffffff;
  --text: #1c1917;
  --text-muted: #78716c;
  --border: #e7e1d8;
  --success: #15803d;
  --success-bg: #dcfce7;
  --danger: #b91c1c;
  --danger-bg: #fee2e2;
  --warning: #b45309;
  --warning-bg: #fef3c7;
  --sidebar: #1c1917;
  --sidebar-text: #a8a29e;
  --sidebar-active: #b45309;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(28, 25, 23, .05), 0 8px 24px rgba(28, 25, 23, .06);
  --font: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-serif: "IBM Plex Serif", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: .95rem; }
a { color: var(--primary); }

/* ---------- Icones ---------- */
.icon {
  display: inline-block;
  vertical-align: -0.18em;
  flex-shrink: 0;
  stroke-width: 1.75;
}
.icon-xs { width: 14px; height: 14px; vertical-align: -0.14em; }
.icon-sm { width: 17px; height: 17px; }
.icon-nav { width: 19px; height: 19px; }
.icon-title { width: 23px; height: 23px; vertical-align: -0.22em; }
.icon-lg { width: 22px; height: 22px; }
.icon-brand { width: 21px; height: 21px; }
.icon-empty { width: 34px; height: 34px; stroke-width: 1.5; }

/* ---------- Layout ---------- */
.layout { display: flex; min-height: 100vh; }

.sidebar {
  width: 252px;
  background: var(--sidebar);
  color: var(--sidebar-text);
  padding: 20px 14px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  flex-shrink: 0;
  overflow-y: auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 10px 20px;
  color: #fff;
  font-weight: 600;
  font-size: 1.04rem;
  letter-spacing: -.01em;
  line-height: 1.15;
}

.brand small {
  display: block;
  color: var(--sidebar-text);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  margin-top: 3px;
}

.brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #d97706, #b45309);
  display: grid;
  place-items: center;
  color: #fff;
  flex-shrink: 0;
}

.nav { display: flex; flex-direction: column; gap: 3px; margin-top: 6px; }

.nav button {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  padding: 10px 12px;
  border: none;
  border-radius: 9px;
  background: transparent;
  color: var(--sidebar-text);
  font-size: .9rem;
  font-weight: 500;
  text-align: left;
  transition: background .15s, color .15s;
}

.nav button:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.nav button.active { background: var(--sidebar-active); color: #fff; font-weight: 600; }

.nav-icon { width: 20px; height: 19px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.nav-label { flex: 1; }
.nav-done { display: inline-flex; align-items: center; color: #86efac; }
.nav-sep { height: 1px; background: rgba(255, 255, 255, .1); margin: 10px 6px; }

.sidebar-footer { margin-top: auto; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, .08); }

.progress-mini { padding: 2px 10px 12px; }
.progress-mini-top {
  display: flex;
  justify-content: space-between;
  font-size: .76rem;
  color: var(--sidebar-text);
  margin-bottom: 6px;
  letter-spacing: .03em;
}
.progress-mini-top strong { color: #fcd34d; font-variant-numeric: tabular-nums; }

.progress-track {
  height: 6px;
  background: #e7e1d8;
  border-radius: 99px;
  overflow: hidden;
}
.progress-track.big { height: 12px; }
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #d97706, #b45309);
  border-radius: 99px;
  transition: width .4s ease;
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  color: #fff;
  font-size: .87rem;
}

.user-chip .avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--primary);
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: .88rem;
  color: #fff;
  flex-shrink: 0;
}

.user-chip small { display: block; color: var(--sidebar-text); font-size: .74rem; }

.logout-btn {
  width: 100%;
  margin-top: 8px;
  padding: 9px;
  border: 1px solid rgba(255, 255, 255, .15);
  border-radius: 8px;
  background: transparent;
  color: #fda4af;
  font-size: .85rem;
}
.logout-btn:hover { background: rgba(220, 38, 38, .15); }

.pass-btn {
  width: 100%;
  margin-top: 8px;
  padding: 9px;
  border: 1px solid rgba(255, 255, 255, .15);
  border-radius: 8px;
  background: transparent;
  color: #fcd34d;
  font-size: .85rem;
}
.pass-btn:hover { background: rgba(180, 83, 9, .25); }

.main { flex: 1; padding: 30px 34px 60px; max-width: 1180px; min-width: 0; }

/* ---------- Typography ---------- */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}
.page-header h1 { font-size: 1.5rem; font-weight: 600; letter-spacing: -.015em; display: flex; align-items: center; gap: 10px; }
.page-header .sub { color: var(--text-muted); font-size: .9rem; margin-top: 3px; }
.section-title { font-size: 1.15rem; font-weight: 600; letter-spacing: -.01em; }

.step-kicker {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 5px;
}

.done-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--success-bg);
  color: var(--success);
  padding: 2px 8px;
  border-radius: 99px;
  font-size: .68rem;
  letter-spacing: .03em;
}

.muted { color: var(--text-muted); font-size: .88rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 16px;
  border: none;
  border-radius: 9px;
  font-size: .9rem;
  font-weight: 500;
  letter-spacing: -.005em;
  transition: background .15s, border-color .15s, transform .05s;
  text-decoration: none;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-primary:disabled:hover { background: var(--primary); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-outline { background: #fff; border: 1px solid var(--border); color: var(--text); }
.btn-outline:hover { background: #fbf9f5; border-color: #d6cec2; }
.btn-ghost { background: transparent; color: var(--text-muted); }
.btn-ghost:hover { background: #f1ece4; color: var(--text); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-sm { padding: 6px 11px; font-size: .8rem; }
.danger-text { color: var(--danger); }
.danger-text:hover { background: var(--danger-bg); color: var(--danger); }
.link-btn {
  border: none;
  background: none;
  color: var(--primary);
  font-weight: 600;
  font-size: inherit;
  padding: 0;
  text-decoration: underline;
}

/* ---------- Cards ---------- */
.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  padding: 22px;
  margin-bottom: 20px;
}
.card h2 { font-size: 1.05rem; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.head-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.warn-card {
  border-left: 5px solid var(--warning);
  background: #fffdf5;
}
.warn-card strong { display: flex; align-items: center; gap: 7px; color: #92400e; }

.tip-card {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #fffdf7;
  border-left: 4px solid #d97706;
}
.tip-icon { color: var(--primary); line-height: 1; margin-top: 1px; }

.info-card { padding: 0; background: #fffdf7; border-left: 4px solid #d97706; }
.info-card summary {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 22px;
  font-weight: 600;
  font-size: 1.02rem;
  color: var(--primary);
  cursor: pointer;
  list-style: none;
}
.info-card summary::-webkit-details-marker { display: none; }
.info-card summary::after {
  content: "";
  width: 8px;
  height: 8px;
  margin-left: auto;
  border-right: 2px solid var(--primary);
  border-bottom: 2px solid var(--primary);
  transform: rotate(45deg);
  transition: transform .18s ease;
}
.info-card[open] summary::after { transform: rotate(225deg); }
.info-body { padding: 0 22px 18px; color: var(--text-muted); font-size: .88rem; line-height: 1.65; }
.info-body p { margin: 0 0 10px; }
.info-body p:last-child { margin-bottom: 0; }

/* ---------- Empty / alerts ---------- */
.empty-state { text-align: center; padding: 34px 12px; color: var(--text-muted); }
.empty-state .big { color: #c9c0b3; line-height: 1; margin-bottom: 10px; }
.empty-state.small { padding: 18px 10px; font-size: .88rem; }

.alert {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 14px;
  border-radius: 9px;
  font-size: .88rem;
  margin-bottom: 16px;
}
.alert.success { background: var(--success-bg); color: #166534; }
.alert.error { background: var(--danger-bg); color: #991b1b; }
.alert.warning { background: var(--warning-bg); color: #92400e; }
.alert .close {
  border: none;
  background: transparent;
  color: inherit;
  font-size: 1.1rem;
  line-height: 1;
  opacity: .7;
}
.alert .close:hover { opacity: 1; }

/* ---------- Login ---------- */
.login-wrap {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background:
    radial-gradient(circle at 15% 15%, rgba(217, 119, 6, .18), transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(180, 83, 9, .14), transparent 45%),
    #faf7f2;
}

.login-card {
  width: 100%;
  max-width: 400px;
  background: #fff;
  border-radius: 18px;
  padding: 36px 32px 26px;
  box-shadow: 0 18px 50px rgba(28, 25, 23, .14);
  border: 1px solid var(--border);
  text-align: center;
}
.login-card .logo {
  width: 64px;
  height: 64px;
  margin: 0 auto 16px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(180, 83, 9, .28);
}
.login-card .logo img { width: 100%; height: 100%; display: block; }
.login-card h1 { font-size: 1.5rem; font-weight: 600; margin-bottom: 4px; letter-spacing: -.025em; }
.login-card > p { color: var(--text-muted); font-size: .9rem; margin-bottom: 24px; }
.login-card .field { text-align: left; }
.login-hint {
  margin-top: 20px;
  font-size: .68rem;
  letter-spacing: .16em;
  color: #a8a29e;
  text-transform: uppercase;
}

.field { display: flex; flex-direction: column; gap: 5px; }
.field label { font-size: .8rem; font-weight: 500; color: #44403c; }
.field input, .field textarea, .field select {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: #fdfcfa;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field textarea:focus, .field select:focus {
  border-color: #d97706;
  box-shadow: 0 0 0 3px rgba(217, 119, 6, .15);
  background: #fff;
}
.field textarea { resize: vertical; min-height: 92px; }

/* ---------- Hero ---------- */
.hero {
  display: grid;
  grid-template-columns: 1.55fr 1fr;
  gap: 26px;
  align-items: stretch;
  background:
    linear-gradient(135deg, rgba(180, 83, 9, .96), rgba(120, 53, 15, .98)),
    #b45309;
  color: #fff;
  border-radius: 20px;
  padding: 34px;
  box-shadow: 0 16px 40px rgba(120, 53, 15, .25);
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  right: -80px;
  top: -80px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .08);
}
.hero-text { position: relative; z-index: 1; }
.hero-kicker {
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #fde68a;
  font-weight: 600;
  margin-bottom: 10px;
}
.hero h1 { font-size: 2rem; font-weight: 600; line-height: 1.14; letter-spacing: -.025em; margin-bottom: 14px; }
.hero p { color: #fef3c7; font-size: .95rem; line-height: 1.65; max-width: 60ch; }
.hero-sign { margin-top: 20px; display: flex; flex-direction: column; }
.hero-sign strong { font-size: .95rem; font-weight: 600; }
.hero-sign span { color: #fde68a; font-size: .82rem; }
.hero-patron { margin-top: 12px; font-size: .76rem; color: rgba(254, 243, 199, .72); }

.hero-side {
  position: relative;
  z-index: 1;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: 16px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-align: center;
}
.hero-side-label { font-size: .8rem; color: #fef3c7; }

.ring {
  --pct: 0;
  width: 132px;
  height: 132px;
  border-radius: 50%;
  background: conic-gradient(#fcd34d calc(var(--pct) * 1%), rgba(255, 255, 255, .18) 0);
  display: grid;
  place-items: center;
  position: relative;
}
.ring::before {
  content: "";
  position: absolute;
  inset: 9px;
  border-radius: 50%;
  background: #8a3f0c;
}
.ring-inner { position: relative; z-index: 1; display: flex; flex-direction: column; }
.ring-inner strong { font-size: 1.6rem; line-height: 1; }
.ring-inner span { font-size: .72rem; color: #fde68a; margin-top: 3px; }

/* ---------- Journey ---------- */
.journey-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(255px, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.journey-card {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  text-align: left;
  padding: 17px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 13px;
  box-shadow: var(--shadow);
  transition: transform .12s, border-color .12s, box-shadow .12s;
}
.journey-card:hover {
  transform: translateY(-2px);
  border-color: #d6cec2;
  box-shadow: 0 10px 26px rgba(28, 25, 23, .1);
}
.journey-card.done { background: #fcfdf9; border-color: #cfe8cf; }
.journey-icon {
  width: 42px;
  height: 42px;
  border-radius: 11px;
  background: var(--primary-light);
  color: var(--primary-dark);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.journey-card.done .journey-icon { background: var(--success-bg); }
.journey-body { flex: 1; min-width: 0; }
.journey-step {
  font-size: .68rem;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 700;
}
.journey-title { font-weight: 600; font-size: .98rem; margin: 1px 0 3px; }
.journey-text { font-size: .82rem; color: var(--text-muted); line-height: 1.45; }
.journey-state { display: flex; align-items: center; color: var(--primary); font-weight: 700; }
.journey-card.done .journey-state { color: var(--success); }

/* ---------- Section footer ---------- */
.section-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.footer-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.footer-hint { font-size: .78rem; color: var(--text-muted); }

/* ---------- Procedimentos do check-in ---------- */
.checklist-card { margin-top: 16px; }
.task-group + .task-group { margin-top: 12px; }
.task-group-title {
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--text-muted);
  margin: 4px 10px 6px;
}
.task-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 9px 10px;
  border-radius: 9px;
  cursor: pointer;
}
.task-row:hover { background: #faf7f2; }
.task-row input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.task-box {
  width: 18px;
  height: 18px;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: #fff;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: #fff;
  margin-top: 1px;
}
.task-row.done .task-box { background: var(--success); border-color: var(--success); }
.task-row input:focus-visible + .task-box { outline: 2px solid var(--primary); outline-offset: 2px; }
.task-text { font-size: .88rem; line-height: 1.45; }
.task-row.done .task-text { color: var(--text-muted); text-decoration: line-through; }
.task-empty { padding: 12px 10px; color: var(--text-muted); font-size: .86rem; }

/* ---------- Search / people ---------- */
.search-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}
.search-input {
  flex: 1;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fdfcfa;
  outline: none;
}
.search-input:focus { border-color: #d97706; box-shadow: 0 0 0 3px rgba(217, 119, 6, .14); background: #fff; }
.search-count { color: var(--text-muted); font-size: .8rem; white-space: nowrap; }

.people-group { margin-bottom: 20px; }
.people-group:last-child { margin-bottom: 0; }
.group-label {
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 9px;
}
.people-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 12px;
}
.person-card {
  display: flex;
  gap: 13px;
  padding: 15px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fdfcfa;
}
.avatar-lg {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: linear-gradient(135deg, #fbbf24, #d97706);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: .95rem;
  flex-shrink: 0;
}
.person-body { min-width: 0; flex: 1; }
.person-name { font-weight: 600; font-size: .95rem; }
.person-role { font-size: .82rem; color: var(--text-muted); margin-bottom: 7px; }
.person-meta { display: flex; flex-wrap: wrap; gap: 5px; }
.copy-btn {
  margin-top: 8px;
  border: none;
  background: none;
  color: var(--primary);
  font-size: .76rem;
  font-weight: 600;
  padding: 0;
}
.copy-btn:hover { text-decoration: underline; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 99px;
  background: #f3eee6;
  color: #57534e;
  font-size: .75rem;
  text-decoration: none;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.chip.link { background: var(--primary-light); color: var(--primary-dark); }
.chip.link:hover { background: #fde68a; }
.person-meta .chip.link,
.contact-actions .chip.link {
  white-space: normal;
  overflow-wrap: anywhere;
  text-align: left;
}

.badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 99px;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-size: .72rem;
  font-weight: 600;
  white-space: nowrap;
}
.badge.soft { background: #f3eee6; color: #57534e; font-weight: 600; }

/* ---------- Stats ---------- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.stat-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 22px 18px;
  box-shadow: var(--shadow);
  border-top: 4px solid #d97706;
}
.stat-value { font-size: 2rem; font-weight: 700; letter-spacing: -.035em; color: var(--primary-dark); line-height: 1.05; font-variant-numeric: tabular-nums; }
.stat-label { font-weight: 600; font-size: .92rem; margin-top: 4px; }
.stat-hint { font-size: .78rem; color: var(--text-muted); margin-top: 3px; }

/* ---------- Courses ---------- */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 15px;
  margin-bottom: 20px;
}
.course-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}
.course-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 5px; }
.course-top h3 { font-size: 1rem; font-weight: 600; line-height: 1.3; }
.course-coord { font-size: .78rem; color: var(--primary); font-weight: 600; margin-bottom: 9px; }
.course-desc { font-size: .86rem; color: var(--text-muted); line-height: 1.5; flex: 1; }
.course-exits { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 13px; }

/* ---------- Projetos e parcerias ---------- */
.split-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 15px;
  margin-bottom: 20px;
  align-items: start;
}
.tag-list { margin-top: 4px; }
.tag-row {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
  font-size: .9rem;
  line-height: 1.4;
}
.tag-row:last-child { border-bottom: none; padding-bottom: 0; }
.tag-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
  flex-shrink: 0;
  margin-top: 8px;
}
.tag-note { font-size: .76rem; margin-top: 1px; }

/* ---------- Places ---------- */
.map-card { padding: 0; overflow: hidden; margin-bottom: 18px; }
.map-card img { display: block; width: 100%; height: auto; }
.map-caption { padding: 11px 16px; font-size: .82rem; color: var(--text-muted); border-top: 1px solid var(--border); }
.places-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 13px;
  margin-bottom: 20px;
}
.place-card {
  display: flex;
  gap: 13px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 13px;
  padding: 17px;
  box-shadow: var(--shadow);
}
.place-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary-dark);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.place-body { min-width: 0; }
.place-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }
.place-top h3 { font-size: .95rem; font-weight: 600; }

/* ---------- Steps ---------- */
.steps-list { display: flex; flex-direction: column; gap: 0; margin-bottom: 20px; }
.step-item {
  display: flex;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}
.step-item:last-child { border-bottom: none; }
.step-number {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: .9rem;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.step-body { min-width: 0; }
.step-title { font-weight: 600; font-size: .98rem; }
.step-desc { font-size: .88rem; color: var(--text-muted); margin-top: 2px; }
.step-detail { font-size: .82rem; color: #57534e; margin-top: 7px; background: #fdfcfa; border-left: 3px solid #fcd34d; padding: 7px 10px; border-radius: 0 7px 7px 0; }
.doc-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 9px;
  padding: 6px 11px;
  border: 1px solid #fcd34d;
  border-radius: 8px;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-size: .8rem;
  font-weight: 500;
  text-decoration: none;
}
.doc-link:hover { background: #fde68a; border-color: #f59e0b; }

.docs-card { margin-top: 18px; }
.doc-list { margin-top: 6px; }
.doc-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
}
.doc-row:last-child { border-bottom: none; }
.doc-row:hover { background: #fdfcfa; }
.doc-icon {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--primary-light);
  color: var(--primary-dark);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.doc-body { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.doc-name { font-weight: 500; font-size: .92rem; }
.doc-note { font-size: .78rem; color: var(--text-muted); }
.doc-row > .icon:last-child { color: var(--primary); }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th {
  text-align: left;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 9px 12px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
td { padding: 12px; border-bottom: 1px solid #f1ece4; font-size: .9rem; vertical-align: top; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: #fdfcfa; }
.time-badge {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 7px;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-weight: 600;
  font-size: .82rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.note-line { margin-top: 13px; font-size: .8rem; color: var(--text-muted); }
.row-actions { text-align: right; white-space: nowrap; }
.row-actions .btn + .btn { margin-left: 5px; }

/* ---------- Contacts ---------- */
.contacts-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.contact-list { display: flex; flex-direction: column; }
.contact-row {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 13px 0;
  border-bottom: 1px solid #f1ece4;
}
.contact-row:last-child { border-bottom: none; }
.avatar-sm {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: #f3eee6;
  color: #57534e;
  display: grid;
  place-items: center;
  font-weight: 600;
  font-size: .78rem;
  flex-shrink: 0;
}
.contact-body { flex: 1; min-width: 0; }
.contact-name { font-weight: 600; font-size: .92rem; }
.contact-actions { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; justify-content: flex-end; }

/* ---------- Conclusion ---------- */
.header-actions { display: flex; gap: 9px; flex-wrap: wrap; }

.print-area { margin-bottom: 20px; }
.certificate {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 34px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.certificate::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 7px;
  background: linear-gradient(90deg, #fbbf24, #b45309);
}
.cert-top { display: flex; align-items: center; gap: 13px; margin-bottom: 26px; }
.cert-logo {
  width: 48px;
  height: 48px;
  border-radius: 13px;
  background: var(--primary-light);
  color: var(--primary-dark);
  display: grid;
  place-items: center;
}
.cert-school { font-family: var(--font-serif); font-weight: 600; font-size: 1.08rem; letter-spacing: -.01em; }
.cert-year { font-size: .8rem; color: var(--text-muted); }
.cert-body { text-align: center; padding: 10px 0 26px; }
.cert-kicker {
  font-size: .72rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 8px;
}
.cert-body h2 { font-family: var(--font-serif); font-weight: 600; font-size: 2.05rem; letter-spacing: -.015em; margin-bottom: 6px; }
.cert-body p { font-family: var(--font-serif); color: var(--text-muted); font-size: 1rem; }
.cert-meta {
  display: flex;
  justify-content: center;
  gap: 40px;
  flex-wrap: wrap;
  margin-top: 24px;
}
.cert-meta div { display: flex; flex-direction: column; gap: 2px; }
.cert-meta span { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-muted); }
.cert-meta strong { font-size: .95rem; font-variant-numeric: tabular-nums; }
.cert-sign { text-align: center; margin-top: 10px; }
.sign-line { width: 200px; height: 1px; background: #d6cec2; margin: 0 auto 8px; }
.cert-sign div { font-weight: 600; font-size: .9rem; }
.cert-sign small { color: var(--text-muted); font-size: .78rem; }

.summary-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 22px;
  margin-top: 16px;
  box-shadow: var(--shadow);
}
.summary-card h3 { font-size: 1rem; font-weight: 600; margin-bottom: 12px; }
.summary-contacts {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 12px;
}
.summary-contact { display: flex; flex-direction: column; font-size: .82rem; color: var(--text-muted); }
.summary-contact strong { color: var(--text); font-size: .9rem; font-weight: 600; }

.progress-big { margin-bottom: 18px; }
.progress-big .muted { margin-top: 7px; }
.remaining-list { display: flex; flex-direction: column; gap: 6px; }
.remaining-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fdfcfa;
  text-align: left;
  font-size: .92rem;
}
.remaining-item:hover { background: #fff; border-color: #d6cec2; }
.remaining-item .arrow { margin-left: auto; color: var(--primary); font-weight: 700; display: inline-flex; }
.remaining-icon { display: inline-flex; color: var(--primary); }

/* ---------- Admin forms ---------- */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.form-grid .span-2 { grid-column: span 2; }
.form-actions { display: flex; justify-content: flex-end; }
.form-stack { display: flex; flex-direction: column; gap: 13px; }

/* ---------- Modal ---------- */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(28, 25, 23, .5);
  backdrop-filter: blur(2px);
  display: grid;
  place-items: center;
  padding: 20px;
  z-index: 50;
}
.modal {
  width: 100%;
  max-width: 520px;
  max-height: 88vh;
  overflow-y: auto;
  background: #fff;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 24px 60px rgba(28, 25, 23, .3);
}
.modal h2 { font-size: 1.15rem; font-weight: 600; margin-bottom: 16px; }
.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin-top: 6px;
}

/* ---------- Toasts ---------- */
#toast-root {
  position: fixed;
  right: 18px;
  bottom: 18px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  z-index: 80;
}
.toast {
  min-width: 220px;
  max-width: 360px;
  padding: 12px 16px;
  border-radius: 10px;
  background: #1c1917;
  color: #fff;
  font-size: .87rem;
  box-shadow: 0 12px 30px rgba(28, 25, 23, .28);
  animation: toastIn .2s ease;
}
.toast.success { border-left: 4px solid #22c55e; }
.toast.error { border-left: 4px solid #ef4444; }
.toast.warning { border-left: 4px solid #f59e0b; }
.toast.out { opacity: 0; transform: translateY(6px); transition: opacity .3s, transform .3s; }
@keyframes toastIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; }
  .hero-side { flex-direction: row; justify-content: space-between; text-align: left; }
  .ring { width: 104px; height: 104px; }
}

@media (max-width: 860px) {
  .layout { flex-direction: column; }
  .sidebar {
    width: 100%;
    height: auto;
    position: static;
    padding: 12px 14px;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
  }
  .brand { padding: 0 10px 0 0; font-size: .98rem; }
  .brand small { display: none; }
  .brand-icon { width: 32px; height: 32px; font-size: 1rem; }
  .nav {
    flex-direction: row;
    flex: 1;
    margin: 0;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }
  .nav::-webkit-scrollbar { display: none; }
  .nav button { width: auto; white-space: nowrap; padding: 8px 10px; font-size: .85rem; }
  .nav-label { flex: none; }
  .nav-sep, .nav-done { display: none; }
  .sidebar-footer {
    margin: 0;
    padding: 0;
    border: none;
    display: flex;
    align-items: center;
    gap: 6px;
  }
  .progress-mini, .user-chip, .pass-btn { display: none; }
  .logout-btn { width: auto; margin: 0; padding: 8px 12px; }
  .main { padding: 22px 18px 50px; }
  .hero { padding: 24px; }
  .hero h1 { font-size: 1.6rem; }
  .hero-side { flex-wrap: wrap; }
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .span-2 { grid-column: span 1; }
  .contact-actions { justify-content: flex-start; }
}

@media (max-width: 560px) {
  .page-header h1 { font-size: 1.3rem; }
  .icon-title { width: 20px; height: 20px; }
  .journey-grid, .people-grid, .courses-grid, .places-grid, .stats-grid, .split-grid { grid-template-columns: 1fr; }
  .search-row { flex-wrap: wrap; }
  .section-footer { flex-direction: column-reverse; align-items: stretch; }
  .footer-actions { width: 100%; }
  .footer-hint { width: 100%; }
  .section-footer .btn { width: 100%; }
  .hero-side { flex-direction: column; text-align: center; }
  .cert-meta { gap: 20px; }
  .certificate { padding: 24px 20px; }
  .contact-row { flex-wrap: wrap; }
  .contact-actions { width: 100%; justify-content: flex-start; padding-left: 49px; }
}

/* ---------- Print ---------- */
@media print {
  body { background: #fff; }
  .sidebar, .page-header, .section-footer, .no-print, #toast-root, #modal-root { display: none !important; }
  .layout { display: block; }
  .main { max-width: none; padding: 0; }
  .print-area { margin: 0; }
  .certificate, .summary-card { box-shadow: none; border: 1px solid #ccc; break-inside: avoid; }
  .certificate { border-radius: 0; }
  .summary-card { margin-top: 14px; }
}
