:root {
  --black: #030306;
  --black-2: #08070c;
  --black-3: #0f0d14;

  --panel: rgba(8, 7, 11, 0.90);
  --panel-heavy: rgba(12, 10, 16, 0.96);

  --line-dark: #111018;
  --line-mid: #2b2434;
  --line-soft: #473b56;

  --text: #d8d4dc;
  --text-soft: #aaa2b4;

  --bone: #cfc7ba;
  --bone-dark: #9f968a;

  --purple: #75519b;
  --purple-soft: #a68ac6;
  --purple-dim: #382947;

  --green: #6f875f;
  --green-soft: #9cad84;
  --green-dark: #263423;

  --mud: #5d554e;
  --blood: #4b252f;
  --gold: #b9a369;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: "IM Fell English", Georgia, serif;
  font-size: 21px;
  font-weight: 400;
  letter-spacing: 0.2px;

  background-image:
    linear-gradient(rgba(3, 3, 6, 0.22), rgba(3, 3, 6, 0.50)),
    url("biblioteca-bg.png");

  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-color: #020204;

  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0.16;
  background:
    repeating-linear-gradient(
      0deg,
      rgba(255, 255, 255, 0.030) 0px,
      rgba(255, 255, 255, 0.030) 1px,
      transparent 1px,
      transparent 5px
    ),
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.018) 0px,
      rgba(255, 255, 255, 0.018) 1px,
      transparent 1px,
      transparent 6px
    );
  mix-blend-mode: overlay;
}

body::after {
  display: none;
}

a {
  color: inherit;
  text-decoration: none;
}

.page-frame {
  position: relative;
  z-index: 1;
  max-width: 1240px;
  margin: 18px auto;
  background:
    linear-gradient(rgba(6, 5, 9, 0.56), rgba(5, 4, 8, 0.74));
  border: 2px solid var(--line-mid);
  box-shadow:
    0 0 0 4px #050408,
    0 0 0 6px #342a3f,
    0 22px 60px rgba(0, 0, 0, 0.72),
    inset 0 0 70px rgba(0, 0, 0, 0.38);
  overflow: hidden;
}

.page-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.12;
  background:
    radial-gradient(circle at 8% 10%, rgba(210, 200, 230, 0.20), transparent 10%),
    radial-gradient(circle at 92% 16%, rgba(160, 130, 200, 0.12), transparent 12%),
    radial-gradient(circle at 20% 86%, rgba(120, 160, 100, 0.10), transparent 14%),
    repeating-linear-gradient(
      -45deg,
      transparent 0px,
      transparent 8px,
      rgba(255, 255, 255, 0.018) 8px,
      rgba(255, 255, 255, 0.018) 9px
    );
}

.top-strip {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 7px 14px;
  background:
    linear-gradient(180deg, rgba(18, 16, 24, 0.88) 0%, rgba(7, 6, 10, 0.90) 100%);
  border-bottom: 2px solid var(--line-mid);
  color: #c7bed2;
  font-family: "IM Fell English", Georgia, serif;
  font-size: 19px;
  font-weight: 400;
  line-height: 1.1;
}

.hero {
  position: relative;
  z-index: 2;
  padding: 34px 20px 22px;
  text-align: center;
  border-bottom: 2px solid var(--line-mid);
  background:
    radial-gradient(circle at 50% 12%, rgba(121, 83, 160, 0.18), transparent 26%),
    linear-gradient(rgba(6, 5, 9, 0.50), rgba(7, 6, 10, 0.76));
}

.hero::before {
  content: "✦   ☾   ✟   ✦   ☽   ✦";
  position: absolute;
  left: 0;
  right: 0;
  top: 10px;
  color: rgba(142, 105, 180, 0.30);
  font-size: 24px;
  letter-spacing: 18px;
  pointer-events: none;
}

.hero::after {
  content: "";
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: 10px;
  height: 1px;
  background:
    linear-gradient(90deg, transparent, rgba(172, 150, 200, 0.35), transparent);
}

.site-title {
  margin: 0;
  font-family: "New Rocker", Georgia, serif;
  font-size: clamp(3.4rem, 8vw, 7rem);
  font-weight: 400;
  line-height: 0.95;
  color: #e9e4ed;
  text-shadow:
    2px 2px 0 #000,
    4px 4px 0 rgba(70, 45, 90, 0.75),
    0 0 18px rgba(160, 120, 210, 0.26);
}

.site-subtitle {
  margin: 18px 0 10px;
  color: var(--green-soft);
  font-family: "IM Fell English", Georgia, serif;
  font-size: 26px;
  font-style: italic;
  font-weight: 400;
  line-height: 1;
  text-shadow: 2px 2px 0 #000;
}

.symbol-row {
  display: flex;
  justify-content: center;
  gap: 18px;
  margin: 10px 0 20px;
  color: var(--purple-soft);
  font-size: 24px;
  opacity: 0.85;
}

.main-nav {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.main-nav a {
  position: relative;
  min-width: 105px;
  padding: 9px 15px 10px;
  color: #dad3e4;
  background:
    linear-gradient(180deg, rgba(42, 35, 51, 0.92) 0%, rgba(21, 18, 27, 0.94) 100%);
  border: 2px solid var(--line-mid);
  box-shadow:
    3px 3px 0 #030306,
    inset 0 1px 0 rgba(255, 255, 255, 0.07),
    inset 0 -3px 0 rgba(0, 0, 0, 0.25);
  font-family: "New Rocker", Georgia, serif;
  font-size: 20px;
  font-weight: 400;
  line-height: 1;
  text-transform: uppercase;
}

.main-nav a::before {
  content: "";
  position: absolute;
  inset: 3px;
  border: 1px solid rgba(255, 255, 255, 0.045);
  pointer-events: none;
}

.main-nav a:hover {
  color: #f1edf5;
  background:
    linear-gradient(180deg, #3a2d48 0%, #1b1722 100%);
  transform: translate(-1px, -1px);
}

.layout {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 270px 1fr;
  gap: 20px;
  padding: 20px;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.widget {
  position: relative;
  padding: 16px;
  background:
    linear-gradient(180deg, rgba(15, 13, 20, 0.88) 0%, rgba(7, 6, 10, 0.92) 100%);
  border: 2px solid var(--line-mid);
  box-shadow:
    5px 5px 0 #030306,
    inset 0 0 30px rgba(0, 0, 0, 0.35);
}

.widget::before {
  content: "";
  position: absolute;
  inset: 4px;
  pointer-events: none;
  border: 1px solid rgba(255, 255, 255, 0.035);
}

.widget::after {
  content: "✶";
  position: absolute;
  right: 10px;
  top: 8px;
  color: rgba(150, 115, 185, 0.42);
  font-size: 20px;
}

.widget h3 {
  margin: 0 0 10px;
  color: var(--purple-soft);
  font-family: "New Rocker", Georgia, serif;
  font-size: 25px;
  font-weight: 400;
  line-height: 1;
  text-shadow: 2px 2px 0 #000;
}

.widget p {
  margin: 0 0 10px;
  color: var(--text);
  font-family: "IM Fell English", Georgia, serif;
  font-size: 20px;
  font-weight: 400;
  line-height: 1.2;
}

.small-line {
  color: var(--green-soft) !important;
}

.souls {
  color: #b4c996 !important;
  font-size: 22px !important;
}

.content {
  min-width: 0;
}

.book-section {
  position: relative;
  padding: 20px;
  background:
    linear-gradient(180deg, rgba(13, 11, 17, 0.88), rgba(5, 4, 8, 0.92));
  border: 2px solid var(--line-mid);
  box-shadow:
    7px 7px 0 #030306,
    inset 0 0 70px rgba(0, 0, 0, 0.45);
  overflow: hidden;
}

.book-section::before {
  content: "";
  position: absolute;
  left: 5%;
  right: 5%;
  top: 62px;
  bottom: 42px;
  pointer-events: none;
  opacity: 0.10;
  background:
    radial-gradient(circle at 22% 22%, rgba(190, 180, 210, 0.32), transparent 8%),
    radial-gradient(circle at 70% 72%, rgba(100, 130, 80, 0.22), transparent 10%),
    repeating-linear-gradient(
      90deg,
      transparent 0px,
      transparent 11px,
      rgba(255, 255, 255, 0.04) 11px,
      rgba(255, 255, 255, 0.04) 12px
    );
}

.section-title {
  position: relative;
  z-index: 2;
  margin: 0 0 20px;
  text-align: center;
  color: #ded3ea;
  font-family: "New Rocker", Georgia, serif;
  font-size: 34px;
  font-weight: 400;
  line-height: 1;
  text-shadow:
    2px 2px 0 #000,
    0 0 12px rgba(117, 81, 155, 0.28);
}

.section-title::before,
.section-title::after {
  content: "✶";
  color: var(--purple);
  padding: 0 12px;
}

.book-stack {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 13px;
  padding: 17px 8px 10px;
  background:
    linear-gradient(180deg, rgba(20, 17, 25, 0.34), rgba(8, 7, 11, 0.12));
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid rgba(0, 0, 0, 0.65);
}

.book {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 78px;
  padding: 13px 25px 14px 36px;
  border: 2px solid rgba(0, 0, 0, 0.55);
  overflow: hidden;
  box-shadow:
    0 8px 0 rgba(0, 0, 0, 0.55),
    inset 0 2px 0 rgba(255, 255, 255, 0.08),
    inset 0 -3px 0 rgba(0, 0, 0, 0.35);
  transition:
    transform 0.16s ease,
    filter 0.16s ease;
}

.book:hover {
  filter: brightness(1.08) contrast(1.04);
}

.book::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 28px;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.52), rgba(255, 255, 255, 0.08)),
    repeating-linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.07) 0px,
      rgba(255, 255, 255, 0.07) 3px,
      transparent 3px,
      transparent 8px
    );
  border-right: 2px solid rgba(0, 0, 0, 0.38);
}

.book::after {
  content: "";
  position: absolute;
  right: 0;
  top: 5px;
  bottom: 5px;
  width: 18px;
  opacity: 0.7;
  background:
    repeating-linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.22) 0px,
      rgba(255, 255, 255, 0.22) 2px,
      rgba(0, 0, 0, 0.12) 2px,
      rgba(0, 0, 0, 0.12) 5px
    );
}

.book-title {
  position: relative;
  z-index: 2;
  max-width: 76%;
  font-family: "New Rocker", Georgia, serif;
  font-size: clamp(1.8rem, 3vw, 3rem);
  font-weight: 400;
  line-height: 1;
  text-shadow:
    2px 2px 0 rgba(0, 0, 0, 0.88),
    0 0 8px rgba(0, 0, 0, 0.45);
}

.book-date {
  position: relative;
  z-index: 2;
  padding-left: 12px;
  font-family: "IM Fell English", Georgia, serif;
  font-size: 22px;
  font-weight: 400;
  line-height: 1;
  opacity: 0.92;
  text-shadow: 2px 2px 0 #000;
}

.book-purple {
  margin-left: 74px;
  transform: rotate(-0.35deg);
  color: #e7daf5;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.08), transparent 16%),
    linear-gradient(180deg, #5f4776 0%, #35243f 100%);
}

.book-purple:hover {
  transform: rotate(-0.35deg) translateX(7px);
}

.book-bone {
  margin-left: 28px;
  transform: rotate(0.22deg);
  color: #191213;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.22), transparent 18%),
    linear-gradient(180deg, #d5cbbd 0%, #a89e92 100%);
}

.book-bone .book-title {
  text-shadow: 1px 1px 0 rgba(255,255,255,0.28);
}

.book-bone .book-date {
  text-shadow: none;
}

.book-bone:hover {
  transform: rotate(0.22deg) translateX(7px);
}

.book-black {
  margin-left: 58px;
  transform: rotate(-0.18deg);
  color: #a9a2b0;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.07), transparent 16%),
    linear-gradient(180deg, #2d2b32 0%, #111117 100%);
}

.book-black:hover {
  transform: rotate(-0.18deg) translateX(7px);
}

.book-green {
  margin-left: 16px;
  transform: rotate(0.16deg);
  color: #d9ca7a;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.09), transparent 18%),
    linear-gradient(180deg, #4d644b 0%, #223220 100%);
}

.book-green:hover {
  transform: rotate(0.16deg) translateX(7px);
}

.book-grey {
  margin-left: 46px;
  transform: rotate(-0.28deg);
  color: #181315;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.13), transparent 16%),
    linear-gradient(180deg, #8b8378 0%, #5e5750 100%);
}

.book-grey .book-title {
  text-shadow: 1px 1px 0 rgba(255,255,255,0.15);
}

.book-grey .book-date {
  text-shadow: none;
}

.book-grey:hover {
  transform: rotate(-0.28deg) translateX(7px);
}

.warning-text {
  position: relative;
  z-index: 2;
  margin: 26px 0 4px;
  text-align: center;
  color: #7d5ca3;
  font-family: "New Rocker", Georgia, serif;
  font-size: 24px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 1px;
  text-shadow: 2px 2px 0 #000;
}

.site-footer {
  position: relative;
  z-index: 2;
  margin-top: 20px;
  text-align: center;
  color: #b6adbf;
  font-family: "IM Fell English", Georgia, serif;
  font-size: 18px;
  line-height: 1.15;
}

.site-footer p {
  margin: 8px 0;
}

.site-footer a {
  color: #a9c58a;
}

.site-footer a:hover {
  color: #d2ecc0;
}

/* PÁGINAS DE POST */

.post-page .layout,
.post-layout {
  display: block;
  padding: 20px;
}

.post-shell {
  max-width: 920px;
  margin: 0 auto;
}

.back-link {
  display: inline-block;
  margin-bottom: 16px;
  padding: 9px 15px;
  color: #ddd7e6;
  background:
    linear-gradient(180deg, #2a2333 0%, #15121b 100%);
  border: 2px solid var(--line-mid);
  box-shadow: 4px 4px 0 #030306;
  font-family: "New Rocker", Georgia, serif;
  font-size: 20px;
  font-weight: 400;
}

.back-link:hover {
  color: #f1edf5;
  transform: translate(-1px, -1px);
}

.post-panel {
  padding: 26px;
  background:
    linear-gradient(180deg, rgba(15, 13, 20, 0.90), rgba(7, 6, 10, 0.94));
  border: 2px solid var(--line-mid);
  box-shadow:
    7px 7px 0 #030306,
    inset 0 0 60px rgba(0, 0, 0, 0.50);
}

.post-panel h1 {
  margin: 0 0 8px;
  color: #e5d9f0;
  font-family: "New Rocker", Georgia, serif;
  font-size: clamp(2.7rem, 5vw, 4.4rem);
  font-weight: 400;
  line-height: 1;
  text-shadow:
    2px 2px 0 #000,
    0 0 13px rgba(117, 81, 155, 0.25);
}

.post-meta {
  margin-bottom: 24px;
  color: var(--green-soft);
  font-family: "IM Fell English", Georgia, serif;
  font-size: 20px;
  font-style: italic;
  font-weight: 400;
}

.post-body p {
  margin: 0 0 16px;
  color: #d7d0dc;
  font-family: "IM Fell English", Georgia, serif;
  font-size: 21px;
  font-weight: 400;
  line-height: 1.45;
}

.post-body blockquote {
  margin: 24px 0;
  padding: 14px 16px;
  color: #d2c4e2;
  background: rgba(255, 255, 255, 0.035);
  border-left: 4px solid var(--purple);
  font-family: "IM Fell English", Georgia, serif;
  font-size: 22px;
  font-style: italic;
  font-weight: 400;
  line-height: 1.35;
}

/* MÓVIL */

@media (max-width: 900px) {
  .page-frame {
    margin: 0;
    border-left: 0;
    border-right: 0;
  }

  .layout {
    grid-template-columns: 1fr;
    padding: 14px;
  }

  .top-strip {
    justify-content: center;
    text-align: center;
  }

  .hero {
    padding-top: 30px;
  }

  .site-title {
    font-size: clamp(3rem, 16vw, 5.5rem);
  }

  .main-nav a {
    min-width: auto;
  }

  .book,
  .book-purple,
  .book-bone,
  .book-black,
  .book-green,
  .book-grey {
    margin-left: 0;
    transform: none;
  }

  .book:hover,
  .book-purple:hover,
  .book-bone:hover,
  .book-black:hover,
  .book-green:hover,
  .book-grey:hover {
    transform: translateX(4px);
  }

  .book {
    min-height: 86px;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
    padding-right: 35px;
  }

  .book-title {
    max-width: 100%;
  }

  .book-date {
    padding-left: 0;
  }
}