/* ============================================
   NEWS MAIN PAGE (_news.main.php)
   ============================================ */

/* Container */
.news-navigation-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.news-page-title {
    font-size: 36px;
    font-weight: 800;
    color: #1B8540;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.news-page-subtitle {
    font-size: 16px;
    color: #666;
    margin-bottom: 40px;
}

/* Section 1: Featured News */
.featured-news-section {
    margin-bottom: 60px;
}

.featured-news-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    margin-bottom: 30px;
    transition: transform 0.3s ease;
}

.featured-news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(27,133,64,0.15);
}

.featured-news-image {
    position: relative;
    overflow: hidden;
    min-height: 350px;
}

.featured-news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.featured-news-card:hover .featured-news-image img {
    transform: scale(1.05);
}

.featured-news-content {
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.featured-news-badge {
    display: inline-block;
    background: linear-gradient(135deg, #1B8540 0%, #148036 100%);
    color: #fff;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
    width: fit-content;
}

.featured-news-title {
    font-size: 28px;
    font-weight: 700;
    color: #222;
    margin-bottom: 15px;
    line-height: 1.3;
}

.featured-news-excerpt {
    font-size: 15px;
    color: #555;
    line-height: 1.7;
    margin-bottom: 20px;
    max-height: 100px;
    overflow: hidden;
}

.featured-news-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    font-size: 14px;
    color: #888;
}

.featured-news-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #1B8540 0%, #148036 100%);
    color: #fff;
    padding: 12px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    width: fit-content;
}

.featured-news-link:hover {
    background: linear-gradient(135deg, #148036 0%, #0f6029 100%);
    transform: translateX(5px);
}

/* Section 2: All News Grid */
.all-news-section {
}

.section-title {
    font-size: 28px;
    font-weight: 800;
    color: #222;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 3px solid #1B8540;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 30px;
}

.news-card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.news-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(27,133,64,0.2);
}

.news-card-image {
    position: relative;
    height: 220px;
    overflow: hidden;
    background: #f0f0f0;
}

.news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-card:hover .news-card-image img {
    transform: scale(1.1);
}

.news-card-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(27,133,64,0.95);
    color: #fff;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.news-card-content {
    padding: 20px;
}

.news-card-title {
    font-size: 18px;
    font-weight: 700;
    color: #222;
    margin-bottom: 12px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-excerpt {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.news-card-date {
    font-size: 13px;
    color: #888;
}

.news-card-link {
    color: #1B8540;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: gap 0.3s ease;
}

.news-card-link:hover {
    gap: 10px;
}

/* Responsive - News Main Page */
@media (max-width: 768px) {
    .featured-news-card {
        grid-template-columns: 1fr;
    }
    .featured-news-image {
        min-height: 250px;
    }
    .news-grid {
        grid-template-columns: 1fr;
    }
    .news-navigation-container {
        padding: 20px 15px;
    }
    .news-page-title {
        font-size: 28px;
    }
}


/* ============================================
   NEWS DETAIL PAGE (_news.detail.php)
   ============================================ */

/* Section 1: Hero Section */
.news-detail-hero {
    position: relative;
    min-height: 400px;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    padding: 60px 0 100px;
    margin: 0 -20px;
    width: calc(100% + 40px);
}

.news-detail-hero-bg {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-position: center;
    background-size: cover;
    opacity: 0.12;
    z-index: 1;
}

.news-detail-container {
    max-width: 1160px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 10;
    padding: 0 20px;
    box-sizing: border-box;
}

.news-back-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255,255,255,0.25);
    padding: 12px 24px;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    text-decoration: none;
    margin-bottom: 30px;
    font-size: 1rem;
}

.news-back-btn:hover {
    background: rgba(255,255,255,0.25);
    border-color: rgba(255,255,255,0.4);
    transform: translateX(-5px);
}

.news-title-section h1 {
    font-size: 2.8rem;
    font-weight: 800;
    line-height: 1.2;
    margin: 0 0 25px 0;
    color: #ffffff;
    text-shadow: 2px 4px 12px rgba(0,0,0,0.3);
}

.news-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 0.95rem;
}

.news-meta-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(10px);
    padding: 12px 24px;
    border-radius: 8px;
    border: none;
    color: #2c3e50;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    font-size: 0.9rem;
}

.news-meta-icon {
    font-size: 1.1rem;
    opacity: 0.8;
}

/* Section 2: Content Section */
.news-content-wrapper {
    max-width: 1160px;
    margin: -80px auto 60px;
    position: relative;
    z-index: 20;
    padding: 0 20px;
    box-sizing: border-box;
}

.news-content-card {
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 10px 50px rgba(0,0,0,0.15);
    overflow: hidden;
}

.news-thumbnail {
    width: 100%;
    height: 500px;
    object-fit: cover;
    display: block;
}

.news-content-body {
    padding: 50px 60px 60px;
    box-sizing: border-box;
}

.news-caption {
    text-align: center;
    font-style: italic;
    color: #666;
    margin-top: -20px;
    margin-bottom: 40px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.news-content-text {
    font-size: 1.1rem;
    line-height: 1.9;
    color: #2c3e50;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.news-content-text p {
    margin-bottom: 1.5rem;
}

.news-content-text img {
    max-width: 100% !important;
    width: auto !important;
    height: auto !important;
    border-radius: 12px;
    margin: 30px auto;
    display: block;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.news-content-text img[style*="width"] {
    width: auto !important;
    max-width: 100% !important;
}

.news-content-text figure {
    max-width: 100%;
    margin: 30px 0;
}

.news-content-text figure img {
    width: 100% !important;
    max-width: 100% !important;
}

.news-content-text h1,
.news-content-text h2,
.news-content-text h3 {
    color: #1B8540;
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.news-content-text ul,
.news-content-text ol {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.news-content-text li {
    margin-bottom: 0.5rem;
}

.news-content-text blockquote {
    border-left: 4px solid var(--primary-color);
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: #555;
}

.news-content-text table {
    max-width: 100%;
    overflow-x: auto;
    display: block;
}

/* Section 3: Share Button */
.share-news-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 25px rgba(27,133,64,0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
}

.share-news-btn:hover {
    transform: scale(1.15) rotate(5deg);
    box-shadow: 0 8px 35px rgba(27,133,64,0.6);
}

.share-news-btn svg {
    width: 24px;
    height: 24px;
    fill: #fff;
}

/* Responsive - News Detail Page */
@media (max-width: 992px) {
    .news-detail-hero {
        margin: 0 -10px;
        width: calc(100% + 20px);
        padding: 60px 0 100px;
    }
    .news-title-section h1 {
        font-size: 2.2rem;
    }
    .news-content-body {
        padding: 40px 35px 50px;
    }
    .news-thumbnail {
        height: 400px;
    }
    .news-content-text {
        font-size: 1.05rem;
    }
}

@media (max-width: 768px) {
    .news-detail-hero {
        min-height: 350px;
        padding: 40px 0 80px;
        margin: 0 -15px;
        width: calc(100% + 30px);
    }
    .news-detail-container {
        padding: 0 20px;
    }
    .news-title-section h1 {
        font-size: 1.8rem;
    }
    .news-content-wrapper {
        margin-top: -60px;
        padding: 0 10px;
    }
    .news-content-card {
        border-radius: 15px;
    }
    .news-content-body {
        padding: 30px 25px 40px;
    }
    .news-thumbnail {
        height: 280px;
    }
    .news-content-text {
        font-size: 1rem;
        line-height: 1.8;
    }
    .news-back-btn {
        padding: 10px 18px;
        font-size: 0.9rem;
    }
    .share-news-btn {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
    }
    .share-news-btn svg {
        width: 20px;
        height: 20px;
    }
}

@media (max-width: 480px) {
    .news-detail-hero {
        padding: 30px 0 70px;
        margin: 0 -15px;
        width: calc(100% + 30px);
    }
    .news-detail-container {
        padding: 0 15px;
    }
    .news-title-section h1 {
        font-size: 1.5rem;
    }
    .news-content-wrapper {
        padding: 0 5px;
    }
    .news-content-body {
        padding: 25px 20px 35px;
    }
    .news-thumbnail {
        height: 220px;
    }
    .news-meta {
        gap: 8px;
    }
    .news-meta-item {
        padding: 10px 18px;
        font-size: 0.85rem;
    }
    .news-content-text {
        font-size: 0.95rem;
    }
}


/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes scroll-left {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}
