/* ========================================
   YDA Programs Section - Modern Design
   Youth Development Association
   ======================================== */

/* ===== Section Container ===== */
.yda-programs-section {
    padding: 5rem 0;
    background: linear-gradient(135deg, #F2F2F2 0%, #FFF9F0 100%);
    position: relative;
    overflow: hidden;
}

/* Background Pattern */
.yda-programs-bg-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(108, 180, 77, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(245, 195, 0, 0.03) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.yda-programs-section .container {
    position: relative;
    z-index: 1;
}

/* ===== Section Header ===== */
.yda-section-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #6CB44D, #7EC45E);
    color: white;
    padding: 0.5rem 1.5rem;
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 12px rgba(108, 180, 77, 0.2);
}

.yda-section-badge i {
    font-size: 1rem;
}

.yda-title-decoration {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin: 1rem 0 1.5rem;
    font-size: 1.5rem;
}

.yda-title-decoration .olive-leaf {
    animation: sway 3s ease-in-out infinite;
}

.yda-title-decoration .sun-icon {
    color: #F5C300;
    animation: rotate-sun 20s linear infinite;
    filter: drop-shadow(0 0 8px rgba(245, 195, 0, 0.4));
}

@keyframes sway {
    0%, 100% { transform: rotate(-5deg); }
    50% { transform: rotate(5deg); }
}

@keyframes rotate-sun {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ===== Program Card ===== */
.yda-program-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.yda-program-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 12px 40px rgba(108, 180, 77, 0.2);
}

/* Image Wrapper */
.yda-program-image-wrapper {
    position: relative;
    height: 280px;
    overflow: hidden;
}

.yda-program-image {
    width: 100%;
    height: 100%;
    position: relative;
}

.yda-program-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.yda-program-card:hover .yda-program-image img {
    transform: scale(1.1);
}

.yda-program-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        to bottom,
        rgba(108, 180, 77, 0.1) 0%,
        rgba(108, 180, 77, 0.4) 100%
    );
    opacity: 0.6;
    transition: opacity 0.4s ease;
}

.yda-program-card:hover .yda-program-overlay {
    opacity: 0.8;
}

/* Category Badge */
.yda-program-category {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: rgba(245, 195, 0, 0.95);
    color: #222222;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.813rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(10px);
    z-index: 2;
}

[dir="rtl"] .yda-program-category {
    left: auto;
    right: 1rem;
}

/* Featured Badge */
.yda-program-featured {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: linear-gradient(135deg, #FFD633, #F5C300);
    color: #222222;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.125rem;
    box-shadow: 0 4px 12px rgba(245, 195, 0, 0.4);
    animation: pulse-star 2s ease-in-out infinite;
    z-index: 2;
}

[dir="rtl"] .yda-program-featured {
    right: auto;
    left: 1rem;
}

@keyframes pulse-star {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Year Badge */
.yda-program-year {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.95);
    color: #6CB44D;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    z-index: 2;
}

[dir="rtl"] .yda-program-year {
    right: auto;
    left: 1rem;
}

/* Content Section */
.yda-program-content {
    padding: 1.25rem 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
    min-height: 80px;
}

/* Program Title Link */
.yda-program-title-link {
    text-decoration: none;
    width: 100%;
    display: block;
    transition: all 0.3s ease;
}

.yda-program-title-link:hover {
    transform: scale(1.02);
}

/* Program Title */
.yda-program-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #6CB44D;
    margin: 0;
    line-height: 1.5;
    transition: all 0.3s ease;
    position: relative;
    display: inline-block;
}

.yda-program-title::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 60%;
    height: 3px;
    background: linear-gradient(90deg, #F5C300, #FFD633);
    border-radius: 2px;
    transition: transform 0.3s ease;
}

.yda-program-card:hover .yda-program-title {
    color: #F5C300;
}

.yda-program-card:hover .yda-program-title::after {
    transform: translateX(-50%) scaleX(1);
}

/* Decorative Corner */
.yda-program-corner {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, transparent 50%, rgba(245, 195, 0, 0.1) 50%);
    border-radius: 20px 0 20px 0;
    pointer-events: none;
}

[dir="rtl"] .yda-program-corner {
    right: auto;
    left: 0;
    background: linear-gradient(225deg, transparent 50%, rgba(245, 195, 0, 0.1) 50%);
    border-radius: 0 20px 0 20px;
}

/* ===== Responsive Design ===== */
@media (max-width: 991px) {
    .yda-programs-section {
        padding: 4rem 0;
    }
    
    .yda-program-image-wrapper {
        height: 260px;
    }
    
    .yda-program-content {
        padding: 1.125rem 1.5rem;
        min-height: 75px;
    }
    
    .yda-program-title {
        font-size: 1.2rem;
    }
}

@media (max-width: 767px) {
    .yda-programs-section {
        padding: 3rem 0;
    }
    
    .yda-section-badge {
        font-size: 0.813rem;
        padding: 0.4rem 1.25rem;
    }
    
    .yda-title-decoration {
        font-size: 1.25rem;
        gap: 0.75rem;
    }
    
    .yda-program-image-wrapper {
        height: 240px;
    }
    
    .yda-program-content {
        padding: 1rem 1.25rem;
        min-height: 70px;
    }
    
    .yda-program-title {
        font-size: 1.125rem;
    }
    
    .yda-program-category {
        font-size: 0.75rem;
        padding: 0.4rem 0.875rem;
    }
    
    .yda-program-featured {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }
    
    .yda-program-year {
        font-size: 0.813rem;
        padding: 0.4rem 0.875rem;
    }
}

@media (max-width: 575px) {
    .yda-program-card:hover {
        transform: translateY(-6px);
    }
    
    .yda-program-corner {
        width: 60px;
        height: 60px;
    }
}

/* ===== Animation on Scroll ===== */
[data-animate] {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

[data-animate].animated {
    opacity: 1;
    transform: translateY(0);
}

/* ===== Accessibility ===== */
@media (prefers-reduced-motion: reduce) {
    .yda-program-card,
    .yda-program-image img,
    .yda-program-btn,
    .yda-program-icon,
    .olive-leaf,
    .sun-icon {
        animation: none !important;
        transition: none !important;
    }
}

/* ===== Print Styles ===== */
@media print {
    .yda-programs-section {
        background: white;
    }
    
    .yda-program-card {
        box-shadow: none;
        border: 1px solid #ddd;
        page-break-inside: avoid;
    }
    
    .yda-program-btn {
        display: none;
    }
}
