/* أنماط البطاقات المخصصة */
.custom-cards-container {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 20px;
    margin: 40px 0;
    padding: 60px 20px 80px 20px;
    direction: rtl;
}

/* تخطيط الأعمدة */
.custom-cards-container[data-columns="1"] {
    justify-content: center;
}

.custom-cards-container[data-columns="2"] {
    justify-content: center;
}

.custom-cards-container[data-columns="3"] {
    justify-content: center;
}

.custom-cards-container[data-columns="4"] {
    justify-content: center;
}

/* تجاوب مع الشاشات الصغيرة */
@media (max-width: 768px) {
    .custom-cards-container {
        flex-direction: column;
        align-items: center;
        padding: 40px 20px 60px 20px;
    }

    .custom-card.featured {
        transform: scale(1.02) translateY(-15px);
        margin: 15px 0 25px 0;
    }

    .custom-card.featured:hover {
        transform: scale(1.02) translateY(-20px);
    }
}

@media (max-width: 480px) {
    .custom-cards-container {
        flex-direction: column;
        align-items: center;
        gap: 15px;
        padding: 30px 15px 40px 15px;
    }

    .custom-card.featured {
        transform: scale(1.01) translateY(-10px);
        margin: 10px 0 20px 0;
        min-height: 480px;
    }

    .custom-card.featured:hover {
        transform: scale(1.01) translateY(-15px);
    }

    .custom-card.featured::before {
        font-size: 0.8em;
        padding: 6px 15px;
        top: -12px;
    }
}

/* أنماط البطاقة الفردية */
.custom-card {
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    position: relative;
    width: 380px;
    min-height: 450px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

/* البطاقة المميزة (الوسطى) */
.custom-card.featured {
    transform: scale(1.05) translateY(-30px);
    z-index: 2;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    min-height: 520px;
    margin: 30px 0 50px 0;
}

.custom-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2) !important;
}

.custom-card.featured:hover {
    transform: scale(1.05) translateY(-35px);
}

/* رأس البطاقة */
.card-header {
    padding: 25px 20px;
    text-align: center;
    color: white;
    position: relative;
}

.card-header.starter {
    background: linear-gradient(135deg, #c0756b, #a85751);
}

.card-header.professional {
    background: linear-gradient(135deg, #4ecdc4, #44a08d);
}

.card-header.premium {
    background: linear-gradient(135deg, #56c596, #4a9d7a);
}

/* عنوان البطاقة */
.card-title {
    margin: 0 0 10px 0;
    font-size: 2em;
    font-weight: bold;
    color: white;
}

/* السعر */
.card-price {
    font-size: 2.2em;
    font-weight: bold;
    margin: 10px 0;
    color: white;
}

.card-price .currency {
    font-size: 0.6em;
    vertical-align: top;
}

.card-price .period {
    font-size: 0.4em;
    font-weight: normal;
    opacity: 0.9;
}

/* وصف السعر */
.card-price-description {
    font-size: 0.9em;
    opacity: 0.9;
    margin-bottom: 15px;
}

/* جسم البطاقة */
.card-body {
    padding: 35px 25px;
    flex-grow: 1;
    background: #f8f9fa;
    display: flex;
    flex-direction: column;
}

/* قائمة المميزات */
.card-features {
    list-style: none;
    padding: 0;
    margin: 20px 0 30px 0;
    flex-grow: 1;
}

.card-features li {
    padding: 8px 0;
    font-size: 0.95em;
    color: #666;
    position: relative;
    padding-right: 25px;
}

.card-features li:before {
    content: "✓";
    position: absolute;
    right: 0;
    color: #28a745;
    font-weight: bold;
    font-size: 1.1em;
}

/* زر البطاقة */
.card-button {
    display: block;
    width: 100%;
    padding: 15px 20px;
    background: #007cba;
    color: white;
    text-decoration: none;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
    font-size: 1em;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    margin-top: auto;
}

.card-button:hover {
    background: #005a87;
    transform: translateY(-2px);
    text-decoration: none;
    color: white;
}

.card-button.starter {
    background: #c0756b;
}

.card-button.starter:hover {
    background: #a85751;
}

.card-button.professional {
    background: #4ecdc4;
}

.card-button.professional:hover {
    background: #44a08d;
}

.card-button.premium {
    background: #56c596;
}

.card-button.premium:hover {
    background: #4a9d7a;
}

/* حركات الظهور */
.custom-card {
    opacity: 0;
    animation-fill-mode: forwards;
}

.custom-card.animate-fadeIn {
    animation: fadeIn 0.6s ease forwards;
}

.custom-card.animate-slideUp {
    animation: slideUp 0.6s ease forwards;
}

.custom-card.animate-zoomIn {
    animation: zoomIn 0.6s ease forwards;
}

/* تأخير الحركة للبطاقات المتعددة */
.custom-card:nth-child(1) {
    animation-delay: 0.1s;
}

.custom-card:nth-child(2) {
    animation-delay: 0.2s;
}

.custom-card:nth-child(3) {
    animation-delay: 0.3s;
}

.custom-card:nth-child(4) {
    animation-delay: 0.4s;
}

.custom-card:nth-child(5) {
    animation-delay: 0.5s;
}

.custom-card:nth-child(6) {
    animation-delay: 0.6s;
}

/* تعريف الحركات */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* عنوان الصفحة */
.cards-page-title {
    text-align: center;
    font-size: 2em;
    color: #333;
    margin-bottom: 40px;
    font-weight: bold;
}

/* أنماط RTL */
.rtl .custom-cards-container {
    direction: rtl;
}



/* عنوان البطاقات */
.cards-section-title {
    text-align: center;
    font-size: 2.2em;
    color: #333;
    margin: 40px 0;
    font-weight: bold;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* حاوي البطاقات مع العنوان */
.custom-cards-wrapper {
    margin: 40px 0;
}

/* تحسينات للتطابق مع الصورة */
.card-features li {
    border-bottom: 1px solid #eee;
    padding: 15px 15px;
    margin-bottom: 5px;
}

.card-features li:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.card-features li:before {
    content: "✓";
    position: absolute;
    right: 0;
    color: #28a745;
    font-weight: bold;
    font-size: 1.2em;
    top: 15px;
}

/* تحسين الخطوط */
.custom-card {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.card-price {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* تأثيرات إضافية */
.custom-card {
    will-change: transform;
}

.custom-card:hover .card-button {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* تحسينات إضافية للبطاقة المميزة */
.custom-card.featured {
    border: 2px solid rgba(255, 215, 0, 0.3);
    position: relative;
}

.custom-card.featured::before {
    content: "الأكثر شعبية";
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #ffd700, #ffb347);
    color: #333;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: bold;
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.3);
    z-index: 3;
}

/* تحسين المسافات للبطاقة المميزة */
.custom-card.featured .card-header {
    padding: 30px 25px;
}

.custom-card.featured .card-body {
    padding: 40px 30px;
}

/* تحسينات المسافات */
.card-header {
    margin-bottom: 0;
}

.card-body {
    margin-top: 0;
}

/* مسافة إضافية بين العناصر */
.card-features li {
    line-height: 1.5;
}

/* تحسين المسافة بين السعر ووصفه */
.card-price {
    margin-bottom: 15px;
}