:root {
  /* --biru: #224873; simpan warna di variabel */
  --biru: #03155c; /* simpan warna di variabel */
  --putih: #ffffff;
  --biruhover: #11233d; /* warna biru untuk hover */
  --abuabu: #f2f3f5; /* warna abu-abu */
  --birufooter: #0c1727; /* warna biru untuk hover */
  --hitam: #000000; /* warna biru untuk hover */
}

html,
body {
  height: 100%;
  margin: 0;
}

body {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
  background-color: var(--abuabu) !important;
  color: #343a40;
}

/* .navbar-brand {
  margin: auto;
} */

/* Loader */
/* Loader full screen */
/* Wrapper loader full screen */
#loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.8s ease, visibility 0.8s ease; /* fade out */
}

/* Loader bola */
.loader {
  width: 48px;
  height: 48px;
  background: #fff;
  border-radius: 50%;
  position: relative;
  animation: roll 1s ease-in-out infinite alternate;
}
.loader:after {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  border: 5px solid;
  border-color: #ff3d00 transparent;
}

/* Animasi bola */
@keyframes roll {
  0% {
    transform: translateX(-150%) rotate(0deg);
  }
  100% {
    transform: translateX(150%) rotate(360deg);
  }
}

/* Loader menghilang */
#loader.fade-out {
  opacity: 0;
  visibility: hidden;
}
/* exit loader */

#wrapper {
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

.navbar-collapse {
  justify-content: right !important; /* geser ke kanan */
  padding: 5px;
  text-align: center;
  font-weight: 500;
}

nav#navid {
  background-color: var(--biru) !important;
}

nav#navid .nav-link {
  padding-left: 20px;
  padding-right: 20px;
}

nav#navid .nav-link,
nav#navid .navbar-brand {
  color: white !important;
}

nav#navid .nav-link:hover {
  color: var(--biruhover) !important;
  background-color: var(--putih) !important; /* warna biru untuk hover */
  border-radius: 20px; /* makin besar makin oval */
  transition: all 0.3s ease; /* biar smooth */
}

.icon-ajuan {
  font-size: 64px;
}

.icon-klik-disini {
  font-size: 20px;
  margin-left: 5px;
}

.card-klik {
  width: 300px;
  height: 210px;
  cursor: pointer; /* biar bisa klik kalau dipakai onclick */
  transition: transform 0.2s, box-shadow 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.card-klik:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* infografis kesini*/
.infografis-container {
  overflow: hidden;
  width: 100%;
  padding: 20px 0;
  background: #f8f9fa;
}

.infografis-slider {
  display: flex;
  gap: 20px;
  animation: marquee 20s linear infinite;
}

.infografis-card {
  flex: 0 0 250px;
  aspect-ratio: 1/1;
  border-radius: 12px;
  overflow: hidden;
  transition: transform 0.4s ease;
}

.infografis-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.infografis-card:hover {
  transform: scale(1.1);
  z-index: 10;
}

.infografis-slider:hover {
  animation-play-state: paused;
}

@keyframes marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-100%);
  } /* geser setengah (karena digandakan via JS) */
}

.infografis-section {
  padding: 20px;
  background-color: var(--putih);
}

.infografis-section h1 {
  font-weight: bold;
}
/* end infografis disini*/

footer {
  background-color: var(--abuabu);
  color: var(--hitam);
  padding: 20px;
  text-align: center;
  margin-top: 20px;
  position: relative;
  bottom: 0;
  left: 0;
  width: 100%;
}

footer .link-alamat {
  color: var(--hitam);
  text-decoration: none;
}
footer .link-alamat:hover {
  color: var(--birufooter);
  text-decoration: none;
  font-weight: bold;
}

#wrapper .content {
  flex: 1; /* isi konten akan dorong footer ke bawah */
}
.text-indent {
  text-align: justify;
  text-indent: 2.5em; /* indentasi pertama */
  margin-bottom: 1em; /* jarak antar paragraf */
}

/* Informasi Berkala - table styling */
.table-custom thead th {
  background-color: var(--biru);
  /* header biru */
  color: #fff;
  font-weight: 700;
  padding: 12px 16px;
  border: none;
}

.table-custom tbody td {
  /* padding: 14px 16px; */
  vertical-align: middle;
  border-top: 1px solid #eef0f3;
  color: #222;
  background: #fff;
  margin-left: 20px;
}

.table-custom thead th.text-end {
  text-align: right;
}

/* Kategori header bar (jika ada multiple thead) */
.table-custom thead + tbody + thead th,
.table-custom thead + thead th {
  background-color: var(--biru);
  color: #fff;
}

/* tombol Lihat */
.btn-lihat {
  display: inline-block;
  background-color: #2b6ef6;
  color: #fff;
  padding: 6px 14px;
  border-radius: 18px;
  text-decoration: none;
  font-weight: 600;
  border: none;
}

.btn-lihat:hover,
.btn-lihat:focus {
  background-color: var(--biruhover);
  color: #fff;
  text-decoration: none;
}

/* layout container spacing */
.container.informasi-berkala {
  margin-top: 30px;
  margin-bottom: 80px;
}
.table-custom td:first-child {
  padding-left: 20px;
}

.img-zoom {
  transition: transform 0.3s ease;
  cursor: pointer;
}

.img-zoom:hover {
  transform: scale(1.1);
}

/* Untuk tampilan mobile (max-width 991px -> bootstrap breakpoint) */
@media (max-width: 991px) {
  #navid .navbar-collapse {
    justify-content: flex-start !important; /* geser ke kiri */
    text-align: left; /* biar isi juga rata kiri */
  }

  #navid .dropdown-item {
    text-align: left; /* dropdown juga rata kiri */
    font-size: small;
  }

  #navid .navbar-nav {
    margin-left: 0 !important;
  }

  .icon-klik-disini {
    font-size: 16px;
    margin-left: 5px;
  }

  .infografis-slider {
    gap: 2; /* hilangin jarak antar card */
  }

  .infografis-card {
    flex: 0 0 100%; /* 1 card = full width layar */
    aspect-ratio: auto; /* biar proporsional */
    height: 390px; /* atur tinggi sesuai kebutuhan */
  }
  .infografis-section h1 {
    font-weight: bold;
    font-size: 20px; /* ukuran font lebih kecil di mobile */
  }

  .table-custom thead th {
    font-size: 14px;
    padding: 10px;
  }

  .table-custom tbody td {
    /* padding: 10px; */
    font-size: 14px;
  }

  .btn-lihat {
    padding: 6px 10px;
    font-size: 13px;
  }
}
