/* ===================================
   MOUWATIN360 — GLOBAL STYLESHEET
   RTL Arabic Editorial Website
   =================================== */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;500;600;700;800;900&display=swap');

/* ===================================
   CSS VARIABLES
=================================== */
:root {
  /* Brand Blues */
  --blue-900: #0C2340;
  --blue-800: #103160;
  --blue-700: #1A4D8F;
  --blue-600: #2361A8;
  --blue-500: #2E76C2;
  --blue-400: #5A9BD4;
  --blue-200: #A8CBE8;
  --blue-100: #D9EAFB;
  --blue-50:  #EDF5FC;

  /* Green Accents */
  --green-700: #145C36;
  --green-600: #1B7A4A;
  --green-500: #22A060;
  --green-100: #CCE9D9;
  --green-50:  #E8F5EE;

  /* Alert */
  --red-700:   #A93226;
  --red-600:   #C0392B;
  --red-50:    #FDEDEC;

  /* Neutrals */
  --gray-900: #0D1520;
  --gray-800: #1A202C;
  --gray-700: #2D3748;
  --gray-600: #4A5568;
  --gray-500: #718096;
  --gray-400: #A0AEC0;
  --gray-300: #CBD5E0;
  --gray-200: #E2E8F0;
  --gray-150: #EDF0F5;
  --gray-100: #F0F4F8;
  --gray-50:  #F7F9FC;
  --white:    #FFFFFF;

  /* Typography */
  --font: 'Cairo', 'Segoe UI', 'Arial', Tahoma, sans-serif;
  --line-height-body:    1.8;
  --line-height-heading: 1.35;
  --line-height-tight:   1.2;

  /* Spacing (8px grid) */
  --space-1:  4px;
  --space-2:  8px;
  --space-3:  12px;
  --space-4:  16px;
  --space-5:  20px;
  --space-6:  24px;
  --space-8:  32px;
  --space-10: 40px;
  --space-12: 48px;
  --space-16: 64px;

  /* Elevation */
  --shadow-xs: 0 1px 2px rgba(0,0,0,0.06);
  --shadow-sm: 0 2px 6px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 14px rgba(0,0,0,0.09);
  --shadow-lg: 0 8px 28px rgba(0,0,0,0.11);

  /* Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition:      0.22s ease;
}

/* ===================================
   RESET & BASE
=================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  direction: rtl;
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font);
  background: var(--gray-50);
  color: var(--gray-800);
  line-height: var(--line-height-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition);
}

ul, ol { list-style: none; }

button {
  font-family: var(--font);
  cursor: pointer;
  border: none;
  background: none;
  line-height: inherit;
}

input, textarea, select {
  font-family: var(--font);
  font-size: inherit;
}

/* --- Global focus ring (accessibility) --- */
:focus-visible {
  outline: 2px solid var(--blue-500);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* ===================================
   LAYOUT
=================================== */
.container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 var(--space-6);
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-6); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-6); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-5); }

/* ===================================
   BADGES & LABELS
=================================== */
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2px;
  line-height: 1.6;
}

.badge-blue    { background: var(--blue-700); color: var(--white); }
.badge-green   { background: var(--green-600); color: var(--white); }
.badge-red     { background: var(--red-600); color: var(--white); }
.badge-brown   { background: #7B4F1E; color: var(--white); }
.badge-gray    { background: var(--gray-200); color: var(--gray-700); }

/* ===================================
   SECTION HEADER
=================================== */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-6);
  padding-bottom: var(--space-3);
  border-bottom: 2px solid var(--gray-200);
}

.section-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--gray-900);
  display: flex;
  align-items: center;
  gap: 10px;
  line-height: var(--line-height-tight);
}

.section-title::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 22px;
  background: var(--green-600);
  border-radius: 2px;
  flex-shrink: 0;
}

.section-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--blue-700);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  transition: color var(--transition);
}

.section-link:hover { color: var(--blue-500); }
.section-link::after { content: ' ←'; font-size: 14px; }

/* ===================================
   TOP BAR
=================================== */
.topbar {
  background: var(--blue-900);
  padding: 7px 0;
  font-size: 12px;
  color: var(--blue-100);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.topbar-links {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.topbar-links a {
  color: var(--blue-200);
  font-size: 12px;
  font-weight: 500;
  transition: color var(--transition);
}

.topbar-links a:hover { color: var(--white); }

/* ===================================
   HEADER
=================================== */
.site-header {
  background: var(--blue-700);
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: 0 2px 10px rgba(10, 35, 64, 0.32);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 0;
  gap: var(--space-6);
}

/* --- Logo --- */
.site-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  text-decoration: none;
}

.logo-mark {
  width: 38px;
  height: 38px;
  background: var(--green-600);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 900;
  color: var(--white);
  letter-spacing: -0.5px;
  flex-shrink: 0;
}

.logo-text-main {
  font-size: 21px;
  font-weight: 900;
  color: var(--white);
  letter-spacing: -0.3px;
  line-height: var(--line-height-tight);
  display: block;
}

.logo-text-sub {
  font-size: 10px;
  color: var(--blue-100);
  font-weight: 400;
  opacity: 0.72;
  display: block;
  line-height: 1.4;
}

/* --- Primary Navigation --- */
.main-nav {
  flex: 1;
  display: flex;
  justify-content: center;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 2px;
}

.nav-list a {
  display: block;
  padding: 7px 13px;
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,0.82);
  border-radius: var(--radius-sm);
  transition: background var(--transition), color var(--transition);
  white-space: nowrap;
}

.nav-list a:hover,
.nav-list a.active {
  background: rgba(255,255,255,0.13);
  color: var(--white);
}

/* --- Header Actions --- */
.header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.btn-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.8);
  font-size: 16px;
  transition: background var(--transition), color var(--transition);
  background: transparent;
  border: none;
}

.btn-icon:hover {
  background: rgba(255,255,255,0.13);
  color: var(--white);
}

.mobile-menu-btn {
  display: none;
  color: var(--white);
  font-size: 22px;
  padding: 4px;
  line-height: 1;
  background: transparent;
  border: none;
}

/* --- Search Bar --- */
.search-bar {
  display: none;
  background: var(--blue-800);
  border-top: 1px solid rgba(255,255,255,0.08);
}

.search-bar.open { display: block; }

.search-bar-inner { padding: 12px 0; }

.search-form { display: flex; gap: 8px; }

.search-input {
  flex: 1;
  padding: 10px 16px;
  background: rgba(255,255,255,0.1);
  border: 1.5px solid rgba(255,255,255,0.18);
  border-radius: var(--radius-sm);
  color: var(--white);
  font-size: 14px;
  font-family: var(--font);
  outline: none;
  transition: border-color var(--transition), background var(--transition);
}

.search-input::placeholder { color: rgba(255,255,255,0.42); }
.search-input:focus {
  border-color: rgba(255,255,255,0.45);
  background: rgba(255,255,255,0.15);
  outline: none;
}

.btn-search-submit {
  padding: 10px 20px;
  background: var(--green-600);
  color: var(--white);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  font-family: var(--font);
  transition: background var(--transition);
  border: none;
  cursor: pointer;
}

.btn-search-submit:hover { background: var(--green-700); }

/* --- Mobile Navigation --- */
.mobile-nav {
  display: none;
  background: var(--blue-800);
  border-top: 1px solid rgba(255,255,255,0.07);
}

.mobile-nav.open { display: block; }

.mobile-nav-list { padding: 8px 0; }

.mobile-nav-list a {
  display: block;
  padding: 11px 24px;
  font-size: 14px;
  font-weight: 600;
  color: rgba(255,255,255,0.8);
  border-bottom: 1px solid rgba(255,255,255,0.04);
  transition: background var(--transition), color var(--transition);
}

.mobile-nav-list a:hover,
.mobile-nav-list a.active {
  background: rgba(255,255,255,0.07);
  color: var(--white);
}

/* ===================================
   BREAKING NEWS TICKER
=================================== */
.breaking-news {
  background: var(--red-600);
  padding: 8px 0;
  overflow: hidden;
}

.breaking-inner {
  display: flex;
  align-items: center;
  gap: 14px;
}

.breaking-label {
  background: var(--white);
  color: var(--red-600);
  font-size: 10px;
  font-weight: 900;
  padding: 3px 10px;
  border-radius: 2px;
  white-space: nowrap;
  flex-shrink: 0;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.breaking-ticker {
  overflow: hidden;
  flex: 1;
}

.ticker-track {
  display: flex;
  gap: 64px;
  animation: tickerScroll 38s linear infinite;
  white-space: nowrap;
}

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

.ticker-item {
  font-size: 13px;
  font-weight: 600;
  color: var(--white);
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.ticker-item::before {
  content: '◆';
  font-size: 7px;
  opacity: 0.55;
  flex-shrink: 0;
}

@keyframes tickerScroll {
  0%   { transform: translateX(-50%); }
  100% { transform: translateX(0); }
}

/* ===================================
   HERO SECTION
=================================== */
.hero-section {
  background: var(--white);
  padding: var(--space-8) 0;
  border-bottom: 1px solid var(--gray-200);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 375px;
  gap: var(--space-6);
  align-items: start;
}

/* --- Featured card --- */
.featured-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.featured-card-image {
  width: 100%;
  height: 448px;
  object-fit: cover;
  display: block;
}

.featured-card-overlay {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 40px 28px 28px;
  background: linear-gradient(
    to top,
    rgba(8, 20, 42, 0.97) 0%,
    rgba(8, 20, 42, 0.60) 55%,
    transparent 100%
  );
}

.featured-card-overlay .badge { margin-bottom: 10px; }

.featured-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--white);
  line-height: 1.45;
  margin-bottom: 12px;
}

.featured-title a { color: var(--white); }

.featured-title a:hover { color: var(--blue-100); }

.featured-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 12px;
  color: rgba(255,255,255,0.62);
  flex-wrap: wrap;
}

.featured-meta span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

/* --- Secondary stories --- */
.hero-secondary {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.secondary-card {
  display: flex;
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: box-shadow var(--transition), border-color var(--transition);
}

.secondary-card:hover {
  box-shadow: var(--shadow-sm);
  border-color: var(--gray-300);
}

.secondary-card-image {
  width: 128px;
  height: 118px;
  object-fit: cover;
  flex-shrink: 0;
}

.secondary-card-body {
  padding: 14px 16px;
  flex: 1;
  min-width: 0;
}

.secondary-card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--gray-800);
  line-height: 1.55;
  margin: 7px 0 10px;
}

.secondary-card-title a:hover { color: var(--blue-700); }

.card-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--gray-500);
  flex-wrap: wrap;
}

.card-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* ===================================
   ARTICLE CARDS
=================================== */
.article-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
  display: flex;
  flex-direction: column;
}

.article-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  border-color: var(--gray-300);
}

.article-card-image {
  width: 100%;
  height: 195px;
  object-fit: cover;
}

.article-card-body {
  padding: 18px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.article-card-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--gray-900);
  line-height: 1.55;
  margin: 8px 0 10px;
  flex: 1;
}

.article-card-title a:hover { color: var(--blue-700); }

.article-card-excerpt {
  font-size: 13.5px;
  color: var(--gray-600);
  line-height: 1.75;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1px solid var(--gray-150);
  margin-top: auto;
}

.read-more {
  font-size: 13px;
  font-weight: 700;
  color: var(--blue-700);
  display: inline-flex;
  align-items: center;
  gap: 3px;
  transition: color var(--transition);
}

.read-more:hover { color: var(--blue-500); }
.read-more::after { content: ' ←'; }

/* ===================================
   CONTENT SECTIONS
=================================== */
.content-section { padding: var(--space-10) 0; }
.content-section.bg-white { background: var(--white); }
.content-section.bg-light { background: var(--blue-50); }

.latest-section {
  padding: var(--space-10) 0 var(--space-12);
  background: var(--white);
  border-top: 1px solid var(--gray-200);
}

/* ===================================
   NEWSLETTER SECTION
=================================== */
.newsletter-section {
  background: var(--blue-800);
  padding: var(--space-16) 0;
}

.newsletter-inner {
  text-align: center;
  max-width: 560px;
  margin: 0 auto;
}

.newsletter-title {
  font-size: 26px;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 10px;
  line-height: var(--line-height-heading);
}

.newsletter-sub {
  font-size: 15px;
  color: var(--blue-100);
  margin-bottom: 28px;
  opacity: 0.88;
  line-height: 1.7;
}

.newsletter-form { display: flex; gap: 10px; position: relative; }

.newsletter-input {
  flex: 1;
  padding: 12px 18px;
  background: rgba(255,255,255,0.1);
  border: 1.5px solid rgba(255,255,255,0.2);
  border-radius: var(--radius-sm);
  color: var(--white);
  font-size: 14px;
  font-family: var(--font);
  outline: none;
  transition: border-color var(--transition), background var(--transition);
}

.newsletter-input::placeholder { color: rgba(255,255,255,0.4); }

.newsletter-input:focus {
  border-color: rgba(255,255,255,0.5);
  background: rgba(255,255,255,0.15);
}

.newsletter-input.field-error {
  border-color: #f97171 !important;
  background: rgba(249, 113, 113, 0.1) !important;
}

.btn-newsletter {
  padding: 12px 24px;
  background: var(--green-600);
  color: var(--white);
  font-size: 14px;
  font-weight: 700;
  font-family: var(--font);
  border-radius: var(--radius-sm);
  white-space: nowrap;
  transition: background var(--transition);
  border: none;
  cursor: pointer;
}

.btn-newsletter:hover { background: var(--green-700); }
.btn-newsletter:disabled { opacity: 0.7; cursor: not-allowed; }

.newsletter-msg {
  font-size: 13px;
  margin-top: 12px;
  min-height: 18px;
}

.newsletter-msg.success { color: #6EE7A0; }
.newsletter-msg.error   { color: #F97171; }

.newsletter-note {
  font-size: 12px;
  color: var(--blue-100);
  opacity: 0.52;
  margin-top: 12px;
}

/* ===================================
   FOOTER
=================================== */
.site-footer { background: var(--blue-900); color: var(--blue-100); }

.footer-main { padding: var(--space-12) 0 var(--space-8); }

.footer-grid {
  display: grid;
  grid-template-columns: 260px 1fr 1fr 1fr;
  gap: var(--space-10);
}

.footer-brand { display: flex; flex-direction: column; gap: var(--space-4); }

.footer-logo-text {
  font-size: 24px;
  font-weight: 900;
  color: var(--white);
  line-height: 1;
}

.footer-logo-text span { color: var(--green-500); }

.footer-tagline {
  font-size: 13px;
  color: var(--blue-400);
  line-height: 1.85;
}

/* --- Social buttons (SVG-style text icons) --- */
.footer-social { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }

.social-btn {
  width: 34px;
  height: 34px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--blue-200);
  transition: background var(--transition), color var(--transition), border-color var(--transition);
  text-decoration: none;
}

.social-btn:hover {
  background: var(--green-600);
  color: var(--white);
  border-color: var(--green-600);
}

.footer-col-title {
  font-size: 11px;
  font-weight: 800;
  color: var(--white);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: var(--space-4);
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}

.footer-links { display: flex; flex-direction: column; gap: 9px; }

.footer-links a {
  font-size: 13px;
  color: var(--blue-400);
  transition: color var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  line-height: 1.5;
}

.footer-links a::before {
  content: '‹';
  font-size: 14px;
  color: var(--green-500);
  line-height: 1;
  flex-shrink: 0;
}

.footer-links a:hover { color: var(--white); }

.footer-bottom {
  background: rgba(0,0,0,0.22);
  padding: 15px 0;
  border-top: 1px solid rgba(255,255,255,0.05);
}

.footer-bottom-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--blue-400);
  flex-wrap: wrap;
  gap: 8px;
}

.footer-bottom-links { display: flex; gap: 20px; }

.footer-bottom-links a {
  color: var(--blue-400);
  font-size: 12px;
  transition: color var(--transition);
}

.footer-bottom-links a:hover { color: var(--white); }

/* ===================================
   ARTICLE PAGE
=================================== */
.article-page { padding: var(--space-8) 0 var(--space-16); }

/* RTL layout: main content right, sidebar left */
.article-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: var(--space-8);
  align-items: start;
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  color: var(--gray-500);
  margin-bottom: var(--space-5);
  flex-wrap: wrap;
}

.breadcrumb a { color: var(--blue-700); }
.breadcrumb a:hover { color: var(--blue-500); text-decoration: underline; }
.breadcrumb-sep { color: var(--gray-300); font-size: 11px; }

.article-header { margin-bottom: var(--space-6); }

.article-category-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 14px;
}

.article-title {
  font-size: 34px;
  font-weight: 900;
  color: var(--gray-900);
  line-height: 1.38;
  margin-bottom: var(--space-4);
}

.article-subtitle {
  font-size: 17px;
  color: var(--gray-600);
  line-height: 1.8;
  border-right: 3px solid var(--blue-500);
  padding-right: 16px;
  margin-bottom: var(--space-5);
}

.article-meta-bar {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 13px 0;
  border-top: 1px solid var(--gray-200);
  border-bottom: 1px solid var(--gray-200);
  margin-bottom: var(--space-6);
  flex-wrap: wrap;
}

.meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--gray-600);
}

.meta-icon { font-size: 14px; color: var(--gray-400); }

.article-hero-image {
  width: 100%;
  height: 420px;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: 10px;
}

.article-image-caption {
  font-size: 12px;
  color: var(--gray-500);
  text-align: center;
  margin-bottom: var(--space-8);
  font-style: italic;
  line-height: 1.6;
}

/* --- Article body typography --- */
.article-content {
  font-size: 16.5px;
  line-height: 1.95;
  color: var(--gray-800);
}

.article-content p { margin-bottom: var(--space-5); }

.article-content h2 {
  font-size: 21px;
  font-weight: 800;
  color: var(--gray-900);
  margin: var(--space-8) 0 var(--space-4);
  padding-right: 14px;
  border-right: 4px solid var(--blue-700);
  line-height: 1.4;
}

.article-content h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--gray-900);
  margin: var(--space-6) 0 var(--space-3);
  line-height: 1.4;
}

.article-content blockquote {
  background: var(--blue-50);
  border-right: 4px solid var(--blue-700);
  padding: 18px 20px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: var(--space-6) 0;
  font-size: 15.5px;
  color: var(--gray-700);
  font-style: italic;
  line-height: 1.85;
}

/* --- Tags --- */
.article-tags {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: var(--space-8);
  padding-top: var(--space-6);
  border-top: 1px solid var(--gray-200);
  flex-wrap: wrap;
}

.tags-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-700);
  flex-shrink: 0;
}

.tag {
  display: inline-block;
  padding: 5px 13px;
  background: var(--gray-100);
  color: var(--gray-700);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--gray-200);
  transition: background var(--transition), color var(--transition), border-color var(--transition);
}

.tag:hover {
  background: var(--blue-700);
  color: var(--white);
  border-color: var(--blue-700);
}

/* --- Share --- */
.share-section {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: var(--space-6);
  padding: var(--space-4) 0;
  border-top: 1px solid var(--gray-200);
  flex-wrap: wrap;
}

.share-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-700);
  flex-shrink: 0;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 15px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 700;
  font-family: var(--font);
  transition: opacity var(--transition);
  border: none;
  cursor: pointer;
}

.share-btn:hover { opacity: 0.84; }
.share-btn-fb { background: #1877F2; color: var(--white); }
.share-btn-tw { background: #1DA1F2; color: var(--white); }
.share-btn-wa { background: #25D366; color: var(--white); }
.share-btn-cp { background: var(--gray-200); color: var(--gray-700); }

/* ===================================
   SIDEBAR
=================================== */
.sticky-sidebar { position: sticky; top: 88px; }

.sidebar-widget {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-6);
  overflow: hidden;
}

.sidebar-widget-title {
  font-size: 11px;
  font-weight: 800;
  color: var(--gray-900);
  padding: 12px 16px;
  border-bottom: 1px solid var(--gray-200);
  background: var(--gray-50);
  text-transform: uppercase;
  letter-spacing: 0.7px;
}

.sidebar-widget-body { padding: 12px 16px; }

.sidebar-article {
  display: flex;
  gap: 10px;
  padding: 11px 0;
  border-bottom: 1px solid var(--gray-150);
}

.sidebar-article:last-child { border-bottom: none; }

.sidebar-article-img {
  width: 68px;
  height: 58px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}

.sidebar-article-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-800);
  line-height: 1.55;
  margin-bottom: 5px;
}

.sidebar-article-title a:hover { color: var(--blue-700); }
.sidebar-article-date { font-size: 11px; color: var(--gray-500); }

.sidebar-categories a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-700);
  border-bottom: 1px solid var(--gray-150);
  transition: color var(--transition);
}

.sidebar-categories a:last-child { border-bottom: none; }
.sidebar-categories a:hover { color: var(--blue-700); }

.cat-count {
  font-size: 11px;
  background: var(--gray-100);
  color: var(--gray-500);
  padding: 2px 7px;
  border-radius: 10px;
  font-weight: 700;
}

/* --- Related Articles --- */
.related-section {
  margin-top: var(--space-12);
  padding-top: var(--space-8);
  border-top: 2px solid var(--gray-200);
}

.related-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: var(--space-6);
  display: flex;
  align-items: center;
  gap: 10px;
  line-height: var(--line-height-tight);
}

.related-title::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 22px;
  background: var(--green-600);
  border-radius: 2px;
  flex-shrink: 0;
}

/* ===================================
   CATEGORY PAGE
=================================== */
.category-hero {
  background: var(--blue-700);
  padding: var(--space-10) 0;
  margin-bottom: var(--space-10);
}

.category-hero-title {
  font-size: 32px;
  font-weight: 900;
  color: var(--white);
  margin-bottom: 6px;
  line-height: var(--line-height-heading);
}

.category-hero-desc {
  font-size: 15px;
  color: var(--blue-100);
  opacity: 0.88;
  line-height: 1.75;
  max-width: 640px;
}

.category-page-body { padding-bottom: var(--space-16); }

.category-filters {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: var(--space-8);
  flex-wrap: wrap;
}

.filter-btn {
  padding: 7px 17px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  font-family: var(--font);
  border: 1.5px solid var(--gray-300);
  color: var(--gray-600);
  background: var(--white);
  transition: all var(--transition);
  cursor: pointer;
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--blue-700);
  border-color: var(--blue-700);
  color: var(--white);
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: var(--space-12);
}

.page-btn {
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  font-family: var(--font);
  border: 1.5px solid var(--gray-300);
  color: var(--gray-700);
  background: var(--white);
  transition: all var(--transition);
  cursor: pointer;
}

.page-btn:hover { background: var(--gray-100); }

.page-btn.active {
  background: var(--blue-700);
  border-color: var(--blue-700);
  color: var(--white);
}

.page-btn-wide { width: auto; padding: 0 14px; }

/* ===================================
   PAGE HERO (About / Contact)
=================================== */
.page-hero {
  background: var(--blue-700);
  padding: var(--space-12) 0;
  margin-bottom: var(--space-10);
}

.page-hero-title {
  font-size: 36px;
  font-weight: 900;
  color: var(--white);
  margin-bottom: 8px;
  line-height: var(--line-height-heading);
}

.page-hero-desc {
  font-size: 16px;
  color: var(--blue-100);
  opacity: 0.88;
  max-width: 620px;
  line-height: 1.8;
}

/* ===================================
   ABOUT PAGE
=================================== */
.about-content { padding-bottom: var(--space-16); }

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-12);
  align-items: start;
}

.about-text h2 {
  font-size: 22px;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: 14px;
  padding-right: 14px;
  border-right: 4px solid var(--green-600);
  line-height: 1.4;
}

.about-text p {
  font-size: 15px;
  color: var(--gray-700);
  line-height: 1.9;
  margin-bottom: 18px;
}

.about-image {
  width: 100%;
  height: 340px;
  object-fit: cover;
  border-radius: var(--radius-lg);
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
  margin-top: var(--space-8);
  padding-top: var(--space-8);
  border-top: 1px solid var(--gray-200);
}

.stat-item {
  text-align: center;
  padding: var(--space-5) var(--space-4);
  background: var(--blue-50);
  border-radius: var(--radius-md);
  border: 1px solid var(--blue-100);
}

.stat-number {
  font-size: 28px;
  font-weight: 900;
  color: var(--blue-700);
  line-height: 1;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 12px;
  color: var(--gray-600);
  font-weight: 600;
}

.values-section { margin-top: var(--space-12); }

.values-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-4);
  margin-top: var(--space-6);
}

.value-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 22px 18px;
  border-top: 3px solid var(--blue-700);
  transition: box-shadow var(--transition);
}

.value-card:hover { box-shadow: var(--shadow-sm); }

.value-icon { font-size: 26px; margin-bottom: 10px; }
.value-title { font-size: 14px; font-weight: 800; color: var(--gray-900); margin-bottom: 6px; }
.value-desc { font-size: 13px; color: var(--gray-600); line-height: 1.75; }

.team-section {
  padding: var(--space-12) 0;
  background: var(--gray-50);
  border-top: 1px solid var(--gray-200);
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-5);
  margin-top: var(--space-8);
}

.team-card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: 24px 16px;
  text-align: center;
  transition: box-shadow var(--transition);
}

.team-card:hover { box-shadow: var(--shadow-sm); }

.team-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 auto 14px;
  border: 3px solid var(--blue-100);
}

.team-name { font-size: 15px; font-weight: 700; color: var(--gray-900); margin-bottom: 4px; }
.team-role { font-size: 12px; color: var(--blue-700); font-weight: 600; }

/* ===================================
   CONTACT PAGE
=================================== */
.contact-content { padding-bottom: var(--space-16); }

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: var(--space-12);
  align-items: start;
}

.contact-info h3 {
  font-size: 18px;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: var(--space-5);
}

.contact-item { display: flex; gap: 14px; margin-bottom: var(--space-5); }

.contact-item-icon {
  width: 42px;
  height: 42px;
  background: var(--blue-50);
  border: 1px solid var(--blue-100);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  flex-shrink: 0;
}

.contact-item-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-900);
  margin-bottom: 3px;
}

.contact-item-val { font-size: 14px; color: var(--gray-600); line-height: 1.6; }

.contact-form-wrap {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: 32px;
}

.form-title {
  font-size: 19px;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: var(--space-6);
}

.form-group { margin-bottom: 20px; }

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-700);
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--gray-300);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: var(--font);
  color: var(--gray-800);
  background: var(--white);
  outline: none;
  transition: border-color var(--transition), box-shadow var(--transition);
  line-height: 1.6;
}

.form-control:focus {
  border-color: var(--blue-500);
  box-shadow: 0 0 0 3px rgba(46, 118, 194, 0.12);
}

.form-control.field-error { border-color: var(--red-600); }
.form-control.field-error:focus { box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.12); }

textarea.form-control { resize: vertical; min-height: 130px; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* Inline field error message */
.field-error-msg {
  display: none;
  font-size: 12px;
  color: var(--red-600);
  margin-top: 5px;
  font-weight: 600;
}

.field-error-msg.visible { display: block; }

/* Form-level feedback */
.form-feedback {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 20px;
  display: none;
  line-height: 1.5;
}

.form-feedback.success {
  background: var(--green-50);
  color: var(--green-700);
  border: 1px solid var(--green-100);
  display: block;
}

.form-feedback.error {
  background: var(--red-50);
  color: var(--red-700);
  border: 1px solid #F5C6C1;
  display: block;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: var(--blue-700);
  color: var(--white);
  font-size: 14px;
  font-weight: 700;
  font-family: var(--font);
  border-radius: var(--radius-sm);
  transition: background var(--transition);
  border: none;
  cursor: pointer;
}

.btn-primary:hover { background: var(--blue-600); }
.btn-primary:disabled { opacity: 0.65; cursor: not-allowed; }

/* ===================================
   UTILITY
=================================== */
.text-muted   { color: var(--gray-500); }
.text-small   { font-size: 12px; }
.mt-8         { margin-top: 8px; }
.mt-16        { margin-top: 16px; }
.mb-24        { margin-bottom: 24px; }

/* ===================================
   RESPONSIVE BREAKPOINTS
=================================== */

/* --- Tablet (≤ 1024px) --- */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .values-grid { grid-template-columns: repeat(2, 1fr); }
  .about-stats { grid-template-columns: repeat(3, 1fr); }
}

/* --- Small tablet / large mobile (≤ 900px) --- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .featured-card-image { height: 320px; }
  .hero-secondary { flex-direction: row; flex-wrap: wrap; }
  .secondary-card { flex: 1 1 260px; }
  .article-layout { grid-template-columns: 1fr; }
  .sticky-sidebar { position: static; }
  .contact-grid { grid-template-columns: 1fr; }
  .about-grid { grid-template-columns: 1fr; gap: 28px; }
  .article-title { font-size: 28px; }
}

/* --- Mobile (≤ 768px) --- */
@media (max-width: 768px) {
  .main-nav   { display: none; }
  .topbar     { display: none; }

  .mobile-menu-btn { display: block; }

  .grid-3 { grid-template-columns: 1fr 1fr; }
  .grid-4 { grid-template-columns: 1fr 1fr; }

  .footer-grid { grid-template-columns: 1fr; gap: 24px; }

  .newsletter-form { flex-direction: column; }

  .page-hero-title,
  .category-hero-title { font-size: 24px; }

  .footer-bottom-inner { flex-direction: column; gap: 10px; text-align: center; }

  .form-row { grid-template-columns: 1fr; }

  .values-grid { grid-template-columns: 1fr 1fr; }
  .team-grid { grid-template-columns: 1fr 1fr; }

  .about-stats { grid-template-columns: 1fr 1fr; }
}

/* --- Small mobile (≤ 520px) --- */
@media (max-width: 520px) {
  .container { padding: 0 16px; }
  .grid-3,
  .grid-4 { grid-template-columns: 1fr; }
  .hero-secondary { flex-direction: column; }
  .secondary-card { flex: none; }
  .featured-card-image { height: 240px; }
  .article-hero-image { height: 240px; }
  .featured-title { font-size: 18px; }
  .team-grid { grid-template-columns: 1fr 1fr; }
  .values-grid { grid-template-columns: 1fr; }
  .about-stats { grid-template-columns: 1fr; }
  .article-title { font-size: 24px; }
}

/* ===================================
   PRINT (basic)
=================================== */
@media print {
  .site-header,
  .topbar,
  .breaking-news,
  .newsletter-section,
  .site-footer,
  .share-section,
  .article-sidebar { display: none !important; }

  body { background: white; color: black; font-size: 12pt; }

  .container { max-width: 100%; padding: 0; }

  .article-title { font-size: 22pt; }
}

/* ===================================
   WORDPRESS CORE COMPATIBILITY
=================================== */

/* Screen reader text (required by WP standards) */
.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  width: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  word-wrap: normal !important;
}

/* Article body: WP content classes share the editorial typography */
.article-content img,
.entry-content img {
  border-radius: var(--radius-md);
  margin: var(--space-5) auto;
}

.article-content ul,
.article-content ol {
  margin: 0 var(--space-6) var(--space-5) 0;
  padding: 0;
}

.article-content ul { list-style: disc; }
.article-content ol { list-style: arabic-indic; }
.article-content li { margin-bottom: var(--space-2); }

.article-content a {
  color: var(--blue-700);
  text-decoration: underline;
  text-decoration-color: var(--blue-200);
  text-underline-offset: 3px;
}

.article-content a:hover { color: var(--blue-500); }

.article-content table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--space-6) 0;
  font-size: 14.5px;
}

.article-content th,
.article-content td {
  border: 1px solid var(--gray-200);
  padding: 10px 14px;
  text-align: right;
}

.article-content th { background: var(--blue-50); font-weight: 700; }

.wp-caption { max-width: 100%; }
.wp-caption-text,
.wp-element-caption {
  font-size: 12px;
  color: var(--gray-500);
  text-align: center;
  font-style: italic;
  margin-top: 6px;
}

.alignright { float: right; margin: 6px 0 16px 20px; }
.alignleft  { float: left;  margin: 6px 20px 16px 0; }
.aligncenter { display: block; margin: 16px auto; }

.sticky-post-label {
  display: inline-block;
  background: var(--green-600);
  color: var(--white);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: var(--radius-sm);
}

/* WP pagination (the_posts_pagination) styled like original buttons */
.pagination .nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pagination .page-numbers {
  min-width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 700;
  border: 1.5px solid var(--gray-300);
  color: var(--gray-700);
  background: var(--white);
  transition: all var(--transition);
}

.pagination .page-numbers:hover { background: var(--gray-100); }

.pagination .page-numbers.current {
  background: var(--blue-700);
  border-color: var(--blue-700);
  color: var(--white);
}

/* Widgetized sidebar: style dynamic widgets like the design's widgets */
.article-sidebar .widget {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-6);
  overflow: hidden;
}

.article-sidebar .widget-title,
.article-sidebar .wp-block-heading {
  font-size: 11px;
  font-weight: 800;
  color: var(--gray-900);
  padding: 12px 16px;
  border-bottom: 1px solid var(--gray-200);
  background: var(--gray-50);
  text-transform: uppercase;
  letter-spacing: 0.7px;
  margin: 0;
}

.article-sidebar .widget > div,
.article-sidebar .widget ul { padding: 12px 16px; }

.article-sidebar .widget ul li {
  padding: 8px 0;
  font-size: 13px;
  border-bottom: 1px solid var(--gray-150);
}

.article-sidebar .widget ul li:last-child { border-bottom: none; }
.article-sidebar .widget ul li a { color: var(--gray-700); font-weight: 600; }
.article-sidebar .widget ul li a:hover { color: var(--blue-700); }

/* Search results / 404 helpers */
.no-results {
  text-align: center;
  padding: var(--space-16) 0;
}

.no-results h2 {
  font-size: 24px;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: 10px;
}

.no-results p { color: var(--gray-600); margin-bottom: var(--space-6); }

.error-404-code {
  font-size: 96px;
  font-weight: 900;
  color: var(--blue-200);
  line-height: 1;
  margin-bottom: var(--space-4);
}

.search-page-form {
  display: flex;
  gap: 8px;
  max-width: 480px;
  margin: 0 auto;
}

.search-page-form .search-input {
  background: var(--white);
  border: 1.5px solid var(--gray-300);
  color: var(--gray-800);
}

.search-page-form .search-input:focus { border-color: var(--blue-500); background: var(--white); }

/* Comments (kept minimal, consistent with design) */
.comments-area { margin-top: var(--space-10); padding-top: var(--space-8); border-top: 2px solid var(--gray-200); }
.comments-area .comment-list { margin: var(--space-6) 0; }
.comments-area .comment-body {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  margin-bottom: var(--space-4);
  font-size: 14.5px;
}
.comments-area .comment-meta { font-size: 12px; color: var(--gray-500); margin-bottom: 8px; }
.comment-form .form-control { margin-bottom: 14px; }

/* ===================================
   ELEMENTOR COMPATIBILITY
   Low-specificity rules; Elementor styles win when needed.
=================================== */

/* Full-width canvas for Elementor-built pages: no theme container constraints */
.mouwatin-elementor-page .site-main-page {
  padding: 0;
  max-width: none;
}

/* Default (non-Elementor) page content wrapper */
.site-main-page { padding: var(--space-8) 0 var(--space-16); }

.page-content-area {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  padding: var(--space-8);
}

@media (max-width: 768px) {
  .page-content-area { padding: var(--space-5); }
}

/* Never trap Elementor sections inside theme card styling */
.elementor-page .page-content-area {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
}

/* WordPress menu current-item states (replaces the static .active class) */
.nav-list .current-menu-item > a,
.nav-list .current_page_item > a {
  background: rgba(255,255,255,0.13);
  color: var(--white);
}

.mobile-nav-list .current-menu-item > a,
.mobile-nav-list .current_page_item > a {
  background: rgba(255,255,255,0.07);
  color: var(--white);
}

/* Custom logo image sized like the original logo mark */
.site-logo .custom-logo {
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: var(--radius-sm);
}
