@font-face {
  font-display: swap;
  font-family: Manrope;
  src: url("assets/Manrope-Regular.woff2") format("woff2");
}

@font-face {
  font-display: swap;
  font-family: Manrope;
  src: url("assets/Manrope-SemiBold.woff2") format("woff2");
  font-weight: 600;
}

@font-face {
  font-display: swap;
  font-family: Cormorant;
  src: url("assets/CormorantGaramond-SemiBold.woff2") format("woff2");
  font-weight: 600;
}

@font-face {
  font-display: swap;
  font-family: Lora;
  src: url("assets/Lora-Regular.woff2") format("woff2");
}

:root {
  color-scheme: dark;
  --bg: #0b0b16;
  --panel: #141421;
  --line: #ffffff14;
  --muted: #a5a2b8;
  --text: #f4f0fa;
  --purple: #b299ff;
  --accent: #8e63ed;
  --mint: #a6d7cb;
  --serif: Cormorant,Georgia,serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.65 Manrope,system-ui,sans-serif;
}

button,
input,
select {
  font: inherit;
}

button,
a,
input,
select {
  -webkit-tap-highlight-color: transparent;
}

button,
a {
  touch-action: manipulation;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  cursor: pointer;
  color: inherit;
}

button:disabled {
  opacity: .5;
  cursor: wait;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 2px solid #c8b4ff;
  outline-offset: 5px;
}

button {
  background: none;
  border: 0;
}

img {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1,
h2,
.serif {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.08;
}

h1 {
  font-size: clamp(44px,5vw,74px);
}

h2 {
  font-size: 36px;
}

h3 {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.45;
}

.wrap {
  width: min(1240px,calc(100% - 80px));
  margin: auto;
}

.skip {
  position: fixed;
  left: 16px;
  top: -80px;
  background: var(--accent);
  padding: 12px;
  z-index: 100;
}

.skip:focus {
  top: 10px;
}

.icon {
  width: 20px;
  height: 20px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.muted {
  color: var(--muted);
}

.eyebrow {
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--purple);
  font-weight: 600;
}

.btn {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  padding: 12px 20px;
  background: #ffffff08;
  border: 1px solid var(--line);
  font-weight: 600;
  white-space: nowrap;
  transition: background .2s,transform .2s;
}

.btn:hover {
  background: #ffffff12;
}

.btn.primary {
  background: #9970ed;
  color: white;
  border-color: #b891ff55;
  box-shadow: 0 6px 30px #7652c221;
}

.btn.primary:hover {
  background: #a47df0;
  transform: translateY(-1px);
}

.btn.small {
  padding: 8px 13px;
  font-size: 12px;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  width: 42px;
  height: 42px;
  background: #141421aa;
}

.icon-btn:hover {
  background: #2b243c;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  border: 1px solid #ffffff18;
  border-radius: 7px;
  padding: 3px 8px;
  color: #d4cce9;
  background: #ffffff05;
}

.row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.spacer {
  flex: 1;
}

.empty {
  border: 1px dashed #ffffff22;
  border-radius: 16px;
  text-align: center;
  padding: 55px 24px;
  margin: 24px 0;
}

.empty h2 {
  font-size: 30px;
  margin-bottom: 10px;
}

.empty p {
  color: var(--muted);
  max-width: 540px;
  margin: 0 auto 20px;
}

.skeleton {
  background: linear-gradient(100deg,#161622 20%,#242134 45%,#161622 70%);
  background-size: 220% 100%;
  animation: pulse 1.7s infinite;
  border-radius: 12px;
  height: 280px;
}

@keyframes pulse {
  to {
    background-position: -220% 0;
  }
}

.grid {
  display: grid;
  grid-template-columns: repeat(6,minmax(0,1fr));
  gap: 24px;
}

.loading-grid {
  padding: 60px 0;
}

.header-inner {
  display: flex;
  align-items: center;
  height: 100%;
  gap: 46px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.brand img {
  width: 37px;
  height: 37px;
  border-radius: 10px;
}

.brand span {
  font-family: var(--serif);
  font-size: 33px;
  line-height: 1;
}

.brand sup {
  font: 9px Manrope;
  color: #b29ccb;
  letter-spacing: .1em;
  margin-left: 4px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 100%;
}

.nav a {
  color: var(--muted);
  height: 100%;
  display: flex;
  align-items: center;
  border-bottom: 2px solid transparent;
  padding-top: 2px;
  font-size: 13px;
}

.nav a:hover,
.nav a.active {
  color: var(--text);
}

.nav a.active {
  border-color: var(--purple);
}

.header-actions {
  margin-left: auto;
  display: flex;
  gap: 14px;
  align-items: center;
}

.header-search {
  color: var(--muted);
  display: flex;
}

.avatar {
  width: 33px;
  height: 33px;
  border-radius: 50%;
  object-fit: cover;
  background: #3c2b58;
}

.mobile-label {
  display: none;
}

.hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg,#0b0b16 8%,#0b0b16e6 30%,#0b0b1633),linear-gradient(0deg,#0b0b16,transparent 65%),url("assets/search_header_bg.jpg") center 46%/cover;
}

.hero-inner {
  min-height: 470px;
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  align-items: center;
  gap: 35px;
  padding-block: 58px;
}

.hero-copy {
  position: relative;
  z-index: 2;
  max-width: 590px;
}

.hero .eyebrow {
  margin-bottom: 20px;
}

.hero h1 {
  letter-spacing: -.035em;
}

.hero h1 em {
  color: #c5a9ff;
  font-weight: 600;
  font-style: italic;
}

.hero-copy>p {
  font-size: 14px;
  color: #bbb3ce;
  max-width: 390px;
  margin: 23px 0 30px;
}

.hero-buttons {
  display: flex;
  gap: 12px;
}

.hero-note {
  font-size: 11px;
  color: #a19bad;
  margin-top: 22px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-note:before {
  content: "";
  width: 5px;
  height: 5px;
  background: var(--mint);
  border-radius: 50%;
}

.hero-books {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  isolation: isolate;
}

.hero-books:before {
  content: "";
  position: absolute;
  width: 300px;
  height: 300px;
  background: #9970ed25;
  filter: blur(65px);
  border-radius: 50%;
  z-index: -1;
}

.hero-book {
  position: absolute;
  width: 165px;
  aspect-ratio: 2/3;
  border-radius: 6px;
  box-shadow: 0 24px 55px #0009;
  border: 1px solid #ffffff24;
  overflow: hidden;
  background: #201a2c;
  transition: transform .25s;
}

.hero-book img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-book {
  --book-x: 0px;
  --book-y: -5px;
  --book-angle: 0deg;
  --book-lift: 0px;
  transform: translate(var(--book-x),calc(var(--book-y) + var(--book-lift))) rotate(var(--book-angle));
}

.hero-book:nth-child(1) {
  --book-x: -135px;
  --book-y: 13px;
  --book-angle: -12deg;
  z-index: 1;
}

.hero-book:nth-child(2) {
  width: 185px;
  z-index: 3;
}

.hero-book:nth-child(3) {
  --book-x: 135px;
  --book-y: 13px;
  --book-angle: 12deg;
  z-index: 2;
}

.hero-book:focus-visible {
  --book-lift: -12px;
  z-index: 6;
  border-color: #d4b5ff;
  box-shadow: 0 24px 55px #0009,0 0 0 2px #b497eb66;
}

@media (hover:hover) and (pointer:fine) {
  .hero-book:hover {
    --book-lift: -12px;
    z-index: 6;
    border-color: #d4b5ff;
    box-shadow: 0 24px 55px #0009,0 0 0 2px #b497eb66;
  }
}

.hero-badge {
  position: absolute;
  bottom: 4px;
  right: 6px;
  z-index: 5;
  border: 1px solid #cfb5ff33;
  border-radius: 10px;
  background: #181324ed;
  padding: 10px 17px;
  font-size: 11px;
  box-shadow: 0 8px 30px #0005;
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-badge .icon {
  color: #c8aaff;
}

.genre-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 26px 0;
  overflow-x: auto;
  scrollbar-width: none;
  border-bottom: 1px solid var(--line);
}

.genre-bar .label {
  white-space: nowrap;
  color: #8e879f;
  font-size: 11px;
  margin-right: 10px;
}

.genre {
  border: 1px solid #ffffff14;
  border-radius: 20px;
  padding: 7px 16px;
  color: #b4adbf;
  font-size: 12px;
  white-space: nowrap;
}

.genre:hover,
.genre.active {
  background: #a77cf01c;
  border-color: #a77cf05a;
  color: #d9c7ff;
}

.section {
  padding-top: 42px;
}

.section-head {
  display: flex;
  align-items: end;
  gap: 20px;
  justify-content: space-between;
  margin-bottom: 24px;
}

.section-title .eyebrow {
  margin-bottom: 8px;
  font-size: 11px;
  letter-spacing: .18em;
}

.section-head>a {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #b8adc9;
  font-size: 12px;
  padding-bottom: 4px;
}

.section-head>a:hover {
  color: white;
}

.book-card {
  display: block;
  min-width: 0;
}

.cover {
  position: relative;
  aspect-ratio: 2/3;
  background: linear-gradient(145deg,#2e2342,#171520);
  border: 1px solid #ffffff12;
  overflow: hidden;
  border-radius: 9px;
  box-shadow: 0 8px 20px #0003;
  transition: transform .25s,box-shadow .25s;
}

.cover img {
  height: 100%;
  width: 100%;
  object-fit: cover;
}

.book-card:hover .cover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px #0006;
}

.cover .age {
  position: absolute;
  top: 8px;
  left: 8px;
  font-size: 11px;
  background: #0b0b16b8;
  border: 1px solid #ffffff25;
  padding: 2px 6px;
  border-radius: 5px;
  backdrop-filter: blur(5px);
}

.cover .completed {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: #15342bea;
  color: #b3ebce;
  border-radius: 4px;
  padding: 2px 7px;
  font-size: 11px;
}

.cover-fallback {
  padding: 18px;
  height: 100%;
  display: flex;
  align-items: center;
  text-align: center;
  font: 28px var(--serif);
  color: #c1acde;
}

.book-card h3 {
  margin: 12px 0 3px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.book-card .author {
  font-size: 11px;
  color: #8f879e;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.book-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  color: #a89fb8;
  margin-top: 8px;
}

.book-meta .rating {
  color: #abcab8;
}

.book-meta .icon {
  width: 12px;
  height: 12px;
}

.book-meta>span {
  display: flex;
  gap: 4px;
  align-items: center;
}

.chapter-grid {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 14px;
}

.chapter-card {
  border: 1px solid var(--line);
  background: linear-gradient(115deg,#171422,#11101b);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 15px;
  border-radius: 12px;
  min-width: 0;
}

.chapter-card:hover {
  border-color: #ae85e34d;
  background: #1b1627;
}

.chapter-card img {
  width: 47px;
  height: 67px;
  object-fit: cover;
  border-radius: 5px;
}

.chapter-card>div {
  min-width: 0;
}

.chapter-card h3 {
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chapter-card p {
  color: #a29aad;
  font-size: 11px;
  margin: 6px 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chapter-card small {
  color: #b79bd7;
  font-size: 11px;
}

.continue {
  display: flex;
  gap: 20px;
  align-items: center;
  padding: 20px 24px;
  border: 1px solid #b193e32c;
  border-radius: 14px;
  background: #9870d90a;
  margin-top: 30px;
}

.continue .eyebrow {
  font-size: 11px;
}

.continue h3 {
  margin-top: 3px;
}

.continue .btn {
  margin-left: auto;
}

.continue img {
  height: 65px;
  width: 44px;
  object-fit: cover;
  border-radius: 4px;
}

.app-banner {
  margin: 55px 0 0;
  padding: 30px 35px;
  border: 1px solid #a786db25;
  border-radius: 16px;
  background: linear-gradient(105deg,#22182d,#12111d);
  display: flex;
  align-items: center;
  gap: 25px;
}

.app-banner img {
  height: 62px;
  width: 62px;
  border-radius: 16px;
}

.app-banner h2 {
  font-size: 30px;
}

.app-banner p {
  color: var(--muted);
  font-size: 12px;
  margin-top: 5px;
}

.app-banner .btn {
  margin-left: auto;
}

#footer {
  border-top: 1px solid var(--line);
  margin-top: 65px;
}

.footer-inner {
  padding: 32px 0;
  display: flex;
  align-items: center;
  gap: 30px;
  color: #938a9f;
  font-size: 11px;
}

.footer-inner .brand {
  color: #c5b7d6;
}

.footer-inner .brand span {
  font-size: 26px;
}

.footer-links {
  display: flex;
  gap: 22px;
  margin-left: auto;
}

.footer-bottom {
  border-top: 1px solid #ffffff08;
  padding: 16px 0 23px;
  color: #655f72;
  font-size: 11px;
}

.page-intro {
  padding: 50px 0 25px;
}

.page-intro .eyebrow {
  margin-bottom: 12px;
}

.page-intro h1 {
  font-size: 56px;
}

.page-intro p {
  color: var(--muted);
  margin-top: 14px;
}

.catalog-tools {
  display: flex;
  gap: 14px;
  margin: 22px 0;
  align-items: center;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid #a78acb38;
  border-radius: 12px;
  padding: 0 16px;
  background: #15111e;
  flex: 1;
}

.search-box:focus-within {
  border-color: #b598e2;
}

.search-box input {
  background: transparent;
  border: 0;
  color: var(--text);
  padding: 14px 0;
  width: 100%;
  min-width: 0;
  outline: none !important;
}

.search-box .icon {
  color: #9d8bb9;
}

.search-box button {
  color: #a898bf;
}

.select {
  background: #15121f;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px;
  color: #bcb1cb;
  max-width: 190px;
}

.result-count {
  color: #8b8299;
  font-size: 11px;
  margin: 25px 0 20px;
}

.load-more {
  display: flex;
  justify-content: center;
  margin: 35px 0;
}

.catalog-grid {
  row-gap: 32px;
}

.back {
  display: inline-flex;
  gap: 7px;
  align-items: center;
  font-size: 12px;
  color: #b4a8c5;
  margin-bottom: 26px;
}

.detail-top {
  position: relative;
  padding: 35px 0 45px;
  isolation: isolate;
  border-bottom: 1px solid var(--line);
}

.detail-top:before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(0deg,#0b0b16, #0b0b16d4 65%),var(--book-back,none) center 35%/cover;
  opacity: .7;
}

.detail-hero {
  display: grid;
  grid-template-columns: 215px 1fr;
  gap: 40px;
  align-items: center;
  max-width: 950px;
}

.detail-cover {
  width: 215px;
  aspect-ratio: 2/3;
  object-fit: cover;
  border-radius: 10px;
  box-shadow: 0 12px 45px #0008;
}

.detail-copy h1 {
  font-size: 58px;
  margin: 14px 0;
}

.author-link {
  color: #b5a1ce;
  font-size: 13px;
}

.tags {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin: 15px 0;
}

.stats {
  display: flex;
  gap: 24px;
  margin: 22px 0;
}

.stat {
  font-size: 20px;
  color: #d2c1e9;
}

.stat small {
  display: block;
  font-size: 11px;
  color: #91849f;
  margin-top: 1px;
}

.detail-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.detail-columns {
  display: grid;
  grid-template-columns: 1fr 310px;
  gap: 45px;
  padding-top: 34px;
}

.tabs {
  display: flex;
  border-bottom: 1px solid var(--line);
  gap: 28px;
  margin-bottom: 28px;
}

.tabs button {
  padding: 10px 0 14px;
  color: #9a8da8;
}

.tabs button.active {
  color: #d6beff;
  border-bottom: 2px solid #a477ec;
}

.description {
  font-size: 14px;
  line-height: 1.95;
  color: #bfb4c9;
  white-space: pre-wrap;
}

.info-panel {
  border: 1px solid var(--line);
  background: #13111d;
  border-radius: 13px;
  padding: 24px;
  height: fit-content;
}

.info-panel h2 {
  font-size: 28px;
  margin-bottom: 20px;
}

.info-row {
  display: flex;
  gap: 20px;
  justify-content: space-between;
  font-size: 11px;
  padding: 11px 0;
  border-bottom: 1px solid #ffffff08;
}

.info-row:last-child {
  border: 0;
}

.info-row span:first-child {
  color: #91869f;
}

.info-row span:last-child {
  text-align: right;
}

.chapter-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.chapter-list li {
  border-bottom: 1px solid var(--line);
}

.chapter-list a {
  padding: 17px 4px;
  display: flex;
  align-items: center;
  gap: 15px;
}

.chapter-list a:hover {
  color: var(--purple);
}

.chapter-list .num {
  color: #84718f;
  font-size: 12px;
  min-width: 48px;
}

.chapter-list .chapter-name {
  flex: 1;
  font-size: 13px;
}

.chapter-list small {
  font-size: 11px;
  color: #74677f;
}

.auth-name {
  font-size: 20px;
}

dialog {
  background: #15121f;
  color: var(--text);
  border: 1px solid #8062a44d;
  border-radius: 22px;
  box-shadow: 0 28px 100px #0008;
  width: min(440px,calc(100% - 32px));
  max-height: calc(100dvh - 48px);
  overflow: auto;
  padding: 32px;
}

dialog::backdrop {
  background: #06050bc9;
  backdrop-filter: blur(7px);
}

dialog .close {
  position: absolute;
  right: 16px;
  top: 16px;
  width: 30px;
  height: 30px;
}

.auth-brand {
  font-family: var(--serif);
  font-size: 34px;
  color: #d1b5f6;
  margin-bottom: 20px;
}

dialog h2 {
  font-size: 35px;
  margin-bottom: 10px;
}

dialog .intro {
  font-size: 12px;
  color: #b0a1bf;
  margin-bottom: 25px;
}

.form-label {
  display: block;
  font-size: 11px;
  margin-bottom: 7px;
  color: #c6b8d4;
}

.field {
  width: 100%;
  border: 1px solid #ffffff20;
  background: #0c0a13;
  color: var(--text);
  border-radius: 9px;
  padding: 12px;
  margin-bottom: 17px;
}

.auth-form .btn {
  width: 100%;
}

.form-error {
  color: #efaaa6;
  font-size: 12px;
  margin: 12px 0;
  min-height: 0;
}

.form-error:empty {
  display: none;
}

.social-row {
  display: flex;
  gap: 9px;
}

.social-row button {
  flex: 1;
  padding: 11px 5px;
  font-size: 11px;
}

.divider {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #7e6f8d;
  font-size: 11px;
  margin: 22px 0;
}

.divider:before,
.divider:after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

.auth-fine {
  font-size: 11px;
  color: #93829f;
  line-height: 1.7;
  margin-top: 21px;
}

.auth-fine a {
  text-decoration: underline;
}

.social-status {
  color: var(--mint);
  font-size: 12px;
  margin-top: 16px;
}

.profile-box {
  max-width: 650px;
  margin-top: 25px;
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 30px;
  border-radius: 15px;
}

.profile-box .avatar {
  width: 65px;
  height: 65px;
}

.profile-box h2 {
  font-size: 34px;
}

.profile-box .row {
  margin-bottom: 26px;
}

.profile-box .btn {
  margin-top: 20px;
}

body.reading {
  background: var(--reader-bg,#f6f0e2);
  color: var(--reader-text,#352c25);
}

body.reading #header {
  display: none;
}

body.reading #footer {
  display: none;
}

.reader-toolbar {
  position: sticky;
  top: 0;
  z-index: 15;
  background: var(--reader-bg,#f6f0e2);
  border-bottom: 1px solid #8577602b;
  backdrop-filter: blur(10px);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.reader-toolbar .icon-btn {
  background: transparent;
  border-color: #85776033;
  color: inherit;
}

.reader-toolbar .reader-name {
  font-size: 12px;
  line-height: 1.5;
  flex: 1;
  min-width: 0;
}

.reader-name strong {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 600;
}

.reader-name small {
  color: inherit;
  opacity: .6;
  font-size: 11px;
}

.reader-body {
  margin: auto;
}

.reader-body h1 {
  margin-bottom: 10px;
}

.reader-body .chapter-label {
  font-size: 11px;
  letter-spacing: .16em;
  text-transform: uppercase;
  opacity: .5;
  margin-bottom: 18px;
}

.reader-text {
  overflow-wrap: anywhere;
}

.reader-text h2 {
  font: 600 1.3em/1.5 Lora;
}

.reader-text blockquote {
  border-left: 2px solid #99836b;
  padding-left: 20px;
  font-style: italic;
  opacity: .8;
}

.reader-text hr {
  border-top: 1px solid #85776044;
  margin: 35px 0;
}

.reader-text strong {
  font-weight: 700;
}

.reader-nav {
  display: flex;
  padding-top: 25px;
  border-top: 1px solid #85776044;
  align-items: center;
}

.reader-nav .btn {
  border-color: #85776044;
  color: inherit;
  background: transparent;
  white-space: normal;
  text-align: center;
}

.reader-progress {
  position: fixed;
  left: 0;
  width: var(--progress,0%);
}

.settings-field {
  margin: 22px 0;
}

.settings-field label {
  font-size: 12px;
  display: flex;
  justify-content: space-between;
  margin-bottom: 12px;
}

.settings-field input {
  width: 100%;
  accent-color: #a182d5;
}

.theme-options {
  display: flex;
  gap: 10px;
}

.theme-button {
  border: 2px solid transparent;
  border-radius: 10px;
  padding: 11px 15px;
}

.theme-button.selected {
  border-color: #a17ad9;
}

.theme-button.paper {
  background: #f6f0e2;
  color: #352c25;
}

.theme-button.light {
  background: #fff;
  color: #222;
}

.theme-button.night {
  background: #17151d;
  color: #c9c2d2;
}

#toast {
  position: fixed;
  left: 50%;
  bottom: 25px;
  transform: translate(-50%,20px);
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  background: #2b2237;
  border: 1px solid #b192d94d;
  color: #f0e6fc;
  padding: 12px 22px;
  border-radius: 11px;
  max-width: calc(100vw - 30px);
  font-size: 12px;
  transition: .2s;
  text-align: center;
}

#toast.show {
  opacity: 1;
  transform: translate(-50%,0);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.fade-in {
  animation: appear .35s ease;
}

@keyframes appear {
  from {
    opacity: .4;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (min-width:1500px) {
  .hero-inner {
    min-height: 510px;
  }
}

@media (max-width:1050px) {
  .wrap {
    width: calc(100% - 48px);
  }
  .header-inner {
    gap: 28px;
  }
  .nav {
    gap: 20px;
  }
  .grid {
    grid-template-columns: repeat(4,minmax(0,1fr));
    gap: 20px;
  }
  .home-row .book-card:nth-child(n/**/+5) {
    display: none;
  }
  .hero-inner {
    grid-template-columns: 1.1fr 1fr;
    min-height: 430px;
  }
  .chapter-grid {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
  .chapter-grid .chapter-card:nth-child(3) {
    display: none;
  }
  .detail-columns {
    grid-template-columns: 1fr 260px;
    gap: 30px;
  }
}

@media (max-width:700px) {
  .wrap {
    width: calc(100% - 36px);
  }
  .brand span {
    font-size: 29px;
  }
  .brand img {
    width: 30px;
    height: 30px;
  }
  .brand sup {
    display: none;
  }
  .nav {
    gap: 16px;
    margin-left: auto;
  }
  .nav a {
    font-size: 11px;
  }
  .nav a:first-child {
    display: none;
  }
  .header-actions {
    margin-left: 5px;
  }
  .header-actions .btn {
    padding: 8px 12px;
    font-size: 11px;
  }
  .header-search {
    display: none;
  }
  .hero {
    background: linear-gradient(0deg,#0b0b16, #0b0b16a6),url("assets/search_header_bg.jpg") center/cover;
  }
  .hero-inner {
    padding: 40px 0 30px;
    gap: 0;
    grid-template-columns: 1fr;
  }
  .hero-copy {
    max-width: 400px;
  }
  .hero .eyebrow {
    font-size: 11px;
  }
  .hero-copy>p {
    font-size: 12px;
    max-width: 310px;
  }
  .hero-note {
    font-size: 11px;
  }
  .hero-badge {
    bottom: 4px;
    right: 4%;
  }
  .genre-bar {
    padding: 20px 0;
  }
  .genre-bar .label {
    display: none;
  }
  .genre {
    font-size: 11px;
    padding: 6px 13px;
  }
  .section {
    padding-top: 30px;
  }
  h2 {
    font-size: 31px;
  }
  .section-title .eyebrow {
    font-size: 10px;
  }
  .section-head {
    margin-bottom: 19px;
  }
  .section-head>a {
    font-size: 11px;
    gap: 2px;
  }
  .section-head>a .icon {
    width: 15px;
  }
  .grid {
    grid-template-columns: repeat(3,minmax(0,1fr));
    gap: 13px;
  }
  .home-row .book-card:nth-child(n/**/+4) {
    display: none;
  }
  .book-card h3 {
    font-size: 11px;
    margin-top: 9px;
  }
  .book-card .author {
    font-size: 11px;
  }
  .book-meta {
    font-size: 11px;
    gap: 6px;
  }
  .book-meta>span:last-child {
    display: none;
  }
  .cover {
    border-radius: 6px;
  }
  .cover .age {
    font-size: 10px;
    padding: 1px 4px;
    top: 5px;
    left: 5px;
  }
  .cover .completed {
    font-size: 10px;
    padding: 2px 4px;
    left: 5px;
    bottom: 5px;
  }
  .chapter-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .chapter-grid .chapter-card:nth-child(3) {
    display: flex;
  }
  .chapter-card {
    padding: 13px;
    gap: 13px;
  }
  .chapter-card img {
    height: 60px;
    width: 42px;
  }
  .chapter-card h3 {
    font-size: 12px;
  }
  .chapter-card p {
    font-size: 11px;
  }
  .app-banner {
    padding: 24px 20px;
    gap: 15px;
    flex-wrap: wrap;
    margin-top: 36px;
  }
  .app-banner img {
    width: 43px;
    height: 43px;
    border-radius: 11px;
  }
  .app-banner h2 {
    font-size: 26px;
  }
  .app-banner p {
    font-size: 11px;
  }
  .app-banner .btn {
    margin-left: 58px;
    font-size: 11px;
    padding: 9px 13px;
  }
  .footer-inner {
    padding-top: 27px;
    flex-wrap: wrap;
    gap: 18px;
  }
  .footer-links {
    margin-left: 0;
    width: 100%;
    gap: 17px;
    font-size: 11px;
  }
  #footer {
    margin-top: 40px;
  }
  .footer-bottom {
    font-size: 11px;
  }
  .page-intro {
    padding-top: 35px;
  }
  .page-intro h1 {
    font-size: 44px;
  }
  .page-intro p {
    font-size: 12px;
  }
  .catalog-tools {
    flex-wrap: wrap;
    gap: 10px;
  }
  .search-box {
    flex-basis: 100%;
  }
  .select {
    font-size: 11px;
    flex: 1;
    max-width: none;
    padding: 10px;
  }
  .catalog-grid {
    row-gap: 23px;
  }
  .detail-top {
    padding: 22px 0 30px;
  }
  .detail-hero {
    grid-template-columns: 115px 1fr;
    gap: 20px;
    align-items: start;
  }
  .detail-cover {
    width: 115px;
    border-radius: 7px;
  }
  .detail-copy h1 {
    font-size: 34px;
    margin: 4px 0 10px;
  }
  .detail-copy .eyebrow {
    font-size: 10px;
  }
  .author-link {
    font-size: 11px;
  }
  .tags {
    gap: 5px;
    margin: 11px 0;
  }
  .pill {
    font-size: 11px;
    padding: 2px 6px;
  }
  .stats {
    gap: 14px;
    margin: 15px 0;
  }
  .stat {
    font-size: 15px;
  }
  .stat small {
    font-size: 10px;
  }
  .detail-actions {
    grid-column: 1/-1;
  }
  .detail-copy .btn {
    font-size: 11px;
    padding: 9px 10px;
  }
  .detail-copy .icon {
    width: 15px;
    height: 15px;
  }
  .detail-columns {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-top: 20px;
  }
  .info-panel {
    padding: 20px;
  }
  .description {
    font-size: 12px;
  }
  .tabs {
    gap: 22px;
  }
  .tabs button {
    font-size: 12px;
  }
  .chapter-list a {
    gap: 9px;
  }
  .chapter-list .num {
    font-size: 11px;
    min-width: 37px;
  }
  .chapter-list .chapter-name {
    font-size: 12px;
  }
  .chapter-list small {
    display: none;
  }
  .continue {
    padding: 16px;
    gap: 12px;
  }
  .continue h3 {
    font-size: 11px;
  }
  .continue .btn {
    padding: 9px;
    font-size: 11px;
  }
  .continue .btn .icon {
    display: none;
  }
  dialog {
    padding: 28px 24px;
  }
  .reader-toolbar {
    padding: 10px 14px;
    gap: 10px;
  }
  .reader-toolbar .icon-btn {
    width: 35px;
    height: 35px;
  }
  .reader-toolbar .reader-name {
    font-size: 11px;
  }
  .reader-nav .btn {
    font-size: 11px;
    padding: 10px;
  }
  .reader-nav .icon {
    width: 15px;
  }
}

@media (prefers-reduced-motion:reduce) {
  * {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

@media (max-width:420px) {
  .header-inner {
    gap: 10px;
  }
  .brand img {
    display: none;
  }
  .brand span {
    font-size: 27px;
  }
  .nav {
    gap: 13px;
  }
  .nav a {
    font-size: 11px;
  }
  .header-actions .btn {
    padding: 8px 10px;
  }
  .header-actions .btn .icon {
    display: none;
  }
}

/* Book details follow the mobile reader's hierarchy and colors. */

@font-face {
  font-family: Playfair;
  src: url("assets/PlayfairDisplay-Regular.woff2") format("woff2");
  font-display: swap;
}

.book-detail {
  max-width: 1000px;
  margin: 0 auto 70px;
  background: #070c1d;
  border-radius: 0 0 24px 24px;
  overflow: hidden;
  color: #e5e0f0;
}

.book-heading {
  position: relative;
  isolation: isolate;
  padding: 26px 30px 12px;
}

.book-heading:before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg,#070c1d66,#070c1dde 75%,#070c1d),var(--book-back) center 30%/cover;
}

.book-back {
  margin-bottom: 22px;
  background: #10182aaa;
}

.book-overview {
  display: grid;
  grid-template-columns: minmax(150px,25%) minmax(0,1fr);
  gap: 30px;
  align-items: center;
}

.book-cover {
  position: relative;
  aspect-ratio: 2/3;
  border-radius: 12px;
  overflow: hidden;
  background: #141b30;
  box-shadow: 0 12px 35px #0005;
}

.book-cover>img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.book-age {
  position: absolute;
  top: 8px;
  right: 8px;
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 8px;
  background: #070c1dbb;
}

.book-heading-copy {
  min-width: 0;
}

.book-heading-copy h1 {
  font-family: Playfair,Georgia,serif;
  font-weight: 400;
  font-size: clamp(28px,4vw,45px);
  line-height: 1.2;
  overflow-wrap: anywhere;
  margin-bottom: 25px;
}

.book-genres,
.book-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.book-genres a,
.book-genres .btn,
.book-tags a {
  border: 1px solid #ffffff10;
  background: #242c42;
  border-radius: 20px;
  padding: 3px 12px;
  font-size: 13px;
  line-height: 1.5;
}

.book-genres .genre-more {
  background: #7942b74d;
  min-height: 0;
  margin: 0;
  gap: 0;
}

.book-metrics {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 12px;
  margin-top: 32px;
}

.book-metric>div {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 18px;
}

.book-metric small {
  display: block;
  font-family: Cormorant,Georgia,serif;
  font-size: 15px;
  color: #b3abc6;
  white-space: nowrap;
}

.book-metric.rating>div {
  color: #45d2a5;
}

.book-metric .icon {
  width: 22px;
  height: 22px;
}

.book-actions {
  display: grid;
  grid-template-columns: 1fr 1.05fr 48px;
  gap: 12px;
  margin-top: 24px;
  align-items: stretch;
}

.book-actions .btn {
  border-radius: 30px;
  min-width: 0;
  min-height: 48px;
  padding: 10px 14px;
  font-family: Cormorant,Georgia,serif;
  gap: 9px;
}

.book-actions .primary {
  background: linear-gradient(110deg,#b13dff,#635cff);
  border-color: #ae71ff;
}

.book-actions .book-shelf {
  background: #151b2b99;
  border: 1px solid #ffffff30;
}

.book-actions>.icon-btn {
  width: 48px;
  height: 48px;
  align-self: center;
  border: 1px solid #ffffff30;
  background: #10182a88;
}

.book-tabs {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  margin: 0 30px 10px;
  border: 1px solid #ffffff12;
  border-radius: 14px;
  background: #10182a;
  padding: 4px 8px;
}

.book-tabs button {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: Cormorant,Georgia,serif;
  color: #aaa4bd;
  padding: 13px 4px 15px;
  white-space: nowrap;
}

.book-tabs button .icon {
  width: 19px;
  height: 19px;
}

.book-tabs button.active {
  color: #e4cffc;
  text-shadow: 0 0 12px #b899ff99;
}

.book-tabs button.active:after {
  content: "";
  position: absolute;
  height: 2px;
  bottom: 0;
  left: 0;
  right: 0;
  background: #b891ff;
  box-shadow: 0 0 9px #b891ff66;
}

.book-tab-body {
  padding: 0 30px 24px;
}

.book-panel {
  background: #10182a;
  border: 1px solid #ffffff12;
  border-radius: 14px;
  padding: 17px 20px;
  margin-bottom: 10px;
}

.book-panel h2 {
  font-family: Cormorant,Georgia,serif;
  font-weight: 600;
  margin-bottom: 10px;
}

.book-description {
  white-space: pre-line;
  overflow-wrap: anywhere;
}

.book-description.collapsed {
  display: -webkit-box;
  -webkit-line-clamp: 6;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.book-expand.btn {
  color: #c7b3e7;
  border: 0;
  background: none;
  min-height: 40px;
  padding: 10px 0 0;
  font: 15px Manrope,sans-serif;
}

.book-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 25px;
}

.book-info-grid>div {
  min-width: 0;
}

.book-info-row {
  display: grid;
  grid-template-columns: 18px auto minmax(0,1fr);
  gap: 9px;
  font-family: Cormorant,Georgia,serif;
  font-size: 23px;
  line-height: 1.4;
  margin-bottom: 6px;
}

.book-info-row .icon {
  width: 17px;
  height: 17px;
  align-self: center;
  color: #c4adf2;
}

.book-info-row strong,
.book-info-row>a {
  text-align: right;
  overflow-wrap: anywhere;
}

.book-info-row.blue strong,
.book-info-row.blue>a {
  color: #8ccbff;
}

.book-info-row.gold strong {
  color: #ffcf7d;
}

.book-info-row.mint strong {
  color: #7de7c5;
}

.book-info-row.pink strong {
  color: #ff93b3;
}

.book-info-genres {
  font-family: Cormorant,Georgia,serif;
  font-size: 23px;
  line-height: 1.35;
  margin-bottom: 8px;
}

.book-info-genres>div {
  display: flex;
  align-items: center;
  gap: 9px;
}

.book-info-genres .icon {
  width: 17px;
  height: 17px;
  color: #c4adf2;
}

.book-info-genres p {
  color: #c2b0df;
  margin-top: 3px;
}

.book-tags a {
  background: #24203c;
  color: #cdb8f1;
}

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

.book-avatar,
.book-author>.cover-fallback {
  width: 65px;
  height: 65px;
  object-fit: cover;
  border-radius: 50%;
  flex-shrink: 0;
}

.book-author h3 {
  font-family: Cormorant,Georgia,serif;
  font-size: 27px;
  font-weight: 600;
}

.book-author small {
  color: #aaa4bd;
}

.book-author-link {
  margin-left: auto;
  border-radius: 50%;
  border: 1px solid #68d5c0;
  color: #7de7c5;
  background: #12584a44;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
}

.book-chapters {
  list-style: none;
  padding: 0;
  margin: 0;
}

.book-chapters li {
  margin-bottom: 10px;
}

.book-chapters a {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  background: #10182a;
  border: 1px solid #ffffff12;
  border-radius: 14px;
}

.book-chapter-number {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 42px;
  height: 46px;
  background: #8253ff22;
  border-radius: 10px;
  color: #c2a7ff;
}

.book-chapters h3 {
  font-size: 16px;
}

.book-chapters small {
  color: #9991b1;
  font-size: 12px;
}

.book-chapters a>.icon {
  margin-left: auto;
  color: #ad99ce;
}

.book-comment-text {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  line-height: 1.8;
  margin: 8px 0;
}

.book-comment-meta {
  display: flex;
  justify-content: space-between;
  color: #c8afe9;
  font-size: 13px;
}

.book-empty {
  padding: 24px;
  text-align: center;
  color: #b6accb;
}

@media (min-width:1100px) {
  .book-detail {
    margin-top: 24px;
  }
  .book-heading {
    padding: 30px 40px 18px;
  }
  .book-tabs {
    margin-left: 40px;
    margin-right: 40px;
  }
  .book-tab-body {
    padding-left: 40px;
    padding-right: 40px;
  }
}

@media (max-width:700px) {
  .book-detail {
    margin-bottom: 30px;
    border-radius: 0;
  }
  .book-heading {
    padding: 18px 16px 12px;
  }
  .book-back {
    margin-bottom: 18px;
  }
  .book-overview {
    grid-template-columns: 31% minmax(0,1fr);
    gap: 16px;
  }
  .book-heading-copy h1 {
    font-size: clamp(24px,5.8vw,34px);
    margin-bottom: 18px;
  }
  .book-genres {
    gap: 5px;
  }
  .book-genres a,
  .book-genres .btn {
    font-size: 12px;
    padding: 2px 9px;
  }
  .book-metrics {
    margin-top: 22px;
    gap: 5px;
  }
  .book-metric>div {
    gap: 4px;
    font-size: 13px;
  }
  .book-metric .icon {
    width: 17px;
    height: 17px;
  }
  .book-actions {
    margin-top: 18px;
  }
  .book-actions>.icon-btn {
    width: 38px;
    height: 40px;
  }
  .book-tabs {
    margin: 0 12px 8px;
    padding: 3px 6px;
  }
  .book-tab-body {
    padding: 0 12px 18px;
  }
  .book-panel {
    padding: 12px 13px;
    border-radius: 12px;
    margin-bottom: 8px;
  }
  .book-info-grid {
    gap: 14px;
  }
  .book-info-row {
    font-size: 19px;
    gap: 5px;
    grid-template-columns: 15px auto minmax(0,1fr);
    line-height: 1.3;
  }
  .book-info-row .icon,
  .book-info-genres .icon {
    width: 14px;
    height: 14px;
  }
  .book-info-genres {
    font-size: 20px;
  }
  .book-avatar {
    width: 52px;
    height: 52px;
  }
  .book-author-link {
    width: 39px;
    height: 39px;
  }
}

@media (max-width:380px) {
  .book-heading {
    padding-left: 12px;
    padding-right: 12px;
  }
  .book-overview {
    gap: 12px;
    grid-template-columns: 30% minmax(0,1fr);
  }
  .book-metric small {
    font-size: 11px;
  }
  .book-metric>div {
    font-size: 12px;
    gap: 3px;
  }
  .book-metric .icon {
    width: 15px;
    height: 15px;
  }
  .book-info-grid {
    gap: 10px;
  }
  .book-info-row {
    font-size: 17px;
  }
}

@media (max-width:700px) {
  .book-metric small {
    font-size: 11px;
    line-height: 1.3;
    white-space: normal;
    overflow-wrap: anywhere;
  }
}

.book-author .book-avatar {
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #2b2445;
  color: #dacbff;
  font: 24px Playfair,Georgia,serif;
}

.book-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.book-author>div:nth-child(2) {
  min-width: 0;
}

.book-author h3 {
  overflow-wrap: anywhere;
}

.book-info-row>a {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.book-avatar img[hidden] {
  display: none;
}

@media (max-width:700px) {
  .book-panel h2 {
    margin-bottom: 8px;
  }
  .book-metrics {
    column-gap: 7px;
  }
  .book-metric:nth-child(2) small {
    font-size: 11px;
    white-space: nowrap;
    overflow-wrap: normal;
  }
}

/* Align metadata values with lining figures, including 7.4K and 78. */

.book-info-row {
  align-items: center;
  min-height: 30px;
}

.book-info-row strong,
.book-info-row>a {
  font-family: Manrope,system-ui,sans-serif;
  font-size: 15px;
  font-weight: 400;
  font-variant-numeric: lining-nums tabular-nums;
  line-height: 1.45;
}

.book-info-row strong {
  justify-self: end;
}

.book-info-row.mint strong {
  max-width: 140px;
}

.book-info-grid>div:last-child .book-info-row {
  min-height: 34px;
}

.author-avatar {
  position: relative;
  display: inline-block;
  vertical-align: middle;
  width: var(--avatar-size);
  height: var(--avatar-size);
  flex-shrink: 0;
  color: #dacbff;
}

.author-portrait {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  background: #2b2445;
  font: 24px Playfair,Georgia,serif;
}

.author-portrait>img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.author-portrait>img[hidden] {
  display: none;
}

.pioneer-avatar {
  color: var(--award);
  margin: 0 7px;
}

.pioneer-avatar .author-portrait {
  inset: 0 3.95% 7.9%;
  padding: 1.25px;
  background: linear-gradient(135deg,color-mix(in srgb,var(--award) 45%,transparent),var(--award) 25%,color-mix(in srgb,var(--award) 30%,transparent) 55%,var(--award) 80%);
  box-shadow: 0 0 6px color-mix(in srgb,var(--award) 15%,transparent);
  border: 1.25px solid var(--award);
}

.pioneer-laurel {
  position: absolute;
  pointer-events: none;
  left: -9.2%;
  top: 0;
  width: 118.4%;
  height: 100%;
  overflow: visible;
}

.pioneer-label {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  left: -7.9%;
  right: -7.9%;
  bottom: 0;
  height: 23.7%;
  border: 1px solid color-mix(in srgb,var(--award) 85%,transparent);
  border-radius: 12px;
  background: linear-gradient(#1a1924f5,#090c18);
  color: var(--award);
  font-family: Manrope,system-ui,sans-serif;
  font-weight: 400;
  font-size: calc(var(--avatar-size) * .12);
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 0 3px color-mix(in srgb,var(--award) 10%,transparent);
}

.book-author>div {
  min-width: 0;
}

.book-author>.author-avatar+div {
  flex: 1;
}

.book-author h3 {
  line-height: 1.25;
}

.profile-box .author-avatar {
  margin-right: 12px;
}

.book-info-grid>div:last-child .book-info-row {
  grid-template-columns: 17px minmax(0,1fr) 52px;
}

@media (max-width:700px) {
  .book-info-grid>div:last-child .book-info-row {
    min-height: 30px;
  }
  .book-author {
    gap: 14px;
  }
  .book-info-row strong,
  .book-info-row>a {
    font-size: 15px;
  }
  .book-info-grid>div:last-child .book-info-row {
    grid-template-columns: 15px minmax(0,1fr) 42px;
  }
}

/* Keep parenthesized counts on the text baseline instead of old-style figures. */

.book-tabs button,
.book-metric.rating small {
  font-variant-numeric: lining-nums tabular-nums;
  font-feature-settings: "lnum" 1,"tnum" 1;
}

@font-face {
  font-family: CormorantText;
  src: url("assets/CormorantGaramond-Regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

.book-description {
  font-family: CormorantText,Georgia,serif;
  font-weight: 400;
}

.book-expand.btn {
  gap: 8px;
}

.book-expand .icon {
  width: 18px;
  height: 18px;
}

.book-expand[aria-expanded="true"] .icon {
  transform: rotate(180deg);
}

/* Compact chapter rows and discussion layout from the mobile app. */

.book-chapters.app-chapters li {
  display: flex;
  align-items: center;
  gap: 4px;
  background: #10182a;
  border: 1px solid #ffffff12;
  border-radius: 11px;
  margin-bottom: 6px;
  padding: 8px 10px;
}

.book-chapters.app-chapters a {
  flex: 1;
  min-width: 0;
  gap: 10px;
  padding: 0;
  border: 0;
  background: none;
  border-radius: 0;
}

.app-chapters .book-chapter-number {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: linear-gradient(135deg,#ffffff0d,#ffffff03);
  border: 1px solid #ffffff18;
  color: #eeeaf7;
  font: 19px Cormorant,Georgia,serif;
  font-variant-numeric: lining-nums tabular-nums;
}

.app-chapters .chapter-copy {
  min-width: 0;
}

.app-chapters h3 {
  font-family: CormorantText,Georgia,serif;
  font-weight: 400;
  font-size: 18px;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-variant-numeric: lining-nums tabular-nums;
}

.app-chapters small {
  font-family: CormorantText,Georgia,serif;
  font-size: 14px;
  color: #ddd6e8;
  font-variant-numeric: lining-nums tabular-nums;
  line-height: 1.4;
}

.review-summary {
  display: grid;
  grid-template-columns: 4fr 7fr;
  align-items: center;
  padding: 16px;
  background: #10182a;
  border: 1px solid #ffffff12;
  border-radius: 11px;
  gap: 16px;
}

.review-average {
  border-right: 1px solid #ffffff18;
  align-self: stretch;
  display: flex;
  justify-content: center;
  flex-direction: column;
}

.review-average strong {
  display: flex;
  align-items: center;
  gap: 5px;
  font: 600 38px/1.1 Manrope,sans-serif;
}

.review-average .icon {
  width: 32px;
  height: 32px;
  fill: currentColor;
}

.review-average small {
  font-size: 11px;
  margin-top: 7px;
  color: #c2bdcf;
}

.review-distribution {
  display: grid;
  gap: 7px;
}

.review-distribution-row {
  display: grid;
  grid-template-columns: 16px 11px minmax(0,1fr) 30px;
  gap: 5px;
  align-items: center;
  font: 10px/1 Manrope,sans-serif;
  color: #c4bed0;
}

.review-distribution-row>span:first-child {
  text-align: right;
}

.review-distribution-row>span:last-child {
  text-align: right;
  font-size: 11px;
}

.review-distribution-row .icon {
  width: 11px;
  height: 11px;
  fill: currentColor;
}

.review-bar {
  position: relative;
  height: 4px;
  border-radius: 4px;
  background: #242b43;
}

.review-bar>span {
  display: block;
  height: 100%;
  border-radius: 4px;
}

.review-bar small {
  position: absolute;
  bottom: 5px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 10px;
  color: #b6afc4;
}

.review-sign-in {
  display: flex;
  align-items: center;
  gap: 15px;
  border: 1px solid #ffffff12;
  border-radius: 11px;
  background: #10182a;
  padding: 12px;
  margin: 8px 0;
}

.review-sign-in p {
  flex: 1;
  font-size: 12px;
  line-height: 1.5;
  color: #ccc4dd;
}

.review-sign-in .btn {
  min-height: 34px;
  padding: 5px 12px;
  font-size: 12px;
}

.review-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 8px 0;
}

.review-toolbar select {
  background: transparent;
  border: 0;
  padding: 6px 3px;
  font-size: 12px;
  color: #e8e2f2;
}

.review-toolbar option {
  background: #151c30;
}

.review-toolbar .icon-btn {
  width: 32px;
  height: 32px;
  border: 0;
  background: none;
}

.review-toolbar .icon {
  width: 18px;
  height: 18px;
}

.review-comments {
  display: grid;
  gap: 18px;
  margin-top: 10px;
}

.review-comment {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 2px;
  color: #eeeaf7;
}

.review-avatar {
  position: relative;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  overflow: hidden;
  border-radius: 50%;
  background: #303449;
  color: #b8b6c6;
}

.review-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.review-avatar img[hidden] {
  display: none;
}

.review-avatar>.icon {
  width: 18px;
  height: 18px;
}

.review-comment-main {
  flex: 1;
  min-width: 0;
}

.review-comment-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 7px;
  line-height: 1.4;
}

.review-comment-heading strong {
  font-size: 12px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.review-comment-heading time {
  font-size: 11px;
  color: #aaa3b8;
}

.review-author-like {
  font-size: 11px;
  color: #f393bd;
}

.review-user-rating {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 11px;
}

.review-user-rating .icon {
  width: 12px;
  height: 12px;
  fill: currentColor;
}

.review-comment-main>p {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 13px;
  line-height: 1.4;
  margin-top: 3px;
}

.review-copy {
  font-size: 11px;
  color: #a9a3b7;
  padding: 5px 0;
}

.review-copy:hover {
  color: #d1bbf5;
}

.review-likes {
  display: flex;
  align-items: center;
  flex-direction: column;
  flex-shrink: 0;
  gap: 3px;
  width: 28px;
  padding-top: 3px;
  color: #aaa2b9;
}

.review-likes .icon {
  width: 18px;
  height: 18px;
}

.review-likes small {
  font-size: 11px;
}

@media (max-width:700px) {
  .app-chapters h3 {
    font-size: 16px;
  }
  .app-chapters small {
    font-size: 12px;
  }
  .review-summary {
    padding: 12px;
    gap: 12px;
  }
}

.review-composer {
  background: #10182a;
  border: 1px solid #ffffff12;
  border-radius: 11px;
  padding: 9px;
  margin-top: 8px;
}

.review-compose-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.review-compose-row textarea {
  flex: 1;
  min-width: 0;
  resize: vertical;
  border: 0;
  background: transparent;
  color: #eeeaf7;
  font: 13px/1.5 Manrope,sans-serif;
  padding: 5px;
}

.review-compose-row .btn {
  padding: 6px 10px;
  min-height: 30px;
  font-size: 12px;
}

.review-rating-picker {
  display: flex;
  align-items: center;
  gap: 3px;
  margin-top: 7px;
}

.review-rating-picker>span {
  font-size: 11px;
  margin-right: 5px;
}

.review-rating-picker button {
  flex: 1;
  min-width: 0;
  padding: 4px 0;
  font-size: 11px;
  border-radius: 5px;
  color: #c8bbdf;
}

.review-rating-picker button.active {
  background: #8253ff;
  color: white;
}

.review-composer-error {
  font-size: 11px;
  color: #f4cf55;
  margin-top: 6px;
}

/* Reader controls and typography match the mobile app. */

@font-face {
  font-family: RobotoReader;
  src: url("assets/Roboto-Regular.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: RobotoReader;
  src: url("assets/Roboto-Medium.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
}

@font-face {
  font-family: RobotoReader;
  src: url("assets/Roboto-Bold.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}

@font-face {
  font-family: RobotoReader;
  src: url("assets/Roboto-Italic.woff2") format("woff2");
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: Kalam;
  src: url("assets/Kalam-Regular.woff2") format("woff2");
  font-display: swap;
}

.reading {
  background: var(--reader-bg);
  color: var(--reader-text);
}

.app-reader-toolbar {
  height: 58px;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: 40px 1fr 40px;
  align-items: start;
  padding: 6px 10px;
  background: none;
  border: 0;
  pointer-events: none;
  color: var(--reader-text);
}

.app-reader-toolbar>* {
  pointer-events: auto;
}

.app-reader-toolbar .icon-btn,
.reader-tools .icon-btn {
  width: 38px;
  height: 38px;
  border: 1px solid #9c85bf44;
  border-radius: 19px;
  background: #6b52794d;
  color: var(--reader-text);
  backdrop-filter: blur(16px);
  box-shadow: inset 0 1px #ffffff44;
}

.app-reader-toolbar .icon-btn .icon {
  width: 19px;
  height: 19px;
}

.reader-top-navigation {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 4px;
  height: 38px;
}

.reader-top-navigation .icon-btn {
  border: 0;
  background: none;
  box-shadow: none;
  backdrop-filter: none;
  width: 30px;
  color: #806493;
}

.reader-chapter-picker {
  min-width: 42px;
  padding: 6px 14px;
  border-radius: 15px;
  border: 1px solid #a78bc64d;
  background: #6b52797a;
  color: white;
  font: 15px/1.2 RobotoReader,sans-serif;
  backdrop-filter: blur(16px);
}

.reader-tools {
  display: flex;
  flex-direction: column;
  gap: 7px;
  align-items: end;
}

.reader-body {
  width: min(740px,calc(100% - 48px));
  padding: 70px 0 45px;
  min-height: 100vh;
}

.reader-body h1 {
  font-family: var(--reader-font,RobotoReader,sans-serif);
  font-weight: 600;
  font-size: calc(var(--reader-size,16.5px) + 4px);
  line-height: 1.3;
  text-align: center;
  margin: 0 20px 26px;
  color: inherit;
}

.reader-text {
  font-family: var(--reader-font,RobotoReader,sans-serif);
  font-size: var(--reader-size,16.5px);
  line-height: var(--reader-line,1.62);
  color: inherit;
}

.reader-text p {
  margin: 0 0 1em;
  white-space: pre-wrap;
}

.reader-text h2 {
  font-family: inherit;
  font-size: 1.15em;
  line-height: 1.4;
  margin: 1.2em 0 .6em;
}

.reader-text hr {
  border: 0;
  height: 1px;
  background: linear-gradient(90deg,transparent,#9a8aaa88,transparent);
}

.reader-figure {
  margin: 22px 0;
}

.reader-figure img {
  width: 100%;
  height: auto;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 10px;
}

.reader-image-zoom {
  display: block;
  width: 100%;
  padding: 0;
  cursor: zoom-in;
}

.reader-figure img[hidden],
.reader-image-error[hidden] {
  display: none;
}

.reader-figure figcaption {
  text-align: center;
  font-size: 13px;
  line-height: 1.5;
  margin-top: 6px;
  opacity: .75;
}

.reader-image-error {
  font: 13px/1.5 Manrope,sans-serif;
  text-align: center;
  opacity: .6;
  padding: 35px 10px;
}

.reader-table {
  max-width: 100%;
  overflow-x: auto;
  margin: 1em 0;
}

.reader-table table {
  border-collapse: collapse;
  width: 100%;
  font-size: .9em;
}

.reader-table td {
  border: 1px solid #9a8aaa77;
  padding: 8px;
  min-width: 80px;
}

.reader-list-item {
  position: relative;
  white-space: pre-wrap;
  margin: 0 0 .5em;
  padding-left: 1.2em;
}

.reader-list-marker {
  margin-right: .6em;
}

.reader-nav {
  justify-content: center;
  gap: 22px;
  border: 0;
  position: relative;
  padding: 22px 0;
  margin-top: 32px;
}

.reader-nav:before,
.reader-nav:after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,transparent,#9a8aaa88,transparent);
}

.reader-nav:before {
  top: 0;
}

.reader-nav:after {
  bottom: 0;
}

.reader-nav .icon-btn {
  background: none;
  border: 0;
  color: #806493;
  width: 40px;
  height: 40px;
}

.reader-nav .reader-chapter-picker {
  background: none;
  border: 0;
  color: #806493;
  font-weight: 600;
  font-size: 18px;
}

.reader-book-link {
  display: block;
  text-align: center;
  font: 12px/1.5 Manrope,sans-serif;
  opacity: .65;
  margin-top: 22px;
}

.reader-progress {
  top: auto;
  bottom: 0;
  height: 3px;
  background: #7047ff;
  z-index: 30;
}

.reading[data-reader-theme="night"] .reader-top-navigation .icon-btn,
.reading[data-reader-theme="night"] .reader-nav .icon-btn,
.reading[data-reader-theme="night"] .reader-nav .reader-chapter-picker {
  color: #c5b7dc;
}

.reader-sheet {
  width: min(460px,calc(100vw - 24px));
  max-height: min(80vh,760px);
  border: 1px solid #ffffff20;
  border-radius: 22px;
  background: #151b2e;
  color: #eeeaf7;
  padding: 24px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.reader-sheet h2 {
  font: 600 21px/1.3 Manrope,sans-serif;
  margin: 0 35px 12px 0;
}

.reader-sheet .sheet-subtitle {
  font: 12px/1.5 Manrope,sans-serif;
  color: #ada5be;
  margin: 0 0 16px;
}

.reader-sheet .close {
  width: 30px;
  height: 30px;
  top: 15px;
  right: 15px;
}

.reader-sheet .settings-field {
  margin: 22px 0;
}

.reader-sheet .theme-options {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 8px;
}

.reader-sheet .theme-button {
  padding: 10px 5px;
  font-size: 12px;
}

.reader-font-options {
  display: flex;
  gap: 8px;
}

.reader-font-options button {
  flex: 1;
  border: 1px solid #ffffff22;
  border-radius: 9px;
  padding: 9px 4px;
  font-size: 13px;
}

.reader-font-options button:nth-child(1) {
  font-family: RobotoReader,sans-serif;
}

.reader-font-options button:nth-child(2) {
  font-family: Lora,serif;
}

.reader-font-options button:nth-child(3) {
  font-family: Kalam,cursive;
}

.reader-font-options button.selected {
  background: #7047ff44;
  border-color: #ac89ff;
}

.reader-sheet>.btn.primary {
  width: 100%;
  background: #7047ff;
  min-height: 42px;
}

.reader-chapter-options {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 7px;
}

.reader-chapter-options a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 9px;
  border: 1px solid #ffffff10;
  border-radius: 10px;
  font-size: 13px;
}

.reader-chapter-options a>span:first-child {
  color: #b394f3;
  min-width: 25px;
}

.reader-chapter-options a>span:nth-child(2) {
  flex: 1;
  overflow-wrap: anywhere;
}

.reader-chapter-options a.current {
  border-color: #ab88ff;
  background: #7047ff22;
}

.reader-marks {
  margin-top: 15px;
}

.reader-marks>div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #ffffff15;
}

.reader-marks>.p {
  font-size: 13px;
}

.reader-marks>div>.btn {
  font-size: 12px;
  border: 0;
  background: none;
}

.reader-marks .icon-btn {
  width: 30px;
  height: 30px;
}

.reader-marks>p {
  font-size: 13px;
  color: #b7adc8;
}

#reader-image {
  width: min(900px,calc(100vw - 24px));
}

#reader-image>img {
  max-height: 65vh;
  max-width: 100%;
  margin: auto;
  object-fit: contain;
  border-radius: 10px;
}

@media (max-width:700px) {
  .reader-body {
    width: calc(100% - 48px);
    padding-top: 68px;
  }
  .reader-body h1 {
    font-size: calc(var(--reader-size,16.5px) + 4px);
  }
  .app-reader-toolbar {
    padding: 6px 10px;
    gap: 0;
  }
  .app-reader-toolbar .icon-btn {
    width: 38px;
    height: 38px;
  }
  .reader-sheet {
    margin: auto auto 0;
    width: 100%;
    max-height: 78vh;
    border-radius: 22px 22px 0 0;
    padding: 22px 20px calc(20px + env(safe-area-inset-bottom));
  }
  .reader-sheet::backdrop {
    background: #0008;
    backdrop-filter: blur(3px);
  }
  .reader-progress {
    left: 24px;
    max-width: calc(100% - 48px);
  }
}

.reader-text a {
  color: #2675b8;
  text-decoration: underline;
}

.reading[data-reader-theme="night"] .reader-text a {
  color: #8fd8ff;
}

.reader-toolbar .icon-btn:disabled {
  cursor: default;
  opacity: .35;
}

/* Bare reader icons; one tap on the reading area toggles the widgets. */

.app-reader-toolbar,
.app-reader-toolbar .icon-btn,
.reader-tools .icon-btn,
.reader-top-navigation .reader-chapter-picker {
  background: transparent;
  border: 0;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.reader-top-navigation .reader-chapter-picker {
  color: #806493;
}

.reading[data-reader-theme="night"] .reader-top-navigation .reader-chapter-picker {
  color: #c5b7dc;
}

.reader-controls-hidden .app-reader-toolbar,
.reader-controls-hidden .reader-progress,
.reader-controls-hidden .reader-widget {
  visibility: hidden;
  pointer-events: none;
}

.reader-heart {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 24px 0 0;
  margin-top: 25px;
  position: relative;
  color: #c96592;
  font: 13px/1.4 RobotoReader,sans-serif;
}

.reader-heart:before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,transparent,#9a8aaa88,transparent);
}

.reader-heart-button {
  display: grid;
  place-items: center;
  width: 54px;
  height: 48px;
  color: #c96592;
  padding: 0;
}

.reader-heart-button .icon {
  width: 31px;
  height: 31px;
  stroke-width: 1.5;
}

.reader-heart-button.liked .icon {
  fill: currentColor;
}

.reader-discussion {
  margin-top: 25px;
  border: 1px solid #b199ce44;
  background: #262136ed;
  border-radius: 22px;
  padding: 16px;
  color: #eeeaf7;
  font-family: RobotoReader,Manrope,sans-serif;
}

.reader-discussion-heading {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 13px;
}

.reader-discussion-heading h2 {
  flex: 1;
  font: 500 16px/1.4 RobotoReader,sans-serif;
  margin: 0;
}

.reader-discussion-heading .icon-btn {
  width: 30px;
  height: 30px;
  background: none;
  border: 0;
  color: #c6b7db;
}

.reader-discussion-heading .icon {
  width: 18px;
  height: 18px;
}

.reader-discussion-heading select {
  max-width: 100px;
  border: 1px solid #bfa7e344;
  border-radius: 13px;
  background: #8a65ad22;
  color: #e8deff;
  font-size: 11px;
  padding: 7px;
}

.reader-discussion-heading option {
  background: #262136;
}

.reader-discussion .review-sign-in {
  background: transparent;
  margin: 0;
  padding: 0;
  border: 0;
}

.reader-discussion .review-sign-in .btn {
  background: #7047ff;
}

.reader-discussion .review-composer {
  background: #ffffff05;
  border-color: #bfa7e333;
}

.reader-discussion .review-comments {
  gap: 17px;
}

.reader-discussion .review-comment-main>p {
  font: 13px/1.4 RobotoReader,sans-serif;
  margin: 4px 0;
}

.reader-discussion .reader-discussion-status,
.reader-discussion-error {
  font-size: 12px;
  line-height: 1.5;
  margin-top: 12px;
  color: #cfc2df;
}

.reader-discussion-error {
  color: #f4cf55;
}

.reader-controls-hidden .reader-discussion {
  visibility: visible;
  pointer-events: auto;
}

.reader-controls-hidden .reader-widget {
  display: none;
}

/* Small individual capsules for the reader controls. */

.app-reader-toolbar>.icon-btn,
.reader-tools>.icon-btn,
.reader-top-navigation>.reader-chapter-picker {
  background: #6b52794d;
  border: 1px solid #9c85bf44;
  box-shadow: inset 0 1px #ffffff44;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.reader-top-navigation>.reader-chapter-picker {
  color: #fff;
  border-radius: 15px;
}

.app-reader-toolbar>.icon-btn,
.reader-tools>.icon-btn {
  border-radius: 19px;
}

.reading[data-reader-theme="night"] .reader-top-navigation>.reader-chapter-picker {
  color: #fff;
}

/* A smaller home introduction without the cover caption or genre strip. */

.hero-copy h1 {
  font-size: 56px;
}

.hero-buttons .btn {
  font-size: 12px;
  padding: 10px 16px;
}

.hero-books {
  transform: scale(.88);
  transform-origin: center;
  height: 310px;
}

.home-content>.continue:first-child {
  margin-top: 26px;
}

@media (max-width:1050px) and (min-width:701px) {
  .hero-copy h1 {
    font-size: 48px;
  }
  .hero-books {
    transform: scale(.72);
    height: 290px;
  }
}

@media (max-width:700px) {
  .hero-copy h1 {
    font-size: 46px;
  }
  .hero-copy>p {
    margin: 16px 0 18px;
  }
  .hero-buttons {
    gap: 9px;
  }
  .hero-buttons .btn {
    font-size: 11px;
    padding: 9px 13px;
  }
  .hero-note {
    margin-top: 14px;
  }
  .hero-books {
    height: 230px;
    transform: scale(.66);
    margin: -10px -15px -22px;
  }
  .hero-inner {
    padding-top: 30px;
    padding-bottom: 24px;
  }
}

.book-author-identity {
  display: flex;
  align-items: center;
  gap: 15px;
  flex: 1;
  min-width: 0;
}

.book-author-identity>div {
  min-width: 0;
}

.author-follow-button {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 39px;
  height: 39px;
  border-radius: 50%;
  color: #e9dcff;
  background: #7f50d955;
  border: 1px solid #bc9aff;
}

.author-follow-button .icon {
  width: 22px;
  height: 22px;
}

.author-follow-button.following {
  color: #91e7d0;
  background: #26c6a433;
  border-color: #73dcc3;
}

.author-follow-button:disabled {
  cursor: default;
}

.public-author {
  max-width: 1000px;
  margin: 0 auto 60px;
  background: #050817;
  min-height: 65vh;
}

.public-author-hero {
  padding: 22px 24px 14px;
  background: linear-gradient(180deg,#0003,#05081788 55%,#050817),url("assets/author_create_bg.png") center top/cover;
}

.public-author-hero>.icon-btn {
  background: #10172988;
  margin-bottom: 20px;
}

.public-author-identity {
  display: flex;
  align-items: center;
  gap: 24px;
}

.public-author-identity h1 {
  font-family: Playfair,Georgia,serif;
  font-weight: 400;
  font-size: 32px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.public-author-identity>div {
  min-width: 0;
}

.public-author-identity p {
  font-size: 14px;
  color: #d4cadd;
  margin-top: 6px;
  overflow-wrap: anywhere;
}

.public-author-bio {
  font-family: CormorantText,Georgia,serif;
  font-size: 22px;
  line-height: 1.4;
  margin-top: 14px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.public-author-metrics {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 12px;
  margin: 24px 0 18px;
}

.public-author-metrics>div>span {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 16px;
}

.public-author-metrics small {
  font-family: CormorantText,Georgia,serif;
  font-size: 16px;
  color: #c5bacf;
}

.public-author-metrics .icon {
  width: 21px;
  height: 21px;
}

.author-follow-full.btn {
  width: 100%;
  border-radius: 22px;
  background: linear-gradient(110deg,#aa4aff,#536cff);
  font-family: Cormorant,Georgia,serif;
  font-size: 20px;
  min-height: 40px;
  padding: 8px;
}

.author-follow-full.following {
  background: linear-gradient(110deg,#aa4aff,#536cff);
}

.public-author-tabs {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 5px;
  margin: 0 16px;
  background: #101729ee;
  border: 1px solid #ffffff14;
  border-radius: 11px;
  padding: 3px 8px;
}

.public-author-tabs button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 12px 2px;
  font-family: Cormorant,Georgia,serif;
  font-size: 20px;
  line-height: 1.2;
  font-variant-numeric: lining-nums tabular-nums;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
}

.public-author-tabs button.active {
  border-bottom-color: #b793ff;
}

.public-author-tabs .icon {
  width: 17px;
  height: 17px;
}

.public-author-content {
  padding: 20px;
}

.public-author-books {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 24px 18px;
}

.public-author-book {
  min-width: 0;
}

.public-author-book>img {
  width: 100%;
  aspect-ratio: 2/3;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid #5f4c8266;
}

.public-author-book h3 {
  font-family: CormorantText,Georgia,serif;
  font-size: 21px;
  font-weight: 400;
  line-height: 1.2;
  margin: 7px 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.public-author-book>div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 7px;
  font-size: 12px;
}

.public-author-book>div>span {
  display: flex;
  align-items: center;
  gap: 4px;
}

.public-author-book .icon {
  width: 15px;
  height: 15px;
  color: #c49cef;
}

.public-author-book .rating .icon {
  color: #ffba74;
}

.public-author-empty {
  font-size: 14px;
  line-height: 1.6;
  text-align: center;
  color: #b4a9c1;
  padding: 30px 8px;
}

.public-author-empty .btn {
  margin-top: 12px;
}

@media (max-width:700px) {
  .public-author-hero {
    padding: 18px 18px 12px;
  }
  .public-author-identity {
    gap: 20px;
  }
  .public-author-identity h1 {
    font-size: 26px;
  }
  .public-author-metrics {
    gap: 6px;
  }
  .public-author-metrics>div>span {
    font-size: 14px;
    gap: 5px;
  }
  .public-author-metrics small {
    font-size: 14px;
  }
  .public-author-metrics .icon {
    width: 19px;
    height: 19px;
  }
  .public-author-tabs {
    margin: 0 12px;
    gap: 3px;
    padding: 3px 6px;
  }
  .public-author-tabs button {
    font-size: 17px;
    gap: 4px;
  }
  .public-author-tabs .icon {
    width: 15px;
    height: 15px;
  }
  .public-author-content {
    padding: 16px 20px;
  }
  .public-author-books {
    grid-template-columns: repeat(3,minmax(0,1fr));
    gap: 20px 12px;
  }
  .public-author-book h3 {
    font-size: 17px;
  }
  .public-author-book>div {
    font-size: 11px;
  }
  .public-author-book .icon {
    width: 13px;
    height: 13px;
  }
  .book-author-identity {
    gap: 14px;
  }
}

.book-top-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 22px;
}

.book-top-controls .book-back {
  margin-bottom: 0;
}

.book-favorite.icon-btn {
  width: 40px;
  height: 40px;
  background: #10182a88;
  border: 1px solid #ffffff22;
  border-radius: 50%;
  color: #eeeaf7;
}

.book-favorite .icon {
  width: 23px;
  height: 23px;
}

.book-favorite.selected {
  color: #f393bd;
}

.book-favorite.selected .icon {
  fill: currentColor;
}

#library-sheet {
  max-height: 72vh;
  background: linear-gradient(135deg,#252640f5,#0b1220f7);
  backdrop-filter: blur(14px);
}

#library-sheet h2 {
  font: 600 25px/1.2 Cormorant,Georgia,serif;
}

.library-choice {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  margin: 0 0 6px;
  border-radius: 13px;
  background: linear-gradient(110deg,#2f3a5238,#2f3a5222);
  border: 1px solid #ffffff1f;
  text-align: left;
}

.library-choice.selected {
  background: linear-gradient(110deg,#4f367f66,#26284d44);
  border-color: #ac87ff;
  box-shadow: 0 0 8px #8a55ff22;
}

.library-choice-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: #ffffff14;
  flex-shrink: 0;
}

.library-choice.selected .library-choice-icon {
  background: #5e3da599;
}

.library-choice-icon .icon {
  width: 23px;
  height: 23px;
}

.library-choice-copy {
  flex: 1;
  min-width: 0;
}

.library-choice strong {
  display: block;
  font: 400 20px/1.15 CormorantText,Georgia,serif;
  overflow-wrap: anywhere;
}

.library-choice small {
  display: block;
  font: 400 14px/1.3 CormorantText,Georgia,serif;
  color: #dcdaec;
  margin-top: 3px;
}

.library-choice-check {
  display: grid;
  place-items: center;
  color: #958cb9;
}

.library-choice-check .icon {
  width: 23px;
  height: 23px;
}

.library-choice.selected .library-choice-check {
  color: #bc9aff;
}

.library-error {
  font-size: 12px;
  line-height: 1.5;
  color: #f4cf55;
  margin: 10px 0;
}

.library-status {
  font-size: 12px;
  line-height: 1.5;
  color: #c8b5e4;
  margin-top: 10px;
}

.library-folder-input {
  width: 100%;
  background: #ffffff08;
  color: #fff;
  border: 1px solid #ffffff30;
  border-radius: 10px;
  padding: 12px;
  font: 14px Manrope,sans-serif;
}

#library-folder-create form>.btn {
  width: 100%;
  margin-top: 12px;
}

@media (max-width:700px) {
  .book-top-controls {
    margin-bottom: 18px;
  }
  .book-favorite.icon-btn {
    width: 38px;
    height: 38px;
  }
  .library-choice strong {
    font-size: 19px;
  }
  .library-choice small {
    font-size: 13px;
  }
}

/* Catalog scenery stays local to this route, including after reader theme changes. */

.catalog-scene {
  position: relative;
  isolation: isolate;
  min-height: calc(100vh - 80px);
  padding-bottom: 32px;
  background: linear-gradient(#0b0b1640,#0b0b1670),url("assets/home_recommendations_space.jpg") center top/cover;
}

.catalog-scene:before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 510px;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(180deg,#0b0b1618 0%,#0b0b1666 60%,#0b0b1600 100%),url("assets/search_header_bg.jpg") center 35%/cover;
  mask-image: linear-gradient(#000 65%,transparent);
}

.catalog-page .page-intro {
  text-shadow: 0 2px 14px #000;
}

.catalog-page .page-intro p {
  color: #d2c9e1;
}

.catalog-page .search-box,
.catalog-page .select {
  background: #111323e8;
}

.catalog-page .genre-bar {
  background: #0b0b1670;
  border-radius: 12px;
}

.catalog-page .genre-bar button {
  background-color: #0b0b16c9;
}

.catalog-page .result-count {
  color: #cec2df;
}

@media (max-width:700px) {
  .catalog-scene:before {
    height: 420px;
  }
  .catalog-scene {
    background-size: auto 1100px;
    background-repeat: repeat-y;
  }
}

/* App-style navigation, with space for content and device safe areas. */

body:not(.reading) {
  padding-bottom: calc(94px + env(safe-area-inset-bottom,0px));
}

#bottom-nav {
  position: fixed;
  bottom: calc(12px + env(safe-area-inset-bottom,0px));
  left: 50%;
  transform: translateX(-50%);
  z-index: 45;
  display: grid;
  align-items: center;
  border: 1px solid #b9a2f52e;
  box-shadow: 0 6px 30px #0006;
  backdrop-filter: blur(18px);
}

#bottom-nav a {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font: 11px Manrope,sans-serif;
  border-radius: 25px;
  transition: color .2s,background .2s;
}

#bottom-nav a .icon {
  width: 24px;
  height: 24px;
}

#bottom-nav a.active .icon {
  filter: drop-shadow(0 0 7px #a35bff66);
}

#bottom-nav a:hover {
  color: #d4baff;
}

#bottom-nav a:focus-visible {
  outline: 2px solid #c5a0ff;
  outline-offset: -5px;
}

.reading #bottom-nav {
  display: none;
}

@media (max-width:700px) {
  #header .nav {
    display: none;
  }
  #header .header-actions {
    margin-left: auto;
  }
}

/* Five-slot navigation follows the mobile app reference. */

#bottom-nav {
  grid-template-columns: repeat(5,minmax(0,1fr));
  height: 80px;
  border-radius: 29px;
  width: min(560px,calc(100% - 28px));
  background: linear-gradient(110deg,#191923f7,#151620f7);
}

#bottom-nav a {
  gap: 8px;
  font-size: 11px;
  color: #96929f;
}

#bottom-nav a.active {
  background: none;
  color: #a855f7;
}

#bottom-nav .bottom-create {
  align-self: center;
  justify-self: center;
  width: 76px;
  height: 76px;
  margin-top: -9px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(115deg,#ae47ff,#6269ff);
  border: 1px solid #cca5ff;
  box-shadow: 0 0 22px #9838ff33;
  color: white;
  cursor: pointer;
}

#bottom-nav .bottom-create .icon {
  width: 34px;
  height: 34px;
  stroke-width: 2.6;
}

#bottom-nav .bottom-create:hover {
  filter: brightness(1.12);
}

#bottom-nav .bottom-create:focus-visible {
  outline: 2px solid white;
  outline-offset: 3px;
}

@media (max-width:700px) {
  #bottom-nav {
    height: 76px;
  }
  #bottom-nav .bottom-create {
    width: 66px;
    height: 66px;
    margin-top: -9px;
  }
  #bottom-nav a {
    font-size: 11px;
  }
  #bottom-nav a .icon {
    width: 23px;
    height: 23px;
  }
}

/* Branded page header and the app notification inbox. */

#header {
  position: relative;
  top: auto;
  z-index: 50;
  backdrop-filter: blur(18px);
  border-bottom-color: #c9adff2b;
}

.header-actions .header-notifications,
.header-actions .header-search {
  position: relative;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid #9f9bbe77;
  background: linear-gradient(130deg,#4a456570,#202b4650,#372d5060);
  color: #f4efff;
  flex-shrink: 0;
}

.header-actions .icon {
  width: 21px;
  height: 21px;
}

.notification-count {
  position: absolute;
  right: -2px;
  top: -3px;
  min-width: 16px;
  padding: 1px 4px;
  border-radius: 9px;
  border: 1px solid #e2d5ff;
  background: #ad84ff;
  color: white;
  font: 700 9px Manrope,sans-serif;
  text-align: center;
}

.notification-count[hidden] {
  display: none;
}

.notifications-scene {
  min-height: calc(100vh - 88px);
  background: linear-gradient(#03050dcc,#03050dcc),url("assets/home_recommendations_space.jpg") center top/cover;
  padding: 8px 0 40px;
}

.notifications-wrap {
  max-width: 720px;
  margin: auto;
  padding: 0 14px;
}

.notification-heading {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 0 14px;
}

.notification-heading h1 {
  font: 600 18px Manrope,sans-serif;
  flex: 1;
  min-width: 0;
}

.notification-heading .btn.notification-back {
  padding: 10px;
  border-radius: 18px;
  background: #191c2ce6;
}

.notification-heading .icon-btn {
  width: 33px;
  height: 33px;
  flex-shrink: 0;
}

.notification-heading .notification-mark {
  font-size: 11px;
  gap: 5px;
  padding: 8px 10px;
  border-radius: 18px;
  background: linear-gradient(110deg,#7351ce,#4267b0);
  border-color: #8faaee66;
  color: #e8dfff;
}

.notification-mark .icon {
  width: 15px;
  height: 15px;
}

.notification-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.notification-card,
.notification-group-heading {
  width: 100%;
  text-align: left;
  border: 1px solid #ffffff25;
  border-radius: 18px;
  background: linear-gradient(135deg,#ffffff0f,transparent),#191c2ce6;
  color: white;
  display: flex;
  align-items: center;
  padding: 11px 12px;
  gap: 10px;
  min-width: 0;
}

.notification-card {
  cursor: pointer;
  font-family: Manrope,sans-serif;
}

.notification-card.unread {
  background: linear-gradient(135deg,#ffffff0f,transparent),#241d38e6;
  border-color: #7f6aab42;
}

.notification-avatar {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  position: relative;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: color-mix(in srgb,var(--notice-accent),transparent 85%);
  color: var(--notice-accent);
}

.notification-avatar>img {
  width: 40px;
  height: 40px;
  object-fit: cover;
  border-radius: 50%;
}

.notification-avatar>.icon {
  width: 21px;
  height: 21px;
}

.notification-kind {
  position: absolute;
  right: -1px;
  bottom: -1px;
  width: 16px;
  height: 16px;
  display: grid;
  place-items: center;
  background: var(--notice-accent);
  border: 1.5px solid #1c1a2d;
  border-radius: 50%;
  color: white;
}

.notification-kind .icon {
  width: 9px;
  height: 9px;
}

.notification-copy {
  flex: 1;
  min-width: 0;
  display: block;
}

.notification-line {
  display: flex;
  align-items: start;
  gap: 5px;
}

.notification-line strong {
  font-size: 12.5px;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.notification-line time {
  font-size: 11px;
  line-height: 1.6;
  white-space: nowrap;
  color: #ada7bb;
}

.notification-title {
  display: block;
  font-size: 11px;
  color: var(--notice-accent);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-top: 1px;
}

.notification-body {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: #ddd9e6;
  font-size: 11.5px;
  line-height: 1.35;
  margin-top: 3px;
  overflow-wrap: anywhere;
}

.notification-cover {
  width: 44px;
  height: 62px;
  object-fit: cover;
  border-radius: 6px;
  flex-shrink: 0;
}

.notification-dot {
  width: 5px;
  height: 5px;
  flex-shrink: 0;
  border-radius: 50%;
  background: #bc95ff;
}

.notification-group-label {
  display: flex;
  gap: 5px;
  align-items: center;
  font-size: 11px;
  color: #c6aaff;
  margin-top: 7px;
}

.notification-group-label .icon {
  width: 12px;
  height: 12px;
}

.notification-group-label .icon:last-child {
  margin-left: auto;
  width: 17px;
  height: 17px;
}

.notification-swipe {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  isolation: isolate;
}

.notification-front {
  position: relative;
  transition: transform .18s;
  touch-action: pan-y;
  z-index: 1;
}

.notification-front.dragging {
  transition: none;
  user-select: none;
}

.notification-delete {
  position: absolute;
  inset: 0 0 0 auto;
  border: 0;
  border-radius: 18px;
  background: #d93d55;
  color: white;
  padding: 10px;
  font: 600 12px Manrope;
  cursor: pointer;
}

.notification-delete[hidden] {
  display: none;
}

.notification-menu {
  position: absolute;
  bottom: 0;
  right: 1px;
  width: 26px;
  height: 22px;
  color: #ada7bb;
  background: #191c2ce6;
  border: 0;
  border-radius: 9px;
  z-index: 2;
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
}

.notification-group {
  position: relative;
  margin-bottom: 7px;
  scroll-margin-top: 110px;
}

.notification-group:not(.expanded):before,
.notification-group:not(.expanded):after {
  content: "";
  position: absolute;
  inset: 5px 7px -5px;
  border-radius: 18px;
  border: 1px solid #d5c5ef24;
  background: #282338;
}

.notification-group:not(.expanded):before {
  inset: 10px 14px -10px;
  background: #1c1d2d;
}

.notification-group>.notification-swipe {
  z-index: 1;
}

.notification-group.expanded {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.notification-group-heading {
  padding: 9px 10px;
  font: 600 12.5px Manrope;
  gap: 8px;
}

.notification-group-heading>span {
  flex: 1;
  min-width: 0;
}

.notification-group-heading strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.notification-group-heading small {
  display: block;
  font-size: 11px;
  color: #ffffff88;
  font-weight: 400;
  margin-top: 2px;
}

.notification-collapse.btn {
  border-radius: 20px;
  background: #bea2eb1c;
  border-color: #d5bfff30;
  color: #e1d7f6;
  font-size: 11px;
  padding: 6px 10px;
  min-height: 32px;
  white-space: nowrap;
  align-self: flex-end;
}

.notification-collapse .icon {
  transform: rotate(180deg);
  width: 17px;
  height: 17px;
}

.notification-empty {
  text-align: center;
  padding: 70px 25px;
  color: #b7b2c5;
  font: 12px/1.6 Manrope;
}

.notification-empty>.icon {
  width: 34px;
  height: 34px;
  margin: 0 auto 14px;
}

.notification-empty h2 {
  font: 500 16px Manrope;
  color: white;
  margin-bottom: 8px;
}

.notification-empty .btn {
  margin-top: 18px;
}

.notification-status {
  text-align: center;
  padding: 20px;
  font-size: 12px;
  color: #c4bad7;
}

.notification-undo {
  position: sticky;
  bottom: 100px;
  background: #242036;
  box-shadow: 0 3px 16px #0006;
  z-index: 5;
  padding: 6px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
}

.notification-undo[hidden] {
  display: none;
}

.notification-undo .btn {
  color: #cfb1ff;
  border: 0;
  background: none;
}

@media (max-width:700px) {
  .header-inner {
    gap: 12px;
  }
  .header-actions {
    gap: 9px;
  }
  .header-actions .header-search,
  .header-actions .header-notifications {
    width: 37px;
    height: 37px;
  }
  .notification-heading {
    gap: 7px;
  }
  .notification-heading h1 {
    font-size: 17px;
  }
  .notification-heading .notification-mark {
    padding: 8px;
    font-size: 11px;
  }
}

.book-tabs,
.review-comment,
.reader-discussion {
  scroll-margin-top: 100px;
}

.notification-target {
  outline: 1px solid #b78fff;
  box-shadow: 0 0 18px #a668ff26;
}

.notification-replies.reader-sheet {
  background: linear-gradient(130deg,#1c2035f5,#16162af7);
  color: #eee8fa;
  max-height: 90vh;
  width: min(620px,100%);
  border-radius: 24px 24px 0 0;
  font: 13px/1.4 Manrope,sans-serif;
}

.notification-replies-title {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-right: 22px;
  margin-bottom: 12px;
}

.notification-replies-title h2 {
  flex: 1;
  font: 600 18px Manrope;
  margin: 0;
}

.notification-reply {
  display: flex;
  gap: 9px;
  background: #1c254055;
  border: 1px solid #ffffff20;
  border-radius: 14px;
  padding: 12px;
  margin: 10px 0;
  scroll-margin: 14px;
}

.notification-reply-copy {
  min-width: 0;
  flex: 1;
  overflow-wrap: anywhere;
}

.notification-reply-copy>strong {
  font-size: 13px;
  color: white;
}

.notification-reply-copy>p {
  font: 13px/1.4 Manrope;
  margin: 6px 0;
  white-space: pre-wrap;
}

.notification-reply-copy small {
  color: #a99cb9;
  font-size: 11px;
}

.notification-reply-copy .btn {
  border: 0;
  background: none;
  padding: 4px 10px;
  color: #d1b9ff;
  font-size: 11px;
}

.notification-reply blockquote {
  border-left: 2px solid #a98bd4;
  padding: 5px 10px;
  margin: 7px 0;
  background: #b899e814;
  font-size: 11px;
}

.notification-reply blockquote p {
  font: 12px/1.4 Manrope;
  margin: 2px 0;
}

.notification-reply-compose {
  position: sticky;
  bottom: -24px;
  display: flex;
  align-items: end;
  gap: 8px;
  padding: 12px 0;
  background: #1b1d32;
}

.notification-reply-compose textarea {
  min-width: 0;
  flex: 1;
  background: #101528;
  color: #eee8fa;
  border: 1px solid #a68dce55;
  border-radius: 10px;
  padding: 10px;
  resize: vertical;
  font: 13px Manrope;
}

.notification-reply-compose .btn {
  font-size: 12px;
  padding: 10px;
}

/* Slim header: search first, notification bell at the right edge. */

#header {
  height: 64px;
}

#header .brand img {
  width: 31px;
  height: 31px;
  border-radius: 9px;
}

#header .brand span {
  font-size: 29px;
}

#header .header-actions .header-search,
#header .header-actions .header-notifications {
  width: 34px;
  height: 34px;
}

#header .header-actions .icon {
  width: 19px;
  height: 19px;
}

@media (max-width:700px) {
  #header {
    height: 56px;
  }
  #header .brand span {
    font-size: 28px;
  }
  #header .header-actions {
    gap: 9px;
  }
}

/* Distinct jewel-toned header, separate from the illustrated page backdrop. */

#header {
  background: radial-gradient(ellipse at 8% 0%,#9d64e53d,transparent 55%),linear-gradient(110deg,#302047f5 0%,#252d50f5 55%,#183745f5 100%);
  border-bottom: 1px solid #b99be866;
  box-shadow: 0 3px 20px #08091a55,inset 0 -1px 0 #e3ceff12;
}

#header .header-actions .header-search,
#header .header-actions .header-notifications {
  background: #100f263d;
  border-color: #d0b9ed66;
}

/* Top 100 mirrors the Flutter ranking screen and uses its server ranking RPC. */

.top100-scene {
  position: relative;
  isolation: isolate;
  min-height: calc(100vh - 56px);
  background: linear-gradient(#05081740,#05081765),url("assets/home_recommendations_space.jpg") center top/cover;
  padding: 4px 0 30px;
}

.top100-scene:before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 230px;
  background: url("assets/search_header_bg.jpg") center top/cover;
  mask-image: linear-gradient(#000 20%,transparent);
  pointer-events: none;
  z-index: -1;
}

.top100-wrap {
  max-width: 850px;
  margin: auto;
  padding: 0 14px;
}

.top100-heading {
  padding: 0 4px;
}

.top100-heading h1 {
  font: 700 36px/1.3 Playfair,Georgia,serif;
  letter-spacing: -.02em;
  margin: 0;
}

.top100-heading h1 span {
  color: #b793ff;
}

.top100-heading p {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #b7aec9;
  font: 13px/1.4 Manrope,sans-serif;
  margin: 4px 0 18px;
}

.top100-heading .icon {
  width: 19px;
  height: 19px;
  color: #b793ff;
}

.top100-modes,
.top100-periods {
  display: flex;
  gap: 6px;
  padding: 0 4px;
}

.top100-periods {
  margin-top: 10px;
  margin-bottom: 14px;
}

.top100-filter {
  flex: 1;
  min-width: 0;
  min-height: 40px;
  padding: 10px 7px;
  border: 1px solid #ffffff1f;
  border-radius: 24px;
  background: #101427cc;
  color: white;
  font: 12px Manrope,sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  cursor: pointer;
}

.top100-filter .icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.top100-filter.active {
  background: linear-gradient(110deg,#ad46ff,#596aff);
  border-color: #b397ff;
}

.top100-filter:focus-visible {
  outline: 2px solid #e5d1ff;
  outline-offset: 2px;
}

.top100-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.top100-card {
  display: flex;
  align-items: center;
  gap: 4px;
  min-height: 100px;
  border: 1px solid #5e4b8c44;
  border-radius: 22px;
  background: #0c1022c9;
  padding: 4px 9px;
}

.top100-card.top100-author {
  min-height: 92px;
  padding-block: 8px;
}

.top100-identity {
  display: flex;
  align-items: center;
  flex: 1;
  gap: 10px;
  min-width: 0;
  color: white;
}

.top100-rank {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 32px;
  color: #ffffffb3;
}

.top100-rank .icon {
  width: 27px;
  height: 27px;
}

.top100-rank strong {
  font: 600 23px/1.15 Manrope,sans-serif;
  font-variant-numeric: lining-nums;
}

.top100-rank.rank-1 {
  color: #ffcb62;
}

.top100-rank.rank-2 {
  color: #d6d6ff;
}

.top100-rank.rank-3 {
  color: #ffab82;
}

.top100-cover {
  width: 68px;
  height: 92px;
  flex-shrink: 0;
  border-radius: 10px;
  background: #1b1b34;
  overflow: hidden;
}

.top100-cover>img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.top100-cover .cover-fallback {
  font-size: 11px;
}

.top100-copy {
  flex: 1;
  min-width: 0;
  display: block;
}

.top100-copy>strong {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font: 600 14px/1.15 Manrope,sans-serif;
}

.top100-author .top100-copy>strong {
  display: block;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.top100-copy>small {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font: 12px/1.1 Manrope,sans-serif;
  color: #b7aec9;
  margin-top: 3px;
}

.top100-author .top100-copy>small {
  font-size: 11px;
}

.top100-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin-top: 6px;
}

.top100-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #ffffffb3;
  font: 11px/1.25 Manrope,sans-serif;
  white-space: nowrap;
}

.top100-stat .icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  color: #c4aff3;
}

.top100-stat.green .icon {
  color: #39d98a;
  fill: #39d98a;
}

.top100-library {
  display: grid;
  place-items: center;
  width: 40px;
  height: 44px;
  flex-shrink: 0;
  background: none;
  border: 0;
  color: #b793ff;
  cursor: pointer;
}

.top100-library .icon {
  width: 23px;
  height: 23px;
}

.top100-library.saved .icon {
  fill: #b793ff;
}

.top100-card .author-follow-button {
  width: 34px;
  height: 34px;
  margin: 5px;
  flex-shrink: 0;
}

.top100-card .author-follow-button .icon {
  width: 21px;
  height: 21px;
}

.top100-card .pioneer-avatar {
  margin: 0 7px;
}

.top100-summary {
  margin: 12px 4px 14px;
  padding: 14px;
  background: #17142fde;
  border-radius: 20px;
}

.top100-summary[hidden] {
  display: none;
}

.top100-summary h2 {
  font: 700 16px/1.4 Manrope,sans-serif;
  margin: 0 0 6px;
}

.top100-summary p {
  font: 13px/1.4 Manrope,sans-serif;
  color: #b7aec9;
  margin: 0;
}

.top100-status {
  padding: 32px;
  text-align: center;
  color: #b7aec9;
  font-size: 13px;
}

.top100-status .btn {
  margin-top: 12px;
}

@media (min-width:701px) {
  .top100-wrap {
    padding-top: 18px;
  }
  .top100-heading h1 {
    font-size: 44px;
  }
  .top100-card {
    min-height: 112px;
  }
  .top100-copy>strong {
    font-size: 16px;
  }
}

@media (max-width:380px) {
  .top100-identity {
    gap: 7px;
  }
  .top100-rank {
    width: 25px;
  }
  .top100-card {
    padding-inline: 6px;
  }
  .top100-card .author-avatar {
    --avatar-size: 64px !important;
  }
  .top100-card .author-follow-button {
    margin-inline: 2px;
  }
  .top100-stats {
    gap: 4px 6px;
  }
  .top100-stat {
    font-size: 11px;
  }
  .top100-filter {
    font-size: 11px;
    padding-inline: 4px;
  }
}

/* Personal library: mobile app categories, compact shelves and selected grids. */

.shelf-scene {
  min-height: calc(100vh - 56px);
  background: linear-gradient(#05081745,#05081765),url("assets/home_recommendations_space.jpg") center top/cover;
  padding-bottom: 30px;
}

.shelf-wrap {
  max-width: 850px;
  margin: auto;
  padding-top: 18px;
}

.shelf-heading {
  display: flex;
  align-items: start;
  gap: 16px;
  padding: 0 18px 18px;
}

.shelf-heading>div {
  flex: 1;
}

.shelf-heading h1 {
  font: 700 34px/1 Playfair,Georgia,serif;
  margin: 0 0 6px;
}

.shelf-heading p {
  font: 13px/1.28 Manrope,sans-serif;
  white-space: pre-line;
  color: #b7aec9;
  margin: 0;
}

.shelf-heading .icon-btn {
  width: 42px;
  height: 42px;
  border-radius: 15px;
  background: #15192b8a;
  border-color: #ffffff2e;
}

.shelf-categories {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 0 18px 12px;
}

.shelf-categories::-webkit-scrollbar {
  display: none;
}

.shelf-category {
  position: relative;
  width: clamp(60px,calc((100% - 24px)/5),120px);
  flex-shrink: 0;
  min-height: 62px;
  padding: 16px 6px 10px;
  border: 1px solid #ffffff2e;
  border-radius: 16px;
  background: #15192b8a;
  color: #f4efff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
}

.shelf-category.active {
  background: linear-gradient(110deg,#ad46ff,#596aff);
  border-color: #c6baff88;
  box-shadow: 0 0 10px #7b5cff44;
}

.shelf-category>.icon {
  width: 18px;
  height: 18px;
}

.shelf-category>span {
  font: 500 9px/1.2 Manrope,sans-serif;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.shelf-category.active>span {
  font-weight: 700;
}

.shelf-category>small {
  position: absolute;
  top: 5px;
  right: 7px;
  font: 8px Manrope;
  color: #b4abc8;
}

.shelf-category.active>small {
  color: #ffffff88;
}

.shelf-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 18px 8px;
  gap: 12px;
}

.shelf-section-heading h2 {
  font: 700 18px/1.2 Playfair,Georgia,serif;
  margin: 0;
}

.shelf-section-heading button {
  display: flex;
  align-items: center;
  gap: 3px;
  font: 9.5px Manrope;
  color: #b7aec9;
  padding: 10px 0;
}

.shelf-section-heading .icon {
  width: 13px;
  height: 13px;
}

.shelf-preview {
  margin-bottom: 12px;
}

.shelf-horizontal {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 0 18px 8px;
  scrollbar-width: thin;
  scrollbar-color: #7962a577 transparent;
}

.shelf-book {
  position: relative;
  padding: 7px;
  border: 1px solid #7b5cff33;
  border-radius: 15px;
  background: #12182a7a;
  box-shadow: 0 4px 10px #0002;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.shelf-book.compact {
  width: 92px;
  height: 135px;
  padding: 5px;
  border-radius: 12px;
  flex-shrink: 0;
}

.shelf-book-main {
  display: block;
  min-width: 0;
  color: #f4efff;
}

.shelf-cover {
  position: relative;
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  background: #211b34;
}

.shelf-cover>img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shelf-book.compact .shelf-cover {
  height: 76px;
  aspect-ratio: auto;
  border-radius: 9px;
}

.shelf-book h3 {
  font: 600 12.5px/1.08 Manrope,sans-serif;
  margin: 7px 0 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.shelf-book.compact h3 {
  font-size: 11px;
  margin-top: 5px;
}

.shelf-book-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  margin-top: auto;
  color: #b7aec9;
  font: 10px Manrope;
  min-height: 20px;
}

.shelf-book.compact .shelf-book-footer {
  font-size: 10px;
  min-height: 16px;
}

.shelf-book-footer button {
  height: 18px;
  min-width: 23px;
  font-size: 17px;
  line-height: 1;
}

.shelf-progress {
  height: 2px;
  background: #ffffff18;
  border-radius: 2px;
  overflow: hidden;
}

.shelf-progress>span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg,#b64bff,#626eff);
}

.shelf-favorite {
  position: absolute;
  top: 5px;
  right: 5px;
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  border: 1px solid #ffffff33;
  border-radius: 50%;
  background: #161930b3;
  color: #ff759d;
}

.shelf-favorite .icon {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.shelf-grid {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 10px;
  padding: 12px 18px 18px;
}

.shelf-grid .shelf-book {
  aspect-ratio: 1/1.72;
}

.account-empty {
  font: 13px/1.5 Manrope,sans-serif;
  text-align: center;
  color: #b7aec9;
  padding: 40px 24px;
}

.account-empty>.icon {
  width: 36px;
  height: 36px;
  display: block;
  margin: 0 auto 15px;
  color: #b793ff;
}

.account-empty h1 {
  font: 32px Playfair,Georgia,serif;
  color: #eee8fa;
}

.account-empty h2 {
  font: 700 21px Playfair,Georgia,serif;
  color: #eee8fa;
  margin: 10px 0;
}

.account-empty .btn {
  margin-top: 16px;
}

.account-sheet.reader-sheet {
  background: linear-gradient(130deg,#1a2034f7,#16152bf7);
  color: #eee8fa;
  font: 13px/1.5 Manrope,sans-serif;
}

.account-sheet.reader-sheet h2 {
  font: 600 21px Manrope,sans-serif;
}

.account-sheet>.btn {
  margin-top: 10px;
  margin-right: 8px;
}

.account-sheet .danger {
  color: #ff8aa9;
}

.account-sheet .form-error {
  color: #ffaaa8;
}

.shelf-search-results {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-top: 12px;
}

.shelf-search-results>a,
.shelf-search-results>div {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px;
  border-radius: 13px;
  background: #12192caa;
  text-align: left;
  min-width: 0;
}

.shelf-search-results img {
  width: 40px;
  height: 57px;
  object-fit: cover;
  border-radius: 5px;
  flex-shrink: 0;
}

.shelf-search-results span {
  min-width: 0;
  flex: 1;
}

.shelf-search-results strong {
  display: block;
  font: 600 13px/1.3 Manrope;
  overflow-wrap: anywhere;
}

.shelf-search-results small {
  font: 11px Manrope;
  color: #b7aec9;
}

/* Own profile uses the same banner, portrait, metrics and glass menus as the app. */

.own-profile {
  max-width: 850px;
  margin: auto;
  min-height: calc(100vh - 56px);
  padding-bottom: 50px;
  background: #050817;
}

.own-profile-hero {
  padding: 12px 22px 0;
  background: linear-gradient(180deg,#0000004a,#05081765 48%,#050817da 83%,#050817),url("assets/author_create_bg.png") center top/cover;
}

.own-profile-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.own-profile-title h1 {
  font: 300 24px/1.3 CormorantText,Georgia,serif;
  margin: 0;
}

.own-profile-title .icon-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #19182777;
}

.own-profile-identity {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.own-profile-identity>div {
  min-width: 0;
  flex: 1;
}

.own-profile-identity h2 {
  font: 400 23px/1.15 Playfair,Georgia,serif;
  overflow-wrap: anywhere;
  text-shadow: 0 0 5px #000;
  margin: 0;
}

.own-profile-identity p {
  font: 12px/1.3 Manrope,sans-serif;
  color: white;
  margin: 6px 0 0;
  overflow-wrap: anywhere;
  text-shadow: 0 0 5px #000;
}

.own-profile-identity p.own-profile-bio {
  font: 400 17px/1.25 CormorantText,Georgia,serif;
  margin-top: 7px;
  white-space: pre-wrap;
}

.own-profile-metrics {
  display: grid;
  grid-template-columns: repeat(4,minmax(0,1fr));
  gap: 6px;
  margin: 14px 0 0;
}

.own-profile-metrics>div>span {
  display: flex;
  align-items: center;
  gap: 3px;
  font: 400 17px/1 CormorantText,Georgia,serif;
  color: white;
  white-space: nowrap;
}

.own-profile-metrics .icon {
  width: 18px;
  height: 18px;
}

.own-profile-metrics small {
  font: 400 13px/1 CormorantText,Georgia,serif;
  color: white;
  display: block;
  margin-top: 2px;
}

.own-profile-links {
  display: flex;
  gap: 8px;
  margin-top: 7px;
  flex-wrap: wrap;
}

.own-profile-links a {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 5px 9px;
  border: 1px solid #bda3e333;
  border-radius: 18px;
  background: #20193666;
  font: 11px Manrope;
  color: #c8b4ed;
}

.own-profile-links .icon {
  width: 14px;
  height: 14px;
}

.own-profile-shortcuts {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 7px;
  margin: 14px 14px 10px;
}

.own-profile-shortcuts>button {
  min-width: 0;
  min-height: 94px;
  border: 1px solid #ffffff14;
  border-radius: 17px;
  background: linear-gradient(135deg,#8470c31a,#17192b88);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  color: #e9e2f4;
  padding: 12px 5px;
  font: 11px/1.25 Manrope,sans-serif;
}

.own-profile-shortcuts>button:nth-child(2) {
  transform: translateY(-5px);
}

.own-profile-shortcuts .icon {
  width: 24px;
  height: 24px;
  color: #c6a9f4;
}

.own-profile-shortcuts strong {
  font: 400 18px CormorantText,Georgia,serif;
}

.own-profile-menu {
  margin: 0 14px;
  border-radius: 20px;
  background: linear-gradient(130deg,#ffffff0e,#5b477f0a,#ffffff04);
  border: 1px solid #ffffff0d;
  overflow: hidden;
  backdrop-filter: blur(13px);
}

.account-menu-row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 15px;
  color: #ebe5f3;
  text-align: left;
  padding: 17px 16px;
  font: 13px/1.4 Manrope,sans-serif;
  min-height: 56px;
  border: 0;
  background: transparent;
}

.account-menu-row>span {
  flex: 1;
}

.account-menu-row>.icon:first-child {
  width: 21px;
  height: 21px;
  color: #c9b5e8;
  flex-shrink: 0;
}

.account-menu-row>.icon:last-child {
  width: 17px;
  height: 17px;
  margin-left: auto;
  color: #8f819f;
}

.own-profile-menu .account-menu-row+.account-menu-row {
  border-top: 1px solid #ffffff0b;
}

.account-sheet .account-menu-row {
  border-bottom: 1px solid #ffffff10;
  padding-inline: 5px;
}

.account-sheet textarea.field {
  resize: vertical;
  min-height: 80px;
}

.my-comment-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}

.my-comment-card {
  display: flex;
  align-items: start;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  background: #12192cdd;
  color: white;
  border: 1px solid #ffffff0d;
  text-align: left;
  width: 100%;
}

.my-comment-card>img {
  width: 40px;
  height: 57px;
  object-fit: cover;
  border-radius: 5px;
  flex-shrink: 0;
}

.my-comment-card>span {
  min-width: 0;
  flex: 1;
}

.my-comment-card strong {
  font: 600 13px Manrope;
}

.my-comment-card p {
  font: 13px/1.4 Manrope;
  margin: 4px 0 6px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.my-comment-card small {
  font: 11px Manrope;
  color: #ffffff88;
}

@media (min-width:701px) {
  .shelf-wrap {
    padding-top: 26px;
  }
  .shelf-heading h1 {
    font-size: 40px;
  }
  .shelf-grid {
    grid-template-columns: repeat(5,minmax(0,1fr));
  }
  .own-profile-hero {
    padding: 24px 30px 8px;
  }
  .own-profile-shortcuts,
  .own-profile-menu {
    margin-left: 24px;
    margin-right: 24px;
  }
}

@media (max-width:380px) {
  .own-profile-identity .author-avatar {
    --avatar-size: 96px !important;
  }
  .own-profile-identity h2 {
    font-size: 21px;
  }
  .own-profile-shortcuts>button {
    font-size: 11px;
  }
  .own-profile-hero {
    padding-inline: 18px;
  }
}

/* Shared mobile author experience. */

.author-scene {
  min-height: 75vh;
  background: linear-gradient(#080b20b8,#080b1cf2 450px,#050817 850px),url("assets/author_create_bg.png") center top/cover no-repeat;
  padding: 20px 18px 125px;
  color: #f1edf9;
}

.author-wrap {
  max-width: 680px;
  margin: auto;
}

.author-heading {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-bottom: 22px;
}

.author-heading h1 {
  font: 600 28px/1.15 CormorantText,Georgia,serif;
  margin: 0;
}

.author-heading p {
  font: 12px/1.5 Manrope,sans-serif;
  color: #aaa2bb;
  margin: 6px 0 0;
}

.author-heading .icon-btn {
  flex-shrink: 0;
}

.author-body {
  display: grid;
  gap: 20px;
}

.author-form {
  display: grid;
  gap: 20px;
}

.author-field {
  display: grid;
  gap: 9px;
  min-width: 0;
  font: 600 13px/1.5 Manrope,sans-serif;
  color: #d9d3e7;
}

.author-field .field {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  font: 400 14px/1.6 Manrope,sans-serif;
  color: #eee8f5;
  background: #0d1224;
  border: 1px solid #39425f;
  border-radius: 14px;
  padding: 13px;
}

.author-field textarea {
  resize: vertical;
}

.author-field .field:focus {
  outline: 2px solid #a764ff66;
  border-color: #a764ff;
}

.author-two-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  min-width: 0;
}

.author-media-grid {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 20px;
  align-items: start;
}

.author-media {
  display: grid;
  gap: 9px;
  min-width: 0;
}

.author-media input[type=file] {
  max-width: 100%;
  font: 11px/1.5 Manrope,sans-serif;
  color: #b5a4cc;
}

.author-media-preview {
  border: 1px dashed #9b79c0;
  border-radius: 15px;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: #10182ccc;
  position: relative;
  max-height: 230px;
}

.author-media-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
}

.author-media-preview img[hidden] {
  display: none;
}

.author-media-preview span {
  color: #b8a5cc;
  font: 13px Manrope,sans-serif;
}

.account-sheet>.author-media {
  max-width: 130px;
  margin: 15px auto;
}

.author-genres {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.author-genre {
  border: 1px solid #3b4765;
  background: #10182c80;
  border-radius: 20px;
  color: #c5c9d7;
  padding: 8px 13px;
  font: 12px Manrope,sans-serif;
  cursor: pointer;
}

.author-genre.active {
  background: #372461aa;
  border-color: #a764ff;
  color: white;
}

.author-inline,
.author-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.author-inline>.field {
  flex: 1;
  min-width: 100px;
}

.author-actions .btn {
  min-height: 42px;
  padding: 10px 16px;
  font-size: 13px;
}

.author-save {
  min-height: 52px;
  background: linear-gradient(110deg,#c64bff,#7b3eff,#4d48ff,#4caeff);
  border-radius: 16px;
  font-size: 16px;
}

.author-rights,
.author-book-summary,
.author-block {
  padding: 18px;
  border: 1px solid #ffffff17;
  border-radius: 18px;
  background: #141b31b8;
}

.author-rights {
  display: grid;
  gap: 16px;
}

.author-rights h2,
.author-body>h2 {
  font: 600 24px/1.2 CormorantText,Georgia,serif;
  margin: 0;
}

.author-rights p,
.author-rights a {
  font: 13px/1.7 Manrope,sans-serif;
  color: #bcb3cf;
}

.author-consent {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  font: 13px/1.65 Manrope,sans-serif;
  color: #d8cce9;
}

.author-consent input {
  accent-color: #a266ff;
  width: 19px;
  height: 19px;
  flex-shrink: 0;
}

.author-translation {
  display: grid;
  gap: 13px;
}

.author-translation[hidden] {
  display: none;
}

.author-work-list {
  display: grid;
  gap: 10px;
}

.author-work-row,
.author-chapter-row {
  display: flex;
  gap: 15px;
  align-items: center;
  color: inherit;
  text-decoration: none;
  padding: 15px;
  border: 1px solid #ffffff16;
  border-radius: 17px;
  background: #10172bdd;
}

.author-work-row>img {
  width: 58px;
  height: 86px;
  object-fit: cover;
  border-radius: 8px;
}

.author-work-row>div,
.author-chapter-row>div {
  flex: 1;
  min-width: 0;
}

.author-work-row h2,
.author-chapter-row h3 {
  font: 600 19px/1.4 CormorantText,Georgia,serif;
  margin: 0;
  overflow-wrap: anywhere;
}

.author-work-row p,
.author-chapter-row small {
  font: 11px/1.6 Manrope,sans-serif;
  color: #b7a6cf;
  margin: 5px 0 0;
}

.author-chapter-row>strong {
  min-width: 30px;
  text-align: center;
  color: #c3a0f8;
}

.author-book-summary {
  display: flex;
  gap: 20px;
  align-items: center;
}

.author-book-summary>img {
  width: 100px;
  border-radius: 12px;
}

.author-book-summary h2 {
  font: 600 27px/1.2 CormorantText,Georgia,serif;
  margin: 0;
}

.author-book-summary p {
  color: #bcb3cf;
  font-size: 13px;
}

.author-auth-card {
  max-width: 420px;
  width: 100%;
  box-sizing: border-box;
  justify-self: center;
  text-align: center;
  background: linear-gradient(135deg,#221a34dd,#10172be8);
  border: 1px solid #a28bb433;
  border-radius: 28px;
  padding: 28px 24px;
  box-shadow: 0 15px 60px #0003;
  backdrop-filter: blur(15px);
}

.author-auth-card .auth-brand {
  font: 400 48px/1.2 CormorantText,Georgia,serif;
  margin: 0;
}

.author-auth-card h2 {
  font: 400 28px/1.2 CormorantText,Georgia,serif;
  margin: 24px 0;
}

.author-auth-card .auth-form {
  text-align: left;
}

.author-auth-card .auth-form>.btn {
  width: 100%;
  justify-content: center;
}

.author-auth-card>a {
  display: inline-block;
  margin-top: 24px;
  font-size: 12px;
  color: #c9a8f4;
}

.author-social {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 15px;
}

.author-social .btn {
  font-size: 12px;
  padding: 10px;
}

.auth-create-link {
  margin-top: 15px;
  width: 100%;
  justify-content: center;
}

.author-crop {
  max-width: min(92vw,550px);
  padding: 22px;
  background: #11182b;
  color: #f1edf9;
  border: 1px solid #5e4c7c;
  border-radius: 22px;
}

.author-crop canvas {
  max-height: 45vh;
  max-width: 100%;
  height: auto;
  display: block;
  margin: auto;
  border-radius: 12px;
}

.author-crop .author-field {
  margin: 12px 0;
}

.author-crop input[type=range] {
  width: 100%;
  accent-color: #aa78ee;
}

.author-crop h2 {
  font-size: 23px;
}

.author-recovery {
  border: 1px solid #9e86b9;
  border-radius: 14px;
  padding: 14px;
  background: #39264a;
  color: #f0e6fa;
}

.author-recovery p {
  font-size: 13px;
}

.author-recovery .btn {
  font-size: 11px;
  margin: 5px;
}

.author-blocks {
  display: grid;
  gap: 16px;
}

.author-block {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.author-block-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 5px;
}

.author-block-tools>span {
  flex: 1;
  color: #bfb2d1;
  font: 11px Manrope,sans-serif;
}

.author-block-tools .btn,
.author-format .btn {
  min-height: 30px;
  padding: 5px 9px;
  font: 11px Manrope,sans-serif;
}

.author-block img {
  max-width: 100%;
  max-height: 420px;
  object-fit: contain;
  border-radius: 12px;
}

.author-format {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.author-format select {
  max-width: 110px;
  font-size: 12px;
}

.author-manuscript {
  width: 100%;
  box-sizing: border-box;
  min-height: 200px;
  resize: vertical;
  font: 400 20px/1.75 CormorantText,Georgia,serif !important;
  background: #111525 !important;
  color: #eee6f4;
}

.author-add-block {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.author-add-block>.author-field {
  width: 100%;
  margin-top: 8px;
}

.author-table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
}

.author-table td {
  padding: 3px;
  border: 1px solid #4c425e;
}

.author-table input {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  border: 0;
  background: #151d30;
  color: #eee;
  padding: 9px;
}

.author-save-status {
  font: 12px/1.5 Manrope,sans-serif;
  color: #a3d4c8;
}

.author-save-actions {
  position: sticky;
  bottom: 108px;
  background: #101525ed;
  padding: 12px;
  border-radius: 17px;
  border: 1px solid #ffffff17;
  z-index: 3;
  backdrop-filter: blur(12px);
}

@media (max-width:430px) {
  .author-media-grid {
    grid-template-columns: 115px 1fr;
    gap: 13px;
  }
  .author-two-columns {
    grid-template-columns: 1fr;
  }
  .author-heading h1 {
    font-size: 26px;
  }
  .author-wrap {
    min-width: 0;
  }
  .author-rights,
  .author-block {
    padding: 13px;
  }
  .author-book-summary {
    gap: 13px;
  }
  .author-book-summary>img {
    width: 76px;
  }
  .author-actions .btn {
    font-size: 12px;
    padding: 10px;
  }
  .author-social {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion:reduce) {
  .author-scene * {
    scroll-behavior: auto !important;
  }
}

.shelf-book>.shelf-favorite {
  top: 12px;
  right: 12px;
}

.shelf-book.compact>.shelf-favorite {
  top: 10px;
  right: 10px;
}

.author-preview {
  max-width: 760px;
  background: #f6f0e2 !important;
  color: #352c25 !important;
}

.author-preview .reader-text {
  font: 400 18px/1.75 Lora,Georgia,serif;
  color: #352c25;
}

.author-preview .reader-text p {
  font: inherit;
}

.author-preview .reader-text table {
  color: inherit;
  width: 100%;
  table-layout: fixed;
}

.author-preview .reader-text td {
  overflow-wrap: anywhere;
}

/* Compact book controls and recognizable account providers. */

.book-actions .btn {
  font-size: 17px;
  line-height: 1.25;
  white-space: nowrap;
  font-weight: 600;
}

.book-tabs button {
  font-size: 18px;
  gap: 7px;
}

.book-actions .btn,
.book-tabs button {
  font-family: Manrope,sans-serif;
  font-variant-numeric: lining-nums tabular-nums;
}

.book-panel h2 {
  font-size: 25px;
}

.book-description {
  font-size: 20px;
  line-height: 1.55;
}

.btn.provider-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 12px 16px;
  border-radius: 12px;
  font: 500 14px/1.3 Manrope,sans-serif;
  text-shadow: none;
  box-shadow: none;
}

.btn.provider-button:before {
  content: "";
  display: block;
  width: 21px;
  height: 21px;
  flex: 0 0 21px;
  background: center/contain no-repeat;
}

.btn.provider-google,
.btn.provider-email {
  background: #fff;
  color: #202124;
  border: 1px solid #dadce0;
}

.btn.provider-google:before {
  background-image: url("assets/google-mark.svg");
}

.btn.provider-email:before {
  background-image: url("assets/gmail-mark.svg");
}

.btn.provider-telegram {
  background: #229ed9;
  color: #fff;
  border: 1px solid #38abe2;
}

.btn.provider-telegram:before {
  background-image: url("assets/telegram-mark.svg");
}

.btn.provider-button:hover {
  filter: brightness(.94);
  transform: none;
}

.btn.provider-button:disabled {
  opacity: .65;
  cursor: wait;
}

.social-row,
.author-social {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

#auth-dialog .auth-brand {
  font-size: 30px;
  margin-bottom: 14px;
}

#auth-dialog h2 {
  font-size: 30px;
}

.author-auth-card .auth-brand {
  font-size: 38px;
}

.author-auth-card h2 {
  font-size: 26px;
}

@media (max-width:700px) {
  .book-actions {
    grid-template-columns: minmax(0,.85fr) minmax(0,1.4fr) 38px;
    gap: 6px;
  }
  .book-actions .btn {
    font-size: 13px;
    padding: 9px 6px;
    min-height: 42px;
    gap: 5px;
  }
  .book-actions .icon {
    width: 17px;
    height: 17px;
    flex-shrink: 0;
  }
  .book-tabs button {
    font-size: 13px;
    gap: 5px;
    min-height: 44px;
    padding: 10px 1px;
  }
  .book-tabs button .icon {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
  }
  .book-panel h2 {
    font-size: 22px;
  }
  .book-description {
    font-size: 18px;
    line-height: 1.55;
  }
  .book-info-row,
  .book-info-genres {
    font-size: 18px;
  }
  .book-author h3 {
    font-size: 22px;
  }
}

@media (max-width:360px) {
  .book-actions .btn {
    font-size: 12px;
  }
  .book-tabs button {
    font-size: 12px;
    gap: 3px;
  }
  .book-tabs button .icon {
    width: 14px;
    height: 14px;
  }
}

/* Clear navigation between sign-in and account creation. */

#auth-dialog .auth-create-link,
.author-auth-card>a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  box-sizing: border-box;
  min-height: 46px;
  padding: 12px 16px;
  border: 1px solid #bb83ff;
  border-radius: 12px;
  background: linear-gradient(110deg,#9b42e9,#635cff);
  color: #fff;
  font: 600 14px/1.4 Manrope,sans-serif;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 4px 18px #8c45dc33;
  margin-top: 22px;
}

#auth-dialog .auth-create-link:hover,
.author-auth-card>a:hover {
  background: linear-gradient(110deg,#ad55f5,#7770ff);
  border-color: #d4b0ff;
}

#auth-dialog .auth-create-link:focus-visible,
.author-auth-card>a:focus-visible {
  outline: 2px solid #e5d4ff;
  outline-offset: 4px;
}

/* Chapter editor follows ChapterEditorScreen: paper, compact header and underlined save actions. */

body.chapter-writing {
  background: var(--ce-paper,#f8f7fc);
  overflow: hidden;
}

body.chapter-writing>#header,
body.chapter-writing>#footer,
body.chapter-writing>#bottom-nav,
body.chapter-writing>.skip {
  display: none !important;
}

body.chapter-writing #main {
  padding: 0 !important;
  max-width: none;
  margin: 0;
  min-height: 0;
}

.chapter-editor {
  --ce-paper: #f8f7fc;
  --ce-ink: #111;
  position: fixed;
  inset: 0;
  z-index: 110;
  background: var(--ce-paper);
  color: var(--ce-ink);
  display: flex;
  flex-direction: column;
  padding: env(safe-area-inset-top) max(0px,env(safe-area-inset-right)) env(safe-area-inset-bottom) max(0px,env(safe-area-inset-left));
  font: 14px/1.4 RobotoReader,Arial,sans-serif;
  box-sizing: border-box;
}

.chapter-editor button,
.ce-sheet button {
  color: inherit;
  background: transparent;
  border: 0;
  border-radius: 0;
  font: inherit;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-width: 0;
}

.chapter-editor button:disabled,
.ce-sheet button:disabled {
  opacity: .25;
  cursor: default;
}

.ce-top {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  padding: 4px 8px;
  min-height: 48px;
  position: static;
  background: transparent;
  color: inherit;
  border: 0;
  max-width: 960px;
  width: 100%;
  box-sizing: border-box;
  align-self: center;
}

.ce-top h1 {
  flex: 1;
  font: 700 18px/1.25 RobotoReader,Arial,sans-serif;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ce-top .ce-icon {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  padding: 0;
}

.ce-icon>span:last-child {
  display: none;
}

.ce-symbol {
  font: 20px/1 RobotoReader,Arial,sans-serif;
  flex-shrink: 0;
}

.ce-top .ce-number {
  width: 68px;
  height: 36px;
  padding: 6px;
  box-sizing: border-box;
  text-align: center;
  background: transparent;
  color: inherit;
  border: 1px solid color-mix(in srgb,var(--ce-ink) 18%,transparent);
  border-radius: 9px;
  font: 600 14px RobotoReader,Arial,sans-serif;
  min-width: 0;
}

.ce-top .ce-number::placeholder {
  color: color-mix(in srgb,var(--ce-ink) 50%,transparent);
}

.ce-body {
  border-top: 2px solid color-mix(in srgb,var(--ce-ink) 65%,transparent);
  margin: 0 20px;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  max-width: 920px;
  width: calc(100% - 40px);
  align-self: center;
  padding-top: 4px;
}

.ce-title {
  width: 100%;
  padding: 10px 0;
  background: transparent !important;
  color: inherit !important;
  border: 0 !important;
  border-radius: 0;
  font: 700 23px/1.3 var(--ce-font),serif;
  box-shadow: none !important;
  outline: none;
  box-sizing: border-box;
}

.ce-title::placeholder {
  color: color-mix(in srgb,var(--ce-ink) 55%,transparent);
}

.ce-title-rule {
  border-top: 2px solid color-mix(in srgb,var(--ce-ink) 45%,transparent);
}

.ce-blocks {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 12px 0 4px;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}

.ce-block {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 6px;
  min-width: 0;
}

.ce-block:has(>img),
.ce-block:has(>table) {
  display: block;
  padding: 10px 0;
}

.ce-text {
  flex: 1;
  min-width: 0;
  min-height: 1.6em;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  outline: none;
  font: 500 var(--ce-size)/var(--ce-line) var(--ce-font),serif;
  color: inherit;
  padding: 0 0 8px;
}

.ce-text:empty:before {
  content: attr(data-placeholder);
  color: color-mix(in srgb,var(--ce-ink) 55%,transparent);
  pointer-events: none;
}

.ce-text-heading {
  font-size: calc(var(--ce-size)*1.25);
  font-weight: 700;
}

.ce-block>input[type=checkbox] {
  accent-color: #9e6cff;
  margin: 6px 6px 0 0;
  width: 19px;
  height: 19px;
  flex-shrink: 0;
}

.ce-list-marker {
  font: 500 var(--ce-size)/var(--ce-line) var(--ce-font),serif;
}

.ce-block img {
  max-width: 100%;
  max-height: 65vh;
  object-fit: contain;
  display: block;
  margin: auto;
}

.ce-caption {
  display: block;
  width: 100%;
  border: 0;
  border-bottom: 1px solid color-mix(in srgb,var(--ce-ink) 20%,transparent);
  background: transparent;
  color: inherit;
  font: 13px RobotoReader;
  padding: 8px;
  box-sizing: border-box;
}

.ce-element-menu {
  position: absolute;
  right: 5px;
  top: 14px;
  width: 34px;
  height: 34px;
  background: var(--ce-paper) !important;
  border-radius: 50% !important;
  z-index: 2;
}

.ce-block table,
.ce-table-grid table {
  border-collapse: collapse;
  width: 100%;
  table-layout: fixed;
}

.ce-block td,
.ce-table-grid td {
  border: 1px solid color-mix(in srgb,var(--ce-ink) 28%,transparent);
  padding: 8px;
  overflow-wrap: anywhere;
}

.ce-footer {
  flex-shrink: 0;
  width: calc(100% - 40px);
  max-width: 920px;
  align-self: center;
  padding: 2px 0 6px;
  background: transparent;
  margin: 0;
  border: 0;
  color: inherit;
}

.ce-footer>button {
  justify-content: flex-start;
  font-size: 13px;
  min-height: 36px;
  padding: 4px 0;
}

.ce-save-actions {
  display: flex;
  gap: 18px;
}

.ce-save-actions>button {
  flex: 1;
  border-bottom: 2px solid color-mix(in srgb,var(--ce-ink) 80%,transparent);
  font-size: 14px;
  font-weight: 700;
  min-height: 32px;
  padding: 2px 4px;
}

.ce-save-actions .ce-symbol {
  font-size: 17px;
}

.ce-status {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font: 11px/1.1 RobotoReader,Arial,sans-serif;
  color: color-mix(in srgb,var(--ce-ink) 65%,transparent);
  margin-top: 5px;
  min-height: 12px;
}

.ce-error:empty {
  display: none;
}

.ce-error {
  color: #d23b57;
  font: 12px/1.4 RobotoReader;
  margin: 4px 0;
}

.chapter-editor .author-recovery {
  color: var(--ce-ink);
  background: var(--ce-paper);
  border: 1px solid currentColor;
  padding: 8px;
  margin: 6px 0;
  flex-shrink: 0;
  font-size: 12px;
}

.chapter-editor .author-recovery button {
  font-size: 12px;
  border-bottom: 1px solid currentColor;
  padding: 6px;
}

.ce-sheet {
  --ce-paper: #f8f7fc;
  --ce-ink: #111;
  position: fixed;
  inset: auto 0 0;
  margin: 0 auto;
  max-width: 640px;
  width: 100%;
  max-height: 74dvh;
  box-sizing: border-box;
  border: 0;
  border-radius: 20px 20px 0 0;
  padding: 10px 20px max(20px,env(safe-area-inset-bottom));
  background: var(--ce-paper);
  color: var(--ce-ink);
  font: 14px/1.4 RobotoReader,Arial,sans-serif;
  overflow: auto;
  z-index: 130;
}

.ce-sheet::backdrop {
  background: #0006;
}

.ce-sheet-large {
  max-height: 90dvh;
  height: 90dvh;
  display: flex;
  flex-direction: column;
}

.ce-sheet:not([open]) {
  display: none;
}

.ce-handle {
  width: 34px;
  height: 3px;
  background: color-mix(in srgb,var(--ce-ink) 25%,transparent);
  margin: 0 auto 8px;
}

.ce-sheet header {
  position: static;
  display: flex;
  align-items: center;
  gap: 4px;
  border-bottom: 1px solid color-mix(in srgb,var(--ce-ink) 40%,transparent);
  margin-bottom: 8px;
  padding: 0;
  background: none;
  color: inherit;
}

.ce-sheet header h2 {
  flex: 1;
  font: 700 18px/1.4 RobotoReader,Arial,sans-serif;
  margin: 0;
  min-width: 0;
}

.ce-sheet header button {
  min-height: 40px;
  padding: 0 8px;
}

.ce-sheet header button:has(.ce-symbol)>span:last-child {
  display: none;
}

.ce-sheet-content {
  min-height: 0;
  overflow: auto;
}

.ce-sheet-content>button {
  display: flex;
  justify-content: flex-start;
  min-height: 48px;
  width: 100%;
  border-bottom: 1px solid color-mix(in srgb,var(--ce-ink) 18%,transparent);
}

.ce-tool-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 12px;
}

.ce-tool-grid button {
  min-height: 54px;
  padding: 10px 2px;
  justify-content: flex-start;
  border-bottom: 1px solid color-mix(in srgb,var(--ce-ink) 18%,transparent);
  text-align: left;
  font-size: 13px;
  line-height: 1.25;
}

.ce-tool-grid button[aria-pressed=true] {
  background: color-mix(in srgb,var(--ce-ink) 6%,transparent);
  border: 1px solid color-mix(in srgb,var(--ce-ink) 55%,transparent);
  border-radius: 7px;
  font-weight: 700;
}

.ce-tool-grid .ce-symbol {
  width: 22px;
  text-align: center;
  font-size: 19px;
}

.ce-tool-grid [data-tool=italic] .ce-symbol {
  font-style: italic;
}

.ce-tool-grid [data-tool=underline] .ce-symbol {
  text-decoration: underline;
}

.ce-tool-grid [data-tool=strike] .ce-symbol {
  text-decoration: line-through;
}

.ce-night {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 50px;
}

.ce-range {
  display: block;
  margin: 10px 0;
  color: inherit;
  font-size: 13px;
}

.ce-range input {
  display: block;
  width: 100%;
  margin: 12px 0;
  accent-color: var(--ce-ink);
}

.ce-colors,
.ce-fonts {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.ce-colors button {
  border: 1px solid currentColor;
  width: 34px;
  height: 34px;
  border-radius: 50%;
}

.ce-fonts button {
  border: 1px solid color-mix(in srgb,var(--ce-ink) 20%,transparent);
  border-radius: 8px;
  padding: 8px 12px;
}

.ce-fonts button[aria-pressed=true] {
  background: var(--ce-ink);
  color: var(--ce-paper);
}

.ce-table-tools,
.ce-draw-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.ce-table-tools button {
  min-height: 42px;
  font-size: 13px;
}

.ce-table-grid {
  overflow: auto;
}

.ce-table-grid table {
  min-width: max-content;
}

.ce-table-grid td {
  width: 150px;
  min-width: 150px;
  padding: 0;
}

.ce-table-grid textarea {
  width: 150px;
  min-height: 65px;
  border: 0;
  color: inherit;
  background: transparent;
  padding: 10px;
  box-sizing: border-box;
  font: 16px/1.5 RobotoReader;
  resize: vertical;
}

.ce-sheet canvas {
  display: block;
  max-width: 100%;
  max-height: 60dvh;
  width: auto;
  height: auto;
  aspect-ratio: 3/4;
  touch-action: none;
  border: 1px solid color-mix(in srgb,var(--ce-ink) 22%,transparent);
  border-radius: 8px;
  margin: 8px auto;
}

.ce-draw-tools button {
  width: 36px;
  height: 38px;
  padding: 0;
}

.ce-draw-tools button>span:last-child {
  display: none;
}

.ce-sheet input[type=url] {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 8px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid currentColor;
  color: inherit;
  font: 16px RobotoReader;
}

.ce-preview {
  font: 500 var(--ce-size,18px)/var(--ce-line,1.6) var(--ce-font,Lora),serif;
}

.ce-preview .reader-text {
  color: inherit !important;
  font: inherit !important;
  max-width: none;
  margin: 0;
  padding: 0;
}

.ce-preview .reader-text p {
  font: inherit !important;
}

.ce-preview h1 {
  font: 700 23px/1.3 var(--ce-font,Lora),serif;
}

.ce-sheet input[type=range] {
  accent-color: var(--ce-ink);
}

@media (max-width:360px) {
  .ce-top h1 {
    font-size: 16px;
  }
  .ce-top .ce-icon {
    width: 34px;
  }
  .ce-top .ce-number {
    width: 58px;
  }
  .ce-tool-grid {
    gap: 4px 8px;
  }
}

.ce-title {
  resize: none;
  min-height: 50px;
  max-height: 80px;
  flex-shrink: 0;
}

.ce-symbol {
  vertical-align: middle;
}

.ce-sheet p {
  font-size: 13px;
}

.ce-sheet-content>.reader-text {
  background: none;
}

.ce-sheet svg {
  display: inline-block;
  flex-shrink: 0;
}

.chapter-editor textarea.ce-title {
  font-size: 23px !important;
  line-height: 1.3 !important;
  padding: 10px 0 !important;
}

.ce-night input {
  appearance: none;
  width: 42px;
  height: 25px;
  border: 1px solid color-mix(in srgb,var(--ce-ink) 35%,transparent);
  border-radius: 20px;
  background: color-mix(in srgb,var(--ce-ink) 15%,transparent);
  position: relative;
  cursor: pointer;
}

.ce-night input:before {
  content: "";
  position: absolute;
  width: 17px;
  height: 17px;
  border-radius: 50%;
  background: var(--ce-ink);
  left: 3px;
  top: 3px;
  transition: transform .15s;
}

.ce-night input:checked {
  background: color-mix(in srgb,var(--ce-ink) 60%,transparent);
}

.ce-night input:checked:before {
  transform: translateX(16px);
  background: var(--ce-paper);
}

.ce-colors button[aria-pressed=true] {
  border-width: 3px;
}

.ce-tool-grid button[aria-pressed=true]:after {
  content: "✓";
  font-size: 14px;
  margin-left: auto;
}

.ce-top button:focus-visible,
.ce-footer button:focus-visible,
.ce-sheet button:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

/* NewBookScreen web counterpart. */

body.book-creating {
  background: #050817;
}

body.book-creating>#header,
body.book-creating>#footer,
body.book-creating>#bottom-nav,
body.book-creating>.skip {
  display: none !important;
}

body.book-creating #main {
  max-width: none;
  padding: 0;
  min-height: 100dvh;
  margin: 0;
}

.new-book-scene {
  min-height: 100dvh !important;
  box-sizing: border-box;
  background: linear-gradient(180deg,#080b20b2 0%,#080b1ced 35%,#050817 100%),url("assets/author_create_bg.png") top center/cover fixed !important;
  padding: 8px 18px 108px !important;
  color: white;
  font: 14px/1.5 RobotoReader,Arial,sans-serif;
}

.nb-wrap {
  max-width: 600px !important;
  width: 100%;
  margin: 0 auto;
}

.new-book-form {
  gap: 0 !important;
}

.nb-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 8px !important;
  padding: 0 !important;
  position: static;
  background: none;
  border: 0;
  color: white;
}

.nb-back {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  background: #18203ac2;
  border: 1px solid #ffffff12;
  color: white;
  flex-shrink: 0;
  box-sizing: border-box;
}

.nb-back .icon {
  width: 17px;
  height: 17px;
}

.nb-heading h1 {
  font: 700 23px/1.2 RobotoReader,Arial,sans-serif;
  margin: 0;
}

.nb-subtitle {
  color: #9a9fb3;
  font-size: 13px;
  line-height: 1.5;
  margin: 0 0 20px 2px;
}

.nb-section {
  margin: 0 0 16px;
  padding: 18px;
  background: #11162aea;
  border: 1px solid #6f669a28;
  border-radius: 22px;
  min-width: 0;
}

.nb-section h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  font: 600 16px/1.4 RobotoReader,Arial,sans-serif;
  margin: 0 0 18px;
  color: white;
}

.nb-section h2 .icon {
  color: #c5a8ff;
  width: 20px;
  height: 20px;
}

.nb-field {
  display: block;
  min-width: 0;
}

.nb-field>span,
.nb-label {
  display: block;
  font-size: 13.5px;
  line-height: 1.4;
  font-weight: 600;
  color: white;
  margin: 0 0 8px;
}

.new-book-form .field,
.nb-sheet .field {
  display: block;
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  background: #0d1224;
  border: .8px solid #39425fd1;
  border-radius: 14px;
  padding: 14px 13px;
  color: white;
  font: 400 15px/1.5 RobotoReader,Arial,sans-serif;
  box-shadow: none;
  outline: none;
}

.new-book-form textarea[aria-label="Asar nomi"] {
  min-height: 52px;
  max-height: 80px;
  resize: none;
  font-size: 16px;
}

.new-book-form .field::placeholder,
.nb-sheet .field::placeholder {
  color: #ffffff5c;
  font-size: 14px;
}

.new-book-form .field:focus,
.nb-sheet .field:focus {
  border-color: #9a64ff;
}

.new-book-form select {
  color-scheme: dark;
  appearance: auto;
}

.nb-media {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px;
  background: linear-gradient(135deg,#322344,#171d3a);
  border: 1px solid #7c639e55;
  border-radius: 24px;
  overflow: hidden;
  margin-bottom: 18px;
  min-width: 0;
}

.nb-media:after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg,#20173233,#101328e6);
  z-index: -1;
  pointer-events: none;
}

.nb-banner-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

.nb-banner-image[hidden] {
  display: none;
}

.nb-cover {
  width: 108px;
  flex-shrink: 0;
  display: block !important;
}

.nb-cover .author-media-preview {
  width: 100%;
  height: auto;
  aspect-ratio: 1/1.48 !important;
  border-radius: 16px;
  border: 1px solid #ab88dcaa;
  background: #1d2038;
  box-shadow: 0 6px 16px #0003;
  cursor: pointer;
  box-sizing: border-box;
  overflow: hidden;
}

.nb-cover .author-media-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.nb-cover .author-media-preview>span {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px;
  box-sizing: border-box;
  height: 100%;
  font: 600 12px/1.3 RobotoReader,Arial,sans-serif;
  color: white;
  text-align: center;
}

.nb-cover .author-media-preview>span[hidden] {
  display: none;
}

.nb-cover .author-media-preview>span .icon {
  color: #d0aaff;
  width: 30px;
  height: 30px;
}

.nb-cover>button,
.nb-banner-source {
  display: none !important;
}

.nb-cover .form-error {
  font-size: 11px;
}

.nb-media-info {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
  flex: 1;
}

.nb-eyebrow {
  color: #d5bcff;
  font-size: 11px;
  letter-spacing: 1.1px;
  font-weight: 700;
  margin-bottom: 10px;
}

.nb-media-info strong {
  font: 700 20px/1.2 RobotoReader,Arial,sans-serif;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: anywhere;
  margin-bottom: 16px;
}

.nb-media-info>button {
  display: flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  color: white;
  border: 1px solid #7f729f66;
  border-radius: 12px;
  min-height: 44px;
  padding: 10px;
  font: 13px/1.4 RobotoReader,Arial,sans-serif;
  text-align: left;
  width: 100%;
  cursor: pointer;
}

.nb-media-info>button .icon {
  width: 19px;
  height: 19px;
  flex-shrink: 0;
}

.nb-media-info .nb-banner-remove {
  border: 0;
  color: #ffffffb3;
  min-height: 30px;
  font-size: 12px;
  padding: 5px 0;
}

.nb-media-info .nb-banner-remove[hidden] {
  display: none;
}

.nb-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 7px;
  align-items: center;
  min-width: 0;
}

.nb-chip {
  display: inline-block;
  max-width: 176px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border: .7px solid #3b4765;
  border-radius: 20px;
  padding: 5px 11px;
  font: 500 12px/1.3 RobotoReader,Arial,sans-serif;
  color: #c5c9d7;
  background: #10182c80;
  cursor: pointer;
  min-height: 29px;
  box-sizing: border-box;
}

.nb-chip[aria-pressed=true] {
  border: 1px solid #a764ff;
  color: white;
  background: #372461aa;
  font-weight: 700;
}

.nb-all {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #55b9ad;
  border-radius: 9px;
  background: #12323a;
  color: #b8fff1;
  font: 700 11px/1.3 RobotoReader,Arial,sans-serif;
  min-height: 29px;
  padding: 5px 9px;
  cursor: pointer;
}

.nb-all .icon {
  color: #71decf;
  width: 16px;
  height: 16px;
}

.nb-tags-label {
  margin-top: 18px;
}

.nb-description-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13.5px;
  font-weight: 600;
  margin-bottom: 4px;
}

.nb-description-expand {
  padding: 5px;
  border: 0;
  background: none;
  color: #c5b4ff;
  cursor: pointer;
}

.nb-description-expand .icon {
  width: 21px;
  height: 21px;
}

.nb-description-expand span {
  display: none;
}

.nb-counter {
  display: block;
  text-align: right;
  color: #9a9fb3;
  font-size: 11px;
  margin-top: 4px;
}

.nb-section:has([aria-label="Tavsif"]) textarea {
  resize: vertical;
  min-height: 150px;
  max-height: 400px;
  font-size: 15px;
  line-height: 1.5;
}

.nb-history-note {
  font: 13px/1.4 RobotoReader,Arial,sans-serif;
  color: #9ddcc7;
  margin: 0 0 10px;
}

.nb-roles {
  gap: 10px;
  margin: 0 0 10px;
}

.nb-roles .nb-chip {
  font-size: 14px;
  border-radius: 8px;
  background: #141b31b8;
  padding: 7px 13px;
}

.nb-roles .nb-chip[aria-pressed=true] {
  background: #6842aa;
}

.nb-translation {
  display: grid;
  gap: 10px;
}

.nb-translation[hidden],
.nb-rights-warnings[hidden] {
  display: none;
}

.nb-translation p,
.nb-rights-warnings p {
  font: 13px/1.5 RobotoReader,Arial,sans-serif;
  color: #ffffffb3;
  white-space: pre-line;
  margin: 8px 0;
}

.nb-rights-warnings a {
  display: inline-block;
  color: #c5a8ff;
  text-decoration: none;
  padding: 8px 4px;
  font-size: 13px;
}

.nb-consent-row {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 12px;
}

.nb-consent {
  display: flex;
  align-items: center;
  gap: 14px;
  font: 13px/1.4 RobotoReader,Arial,sans-serif;
  white-space: pre-line;
  flex: 1;
}

.nb-consent input {
  accent-color: #8a55e8;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.nb-consent-row>button {
  border: 0;
  background: none;
  color: #ffffffb3;
  cursor: pointer;
}

.nb-consent-row>button[hidden] {
  display: none;
}

.nb-consent-row>button span {
  display: none;
}

.nb-consent-row>button .icon {
  transform: rotate(90deg);
  width: 20px;
  height: 20px;
}

.nb-bottom {
  position: fixed;
  inset: auto 0 0;
  padding: 12px 18px max(12px,env(safe-area-inset-bottom));
  background: #0a0e1ff2;
  border-top: 1px solid #6d619822;
  z-index: 90;
  box-sizing: border-box;
  display: flex;
  justify-content: center;
}

.nb-bottom.nb-keyboard {
  display: none;
}

.nb-next {
  width: 100%;
  max-width: 600px;
  height: 52px;
  border-radius: 16px;
  border: 0;
  background: linear-gradient(90deg,#c64bff 0%,#7b3eff 35%,#4d48ff 68%,#4caeff);
  box-shadow: 0 0 16px #7047ff33;
  color: white;
  text-decoration: none;
  font: 600 17px RobotoReader,Arial,sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  cursor: pointer;
}

.nb-next:after {
  content: "→";
  position: absolute;
  right: 16px;
  font-size: 23px;
  font-weight: 400;
}

.nb-next:disabled {
  opacity: .45;
  cursor: default;
}

.nb-sheet {
  position: fixed;
  inset: auto 0 0;
  margin: 0 auto;
  width: 100%;
  max-width: 636px;
  height: 65dvh;
  max-height: 85dvh;
  padding: 16px;
  box-sizing: border-box;
  background: #11182b;
  color: white;
  border: 0;
  border-radius: 22px 22px 0 0;
  font: 14px/1.5 RobotoReader,Arial,sans-serif;
  overflow: hidden;
}

.nb-sheet[open] {
  display: flex;
  flex-direction: column;
}

.nb-sheet::backdrop {
  background: #0007;
}

.nb-sheet header {
  position: static;
  display: flex;
  align-items: center;
  background: none;
  color: white;
  border: 0;
  gap: 6px;
  padding: 0 0 12px;
  margin: 0;
}

.nb-sheet header h2 {
  flex: 1;
  font: 500 18px/1.4 RobotoReader,Arial,sans-serif;
  margin: 0;
}

.nb-sheet button {
  cursor: pointer;
}

.nb-sheet header button {
  display: flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: 0;
  color: #d1beff;
  min-height: 34px;
  font: 14px RobotoReader;
}

.nb-sheet header button:has(.icon) span {
  display: none;
}

.nb-sheet header .icon {
  width: 20px;
  height: 20px;
}

.nb-sheet-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  display: flex;
  flex-direction: column;
}

.nb-all-chips {
  align-content: flex-start;
  flex: 1;
  overflow: auto;
  padding: 0 0 16px;
}

.nb-add-choice {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: none;
  color: #c5a8ff;
  border: 0;
  font: 14px RobotoReader;
  min-height: 42px;
  padding: 8px;
}

.nb-add-choice .icon {
  width: 18px;
  height: 18px;
}

.nb-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}

.nb-dialog-actions button {
  background: none;
  border: 0;
  color: #c5a8ff;
  font: 14px RobotoReader;
  padding: 10px;
}

.nb-sheet-full {
  height: 100dvh;
  max-height: 100dvh;
  border-radius: 0;
  inset: 0;
  max-width: none;
  background: #050817;
}

.nb-sheet-full .nb-sheet-body {
  max-width: 800px;
  width: 100%;
  align-self: center;
}

.nb-sheet-full textarea {
  flex: 1;
  font-size: 17px;
  resize: none;
}

.nb-created {
  box-sizing: border-box;
  min-height: 100dvh;
  max-width: 636px;
  margin: 0 auto;
  padding: 8px 18px 16px;
  color: white;
  display: flex;
  flex-direction: column;
  background: radial-gradient(ellipse at 90% 15%,#a648ff38,transparent 50%),radial-gradient(ellipse at 5% 40%,#315eff29,transparent 50%),linear-gradient(135deg,#07162d,#21104b 48%,#050817);
  font: 14px/1.4 RobotoReader,Arial,sans-serif;
}

.nb-created h1 {
  font: 700 24px/1.05 CormorantText,Georgia,serif;
  margin: 10px 0 5px;
}

.nb-created>p {
  font: 12px/1.3 CormorantText,Georgia,serif;
  color: #ffffffbd;
  margin: 0 0 12px;
}

.nb-created-hero {
  text-align: center;
  margin-bottom: 14px;
}

.nb-created-hero>img {
  width: 128px;
  height: 174px;
  object-fit: cover;
  border: 2px solid #bb5dff;
  border-radius: 17px;
  box-shadow: 0 0 20px #8955ff38;
}

.nb-created-hero h2 {
  font: 700 22px CormorantText,Georgia,serif;
  margin: 7px 0;
}

.nb-created-hero .nb-chips {
  justify-content: center;
}

.nb-created-hero>p {
  font: 12px CormorantText,Georgia,serif;
}

.nb-created-action {
  display: flex;
  align-items: center;
  gap: 11px;
  color: white;
  text-decoration: none;
  background: #0e1730d9;
  border: .8px solid #56638a7a;
  border-radius: 15px;
  padding: 11px 12px;
  margin-bottom: 8px;
  min-height: 58px;
  box-sizing: border-box;
}

.nb-created-action>.icon:first-child {
  width: 43px;
  height: 43px;
  box-sizing: border-box;
  padding: 10px;
  color: #d46dff;
  background: #bb4fff24;
  border-radius: 12px;
}

.nb-created-action>div {
  flex: 1;
  min-width: 0;
}

.nb-created-action strong {
  font: 600 15px CormorantText,Georgia,serif;
  display: block;
}

.nb-created-action small {
  display: block;
  color: #ffffff94;
  font: 11px CormorantText,Georgia,serif;
}

.nb-created-action>.icon:last-child {
  width: 17px;
  color: #c7b6ff;
}

.nb-created-bottom {
  margin-top: auto;
  display: grid;
  gap: 8px;
  padding-top: 20px;
}

.nb-created .nb-next {
  height: 47px;
  font: 600 16px CormorantText,Georgia,serif;
}

.nb-later {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #884dff;
  border-radius: 14px;
  height: 43px;
  color: #d3c3ff;
  text-decoration: none;
  font: 600 14px CormorantText,Georgia,serif;
}

@media (max-width:375px) {
  .nb-cover {
    width: 90px;
  }
  .nb-media {
    padding: 18px;
    gap: 16px;
  }
  .nb-media-info strong {
    font-size: 20px;
  }
  .nb-heading h1 {
    font-size: 23px;
  }
}

.nb-cover .author-media-preview img[hidden] {
  display: none !important;
}

.nb-cover input[hidden],
.nb-banner-source input[hidden] {
  display: none !important;
}

.nb-media-info .form-error {
  font-size: 11px;
  color: #ff8f9e;
}

.nb-rights-warnings p {
  margin-top: 12px;
}

.nb-sheet button:focus-visible,
.nb-chip:focus-visible,
.nb-back:focus-visible,
.nb-next:focus-visible {
  outline: 2px solid #c5a8ff;
  outline-offset: 3px;
}

.new-book-scene {
  background-attachment: fixed,fixed !important;
  background-repeat: no-repeat !important;
}

.nb-cover .author-media-preview>span>span {
  font: inherit;
  color: inherit;
}

@media (max-width:700px) {
  .book-metrics {
    grid-template-columns: repeat(4,auto);
    justify-content: space-between;
  }
}

/* 282: separate book/reading links, owner actions and compact mobile forms. */
.continue-cover,.chapter-cover-link {flex:0 0 auto;display:block;line-height:0;}
.continue-copy,.latest-chapter-copy {min-width:0;flex:1;}
.continue h3 a,.chapter-card h3 a {display:block;overflow-wrap:anywhere;}
.continue>.btn {flex-shrink:0;}
.latest-chapter-read {display:block;border-radius:6px;}
.chapter-card .chapter-cover-link img {display:block;}
.chapter-like-count {display:inline-flex;align-items:center;justify-content:center;gap:4px;flex:0 0 auto;color:#d4c1ee;font:13px/1.2 Manrope,Arial,sans-serif;min-width:34px;font-variant-numeric:lining-nums tabular-nums;}
.chapter-like-count .icon {width:17px;height:17px;}
.chapter-owner-menu {display:grid;place-items:center;background:none;border:0;border-radius:50%;padding:6px;flex:0 0 30px;width:30px;height:34px;color:#ded1ef;}
.chapter-owner-menu .icon {width:20px;height:20px;}
.chapter-actions {display:grid;gap:12px;}
.chapter-actions .btn {justify-content:flex-start;}
.chapter-actions .danger {color:#ff9ba7;border-color:#ff849d55;}
.genre-info-more {background:none;border:0;padding:5px 0;color:#c7a8ff;font:12px/1.4 Manrope,Arial,sans-serif;text-align:left;}
.book-info-genres p {overflow-wrap:anywhere;font-size:15px;line-height:1.45;}
.new-book-form .nb-consent-row {align-items:flex-start;width:100%;max-width:100%;min-width:0;}
.new-book-form label.nb-consent {display:grid;grid-template-columns:20px minmax(0,1fr);align-items:start;gap:12px;width:100%;min-width:0;max-width:100%;margin:0;}
.new-book-form .nb-consent>input[type=checkbox] {display:block;width:20px;min-width:20px;max-width:20px;height:20px;min-height:20px;padding:0;margin:2px 0 0;appearance:auto;box-shadow:none;}
.new-book-form .nb-consent>span {min-width:0;overflow-wrap:anywhere;white-space:pre-line;font:13px/1.5 RobotoReader,Arial,sans-serif;}
.nb-select-wrap {display:block;position:relative;min-width:0;}
.new-book-form .nb-select-wrap select {appearance:none;-webkit-appearance:none;padding-right:44px;}
.nb-select-wrap>.icon {position:absolute;right:14px;top:50%;transform:translateY(-50%);pointer-events:none;width:17px;height:17px;color:#c9b5e8;}
.reader-text.reader-protected,.reader-protected * {-webkit-user-select:none;user-select:none;-webkit-touch-callout:none;}
.reader-discussion input,.reader-discussion textarea {-webkit-user-select:text;user-select:text;-webkit-touch-callout:default;}
#header {position:relative;box-sizing:content-box;padding-top:env(safe-area-inset-top,0px);top:auto;}
html {scroll-padding-top:16px;}
html:has(body.reading) {scroll-padding-top:calc(72px + env(safe-area-inset-top,0px));}
.footer-about {max-width:520px;color:var(--muted);margin-bottom:28px;}
.footer-about>.brand {color:var(--text);}
.footer-about>p {margin:15px 0 10px;line-height:1.7;}
.footer-about>a[href^="mailto:"] {color:#c6a7ff;overflow-wrap:anywhere;}
.footer-sections {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:26px;}
.footer-sections h3 {font:600 15px Manrope,Arial,sans-serif;margin:0 0 14px;color:#e9dff7;}
.footer-sections a {display:block;font:13px/1.5 Manrope,Arial,sans-serif;color:var(--muted);margin:10px 0;overflow-wrap:anywhere;}
.footer-sections a:hover {color:#c8a9ff;}
.information-page {padding-top:32px;padding-bottom:40px;max-width:850px;}
.info-panel,.info-faq {margin:18px 0;padding:20px;border:1px solid var(--line);border-radius:18px;background:#141421bd;}
.info-panel h2 {font-size:23px;margin:0 0 12px;}
.info-panel p,.info-faq p {color:#c0b8cb;font:14px/1.8 Manrope,Arial,sans-serif;}
.info-faq details {padding:14px 0;border-bottom:1px solid var(--line);}
.info-faq details:last-child {border:0;}
.info-faq summary {cursor:pointer;font:14px/1.5 Manrope,Arial,sans-serif;}
@media(max-width:700px){.footer-sections{grid-template-columns:repeat(2,minmax(0,1fr));gap:22px 18px;}.book-info-genres p{font-size:14px;}.continue{gap:10px;}.continue .eyebrow{font-size:10px;}.chapter-like-count{font-size:12px;}}
.footer-telegram {display:flex;align-items:center;gap:8px;width:fit-content;margin-top:14px;color:#b8dfff;}
.footer-telegram .icon {width:21px;height:21px;}
.book-creating .new-book-scene {padding-top:calc(8px + env(safe-area-inset-top,0px)) !important;}
.reading .app-reader-toolbar {top:env(safe-area-inset-top,0px);}

.reading .reader-body {padding-top:calc(70px + env(safe-area-inset-top,0px));}
@media(max-width:700px){.reading .reader-body{padding-top:calc(68px + env(safe-area-inset-top,0px));}}

/* The inner heart grows from its centre while its write is pending. */
.loading-heart {background:transparent;border:0;padding:0;cursor:pointer;color:#9c83c3;flex-shrink:0;}
.loading-heart:disabled {opacity:1;cursor:progress;}
.loading-heart-shape {display:inline-grid;place-items:center;position:relative;vertical-align:middle;}
.loading-heart-outline,.loading-heart-fill {display:grid;grid-area:1/1;place-items:center;}
.loading-heart-fill {transform:scale(0);transform-origin:center;will-change:transform;color:#e26ca4;}
.loading-heart .loading-heart-outline .icon {fill:none;stroke:#9c83c3;}
.loading-heart .loading-heart-fill .icon {fill:#e26ca4;stroke:#e26ca4;}
.review-like-button {display:grid;place-items:center;min-width:34px;min-height:34px;}
.review-likes {width:36px;gap:0;}
.loading-heart:focus-visible {outline:2px solid #b294ee;outline-offset:3px;border-radius:8px;}
@media (prefers-reduced-motion:reduce) {.loading-heart-fill {transition:none!important;}}

/* Loading placeholders mirror the content of the destination. */
.context-loading {padding-top:28px;padding-bottom:36px;min-height:55vh;overflow:hidden;}
.load-label {font:500 13px/1.5 RobotoReader,sans-serif;color:var(--muted,#aaa2b9);margin:0 0 24px;letter-spacing:.02em;}
.load-shape {display:block;border-radius:8px;background:linear-gradient(105deg,rgba(156,131,195,.09) 20%,rgba(156,131,195,.23) 45%,rgba(156,131,195,.09) 70%);background-size:220% 100%;animation:pulse 1.7s infinite;}
.load-title {height:28px;width:65%;margin-bottom:22px;}
.load-lines {display:grid;gap:11px;min-width:0;flex:1;}
.load-line {height:12px;width:100%;}.load-line.short {width:62%;}
.load-books {display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:18px;}
.load-book {min-width:0;}.load-cover {aspect-ratio:2/3;width:100%;margin-bottom:16px;}
.load-book .load-line {height:10px;}
.load-row {display:flex;align-items:center;gap:16px;padding:20px;border:1px solid rgba(156,131,195,.13);border-radius:18px;min-width:0;}
.load-rows {display:grid;gap:14px;}.load-avatar {width:58px;height:58px;border-radius:50%;flex-shrink:0;}
.load-dot {width:14px;height:14px;border-radius:50%;flex-shrink:0;}
.load-mini-cover {width:55px;height:80px;flex-shrink:0;}
.load-tabs,.load-actions {display:flex;gap:12px;margin:22px 0;}.load-tabs>* {flex:1;min-width:0;}
.load-pill {width:76px;height:29px;border-radius:30px;}.load-action {height:46px;width:170px;border-radius:24px;}.load-tile {height:64px;border-radius:15px;}
.load-detail-hero {display:flex;gap:26px;align-items:center;}.load-detail-hero>.load-cover {width:160px;flex-shrink:0;margin:0;}.load-detail-copy {flex:1;min-width:0;}.load-detail-copy .load-pill {margin:20px 0;}
.load-profile {max-width:720px;margin:auto;}.load-profile>.load-avatar {width:94px;height:94px;margin-bottom:20px;}
.load-profile .load-title {width:42%;}.load-form {max-width:720px;margin:auto;}.load-field {margin:25px 0;}.load-field>.load-line {margin-bottom:12px;width:100px;}.load-input {height:48px;}.load-editor {height:160px;}
.load-home-hero {padding:25px 0 40px;max-width:700px;}.load-home-hero .load-title {height:45px;}.load-home-hero .load-action {margin-top:24px;}
.load-view-read {max-width:760px;min-height:90vh;padding:22px 24px;color:var(--reader-text);}.load-reader-tools {display:flex;justify-content:space-between;align-items:center;margin-bottom:50px;}.load-circle {width:38px;height:38px;border-radius:50%;}.load-reader>.load-title {width:50%;margin:0 auto 38px;}.load-reader>.load-lines {margin-bottom:32px;}.load-view-read .load-label {color:var(--reader-text);opacity:.6;}.load-view-read .load-shape {background-image:linear-gradient(105deg,rgba(156,131,195,.08) 20%,rgba(156,131,195,.22) 45%,rgba(156,131,195,.08) 70%);}
.load-compact {min-height:0;padding:16px 0;width:100%;}.load-compact .load-label {margin-bottom:16px;}.load-compact .load-row {padding:15px;}.load-compact .load-avatar {width:38px;height:38px;}.load-compact .load-books {grid-template-columns:repeat(3,minmax(0,1fr));}
@media(max-width:700px){.load-books {grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;}.load-detail-hero {gap:20px;}.load-detail-hero>.load-cover {width:120px;}.load-detail-copy>.load-title {width:95%;height:24px;}.context-loading .load-tabs {gap:8px;}.load-view-read {padding-top:18px;}.load-view-read .load-label {margin-bottom:18px;}.load-row {padding:16px;}}
@media(prefers-reduced-motion:reduce){.context-loading .load-shape {animation:none;}}
.social-status {display:grid;gap:12px;}
.social-status .provider-button {margin:0;width:100%;text-align:center;}

/* Reserve the cover surface while the network image decodes. */
.cover,.hero-book,.chapter-cover-link,.continue-cover{background:linear-gradient(135deg,#1e1936,#111827);}

/* Chapter sponsorship: separated from text and reading controls. */
.chapter-ad-panel { margin: 24px auto 32px; max-width: 728px; clear: both; }
.chapter-ad-label { display:block; margin:0 0 7px; text-align:center; font:500 10px/1.4 Arial,sans-serif; letter-spacing:.14em; opacity:.6; }
.chapter-ad-link { display:block; overflow:hidden; border:1px solid currentColor; border-color:color-mix(in srgb, currentColor 16%, transparent); border-radius:12px; }
.chapter-ad-link img { display:block; width:100%; height:auto; aspect-ratio:728/90; object-fit:contain; margin:0; }
.chapter-ad-link:focus-visible { outline:3px solid #ac66ff; outline-offset:4px; }

.chapter-network-ad { display:flex; flex-direction:column; align-items:center; min-height:71px; }
.chapter-network-ad iframe { display:block; border:0; max-width:100%; background:transparent; border-radius:8px; }
@media(min-width:760px){.chapter-network-ad{min-height:111px;}}

.chapter-network-ad {width:calc(100% + 16px);position:relative;left:50%;transform:translateX(-50%);margin-left:0;margin-right:0;}
