*, *::before, *::after {
  box-sizing: border-box;
}

/* --- GLOBAL VARIABLES --- */
:root {
  --primary-color: #345d9d;
  --primary-dark: #2c4f8a;
  --accent-color: #ffc107;
  --bg-light: #f8f9fa;
  --success-color: #10b981;
}

/* --- [FIX 1] RESET GLOBAL AGAR TIDAK MELEBAR --- */
html, body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden; /* Mencegah scroll ke samping */
  margin: 0;
  padding: 0;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background-color: #fff;
  position: relative;
}

/* --- [FIX 2] MENCEGAH GAMBAR APAPUN MERUSAK LAYOUT --- */
img {
  max-width: 100%;
  height: auto;
}

/* --- NAVBAR MODERN --- */
.navbar {
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 15px;
  padding-bottom: 15px;
  transition: all 0.3s ease;
}

.navbar-brand {
  font-size: 1.5rem;
  letter-spacing: 1px;
}

.nav-link {
  font-weight: 500;
  margin: 0 5px;
  position: relative;
  color: rgba(255, 255, 255, 0.8) !important;
  transition: color 0.3s;
}

.nav-link:hover,
.nav-link.active {
  color: #fff !important;
}

.nav-link::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: var(--accent-color);
  transition: width 0.3s ease-in-out;
}

.nav-link:hover::after {
  width: 100%;
}

.navbar-toggler {
  border-color: rgba(255, 255, 255, 0.5);
}
.navbar-toggler:focus {
  box-shadow: none;
}

/* --- HERO SECTION --- */
.hero-section {
  position: relative;
  background: linear-gradient(
      135deg,
      rgba(13, 20, 36, 0.95) 0%,
      rgba(52, 93, 157, 0.8) 100%
    ),
    url("<?= BASEURL; ?>/img/bghero.png") no-repeat center center;
  background-size: cover;
  background-attachment: fixed;

  /* --- [FIX 3] PASTIKAN HERO TIDAK LEBIH DARI LAYAR --- */
  width: 100%;
  max-width: 100vw; 
  overflow: hidden; /* Wajib ada untuk memotong shape */
  
  min-height: 100vh;
  display: flex;
  align-items: center; 
  justify-content: center;
  padding-top: 80px;
  padding-bottom: 80px;
}

/* Animasi Pulsa */
.animate-pulse {
  animation: pulse-glow 2s infinite;
}
@keyframes pulse-glow {
  0% {
    transform: scale(1);
    filter: drop-shadow(0 0 0 rgba(255, 255, 255, 0));
  }
  50% {
    transform: scale(1.05);
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.5));
  }
  100% {
    transform: scale(1);
    filter: drop-shadow(0 0 0 rgba(255, 255, 255, 0));
  }
}

.hero-shape {
  position: absolute;
  color: rgba(255, 255, 255, 0.05);
  z-index: 1;
  pointer-events: none;
  animation: floatHero 6s ease-in-out infinite;
}

.shape-1 {
  top: 15%;
  left: 5%;
  font-size: 4rem;
  animation-delay: 0s;
}
.shape-2 {
  bottom: 10%;
  right: 50%;
  font-size: 8rem;
  animation-delay: 2s;
}
.shape-3 {
  top: 20%;
  right: 10%;
  font-size: 3rem;
  animation-delay: 4s;
  opacity: 0.08;
}
.shape-4 {
  bottom: 10%;
  left: 10%;
  font-size: 5rem;
  animation-delay: 1s;
  opacity: 0.03;
}

@keyframes floatHero {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(5deg); }
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-badge {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(5px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 0.85rem;
}

.hero-title {
  font-weight: 800;
  letter-spacing: -1px;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.text-gradient {
  background: linear-gradient(to right, #fff, #50af95);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.btn-glow {
  background-color: var(--primary-color);
  border: none;
  box-shadow: 0 0 20px rgba(52, 93, 157, 0.5);
  transition: all 0.3s ease;
}

.btn-glow:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 30px rgba(52, 93, 157, 0.8);
  background-color: var(--primary-dark);
}

/* Hero Login Card */
.hero-login-card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 24px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.hero-form-control {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: white;
  padding: 12px 15px;
}

.hero-form-control:focus {
  background: rgba(255, 255, 255, 0.2);
  border-color: var(--success-color);
  color: white;
  box-shadow: none;
}
.hero-form-control::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

/* --- SECTION GENERAL --- */
section {
  padding: 80px 0;
}

.trust-badges img {
  height: 25px;
  opacity: 0.6;
  transition: opacity 0.3s;
  filter: grayscale(100%) brightness(200%);
}
.trust-badges img:hover {
  opacity: 1;
}

.status-img-main {
  transition: transform 0.3s ease;
}
.status-img-main:hover {
  transform: scale(1.02);
}

.current-status-wrapper {
  background: #fff;
  border: 1px solid #eef0f3;
  border-radius: 15px;
  padding: 25px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.03);
}

.current-status-box {
  background: linear-gradient(
    90deg,
    var(--primary-color) 0%,
    var(--primary-dark) 100%
  );
  color: white;
  border-radius: 10px;
  padding: 20px 30px;
  box-shadow: 0 10px 25px rgba(52, 93, 157, 0.25);
  transition: transform 0.3s ease;
}
.current-status-box:hover {
  transform: translateY(-2px);
}

/* --- PRICING SECTION --- */
.pricing-section {
  background-color: #fff;
}

.pricing-card {
  border: none;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.pricing-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(52, 93, 157, 0.15);
}

.pricing-header {
  background-color: var(--primary-color);
  color: white;
  padding: 30px 20px;
  text-align: center;
  border-bottom-left-radius: 20px;
  border-bottom-right-radius: 20px;
  margin-bottom: 20px;
}

.pricing-version {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  opacity: 0.8;
}
.pricing-price {
  font-size: 2.5rem;
  font-weight: 700;
  margin: 10px 0;
}

.pricing-features ul {
  list-style: none;
  padding: 0;
  margin: 0 20px 20px 20px;
}
.pricing-features li {
  padding: 12px 0;
  border-bottom: 1px dashed #e0e0e0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.95rem;
}
.pricing-features li:last-child {
  border-bottom: none;
}
.pricing-features span.value {
  font-weight: 700;
  color: #212529;
}

.btn-plan {
  background-color: white;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
  font-weight: 600;
  transition: all 0.3s;
}
.btn-plan:hover {
  background-color: var(--primary-color);
  color: white;
}

.pricing-card.popular {
  border: 2px solid var(--primary-color);
  position: relative;
}
.popular-badge {
  position: absolute;
  top: 15px;
  right: 15px;
  background-color: var(--accent-color);
  color: #fff;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: bold;
}

/* --- FAQ SECTION --- */
.faq-section {
  background-color: var(--bg-light);
}
.accordion-item {
  border: 1px solid #eef0f3;
  border-radius: 10px !important;
  margin-bottom: 15px;
  overflow: hidden;
}
.accordion-button {
  padding: 20px 25px;
  font-weight: 600;
}
.accordion-button:not(.collapsed) {
  color: var(--primary-color);
  background-color: #e6fcfc;
}
.accordion-body {
  color: #666;
  line-height: 1.6;
}

/* --- CONTACT SECTION --- */
.contact-card {
  background: #f8f9fa;
  border-radius: 20px;
  padding: 40px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}
.contact-icon {
  width: 50px;
  height: 50px;
  background-color: rgba(52, 93, 157, 0.1);
  color: var(--primary-color);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-right: 20px;
  flex-shrink: 0;
}
.contact-info-item {
  display: flex;
  align-items: start;
  margin-bottom: 30px;
}

/* --- RESPONSIVE MEDIA QUERIES --- */

/* Tablet & Mobile Devices (Width < 992px) */
@media (max-width: 991.98px) {
  .hero-section {
    align-items: flex-start !important;
    padding-top: 160px !important;
    height: auto !important;
    min-height: 100vh;
    padding-bottom: 120px !important;
  }
  .hero-title {
    font-size: 2.2rem !important;
  }

  .hero-element {
    margin-bottom: 25px;
  }
  .hero-content .d-flex.justify-content-center.justify-content-lg-start {
    justify-content: center !important;
  }

  .hero-content .trust-badges.justify-content-lg-start {
    justify-content: center !important;
  }

  .hero-login-card {
    margin-top: 40px;
  }

  .status-img-container {
    padding-left: 0 !important;
    margin-bottom: 30px;
  }

  .pricing-card {
    margin-bottom: 20px;
  }
}

/* Mobile Devices (Width < 768px) */
@media (max-width: 767.98px) {
  /* --- [FIX 4] PERBAIKAN GRID BOOTSTRAP DI HP --- */
  .container, .container-fluid {
    padding-right: 15px;
    padding-left: 15px;
    overflow-x: hidden; /* Jaga-jaga elemen bandel */
  }
  
  /* Mematikan margin negatif row yang sering bikin layout melebar */
  .row {
    margin-right: 0 !important;
    margin-left: 0 !important;
  }

  .hero-title {
    font-size: 1.8rem !important;
  }
  .hero-section {
    padding-top: 140px !important;
  }
  
  /* Navbar */
  .navbar-collapse {
    background: rgba(15, 23, 42, 0.98);
    padding: 20px;
    border-radius: 10px;
    margin-top: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
  }

  .navbar-nav .nav-link {
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  /* Wallet/Transfer Section Responsive */
  .card-body .input-group {
    flex-direction: column;
  }

  .card-body .input-group input {
    width: 100% !important;
    border-radius: 50rem !important;
    margin-bottom: 10px;
    padding-left: 20px;
    text-align: center;
  }

  .card-body .input-group .input-group-text {
    display: none;
  }

  .card-body .input-group button {
    width: 100% !important;
    margin: 0 !important;
  }

  .card-body .row > .col-md-4 {
    border-right: none !important;
    border-bottom: 1px solid #eee;
    margin-bottom: 10px;
  }

  /* Typography */
  h1.display-3 {
    font-size: 2.2rem;
  }
  h2.display-5 {
    font-size: 1.8rem;
  }
  .lead {
    font-size: 1rem !important;
  }

  .shape-2 {
    font-size: 4rem;
    opacity: 0.05;
  }
  .shape-1 {
    font-size: 2rem;
    top: 10%;
  }

  /* Section Spacing */
  section {
    padding: 50px 0;
  }

  /* Current Status Box */
  .current-status-box .row .col-6 {
    text-align: center;
  }
}