:root {
  --bg: #030914;
  --surface: #0a1829;
  --surface-soft: #12253d;
  --control-bg: #12253d;
  --text: #f3f7ff;
  --muted: rgba(227, 236, 250, 0.6);
  --muted-weak: rgba(227, 236, 250, 0.38);
  --control-muted: rgba(227, 236, 250, 0.6);
  --line: rgba(181, 205, 235, 0.28);
  --line-strong: rgba(216, 229, 247, 0.58);
}

body[data-theme="light"] {
  --bg: #f3f4f6;
  --surface: #ffffff;
  --surface-soft: #e7eaef;
  --control-bg: #e1e5eb;
  --text: #141414;
  --muted: rgba(20, 20, 20, 0.62);
  --muted-weak: rgba(20, 20, 20, 0.34);
  --control-muted: rgba(20, 20, 20, 0.48);
  --line: rgba(20, 20, 20, 0.24);
  --line-strong: rgba(20, 20, 20, 0.38);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  min-width: 320px;
  overflow-y: scroll;
  background: var(--bg);
  color: var(--text);
  font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: inherit;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 999px;
  background-color: var(--control-bg);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 18px 18px;
  color: var(--text);
  cursor: pointer;
}

.theme-toggle:hover {
  box-shadow: inset 0 0 0 1px var(--line);
}

.theme-toggle:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 1px var(--line), 0 0 0 2px color-mix(in srgb, var(--line) 65%, transparent);
}

body[data-theme="dark"] .theme-toggle {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='4'/%3E%3Cpath d='M12 2v3'/%3E%3Cpath d='M12 19v3'/%3E%3Cpath d='M4.9 4.9l2.1 2.1'/%3E%3Cpath d='M17 17l2.1 2.1'/%3E%3Cpath d='M2 12h3'/%3E%3Cpath d='M19 12h3'/%3E%3Cpath d='M4.9 19.1L7 17'/%3E%3Cpath d='M17 7l2.1-2.1'/%3E%3C/svg%3E");
}

body[data-theme="light"] .theme-toggle {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23757c86' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M20 14.5A8.5 8.5 0 1 1 9.5 4 7 7 0 0 0 20 14.5Z'/%3E%3C/svg%3E");
}

.layout {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.main {
  flex: 1;
}

.header {
  min-width: 320px;
}

.header__wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 19px 60px 17px;
  background: var(--surface);
}

.header__wrapper_has-search {
  width: 100%;
}

.header__wrapper_compact {
  width: 100%;
}

.header__inner {
  display: flex;
  align-items: center;
  min-height: 40px;
}

.header__inner_brand {
  flex: 0 1 auto;
  justify-content: flex-start;
  min-width: 0;
  overflow: hidden;
}

.header__inner_actions {
  min-width: 0;
  flex: 1 1 auto;
  justify-content: flex-end;
  gap: 12px;
}

.main-title-group {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  white-space: nowrap;
}

.main-title {
  flex: 0 1 auto;
  min-width: 0;
  margin: 0;
  font-size: 30px;
  line-height: 36px;
  font-weight: 400;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-version {
  color: var(--control-muted);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
  flex: 0 0 auto;
  font-style: italic;
  line-height: 1;
}

.home-link {
  display: block;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  text-decoration: none;
}

.home-link:hover {
  opacity: 0.6;
}

.header-search {
  width: 100%;
  min-width: 0;
  max-width: 920px;
  margin-left: auto;
}

.header-search_desktop {
  flex: 1 1 920px;
}

.header-search__field {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 38px;
  width: 100%;
  border-radius: 999px;
  border: none;
  background: var(--control-bg);
  padding: 0 10px 0 12px;
  cursor: text;
}

.header-search__field:focus-within {
  box-shadow: inset 0 0 0 1px var(--line);
}

.header-search__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  color: var(--control-muted);
}

.header-search__icon svg {
  width: 18px;
  height: 18px;
}

.header-search__input {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 16px;
  line-height: 1;
  padding: 0;
  appearance: none;
}

.header-search__input::placeholder {
  color: var(--control-muted);
}

.header-search__input:focus {
  outline: none;
}

.header-search__shortcut {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-width: 46px;
  height: 24px;
  border-radius: 8px;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--control-muted);
  font-size: 13px;
  line-height: 1;
  letter-spacing: 0.02em;
  padding: 0 7px;
}

.header-search-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  border: none;
  border-radius: 999px;
  background-color: var(--control-bg);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 18px 18px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m16 16 4.5 4.5'/%3E%3C/svg%3E");
  cursor: pointer;
}

body[data-theme="light"] .header-search-toggle {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23141414' stroke-width='1.8' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m16 16 4.5 4.5'/%3E%3C/svg%3E");
}

.header-search-toggle:hover,
.header-search-toggle_active {
  box-shadow: inset 0 0 0 1px var(--line);
}

.header-search-toggle:focus-visible {
  outline: none;
  box-shadow: inset 0 0 0 1px var(--line), 0 0 0 2px color-mix(in srgb, var(--line) 65%, transparent);
}

.header-search-panel {
  padding: 0 60px 17px;
  background: var(--surface);
}

.header-search_mobile {
  min-width: 0;
  max-width: none;
}

.header-search__field_mobile .header-search__shortcut {
  display: none;
}

@media (max-width: 1220px) {
  .header-search_desktop {
    display: none;
  }

  .header-search-toggle {
    display: inline-flex;
  }
}

.link {
  display: inline-block;
  position: relative;
  text-decoration: none;
  font-size: 20px;
  line-height: 24px;
}

.link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  border-bottom: 1px solid var(--line);
}

.link:hover::after {
  border-color: var(--text);
}

.main__inner {
  padding: 0 60px;
}

.intro {
  max-width: 1000px;
  margin: 28px 0 24px;
  font-size: 30px;
  line-height: 1.2;
}

.filters-pane {
  margin-top: 20px;
  margin-bottom: 18px;
}

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

.main-search__field,
.custom-select {
  height: 38px;
  border-radius: 999px;
  border: none;
  color: var(--text);
  background: var(--control-bg);
  padding: 0 18px;
  font-size: 16px;
}

.main-search__field {
  flex: 1 1 340px;
}

.main-search__field::placeholder {
  color: var(--control-muted);
}

.main-search__field:focus,
.custom-select:focus {
  outline: none;
  box-shadow: inset 0 0 0 1px var(--line);
}

.custom-select {
  min-width: 200px;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='white' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 6 4 4 4-4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px 16px;
  padding-right: 44px;
}

.custom-select_state_placeholder {
  color: var(--control-muted);
}

body[data-theme="light"] .custom-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23757c86' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 6 4 4 4-4'/%3E%3C/svg%3E");
}

.main-bar {
  margin-top: 20px;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.book-counter {
  margin: 0;
  font-size: 40px;
  line-height: 48px;
}

.sort-bar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.sort-bar__item {
  height: 32px;
  border-radius: 20px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  font-size: 15px;
  line-height: 20px;
  padding: 0 14px;
  cursor: pointer;
}

.sort-bar__item:hover {
  border-color: var(--line);
}

.sort-bar__item_state_active {
  background: var(--surface-soft);
}

.books {
  position: relative;
  margin: 27px 0 40px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 34px 24px;
}

.books__item {
  width: 100%;
}

.books__item[hidden] {
  display: none;
}

.books__link {
  display: inline-flex;
  flex-direction: column-reverse;
  width: 100%;
  text-decoration: none;
  color: var(--text);
}

.books__wrapper {
  overflow: hidden;
}

.books__wrapper:first-child {
  margin-bottom: 10px;
}

.books__wrapper_meta {
  overflow: visible;
}

.books__inner {
  margin: 18px 20px 10px 0;
}

.books__title {
  margin: 0;
  display: inline;
  vertical-align: middle;
  font-size: 24px;
  line-height: 1.35;
  font-weight: 400;
  background-image: linear-gradient(90deg, var(--muted-weak), var(--muted-weak));
  background-position: 0 92%;
  background-repeat: repeat-x;
  background-size: 100% 1px;
}

.books__paper-badge {
  --tooltip-shift: 0px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 21px;
  height: 21px;
  color: var(--text);
  cursor: help;
  flex: 0 0 auto;
  margin-right: 10px;
  vertical-align: middle;
}

.books__paper-badge svg {
  width: 100%;
  height: 100%;
  display: block;
}

.books__paper-tooltip {
  position: absolute;
  left: 50%;
  top: calc(100% + 8px);
  transform: translateX(calc(-50% + var(--tooltip-shift)));
  min-width: 220px;
  max-width: min(280px, calc(100vw - 24px));
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font-size: 13px;
  line-height: 1.3;
  white-space: normal;
  opacity: 0;
  pointer-events: none;
  z-index: 30;
}

.books__paper-badge:hover .books__paper-tooltip,
.books__paper-badge:focus-visible .books__paper-tooltip {
  opacity: 1;
}

.books__paper-badge:focus-visible {
  outline: 1px solid var(--line-strong);
  outline-offset: 3px;
  border-radius: 4px;
}

.books__meta {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.3;
}

.books__year {
  margin: 10px 0 0;
  font-size: 16px;
  line-height: 21px;
  color: var(--muted);
}

.books__thumb {
  width: 100%;
  background: var(--surface-soft);
}

.books__link:hover .books__title {
  background-image: linear-gradient(90deg, var(--text), var(--text));
}

.books__link:hover .books__thumb {
  opacity: 0.82;
}

.page-notification {
  margin: 24px 0 48px;
  font-size: 26px;
  line-height: 1.2;
  color: var(--muted);
}

.book {
  margin: 60px 0;
}

.book__header {
  margin: 0 60px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  column-gap: 28px;
  align-items: flex-start;
}

.book__wrapper {
  margin-bottom: 30px;
  min-width: 0;
}

.book__wrapper:first-child {
  min-width: 0;
}

.book__wrapper:last-child {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 30px;
}

.book__wrapper:first-child .book__inner {
  padding-right: 28px;
}

.book__wrapper:last-child .book__inner {
  width: 100%;
  max-width: 380px;
}

.book__title {
  margin: 12px 0 20px;
  font-size: 40px;
  line-height: 1.08;
  font-weight: 400;
}

.book__author,
.book__publishing,
.book__description {
  margin: 0 0 10px;
  font-size: 20px;
  line-height: 1.45;
  color: var(--muted);
}

.book__description {
  margin-top: 18px;
  max-width: calc(100% - 24px);
}

.book__control-bar {
  margin-top: 28px;
}

.book-read__button {
  display: inline-flex;
  align-items: center;
  min-height: 60px;
  padding: 0 40px;
  border-radius: 100px;
  border: 1px solid transparent;
  background: var(--surface-soft);
  color: var(--text);
  font-size: 24px;
  text-decoration: none;
}

.book-read__button:hover {
  border-color: var(--line);
}

.book__cover {
  width: 100%;
  max-width: 380px;
  margin-left: auto;
}

.book__pages {
  margin: 50px 60px 60px;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
}

.scroll-top-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  margin: 0 60px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  color: var(--text);
  text-decoration: none;
  font-size: 16px;
  line-height: 1;
}

.scroll-top-button:hover {
  border-color: var(--text);
}

.book__page {
  width: 32%;
  margin: 0 2% 33px 0;
}

.book__page:nth-child(3n) {
  margin-right: 0;
}

.book__page-inner:hover {
  opacity: 0.8;
}

.page-pane {
  margin-top: 4px;
  height: 27px;
  display: flex;
  align-items: center;
}

.page-number {
  margin: 0;
  color: var(--text);
  font-size: 24px;
}

.layout_reader {
  background: var(--bg);
}

.page {
  margin: 0 24px 30px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}

.page__header {
  width: 100%;
  margin: 24px 0;
  display: flex;
  align-items: center;
}

.page__inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.page__inner:first-child {
  flex: 0 0 62px;
  justify-content: flex-start;
}

.page__inner:nth-child(2) {
  flex: 1 1 auto;
}

.page__inner:last-child {
  flex: 0 0 auto;
  justify-content: flex-end;
  gap: 12px;
}

.page__title {
  margin: 0;
  max-width: 65vw;
  font-size: 16px;
  line-height: 1.4;
  font-weight: 400;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.page__link_back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  opacity: 0.7;
  text-decoration: none;
  color: var(--text);
}

.page__link_back {
  width: 36px;
  height: 36px;
}

.page__link_back::before {
  content: "";
  width: 14px;
  height: 14px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}

.page__link_back:hover {
  opacity: 1;
}

.page__viewport {
  position: relative;
  width: 100%;
  margin: 0 0 26px;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0;
}

.page__image-link {
  display: inline-flex;
  justify-content: center;
  width: 100%;
  max-width: 1200px;
}

.page__image {
  width: auto;
  max-width: 100%;
  margin: 0 auto;
}

.page__switch {
  position: fixed;
  top: 50vh;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--text);
  opacity: 0.8;
  text-decoration: none;
  z-index: 120;
}

.page__switch::before {
  content: "";
  width: 12px;
  height: 12px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
}

.page__switch_prev {
  left: 14px;
}

.page__switch_prev::before {
  transform: rotate(45deg);
  margin-left: 4px;
}

.page__switch_next {
  right: 14px;
}

.page__switch_next::before {
  transform: rotate(-135deg);
  margin-right: 4px;
}

.page__switch:hover {
  opacity: 1;
  border-color: var(--text);
}

.page__content {
  width: min(100%, 980px);
  margin-bottom: 120px;
  color: var(--muted);
  font-size: 20px;
  line-height: 1.55;
}

.page__content p {
  margin: 0 0 14px;
}

.page-slider {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 20px 20px 20px 24px;
  background: var(--bg);
}

.page-slider__wrapper {
  overflow: hidden;
  flex: 1 1 auto;
}

.page-slider__list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}

.page-slider__list::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.page-slider__item {
  flex: 0 0 auto;
}

.page-slider__link {
  display: flex;
  flex-direction: column;
  text-decoration: none;
}

.page-slider__inner {
  height: 55px;
  min-width: 45px;
}

.page-slider__thumb {
  max-height: 100%;
  border: 1px solid transparent;
}

.page-slider__item_active .page-slider__thumb {
  border-color: var(--text);
}

.page-slider .page-number {
  font-size: 12px;
  margin-right: 0;
  opacity: 0.5;
}

.page-slider__item_active .page-number {
  opacity: 1;
}

.page-slider__counter {
  color: var(--text);
  flex: 0 0 66px;
  text-align: right;
  font-size: 14px;
}

.footer_main {
  margin: 0 62px;
  padding: 36px 0;
  display: flex;
  justify-content: center;
}

.footer__column_als-logo {
  max-width: 460px;
  color: var(--text);
  text-align: center;
  font-size: 18px;
  line-height: 24px;
  opacity: 0.75;
}

@media (max-width: 850px) {
  .header__wrapper {
    padding: 19px 30px 17px;
  }

  .header-search-panel {
    padding: 0 30px 17px;
  }

  .main__inner {
    padding: 0 30px;
  }

  .footer_main {
    margin: 0 34px;
  }

  .book {
    margin: 30px 0;
  }

  .book__header {
    margin: 0 30px;
    grid-template-columns: 1fr;
    column-gap: 0;
  }

  .book__wrapper {
    width: 100%;
  }

  .book__wrapper:first-child .book__inner {
    padding-right: 0;
  }

  .book__description {
    max-width: none;
  }

  .book__pages {
    margin: 40px 30px 60px;
  }

  .scroll-top-button {
    margin: 0 30px;
  }

  .book__page {
    width: 49%;
    margin-right: 2%;
  }

  .book__page:nth-child(3n) {
    margin-right: 2%;
  }

  .book__page:nth-child(2n) {
    margin-right: 0;
  }
}

@media (max-width: 720px) {
  .header__wrapper {
    padding: 17px 30px 11px;
  }

  .main-title-group {
    gap: 8px;
  }

  .main-title {
    font-size: 24px;
    line-height: 1.2;
  }

  .site-version {
    font-size: 18px;
  }

  .intro {
    font-size: 24px;
  }

  .books {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  }

  .book__title {
    font-size: 38px;
  }

  .book__author,
  .book__publishing,
  .book__description {
    font-size: 21px;
  }
}

@media (max-width: 500px) {
  body {
    min-width: 100vw;
  }

  .header__wrapper {
    padding: 17px 15px 11px;
  }

  .header__wrapper_has-search,
  .header__wrapper_compact {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .main-title-group {
    gap: 4px 6px;
  }

  .header__wrapper_has-search .header__inner_brand,
  .header__wrapper_has-search .home-link,
  .header__wrapper_has-search .main-title-group {
    min-width: 0;
    max-width: 100%;
  }

  .header__wrapper_compact .header__inner_brand,
  .header__wrapper_compact .home-link,
  .header__wrapper_compact .main-title-group {
    min-width: 0;
    max-width: 100%;
  }

  .header__inner_actions {
    gap: 8px;
  }

  .main-title {
    font-size: clamp(19px, 6.9vw, 24px);
    line-height: 1.12;
  }

  .site-version {
    font-size: clamp(14px, 4.1vw, 18px);
  }

  .header__wrapper_has-search .main-title {
    font-size: clamp(15px, 5.2vw, 20px);
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .header__wrapper_has-search .site-version {
    font-size: clamp(11px, 3.1vw, 14px);
    flex: 0 0 auto;
  }

  .header__wrapper_compact .main-title {
    font-size: clamp(16px, 6vw, 21px);
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .header__wrapper_compact .site-version {
    font-size: clamp(12px, 3.4vw, 15px);
    flex: 0 0 auto;
  }

  .header-search-panel {
    padding: 0 15px 14px;
  }

  .header-search__field {
    gap: 8px;
    height: 38px;
    padding: 0 9px 0 12px;
  }

  .header-search__icon {
    width: 18px;
    height: 18px;
  }

  .header-search__icon svg {
    width: 18px;
    height: 18px;
  }

  .header-search__input {
    font-size: 16px;
  }

  .header-search__shortcut {
    min-width: 44px;
    height: 24px;
    font-size: 12px;
    padding: 0 6px;
  }

  .main__inner {
    padding: 0 15px;
  }

  .filters {
    gap: 8px;
  }

  .filters-pane {
    margin-top: 18px;
  }

  .main-search__field,
  .custom-select {
    width: 100%;
  }

  .custom-select {
    min-width: 0;
  }

  .books {
    margin-top: 30px;
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .intro {
    margin-top: 22px;
    font-size: 20px;
    line-height: 1.25;
  }

  .book {
    margin: 40px 0;
  }

  .book__header {
    margin: 0 15px;
  }

  .book__wrapper {
    margin-bottom: 18px;
  }

  .book__title {
    margin-top: 0;
    font-size: 30px;
    line-height: 1.1;
  }

  .book__author,
  .book__publishing,
  .book__description {
    margin-bottom: 6px;
    font-size: 20px;
    line-height: 1.45;
    font-weight: 300;
  }

  .book-read__button {
    min-height: 46px;
    padding: 0 24px;
    font-size: 20px;
  }

  .book__pages {
    margin: 22px 15px;
  }

  .scroll-top-button {
    margin: 0 15px;
    min-height: 38px;
    font-size: 15px;
  }

  .book__page {
    width: calc(100vw - 30px);
    margin-right: 0;
  }

  .page {
    margin: 0 15px 15px;
  }

  .page__viewport {
    padding: 0;
  }

  .page__switch {
    width: 34px;
    height: 34px;
  }

  .page__switch_prev {
    left: 8px;
  }

  .page__switch_next {
    right: 8px;
  }

  .page__title {
    display: none;
  }

  .page__content {
    margin-bottom: 164px;
    font-size: 18px;
  }

  .page-slider {
    flex-wrap: wrap;
  }

  .page-slider__counter {
    margin-top: 10px;
    text-align: left;
    flex-basis: 100%;
  }

  .footer_main {
    margin: 0 18px;
  }
}

@media (max-width: 430px) {
  .main-title {
    font-size: clamp(16px, 5.6vw, 18px);
    line-height: 1.08;
  }

  .site-version {
    font-size: clamp(10px, 2.8vw, 12px);
  }

  .header__wrapper_has-search .main-title,
  .header__wrapper_compact .main-title {
    font-size: clamp(14px, 5vw, 16px);
  }

  .header__wrapper_has-search .site-version,
  .header__wrapper_compact .site-version {
    font-size: clamp(9px, 2.4vw, 10px);
  }
}

@media (max-width: 390px) {
  .header__wrapper_has-search .main-title,
  .header__wrapper_compact .main-title {
    font-size: clamp(12px, 4.4vw, 14px);
    line-height: 1.04;
  }

  .header__wrapper_has-search .site-version,
  .header__wrapper_compact .site-version {
    font-size: clamp(8px, 2vw, 9px);
  }
}
