/*
Theme Name: Akher Sa3a News
Theme URI: https://example.com
Author: ChatGPT
Author URI: https://example.com
Description: قالب إخباري عربي RTL سريع وخفيف، بتخطيط صحيفة إلكترونية (هيدر + شريط عاجل + شبكة أخبار + سايدبار).
Version: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: akher-sa3a-news
Tags: news, rtl-language-support, two-columns, custom-logo, featured-images, sticky-post, translation-ready
*/

:root{
  --bg:#0b0f17;
  --surface:#111827;
  --card:#0f172a;
  --text:#e5e7eb;
  --muted:#9ca3af;
  --brand:#e11d48; /* red */
  --brand2:#f59e0b; /* amber */
  --border:rgba(255,255,255,.08);
  --shadow: 0 10px 30px rgba(0,0,0,.25);
  --radius:16px;
}

html{scroll-behavior:smooth}
body{
  direction:rtl;
  text-align:right;
  margin:0;
  font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Tahoma,"Noto Kufi Arabic","Cairo",Arial,sans-serif;
  background: #0b1220;
  color: var(--text);
}
a{color:inherit;text-decoration:none}
a:hover{color:var(--brand)}
img{max-width:100%;height:auto}

.container{max-width:1200px;margin:0 auto;padding:0 16px}
.site-header{
  position:sticky; top:0; z-index:50;
  background: rgba(11,18,32,.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner{
  display:flex; align-items:center; justify-content:space-between;
  gap:12px; padding:14px 0;
}
.brand{
  display:flex; align-items:center; gap:10px; min-width:220px;
}
.brand .logo{
  width:44px;height:44px;border-radius:12px;
  background: linear-gradient(135deg,var(--brand),#7c3aed);
  display:grid;place-items:center;
  box-shadow: var(--shadow);
  font-weight:800;
}
.brand .title{display:flex;flex-direction:column;line-height:1.1}
.brand .title strong{font-size:20px}
.brand .title span{font-size:12px;color:var(--muted)}
.header-actions{display:flex;align-items:center;gap:10px}
.search-wrap{position:relative}
.search-wrap input[type="search"]{
  width:260px; max-width:40vw;
  padding:10px 14px;border-radius:999px;
  border:1px solid var(--border);
  background: rgba(255,255,255,.03);
  color:var(--text); outline:none;
}
.search-wrap input[type="search"]::placeholder{color:rgba(229,231,235,.6)}
.btn{
  display:inline-flex; align-items:center; gap:8px;
  padding:10px 14px;border-radius:999px;
  border:1px solid var(--border);
  background: rgba(255,255,255,.03);
}
.btn.primary{background:linear-gradient(135deg,var(--brand),#7c3aed);border-color:transparent}
.btn small{color:rgba(255,255,255,.8)}

.navbar{
  border-top:1px solid var(--border);
  border-bottom:1px solid var(--border);
  background: rgba(255,255,255,.02);
}
.navbar .menu{
  display:flex; gap:16px; flex-wrap:wrap;
  padding:10px 0; margin:0; list-style:none;
}
.navbar .menu a{
  color:rgba(229,231,235,.9);
  padding:8px 10px;border-radius:999px;
}
.navbar .menu a:hover{background:rgba(255,255,255,.06)}

.breaking{
  margin:14px 0 0;
  background: linear-gradient(90deg, rgba(225,29,72,.22), rgba(245,158,11,.16));
  border:1px solid var(--border);
  border-radius: var(--radius);
  overflow:hidden;
}
.breaking-inner{
  display:flex; align-items:center; gap:12px;
  padding:10px 12px;
}
.breaking-badge{
  background: var(--brand);
  color:white;
  font-weight:700;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  white-space:nowrap;
}
.breaking-marquee{
  flex:1;
  overflow:hidden;
}
.breaking-marquee .track{
  display:inline-block;
  white-space:nowrap;
  animation: ticker 25s linear infinite;
  color:rgba(229,231,235,.95);
}
@keyframes ticker{
  0%{transform:translateX(-10%)}
  100%{transform:translateX(110%)}
}

.main{
  padding:18px 0 34px;
}
.grid{
  display:grid;
  grid-template-columns: 1.6fr .9fr;
  gap:18px;
}
@media (max-width: 980px){
  .grid{grid-template-columns:1fr}
  .search-wrap input[type="search"]{width:200px}
}

.card{
  background: rgba(255,255,255,.03);
  border:1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 8px 20px rgba(0,0,0,.18);
}
.card.pad{padding:14px}
.section-title{
  display:flex; align-items:center; justify-content:space-between;
  padding:12px 14px;
  border-bottom:1px solid var(--border);
}
.section-title h2{margin:0;font-size:16px}
.section-title a{font-size:12px;color:var(--muted)}
.section-title a:hover{color:var(--brand)}

.hero{
  display:grid;
  grid-template-columns: 1.3fr 1fr;
  gap:14px;
  padding:14px;
}
@media(max-width:780px){.hero{grid-template-columns:1fr}}
.hero .lead{
  border-radius: calc(var(--radius) - 6px);
  overflow:hidden;
  position:relative;
  min-height:320px;
  background:#0f172a;
}
.hero .lead img{width:100%;height:100%;object-fit:cover;display:block}
.hero .lead .overlay{
  position:absolute; inset:0;
  background: linear-gradient(180deg, transparent 40%, rgba(0,0,0,.72));
}
.hero .lead .meta{
  position:absolute; inset:auto 0 0 0;
  padding:14px;
}
.kicker{
  display:inline-flex;
  gap:8px; align-items:center;
  padding:6px 10px;
  border-radius:999px;
  background: rgba(225,29,72,.22);
  border:1px solid rgba(225,29,72,.35);
  font-size:12px;
  margin-bottom:10px;
}
.hero .lead h1{margin:0;font-size:22px;line-height:1.4}
.hero .lead p{margin:8px 0 0;color:rgba(229,231,235,.78);font-size:13px}

.hero .stack{display:grid;gap:12px}
.post-row{
  display:grid;
  grid-template-columns: 120px 1fr;
  gap:12px;
  padding:12px;
  border-radius: calc(var(--radius) - 6px);
  border:1px solid var(--border);
  background: rgba(255,255,255,.02);
}
.post-row img{width:120px;height:86px;object-fit:cover;border-radius:12px}
.post-row h3{margin:0 0 6px;font-size:14px;line-height:1.35}
.post-row .meta{font-size:12px;color:var(--muted)}
.post-row:hover{border-color:rgba(225,29,72,.35)}

.cards{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:14px;
  padding:14px;
}
@media(max-width:980px){.cards{grid-template-columns:repeat(2,1fr)}}
@media(max-width:620px){.cards{grid-template-columns:1fr}}
.article{
  overflow:hidden;
}
.article .thumb{aspect-ratio: 16/9; background:#0f172a}
.article .thumb img{width:100%;height:100%;object-fit:cover;display:block}
.article .body{padding:12px}
.article h3{margin:0 0 8px;font-size:14px;line-height:1.4}
.article p{margin:0;color:rgba(229,231,235,.72);font-size:12px;line-height:1.8;min-height:44px}
.article .meta{margin-top:10px;font-size:12px;color:var(--muted)}
.pager{display:flex;justify-content:center;gap:8px;padding:18px 14px}
.pager a,.pager span{
  padding:8px 12px;border-radius:999px;border:1px solid var(--border);
  background: rgba(255,255,255,.02);
}
.pager .current{background:rgba(225,29,72,.22);border-color:rgba(225,29,72,.35)}

.sidebar .widget{padding:14px}
.sidebar .widget + .widget{border-top:1px solid var(--border)}
.widget-title{margin:0 0 10px;font-size:14px}
.widget ul{margin:0;padding:0 0 0 0;list-style:none}
.widget li{padding:8px 0;border-bottom:1px dashed rgba(255,255,255,.08)}
.widget li:last-child{border-bottom:0}
.badge{
  display:inline-block;
  font-size:11px;
  padding:4px 8px;
  border-radius:999px;
  border:1px solid var(--border);
  color:var(--muted);
  margin-left:6px;
}

.site-footer{
  border-top:1px solid var(--border);
  padding:22px 0;
  background: rgba(255,255,255,.02);
  color:rgba(229,231,235,.78);
}
.footer-grid{
  display:grid;grid-template-columns: 2fr 1fr 1fr;gap:16px
}
@media(max-width:900px){.footer-grid{grid-template-columns:1fr}}
.footer-grid h4{margin:0 0 10px}
.footer-grid p{margin:0;color:rgba(229,231,235,.68);line-height:1.9}
.small{font-size:12px;color:var(--muted)}
