/* =========================================================
   HEZA Solusi Utama - Custom Styles
   Warna diambil dari logo: navy (#0B2A4A) & teal (#1FA6A0)
   ========================================================= */

:root {
  --heza-navy: #0b2a4a;
  --heza-navy-dark: #071b30;
  --heza-teal: #1fa89f;
  --heza-teal-light: #e6f6f5;
  --heza-orange: #f5811f;
  --heza-gray: #6c7a89;

  /* Theme-aware tokens (light default) — biru langit lembut, bukan putih polos */
  --bg-page: linear-gradient(180deg, #eaf4fb 0%, #d9ebf7 45%, #c9e2f2 100%);
  --bg-alt: linear-gradient(135deg, #e1eef8 0%, #cfe5f3 100%);
  --bg-card: #f4faff;
  --bg-input: #ffffff;
  --navbar-bg: #eaf4fb;
  --heading-color: var(--heza-navy);
  --text-body: #2b2b2b;
  --text-muted: #5b7284;
  --border-color: #c3dcee;
  --placeholder-border: #a9c9e0;
  color-scheme: light;
}

[data-theme="dark"] {
  --bg-page: #0c1a29;
  --bg-alt: #091421;
  --bg-card: #122439;
  --bg-input: #0e2032;
  --navbar-bg: #0c1a29;
  --heading-color: #eef4fa;
  --text-body: #dbe6f0;
  --text-muted: #93a8bc;
  --border-color: #24405a;
  --placeholder-border: #345473;
  --heza-teal-light: rgba(31, 168, 159, .16);
  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg-page: #0c1a29;
    --bg-alt: #091421;
    --bg-card: #122439;
    --bg-input: #0e2032;
    --navbar-bg: #0c1a29;
    --heading-color: #eef4fa;
    --text-body: #dbe6f0;
    --text-muted: #93a8bc;
    --border-color: #24405a;
    --placeholder-border: #345473;
    --heza-teal-light: rgba(31, 168, 159, .16);
    color-scheme: dark;
  }
}

body {
  font-family: 'Segoe UI', Roboto, Arial, sans-serif;
  background: var(--bg-page);
  color: var(--text-body);
  transition: background-color .2s ease, color .2s ease;
}

[data-theme="dark"] .text-secondary,
[data-theme="dark"] .text-white-50 {
  color: var(--text-muted) !important;
}

[data-theme="dark"] .form-control,
[data-theme="dark"] .form-select {
  background-color: var(--bg-input);
  border-color: var(--border-color);
  color: var(--text-body);
}
[data-theme="dark"] .form-control::placeholder {
  color: var(--text-muted);
}
[data-theme="dark"] .form-control:focus,
[data-theme="dark"] .form-select:focus {
  background-color: var(--bg-input);
  color: var(--text-body);
}

[data-theme="dark"] .table {
  color: var(--text-body);
}
[data-theme="dark"] .table > :not(caption) > * > * {
  background-color: var(--bg-card);
  color: var(--text-body);
  border-color: var(--border-color);
}

[data-theme="dark"] .badge-pill {
  background: var(--bg-card);
  border-color: var(--border-color);
  color: var(--text-body);
}

[data-theme="dark"] .dropdown-menu {
  background-color: var(--bg-card);
  border-color: var(--border-color);
}
[data-theme="dark"] .dropdown-item {
  color: var(--text-body);
}
[data-theme="dark"] .dropdown-item:hover,
[data-theme="dark"] .dropdown-item:focus {
  background-color: var(--bg-alt);
  color: var(--text-body);
}

[data-theme="dark"] .list-group-item {
  background-color: var(--bg-card);
  color: var(--text-body);
}
[data-theme="dark"] .list-group-item-action:hover,
[data-theme="dark"] .list-group-item-action:focus {
  background-color: var(--bg-alt);
}

a {
  text-decoration: none;
}

img, svg {
  max-width: 100%;
  height: auto;
}

/* ---------- Navbar ---------- */
.navbar-heza {
  background: var(--navbar-bg) !important;
  box-shadow: 0 2px 10px rgba(11, 42, 74, 0.08);
}

.navbar-heza .nav-link {
  color: var(--heading-color);
  font-weight: 500;
  margin: 0 .35rem;
}

.navbar-heza .navbar-toggler-icon {
  filter: none;
}
[data-theme="dark"] .navbar-heza .navbar-toggler {
  border-color: var(--border-color);
}
[data-theme="dark"] .navbar-heza .navbar-toggler-icon {
  filter: invert(1) grayscale(1);
}

/* ---------- Theme & language toggles ---------- */
.toggle-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--heading-color);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: background-color .15s ease, transform .15s ease;
}
.toggle-btn:hover {
  background: var(--heza-teal-light);
  color: var(--heza-teal);
}
.theme-toggle .bi-moon-stars { display: none; }
[data-theme="dark"] .theme-toggle .bi-sun { display: none; }
[data-theme="dark"] .theme-toggle .bi-moon-stars { display: inline-block; }

.lang-toggle {
  display: inline-flex;
  border: 1px solid var(--border-color);
  border-radius: 30px;
  overflow: hidden;
  font-size: .75rem;
  font-weight: 700;
}
.lang-toggle a {
  padding: .4rem .7rem;
  color: var(--text-muted);
  letter-spacing: .03em;
}
.lang-toggle a.active {
  background: var(--heza-teal);
  color: #fff;
}

.navbar-heza .nav-link.active,
.navbar-heza .nav-link:hover {
  color: var(--heza-teal);
}

.navbar-heza .navbar-brand img {
  height: 42px;
}

/* Logo PNG punya area transparan berisi bentuk navy — kasih chip terang di
   belakangnya supaya tetap kelihatan saat menyatu dengan background gelap
   (navbar dark mode & footer yang memang selalu navy). */
.logo-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border-radius: 10px;
  padding: 5px;
  box-shadow: 0 1px 4px rgba(11, 42, 74, .12);
}
.logo-badge img {
  display: block;
}

.brand-wordmark {
  display: flex;
  flex-direction: column;
  line-height: 1;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: .01em;
  color: var(--heading-color);
}
.brand-wordmark .brand-sub {
  margin-top: .3rem;
  font-weight: 600;
  font-size: .6rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--heza-teal);
}

.btn-heza-outline {
  border: 1px solid var(--heza-teal);
  color: var(--heza-teal);
  border-radius: 30px;
  padding: .5rem 1.25rem;
  font-weight: 600;
}
.btn-heza-outline:hover {
  background: var(--heza-teal);
  color: #fff;
}

.btn-heza-primary {
  background: var(--heza-orange);
  border: none;
  color: #fff;
  border-radius: 30px;
  padding: .5rem 1.4rem;
  font-weight: 600;
}
.btn-heza-primary:hover {
  background: #d96e0f;
  color: #fff;
}

.btn-heza-teal {
  background: var(--heza-teal);
  border: none;
  color: #fff;
  border-radius: 30px;
  padding: .6rem 1.5rem;
  font-weight: 600;
}
.btn-heza-teal:hover {
  background: #178a82;
  color: #fff;
}

/* ---------- Hero ---------- */
.hero-section {
  position: relative;
  background:
    radial-gradient(circle, rgba(31, 168, 159, .10) 1.5px, transparent 1.5px),
    linear-gradient(120deg, #f2fbfa 0%, #eef6fb 100%);
  background-size: 22px 22px, 100% 100%;
  padding: 4.5rem 0;
  overflow: hidden;
}
[data-theme="dark"] .hero-section {
  background:
    radial-gradient(circle, rgba(31, 168, 159, .14) 1.5px, transparent 1.5px),
    linear-gradient(120deg, #0e2033 0%, #0a1826 100%);
  background-size: 22px 22px, 100% 100%;
}

.hero-section::before {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(10px);
  z-index: 0;
  pointer-events: none;
  width: 380px;
  height: 380px;
  background: radial-gradient(circle, rgba(31, 168, 159, .12) 0%, rgba(31, 168, 159, 0) 70%);
  top: -160px;
  right: -100px;
}
.hero-section > .container {
  position: relative;
  z-index: 1;
}

.hero-title {
  color: var(--heading-color);
  font-weight: 800;
  line-height: 1.2;
}

.breadcrumb-heza a {
  color: var(--heza-teal);
}
.breadcrumb-heza span {
  color: var(--heza-gray);
}

.eyebrow {
  color: var(--heza-teal);
  font-weight: 700;
  letter-spacing: .08em;
  font-size: .8rem;
  text-transform: uppercase;
}

/* ---------- Cards ---------- */
.card-heza {
  position: relative;
  border: none;
  border-radius: 14px;
  background: var(--bg-card);
  box-shadow: 0 4px 18px rgba(11, 42, 74, 0.06);
  transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease;
  height: 100%;
  overflow: hidden;
}
.card-heza::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--heza-teal) 0%, var(--heza-navy) 100%);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s ease;
}
.card-heza:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 26px rgba(11, 42, 74, 0.12);
}
.card-heza:hover::before {
  transform: scaleX(1);
}

.hero-tile {
  background: var(--bg-card);
}

.icon-circle {
  width: 54px;
  height: 54px;
  border-radius: 16px;
  background: linear-gradient(145deg, var(--heza-teal-light) 0%, #d7f0ee 100%);
  color: var(--heza-teal);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: .9rem;
  box-shadow: 0 6px 14px rgba(31, 168, 159, .18);
}

.icon-badge-xl {
  position: relative;
  width: 110px;
  height: 110px;
  border-radius: 28px;
  background: linear-gradient(145deg, var(--heza-navy) 0%, var(--heza-teal) 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.6rem;
  margin: 0 auto;
  box-shadow: 0 14px 30px rgba(11, 42, 74, .25);
}
.icon-badge-xl::before {
  content: "";
  position: absolute;
  inset: -14px;
  border: 1.5px dashed rgba(31, 168, 159, .35);
  border-radius: 36px;
}

.step-number {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--heza-teal);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  flex-shrink: 0;
}

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(120deg, var(--heza-teal-light) 0%, #eaf7f6 60%, #f3f9fc 100%);
  border: 1px solid #dcf0ee;
  border-radius: 16px;
  padding: 1.75rem 2.25rem;
}
[data-theme="dark"] .cta-band {
  background: linear-gradient(120deg, rgba(31, 168, 159, .16) 0%, rgba(31, 168, 159, .07) 60%, rgba(255, 255, 255, .02) 100%);
  border-color: var(--border-color);
}

/* ---------- Section helpers ---------- */
.section-alt {
  background: var(--bg-alt);
}

.panel-soft {
  background: var(--bg-alt);
  border-radius: 18px;
  padding: 2rem;
}

.section-divider {
  border: none;
  border-top: 1px solid var(--border-color);
  margin: 3rem 0;
}

/* ---------- Image placeholder ---------- */
.img-placeholder {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  width: 100%;
  min-height: 180px;
  border: 2px dashed var(--placeholder-border);
  border-radius: 16px;
  background: var(--bg-alt);
  color: var(--text-muted);
  text-align: center;
  padding: 1.5rem;
}
.img-placeholder i {
  font-size: 1.9rem;
  color: var(--heza-teal);
}
.img-placeholder .img-placeholder-label {
  font-weight: 700;
  font-size: .85rem;
  color: var(--text-muted);
}
.img-placeholder .img-placeholder-hint {
  font-size: .72rem;
  color: var(--text-muted);
  opacity: .8;
}

/* ---------- Footer ---------- */
.footer-heza {
  background: var(--heza-navy-dark);
  color: #cbd8e6;
  padding: 3rem 0 1.5rem;
}
.footer-heza a {
  color: #cbd8e6;
}
.footer-heza a:hover {
  color: var(--heza-teal);
}

/* ---------- Widget Chat Telegram Mengambang ---------- */
.tg-widget {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 1050;
}
.tg-widget-toggle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: none;
  background: #229ed9;
  color: #fff;
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(11, 42, 74, .25);
  cursor: pointer;
  transition: transform .15s ease;
}
.tg-widget-toggle:hover {
  transform: scale(1.06);
}
.tg-widget-panel {
  position: absolute;
  right: 0;
  bottom: 70px;
  width: 320px;
  max-width: calc(100vw - 2.5rem);
  background: var(--bg-card, #fff);
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(11, 42, 74, .25);
  overflow: hidden;
  border: 1px solid var(--border-color, rgba(11, 42, 74, .1));
}
.tg-widget-header {
  background: #229ed9;
  color: #fff;
  padding: .9rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.tg-widget-close {
  background: transparent;
  border: none;
  color: #fff;
  opacity: .85;
}
.tg-widget-close:hover {
  opacity: 1;
}
.tg-widget-body {
  padding: 1rem;
  max-height: 70vh;
  overflow-y: auto;
}
[data-theme="dark"] .tg-widget-panel {
  background: var(--bg-card);
  border-color: var(--border-color);
}
.footer-heza h6 {
  color: #fff;
  font-weight: 700;
  margin-bottom: 1rem;
}
.footer-heza .footer-logo img {
  height: 38px;
}
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  margin-top: 2rem;
  padding-top: 1.25rem;
  font-size: .85rem;
  color: #93a6ba;
}

/* ---------- Auth pages ---------- */
.auth-side {
  background: linear-gradient(135deg, var(--heza-navy) 0%, var(--heza-navy-dark) 100%);
  color: #fff;
  min-height: calc(100vh - 76px);
  display: flex;
  align-items: center;
}

/* ---------- Misc ---------- */
.section-title {
  color: var(--heading-color);
  font-weight: 800;
}

.badge-pill {
  background: #fff;
  border: 1px solid #e3e9ef;
  border-radius: 30px;
  padding: .5rem 1rem;
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-weight: 600;
  color: var(--heza-navy);
}

@media (max-width: 767.98px) {
  .hero-title { font-size: 1.75rem; }
}
