:root {
  --paper: #faf8f3;
  --cream: #fffdf8;
  --ink: #24392f;
  --green: #315449;
  --pine: #23473a;
  --muted: #516458;
  --rule: #cbd0c3;
  --sage: #e8ecdf;
  --serif: Georgia, "Times New Roman", serif;
  color-scheme: light;
}
* { box-sizing: border-box }
html { scroll-padding-top: 2rem }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.58 system-ui, sans-serif }
.wrap { width: min(1160px, calc(100% - 96px)); margin-inline: auto }
h1, h2, h3, p, figure { margin: 0 }
h1, h2, h3, .brand, .foot b { font-family: var(--serif); font-weight: 400 }
button, select { font: inherit }
a { color: var(--green); text-decoration-thickness: 1px; text-underline-offset: .24em }
a:hover { text-decoration-thickness: 2px }
:focus-visible { outline: 3px solid #935827; outline-offset: 4px }
[tabindex="-1"]:focus:not(:focus-visible) { outline: none }
[hidden], .only-input, .js-only { display: none !important }
.ready [data-view]:not([hidden]).js-only { display: block !important }
.ready .js-only:not([data-view]):not([hidden]) { display: inline-flex !important }
.ready:not(.reading) .only-input { display: block !important }
.sr, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap }
.skip:focus { position: fixed; top: .5rem; left: .5rem; background: white; padding: .65rem 1rem; z-index: 4 }
.brandbar { min-height: 82px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; border-bottom: 1px solid var(--rule) }
.brand { color: var(--ink); font-size: 1.68rem; line-height: 1.13; text-decoration: none; letter-spacing: -.045em }
.brand span, .foot span { display: block; margin-top: .32rem; color: var(--muted); letter-spacing: .045em; font: 500 .78rem/1.4 system-ui, sans-serif }
.pdf-top { font-size: .85rem; font-weight: 600; text-decoration: none; padding-block: .7rem }
.pdf-top span { margin-left: .35rem }
.hero { display: grid; grid-template-columns: 1.12fr .88fr; align-items: center; gap: clamp(2rem, 6vw, 6.5rem); padding-block: clamp(2.5rem, 4.6vw, 4.25rem) }
.kicker, .contents small { font: 650 .74rem/1.4 system-ui, sans-serif; letter-spacing: .135em; text-transform: uppercase; color: var(--muted) }
h1 { font-size: clamp(3rem, 5.7vw, 5.25rem); line-height: 1.01; letter-spacing: -.062em; margin: .95rem 0 1.3rem }
h1 em { display: block; color: var(--green); font-weight: 400 }
.intro, .lead, .reader-intro > p:not(.kicker) { font-size: clamp(1.04rem, 1.3vw, 1.19rem); line-height: 1.62; max-width: 58ch; color: #354b40 }
.actions, .tools, .turn { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem 1.4rem }
.actions { margin-top: 1.8rem }
.btn { display: inline-flex; gap: .8rem; justify-content: center; align-items: center; padding: .78rem 1.25rem; border-radius: .32rem; text-decoration: none; font-size: .93rem; font-weight: 600 }
.primary { background: var(--pine); color: white }
.primary:hover { background: #183b30 }
.text-link, .tools a, .turn > a:not(.btn) { font-weight: 580; font-size: .93rem; padding-block: .6rem }
.byline { padding-top: 1.25rem; color: var(--muted); font: italic 1rem/1.5 var(--serif) }
.cover { position: relative; isolation: isolate; overflow: hidden; min-height: 354px; height: clamp(354px, 29vw, 413px); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 15px; border-radius: 1.2rem .25rem 1.2rem .25rem; background: radial-gradient(ellipse at 90% 0%, #edf0e5 0, transparent 60%), linear-gradient(145deg, #dce3d3 0%, #c5d5bf 70%, #c0d0b9 100%) }
.cover a { display: block; line-height: 0; transform: rotate(-4deg); height: 76%; border-radius: 2px 3px 3px 2px; box-shadow: 2px 2px #eee9d9, 4px 3px #9d9c88, 9px 16px 22px #35413643; }
.cover img { height: 100%; width: auto; max-width: 100%; object-fit: contain; border-radius: inherit }
.cover figcaption { align-self: stretch; display: flex; justify-content: space-between; color: #384e41; padding-inline: 1.4rem; font-size: .76rem }
.contents { display: grid; grid-template-columns: .85fr repeat(3,1fr); border-block: 1px solid var(--rule); padding: 1.35rem 0; align-items: stretch; margin-bottom: 3rem }
.contents h2 { font-size: 1.55rem; align-self: center }
.contents a { color: var(--ink); border-left: 1px solid var(--rule); padding: .2rem 2.3rem .2rem 1.4rem; position: relative; text-decoration: none }
.contents a:hover strong { text-decoration: underline }
.contents small { display: block; font-size: .76rem; margin-bottom: .35rem }
.contents strong { font: 1.38rem/1.25 var(--serif) }
.contents a > span { position: absolute; right: .85rem; top: 43% }
.workbook { display: grid; gap: clamp(2rem, 5vw, 5rem); grid-template-columns: minmax(10rem, .3fr) minmax(0,1fr); align-items: start }
.workbook:has(.chapter-nav[hidden]) { display: block }
.chapter-nav { margin-top: 4rem; border-left: 1px solid var(--rule); display: grid; align-content: start; position: sticky; top: 1.5rem }
.chapter-nav a { text-decoration: none; padding: .62rem .85rem; margin-left: -1px; color: var(--muted); font-size: .9rem }
.chapter-nav a[aria-current] { border-left: 3px solid var(--green); padding-left: calc(.85rem - 2px); color: var(--ink); background: var(--sage); font-weight: 650 }
.chapter-nav a:hover { text-decoration: underline }
.chapter, .reader-intro { padding: clamp(2rem, 4.2vw, 3.8rem) 0; max-width: 54rem }
.chapter + .chapter:not([hidden]), .reading .chapter { border-top: 1px solid var(--rule) }
.chapter h2, .reader-intro h2 { font-size: clamp(2.3rem, 4.15vw, 3.7rem); letter-spacing: -.047em; line-height: 1.08; margin: .55rem 0 1rem; text-wrap: balance }
.reader-intro .text-link { display: inline-block; margin-top: .65rem }
.guide, .empty { margin: 1.25rem 0; border-left: 3px solid #98ae8b; padding: .7rem 1rem; background: #edf0e6; color: #354b40; font-size: .94rem }
.group { max-width: 43rem; margin: 2rem 0 }
.group h3, .notes h3 { font-size: 1.65rem; letter-spacing: -.032em; line-height: 1.2; margin-bottom: .8rem }
.question { border-top: 1px solid var(--rule); padding: 1.1rem .1rem; display: grid; grid-template-columns: minmax(0,1fr) auto; gap: .6rem 1.5rem; align-items: center }
.topic { font-size: .76rem; font-weight: 650; color: var(--muted) }
.question label { display: block; font-size: 1.05rem; line-height: 1.48 }
.prior { margin-top: .35rem; font-size: .85rem; color: var(--muted) }
.ready:not(.reading) .prior:empty { display: none !important }
select { width: 10.8rem; max-width: 100%; min-height: 44px; border: 1px solid #859280; border-radius: .35rem; padding: .48rem .6rem; background: var(--cream); color: var(--ink) }
.turn { padding-top: 1.35rem; border-top: 1px solid var(--rule); margin-top: 2rem; justify-content: space-between }
.comparison { width: 100%; border-collapse: collapse; margin: 1.65rem 0; font-size: .98rem; table-layout: fixed }
.comparison th, .comparison td { padding: .75rem .7rem; text-align: left; border-bottom: 1px solid var(--rule); vertical-align: top; overflow-wrap: break-word }
.comparison thead { background: var(--sage) }
.comparison tbody th { font-weight: 600 }
.comparison small { display: block; font-weight: 400; color: var(--muted) }
.comparison-label { display: none }
.tools { margin-top: 1.35rem; gap: .25rem 1.4rem }
.link-button { background: transparent; border: 0; padding: .55rem .05rem; cursor: pointer; text-decoration: underline; text-underline-offset: .24em; color: var(--green); font-size: .93rem }
.status { font-size: .9rem; margin-top: .6rem }
.reflection { padding: 0; list-style: none; counter-reset: thoughts; margin: 1.8rem 0 }
.reflection li { position: relative; padding: 1.3rem 1rem 1.3rem 3.3rem; border-top: 1px solid var(--rule); counter-increment: thoughts; font: 1.47rem/1.4 var(--serif) }
.reflection li::before { content: counter(thoughts,decimal-leading-zero); position: absolute; top: 1.5rem; left: .25rem; font: .9rem/1.5 var(--serif); color: var(--muted) }
.notes { max-width: 67ch; margin-top: 1.7rem }
.chapter-resources {
  max-width: 67ch;
  margin-top: 1.8rem;
  background: var(--cream);
  border: 1px solid var(--rule);
  border-radius: .65rem;
}
.chapter-resources details + details { border-top: 1px solid var(--rule) }
.chapter-resources summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 56px;
  padding: .85rem 1.1rem;
  font: 1.17rem/1.35 var(--serif);
  color: var(--pine);
  cursor: pointer;
  list-style: none;
}
.chapter-resources summary::-webkit-details-marker { display: none }
.chapter-resources summary::after {
  content: "";
  flex: 0 0 auto;
  width: .5rem;
  height: .5rem;
  margin-right: .2rem;
  border: solid currentColor;
  border-width: 0 1.5px 1.5px 0;
  transform: rotate(45deg);
}
.chapter-resources details[open] summary::after { transform: rotate(225deg) }
.chapter-resources summary:hover { color: var(--ink); background: var(--sage) }
.chapter-resources ul { list-style: none; margin: 0; padding: 0 1.1rem .6rem }
.chapter-resources li > :is(a,button) {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .8rem;
  min-height: 44px;
  width: 100%;
  padding: .55rem .1rem;
  border: 0;
  border-top: 1px solid var(--rule);
  color: var(--green);
  background: transparent;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  font: inherit;
}
.chapter-resources li > :is(a,button):hover { text-decoration: underline; text-underline-offset: .24em }
.chapter-resources li span { font-size: .86rem; color: var(--muted) }
.chapter-end { max-width: 67ch; margin-top: 1.5rem; padding-top: .65rem; gap: .5rem }
.chapter-end > a { display: inline-flex; gap: .45rem; align-items: center; min-height: 44px }
.foot { border-top: 1px solid var(--rule); padding: 1.5rem 0 2rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 2rem }
.foot b { font-size: 1.15rem }
.foot a { font-size: .79rem }
.foot nav { display: flex; gap: 1.2rem; flex-wrap: wrap }
.reading .turn:not(.chapter-end) { display: none }
.reading .chapter-end { justify-content: flex-end }
.reading .chapter-end a[href="#reflexao"] { display: none }
.reading .question { grid-template-columns: 1fr }
@media(max-width:850px) {
  .wrap { width: min(100% - 48px, 720px) }
  .hero { gap: 2rem; grid-template-columns: 1.2fr .8fr }
  .cover { height: 320px; min-height: 0 }
  .contents { grid-template-columns: repeat(3,1fr); row-gap: 1rem }
  .contents h2 { grid-column: 1/-1 }
  .contents a:first-of-type { border-left: 0; padding-left: 0 }
  .workbook { display: block }
  .chapter-nav { position: static; display: flex; gap: .1rem .7rem; flex-wrap: wrap; border: 0; border-bottom: 1px solid var(--rule); margin: .5rem 0 0; padding-bottom: .4rem }
  .chapter-nav a { line-height: 1.35; padding: .65rem .3rem }
  .chapter-nav a[aria-current] { border: 0; padding: .65rem .4rem; border-radius: 3px }
}
@media(max-width:620px) {
  .wrap { width: calc(100% - 36px) }
  .brandbar { min-height: 68px }
  .brand { font-size: 1.38rem }
  .pdf-top { font-size: .76rem }
  .hero { grid-template-columns: 1fr; gap: 1.5rem; padding: 2rem 0 }
  h1 { margin: .65rem 0 1rem; font-size: clamp(3rem, 12vw, 4rem) }
  .intro, .lead { font-size: 1.02rem }
  .actions { margin-top: 1.25rem; gap: .4rem 1rem }
  .byline { padding-top: .9rem }
  .cover { height: 210px; flex-direction: row; justify-content: center; gap: min(8vw,2rem) }
  .cover a { height: 78% }
  .cover figcaption { align-self: center; flex-direction: column; padding: 0; font-size: .78rem; gap: .2rem }
  .contents { grid-template-columns: 1fr; padding-bottom: 0; gap: 0; margin-bottom: 1.8rem }
  .contents h2 { margin-bottom: .7rem }
  .contents a, .contents a:first-of-type { padding: .85rem 1.4rem .85rem 0; border: 0; border-top: 1px solid var(--rule) }
  .contents strong { font-size: 1.25rem }
  .chapter h2 { margin-top: .5rem }
  .question { grid-template-columns: 1fr; padding: .9rem 0 }
  .comparison { font-size: .86rem }
  .comparison td, .comparison th { padding: .65rem .3rem }
  .foot { gap: .7rem 1.25rem }
}
@media(max-width:420px) {
  .comparison, .comparison tbody { display: block }
  .comparison thead { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap }
  .comparison tbody { display: grid; gap: .75rem }
  .comparison tbody tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9rem; padding: 1rem; border: 1px solid var(--rule); border-radius: .45rem; background: var(--cream) }
  .comparison tbody th, .comparison tbody td { display: block; padding: 0; border: 0 }
  .comparison tbody th { grid-column: 1 / -1; font-size: 1rem }
  .comparison-label { display: block; margin-bottom: .25rem; color: var(--muted); font-size: .78rem; font-weight: 600; line-height: 1.3 }
}
@page { margin: 15mm }
@media print {
  body, .wrap { background: white; color: black; font-size: 10pt; margin: 0; width: 100% }
  .wrap { max-width: none }
  body .view[hidden]:not(#comparacao), #inicio { display: block !important }
  body #comparacao, .only-input, body.ready:not(.reading) .only-input, .chapter-nav, .contents, .reader-intro, nav, .actions, .turn, .cover, .pdf-top, .tools, .skip, .foot, .chapter-resources, .byline { display: none !important }
  .workbook, .hero, .question { display: block }
  .brandbar { min-height: 0; padding: 0 0 .5rem }
  .hero { padding: 1rem 0 0 }
  .hero h1 { font-size: 26pt; margin: .35rem 0 }
  .hero h1 em { display: inline; color: black }
  h2, h3, .kicker, .topic { break-after: avoid }
  .chapter, .group { padding: 0; margin: .75rem 0; max-width: none; border: 0 }
  .chapter h2, .group h3 { font-size: 17pt; margin: .35rem 0 }
  .question, .reflection li, .notes { break-inside: avoid }
  .question { padding: .35rem 0 }
  .question::after { content: "Minha resposta  _____________________________________"; font-size: 9pt; color: #424e42 }
  .reflection li { font-size: 12pt; margin: 0; padding: .55rem .5rem .75rem 2rem }
  .reflection li::before { top: .65rem }
  .reflexao, .notes { margin: .5rem 0 }
  .intro, .lead, .question label, .notes p { font-size: 10pt }
  .guide { margin: .4rem 0 }
}
