/* =========================================
   HALAMAN INFO (BERITA & PENGUMUMAN)
   ========================================= */

.hidden {
    display: none !important;
}

.info-page {
    max-width: 1000px;
    margin: 40px auto 100px;
    padding: 0 20px;
}

.info-header {
    text-align: center;
    margin-bottom: 36px;
}

.info-header h1 {
    font-size: 2.6rem;
    margin: 14px 0 12px;
    font-weight: 800;
    letter-spacing: -1px;
    color: #111111;
}

.info-header p {
    color: #666666;
    max-width: 560px;
    margin: 0 auto;
    font-size: 0.98rem;
    line-height: 1.6;
}

.badge-outline {
    display: inline-block;
    padding: 6px 16px;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 30px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #555555;
    letter-spacing: 1px;
    text-transform: uppercase;
    background: rgba(0, 0, 0, 0.03);
}

/* =========================================
   FILTER KATEGORI
   ========================================= */
.news-filter {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-bottom: 32px;
}

.filter-chip {
    border: 1px solid #e5e5e5;
    background: #ffffff;
    color: #555555;
    padding: 7px 16px;
    border-radius: 30px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
}

.filter-chip:hover {
    border-color: #111111;
    color: #111111;
}

.filter-chip.active {
    background: #111111;
    border-color: #111111;
    color: #ffffff;
}

/* =========================================
   GRID BERITA
   ========================================= */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    align-items: stretch;
}

.news-card {
    background: #ffffff;
    border: 1px solid #ececec;
    border-radius: 16px;
    padding: 22px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow: hidden;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
    min-height: 100%;
}

.news-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
    transform: translateY(-2px);
}

.news-card-latest {
    border-color: #111111;
}

.latest-tag {
    display: inline-block;
    align-self: flex-start;
    background: #111111;
    color: #ffffff;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 3px 10px;
    border-radius: 20px;
    margin-bottom: 2px;
}

/* Wrapper foto sampul kartu grid: lapisan blur di belakang (penuh)
   + foto asli utuh di depan (tidak terpotong) */
.news-card-cover-wrap {
    position: relative;
    width: calc(100% + 44px);
    margin: -22px -22px 14px;
    height: 240px;
    overflow: hidden;
}

.news-card-cover-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(20px) brightness(0.85);
    transform: scale(1.15);
}

.news-card-cover {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.news-card-cover-wrap + .latest-tag,
.news-card-cover-wrap + .news-meta {
    margin-top: 14px;
}

.news-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    font-size: 0.78rem;
    color: #999999;
    font-weight: 600;
}

.news-category {
    padding: 4px 11px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    background: rgba(0, 0, 0, 0.06);
    color: #333333;
    white-space: nowrap;
}

.news-category[data-cat="Kegiatan"]    { background: #eaf1ff; color: #1d4ed8; }
.news-category[data-cat="Pengumuman"]  { background: #fdeaea; color: #b91c1c; }
.news-category[data-cat="Seminar"]     { background: #e9f8ee; color: #15803d; }
.news-category[data-cat="Lomba"]       { background: #fff4e1; color: #b45309; }

.news-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #111111;
    line-height: 1.4;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card p {
    font-size: 0.88rem;
    color: #666666;
    line-height: 1.6;
    margin: 0;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.read-more {
    align-self: flex-start;
    margin-top: 4px;
    background: none;
    border: none;
    padding: 0 0 2px;
    font-family: inherit;
    color: #111111;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}

.read-more:hover {
    border-color: #111111;
}

/* =========================================
   SKELETON LOADING
   ========================================= */
.skeleton-card {
    pointer-events: none;
}

.skeleton-line {
    background: linear-gradient(90deg, #eeeeee 25%, #f6f6f6 50%, #eeeeee 75%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.4s infinite;
    border-radius: 6px;
}

.skeleton-badge { width: 72px; height: 20px; border-radius: 20px; }
.skeleton-title { width: 100%; height: 16px; margin-top: 8px; }
.skeleton-title.short { width: 55%; }
.skeleton-text { width: 100%; height: 12px; }

@keyframes skeleton-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* =========================================
   EMPTY STATE
   ========================================= */
.admin-empty {
    grid-column: 1 / -1;
    text-align: center;
    color: #888888;
    font-size: 0.9rem;
    padding: 50px 0;
}

/* =========================================
   MODAL BACA BERITA
   ========================================= */
.news-modal {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.news-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 15, 15, 0.55);
}

.news-modal-card {
    position: relative;
    background: #ffffff;
    max-width: 640px;
    width: 100%;
    max-height: 88vh;
    overflow-y: auto;
    border-radius: 20px;
    padding: 34px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
}

/* Wrapper foto sampul modal: blur belakang (penuh) + foto asli utuh depan */
.news-modal-cover-wrap {
    position: relative;
    width: calc(100% + 68px);
    margin: -34px -34px 20px;
    height: 380px;
    overflow: hidden;
    cursor: zoom-in;
}

.news-modal-cover-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(24px) brightness(0.85);
    transform: scale(1.15);
}

.news-modal-cover {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.news-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: #f2f2f2;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 0.85rem;
    cursor: pointer;
    color: #111111;
    line-height: 1;
    z-index: 2;
}

.news-modal-close:hover {
    background: #e5e5e5;
}

.news-modal-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
}

.news-modal-date {
    font-size: 0.8rem;
    color: #999999;
    font-weight: 600;
}

.news-modal-card h2 {
    font-size: 1.4rem;
    color: #111111;
    margin: 0 0 16px;
    line-height: 1.4;
    padding-right: 20px;
}

.news-modal-body {
    color: #444444;
    font-size: 0.92rem;
    line-height: 1.8;
    white-space: pre-wrap;
}

/* Galeri — juga pakai blur belakang + foto utuh depan */
.news-modal-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 14px;
    margin-top: 22px;
}

.news-modal-gallery-item {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
    border-radius: 12px;
    cursor: zoom-in;
}

.news-modal-gallery-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(18px) brightness(0.85);
    transform: scale(1.15);
}

.news-modal-gallery-img {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

/* =========================================
   LIGHTBOX FULLSCREEN (KLIK FOTO SAMPUL/GALERI)
   ========================================= */
.img-lightbox {
    position: fixed;
    inset: 0;
    z-index: 1100;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.9);
    padding: 30px;
    cursor: zoom-out;
}

.img-lightbox img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.img-lightbox-close {
    position: absolute;
    top: 20px;
    right: 24px;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: #ffffff;
    font-size: 1.1rem;
    cursor: pointer;
    z-index: 2;
}

.img-lightbox-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

@media (max-width: 600px) {
    .info-header h1 {
        font-size: 2rem;
    }

    .news-card-cover-wrap {
        height: 200px;
    }

    .news-modal-card {
        padding: 24px 20px;
        max-height: 88vh;
    }

    .news-modal-cover-wrap {
        width: calc(100% + 40px);
        margin: -24px -20px 16px;
        height: 260px;
    }

    .news-modal-gallery-item {
        height: 180px;
    }
}