/* ==========================================================================
   न्यूज पोर्टल — Design System
   Palette:  Paper #FBFAF7 · Ink #1C1B1A · Maratha Maroon #A61C2E
             Konkan Teal #0E6E6E · Sahyadri Gold #D9A441 · Stone #6B6560
   Display face: Noto Serif Devanagari (headlines, editorial gravitas)
   Body face:    Noto Sans Devanagari
   Signature:    "गड" battlement (fort) motif under masthead & section heads
   ========================================================================== */

/* Addon: prevents background scroll while the mobile off-canvas menu is open */
body.nav-open-lock { overflow: hidden; }

:root {
  --paper: #FBFAF7;
  --paper-dim: #F3F0E9;
  --ink: #1C1B1A;
  --ink-soft: #4A4643;
  --stone: #6B6560;
  --line: #E4DFD5;
  --maroon: #A61C2E;
  --maroon-dark: #7E1522;
  --teal: #0E6E6E;
  --gold: #D9A441;
  --white: #FFFFFF;
  --radius-s: 6px;
  --radius-m: 12px;
  --shadow-card: 0 2px 10px rgba(28,27,26,0.06), 0 1px 2px rgba(28,27,26,0.08);
  --shadow-hover: 0 10px 24px rgba(28,27,26,0.12);
  --font-display: 'Noto Serif Devanagari', 'Georgia', serif;
  --font-body: 'Noto Sans Devanagari', -apple-system, sans-serif;
  --font-utility: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --container: 1240px;
}

/* ---------- Theme Customization overrides ----------
   Populated dynamically from the `settings` table in templates/header.php
   (Admin → Settings → Appearance). Defaults below match the values above
   1:1, so the site looks unchanged until an admin edits a value. ---------- */
:root {
  --header-bg: var(--white);
  --header-text: var(--ink);
  --nav-bg: var(--maroon);
  --nav-text: #FFFFFF;
  --nav-hover-color: var(--maroon-dark);
  --body-bg: var(--paper);
  --content-bg: var(--paper);
  --card-bg: var(--white);
  --card-border: transparent;
  --heading-color: var(--ink);
  --body-text-color: var(--ink);
  --link-color: var(--maroon);
  --link-hover-color: var(--maroon-dark);
  --footer-bg: var(--ink);
  --footer-text: #C9C4BC;
  --share-bar-bg: var(--ink);
  --share-icon-color: #FFFFFF;
  --share-icon-hover: var(--gold);
  --share-bar-border: transparent;
  --share-bar-height: 46px;
  --share-icon-size: 18px;
  --share-bar-text-color: #FFFFFF;
  --share-bar-font-size: 13px;
  --breaking-bg: #FBF3E4;
  --breaking-text: var(--ink);
  --badge-bg: var(--teal);
  --badge-text: #FFFFFF;
  --btn-bg: var(--maroon);
  --btn-text: #FFFFFF;
  --nav-font-size: 13px;
  --category-font-size: 12px;
  --footer-font-size: 13.5px;
  --news-title-font-size: 17px;
  --article-heading-font-size: 32px;
  --article-body-font-size: 19px;
  --logo-width: auto;
  --logo-height: 44px;
  --title-color: var(--maroon);
  --title-font-size: 26px;
  --title-font-weight: 700;
  --header-height-desktop: auto;
  --header-height-mobile: auto;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--body-text-color);
  background: var(--body-bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
}
#main-content { background: var(--content-bg); }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1,h2,h3,h4 { font-family: var(--font-display); margin: 0; color: var(--heading-color); }
.article-content a, .comment-item a { color: var(--link-color); text-decoration: underline; }
.article-content a:hover, .comment-item a:hover { color: var(--link-hover-color); }
.container { max-width: var(--container); margin: 0 auto; padding: 0 20px; }

.skip-link {
  position: absolute; left: -999px; top: 0; background: var(--maroon); color: #fff;
  padding: 10px 16px; z-index: 999; border-radius: 0 0 6px 0;
}
.skip-link:focus { left: 0; }

:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }

/* ---------- Fort-battlement signature divider ---------- */
.fort-edge {
  height: 10px;
  width: 100%;
  background:
    linear-gradient(135deg, var(--maroon) 25%, transparent 25%) -6px 0,
    linear-gradient(225deg, var(--maroon) 25%, transparent 25%) -6px 0;
  background-size: 12px 12px;
  background-repeat: repeat-x;
  background-color: transparent;
}

/* ---------- Topbar ---------- */
.topbar { background: var(--ink); color: #D8D3CB; font-family: var(--font-utility); font-size: 13px; }
.topbar__inner { display: flex; justify-content: space-between; align-items: center; padding: 6px 20px; }
.topbar__meta span { margin-right: 14px; }
.topbar__social { display: flex; align-items: center; gap: 14px; }
.topbar__social a { color: #D8D3CB; }
.topbar__social a:hover { color: var(--gold); }
.topbar__epaper, .topbar__login {
  border: 1px solid rgba(255,255,255,0.25); padding: 3px 10px; border-radius: 20px; font-size: 12px;
}
.topbar__epaper:hover, .topbar__login:hover { background: var(--maroon); border-color: var(--maroon); }
.lang-switcher { display: flex; gap: 4px; font-size: 12px; }
.lang-switcher a { padding: 3px 8px; border-radius: 12px; color: #a8a29b; }
.lang-switcher a.is-active { background: var(--maroon); color: #fff; }
.lang-switcher a:hover { color: #fff; }

/* ---------- Header ---------- */
.site-header {
  background: transparent; position: sticky; top: 0; z-index: 100;
}
/* Note: Heading + Menu bar stay permanently fixed/visible while scrolling
   (position: sticky above) — the previous hide-on-scroll-down behavior and
   its .is-hidden toggle (main.js) were removed per updated requirement. */
/* Addon: the Heading/Logo background color is now scoped to the SAME
   .container width as the menu bar below it (not the full browser width) —
   both sit centered at the same size, matching edge-to-edge with each other
   instead of the header stretching wider than the nav bar. */
.site-header__inner {
  display: flex; align-items: center; gap: 24px; padding: 14px 20px; min-height: var(--header-height-desktop); flex-wrap: wrap;
  background: var(--header-bg); border-bottom: 1px solid var(--line); border-radius: 0 0 8px 8px;
}
.brand { display: flex; align-items: center; gap: 10px; }
/* ---------- Masthead (logo column + tagline / RNI-editor-phone column) ---------- */
.masthead__brand-col { display: flex; flex-direction: column; gap: 6px; margin-right: auto; align-items: flex-start; }
.masthead__tagline {
  font-size: 12.5px; font-weight: 600; letter-spacing: .3px; color: var(--header-text); opacity: .85;
  font-family: var(--font-utility);
}
.masthead__meta-col {
  display: flex; flex-direction: column; align-items: flex-end; gap: 3px; text-align: right;
  font-family: var(--masthead-font-family, var(--font-utility)); color: var(--masthead-font-color, var(--header-text)); flex-shrink: 0;
  font-weight: var(--masthead-font-weight, 400); font-style: var(--masthead-font-style, normal);
}
.masthead__rni { font-size: var(--masthead-font-size, 12.5px); letter-spacing: .2px; font-weight: var(--masthead-font-weight, 700); }
.masthead__editor { font-size: var(--masthead-font-size, 12.5px); opacity: .9; }
.masthead__phone { font-size: calc(var(--masthead-font-size, 12.5px) + 2.5px); display: flex; align-items: center; gap: 6px; font-weight: var(--masthead-font-weight, 700); }
.masthead__phone i {
  width: 24px; height: 24px; border-radius: 50%; background: rgba(0,0,0,.15);
  display: inline-flex; align-items: center; justify-content: center; font-size: 11px;
}
.brand__logo { height: var(--logo-height); width: var(--logo-width); object-fit: contain; }
.brand__text { font-family: var(--title-font-family, var(--font-display)); font-weight: var(--title-font-weight); font-size: var(--title-font-size); font-style: var(--title-font-style, normal); color: var(--title-color); }
/* Addon: two-tone site name (e.g. "लढवय्या" in one color, "रोखठोक" in another) */
.brand__text-part1 { color: var(--title-color); }
.brand__text-part2 { color: var(--title-color-2); }
.header-search { display: flex; align-items: center; background: var(--paper-dim); border-radius: 24px; padding: 4px 4px 4px 16px; width: 320px; }
.header-search input { border: none; background: transparent; flex: 1; font-family: var(--font-body); font-size: 14px; outline: none; }
.header-search button { background: var(--maroon); color: #fff; border: none; width: 34px; height: 34px; border-radius: 50%; cursor: pointer; }
.hamburger { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 6px; }
.hamburger span { width: 24px; height: 2.5px; background: var(--header-text); border-radius: 2px; }

/* Logo/title alignment & position, set on <body> by templates/header.php from Admin Theme settings */
body.header-align-center .brand { margin: 0 auto; }
body.header-align-right .brand { margin-left: auto; margin-right: 0; }
body.logo-pos-above .brand { flex-direction: column; }
body.logo-pos-after .brand { flex-direction: row-reverse; }
body.title-valign-top .brand { align-items: flex-start; }
body.title-valign-bottom .brand { align-items: flex-end; }

/* Addon: ONE shared "box" wraps the Logo image AND the Title text together
   (matching a typical logo badge/pill design) — single color control, and
   the Title text always renders inside this same box, not separately.
   Opt-in: stays invisible until an admin sets a non-transparent Box color. */
.brand { background: var(--logo-bg-color, transparent); }
body:not([data-logo-bg="transparent"]) .brand {
  padding: var(--box-padding, 8px 14px); border-radius: var(--box-radius, 8px);
}
/* When only the Title/Name is shown (no logo image), a separately-set Title
   Box color can override the shared box color above — optional, falls back
   to the same shared color when left transparent/unset. */
body.header-text-only:not([data-title-box-bg="transparent"]) .brand {
  background: var(--title-box-bg-color);
}
body.logo-align-center .brand__logo { margin-left: auto; margin-right: auto; display: block; }
body.logo-align-right .brand__logo { margin-left: auto; margin-right: 0; display: block; }
body.heading-align-center .brand__text { text-align: center; display: block; }
body.heading-align-right .brand__text { text-align: right; display: block; }
/* In row layouts (logo before/after title) alignment maps to cross-axis position instead */
body:not(.logo-pos-above).logo-align-center .brand { justify-content: center; }
body:not(.logo-pos-above).logo-align-right .brand { justify-content: flex-end; }

.main-nav { background: transparent; position: relative; }
/* These only exist for the mobile off-canvas drawer; hidden by default (desktop)
   and switched on inside the max-width:900px block below. Missing this base
   rule was causing the drawer's logo+title to render inline in the desktop
   nav bar, duplicating the header logo. */
.main-nav__drawer-head, .main-nav__close, .nav-backdrop { display: none; }
.main-nav__inner { overflow: visible; height: 42px; background: var(--nav-bg); border-radius: 0 0 8px 8px; box-shadow: 0 3px 10px rgba(0,0,0,.14); }
.main-nav__list { display: flex; flex-wrap: nowrap; width: max-content; min-width: 100%; justify-content: flex-start; height: 100%; }
.main-nav__list > li { display: flex; }
.main-nav__list > li > a {
  display: flex; align-items: center; gap: 5px; padding: 0 14px; color: var(--nav-text); font-size: var(--nav-font-size); font-family: var(--nav-font-family, var(--font-body)); font-weight: var(--nav-font-weight, 500); white-space: nowrap; height: 100%;
  transition: background .16s ease, color .16s ease;
}
.nav-caret { font-size: 8px; opacity: .8; pointer-events: none; }
.main-nav__list > li:hover > a, .main-nav__list > li > a:focus-visible { background: var(--nav-hover-color); }
.has-dropdown { position: relative; }
.dropdown {
  display: none; position: absolute; top: 100%; left: 0; background: var(--white); min-width: 200px;
  box-shadow: var(--shadow-hover); border-radius: 0 0 var(--radius-s) var(--radius-s); z-index: 50;
  max-height: 60vh; overflow-y: auto;
}
.has-dropdown:hover .dropdown, .has-dropdown.is-open .dropdown { display: block; }
.dropdown li a { color: var(--ink); padding: 9px 16px; display: block; font-size: 14px; transition: background .14s ease, color .14s ease; }
.dropdown li a:hover { background: var(--paper-dim); color: var(--maroon); }

.main-nav__home {
  background: var(--gold); color: var(--ink) !important; padding: 0 18px !important; font-size: 14px; border-radius: 0 0 0 8px;
  transition: background .16s ease;
}
.main-nav__home:hover { background: #c99333 !important; }
/* Addon: search icon moved out of the Heading into the nav bar — pushed to
   the far right, matching the reference design. */
.main-nav__search { margin-left: auto; }
.main-nav__search > a {
  font-size: 15px; display: flex; align-items: center; justify-content: center;
}

/* Addon: alternate "Menu Bar Style" — pipe-separated plain text links
   (Home | ताज्या बातम्या | जिल्हा...) instead of the default boxed/hover-fill
   look. DESKTOP ONLY (min-width: 901px) — the mobile drawer always uses its
   own plain horizontal row-separator lines, completely independent of this
   setting, so nothing "divider"-related ever leaks into mobile. */
@media (min-width: 901px) {
  body.nav-style-divider .main-nav__list > li > a {
    background: transparent !important; padding: 0 10px; position: relative;
  }
  body.nav-style-divider .main-nav__list > li > a::before {
    content: ""; position: absolute; left: 10px; right: 10px; bottom: 8px; height: 2px; background: var(--gold);
    transform: scaleX(0); transform-origin: left; transition: transform .2s ease; pointer-events: none;
  }
  body.nav-style-divider .main-nav__list > li:hover > a::before { transform: scaleX(1); }
  body.nav-style-divider .main-nav__home {
    background: transparent !important; color: var(--nav-text) !important; padding: 0 10px !important; border-radius: 0;
  }
  body.nav-style-divider .main-nav__list > li:hover > a,
  body.nav-style-divider .main-nav__home:hover {
    background: transparent !important;
  }
  /* The "|" itself is a vertical bar character, matching "Desktop Vertical" divider. */
  body.nav-style-divider .main-nav__list > li:not(:last-child)::after {
    content: "|"; color: var(--nav-text); opacity: .45; display: flex; align-items: center; padding: 0 2px; font-weight: 400;
  }
}

/* ---------- Breaking news ticker (single-line rotation, matches conventional news-portal UX) ---------- */
.breaking-bar { background: transparent; padding: 8px 0; border-bottom: 1px solid var(--line); }
.breaking-bar__inner { display: flex; align-items: stretch; height: 38px; background: var(--breaking-bg); border: 1px solid var(--gold); border-radius: 6px; overflow: hidden; }
.breaking-bar__label {
  background: var(--maroon); color: #fff; font-weight: 700; padding: 0 16px; font-size: 12px;
  white-space: nowrap; flex-shrink: 0; letter-spacing: .3px; display: flex; align-items: center; gap: 6px; height: 100%;
}
.breaking-bar__label::before { content: "●"; color: var(--gold); font-size: 8px; animation: blink 1.6s infinite; }
@keyframes blink { 50% { opacity: .3; } }
.breaking-bar__track { flex: 1; display: flex; align-items: center; padding: 0 4px 0 16px; min-width: 0; height: 100%; position: relative; overflow: hidden; }
.breaking-bar__nav { background: none; border: none; color: var(--stone); cursor: pointer; padding: 0 8px; flex-shrink: 0; height: 100%; display: flex; align-items: center; font-size: 12px; }
.breaking-bar__nav:hover { color: var(--maroon); }
.breaking-bar__nav.is-hidden { display: none; } /* continuous marquee replaces manual prev/next stepping */
.breaking-bar__list { position: relative; flex: 1; height: 100%; overflow: hidden; min-width: 0; display: flex; align-items: center; }

/* Static (non-marquee) fallback: single headline, or reduced-motion */
.breaking-bar__list:not(.breaking-bar__list--marquee) li {
  position: absolute; inset: 0; display: flex; align-items: center; text-align: left; opacity: 0; pointer-events: none;
  transition: opacity .4s ease;
}
.breaking-bar__list:not(.breaking-bar__list--marquee) li.is-active { opacity: 1; pointer-events: auto; }

/* Continuous smooth horizontal auto-scroll (marquee).
   Absolutely positioned within .breaking-bar__track (not a flex item) so its
   intrinsic width can NEVER affect the label's or track's flex sizing —
   this is what previously let the scrolling text visually bleed over the
   "ब्रेकिंग न्यूज" label. will-change forces its own GPU compositing layer,
   which also avoids the tearing/ghosting some browsers show on animated
   flex children clipped by overflow:hidden + border-radius. */
.breaking-bar__list--marquee {
  position: absolute; top: 0; left: 0; height: 100%; flex-wrap: nowrap; white-space: nowrap; width: max-content;
  animation: breaking-marquee var(--marquee-duration, 30s) linear infinite;
  will-change: transform; backface-visibility: hidden;
}
.breaking-bar__list--marquee.is-paused { animation-play-state: paused; }
.breaking-bar__list--marquee li { flex-shrink: 0; padding-right: 48px; }
@keyframes breaking-marquee { from { transform: translate3d(0,0,0); } to { transform: translate3d(-50%,0,0); } }

.breaking-bar__list li a {
  color: var(--breaking-text); font-size: var(--breaking-font-size, 13px); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; text-align: left;
}
.breaking-bar__list:not(.breaking-bar__list--marquee) li a { width: 100%; }
.breaking-bar__list li a::before {
  content: ""; display: inline-block; width: 0; height: 0; flex-shrink: 0; vertical-align: middle;
  border-top: 4px solid transparent; border-bottom: 4px solid transparent; border-left: 6px solid var(--maroon);
  margin-right: 10px;
}
.breaking-bar__list li a:hover { color: var(--maroon); }
@media (prefers-reduced-motion: reduce) {
  .breaking-bar__list li { transition: none; }
  .breaking-bar__list--marquee { animation: none; }
}
@media (max-width: 900px) {
  .breaking-bar__list--marquee li { padding-right: 32px; }
}

/* ---------- Section headers ---------- */
.section { padding: 36px 0; }
.section__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.section__title {
  font-size: 24px; font-weight: 700; position: relative; padding-bottom: 10px; display: inline-block;
}
.section__title::after {
  content: ""; position: absolute; left: 0; bottom: 0; width: 56px; height: 6px;
  background:
    linear-gradient(135deg, var(--maroon) 25%, transparent 25%) 0 0,
    linear-gradient(225deg, var(--maroon) 25%, transparent 25%) 0 0;
  background-size: 8px 8px; background-repeat: repeat-x;
}
.section__more { font-size: 13.5px; font-weight: 600; color: var(--teal); font-family: var(--font-utility); }
.section__more:hover { text-decoration: underline; }
.section--tinted { background: var(--paper-dim); }

/* ---------- Hero ---------- */
.hero-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; }
.hero-feature { position: relative; border-radius: var(--radius-m); overflow: hidden; box-shadow: var(--shadow-card); }
.hero-feature img { width: 100%; height: 460px; object-fit: cover; display: block; }
.hero-feature__overlay {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 28px 24px 22px;
  background: linear-gradient(to top, rgba(0,0,0,.85), rgba(0,0,0,0));
  color: #fff;
}
.hero-feature__cat { background: var(--maroon); padding: 3px 10px; border-radius: 4px; font-size: 12px; font-family: var(--font-utility); }
.hero-feature__title { font-size: 30px; line-height: 1.3; margin-top: 10px; }
.hero-feature__title a { color: #fff; }

/* Auto-scrolling hero carousel (multiple top stories, cross-fading) */
.hero-carousel { height: 460px; }
.hero-carousel__slide {
  position: absolute; inset: 0; opacity: 0; visibility: hidden; transition: opacity .7s ease;
  display: block;
}
.hero-carousel__slide.is-active { opacity: 1; visibility: visible; z-index: 1; }
.hero-carousel__slide img { height: 100%; }
.hero-carousel__dots {
  position: absolute; right: 20px; bottom: 20px; z-index: 2; display: flex; gap: 8px;
}
.hero-carousel__dot {
  width: 9px; height: 9px; border-radius: 50%; border: 1.5px solid rgba(255,255,255,.8); background: rgba(255,255,255,.35);
  padding: 0; cursor: pointer; transition: background .2s ease, transform .2s ease;
}
.hero-carousel__dot.is-active { background: var(--gold); border-color: var(--gold); transform: scale(1.15); }
.hero-carousel__dot:hover { background: rgba(255,255,255,.7); }

.hero-side { display: flex; flex-direction: column; gap: 12px; }
.hero-side-item {
  display: flex; gap: 12px; align-items: center; background: var(--card-bg); border: 1px solid var(--line);
  border-radius: 10px; padding: 10px; box-shadow: var(--shadow-card); transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.hero-side-item:hover { transform: translateX(-3px); box-shadow: var(--shadow-hover); border-color: var(--maroon); }
.hero-side-item img { width: 88px; height: 68px; object-fit: cover; border-radius: 8px; flex-shrink: 0; }
.hero-side-item__cat {
  display: inline-block; font-size: 11px; color: #fff; background: var(--maroon); font-weight: 700; font-family: var(--font-utility);
  padding: 2px 9px; border-radius: 12px; letter-spacing: .2px;
}
.hero-side-item__title { font-size: 14.5px; line-height: 1.4; margin-top: 6px; font-weight: 600; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hero-side-item__title a:hover { color: var(--maroon); }

/* ---------- News grid & cards ---------- */
.news-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.news-grid--3 { grid-template-columns: repeat(3, 1fr); }
.news-card {
  background: var(--card-bg); border: 1px solid var(--card-border); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow-card);
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease; display: flex; flex-direction: column;
}
.news-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-hover); border-color: var(--maroon); }
.news-card__image-link { position: relative; display: block; aspect-ratio: 4/3; overflow: hidden; }
.news-card__image { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.news-card:hover .news-card__image { transform: scale(1.08); }
.news-card__badge {
  position: absolute; top: 10px; left: 10px; background: var(--badge-bg); color: var(--badge-text); font-size: var(--category-font-size);
  padding: 4px 11px; border-radius: 20px; font-family: var(--category-font-family, var(--font-utility)); font-weight: var(--category-font-weight, 600);
  box-shadow: 0 2px 6px rgba(0,0,0,.18); letter-spacing: .2px;
}
.news-card__badge--breaking { left: auto; right: 10px; background: var(--maroon); top: 10px; }
.news-card__body { padding: 15px 17px 17px; display: flex; flex-direction: column; gap: 9px; flex: 1; }
.news-card__location { font-size: 11.5px; color: var(--stone); font-family: var(--font-utility); text-transform: uppercase; letter-spacing: .3px; }
.news-card__title {
  font-size: var(--news-title-font-size); font-family: var(--news-title-font-family, var(--font-body)); font-weight: var(--news-title-font-weight, 700); line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.news-card__title a:hover { color: var(--maroon); }
.news-card__excerpt {
  font-size: 13.5px; color: var(--ink-soft); margin: 0;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.news-card__meta {
  margin-top: auto; padding-top: 9px; border-top: 1px dashed var(--line);
  display: flex; justify-content: space-between; font-size: 11.5px; color: var(--stone); font-family: var(--font-utility);
}

/* ---------- District chips ---------- */
.district-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 22px; }
.district-chip {
  padding: 7px 16px; border: 1px solid var(--line); border-radius: 20px; font-size: 13.5px; background: var(--white);
}
.district-chip:hover, .district-chip.is-active { background: var(--maroon); border-color: var(--maroon); color: #fff; }

/* ---------- Sidebar widgets ---------- */
.layout-2col { display: grid; grid-template-columns: 2.4fr 1fr; gap: 28px; align-items: start; }
.widget { background: var(--white); border-radius: var(--radius-m); box-shadow: var(--shadow-card); padding: 18px; margin-bottom: 20px; }
.widget__title { font-size: 17px; font-weight: 700; margin-bottom: 14px; padding-bottom: 10px; border-bottom: 2px solid var(--gold); }
.widget-list li { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.widget-list li:last-child { border: none; }
.widget-list__num { font-family: var(--font-display); font-weight: 700; color: var(--maroon); font-size: 20px; width: 26px; flex-shrink: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 22px; border-radius: 24px;
  font-weight: 600; font-size: 14px; cursor: pointer; border: none; font-family: var(--font-body);
}
.btn--primary { background: var(--btn-bg); color: var(--btn-text); }
.btn--primary:hover { background: var(--maroon-dark); }
.btn--outline { background: transparent; border: 1.5px solid var(--maroon); color: var(--maroon); }
.btn--load-more { display: block; margin: 28px auto 0; }

/* ---------- Newsletter ---------- */
.newsletter-form { display: flex; gap: 8px; margin-top: 10px; }
.newsletter-form input { flex: 1; padding: 9px 12px; border-radius: 6px; border: none; }
.newsletter-form button { background: var(--gold); color: var(--ink); border: none; padding: 9px 16px; border-radius: 6px; font-weight: 700; cursor: pointer; }
.newsletter-form__msg { flex-basis: 100%; font-size: 12.5px; margin: 4px 0 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--footer-bg); color: var(--footer-text); margin-top: 40px; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 30px; padding: 44px 20px 30px; }
.footer__col h4 { color: #fff; font-size: 15px; margin-bottom: 14px; font-family: var(--font-body); }
.footer__col ul li { margin-bottom: 8px; font-size: var(--footer-font-size); font-family: var(--footer-font-family, var(--font-body)); font-weight: var(--footer-font-weight, 400); }
.footer__col ul li a:hover { color: var(--gold); }
.footer__logo { height: 38px; margin-bottom: 10px; }
.footer__social { display: flex; gap: 12px; margin-top: 12px; }
.footer__social a { width: 32px; height: 32px; border-radius: 50%; background: rgba(255,255,255,.08); display: flex; align-items: center; justify-content: center; }
.footer__social a:hover { background: var(--maroon); }
.footer__bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 14px 20px; font-size: 12.5px; text-align: center; }
.footer__bottom-links { margin-left: 10px; }
.footer__bottom-links a:hover { color: var(--gold); }

/* ---------- Footer follow CTA (WhatsApp / Telegram) ---------- */
.footer__follow { background: rgba(255,255,255,.04); border-top: 1px solid rgba(255,255,255,.08); border-bottom: 1px solid rgba(255,255,255,.08); }
.footer__follow-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 16px 20px; }
.footer__follow-label { font-size: 13.5px; color: #F0E9E4; display: flex; align-items: center; gap: 8px; font-family: var(--font-utility); }
.footer__follow-label i { color: var(--gold); }
.footer__follow-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.footer__follow-btn {
  display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 20px;
  font-size: 13px; font-weight: 600; font-family: var(--font-utility); color: #fff;
}
.footer__follow-btn--wa { background: #25D366; }
.footer__follow-btn--wa:hover { background: #1ebc59; }
.footer__follow-btn--tg { background: #2AABEE; }
.footer__follow-btn--tg:hover { background: #1c96d4; }

/* ---------- Back to top (addon) ---------- */
.back-to-top {
  position: fixed; right: 18px; bottom: 18px; width: 42px; height: 42px; border-radius: 50%;
  background: var(--maroon); color: #fff; border: none; box-shadow: var(--shadow-hover);
  display: flex; align-items: center; justify-content: center; font-size: 15px; cursor: pointer;
  z-index: 190; opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity .2s ease, transform .2s ease, visibility .2s ease;
}
.back-to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top:hover { background: var(--maroon-dark); }
@media (max-width: 900px) {
  .back-to-top { bottom: calc(66px + max(6px, env(safe-area-inset-bottom))); right: 14px; }
}

/* ---------- Mobile bottom nav ---------- */
.bottom-nav {
  display: none; position: fixed; bottom: 0; left: 0; right: 0; background: var(--white);
  border-top: 1px solid var(--line); z-index: 200; padding: 6px 0 max(6px, env(safe-area-inset-bottom));
  box-shadow: 0 -2px 10px rgba(0,0,0,0.06);
}
.bottom-nav a, .bottom-nav__more {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10.5px;
  color: var(--stone); background: none; border: none; font-family: var(--font-utility);
}
.bottom-nav a.is-active, .bottom-nav a:hover { color: var(--maroon); }
.bottom-nav i { font-size: 18px; }

/* ---------- Breadcrumb ---------- */
.breadcrumb { padding: 16px 0 6px; font-size: 13px; color: var(--stone); font-family: var(--font-utility); }
.breadcrumb a:hover { color: var(--maroon); }

/* ---------- Back + Home bar (every page except homepage) ---------- */
.back-home-bar { background: var(--paper-dim); border-bottom: 1px solid var(--line); }
.back-home-bar__inner { display: flex; gap: 10px; padding: 8px 20px; }
.back-home-bar__btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 20px;
  font-size: 12.5px; font-family: var(--font-utility); font-weight: 600; color: var(--ink-soft);
  background: var(--white); border: 1px solid var(--line); cursor: pointer;
}
.back-home-bar__btn:hover { color: var(--maroon); border-color: var(--maroon); }
.back-home-bar__btn i { font-size: 11px; }

/* ---------- Article page ---------- */
.article-layout { align-items: start; }
.article { background: var(--white); border-radius: var(--radius-m); box-shadow: var(--shadow-card); padding: 28px 30px 34px; }
.article__meta-top { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; flex-wrap: wrap; }
.article__cat-badge { background: var(--maroon); color: #fff; font-size: 12px; padding: 4px 12px; border-radius: 4px; font-family: var(--font-utility); font-weight: 600; }
.article__location { font-size: 13px; color: var(--stone); font-family: var(--font-utility); }
.article__title { font-size: var(--article-heading-font-size); font-family: var(--article-heading-font-family, var(--font-display)); font-weight: var(--article-heading-font-weight, 700); line-height: 1.35; margin-bottom: 10px; }
.article__subtitle { font-size: 17px; color: var(--ink-soft); font-family: var(--font-body); margin: 0 0 16px; }
.article__byline { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.article__author { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 14px; }
.article__author-avatar { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; }
.article__dates { font-size: 12.5px; color: var(--stone); font-family: var(--font-utility); }
.article__toolbar { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 20px; }
.font-size-controls button {
  border: 1px solid var(--line); background: var(--white); width: 34px; height: 34px; border-radius: 6px; cursor: pointer; font-family: var(--font-utility); font-weight: 700; margin-right: 4px;
}
.font-size-controls button:hover { background: var(--paper-dim); border-color: var(--maroon); color: var(--maroon); }
.share-controls { display: flex; gap: 8px; flex-wrap: wrap; }
.share-controls button {
  border: 1px solid var(--line); background: var(--white); padding: 7px 12px; border-radius: 20px; cursor: pointer; font-size: 13px; font-family: var(--font-utility); display: flex; align-items: center; gap: 6px;
}
.share-controls button:hover { background: var(--maroon); color: #fff; border-color: var(--maroon); }
.article__figure { margin: 0 0 20px; }
.article__image { width: 100%; border-radius: var(--radius-s); max-height: 480px; object-fit: cover; }
.article-content { font-size: var(--article-body-font-size); font-family: var(--article-body-font-family, var(--font-body)); font-weight: var(--article-body-font-weight, 400); line-height: 1.9; color: var(--body-text-color); }
.article-content p { margin: 0 0 20px; }
.article-content h2 { font-size: 24px; margin: 28px 0 14px; }
.article-content h3 { font-size: 20px; margin: 22px 0 12px; }
.article-content img { border-radius: var(--radius-s); margin: 16px 0; }
.article-content blockquote { border-left: 4px solid var(--gold); padding: 10px 20px; margin: 20px 0; font-style: italic; background: var(--paper-dim); border-radius: 0 8px 8px 0; }
.article__tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 24px 0; }
.tag-chip { background: var(--paper-dim); padding: 5px 14px; border-radius: 16px; font-size: 12.5px; color: var(--teal); }
.tag-chip:hover { background: var(--teal); color: #fff; }
.article__prevnext { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 30px 0; }
.prevnext__link { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius-s); font-size: 13.5px; }
.prevnext__link--next { text-align: right; align-items: flex-end; }
.prevnext__link span { color: var(--stone); font-size: 12px; font-family: var(--font-utility); }
.prevnext__link:hover { border-color: var(--maroon); }

@media print {
  .site-header, .topbar, .main-nav, .breaking-bar, .article-sidebar, .article__toolbar,
  .comments-section, .site-footer, .bottom-nav, .mobile-share-bar, .ad-slot, .breadcrumb,
  .article__prevnext { display: none !important; }
  .article { box-shadow: none; padding: 0; }
}

/* ---------- Comments ---------- */
.comments-section { margin-top: 36px; padding-top: 26px; border-top: 1px solid var(--line); }
.comment-form { margin-bottom: 26px; }
.comment-form__row { display: flex; gap: 12px; margin-bottom: 12px; }
.comment-form input, .comment-form textarea {
  width: 100%; padding: 10px 14px; border: 1px solid var(--line); border-radius: var(--radius-s); font-family: var(--font-body); font-size: 14px;
}
.comment-form textarea { margin-bottom: 12px; resize: vertical; }
.comment-form__msg { font-size: 13px; margin-top: 8px; }
.comments-list li { padding: 14px 0; border-bottom: 1px solid var(--line); }
.comment-item__head { display: flex; justify-content: space-between; margin-bottom: 6px; font-size: 13.5px; }
.comment-item__head span { color: var(--stone); font-size: 12px; }
.comment-item--empty { color: var(--stone); text-align: center; border: none; }

/* ---------- Mobile share bar ---------- */
.mobile-share-bar {
  display: none; position: fixed; bottom: 58px; left: 0; right: 0; background: var(--share-bar-bg);
  border-top: 1px solid var(--share-bar-border); min-height: var(--share-bar-height); z-index: 150;
  justify-content: space-around; align-items: center; padding: 8px 0; font-size: var(--share-bar-font-size);
  color: var(--share-bar-text-color);
}
.mobile-share-bar button { background: none; border: none; color: var(--share-icon-color); font-size: var(--share-icon-size); padding: 6px 14px; transition: color .15s ease, filter .15s ease; }
.mobile-share-bar button:hover, .mobile-share-bar button:active { color: var(--share-icon-hover); }

/* "Use Brand Colors: ON" (data-brand="1", set from Admin -> Appearance -> Mobile Sharing Bar).
   Each icon takes a distinct vivid color so the bar reads as fully colorful:
   real platforms get their brand color; "native"/"copy" (no brand of their
   own) get a complementary accent color instead of a flat single tone. */
.mobile-share-bar[data-brand="1"] button[data-share="whatsapp"] { color: #25D366; }
.mobile-share-bar[data-brand="1"] button[data-share="facebook"] { color: #1877F2; }
.mobile-share-bar[data-brand="1"] button[data-share="twitter"] { color: #000000; }
.mobile-share-bar[data-brand="1"] button[data-share="telegram"] { color: #229ED9; }
.mobile-share-bar[data-brand="1"] button[data-share="instagram"] { color: #E1306C; }
.mobile-share-bar[data-brand="1"] button[data-share="native"] { color: #00BCD4; }
.mobile-share-bar[data-brand="1"] button[data-share="copy"] { color: #FFC107; }
.mobile-share-bar[data-brand="1"] button:hover,
.mobile-share-bar[data-brand="1"] button:active { filter: brightness(0.82); }

/* ---------- Public pagination ---------- */
.pub-pagination { display: flex; align-items: center; justify-content: center; gap: 20px; margin: 32px 0; font-family: var(--font-utility); font-size: 13.5px; }
.pub-pagination__link { padding: 8px 18px; border: 1px solid var(--line); border-radius: 20px; }
.pub-pagination__link:hover { background: var(--maroon); border-color: var(--maroon); color: #fff; }
.pub-pagination__info { color: var(--stone); }

/* ---------- Ads ---------- */
.ad-slot { display: flex; align-items: center; justify-content: center; background: var(--paper-dim); border: 1px dashed var(--line); border-radius: var(--radius-s); overflow: hidden; margin: 20px 0; max-width: 100%; }
.ad-slot img { width: 100%; }
.ad-slot iframe, .ad-slot ins, .ad-slot > div { max-width: 100%; }
.ad-slot--header, .ad-slot--top_banner, .ad-slot--footer { margin: 12px 0; }
.ad-slot--sidebar { min-height: 250px; }

/* ==========================================================================
   RESPONSIVE — mobile-first breakpoints
   ========================================================================== */
@media (max-width: 1024px) {
  .news-grid { grid-template-columns: repeat(3, 1fr); }
  .layout-2col { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .header-search { display: none; }
  .hamburger { display: flex; }
  .site-header__inner {
    min-height: var(--header-height-mobile); position: relative;
    flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 18px 50px;
  }

  /* Addon: masthead stacks centered on mobile — tagline, logo, then RNI/editor/phone,
     matching the reference design. Hamburger floats top-right so it doesn't
     interrupt the centered stack. */
  .masthead__brand-col { margin-right: 0; align-items: center; }
  .masthead__meta-col { align-items: center; text-align: center; }
  .hamburger { position: absolute; top: 14px; right: 14px; }
  /* Note: the pipe-divider Menu Bar Style is now scoped entirely to
     @media(min-width:901px) above, so nothing further needs undoing here —
     the mobile drawer always shows its own plain horizontal row-separator
     lines (.main-nav__list > li > a's border-bottom below), regardless of
     the Desktop "Menu Bar Style" setting. */
  /* Addon: Title always sits below the Logo on mobile, regardless of the
     desktop "Logo Position" setting (before/after/above) — narrow screens
     read better stacked than side-by-side. */
  .brand { flex-direction: column !important; align-items: center !important; gap: 6px; }

  /* Addon: off-canvas slide-in drawer (replaces the old push-down panel) */
  .nav-backdrop {
    display: block; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 199;
    opacity: 0; visibility: hidden; transition: opacity .25s ease, visibility .25s ease;
  }
  .nav-backdrop.is-open { opacity: 1; visibility: visible; }
  .main-nav {
    display: block; position: fixed; top: 0; right: 0; bottom: 0; left: auto;
    width: min(320px, 85vw); background: var(--nav-bg);
    max-height: none; overflow-y: auto; box-shadow: -8px 0 24px rgba(0,0,0,.25); z-index: 200;
    transform: translateX(100%); transition: transform .3s ease;
  }
  .main-nav.is-open { transform: translateX(0); }
  .main-nav__drawer-head {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    padding: 16px 18px; border-bottom: 1px solid rgba(255,255,255,.12);
  }
  .main-nav__drawer-head .brand__text { color: #fff; }
  /* Addon: cap the logo shown in the drawer header to a small fixed size,
     independent of whatever custom "Logo Size" is set for the main desktop
     header — otherwise a large custom logo height (now unrestricted, can be
     100s of px) blows up this narrow drawer into one giant empty box. */
  .main-nav__drawer-head .brand { max-height: 40px; overflow: hidden; flex-shrink: 0; padding: 4px 8px !important; }
  .main-nav__drawer-head .brand__logo { height: 32px !important; width: auto !important; max-width: 140px; object-fit: contain; }
  .main-nav__close {
    display: flex; align-items: center; justify-content: center; gap: 7px;
    background: rgba(255,255,255,.1); border: none; color: #fff; padding: 8px 14px;
    border-radius: 20px; cursor: pointer; flex-shrink: 0; font-size: 14px; font-weight: 600;
  }
  .main-nav__close:hover { background: rgba(255,255,255,.2); }
  .main-nav__inner { overflow-x: visible; height: auto; background: transparent; border-radius: 0; padding: 0; }
  .main-nav__list { flex-direction: column; width: auto; min-width: 0; height: auto; }
  .main-nav__list > li { display: block; }
  .main-nav__list > li > a {
    display: flex; align-items: center; justify-content: space-between; padding: 14px 20px;
    border-bottom: 1px solid rgba(255,255,255,.1); height: auto; font-size: 15px;
  }
  .main-nav__list > li > a:active { background: var(--maroon-dark); }
  .main-nav__home {
    padding: 14px 20px !important; justify-content: flex-start !important; gap: 10px !important;
    background: var(--maroon-dark) !important; border-bottom: 1px solid rgba(255,255,255,.1);
  }
  .main-nav__home::after { content: "मुख्यपृष्ठ"; font-size: 15px; }
  .nav-caret { transition: transform .2s ease; }
  .has-dropdown.is-open > a .nav-caret { transform: rotate(180deg); }
  .dropdown {
    position: static; box-shadow: none; background: rgba(0,0,0,.18); display: none;
    border-radius: 0; max-height: none;
  }
  .has-dropdown.is-open .dropdown { display: block; }
  .dropdown li a {
    color: #F0E9E4; padding: 12px 20px 12px 36px; font-size: 14px; border-bottom: 1px solid rgba(255,255,255,.06);
    position: relative;
  }
  .dropdown li a::before { content: "—"; position: absolute; left: 20px; color: var(--gold); }
  .dropdown li a:hover, .dropdown li a:active { background: rgba(255,255,255,.06); color: #fff; }

  .hero-grid { grid-template-columns: 1fr; }
  .hero-feature img { height: 280px; }
  .hero-carousel { height: 280px; }
  .news-grid { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .bottom-nav { display: flex; }
  .mobile-share-bar { display: flex; }
  body { padding-bottom: 62px; }
  .article { padding: 20px 16px 26px; }
  .article__title { font-size: 24px; }
  .article-content { font-size: 17px; }
  .article__prevnext { grid-template-columns: 1fr; }
  .share-controls { display: none; }
}

@media (max-width: 640px) {
  .container { padding: 0 14px; }
  .topbar__meta span:not(:first-child) { display: none; }
  .news-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .news-card__title { font-size: 15px; }
  .hero-feature__title { font-size: 22px; }
  .footer__grid { grid-template-columns: 1fr; padding: 30px 16px; }
  .section__title { font-size: 20px; }
}

@media (max-width: 400px) {
  .news-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
}
