/*
 * Header Bar – 4D King Results
 *
 * Fixed header, site branding, contact button, and hamburger icon.
 * The off‑canvas panel styles live in offcanvas.css.
 */

/* ---------- Fixed Header Bar ---------- */
.site-header-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 70px;
  background: var(--white);
  border-bottom: 1px solid var(--light-grey);
  display: flex;
  align-items: center;
  justify-content: flex-end;        /* contact button on the right */
  padding: 0 20px;
  padding-top: env(safe-area-inset-top, 0); /* respect iOS notch/dynamic island */
  z-index: 1050;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

/* Push page content below the fixed header */
.site-main {
  padding-top: 80px;
}

/* ---------- Site Branding ---------- */
.site-branding {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  max-width: calc(100% - 140px); /* keep clear of hamburger (left) + contact btn (right) */
}

.site-title {
  display: block;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--dark);
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.site-title:hover {
  color: var(--primary-red);
}

/* ---------- Contact Button ---------- */
.header-contact-btn {
  display: inline-block;
  padding: 8px 18px;
  background: var(--primary-red);
  color: var(--white);
  border-radius: 30px;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s ease;
  white-space: nowrap;
}

.header-contact-btn:hover {
  background: var(--primary-hover, #a00000);
}

/* ---------- Hamburger Button ---------- */
.menu-toggle {
  position: fixed;
  top: 15px;
  left: 15px;
  z-index: 1100;
  background: var(--white);
  border: 2px solid var(--primary-red);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--primary-red);
  padding: 0;
  transition: background 0.15s, color 0.15s;
}

.menu-toggle:hover {
  background: var(--primary-red);
  color: var(--white);
}

.menu-toggle svg {
  width: 24px;
  height: 24px;
  pointer-events: none;
}

/* ---------- Responsive ---------- */

/* --- Tablet (≤1024px) --- */
@media (max-width: 1024px) {
  .site-branding {
    max-width: calc(100% - 130px);
  }
}

/* --- Mobile (≤768px) --- */
@media (max-width: 768px) {
  .header-contact-btn {
    padding: 8px 14px; /* height kept closer to a comfortable tap target */
    font-size: 0.8rem;
  }
  .site-title {
    font-size: 1rem;
  }
  .site-branding {
    max-width: calc(100% - 120px);
  }
}

/* --- Small phones (≤480px) --- */
@media (max-width: 480px) {
  .header-contact-btn {
    display: none;
  }
  .site-branding {
    max-width: calc(100% - 90px); /* only need clearance for the hamburger now */
  }
}