.top-bar {
  display: flex;
  justify-content: space-between; /* kiri-kanan */
  align-items: center;
  padding: 0 16px;
  position: sticky;
  top: 0;
  background: #141414;
  backdrop-filter: blur(6px);
  z-index: 50;
  height: 64px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  overflow-x: auto; /* Tambahan supaya tidak keluar viewport */
}

/* === Kiri: gambar + judul === */
.left-group {
  display: flex;
  align-items: center;
  gap: 8px; /* jarak antara gambar dan teks */
  flex-shrink: 0; /* jangan menyusut */
}

.back-btn {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.back-btn img {
  width: 28px;
  height: 28px;
}

.app-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: #01baa7;
  white-space: nowrap; /* supaya teks tidak wrap */
  text-decoration: none;
}

a {
  text-decoration: none;
}

/* === Right group: tabs / buttons === */
.right-group {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.tab-btn {
  background: none;
  border: none;
  padding: 6px 12px;
  cursor: pointer;
  color: #ccc;
  font-size: 14px;
  border-radius: 6px;
  transition: background 0.2s, color 0.2s;
}

.tab-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

/* === How It Works Section === */
.howitworks-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
}

.howitworks-text p {
  color: #aaa;
}

.howitworks-code pre {
  background: #1a1a1a;
  padding: 1rem;
  border-radius: 8px;
  max-width: 100%;       /* jangan keluar viewport */
  overflow-x: auto;       /* scroll horizontal kalau perlu */
  white-space: pre;       /* pertahankan formatting desktop */
  font-size: 0.875rem;
  word-wrap: normal;
  word-break: normal;
}

/* scrollbar lebih rapih di desktop */
.howitworks-code pre::-webkit-scrollbar {
  height: 6px;
}

.howitworks-code pre::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.2);
  border-radius: 3px;
}

.howitworks-code pre::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.05);
}

/* === Responsif: layar kecil === */
@media (max-width: 600px) {
  .howitworks-code pre {
    white-space: pre-wrap;   /* wrap otomatis */
    word-break: break-word;   /* jangan overflow */
    overflow-x: hidden;       /* hilangkan scroll */
    font-size: 0.8rem;
  }
}



/* ===== FOOTER ===== */
.footer {
  align-item: center;
  background-color: #000;
  color: #ccc;
  padding: 60px 30px;
  font-family: Arial, sans-serif;
}

.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-column h3 {
  color: #fff;
  font-size: 16px;
  margin-bottom: 16px;
  font-weight: 600;
}

.footer-column ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-column ul li {
  margin-bottom: 8px;
}

.footer-column ul li a {
  text-decoration: none;
  color: #aaa;
  font-size: 28px;
  transition: color 0.2s ease;
}

.footer-column ul li a:hover {
  color: #fff;
}

.social-links li a {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-bottom {
  align-item: center;
  text-align: center;
  font-size: 13px;
  color: #777;
  margin-top: 40px;
  border-top: 1px solid #222;
  padding-top: 20px;
}

/* === Responsif === */
@media (max-width: 900px) {
  .howitworks-section {
    grid-template-columns: 1fr;
  }

  .top-bar {
    padding: 0 12px;
  }

  .app-title {
    font-size: 1rem;
  }

  .tab-btn {
    padding: 4px 8px;
    font-size: 12px;
  }
}

@media (max-width: 600px) {
  .footer {
    padding: 40px 20px;
  }

  .footer-container {
    gap: 20px;
  }

  .footer-column h3 {
    font-size: 15px;
  }

  .footer-column ul li a {
    font-size: 13px;
  }
}


.layout main, .layout aside {
  max-height: calc(100vh - 180px); /* viewport minus header/footer */
  overflow-y: auto;
  overflow-x: auto; /* horizontal scroll kalo terlalu lebar */
  padding-right: 12px;
  word-break: break-word; /* kata panjang tetap rapi */
}