/* ===============================
   BERITA DETAIL STYLES - UNMI Bogor
   =============================== */

/* Main Content */
.main-content {
    padding-top: 10px; /* Reduced to bring content closer to navbar */
    min-height: 100vh;
    background: #f8f9fa;
}

/* News Detail Section */
.news-detail-section {
    padding: 0.5rem 0; /* Further reduced to bring content closer to navbar */
}

/* Breadcrumb Navigation */
.breadcrumb-nav {
    margin-bottom: 1rem; /* Reduced margin to bring content closer */
}

.breadcrumb {
    background: white;
    border-radius: 15px;
    padding: 1rem 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.breadcrumb-item a {
    color: #667eea;
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-item a:hover {
    color: #5a6fd8;
}

.breadcrumb-item.active {
    color: #6c757d;
}

/* News Detail */
.news-detail {
    background: white;
    border-radius: 20px;
    padding: 1.5rem; /* Reduced padding to make content more compact */
    box-shadow: 0 8px 30px rgba(0,0,0,0.1);
    margin-bottom: 1.5rem; /* Reduced margin */
}

/* News Header */
.news-header {
    margin-bottom: 2rem;
}

.news-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    align-items: center;
}

.news-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #6c757d;
}

.news-meta .category {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.news-meta i {
    color: #667eea;
}

.news-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2c3e50;
    line-height: 1.3;
    margin-bottom: 1rem;
}

.news-excerpt {
    font-size: 1.2rem;
    color: #6c757d;
    line-height: 1.6;
    margin-bottom: 0;
    display: none; /* Hide the news excerpt */
}

/* Featured Image */
.news-featured-image {
    margin: 2rem 0;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    position: relative;
    display: none; /* Hide the featured image */
}

.news-featured-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

.news-featured-image:hover img {
    transform: scale(1.02);
}

/* News Content */
.news-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #2c3e50;
    margin: 2rem 0;
}

.news-content h2, .news-content h3, .news-content h4 {
    color: #2c3e50;
    margin: 2rem 0 1rem 0;
    font-weight: 600;
    position: relative;
    padding-left: 1rem;
}

.news-content h2::before, .news-content h4::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 60%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 2px;
}

.news-content p {
    margin-bottom: 1.5rem;
    text-align: justify;
}

.news-content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 1.5rem 0;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.news-content blockquote {
    border-left: 4px solid #667eea;
    background: #f8f9fa;
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    border-radius: 0 10px 10px 0;
    font-style: italic;
    color: #495057;
}

.news-content ul, .news-content ol {
    margin: 1rem 0;
    padding-left: 2rem;
}

.news-content li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

/* News Footer */
.news-footer {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e9ecef;
}

/* Share Section */
.share-section {
    margin-bottom: 2rem;
}

.share-link-container {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 1.5rem;
    border: 1px solid #e9ecef;
}

.share-title {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
}

.share-title i {
    color: #667eea;
}

.share-url {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.share-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid #dee2e6;
    border-radius: 10px;
    background: white;
    font-size: 0.9rem;
    color: #495057;
    cursor: pointer;
    transition: all 0.3s ease;
}

.share-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.copy-btn {
    padding: 0.75rem 1.25rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

.copy-btn:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.copy-btn:active {
    transform: translateY(0);
}

/* News Tags */
.news-tags {
    margin-top: 2rem;
}

.tags-section {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 1.5rem;
    border: 1px solid #e9ecef;
}

.tags-title {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1rem;
}

.tags-title i {
    color: #667eea;
}

.tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.tag-link {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.tag-link:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    text-decoration: none;
    color: white;
    border-color: #667eea;
}

/* Related News */
.related-news {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 8px 30px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.section-title {
    color: #2c3e50;
    font-weight: 700;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 3px solid #667eea;
    display: inline-block;
    font-size: 1.8rem;
}

.related-news-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    height: 100%;
    cursor: pointer;
}

.related-news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    background: #f8f9fa;
}

.related-news-image {
    height: 180px;
    overflow: hidden;
}

.related-news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.related-news-card:hover .related-news-image img {
    transform: scale(1.1);
}

.related-news-content {
    padding: 1.5rem;
}

.related-news-content h5 {
    color: #2c3e50;
    margin-bottom: 1rem;
    line-height: 1.4;
}

.related-news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: #6c757d;
}

.related-news-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* ===============================
   SIDEBAR STYLES
   =============================== */

.news-sidebar {
    position: sticky;
    top: 100px;
}

.sidebar-widget {
    background: white;
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    border: 1px solid rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.sidebar-widget:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

.widget-title {
    color: #2c3e50;
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #667eea;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.widget-title i {
    color: #667eea;
}

/* Search Widget */
.search-form .input-group {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border-radius: 10px;
    overflow: hidden;
}

.search-form .form-control {
    border: none;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
}

.search-form .btn {
    border: none;
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 500;
}

.search-form .btn:hover {
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
    transform: translateY(-1px);
}

/* Categories Widget */
.categories-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.categories-list li {
    margin-bottom: 0.75rem;
}

.categories-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background: #f8f9fa;
    border-radius: 10px;
    color: #2c3e50;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.categories-list a:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    transform: translateX(5px);
    border-color: #667eea;
}

.category-count {
    background: rgba(255,255,255,0.2);
    color: inherit;
    padding: 0.25rem 0.5rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Recent News Widget */
.recent-news-item {
    display: flex;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid #f1f3f4;
    transition: all 0.3s ease;
    cursor: pointer;
    border-radius: 10px;
    margin: 0 -0.5rem;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
}

.recent-news-item:last-child {
    border-bottom: none;
}

.recent-news-item:hover {
    transform: translateX(5px);
    background: #f8f9fa;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
}

.recent-news-image {
    flex-shrink: 0;
    width: 80px;
    height: 60px;
    border-radius: 10px;
    overflow: hidden;
}

.recent-news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recent-news-content {
    flex: 1;
    min-width: 0;
}

.recent-news-content h6 {
    color: #2c3e50;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

.recent-news-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.8rem;
    color: #6c757d;
}

.recent-news-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.recent-news-meta i {
    color: #667eea;
    font-size: 0.75rem;
}



/* Share Widget */
.share-buttons-sidebar {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

.share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 1.1rem;
}

.share-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
    text-decoration: none;
    color: white;
}

.share-btn.facebook {
    background: #1877f2;
}

.share-btn.twitter {
    background: #1da1f2;
}

.share-btn.whatsapp {
    background: #25d366;
}

.share-btn.email {
    background: #ea4335;
}

/* Back to News Widget */
.back-to-news-widget .btn {
    width: 100%;
    padding: 0.875rem 1.5rem;
    font-weight: 500;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.back-to-news-widget .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

/* No Image Frame Small */
.no-image-frame-small {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px dashed #dee2e6;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
}

.no-image-frame-small i {
    font-size: 1.2rem;
    opacity: 0.7;
}

/* Error Section */
.error-section {
    padding: 4rem 0;
    text-align: center;
}

.error-content {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 8px 30px rgba(0,0,0,0.1);
}

.error-title {
    font-size: 6rem;
    font-weight: 700;
    color: #667eea;
    margin-bottom: 1rem;
}

.error-subtitle {
    color: #2c3e50;
    margin-bottom: 1rem;
}

.error-message {
    color: #6c757d;
    margin-bottom: 2rem;
}

/* Responsive Design */
@media (max-width: 991px) {
    .news-sidebar {
        position: static;
        margin-top: 2rem;
    }
    
    .news-detail {
        padding: 2rem;
    }
    
    .news-title {
        font-size: 2rem;
    }
    
    .related-news {
        padding: 1.5rem;
    }
}

@media (max-width: 768px) {
    .news-detail {
        padding: 1.5rem;
    }
    
    .news-title {
        font-size: 1.8rem;
    }
    
    .news-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .sidebar-widget {
        padding: 1.25rem;
    }
    
    .share-url {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .copy-btn {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .news-detail {
        padding: 1.25rem;
    }
    
    .news-title {
        font-size: 1.5rem;
    }
    
    .sidebar-widget {
        padding: 1rem;
    }
    
    .recent-news-image {
        width: 70px;
        height: 50px;
    }
}
