:root {
  --mtm-blue: #185fa8;
  --mtm-line: #d8dde4;
  --mtm-ink: #242b35;
}
/* Keep the WordPress admin bar, but hide the public theme header/menu while reading. */
body.single-mtm_epub_book .site-header,
body.single-mtm_epub_book #masthead,
body.single-mtm_epub_book header#site-header,
body.single-mtm_epub_book .main-header-bar,
body.single-mtm_epub_book .header-main-layout-1,
body.single-mtm_epub_book .ct-header,
body.single-mtm_epub_book .kadence-header-wrap,
body.single-mtm_epub_book .wp-site-blocks > header,
body.single-mtm_epub_book .wp-site-blocks > .wp-block-template-part:first-child {
  display: none !important;
}
.mtm-library-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(165px, 1fr));
  gap: 24px;
}
.mtm-book-card {
  display: flex;
  flex-direction: column;
  gap: 7px;
  color: var(--mtm-ink);
  text-decoration: none;
}
.mtm-cover {
  aspect-ratio: 2/3;
  background: #edf2f7;
  border: 1px solid #d8dee7;
  border-radius: 6px;
  display: grid;
  place-items: center;
  overflow: hidden;
  box-shadow: 0 5px 15px #1112;
}
.mtm-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.mtm-book-card strong {
  line-height: 1.3;
}
.mtm-book-card small {
  color: #6e7681;
}
.mtm-epub-app {
  --mtm-font-scale: 110%;
  --mtm-toc-font-scale: 75%;
  --mtm-toc-width: 372px;
  --mtm-reader-width: 100%;
  --mtm-line-height-scale: .86;
  --mtm-toolbar-height: 44px;
  border: 0;
  background: #27354a;
  color: var(--mtm-ink);
  height: calc(100vh - var(--mtm-toolbar-height));
  min-height: 620px;
  display: grid;
  /* v0.9.72: toolbar is position:fixed and therefore is not a grid item.
     Keep a single definite grid row for the reader workspace; otherwise Edge can
     place the workspace in the implicit auto row when the viewport crosses the
     desktop breakpoint, leaving the 1fr row empty and collapsing the scroll pane. */
  grid-template-rows: minmax(0, 1fr);
  position: relative;
  overflow: hidden;
}
.mtm-toolbar {
  min-height: var(--mtm-toolbar-height);
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 5px 12px;
  border-bottom: 1px solid #31415a;
  background: #111c2e;
  color: #e7edf6;
  position: fixed;
  z-index: 99998;
  top: 0;
  left: 0;
  right: 0;
  box-sizing: border-box;
  box-shadow: 0 2px 8px #0005;
}
body.admin-bar.single-mtm_epub_book .mtm-toolbar { top: 32px; }
body.admin-bar.single-mtm_epub_book .mtm-epub-app { height: calc(100vh - 32px - var(--mtm-toolbar-height)); }
/* Không tạo thêm một hàng trắng bên dưới ribbon cố định. */
.mtm-toolbar-spacer { display: none; height: 0; }
.mtm-toolbar button {
  border: 1px solid #344766;
  background: #18263d;
  color: #eef3fa;
  border-radius: 6px;
  padding: 5px 9px;
}
.mtm-toolbar button:disabled {
  opacity: .42;
  cursor: default;
}
.mtm-epub-back:not(:disabled) {
  border-color: #5075a8;
  cursor: pointer;
}
.mtm-search-toggle,
.mtm-catalog-search-toggle {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 6px;
  white-space: nowrap;
}
.mtm-search-toggle .mtm-search-icon,
.mtm-catalog-search-toggle .mtm-search-icon {
  display: block;
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.mtm-catalog-link,
.mtm-home-link,
.mtm-download-link {
  color: #eef3fa;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  font-size: 13px;
  line-height: 1.2;
}
.mtm-download-link{display:inline-flex;align-items:center;border:1px solid #344766;border-radius:6px;background:#18263d;padding:5px 9px}
.mtm-home-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.mtm-home-link svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.mtm-toolbar input[type="range"] { accent-color: #d6aa27; }
.mtm-toolbar output { color: #eef3fa; }
.mtm-toolbar-end { display:inline-flex;align-items:center;gap:8px;margin-left:auto;white-space:nowrap; }
/* Theme WordPress có thể đặt màu chữ label/output thành đen; luôn giữ ribbon dễ đọc. */
body.single-mtm_epub_book .mtm-toolbar,
body.single-mtm_epub_book .mtm-toolbar label,
body.single-mtm_epub_book .mtm-toolbar output,
body.single-mtm_epub_book .mtm-toolbar a,
body.single-mtm_epub_book .mtm-toolbar button,
body.single-mtm_epub_book .mtm-toolbar span {
  color: #fff !important;
  text-shadow: none !important;
}
.mtm-catalog-link:hover,
.mtm-catalog-link:focus,
.mtm-home-link:hover,
.mtm-home-link:focus {
  text-decoration: underline;
}
.mtm-epub-catalog {
  display: block;
  width: 100%;
}
.mtm-epub-catalog {
  font-size: 90%;
}
.mtm-catalog-group {
  break-inside: avoid;
  min-width: 0;
}
.mtm-catalog-columns{column-count:3;column-gap:40px;width:100%}.mtm-catalog-columns>.mtm-catalog-group{display:inline-block;width:100%;margin:0 0 30px;vertical-align:top}.mtm-catalog-columns>.mtm-catalog-group.mtm-category-selected{display:block;column-span:all}.mtm-catalog-user-actions{display:flex;align-items:flex-start;justify-content:flex-end;gap:10px;flex-wrap:wrap}.mtm-catalog-login-wrap{display:flex;flex-direction:column;align-items:center;gap:5px}.mtm-catalog-login{display:inline-flex;align-items:center;min-height:39px;padding:8px 15px;border-radius:7px;background:#334155;color:#fff!important;font-family:"Bookerly","Noto Serif","DejaVu Serif",Georgia,"Times New Roman",serif!important;font-size:14px!important;font-weight:700!important;line-height:1.2!important;text-decoration:none}.mtm-catalog-login-note{max-width:390px;color:#5b6470;font-family:"Bookerly","Noto Serif","DejaVu Serif",Georgia,"Times New Roman",serif;font-size:13px;line-height:1.35;text-align:center}.mtm-catalog-login:hover,.mtm-catalog-login:focus{background:#1e293b;color:#fff!important}.mtm-private-badge{font-size:.8em;white-space:nowrap}.mtm-inline-private{display:grid;gap:7px}.mtm-inline-private>span{display:flex;justify-content:space-between;gap:12px}.mtm-inline-private>label{display:flex;align-items:center;gap:7px}
@media(max-width:1024px){.mtm-catalog-columns{column-count:2}}
@media(max-width:600px){.mtm-catalog-columns{column-count:1}}
.mtm-catalog-group h2 {
  margin: 0 0 18px;
  padding-bottom: 9px;
  border-bottom: 1px solid #e5e7eb;
  color: var(--mtm-ink);
  font-size: clamp(1.305rem, 1.8vw, 1.8rem);
}
.mtm-catalog-group ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.mtm-catalog-group.mtm-category-selected { grid-column: 1 / -1; }
.mtm-catalog-group.mtm-category-selected ul {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 40px;
}
.mtm-catalog-group li {
  margin: 0 0 14px;
  line-height: 1.45;
}
.mtm-catalog-group a.mtm-catalog-book {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 5px;
  border-radius: 7px;
  text-decoration: none;
}
.mtm-catalog-group a.mtm-catalog-book:hover,
.mtm-catalog-group a.mtm-catalog-book:focus {
  background: #eef6fd;
}
.mtm-catalog-thumb {
  width: 52px;
  aspect-ratio: 2 / 3;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid #d8dee7;
  border-radius: 3px;
  background: #edf2f7;
  box-shadow: 0 2px 7px #1112;
}
.mtm-catalog-thumb img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}
.mtm-catalog-placeholder {
  color: #718096;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .04em;
}
.mtm-catalog-actions{grid-column:1/-1;display:flex;align-items:end;justify-content:space-between;gap:16px;margin:0 0 18px}.mtm-catalog-pickers{display:flex;align-items:end;gap:14px;flex-wrap:wrap}.mtm-category-picker{display:grid;gap:5px;color:#3f4a58;font-weight:600}.mtm-category-picker select{min-width:min(360px,72vw);padding:9px 34px 9px 11px;border:1px solid #cbd5e1;border-radius:7px;background:#fff;color:#202a36}.mtm-view-picker{display:flex;align-items:center;gap:14px;min-height:42px;margin:0;padding:8px 12px;border:1px solid #cbd5e1;border-radius:7px}.mtm-view-picker legend{padding:0 4px;color:#3f4a58;font-weight:700}.mtm-view-picker label{display:flex;align-items:center;gap:6px;white-space:nowrap}.mtm-view-picker input{width:18px;height:18px}.mtm-catalog-search-toggle{background:#0876d1!important;color:#fff!important;border:0!important;border-radius:7px;padding:9px 15px!important;font-weight:700;cursor:pointer}.mtm-catalog-search-toggle:hover,.mtm-catalog-search-toggle:focus{background:#065fa9!important}.mtm-search-results:not(:empty){max-height:42vh;overflow:auto;margin:8px 0 18px;border:1px solid #dfe3e8;border-radius:7px}.mtm-search-results:not(:empty)+form{border-top:1px solid #dfe3e8;padding-top:14px}
.mtm-catalog-book-text {
  min-width: 0;
}
.mtm-catalog-inline-bar{grid-column:1/-1;display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:0 0 12px}.mtm-catalog-inline-toggle{background:#0876d1!important;color:#fff!important;border:0!important;border-radius:5px;padding:10px 18px!important;font-weight:700;cursor:pointer}.mtm-catalog-selected-count{color:#52606d}.mtm-epub-catalog.is-inline-editing .mtm-catalog-group li{position:relative;padding-left:30px}.mtm-catalog-edit-check{position:absolute;left:4px;top:20px;width:18px;height:18px}.mtm-catalog-row-edit{margin:4px 0 5px;background:none;border:0;color:#2271b1;text-decoration:underline;cursor:pointer;padding:0}.mtm-catalog-inline-panel{grid-column:1/-1;background:#f6f7f7;border:1px solid #c3c4c7;border-left:4px solid #2271b1;padding:16px 18px;margin:8px 0 18px;box-shadow:0 1px 2px #0000000d}.mtm-catalog-inline-panel h3{margin:0 0 14px}.mtm-catalog-inline-panel form{display:grid;grid-template-columns:repeat(2,minmax(220px,1fr));gap:13px 18px}.mtm-inline-field{display:grid;gap:5px}.mtm-inline-field>span{display:flex;justify-content:space-between;gap:12px}.mtm-inline-field input[type=text]{width:100%;padding:8px 10px;border:1px solid #8c8f94;border-radius:4px;background:#fff}.mtm-inline-field small{color:#646970}.mtm-inline-apply{font-weight:400}.mtm-inline-status,.mtm-inline-actions{grid-column:1/-1;margin:0}.mtm-inline-actions{display:flex;justify-content:flex-end;gap:8px}@media(max-width:700px){.mtm-catalog-inline-panel form{grid-template-columns:1fr}}
@media(max-width:700px){.mtm-catalog-actions{align-items:stretch;flex-direction:column}.mtm-catalog-pickers{display:grid;grid-template-columns:1fr}.mtm-category-picker select{width:100%;min-width:0}.mtm-catalog-search-toggle{align-self:flex-start}}
.mtm-catalog-title {
  display: block;
  color: #0876d1;
  font-size: clamp(.778rem, 1.044vw, 1.044rem);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* The catalog owns the full content width; the public theme sidebar is not used here. */
body.mtm-epub-catalog-page #secondary,
body.mtm-epub-catalog-page #right-sidebar,
body.mtm-epub-catalog-page aside.sidebar,
body.mtm-epub-catalog-page .sidebar-primary,
body.mtm-epub-catalog-page .widget-area:not(.mtm-epub-catalog) {
  display: none !important;
}
body.mtm-epub-catalog-page #primary,
body.mtm-epub-catalog-page #main,
body.mtm-epub-catalog-page .content-area,
body.mtm-epub-catalog-page .site-main,
body.mtm-epub-catalog-page .site-content > .content-area {
  width: 100% !important;
  max-width: none !important;
  float: none !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}
body.mtm-epub-catalog-page .site-content{padding-top:0!important;margin-top:0!important}
body.mtm-epub-catalog-page .content-area,body.mtm-epub-catalog-page .site-main,body.mtm-epub-catalog-page article,body.mtm-epub-catalog-page .entry-content{margin-top:0!important}
body.mtm-epub-catalog-page .inside-article{padding-top:16px!important}
body.mtm-epub-catalog-page .entry-header{margin-top:0!important;margin-bottom:12px!important}
body.mtm-epub-catalog-page .entry-header h1{margin-top:0!important}
.mtm-catalog-book-text small {
  display: block;
  margin-top: 2px;
  color: #777;
  font-size: .828rem;
}
.mtm-toolbar label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  white-space: nowrap;
}
.mtm-toolbar input {
  width: 110px;
}
.mtm-search-dialog{position:fixed;inset:0;z-index:100002;background:#1118;display:grid;place-items:center;padding:18px}.mtm-search-dialog[hidden]{display:none}.mtm-search-panel{width:min(860px,96vw);max-height:88vh;overflow:auto;background:#fff;border-radius:10px;padding:20px;box-shadow:0 20px 70px #0005}.mtm-search-panel>header{display:flex;align-items:center;justify-content:space-between}.mtm-search-panel h3{margin:0}.mtm-search-close{font-size:24px}.mtm-search-query,.mtm-search-book-filter{width:100%!important;padding:10px;margin:12px 0}.mtm-search-modes{display:grid;grid-template-columns:1fr 1fr;gap:12px}.mtm-search-modes label{border:1px solid var(--mtm-line);border-radius:7px;padding:10px!important;text-align:center}.mtm-search-hint{margin:7px 0 14px;color:#687386;font-style:italic}.mtm-search-panel fieldset{display:grid;gap:8px}.mtm-search-panel label{display:block;margin:7px 0}.mtm-search-books{border:1px solid var(--mtm-line);padding:10px;margin:10px 0}.mtm-search-book-list{max-height:220px;overflow:auto;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px 14px}.mtm-search-submit{background:var(--mtm-blue)!important;color:#fff!important;padding:9px 16px!important}.mtm-search-status{margin:14px 0;color:#59636f}.mtm-search-book-group{border-top:1px solid #dfe3e8}.mtm-search-book-heading{display:flex;width:100%;justify-content:flex-start;align-items:center;padding:12px 6px!important;background:transparent!important;color:#126ba3!important;text-align:left;font-size:1.04rem;font-weight:700}.mtm-search-book-heading b{color:#667085}.mtm-search-book-heading:after{content:'▾';margin-left:auto;transition:transform .15s}.mtm-search-book-heading[aria-expanded="true"]:after{transform:rotate(180deg)}.mtm-search-result{display:block;padding:10px 8px 10px 20px;border-top:1px solid #edf0f2;text-decoration:none}.mtm-search-result:hover{background:#f5f9fc}.mtm-search-result-opened{border-left:4px solid var(--mtm-blue);padding-left:16px;background:#eef7ff}.mtm-search-result small{display:block;color:#7c3aed}.mtm-search-result p{margin:4px 0;color:var(--mtm-ink)}.mtm-search-hit{background:#ffd84d;color:#202020;border-radius:2px;padding:0 .08em}@media(max-width:700px){.mtm-search-book-list{grid-template-columns:1fr}.mtm-search-modes{grid-template-columns:1fr}}
.mtm-search-expand{background:var(--mtm-blue)!important;color:#fff!important;border:0!important;border-radius:7px;padding:9px 14px!important;font-weight:700;cursor:pointer}.mtm-search-dialog.is-minimized{inset:auto 18px 18px auto;background:transparent;display:block;padding:0;pointer-events:none}.mtm-search-dialog.is-minimized .mtm-search-panel{width:auto;max-height:none;overflow:visible;padding:8px;box-shadow:0 5px 24px #0004;pointer-events:auto}.mtm-search-dialog.is-minimized .mtm-search-panel>header{gap:8px}.mtm-search-dialog.is-minimized .mtm-search-panel h3,.mtm-search-dialog.is-minimized .mtm-search-panel>header~*{display:none}.mtm-search-dialog.is-minimized .mtm-search-expand{display:inline-block}.mtm-search-dialog.is-minimized .mtm-search-close{font-size:20px;padding:3px 8px!important}@media(max-width:700px){.mtm-search-dialog.is-minimized{right:10px;bottom:10px}.mtm-search-expand{padding:8px 11px!important}}
.mtm-reader-workspace {
  display: grid;
  grid-template-columns: var(--mtm-toc-width) 8px minmax(0, 1fr);
  height: 100%;
  min-height: 0;
  overflow: hidden;
  background: #27354a;
}
.mtm-toc {
  overflow: auto;
  padding: 18px 12px;
  background: #172338;
  color: #e8edf5 !important;
  font-family: "Bookerly", "Noto Serif", "DejaVu Serif", "Liberation Serif", Georgia, "Times New Roman", serif;
  font-size: var(--mtm-toc-font-scale);
}
.mtm-toc-resizer {
  position: relative;
  z-index: 4;
  width: 8px;
  min-width: 8px;
  cursor: col-resize;
  touch-action: none;
  background: #34445d;
  border-left: 1px solid #42536d;
  border-right: 1px solid #101a2a;
  transition: background-color .15s;
}
.mtm-toc-resizer::before { content: ""; position: absolute; inset: 0 -4px; }
.mtm-toc-resizer:hover,
.mtm-toc-resizer:focus,
.mtm-toc-resizer.is-dragging { outline: 0; background: #3b82c4; }
body.mtm-toc-resizing { cursor: col-resize !important; user-select: none !important; }
.mtm-toc-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 8px 12px;
}
.mtm-sidebar-tabs { display: flex; min-width: 0; gap: 3px; }
.mtm-sidebar-tab {
  border: 0 !important;
  border-bottom: 2px solid transparent !important;
  border-radius: 4px 4px 0 0;
  padding: 7px 9px !important;
  background: transparent !important;
  color: #b9c5d5 !important;
  font: 700 1em/1.2 inherit !important;
  box-shadow: none !important;
}
.mtm-sidebar-tab.is-active { border-bottom-color: #d6aa27 !important; color: #fff !important; background: #22314a !important; }
.mtm-toc-font-controls {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: system-ui, sans-serif;
  font-size: 12px;
  white-space: nowrap;
}
.mtm-toc-font-controls button {
  width: 28px;
  height: 28px;
  padding: 0 !important;
  border: 1px solid #40526e !important;
  border-radius: 5px;
  background: #22314a !important;
  color: #eef3fa !important;
  font: 700 17px/1 system-ui, sans-serif !important;
  box-shadow: none !important;
}
.mtm-toc-font-value {
  min-width: 34px;
  text-align: center;
  color: #c9d2df;
}
.mtm-toc-tree button {
  display: block;
  width: 100%;
  border: 0 !important;
  background: transparent !important;
  color: #e8edf5 !important;
  text-align: left;
  padding: 8px;
  border-radius: 5px;
  line-height: 1.35;
  font: inherit;
  box-shadow: none !important;
  text-shadow: none !important;
}
.mtm-toc-tree button:hover,
.mtm-toc-tree button:focus {
  background: #263752 !important;
  color: #fff !important;
}

.mtm-toc-tree button.is-current {
  background: #2d4f78 !important;
  color: #fff !important;
  box-shadow: inset 4px 0 0 #69b8ff !important;
  font-weight: 700;
}
.mtm-toc-tree button.is-current:hover,
.mtm-toc-tree button.is-current:focus {
  background: #365f8f !important;
}
.mtm-sidebar-panel[hidden] { display: none !important; }
.mtm-image-status { margin: 14px 8px; color: #66717d; font-style: italic; }
.mtm-image-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; padding: 2px 4px 14px; }
.mtm-image-list > .mtm-image-status { grid-column: 1 / -1; }
.mtm-image-item {
  min-width: 0;
  padding: 6px !important;
  border: 1px solid #d7dee7 !important;
  border-radius: 7px;
  background: #fff !important;
  color: var(--mtm-ink) !important;
  text-align: left;
  box-shadow: none !important;
}
.mtm-image-item:hover,.mtm-image-item:focus { border-color: #5793c5 !important; background: #edf5fb !important; }
.mtm-image-item img { display: block; width: 100%; height: 105px; object-fit: contain; margin: 0 0 6px; background: #fff; }
.mtm-image-item span { display: block; overflow: hidden; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.mtm-reader-main {
  min-width: 0;
  min-height: 0;
  overflow: auto;
  padding: 38px max(24px, 4vw) 60px;
  background: #27354a;
}
.mtm-reader-status {
  text-align: center;
  margin: 18vh auto;
  color: #66717d;
}
.mtm-reader-status.is-error {
  color: #a32626;
}
.mtm-reader-content {
  font-family: "Bookerly", "Segoe UI", "Noto Serif", "DejaVu Serif", serif;
  font-size: var(--mtm-font-scale);
  line-height: calc(1.68 * var(--mtm-line-height-scale));
  width: var(--mtm-reader-width);
  max-width: 100%;
  margin: auto;
  padding: 42px var(--mtm-page-margin, 4.5vw) 56px;
  background: #fff;
  color: var(--mtm-ink);
  box-shadow: 0 2px 12px #0004;
}
.mtm-reader-content p {
  margin-top: var(--mtm-paragraph-gap, 12px);
  margin-bottom: var(--mtm-paragraph-gap, 12px);
  text-align: justify;
}
.mtm-reader-content table {
  border-collapse: collapse;
  max-width: 100%;
  width: 100%;
}
.mtm-reader-content td,
.mtm-reader-content th {
  vertical-align: top;
  padding: 12px;
}
.mtm-reader-content img,
.mtm-reader-content svg {
  max-width: 100%;
  height: auto;
}
.mtm-reader-content h1,
.mtm-reader-content h2,
.mtm-reader-content h3,
.mtm-reader-content h4,
.mtm-reader-content h5,
.mtm-reader-content h6 {
  font-size: revert;
  line-height: 1.25;
}
.mtm-page-nav {
  width: var(--mtm-reader-width);
  max-width: 100%;
  margin: 42px auto 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.mtm-page-nav button {
  border: 1px solid #cbd3dc;
  background: #fff;
  color: var(--mtm-ink);
  padding: 8px 12px;
  border-radius: 6px;
}
.mtm-page-nav button:disabled {
  opacity: 0.35;
}
.mtm-epub-warning {
  padding: 12px;
  background: #fff4cf;
  border-left: 4px solid #d8a100;
}
/* Trang sách EPUB dùng toàn bộ vùng nội dung; không thay đổi sidebar ở các trang WordPress khác. */
body.single-mtm_epub_book #secondary,
body.single-mtm_epub_book .widget-area,
body.single-mtm_epub_book aside.sidebar,
body.single-mtm_epub_book .sidebar-primary {
  display: none !important;
}
body.single-mtm_epub_book #primary,
body.single-mtm_epub_book .content-area,
body.single-mtm_epub_book .site-main,
body.single-mtm_epub_book article.mtm_epub_book {
  width: 100% !important;
  max-width: none !important;
  float: none !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}
/* Bỏ phần tiêu đề, tác giả và ngày tháng do theme WordPress chèn trên trang đọc. */
body.single-mtm_epub_book article.mtm_epub_book > .entry-header,
body.single-mtm_epub_book article.mtm_epub_book > header,
body.single-mtm_epub_book article.mtm_epub_book .entry-title,
body.single-mtm_epub_book article.mtm_epub_book .entry-meta,
body.single-mtm_epub_book article.mtm_epub_book .byline,
body.single-mtm_epub_book article.mtm_epub_book .posted-on {
  display: none !important;
}
/* Thu hồi padding/margin của theme để khung đọc bắt đầu ngay dưới ribbon. */
body.single-mtm_epub_book .site-content,
body.single-mtm_epub_book .content-container,
body.single-mtm_epub_book #primary,
body.single-mtm_epub_book .content-area,
body.single-mtm_epub_book .site-main,
body.single-mtm_epub_book article.mtm_epub_book,
body.single-mtm_epub_book article.mtm_epub_book > .entry-content,
body.single-mtm_epub_book article.mtm_epub_book > .post-content {
  padding-top: 0 !important;
  margin-top: 0 !important;
}
body.single-mtm_epub_book article.mtm_epub_book > .entry-content,
body.single-mtm_epub_book article.mtm_epub_book > .post-content {
  padding-left: 0 !important;
  padding-right: 0 !important;
}
body.single-mtm_epub_book .site-content,
body.single-mtm_epub_book .content-container {
  max-width: none !important;
  width: 100% !important;
}
body.single-mtm_epub_book,
body.single-mtm_epub_book .site,
body.single-mtm_epub_book .site-content,
body.single-mtm_epub_book .content-container,
body.single-mtm_epub_book #primary,
body.single-mtm_epub_book .content-area,
body.single-mtm_epub_book .site-main,
body.single-mtm_epub_book article.mtm_epub_book,
.mtm-epub-app,
.mtm-reader-workspace,
.mtm-reader-main,
.mtm-reader-content {
  min-width: 0 !important;
  box-sizing: border-box;
}
@media (max-width: 900px) {
  .mtm-epub-catalog {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 34px;
  }
  .mtm-epub-app {
    height: calc(100vh - var(--mtm-toolbar-height));
    min-height: 540px;
  }
  .mtm-toolbar {
    gap: 8px;
    flex-wrap: wrap;
  }
  .mtm-toolbar label {
    display: none;
  }
  .mtm-reader-workspace {
    display: block;
    position: relative;
  }
  .mtm-toc-resizer { display: none; }
  .mtm-toc {
    position: absolute;
    z-index: 5;
    inset: 0 auto 0 0;
    width: min(86vw, 340px);
    transform: translateX(-102%);
    transition: transform 0.2s;
    box-shadow: 6px 0 18px #0002;
  }
  .mtm-toc-open .mtm-toc {
    transform: translateX(0);
  }
  .mtm-reader-main {
    height: 100%;
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
    padding: 18px 12px 36px;
  }
  .mtm-reader-content,
  .mtm-page-nav { width: 100%; max-width: 100% !important; }
  .mtm-reader-content { padding: 24px max(12px, var(--mtm-page-margin, 4.5vw)) 36px; }
  .mtm-reader-content p {
    text-align: left;
  }
}
@media (max-width: 640px) {
  .mtm-epub-catalog {
    grid-template-columns: 1fr;
  }
  .mtm-catalog-group.mtm-category-selected ul { grid-template-columns: 1fr; }
}
@media (min-width: 641px) and (max-width: 900px) {
  .mtm-catalog-group.mtm-category-selected ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 782px) {
  body.admin-bar.single-mtm_epub_book .mtm-toolbar { top: 46px; }
  body.admin-bar.single-mtm_epub_book .mtm-epub-app { height: calc(100vh - 46px - var(--mtm-toolbar-height)); }
}
.mtm-annotation-tools {
  position: fixed;
  z-index: 100000;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 7px;
  background: #20252b;
  border-radius: 9px;
  box-shadow: 0 6px 24px #0005;
  max-width: calc(100vw - 16px);
  flex-wrap: wrap;
}
.mtm-annotation-tools[hidden] {
  display: none;
}
.mtm-annotation-tools button {
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: #fff;
  color: #20252b;
  display: grid;
  place-items: center;
  font: 16px/1 Arial;
  cursor: pointer;
}
.mtm-annotation-tools .mtm-color {
  width: 25px;
  height: 25px;
  border-radius: 50%;
  border: 2px solid #fff;
}
.mtm-annotation-tools .mtm-color[aria-pressed="true"] {
  outline: 3px solid #fff;
  outline-offset: 2px;
  box-shadow: 0 0 0 5px #185fa8;
}
.mtm-annotation-tools .mtm-yellow {
  background: #f6df62;
}
.mtm-annotation-tools .mtm-blue {
  background: #7fc8f8;
}
.mtm-annotation-tools .mtm-pink {
  background: #f5a1bd;
}
.mtm-annotation-tools .mtm-orange {
  background: #f4ad62;
}
.mtm-tool-divider {
  width: 1px;
  height: 26px;
  background: #ffffff55;
  margin: 0 2px;
}
.mtm-style-check {
  width: 34px;
  height: 32px;
  border-radius: 5px;
  background: #fff;
  color: #20252b;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
  cursor: pointer;
  font: 16px/1 Arial;
}
.mtm-style-check input {
  width: 13px;
  height: 13px;
  margin: 0;
  accent-color: #185fa8;
}
.mtm-style-check:has(input:checked) {
  background: #dcecff;
  box-shadow: inset 0 0 0 2px #4c91d2;
}
.mtm-annotation-tools .mtm-apply-annotation {
  background: #dff3df;
  color: #12631f;
  font-weight: 700;
}
.mtm-annotation-tools .mtm-delete-annotation {
  background: #ffe2e2;
  color: #9c1c1c;
}
.mtm-annotation-tools .mtm-close-annotation { background:#e7e9ec;color:#343a40;font-size:20px; }
.mtm-note-dialog {
  position: fixed;
  z-index: 100001;
  inset: 0;
  background: #0007;
  display: grid;
  place-items: center;
  padding: 20px;
}
.mtm-note-dialog[hidden] {
  display: none;
}
.mtm-note-dialog > div {
  width: min(520px, 95vw);
  background: #fff;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 12px 40px #0005;
}
.mtm-note-dialog h3 {
  margin: 0 0 12px;
}
.mtm-note-dialog textarea {
  box-sizing: border-box;
  width: 100%;
  resize: vertical;
  padding: 10px;
  border: 1px solid #aeb7c2;
  border-radius: 6px;
  font: inherit;
}
.mtm-note-dialog p {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin: 12px 0 0;
}
.mtm-note-dialog button {
  padding: 8px 14px;
  border: 1px solid #b7c0cb;
  border-radius: 6px;
  background: #fff;
}
.mtm-note-dialog .mtm-note-save {
  background: var(--mtm-blue);
  color: #fff;
  border-color: var(--mtm-blue);
}
.mtm-reader-book-index {
  max-width: 1500px;
  margin: 42px auto;
  padding: 0 20px 36px;
}
.mtm-reader-book-index > h2 {
  margin-bottom: 24px;
}
.mtm-reader-category {
  margin: 0 0 30px;
}
.mtm-reader-category > h3 {
  padding-bottom: 8px;
  border-bottom: 1px solid var(--mtm-line);
}
.mtm-reader-book-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 10px 18px;
}
.mtm-reader-book-link {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 7px;
  border-radius: 6px;
  color: var(--mtm-ink);
  text-decoration: none;
}
.mtm-reader-book-link:hover,
.mtm-reader-book-link:focus,
.mtm-reader-book-link.is-current {
  background: #e8f1fa;
  color: #124f8e;
}
.mtm-reader-book-link.is-current {
  font-weight: 700;
}
.mtm-reader-book-thumb {
  width: 42px;
  aspect-ratio: 2/3;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #edf2f7;
  border: 1px solid #d8dee7;
  border-radius: 3px;
}
.mtm-reader-book-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* 0.9.14: honor JS filtering even when theme/plugin CSS gives groups a display value. */
.mtm-catalog-group[hidden]{display:none!important}


/* v0.9.25: Kindle-style collapsible TOC for tablets and narrow screens. */
.mtm-toc-toggle{
  display:inline-flex;align-items:center;gap:5px;white-space:nowrap;
  border:1px solid #42536d!important;border-radius:5px!important;
  background:#22314a!important;color:#fff!important;padding:6px 9px!important;
  font-weight:700;cursor:pointer;
}
.mtm-toc-toggle:hover,.mtm-toc-toggle:focus-visible{background:#304462!important;outline:2px solid #6ba8e7;outline-offset:1px}
@media (min-width: 1367px){
  .mtm-epub-app.mtm-toc-collapsed .mtm-reader-workspace{grid-template-columns:0 0 minmax(0,1fr)}
  .mtm-epub-app.mtm-toc-collapsed .mtm-toc,
  .mtm-epub-app.mtm-toc-collapsed .mtm-toc-resizer{display:none!important}
}
@media (max-width:1366px){
  /* v0.9.71: keep the overlay-TOC workspace and reader at a definite height.
     The previous 901-1366px band switched the workspace from grid to block
     without giving the reader main pane a height; Chromium could collapse the
     scroll pane while Firefox happened to recover it. */
  .mtm-reader-workspace{display:block!important;position:relative!important;height:100%!important;min-height:0!important}
  .mtm-toc-resizer{display:none!important}
  .mtm-toc{
    position:absolute!important;z-index:80!important;inset:0 auto 0 0!important;
    width:min(86vw,390px)!important;max-width:calc(100vw - 44px)!important;height:100%!important;
    transform:translateX(-103%);transition:transform .2s ease;
    box-shadow:8px 0 26px #0008;
  }
  .mtm-epub-app.mtm-toc-open .mtm-toc{transform:translateX(0)}
  .mtm-reader-main{width:100%!important;max-width:100vw!important;height:100%!important;min-height:0!important;overflow:auto!important}
  .mtm-toc-toggle span{display:none}
}

/* v0.9.27: touch navigation and native-selection-menu coexistence. */
@media (max-width:1600px){
  .mtm-reader-main{overscroll-behavior-x:contain}
}
@media (pointer:coarse){
  .mtm-reader-content, .mtm-reader-content *{
    -webkit-user-select:text;
    user-select:text;
  }
  .mtm-annotation-tools{
    max-width:calc(100vw - 16px);
    flex-wrap:wrap;
  }
}

.mtm-search-form-actions{display:flex;gap:8px;align-items:center}.mtm-search-form-actions .mtm-search-reset{background:#fff;color:#234f9d;border:1px solid #5678ad}.mtm-search-result-opened{outline:2px solid #f59e0b;outline-offset:-2px}.mtm-search-target{outline:2px solid #f59e0b!important;outline-offset:3px}

/* Home-page EPUB selection shortcode: [mtm_epub_home] */
.mtm-epub-home-books{margin:1.25rem 0 2rem}.mtm-epub-home-title{margin:0 0 1rem}.mtm-epub-home-grid{display:grid;grid-template-columns:repeat(auto-fill,150px);gap:22px 20px;justify-content:start;align-items:start}.mtm-epub-home-card{width:150px;min-width:0}.mtm-epub-home-cover{display:block;width:150px;height:225px;background:#f3f3f3;border-radius:6px;overflow:hidden;text-decoration:none}.mtm-epub-home-cover img{width:100%;height:100%;object-fit:cover;display:block}.mtm-epub-home-placeholder{width:100%;height:100%;display:grid;place-items:center;font-size:2.5rem}.mtm-epub-home-info{padding-top:8px}.mtm-epub-home-info h3{font-size:.92rem;line-height:1.28;margin:0 0 5px;overflow-wrap:anywhere}.mtm-epub-home-info h3 a{text-decoration:none;color:inherit}.mtm-epub-home-author,.mtm-epub-home-category{font-size:.82rem;line-height:1.3;color:#666;margin-top:3px;overflow-wrap:anywhere}.mtm-epub-home-read{display:inline-block;margin-top:7px;font-size:.84rem;font-weight:600;text-decoration:none}.mtm-epub-home-empty{font-style:italic;color:#666}@media(max-width:760px){.mtm-epub-home-grid{grid-template-columns:repeat(auto-fill,130px);gap:18px 14px}.mtm-epub-home-card{width:130px}.mtm-epub-home-cover{width:130px;height:195px}.mtm-epub-home-info h3{font-size:.88rem}}@media(max-width:380px){.mtm-epub-home-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px 10px}.mtm-epub-home-card,.mtm-epub-home-cover{width:100%}.mtm-epub-home-cover{height:auto;aspect-ratio:2/3}}

.mtm-epub-home-category-group{margin:1.75rem 0 2.25rem}.mtm-epub-home-category-title{margin:0 0 1rem;padding-bottom:.45rem;border-bottom:1px solid rgba(127,127,127,.28);font-size:1.45rem;line-height:1.25}.mtm-epub-home-subcategory-group{margin:0 0 1.6rem}.mtm-epub-home-subcategory-title{margin:.2rem 0 .9rem;font-size:1.08rem;line-height:1.3}.mtm-epub-home-subcategory-group+.mtm-epub-home-subcategory-group{margin-top:1.7rem}

/* v0.9.60 — unified desktop/tablet spine navigation */
.mtm-reader-workspace{position:relative}
.mtm-side-nav{position:absolute;top:50%;z-index:24;width:46px;height:66px;transform:translateY(-50%);border:0;border-radius:10px;background:rgba(35,50,70,.20);color:#1e314b;font-size:42px;line-height:1;display:flex;align-items:center;justify-content:center;cursor:pointer;opacity:.42;transition:opacity .15s ease,background .15s ease,transform .15s ease;user-select:none;-webkit-user-select:none;touch-action:manipulation}
.mtm-side-prev{left:calc(var(--mtm-toc-width,280px) + 12px)}
.mtm-side-next{right:12px}
.mtm-side-nav:hover,.mtm-side-nav:focus-visible{opacity:.92;background:rgba(35,50,70,.68);color:#fff;outline:none}
.mtm-side-nav:active{transform:translateY(-50%) scale(.96)}
.mtm-side-nav:disabled{opacity:.10;cursor:default;pointer-events:none}
@media(pointer:coarse){.mtm-side-nav{width:54px;height:76px;font-size:48px;opacity:.52}.mtm-side-prev{left:8px}.mtm-side-next{right:8px}}
@media(max-width:760px){.mtm-side-nav{width:44px;height:64px;font-size:40px}.mtm-side-prev{left:4px}.mtm-side-next{right:4px}}
.mtm-epub-app.mtm-toc-collapsed .mtm-side-prev{left:12px}

/* v0.9.73 — Reader ribbon must stay on one row in Chromium/Edge.
   Edge can use wider intrinsic controls/font metrics than Firefox/Chrome. When
   the ribbon wraps, its fixed 44px height no longer matches the real toolbar
   height and the second row overlaps the reader. Never allow wrapping; keep
   the action group visible and compact range controls instead. */
body.single-mtm_epub_book .mtm-toolbar{
  flex-wrap:nowrap!important;
  overflow-x:auto!important;
  overflow-y:hidden!important;
  height:var(--mtm-toolbar-height)!important;
  min-height:var(--mtm-toolbar-height)!important;
  max-height:var(--mtm-toolbar-height)!important;
  scrollbar-width:thin;
}
body.single-mtm_epub_book .mtm-toolbar > *{
  flex:0 0 auto;
  min-width:0;
}
body.single-mtm_epub_book .mtm-toolbar label{
  display:inline-flex;
  align-items:center;
  gap:4px;
  white-space:nowrap;
}
body.single-mtm_epub_book .mtm-toolbar input[type="range"]{
  width:92px;
  min-width:72px;
  max-width:92px;
  flex:0 1 92px;
}
body.single-mtm_epub_book .mtm-toolbar-end{
  position:sticky;
  right:0;
  z-index:2;
  flex:0 0 auto;
  margin-left:auto;
  padding-left:8px;
  background:#111c2e;
}
@media (max-width:1600px){
  body.single-mtm_epub_book .mtm-toolbar{gap:8px}
  body.single-mtm_epub_book .mtm-toolbar input[type="range"]{width:78px;max-width:78px;min-width:62px;flex-basis:78px}
  body.single-mtm_epub_book .mtm-toolbar-end{gap:5px}
  body.single-mtm_epub_book .mtm-download-link{padding:5px 7px}
}
@media (max-width:1100px){
  body.single-mtm_epub_book .mtm-toolbar label{display:none!important}
  body.single-mtm_epub_book .mtm-toolbar{overflow-x:hidden!important}
  body.single-mtm_epub_book .mtm-toolbar-end{position:static;margin-left:auto;padding-left:0}
}


/* v0.9.74: responsive Reader ribbon.  Keep Search permanently visible; collapse
   secondary Reader commands into a hamburger menu on narrow screens. */
.mtm-mobile-menu-toggle{display:none;align-items:center;justify-content:center;width:36px;height:32px;padding:0!important;font-size:21px;line-height:1;flex:0 0 auto}
.mtm-toolbar-main{display:contents}
@media (max-width:1100px){
  body.single-mtm_epub_book .mtm-toolbar{height:var(--mtm-toolbar-height);min-height:var(--mtm-toolbar-height);flex-wrap:nowrap!important;overflow:visible!important;padding:5px 8px;gap:7px}
  body.single-mtm_epub_book .mtm-mobile-menu-toggle{display:inline-flex!important}
  body.single-mtm_epub_book .mtm-toolbar-main{
    display:none;position:absolute;left:8px;top:calc(100% + 1px);z-index:100001;
    width:min(310px,calc(100vw - 16px));max-height:calc(100vh - 70px);overflow:auto;
    padding:9px;background:#111c2e;border:1px solid #40506a;border-radius:0 0 8px 8px;
    box-shadow:0 10px 28px #0008;flex-direction:column;align-items:stretch;gap:5px
  }
  body.single-mtm_epub_book .mtm-toolbar-main.is-open{display:flex!important}
  body.single-mtm_epub_book .mtm-toolbar-main>a,
  body.single-mtm_epub_book .mtm-toolbar-main>button,
  body.single-mtm_epub_book .mtm-toolbar-main>label{box-sizing:border-box;width:100%;min-height:36px;justify-content:flex-start}
  body.single-mtm_epub_book .mtm-toolbar-main>a{display:flex!important;align-items:center;padding:7px 9px;border:1px solid #344766;border-radius:6px;background:#18263d;text-decoration:none!important}
  body.single-mtm_epub_book .mtm-toolbar-main>button{display:flex!important;align-items:center;text-align:left}
  body.single-mtm_epub_book .mtm-toolbar-main .mtm-toolbar-font-control{display:flex!important;align-items:center;gap:8px;padding:5px 8px;border:1px solid #344766;border-radius:6px;background:#18263d}
  body.single-mtm_epub_book .mtm-toolbar-main .mtm-toolbar-font-control input[type="range"]{margin-left:auto;width:130px;max-width:130px;min-width:90px}
  /* Layout tuning is deliberately omitted from the small-screen menu. */
  body.single-mtm_epub_book .mtm-toolbar-main .mtm-toolbar-layout-control{display:none!important}
  body.single-mtm_epub_book .mtm-toolbar-end{display:flex!important;position:static!important;margin-left:auto!important;padding-left:0!important;background:transparent!important;flex:0 0 auto}
  body.single-mtm_epub_book .mtm-search-toggle{display:inline-flex!important;min-width:0;padding:5px 9px!important}
}
@media (max-width:480px){
  body.single-mtm_epub_book .mtm-search-toggle span{display:none}
  body.single-mtm_epub_book .mtm-search-toggle{width:38px;height:32px;padding:0!important}
}


/* v0.9.75: compact ribbon must also activate on touch/handheld browsers that
   expose a desktop-like CSS viewport.  On compact mode keep only Menu + Search
   on the fixed ribbon; navigation/download/TOC/font controls live in Menu. */
.mtm-mobile-menu-toggle{gap:6px;width:auto;min-width:42px;padding:0 9px!important;white-space:nowrap}
.mtm-mobile-menu-label{font-size:13px;font-weight:700}
@media (max-width:1400px), (hover:none) and (pointer:coarse){
  body.single-mtm_epub_book .mtm-toolbar{
    height:var(--mtm-toolbar-height)!important;
    min-height:var(--mtm-toolbar-height)!important;
    max-height:var(--mtm-toolbar-height)!important;
    flex-wrap:nowrap!important;
    overflow:visible!important;
    padding:5px 8px!important;
    gap:7px!important;
  }
  body.single-mtm_epub_book .mtm-mobile-menu-toggle{display:inline-flex!important;order:1}
  body.single-mtm_epub_book .mtm-toolbar-main{
    display:none!important;
    position:absolute!important;
    left:8px!important;
    top:calc(100% + 1px)!important;
    z-index:100001!important;
    width:min(310px,calc(100vw - 16px))!important;
    max-height:calc(100vh - 70px)!important;
    overflow:auto!important;
    padding:9px!important;
    background:#111c2e!important;
    border:1px solid #40506a!important;
    border-radius:0 0 8px 8px!important;
    box-shadow:0 10px 28px #0008!important;
    flex-direction:column!important;
    align-items:stretch!important;
    gap:5px!important;
  }
  body.single-mtm_epub_book .mtm-toolbar-main.is-open{display:flex!important}
  body.single-mtm_epub_book .mtm-toolbar-main>a,
  body.single-mtm_epub_book .mtm-toolbar-main>button,
  body.single-mtm_epub_book .mtm-toolbar-main>label{box-sizing:border-box;width:100%;min-height:36px;justify-content:flex-start}
  body.single-mtm_epub_book .mtm-toolbar-main>a{display:flex!important;align-items:center;padding:7px 9px;border:1px solid #344766;border-radius:6px;background:#18263d;text-decoration:none!important}
  body.single-mtm_epub_book .mtm-toolbar-main>button{display:flex!important;align-items:center;text-align:left}
  body.single-mtm_epub_book .mtm-toolbar-main .mtm-toolbar-font-control{display:flex!important;align-items:center;gap:8px;padding:5px 8px;border:1px solid #344766;border-radius:6px;background:#18263d}
  body.single-mtm_epub_book .mtm-toolbar-main .mtm-toolbar-font-control input[type="range"]{margin-left:auto;width:130px;max-width:130px;min-width:90px}
  body.single-mtm_epub_book .mtm-toolbar-main .mtm-toolbar-layout-control{display:none!important}
  body.single-mtm_epub_book .mtm-toolbar-end{display:flex!important;order:2;position:static!important;margin-left:auto!important;padding-left:0!important;background:transparent!important;flex:0 0 auto!important}
  body.single-mtm_epub_book .mtm-search-toggle{display:inline-flex!important;align-items:center!important;min-width:0!important;padding:5px 9px!important}
}
@media (max-width:520px), (hover:none) and (pointer:coarse) and (max-device-width:900px){
  body.single-mtm_epub_book .mtm-toolbar{justify-content:space-between!important}
  body.single-mtm_epub_book .mtm-search-toggle span{display:inline!important}
  body.single-mtm_epub_book .mtm-search-toggle{width:auto!important;height:32px!important;padding:0 10px!important}
}
@media (max-width:380px){
  body.single-mtm_epub_book .mtm-mobile-menu-label,
  body.single-mtm_epub_book .mtm-search-toggle span{display:none!important}
  body.single-mtm_epub_book .mtm-mobile-menu-toggle,
  body.single-mtm_epub_book .mtm-search-toggle{width:38px!important;min-width:38px!important;padding:0!important}
}


/* v0.9.76: Search is also an explicit item inside the compact Reader menu.
   Keep the permanent ribbon Search button as well. */
.mtm-mobile-search-item{display:none!important}
@media (max-width:1400px), (hover:none) and (pointer:coarse){
  body.single-mtm_epub_book .mtm-toolbar-main .mtm-mobile-search-item{
    display:flex!important;align-items:center!important;gap:8px!important;
    box-sizing:border-box;width:100%;min-height:36px;justify-content:flex-start;
    padding:7px 9px!important;border:1px solid #344766!important;border-radius:6px!important;
    background:#18263d!important;color:#eef3fa!important;font-weight:700;text-align:left
  }
}
