/* Setting */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}
mark {
  background-color: #cce5ff; /* biru pastel */
  color: #003366; /* navy text */
  padding: 4px 12px;
  border-radius: 8px;
  font-weight: 600;
  width: auto;
}
:root {
  --primary-blue: #0056b3;
  --secondary-green: #28a745;
  --light-bg: #f4f7f6;
  --dark-text: #333;
  --white: #ffffff;
}

body {
  line-height: 1.6;
  color: var(--dark-text);
}

/* --- Desktop: Sembunyikan Hamburger --- */
.hamburger {
  display: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  z-index: 1001; /* pastikan atas menu */
}

.hamburger .bar {
  width: 25px;
  height: 3px;
  background-color: var(--white);
  transition: 0.3s;
}

/* --- Mobile & Tablet (max 768px) --- */
@media (max-width: 768px) {
  
  header {
    flex-direction: column;
    padding: 1rem;
    position: relative;
  }

  .hamburger {
    display: flex; /* Tunjukkan hamburger */
  }

  nav ul {
    position: absolute;
    top: 70px; /* ikut tinggi header */
    left: -100%; /* sembunyi di luar skrin kiri */
    flex-direction: column;
    background-color: var(--primary-blue);
    width: 100%;
    text-align: center;
    transition: left 0.3s ease; /* animasi slide */
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    padding: 20px 0;
  }

  nav ul.active {
    left: 0; /* slide masuk */
  }

  nav ul li {
    margin: 15px 0;
    position: relative;
  }
  nav ul li .dropdown {
    display: none;
    position: absolute;
    top: 100%; /* bawah parent link */
    left: 0;
    background: var(--primary-blue);
    padding: 10px 0;
    border-radius: 6px;
    min-width: 180px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  }

  nav ul li:hover .dropdown {
    display: block;
  }
  nav ul li .dropdown li {
    margin: 0;
  }

  nav ul li .dropdown a {
    display: block;
    padding: 8px 15px;
    color: #fff;
    text-decoration: none;
  }

  nav ul li .dropdown a:hover {
    background: #003366;
  }

  /* dropdown klik */
  nav ul li .dropdown {
    display: none;
  }
  nav ul li .dropdown.show {
    display: block;
  }

  .slideshow,
  .slider-container {
    width: 100%;
    height: auto;
  }
  .slide {
    max-height: 40vh;
    object-fit: contain;
    /*height: 250px; /* sesuaikan ketinggian untuk mobile */
  }

  .row {
    flex-direction: column;
    text-align: center;
  }
  .col {
    width: 100%;
  }
  h2 {
    font-size: 1.5rem;
  }
}

/* --- Animasi Hamburger jadi 'X' --- */
.hamburger.is-active .bar:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.hamburger.is-active .bar:nth-child(2) {
  opacity: 0;
}
.hamburger.is-active .bar:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* Navigation */
header {
  background: var(--primary-blue);
  color: var(--white);
  padding: 0.5rem 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 1000;
}

.logo img {
  width: auto;
  height: 50px;
  border-radius: 50%;
}

.logo {
  display: flex;
  gap: 15px;
  font-style: italic;
  font-size: small;
  font-weight: bold;
  align-items: center;
}
nav ul {
  list-style: none;
  display: flex;
}

nav ul li {
  position: relative;
  margin-left: 20px;
}

nav ul li a {
  color: var(--white);
  text-decoration: none;
  font-weight: bold;
}

nav ul li a:hover {
  background-color: rgba(255, 255, 255, 0.1);
  padding: 4px 12px;
  border-radius: 8px;
  width: auto;
}

/* Style the active link with an underline */
nav ul li a:current {
  text-decoration: underline; /* Adds an underline to the current page link */
  color: white;
}

nav ul li .dropdown {
  display: none; /*hide the sub menu*/
  position: absolute;
  top: 100%;
  left: 0;
  background-color: var(--primary-blue);
  list-style: none;
  padding: 10px 0;
  min-width: 150px;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
  z-index: 1001;
}

nav ul li .dropdown li a {
  padding: 10px;
  display: block;
  font-size: 0.9rem;
  white-space: nowrap;
}

nav ul li .dropdown li a:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

nav ul li:hover .dropdown {
  display: block;
}

/* slideshow */
.slideshow {
  margin: auto;
  width: 100%;
}
.slide {
  width: 100%;
  height: 500px;
  margin: auto;
  object-fit: cover;
}

.btn {
  display: inline-block;
  background: var(--secondary-green);
  color: var(--white);
  padding: 10px 25px;
  text-decoration: none;
  border-radius: 5px;
  margin-top: 20px;
  border: none;
  cursor: pointer;
}

/* Content */
.content-section {
  padding: 60px 10%;
  text-align: justify;
}

.bg-light {
  background: var(--light-bg);
}

.row {
  display: flex;
  gap: 40px;
  align-items: center;
  margin-top: 30px;
}

.col {
  flex: 1;
}

.image-placeholder {
  background: #ccc;
  height: 200px;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: 8px;
}

/* Kad Pelancongan */
.card-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.card {
  background: var(--white);
  padding: 15px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  text-align: center;
}

/* Borang */
.contact-form {
  display: flex;
  flex-direction: column;
  max-width: 500px;
  margin: auto;
}

.contact-form input,
.contact-form textarea {
  margin-bottom: 15px;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 5px;
}

/* Footer */
footer {
  background: #222;
  color: var(--white);
  text-align: center;
  padding: 20px;
  font-size: 0.9rem;
}

footer a {
  color: white;
}

/* auni Tambah*/
.content-section {
  padding: 60px 8%;
}

.content-section h2 {
  font-size: 32px;
  margin-bottom: 15px;
  color: #0b3c5d;
}

.content-section p {
  line-height: 1.8;
  color: #333;
}

.row {
  display: flex;
  gap: 40px;
  align-items: center;
  margin-top: 40px;
  flex-wrap: wrap;
}

.col {
  flex: 1;
}

.col img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

h3 {
  color: #1d6fa5;
  margin-bottom: 10px;
}

.card:nth-child(1) .image-placeholder {
  background-image: url("https://i.pinimg.com/736x/96/e9/40/96e940d7c6109e642f141e481e40122c.jpg");
}

.card:nth-child(2) .image-placeholder {
  background-image: url("https://i.pinimg.com/1200x/2e/2a/02/2e2a02827dbfe90e289cf397bf85d63c.jpg");
}

.card:nth-child(3) .image-placeholder {
  background-image: url("https://i.pinimg.com/1200x/e8/0f/32/e80f322be4ffff6d971a7931322f906e.jpg");
}
.image-placeholder {
  width: 100%;
  height: 180px;

  background-size: cover; /* 🔥 fill penuh */
  background-position: center; /* 🔥 center betul-betul */
  background-repeat: no-repeat;

  border-radius: 12px;

  display: flex;
  align-items: center; /* center vertical */
  justify-content: center; /* center horizontal */

  color: white;
  font-weight: bold;
  font-size: 18px;

  position: relative;
}

.video-container {
  position: relative;
  width: 100%;
  max-width: 900px;
  margin: 20px auto 30px auto;
  padding-bottom: 40%; /* 16:9 ratio */
  height: 0;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 10px;
}

.colonial-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  font-size: 16px;
}

.colonial-table th,
.colonial-table td {
  border: 1px solid #ccc;
  padding: 12px;
  text-align: left;
  vertical-align: top;
}

.colonial-table th {
  background-color: #0f3d3e;
  color: #fff;
  font-weight: bold;
}

.colonial-table tr:nth-child(even) {
  background-color: #f4f7f7;
}

.colonial-table tr:hover {
  background-color: #e0f2f1;
}

/*alisha add*/
.pollution {
  margin: 0;
  padding: 12px;
  box-sizing: border-box;
  background-color: #8bb5e2;
  width: 100%;
  color: white;
  border-radius: 10px;
}

#environment .row .image-env img {
  width: 500px;
  height: 650px;
  border-radius: 12px;
}

#env {
  margin: 0;
  padding: 12px;
  box-sizing: border-box;
  background-color: #8bb5e2;
  color: white;
  border-radius: 10px;
  padding-left: 25px;
  width: 40%;
}

#oilspilled .row .image-oil img {
  width: 600px;
  height: 520px;
  border-radius: 12px;
}

#shipping .row .image-ship img {
  border-radius: 12px;
  height: 400px;
  width: 100%;
}

#trade .row .image-trade img {
  border-radius: 12px;
  height: 400px;
  width: 100%
}

#safety .row .image-safety img {
  width: 600px;
  height: 400px;
  border-radius: 12px;
}

/*SITEMAP PAGE*/

/* Center the title */
.sitemap-title {
  text-align: center;
  margin-bottom: 20px;
}

/* Root list */
main ul {
  list-style-type: disc;
  padding-left: 15px;
}

/* Home item (no bullet + vertical line) */
main ul li.home {
  list-style-type: none;
  position: relative;
}
#index {
  font-size: 20px;
}
main ul li.home::after {
  content: "";
  position: absolute;
  left: 10px;
  top: 1.6em;
  width: 2px;
  height: 400px; /* adjust to match sitemap length */
  background-color: #ccc;
}

/* Children bullets */
main ul li.home > ul > li {
  list-style-type: disc;
}

/* Subpoints bullets */
main ul ul {
  list-style-type: circle;
  margin-left: 20px;
}
/* Default link style (berbeza dari teks biasa) */
main ul li a {
  text-decoration: none;
  color: #0066cc; /* biru muted untuk beza dengan teks */
  transition: color 0.3s, text-decoration 0.3s;
  font-weight: inherit; /* ikut level (Home bold, children semi-bold, subpoints normal) */
}
main ul li a strong {
  color: inherit;
}

/* Visited link */
main ul li a:visited {
  color: #663399; /* ungu muted untuk link dah pernah klik */
}

/* Hover effect */
main ul li a:hover {
  color: #cc0000; /* merah muted bila hover */
  text-decoration: underline;
}

/* Active (clicked) */
main ul li a:active {
  color: #ff6600; /* oren bila ditekan */
}

/* END OF SITEMAP PAGE */

/* --- REKABENTUK UNTUK TELEFON & TABLET (Skrin bawah 768px) ---
simpan jap notepad */

/* =========================
   Section 1: Contact Info + Map
   ========================= */
.contact-info-section {
  background-color: #0b3c5d; /* Navy laut */
  color: #fff; /* Putih – jelas & profesional */
  padding: 60px 10%;
}

.contact-container {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  align-items: flex-start;
}

.contact-details {
  flex: 1;
  min-width: 250px;
}

.contact-details h2 {
  font-size: 2rem;
  margin-bottom: 20px;
}

.contact-details p {
  margin-bottom: 10px;
}

.external-link {
  color: #33ccff;              /* biru khas */
  font-weight: 600;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color 0.3s ease, border-bottom 0.3s ease;
}

.external-link:hover {
  color: #ff6600;              /* tukar oren bila hover */
  border-bottom: 2px solid #ff6600; /* underline animasi */
}

.contact-map {
  flex: 1;
  min-width: 300px;
}

.contact-map iframe {
  width: 100%;
  height: 300px;
  border-radius: 10px;
}

/* Social box */
.social-box {
  background-color: #f5faff;
  border: 1px solid #cce0ff;
  border-radius: 10px;
  padding: 20px;
  margin-top: 20px;
  text-align: center;
}

.social-title {
  color: #0066cc;
  font-weight: 600;
  font-size: 1.1em;
  margin: 0 0 15px;
}

.social-icons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}

.social-icons a.icon {
  display: inline-block;
  width: 45px;
  height: 45px;
  background-color: #0066cc;
  color: #fff;
  border-radius: 50%;
  text-align: center;
  line-height: 45px;
  font-size: 20px;
  transition: background-color 0.3s, transform 0.3s;
}

.social-icons a.icon:hover {
  background-color: #cc0000;
  transform: scale(1.1);
}

/* =========================
   Section 2: Contact Form
   ========================= */
.contact-form-section {
  padding: 60px 10%;
  background-color: #0c5b97; /* Light Navy */
}

.contact-form-container {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  align-items: flex-start;
}

.form-box {
  flex: 1 1 400px;
  background-color: #fff;
  border-radius: 10px;
  padding: 30px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.form-box h2 {
  margin-bottom: 20px;
  color: #0b3c5d;
}

.form-group {
  margin-bottom: 20px;
  text-align: left;
}

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  color: #333;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: none;
  border-bottom: 1px solid #999;
  padding: 8px 5px;
  font-size: 16px;
  background: transparent;
  outline: none;
  transition: border-color 0.3s;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-bottom: 1px solid #0b3c5d;
}

.error {
  color: #cc0000;
  font-size: 0.9em;
}

.btn {
  background-color: #0b3c5d;
  color: #fff;
  border: none;
  padding: 10px 20px; /* lebih kecil, tak penuh ruang */
  border-radius: 50px;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s;
  display: inline-flex; /* align icon + text */
  align-items: center; /* vertical center */
  justify-content: center; /* horizontal center */
  gap: 8px; /* jarak antara text dan gif */
  width: auto; /* ikut content, bukan penuh */
  min-width: 120px; /* bagi nampak cantik, tak terlalu pendek */
  text-align: center;
}

.btn:hover {
  background-color: #003366;
}

.form-image {
  flex: 1 1 400px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.form-image img {
  max-width: 100%;
  border-radius: 10px;
}

/* Success + Loading */
.success-box {
  padding: 30px;
  background-color: #e6f4ff;
  border-left: 5px solid #0b3c5d;
  border-radius: 8px;
  color: #0b3c5d;
  font-size: 1.1em;
  font-weight: 500;
  text-align: center;
  animation: fadeIn 0.5s ease-in-out;
}

.loading-gif {
  height: 20px;
  margin-left: 8px;
  vertical-align: middle;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
