html, body {
	font-family: 'Helvetica Neue', Arial, sans-serif;
    border: 5px solid #89c4ec;
    box-sizing: border-box;
}


.entry-content p,
.entry-content ol,
.entry-content ul,
.entry-content dl,
.entry-content dt {
  font-family: Arial, sans-serif;
  font-weight: 700;
  font-style: normal;
  color: #000000;
  line-height: 34px;
  font-size: 22px;
    will-change: transform;
}

@media (max-width: 768px) {
  .entry-content p,
  .entry-content ol,
  .entry-content ul,
  .entry-content dl,
  .entry-content dt {
    font-family: Arial, sans-serif;
    font-weight: 700;
    font-style: normal;
    color: #000000;
    line-height: 36px;
    font-size: 22px;
        will-change: transform;
  }
}


h1, .entry-content h1 { 
    font-family: arial; 
    font-size: 30px;
    font-weight: 700; 
    color: #000; 
    line-height: 36px; 
    text-align: center;
    padding: 10px;
    margin-bottom: 20px;
    background: linear-gradient(to right, rgba(137, 207, 240, 0), rgba(137, 207, 240, 1), rgba(137, 207, 240, 0));

    -webkit-background-clip: padding-box;
	    will-change: transform;
}

@media (max-width: 600px) {
    h1, .entry-content h1 { 
        font-size: 25px;
        line-height: 30px;
        margin-bottom: 15px; 
			        will-change: transform;
    }
}




.author-date-box {
    padding: 5px;
    margin-bottom: 5px;
    font-weight: bold;
    will-change: transform;
}


@media (max-width: 600px) {
    .author-date-box {
        font-size: 16px;
			        will-change: transform;
    }
}


h2, .entry-content h2, h3, .entry-content h3, h4, .entry-content h4 {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    font-weight: 700;
    line-height: 36px;
    padding: 10px;
    display: block;
    background: linear-gradient(to right, transparent, #50afe5);
    color: #000;
    will-change: transform;
}


@media screen and (max-width: 600px) {
    h2, .entry-content h2, h3, .entry-content h3, h4, .entry-content h4 {
        font-size: 25px; 
        line-height: 36px; 
    }
}


@media screen and (min-width: 601px) and (max-width: 1024px) {
    h2, .entry-content h2, h3, .entry-content h3, h4, .entry-content h4 {
        font-size: 25px; 
        line-height: 36px;
    }
}





#breadcrumbs {
    text-align: center;
    padding: 5px;
    margin-bottom: 5px;
    font-weight: bold;
will-change: transform;
}

@media (max-width: 600px) {
    #breadcrumbs {
        font-size: 14px;
        padding: 5px;
			 will-change: transform;
    }
}
.related-post {
    padding: 10px;
    margin: 10px 0;
    color: #000;
}

@media only screen and (max-width: 600px) {
  .responsive-title {
    font-size: 14px;
    padding: 5px 10px;
  }
}


.custom-featured-image {
    width: 100%;
    max-width: 380px;
    height: 200px; 
    object-fit: cover;
    margin: auto;
    display: block;
    border: 2px solid #7EC8E3;
}

@media (max-width: 380px) {
    .custom-featured-image {
        width: 85%;
        height: auto;
        margin: auto;
    }
}


.custom-caption {
    width: 100%;
    color: black;
    background-color: rgba(255, 255, 255, 0.5);
    padding: 5px 0;
    font-weight: bold;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

@media (max-width: 380px) {
    .custom-caption {
        width: 85%; 
    }
}


.custom-post-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 7px; 
    padding: 0;
    background: radial-gradient(circle, rgba(211,211,211,1) 50%, rgba(211,211,211,0) 100%);
width: 100%;

    width: 100%;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

@media only screen and (max-width: 600px) {
    .custom-post-meta {
        padding-left: 10px;
        padding-right: 10px;
    }
}

.engraved-line {
    height: 2px;
    background: #ccc; 
    box-shadow: 0 1px 1px rgba(255,255,255,.1), 0 -1px 1px rgba(0,0,0,.1);
    margin-top: 7px; 
    margin-bottom: 20px;
}

@media only screen and (max-width: 600px) {
    .engraved-line {
        margin-top: 7px;
        margin-bottom: 10px;
    }
}

@media only screen and (min-width: 601px) and (max-width: 1024px) {
    .engraved-line {
        margin-top: 7px;
        margin-bottom: 15px;
    }
}

@media only screen and (min-width: 1025px) {
    .engraved-line {
        margin-top: 7px;
        margin-bottom: 20px;
    }
}




.social-icons {
    position: fixed;
    top: 50%;  
    right: 20px; 
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    transition: 0.3s ease;
    opacity: 0.5;
    animation: 1s fadeIn ease-in;
}

.social-icon {
    margin-bottom: 10px; 
    transition: 0.3s ease;
}

.social-icon:hover {
    transform: rotate(360deg);
    opacity: 1;
}

@keyframes fadeIn {
    0% {opacity: 0;}
    100% {opacity: 0.5;} 
}

@media only screen and (max-width: 600px) {
    .social-icons {
        right: 10px;
    }

    .social-icon {
        margin-bottom: 5px;
    }
}

#related-post {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: auto;
    text-align: center;
    padding: 0px 0;
    box-sizing: border-box;
    margin-bottom: 20px;
    animation: gradient 8s ease infinite; 
}

.related-post-title {
    color: white;
    font-weight: bold;
    padding: 0px 0;
    display: inline-block;
    margin: 0 auto;
}

@media only screen and (min-width: 600px) {
    #related-post {
        left: 0;
        right: 0;
        width: auto;
        padding: 0px;
        display: flex;
        justify-content: center;
    }
}


@keyframes gradient {
    0% {background: #8B4513;}
    33% {background: #8B0000;} 
    66% {background: #006400;} 
    100% {background: #8B4513;} 
}

.related-post-item {
    display: none;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

.related-post-item.active {
    display: block;
    opacity: 1;
}


/* Rule for blockquote */
blockquote {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    padding: 1em 2em;
    background-color: #E6E6FA;
    color: black;
    border-radius: 25px;
    position: relative;
    font-weight: bold;
    direction: rtl;
    transition: 0.5s;
    box-shadow: 2px 2px 10px rgba(0,0,0,0.1);
    max-width: 90%;
    margin: auto;
    margin-bottom: 1em;
}

/* Hide direct child div elements of blockquote */
blockquote > div {
    display: none;
}

/* Show only direct child paragraphs and lists of blockquote */
blockquote > p, 
blockquote > ol,
blockquote > ul {
    display: block;
    padding: 0 1em;
    text-shadow: 1px 1px 1px rgba(0,0,0,0.1);
    font-size: 2em;
}

/* Hover effect for blockquote */
blockquote:hover {
    transform: scale(1.02);
    box-shadow: 4px 4px 20px rgba(0,0,0,0.2);
}

/* Adding quotations before and after blockquote */
blockquote::before,
blockquote::after {
    font-size: 3em;
    position: absolute;
    color: #4169E1;
}

blockquote::before {
    content: "❞";
    top: 2%;
    right: 2%;
}

blockquote::after {
    content: "❞";
    transform: scaleX(-1);
    bottom: 2%;
    left: 2%;
}

/* Adjustments for mobile and tablet screens */
@media only screen and (max-width: 768px) {
    blockquote::before,
    blockquote::after {
        font-size: 2em;
    }
    
    blockquote > p,
    blockquote > ol,
    blockquote > ul {
        font-size: 1.5em;
    }
    
    blockquote {
        padding: 0.5em 1em;
    }
}

table {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    border: 0.1rem solid #dcd7ca;
    border-collapse: separate;
    border-spacing: 0;
    empty-cells: show;
    font-size: 2rem;
    margin: 4rem 0;
    width: 100%;
    box-shadow: inset 0 0 1rem rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
}


.alignleft > table {
	margin: 0;
}

.alignright > table {
	margin: 0;
}

th,
td {
	border: 0.1rem solid #dcd7ca;
	line-height: 1.4;
	margin: 0;
	overflow: visible;
	padding: 0.5em;
	font-weight: bold;
	text-align: center;
	vertical-align: middle;
    white-space: nowrap;
}

caption {
	background: #dcd7ca;
	font-weight: 600;
	padding: 0.5em;
	text-align: center;
}

thead {
	vertical-align: bottom;
	white-space: nowrap;
}

th {
	font-weight: 700;
}

tr:nth-child(odd) {
	background: #f2f2f2;
}

tr:nth-child(even) {
	background: #fff;
}

tr:hover {
	background: #a6caf0; 
	cursor: pointer;
}

table:hover {
	transform: scale(1.01);
}

@media screen and (max-width: 768px) {
	table {
		display: block;
        overflow-x: auto;
	}
}






@keyframes blink {
  0%, 100% {background-position: left bottom;}
  50% {background-position: right top;}
}

.alert {
  padding: 20px;
  margin: 10px 0;
  border-radius: 5px;
  font-size: 1em; 
  font-weight: bold; 
}

.alert-red {
  background: linear-gradient(90deg, #f8d7da 50%, transparent 50%);
  background-size: 200% 100%;
  color: #721c24;
  box-shadow: 0 0 10px rgba(0,0,0,0.5);
}

.alert-green {
  background: linear-gradient(90deg, #d4edda 50%, transparent 50%);
  background-size: 200% 100%;
  color: #155724;
  box-shadow: 0 0 10px rgba(0,0,0,0.5);
}

@media only screen and (max-width: 768px) { 
  .alert {
    font-size: 1.25em; 
  }
}

@media only screen and (max-width: 480px) { 
  .alert {
    font-size: 1em;
  }
}


.blue-bold {
    color: blue;
    font-weight: bold;
}








.qa-section {
    margin: 20px auto; 
    padding: 20px;
    background-color: #f9f9f9;
    border: 1px solid #e1e1f1;
    border-radius: 5px;
    box-shadow: 0px 10px 30px -5px rgba(0, 0, 0, 0.3);
    max-width: 80%; 
}

.qa-section .question {
    margin-bottom: 10px;
  
    color: #ffffff; 
  
    background-color: #9b2822; 
    font-weight: 600;
    font-size: 1.4em;
    text-align: center;
    padding: 10px;
    
    border-radius: 5px;
    box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.2);
}

.qa-section .answer {
    padding: 10px;
    background-color: #4caf50;
    border-top: 1px solid #e1e1f1;
    position: relative;
    color: #fff;
    padding-right: 70px;
    text-align: center;
}

.qa-section .answer:before {
    content: "✔";
    color: #fff;
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5em;
    background-color: #008000;
    border-radius: 50%;
    padding: 5px;
    line-height: 1;
}

.qa-section .answer div {
    color: #fff;
}

/* For tablets */
@media (max-width: 768px) {
    .qa-section .question {
        font-size: 1.3em;
    }
}

/* For mobile phones */
@media (max-width: 480px) {
    .qa-section {
        padding: 10px;
    }

    .qa-section .question {
        font-size: 1.1em;
    }
}

/* author-bio  */

.custom-author-bio {
    display: flex;
    align-items: center;
    padding: 20px;
    background-color: #f9f9f9;
    border-radius: 15px;
    box-shadow: 0 0 10px rgba(0,0,0,0.15);
    direction: rtl;
}

.custom-author-avatar {
    margin-left: 30px;
    position: relative;
    flex-shrink: 0;
}

.custom-author-avatar img {
    border-radius: 50%;
    width: 110px;
    height: 110px;
    border: 3px solid #A2D2FF;
    object-fit: cover;
}

.custom-author-details {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    margin-right: 20px;
}

.custom-author-title {
    font-size: 28px;
    margin-bottom: 15px;
    color: #A2D2FF;
    text-decoration: none;
    font-weight: bold;
}

.custom-author-description {
    color: #333;
    font-weight: bold;
    text-align: justify;
}

.custom-author-link {
    text-decoration: none;
}

.custom-author-link:hover .custom-author-title {
    color: red;
}

@media (max-width: 768px) {
    .custom-author-bio {
        flex-direction: column;
        align-items: center;
    }

    .custom-author-avatar {
        margin: 0 0 20px 0;
    }

    .custom-author-details {
        margin: 0;
        align-items: center;
    }
}


/*  comments */

.comments {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0px 0px 10px #888888;
    transition: all 0.3s ease-in-out;
}

.comments:hover {
    box-shadow: 0px 0px 20px #666666;
}

.comments-header {
    margin-bottom: 20px;
}

.comments-header > div {
    font-size: 20px;
    color: #333;
    text-transform: uppercase;
    text-align: center;
    padding-bottom: 15px;
    border-bottom: 1px solid #ddd;
}

.comments-inner {
    padding-top: 20px;
}

.comment-form-author,
.comment-form-email {
    display: flex;
    flex-direction: column;
    margin-bottom: 15px;
}

.comment-form-author label,
.comment-form-email label {
    font-size: 14px;
    color: #333;
    margin-bottom: 5px;
}

.comment-form-author input,
.comment-form-email input {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    color: #333;
    transition: border 0.3s ease-in-out;
}

.comment-form-author input:focus,
.comment-form-email input:focus {
    border-color: #888;
}

.comments-closed {
    text-align: center;
    font-size: 16px;
    color: #888;
    margin-top: 20px;
}

/* searchform  */

.search-form {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto;
}

.search-field {
    margin-right: 10px;
    padding: 10px;
    font-size: 16px;
    line-height: 20px;
}

.search-submit {
    padding: 10px 20px;
    font-size: 16px;
    line-height: 20px;
}

@media (max-width: 768px) {
    .search-form {
        flex-direction: column;
    }

    .search-field, .search-submit {
        margin-top: 10px;
        width: 100%;
    }
}


    
.entry-content > *:not(.alignwide):not(.alignfull):not(.alignleft):not(.alignright):not(.wp-block-separator):not(.woocommerce) {
  width: 100%;
  max-width: 1240px;
  padding: 0 15px 0 15px; 
  box-sizing: border-box;
}

@media screen and (min-width: 768px) {
  .entry-content > *:not(.alignwide):not(.alignfull):not(.alignleft):not(.alignright):not(.wp-block-separator):not(.woocommerce) {
    padding: 0 15px 0 15px; 
  }
}

@media screen and (min-width: 1024px) {
  .entry-content > *:not(.alignwide):not(.alignfull):not(.alignleft):not(.alignright):not(.wp-block-separator):not(.woocommerce) {
    padding: 0 15px 0 15px; 
  }
}


    	.singular .entry-header {
		padding: 0.5rem 0;
	}
	
	
		.post-inner {
		padding-top: 0.5rem;
	}
	
	
	a {
  text-decoration: none;
}

a:hover {
  text-decoration: none;
}


@keyframes background-color-change {
    0% {background-color: rgba(0, 255, 0, 0.1);}
    25% {background-color: rgba(255, 0, 0, 0.1);}
    50% {background-color: rgba(0, 0, 255, 0.1);}
    75% {background-color: rgba(255, 255, 0, 0.1);}
    100% {background-color: rgba(0, 255, 0, 0.1);}
}

.responsive-title {
    color: inherit;
    text-decoration: underline;
    padding: 5px;
    margin: 10px 0 0 0;
    border-radius: 5px;
    font-size: 22px;
    border: 1px solid #9d9d9d;
    display: inline-block;
    white-space: normal;
    overflow-wrap: break-word;
    font-weight: bold;
    animation: background-color-change 5s infinite;
}

.buttons-container-89 {
    position: fixed;
    left: 5px;  
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.custom-button {
    border: none;
    border-radius: 4px;
    background-color: rgba(143, 18, 42, 0.5);
    color: #fff;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    margin: 3px; 
    text-decoration: none;
    transition: background-color 0.3s ease, transform 0.3s ease;
    text-align: center;
    padding: 2px 2px;
    white-space: nowrap;
    display: inline-block;
}

.text-button {
    writing-mode: tb-rl;
    transform: rotate(180deg);
}

.icon-button img {
    height: 30px;
    width: 30px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.icon-button:hover img {
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3);
}

.icon-button {
    background-color: transparent;
}

.custom-button:hover,
.custom-button:focus {
    background-color: #6c142c; 
    transform: translateY(-5px); 
}

/* azkar */

.custom-banner {
    background-color: #000000;
    color: #fff;
    text-align: center;
    padding: 20px;
    width: 80%;
    max-width: 600px;
    position: fixed;
    top: 70%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1000;
    font-size: 18px;
    font-weight: bold;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    border-radius: 10px;
    display: none;
    aria-hidden: true;
}
.close-button {
    cursor: pointer;
    position: absolute;
    top: -10px;
    right: -10px;
    background-color: #8B0000;
    color: #fff;
    width: 30px;
    height: 30px;
    text-align: center;
    line-height: 30px;
    border-radius: 5px;
}
.part-one,
.part-two,
.part-three {
    display: block;
    margin: 10px 0;
}
.part-one {
    color: #FFD700;
}
.part-two {
    color: #FFFFFF;
}
.part-three {
    color: #ADFF2F;
}


    .search-toggle,
    .nav-toggle {
        display: none !important;
    }
    
    
    /*
=====================================================
--- كود تنسيق بطاقات المقالات الاحترافي ---
=====================================================
*/

/* 1. حاوية الشبكة (Grid) الرئيسية
----------------------------------- */
.posts-grid-container {
    display: grid;
    
    /* هذا هو الكود الاحترافي للتجاوب:
      - ينشئ أعمدة يتراوح عرضها بين 300px و 1fr (مساحة متساوية).
      - auto-fill: يملأ المساحة المتاحة بالأعمدة.
      - النتيجة: 
        - شاشة الهاتف (أقل من 630px): عمود واحد.
        - شاشة التابلت (أكبر من 630px): عمودان.
        - شاشة الحاسوب (أكبر من 960px): 3 أعمدة أو أكثر.
    */
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    
    gap: 30px; /* مسافة واضحة بين البطاقات */
    padding-top: 20px; /* لإعطاء مسافة من العنوان العلوي */
}

/* 2. الحل الجذري لمشكلة "العمود الواحد" 
     (لأن كلاس "section-inner" في القالب يحدد max-width)
------------------------------------------------------- */
.posts-grid-container.section-inner {
    /* نلغي العرض الأقصى الضيق الذي يفرضه القالب */
    max-width: none;
    /* يمكنك تحديد عرض أقصى جديد مناسب للشبكة (اختياري) */
    /* max-width: 1280px; */ 
}


/* 3. تصميم البطاقة الاحترافي
------------------------------- */
.post-card {
    background-color: #ffffff;
    border: 1px solid #e9e9e9; /* لون إطار ناعم جداً */
    border-radius: 12px; /* زوايا دائرية أكثر احترافية */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05); /* ظل ناعم "مرتفع" */
    overflow: hidden; /* ضروري لقص الصورة والزوايا */
    display: flex; /* لضمان تنسيق المحتوى الداخلي بشكل سليم */
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* 4. تأثير بسيط عند تمرير الماوس
---------------------------------- */
.post-card:hover {
    transform: translateY(-6px); /* تأثير "رفع" البطاقة */
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08); /* ظل أوضح */
}

/* 5. الرابط الذي يغلف البطاقة
------------------------------ */
.post-card-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%; /* لجعل البطاقة كلها قابلة للضغط */
}

/* 6. تنسيق حاوية الصورة (لضمان أحجام موحدة)
----------------------------------------------- */
.post-card-image {
    width: 100%;
    /* هذا هو السر: تحديد نسبة عرض إلى ارتفاع ثابتة (16:9) */
    aspect-ratio: 16 / 9;
    overflow: hidden; /* لإخفاء أجزاء الصورة الزائدة */
    background-color: #f0f0f0; /* لون للخلفية حال عدم وجود صورة */
}

/* 7. تنسيق الصورة نفسها
------------------------- */
.post-card-image img {
    width: 100%;
    height: 100%;
    /* هذا يضمن ملء الصورة للحاوية دون تشويه (يقص الزوائد) */
    object-fit: cover; 
    display: block;
    transition: transform 0.4s ease-out; /* تأثير للزوم عند الهوفر */
}

/* 8. تأثير زوم بسيط للصورة عند الهوفر
------------------------------------ */
.post-card:hover .post-card-image img {
    transform: scale(1.05); /* تكبير بسيط للصورة */
}

/* 9. تنسيق منطقة المحتوى (العنوان)
------------------------------------ */
.post-card-content {
    padding: 20px 25px; /* حشو مريح للعين */
    /* هذا يضمن أن المحتوى يملأ باقي البطاقة */
    flex-grow: 1; 
    display: flex;
    flex-direction: column;
    justify-content: center; /* توسيط العنوان عمودياً (إذا كان قصيراً) */
}

/* 10. تنسيق العنوان
-------------------- */
.post-card-title {
    font-size: 1.2rem; /* حجم خط مقروء وواضح */
    font-weight: 600; /* خط شبه عريض (Semi-bold) */
    line-height: 1.4;
    color: #222;
    margin: 0;
}

/* ---- نهاية كود التنسيق ---- */

/* --- :root Variables (لإدارة الألوان بسهولة واحترافية) --- */
:root {
  --primary-color: #00796B; /* لون أساسي (أخضر داكن/تيال) */
  --light-bg: #F5F7FA;      /* خلفية فاتحة (بدلاً من الأبيض الصريح) */
  --card-bg: #FFFFFF;        /* خلفية الكروت */
  --text-color: #333;        /* لون النص الأساسي */
  --border-color: #E0E0E0;   /* لون الحدود الخفيف */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 10px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.1);
}

/* --- Global (لضمان تناسق المقاسات) --- */
* {
  box-sizing: border-box;
}

body {
  background-color: var(--light-bg); /* تطبيق خلفية أفتح للموقع */
  font-family: 'Tahoma', 'Arial', sans-serif; /* خط مقترح لتحسين المظهر */
}

/* --- Navigation Menu (شريط التنقل العلوي) --- */
.nav-container {
  display: flex;
  justify-content: center; /* توسط العناصر على الشاشات الكبيرة */
  gap: 1.5rem;
  padding: 1.5rem;
  overflow-x: auto; /* ضروري للتجاوب على الموبايل */
  -webkit-overflow-scrolling: touch; /* لتحسين التمرير على iOS */
  background-color: var(--card-bg);
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  margin: 1.5rem auto;
  max-width: 95%;
}

.nav-item {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  font-size: 1.5rem; /* حجم خط أنسب */
  font-weight: bold;
  color: var(--text-color);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  padding: 1rem;
  border: 1px solid var(--border-color); /* حد أخف */
  border-radius: 10px;
  background-color: var(--card-bg);
  box-shadow: var(--shadow-sm);
  min-width: 160px; /* عرض أدنى لضمان الشكل */
  min-height: 150px;
  text-align: center;
}

.nav-item img {
  width: 7rem; /* تصغير الأيقونة قليلاً */
  height: 7rem;
  margin-bottom: 0.5rem; /* فصل بين الأيقونة والنص */
}

.nav-text {
  direction: rtl;
}

/* --- تأثيرات احترافية للـ Navigation --- */
.nav-item:hover {
  transform: translateY(-5px); /* تأثير "رفع" عند المرور */
  box-shadow: var(--shadow-lg);
  color: var(--primary-color);
}

.nav-item:active {
  transform: translateY(-2px) scale(0.98); /* تأثير ضغط أنعم */
}

/* --- تجاوب شريط التنقل --- */
@media (max-width: 900px) {
  .nav-container {
    justify-content: flex-start; /* السماح بالتمرير الأفقي */
  }
}

/* --- Post Grid (شبكة المقالات) --- */
.container {
  width: 100%;
  max-width: 1400px; /* تحديد عرض أقصى للمحتوى */
  padding-right: 15px;
  padding-left: 15px;
  margin-right: auto;
  margin-left: auto;
}

.row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  margin-right: -15px; /* لضبط المسافات مع الأعمدة */
  margin-left: -15px;
}

/* --- نظام الأعمدة المتجاوب (الأهم) --- */
.col-md-4 {
  position: relative;
  width: 100%;
  padding-right: 15px;
  padding-left: 15px;
  margin-bottom: 30px; /* تم نقل margin هنا بدلاً من الكارد */
  
  /* Mobile-first: 1 column */
  flex: 0 0 100%;
  max-width: 100%;
}

@media (min-width: 768px) {
  /* Tablet: 2 columns */
  .col-md-4 {
    flex: 0 0 50%;
    max-width: 50%;
  }
}

@media (min-width: 992px) {
  /* Desktop: 4 columns (كما كان) */
  .col-md-4 {
    flex: 0 0 25%;
    max-width: 25%;
  }
}

/* --- Card Styling (تصميم الكارت) --- */
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  word-wrap: break-word;
  background-color: var(--card-bg);
  background-clip: border-box;
  border: 1px solid var(--border-color);
  border-radius: 10px; /* زوايا دائرية أكثر */
  box-shadow: var(--shadow-md);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%; /* لضمان تساوي ارتفاع الكروت في نفس الصف */
  overflow: hidden; /* لإخفاء زوائد الصورة عند التكبير */
}

/* --- تأثيرات احترافية للكارت --- */
.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.card-img-top {
  width: 100%;
  height: 200px; /* تحديد ارتفاع ثابت للصورة */
  object-fit: cover; /* لضمان ملء الصورة للمساحة دون تشويه */
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
  transition: transform 0.3s ease; /* إضافة تأثير للصورة */
}

.card:hover .card-img-top {
  transform: scale(1.05); /* تأثير زووم للصورة عند مرور الماوس */
}

.card-body {
  flex: 1 1 auto;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
}

/* --- تحسين SEO (استخدام H3 بدلاً من H5) --- */
.card-title {
  margin: 0.3rem 0;
  flex-grow: 1; /* لدفع المحتوى السفلي (لو وجد) للأسفل */
  text-align: center;
  font-size: 1.4rem; /* حجم خط مناسب للعنوان */
  line-height: 1.4;
}

.card-title a {
  color: var(--text-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.card-title a:hover {
  color: var(--primary-color); /* تغيير لون الرابط عند المرور */
}

/*
=====================================================
--- 23. تنسيق إعلان مفسر الأحلام الجذاب (CTA Banner) ---
=====================================================
*/

.dream-cta-banner {
    background: linear-gradient(135deg, #007791, #20A0B1); /* تدرج تركواز منعش */
    color: #ffffff; 
    padding: 35px 30px; 
    margin: 30px 0; 
    border-radius: 15px; 
    text-align: center;
    position: relative;
    overflow: hidden; 
    box-shadow: 0 10px 25px rgba(0, 119, 145, 0.25); /* ظل بلون قريب من الخلفية */
    border: 1px solid rgba(255, 255, 255, 0.15); 
    
    /* --- 🟡 الإضافة هنا للتوسيط --- */
    max-width: 95%;     /* اجعل أقصى عرض له أقل من 100% بقليل */
    margin-left: auto;  /* هامش تلقائي لليسار */
    margin-right: auto; /* هامش تلقائي لليمين */
    /* --- نهاية الإضافة --- */
}

.dream-cta-banner .cta-icon {
    font-size: 3.5em; 
    color: #FF7F50; /* لون مرجاني (Coral) مشرق */
    margin-bottom: 15px;
    display: block;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.15); 
}

.dream-cta-banner h3 {
    font-family: var(--font-heading); 
    font-size: 1.9em; 
    font-weight: 700;
    margin-bottom: 10px;
    line-height: 1.4;
    color: #ffffff; 
}

.dream-cta-banner p {
    font-size: 1.1em;
    margin-bottom: 25px;
    line-height: 1.7;
    opacity: 0.95; /* شفافية أقل قليلاً */
    max-width: 600px; 
    margin-left: auto;
    margin-right: auto;
    color: #f5f5f5; /* أبيض دافئ قليلاً */
}

.dream-cta-banner .cta-button {
    display: inline-block;
    background-color: #FF7F50; /* لون مرجاني مشرق */
    color: #004050; /* لون تركواز داكن جداً للنص */
    padding: 14px 30px;
    border-radius: 50px; 
    text-decoration: none;
    font-family: var(--font-primary);
    font-size: 1.15em;
    font-weight: 700;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94); 
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15); 
    border: none;
}

.dream-cta-banner .cta-button .cta-arrow {
    margin-right: 8px; 
    transition: transform 0.3s ease;
    display: inline-block; 
}

.dream-cta-banner .cta-button:hover {
    background-color: #ff9a75; /* درجة أفتح من المرجاني */
    color: #002d38; /* أغمق */
    transform: translateY(-3px) scale(1.03); 
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2); 
}

.dream-cta-banner .cta-button:hover .cta-arrow {
    transform: translateX(-4px); 
}
/* تحسينات للشاشات الصغيرة (الموبايل) */
@media (max-width: 600px) {
    .dream-cta-banner {
        padding: 25px 20px;
        margin: 20px 0;
    }
    .dream-cta-banner .cta-icon {
        font-size: 3em;
    }
    .dream-cta-banner h3 {
        font-size: 1.6em;
    }
    .dream-cta-banner p {
        font-size: 1em;
    }
    .dream-cta-banner .cta-button {
        padding: 12px 25px;
        font-size: 1.05em;
    }
}

/*
=====================================================
--- 24. تنسيق إعلانات CTA أسفل المحتوى ---
=====================================================
*/

.end-content-cta {
    color: #ffffff; /* لون نص افتراضي أبيض */
    padding: 30px 25px; 
    margin: 40px auto; /* هامش أعلى/أسفل وتوسيط */
    border-radius: 12px; 
    text-align: center;
    position: relative;
    overflow: hidden; 
    max-width: 95%; /* تحديد عرض أقصى */
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15); /* ظل بارز */
    border: 1px solid rgba(255, 255, 255, 0.1); 
}

/* أيقونة الإعلان */
.end-content-cta .cta-icon {
    font-size: 2.8em; 
    margin-bottom: 12px;
    display: block;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); 
}

/* عنوان الإعلان */
.end-content-cta .cta-heading {
    font-family: var(--font-heading, 'Amiri', serif); /* استخدام خط القالب أو خط Amiri */
    font-size: 1.7em; 
    font-weight: 700;
    margin-bottom: 8px;
    line-height: 1.4;
    color: inherit; /* يرث اللون من الحاوية الرئيسية */
}

/* نص الإعلان */
.end-content-cta .cta-text {
    font-size: 1.05em;
    margin-bottom: 20px;
    line-height: 1.6;
    opacity: 0.9; 
    max-width: 550px; 
    margin-left: auto;
    margin-right: auto;
    color: inherit; /* يرث اللون */
}

/* زر الإعلان */
.end-content-cta .cta-button {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 50px; 
    text-decoration: none;
    font-family: var(--font-primary, 'Tajawal', sans-serif); /* استخدام خط القالب أو Tajawal */
    font-size: 1.1em;
    font-weight: 700;
    transition: all 0.3s ease; 
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); 
    border: none;
}
.end-content-cta .cta-button i {
    margin-right: 6px; 
    transition: transform 0.3s ease;
    display: inline-block; 
}

.end-content-cta .cta-button:hover {
    transform: translateY(-3px); 
    box-shadow: 0 7px 18px rgba(0, 0, 0, 0.18); 
}
.end-content-cta .cta-button:hover i {
    transform: translateX(-4px); 
}

/* --- ستايلات لونية مختلفة --- */

/* ستايل 1: أزرق وذهبي (مثل تصميمك) */
.end-content-cta.cta-style-1 {
    background: linear-gradient(135deg, var(--color-primary, #005a78), #007a9e);
    color: #ffffff;
}
.end-content-cta.cta-style-1 .cta-icon { color: var(--color-accent, #d4af37); }
.end-content-cta.cta-style-1 .cta-button {
    background-color: var(--color-accent, #d4af37);
    color: var(--color-primary, #005a78);
}
.end-content-cta.cta-style-1 .cta-button:hover { background-color: #e7c04e; }

/* ستايل 2: تركواز ومرجاني */
.end-content-cta.cta-style-2 {
    background: linear-gradient(135deg, #007791, #20A0B1);
    color: #ffffff;
}
.end-content-cta.cta-style-2 .cta-icon { color: #FF7F50; }
.end-content-cta.cta-style-2 .cta-button {
    background-color: #FF7F50;
    color: #004050;
}
.end-content-cta.cta-style-2 .cta-button:hover { background-color: #ff9a75; }

/* ستايل 3: بنفسجي وذهبي */
.end-content-cta.cta-style-3 {
    background: linear-gradient(135deg, #4B0082, #8A2BE2);
    color: #ffffff;
}
.end-content-cta.cta-style-3 .cta-icon { color: var(--color-accent, #d4af37); }
.end-content-cta.cta-style-3 .cta-button {
    background-color: var(--color-accent, #d4af37);
    color: #4B0082;
}
.end-content-cta.cta-style-3 .cta-button:hover { background-color: #e7c04e; }

/* ستايل 4: غروب الشمس (برتقالي/أصفر) */
.end-content-cta.cta-style-4 {
    background: linear-gradient(135deg, #FF8C00, #FFB347);
    color: var(--color-primary, #005a78); /* نص داكن */
}
.end-content-cta.cta-style-4 .cta-icon { color: #ffffff; } /* أيقونة بيضاء */
.end-content-cta.cta-style-4 .cta-heading { color: #003d50; }
.end-content-cta.cta-style-4 .cta-button {
    background-color: var(--color-primary, #005a78);
    color: #ffffff;
}
.end-content-cta.cta-style-4 .cta-button:hover { background-color: #004058; }


/* تحسين للموبايل */
@media (max-width: 600px) {
    .end-content-cta {
        padding: 25px 20px;
        margin: 30px auto; 
        max-width: 100%;
    }
    .end-content-cta .cta-icon { font-size: 2.5em; }
    .end-content-cta .cta-heading { font-size: 1.5em; }
    .end-content-cta .cta-text { font-size: 1em; }
    .end-content-cta .cta-button { padding: 11px 24px; font-size: 1em; }
}