:root {
  --bg-top: #fcf8f3;
  --bg-bottom: #f4ede4;
  --panel: #f8f2ea;
  --title: #5b4037;
  --text: #6a544a;
  --wood: #8a5a43;
  --wood-dark: #6f4634;
  --wood-shadow: rgba(71, 42, 29, 0.22);
  --metal: #534741;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body.library-page {
  min-height: 100vh;
  font-family: "Segoe UI", Arial, sans-serif;
  background:
    radial-gradient(circle at top, #fffdf9 0%, transparent 35%),
    linear-gradient(to bottom, var(--bg-top), var(--bg-bottom));
  color: var(--text);
}

.library-header {
  text-align: center;
  padding: 14px 12px 4px;
}

.library-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.75);
  color: var(--title);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
}

.badge-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #e8a2ad;
  display: inline-block;
}

.library-header h1 {
  margin: 0;
  font-size: clamp(1.4rem, 3vw, 2rem);
  color: var(--title);
  font-weight: 700;
}

.library-header p {
  margin: 0;
  font-size: 1rem;
  color: #7a655b;
}

.library-scene {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 24px 14px 40px;
}

.bookshelf {
  position: relative;
  width: min(900px, 100%);
  background: linear-gradient(to bottom, #fbf6f0, var(--panel));
  border-radius: 22px;
  padding: 24px 20px 20px;

.bookshelf::before,
.bookshelf::after {
  content: "";
  position: absolute;
  top: 18px;
  bottom: 18px;
  width: 14px;
  border-radius: 10px;
  background: linear-gradient(to bottom, #5d4f48, #453933);
  opacity: 0.95;
}

.bookshelf::before {
  left: 12px;
}

.bookshelf::after {
  right: 12px;
}

.shelf-row {
  position: relative;
  min-height: 220px;
  display: flex;
  align-items: flex-end;
  gap: 10px;
  padding: 8px 16px 12px;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  scrollbar-color: #ccb7a6 transparent;
}

.shelf-row::-webkit-scrollbar {
  height: 8px;
}

.shelf-row::-webkit-scrollbar-thumb {
  background: #ccb7a6;
  border-radius: 999px;
}

.shelf-plank {
  height: 16px;
  border-radius: 10px;
  background: linear-gradient(to bottom, #9b6a50, var(--wood));
  box-shadow:
    0 6px 0 var(--wood-dark),
    0 10px 18px var(--wood-shadow);
  margin: 0 10px 22px;
}

.shelf-plank {
  position: relative;
  height: 16px;
  border-radius: 10px;
  background: linear-gradient(to bottom, #a67458, var(--wood));
  box-shadow:
    0 6px 0 var(--wood-dark),
    0 10px 18px var(--wood-shadow);
  margin: 0 10px 22px;
}

.shelf-plank::before {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  top: 3px;
  height: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
}

.shelf-plank::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  top: 16px;
  height: 10px;
  border-radius: 0 0 10px 10px;
  background: linear-gradient(to bottom, rgba(88, 54, 39, 0.28), rgba(88, 54, 39, 0.08));
  filter: blur(2px);
}

.second-row {
  margin-top: 8px;
}

.book-spine {
  flex: 0 0 auto;
  width: 72px;
  height: 190px;
  border: none;
  border-radius: 8px 8px 4px 4px;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  padding: 12px 8px 10px;
  position: relative;
  box-shadow:
    inset -7px 0 10px rgba(0, 0, 0, 0.10),
    inset 2px 0 1px rgba(255, 255, 255, 0.22),
    0 4px 10px rgba(0, 0, 0, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
  cursor: pointer;
}

a.book-spine:hover,
a.book-spine:focus-visible {
  transform: translateY(-8px);
  box-shadow:
    inset -7px 0 10px rgba(0, 0, 0, 0.10),
    0 12px 18px rgba(0, 0, 0, 0.12);
  outline: none;
}

.empty-book {
  cursor: default;
}

.empty-book:hover {
  transform: none;
}

.series-name,
.issue-name,
.issue-sub,
.coming {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  user-select: none;
}

.series-name {
  font-size: 0.62rem;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.90);
  font-weight: 700;
}

.issue-name {
  font-size: 1rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: 1px;
}

.issue-sub {
  font-size: 0.8rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.92);
}

.coming {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.92);
  margin: auto;
}

.coming.dark {
  color: #5c463c;
}

/* kitap çeşitleri */
.short-book {
  height: 160px;
}

.thin-book {
  width: 54px;
}

.tilt-left {
  transform: rotate(-9deg);
  transform-origin: bottom right;
  margin-left: 6px;
  margin-right: 12px;
}

.tilt-right {
  transform: rotate(8deg);
  transform-origin: bottom left;
  margin-left: 8px;
}

/* renkler */
.spine-blue {
  background: linear-gradient(to right, #88b9df, #6d9dc5);
}

.spine-pink {
  background: linear-gradient(to right, #df9fad, #c88293);
}

.spine-green {
  background: linear-gradient(to right, #9dc9ac, #78aa8b);
}

.spine-lilac {
  background: linear-gradient(to right, #c3b0de, #9e88c2);
}

.spine-yellow {
  background: linear-gradient(to right, #ead07c, #d7b957);
}

.spine-mint {
  background: linear-gradient(to right, #b5ddd2, #8cc7ba);
}

.spine-peach {
  background: linear-gradient(to right, #efc5a6, #dfa77e);
}

.spine-cream {
  background: linear-gradient(to right, #f2e8da, #e6d7c2);
}

/* tablet */
@media (max-width: 768px) {
  .library-header {
    padding-top: 18px;
  }

  .bookshelf {
    border-radius: 18px;
    padding: 26px 18px 22px;
  }

  .bookshelf::before,
  .bookshelf::after {
    width: 10px;
  }

  .shelf-row {
    min-height: 190px;
    gap: 8px;
    padding: 8px 10px 10px;
  }

  .book-spine {
    width: 60px;
    height: 165px;
    padding: 10px 6px 8px;
  }

  .short-book {
    height: 138px;
  }

  .thin-book {
    width: 46px;
  }

  .issue-name {
    font-size: 0.86rem;
  }

 .issue-sub{
  font-size: .78rem;
  color:#ffffffee;
  font-weight:600;
}

  .series-name{
  font-size:.60rem;
  font-weight:700;
  color:#ffffffcc;
  letter-spacing:1px;
}
}

.series-name,
.issue-name,
.issue-sub{
  text-shadow:
    0 1px 2px rgba(0,0,0,0.35);
}

.book-spine:hover .issue-name{
  text-shadow:
    0 0 6px rgba(255,255,255,0.6),
    0 1px 3px rgba(0,0,0,0.35);
}
/* telefon */
@media (max-width: 480px) {
  .library-header h1 {
    font-size: 1.7rem;
  }

  .library-header p {
    font-size: 0.92rem;
    padding: 0 8px;
  }

  .library-scene {
    padding: 18px 10px 28px;
  }

  .bookshelf {
    padding: 22px 14px 18px;
    border-radius: 16px;
  }

  .bookshelf::before,
  .bookshelf::after {
    width: 8px;
    top: 14px;
    bottom: 14px;
  }

  .bookshelf::before {
    left: 8px;
  }

  .bookshelf::after {
    right: 8px;
  }

  .shelf-row {
    min-height: 170px;
    gap: 7px;
    padding: 6px 8px 8px;
  }

  .book-spine {
    width: 52px;
    height: 145px;
    border-radius: 7px 7px 4px 4px;
  }

  .short-book {
    height: 120px;
  }

  .thin-book {
    width: 40px;
  }

  .shelf-plank {
    height: 14px;
    margin: 0 4px 18px;
  }

.issue-name{
  font-size: .95rem;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: 1px;
}



  .series-name {
    font-size: 0.48rem;
  }
}

.floor-plant {
  position: absolute;
  right: 18px;
  bottom: 18px;
  width: 150px;
  height: 220px;
  pointer-events: none;
  z-index: 1;
}

.pot {
  position: absolute;
  bottom: 0;
  left: 42px;
  width: 68px;
  height: 78px;
  background: linear-gradient(to bottom, #c98f6b, #a76f4f);
  border-radius: 10px 10px 18px 18px;
  box-shadow:
    inset 0 4px 0 rgba(255,255,255,0.18),
    0 8px 12px rgba(0,0,0,0.12);
}

.pot::before {
  content: "";
  position: absolute;
  top: -10px;
  left: -6px;
  width: 80px;
  height: 16px;
  background: linear-gradient(to bottom, #d7a17d, #b47a58);
  border-radius: 10px;
}

.pot-shadow {
  position: absolute;
  bottom: -6px;
  left: 30px;
  width: 96px;
  height: 22px;
  background: rgba(0, 0, 0, 0.10);
  border-radius: 50%;
  filter: blur(4px);
}

.leaf {
  position: absolute;
  bottom: 58px;
  left: 50%;
  transform-origin: bottom center;
  border-radius: 80% 20% 70% 20%;
  background: linear-gradient(to bottom, #88b895, #5f8f6e);
  box-shadow: inset -2px 0 2px rgba(0,0,0,0.08);
}

.leaf::after {
  content: "";
  position: absolute;
  left: 48%;
  top: 8%;
  width: 2px;
  height: 82%;
  background: rgba(255,255,255,0.18);
  border-radius: 999px;
}

.leaf-1 {
  width: 28px;
  height: 92px;
  margin-left: -10px;
  transform: rotate(-34deg);
}

.leaf-2 {
  width: 30px;
  height: 110px;
  margin-left: 8px;
  transform: rotate(28deg);
}

.leaf-3 {
  width: 24px;
  height: 88px;
  margin-left: -38px;
  transform: rotate(-56deg);
}

.leaf-4 {
  width: 24px;
  height: 84px;
  margin-left: 28px;
  transform: rotate(50deg);
}

.leaf-5 {
  width: 26px;
  height: 98px;
  margin-left: -2px;
  transform: rotate(-8deg);
}

.leaf-6 {
  width: 22px;
  height: 72px;
  margin-left: 40px;
  transform: rotate(66deg);
}

.floor-plant {
  right: 8px;
  bottom: 10px;
  width: 105px;
  height: 160px;
}

.pot {
  left: 30px;
  width: 48px;
  height: 58px;
}

.pot::before {
  width: 58px;
  left: -5px;
  height: 12px;
}

.pot-shadow {
  left: 22px;
  width: 68px;
  height: 16px;
}

.leaf-1 { width: 20px; height: 66px; }
.leaf-2 { width: 22px; height: 78px; }
.leaf-3 { width: 18px; height: 62px; }
.leaf-4 { width: 18px; height: 60px; }
.leaf-5 { width: 20px; height: 70px; }
.leaf-6 { width: 16px; height: 52px; }

.shelf-row {
  position: relative;
  z-index: 2;
}

.second-row {
  padding-right: 150px;
}

.book-spine {
  transform-origin: bottom center;
  transition: transform .25s ease, box-shadow .25s ease;
}

.book-spine:hover {
  transform: translateY(-6px) rotateY(-8deg);
  box-shadow:
    -6px 8px 14px rgba(0,0,0,0.15),
    inset -6px 0 8px rgba(0,0,0,0.1);
}

.book-spine::after{
  content:"";
  position:absolute;
  top:4px;
  bottom:4px;
  right:4px;
  width:3px;
  border-radius:2px;
  background:rgba(255,255,255,0.25);
  opacity:.6;
}

.book-spine::before{
  content:"";
  position:absolute;
  bottom:-6px;
  left:10%;
  width:80%;
  height:8px;
  background:rgba(0,0,0,0.15);
  border-radius:50%;
  filter:blur(3px);
  opacity:.6;
}
.book-spine:hover::before{
  opacity:.8;
  height:10px;
}

@keyframes bookAppear {
  0% {
    transform: translateY(20px);
    opacity: 0;
  }

  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

.book-spine{
  animation: bookAppear .8s ease forwards;
}

.book-spine:nth-child(1){ animation-delay: .1s; }
.book-spine:nth-child(2){ animation-delay: .2s; }
.book-spine:nth-child(3){ animation-delay: .3s; }
.book-spine:nth-child(4){ animation-delay: .4s; }
.book-spine:nth-child(5){ animation-delay: .5s; }
.book-spine:nth-child(6){ animation-delay: .6s; }
.book-spine:nth-child(7){ animation-delay: .7s; }

@keyframes leafSway {
  0%   { transform: rotate(-2deg); }
  50%  { transform: rotate(2deg); }
  100% { transform: rotate(-2deg); }
}

.leaf{
  animation: leafSway 6s ease-in-out infinite;
  transform-origin: bottom center;
}

.leaf-1 { animation-delay: 0s; }
.leaf-2 { animation-delay: 1s; }
.leaf-3 { animation-delay: 2s; }
.leaf-4 { animation-delay: 1.5s; }
.leaf-5 { animation-delay: 0.5s; }
.leaf-6 { animation-delay: 2.5s; }

}