/* ============================================================
   NEWS PAGE STYLING - SMP Negeri 26 Surakarta
   File: css/news-style.css
   
   Tambahkan di header SETELAH style.css:
   <link rel="stylesheet" href="css/news-style.css?v=1.0">
   
   File ini HANYA CSS, tidak perlu ubah PHP apapun.
   Target: class-class yang sudah ada di news.php
   ============================================================ */

/* ============================================================
   1. NEWS LIST PAGE (bannerberita / news.php?req=d)
   ============================================================ */

/* Blog box card style */
#halamannews .blog-box {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
    margin-bottom: 25px !important;
    min-height: auto !important;
    transition: all 0.3s ease;
    padding: 0 !important;
}

#halamannews .blog-box:hover {
    box-shadow: 0 8px 30px rgba(0,0,0,0.1);
    transform: translateY(-3px);
}

/* Image in news list */
#halamannews .blog-box .post-image {
    max-height: none !important;
    overflow: hidden;
    height: 100%;
}

#halamannews .blog-box .post-image img {
    width: 100%;
    height: 100%;
    min-height: 220px;
    object-fit: cover;
    display: block;
    max-height: none !important;
    transition: transform 0.4s ease;
    border-radius: 10px 0 0 10px;
}

#halamannews .blog-box:hover .post-image img {
    transform: scale(1.05);
}

/* Content area */
#halamannews .blog-box .post-content-wrapper {
    padding: 25px !important;
}

#halamannews .blog-box .post-content-wrapper > div {
    padding-left: 0 !important;
}

#halamannews .blog-box .post-title h3 {
    font-size: 18px !important;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 10px;
}

#halamannews .blog-box .post-title h3,
#halamannews .blog-box h3 a {
    color: #1a1a2e;
    text-decoration: none;
    transition: color 0.2s;
}

#halamannews .blog-box h3 a:hover {
    color: #05094a;
}

/* Post meta */
#halamannews .blog-box .post-meta {
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #f0f0f0;
}

#halamannews .blog-box .post-meta span {
    font-size: 12px;
    color: #888;
    margin-right: 14px;
}

#halamannews .blog-box .post-meta span i {
    margin-right: 4px;
    color: #05094a;
}

/* Post content/excerpt */
#halamannews .blog-box .post-content {
    margin-bottom: 15px;
}

#halamannews .blog-box .post-content p {
    font-size: 14px;
    color: #555;
    line-height: 1.7;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Read more button */
#halamannews .blog-box .btn-default,
#halamannews .blog-box .btn-sm {
    background: transparent;
    color: #05094a;
    border: 2px solid #05094a;
    border-radius: 25px;
    padding: 6px 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

#halamannews .blog-box .btn-default:hover,
#halamannews .blog-box .btn-sm:hover {
    background: #05094a;
    color: #fff;
    transform: translateY(-2px);
}

/* Section heading */
#halamannews h3[align="center"] {
    font-size: 24px;
    font-weight: 700;
    color: #05094a;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 15px;
}

#halamannews h3[align="center"]::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: #05094a;
    border-radius: 2px;
}

/* Background */
#halamannews .section-blog {
    background: #f8f9fc;
}

/* List images override */
#halamannews .list img {
    max-height: none !important;
}

/* Mobile responsive */
@media (max-width: 767.98px) {
    #halamannews .blog-box .post-image img {
        min-height: 180px;
        border-radius: 10px 10px 0 0;
    }
    #halamannews .blog-box .post-content-wrapper {
        padding: 18px !important;
    }
    #halamannews .blog-box .post-title h3 {
        font-size: 16px !important;
    }
}


/* ============================================================
   2. DETAIL BERITA PAGE (detailberita / news/{id}/...)
   ============================================================ */

/* Main container */
#news .container {
    max-width: 1140px;
}

/* Article card wrapper */
#news .blog-box-single {
    background: #fff;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    margin-bottom: 25px;
}

#news .blog-box-single h3 {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a2e;
    line-height: 1.4;
    margin-bottom: 15px;
}

#news .blog-box-single h3 a {
    color: #1a1a2e;
    text-decoration: none;
}

/* Post meta in detail */
#news .blog-box-single .post-meta {
    padding: 12px 0;
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
    border-top: 1px solid #eee;
}

#news .blog-box-single .post-meta span {
    font-size: 13px;
    color: #888;
    margin-right: 18px;
}

#news .blog-box-single .post-meta span i {
    margin-right: 5px;
    color: #05094a;
}

/* Article content */
#news .blog-box-single .post-content {
    font-size: 15px;
    line-height: 1.8;
    color: #333;
}

#news .blog-box-single .post-content p {
    margin-bottom: 14px;
}

#news .blog-box-single .post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 10px 0;
}

/* Divider */
#news .divider {
    border-top: 1px solid #eee;
    margin: 15px 0;
}

/* Admin edit/delete links in detail */
#news .postmeta a {
    display: inline-block;
    padding: 5px 16px;
    margin: 3px 3px;
    border: 1px solid #05094a;
    color: #05094a;
    border-radius: 20px;
    font-size: 12px;
    text-decoration: none;
    transition: all 0.2s;
}

#news .postmeta a:hover {
    background: #05094a;
    color: #fff;
}

/* Tags box */
#news .content-box {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.04);
    margin-top: 20px;
    border: 1px solid #eee;
}

#news .content-box-header {
    font-size: 15px;
    font-weight: 700;
    padding: 12px 18px;
    margin: 0;
    background: #05094a !important;
    color: #fff;
}

#news .content-box-wrapper {
    padding: 15px 18px;
}

#news .content-box-wrapper a {
    display: inline-block;
    padding: 4px 14px;
    background: #f0f4ff;
    color: #05094a;
    border-radius: 20px;
    font-size: 12px;
    margin: 3px 3px;
    text-decoration: none;
    transition: all 0.2s;
}

#news .content-box-wrapper a:hover {
    background: #05094a;
    color: #fff;
}


/* ============================================================
   3. SIDEBAR (Related Posts)
   ============================================================ */

/* Sidebar content box */
#news .col-md-4 .content-box {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
    border: none;
}

#news .col-md-4 .content-box .content-box-header {
    background: #05094a !important;
    color: #fff;
    font-size: 16px;
    padding: 15px 20px;
}

#news .col-md-4 .posts-list {
    padding: 10px 15px;
}

/* Related post items */
#news .col-md-4 .gallery,
#news .col-md-4 #listrelatedpost {
    list-style: none;
    padding: 0;
    margin: 0;
}

#news .col-md-4 .gallery li,
#news .col-md-4 #listrelatedpost li {
    padding: 12px 5px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s;
    border-radius: 6px;
}

#news .col-md-4 .gallery li:last-child,
#news .col-md-4 #listrelatedpost li:last-child {
    border-bottom: none;
}

#news .col-md-4 .gallery li:hover,
#news .col-md-4 #listrelatedpost li:hover {
    background: #f8f9fc !important;
}

#news .col-md-4 .gallery li img,
#news .col-md-4 #listrelatedpost li img {
    width: 100%;
    max-height: 100px;
    object-fit: cover;
    border-radius: 6px;
    margin-bottom: 8px;
}

#news .col-md-4 .gallery li h3,
#news .col-md-4 #listrelatedpost li h3 {
    font-size: 14px !important;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 4px;
}

#news .col-md-4 .gallery li h3 a,
#news .col-md-4 #listrelatedpost li h3 a {
    color: #333;
    text-decoration: none;
    transition: color 0.2s;
}

#news .col-md-4 .gallery li h3 a:hover,
#news .col-md-4 #listrelatedpost li h3 a:hover {
    color: #05094a;
}

#news .col-md-4 .gallery li p,
#news .col-md-4 #listrelatedpost li p {
    font-size: 12px;
    color: #888;
    line-height: 1.5;
    margin: 0;
}


/* ============================================================
   4. COMMENTS SECTION
   ============================================================ */

/* Comment list */
.commentlist {
    list-style: none;
    padding: 0;
}

.commentlist li {
    padding: 15px 18px;
    margin-bottom: 12px;
    background: #f9fafe;
    border-radius: 8px;
    border-left: 3px solid #05094a;
}

.bobcomment {
    margin-bottom: 5px;
}

.bobcomment a {
    color: #05094a;
    font-weight: 600;
    text-decoration: none;
}

.bobcomment small a {
    color: #999;
    font-weight: 400;
    font-size: 12px;
}

.bobcomment p {
    font-size: 14px;
    color: #444;
    line-height: 1.6;
    margin: 8px 0 0;
}

/* Comment form */
#boxcomment {
    background: #fff;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
    margin-top: 20px;
}

#boxcomment .comments h3 {
    font-size: 18px;
    font-weight: 700;
    color: #05094a;
    margin-bottom: 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid #05094a;
}

#boxcomment input[type="text"],
#boxcomment textarea {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s;
    margin-bottom: 5px;
    box-sizing: border-box;
}

#boxcomment input[type="text"]:focus,
#boxcomment textarea:focus {
    border-color: #05094a;
    outline: none;
    box-shadow: 0 0 0 3px rgba(5,9,74,0.08);
}

#boxcomment textarea {
    min-height: 100px;
    resize: vertical;
}

#boxcomment input[type="submit"] {
    background: #05094a;
    color: #fff;
    border: none;
    padding: 10px 28px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 10px;
}

#boxcomment input[type="submit"]:hover {
    background: #1a237e;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(5,9,74,0.2);
}


/* ============================================================
   5. BERITA HOME (carousel di homepage)
   ============================================================ */

#news .thumbnail-box-wrapper {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
    transition: all 0.3s ease;
}

#news .thumbnail-box-wrapper:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
    transform: translateY(-3px);
}

#news .thumbnail-box img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

#news .thumb-pane {
    padding: 15px;
    background: #fff;
}

#news .thumb-heading {
    font-size: 14px !important;
    font-weight: 600;
    line-height: 1.4;
    margin: 0;
}

#news .thumb-heading a {
    color: #1a1a2e;
    text-decoration: none;
    transition: color 0.2s;
}

#news .thumb-heading a:hover {
    color: #05094a;
}

#news .thumb-heading small {
    display: block;
    font-size: 11px;
    color: #999;
    margin-top: 5px;
    font-weight: 400;
}

/* Section title "Recent Blog Posts" */
#news h3 {
    color: #05094a;
}


/* ============================================================
   6. PAGINATION
   ============================================================ */
#halamannews a[href*="offset"],
#show_table a[href*="offset"],
.pagination a {
    display: inline-block;
    padding: 6px 14px;
    margin: 0 2px;
    border-radius: 6px;
    font-size: 13px;
    color: #05094a;
    text-decoration: none;
    background: #fff;
    border: 1px solid #e0e0e0;
    transition: all 0.2s;
    font-weight: 500;
}

#halamannews a[href*="offset"]:hover,
#show_table a[href*="offset"]:hover,
.pagination a:hover,
.pagination a.active {
    background: #05094a;
    color: #fff;
    border-color: #05094a;
}


/* ============================================================
   7. SUBSCRIBE EMAIL
   ============================================================ */
#boxaddmail .input-group {
    max-width: 500px;
}

#boxaddmail .form-control {
    border-radius: 25px 0 0 25px;
    padding: 10px 20px;
    border: 2px solid #e0e0e0;
    font-size: 14px;
}

#boxaddmail .form-control:focus {
    border-color: #05094a;
    box-shadow: none;
}

#boxaddmail .btn-primary {
    border-radius: 0 25px 25px 0;
    background: #05094a;
    border-color: #05094a;
    padding: 10px 20px;
}

#boxaddmail .btn-primary:hover {
    background: #1a237e;
}


/* ============================================================
   8. MOBILE RESPONSIVE
   ============================================================ */
@media (max-width: 991.98px) {
    #news .blog-box-single {
        padding: 20px;
    }
    #news .blog-box-single h3 {
        font-size: 20px;
    }
    #news .blog-box-single .post-content {
        font-size: 14px;
    }
}

@media (max-width: 767.98px) {
    #news .blog-box-single {
        padding: 15px;
    }
    #news .blog-box-single h3 {
        font-size: 18px;
    }
    #boxcomment {
        padding: 18px;
    }
}