@charset "UTF-8";
/* ==========================================================================
   دار النشر — مكتبة النشر — page-press.css
   No titles, authors or dates are verified. This is a working catalogue
   shell — search, category filter and a grid/list toggle all function —
   populated with an honest empty state, built so real records drop in.
   ========================================================================== */

/* ---------- breadcrumb ---------- */
.crumb {
  display: flex; align-items: center; gap: var(--s2);
  font-family: var(--ar-body); font-size: 13.5px; letter-spacing: normal;
  color: var(--muted); margin-bottom: var(--s4);
}
.crumb a { color: var(--muted); transition: color .25s var(--ease); }
.crumb a:hover { color: var(--gold-ink); }
:root[data-theme="dark"] .crumb a:hover { color: var(--gold); }
.crumb [aria-current] { color: var(--ink-2); }
.crumb-sep { color: var(--line-2); }

/* ---------- compact page hero ----------
   A single bell tower, faint, centred behind the standfirst — a quiet nod
   to a library reading room rather than the homepage skyline. */
.phhero {
  position: relative; overflow: hidden; isolation: isolate;
  padding: 168px var(--s5) var(--s7);
  background: var(--hero-sky);
  border-bottom: 1px solid var(--line);
  text-align: center;
}
.phhero-bg { position: absolute; inset: 0; z-index: -1; display: grid; place-items: end center; }
.phhero-tow { width: 100%; height: 82%; fill: var(--tower); opacity: .5; }
.phhero-in { max-width: 720px; margin-inline: auto; }
.phhero .crumb { justify-content: center; }
.phhero h1 {
  font-family: var(--ar-display); font-weight: 400;
  font-size: clamp(30px, 5vw, 48px); line-height: 1.45; letter-spacing: normal;
}
.phhero-x {
  font-size: 17px; line-height: 1.8; color: var(--ink-2); max-width: 60ch;
  margin: var(--s3) auto 0;
}

/* ---------- catalogue toolbar (search + filter + view) ---------- */
.pr-tools {
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--s4);
  margin-top: var(--s7); padding-bottom: var(--s5); border-bottom: 1px solid var(--line);
}

.pr-search {
  display: flex; align-items: center; gap: var(--s2);
  flex: 1 1 260px; min-width: 0;
  padding: 11px var(--s4); border-radius: 999px;
  border: 1px solid var(--line-2); background: var(--surface);
  transition: border-color .25s var(--ease);
}
.pr-search:focus-within { border-color: var(--navy); }
:root[data-theme="dark"] .pr-search:focus-within { border-color: var(--gold); }
.pr-search svg { width: 17px; height: 17px; color: var(--muted); flex: none; }
.pr-search input {
  border: 0; background: none; outline: none; width: 100%; min-width: 0;
  font-family: var(--ar-body); font-size: 15px; letter-spacing: normal; color: var(--ink);
}
.pr-search input::placeholder { color: var(--muted); }

.pr-cats { display: flex; flex-wrap: wrap; gap: var(--s2); }
.pr-chip {
  font-family: var(--ar-body); font-size: 13.5px; font-weight: 500; letter-spacing: normal;
  padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line-2);
  color: var(--ink-2); background: var(--surface); white-space: nowrap;
  transition: background-color .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease);
}
.pr-chip:hover { border-color: var(--navy); color: var(--ink); }
:root[data-theme="dark"] .pr-chip:hover { border-color: var(--gold); }
.pr-chip.is-on { background: var(--navy); border-color: var(--navy); color: #fff; }
:root[data-theme="dark"] .pr-chip.is-on { background: var(--gold); border-color: var(--gold); color: #12203B; }

.pr-view { display: flex; gap: 2px; padding: 3px; border: 1px solid var(--line-2); border-radius: 999px; flex: none; }
.pr-vbtn {
  width: 34px; height: 34px; border-radius: 999px; display: grid; place-items: center;
  color: var(--muted); transition: background-color .25s var(--ease), color .25s var(--ease);
}
.pr-vbtn svg { width: 17px; height: 17px; }
.pr-vbtn:hover { color: var(--ink); }
.pr-vbtn.is-on { background: var(--bg-2); color: var(--navy); }
:root[data-theme="dark"] .pr-vbtn.is-on { color: var(--gold); }

.pr-count {
  margin-top: var(--s4); font-size: 13.5px; color: var(--muted);
  font-variant-numeric: tabular-nums; letter-spacing: normal;
}

/* ---------- results grid (empty today; ready for real cards) ---------- */
.pr-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--s4); margin-top: var(--s5);
}
.pr-grid:empty { display: none; }
.pr-grid.is-list { grid-template-columns: 1fr; }

/* the shape a real card takes once records exist — kept here so records
   drop straight in without further styling work */
.pr-card {
  padding: var(--s4); background: var(--surface); border: 1px solid var(--line);
  border-radius: 14px; display: flex; flex-direction: column; gap: var(--s2);
}
.pr-card .pr-cover {
  aspect-ratio: 3 / 4; border-radius: 8px; background: var(--bg-2);
  display: grid; place-items: center; margin-bottom: var(--s2);
}
.pr-card .pr-cover svg { width: 30%; height: 30%; fill: var(--line-2); }
.pr-card h3 { font-family: var(--ar-display); font-weight: 400; font-size: 17px; letter-spacing: normal; }
.pr-card p { font-size: 13px; color: var(--muted); }
.pr-grid.is-list .pr-card { flex-direction: row; align-items: center; }
.pr-grid.is-list .pr-card .pr-cover { width: 56px; aspect-ratio: 1; margin-bottom: 0; }

/* ---------- empty state ---------- */
.pr-empty {
  text-align: center; max-width: 560px; margin: var(--s6) auto 0;
  padding: var(--s7) var(--s5);
  background: var(--surface); border: 1px solid var(--line); border-radius: 18px;
}
.pr-empty-ico { width: 36px; height: 47px; fill: var(--line-2); margin: 0 auto var(--s4); }
.pr-empty h3 { font-family: var(--ar-display); font-weight: 400; font-size: 22px; margin-bottom: var(--s3); }
.pr-empty p { font-size: 15px; color: var(--ink-2); line-height: 1.75; margin-bottom: var(--s5); max-width: 48ch; margin-inline: auto; }

/* ---------- scope figure: single ghost book card ---------- */
.pr-preview {
  margin: 0; position: relative; max-width: 220px; justify-self: end;
  padding: var(--s5); border-radius: 16px;
  border: 1.5px dashed var(--line-2);
  background: repeating-linear-gradient(135deg, var(--bg-2) 0 12px, var(--surface) 12px 24px);
  display: flex; flex-direction: column; align-items: center; gap: var(--s3);
}
.pr-preview-tag {
  position: absolute; top: var(--s3); right: var(--s3); left: var(--s3);
  font-size: 10.5px; font-weight: 600; letter-spacing: normal; text-align: center;
  color: var(--gold-ink); background: var(--surface); border: 1px solid var(--line-2);
  border-radius: 999px; padding: 3px 8px;
}
:root[data-theme="dark"] .pr-preview-tag { color: var(--gold); }
.pr-preview-cover {
  width: 100%; aspect-ratio: 3/4; border-radius: 10px; background: var(--line-2);
  opacity: .6; display: grid; place-items: center; margin-top: var(--s6);
}
.pr-preview-cover svg { width: 34%; height: 34%; fill: var(--surface); }
.pr-preview-bar { display: block; height: 9px; border-radius: 5px; background: var(--line-2); opacity: .8; width: 100%; }
.pr-preview-bar-l { width: 82%; }
.pr-preview-bar-s { width: 50%; }
.pr-preview-pill {
  font-size: 11px; letter-spacing: normal; color: var(--muted);
  border: 1px solid var(--line-2); border-radius: 999px; padding: 3px 12px;
}

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .phhero { padding-top: 140px; }
  .two { grid-template-columns: 1fr; }
  .pr-preview { justify-self: center; }
}
@media (max-width: 620px) {
  .phhero { padding: 128px var(--s4) var(--s6); }
  .pr-tools { flex-direction: column; align-items: stretch; }
  .pr-view { align-self: flex-start; }
  .pr-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 420px) {
  .pr-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .pr-chip, .pr-vbtn, .pr-search { transition: none; }
}
