/* ============================================================
   HEADER CSS  –  RekapSEO Design System
   Hello Elementor Child
   NOTE: Semua variable di-scope ke .site-header / .mobile-drawer
         agar TIDAK konflik dengan parent theme Hello Elementor
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700;800&family=Inter:wght@400;500;600&display=swap');

/* ── Variables scoped to header only ─────────────────────── */
.site-header,
.mobile-drawer,
.drawer-overlay,
.site-header-spacer {
  --h-primary:       #1A56DB;
  --h-primary-soft:  #EBF0FF;
  --h-accent:        #0EA5E9;
  --h-text:          #0F1523;
  --h-text-muted:    #5A6480;
  --h-surface:       #FFFFFF;
  --h-surface-2:     #F2F4F8;
  --h-border:        #E4E8F0;
  --h-border-light:  #EEF1F7;
  --h-shadow-sm:     0 2px 8px rgba(15,21,35,0.06);
  --h-shadow-pri:    0 8px 32px rgba(26,86,219,0.24);
  --h-font-head:     'Poppins', -apple-system, sans-serif;
  --h-font-body:     'Inter', -apple-system, sans-serif;
  --h-ease:          cubic-bezier(0.4, 0, 0.2, 1);
  --h-height:        68px;
}

/* ── Reset in scope ──────────────────────────────────────── */
.site-header *,
.site-header *::before,
.site-header *::after,
.mobile-drawer *,
.mobile-drawer *::before,
.mobile-drawer *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ══════════════════════════════════════════════════════════
   SITE HEADER
══════════════════════════════════════════════════════════ */
.site-header {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  z-index: 9999 !important;
  height: var(--h-height) !important;
  background: rgba(248, 249, 252, 0.88) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--h-border-light) !important;
  box-shadow: none !important;
  transition: background 250ms var(--h-ease), box-shadow 250ms var(--h-ease);
}

.site-header.scrolled {
  background: rgba(255, 255, 255, 0.97) !important;
  box-shadow: var(--h-shadow-sm) !important;
}

/* ── Header Inner ────────────────────────────────────────── */
.header-inner {
  max-width: 1200px !important;
  width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left:  clamp(1rem, 4vw, 2rem) !important;
  padding-right: clamp(1rem, 4vw, 2rem) !important;
  height: 100% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 2rem !important;
}



/* ══════════════════════════════════════════════════════════
   LOGO
══════════════════════════════════════════════════════════ */
.site-header .site-logo {
  display: flex !important;
  align-items: center !important;
  gap: 0.75rem !important;
  flex-shrink: 0 !important;
  text-decoration: none !important;
}

.site-header .site-logo__img {
  height: 36px !important;
  width: auto !important;
  display: block !important;
}

.site-header .logo-mark {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, #1A56DB, #0EA5E9);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(26,86,219,0.28);
}

.site-header .logo-mark svg {
  width: 20px;
  height: 20px;
  color: #fff;
  display: block;
}

.site-header .logo-text {
  font-family: var(--h-font-head) !important;
  font-size: 1.25rem !important;
  font-weight: 800 !important;
  color: var(--h-text) !important;
  letter-spacing: -0.03em !important;
  white-space: nowrap !important;
}

/* Custom logo from WordPress */
.site-header .custom-logo-link { display: flex !important; align-items: center !important; }
.site-header .custom-logo      { height: 36px !important; width: auto !important; }

/* ══════════════════════════════════════════════════════════
   DESKTOP NAV
══════════════════════════════════════════════════════════ */
.site-nav {
  display: flex !important;
  align-items: center !important;
  gap: 0.25rem !important;
  flex: 1 !important;
  justify-content: center !important;
}

.site-nav__list,
.site-nav > ul {
  display: flex !important;
  align-items: center !important;
  gap: 0.25rem !important;
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.site-nav__list > li,
.site-nav > ul > li {
  position: relative !important;
}

.site-header .nav-link,
.site-nav a {
  font-family: var(--h-font-head) !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  color: var(--h-text-muted) !important;
  padding: 0.5rem 0.75rem !important;
  border-radius: 6px !important;
  transition: color 150ms var(--h-ease), background 150ms var(--h-ease) !important;
  text-decoration: none !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
  white-space: nowrap !important;
  background: transparent !important;
  border: none !important;
}

.site-header .nav-link:hover,
.site-nav a:hover,
.site-nav .current-menu-item > a,
.site-nav .current_page_item > a {
  color: var(--h-text) !important;
  background: var(--h-surface-2) !important;
}

/* Dropdown */
.site-nav .sub-menu {
  display: none !important;
  position: absolute !important;
  top: calc(100% + 8px) !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
  min-width: 180px !important;
  background: var(--h-surface) !important;
  border: 1px solid var(--h-border) !important;
  border-radius: 10px !important;
  box-shadow: 0 8px 30px rgba(15,21,35,0.10) !important;
  list-style: none !important;
  padding: 0.5rem !important;
  z-index: 10000 !important;
  margin: 0 !important;
}

.site-nav li:hover > .sub-menu,
.site-nav li:focus-within > .sub-menu {
  display: block !important;
}

.site-nav .sub-menu a {
  font-size: 0.8rem !important;
  display: block !important;
  border-radius: 6px !important;
}

/* ══════════════════════════════════════════════════════════
   CTA BUTTONS
══════════════════════════════════════════════════════════ */
.header-cta {
  display: flex !important;
  align-items: center !important;
  gap: 0.75rem !important;
  flex-shrink: 0 !important;
}

/* Base button */
.site-header .btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.5rem !important;
  font-family: var(--h-font-head) !important;
  font-weight: 600 !important;
  cursor: pointer !important;
  text-decoration: none !important;
  white-space: nowrap !important;
  letter-spacing: -0.01em !important;
  border-radius: 8px !important;
  transition: transform 150ms var(--h-ease),
              box-shadow 150ms var(--h-ease),
              background 150ms var(--h-ease) !important;
}

/* Outline button (Masuk) */
.site-header .btn-outline {
  background: transparent !important;
  color: var(--h-primary) !important;
  border: 1.5px solid var(--h-border) !important;
  font-size: 0.8rem !important;
  padding: 0.6rem 1.25rem !important;
  height: 38px !important;
}
.site-header .btn-outline:hover {
  background: var(--h-primary-soft) !important;
  border-color: var(--h-primary) !important;
  color: var(--h-primary) !important;
  transform: none !important;
}

/* Primary button (Daftar Gratis) */
.site-header .btn-primary {
  background: linear-gradient(135deg, #1A56DB, #0EA5E9) !important;
  color: #fff !important;
  border: none !important;
  font-size: 0.8rem !important;
  padding: 0.6rem 1.25rem !important;
  height: 38px !important;
  box-shadow: 0 8px 32px rgba(26,86,219,0.24) !important;
}
.site-header .btn-primary:hover {
  transform: translateY(-1px) !important;
  box-shadow: 0 12px 40px rgba(26,86,219,0.32) !important;
  color: #fff !important;
}
.site-header .btn-primary:active {
  transform: translateY(0) !important;
}

/* svg icon inside button */
.site-header .btn svg {
  width: 14px !important;
  height: 14px !important;
  flex-shrink: 0 !important;
}

/* ══════════════════════════════════════════════════════════
   HAMBURGER TOGGLE
══════════════════════════════════════════════════════════ */
.menu-toggle {
  display: none !important;
  flex-direction: column !important;
  gap: 5px !important;
  padding: 0.5rem !important;
  border-radius: 6px !important;
  background: none !important;
  border: none !important;
  cursor: pointer !important;
  transition: background 150ms var(--h-ease) !important;
  flex-shrink: 0 !important;
}
.menu-toggle:hover { background: var(--h-surface-2) !important; }

.menu-toggle span {
  display: block !important;
  width: 22px !important;
  height: 2px !important;
  background: var(--h-text) !important;
  border-radius: 2px !important;
  transition: all 250ms var(--h-ease) !important;
}

/* Hamburger → X */
.menu-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg) !important; }
.menu-toggle.active span:nth-child(2) { opacity: 0 !important; transform: scaleX(0) !important; }
.menu-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg) !important; }

/* ══════════════════════════════════════════════════════════
   MOBILE DRAWER
══════════════════════════════════════════════════════════ */
.drawer-overlay {
  display: none;
  position: fixed !important;
  inset: 0 !important;
  background: rgba(15, 21, 35, 0.5) !important;
  z-index: 10000 !important;
  opacity: 0;
  transition: opacity 250ms var(--h-ease);
}
.drawer-overlay.open    { display: block !important; }
.drawer-overlay.visible { opacity: 1 !important; }

.mobile-drawer {
  position: fixed !important;
  top: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 300px !important;
  max-width: 88vw !important;
  background: #fff !important;
  z-index: 10001 !important;
  transform: translateX(100%) !important;
  transition: transform 380ms var(--h-ease) !important;
  display: flex !important;
  flex-direction: column !important;
  box-shadow: -12px 0 48px rgba(15, 21, 35, 0.18) !important;
  font-family: var(--h-font-head) !important;
  padding: 0 !important;
}
.mobile-drawer.open { transform: translateX(0) !important; }

/* ── Drawer Header ── */
.drawer-header {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  padding: 1.125rem 1.25rem !important;
  border-bottom: 1px solid #EEF1F7 !important;
  flex-shrink: 0 !important;
  background: #fff !important;
}

.drawer-header .site-logo {
  display: flex !important;
  align-items: center !important;
  gap: 0.625rem !important;
  text-decoration: none !important;
}

.drawer-header .logo-mark {
  width: 32px !important;
  height: 32px !important;
  background: linear-gradient(135deg, #1A56DB, #0EA5E9) !important;
  border-radius: 8px !important;
  display: flex !important; align-items: center !important; justify-content: center !important;
  box-shadow: 0 3px 10px rgba(26,86,219,0.28) !important;
  flex-shrink: 0 !important;
}
.drawer-header .logo-mark svg { width: 16px !important; height: 16px !important; color: #fff !important; display: block !important; }
.drawer-header .logo-text {
  font-family: var(--h-font-head) !important;
  font-size: 1.1rem !important;
  font-weight: 800 !important;
  color: #0F1523 !important;
  letter-spacing: -0.03em !important;
}
.drawer-header .custom-logo { height: 30px !important; width: auto !important; }
.drawer-header .custom-logo-link { display: flex !important; align-items: center !important; }
.drawer-header .site-logo__img { height: 30px !important; width: auto !important; }

.drawer-close {
  width: 34px !important; height: 34px !important;
  display: flex !important; align-items: center !important; justify-content: center !important;
  border-radius: 8px !important;
  color: #8B96B0 !important;
  background: #F2F4F8 !important;
  border: none !important; cursor: pointer !important;
  transition: background 150ms !important, color 150ms !important;
  flex-shrink: 0 !important;
}
.drawer-close:hover { background: #E4E8F0 !important; color: #0F1523 !important; }

/* ── Drawer Nav ── */
.drawer-nav {
  flex: 1 !important;
  padding: 0.625rem 0.875rem !important;
  overflow-y: auto !important;
}

/* Reset semua list dan li dari WordPress */
.drawer-nav ul,
.drawer-nav ol,
.drawer-nav__list {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 4px !important;
}

.drawer-nav li {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

.drawer-nav a,
.drawer-nav .nav-link {
  display: flex !important;
  align-items: center !important;
  font-family: var(--h-font-head) !important;
  font-size: 0.9375rem !important;   /* 15px */
  font-weight: 500 !important;
  color: #3D4A66 !important;
  padding: 0.85rem 0.875rem !important;
  border-radius: 8px !important;
  text-decoration: none !important;
  line-height: 1.4 !important;
  transition: color 150ms !important, background 150ms !important;
  background: transparent !important;
}
.drawer-nav a:hover,
.drawer-nav .nav-link:hover {
  color: #0F1523 !important;
  background: #F2F4F8 !important;
}

/* Active / current item */
.drawer-nav .current-menu-item > a,
.drawer-nav .current_page_item > a {
  color: #1A56DB !important;
  background: #EBF0FF !important;
  font-weight: 600 !important;
}

/* Sub-menu indented */
.drawer-nav .sub-menu {
  padding-left: 0.875rem !important;
  margin-top: 2px !important;
}
.drawer-nav .sub-menu a {
  font-size: 0.875rem !important;
  color: #5A6480 !important;
}

/* ── Drawer Footer (CTA Buttons) ── */
.drawer-footer {
  padding: 0.875rem 0.875rem 1.5rem !important;
  border-top: 1px solid #EEF1F7 !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 0.625rem !important;
  flex-shrink: 0 !important;
  background: #fff !important;
}

.drawer-footer .btn {
  width: 100% !important;
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 0.5rem !important;
  height: 50px !important;
  font-size: 0.9rem !important;
  font-family: var(--h-font-head) !important;
  font-weight: 600 !important;
  border-radius: 8px !important;
  cursor: pointer !important;
  text-decoration: none !important;
  transition: opacity 150ms !important, transform 150ms !important;
}

.drawer-footer .btn-outline {
  background: transparent !important;
  color: #1A56DB !important;
  border: 1.5px solid #E4E8F0 !important;
}
.drawer-footer .btn-primary {
  background: linear-gradient(135deg, #1A56DB, #0EA5E9) !important;
  color: #fff !important;
  border: none !important;
  box-shadow: 0 8px 32px rgba(26,86,219,0.24) !important;
}

/* Prevent body scroll when drawer open */
body.drawer-open { overflow: hidden !important; }

/* ══════════════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .site-nav    { display: none !important; }
  .header-cta  { display: none !important; }
  .menu-toggle { display: flex !important; }
}

@media (max-width: 480px) {
  .header-inner { gap: 1rem !important; }
}
