/* =============================================
   اليمني الجديد — Main Stylesheet v3.0
   Modern, Dynamic, RTL Optimized
   =============================================
   
   الفهرس:
   01. Variables & Foundations
   02. Reset & Base
   03. Layout & Utilities
   04. Header & Navigation
   05. Section Heading
   06. Hero Section
   07. Card System (Base + Variants)
   08. Section Layouts
   09. Dynamic Components (Slider & Tabs)
   10. Sidebar & Widgets
   11. Single Post
   12. Archive & Pagination
   13. Footer
   14. UI Elements (Progress, Back-to-top)
   15. Responsive Breakpoints
   ============================================= */

/* ═══════════════════════════════════════════════
   01. VARIABLES & FOUNDATIONS
═══════════════════════════════════════════════ */
:root {
    /* ── Core Colors ── */
    --blue: #1a7dc4;
    --blue-dark: #155f96;
    --blue-light: #2e9de4;
    --orange: #f5a520;
    --orange-dark: #d4880e;
    --red: #d42020;

    /* ── Neutrals ── */
    --ink: #0f1923;
    --ink-mid: #1e2d3d;
    --cream: #f8f5ef;
    --light: #f0ece4;
    --muted: #7a8899;
    --border: #ddd6c8;
    --white: #ffffff;

    /* ── Shadows ── */
    --shadow-sm: 0 2px 8px rgba(15, 25, 35, .06);
    --shadow: 0 8px 24px rgba(15, 25, 35, .10);
    --shadow-lg: 0 16px 48px rgba(15, 25, 35, .15);

    /* ── Radii ── */
    --radius: 8px;
    --radius-lg: 12px;

    /* ── Typography ── */
    --ff-title: 'Noto Kufi Arabic', serif;
    --ff-body: 'Cairo', sans-serif;

    /* ── Motion ── */
    --transition: .3s cubic-bezier(.4, 0, .2, 1);

    /* ── Customizer Hooks (overridden by inline :root vars) ── */
    --primary: var(--blue);
    --secondary: var(--orange);
    --accent: var(--red);
    --bg: var(--cream);
    --surface: var(--white);
    --text: var(--ink);
    --text-muted: var(--muted);
    --header-bg: var(--white);
    --footer-bg: var(--ink);
}

/* ── Dark Mode ── */
body.dark-mode {
    --bg: #0f1923;
    --surface: #1a2636;
    --text: #e8e0d4;
    --text-muted: #8a9bac;
    --border: #2a3a4a;
    --light: #162030;
    --header-bg: #111c28;
    --footer-bg: #080e14;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, .2);
    --shadow: 0 8px 24px rgba(0, 0, 0, .3);
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--ff-body);
    background: var(--bg);
    color: var(--text);
    direction: rtl;
    font-size: 15px;
    line-height: 1.7;
    transition: background var(--transition), color var(--transition);
    overflow-x: hidden;
}

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

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

ul, ol { list-style: none; }
button, input, textarea { font-family: inherit; font-size: inherit; }

/* ═══════════════════════════════════════════════
   03. LAYOUT & UTILITIES
═══════════════════════════════════════════════ */
.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 20px;
}

.ayj-homepage {
    min-height: 60vh;
}

.two-col {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 32px;
}

.half-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

.half-col > .sec-head { margin-top: 32px; }
.half-col > .sec-head:first-child { margin-top: 0; }

.divider {
    height: 3px;
    background: linear-gradient(to left, var(--primary) 0%, var(--secondary) 50%, transparent 100%);
    margin: 44px 0 0;
    border-radius: 2px;
}

/* ── Reveal Animation ── */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .6s ease, transform .6s ease;
}
.reveal.visible {
    opacity: 1;
    transform: none;
}

/* ── Section Wrapper (ألوان وستايلات مخصصة لكل قسم) ── */
.ayj-section {
    position: relative;
}

/* ── Card Style Variants (يُطبّق على .ayj-section) ── */
.cards-shadow .news-card,
.cards-shadow .interview-card,
.cards-shadow .video-card,
.cards-shadow .invest-sub-card {
    box-shadow: var(--shadow);
}

.cards-bordered .news-card,
.cards-bordered .interview-card,
.cards-bordered .video-card,
.cards-bordered .invest-sub-card {
    box-shadow: none;
    border: 1.5px solid var(--border);
}

.cards-flat .news-card,
.cards-flat .interview-card,
.cards-flat .video-card,
.cards-flat .invest-sub-card {
    box-shadow: none;
}
.cards-flat .news-card:hover,
.cards-flat .interview-card:hover,
.cards-flat .video-card:hover {
    box-shadow: var(--shadow-sm);
}

.cards-rounded .news-card,
.cards-rounded .interview-card,
.cards-rounded .video-card,
.cards-rounded .invest-sub-card {
    border-radius: 20px;
}
.cards-rounded .news-card .thumb img,
.cards-rounded .interview-card .thumb img {
    border-radius: 20px 20px 0 0;
}

/* ═══════════════════════════════════════════════
   04. HEADER & NAVIGATION
═══════════════════════════════════════════════ */

/* ── Ticker Bar ── */
.ticker-bar {
    background: var(--ink);
    color: var(--white);
    display: flex;
    align-items: center;
    height: 38px;
    font-size: 13px;
}

body.dark-mode .ticker-bar { background: #060d14; }

.ticker-label {
    background: var(--accent);
    padding: 0 18px;
    height: 100%;
    display: flex;
    align-items: center;
    font-weight: 700;
    font-size: 12px;
    white-space: nowrap;
    flex-shrink: 0;
}

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

.ticker-inner {
    display: flex;
    gap: 60px;
    white-space: nowrap;
    animation: ticker-scroll 45s linear infinite;
    padding-right: 100%;
}

.ticker-inner span::before {
    content: '◆';
    color: var(--secondary);
    margin-left: 12px;
    font-size: 8px;
}

@keyframes ticker-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(100%); }
}

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

/* ── Date Bar ── */
.date-bar {
    background: var(--light);
    border-bottom: 1px solid var(--border);
    padding: 7px 0;
    font-size: 12px;
    color: var(--text-muted);
}

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

/* ── Site Header ── */
.site-header {
    background: var(--header-bg);
    border-bottom: 3px solid var(--primary);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-sm);
    transition: background var(--transition);
}

.header-inner {
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

/* ── Logo ── */
.site-logo img { height: 54px; width: auto; }

.logo-fallback { display: flex; align-items: center; gap: 12px; }

.logo-icon {
    width: 46px;
    height: 46px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 20px;
    font-weight: 900;
    font-family: var(--ff-title);
    flex-shrink: 0;
}

.logo-text .main {
    font-size: 22px;
    font-weight: 800;
    font-family: var(--ff-title);
    color: var(--text);
}

.logo-text .sub {
    font-size: 10px;
    color: var(--text-muted);
    letter-spacing: 1px;
}

/* ── Main Nav ── */
.main-nav { display: flex; gap: 4px; align-items: center; }

.main-nav a {
    padding: 8px 14px;
    border-radius: var(--radius);
    font-size: 13.5px;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    transition: all var(--transition);
}

.main-nav a:hover,
.main-nav a.current-menu-item {
    background: var(--primary);
    color: var(--white);
}
/* ========== Submenu Styles ========== */
.main-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}
.main-menu li {
    position: relative;
}
.main-menu a {
    display: block;
    padding: 8px 14px;
}
/* Submenu - desktop */
.main-menu .sub-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--surface);
    min-width: 200px;
    box-shadow: var(--shadow);
    border-radius: var(--radius);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    z-index: 100;
    list-style: none;
    padding: 8px 0;
}
.main-menu li:hover > .sub-menu,
.main-menu li.submenu-open > .sub-menu {
    opacity: 1;
    visibility: visible;
}
.main-menu .sub-menu .sub-menu {
    top: 0;
    right: 100%;
}
/* Submenu toggle button */
.submenu-toggle {
    background: none;
    border: none;
    padding: 0 6px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.submenu-toggle .toggle-icon::after {
    content: "▼";
    font-size: 10px;
    transition: transform 0.2s;
}
.submenu-open > .submenu-toggle .toggle-icon::after {
    transform: rotate(180deg);
}
/* Mobile submenu */
.mobile-menu {
    list-style: none;
    margin: 0;
    padding: 0;
}
.mobile-menu li {
    border-bottom: 1px solid var(--border);
    position: relative;
}
.mobile-menu .sub-menu {
    display: none;
    padding-right: 20px;
    list-style: none;
}
.mobile-menu .submenu-open > .sub-menu {
    display: block;
}
.mobile-menu .submenu-toggle {
    position: absolute;
    left: 10px;
    top: 12px;
}
/* Responsive: desktop menu becomes accordion on small screens */
@media (max-width: 820px) {
    .main-menu .sub-menu {
        position: static;
        box-shadow: none;
        opacity: 1;
        visibility: visible;
        display: none;
        background: transparent;
    }
    .main-menu li:hover > .sub-menu {
        display: none;
    }
    .main-menu li.submenu-open > .sub-menu {
        display: block;
    }
}
/* ── Header Tools ── */
.header-tools { display: flex; gap: 8px; align-items: center; }

.tool-btn {
    width: 40px;
    height: 40px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text);
    transition: all var(--transition);
}

.tool-btn:hover {
    border-color: var(--primary);
    background: var(--primary);
    color: var(--white);
}

.tool-btn svg { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 2; }

.dark-toggle-icon-moon { display: block; }
.dark-toggle-icon-sun { display: none; }
body.dark-mode .dark-toggle-icon-moon { display: none; }
body.dark-mode .dark-toggle-icon-sun { display: block; }

/* ── Mobile Nav ── */
.mobile-nav {
    display: none;
    background: var(--header-bg);
    border-top: 1px solid var(--border);
    padding: 12px 0;
    max-height: 400px;
    overflow-y: auto;
}

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

.mobile-nav a {
    display: block;
    padding: 12px 20px;
    font-weight: 600;
    color: var(--text);
    border-bottom: 1px solid var(--border);
}

.mobile-nav a:hover { background: var(--primary); color: var(--white); }

.menu-toggle {
    display: none;
    width: 40px;
    height: 40px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    background: transparent;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    color: var(--text);
}

/* ── Search Bar ── */
.search-bar {
    display: none;
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding: 16px 0;
}

.search-bar.open { display: block; }
.search-bar form { display: flex; gap: 10px; }

.search-bar input {
    flex: 1;
    padding: 12px 18px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg);
    color: var(--text);
    outline: none;
    transition: border var(--transition);
}

.search-bar input:focus { border-color: var(--primary); }

.search-bar button {
    padding: 12px 24px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    font-weight: 700;
    cursor: pointer;
}

/* ═══════════════════════════════════════════════
   05. SECTION HEADING
═══════════════════════════════════════════════ */
.sec-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
    margin-top: 48px;
}

.sec-head h2 {
    font-size: 20px;
    font-weight: 800;
    font-family: var(--ff-title);
    color: var(--text);
    white-space: nowrap;
}

.sec-head .line {
    flex: 1;
    height: 2px;
    background: var(--border);
    position: relative;
}

.sec-head .line::before {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    width: 50px;
    height: 2px;
    background: var(--primary);
}

.sec-head .more {
    font-size: 12px;
    color: var(--text-muted);
    border: 1.5px solid var(--border);
    padding: 5px 14px;
    border-radius: 20px;
    white-space: nowrap;
    transition: all var(--transition);
}

.sec-head .more:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(26, 125, 196, .05);
}

/* ═══════════════════════════════════════════════
   06. HERO SECTION
═══════════════════════════════════════════════ */
.hero { padding: 28px 0 0; }

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 16px;
}

.hero-main {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    grid-row: 1/3;
}

.hero-main .thumb img {
    height: 490px;
    transition: transform .6s ease;
}

.hero-main:hover .thumb img { transform: scale(1.05); }

.overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(10, 18, 28, .92) 35%, transparent 70%);
}

.hero-main .post-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    background: var(--accent);
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 14px;
    border-radius: 20px;
}

.hero-main .hero-content {
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    padding: 28px;
}

.hero-main .hero-content h2 {
    font-size: 26px;
    font-weight: 800;
    font-family: var(--ff-title);
    color: var(--white);
    line-height: 1.4;
    margin-bottom: 12px;
}

.hero-meta {
    display: flex;
    gap: 16px;
    font-size: 12px;
    color: rgba(255, 255, 255, .6);
}

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

/* ── Hero Side Cards ── */
.hero-side { display: flex; flex-direction: column; gap: 16px; }

.hero-card {
    flex: 1;
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    cursor: pointer;
}

.hero-card .thumb img {
    height: 100%;
    min-height: 232px;
    transition: transform .5s ease;
}

.hero-card:hover .thumb img { transform: scale(1.06); }

.hero-card .hero-content {
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    padding: 18px;
}

.hero-card .cat-badge {
    display: inline-block;
    background: var(--secondary);
    color: var(--ink);
    font-size: 10px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    margin-bottom: 8px;
}

.hero-card .hero-content h3 {
    font-size: 15px;
    font-weight: 700;
    font-family: var(--ff-title);
    color: var(--white);
    line-height: 1.4;
}

/* ── Breaking Strip ── */
.breaking-strip {
    background: var(--ink-mid);
    border-radius: var(--radius-lg);
    padding: 14px 22px;
    display: flex;
    gap: 18px;
    align-items: center;
    margin-top: 18px;
    flex-wrap: wrap;
}

body.dark-mode .breaking-strip { background: #0a1520; }

.breaking-strip .label {
    background: var(--primary);
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    padding: 5px 14px;
    border-radius: 20px;
    white-space: nowrap;
}

.breaking-strip .items { display: flex; gap: 24px; flex-wrap: wrap; flex: 1; }

.breaking-strip .items a { color: rgba(255, 255, 255, .75); font-size: 13px; }
.breaking-strip .items a::before { content: '◆'; color: var(--secondary); margin-left: 8px; font-size: 7px; }
.breaking-strip .items a:hover { color: var(--white); }

/* ═══════════════════════════════════════════════
   07. CARD SYSTEM — Base + All Variants
═══════════════════════════════════════════════ */

/* ── Shared Card Elements ── */
.cat-tag {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    color: var(--primary);
    border-right: 3px solid var(--primary);
    padding-right: 8px;
    margin-bottom: 8px;
}

.post-meta {
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-muted);
}

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

/* ── Card Excerpt (جديد — يظهر حسب إعدادات الميتا) ── */
.card-excerpt {
    font-size: 12.5px;
    color: var(--text-muted);
    line-height: 1.6;
    margin: 6px 0 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── Standard Card (news-card) ── */
.news-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.news-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
    transition: transform var(--transition), box-shadow var(--transition);
}

.news-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.news-card .thumb { overflow: hidden; }
.news-card .thumb img { height: 180px; transition: transform .5s ease; }
.news-card:hover .thumb img { transform: scale(1.07); }

.news-card .body {
    padding: 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-card h3 {
    font-size: 14.5px;
    font-weight: 700;
    font-family: var(--ff-title);
    line-height: 1.6;
    flex: 1;
    color: var(--text);
    transition: color var(--transition);
}

.news-card:hover h3 { color: var(--primary); }

/* ── Side Card (List Style) ── */
.list-grid { display: flex; flex-direction: column; }

.side-card {
    display: flex;
    gap: 14px;
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
}

.side-card:last-child { border-bottom: none; }

.side-card .thumb {
    flex-shrink: 0;
    width: 140px;
    height: 95px;
    border-radius: var(--radius);
    overflow: hidden;
}

.side-card .body { flex: 1; display: flex; flex-direction: column; justify-content: center; }

.side-card .body h3 {
    font-size: 14px;
    font-weight: 700;
    line-height: 1.6;
    margin: 6px 0 4px;
    color: var(--text);
}

.side-card:hover .body h3 { color: var(--primary); }

/* ── Numbered Card ── */
.numbered-grid { max-width: 720px; }

.numbered-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
}

.numbered-item .num {
    font-size: 36px;
    font-weight: 900;
    color: #e0e0e0;
    min-width: 50px;
    text-align: center;
    font-family: var(--ff-body);
    line-height: 1;
}

body.dark-mode .numbered-item .num { color: #2a3a4a; }
.numbered-item.num-hot .num { color: var(--accent); }
.numbered-item .body { flex: 1; }

.numbered-item .body h3 {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.7;
    color: var(--text);
}

.numbered-item:hover .body h3 { color: var(--primary); }

.numbered-item .thumb {
    flex-shrink: 0;
    width: 90px;
    height: 65px;
    border-radius: var(--radius);
    overflow: hidden;
}

/* ── Video Card ── */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
}

.video-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition);
}

.video-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.video-card .thumb { position: relative; overflow: hidden; }
.video-card .thumb img { height: 200px; transition: transform .4s; }
.video-card:hover .thumb img { transform: scale(1.05); }

.play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(212, 32, 32, .9);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, .3);
    transition: transform var(--transition);
}

.video-card:hover .play-overlay { transform: translate(-50%, -50%) scale(1.1); }

.video-card .body { padding: 14px; }
.video-card .body h3 { font-size: 14px; font-weight: 700; line-height: 1.5; color: var(--text); }

/* ── Overlay Card ── */
.overlay-card {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    min-height: 240px;
}

.overlay-card .thumb { position: absolute; inset: 0; }

.overlay-card .content {
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    padding: 22px;
    z-index: 2;
}

.overlay-card .content h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--white);
    margin: 8px 0;
    line-height: 1.6;
}

.overlay-card .content .cat-tag {
    border-color: rgba(255, 255, 255, .5);
    color: var(--white);
    background: rgba(255, 255, 255, .1);
    padding: 2px 10px;
    border-radius: 20px;
    border-right: none;
}

/* ── Quote Card ── */
.quotes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.quote-card {
    background: var(--light);
    border-radius: var(--radius-lg);
    padding: 24px;
    border-right: 4px solid var(--secondary);
    transition: transform var(--transition), box-shadow var(--transition);
}

body.dark-mode .quote-card { background: var(--ink-mid); }
.quote-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

.quote-icon { color: var(--secondary); opacity: .3; display: block; margin-bottom: 10px; }

.quote-card h3 {
    font-size: 16px;
    font-weight: 800;
    line-height: 1.7;
    margin-bottom: 10px;
    color: var(--text);
}

.quote-card p {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 14px;
}

.quote-author { display: flex; align-items: center; gap: 10px; }
.quote-author img { border-radius: 50%; width: 36px; height: 36px; }
.quote-author span { font-size: 13px; font-weight: 600; color: var(--primary); }

/* ── Pinned Card ── */
.pinned-card {
    padding: 16px;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: var(--radius);
    position: relative;
}

body.dark-mode .pinned-card { background: #2a2415; border-color: #4a3f20; }

.pinned-card .pin-icon { color: var(--secondary); position: absolute; top: 14px; left: 14px; }
.pinned-card h3 { font-size: 15px; font-weight: 700; margin: 8px 0; padding-left: 20px; line-height: 1.6; }

/* ═══════════════════════════════════════════════
   08. SECTION LAYOUTS
═══════════════════════════════════════════════ */

/* ── Opinion ── */
.opinion-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.opinion-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
    display: flex;
    gap: 14px;
    border-top: 3px solid var(--border);
    transition: all var(--transition);
}

.opinion-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-top-color: var(--primary); }

.author-avatar {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    border: 2px solid var(--border);
}

.author-avatar img { height: 100%; }
.opinion-card .author-name { font-size: 11px; color: var(--primary); font-weight: 700; margin-bottom: 6px; }

.opinion-card h4 {
    font-size: 14px;
    font-weight: 700;
    font-family: var(--ff-title);
    margin-bottom: 6px;
    line-height: 1.5;
    color: var(--text);
}

.opinion-card p {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── Reports / Big-Small ── */
.reports-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.report-card-big {
    grid-column: 1/3;
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.report-card-big .thumb img { height: 320px; transition: transform .5s ease; }
.report-card-big:hover .thumb img { transform: scale(1.04); }

.report-card-big .content,
.report-card .content {
    position: absolute;
    bottom: 0;
    padding: 22px;
    right: 0;
    left: 0;
    z-index: 2;
}

.gold-badge {
    display: inline-block;
    background: var(--secondary);
    color: var(--ink);
    font-size: 10px;
    font-weight: 700;
    padding: 4px 14px;
    border-radius: 20px;
    margin-bottom: 8px;
}

.report-card-big h3 {
    font-size: 20px;
    font-weight: 800;
    font-family: var(--ff-title);
    color: var(--white);
    line-height: 1.4;
}

.report-card {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.report-card .thumb img { height: 200px; transition: transform .4s; }
.report-card:hover .thumb img { transform: scale(1.05); }
.report-card h3 { font-size: 14px; font-weight: 700; font-family: var(--ff-title); color: var(--white); line-height: 1.5; }

/* ── Featured / Investigation ── */
.invest-card {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.invest-card .thumb img { height: 440px; transition: transform .6s ease; }
.invest-card:hover .thumb img { transform: scale(1.03); }

.invest-card .content {
    position: absolute;
    bottom: 0;
    padding: 34px;
    right: 0;
    left: 0;
    z-index: 2;
}

.invest-card .content h2 {
    font-size: 28px;
    font-weight: 900;
    font-family: var(--ff-title);
    color: var(--white);
    line-height: 1.4;
    margin-bottom: 12px;
}

.invest-card .content p {
    font-size: 14px;
    color: rgba(255, 255, 255, .7);
    line-height: 1.7;
    max-width: 700px;
}

.invest-sub {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    margin-top: 18px;
}

.invest-sub-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition);
}

.invest-sub-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.invest-sub-card .thumb img { height: 160px; }
.invest-sub-card .body { padding: 16px; }
.invest-sub-card h4 { font-size: 14px; font-weight: 700; font-family: var(--ff-title); line-height: 1.5; color: var(--text); }

/* ── Magazine ── */
.magazine-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 20px;
}

.mag-main {
    grid-row: 1/3;
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    min-height: 440px;
}

.mag-main .thumb { position: absolute; inset: 0; }
.mag-main .thumb img { height: 100%; transition: transform .5s ease; }
.mag-main:hover .thumb img { transform: scale(1.04); }

.mag-main .content {
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    padding: 28px;
    z-index: 2;
}

.mag-main .content h2 {
    font-size: 22px;
    font-weight: 800;
    color: var(--white);
    line-height: 1.5;
    margin: 8px 0;
}

.mag-main .content .cat-tag {
    border-color: rgba(255, 255, 255, .5);
    color: var(--white);
    background: rgba(255, 255, 255, .1);
    padding: 2px 10px;
    border-radius: 20px;
    border-right: none;
}

.mag-main .content .post-meta span { color: rgba(255, 255, 255, .7); }
.mag-sub { border-radius: var(--radius-lg); overflow: hidden; }

/* ── Side Stacked ── */
.side-stacked {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
}

.ss-image { border-radius: var(--radius); overflow: hidden; height: 100%; min-height: 260px; }
.ss-items { display: flex; flex-direction: column; gap: 16px; justify-content: center; }

.ss-item { padding-bottom: 16px; border-bottom: 1px solid var(--border); }
.ss-item:last-child { border-bottom: none; padding-bottom: 0; }
.ss-item h3 { font-size: 15px; font-weight: 700; line-height: 1.6; margin: 6px 0 4px; color: var(--text); }
.ss-item:hover h3 { color: var(--primary); }
.ss-item .date { font-size: 12px; color: var(--text-muted); }

/* ── Interviews ── */
.interviews-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.interview-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition);
}

.interview-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.interview-card .thumb { overflow: hidden; }
.interview-card .thumb img { height: 240px; transition: transform .5s ease; }
.interview-card:hover .thumb img { transform: scale(1.05); }

.interview-card .body { padding: 18px 16px 20px; }

.interview-card .body h3 {
    font-size: 16px;
    font-weight: 700;
    font-family: var(--ff-title);
    line-height: 1.5;
    color: var(--text);
    margin-top: 8px;
}

.interview-card:hover .body h3 { color: var(--primary); }

/* ── Custom Content Section ── */
.custom-content-section {
    padding: 20px 0;
    font-size: 15px;
    line-height: 1.8;
}

.custom-content-section img { border-radius: var(--radius); margin: 16px 0; }
.custom-content-section p { margin-bottom: 16px; }

/* ═══════════════════════════════════════════════
   09. DYNAMIC COMPONENTS — Slider & Tabs
═══════════════════════════════════════════════ */

/* ── Slider Base ── */
.ayj-slider { position: relative; margin: 0 -12px; padding: 0 12px; }

.slider-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    gap: 16px;
}

.slider-track::-webkit-scrollbar { display: none; }

/* Default slide = full width */
.slider-slide {
    scroll-snap-align: start;
    flex-shrink: 0;
    width: 100%;
}

/* Card slider = auto width */
.ayj-slider.is-cards .slider-slide { width: auto; }

.slider-slide .news-card {
    width: 280px;
    height: 100%;
    margin: 0;
    box-shadow: var(--shadow-sm);
}

.slider-slide .news-card .thumb img { height: 170px; }

/* ── Hero Slider ── */
.slider-hero-slide {
    position: relative;
    width: 100%;
    border-radius: var(--radius-lg);
    overflow: hidden;
    min-height: 420px;
}

.slider-hero-slide .thumb { position: absolute; inset: 0; }
.slider-hero-slide .thumb img { height: 100%; transition: transform 6s ease; }
.slider-hero-slide:hover .thumb img { transform: scale(1.05); }

.slider-hero-slide .content {
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    padding: 32px;
    z-index: 2;
}

.slider-hero-slide .content h2 {
    font-size: 26px;
    font-weight: 800;
    color: var(--white);
    line-height: 1.4;
    margin: 10px 0;
}

.slider-hero-slide .content .hero-meta span { color: rgba(255, 255, 255, .7); }

.slider-hero-slide .content .cat-tag {
    border-color: rgba(255, 255, 255, .5);
    color: var(--white);
    background: rgba(255, 255, 255, .15);
    backdrop-filter: blur(4px);
    border-right: none;
    padding: 3px 12px;
    border-radius: 20px;
}

/* ── Slider Buttons ── */
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background: rgba(255, 255, 255, .95);
    border: none;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--shadow);
    transition: all var(--transition);
    color: #333;
}

.slider-btn:hover { background: var(--primary); color: #fff; box-shadow: var(--shadow-lg); }
.slider-prev { right: -10px; }
.slider-next { left: -10px; }

/* ── Slider Dots ── */
.slider-dots { display: flex; justify-content: center; gap: 8px; padding: 18px 0 0; }

.slider-dots .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border);
    border: none;
    cursor: pointer;
    transition: all var(--transition);
}

.slider-dots .dot.active { background: var(--primary); transform: scale(1.3); }

/* ── Tabs ── */
.ayj-tabs { margin-top: 8px; }

.tabs-nav {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--border);
    overflow-x: auto;
    scrollbar-width: none;
}

.tabs-nav::-webkit-scrollbar { display: none; }

.tab-btn {
    padding: 12px 24px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    font-family: var(--ff-body);
    font-size: 14px;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    white-space: nowrap;
    transition: all var(--transition);
    margin-bottom: -2px;
}

.tab-btn:hover { color: var(--text); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }
.tabs-body { padding: 18px 0; }
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: tabFadeIn .4s ease; }
.tab-empty { color: var(--text-muted); font-size: 14px; padding: 24px 0; text-align: center; }

@keyframes tabFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ═══════════════════════════════════════════════
   10. SIDEBAR & WIDGETS
═══════════════════════════════════════════════ */
.sidebar-widget {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    margin-bottom: 24px;
}

.widget-head {
    background: var(--ink);
    color: var(--white);
    padding: 14px 18px;
    font-size: 13px;
    font-weight: 700;
    font-family: var(--ff-title);
    display: flex;
    align-items: center;
    gap: 10px;
}

body.dark-mode .widget-head { background: #060d14; }

.widget-head::before {
    content: '';
    width: 4px;
    height: 18px;
    background: var(--primary);
    border-radius: 2px;
    flex-shrink: 0;
}

.widget-list { padding: 0; }

.widget-item {
    display: flex;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
    transition: background var(--transition);
}

.widget-item:last-child { border-bottom: none; }
.widget-item:hover { background: var(--light); }
body.dark-mode .widget-item:hover { background: var(--ink-mid); }

.widget-item .wi-thumb {
    width: 72px;
    height: 58px;
    border-radius: 6px;
    flex-shrink: 0;
    overflow: hidden;
}

.widget-item .wi-title {
    font-size: 13px;
    font-weight: 600;
    font-family: var(--ff-title);
    line-height: 1.5;
    color: var(--text);
}

.widget-item .wi-date { font-size: 11px; color: var(--text-muted); margin-top: 4px; }

/* ── Default WP Widgets Override ── */
.widget { margin-bottom: 28px; color: var(--text); }

.widget-title {
    font-size: 15px;
    font-weight: 700;
    font-family: var(--ff-title);
    color: var(--text);
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--primary);
    display: inline-block;
}

.widget ul li { padding: 8px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.widget ul li a { color: var(--text); }
.widget ul li a:hover { color: var(--primary); }


/* ═══════════════════════════════════════════════
   11. SINGLE POST (محسّن بالكامل)
═══════════════════════════════════════════════ */

/* ── تخطيط الصفحة حسب موضع الشريط الجانبي ── */
.single-layout {
    display: grid;
    gap: 36px;
    margin: 32px 0;
}

/* الوضع الافتراضي: شريط جانبي على اليمين (RTL) */
.single-layout:not([data-sidebar-pos]) {
    grid-template-columns: 1fr 340px;
}

/* شريط جانبي على اليسار */
.single-layout[data-sidebar-pos="left"] {
    grid-template-columns: 340px 1fr;
}

/* بدون شريط جانبي */
.single-layout[data-sidebar-pos="none"] {
    grid-template-columns: 1fr;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

/* إخفاء الشريط الجانبي على الجوال إذا تم تفعيل الإعداد */
@media (max-width: 820px) {
    .single-layout[data-sidebar-hide-mobile="true"] {
        grid-template-columns: 1fr;
    }
    .single-layout[data-sidebar-hide-mobile="true"] .single-sidebar {
        display: none;
    }
}

/* ── رأس المقال ── */
.post-header {
    margin-bottom: 30px;
}

.post-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
}

.post-cats a {
    background: var(--primary);
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 16px;
    border-radius: 20px;
    transition: all var(--transition);
}

.post-cats a:hover {
    background: var(--secondary);
    transform: translateY(-2px);
}

.post-header h1 {
    font-size: clamp(28px, 5vw, 42px);
    font-weight: 900;
    font-family: var(--ff-title);
    line-height: 1.4;
    color: var(--text);
    margin-bottom: 20px;
}

/* ── شريط المعلومات (Meta) ── */
.post-meta-full {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-muted);
    padding-bottom: 18px;
    border-bottom: 1px solid var(--border);
}

.meta-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.meta-item .svg-icon {
    width: 1.2em;
    height: 1.2em;
    vertical-align: middle;
    fill: currentColor;
}

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

.meta-item a:hover {
    color: var(--primary);
}

/* ── الصورة المميزة ── */
.post-featured-img {
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 32px;
}

/* محاذاة الصورة */
.post-featured-img.align-center {
    text-align: center;
}
.post-featured-img.align-wide {
    margin-left: -20px;
    margin-right: -20px;
    border-radius: 0;
}
@media (min-width: 1300px) {
    .post-featured-img.align-wide {
        margin-left: calc(-50vw + 50%);
        margin-right: calc(-50vw + 50%);
        border-radius: 0;
    }
}
.post-featured-img.align-left {
    float: left;
    margin-right: 24px;
    margin-bottom: 16px;
    max-width: 50%;
}
.post-featured-img.align-right {
    float: right;
    margin-left: 24px;
    margin-bottom: 16px;
    max-width: 50%;
}

.post-featured-img img {
    width: 100%;
    height: auto;
    max-height: 560px;
    object-fit: cover;
}

.post-featured-img figcaption {
    font-size: 12px;
    color: var(--text-muted);
    text-align: center;
    padding: 8px;
    background: var(--light);
    margin-top: -4px;
}

/* ── محتوى المقال ── */
.post-content {
    font-size: var(--single-font-size, 16.5px);
    line-height: var(--single-line-height, 1.9);
    color: var(--text);
    max-width: var(--single-content-width, 760px);
    margin-left: auto;
    margin-right: auto;
    font-family: var(--single-body-font, var(--ff-body));
}

.post-content h2,
.post-content h3,
.post-content h4 {
    font-family: var(--ff-title);
    margin: 1.8em 0 0.8em;
    color: var(--text);
    font-weight: 800;
}

.post-content p {
    margin-bottom: 1.5em;
}

.post-content blockquote {
    border-right: 4px solid var(--primary);
    background: var(--light);
    padding: 1.2em 1.8em;
    border-radius: 0 var(--radius) var(--radius) 0;
    margin: 2em 0;
    font-style: italic;
    color: var(--text-muted);
    font-size: 1.05em;
}

.post-content img {
    border-radius: var(--radius);
    margin: 1.5em 0;
    max-width: 100%;
    height: auto;
}

.post-content a {
    color: var(--primary);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* ── أزرار المشاركة ── */
.share-btns {
    display: flex;
    gap: 12px;
    margin: 32px 0 16px;
    align-items: center;
    flex-wrap: wrap;
}

.share-btns span {
    font-size: 14px;
    font-weight: 700;
    color: var(--text);
}

.share-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease, opacity 0.2s;
    color: #fff;
    border: none;
    cursor: pointer;
}

.share-btn:hover {
    transform: scale(1.1);
}

.share-btn.tw { background: #1da1f2; }
.share-btn.fb { background: #1877f2; }
.share-btn.wa { background: #25d366; }
.share-btn.tg { background: #0088cc; }
.share-btn.mail { background: #6c757d; }

/* ── وسوم المقال ── */
.post-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 32px 0 24px;
}

.post-tags a {
    background: var(--light);
    color: var(--text-muted);
    font-size: 12px;
    padding: 6px 16px;
    border-radius: 30px;
    border: 1px solid var(--border);
    transition: all var(--transition);
    text-decoration: none;
}

.post-tags a:hover {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* ── صندوق معلومات الكاتب (Author Box) ── */
.author-box {
    background: var(--surface);
    border-radius: var(--radius-lg);
    padding: 28px;
    margin: 40px 0 32px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    display: flex;
    gap: 24px;
    align-items: flex-start;
    flex-wrap: wrap;
}

.author-avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    border: 3px solid var(--primary);
}

.author-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.author-info {
    flex: 1;
}

.author-name {
    font-size: 1.3rem;
    font-weight: 800;
    font-family: var(--ff-title);
    color: var(--text);
    margin-bottom: 8px;
}

.author-bio {
    font-size: 14px;
    line-height: 1.7;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.author-socials {
    display: flex;
    gap: 12px;
}

.author-socials a {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--light);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    transition: all var(--transition);
}

.author-socials a:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-3px);
}

/* ── المقالات المشابهة (Related Posts) ── */
.related-posts {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.related-posts .sec-head {
    margin-top: 0;
}

.related-grid {
    display: grid;
    gap: 24px;
    margin-top: 24px;
}

/* عدد الأعمدة (يتم ضبطه عبر inline style أو class) */
.related-grid[data-columns="2"] {
    grid-template-columns: repeat(2, 1fr);
}
.related-grid[data-columns="3"] {
    grid-template-columns: repeat(3, 1fr);
}
.related-grid[data-columns="4"] {
    grid-template-columns: repeat(4, 1fr);
}

/* البطاقة داخل المقالات المشابهة */
.related-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition);
}

.related-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.related-card .thumb {
    overflow: hidden;
}

.related-card .thumb img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.related-card:hover .thumb img {
    transform: scale(1.05);
}

.related-card .body {
    padding: 16px;
}

.related-card h4 {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.5;
    margin-bottom: 8px;
}

.related-card h4 a {
    color: var(--text);
    text-decoration: none;
}

.related-card h4 a:hover {
    color: var(--primary);
}

.related-card .date {
    font-size: 11px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ── التعليقات ── */
.comments-area {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
}

.comment-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.comment {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid var(--border);
}


/* ═══════════════════════════════════════════════
   12. ARCHIVE & PAGINATION
═══════════════════════════════════════════════ */
.archive-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--blue-dark) 100%);
    padding: 44px 0;
    margin-bottom: 36px;
    border-radius: 0 0 18px 18px;
}

.archive-header h1 {
    font-size: 30px;
    font-weight: 900;
    font-family: var(--ff-title);
    color: var(--white);
    margin-bottom: 10px;
}

.archive-header .arc-meta { font-size: 14px; color: rgba(255, 255, 255, .7); }

.archive-grid { display: grid; grid-template-columns: 1fr 340px; gap: 32px; }
.posts-list { display: flex; flex-direction: column; gap: 22px; }

.list-card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    display: flex;
    transition: transform var(--transition), box-shadow var(--transition);
}

.list-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.list-card .thumb { width: 220px; flex-shrink: 0; overflow: hidden; }
.list-card .thumb img { height: 100%; min-height: 160px; transition: transform .4s; }
.list-card:hover .thumb img { transform: scale(1.06); }

.list-card .body { padding: 20px; flex: 1; display: flex; flex-direction: column; }

.list-card h3 {
    font-size: 17px;
    font-weight: 700;
    font-family: var(--ff-title);
    line-height: 1.5;
    color: var(--text);
    margin-bottom: 10px;
    flex: 1;
}

.list-card:hover h3 { color: var(--primary); }

.list-card .excerpt {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.7;
    margin-bottom: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 36px; flex-wrap: wrap; }

.pagination a,
.pagination span {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 600;
    border: 1.5px solid var(--border);
    color: var(--text);
    transition: all var(--transition);
}

.pagination a:hover,
.pagination .current {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
}

/* ═══════════════════════════════════════════════
   13. FOOTER
═══════════════════════════════════════════════ */
.site-footer { background: var(--footer-bg); padding: 56px 0 0; margin-top: auto; }

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 36px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.footer-brand p { font-size: 13px; color: rgba(255, 255, 255, .5); margin-top: 16px; line-height: 1.8; }
.footer-logo img { height: 52px; width: auto; filter: brightness(10); }

.footer-socials { display: flex; gap: 10px; margin-top: 22px; }

.social-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: rgba(255, 255, 255, .6);
    transition: all var(--transition);
}

.social-btn:hover { background: var(--primary); color: var(--white); transform: translateY(-3px); }

.footer-col h4 {
    font-size: 14px;
    font-weight: 700;
    color: var(--white);
    font-family: var(--ff-title);
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary);
    display: inline-block;
}

.footer-col ul { display: flex; flex-direction: column; gap: 12px; }
.footer-col ul li a { font-size: 13px; color: rgba(255, 255, 255, .5); display: flex; align-items: center; gap: 8px; }
.footer-col ul li a::before { content: '‹'; color: var(--primary); font-size: 18px; }
.footer-col ul li a:hover { color: var(--white); padding-right: 6px; }

.footer-bottom {
    padding: 18px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    color: rgba(255, 255, 255, .3);
    flex-wrap: wrap;
    gap: 12px;
}


/* ═══════════════════════════════════════════════
   14. UI ELEMENTS (محسّن)
═══════════════════════════════════════════════ */

/* ── شريط تقدم القراءة ── */
#reading-progress {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    height: var(--progress-height, 4px);
    background: transparent;
    z-index: 9999;
    pointer-events: none;
}

#reading-progress.below-header {
    top: auto;
    bottom: 0;
}

#reading-progress .bar {
    height: 100%;
    width: 0%;
    background: var(--progress-color, var(--primary));
    transition: width 0.08s linear;
    box-shadow: 0 0 6px rgba(0,0,0,0.2);
}

/* ── زر العودة للأعلى ── */
#back-to-top {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 48px;
    height: 48px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: all var(--transition);
    z-index: 50;
    border: none;
    font-size: 20px;
}

#back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}

#back-to-top:hover {
    background: var(--blue-dark);
    transform: translateY(-4px);
}

/* ═══════════════════════════════════════════════
   15. RESPONSIVE BREAKPOINTS
═══════════════════════════════════════════════ */
/* ═══════════════════════════════════════════════
   15. RESPONSIVE BREAKPOINTS (إضافات Single)
═══════════════════════════════════════════════ */

@media (max-width: 820px) {
    .single-layout {
        grid-template-columns: 1fr !important;
    }
    .single-sidebar {
        margin-top: 40px;
    }
    .post-header h1 {
        font-size: 28px;
    }
    .author-box {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .author-socials {
        justify-content: center;
    }
    .related-grid[data-columns="3"],
    .related-grid[data-columns="4"] {
        grid-template-columns: repeat(2, 1fr);
    }
    .post-featured-img.align-left,
    .post-featured-img.align-right {
        float: none;
        max-width: 100%;
        margin: 0 0 20px 0;
    }
}

@media (max-width: 560px) {
    .post-meta-full {
        gap: 12px;
        font-size: 12px;
    }
    .related-grid[data-columns="2"],
    .related-grid[data-columns="3"],
    .related-grid[data-columns="4"] {
        grid-template-columns: 1fr;
    }
    .share-btns {
        justify-content: center;
    }
    .post-content {
        font-size: 16px;
        line-height: 1.75;
    }
    .author-avatar {
        width: 80px;
        height: 80px;
    }
}
/* ── Tablet Landscape (≤ 1100px) ── */
@media (max-width: 1100px) {
    .hero-grid { grid-template-columns: 1fr 300px; }
    .news-grid,
    .opinion-grid { grid-template-columns: repeat(3, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
    .magazine-grid { grid-template-columns: 1fr; }
    .mag-main { min-height: 300px; grid-row: auto; }
    .interviews-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ── Tablet Portrait (≤ 820px) ── */
@media (max-width: 820px) {
    .hero-grid { grid-template-columns: 1fr; }
    .hero-main { grid-row: auto; }
    .hero-main .thumb img { height: 320px; }
    .hero-side { flex-direction: row; }
    .hero-card .thumb img { min-height: 200px; }

    .news-grid,
    .opinion-grid { grid-template-columns: repeat(2, 1fr); }

    .two-col,
    .single-layout,
    .archive-grid { grid-template-columns: 1fr; }

    .half-grid { grid-template-columns: 1fr; }

    .reports-grid { grid-template-columns: 1fr; }
    .report-card-big { grid-column: auto; }
    .invest-sub { grid-template-columns: repeat(2, 1fr); }

    .main-nav { display: none; }
    .menu-toggle { display: flex; }
    .related-grid { grid-template-columns: repeat(2, 1fr); }

    .list-card { flex-direction: column; }
    .list-card .thumb { width: 100%; }
    .list-card .thumb img { height: 200px; }

    .side-stacked { grid-template-columns: 1fr; }
    .ss-image { height: 220px; min-height: auto; }

    .slider-btn { display: none; }
    .slider-hero-slide { min-height: 280px; }
    .slider-hero-slide .content h2 { font-size: 20px; }

    .interviews-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ── Mobile (≤ 560px) ── */
@media (max-width: 560px) {
    .container { padding: 0 16px; }

    .news-grid,
    .opinion-grid,
    .invest-sub,
    .quotes-grid,
    .video-grid { grid-template-columns: 1fr; }

    .footer-grid { grid-template-columns: 1fr; }
    .hero-side { flex-direction: column; }
    .related-grid { grid-template-columns: 1fr; }
    .post-header h1 { font-size: 24px; }
    .invest-card .content h2 { font-size: 22px; }
    .mag-main .content h2 { font-size: 18px; }
    .numbered-grid { max-width: 100%; }
    .numbered-item .thumb { display: none; }

    /* تحوّل الحوارات لسلايدر أفقي */
    .interviews-grid {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 16px;
        padding-bottom: 12px;
    }

    .interviews-grid::-webkit-scrollbar { display: none; }

    .interview-card {
        scroll-snap-align: start;
        flex-shrink: 0;
        width: 280px;
    }

    .interview-card .thumb img { height: 180px; }

    /* النصف يصبح عمود كامل */
    .half-grid { grid-template-columns: 1fr; }
    .half-col > .sec-head { margin-top: 44px; }
}

/* ── Print ── */
@media print {
    .site-header,
    .ticker-bar,
    .date-bar,
    .site-footer,
    #back-to-top,
    #reading-progress,
    .share-btns,
    .slider-btn,
    .slider-dots { display: none !important; }

    body { background: #fff; color: #000; font-size: 12pt; }
    .container { max-width: 100%; padding: 0; }
    a { color: #000; text-decoration: underline; }
}
/* ========== تبويبات الودجيت ========== */
.ayj-tabs-widget {
    background: var(--surface);
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 24px;
}

.ayj-tabs-nav {
    display: flex;
    border-bottom: 1px solid var(--border);
    background: var(--light);
}

.ayj-tab-btn {
    flex: 1;
    padding: 12px 10px;
    background: none;
    border: none;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}

.ayj-tab-btn.active {
    color: var(--primary);
    border-bottom: 2px solid var(--primary);
    margin-bottom: -1px;
}

.ayj-tabs-content {
    padding: 8px 0;
}

.ayj-tab-pane {
    display: none;
}

.ayj-tab-pane.active {
    display: block;
}

.ayj-tabs-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.ayj-tabs-item {
    display: flex;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    align-items: center;
}

.ayj-tabs-item:last-child {
    border-bottom: none;
}

.ayj-tabs-thumb {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
}

.ayj-tabs-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ayj-tabs-info {
    flex: 1;
}

.ayj-tabs-info h4 {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    margin: 0 0 4px;
}

.ayj-tabs-info h4 a {
    color: var(--text);
    text-decoration: none;
    transition: color 0.2s;
}

.ayj-tabs-info h4 a:hover {
    color: var(--primary);
}

.ayj-tabs-meta {
    font-size: 11px;
    color: var(--text-muted);
}

/* RTL tweak */
[dir="rtl"] .ayj-tabs-item {
    flex-direction: row;
}