/* The public catalog uses the same ink and type as the publisher's imprint. */
:root {
  --frame: 1240px;
  --gutter: clamp(1.15rem, 4vw, 3.75rem);
  --paper: #fbfaf7;
  --surface: #fffefa;
  --ink: #152f45;
  --green: #173e56;
  --accent: #21688a;
  --muted: #465c65;
  --border: #d9dedb;
  --wash: #eef0ea;
  --hover: #e5ecea;
  --desk: #eaf0ed;
  --well: #f1eee6;
  --umber: #75562c;
  --shadow: none;
  --serif: Georgia, 'Times New Roman', serif;
}
[data-theme=dark] {
  --paper: #111d23;
  --surface: #18272e;
  --ink: #eef1ed;
  --green: #b5ddeb;
  --accent: #93c9de;
  --muted: #bdc9c9;
  --border: #36464b;
  --wash: #203037;
  --hover: #2a3c43;
  --desk: #213338;
  --well: #2a302e;
  --umber: #e9c48c;
}
body {
  font-size: 1rem;
  line-height: 1.63;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: var(--serif); font-weight: 400; }
h2 { font-size: clamp(1.65rem, 2.25vw, 2.15rem); }
a { text-decoration-thickness: 1px; text-underline-offset: .19em; }
.button, button.button {
  color: #fff;
  background: #173e56;
  border: 1px solid #173e56;
  border-radius: 5px;
  font-size: .92rem;
  line-height: 1.4;
  font-weight: 600;
  padding: .76rem 1.17rem;
  min-height: 45px;
  transition: background-color .16s ease;
}
.button:hover, button.button:hover { color: #fff; background: #255875; }
[data-theme=dark] .button { background: #b5ddeb; color: #122731; border-color: #b5ddeb; }
[data-theme=dark] .button:hover { background: #d0e8f0; color: #102733; }
.button.secondary, button.button.secondary {
  background: transparent;
  border-color: var(--border);
  color: var(--green);
}
.button.secondary:hover, button.button.secondary:hover { background: var(--hover); color: var(--green); }
.button.danger, button.button.danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.quiet-link, .entry-action {
  color: var(--green);
  font-size: .93rem;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--green) 55%, transparent);
  text-underline-offset: .26em;
}
.quiet-link:hover { text-decoration-color: currentColor; }
.eyebrow {
  color: var(--accent);
  font-size: .88rem;
  letter-spacing: .012em;
  text-transform: none;
  font-weight: 600;
  line-height: 1.5;
  margin-bottom: .6rem;
}
#header {
  height: 86px;
  background: var(--surface);
  padding-inline: max(var(--gutter), calc((100% - var(--frame)) / 2));
  gap: clamp(.75rem, 1.5vw, 1.6rem);
  border-bottom: 1px solid var(--border);
}
#header .brand img { width: 227px; height: 59px; }
#nav { gap: clamp(.8rem, 1.65vw, 1.7rem); font-size: .93rem; line-height: 1.35; }
@media (min-width: 961px) { #header #nav { background: transparent; } }
#nav > a:not(.button) { color: var(--ink); }
#nav a[aria-current]:not(.button) { color: var(--accent); text-decoration: underline; text-underline-offset: .42em; }
#nav .button.compact { min-height: 43px; padding: .69rem .97rem; font-size: .89rem; }
.theme-toggle, .menu-toggle {
  min-height: 40px;
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--border);
}
.theme-toggle { width: 40px; height: 40px; border-radius: 50%; }
.theme-toggle svg { width: 19px; height: 19px; }
.theme-toggle .sun, [data-theme=dark] .theme-toggle .moon { display: none; }
[data-theme=dark] .theme-toggle .sun { display: block; }
#workspace:not(.has-sidebar) { max-width: calc(var(--frame) + 2 * var(--gutter)); }
#workspace:not(.has-sidebar) main { padding: 0 var(--gutter) clamp(2rem, 5vw, 4.5rem); }
#main:focus { outline: none; }
.reading-head, .page-head {
  padding: clamp(2.3rem, 4vw, 3.5rem) 0 1.75rem;
  max-width: none;
}
.reading-head h1, .page-head h1, .has-sidebar .page-head h1, .auth-layout h1 {
  font-size: clamp(2.15rem, 3.3vw, 3.05rem);
  line-height: 1.13;
  letter-spacing: -.036em;
  max-width: 28ch;
  margin-bottom: .65rem;
}
.reading-head p, .page-head > p {
  color: var(--muted);
  font-size: 1.03rem;
  line-height: 1.65;
  max-width: 66ch;
  margin-bottom: 0;
}

/* A volume photographed on a paper-toned surface. The title remains live text. */
.cover-link { display: block; min-width: 0; border-radius: 3px; text-decoration: none; }
.cover-link:focus-visible { outline-offset: 5px; }
.book-spread {
  display: grid;
  grid-template-columns: minmax(0, .97fr) minmax(0, 1.03fr);
  align-items: center;
  column-gap: clamp(2rem, 6%, 5rem);
  padding-block: clamp(2rem, 3.5vw, 3rem);
}
.cover-stage {
  --stock: #fff0d3;
  position: relative;
  isolation: isolate;
  min-width: 0;
  margin: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 3px;
  aspect-ratio: 1.27;
  background:
    radial-gradient(ellipse at 78% 18%, #faf6eb 0%, transparent 59%),
    linear-gradient(138deg, #d5cdc0 0%, #ece7db 50%, #d7cfc0 100%);
}
.cover-stage::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(25deg, #b9afa01f 0% 22%, transparent 23% 70%, #fff9ed70 84%, #d1cabb33 100%);
}
[data-theme=dark] .cover-stage {
  background:
    radial-gradient(ellipse at 72% 18%, #585a50, transparent 65%),
    linear-gradient(132deg, #343a38, #474a40 55%, #303432);
}
[data-theme=dark] .cover-stage::before {
  background: linear-gradient(25deg, #080d0e1a 0% 22%, transparent 23% 68%, #ddd9be0d 84%, transparent 100%);
}
.cover-stage figcaption {
  position: absolute;
  right: 1rem;
  bottom: .73rem;
  font-size: .79rem;
  font-style: italic;
  line-height: 1.3;
  font-family: var(--serif);
  color: #534d43;
}
[data-theme=dark] .cover-stage figcaption { color: #e1ded3; }
.binding {
  position: relative;
  z-index: 1;
  container-type: inline-size;
  width: 44%;
  max-width: 245px;
  aspect-ratio: .72;
  margin-bottom: 2%;
  transform: perspective(1000px) rotateY(-13deg) rotateZ(-8deg);
  box-shadow: 6px 9px 9px #2c241834, 16px 22px 23px #2c241837, 29px 34px 41px #2c24181c;
}
.binding::before, .binding::after { content: ''; position: absolute; }
.binding::before {
  right: -3.2%; top: 1.7%; bottom: -.8%; width: 3.8%;
  transform: skewY(29deg);
  background: repeating-linear-gradient(90deg, #d8ceb7 0 1px, #f7efdc 1px 2px, #eae0ca 2px 3px);
  box-shadow: 2px 0 0 #334757;
}
.binding::after {
  left: 1.2%; right: -3%; bottom: -1.8%; height: 2.1%;
  transform: skewX(34deg);
  background: linear-gradient(#e6dcc6, #bcb29e 73%, #1e3b4d 74% 100%);
}
.jacket-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background: var(--stock);
  z-index: 1;
  box-shadow: inset 0 0 1px #615a46;
}
.jacket-face::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: linear-gradient(90deg, #403a2e38, #fff9e82e 1.4%, #39322436 3%, transparent 4.5%, #fff9e84d 5.2%, transparent 6.4%);
}
.jacket-print {
  position: absolute;
  inset: 0;
  color: #172f40;
  background: linear-gradient(100deg, #f4e3c6 0%, #fff0d3 17%, #fff0d3 80%, #ffeac9 100%);
}
.jacket-imprint {
  position: absolute;
  left: 12%;
  top: 6.6%;
  font: 600 4.05cqw/1.2 Arial, sans-serif;
  letter-spacing: .05em;
}
.jacket-typeset {
  position: absolute;
  left: 12%; right: 9%; top: 17%;
  z-index: 1;
}
.jacket-title, .jacket-subtitle { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; }
.jacket-title {
  -webkit-line-clamp: 3;
  font: 400 12.2cqw/1.035 var(--serif);
  letter-spacing: -.048em;
}
.jacket-subtitle {
  -webkit-line-clamp: 3;
  margin-top: 3.6%;
  font: 400 4.9cqw/1.25 var(--serif);
}
.jacket-plate {
  position: absolute;
  left: 0; right: 0; bottom: 10.4%; height: 44%;
  background: linear-gradient(to bottom, var(--stock), transparent 14%), url('/assets/gravura-cadernos.jpg') center 53% / cover no-repeat;
}
.jacket-colophon {
  position: absolute;
  inset: auto 0 0;
  height: 10.5%;
  padding: 0 8% 0 11%;
  background: #193b4b;
  color: #fff7e9;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 5%;
  font: 500 3.8cqw/1.3 Arial, sans-serif;
}
.jacket-colophon img { width: 11%; height: 68%; object-fit: contain; }
.registered-cover {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%; height: 100%;
  object-fit: contain;
  background: #f0ebdc;
}
.spread-copy { min-width: 0; }
.work-edition, .work-actions, .chapter-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: .65rem 1.25rem;
}
.work-edition { margin-bottom: 1.25rem; }
.work-state, .edition-meta { font-size: .91rem; line-height: 1.4; }
.work-state { display: inline-flex; align-items: center; gap: .55rem; font-weight: 600; color: var(--umber); }
.work-state::before { content: ''; width: .55rem; height: .55rem; border: 1.5px solid currentColor; border-radius: 50%; }
.work-state.is-published { color: var(--accent); }
.work-state.is-published::before { background: currentColor; }
.edition-meta { color: var(--muted); }
.work-title {
  font-size: clamp(2.25rem, 3.7vw, 3.42rem);
  line-height: 1.07;
  letter-spacing: -.045em;
  overflow-wrap: anywhere;
  margin-bottom: 0;
}
.work-title > span:first-child { display: block; text-wrap: balance; }
.work-subtitle {
  display: block;
  color: var(--ink);
  font-size: clamp(1.27rem, 1.85vw, 1.68rem);
  line-height: 1.34;
  font-weight: 400;
  letter-spacing: -.012em;
  margin-top: .6rem;
  max-width: 42ch;
}
.edition-subtitle { font-size: 1rem; color: var(--muted); margin: 1rem 0 0; line-height: 1.55; }
.work-lead { max-width: 54ch; font-size: 1.04rem; line-height: 1.73; color: var(--muted); margin: 1.4rem 0 0; }
.work-actions { margin-top: 1.85rem; gap: .85rem 1.3rem; }

.author-desk {
  display: grid;
  grid-template-columns: 1.13fr 1fr;
  align-items: start;
  gap: clamp(2rem, 7vw, 6rem);
  padding: clamp(1.6rem, 3vw, 2.7rem);
  background: var(--desk);
  border-radius: 5px;
}
.desk-intro h2, .proposals h2 { margin-bottom: .7rem; }
.desk-intro p, .proposals p, .imprint-text p { font-size: 1rem; color: var(--muted); line-height: 1.72; max-width: 58ch; }
.desk-actions { display: grid; gap: 1.25rem; }
.desk-actions a { color: var(--ink); text-decoration: none; padding-left: 1rem; border-left: 3px solid var(--accent); }
.desk-actions strong { display: block; font-size: 1.04rem; font-weight: 600; }
.desk-actions span { display: block; font-size: .93rem; color: var(--muted); }
.desk-actions a:hover strong { text-decoration: underline; }
.proposals {
  margin-top: clamp(2rem, 4vw, 3.45rem);
  display: grid;
  grid-template-columns: 1.12fr 1fr;
  align-items: center;
  gap: 2.5rem;
}
.proposals p { margin: 0; }
.proposals > div:last-child { display: flex; gap: .8rem 1.7rem; justify-content: end; flex-wrap: wrap; }
.proposals a { font-size: .94rem; font-weight: 600; }
.press-home > .shelf-section { margin: 0 0 2.8rem; }

/* A single catalog record occupies the shelf, and larger lists use two columns. */
.catalog-tools {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 1.25rem 1.4rem;
  background: var(--wash);
  border-radius: 5px;
}
.catalog-tools .field { font-size: .9rem; flex: 1 1 230px; }
.catalog-tools .field:first-child { flex: 2.4 1 300px; }
.catalog-tools input, .catalog-tools select { border-radius: 4px; }
.result-count { color: var(--muted); font-size: .91rem; margin: 1.15rem 0 0; }
.shelf-section { margin-top: 2.45rem; }
.shelf-section > h2 { margin-bottom: 1.22rem; }
.book-shelf { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.55rem; }
.shelf-entry {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1fr);
  gap: clamp(1.1rem, 2.4vw, 2rem);
  align-items: center;
  color: var(--ink);
  text-decoration: none;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 5px;
  overflow: hidden;
}
.shelf-entry:only-child { grid-column: 1 / -1; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); gap: clamp(1.5rem, 5%, 4rem); }
.shelf-entry .cover-stage { align-self: stretch; aspect-ratio: auto; min-height: 265px; border-radius: 0; }
.shelf-entry:only-child .cover-stage { min-height: 316px; }
.shelf-entry .binding { width: 58%; max-width: 185px; }
.shelf-entry .cover-stage figcaption { font-size: .75rem; right: .75rem; bottom: .6rem; }
.entry-copy { min-width: 0; padding: 1.5rem 1.4rem 1.6rem 0; }
.entry-copy .work-edition { gap: .4rem .9rem; margin-bottom: .8rem; }
.entry-copy h3 { font-size: clamp(1.3rem, 1.75vw, 1.75rem); line-height: 1.24; letter-spacing: -.02em; margin: 0; overflow-wrap: anywhere; }
.shelf-entry:only-child h3 { max-width: 39ch; font-size: clamp(1.65rem, 2.3vw, 2rem); }
.entry-lead { font-size: .96rem; color: var(--muted); line-height: 1.68; margin: .85rem 0 0; max-width: 65ch; }
.entry-action { display: inline-block; margin-top: 1.05rem; }
.shelf-entry:hover .entry-action { text-decoration-thickness: 2px; }
.shelf-entry:not(:only-child) .entry-lead { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.chapter-shelf { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 1.4rem; }
.chapter-entry { padding: 1.3rem 0; border-top: 2px solid var(--border); min-width: 0; }
.chapter-meta { font-size: .88rem; color: var(--muted); margin-bottom: .7rem; }
.chapter-entry h3 { font-size: 1.5rem; line-height: 1.3; margin-bottom: .65rem; }
.chapter-entry h3 a { text-decoration: none; }
.chapter-entry h3 a:hover { text-decoration: underline; }
.chapter-entry p, .section-note { color: var(--muted); font-size: .99rem; line-height: 1.7; max-width: 78ch; }
.section-link { display: inline-block; margin-top: .8rem; }
.catalog-empty { background: var(--well); border-radius: 5px; padding: 2rem; margin-top: 1.2rem; }
.catalog-empty h2 { font-size: 1.55rem; }
.catalog-empty p { max-width: 68ch; margin-bottom: .35rem; }

.book-record, .imprint-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, .75fr);
  gap: clamp(1.8rem, 6vw, 5.5rem);
  align-items: start;
}
.record-description, .imprint-text p { white-space: pre-line; overflow-wrap: anywhere; max-width: 67ch; font-size: 1.03rem; line-height: 1.76; color: var(--muted); }
.record-facts, .model-shelf { background: var(--well); padding: clamp(1.4rem, 2.5vw, 2.1rem); border-radius: 4px; }
.record-facts h2 { font-size: 1.48rem; }
.record-facts dl { display: grid; gap: .9rem; }
.record-facts dt, .manuscript-facts dt { font-size: .89rem; font-weight: 600; letter-spacing: 0; text-transform: none; margin: 0 0 .16rem; color: var(--muted); }
.record-facts dd, .manuscript-facts dd { font-size: 1rem; margin: 0; }
.record-facts .quiet-link { display: inline-block; margin-top: 1.1rem; }
.imprint-text h2:not(:first-child) { margin-top: 1.8rem; }
.guide-head { display: flex; align-items: end; justify-content: space-between; gap: 2rem; }
.guide-head .button { flex: none; }
.guide-preparation { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(2rem, 6vw, 5rem); align-items: start; }
.guide-description { padding-top: .9rem; }
.guide-description > p { color: var(--muted); font-size: 1rem; max-width: 63ch; }
.manuscript-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 1.3rem 1.7rem; margin: 1.45rem 0 0; }
.manuscript-facts dd { font-family: var(--serif); font-size: 1.2rem; }
.model-shelf h2 { font-size: 1.65rem; margin-bottom: 1.1rem; }
.model-shelf > a { display: grid; grid-template-columns: 23px 1fr 20px; gap: .9rem; align-items: center; padding: .83rem 0; text-decoration: none; }
.model-shelf > a + a { border-top: 1px solid var(--border); }
.model-shelf strong, .model-shelf a span span { display: block; }
.model-shelf strong { font-size: 1rem; color: var(--ink); }
.model-shelf a span span, .model-shelf > p { font-size: .91rem; color: var(--muted); line-height: 1.53; }
.model-shelf > p { margin: .8rem 0 0; }
.model-shelf a:hover strong { text-decoration: underline; }
.doc-icon { display: block; position: relative; height: 26px; width: 20px; border: 1.4px solid currentColor; border-radius: 2px; color: var(--accent); }
.doc-icon::after { content: ''; position: absolute; inset: 10px 3px auto; height: 4px; border-block: 1px solid currentColor; }
.download-icon { position: relative; width: 15px; height: 15px; color: var(--accent); border-bottom: 1.5px solid currentColor; }
.download-icon::before { content: ''; position: absolute; height: 9px; left: 7px; border-left: 1.5px solid currentColor; }
.download-icon::after { content: ''; position: absolute; width: 5px; height: 5px; top: 3px; left: 4.8px; border: solid currentColor; border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); }
.fee-note { display: grid; grid-template-columns: .82fr 1.18fr; align-items: center; gap: 2rem; padding: 1.5rem 2rem; margin-top: 2.3rem; background: var(--desk); border-radius: 4px; }
.fee-note h2 { font: 600 .96rem/1.45 Arial, sans-serif; margin: 0 0 .35rem; }
.fee-note .fee-value { font: 400 1.8rem/1.2 var(--serif); margin: 0; color: var(--ink); }
.fee-value span { display: block; margin-top: .25rem; font: .93rem/1.4 Arial, sans-serif; color: var(--muted); }
.fee-note > p { margin: 0; color: var(--muted); font-size: .97rem; max-width: 67ch; }
.guide-process { display: grid; grid-template-columns: .65fr 1.35fr; gap: clamp(2rem, 6vw, 5rem); padding-top: clamp(2.4rem, 4vw, 3.6rem); }
.process-intro > p { color: var(--muted); max-width: 34ch; font-size: 1rem; }
.process-list { list-style: none; margin: 0; padding: 0; counter-reset: stage; }
.process-list li { display: grid; grid-template-columns: 2.15rem 1fr; column-gap: 1rem; position: relative; padding: 0 0 1.35rem; counter-increment: stage; }
.process-list li::before { content: counter(stage); display: grid; place-items: center; z-index: 1; width: 2.1rem; height: 2.1rem; border-radius: 50%; background: var(--desk); color: var(--green); font: 1.12rem var(--serif); }
.process-list li:not(:last-child)::after { content: ''; position: absolute; width: 1px; top: 2.1rem; bottom: 0; left: 1.04rem; background: var(--border); }
.process-list h3 { font-size: 1.37rem; line-height: 1.3; margin: .1rem 0 .25rem; }
.process-list p { font-size: .98rem; line-height: 1.64; color: var(--muted); margin: 0; max-width: 66ch; }
.guide-notes { margin-top: 1.2rem; padding: 1.35rem 0 0; border-top: 1px solid var(--border); }
.guide-notes p { max-width: 90ch; font-size: .94rem; color: var(--muted); margin-bottom: .65rem; }

/* Secondary pages and the workspace keep the same type sizes and surfaces. */
.prose { max-width: 76ch; }
.prose p { color: var(--muted); font-size: 1.02rem; line-height: 1.75; }
.prose h2 { font-size: 1.66rem; margin-top: 1.85rem; }
.page-head + .prose h2:first-child { margin-top: 0; }
.card, .stat, .table-wrap, details { background: var(--surface); box-shadow: none; border-radius: 5px; }
.card p, .field, .download-list a, .file-list li { font-size: .94rem; }
.has-sidebar main { padding-top: 2rem; }
.has-sidebar .page-head { padding: 0 0 1.5rem; }
.has-sidebar .page-head h1 { font-size: 2.5rem; }
#sidebar { background: var(--wash); }
#sidebar nav a { font-size: .92rem; }
#sidebar nav a.active { background: #173e56; color: #fff; }
.auth-layout { align-items: start; gap: clamp(2rem, 7vw, 5.5rem); margin-block: clamp(2.5rem, 6vw, 5rem); }
.auth-layout .note { padding: 1rem 1.15rem; font-size: .94rem; background: var(--desk); color: var(--ink); border: 0; }
.auth-layout form { background: var(--surface); border-top: 3px solid var(--accent); }
.auth-layout .field { font-size: .94rem; }
.field input, .field select, .field textarea, input:not([type=checkbox]):not([type=radio]), select, textarea { font-size: 1rem; }
.chapter-detail { gap: clamp(1.6rem, 5vw, 4rem); }
.chapter-detail article p { max-width: 76ch; }
.chapter-detail article > h2 { font-size: 1.7rem; }
.chapter-detail .card { box-shadow: none; }
#footer {
  display: block;
  max-width: none;
  padding: 0;
  margin: 0;
  color: #f2f1e9;
  border: 0;
  background: #173443;
}
[data-theme=dark] #footer { background: #0d171d; }
.footer-inner {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 2.15rem 3rem;
  width: 100%;
  max-width: calc(var(--frame) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 2.7rem var(--gutter) 1.3rem;
}
.footer-inner nav { display: grid; align-content: start; gap: .45rem; }
#footer a, #footer p, #footer small { color: inherit; }
#footer a { margin: 0; font-size: .94rem; text-decoration: none; }
#footer a:hover { text-decoration: underline; }
.footer-identity a { display: flex; align-items: center; gap: .7rem; }
.footer-identity strong { font: 400 clamp(1.27rem, 1.65vw, 1.55rem)/1.25 var(--serif); }
#footer .footer-identity p { margin: .45rem 0 0; font-size: .95rem; color: #d2e1e4; }
.footer-legal { grid-column: 1/-1; display: flex; justify-content: space-between; flex-wrap: wrap; gap: .35rem 1rem; padding-top: .9rem; border-top: 1px solid #ffffff26; color: #c5d5d9; }
#footer small { font-size: .83rem; margin: 0; }
#toast { color: #fff; background: #173e56; }
#toast.error { background: #902b2c; }

@media (max-width: 1100px) {
  #header .brand img { width: 192px; }
  #nav { gap: .85rem; font-size: .88rem; }
  #nav .button.compact { padding-inline: .75rem; }
  .book-spread { column-gap: 2rem; }
  .shelf-entry:not(:only-child) { grid-template-columns: 1fr; gap: 0; }
  .shelf-entry:not(:only-child) .entry-copy { padding: 1.3rem; }
  .shelf-entry:not(:only-child) .cover-stage { min-height: 240px; }
  .shelf-entry:not(:only-child) .binding { width: 35%; max-width: 145px; }
}
@media (max-width: 960px) {
  #header { height: 76px; }
  #header .brand img { width: 208px; height: 55px; }
  #nav { top: 75px; padding: 1rem var(--gutter); gap: .3rem; font-size: 1rem; background: var(--surface); z-index: 50; }
  #nav > a:not(.button) { padding: .6rem .1rem; }
  #nav .button { margin-block: .35rem; }
  #menu-toggle { border-radius: 5px; padding: .36rem .7rem; }
  .book-spread:not(.empty) { grid-template-columns: 1fr 1.08fr; }
  .cover-stage { aspect-ratio: 1.03; }
  .binding { width: 52%; }
  .work-edition { gap: .45rem .9rem; }
  .work-title { font-size: clamp(2.12rem, 4.8vw, 2.8rem); }
  .work-lead { font-size: .98rem; margin-top: .9rem; }
  .work-actions { gap: .75rem 1rem; margin-top: 1.15rem; }
  .proposals > div:last-child { justify-content: start; }
  .shelf-entry:only-child .cover-stage { min-height: 285px; }
  .guide-preparation, .book-record, .imprint-layout { grid-template-columns: 1.12fr 1fr; gap: 1.8rem; }
}
@media (max-width: 730px) {
  #header { height: 70px; gap: .6rem; }
  #header .brand img { width: clamp(150px, 42vw, 200px); height: 51px; }
  #nav { top: 69px; }
  .header-controls { gap: .45rem; }
  .theme-toggle { width: 40px; height: 40px; }
  #menu-toggle { font-size: .89rem; }
  .book-spread:not(.empty) { grid-template-columns: minmax(0, 1fr); gap: 1.6rem; padding: 1.3rem 0 2rem; }
  .cover-stage { aspect-ratio: 1.34; max-height: 365px; }
  .binding { width: 42%; max-width: 174px; }
  .cover-stage figcaption { font-size: .76rem; right: .8rem; bottom: .55rem; }
  .work-title { font-size: clamp(2.14rem, 7.4vw, 2.75rem); }
  .work-subtitle { font-size: clamp(1.22rem, 4.5vw, 1.45rem); line-height: 1.35; }
  .work-edition { margin-bottom: .7rem; }
  .work-state, .edition-meta { font-size: .87rem; }
  .work-actions { margin-top: 1.1rem; }
  .author-desk, .proposals, .guide-preparation, .guide-process, .book-record, .imprint-layout { grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
  .author-desk { padding: 1.55rem; }
  .desk-actions { gap: 1rem; }
  .proposals { gap: .9rem; }
  .shelf-section { margin-top: 1.85rem; }
  .book-shelf { grid-template-columns: 1fr; gap: 1.35rem; }
  .shelf-entry:only-child, .shelf-entry:not(:only-child) { grid-template-columns: minmax(0, .72fr) minmax(0, 1fr); gap: 1rem; }
  .shelf-entry:only-child .cover-stage, .shelf-entry:not(:only-child) .cover-stage { max-height: none; min-height: 205px; }
  .shelf-entry:only-child .binding, .shelf-entry:not(:only-child) .binding { width: 64%; max-width: 154px; }
  .shelf-entry .entry-copy, .shelf-entry:not(:only-child) .entry-copy { padding: 1.1rem 1rem 1.1rem 0; }
  .shelf-entry h3, .shelf-entry:only-child h3 { font-size: 1.37rem; }
  .entry-lead { font-size: .93rem; }
  .catalog-tools { padding: 1rem; gap: .7rem; }
  .catalog-tools .field { flex: 1 1 180px; }
  .reading-head, .page-head { padding: 2rem 0 1.3rem; }
  .guide-head { display: block; }
  .guide-head .button { margin-top: 1.05rem; }
  .guide-description { padding: 0; }
  .fee-note { padding: 1.35rem; margin-top: 1.4rem; gap: 1.2rem; grid-template-columns: 1fr; }
  .guide-process { padding-top: 2.15rem; }
  .process-intro > p { max-width: none; margin: 0; }
  .chapter-detail, .auth-layout { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 1.5rem 1.2rem; padding-top: 2rem; }
  .footer-identity { grid-column: 1 / -1; }
}
@media (max-width: 520px) {
  .shelf-entry:only-child, .shelf-entry:not(:only-child) { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .shelf-entry:only-child .cover-stage, .shelf-entry:not(:only-child) .cover-stage { min-height: 0; aspect-ratio: 1.68; }
  .shelf-entry:only-child .binding, .shelf-entry:not(:only-child) .binding { width: 30%; max-width: 128px; }
  .shelf-entry .entry-copy, .shelf-entry:not(:only-child) .entry-copy { padding: 1.15rem 1.2rem; }
  .manuscript-facts { gap: 1.15rem .9rem; }
  .catalog-tools { flex-direction: column; align-items: stretch; }
  .catalog-tools .field, .catalog-tools .field:first-child { flex: auto; }
  .reading-head h1, .page-head h1, .auth-layout h1 { font-size: 2.25rem; }
  .prose p { font-size: 1rem; }
}
@media (prefers-reduced-motion: reduce) { .button { transition: none; } }
@media print {
  #header, #footer { display: none !important; }
  .book-spread { gap: 1rem; }
  .binding { box-shadow: none; transform: none; }
}
