/* Design System for Nagrik Abhivyakti (नागरिक अभिव्यक्ति) */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Devanagari:wght@400;500;600;700;800&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:wght,FILL@100..700,0..1&display=swap');

/* Prevent layout shift during custom font loading */
@font-face {
  font-family: 'Noto Sans Devanagari';
  font-display: swap;
}
@font-face {
  font-family: 'Material Symbols Outlined';
  font-display: swap;
}

:root {
  --color-primary: #ba0014;
  --color-breaking-red: #E31E25;
  --color-surface-ink: #221F1F;
  --color-on-surface: #1a1c1d;
  --color-tertiary: #5f5a5a;
  --color-paper-white: #FFFFFF;
  --color-background: #f9f9fb;
  --color-surface-low: #f3f3f5;
  --color-border-gray: #E1E1E6;
  
  --font-family: 'Noto Sans Devanagari', sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
}

body {
  font-family: var(--font-family);
  background-color: var(--color-paper-white);
  color: var(--color-on-surface);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  vertical-align: middle;
}

.icon-filled {
  font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* Breaking Ticker */
@keyframes ticker {
  0% { transform: translateX(100%); }
  100% { transform: translateX(-100%); }
}

.breaking-ticker {
  display: inline-block;
  white-space: nowrap;
  animation: ticker 35s linear infinite;
}

.breaking-ticker:hover {
  animation-play-state: paused;
}

/* Hide Scrollbar for Horizontal Navigation */
.hide-scrollbar::-webkit-scrollbar {
  display: none;
}
.hide-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Category Badge Styling */
.badge-breaking {
  background-color: var(--color-breaking-red);
  color: #FFFFFF;
  font-weight: 700;
  padding: 2px 8px;
  font-size: 12px;
  text-transform: uppercase;
}

.badge-category {
  background-color: var(--color-surface-ink);
  color: #FFFFFF;
  font-weight: 600;
  padding: 2px 10px;
  font-size: 13px;
}

.badge-hadoti {
  background-color: #d97706;
  color: #FFFFFF;
  font-weight: 700;
  padding: 2px 8px;
  font-size: 12px;
}

.badge-samajik {
  background-color: #0d9488;
  color: #FFFFFF;
  font-weight: 700;
  padding: 2px 8px;
  font-size: 12px;
}

/* Line Clamps */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Card Hover Effects */
.news-card-hover {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.news-card-hover:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Modal Styling */
.modal-overlay {
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
}

/* Seamless Infinite Marquee Ticker - Slow & Readable */
@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.animate-marquee {
  display: inline-flex;
  white-space: nowrap;
  animation: marquee 75s linear infinite;
  will-change: transform;
}
.pause-marquee:hover {
  animation-play-state: paused;
}

/* Article Editorial Quote Styling (उद्धरण / कोट) */
#article-content blockquote, article blockquote {
  border-left: 4px solid #ba0014;
  background-color: #f8fafc;
  padding: 1rem 1.25rem;
  margin: 1.25rem 0;
  font-style: italic;
  font-size: 1.05rem;
  color: #1e293b !important;
  border-radius: 0 4px 4px 0;
}
#article-content blockquote p, article blockquote p {
  margin: 0;
  font-weight: 600;
  line-height: 1.6;
  color: #1e293b !important;
}

/* Article Reader High Contrast Text & Selection Styling */
#article-content, #article-content p, #article-content h1, #article-content h2, #article-content h3, #article-content h4, #article-content h5, #article-content h6, #article-content span, #article-content div, #article-content li {
  color: #111827 !important;
}
#article-content h1, #article-content h2, #article-content h3, #article-content h4 {
  font-weight: 800 !important;
  color: #0f172a !important;
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
}
#article-content strong, #article-content b {
  color: #000000 !important;
  font-weight: 700 !important;
}
#article-content ::selection, article ::selection {
  background-color: #b91c1c !important; /* Rich Dark Red Highlight */
  color: #ffffff !important;           /* Crisp White Text when highlighted */
}
#article-content ::-moz-selection, article ::-moz-selection {
  background-color: #b91c1c !important;
  color: #ffffff !important;
}









/* Clean Unclipped Vertical Dropdown Overlays for Desktop */
header, nav {
  overflow: visible !important;
}

@media (min-width: 768px) {
  .nav-categories-bar {
    overflow: visible !important;
    display: flex !important;
    flex-wrap: wrap !important;
  }

  .relative.group {
    position: relative !important;
  }

  .relative.group .absolute {
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    z-index: 999999 !important;
    background-color: #ffffff !important;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.25), 0 8px 10px -6px rgba(0, 0, 0, 0.15) !important;
    display: flex !important;
    flex-direction: column !important;
    white-space: normal !important;
  }

  .relative.group .absolute a {
    display: block !important;
    width: 100% !important;
    text-align: left !important;
    white-space: nowrap !important;
  }
}

/* Mobile Devices: Smooth Horizontal Scrolling Bar & Drawer Only for Subcategories */
@media (max-width: 767px) {
  .nav-categories-bar {
    overflow-x: auto !important;
    overflow-y: hidden !important;
    display: flex !important;
    flex-wrap: nowrap !important;
    white-space: nowrap !important;
    -webkit-overflow-scrolling: touch;
  }
  
  /* Disable hover popups on mobile to prevent clipping issues */
  .relative.group .absolute {
    display: none !important;
  }
}