/* Reset & Global */
body {
  font-family: 'DM Sans', sans-serif;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

p {
  text-align: center;
  font-weight: bold;
  color: #0a1510;
  margin-top: 5px;
  margin-bottom: 10px;
}

h1, h2 {
  color: #ffffff;
  margin: 10px 0;
  font-size: 24px;
  text-align: center;
}

h3 {
  color: #0A3822;
  text-align: center;
  font-weight: bold;
  font-size: 20px;
  margin-top: 30px;
}

/* Header & Nav */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

a img {
  height: 50px;
  width: auto;
  display: flex;
  margin-left: auto;
  margin-right: 250px;
}

nav {
  text-align: left;
  padding: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background-color: rgba(0, 0, 0, 0.616);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 15px;
  flex-grow: 1;
}

.nav-links a {
  text-decoration: none;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  padding: 10px 15px;
  transition: color 0.3s ease-in-out;
}

.nav-links a:hover,
.nav-links a.active {
  color: #F6D920;
}

.login-admin {
  margin-left: auto;
}

.login-admin button {
  padding: 8px 12px;
  background-color: #0f8950;
  color: white;
  border: none;
  cursor: pointer;
  border-radius: 5px;
  font-size: 14px;
  transition: background 0.3s ease-in-out;
}

.login-admin button:hover {
  background-color: #0b6840;
}

/* Toggle Nav */
.toggle-nav {
  background: #0f8950;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
  border-radius: 5px;
  padding: 5px 10px;
  display: none;
  margin:0px;
}

/* Mobile view: max 768px */
@media (max-width: 768px) {
  header {
    flex-direction: column;
    text-align: center;
  }
  nav .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 60px;
    right: 0;
    background: #292929;
    width: 40%;
    padding: 10px 0;
    align-items: flex-end;
  }
  
  .nav-links.show {
    display: flex;
  }
  

  .nav-links a,
  .login-admin {
    display: block;
    padding: 10px;
    text-align: left;
    margin-left: 0;
  }

  .toggle-nav {
    display: block;
  }
  .nav-links .login-admin {
    display: block;
    text-align: center;
    padding: 10px;
    margin:0 auto;
  }

  a img {
    height: 50px;
    width: auto;
    display: flex;
    margin-left: auto;
    margin-right: auto;
  }
  h1, h2{
    font-size: 18px;
  }
}
@media (max-width: 480px) {
  header {
    padding: 10px;
  }

  nav .nav-links {
    top: 50px;
    padding: 8px 0;
  }

  .nav-links a {
    padding: 8px 15px;
    font-size: 14px;
  }

  .nav-links .login-admin {
    padding: 8px;
    font-size: 14px;
  }

  h1, h2 {
    font-size: 16px;
  }

  .toggle-nav {
    font-size: 20px;
    padding: 5px;
  }

  a img {
    width: 200px;
    height: auto;
    margin-right:auto;
    margin-left:auto;
  }
}

/* Background */
.bg-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 48%;
  object-fit: cover;
  z-index: -1;
}

.background-shape1 {
  width: 600px;
  height: 400px;
  flex-shrink: 0;
  border-radius: 600px;
  background: #255D3E;
  filter: blur(223.6px);
  display: flex;
}

/* Header Container */
.header-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 30px;
  margin-top: 90px;
}

/* Text & Logo Container */
.text-container {
  text-align: center;
}

.logo-container {
  display: flex;
  align-items: center;
}

.logo {
  width: 100px;
  height: auto;
}

/* Table & Filters */
.tablembaga, .containlembaga {
  text-align: center;
  margin: 20px auto;
  width: 80%;
}

select {
  padding: 10px;
  margin: 5px;
  border: 1px solid #0f8950;
  border-radius: 5px;
  background-color: white;
  color: black;
  font-size: 14px;
  cursor: pointer;
}

select:focus {
  outline: none;
  border-color: #0b6840;
}

.containsearchlembaga {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin: 20px 0;
}

.search-input {
  padding: 10px;
  width: 400px;
  border: 1px solid #ccc;
  border-radius: 5px;
}

.search-btn {
  padding: 10px 20px;
  background-color: #0f8950;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

/* Table */
table {
  width: 95%;
  border-collapse: collapse;
  margin: 10px auto;
  font-size: 16px;
}

table thead tr {
  background-color: #198754;
  color: white;
  text-align: left;
}

table th, table td {
  padding: 8px;
  border: 1px solid #ddd;
  font-size: 14px;
}

table tbody tr:nth-child(even) {
  background-color: #f2f2f2;
}

table tbody tr:hover {
  background-color: #d1e7dd;
}

/* Pagination */
.pagination {
  margin-top: 10px;
  text-align: center;
}

.page-btn {
  background-color: #198754;
  color: white;
  border: none;
  padding: 5px 10px;
  margin: 2px;
  cursor: pointer;
}

.page-btn:hover {
  background-color: #145a32;
}

/* Button Umum */
button {
  margin: 10px auto;
  background-color: #fff;
  color: #051f13;
  border: 1px solid #0b6840;
  padding: 5px 50px;
  cursor: pointer;
  border-radius: 5px;
  display: block;
}

button:hover {
  background-color: #198754;
  color: #fff;
}

/* Tombol Kembali */
#backButton {
  margin-top: 15px;
  display: none;
  margin-bottom: auto;
}

/* Grid */
.grid-lembaga {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 20px;
  max-width: 900px;
  margin: 20px auto;
}

.lembaga-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background-color: white;
  border: 1px solid #0f8950;
  padding: 10px;
  border-radius: 8px;
  cursor: pointer;
  transition: 0.3s;
  width: 200px;
  height: 120px;
  box-shadow: 5px 8px 24px 0px rgba(76, 76, 76, 0.233);
  white-space: nowrap;
  word-wrap: break-word;
}

.lembaga-item img {
  width: 50px;
  height: 50px;
  margin-bottom: 10px;
}

.lembaga-item:hover {
  border-color: #0f8950;
  background-color: rgb(180, 182, 183);
}
