/* Landing page custom styles — refactored for spacing, cards, forms, and responsiveness */

:root {
  --primary: #1a237e;
  --muted: #6c757d;
}

body {
  font-family: "Poppins", sans-serif;
  background: #f5f7fb;
  padding-top: 72px; /* space for fixed navbar */
  font-size: 15px; /* slightly smaller base font */
}

/* NAVBAR */
.navbar {
  background: white;
}
.navbar-brand span {
  font-weight: 600;
  font-size: 15px;
  /* follow navbar's default text color */
  color: inherit;
}
.navbar-brand .logo-img {
  height: 28px;
  width: auto;
}
@media (min-width: 768px) {
  .navbar-brand .logo-img {
    height: 36px;
  }
  .hero-section .btn {
    padding: 0.6rem 1.25rem;
  }
}
.nav-link {
  font-weight: 500;
  margin-left: 12px;
  color: var(--primary) !important;
}

/* HERO */
.hero-section {
  background:
    linear-gradient(to right, rgba(63, 81, 181, 0.85), rgba(26, 35, 126, 0.85)),
    url("https://images.unsplash.com/photo-1517700768478-654dbbdfb472?q=80&w=2000")
      center/cover;
  color: white;
  min-height: 60vh;
  padding: 3.5rem 0;
  display: flex;
  align-items: center;
  margin-top: -58px;
}
.hero-section h1 {
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1.05;
  font-size: 2rem; /* desktop size restored */
}
.hero-section p {
  max-width: 640px;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

/* Use Bootstrap primary color override */
.btn-primary {
  background: var(--primary);
  border-color: var(--primary);
}
.btn-primary:hover {
  background: #0e145a;
  border-color: #0e145a;
}

/* Hero CTA sizing */
.hero-section .btn {
  padding: 0.5rem 1rem;
}

/* SECTIONS */
section {
  padding: 3rem 0;
}
.section-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem; /* reduced spacing */
  color: #333;
  margin-top: -5px;
}

/* ALUR CARD */
.card-alur {
  background: white;
  padding: 1rem;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.06);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}
.card-alur:hover {
  transform: translateY(-6px);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
}
.icon-box {
  width: 64px;
  height: 64px;
  background: #eef1ff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: auto;
  margin-bottom: 12px;
  font-size: 20px;
  color: var(--primary);
}
.card-alur h6 {
  font-weight: 600;
  margin-bottom: 8px;
}
.card-alur p {
  font-size: 14px;
  color: var(--muted);
}

/* Ensure icon, title and description are aligned consistently across cards */
.card-alur {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  gap: 0.5rem;
}
.card-alur h6 {
  min-height: 48px; /* reserve space so titles line up */
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.25rem;
}
.card-alur p {
  margin: 0;
  margin-top: 0.25rem;
}
/* card head grouping */
.card-head {
  min-height: 88px;
}
/* description justification and spacing */
.card-desc {
  text-align: center;
}

/* Reduce spacing between alur cards and make gutters consistent */
#alur .row {
  --bs-gutter-x: 0.75rem;
  --bs-gutter-y: 0.75rem;
}

/* STAT */
.section-gray {
  background: #f3f5fa;
}
.section-gray .section-title {
  margin-top: -40px; /* naikkan judul sekitar 25px */
}

/* Lift the Cek Status section title to align visually */
#cek-status .section-title {
  margin-top: -40px; /* naikkan sekitar 40px pada desktop */
}
.card-stat {
  background: white;
  padding: 1rem;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.05);
  min-height: 160px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.card-stat h6 {
  color: var(--muted);
  font-weight: 600;
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.card-stat h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
}

/* CHART */
.chart-card {
  background: white;
  padding: 1rem;
  border-radius: 12px;
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.05);
}

/* Ensure the stat cards use the same grid gutters as the chart row
   so horizontal/vertical spacing between cards appears consistent */
.section-gray .row {
  --bs-gutter-x: 1.5rem;
  --bs-gutter-y: 1.5rem;
}
canvas {
  max-height: 260px;
  width: 100% !important;
}

/* CEK STATUS */
.cek-box {
  display: flex;
  gap: 0.5rem;
  background: transparent;
  border-radius: 8px;
  margin-bottom: 1rem;
}
.cek-box .form-control {
  border-radius: 10px;
  padding: 0.45rem 0.65rem; /* slightly smaller input height */
}
.cek-box .btn {
  border-radius: 10px;
  padding: 0.45rem 0.85rem;
  width: 10px;
}

/* FOOTER */
.footer-top {
  background: #e8eaf6;
  padding: 3rem 0;
}
.footer-bottom {
  background: var(--primary);
  color: white;
  text-align: center;
  padding: 0.9rem 0;
}
.social {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.social a {
  text-decoration: none;
  color: #333;
}

/* Responsive tweaks */
@media (max-width: 767.98px) {
  .hero-section {
    padding-top: 2rem;
    padding-bottom: 2rem;
    min-height: 50vh;
    margin-top: -65px;
  }
  .section-gray .section-title {
    margin-top: -12px;
  }
  #cek-status .section-title {
    margin-top: -18px;
  }
  .hero-section h1 {
    font-size: 1.25rem; /* smaller on mobile only */
  }
  .hero-section p {
    font-size: 0.95rem; /* paragraph smaller on mobile */
  }
  section {
    padding: 1rem 0;
  }
  .section-title {
    font-size: 1.25rem;
  }
  .card-alur {
    padding: 1rem;
  }
  .cek-box {
    flex-direction: column;
    gap: 0.75rem;
  }
  .cek-box .btn {
    width: 100%;
  }
  /* Make placeholder smaller on mobile so it doesn't wrap/cut visually */
  .cek-box .form-control::placeholder {
    font-size: 0.85rem;
  }

  /* Tighten footer contact spacing on mobile */
  .footer-top .col-md-7 h5 {
    margin-bottom: 0.25rem;
  }
  .footer-top .col-md-7 p {
    margin-bottom: 0.35rem;
  }
}

/* Nudge footer contact block slightly down on desktop so it aligns with media column */
@media (min-width: 768px) {
  .footer-top .col-md-7 {
    margin-top: 0.45rem;
  }
}
