/* RESET DASAR */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* BODY */
body {
  font-family: "Segoe UI", sans-serif;
  background-color: #fff;
  color: #333;
  line-height: 1.6;
}

/* HEADER */
header {
  background-color: #002147;
  color: white;
  padding: 10px 20px;
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}

.logo {
  height: 60px;
  max-width: 100%;
  margin-right: 15px;
}

header h1 {
  font-size: 20px;
  margin: 0;
  flex-grow: 1;
  font-weight: bold;
}

.menu-toggle {
  background: none;
  border: none;
  font-size: 24px;
  color: white;
  cursor: pointer;
  display: none;
}

#nav-menu {
  display: flex;
  flex-direction: row;
  gap: 10px;
}

#nav-menu a {
  color: white;
  text-decoration: none;
  padding: 10px 20px;
  display: block;
  transition: background-color 0.3s;
}

#nav-menu a:hover {
  background-color: #001b3a;
}

/* RESPONSIVE MENU */
@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }

  #nav-menu {
    display: none;
    flex-direction: column;
    width: 100%;
  }

  #nav-menu.active {
    display: flex;
  }

  #nav-menu a {
    border-top: 1px solid #1a3a6b;
    padding: 12px 20px;
  }
}

/* HERO SECTION */
.hero {
  background: url('hero.jpg') no-repeat center center/cover;
  height: 150px;
  position: relative;
}

.hero-overlay {
  background-color: rgba(0, 33, 71, 0.6);
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-text {
  color: white;
  text-align: center;
}

.hero-text h1 {
  font-size: 20px;
  margin-bottom: 10px;
}

/* CONTAINER */
.container {
  width: 90%;
  max-width: 1200px;
  margin: auto;
}

/* BERITA */
.berita {
  padding: 40px 0;
}

.berita h2 {
  text-align: center;
  color: #002147;
  margin-bottom: 30px;
}

/* GRID UMUM */
.fitur-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

/* BERITA ITEM */
.berita-item, .penelitian-box {
  background-color: #f9f9f9;
  padding: 15px;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.berita-item img,
.fitur-grid img {
  width: 100%;
  height: auto;
  border-radius: 6px;
}

.berita-item h3 {
  margin-top: 10px;
  font-size: 1.1em;
}

.berita-item h3 a {
  color: #002147;
  text-decoration: none;
}

.berita-item h3 a:hover {
  text-decoration: underline;
}

/* Tombol Baca Selengkapnya */
.btn-selengkapnya {
  display: inline-block;
  margin-top: 10px;
  padding: 8px 16px;
  background-color: #0077cc;
  color: white;
  text-decoration: none;
  border-radius: 4px;
  font-size: 14px;
  transition: background-color 0.3s ease;
}

.btn-selengkapnya:hover {
  background-color: #005fa3;
}

/* PENELITIAN */
.penelitian-box ul {
  padding-left: 20px;
}

.penelitian-box ul li {
  margin-bottom: 8px;
}

/* PENGABDIAN */
.pengabdian-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.pengabdian-card {
  background-color: #f9f9f9;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  text-align: center;
}

.pengabdian-card img.pengabdian-img {
  width:100%;
  max-width: 400px;
  height: auto;
  border-radius: 8px;
  margin-bottom: 15px;
}

.section-intro {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 30px;
  line-height: 1.6;
}

/* FORM KOMENTAR */
#komentar {
  background-color: #f9fff9;
  padding: 20px;
  margin-top: 40px;
  border-top: 4px solid #228B22;
  font-size: 1em;
}

#komentar h3 {
  color: #006400;
  margin-bottom: 15px;
}

#form-komentar input,
#form-komentar textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 0.9em;
  margin-bottom: 10px;
}

#form-komentar button {
  background-color: #006400;
  color: white;
  padding: 10px 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.9em;
}

#form-komentar button:hover {
  background-color: #228B22;
}

/* KOMENTAR YANG TAMPIL */
#daftar-komentar {
  margin-top: 20px;
}

#daftar-komentar div {
  background-color: #f0f0f0;
  padding: 10px;
  border-left: 4px solid #228B22;
  margin-bottom: 10px;
  border-radius: 6px;
}

/* FOOTER */
footer {
  background-color: #002147;
  color: white;
  text-align: center;
  padding: 20px;
  margin-top: 40px;
}

/* RESPONSIF KHUSUS TABLET & MOBILE */
@media screen and (max-width: 576px) {
  .hero-text h1 {
    font-size: 16px;
  }

  header h1 {
    font-size: 16px;
  }

  .btn-selengkapnya {
    font-size: 12px;
    padding: 6px 12px;
  }

  #form-komentar input,
  #form-komentar textarea {
    font-size: 0.85em;
  }

  #form-komentar button {
    font-size: 0.85em;
  }
  }
