/* =================== Artikel =================== */

/* .main-content {
    margin-top: 130px;
} */

body {
    z-index: 0;
}

body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("/img/background-page.png");
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.7;
    z-index: -1;
}

h2.section-title {
    font-weight: 700;
    color: #427057;
    font-size: 1.75rem;
}

/* Artikel Utama (3 teratas) */
.article-card {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    cursor: pointer;
    transition: transform 0.3s ease;
}
.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(13, 58, 145, 0.15);
}
.article-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 12px;
    transition: filter 0.3s ease;
}
.article-img-left {
    height: 550px;
}
.article-img-right {
    height: 267px;
}
.article-card:hover .article-img {
    filter: brightness(0.8);
}
.article-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(116, 112, 110, 0.65);
    padding: 1.2rem;
    border-bottom-left-radius: 12px;
    border-bottom-right-radius: 12px;
    color: #fff;
}

.text-author-name-terbaru {
    color: #c4dfd7;
}

@media (max-width: 767.98px) {
    .article-caption {
        font-size: 0.9rem;
        padding: 0.75rem;
        max-height: 5.4rem;
        -webkit-line-clamp: 4;
    }
}

/* Artikel Lainnya (Versi Desain Terbaru) */
/* #artikel-lainnya-container {
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Atau 'flex-start' jika tidak ingin full sebar 
} */

.artikel-thumbnail {
    width: 100%;
    object-fit: cover;
        transition: filter 0.3s ease;
}

@media (min-width: 768px) {
    .artikel-thumbnail {
        width: 50%;
        height: 100%;
    }
}

.artikel-title {
    font-size: 1.25rem; /* atau lebih besar jika perlu, contoh 1.5rem */
    color: #000;
    line-height: 1.4;
}

.artikel-avatar {
    width: 35px;
    height: 35px;
    border-radius: 50%;
}

.artikel-list-card {
    background-color: white;
    display: flex;
    flex-direction: column;
    height: 100%;
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

@media (min-width: 768px) {
    .artikel-list-card {
        flex-direction: row;
        height: 210px; 
    }
}

.artikel-list-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(13, 58, 145, 0.15);
}

.artikel-list-card:hover .artikel-thumbnail {
    filter: brightness(0.8);
}

.artikel-list-card .card-title {
    font-weight: bold;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.artikel-list-card .article-meta {
    font-size: 0.9rem;
    color: #555;
}

.artikel-list-card .rounded-circle {
    width: 35px;
    height: 35px;
}

.artikel-list-card > div {
    flex: 1;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

@media (min-width: 768px) {
    .artikel-list-card > div {
        width: 50%;
        padding: 1rem;
    }
}

/* Card lama (jika masih digunakan di komponen lain) */
.card {
    transition: transform 0.2s;
    height: 500px !important;
}
.card:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(13, 58, 145, 0.15);
}
.other-article-img {
    height: 300px !important;
}

/* Animasi transisi konten other articles */
.fade-transition {
    transition: opacity 0.5s ease-in-out;
    opacity: 1;
}

.fade-out {
    opacity: 0;
}

/* Pagination */
.page-item.active .page-link {
    background-color: #427057;
    border-color: #427057;
    color: #fff;
}
.page-link {
    color: #427057;
}

.page-link:hover {
    color: #fff;
    background-color: #427057;
    border-color: #427057;
}

/* ANIMASI MASUK UNTUK BERITA */

@keyframes fadeInUpNews {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
@keyframes fadeInLeftNews {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}
@keyframes fadeInRightNews {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUpNews 0.8s ease-out both;
}
.animate-fadeInLeft {
    animation: fadeInLeftNews 1s ease-out both;
}
.animate-fadeInRight {
    animation: fadeInRightNews 1s ease-out both;
}

/* Delay bertahap */
.delay-1 {
    animation-delay: 0.2s;
}
.delay-2 {
    animation-delay: 0.4s;
}
.delay-3 {
    animation-delay: 0.6s;
}
.delay-4 {
    animation-delay: 0.8s;
}


/* =================== Aspirasi =================== */

main {
    padding-top: 130px;
}

/* --- ASPIRASI SECTION ---------------------------------- */

.aspirasi-quote {
    font-size: 1.8rem;
    font-style: italic;
    font-weight: 400;
    color: #000;
    margin-bottom: 0.5rem;
    border-left: 4px solid #000;
    padding-left: 1rem;
}

.aspirasi-author {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-align: center;
}

.aspirasi-img img {
    width: 240px;
    height: auto;
    margin-top: 1rem;
}

.aspirasi-form-title {
    font-size: 2rem;
    font-weight: 700;
    color: #2c6044;
    margin-bottom: 1.5rem;
    text-align: center;
}

.aspirasi-form .form-control {
    margin-bottom: 1rem;
    border-radius: 12px;
    background-color: #f2f2f2;
    border: none;
    padding: 0.8rem 1rem;
    font-size: 1rem;
}

.aspirasi-form textarea.form-control {
    resize: none;
}

.aspirasi-form .btn-success {
    background-color: #2c6044;
    border-radius: 14px;
    padding-inline: 1.5rem;
    font-weight: 600;
    font-size: 1.05rem;
    border: none;
}

.aspirasi-form .btn-success:hover {
    background-color: #245038;
}

/**/
/* --- FLOATING LABEL FORM --- */
.floating-label {
    position: relative;
    margin-bottom: 1.8rem;
}

.floating-label .form-control,
.floating-label textarea,
.floating-label select {
    padding: 1.2rem 1rem 0.6rem;
    font-size: 1rem;
    border: 2px solid #ccc;
    border-radius: 12px;
    background-color: #f2f2f2;
    transition: all 0.3s ease;
    width: 100%;
}

.floating-label label {
    position: absolute;
    top: 1.2rem;
    left: 1rem;
    font-size: 1rem;
    color: #777;
    background-color: transparent;
    padding: 0 0.4rem;
    pointer-events: none;
    transition: 0.25s ease;
}

/* Trigger label naik saat input aktif/terisi */
.floating-label .form-control:focus + label,
.floating-label .form-control:not(:placeholder-shown) + label,
.floating-label textarea:focus + label,
.floating-label textarea:not(:placeholder-shown) + label,
.floating-label select:focus + label,
.floating-label select:valid + label {
    top: -0.6rem;
    left: 0.8rem;
    font-size: 0.75rem;
    color: #2c6044;
    background-color: #fff;
    border-left: 3px solid #2c6044;
    border-right: 3px solid #2c6044;
    padding: 0 0.4rem;
    z-index: 1;
}

.floating-label .form-control:not(:placeholder-shown) {
    background-color: #fff;
    border-color: #2c6044;
}

/* =================== ANIMASI =================== */

/* Keyframes */
@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.7);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Animasi per elemen */
.animated {
    opacity: 0;
    animation-fill-mode: forwards;
    animation-delay: 0s;
}

label.animated {
    opacity: 0;
    animation-fill-mode: forwards;
}

/* Urutan dan timing */
.aspirasi-form-title.animated {
    animation: zoomIn 0.8s ease-out 0.4s forwards;
}

.aspirasi-img.animated {
    animation: fadeIn 1s ease-in-out 0.8s forwards;
}

.aspirasi-quote.animated {
    animation: fadeInLeft 1s ease-in-out 1.2s forwards;
}

.aspirasi-author.animated {
    animation: fadeInRight 1s ease-in-out 1.6s forwards;
}

.form-control.animated {
    animation: slideUp 0.6s ease-out forwards;
}

.form-animate-1 label.animated {
    animation: fadeInRight 0.6s ease-out 1.4s forwards;
}

.form-animate-2 label.animated {
    animation: fadeInRight 0.6s ease-out 1.9s forwards;
}

.form-animate-3 label.animated {
    animation: fadeInRight 0.6s ease-out 2.4s forwards;
}

.form-animate-4 label.animated {
    animation: fadeInRight 0.6s ease-out 2.9s forwards;
}

.form-animate-5 label.animated {
    animation: fadeInRight 0.6s ease-out 3.4s forwards;
}

/* Atur delay berdasarkan urutan parent .form-group */
.form-animate-1 .form-control.animated {
    animation-delay: 1.5s;
}
.form-animate-2 .form-control.animated {
    animation-delay: 2s;
}
.form-animate-3 .form-control.animated {
    animation-delay: 2.5s;
}
.form-animate-4 .form-control.animated {
    animation-delay: 3s;
}
.form-animate-5 .form-control.animated {
    animation-delay: 3.5s;
}
.form-animate-6 .btn-success.animated {
    animation-delay: 4s;
}
.form-animate-7 .btn-success.animated {
    animation-delay: 4.5s;
}

.btn-success.animated {
    animation: slideUp 0.6s ease-out 6s forwards;
}

/* UNTUK GOOGLE CAPTCHA */
.recaptcha-wrapper {
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
}

/* Setelah animasi dimulai (class ini ditambahkan via JS delay) */
.recaptcha-wrapper.animate-visible {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
}

/* RESPONSIVE – jika layar < 992px jadikan kolom */
@media (max-width: 991.98px) {
    .floating-label label {
        font-size: 0.8rem;
    }
    .form-animate-1 {
        margin-top: 25px;
    }
}
