/* ============================================================
   bookshelf.css
   a little library, lovingly maintained
   ============================================================ */

/* ---------- Google Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=IM+Fell+English:ital@0;1&family=Crimson+Text:ital,wght@0,400;0,600;1,400&display=swap');

/* ---------- Root Tokens ---------- */
:root {
  --ink:        #343c64;
  --ink-light:  #5a6490;
  --gold:       #FCB033;
  --gold-pale:  #FFD89B;
  --cream:      rgba(255, 255, 255, 0.92);
  --glass:      rgba(255, 255, 255, 0.42);
  --glass-hover:rgba(255, 255, 255, 0.62);
  --border:     2px double white;
  --shadow:     2px 4px 18px rgba(52, 60, 100, 0.13);
  --radius:     2px; /* keep it boxy & academic */
}

body {
background-image: linear-gradient(
#FCB033, 
#FFD89B, 
#FFFFFF), url("https://bellelaviemedspa.com/wp-content/uploads/2016/12/132341-Gif-Stars-Purple-Sparkles-Yes-Sparkle-Png-Transparent-Transparency-....gif");
background-size: cover;
background-position: center;
background-attachment: fixed;
margin: 0;
height: 100vh;
color: 
#343c64;
column-rule: 2px double white;
font-family: monospace;
font-size: 20px;
}

/* ============================================================
   PAGE LAYOUT
   ============================================================ */

.bookshelf-page {
  font-family: 'Crimson Text', 'Georgia', serif;
  font-size: 1.1rem;
  color: var(--ink);
  line-height: 1.7;
}

/* main wrapper — mirrors .box */
.bookshelf-wrapper {
  margin: 50px 150px;
  padding: 40px 50px;
  border: var(--border);
  background: var(--glass);
  box-shadow: var(--shadow);
}

/* page heading */
.bookshelf-wrapper h1 {
  font-family: 'IM Fell English', 'clouds', cursive;
  font-style: italic;
  font-size: 2.6rem;
  text-align: center;
  color: white;
  text-shadow: 1px 2px 8px rgba(52,60,100,0.25);
  letter-spacing: 0.04em;
  margin-bottom: 0.2em;
}

/* little decorative flourish under h1 */
.bookshelf-wrapper h1::after {
  content: "✦  ✦  ✦";
  display: block;
  font-size: 0.85rem;
  color: var(--gold-pale);
  letter-spacing: 0.5em;
  margin-top: 0.3em;
  font-style: normal;
}

/* section headings (genre names) */
.bookshelf-wrapper h2 {
  font-family: 'IM Fell English', 'clouds', monospace;
  font-size: 1.45rem;
  font-style: italic;
  color: var(--ink);
  border-bottom: 1px dashed var(--gold);
  padding-bottom: 0.25em;
  margin: 2em 0 0.75em;
  letter-spacing: 0.02em;
}

/* small epigraph / intro blurb beneath h1 */
.shelf-intro {
  font-style: italic;
  text-align: center;
  color: var(--ink-light);
  font-size: 0.95rem;
  margin-bottom: 2.5em;
}

/* ============================================================
   GENRE SECTION
   ============================================================ */

.genre-section {
  margin-bottom: 2.5em;
}

/* ============================================================
   BOOK LIST
   ============================================================ */

.book-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5em;
}

.book-item {
  display: flex;
  align-items: baseline;
  gap: 0.6em;
  padding: 0.45em 0.75em;
  border-radius: var(--radius);
  background: transparent;
  transition: background 0.2s ease, transform 0.15s ease;
  position: relative;
}

.book-item:hover {
  background: var(--glass-hover);
  transform: translateX(4px);
  cursor: default;
}

/* spine-tab accent on hover */
.book-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--gold);
  border-radius: 2px 0 0 2px;
  opacity: 0;
  transition: opacity 0.2s ease;
}
.book-item:hover::before {
  opacity: 1;
}

/* book icon — a tiny open book */
.book-icon {
  font-size: 1.1em;
  flex-shrink: 0;
  user-select: none;
}

/* title */
.book-title {
  font-family: 'Crimson Text', Georgia, serif;
  font-weight: 600;
  color: var(--ink);
}

/* author — italicised, lighter */
.book-author {
  font-family: 'Crimson Text', Georgia, serif;
  font-style: italic;
  color: var(--ink-light);
  font-size: 0.95em;
}
.book-author::before { content: "— "; }

/* optional year tag */
.book-year {
  font-family: monospace;
  font-size: 0.78em;
  color: var(--gold);
  margin-left: auto;
  flex-shrink: 0;
  opacity: 0.85;
}

/* optional short note / annotation */
.book-note {
  display: block;
  font-style: italic;
  font-size: 0.82em;
  color: var(--ink-light);
  margin-left: 1.9em; /* aligns under title, past the icon */
  margin-top: 0.1em;
}

/* ============================================================
   TO-READ LIST
   ============================================================ */

.to-read-section {
  margin-top: 3em;
  padding-top: 1.5em;
  border-top: var(--border);
}

.to-read-section h2 {
  font-size: 1.6rem;
}

/* to-read items share .book-list / .book-item but get their own icon logic */

/* status icon — changes based on read state */
.read-status {
  font-size: 1.15em;
  flex-shrink: 0;
  user-select: none;
  transition: transform 0.25s ease;
}

/* unread: hollow bookmark */
.book-item.unread   .read-status::before { content: "🔖"; }

/* currently reading: magnifying glass */
.book-item.reading  .read-status::before { content: "🔍"; }

/* finished: star */
.book-item.finished .read-status::before { content: "⭐"; }

/* abandoned: fallen leaf — because sometimes that happens */
.book-item.abandoned .read-status::before { content: "🍂"; }

/* pulse on currently-reading */
.book-item.reading .read-status {
  animation: reading-pulse 2.2s ease-in-out infinite;
}
@keyframes reading-pulse {
  0%, 100% { transform: scale(1);   opacity: 1;   }
  50%       { transform: scale(1.2); opacity: 0.7; }
}

/* status labels — tiny pill badges */
.status-label {
  font-family: monospace;
  font-size: 0.7em;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.15em 0.55em;
  border-radius: 20px;
  border: 1px solid currentColor;
  margin-left: 0.5em;
  flex-shrink: 0;
  align-self: center;
}

.book-item.unread    .status-label { color: var(--ink-light); border-color: var(--ink-light); }
.book-item.reading   .status-label { color: var(--gold);      border-color: var(--gold); background: rgba(252,176,51,0.12); }
.book-item.finished  .status-label { color: #6b8f5e;          border-color: #6b8f5e;     background: rgba(107,143,94,0.1); }
.book-item.abandoned .status-label { color: #b07c50;          border-color: #b07c50;     background: rgba(176,124,80,0.1); }

/* ============================================================
   DIVIDERS & ORNAMENTS
   ============================================================ */

.shelf-divider {
  text-align: center;
  color: var(--gold-pale);
  font-size: 1.1rem;
  letter-spacing: 0.7em;
  margin: 2em 0;
  user-select: none;
}
.shelf-divider::before { content: "❧ "; }
.shelf-divider::after  { content: " ❧"; }

/* little marginal annotation style */
.marginalia {
  font-family: monospace;
  font-size: 0.75rem;
  color: var(--ink-light);
  font-style: italic;
  display: inline-block;
  border-left: 2px solid var(--gold-pale);
  padding-left: 0.6em;
  margin: 0.5em 0 0.5em 2em;
  opacity: 0.8;
}

/* ============================================================
   RETURN LINK  (mirrors .return from main css)
   ============================================================ */

.return-shelf {
  flex: 1;
  margin: 30px auto;
  padding: 10px;
  border: var(--border);
  color: var(--ink);
  background: var(--glass);
  text-align: center;
  width: fit-content;
  min-width: 14em;
  font-family: monospace;
  transition: background 0.2s;
}
.return-shelf:hover { background: var(--glass-hover); }
.return-shelf a {
  font-family: 'IM Fell English', monospace;
  font-style: italic;
  color: var(--ink);
  text-decoration: none;
}
.return-shelf a:hover { text-decoration: underline dotted; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 900px) {
  .bookshelf-wrapper {
    margin: 30px 30px;
    padding: 24px 20px;
  }
}

@media (max-width: 600px) {
  .bookshelf-wrapper {
    margin: 16px 10px;
    padding: 18px 14px;
  }
  .bookshelf-wrapper h1 { font-size: 1.9rem; }
  .book-year { display: none; }
}