/* Mobile / tablet (<= 820px): pro-level header + floating bottom navigation */
@media (max-width: 820px) {
  :root { --mp-y: #e11d2e; --mp-ink: #111316; }

  /* ---------- header ---------- */
  .tp-header { background: #fff; border-top: 3px solid var(--mp-y); box-shadow: 0 6px 20px -12px rgba(0,0,0,.35); position: relative; z-index: 40; }
  .tp-top .wrap { min-height: 62px; padding-block: 9px; gap: 10px; align-items: center; }
  .tp-ham { width: 42px; height: 42px; border-radius: 13px; background: #f2f3f6; color: var(--mp-ink); transition: background .15s; }
  .tp-ham:active { background: var(--mp-y); }
  .tp-ham svg { width: 22px; height: 22px; stroke-width: 2.4; }
  .tp-brand { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; }
  .tp-brand .brand-word { height: 36px !important; width: auto !important; max-width: 100%; object-fit: contain; }
  .tp-top-actions { gap: 8px; margin-left: auto; align-items: center; }
  .tp-yt { height: 40px; padding: 0 14px 0 12px; border-radius: 999px; background: linear-gradient(135deg, #e5202f, #b50f1c); gap: 7px; font-size: 13px; letter-spacing: .6px; box-shadow: 0 6px 14px -5px rgba(209,26,42,.7); }
  .tp-yt svg { width: 22px; height: 22px; }
  .tp-yt span { display: inline !important; }
  .tp-epaper { width: 40px; height: 40px; border-radius: 13px; background: var(--mp-ink); box-shadow: 0 6px 14px -6px rgba(0,0,0,.55); border: 0; }
  .tp-epaper svg { width: 20px; height: 20px; }
  .tp-nav { box-shadow: none; }

  /* ---------- floating bottom navigation ---------- */
  /* (nav is shown <= 720px; body spacing set below) */
  .bottom-nav { left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); width: auto; border: 1px solid rgba(17,19,22,.07); border-radius: 24px; padding: 0 6px; background: rgba(255,255,255,.94); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); box-shadow: 0 16px 40px -10px rgba(0,0,0,.42), 0 2px 6px rgba(0,0,0,.06); }
  .bottom-nav ul { align-items: flex-end; }
  .bottom-nav a { position: relative; padding: 11px 2px 9px; gap: 4px; font-size: 11.5px; font-weight: 600; letter-spacing: .15px; color: #6b7280; border-radius: 16px; transition: color .15s; }
  .bottom-nav svg { width: 23px; height: 23px; transition: transform .15s; }
  .bottom-nav a.active { color: var(--mp-ink); font-weight: 800; }
  .bottom-nav a.active svg { fill: var(--mp-y); transform: translateY(-1px); }
  .bottom-nav a.active::before { content: ""; position: absolute; top: 0; left: 50%; width: 28px; height: 3px; margin-left: -14px; border-radius: 0 0 6px 6px; background: var(--mp-y); }
  .bottom-nav a:active svg { transform: scale(.88); }
  .bottom-nav .bn-search { padding-top: 0; }
  .bottom-nav .bn-search .bn-search-btn { width: 58px; height: 58px; margin-top: -34px; background: var(--mp-ink); color: var(--mp-y); border: 0; box-shadow: 0 0 0 5px #fff, 0 0 0 7px var(--mp-y), 0 12px 22px -6px rgba(0,0,0,.5); }
  .bottom-nav .bn-search .bn-search-btn svg { width: 25px; height: 25px; }
  .bottom-nav .bn-search .bn-lbl { margin-top: 2px; color: var(--mp-ink); font-weight: 700; }

  /* keep other fixed bits clear of the floating bar */
  .app-banner { bottom: 100px; }
  .push-ask, .push-toast { bottom: 112px; }
  .to-top { bottom: 108px; }
  .pro-footer .footer-bottom { padding-bottom: 120px; }
}
@media (max-width: 380px) { .tp-yt { padding: 0 11px 0 10px; } .tp-brand .brand-word { height: 32px !important; } }
@media (max-width: 720px) { body { padding-bottom: 104px; } }

/* header tune: bigger logo, smaller buttons */
@media (max-width: 820px) {
  .tp-top .wrap { min-height: 64px; gap: 8px; }
  .tp-brand .brand-word { height: 48px !important; }
  .tp-ham { width: 38px; height: 38px; border-radius: 11px; }
  .tp-ham svg { width: 20px; height: 20px; }
  .tp-yt { height: 32px; padding: 0 11px 0 9px; gap: 5px; font-size: 11.5px; letter-spacing: .5px; box-shadow: 0 4px 10px -4px rgba(209,26,42,.65); }
  .tp-yt svg { width: 18px; height: 18px; }
  .tp-epaper { width: 32px; height: 32px; border-radius: 10px; }
  .tp-epaper svg { width: 17px; height: 17px; }
  .tp-top-actions { gap: 6px; }
}
@media (max-width: 380px) { .tp-brand .brand-word { height: 42px !important; } .tp-yt { padding: 0 9px 0 7px; } }

/* no stray strip under the footer: the dark footer itself runs behind the floating nav */
@media (max-width: 720px) {
  html body { padding-bottom: 0 !important; margin-bottom: 0; }
  .pro-footer .footer-bottom { padding-bottom: calc(92px + env(safe-area-inset-bottom, 0px)); }
  .site-footer { margin-bottom: 0; }
}

/* header v3: larger logo (the e-paper button is in the bottom nav, so the header frees its space), clearer menu icon */
@media (max-width: 820px) {
  .tp-epaper { display: none !important; }
  .tp-brand .brand-word { height: 54px !important; }
  .tp-ham { width: 44px; height: 44px; border-radius: 12px; background: #fff; border: 1.5px solid #e3e6eb; box-shadow: 0 2px 6px -2px rgba(0,0,0,.18); color: #111316; display: grid; place-items: center; flex: none; }
  .tp-ham svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; }
  .tp-ham:active { background: var(--mp-y); border-color: var(--mp-y); }
  .tp-top .wrap { gap: 10px; }
}
@media (max-width: 380px) { .tp-brand .brand-word { height: 52px !important; } }

/* header v4 — aligned: [menu] ... [logo centred] ... [LIVE], all on one centre line */
@media (max-width: 820px) {
  .tp-top .wrap { display: grid !important; grid-template-columns: 1fr auto 1fr; align-items: center; column-gap: 8px; padding: 8px 14px; min-height: 66px; }
  .tp-edition { display: none !important; }
  .tp-ham { grid-column: 1; justify-self: start; align-self: center; width: 42px; height: 42px; margin: 0; }
  .tp-brand { grid-column: 2; justify-self: center; align-self: center; margin: 0; flex: none; }
  .tp-brand .brand-word { height: 46px !important; width: auto !important; max-width: none; display: block; }
  .tp-top-actions { grid-column: 3; justify-self: end; align-self: center; margin: 0; gap: 0; height: auto; }
  .tp-yt { height: 36px; padding: 0 12px 0 10px; font-size: 12px; margin: 0; }
}
@media (max-width: 370px) {
  .tp-yt span { display: none !important; }
  .tp-yt { padding: 0 9px; }
  .tp-brand .brand-word { height: 42px !important; }
}

/* ===== Mobile Top Stories slider + type scale ===== */
@media (max-width: 820px) {
  .nt-m-hide { display: none !important; }      /* the old big-feature block is replaced by the slider */
  .m-slider { padding: 14px 0 6px; }
  .ms-head { display: flex; align-items: baseline; justify-content: space-between; padding: 0 16px 10px; }
  .ms-head h2 { margin: 0; font-size: 21px; font-weight: 800; line-height: 1.2; color: var(--heading, #111316); padding-bottom: 6px; border-bottom: 3px solid var(--mp-y, #e11d2e); }
  .ms-head a { font-size: 13.5px; font-weight: 700; color: #6b7280; text-decoration: none; }
  .ms-track { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 0 16px; scroll-padding-inline: 16px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .ms-track::-webkit-scrollbar { display: none; }
  .ms-slide { position: relative; flex: 0 0 100%; scroll-snap-align: center; border-radius: 16px; overflow: hidden; background: #111316; text-decoration: none; color: #fff; aspect-ratio: 16 / 11; box-shadow: 0 10px 24px -14px rgba(0,0,0,.6); }
  .ms-img, .ms-img img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; object-fit: cover; }
  .ms-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.88) 0%, rgba(0,0,0,.5) 42%, rgba(0,0,0,0) 72%); }
  .ms-cat { position: absolute; z-index: 2; top: 12px; left: 12px; padding: 4px 10px; border-radius: 6px; background: var(--mp-y, #e11d2e); color: #111316; font-size: 11.5px; font-weight: 800; letter-spacing: .3px; }
  .ms-txt { position: absolute; z-index: 2; left: 0; right: 0; bottom: 0; padding: 16px 16px 14px; }
  .ms-txt b { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; font-size: 19px; line-height: 1.45; font-weight: 700; letter-spacing: 0; }
  .ms-txt small { display: block; margin-top: 6px; font-size: 12.5px; color: rgba(255,255,255,.82); }
  .ms-dots { display: flex; justify-content: center; gap: 7px; padding: 12px 0 2px; }
  .ms-dots i { width: 7px; height: 7px; border-radius: 99px; background: #cfd4db; transition: width .25s, background .25s; cursor: pointer; }
  .ms-dots i.on { width: 22px; background: var(--mp-y, #e11d2e); }

  /* type scale for Devanagari: readable sizes, generous line-height (matras need room), no oversized headings */
  body { font-size: 16px; line-height: 1.7; -webkit-text-size-adjust: 100%; }
  h1, .article h1 { font-size: 24px !important; line-height: 1.4 !important; font-weight: 800; letter-spacing: 0; }
  .n18-head h2, .section > h2, .sec-title, .dyn-head h1 { font-size: 21px !important; line-height: 1.25; }
  .sb-feat h3, .fsec-body h3 { font-size: 20px !important; line-height: 1.45 !important; font-weight: 700; }
  .sb-mini h4, .card h3, .card h4, .feat-list h3, .feat-list h4, .mr-title, .vs-card h4 { font-size: 16px !important; line-height: 1.5 !important; font-weight: 700; letter-spacing: 0; }
  .card p, .dyn-card p, .excerpt, .mr-dek { font-size: 14.5px; line-height: 1.65; }
  .meta, .card .meta, .byline, time { font-size: 12.5px; }
  .article-body, .article-body p, .page-body p { font-size: 17px; line-height: 1.85; }
  .article-body h2, .page-body h2 { font-size: 21px; line-height: 1.4; }
}

@media (max-width: 820px) {
  /* one heading style everywhere (the home "Live YouTube" title was in a serif) */
  .n18-head h2, .ms-head h2, .section > h2, .sec-title { font-family: var(--f-ui, "Mukta", "Noto Sans Devanagari", sans-serif) !important; font-weight: 800; }
  .n18-head.plain h2 { border-bottom: 3px solid var(--mp-y, #e11d2e); padding-bottom: 6px; display: inline-block; }
}

/* header leaderboard strip (DTPR banner under the menu) — hidden on mobile / tablet */
@media (max-width: 820px) {
  .tp-ad.nt-mobile-only { display: none !important; }
}

/* ===== drawer bottom buttons: three equal tiles, real icons, no wrapping ===== */
.drawer-cta { display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 14px 16px 18px; }
.drawer-cta a { display: flex !important; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 68px; padding: 10px 6px !important; border: 0 !important; border-radius: 14px !important; text-align: center; font: 700 13.5px/1.1 var(--f-ui, inherit) !important; white-space: nowrap; text-decoration: none; transition: transform .15s, filter .15s; }
.drawer-cta a:active { transform: scale(.96); }
.drawer-cta a svg { width: 24px; height: 24px; flex: none; fill: currentColor; }
.drawer-cta .d-live { background: linear-gradient(135deg, #e5202f, #b50f1c) !important; color: #fff !important; box-shadow: 0 8px 16px -8px rgba(209,26,42,.7); }
.drawer-cta .d-epaper { background: #111316 !important; color: #fff !important; }
.drawer-cta .d-epaper svg { fill: #e11d2e; }
.drawer-cta .d-app { background: #e11d2e !important; color: #111316 !important; }

/* ===== mobile: share icons to the left, bigger story images ===== */
@media (max-width: 820px) {
  /* share / social row under each story starts at the left edge */
  .card-foot, .card-foot--share-only, .card-foot--stats, .card-share, .share-row, .dyn-share { justify-content: flex-start !important; }
  .card-foot--share-only { justify-content: flex-start !important; }
  .card-share { margin-left: 0 !important; }

  /* images: list thumbnails 96px → 132px, 2-up grid cards taller, most-read thumbs bigger */
  .ws-row, .duo-grid .ws-row { grid-template-columns: 1fr 132px; gap: 14px; }
  .ws-row .imgwrap, .duo-grid .ws-row .imgwrap { width: 132px; aspect-ratio: 4 / 3; border-radius: 8px; }
  .vrow { grid-template-columns: 1fr 124px; gap: 14px; }
  .vrow .imgwrap { width: 124px; aspect-ratio: 4 / 3; border-radius: 8px; }
  .sb-mini .imgwrap { aspect-ratio: 4 / 3; border-radius: 8px; }
  .mr-item { grid-template-columns: 124px 1fr; gap: 14px; }
  .mr-thumb { width: 124px; height: auto; aspect-ratio: 4 / 3; }
  .live-yt-list a { grid-template-columns: 132px 1fr; gap: 12px; }
  .live-yt-list img { width: 132px; }
  .ms-slide { aspect-ratio: 4 / 3; }
}

/* story rows (title left, image right): no share icons under them */
.ws-row .card-foot, .vrow .card-foot, .ws-row .card-share, .vrow .card-share { display: none !important; }

/* header v5 — bigger logo on phones: the LIVE button becomes an icon so the logo can use the freed width */
@media (max-width: 820px) {
  .tp-top .wrap { grid-template-columns: auto 1fr auto !important; min-height: 74px; }
  .tp-brand .brand-word { height: min(60px, 14vw) !important; }
  .tp-yt span { display: none !important; }
  .tp-yt { width: 40px; height: 40px; padding: 0 !important; justify-content: center; border-radius: 50%; }
  .tp-yt svg { width: 22px; height: 22px; }
}

/* drawer: login button (yellow, like the old app tile) */
.drawer-cta .d-login { background: #e11d2e !important; color: #111316 !important; }

/* drawer: login pill in the head, next to the close button */
.drawer-head { gap: 10px; }
.drawer-head .drawer-login { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; background: #e11d2e; color: #111316 !important; font: 800 14px/1 var(--f-ui, inherit); text-decoration: none; white-space: nowrap; box-shadow: 0 6px 14px -8px rgba(225,29,46,.9); }
.drawer-head .drawer-login svg { width: 17px; height: 17px; fill: currentColor; }
