/* assets/css/stories.css */

/* ==============================================
   STORIES & UPDATES PAGE STYLES
   ============================================== */

/* --- Stories Hero Section --- */
/* ==============================================
   STORIES & UPDATES PAGE STYLES
   ============================================== */

/* --- Stories Banner Section (UPDATED) --- */
.stories-banner-section {
    width: 100%;
    background-color: #1a3a5c; /* Fallback color */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.stories-banner-section img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain; /* Ensures the full image is visible without cropping */
    object-position: center;
}

/* --- Stories Listing Section --- */
.stories-listing-section {
    padding: 70px 0;
    background-color: #f8fbf9;
}
/* --- Stories Listing Section --- */
.stories-listing-section {
    padding: 70px 0;
    background-color: #f8fbf9;
}

.stories-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 50px;
}

/* --- Story Card --- */
.story-card {
    background: #ffffff;
    border: 1px solid #e8e8e8;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.story-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 18px 35px rgba(0, 0, 0, 0.1);
    border-color: #d4e8d9;
}

.story-card-link {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    text-decoration: none;
    color: inherit;
}

/* --- Story Card Image --- */
.story-card-image {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    background-color: #e8f5e9;
}

.story-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.story-card:hover .story-card-image img {
    transform: scale(1.05);
}

.story-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, #e8f5e9 0%, #d4e8d9 100%);
    color: #2e8b57;
    font-size: 3rem;
}

/* Category Badge */
.story-category {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: #2e8b57;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    z-index: 2;
}

/* --- Story Card Content --- */
.story-card-content {
    padding: 25px 25px 30px 25px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.story-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    font-size: 0.8rem;
    color: #888888;
    margin-bottom: 12px;
}

.story-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.story-meta i {
    color: #2e8b57;
}

.story-card-content h3 {
    font-size: 1.2rem;
    color: #1a3a5c;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 12px;
    flex-grow: 0;
}

.story-card-content p {
    font-size: 0.9rem;
    color: #666666;
    line-height: 1.6;
    margin-bottom: 20px;
    flex-grow: 1;
}

.story-read-more {
    font-size: 0.9rem;
    font-weight: 600;
    color: #2e8b57;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: gap 0.3s ease;
}

.story-card:hover .story-read-more {
    gap: 12px;
}

.story-read-more i {
    font-size: 0.8rem;
}

/* --- No Stories Message --- */
.no-stories {
    text-align: center;
    padding: 80px 20px;
    background: #ffffff;
    border-radius: 16px;
    border: 1px dashed #d4e8d9;
}

.no-stories i {
    font-size: 3rem;
    color: #2e8b57;
    margin-bottom: 20px;
    opacity: 0.5;
}

.no-stories h3 {
    font-size: 1.5rem;
    color: #1a3a5c;
    margin-bottom: 10px;
}

.no-stories p {
    color: #666666;
}

/* --- Pagination --- */
.stories-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.page-numbers {
    display: flex;
    gap: 8px;
}

.page-num {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background-color: #ffffff;
    border: 1px solid #e0ece6;
    color: #1a3a5c;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.page-num:hover {
    background-color: #e8f5e9;
    border-color: #2e8b57;
    color: #2e8b57;
}

.page-num.active {
    background-color: #2e8b57;
    border-color: #2e8b57;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(46, 139, 87, 0.3);
}

.page-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 22px;
    border-radius: 50px;
    background-color: #ffffff;
    border: 1px solid #e0ece6;
    color: #1a3a5c;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.page-btn:hover {
    background-color: #2e8b57;
    border-color: #2e8b57;
    color: #ffffff;
}

.page-btn i {
    font-size: 0.75rem;
}

/* ==============================================
   RESPONSIVE DESIGN
   ============================================== */

/* --- Tablet (768px to 991px) --- */
@media (max-width: 991px) {
    .stories-hero-section h1 {
        font-size: 2.2rem;
    }
    .stories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
}

/* --- Mobile (up to 767px) --- */
@media (max-width: 767px) {
    .stories-hero-section {
        padding: 50px 0;
    }
    .stories-hero-section h1 {
        font-size: 1.8rem;
    }
    .stories-hero-section p {
        font-size: 0.95rem;
    }
    .stories-listing-section {
        padding: 40px 0;
    }
    .stories-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-bottom: 35px;
    }
    .story-card-image {
        height: 180px;
    }
    .story-card-content {
        padding: 20px;
    }
    .story-card-content h3 {
        font-size: 1.1rem;
    }
    .story-card-content p {
        font-size: 0.85rem;
    }
    .stories-pagination {
        gap: 12px;
    }
    .page-btn {
        padding: 8px 16px;
        font-size: 0.85rem;
    }
    .page-num {
        width: 38px;
        height: 38px;
        font-size: 0.9rem;
    }
}

/* --- Small Mobile (up to 480px) --- */
@media (max-width: 480px) {
    .stories-hero-section h1 {
        font-size: 1.5rem;
    }
    .stories-hero-section p {
        font-size: 0.85rem;
    }
    .story-category {
        font-size: 0.7rem;
        padding: 5px 12px;
    }
    .story-meta {
        font-size: 0.75rem;
        gap: 10px;
    }
    .page-numbers {
        gap: 5px;
    }
    .page-num {
        width: 34px;
        height: 34px;
        font-size: 0.8rem;
    }
    .page-btn {
        font-size: 0.8rem;
        padding: 7px 14px;
    }
}