:root {
  --hg-bf-bg: #0b0b0c;
  --hg-bf-ink: #f6f1e8;
  --hg-bf-gold: #d4a017;
  --hg-bf-gold-2: #f0c14b;
  --hg-bf-red: #c1121f;
  --hg-bf-red-2: #e63946;
  --hg-bf-muted: rgba(246, 241, 232, 0.78);
  --hg-bf-line: rgba(225, 57, 70, 0.45);
}

.hg-bf-bar {
  position: sticky;
  top: 0;
  z-index: 10050;
  background: linear-gradient(90deg, #0a0a0a 0%, #2a0a0c 50%, #0a0a0a 100%);
  border-bottom: 1px solid var(--hg-bf-line);
  font-family: Tajawal, "Segoe UI", Tahoma, sans-serif;
}
.hg-bf-bar__link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.55rem 1rem;
  color: var(--hg-bf-ink) !important;
  text-decoration: none !important;
  font-size: 0.92rem;
  line-height: 1.45;
}
.hg-bf-bar__badge {
  letter-spacing: 0.08em;
  font-weight: 800;
  font-size: 0.72rem;
  color: #fff;
  background: linear-gradient(180deg, var(--hg-bf-red-2), var(--hg-bf-red));
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
}
.hg-bf-bar__cta {
  border: 1px solid var(--hg-bf-gold);
  color: var(--hg-bf-gold-2);
  padding: 0.15rem 0.65rem;
  border-radius: 999px;
  font-size: 0.8rem;
  white-space: nowrap;
}
.hg-bf-bar__text strong { color: var(--hg-bf-gold-2); }

body.admin-bar .hg-bf-bar { top: 32px; }
@media (max-width: 782px) {
  body.admin-bar .hg-bf-bar { top: 46px; }
}

.hg-bf-modal[hidden] { display: none !important; }
.hg-bf-modal {
  position: fixed;
  inset: 0;
  z-index: 10060;
  display: grid;
  place-items: center;
  padding: 1rem;
  font-family: Tajawal, "Segoe UI", Tahoma, sans-serif;
}
.hg-bf-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(4px);
}
.hg-bf-modal__panel {
  position: relative;
  z-index: 1;
  width: min(920px, 100%);
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 0;
  background: var(--hg-bf-bg);
  color: var(--hg-bf-ink);
  border: 1px solid var(--hg-bf-line);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
  animation: hgBfIn 0.45s ease both;
}
@keyframes hgBfIn {
  from { opacity: 0; transform: translateY(14px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.hg-bf-modal__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  min-height: 320px;
}
.hg-bf-modal__copy {
  padding: 1.4rem 1.35rem 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.75rem;
}
.hg-bf-modal__eyebrow {
  margin: 0;
  color: var(--hg-bf-red-2);
  letter-spacing: 0.12em;
  font-size: 0.75rem;
  font-weight: 800;
}
.hg-bf-modal__hook {
  margin: 0 !important;
  padding: 0.65rem 0.75rem;
  border: 1px dashed var(--hg-bf-line);
  border-radius: 10px;
  background: rgba(193, 18, 31, 0.12);
  color: var(--hg-bf-ink) !important;
  font-size: 0.92rem;
}
.hg-bf-modal__copy h2 {
  margin: 0;
  font-size: clamp(1.25rem, 2.4vw, 1.7rem);
  line-height: 1.35;
  font-weight: 800;
}
.hg-bf-modal__copy p {
  margin: 0;
  color: var(--hg-bf-muted);
  line-height: 1.7;
}
.hg-bf-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.35rem;
}
.hg-bf-modal__close {
  position: absolute;
  top: 0.55rem;
  left: 0.55rem;
  z-index: 2;
  width: 2rem;
  height: 2rem;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
}

.hg-bf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.7rem 1.1rem;
  border-radius: 999px;
  text-decoration: none !important;
  font-weight: 700;
  font-size: 0.95rem;
  border: 1px solid transparent;
  transition: transform 0.15s ease, background 0.15s ease;
}
.hg-bf-btn:hover { transform: translateY(-1px); }
.hg-bf-btn--sm { padding: 0.45rem 0.85rem; font-size: 0.85rem; }
.hg-bf-btn--gold {
  background: linear-gradient(180deg, var(--hg-bf-gold-2), var(--hg-bf-gold));
  color: #111 !important;
}
.hg-bf-btn--ghost {
  border-color: var(--hg-bf-line);
  color: var(--hg-bf-ink) !important;
  background: transparent;
}

@media (max-width: 760px) {
  .hg-bf-modal__panel { grid-template-columns: 1fr; }
  .hg-bf-modal__media img { max-height: 240px; }
  .hg-bf-bar__text { text-align: center; }
}

/* Landing */
.hg-bf-page {
  margin: 0;
  background: #090909;
  color: var(--hg-bf-ink);
  font-family: Tajawal, "Segoe UI", Tahoma, sans-serif;
}
.hg-bf-page__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.9rem 1.2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.hg-bf-page__top a { color: var(--hg-bf-ink); text-decoration: none; font-weight: 700; }
.hg-bf-hero {
  position: relative;
  min-height: min(70vh, 560px);
  display: grid;
  align-items: end;
  overflow: hidden;
}
.hg-bf-hero__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hg-bf-hero__veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.25), rgba(0,0,0,0.82));
}
.hg-bf-hero__inner {
  position: relative;
  z-index: 1;
  padding: 2.5rem 1.25rem 2.2rem;
  max-width: 920px;
  margin: 0 auto;
}
.hg-bf-hero h1 {
  margin: 0.35rem 0 0.75rem;
  font-size: clamp(1.55rem, 4.5vw, 2.6rem);
  line-height: 1.25;
}
.hg-bf-hero__lead {
  color: var(--hg-bf-muted);
  line-height: 1.75;
  max-width: 46rem;
}
.hg-bf-section {
  padding: 3rem 1.25rem;
  max-width: 1100px;
  margin: 0 auto;
}
.hg-bf-section--dark {
  max-width: none;
  background: linear-gradient(180deg, #12100a, #0b0b0c);
  border-block: 1px solid var(--hg-bf-line);
  text-align: center;
}
.hg-bf-section h2 {
  margin-top: 0;
  font-size: clamp(1.3rem, 3vw, 1.9rem);
  line-height: 1.35;
}
.hg-bf-section p { color: var(--hg-bf-muted); line-height: 1.8; }
.hg-bf-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2rem;
  align-items: center;
}
.hg-bf-list {
  padding: 0;
  margin: 1.2rem 0 0;
  list-style: none;
}
.hg-bf-list li {
  padding: 0.65rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--hg-bf-ink);
}
.hg-bf-figure {
  margin: 0;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--hg-bf-line);
}
.hg-bf-figure img { width: 100%; display: block; }
.hg-bf-page__foot {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: space-between;
  padding: 1.4rem 1.25rem 2rem;
  color: var(--hg-bf-muted);
  font-size: 0.9rem;
}
.hg-bf-page__foot a { color: var(--hg-bf-gold-2); }

.hg-bf-hooks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}
.hg-bf-hooks article {
  padding: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: linear-gradient(180deg, #141010, #0c0c0c);
}
.hg-bf-hooks h2 {
  margin: 0 0 0.55rem;
  font-size: 1.15rem;
  color: var(--hg-bf-gold-2);
}
.hg-bf-calc {
  margin-top: 1.25rem;
  padding: 1rem;
  border-radius: 14px;
  border: 1px solid var(--hg-bf-line);
  background: rgba(193, 18, 31, 0.08);
}
.hg-bf-calc label {
  display: block;
  margin-bottom: 0.45rem;
  font-weight: 700;
}
.hg-bf-calc__row {
  display: flex;
  gap: 0.55rem;
  flex-wrap: wrap;
}
.hg-bf-calc input {
  flex: 1 1 140px;
  min-width: 0;
  padding: 0.7rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: #111;
  color: var(--hg-bf-ink);
  font-size: 1rem;
}
.hg-bf-calc__out {
  margin: 0.85rem 0 0.55rem;
  line-height: 1.7;
  color: var(--hg-bf-ink);
}
.hg-bf-calc__out strong { color: var(--hg-bf-gold-2); }

@media (max-width: 860px) {
  .hg-bf-grid { grid-template-columns: 1fr; }
  .hg-bf-hooks { grid-template-columns: 1fr; }
  .hg-bf-hero { min-height: 70vh; }
}

/* Soft site-wide BF accent */
body:not(.hg-bf-page) .site-header,
body:not(.hg-bf-page) header {
  box-shadow: inset 0 -2px 0 rgba(212, 160, 23, 0.35);
}
@media (prefers-reduced-motion: reduce) {
  .hg-bf-modal__panel { animation: none; }
  .hg-bf-btn { transition: none; }
}