.recipe-modal{
    display:none;
    position:fixed;
    top:0;
    left:0;
    width:100%;
    height:100%;
    background:rgba(0,0,0,.7);
    justify-content:center;
    align-items:center;
    z-index:999;
    }
    
    .modal-content{
    background:white;
    width:600px;
    max-width:90%;
    border-radius:10px;
    padding:20px;
    }
    
    .close-modal{
    float:left;
    font-size:22px;
    cursor:pointer;
    }
    
    .modal-content img{
    width:100%;
    border-radius:8px;
    margin-bottom:10px;
    }
    
    .modal-social a{
    margin-left:10px;
    font-size:20px;
    color:#333;
    }

/* تنسيقات النافذة المنبثقة */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.6);
    overflow-y: auto;
}

.modal-content {
    background-color: #fff;
    margin: 5% auto;
    padding: 20px;
    border-radius: 15px;
    width: 90%;
    max-width: 600px;
    position: relative;
    animation: modalFadeIn 0.3s;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: translateY(-30px); }
    to { opacity: 1; transform: translateY(0); }
}

.close-modal {
    position: absolute;
    left: 20px;
    top: 15px;
    font-size: 28px;
    font-weight: bold;
    color: #888;
    cursor: pointer;
    transition: color 0.2s;
}

.close-modal:hover {
    color: #000;
}

.modal-body {
    margin-top: 20px;
}

.modal-body img {
    margin-bottom: 15px;
}

.modal-body ul {
    list-style-type: disc;
    padding-right: 20px;
    margin-bottom: 15px;
}

.author-info {
    border-top: 1px solid #eee;
    padding-top: 15px;
    margin-top: 15px;
}

.video-container {
    margin: 15px 0;
    position: relative;
    padding-bottom: 56.25%; /* نسبة 16:9 */
    height: 0;
    overflow: hidden;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 8px;
}

/* تحسين استجابة البطاقات */
.card {
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}



/* تحسين عرض المقادير وطريقة التحضير داخل modal */
.ingredients-list {
    list-style-type: circle;
    padding-right: 20px;
    margin-bottom: 15px;
    columns: 2; /* عرض القائمة على عمودين لتوفير المسافة */
    column-gap: 30px;
}

.ingredients-list li {
    margin-bottom: 5px;
    font-size: 0.95rem;
}

.method-text {
    line-height: 1.7;
    background-color: #f9f9f9;
    padding: 10px 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    white-space: pre-line; /* يحافظ على فواصل الأسطر */
}



/* أزرار التصفية */
.filter-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0 0;
    padding: 0 5%;
    flex-wrap: wrap;
}

.filter-btn {
    background-color: white;
    border: 2px solid #e622bc;
    color: #a11b96;
    padding: 0.6rem 1.8rem;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Tajawal', sans-serif;
}

.filter-btn:hover,
.filter-btn.active {
    background-color: #e67e22;
    color: white;
}

/* تحديث ألوان شارات الحميات (موجودة سابقاً ولكن للتأكيد) */
.card-badge.diet-modern {
    background-color: #27ae60;
}

.card-badge.diet-traditional {
    background-color: #c0392b;
}

