/*
Theme Name: SAW v3 Theme
Theme URI: https://sawinstory.com
Author: سعيد
Description: قالب مخصص بدون إضافات ثقيلة معتمد على HTMX والمنظومة المعرفية v3.
Version: 1.0.0
*/

/*
Theme Name: SAW v3 Theme
Theme URI: https://sawinstory.com
Author: سعيد
Description: قالب مخصص بدون إضافات ثقيلة معتمد على HTMX والمنظومة المعرفية v3.
Version: 1.0.0
*/

/* غلاف القسم لتوسيعه وتحديد منطقة الطفو */
.saw-hero-latest-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px auto 35px auto;
    padding: 0 15px;
    width: 100%;
    max-width: 850px;
}

/* بطاقة "الأحدث على الإطلاق" العائمة والمعلقة في الوسط */
.saw-hero-latest-card {
    position: relative;
    background: rgba(18, 24, 38, 0.85);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 20px;
    padding: 25px 30px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5),
                0 0 25px rgba(212, 175, 55, 0.25); /* التوهج الذهبي */
    animation: sawFloat 4s ease-in-out infinite, sawGlowPulse 3s infinite alternate;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 100%;
}

.saw-hero-latest-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6),
                0 0 35px rgba(212, 175, 55, 0.45);
}

/* شارة الأحدث المعرفية */
.saw-latest-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.5);
    padding: 4px 14px;
    border-radius: 50px;
    font-size: 0.85rem;
    color: #d4af37;
    margin-bottom: 12px;
    font-weight: bold;
}

/* النقطة النابضة باللون الأحمر/الذهبي لتأكيد الحيوية والتحديث */
.saw-pulse-dot {
    width: 8px;
    height: 8px;
    background-color: #ff4d4d;
    border-radius: 50%;
    box-shadow: 0 0 8px #ff4d4d;
    animation: sawDotPulse 1.5s infinite;
}

/* عنوان المقال الأحدث */
.saw-latest-title {
    margin: 10px 0;
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.4;
}

.saw-latest-title a {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.saw-latest-title a:hover {
    color: #d4af37;
}

/* تفاصيل المقال (التاريخ والقسم) */
.saw-latest-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    color: #a0aec0;
    margin-bottom: 18px;
}

.saw-meta-divider {
    color: #4a5568;
}

/* زر الانتقال */
.saw-latest-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #d4af37 0%, #aa7c11 100%);
    color: #0d1117;
    padding: 8px 22px;
    border-radius: 30px;
    font-weight: bold;
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.saw-latest-btn:hover {
    background: linear-gradient(135deg, #f3e5ab 0%, #d4af37 100%);
    color: #000;
    transform: scale(1.03);
}

/* أنيميشن الطفو التلقائي */
@keyframes sawFloat {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-7px); }
    100% { transform: translateY(0px); }
}

/* أنيميشن نبض التوهج */
@keyframes sawGlowPulse {
    0% { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 15px rgba(212, 175, 55, 0.2); }
    100% { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 30px rgba(212, 175, 55, 0.45); }
}

@keyframes sawDotPulse {
    0% { transform: scale(0.95); opacity: 0.8; }
    50% { transform: scale(1.3); opacity: 1; }
    100% { transform: scale(0.95); opacity: 0.8; }
}

/* ----------------------------------------------------
   1. التنسيقات العامة والأساسية (Global Variables & Base)
---------------------------------------------------- */
:root {
    --saw-gold: #d4af37;           /* اللون الذهبي */
    --saw-gold-hover: #f1c40f;     /* ذهبي مشرق عند التحويم */
    --saw-burgundy: #800020;       /* لون دم الغزال */
    --saw-burgundy-light: #9b111e; /* دم غزال أفتح قليلاً للتأثيرات */
    --saw-text-light: #f8fafc;
    --saw-text-muted: #94a3b8;
    --saw-border-color: rgba(255, 255, 255, 0.1);
}

body {
    margin: 0;
    padding: 0;
    background-color: #090d16;
    color: var(--saw-text-light);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    direction: rtl;
}

/* ----------------------------------------------------
   2. تنسيقات الهيدر (Header Styles)
---------------------------------------------------- */
.saw-site-header {
    background: transparent; /* خلفية شفافة */
    border-bottom: 1px solid var(--saw-border-color);
    padding: 18px 20px;
    position: relative;
    z-index: 100;
}

.saw-header-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

/* هوية الموقع */
.saw-branding {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.saw-site-title {
    margin: 0;
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.2;
}

/* اسم الموقع باللون الذهبي */
.saw-site-title a {
    color: var(--saw-gold);
    text-decoration: none;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.saw-site-title a:hover {
    color: var(--saw-gold-hover);
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

/* سطر الوصف بلون دم الغزال */
.saw-site-description {
    color: var(--saw-burgundy);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.3px;
}

/* أزرار التفاعل والرصيد */
.saw-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* عرض رصيد المحفظة */
.saw-wallet-badge {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--saw-border-color);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--saw-text-light);
    backdrop-filter: blur(5px);
}

.saw-wallet-amount {
    color: var(--saw-gold);
    font-weight: bold;
}

/* زر تسجيل الدخول */
.saw-btn-login {
    color: var(--saw-text-light);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 8px;
    transition: all 0.25s ease;
}

.saw-btn-login:hover {
    background: rgba(255, 255, 255, 0.08);
}

/* زر الانضمام بلون دم الغزال المميز */
.saw-btn-join {
    background: var(--saw-burgundy);
    color: #ffffff;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 8px 18px;
    border-radius: 8px;
    border: 1px solid var(--saw-burgundy-light);
    transition: all 0.25s ease;
    box-shadow: 0 2px 8px rgba(128, 0, 32, 0.3);
}

.saw-btn-join:hover {
    background: var(--saw-burgundy-light);
    box-shadow: 0 4px 12px rgba(155, 17, 30, 0.5);
}
