/* BBC Urdu Style Theme - Noto Naskh Arabic, clean white layout, #7A1E2B accent */
/* Matches BBC.com/urdu design: Naskh font, minimal color, generous whitespace */

:root {
  --bbc-red: #7A1E2B;
  --bbc-red-dark: #8B0000;
  --bbc-text: #141414;
  --bbc-text-secondary: #404040;
  --bbc-meta: #5A5A5A;
  --bbc-meta-light: #767676;
  --bbc-border: #E6E6E6;
  --bbc-border-light: #F0F0F0;
  --bbc-bg: #FFFFFF;
  --bbc-bg-alt: #F6F6F6;
  --bbc-font-urdu: 'Noto Naskh Arabic', 'Adobe Arabic', 'Geeza Pro', 'Traditional Arabic', serif;
  --bbc-font-latin: 'Inter', Arial, Helvetica, sans-serif;
}

/* ===== GLOBAL OVERRIDES ===== */
html { direction: rtl; }
body {
  direction: rtl;
  text-align: right;
  font-family: var(--bbc-font-urdu) !important;
  background: var(--bbc-bg);
  color: var(--bbc-text);
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

/* Override Nastaliq fonts everywhere - force Naskh */
body, p, span, div, li, a, h1, h2, h3, h4, h5, h6, label, input, textarea, select, button, td, th {
  font-family: var(--bbc-font-urdu) !important;
}
code, pre, .monospace { font-family: monospace !important; }
.fas, .fab, .far, .fa, i[class*="fa-"] {
  font-family: 'Font Awesome 6 Free', 'Font Awesome 6 Brands' !important;
}

/* Container max-width */
.container { max-width: 1280px; }

/* Links: bold, no color, hover underline */
a { color: var(--bbc-text); text-decoration: none; }
a:hover { text-decoration: underline; color: var(--bbc-text); }

/* ===== HIDE DEFAULT HEADER/NAV ===== */
/* Header hidden via page-level CSS, not globally */

/* ===== SECTION HEADINGS ===== */
.home-section-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--bbc-text);
  border-bottom: none;
  border-top: 4px solid var(--bbc-red);
  padding-top: 10px;
  padding-bottom: 0;
  margin-bottom: 16px;
  text-transform: none;
  letter-spacing: 0;
}

.home-section-more {
  color: var(--bbc-red);
  border: none;
  font-weight: 600;
  font-size: 0.88rem;
  padding: 0;
  border-radius: 0;
}
.home-section-more:hover { text-decoration: underline; color: var(--bbc-red); }

/* ===== NEWS CARDS ===== */
.news-main .card, .news-side .card { border: none; border-radius: 0; box-shadow: none; }
.news-main .card-title {
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 2;
  color: var(--bbc-text);
}
.news-main .card-title a { color: var(--bbc-text); }
.news-main .card-title a:hover { text-decoration: underline; }

.news-side .card-title {
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.8;
}

.card-meta { font-size: 0.78rem; color: var(--bbc-meta); }
.section-badge { color: var(--bbc-red) !important; background: transparent !important; font-weight: 700; font-size: 0.75rem; }

/* ===== ARTICLE LIST ===== */
.article-list-item { border-bottom: 1px solid var(--bbc-border); }
.article-list-title { font-weight: 700; line-height: 1.9; }
.article-list-title a { color: var(--bbc-text); }
.article-list-title a:hover { text-decoration: underline; }
.article-list-meta { color: var(--bbc-meta); }
.article-list-summary { color: var(--bbc-text-secondary); }

/* ===== ARTICLE PAGE ===== */
.article-headline {
  font-size: clamp(1.6rem, 4vw, 2.75rem);
  font-weight: 700;
  line-height: 1.9;
  color: var(--bbc-text);
  direction: rtl;
  text-align: right;
}
.article-subheadline { color: var(--bbc-text-secondary); line-height: 1.8; }
.article-content {
  font-size: 1rem;
  line-height: 2.2;
  color: var(--bbc-text);
  direction: rtl;
  text-align: right;
}
.article-content p { margin-bottom: 1.2em; line-height: 2.2; }
.article-content blockquote {
  border-right: 4px solid var(--bbc-red);
  border-left: none;
  padding-right: 1rem;
  padding-left: 0;
  background: var(--bbc-bg-alt);
}
.article-author-bar { flex-direction: row-reverse; }
.article-author-avatar { display: none !important; }
.article-date, .article-read-time { color: var(--bbc-meta); }
.article-share a:hover { background: var(--bbc-red); color: #fff; }
.article-tags .badge {
  background: var(--bbc-bg-alt);
  color: var(--bbc-text);
  border: 1px solid var(--bbc-border);
}

/* ===== SECTION PAGE ===== */
.section-page-title {
  border-bottom: none;
  border-top: 4px solid var(--bbc-red);
  padding-top: 10px;
  color: var(--bbc-text);
}

/* ===== SIDEBAR ===== */
.sidebar-widget { background: var(--bbc-bg-alt); border-radius: 0; }
.sidebar-widget-title {
  color: var(--bbc-text);
  border-bottom: 4px solid var(--bbc-red);
  padding-bottom: 8px;
}

/* ===== RTL LAYOUT ===== */
.kt-header-inner { flex-direction: row-reverse; }
.kt-header-date { left: auto; right: 0; }
.kt-header-social { right: auto; left: 0; }
.kt-nav-menu { flex-direction: row-reverse; }
.kt-nav-right { flex-direction: row-reverse; }
.kt-search-form { direction: rtl; }
.kt-search-form input { text-align: right; }
.row { direction: rtl; }
ul, ol { padding-right: 2rem; padding-left: 0; }
blockquote { border-right: 4px solid var(--bbc-red); border-left: none; padding-right: 1rem; padding-left: 0; }
.text-start { text-align: right !important; }
.text-end { text-align: left !important; }
.ms-auto { margin-right: auto !important; margin-left: unset !important; }
.me-auto { margin-left: auto !important; margin-right: unset !important; }
.float-start { float: right !important; }
.float-end { float: left !important; }
input, textarea, select { direction: rtl; text-align: right; }
.breadcrumb { direction: rtl; }

/* ===== NEWS GRID RTL ===== */
.news-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 20px; direction: rtl; }
.news-main { grid-column: 1; grid-row: 1 / span 3; }
.news-side { display: flex; flex-direction: row-reverse; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--bbc-border); }
.news-side:last-child { border-bottom: none; }
.news-side img { width: 110px; min-width: 110px; height: 75px; object-fit: cover; border-radius: 0; }
.news-side div { text-align: right; flex: 1; }

/* ===== ARTICLE LIST RTL ===== */
.article-list-item { flex-direction: row-reverse; gap: 14px; }
.article-list-item div { text-align: right; }
.article-list-img { border-radius: 0; }

/* ===== NEWSLETTER ===== */
.newsletter-section {
  background: var(--bbc-bg-alt) !important;
  color: var(--bbc-text) !important;
  direction: rtl;
  border-top: 1px solid var(--bbc-border);
}
.newsletter-section h4 { color: var(--bbc-text); }
.newsletter-section .text-muted { color: var(--bbc-meta) !important; }
.newsletter-form { flex-direction: row-reverse; }
.newsletter-form input {
  background: #fff;
  border: 1px solid var(--bbc-border);
  color: var(--bbc-text);
}
.btn-accent {
  background: var(--bbc-red) !important;
  color: #fff !important;
  border: none;
  font-weight: 600;
}
.btn-accent:hover { background: var(--bbc-red-dark) !important; }

/* ===== FOOTER ===== */
footer.site-footer {
  background: #1a1a1a !important;
  direction: rtl;
  text-align: right;
}
footer a { color: rgba(255,255,255,0.7) !important; }
.footer-heading { text-align: right; color: #fff; text-transform: none; letter-spacing: 0; }
.footer-links { text-align: right; }
.footer-links a:hover { color: #fff; }
.footer-bottom { text-align: center; }
.footer-brand { font-family: var(--bbc-font-urdu) !important; }
.footer-social a:hover { color: var(--bbc-red); }

/* ===== BREAKING BAR ===== */
.breaking-bar { background: var(--bbc-red); }
.breaking-label { background: rgba(0,0,0,0.3); }

/* ===== HERO ===== */
.hero-headline { font-family: var(--bbc-font-urdu) !important; }

/* ===== PAGINATION ===== */
.pagination .page-item.active .page-link {
  background: var(--bbc-red);
  border-color: var(--bbc-red);
}

/* ===== COMPACT LIST ===== */
.compact-list li { border-bottom: 1px solid var(--bbc-border); }
.compact-list a { font-weight: 600; }
.compact-list a:hover { color: var(--bbc-red); }

/* ===== DARK MODE ===== */
body.dark-mode {
  --bbc-bg: #1a1a2e;
  --bbc-bg-alt: #16213e;
  --bbc-text: #e0e0e0;
  --bbc-text-secondary: #b0b0b0;
  --bbc-meta: #888;
  --bbc-border: #2a2a4a;
}
body.dark-mode { background: var(--bbc-bg); color: var(--bbc-text); }
body.dark-mode .kt-header { background: #0f0f23; }
body.dark-mode .news-main .card-title, body.dark-mode .news-main .card-title a { color: var(--bbc-text); }
body.dark-mode .article-headline { color: var(--bbc-text); }
body.dark-mode .sidebar-widget { background: var(--bbc-bg-alt); }
body.dark-mode footer.site-footer { background: #0a0a1a !important; }

/* ===== MOBILE ===== */
@media (max-width: 768px) {
  .news-grid { grid-template-columns: 1fr; }
  .news-main { grid-column: 1; grid-row: auto; }
  .news-main .card-title { font-size: 1.1rem; }
  .news-side { flex-direction: row-reverse; gap: 10px; }
  .news-side img { width: 90px; min-width: 90px; height: 65px; }
  .article-headline { font-size: 1.3rem; line-height: 1.8; }
  .article-list-item { flex-direction: row-reverse; gap: 10px; }
  .article-list-img { width: 90px; min-width: 90px; height: 65px; }
  .home-section-title { font-size: 1.15rem; }
}

/* ===== ENHANCED MOBILE ===== */
@media (max-width: 768px) {
  body { font-size: 1rem; line-height: 1.9; }
  .container { padding-left: 14px; padding-right: 14px; }
  
  /* Article page */
  .article-headline { font-size: 1.5rem !important; line-height: 2 !important; font-weight: 700 !important; }
  .article-subheadline { font-size: 1rem; line-height: 1.8; }
  .article-content { font-size: 1rem; line-height: 2.2 !important; }
  .article-content p { font-size: 1rem; line-height: 2.2; }
  .article-hero-img { max-height: 250px; }
  .article-author-bar { gap: 10px; padding: 12px 0; }
  .article-author-name { font-size: 1rem; }
  .article-date, .article-read-time { font-size: 0.85rem; }
  .article-share a { width: 38px; height: 38px; font-size: 1rem; }
  .article-tags .badge { font-size: 0.85rem; padding: 6px 14px; }
  
  /* Section page */
  .section-page-title { font-size: 1.5rem !important; font-weight: 700 !important; }
  .article-list-item { gap: 12px !important; padding: 14px 0 !important; }
  .article-list-img { width: 120px !important; min-width: 120px !important; height: 80px !important; }
  .article-list-title { font-size: 1rem !important; line-height: 1.8 !important; font-weight: 700 !important; }
  .article-list-summary { font-size: 0.88rem; }
  .article-list-meta { font-size: 0.8rem; }
  
  /* Sidebar */
  .sidebar-widget { padding: 16px; }
  .sidebar-widget-title { font-size: 1.15rem; }
  .compact-list a { font-size: 0.95rem; }
  
  /* Newsletter */
  .newsletter-section { padding: 24px 0 !important; }
  .newsletter-section h4 { font-size: 1.2rem; }
  .newsletter-form { flex-direction: column !important; gap: 8px !important; }
  .newsletter-form input { max-width: 100% !important; font-size: 1rem; }
  
  /* Footer */
  .site-footer { padding: 28px 0 14px !important; }
  .footer-brand { font-size: 1.2rem !important; }
  .footer-links a { font-size: 0.92rem !important; }
  
  /* Home sections */
  .home-section { padding: 18px 0 !important; }
  .home-section-title { font-size: 1.3rem !important; }
  
  /* News grid */
  .news-main .card-title { font-size: 1.2rem !important; line-height: 1.8 !important; }
  .news-side .card-title { font-size: 0.95rem !important; }
  
  /* Pagination */
  .pagination .page-link { font-size: 0.88rem; padding: 6px 12px; }
  
  /* Section badge */
  .section-badge { font-size: 0.85rem !important; }
}

@media (max-width: 400px) {
  .article-headline { font-size: 1.3rem !important; }
  .section-page-title { font-size: 1.3rem !important; }
}
