:root{
  --accent: var(--theme-accent, #c0392b);
  --bg: var(--theme-bg, #f4f5f7);
  --card-bg: var(--theme-card-bg, #ffffff);
  --text: var(--theme-text, #1c1c1c);
  --muted: var(--theme-muted, #6c757d);
  --header-bg: var(--theme-header-bg, #ffffff);
  --border: var(--theme-border, #e9ecef);
}

*{box-sizing:border-box;}
body{
  font-family:'Tajawal', sans-serif;
  background:var(--bg);
  color:var(--text);
  margin:0;
}
a{text-decoration:none; color:inherit;}
img{max-width:100%; display:block;}

/* ===== Breaking bar ===== */
.breaking-bar{
  background:var(--accent);
  color:#fff;
  overflow:hidden;
  font-weight:700;
}
.breaking-label{
  background:rgba(0,0,0,.25);
  padding:8px 16px;
  white-space:nowrap;
  flex-shrink:0;
}
.breaking-ticker{ overflow:hidden; flex:1; position:relative; height:36px;}
.breaking-ticker-track{
  display:flex;
  gap:40px;
  white-space:nowrap;
  position:absolute;
  animation: ticker 30s linear infinite;
  padding:8px 0;
}
.breaking-ticker-track a{ color:#fff; opacity:.95; }
.breaking-ticker-track a:hover{ text-decoration:underline; }
@keyframes ticker{
  0%{ transform: translateX(100%); }
  100%{ transform: translateX(-100%); }
}

/* ===== Header ===== */
.site-header{ background:var(--header-bg); border-bottom:1px solid var(--border); }
.brand-text{ font-size:1.8rem; font-weight:900; color:var(--accent); }
.date-box{ color:var(--muted); font-size:.9rem; }
.search-box{ background:var(--bg); border-radius:30px; padding:6px 14px; align-items:center; gap:8px; }
.search-box input{ border:none; background:transparent; outline:none; width:200px; color:var(--text); }
.search-box button{ border:none; background:transparent; color:var(--accent); }

.main-nav{ background:var(--accent); }
.main-nav ul{ display:flex; list-style:none; margin:0; padding:0; flex-wrap:wrap; }
.main-nav li a{ display:block; padding:14px 18px; color:#fff; font-weight:700; font-size:.95rem; transition:.2s; }
.main-nav li a:hover{ background:rgba(0,0,0,.15); }
.navbar-toggler{ color:#fff; background:transparent; border:none; padding:14px 18px; font-weight:700; }

/* ===== Section titles ===== */
.section-title{ display:flex; align-items:center; justify-content:space-between; border-bottom:3px solid var(--accent, #c0392b); padding-bottom:10px; margin-bottom:20px;}
.section-title h2{ font-size:1.4rem; font-weight:900; margin:0; color:var(--text); }
.section-title h2 i{ color:var(--accent); margin-left:8px; }
.see-more{ color:var(--accent); font-weight:700; font-size:.9rem; }

/* ===== Hero ===== */
.hero-card{ position:relative; border-radius:14px; overflow:hidden; height:100%; min-height:420px; }
.hero-card img{ width:100%; height:420px; object-fit:cover; }
.hero-overlay{ position:absolute; bottom:0; right:0; left:0; padding:30px 24px; background:linear-gradient(0deg, rgba(0,0,0,.88), rgba(0,0,0,0)); color:#fff; }
.hero-title{ font-size:1.9rem; font-weight:900; margin:10px 0; line-height:1.4; }
.hero-meta{ font-size:.85rem; opacity:.85; margin:0;}
.badge-cat{ display:inline-block; background:var(--accent); color:#fff; padding:4px 14px; border-radius:20px; font-size:.78rem; font-weight:700; }
.badge-cat.sm{ padding:3px 10px; font-size:.72rem; }

.side-list{ display:flex; flex-direction:column; gap:16px; }
.side-item{ display:flex; gap:12px; background:var(--card-bg); border-radius:10px; padding:10px; border:1px solid var(--border); }
.side-item img{ width:90px; height:70px; object-fit:cover; border-radius:8px; flex-shrink:0; }
.side-item h3{ font-size:.95rem; font-weight:700; margin:4px 0; line-height:1.4; }
.side-item small{ color:var(--muted); font-size:.75rem; }

/* ===== News cards ===== */
.news-card{ background:var(--card-bg); border-radius:12px; overflow:hidden; border:1px solid var(--border); height:100%; transition:.2s; }
.news-card:hover{ transform:translateY(-4px); box-shadow:0 10px 25px rgba(0,0,0,.08); }
.news-card-img img{ width:100%; height:180px; object-fit:cover; }
.news-card.small .news-card-img img{ height:130px; }
.news-card-body{ padding:16px; }
.news-card-body h3{ font-size:1.05rem; font-weight:700; margin:8px 0; line-height:1.5; color:var(--text); }
.news-card.small .news-card-body h3{ font-size:.92rem; }
.news-card-body p{ font-size:.88rem; color:var(--muted); margin-bottom:8px; }
.news-card-body small{ color:var(--muted); font-size:.75rem; }

/* ===== Sidebar ===== */
.sidebar-box{ background:var(--card-bg); border:1px solid var(--border); border-radius:12px; padding:20px; margin-bottom:20px; }
.sidebar-box h4{ font-weight:900; border-bottom:2px solid var(--accent); padding-bottom:12px; margin-bottom:16px; font-size:1.1rem; }
.sidebar-box h4 i{ color:var(--accent); }
.most-viewed-list{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:14px; }
.most-viewed-list li{ display:flex; gap:12px; align-items:flex-start; }
.rank{ background:var(--accent); color:#fff; width:28px; height:28px; border-radius:50%; display:flex; align-items:center; justify-content:center; font-weight:900; flex-shrink:0; }
.most-viewed-list h5{ font-size:.9rem; font-weight:700; margin:0 0 4px; line-height:1.4; }
.most-viewed-list small{ color:var(--muted); font-size:.75rem; }
.ad-box{ background:var(--border); border:2px dashed var(--muted); border-radius:12px; height:250px; display:flex; align-items:center; justify-content:center; color:var(--muted); font-weight:700; }

/* ===== Article page ===== */
.breadcrumb-custom{ font-size:.85rem; color:var(--muted); }
.breadcrumb-custom a{ color:var(--muted); }
.article-page h1{ font-size:2rem; font-weight:900; margin:14px 0; line-height:1.5; }
.article-meta{ display:flex; gap:18px; flex-wrap:wrap; color:var(--muted); font-size:.85rem; margin-bottom:18px; }
.article-cover{ width:100%; max-height:480px; object-fit:cover; border-radius:12px; margin-bottom:20px; }
.article-summary{ font-size:1.15rem; font-weight:700; color:var(--text); border-right:4px solid var(--accent); padding-right:14px; margin-bottom:20px; }
.article-content{ font-size:1.05rem; line-height:2; color:var(--text); }
.article-content p{ margin-bottom:16px; }
.share-box{ display:flex; align-items:center; gap:12px; margin-top:30px; padding-top:20px; border-top:1px solid var(--border); }
.share-box a{ width:36px; height:36px; border-radius:50%; background:var(--accent); color:#fff; display:flex; align-items:center; justify-content:center; }

/* ===== Footer ===== */
.site-footer{ background:var(--header-bg); border-top:1px solid var(--border); margin-top:40px; }
.footer-brand{ color:var(--accent); font-weight:900; font-size:1.4rem; }
.footer-links{ list-style:none; padding:0; }
.footer-links li{ margin-bottom:8px; }
.footer-links a{ color:var(--muted); }
.footer-links a:hover{ color:var(--accent); }
.social-icons{ display:flex; gap:10px; margin-top:14px; }
.social-icons a{ width:36px; height:36px; border-radius:50%; background:var(--accent); color:#fff; display:flex; align-items:center; justify-content:center; }
.btn-theme{ background:var(--accent); color:#fff; border:none; }
.btn-theme:hover{ background:var(--accent); opacity:.9; color:#fff; }

.back-to-top{ position:fixed; bottom:24px; left:24px; background:var(--accent); color:#fff; width:44px; height:44px; border-radius:50%; display:flex; align-items:center; justify-content:center; box-shadow:0 4px 12px rgba(0,0,0,.2); opacity:0; visibility:hidden; transition:.3s; z-index:999; }
.back-to-top.show{ opacity:1; visibility:visible; }

@media(max-width:991px){
  .main-nav ul{ flex-direction:column; }
  .hero-title{ font-size:1.4rem; }
}
