/* The Ledger — the story screen. A page, not a dashboard: one column,
   generous leading, and blank ruled lines where a page is unwritten. */

.screen--ledger {
  overflow-y: auto;
  justify-content: flex-start; /* the centred-overflow trap again */
  padding: calc(20px + env(safe-area-inset-top, 0px)) 16px
           calc(24px + env(safe-area-inset-bottom, 0px));
}

.ledger {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.ledger__head h2 {
  font-family: var(--font-display, 'Cinzel', serif);
  font-size: 1.6rem;
  color: var(--c-text-bright);
  letter-spacing: 0.06em;
}

.ledger__sub {
  margin-top: 4px;
  color: var(--c-text-dim);
  font-size: 0.85rem;
}

.ledger__count {
  color: var(--c-text-dim);
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
}

.ledger__body {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.ledger__chapter {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.ledger__chapter-title {
  font-family: var(--font-display, 'Cinzel', serif);
  font-size: 0.82rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--c-text-dim);
  border-bottom: 1px solid var(--c-border);
  padding-bottom: 6px;
}

.ledger__entry {
  padding: 12px 14px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-left: 2px solid var(--c-border);
  border-radius: 8px;
}

.ledger__entry-title {
  font-family: var(--font-display, 'Cinzel', serif);
  font-size: 0.98rem;
  color: var(--c-text-bright);
  margin-bottom: 5px;
}

.ledger__entry-text {
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--c-text);
}

/* Unwritten: the ruling is there, the sentence is not. */
.ledger__entry--blank {
  display: flex;
  flex-direction: column;
  gap: 9px;
  padding: 16px 14px;
  background: none;
  border-color: transparent;
  border-left-color: var(--c-border);
}

.ledger__entry--blank span {
  height: 1px;
  background: var(--c-border);
  opacity: 0.7;
}

.ledger__entry--blank span:nth-child(1) { width: 42%; }
.ledger__entry--blank span:nth-child(2) { width: 88%; }
.ledger__entry--blank span:nth-child(3) { width: 66%; }

/* The spine reads as the important thing it is. */
.ledger__chapter--acts .ledger__entry--act {
  border-left-color: var(--c-gold-dim);
  box-shadow: inset 0 0 26px rgba(0, 0, 0, 0.35);
}

.ledger__chapter--acts .ledger__entry-title {
  color: var(--c-gold);
}

/* A run left something unread. */
.btn--marked::after {
  content: '';
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: 8px;
  border-radius: 50%;
  background: var(--c-gold);
  box-shadow: 0 0 8px var(--c-gold);
  vertical-align: middle;
}
