.news-detail-meta {
    margin-top: 10px;
}

.news-detail-date {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    font-weight: 500;
}

.news-detail-section {
    background: #f0f2f5;
    padding: 30px 0 50px;
}

.news-article-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.news-article-image {
    overflow: hidden;
    max-height: 450px;
}

.news-article-image img {
    width: 100%;
    height: auto;
    max-height: 450px;
    object-fit: cover;
    display: block;
}

.news-article-content {
    padding: 28px;
    font-size: 0.95rem;
    line-height: 1.7;
    color: #2d3748;
}

.news-article-content h2,
.news-article-content h3,
.news-article-content h4 {
    color: #1a1a2e;
    font-weight: 700;
    margin-top: 1.8em;
    margin-bottom: 0.8em;
}

.news-article-content h2 {
    font-size: 1.35rem;
}

.news-article-content h3 {
    font-size: 1.15rem;
}

.news-article-content p {
    margin-bottom: 1.2em;
}

.news-article-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin: 1.5em 0;
}

.news-article-content a {
    color: #003f7d;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.2s ease;
}

.news-article-content a:hover {
    color: #0078d4;
}

.news-article-content ul,
.news-article-content ol {
    padding-left: 1.5em;
    margin-bottom: 1.2em;
}

.news-article-content li {
    margin-bottom: 0.5em;
}

.news-article-content blockquote {
    border-left: 4px solid #003f7d;
    background: #f8f9fb;
    margin: 1.5em 0;
    padding: 1.2em 1.5em;
    border-radius: 0 12px 12px 0;
    color: #4a4a68;
    font-style: italic;
}

.nai {
    padding: 16px 40px 0;
}

.news-ai-sidebar {
    margin-top: 16px;
}

.nai--sidebar {
    padding: 16px;
}

.nai-trigger {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 14px 20px;
    border: 2px solid transparent;
    border-radius: 14px;
    background: linear-gradient(135deg, #edf4ff 0%, #f5f0ff 100%);
    cursor: pointer;
    transition: all 0.28s ease;
    position: relative;
    overflow: hidden;
}

.nai-trigger::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 14px;
    padding: 2px;
    background: linear-gradient(135deg, #003f7d, #6366f1);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.28s ease;
}

.nai-trigger:hover::before {
    opacity: 1;
}

.nai-trigger:hover {
    background: linear-gradient(135deg, #e5eeff 0%, #ede8ff 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(0, 63, 125, 0.12);
}

.nai-trigger.is-hidden {
    display: none;
}

.nai-trigger-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: linear-gradient(135deg, #003f7d, #0066cc);
    color: #fff;
    font-size: 1.1rem;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 63, 125, 0.3);
}

.nai-trigger-label {
    flex: 1;
    text-align: left;
    font-weight: 600;
    font-size: 0.95rem;
    color: #1a2b45;
    letter-spacing: -0.01em;
}

.nai-trigger-arrow {
    color: #6b7c93;
    font-size: 0.8rem;
    transition: transform 0.2s ease;
}

.nai-trigger:hover .nai-trigger-arrow {
    transform: translateX(3px);
    color: #003f7d;
}

.nai-card {
    display: none;
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 8px 32px rgba(0, 63, 125, 0.10), 0 1px 4px rgba(0, 0, 0, 0.04);
    animation: naiSlideIn 0.32s ease;
}

.nai-card.is-open {
    display: block;
}

@keyframes naiSlideIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.nai-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: linear-gradient(135deg, #003f7d 0%, #004f9e 100%);
    color: #fff;
}

.nai-card-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 0.95rem;
}

.nai-card-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(4px);
    color: #fff;
}

.nai-card-close {
    border: none;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease;
    font-size: 0.85rem;
}

.nai-card-close:hover {
    background: rgba(255, 255, 255, 0.25);
}

.nai-card-body {
    padding: 24px;
    min-height: 100px;
}

.nai-loading {
    display: flex;
    align-items: center;
    gap: 14px;
    color: #4a6583;
    font-size: 0.92rem;
    font-weight: 500;
}

.nai-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid #e2e8f0;
    border-top-color: #003f7d;
    border-radius: 50%;
    animation: naiSpin 0.8s linear infinite;
    flex-shrink: 0;
}

@keyframes naiSpin {
    to {
        transform: rotate(360deg);
    }
}

.nai-error {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    padding: 16px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 10px;
    color: #991b1b;
    font-size: 0.9rem;
}

.nai-error>i {
    font-size: 1rem;
    color: #dc2626;
}

.nai-retry-btn {
    margin-left: auto;
    border: 1px solid #fca5a5;
    background: #fff;
    color: #991b1b;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nai-retry-btn:hover {
    background: #fef2f2;
    border-color: #dc2626;
}

.nai-result {}

.nai-text {
    color: #1e293b;
    font-size: 0.98rem;
    line-height: 1.8;
    white-space: pre-line;
    margin: 0;
}

.nai-card-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 12px 20px;
    border-top: 1px solid #f1f5f9;
    background: #fafbfc;
}

.nai-footer-btn {
    border: 1px solid #cbd5e1;
    background: #fff;
    color: #334155;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.nai-footer-btn:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
    color: #003f7d;
}

.nai-footer-btn i {
    margin-right: 5px;
}

.news-gallery {
    margin: 2em 0;
    border-radius: 14px;
    overflow: hidden;
    background: #f8f9fb;
    border: 1px solid #e2e8f0;
}

.news-gallery-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 24px;
    background: linear-gradient(135deg, #003f7d, #0056b3);
    color: #fff;
    font-weight: 600;
    font-size: 0.95rem;
}

.news-gallery-header i {
    font-size: 1rem;
    opacity: 0.85;
}

.news-gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    padding: 8px;
}

.news-gallery-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    aspect-ratio: 4 / 3;
    background: #e2e8f0;
}

.news-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
    margin: 0 !important;
    border-radius: 0 !important;
}

.news-gallery-item:hover img {
    transform: scale(1.06);
}

.news-gallery-item-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 63, 125, 0);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
}

.news-gallery-item-overlay i {
    color: #fff;
    font-size: 1.4rem;
    opacity: 0;
    transform: scale(0.7);
    transition: all 0.3s ease;
}

.news-gallery-item:hover .news-gallery-item-overlay {
    background: rgba(0, 63, 125, 0.35);
}

.news-gallery-item:hover .news-gallery-item-overlay i {
    opacity: 1;
    transform: scale(1);
}

.news-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: lbFadeIn 0.25s ease;
}

@keyframes lbFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.news-lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    cursor: pointer;
}

.news-lightbox-content {
    position: relative;
    z-index: 1;
    max-width: 90vw;
    max-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.news-lightbox-content img {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.4);
}

.news-lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 2;
    width: 48px;
    height: 48px;
    border: none;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 1.3rem;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
    backdrop-filter: blur(4px);
}

.news-lightbox-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.news-lightbox-prev,
.news-lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    width: 52px;
    height: 52px;
    border: none;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    font-size: 1.2rem;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
}

.news-lightbox-prev {
    left: 20px;
}

.news-lightbox-next {
    right: 20px;
}

.news-lightbox-prev:hover,
.news-lightbox-next:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-50%) scale(1.08);
}

.news-lightbox-counter {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    font-weight: 600;
    background: rgba(0, 0, 0, 0.4);
    padding: 6px 18px;
    border-radius: 999px;
    backdrop-filter: blur(4px);
}

.news-back-nav {
    margin-top: 24px;
}

.news-back-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #fff;
    color: #003f7d;
    padding: 14px 28px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    border: 1px solid rgba(0, 63, 125, 0.15);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.3s ease;
}

.news-back-btn:hover {
    background: #003f7d;
    color: #fff;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 63, 125, 0.2);
}

.news-back-btn i {
    transition: transform 0.3s ease;
}

.news-back-btn:hover i {
    transform: translateX(-3px);
}

.news-sidebar-sticky {
    position: sticky;
    top: 100px;
}

.news-sidebar-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.news-sidebar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 24px 28px;
    background: linear-gradient(135deg, #003f7d, #0056b3);
    color: #fff;
}

.news-sidebar-header i {
    font-size: 1.1rem;
    opacity: 0.85;
}

.news-sidebar-header h4 {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0;
}

.news-sidebar-list {
    padding: 8px;
}

.news-sidebar-item {
    display: block;
    padding: 18px 20px;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.25s ease;
    border-bottom: 1px solid #f0f2f5;
}

.news-sidebar-item:last-child {
    border-bottom: none;
}

.news-sidebar-item:hover {
    background: #f8f9fb;
    text-decoration: none;
    transform: translateX(4px);
}

.news-sidebar-item-date {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 6px;
}

.news-sidebar-item-date i {
    font-size: 0.75rem;
}

.news-sidebar-item-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1a1a2e;
    margin: 0;
    line-height: 1.4;
    transition: color 0.25s ease;
}

.news-sidebar-item:hover .news-sidebar-item-title {
    color: #003f7d;
}

@media (max-width: 991px) {
    .news-detail-section {
        padding: 30px 0 50px;
    }

    .news-article-content {
        padding: 30px;
    }

    .nai {
        padding: 16px 30px 0;
    }

    .nai--sidebar {
        padding: 16px;
    }

    .news-sidebar-sticky {
        position: static;
        margin-top: 16px;
    }

    .news-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 767px) {
    .news-detail-section {
        padding: 20px 0 40px;
    }

    .news-article-content {
        padding: 24px;
        font-size: 1rem;
    }

    .nai {
        padding: 14px 24px 0;
    }

    .nai--sidebar {
        padding: 14px;
    }

    .nai-trigger {
        padding: 12px 16px;
        gap: 10px;
    }

    .nai-trigger-icon {
        width: 36px;
        height: 36px;
        font-size: 0.95rem;
    }

    .nai-trigger-label {
        font-size: 0.88rem;
    }

    .news-article-image {
        max-height: 280px;
    }

    .news-article-image img {
        max-height: 280px;
    }

    .nai-card-body {
        padding: 18px;
    }

    .nai-text {
        font-size: 0.92rem;
    }

    .news-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
        padding: 6px;
    }

    .news-gallery-header {
        padding: 12px 18px;
        font-size: 0.9rem;
    }

    .news-lightbox-prev,
    .news-lightbox-next {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }

    .news-lightbox-prev {
        left: 10px;
    }

    .news-lightbox-next {
        right: 10px;
    }

    .news-lightbox-close {
        top: 10px;
        right: 10px;
        width: 40px;
        height: 40px;
    }
}