[hidden] {
  display: none !important;
}

html {
  background: #100c11;
}

body.ms-page .download-trigger {
  cursor: pointer;
  text-decoration: none;
}

body.ms-page .modal-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 14px 18px;
  line-height: 1.4;
}

body.ms-page #download-status:empty {
  display: none;
}

body.ms-page #download-status {
  padding: 10px;
  margin-top: 8px;
  color: var(--mint);
  font-size: 12px;
}

html[dir="rtl"] body.ms-page .brand-text,
html[dir="rtl"] body.ms-page .guide-content {
  text-align: right;
}

html[dir="rtl"] body.ms-page .entry-popup-close {
  right: auto;
  left: 12px;
}

body.ms-page .drama:focus-visible,
body.ms-page .download-trigger:focus-visible,
body.ms-page button:focus-visible {
  outline: 3px solid #19c8a2;
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  body.ms-page *,
  body.ms-page *:before,
  body.ms-page *:after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

body.ms-page .download-message {
  padding: 12px;
  text-align: center;
  color: var(--mint);
  font-size: 13px;
}

body.ms-page .modal-overlay,
body.ms-page .entry-popup-overlay {
  overflow-y: auto;
  overscroll-behavior: contain;
}

body.ms-page .modal-box,
body.ms-page .entry-popup-card {
  max-height: calc(100vh - 48px);
  max-height: calc(100dvh - 48px);
  overflow-y: auto;
}

/* 孟加拉语字体与行高适配（展开 :is() 兼容旧版浏览器） */
html[lang^="bn"] body.ms-page {
  font-family: "Noto Sans Bengali", system-ui, sans-serif;
  font-synthesis: none;
}
html[lang^="bn"] body.ms-page h1,
html[lang^="bn"] body.ms-page h2,
html[lang^="bn"] body.ms-page h3,
html[lang^="bn"] body.ms-page p,
html[lang^="bn"] body.ms-page b,
html[lang^="bn"] body.ms-page span,
html[lang^="bn"] body.ms-page a,
html[lang^="bn"] body.ms-page button {
  letter-spacing: normal;
}
html[lang^="bn"] body.ms-page .drama-copy h1,
html[lang^="bn"] body.ms-page .hero-title-shimmer {
  line-height: 1.4;
  font-size: 28px;
  font-size: clamp(25px, 7.4vw, 32px);
  font-weight: 700;
  overflow: visible;
}
html[lang^="bn"] body.ms-page .drama-copy p,
html[lang^="bn"] body.ms-page .modal-desc,
html[lang^="bn"] body.ms-page .guide-content p,
html[lang^="bn"] body.ms-page .final p,
html[lang^="bn"] body.ms-page .page-footer p {
  line-height: 1.75;
  font-weight: 400;
}
html[lang^="bn"] body.ms-page .modal-title,
html[lang^="bn"] body.ms-page .section-head h2,
html[lang^="bn"] body.ms-page .final h2,
html[lang^="bn"] body.ms-page .entry-popup-title {
  line-height: 1.45;
  font-weight: 700;
}
html[lang^="bn"] body.ms-page .hero-cta,
html[lang^="bn"] body.ms-page .modal-cta,
html[lang^="bn"] body.ms-page .cta,
html[lang^="bn"] body.ms-page .entry-popup-cta {
  min-height: 54px;
  line-height: 1.6;
  font-weight: 700;
  padding-top: 12px;
  padding-bottom: 12px;
}
html[lang^="bn"] body.ms-page .bonus-live {
  font-size: 13px;
  line-height: 1.5;
  font-weight: 600;
}
html[lang^="bn"] body.ms-page .dramas b {
  line-height: 1.5;
  font-weight: 600;
}

body.ms-page .drama {
  cursor: pointer;
}

/* 印地语字体与行高适配 */
html[lang="hi-IN"] body.ms-page {
  font-family: "Noto Sans Devanagari", system-ui, sans-serif;
  font-synthesis: none;
}
html[lang="hi-IN"] body.ms-page h1,
html[lang="hi-IN"] body.ms-page h2,
html[lang="hi-IN"] body.ms-page h3,
html[lang="hi-IN"] body.ms-page p,
html[lang="hi-IN"] body.ms-page b,
html[lang="hi-IN"] body.ms-page span,
html[lang="hi-IN"] body.ms-page a,
html[lang="hi-IN"] body.ms-page button {
  letter-spacing: normal;
}
html[lang="hi-IN"] body.ms-page .drama-copy h1,
html[lang="hi-IN"] body.ms-page .hero-title-shimmer {
  font-size: 28px;
  font-size: clamp(25px, 7vw, 31px);
  line-height: 1.5;
  font-weight: 700;
  overflow: visible;
}
html[lang="hi-IN"] body.ms-page .drama-copy p,
html[lang="hi-IN"] body.ms-page .modal-desc,
html[lang="hi-IN"] body.ms-page .guide-content p,
html[lang="hi-IN"] body.ms-page .final p,
html[lang="hi-IN"] body.ms-page .page-footer p {
  line-height: 1.85;
  font-weight: 400;
}
html[lang="hi-IN"] body.ms-page .modal-title,
html[lang="hi-IN"] body.ms-page .section-head h2,
html[lang="hi-IN"] body.ms-page .final h2 {
  line-height: 1.55;
}
html[lang="hi-IN"] body.ms-page .hero-cta,
html[lang="hi-IN"] body.ms-page .modal-cta,
html[lang="hi-IN"] body.ms-page .cta {
  min-height: 54px;
  line-height: 1.65;
  padding-top: 12px;
  padding-bottom: 12px;
}
html[lang="hi-IN"] body.ms-page .bonus-live {
  font-size: 14px;
  line-height: 1.6;
  white-space: nowrap;
}
html[lang="hi-IN"] body.ms-page .dramas b {
  line-height: 1.7;
}
html[lang="en-IN"] body.ms-page .bonus-live {
  white-space: nowrap;
}

/* 剧集弹窗应用图标容器 */
body.ms-page .modal-icon {
  width: 80px;
  height: 80px;
  padding: 5px;
  border: 1px solid rgba(214, 182, 122, 0.5);
  border-radius: 23px;
  background: #18141b;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.33), inset 0 1px 0 rgba(255, 255, 255, 0.13);
  overflow: hidden;
}
body.ms-page .modal-icon img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 17px;
}

/* APK 安装指南四步卡片 */
body.ms-page .guide-steps {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
}
body.ms-page .guide-step {
  position: relative;
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 16px 15px;
  margin: 0;
  border: 1px solid rgba(181, 154, 98, 0.22);
  border-radius: 16px;
  background: linear-gradient(115deg, #153c34, #142b28 62%, #172724);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03), 0 5px 16px rgba(0, 0, 0, 0.13);
}
body.ms-page .guide-step:nth-child(even) {
  background: linear-gradient(115deg, #34302a, #292725 62%, #252724);
}
body.ms-page .guide-step::after {
  content: "";
  position: absolute;
  right: 11px;
  inset-inline-end: 11px;
  top: 11px;
  width: 4px;
  height: 4px;
  border: 1px solid rgba(197, 169, 113, 0.5);
  transform: rotate(45deg);
}
body.ms-page .guide-icon {
  flex: 0 0 58px;
  width: 58px;
  height: 66px;
  min-width: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
}
body.ms-page .guide-icon svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}
body.ms-page .guide-icon path,
body.ms-page .guide-icon rect,
body.ms-page .guide-icon circle {
  stroke-linecap: round;
  stroke-linejoin: round;
}
body.ms-page .guide-ornament {
  fill: rgba(209, 183, 124, 0.04);
  stroke: rgba(209, 183, 124, 0.27);
  stroke-width: 0.8;
}
body.ms-page .guide-stitch {
  stroke: rgba(209, 183, 124, 0.22);
  stroke-width: 0.8;
  stroke-dasharray: 1 3;
}
body.ms-page .guide-object {
  fill: #25584b;
  stroke: #e3c58d;
  stroke-width: 1.6;
}
body.ms-page .guide-paper {
  fill: #f2deb1;
  stroke: #d5b577;
  stroke-width: 1.2;
}
body.ms-page .guide-line {
  stroke: #f7dfaa;
  stroke-width: 1.8;
}
body.ms-page .guide-step:nth-child(2) .guide-line {
  stroke: #a0783c;
}
body.ms-page .guide-check {
  stroke: #245747;
  stroke-width: 2.8;
}
body.ms-page .guide-highlight {
  fill: #f6d691;
}
body.ms-page .guide-content {
  min-width: 0;
  flex: 1 1 auto;
}
body.ms-page .guide-content b {
  margin: 0 0 5px;
  color: #f7e6c5;
  font-size: 14px;
  line-height: 1.6;
  font-weight: 600;
}
body.ms-page .guide-content p {
  margin: 0;
  color: #c3d0c7;
  font-size: 12px;
  line-height: 1.8;
}
@media (max-width: 360px) {
  body.ms-page .guide-step {
    padding: 13px 11px;
    gap: 11px;
  }
  body.ms-page .guide-icon {
    flex-basis: 49px;
    width: 49px;
    height: 58px;
  }
  body.ms-page .guide-content b {
    font-size: 13px;
  }
}

/* 越南语：确保双声调变音符号清晰且行高舒展 */
html[lang^="vi"] body.ms-page {
  font-family: "Inter", "Segoe UI", "Roboto", "Noto Sans", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}
html[lang^="vi"] body.ms-page.romance-page .hero-title-shimmer {
  line-height: 1.35;
  letter-spacing: -0.2px;
}

/* 繁体中文：使用清晰的无衬线繁体字体栈并优化标题与标签字距 */
html[lang="zh-TW"] body.ms-page {
  font-family: "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", "Heiti TC", system-ui, -apple-system, sans-serif;
}
html[lang="zh-TW"] body.ms-page.romance-page .tag {
  letter-spacing: 1px;
  font-size: 11px;
}
html[lang="zh-TW"] body.ms-page.romance-page .hero-title-shimmer {
  font-size: 26px;
  line-height: 1.38;
  letter-spacing: 0;
  text-wrap: balance;
}
html[lang="zh-TW"] body.ms-page.romance-page .drama b {
  font-size: 11px;
  line-height: 1.5;
}

/* 日语：使用标准日文无衬线字体栈并优化断行与字距 */
html[lang^="ja"] body.ms-page {
  font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", "Meiryo", system-ui, -apple-system, sans-serif;
}
html[lang^="ja"] body.ms-page.romance-page .tag {
  letter-spacing: 0.8px;
  font-size: 10px;
}
html[lang^="ja"] body.ms-page.romance-page .hero-title-shimmer {
  font-size: 26px;
  line-height: 1.4;
  letter-spacing: -0.2px;
  word-break: keep-all;
  overflow-wrap: break-word;
  overflow-wrap: anywhere;
}
html[lang^="ja"] body.ms-page.romance-page .drama b {
  font-size: 10px;
  line-height: 1.55;
}
