/* ==========================================================================
   Daniel Bolmart — web de autor
   Base neutra (negro, antracita, grises cálidos, blanco roto).
   El color de interfaz lo ponen solo las portadas: terracota (Semillas de
   naranjo), verde (La piedra…) y azul noche (El faro cansado).
   ========================================================================== */

:root {
  --ink: #161310;
  --coal: #2c2822;
  --stone: #8c8272;
  --sand: #d9d1c2;
  --paper: #f4eee3;
  --paper-2: #ebe2d1;
  --text-soft: #5a5246;
  --terra: #a8622f;
  --terra-deep: #8f5326;
  --terra-text: #94521f;
  --olive: #4b5a2e;
  --night: #28384b;

  --serif: "EB Garamond", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;

  --gutter: clamp(20px, 4vw, 56px);
  --wrap: 1240px;
  --ease: cubic-bezier(0.22, 0.7, 0.2, 1);
  --noise: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .09 0 0 0 0 .07 0 0 0 0 .05 0 0 0 .12 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--noise), var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.18rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
button, input, textarea { font: inherit; color: inherit; }

:focus-visible { outline: 2px solid var(--terra); outline-offset: 3px; }
.on-dark :focus-visible, .site-footer :focus-visible { outline-color: var(--paper); }

.wrap { width: min(var(--wrap), 100% - 2 * var(--gutter)); margin-inline: auto; }
.skip-link {
  position: absolute; left: var(--gutter); top: -80px; z-index: 200;
  background: var(--ink); color: var(--paper); padding: 12px 18px;
  font: 600 0.95rem var(--sans); text-decoration: none;
}
.skip-link:focus { top: 12px; }

/* ---------- Tipografía ---------- */
.h-display {
  font-weight: 500;
  font-size: clamp(2.6rem, 7vw, 5.4rem);
  line-height: 1.02;
  letter-spacing: -0.012em;
}
.h-section {
  font-weight: 500;
  font-size: clamp(2rem, 4.4vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.008em;
}
.h-card { font-weight: 500; font-size: clamp(1.45rem, 2vw, 1.8rem); line-height: 1.16; }
.lede { font-size: clamp(1.3rem, 2.1vw, 1.65rem); line-height: 1.45; }
.measure { max-width: 62ch; }
.soft { color: var(--text-soft); }
.ui { font-family: var(--sans); }
.italic { font-style: italic; }

/* ---------- Botones y enlaces ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 12px 24px;
  background: var(--terra-deep); color: #fff;
  border: 1px solid var(--terra-deep); border-radius: 4px;
  font: 600 0.98rem var(--sans); letter-spacing: 0.01em; text-decoration: none;
  cursor: pointer; transition: background 0.25s var(--ease), border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.btn:hover { background: var(--ink); border-color: var(--ink); }
.btn--ghost { background: transparent; color: inherit; border-color: currentColor; }
.btn--ghost:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.on-dark .btn--ghost:hover { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.on-dark .btn:not(.btn--ghost):hover { background: var(--paper); color: var(--ink); border-color: var(--paper); }

.link-arrow {
  display: inline-flex; align-items: center; min-height: 44px;
  font: 600 0.98rem var(--sans); text-decoration: none;
  border-bottom: 1px solid currentColor; padding-block: 8px 6px;
}
.link-arrow::after { content: "\2192"; margin-left: 10px; transition: transform 0.25s var(--ease); }
.link-arrow:hover::after { transform: translateX(4px); }

/* ---------- Cabecera ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--paper) 94%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease);
}
.site-header.is-scrolled { border-bottom-color: var(--sand); }
.bar { display: flex; align-items: center; gap: 24px; min-height: 76px; }
.brand {
  font-weight: 500; font-size: 1.05rem; letter-spacing: 0.16em; text-transform: uppercase;
  text-decoration: none; white-space: nowrap; margin-right: auto;
}
.nav { display: flex; gap: clamp(18px, 2.6vw, 38px); font: 500 0.98rem var(--sans); }
.nav a {
  text-decoration: none; padding: 10px 0; position: relative;
}
.nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 4px; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: left;
  transition: transform 0.3s var(--ease);
}
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.cta-new {
  display: inline-flex; align-items: center; gap: 9px; min-height: 46px; padding: 10px 20px;
  background: var(--ink); color: var(--paper); border-radius: 4px;
  font: 600 0.95rem var(--sans); text-decoration: none; white-space: nowrap;
  transition: background 0.25s var(--ease);
}
.cta-new:hover { background: var(--terra-deep); }
.cta-new svg { width: 18px; height: 18px; flex: none; }
.menu-toggle {
  display: none; width: 46px; height: 46px; padding: 0; background: none;
  border: 1px solid var(--sand); border-radius: 4px; cursor: pointer;
}
.menu-toggle span, .menu-toggle span::before, .menu-toggle span::after {
  display: block; width: 18px; height: 1.5px; background: var(--ink); margin: auto; position: relative; content: "";
}
.menu-toggle span::before { position: absolute; top: -6px; left: 0; }
.menu-toggle span::after { position: absolute; top: 6px; left: 0; }

/* ---------- Portada ---------- */
.hero { padding-block: clamp(20px, 4vw, 56px) clamp(56px, 8vw, 112px); }
.masthead {
  font-weight: 500; text-transform: uppercase; text-align: center; white-space: nowrap;
  font-size: clamp(1.7rem, 7.8vw, 7rem); letter-spacing: 0.1em; line-height: 1;
  padding-bottom: clamp(28px, 4vw, 52px); margin-right: -0.1em;
  border-bottom: 1px solid var(--ink);
}
.hero__grid {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(32px, 6vw, 96px); align-items: center; padding-top: clamp(32px, 5vw, 64px);
}
.hero__lede {
  font-style: italic; font-weight: 400;
  font-size: clamp(1.9rem, 3.7vw, 3.3rem); line-height: 1.16; letter-spacing: -0.005em;
  max-width: 19em;
}
.hero__role { margin-top: 26px; color: var(--text-soft); font: 500 1rem var(--sans); }
.entries { display: flex; flex-wrap: wrap; gap: 8px 40px; margin-top: clamp(28px, 4vw, 48px); }
.hero__book img { width: 100%; box-shadow: 0 1px 0 var(--sand); }
.hero__caption {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 14px 20px; padding-top: 18px;
}
.hero__caption p { font-size: 1.05rem; line-height: 1.3; }
.hero__caption em { display: block; font-size: 1.3rem; }
.hero__caption small { font: 500 0.9rem var(--sans); color: var(--terra-text); }

.hero .rise { opacity: 0; transform: translateY(14px); animation: rise 0.9s var(--ease) forwards; }
.hero .rise:nth-child(2) { animation-delay: 0.12s; }
.hero .rise:nth-child(3) { animation-delay: 0.24s; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- Banda oscura: Semillas de naranjo ---------- */
.band-dark {
  background: linear-gradient(rgba(22, 19, 16, 0.8), rgba(22, 19, 16, 0.93)), url("../img/textura.jpg") center / cover;
  color: var(--paper); padding-block: clamp(64px, 9vw, 128px);
}
.seed { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(32px, 6vw, 104px); align-items: center; }
.seed__cover { max-width: 340px; justify-self: center; }
.seed__cover img { width: 100%; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.7); }
.seed__lead { font-style: italic; font-size: clamp(1.45rem, 2.4vw, 2rem); line-height: 1.38; margin-top: 26px; }
.themes { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: clamp(28px, 4vw, 44px); }
.themes li {
  padding: 6px 0 6px 18px; border-left: 1px solid rgba(247, 243, 236, 0.3);
  font-style: italic; font-size: clamp(1.15rem, 1.7vw, 1.4rem);
}
.actions { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; margin-top: clamp(28px, 4vw, 44px); }

/* ---------- El Cuaderno ---------- */
.section { padding-block: clamp(64px, 9vw, 128px); }
.section-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 16px 40px; margin-bottom: clamp(32px, 5vw, 64px); }
.section-head p { max-width: 38ch; color: var(--text-soft); }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(28px, 3.4vw, 56px); }
.card { border-top: 2px solid var(--ink); padding-top: 22px; display: flex; flex-direction: column; gap: 14px; }
.card__cat { font: 600 0.9rem var(--sans); color: var(--terra-text); }
.card__excerpt { color: var(--text-soft); font-size: 1.1rem; line-height: 1.55; }
.card__status { margin-top: auto; padding-top: 10px; font: 500 0.9rem var(--sans); color: var(--text-soft); display: flex; align-items: center; gap: 10px; }
.card__status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; border: 1px solid var(--stone); }
.section-foot { margin-top: clamp(28px, 4vw, 48px); }

.band-sand { background: var(--paper-2); }

/* ---------- Estantería ---------- */
.shelf-wrap { background: var(--sand); }
.shelf { display: flex; gap: 12px; height: clamp(520px, 62vw, 600px); }
.book {
  --c: var(--terra-deep);
  flex: 0 0 112px; position: relative; overflow: hidden; border-radius: 4px;
  background: var(--c); color: #fff;
  transition: flex-basis 0.7s var(--ease);
}
.book::after { /* grano de papel sobre cada lomo */
  content: ""; position: absolute; inset: 0; background: var(--noise); opacity: 0.55; pointer-events: none;
}
.book.is-active { flex: 1 1 0; }
.book__spine {
  position: absolute; inset: 0; width: 100%; z-index: 2; padding: 28px 0 24px;
  display: flex; flex-direction: column; align-items: center; justify-content: space-between;
  background: none; border: 0; cursor: pointer; color: inherit;
  transition: opacity 0.35s var(--ease), background 0.3s var(--ease);
}
.book__spine:hover { background: rgba(255, 255, 255, 0.07); }
.book__spine-title {
  writing-mode: vertical-rl; transform: rotate(180deg);
  font-weight: 500; font-size: 1.05rem; letter-spacing: 0.12em; text-transform: uppercase;
  white-space: normal; text-align: center; line-height: 1.3; max-height: 420px;
}
.book__dot { width: 9px; height: 9px; border-radius: 50%; border: 1.5px solid #fff; flex: none; }
.book__dot.is-on { background: #fff; }
.book.is-active .book__spine { opacity: 0; pointer-events: none; }
.book__panel {
  position: absolute; inset: 0 auto 0 0; z-index: 1; width: 100%; min-width: 760px;
  padding: clamp(24px, 3.4vw, 48px); display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: center;
  opacity: 0; visibility: hidden; transition: opacity 0.4s var(--ease), visibility 0s linear 0.4s;
}
.book.is-active .book__panel { opacity: 1; visibility: visible; transition: opacity 0.5s var(--ease) 0.25s, visibility 0s; }
.book__panel img { width: 100%; box-shadow: 0 24px 44px -18px rgba(0, 0, 0, 0.65); }
.book__status { display: inline-flex; align-items: center; gap: 10px; font: 600 0.92rem var(--sans); }
.book__status::before { content: ""; width: 9px; height: 9px; border-radius: 50%; border: 1.5px solid #fff; }
.book__status.is-on::before { background: #fff; }
.book__title { font-weight: 500; font-size: clamp(1.9rem, 3.4vw, 2.9rem); line-height: 1.06; margin-top: 14px; outline: none; }
.book__text { margin-top: 18px; font-size: 1.12rem; line-height: 1.55; max-width: 46ch; }
.book__text + .book__text { margin-top: 12px; opacity: 0.88; font-style: italic; }
.book .actions { margin-top: 26px; }
.book .btn { background: #fff; color: var(--ink); border-color: #fff; }
.book .btn:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.book .btn--ghost { background: transparent; color: #fff; border-color: #fff; }
.book .btn--ghost:hover { background: #fff; color: var(--ink); }
.book .link-arrow { color: #fff; }
.book :focus-visible { outline-color: #fff; }

/* ---------- Sobre Daniel ---------- */
.about { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: clamp(28px, 5vw, 80px); align-items: start; }
.portrait { position: relative; isolation: isolate; width: 220px; }
.portrait img { width: 220px; height: 220px; object-fit: cover; border-radius: 50%; border: 6px solid var(--paper); box-shadow: 0 0 0 1px var(--sand); filter: grayscale(0.15) contrast(1.02); }
.portrait figcaption { margin-top: 10px; font: 500 0.85rem var(--sans); color: var(--text-soft); }
.about__text > * + * { margin-top: 20px; }

/* ---------- Encuentros + newsletter ---------- */
.band-coal { background: var(--coal); color: var(--paper); padding-block: clamp(64px, 8vw, 112px); }
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }
.duo > div { padding-inline: clamp(0px, 3vw, 56px); }
.duo > div:first-child { padding-left: 0; border-right: 1px solid rgba(247, 243, 236, 0.22); }
.duo > div:last-child { padding-right: 0; }
.duo .h-card { font-size: clamp(1.7rem, 2.8vw, 2.4rem); }
.duo p + p, .duo .h-card + p { margin-top: 16px; }

.form { display: grid; gap: 16px; margin-top: 26px; max-width: 480px; }
.field { display: grid; gap: 7px; }
.field label { font: 600 0.92rem var(--sans); }
.field input, .field textarea {
  min-height: 52px; padding: 12px 14px; background: transparent;
  border: 1px solid currentColor; border-radius: 4px; font: 400 1rem var(--sans); width: 100%;
}
.field textarea { min-height: 110px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: inherit; opacity: 0.55; }
.band-coal .btn, .form--light .btn { justify-self: start; }
.band-coal .btn { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.band-coal .btn:hover { background: var(--terra); border-color: var(--terra); color: #fff; }
.form__note { font: 400 0.88rem/1.5 var(--sans); opacity: 0.8; }
.form__status { font: 600 0.95rem var(--sans); min-height: 1.4em; }

/* ---------- Pie ---------- */
.site-footer { background: var(--ink); color: var(--paper); padding-block: clamp(48px, 6vw, 80px) 32px; font-family: var(--sans); }
.footer__grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 40px; }
.footer__brand { font-family: var(--serif); font-size: 1.5rem; letter-spacing: 0.14em; text-transform: uppercase; }
.site-footer h2 { font: 600 0.95rem var(--sans); margin-bottom: 14px; }
.site-footer li a, .site-footer p a { display: inline-block; padding-block: 5px; color: rgba(247, 243, 236, 0.82); text-decoration: none; font-size: 0.97rem; }
.site-footer li a:hover, .site-footer p a:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.footer__small { margin-top: 48px; padding-top: 20px; border-top: 1px solid rgba(247, 243, 236, 0.18); font-size: 0.87rem; color: rgba(247, 243, 236, 0.7); }

/* ---------- Páginas interiores ---------- */
.page-head { padding-block: clamp(48px, 8vw, 112px) clamp(32px, 5vw, 64px); }
.page-head .lede { margin-top: 24px; max-width: 40ch; color: var(--text-soft); }
.page-body { padding-bottom: clamp(64px, 9vw, 128px); }

.book-page { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.book-page__media { position: sticky; top: 108px; }
.book-page__media img { width: 100%; }
.book-page__body > * + * { margin-top: 20px; }
.status-line { display: inline-flex; align-items: center; gap: 10px; font: 600 0.95rem var(--sans); color: var(--terra-text); }
.status-line::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--terra-text); }
.themes--light { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 8px; }
.themes--light li { border-left-color: var(--stone); }

.entries-list { border-top: 2px solid var(--ink); }
.entry-row { display: grid; grid-template-columns: 180px minmax(0, 1fr) auto; gap: 8px 32px; padding-block: 28px; border-bottom: 1px solid var(--sand); align-items: baseline; }
.entry-row .card__cat { font-size: 0.92rem; }

.contact-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 6vw, 96px); }
.contact-list li { border-top: 1px solid var(--sand); }
.contact-list li:last-child { border-bottom: 1px solid var(--sand); }
.contact-list a { display: flex; justify-content: space-between; align-items: center; min-height: 64px; text-decoration: none; font-size: 1.3rem; }
.contact-list a span { font: 500 0.92rem var(--sans); color: var(--text-soft); }
.contact-list a:hover { color: var(--terra-text); }
.form--light { max-width: 520px; }
.form--light .btn { background: var(--terra-deep); color: #fff; border-color: var(--terra-deep); }
.form--light .btn:hover { background: var(--ink); border-color: var(--ink); }

/* ---------- Cuaderno: tarjetas con imagen y artículos ---------- */
.card__img { display: block; overflow: hidden; border-radius: 2px; margin-bottom: 4px; }
.card__img img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; transition: transform 0.6s var(--ease); }
.card__img:hover img { transform: scale(1.03); }
.card__link { text-decoration: none; }
.card__link:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px; }
.card__status--date::before { display: none; }

.entry-row--img { grid-template-columns: 180px minmax(0, 1fr) 220px; align-items: center; }
.entry-row__img { display: block; overflow: hidden; border-radius: 2px; box-shadow: 0 0 0 1px var(--sand); }
.entry-row__img img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; object-position: center 30%; transition: transform 0.6s var(--ease); }
.entry-row:hover .entry-row__img img { transform: scale(1.04); }

.article { width: min(720px, 100% - 2 * var(--gutter)); margin-inline: auto; padding-block: clamp(48px, 8vw, 104px) clamp(56px, 8vw, 104px); }
.article__head .h-display { font-size: clamp(2.3rem, 5.6vw, 4rem); margin-top: 14px; }
.article__date { margin-top: 18px; font: 500 0.95rem var(--sans); color: var(--text-soft); }
.article__media { margin: clamp(28px, 4vw, 48px) 0 0; text-align: center; }
.article__media img { width: auto; max-width: 100%; max-height: min(640px, 78vh); margin-inline: auto; border-radius: 2px; box-shadow: 0 0 0 1px var(--sand); }
.article__foot { margin-top: clamp(36px, 5vw, 64px); padding-top: 20px; border-top: 1px solid var(--sand); display: flex; flex-wrap: wrap; gap: 4px 32px; }
.prose { margin-top: clamp(28px, 4vw, 44px); font-size: 1.22rem; line-height: 1.75; }
.prose > * + * { margin-top: 1.15em; }
.prose h2, .prose h3 { font-weight: 500; line-height: 1.15; margin-top: 1.8em; }
.prose h2 { font-size: 1.9rem; }
.prose h3 { font-size: 1.5rem; }
.prose a { color: var(--terra-text); text-underline-offset: 3px; }
.prose img { width: 100%; height: auto; border-radius: 2px; margin-block: 1.6em; }
.prose blockquote { margin-inline: 0; padding-left: 22px; border-left: 2px solid var(--terra); font-style: italic; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose ul { list-style: disc; }
.prose li + li { margin-top: 0.4em; }
.prose hr { border: 0; border-top: 1px solid var(--sand); margin-block: 2em; }

/* ---------- Portada y estudios lineales ---------- */
.hero__caption { padding-top: 24px; }

/* Dibujos lineales decorativos (líneas finas color tinta sepia, sin relleno) */
.study { position: absolute; height: auto; pointer-events: none; color: #6e4328; opacity: 0.42; }

/* Reflexión destacada en el Cuaderno */
.featured {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 80px);
  align-items: center; padding-bottom: clamp(40px, 6vw, 80px); margin-bottom: clamp(8px, 2vw, 24px);
}
.featured--noimg { grid-template-columns: minmax(0, 1fr); }
.featured__img { display: block; overflow: hidden; border-radius: 2px; box-shadow: 0 0 0 1px var(--sand); }
.featured__img img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: center 30%; transition: transform 0.8s var(--ease); }
.featured:hover .featured__img img { transform: scale(1.03); }
.featured__text > * + * { margin-top: 20px; }
.featured__text .card__cat { font-size: 0.95rem; }

/* Aperturas con estudio lineal en las páginas interiores */
.page-head { position: relative; }
.page-head > :not(.study) { position: relative; }
.study--head { right: 0; top: 50%; width: min(340px, 38vw); transform: translateY(-50%); }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .featured { grid-template-columns: minmax(0, 1fr); }
  .study--head { display: none; }
  .entry-row--img { grid-template-columns: minmax(0, 1fr); }
  .entry-row__img { max-width: 320px; }
  .hero__grid, .seed, .about, .book-page, .contact-grid { grid-template-columns: minmax(0, 1fr); }
  .hero__book { max-width: 520px; }
  .book-page__media { position: static; max-width: 420px; }
  .cards { grid-template-columns: minmax(0, 1fr); gap: 36px; }
  .themes, .themes--light { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 0; }
  .duo { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .duo > div, .duo > div:first-child, .duo > div:last-child { padding-inline: 0; border-right: 0; }
  .duo > div:first-child { padding-bottom: 48px; border-bottom: 1px solid rgba(247, 243, 236, 0.22); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .entry-row { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 860px) {
  .menu-toggle { display: block; order: 3; }
  .cta-new { order: 2; }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--paper); border-bottom: 1px solid var(--sand); padding: 8px var(--gutter) 20px;
    display: none;
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 14px 0; font-size: 1.05rem; border-bottom: 1px solid var(--paper-2); }
  .nav a::after { display: none; }
  .bar { gap: 12px; }

  /* Estantería en vertical */
  .shelf { flex-direction: column; height: auto; }
  .book { flex: none; height: 76px; transition: height 0.6s var(--ease); }
  .book.is-active { flex: none; height: 780px; }
  .book__spine { flex-direction: row; padding: 0 24px; }
  .book__spine-title { writing-mode: horizontal-tb; transform: none; font-size: 1rem; letter-spacing: 0.12em; max-height: none; text-align: left; }
  .book__panel { min-width: 0; grid-template-columns: minmax(0, 1fr); align-content: start; gap: 22px; padding: 28px 24px; }
  .book__panel img { width: 150px; }
}

@media (max-width: 560px) {
  body { font-size: 1.1rem; }
  .brand { font-size: 0.9rem; letter-spacing: 0.1em; }
  .cta-new { padding: 10px 12px; font-size: 0.88rem; }
  .cta-new svg { display: none; }
  .bar { min-height: 68px; }
  .footer__grid { grid-template-columns: minmax(0, 1fr); }
  .book.is-active { height: 860px; }
  .hero__caption { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; animation-delay: 0s !important; }
  .hero .rise { opacity: 1; transform: none; }
}
