/* ==========================================================================
   ALMADEENA COMMON COMPONENTS STYLESHEET
   Separated CSS Architecture for Backend-Connected Front-End Sections
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Latest Updates & Announcements Component
   -------------------------------------------------------------------------- */
.news-card-horizontal {
    display: flex;
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    border: 1px solid #f1f5f9;
}

.news-card-horizontal:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.news-card-img {
    width: 140px;
    min-width: 140px;
    height: 100%;
    min-height: 120px;
    object-fit: cover;
}

.news-card-body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
}

.news-card-title {
    font-size: 1.05rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.4;
    margin-bottom: 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.85rem;
    margin-top: auto;
}

.news-read-more {
    color: #64748b;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s ease;
}

.news-card-horizontal:hover .news-read-more {
    color: #059669;
}

.news-date {
    color: #94a3b8;
    font-size: 0.82rem;
    font-weight: 500;
}

/* --------------------------------------------------------------------------
   2. Campus Life Scroll Gallery Component
   -------------------------------------------------------------------------- */
.scroll-gallery-wrapper {
    display: flex;
    gap: 1.25rem;
    height: 520px;
    overflow: hidden;
    position: relative;
    padding: 1rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(10px);
    border: 1px solid #e2e8f0;
}

.scroll-gallery-wrapper::before,
.scroll-gallery-wrapper::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    height: 60px;
    z-index: 2;
    pointer-events: none;
}

.scroll-gallery-wrapper::before {
    top: 0;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.9), transparent);
}

.scroll-gallery-wrapper::after {
    bottom: 0;
    background: linear-gradient(to top, rgba(255, 255, 255, 0.9), transparent);
}

.scroll-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    height: 100%;
    position: relative;
}

.scroll-track {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    animation: scrollUp 28s linear infinite;
}

.scroll-column.reverse .scroll-track {
    animation: scrollDown 28s linear infinite;
}

.scroll-gallery-wrapper:hover .scroll-track {
    animation-play-state: paused;
}

.scroll-img-card {
    width: 100%;
    height: 220px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    flex-shrink: 0;
    position: relative;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

.scroll-img-card:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.scroll-img-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

@keyframes scrollUp {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(-50%);
    }
}

@keyframes scrollDown {
    0% {
        transform: translateY(-50%);
    }
    100% {
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .scroll-gallery-wrapper {
        height: 420px;
        gap: 0.75rem;
        padding: 0.5rem;
    }
    .scroll-img-card {
        height: 160px;
    }
}

/* --------------------------------------------------------------------------
   3. Social Upliftment Card Styles
   -------------------------------------------------------------------------- */
.social-card-slide {
    position: relative;
    height: 380px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
    transition: transform 0.35s ease, box-shadow 0.35s ease;
    background: #0f172a;
    display: block;
    text-decoration: none !important;
}

.social-card-slide:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.15);
}

.social-card-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.social-card-slide:hover img {
    transform: scale(1.06);
}

.social-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem 1.5rem 1.5rem 1.5rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.5) 65%, transparent 100%);
    color: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.social-overlay h4 {
    font-size: 1.35rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.4rem;
    line-height: 1.3;
}

.social-overlay p {
    font-size: 0.88rem;
    color: #e2e8f0;
    margin-bottom: 0;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* --------------------------------------------------------------------------
   4. Gallery Album Details Lightbox Item Styles
   -------------------------------------------------------------------------- */
.album-photo-item {
    position: relative;
    height: 240px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    margin-bottom: 25px;
    cursor: pointer;
}

.album-photo-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.album-photo-item:hover img {
    transform: scale(1.08);
}

.album-photo-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 91, 102, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.album-photo-item:hover .album-photo-overlay {
    opacity: 1;
}

.zoom-icon {
    width: 48px;
    height: 48px;
    background: #ffffff;
    color: #005b66;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* --------------------------------------------------------------------------
   5. Career Job Openings & Application Modal Styles
   -------------------------------------------------------------------------- */
.job-opening-card {
    border: 1px solid #e2e8f0;
    border-left: 4px solid #059669;
    border-radius: 12px;
    padding: 1.5rem;
    background: #ffffff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.job-opening-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
    border-color: #cbd5e1;
}

.job-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.35rem;
}

.job-meta {
    font-size: 0.85rem;
    color: #059669;
    font-weight: 600;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.job-desc {
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.5;
    margin-bottom: 1rem;
}

.job-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid #f1f5f9;
}

/* Modal Popup Styles */
.career-modal-backdrop {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(4px);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    overflow-y: auto;
}

.career-modal-backdrop.active {
    display: flex;
    animation: fadeInModal 0.25s ease forwards;
}

.career-modal-box {
    background: #ffffff;
    border-radius: 16px;
    max-width: 650px;
    width: 100%;
    padding: 2rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
    position: relative;
    transform: scale(0.95);
    transition: transform 0.25s ease;
    max-height: 90vh;
    overflow-y: auto;
}

.career-modal-backdrop.active .career-modal-box {
    transform: scale(1);
}

.career-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 1rem;
    margin-bottom: 1.25rem;
    border-bottom: 1px solid #e2e8f0;
}

.career-modal-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
}

.career-modal-close {
    background: #f1f5f9;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s ease;
}

.career-modal-close:hover {
    background: #e2e8f0;
    color: #0f172a;
}

@keyframes fadeInModal {
    from { opacity: 0; }
    to { opacity: 1; }
}

