.comic-reader-container,
.comic-reader-fullwidth {
  width: 100%;
  margin: 16px 0 32px 0;
  background: #0a0a0a;
  position: relative;
  box-sizing: border-box;
}

#reader {
  width: 100%;
  height: 85vh;
  min-height: 600px;
  background: #111;
  color: #fff;
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: var(--bb-border, 1.5px solid #111);
  font-family: var(--font-body, monospace, sans-serif);
  box-sizing: border-box;
}

#reader:fullscreen,
#reader:-webkit-full-screen {
  width: 100vw;
  height: 100vh;
  border: none;
}

#reader-stage {
  flex-grow: 1;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: inherit;
}

#reader-ui {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 12px 18px;
  background: linear-gradient(transparent, rgba(0,0,0,0.85));
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: opacity 0.3s;
  z-index: 100;
}

.ui-hidden #reader-ui {
  opacity: 0;
  pointer-events: none;
}

#reader button {
  background: rgba(255,255,255,0.1);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.25);
  padding: 6px 12px;
  cursor: pointer;
  border-radius: 2px;
  font-weight: bold;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  font-family: inherit;
  transition: all 0.15s ease;
}

#reader button:hover {
  background: #fff;
  color: #000;
  border-color: #fff;
}

#reader button.is-active {
  background: var(--red, #c8102e);
  color: #fff;
  border-color: var(--red, #c8102e);
}

.ui-left, .ui-right {
  display: flex;
  gap: 8px;
  align-items: center;
}

.ui-center {
  display: flex;
  align-items: center;
  gap: 15px;
}

#progress {
  font-family: monospace;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  color: #fff;
}

#reader-thumbnails {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(10, 10, 10, 0.95);
  z-index: 150;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 12px;
  padding: 24px;
  overflow-y: auto;
}

#reader-thumbnails.hidden {
  display: none;
}

.thumb-item {
  cursor: pointer;
  border: 2px solid #333;
  transition: 0.2s;
  background: #000;
  padding: 4px;
  text-align: center;
}

.thumb-item:hover, .thumb-item.is-current {
  border-color: var(--red, #c8102e);
}

.thumb-item img {
  width: 100%;
  height: auto;
  display: block;
}

.thumb-item .thumb-label {
  font-size: 0.65rem;
  color: #aaa;
  margin-top: 4px;
  font-family: monospace;
}