.main-wrapper {
    display: flex;
    gap: 15px;
    max-width: 1800px;
    padding: 0 15px;
    flex-wrap: wrap; 
    margin-top: 30px;
    align-items: flex-start;
    justify-content: center;
}

.header-image img {
    width: 100%;
    height: 440px;
    object-fit: cover;
    object-position: center;
    display: block;
    }
.no-data {
    text-align: center;
    padding: 20px;
    font-style: italic;
    color: #666;
}
.container {
    flex: 1;
    min-width: 0;
    background: white;
    border-radius: 10px;
    padding: 20px;
    margin: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    min-height: 400px;
    height: auto;
    max-width: 1000px;
    width: 100%;
}

.new-populer{
    width: 300px;
    flex-shrink: 0;
    border-radius: 10px;
    padding: 20px;
    margin: 10px;
    margin-left: 100px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.522);
    height: auto;
}

/* === Konten Di Dalam Card Terbaru === */
.thumbnail-terbaru {
    width: 150px;
    height: auto;
    display: block;
    margin: 0 auto;
    border-radius: 8px;
    object-fit: cover;
}

.title-terbaru {
    font-size: 13px;
    font-weight: bold;
    color: #555;
    width: 100%;
    text-align: center;
}

.heading-terbaru {
    width: 100%;
    display: block;
    font-size: 24px;
    font-weight: bold;
    color: white;
    text-align: center;
    margin-bottom: 20px;
    padding: 10px 0;
    background-color: #0ee9af;
    border-radius: 6px;
}

.content-terbaru {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex: 1;
}

.date-terbaru {
    font-size: 16px;
    color: #999;
    margin-top: 15px;
    font-weight: bold;
    text-align: center;
}

.date{
    font-size: 16px;
    color: #999;
    font-weight: bold;
    margin-bottom: 10px;
}

.button-group-terbaru {
    display: flex;
    gap: 5px;
    justify-content: center;
    margin-top: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.btn-download-terbaru,
.btn-info-terbaru {
    padding: 10px 12px;
    font-size: 14px;
    font-weight: bold;
    border-radius: 5px;
    text-align: center;
    text-decoration: none;
    color: white;
    border: none;
    cursor: pointer;
}

.btn-download-terbaru {
    background-color: #28a745;
}

.btn-download-terbaru:hover {
    background-color: #218838;
}

.btn-info-terbaru {
    background-color: #007BFF;
}

.btn-info-terbaru:hover {
    background-color: #0056b3;
}

/* === Kartu Warta Utama === */
.card {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 15px;
    margin-bottom: 15px;
    gap: 15px;
}

.heading {
    font-size: 24px;
    font-weight: bold;
    color: #333;
    text-align: center;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 5px;
}

.heading::after {
    content: "";
    display: block;
    width: 50%;
    height: 4px;
    background-color: #000;
    margin: 10px auto 0 auto;
}

.thumbnail {
    width: 300px;
    height: auto;
    border-radius: 8px;
    object-fit: cover;
}

.content {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex: 1;
}

.title {
    font-size: 24px;
    font-weight: bold;
    color: #555;
    margin-bottom: 10px;
}

.button-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-download,
.btn-info {
    padding: 10px 12px;
    font-size: 14px;
    font-weight: bold;
    border-radius: 5px;
    text-align: center;
    text-decoration: none;
    color: white;
    border: none;
    cursor: pointer;
}

.btn-download {
    background-color: #28a745;
}

.btn-download:hover {
    background-color: #218838;
}

.btn-info {
    background-color: #007BFF;
}

.btn-info:hover {
    background-color: #0056b3;
}

.pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}


/* === Responsive Design === */
@media (max-width: 768px) {
    .main-wrapper {
        flex-direction: column;
        align-items: center;
    }

    .container, .new-populer {
        width: 90%;
        max-width: 100%;
        margin: 10px 0;
    }

    .card {
        flex-direction: column;
        align-items: center;
    }
    .date{
        text-align: center;
    }
    .thumbnail {
        width: 100%;
        max-width: 100%;
    }

    .button-group,
    .button-group-terbaru {
        justify-content: center;
    }
}
@media(max-width: 480px) {
    .header-image img {
            height: 160px;
    }

    .title {
        font-size: 14px;
    }

    .btn-download,.btn-download-terbaru,.btn-info-terbaru,
    .btn-info {
        font-size: 10px;
        padding: 5px 8px;
    }

    .date{
        font-size: 14px;
        text-align: center;
    }

    .date-terbaru {
        font-size: 14px;
    }
}

#pdf-viewer .btn-back {
  display: inline-block;
  margin: 20px;
  padding: 10px 20px;
  background-color: #444;
  color: #fff;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

#pdf-viewer iframe {
  width: 100%;
  height: 90vh;
  border: none;
}

#close-pdf {
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: white;
  font-size: 22px;
  cursor: pointer;
  transition: transform 0.2s ease, color 0.2s ease;
}

#close-pdf:hover {
  color: #f60a0a;
  transform: translateY(-50%) scale(1.2);
}

#close-pdf:active {
  transform: translateY(-50%) scale(0.95);
}