/* header.css */

#header-page {
  padding: 4.5em 0 3em 0;
}

@font-face {
  font-family: "GUERRILLA";
  /* The leading slash / ensures it starts from the root of your site */
  src: url("/assets/webfonts/GUERRILLA.woff2") format("woff2"),
    url("/assets/webfonts/GUERRILLA.woff") format("woff"),
    url("/assets/webfonts/GUERRILLA.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
  font-display: block;
}

/* Logo - Force visibility and skip template delays */
#logo {
  display: inline-block;
  visibility: visible !important;
  opacity: 1 !important;
}

#logo h1 {
  color: #e6e6e6;
  border-radius: 6px;
  font-family: "GUERRILLA", serif;
  font-weight: 400;
  padding: 0.25em 0.2em 0.25em 0.2em;
  font-size: 3.5em;
  display: inline-block;
  vertical-align: middle;
  /* background-color: #301545; */
  white-space: nowrap;
  /* Force it to show immediately */
  visibility: visible !important;
  opacity: 1 !important;
}

/* Style individual words */
#logo h1 span {
  display: inline;
  letter-spacing: 0.1em;
}

#logo h1 .hyper {
  color: #fa61b9;
  margin-right: 5px;
}

#logo h1 .game {
  color: #9599ff;
  margin-right: 5px;
}

#logo h1 .dot {
  color: #ffffff;
  margin-left: -2px;
  margin-right: -2px;
}

#logo h1 .dev {
  color: #fa61b9;
}

/* Responsive adjustments */
@media (max-width: 1200px) {
  #logo h1 {
    font-size: 2.5em;
  }
}
@media (max-width: 768px) {
  #logo h1 {
    font-size: 2em;
  }
}
@media (max-width: 480px) {
  #logo h1 {
    font-size: 1.5em;
  }
}

#header-page .beta-badge {
  display: inline-block;
  font-size: 0.95em;
  font-weight: 800;
  padding: 0px 6px;
  border-radius: 4px;
  background: #9599ff;
  color: #200e2e;
  letter-spacing: 0.04em;
  vertical-align: middle;
  margin-left: 0.4em;
  position: relative;
  top: -0.15em;
}

#header-page #portal-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 120px;
  overflow: visible;
}

#header-page #portal-hero-right {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-height: 120px;
}

#header-page #patreon-login-btn {
  font-size: 0.85em;
  padding: 0.5em 1.1em;
  white-space: nowrap;
  text-decoration: none;
}

#header-page #user-info-bar {
  display: none;
  align-items: center;
  gap: 0.75em;
  font-size: 0.82em;
  line-height: 1.4;
}

#header-page #hero-unauthed {
  display: block;
}

body.user-logged-in #header-page #user-info-bar {
  display: flex;
}

body.user-logged-in #header-page #hero-unauthed {
  display: none;
}

#header-page #user-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 2px solid #fa61b9;
  object-fit: cover;
  flex-shrink: 0;
}

#header-page #user-avatar-placeholder {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 2px solid #444;
  background: #2a1040;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #666;
  font-size: 1.4em;
}

#header-page #user-details {
  text-align: right;
}

#header-page #user-name {
  font-weight: 800;
  color: #e6e6e6;
  display: block;
}

#header-page .tier-badge {
  display: inline-block;
  font-size: 0.78em;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  background: #fa61b9;
  color: #200e2e;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-top: 2px;
}

#header-page .tier-badge.free {
  background: #444;
  color: #ccc;
}

@media screen and (max-width: 980px) {
  #header-page #portal-hero {
    flex-direction: column;
    min-height: auto;
    padding: 1.5em 1em;
    gap: 1em;
  }
  #header-page #portal-hero-right {
    flex: none;
    width: 100%;
    justify-content: center;
    min-height: auto;
  }
}

/* Reserve space for the header so content doesn't jump */
#header-container {
  min-height: 187px; /* Matches the height of your logo + padding */
  display: block;
  background-color: transparent;
}

/* On smaller screens where the logo shrinks, adjust the placeholder */
@media screen and (max-width: 980px) {
  #header-container {
    min-height: 220px; /* Adjust based on your mobile layout height */
  }
}

/* Three-dot menu */
#header-page #user-menu-wrap {
  position: relative;
  flex-shrink: 0;
  align-self: flex-start;
  margin-top: auto;
  margin-bottom: auto;
}

#header-page #user-info-bar #user-menu-btn {
  position: relative;
  background: none;
  border: none;
  color: #aaa;
  font-size: 1.4em;
  cursor: pointer;
  padding: 0.1em 0.3em;
  line-height: 1;
  border-radius: 4px;
  transition: color 0.15s, background 0.15s;
}

#header-page #user-menu-btn:hover {
  color: #e6e6e6;
  background: #2a1040;
}

#header-page #user-menu-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  background: #1a0b28;
  border: 1px solid #3a2050;
  border-radius: 6px;
  padding: 0.4em 0;
  min-width: 150px;
  z-index: 100;
  display: flex;
  flex-direction: column;
}

#header-page #user-menu-dropdown.hidden {
  display: none;
}

#header-page #cookie-optin {
  display: flex;
  align-items: center;
  gap: 0.4em;
  font-size: 0.8em;
  color: #aaa;
  cursor: pointer;
  white-space: nowrap;
  padding: 0.45em 0.9em;
  margin: 0;
}

#header-page #cookie-optin:hover {
  color: #e6e6e6;
}

#header-page #cookie-optin input[type="checkbox"] {
  appearance: auto !important;
  width: auto;
  cursor: pointer;
}

#header-page #user-info-bar #logout-btn {
  background: none;
  border: none;
  color: #aaa;
  font-size: 0.8em;
  cursor: pointer;
  text-align: left;
  padding: 0.45em 0.9em;
  width: 100%;
  white-space: nowrap;
}

#header-page #logout-btn:hover {
  color: #fa61b9;
}
