/* ============================================================================
   article.css — modern, attractive single-article view.
   Used on /articles/<slug> (and /ar/articles/<slug>).
   ============================================================================ */

.aa-article { background: #fff; }

/* === HERO BANNER === */
.aa-article__hero {
    background: linear-gradient(135deg, #2a1850 0%, #4F3580 45%, #6c4dff 100%);
    color: #fff;
    padding: 90px 0 140px;
    position: relative;
    overflow: hidden;
}
.aa-article__hero::before {
    content: '';
    position: absolute; top: -50%; right: -10%;
    width: 600px; height: 600px;
    background: radial-gradient(circle, rgba(196,181,253,0.18), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.aa-article__hero::after {
    content: '';
    position: absolute; bottom: -30%; left: -10%;
    width: 500px; height: 500px;
    background: radial-gradient(circle, rgba(108,77,255,0.18), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.aa-article__hero .aa-container {
    text-align: center;
    max-width: 820px;
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 1;
}

.aa-article__breadcrumb {
    font-size: 11.5px;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(255,255,255,0.85);
    margin-bottom: 18px;
    font-weight: 600;
}
.aa-article__breadcrumb a { color: rgba(255,255,255,0.9); text-decoration: none; }
.aa-article__breadcrumb a:hover { color: #fff; text-decoration: underline; }

.aa-article__title {
    font-family: 'Outfit', 'Inter', system-ui, sans-serif !important;
    font-size: clamp(28px, 4.5vw, 48px);
    line-height: 1.15;
    margin: 0 0 22px;
    color: #fff !important;
    font-weight: 800;
    letter-spacing: -0.02em;
    text-shadow: 0 4px 24px rgba(0,0,0,0.25);
}

.aa-article__meta {
    font-size: 14px;
    color: #fff;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: rgba(255,255,255,0.12);
    border: 1px solid rgba(255,255,255,0.2);
    padding: 10px 22px;
    border-radius: 999px;
    backdrop-filter: blur(10px);
}
.aa-article__byline-link {
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    border-bottom: 1px dotted rgba(255,255,255,0.5);
}
.aa-article__byline-link:hover {
    color: #fff;
    border-bottom-color: #fff;
}

/* === FEATURED IMAGE === */
.aa-article__featured {
    max-width: 980px;
    margin: -100px auto 0;
    padding: 0 20px;
    position: relative;
    z-index: 2;
}
.aa-article__featured img {
    width: 100%;
    height: auto;
    max-height: 540px;
    object-fit: cover;
    border-radius: 18px;
    box-shadow: 0 24px 60px rgba(42, 24, 80, 0.25);
    display: block;
}

/* === BODY === */
.aa-article__body {
    max-width: 720px;
    margin: 60px auto 40px;
    padding: 0 24px;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 17px;
    line-height: 1.75;
    color: #2a2a3e;
}
.aa-article__body h2,
.aa-article__body h3,
.aa-article__body h4 {
    font-family: 'Outfit', 'Inter', system-ui, sans-serif;
    font-weight: 700;
    color: #2a1850;
    line-height: 1.25;
    letter-spacing: -0.01em;
    margin: 1.8em 0 0.6em;
}
.aa-article__body h2 { font-size: 1.7em; }
.aa-article__body h3 { font-size: 1.35em; }
.aa-article__body h4 { font-size: 1.15em; }
.aa-article__body p { margin: 1em 0; }
.aa-article__body a {
    color: #6c4dff;
    text-decoration: underline;
    text-decoration-thickness: 1.5px;
    text-underline-offset: 2px;
    transition: color .15s;
}
.aa-article__body a:hover { color: #4F3580; }
.aa-article__body ul, .aa-article__body ol { margin: 1em 0; padding-left: 1.6em; }
.aa-article__body li { margin: 0.5em 0; }
.aa-article__body img { max-width: 100%; height: auto; border-radius: 12px; margin: 1.6em 0; box-shadow: 0 8px 24px rgba(42,24,80,0.1); }
.aa-article__body blockquote {
    border-left: 4px solid #6c4dff;
    margin: 1.6em 0;
    padding: 0.6em 0 0.6em 1.4em;
    color: #4F3580;
    font-style: italic;
    background: linear-gradient(135deg, #faf5ff, transparent);
    border-radius: 0 8px 8px 0;
}
.aa-article__body code {
    background: #f1ecf8;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.9em;
    color: #4F3580;
    font-family: 'JetBrains Mono', Menlo, monospace;
}
.aa-article__body pre {
    background: #2a1850;
    color: #e0d4f4;
    padding: 16px 20px;
    border-radius: 10px;
    overflow-x: auto;
    font-size: 14px;
    line-height: 1.55;
}
.aa-article__body pre code { background: none; color: inherit; padding: 0; }
.aa-article__body hr {
    border: none;
    border-top: 2px solid #f1ecf8;
    margin: 2em 0;
}

/* === TAGS === */
.aa-article__tags {
    max-width: 720px;
    margin: 40px auto;
    padding: 24px;
    background: linear-gradient(135deg, #faf5ff, #fff);
    border-radius: 14px;
    border: 1px solid #ece8f5;
}
.aa-article__tags-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #6b7280;
    font-weight: 700;
    margin-bottom: 10px;
}
.aa-article__tag-list { display: flex; flex-wrap: wrap; gap: 8px; }
.aa-article__tag {
    display: inline-block;
    padding: 6px 14px;
    background: #fff;
    color: #604580;
    border: 1px solid #d8d6e2;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all .15s;
}
.aa-article__tag:hover {
    background: #604580;
    color: #fff;
    border-color: #604580;
    transform: translateY(-1px);
}

/* === CTA BLOCK === */
.aa-article__cta {
    max-width: 820px;
    margin: 50px auto;
    padding: 38px 32px;
    background: linear-gradient(135deg, #2a1850 0%, #6c4dff 100%);
    border-radius: 18px;
    text-align: center;
    color: #fff;
    box-shadow: 0 16px 40px rgba(42,24,80,0.2);
}
.aa-article__cta h3 {
    font-family: 'Outfit', 'Inter', sans-serif !important;
    font-size: 1.6em;
    margin: 0 0 10px;
    color: #fff !important;
    font-weight: 700;
}
.aa-article__cta p {
    margin: 0 0 22px;
    color: rgba(255,255,255,0.85);
    font-size: 15px;
}
.aa-article__cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    background: #fff;
    color: #2a1850 !important;
    text-decoration: none;
    font-weight: 700;
    border-radius: 999px;
    font-size: 15px;
    transition: all .15s;
    box-shadow: 0 6px 18px rgba(0,0,0,0.15);
}
.aa-article__cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0,0,0,0.25);
}

/* === BACK NAV === */
.aa-article__back {
    max-width: 720px;
    margin: 40px auto 80px;
    padding: 0 24px;
    text-align: center;
}
.aa-article__back a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    color: #604580;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    border: 1.5px solid #d8d6e2;
    border-radius: 999px;
    transition: all .15s;
}
.aa-article__back a:hover {
    background: #604580;
    color: #fff;
    border-color: #604580;
}

/* === RTL (Arabic) === */
html[dir="rtl"] .aa-article__body,
html[dir="rtl"] .aa-article__title,
html[dir="rtl"] .aa-article__cta h3 {
    font-family: 'Cairo', 'Tajawal', sans-serif !important;
    direction: rtl;
    text-align: right;
}
html[dir="rtl"] .aa-article__hero .aa-container { text-align: center; } /* hero stays centered */
html[dir="rtl"] .aa-article__body ul,
html[dir="rtl"] .aa-article__body ol { padding-left: 0; padding-right: 1.6em; }
html[dir="rtl"] .aa-article__body blockquote {
    border-left: none;
    border-right: 4px solid #6c4dff;
    padding: 0.6em 1.4em 0.6em 0;
    border-radius: 8px 0 0 8px;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .aa-article__hero { padding: 60px 0 100px; }
    .aa-article__title { font-size: 1.7em; }
    .aa-article__featured { margin: -70px auto 0; padding: 0 16px; }
    .aa-article__featured img { max-height: 320px; border-radius: 14px; }
    .aa-article__body { font-size: 16px; padding: 0 18px; }
    .aa-article__cta { margin: 32px 16px; padding: 28px 22px; }
    .aa-article__cta h3 { font-size: 1.35em; }
}
