/* === 💻 Perbaikan untuk Tablet Landscape & Foldable (800px–1300px) === */
@media (min-width: 800px) and (max-width: 1300px) {
  header {
    padding: 10px 24px;
    width: calc(100% - 30px);
    z-index: 2200;
  }

  .logo img {
    width: 80px;
    height: 80px;
  }

  .logo span {
    font-size: 1.6rem;
  }

  nav a, .dropbtn {
    padding: 8px 14px;
    font-size: 0.9rem;
  }

  .hero {
    min-height: 70vh;
    background-size: cover;
    padding: 60px 30px;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero h2 {
    font-size: 1.2rem;
  }

  .feature-list {
    gap: 10px;
    padding: 0 40px;
  }

  .feature {
    flex: 0 0 220px;
  }

  
  .floating-stats {
    top: auto;
    bottom: 120px;
    left: auto;
    right: 20px;
    transform: scale(0.9);
  }

  .floating-map {
    bottom: 40px;
    right: 20px;
    width: 150px;
    height: 100px;
  }

  .fab-right {
    right: 0;
    top: 20%;
    transform: translateY(-50%) scale(0.9);
  }
}

/* === 💻 Mode iPad & Tablet (Navbar tetap horizontal & elegan) === */
@media (min-width: 768px) and (max-width: 1024px) {
  header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 40px;
    gap: 15px;
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(8px);
    border-radius: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    z-index: 2200;
  }

  .logo {
    display: flex;
    align-items: center;
    gap: 10px;
  }

  .logo img {
    width: 70px;
    height: 70px;
  }

  .logo span {
    font-size: 1.5rem;
    font-weight: 600;
    color: #2d5cff;
  }

  nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
  }

  nav a, .dropbtn {
    font-size: 0.95rem;
    padding: 7px 14px;
    border-radius: 12px;
    background: white;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
    transition: all 0.25s ease;
  }

  nav a:hover, .dropbtn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  }

  /* === 🌈 Dropdown Modern Elegan === */
.dropdown-content {
  position: absolute;
  top: 120%;                    /* muncul tepat di bawah tombol */
  left: 50%;
  transform: translateX(-50%) translateY(10px); /* sedikit turun sebelum animasi */
  min-width: 220px;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);  /* efek kaca */
  border-radius: 16px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: all 0.3s ease;
  z-index: 999;
}

/* Saat hover tampil dengan animasi lembut */
.dropdown:hover .dropdown-content {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

/* Isi link dropdown */
.dropdown-content a {
  display: block;
  text-align: left;
  font-size: 0.92rem;
  color: #333;
  padding: 10px 14px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.5);
  transition: all 0.25s ease;
}

/* Efek hover modern */
.dropdown-content a:hover {
  background: linear-gradient(135deg, #e0e7ff, #f0f4ff);
  color: #2d5cff;
  transform: translateX(3px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* Tambahan bayangan dan batas atas lembut */
.dropdown::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 8px solid transparent;
  border-top-color: rgba(255, 255, 255, 0.85); /* segitiga kecil di atas */
  filter: drop-shadow(0 -2px 4px rgba(0,0,0,0.1));
}


  /* Hilangkan hamburger & sidebar */
  .hamburger, .sidebar {
    display: none !important;
  }

  /* Floating items */
  .floating-stats {
    left: 24px;
    bottom: 110px;
    transform: scale(0.95);
  }

  .floating-map {
    bottom: 30px;
    right: 24px;
    width: 140px;
    height: 100px;
  }

  .fab-right {
    right: 0;
    top: 50%;
    transform: translateY(-50%) scale(0.9);
  }
}

/* === 💻 Tablet Landscape & Foldable (800px–1300px) === */
@media (min-width: 800px) and (max-width: 1300px) {
  .floating-stats {
    position: fixed;
    bottom: 110px;
    left: 24px;
    background: transparent;
    border-radius: 12px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.15);
    padding: 8px 12px;
    font-size: 0.85rem;
    width: 150px;
    display: flex !important;
    flex-direction: column;
    gap: 4px;
    transform: scale(0.9);
    z-index: 999;
  }
  .animated-text {
  width: 200px;       /* lebar tetap agar menu tidak tergeser */

  font-weight: 600;
  font-size: 1rem;
  color: #ff4081;
  display: inline-block;
  opacity: 0;
  transition: opacity 1s ease;
}
.fab-right {
    right: 0;
    top: 15%;
    transform: translateY(-50%) scale(0.9);
  }



  .floating-stats .stat-item {
    white-space: nowrap;
  }

  .floating-map {
    position: fixed;
    bottom: 40px;
    right: 24px;
    width: 90px;
    height: 65px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    display: block !important;
    z-index: 999;
  }

  .floating-map iframe {
    width: 100%;
    height: 100%;
    border: none;
  }
}

/* === 💻 iPad Air & Tablet (768px–1024px) === */
@media (min-width: 768px) and (max-width: 1024px) {
  .floating-stats {
    position: fixed;
    bottom: 95px;
    left: 20px;
    background: transparent;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.12);
    padding: 6px 10px;
    font-size: 0.8rem;
    width: 150px;
    display: flex !important;
    flex-direction: column;
    gap: 3px;
    transform: scale(0.85);
    z-index: 999;
  }

  .floating-map {
    position: fixed;
    bottom: 25px;
    right: 20px;
    width: 80px;
    height: 60px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0,0,0,0.12);
    display: block !important;
    z-index: 999;
  }
}
/* === 📱 Asus Zenfone Fold / Foldable kecil (850px–950px) === */
@media (min-width: 850px) and (max-width: 950px) {
  
  /* --- Floating Stats --- */
  .floating-stats {
    position: fixed;
    bottom: 85px;
    left: 18px;
    width: 150px;
    padding: 6px 9px;
    background: transparent;
    border-radius: 10px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: 0.78rem;
    transform: scale(0.85);
    z-index: 999;
  }

  /* --- Dropdown Utama --- */
  .dropdown-mobile {
    margin-bottom: 16px;
  }

  .dropdown-toggle {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    width: 100%;
    padding: 12px 16px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    color: #000;
    text-align: left;
    transition: all 0.35s ease;
    perspective: 500px;
  }

  .dropdown-toggle:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 12px rgba(0,0,0,0.2);
  }

  /* Dropdown Menu */
  .dropdown-menu {
    display: none;
    flex-direction: column;
    margin-top: 6px;
    gap: 6px;
    padding: 8px 10px;
    border-radius: 12px;
    transition: all 0.35s ease;
  }

  .dropdown-mobile.active .dropdown-menu {
    display: flex;
    opacity: 1;
  }

  .dropdown-menu a {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 10px;
    font-weight: 500;
    font-size: 0.95rem;
    color: #111;
    background: #fff;
    text-decoration: none;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    transition: all 0.35s ease;
  }

  .dropdown-menu a:hover {
    transform: translateX(3px);
    background: royalblue;
    color: #fff;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
  }

  /* --- Submenu --- */
  .dropdown-submobile {
    margin-top: 6px;
  }

  .dropdown-subtoggle {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    width: 100%;
    padding: 10px 14px;
    border-radius: 12px;
    font-weight: 600;
    color: #000;
    cursor: pointer;
    text-align: left;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    transition: all 0.35s ease;
  }

  .dropdown-subtoggle:hover {
    transform: scale(1.01);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  }

  .dropdown-subtoggle::after {
    content: "+";
    font-size: 0.9rem;
    transition: transform 0.35s ease;
  }

  .dropdown-subtoggle.active::after {
    transform: rotate(180deg);
  }

  /* Submenu Items */
  .dropdown-submenu {
    display: none;
    flex-direction: column;
    margin-left: 10px;
    margin-top: 9px;
    gap: 6px;
  }

  .dropdown-submenu.show {
    display: flex;
    opacity: 1;
    transition: all 0.35s ease;
  }

  .dropdown-submenu a {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 10px;
    font-weight: 500;
    font-size: 0.9rem;
    color: #fff;
    background: #3a5998;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    transition: all 0.35s ease;
  }

  .dropdown-submenu a:hover {
    transform: translateX(3px);
    background: #2e4a8c;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
  }

  .dropdown-submenu a i {
    min-width: 18px; /* biar ikon sejajar */
    text-align: center;
  }

  /* --- Floating Map --- */
  .floating-map {
    position: fixed;
    bottom: 20px;
    right: 18px;
    width: 70px;
    aspect-ratio: 7 / 5;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
    display: block;
    z-index: 999;
  }

}


/* === 📱 HP & Small Fold (≤820px) === */
@media (max-width: 820px) {
  .floating-stats {
    position: fixed;
    bottom: 90px;
    left: 12px;
    background: transparent;
    border-radius: 10px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
    padding: 6px 8px;
    font-size: 0.75rem;
    width: 150px;
    display: flex !important;
    flex-direction: column;
    gap: 3px;
    transform: scale(0.9);
    z-index: 1000;
  }

  .floating-map {
    position: fixed;
    bottom: 18px;
    right: 12px;
    width: 65px;
    height: 50px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
    display: block !important;
    z-index: 1000;
  }

  .floating-map iframe {
    width: 100%;
    height: 100%;
    border: none;
  }
}

/* === 💡 ASUS Zenfone Fold (Full Unfold Mode ~1200px–1550px) === */
@media (min-width: 1200px) and (max-width: 1550px) {
  .floating-stats {
    position: fixed;
    bottom: 100px;
    left: 30px;
    background: transparent;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    padding: 8px 14px;
    font-size: 0.85rem;
    width: 160px;
    display: flex !important;
    flex-direction: column;
    gap: 5px;
    transform: scale(0.95);
    z-index: 999;
  }

  .floating-map {
    position: fixed;
    bottom: 35px;
    right: 30px;
    width: 100px;
    height: 75px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    display: block !important;
    z-index: 999;
  }

  .floating-map iframe {
    width: 100%;
    height: 100%;
    border: none;
  }
}
/* === 💻 iPad Air & iPad Pro (820px–1180px) === */
@media (min-width: 820px) and (max-width: 1180px) {
  .floating-stats {
    position: fixed;
    bottom: 120px;           /* naik sedikit agar terlihat lebih tinggi */
    left: 28px;
    background: transparent;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    padding: 10px 14px;
    font-size: 0.9rem;       /* lebih besar agar terbaca jelas */
    width: 170px;            /* sedikit lebih lebar */
    display: flex !important;
    flex-direction: column;
    gap: 5px;
    transform: scale(1);
    z-index: 999;
  }

  .floating-map {
    position: fixed;
    bottom: 30px;            /* naik sedikit */
    right: 28px;
    width: 90px;            /* diperbesar agar seimbang */
    height: 85px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.12);
    display: block !important;
    z-index: 999;
  }

  .floating-map iframe {
    width: 100%;
    height: 100%;
    border: none;
  }
}
/* === 🎨 Perbaikan Hero untuk iPad (Agar gambar tidak terpotong) === */
@media (min-width: 768px) and (max-width: 1180px) {
  .hero {
    margin: 0;
    border-radius: 10px 10px 10px 10px;
    padding: 0 16px; /* biar gambar full tanpa jarak */
    height: 40vh;
    min-height: 25vh;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center center;
    background-attachment: scroll;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .hero h1 {
    font-size: 2rem;
  }
.logo span {
    font-size: 1rem;
  }
  .hero h2 {
    font-size: 1.1rem;
  }
}
/* === 📱 Surface Duo (dua layar, layar kecil tapi lebar) === */
@media (min-width: 540px) and (max-width: 720px) {
  .hero {
     margin: 0;
    border-radius: 10px 10px 10px 10px;
    padding: 0 16px; /* biar gambar full tanpa jarak */
    height: 40vh;
    min-height: 25vh;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center center;
    background-attachment: scroll;
    display: flex;
    align-items: center;
    justify-content: center;
  }
 .logo span {
    font-size: 1rem;
  }

  .hero h1 {
    font-size: 1.8rem;
  }

  .hero h2 {
    font-size: 1rem;
  }
}
/* === 📱 iPad Air / iPad Mini Portrait (768px–1023px) === */
@media (min-width: 768px) and (max-width: 1023px) and (orientation: portrait) {
  
  /* ===== Sembunyikan navbar horizontal ===== */
  nav, .dropbtn {
    display: none !important;
  }

  /* ===== Hamburger Menu ===== */
  .hamburger {
    display: flex !important;
    flex-direction: column;
    justify-content: space-between;
    position: fixed;
    top: 35px;
    right: 25px;
    width: 35px;
    height: 28px;
    z-index: 2300;
    cursor: pointer;
    transition: all 0.3s ease;
  }

  .hamburger span {
    display: block;
    height: 4px;
    background: #007bff;
    border-radius: 2px;
    transition: all 0.3s ease;
  }

  /* Hamburger animasi menjadi "X" saat aktif */
  .hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }
  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }
  .hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }

  /* ===== Sidebar ===== */
.sidebar {
  display: block !important;
  position: fixed;
  top: 0;
  left: -280px; /* mulai di luar layar */
  width: 280px;
  height: 100%;
  background: #fff;
  box-shadow: 3px 0 12px rgba(0,0,0,0.15);
  transition: left 0.3s ease;
  z-index: 2299;
  padding: 60px 20px 20px 20px; /* <== tambah padding top 60px */
  overflow-y: auto;
}




  .sidebar.active {
    left: 0;
  }

 /* Tombol Close tetap di atas kanan */
.sidebar-close {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.05);
  color: #007bff;
  font-size: 20px;
  text-align: center;
  line-height: 32px;
  cursor: pointer;
  z-index: 2400;
  transition: all 0.3s ease;
}

  .sidebar-close:hover {
    background: #007bff;
    color: #fff;
  }

  /* ===== Overlay saat Sidebar Aktif ===== */
  .sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.3);
    z-index: 2298;
    transition: opacity 0.3s ease;
  }
  .sidebar-overlay.active {
    display: block;
  }

}

/* --- 1. Perbaikan Umum untuk Ponsel & Tablet Landscape (Lebar Max 1300px) --- */
@media (max-width: 1300px) and (orientation: landscape) {

  /* 💡 PERBAIKAN HERO UTAMA: Tinggi fleksibel & Gambar Anti-Potong */
  .hero {
    height: auto !important; 
    min-height: 40vh !important; /* Min-height rendah agar konten terlihat */
    
    /* 🖼️ KUNCI FIX GAMBAR: Lapisan Ganda */
    /* Lapisan 1: Gambar utama (contain, agar TIDAK terpotong) */
    /* Lapisan 2: Gradien (mengisi ruang kosong) */
    background-image: url('https://lh3.googleusercontent.com/pw/AP1GczMAg4shxHdsLFkIK6rAviI0TUNQpo2aYDkQIlgvDoOErZ45tpSG5-rqdFBwYkOFk17V9xEpXMUcUyF-VtSrtmuKvcQAA0gwP7WKCErGw_UF5JPmTGQUll3ANuYc1hpLo5Qtc_tVkyYgIsBEHfXZVi-s=w1024-h585-s-no-gm?authuser=0'), 
linear-gradient(135deg, #fff, #fff);    background-size: contain, cover; /* Gambar utama: contain, Gradien: cover */
    background-repeat: no-repeat, no-repeat;
    background-position: center center, center center;
    
    padding: 30px 20px !important; 
    margin: 10px !important; 
  }

  /* Konten Hero: Ukuran font disesuaikan agar ringkas */
  .hero h1 {
    font-size: 1.6rem !important;
    color: royalblue;
  }
  .hero h2 {
    font-size: 1rem !important;
    color: royalblue;
  }
  .hero p {
    font-size: 1rem !important;
    color: royalblue;
  }
  /* ... dan penyesuaian font/padding lainnya ... */
}