/* Liderar Servindo: sistema visual do material.
   Leitura longa em primeiro lugar: serifada de leitura (Literata) no texto,
   sem serifa (Source Sans 3) na interface, coluna de ~68 caracteres, papel
   claro com tinta quente. Tema escuro pelo sistema ou pelo botão. */

:root {
  --paper: #F6F2EA;
  --surface: #FFFDF8;
  --sunk: #EFE9DD;
  --ink: #2A2521;
  --ink-2: #4A433C;
  --muted: #776D63;
  --line: #E2D9CA;
  --line-2: #D3C7B4;
  --terra: #9A4F2C;
  --terra-2: #B5643D;
  --terra-bg: #F5E6DC;
  --olive: #56613A;
  --olive-bg: #E9ECDC;
  --ochre: #8F6514;
  --ochre-bg: #F6ECD3;
  --slate: #3F5866;
  --slate-bg: #E3EAEE;
  --shadow: 0 1px 2px rgba(60, 40, 20, .06), 0 6px 24px rgba(60, 40, 20, .06);
  --serif: "Literata", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", -apple-system, "Segoe UI", Roboto, sans-serif;
  --col: 42rem;
  --wide: 60rem;
  --side: 17.5rem;
  --top: 3.5rem;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #191613; --surface: #211D19; --sunk: #2A2520; --ink: #EDE6DA; --ink-2: #D2C8BA;
    --muted: #A3978A; --line: #352F29; --line-2: #463E36; --terra: #E0956B; --terra-2: #EBA882;
    --terra-bg: #3A2A20; --olive: #B5C08E; --olive-bg: #2A2E20; --ochre: #DDB560; --ochre-bg: #382E18;
    --slate: #9DB8C6; --slate-bg: #222C31; --shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 24px rgba(0,0,0,.25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #191613; --surface: #211D19; --sunk: #2A2520; --ink: #EDE6DA; --ink-2: #D2C8BA;
  --muted: #A3978A; --line: #352F29; --line-2: #463E36; --terra: #E0956B; --terra-2: #EBA882;
  --terra-bg: #3A2A20; --olive: #B5C08E; --olive-bg: #2A2E20; --ochre: #DDB560; --ochre-bg: #382E18;
  --slate: #9DB8C6; --slate-bg: #222C31; --shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 24px rgba(0,0,0,.25);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--top) + 1rem); }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 1.0625rem/1.7 var(--serif); font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--terra); text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { color: var(--terra-2); }
:focus-visible { outline: 2px solid var(--terra); outline-offset: 2px; border-radius: 4px; }
::selection { background: var(--terra-bg); }

/* ---------- topo ---------- */
.topbar {
  position: sticky; top: 0; z-index: 40; height: var(--top);
  display: flex; align-items: center; gap: .75rem; padding: 0 1rem;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line); font-family: var(--sans);
}
.topbar .brand { display: flex; align-items: center; gap: .55rem; color: var(--ink); text-decoration: none; font-weight: 700; letter-spacing: .01em; white-space: nowrap; }
.brand-mark { width: 1.6rem; height: 1.6rem; flex: none; }
.topbar .where { color: var(--muted); font-size: .92rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.topbar .where::before { content: "/"; margin-right: .6rem; color: var(--line-2); }
.topbar .sp { flex: 1; }
.iconbtn {
  display: inline-grid; place-items: center; width: 2.5rem; height: 2.5rem; border-radius: .6rem;
  border: 1px solid transparent; background: none; color: var(--ink-2); cursor: pointer; flex: none;
}
.iconbtn:hover { background: var(--sunk); }
.iconbtn svg { width: 1.25rem; height: 1.25rem; }
.progress { position: absolute; left: 0; bottom: -1px; height: 2px; width: 0; background: var(--terra); transition: width .1s linear; }

/* ---------- navegação lateral ---------- */
.side {
  position: fixed; z-index: 50; top: 0; bottom: 0; left: 0; width: min(86vw, var(--side));
  background: var(--surface); border-right: 1px solid var(--line); overflow-y: auto;
  transform: translateX(-102%); transition: transform .25s ease; font-family: var(--sans);
  padding: 1rem .75rem 2rem; overscroll-behavior: contain;
}
.side.open { transform: none; box-shadow: var(--shadow); }
.scrim { position: fixed; inset: 0; z-index: 45; background: rgba(20, 14, 8, .35); opacity: 0; pointer-events: none; transition: opacity .25s; }
.scrim.open { opacity: 1; pointer-events: auto; }
.side .side-head { display: flex; align-items: center; justify-content: space-between; padding: .25rem .5rem 1rem; }
.side .side-head b { font-size: 1.05rem; }
.side h4 { margin: 1.1rem .6rem .35rem; font-size: .72rem; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.side a {
  display: flex; align-items: baseline; gap: .6rem; padding: .5rem .6rem; border-radius: .55rem;
  color: var(--ink-2); text-decoration: none; font-size: .95rem; line-height: 1.35;
}
.side a:hover { background: var(--sunk); color: var(--ink); }
.side a[aria-current="page"] { background: var(--terra-bg); color: var(--terra); font-weight: 600; }
.side a .n { font-variant-numeric: tabular-nums; color: var(--muted); font-size: .8rem; min-width: 1.2rem; }
.side a[aria-current="page"] .n { color: var(--terra); }
.side a .ok { margin-left: auto; color: var(--olive); font-size: .85rem; }

@media (min-width: 1100px) {
  .side { transform: none; top: var(--top); width: var(--side); padding-top: .75rem; }
  .side .side-head, .scrim, .menu-btn { display: none; }
  .shell { padding-left: var(--side); }
}

/* ---------- página ---------- */
.shell { min-height: calc(100vh - var(--top)); }
main { padding: 0 1rem 4rem; }
.col, .page > * { max-width: var(--col); margin-left: auto; margin-right: auto; }
.page > .wide, .page .wide { max-width: var(--wide); }
.page > .full { max-width: none; }

@media (min-width: 1400px) {
  .with-toc { display: grid; grid-template-columns: minmax(0, 1fr) 14rem; gap: 3rem; max-width: calc(var(--wide) + 17rem); margin: 0 auto; }
  .with-toc .toc { display: block; }
  .with-toc .toc-inline { display: none; }
}
.toc { display: none; position: sticky; top: calc(var(--top) + 2rem); align-self: start; font-family: var(--sans); font-size: .87rem; padding-top: 3rem; }
.toc b { display: block; font-size: .72rem; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); margin-bottom: .6rem; }
.toc a { display: block; color: var(--muted); text-decoration: none; padding: .3rem 0 .3rem .8rem; border-left: 2px solid var(--line); line-height: 1.35; }
.toc a:hover { color: var(--ink); }
.toc a.on { color: var(--terra); border-left-color: var(--terra); }
.toc-inline { font-family: var(--sans); margin: 1.5rem auto 0; border: 1px solid var(--line); border-radius: .8rem; background: var(--surface); }
.toc-inline summary { cursor: pointer; padding: .8rem 1rem; font-weight: 600; font-size: .95rem; list-style: none; display: flex; justify-content: space-between; }
.toc-inline summary::-webkit-details-marker { display: none; }
.toc-inline summary::after { content: "+"; color: var(--muted); }
.toc-inline[open] summary::after { content: "–"; }
.toc-inline ol { margin: 0; padding: 0 1rem .9rem 2.2rem; font-size: .95rem; }
.toc-inline li { padding: .2rem 0; }
.toc-inline a { color: var(--ink-2); text-decoration: none; }

/* ---------- abertura ---------- */
.hero { padding: 2.5rem 0 0; }
.eyebrow { font-family: var(--sans); font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--terra); font-weight: 700; margin: 0 0 .7rem; }
h1 { font-size: clamp(2rem, 5.2vw, 3rem); line-height: 1.1; margin: 0 0 1rem; font-weight: 600; letter-spacing: -.015em; text-wrap: balance; }
.lead { font-size: 1.2rem; line-height: 1.6; color: var(--ink-2); margin: 0 0 1.5rem; text-wrap: pretty; }
.page .chips, .chips { display: flex; flex-wrap: wrap; gap: .5rem; font-family: var(--sans); margin: 0 0 1.75rem; padding: 0; list-style: none; }
.chips li { font-size: .85rem; padding: .3rem .7rem; border-radius: 99px; background: var(--surface); border: 1px solid var(--line); color: var(--ink-2); }
.chips li b { color: var(--ink); font-weight: 600; }
.figure { margin: 1.75rem auto 0; border-radius: 1rem; overflow: hidden; background: #F3EEE3; border: 1px solid var(--line); }
.figure img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
:root[data-theme="dark"] .figure img { filter: brightness(.92) contrast(1.02); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .figure img { filter: brightness(.92) contrast(1.02); } }

/* ---------- tipografia do corpo ---------- */
.page h2 {
  font-size: clamp(1.45rem, 3.2vw, 1.85rem); line-height: 1.25; margin: 3.5rem auto 1rem; font-weight: 600;
  letter-spacing: -.01em; text-wrap: balance; padding-top: 1.25rem; border-top: 1px solid var(--line);
}
.page h2 .num { font-family: var(--sans); font-size: .8rem; letter-spacing: .1em; color: var(--terra); display: block; font-weight: 700; margin-bottom: .35rem; text-transform: uppercase; }
.page h3 { font-size: 1.2rem; line-height: 1.35; margin: 2.2rem auto .6rem; font-weight: 600; }
.page h3 .nivel { display: block; font-family: var(--sans); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; color: var(--terra); margin-bottom: .3rem; }
.page h3 .nivel.aprofundar { color: var(--muted); }
.page h4 { font-family: var(--sans); font-size: .95rem; margin: 1.5rem auto .4rem; font-weight: 700; }
.page p { margin: 0 auto 1.1rem; text-wrap: pretty; }
.page ul, .page ol { padding-left: 1.4rem; margin: 0 auto 1.2rem; }
.page li { margin: .35rem 0; }
.page li::marker { color: var(--terra); }
.page strong { font-weight: 650; color: var(--ink); }
.page blockquote {
  margin: 2rem auto; padding: 0 0 0 1.25rem; border-left: 3px solid var(--terra);
  font-size: 1.25rem; line-height: 1.5; font-style: italic; color: var(--ink-2);
}
.page blockquote cite { display: block; font-style: normal; font-family: var(--sans); font-size: .85rem; color: var(--muted); margin-top: .5rem; }
.small, .page .small { font-size: .9rem; color: var(--muted); }
hr { border: 0; border-top: 1px solid var(--line); margin: 2.5rem auto; }

/* objetivos */
.goals { background: var(--surface); border: 1px solid var(--line); border-radius: 1rem; padding: 1.25rem 1.4rem; margin: 2rem auto; box-shadow: var(--shadow); }
.goals h3 { margin: 0 0 .6rem; font-family: var(--sans); font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.page .goals ul { margin: 0; padding: 0; list-style: none; }
.goals li { padding: .45rem 0 .45rem 1.9rem; position: relative; border-top: 1px dashed var(--line); }
.goals li:first-child { border-top: 0; }
.goals li::before { content: ""; position: absolute; left: .1rem; top: .85rem; width: 1rem; height: 1rem; border-radius: 50%; border: 2px solid var(--olive); }

/* caixas */
.box { border-radius: .9rem; padding: 1.15rem 1.3rem; margin: 1.75rem auto; border: 1px solid; }
.box > :last-child { margin-bottom: 0; }
.box .tag { font-family: var(--sans); font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; display: flex; align-items: center; gap: .45rem; margin-bottom: .5rem; }
.box .tag svg { width: 1rem; height: 1rem; }
.box h3, .box h4 { margin-top: 0; }
.box p { margin-bottom: .7rem; }
.virtude { background: var(--olive-bg); border-color: color-mix(in srgb, var(--olive) 25%, transparent); }
.virtude .tag { color: var(--olive); }
.pratica { background: var(--terra-bg); border-color: color-mix(in srgb, var(--terra) 22%, transparent); }
.pratica .tag { color: var(--terra); }
.atencao { background: var(--ochre-bg); border-color: color-mix(in srgb, var(--ochre) 25%, transparent); }
.atencao .tag { color: var(--ochre); }
.nota { background: var(--slate-bg); border-color: color-mix(in srgb, var(--slate) 22%, transparent); }
.nota .tag { color: var(--slate); }
.caso { background: var(--surface); border-color: var(--line); box-shadow: var(--shadow); }
.caso .tag { color: var(--ink-2); }
.caso .situacao { font-size: 1.05rem; }

/* comparação lado a lado */
.pair { display: grid; gap: 1rem; margin: 1.5rem auto; }
@media (min-width: 720px) { .pair { grid-template-columns: 1fr 1fr; } }
.pair > div { border: 1px solid var(--line); border-radius: .9rem; padding: 1rem 1.15rem; background: var(--surface); }
.pair h4 { margin: 0 0 .4rem; }
.pair .neg h4 { color: var(--muted); }
.pair .pos h4 { color: var(--olive); }
.pair p, .pair ul { margin-bottom: 0; font-size: .98rem; }

/* passos */
.steps { counter-reset: s; list-style: none; padding: 0 !important; }
.steps > li { counter-increment: s; position: relative; padding: .15rem 0 .9rem 3rem; margin: 0; }
.steps > li::before {
  content: counter(s); position: absolute; left: 0; top: 0; width: 2rem; height: 2rem; border-radius: 50%;
  background: var(--terra); color: #fff; font: 700 .9rem/2rem var(--sans); text-align: center;
}
.steps > li:not(:last-child)::after { content: ""; position: absolute; left: .95rem; top: 2.3rem; bottom: .2rem; width: 2px; background: var(--line); }
.steps > li > strong:first-child { display: block; }

/* ferramenta (modelo para preencher e imprimir) */
.tool { background: var(--surface); border: 1px solid var(--line-2); border-radius: 1rem; margin: 2rem auto; box-shadow: var(--shadow); overflow: hidden; }
.tool-head { display: flex; align-items: center; gap: .75rem; padding: .9rem 1.2rem; background: var(--sunk); border-bottom: 1px solid var(--line); font-family: var(--sans); }
.tool-head .k { font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--terra); font-weight: 700; }
.tool-head h3 { margin: 0; font-family: var(--sans); font-size: 1.05rem; flex: 1; }
.tool-head button { font: 600 .82rem var(--sans); color: var(--ink-2); background: var(--surface); border: 1px solid var(--line-2); border-radius: .5rem; padding: .35rem .7rem; cursor: pointer; }
.tool-body { padding: 1.1rem 1.2rem 1.3rem; }
.tool-body > :last-child { margin-bottom: 0; }
.field { margin: 0 0 1rem; }
.field label, .field .lbl { display: block; font: 700 .9rem/1.35 var(--sans); color: var(--ink); }
.field .hint { display: block; font: 400 .86rem/1.45 var(--sans); color: var(--muted); margin-top: .15rem; }
.field .lines { height: 4.2rem; margin-top: .4rem; background: repeating-linear-gradient(to bottom, transparent 0, transparent 1.37rem, var(--line-2) 1.37rem, var(--line-2) 1.4rem); }
.field .lines.s { height: 1.45rem; }
.field .lines.l { height: 7rem; }
.exemplo { margin-top: 1.2rem; border-top: 1px dashed var(--line-2); padding-top: 1rem; }
.exemplo > summary { cursor: pointer; font: 700 .88rem var(--sans); color: var(--olive); list-style: none; }
.exemplo > summary::-webkit-details-marker { display: none; }
.exemplo > summary::before { content: "▸ "; }
.exemplo[open] > summary::before { content: "▾ "; }
.exemplo .ex { font-size: .97rem; margin-top: .8rem; }
.exemplo .ex b { font-family: var(--sans); font-size: .88rem; }

/* tabelas */
.tbl { width: 100%; border-collapse: separate; border-spacing: 0; font-family: var(--sans); font-size: .93rem; line-height: 1.45; margin: 1.5rem auto; background: var(--surface); border: 1px solid var(--line); border-radius: .9rem; overflow: hidden; }
.tbl th { text-align: left; font-weight: 700; background: var(--sunk); padding: .7rem .85rem; border-bottom: 1px solid var(--line); vertical-align: bottom; }
.tbl td { padding: .7rem .85rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl td:first-child { font-weight: 600; }
@media (max-width: 719px) {
  .tbl, .tbl tbody, .tbl tr, .tbl td { display: block; }
  .tbl thead { display: none; }
  .tbl tr { padding: .6rem .9rem; border-bottom: 1px solid var(--line); }
  .tbl tr:last-child { border-bottom: 0; }
  .tbl td { border: 0; padding: .25rem 0; }
  .tbl td[data-l]::before { content: attr(data-l); display: block; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
  .tbl.inline td:not(:first-child) { display: inline-block; margin-right: 1.1rem; }
  .tbl.inline td:not(:first-child)::before { display: inline; margin-right: .35rem; }
  .tool-body { padding: 1rem; }
}

/* rubrica */
.rubrica { margin: 1.5rem auto; font-family: var(--sans); }
.rub-row { border: 1px solid var(--line); border-radius: .9rem; background: var(--surface); margin-bottom: .9rem; overflow: hidden; }
.rub-row > h4 { margin: 0; padding: .75rem 1rem; background: var(--sunk); font-size: .98rem; border-bottom: 1px solid var(--line); }
.rub-levels { display: grid; }
@media (min-width: 720px) { .rub-levels { grid-template-columns: repeat(3, 1fr); } }
.rub-levels > div { padding: .8rem 1rem; font-size: .92rem; line-height: 1.5; border-top: 1px solid var(--line); }
@media (min-width: 720px) { .rub-levels > div { border-top: 0; border-left: 1px solid var(--line); } .rub-levels > div:first-child { border-left: 0; } }
.rub-levels > div:first-child { border-top: 0; }
.rub-levels b { display: block; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; margin-bottom: .3rem; }
.lv1 b { color: var(--muted); } .lv2 b { color: var(--ochre); } .lv3 b { color: var(--olive); }
.lv3 { background: color-mix(in srgb, var(--olive-bg) 55%, transparent); }

/* exercício com checklist */
.task { border: 2px solid var(--terra); border-radius: 1rem; padding: 1.2rem 1.3rem; margin: 2rem auto; background: var(--surface); }
.task .tag { font-family: var(--sans); font-size: .74rem; letter-spacing: .1em; text-transform: uppercase; color: var(--terra); font-weight: 700; margin-bottom: .4rem; }
.task h3 { margin: 0 0 .6rem; }
.task dl { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1rem; font-family: var(--sans); font-size: .93rem; margin: .9rem 0; }
.task dt { color: var(--muted); font-weight: 600; }
.task dd { margin: 0; }
@media (max-width: 519px) { .task dl { grid-template-columns: 1fr; } .task dd { margin-bottom: .4rem; } }
.check { list-style: none; padding: 0 !important; margin: .8rem 0 0; font-family: var(--sans); font-size: .97rem; }
.check li { margin: 0; border-top: 1px solid var(--line); }
.check label { display: flex; gap: .75rem; align-items: flex-start; padding: .6rem 0; cursor: pointer; line-height: 1.45; }
.check input { appearance: none; -webkit-appearance: none; flex: none; width: 1.25rem; height: 1.25rem; margin-top: .1rem; border: 2px solid var(--line-2); border-radius: .35rem; background: var(--paper); cursor: pointer; display: grid; place-items: center; }
.check input:checked { background: var(--olive); border-color: var(--olive); }
.check input:checked::after { content: ""; width: .35rem; height: .65rem; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg) translate(-1px, -1px); }
.check input:checked + span { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--line-2); }

/* perguntas (mentoria, reflexão) */
.qs { list-style: none; padding: 0 !important; counter-reset: q; }
.qs li { counter-increment: q; position: relative; padding: .75rem 0 .75rem 2.4rem; border-top: 1px solid var(--line); margin: 0; }
.qs li::before { content: counter(q, decimal-leading-zero); position: absolute; left: 0; top: .85rem; font: 700 .8rem var(--sans); color: var(--terra); }

/* leituras */
.reads { display: grid; gap: .8rem; margin: 1.25rem auto; }
.read { display: grid; grid-template-columns: 3rem 1fr; gap: .9rem; align-items: start; padding: .9rem 1rem; background: var(--surface); border: 1px solid var(--line); border-radius: .9rem; }
.read .spine { width: 3rem; height: 4rem; border-radius: .25rem .5rem .5rem .25rem; background: var(--terra); box-shadow: inset 4px 0 0 rgba(0,0,0,.15); }
.read:nth-child(2n) .spine { background: var(--olive); }
.read:nth-child(3n) .spine { background: var(--slate); }
.read h4 { margin: 0 0 .15rem; font-family: var(--serif); font-size: 1.02rem; }
.read .au { font-family: var(--sans); font-size: .85rem; color: var(--muted); margin-bottom: .35rem; }
.read p { margin: 0; font-size: .95rem; }

/* mapa da jornada (início) */
.journey { list-style: none; padding: 0 !important; margin: 2rem auto; display: grid; gap: .9rem; }
.journey > li { margin: 0; }
.jcard { display: grid; grid-template-columns: 3.2rem 1fr; gap: 1rem; padding: 1rem 1.1rem; background: var(--surface); border: 1px solid var(--line); border-radius: 1rem; text-decoration: none; color: var(--ink); transition: border-color .15s, transform .15s; }
a.jcard:hover { border-color: var(--terra); color: var(--ink); transform: translateY(-1px); }
.jcard .jn { font: 700 1.5rem/1 var(--serif); color: var(--terra); padding-top: .2rem; }
.jcard h3 { margin: 0 0 .2rem; font-size: 1.1rem; }
.jcard p { margin: 0; font-size: .95rem; color: var(--ink-2); }
.jcard .meta { font-family: var(--sans); font-size: .8rem; color: var(--muted); margin-top: .4rem; }
.jcard .meta .done { color: var(--olive); font-weight: 700; }
.phase { font-family: var(--sans); font-size: .76rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 700; margin: 2.2rem auto .2rem; }
.grid2 { display: grid; gap: .9rem; margin: 1.5rem auto; }
@media (min-width: 720px) { .grid2 { grid-template-columns: 1fr 1fr; } }

/* fim de módulo */
.finish { margin: 3rem auto 0; padding: 1.5rem; border-radius: 1rem; background: var(--sunk); text-align: center; font-family: var(--sans); }
.finish p { margin: 0 auto .9rem; color: var(--ink-2); }
.btn { display: inline-flex; align-items: center; gap: .5rem; font: 700 .95rem var(--sans); padding: .75rem 1.2rem; border-radius: .7rem; border: 1px solid var(--terra); background: var(--terra); color: #fff; cursor: pointer; text-decoration: none; }
.btn:hover { background: var(--terra-2); border-color: var(--terra-2); color: #fff; }
.btn.ghost { background: transparent; color: var(--terra); }
.btn.is-done { background: var(--olive); border-color: var(--olive); }
.pn { display: grid; gap: .8rem; margin: 2rem auto 0; font-family: var(--sans); }
@media (min-width: 620px) { .pn { grid-template-columns: 1fr 1fr; } }
.pn a { display: block; padding: .9rem 1.1rem; border: 1px solid var(--line); border-radius: .9rem; text-decoration: none; background: var(--surface); color: var(--ink); }
.pn a:hover { border-color: var(--terra); }
.pn small { display: block; color: var(--muted); font-size: .8rem; margin-bottom: .15rem; }
.pn .next { text-align: right; }
.pn .next:only-child { grid-column: 2; }

footer.foot { font-family: var(--sans); font-size: .82rem; color: var(--muted); text-align: center; padding: 2rem 1rem 3rem; border-top: 1px solid var(--line); margin-top: 3rem; }

/* impressão: cada ferramenta numa folha limpa */
@page { size: A4; margin: 14mm 14mm 16mm; }
@media print {
  :root, :root[data-theme="dark"] {
    --paper: #fff; --surface: #fff; --sunk: #F3EFE7; --ink: #1E1A17; --ink-2: #3A342E; --muted: #6E655C;
    --line: #D9D0C2; --line-2: #B9AD9B; --terra: #8A4526; --olive: #4C5733; color-scheme: light;
  }
  html, body { background: #fff !important; }
  body { font-size: 10.5pt; line-height: 1.5; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; box-shadow: none !important; }
  .topbar, .side, .scrim, .toc, .toc-inline, .pn, .finish, .tool-head button, footer.foot, .figure, .exemplo > summary { display: none !important; }
  .shell { padding: 0 !important; min-height: 0 !important; }
  main { padding: 0 !important; }
  .with-toc { display: block !important; max-width: none !important; }
  .page > *, .page .wide { max-width: none !important; }
  a { color: inherit; text-decoration: none; }

  /* blocos pequenos não partem; a ferramenta inteira pode partir entre campos */
  .box, .task, .rub-row, .caso, .field, .tbl tr, .steps > li, .read, .qs li { break-inside: avoid; }
  .page h2, .page h3, .page h4, .tool-head { break-after: avoid; break-inside: avoid; }
  .page h2 { margin-top: 8mm; }
  .page h2 .num { break-after: avoid; }
  .tool { break-inside: auto; border: 1px solid var(--line-2); border-radius: 0; margin: 1rem 0; }
  .exemplo:not([open]) { display: none; }

  /* tabelas sempre como tabela no papel, com altura para escrever nas células vazias */
  .tbl { display: table !important; border-radius: 0; font-size: 9.5pt; }
  .tbl thead { display: table-header-group !important; }
  .tbl tbody { display: table-row-group !important; }
  .tbl tr { display: table-row !important; padding: 0 !important; }
  .tbl td, .tbl th { display: table-cell !important; padding: .45rem .55rem !important; border-bottom: 1px solid var(--line) !important; }
  .tbl td + td, .tbl th + th { border-left: 1px solid var(--line) !important; }
  .tbl td::before { display: none !important; }
  .tbl td.vazio { height: 9mm; }
  tr.extra { display: none; }
  body.print-one tr.extra { display: table-row !important; }
  .rub-levels { grid-template-columns: repeat(3, 1fr) !important; }
  .rub-levels > div { border-top: 0 !important; border-left: 1px solid var(--line) !important; }
  .rub-levels > div:first-child { border-left: 0 !important; }

  /* linhas de escrever: borda real, que sai em qualquer impressora */
  .field .lines { background: repeating-linear-gradient(to bottom, transparent 0, transparent 7.6mm, var(--line-2) 7.6mm, var(--line-2) 7.9mm) !important; }
  .field .lines { height: 15.8mm; } .field .lines.s { height: 7.9mm; } .field .lines.l { height: 31.6mm; }
  .field { margin-bottom: 3.5mm; }
  .field .hint { font-size: 8.5pt; }
  .tool-body > p { margin-bottom: 3mm; }
  .qs li { padding: 1.8mm 0 1.8mm 2.2rem; }
  .qs li::before { top: 2mm; }
  .tool-body h4, .tool-body h3 { margin: 4mm 0 1.5mm; }

  tr.extra { break-inside: avoid; }
  body.print-one .tool.printing .quebra { break-before: page; margin-top: 0; }
  .tbl.assina td.vazio { height: 12mm; }
  /* modo "uma ferramenta só" */
  body.print-one .page > *:not(.printing) { display: none !important; }
  body.print-one .tool.printing { display: block !important; border: 0; margin: 0; }
  body.print-one .tool.printing .tool-head {
    display: block; background: none; border: 0; border-bottom: 2px solid var(--terra); padding: 0 0 3mm; margin-bottom: 5mm;
  }
  body.print-one .tool.printing .tool-head::before {
    content: "Liderar Servindo · Programa de liderança para equipes de Comunicação e Marketing"; display: block;
    font: 600 8pt var(--sans); color: var(--muted); letter-spacing: .04em; margin-bottom: 3mm;
  }
  body.print-one .tool.printing .tool-head .k { display: block; font-size: 8.5pt; }
  body.print-one .tool.printing .tool-head h3 { font: 700 17pt/1.2 var(--serif); margin-top: 1mm; }
  body.print-one .tool.printing .tool-head::after {
    content: "Nome: ______________________________     Data: ____/____/______"; display: block;
    font: 400 9.5pt var(--sans); color: var(--ink-2); margin-top: 4mm;
  }
  body.print-one .tool.printing .tool-body { padding: 0; }
  body.print-one .tool.printing .exemplo { display: none !important; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ajustes de celular */

@media (max-width: 520px) {
  body { font-size: 1.03rem; }
  .lead { font-size: 1.1rem; }
  .topbar .where { display: none; }
  .hero { padding-top: 1.75rem; }
}
.grid2 > .box, .grid3 > .box { margin: 0; }
.grid3 { display: grid; gap: .9rem; margin: 1.5rem auto; }
@media (min-width: 900px) { .grid3 { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 719px) {
  .tool-head { flex-wrap: wrap; row-gap: .2rem; }
  .tool-head .k { width: 100%; }
  .tool-head h3 { font-size: 1rem; }
  .tbl.inline td:not(:first-child) { min-width: 4.5rem; }
}
/* imagem na mesma largura da coluna de texto (antes vazava 85 px de cada lado) */
.page .figure, .page > .figure.wide { max-width: var(--col); }
/* três estilos na largura da coluna: um por linha, sem vazar para os lados */
@media (min-width: 900px) { .grid3 { grid-template-columns: 1fr; } }

/* Quebra de linha (revisão geral): nunca partir palavra com hífen automático.
   O texto é alinhado à esquerda, então a hifenização não ganha nada e ainda
   quebrava palavras como "su-mário". Parágrafos e listas evitam palavra
   sozinha na última linha (pretty); textos curtos, centralizados, títulos,
   rótulos e células se equilibram em linhas de tamanho parecido (balance).
   Palavra longa demais para a largura (URL, termo composto) quebra sem hífen. */
html, body, body * { -webkit-hyphens: manual; hyphens: manual; }
body { overflow-wrap: break-word; }
.page p, .page li, .page dd, .tbl td, .rub-levels > div, .field .hint, .read p, .box p { text-wrap: pretty; }
h1, h2, h3, h4, .lead, .eyebrow, .finish p, .tag, .tool-head h3, .jcard h3, .jcard p,
.pn a, .chips li, .tbl th, .rub-row > h4, .goals li, .phase,
.small, blockquote, .pair h4, .field .lbl, .task h3 { text-wrap: balance; }
/* palavra composta (texto-base, mal-entendido) não quebra no próprio hífen */
.nw { white-space: nowrap; }

/* ---------- Biblioteca: trilha, "Em resumo" e rodapé com volta ao site
   (pedido do Eduardo 2026-11-12, SEO/AEO da Biblioteca). Discretos de
   propósito: a trilha é sans pequena e apagada, o resumo é um bloco de
   papel com fio terra à esquerda, sem sombra, para não competir com a abertura. */
.trilha { font-family: var(--sans); font-size: .8rem; color: var(--muted); padding-top: 1.5rem; }
.trilha ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .1rem .5rem; }
.trilha li { margin: 0; }
.trilha li + li::before { content: "›"; color: var(--line-2); margin-right: .5rem; }
.trilha a { color: var(--muted); text-decoration: none; }
.trilha a:hover { color: var(--terra); text-decoration: underline; }
.trilha [aria-current] { color: var(--ink-2); }
.trilha + .hero { padding-top: 1rem; }
.resumo { margin: 0 auto 1.75rem; padding: .9rem 1.2rem; border-left: 3px solid var(--terra); background: var(--sunk); border-radius: 0 .7rem .7rem 0; }
.page .resumo p { margin: 0 0 .55rem; font-size: 1rem; line-height: 1.6; color: var(--ink-2); }
.page .resumo p:last-child { margin-bottom: 0; }
.page .resumo .resumo-tag { font-family: var(--sans); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; font-weight: 700; color: var(--terra); margin-bottom: .35rem; }
footer.foot p { margin: 0 0 .35rem; }
footer.foot .foot-links a { color: var(--muted); }
footer.foot .foot-links a:hover { color: var(--terra); }
@media print { .trilha, .resumo { display: none !important; } }
