:root {
  --mineraze-blue-dark: #12385c;
  --mineraze-blue-deeper: #0b1d30;
  --mineraze-blue: #1e9bd7;
  --mineraze-green: #39c766;
  --mineraze-text: #172033;
  --mineraze-muted: #5f6f84;
  --mineraze-soft: #8b98ab;
  --mineraze-border: rgba(15, 23, 42, 0.10);
  --mineraze-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
}

html,
body {
  background: #efefef;
}

body,
.md-typeset {
  font-family: 'Montserrat', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Kill Material's native top chrome. We render a store-style header instead. */
.md-header,
.md-tabs {
  display: none !important;
}

.md-grid {
  max-width: 1280px;
}

/* Store-style header */
.mineraze-wiki-header {
  position: relative;
  z-index: 10;
  background: transparent;
  box-shadow: none;
}

.mineraze-wiki-hero {
  position: relative;
  min-height: 245px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(24, 150, 205, 0.62) 0%, rgba(6, 33, 56, 0.68) 100%),
    url("https://i.pinimg.com/originals/89/21/9b/89219b60d170d1b5fbb4b4ab11bf4996.jpg") center top / cover no-repeat;
}

.mineraze-wiki-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(255,255,255,0.08), transparent 42%);
  pointer-events: none;
}

.mineraze-wiki-topbar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 2;
  background: rgba(255, 255, 255, 0.10);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 3px 3px rgba(0,0,0,0.05);
  backdrop-filter: blur(3px);
}

.mineraze-wiki-topbar-inner {
  min-height: 62px;
  width: min(960px, calc(100vw - 32px));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.mineraze-wiki-toplinks {
  display: flex;
  align-items: center;
  gap: 1.15rem;
}

.mineraze-wiki-toplinks a {
  display: inline-flex;
  align-items: center;
  gap: 0.36rem;
  color: rgba(255,255,255,0.94) !important;
  font-size: 0.66rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0.03em;
  text-decoration: none !important;
  text-transform: uppercase;
}

.mineraze-wiki-toplinks a:hover {
  color: #ffffff !important;
}

.mineraze-wiki-server-pill {
  appearance: none;
  border: 0;
  padding: 0;
  background: transparent;
  color: #ffffff;
  cursor: pointer;
  text-align: right;
  line-height: 1.15;
}

.mineraze-wiki-server-pill span {
  display: block;
  color: rgba(255,255,255,0.88);
  font-size: 0.56rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.mineraze-wiki-server-pill strong {
  display: block;
  color: #ffffff;
  font-size: 0.92rem;
  font-weight: 900;
  letter-spacing: 0.02em;
}

.mineraze-wiki-logo {
  position: relative;
  z-index: 1;
  display: block;
  width: 245px;
  max-width: 42vw;
  margin-top: 34px;
  line-height: 0;
  filter: drop-shadow(0 14px 26px rgba(0,0,0,0.24));
}

.mineraze-wiki-logo img,
.md-typeset .mineraze-wiki-logo img {
  display: block;
  width: 100%;
  max-width: 245px;
  height: auto;
  max-height: 175px;
  object-fit: contain;
  margin: 0;
}

.mineraze-wiki-nav-wrap {
  position: relative;
  z-index: 3;
  background: #ffffff;
  border-bottom: 1px solid rgba(15,23,42,0.08);
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
}

.mineraze-wiki-nav-inner {
  min-height: 68px;
  width: min(960px, calc(100vw - 32px));
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
}

.mineraze-wiki-mobile-menu {
  display: none;
  color: #12385c;
}

.mineraze-wiki-primary-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.mineraze-wiki-nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 1.12rem;
  border-radius: 8px;
  background: #f5f8fb;
  border: 1px solid rgba(15,23,42,0.08);
  color: #172033 !important;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.035em;
  text-transform: uppercase;
  text-decoration: none !important;
  transition: 0.14s ease;
}

.mineraze-wiki-nav-link:hover,
.mineraze-wiki-nav-link.is-active {
  background: #eef8ff;
  border-color: rgba(30,155,215,0.35);
  color: #12385c !important;
  box-shadow: inset 0 -2px 0 #1e9bd7;
}

.mineraze-wiki-search-wrap {
  width: min(260px, 24vw);
  margin-left: 1rem;
}

.mineraze-wiki-search-wrap .md-search {
  width: 100%;
}

.mineraze-wiki-search-wrap .md-search__form {
  height: 42px;
  border-radius: 999px;
  background: #eef8ff;
  border: 1px solid rgba(30,155,215,0.22);
  box-shadow: none;
}

.mineraze-wiki-search-wrap .md-search__input,
.mineraze-wiki-search-wrap .md-search__icon {
  color: #12385c;
}

.mineraze-wiki-search-wrap .md-search__input::placeholder {
  color: #5f6f84;
}

.mineraze-wiki-palette {
  display: flex;
  align-items: center;
}

.mineraze-wiki-palette .md-header__button {
  color: #12385c;
}

/* Page layout */
.md-main__inner {
  margin-top: 2.2rem;
}

.md-content,
.md-content__inner {
  max-width: none !important;
}

.md-typeset {
  font-size: 0.82rem;
  line-height: 1.72;
}

.md-typeset h1,
.md-typeset h2,
.md-typeset h3 {
  color: var(--mineraze-text);
  font-weight: 900;
  letter-spacing: -0.02em;
}

.md-typeset h1 {
  font-size: 2rem;
}

.md-typeset h2 {
  margin-top: 1.6rem;
  font-size: 1.35rem;
}

.md-typeset code {
  border-radius: 6px;
  font-weight: 700;
  white-space: nowrap;
}

/* Left navigation cleanup */
.md-sidebar--primary .md-sidebar__scrollwrap {
  padding-right: 0.8rem;
}

.md-sidebar--primary .md-nav {
  background: transparent;
}

.md-sidebar--primary > .md-sidebar__scrollwrap > .md-sidebar__inner > .md-nav > .md-nav__title {
  display: none !important;
}

.md-sidebar--primary .md-nav__item--section > .md-nav__link {
  margin-top: 0.7rem;
  color: #6b7280;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  text-transform: none;
}

.md-sidebar--primary .md-nav__link {
  margin: 0;
  padding: 0.22rem 0;
  color: #172033;
  font-size: 0.78rem;
  font-weight: 800;
  line-height: 1.45;
}

.md-sidebar--primary .md-nav__link:hover,
.md-sidebar--primary .md-nav__link--active {
  color: #1e88d1 !important;
  background: transparent;
}

/* GitBook-like right table of contents */
.md-sidebar--secondary .md-nav {
  padding-left: 0.9rem;
  border-left: 1px solid rgba(15, 23, 42, 0.13);
}

.md-sidebar--secondary .md-nav__title,
.md-sidebar--secondary .md-nav__title[for="__toc"] {
  display: block !important;
  margin: 0 0 0.7rem;
  padding: 0;
  background: transparent;
  box-shadow: none;
  color: #6b7280;
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.055em;
  text-transform: uppercase;
}

.md-sidebar--secondary .md-nav__title::before {
  content: "☰ ";
  opacity: 0.65;
}

.md-sidebar--secondary .md-nav__link {
  margin: 0;
  padding: 0.22rem 0;
  color: #4b5563;
  font-size: 0.76rem;
  font-weight: 500 !important;
  line-height: 1.45;
  letter-spacing: 0;
}

.md-sidebar--secondary .md-nav__link:hover,
.md-sidebar--secondary .md-nav__link--active {
  color: #1e88d1 !important;
  font-weight: 500 !important;
  background: transparent;
}

.md-sidebar--secondary .md-nav__link--active::before {
  content: "";
  display: inline-block;
  width: 2px;
  height: 1em;
  margin-right: 0.42rem;
  background: #1e88d1;
  vertical-align: -0.15em;
}

/* Tables */
.md-typeset table:not([class]) {
  display: table;
  width: 100%;
  margin: 1.1rem 0 1.4rem;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid rgba(15, 23, 42, 0.10);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--mineraze-shadow);
}

.md-typeset table:not([class]) th,
.md-typeset table:not([class]) td {
  padding: 0.72rem 0.85rem;
  vertical-align: top;
}

.md-typeset table:not([class]) th {
  background: #eef8ff;
  color: var(--mineraze-blue-dark);
  font-weight: 900;
}

.md-typeset table:not([class]) td:first-child {
  font-weight: 800;
}

/* Homepage */
body:has(.mineraze-store-page) .md-sidebar--primary,
body:has(.mineraze-store-page) .md-sidebar--secondary,
body:has(.mineraze-store-page) .md-content__button,
body:has(.mineraze-store-page) .md-path,
body:has(.mineraze-store-page) .md-content__inner > h1:first-child {
  display: none !important;
}

body:has(.mineraze-store-page) .md-main__inner {
  display: block;
  width: min(960px, calc(100vw - 32px));
  max-width: none;
  margin: 2.2rem auto 0;
}

body:has(.mineraze-store-page) .md-content {
  margin: 0 !important;
}

body:has(.mineraze-store-page) .md-content__inner {
  margin: 0 !important;
  padding: 0 !important;
}

body:has(.mineraze-store-page) .md-content__inner::before {
  display: none;
}

.mineraze-store-page {
  width: 100% !important;
  max-width: none !important;
  position: static !important;
  left: auto !important;
  transform: none !important;
  margin: 0 auto 70px !important;
}

.mineraze-store-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid var(--mineraze-border);
  box-shadow: 0 10px 30px rgba(15,23,42,0.10);
  overflow: hidden;
}

.mineraze-store-header {
  padding: 30px;
  background: linear-gradient(135deg, var(--mineraze-blue-dark) 0%, var(--mineraze-blue) 100%);
  color: #ffffff;
  text-align: center;
}

.mineraze-store-header span {
  display: block;
  margin-bottom: 7px;
  color: rgba(255,255,255,0.82);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.mineraze-store-header h1 {
  margin: 0;
  color: #ffffff;
  font-size: 30px;
  line-height: 1.1;
  font-weight: 900;
}

.mineraze-store-header p {
  max-width: 720px;
  margin: 10px auto 0;
  color: rgba(255,255,255,0.84);
  font-size: 14px;
  font-weight: 600;
}

.mineraze-store-body {
  padding: 34px 38px;
}

.mineraze-store-body > h2:first-child {
  margin-top: 0;
}

.mineraze-warning {
  margin: 20px 0;
  padding: 14px 16px;
  border-radius: 10px;
  background: #fff3cd;
  border: 1px solid #ffbf47;
  color: #5c3900;
  font-weight: 800;
}

.mineraze-category-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 20px 0 30px;
}

.mineraze-category-card {
  display: block;
  min-height: 150px;
  padding: 18px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid var(--mineraze-border);
  box-shadow: 0 6px 18px rgba(15,23,42,0.06);
  color: var(--mineraze-text) !important;
  text-decoration: none !important;
  transition: 0.16s ease;
}

.mineraze-category-card:hover {
  transform: translateY(-3px);
  border-color: rgba(30,155,215,0.36);
  box-shadow: 0 14px 28px rgba(15,23,42,0.12);
}

.mineraze-category-card span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  margin-bottom: 12px;
  border-radius: 12px;
  background: #eef8ff;
  font-size: 20px;
}

.mineraze-category-card strong {
  display: block;
  margin-bottom: 6px;
  color: var(--mineraze-text);
  font-size: 15px;
  font-weight: 900;
}

.mineraze-category-card p {
  margin: 0;
  color: var(--mineraze-muted);
  font-size: 13px;
  line-height: 1.55;
  font-weight: 600;
}

.mineraze-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.mineraze-action-row a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  text-decoration: none !important;
}

.mineraze-action-main {
  background: linear-gradient(135deg, #39c766, #249f46);
  color: #ffffff !important;
  box-shadow: 0 8px 18px rgba(36,159,70,0.22);
}

.mineraze-action-secondary {
  background: #ffffff;
  color: var(--mineraze-text) !important;
  border: 1px solid var(--mineraze-border);
}

/* Footer */
.md-footer-meta,
.md-footer__inner:not(.mineraze-footer-inner):not(.mineraze-footer-bottom-inner) {
  display: none !important;
}

.mineraze-footer {
  margin-top: 3rem;
  background: #081421;
  color: #ffffff;
}

.mineraze-footer-main {
  padding: 2rem 0;
  background: #0b1d30;
  border-top: 1px solid rgba(255,255,255,0.06);
}

.mineraze-footer-inner,
.mineraze-footer-bottom-inner {
  width: min(960px, calc(100vw - 32px));
}

.mineraze-footer-inner {
  display: flex;
  align-items: center;
  gap: 1.1rem;
}

.mineraze-footer-badge {
  width: 3.25rem;
  height: 3.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: 1rem;
  background: rgba(30, 155, 215, 0.14);
  border: 1px solid rgba(30, 155, 215, 0.25);
  font-size: 1.35rem;
}

.mineraze-footer-copy {
  flex: 1;
}

.mineraze-footer-copy strong {
  display: block;
  color: #ffffff;
  font-size: 1rem;
  font-weight: 900;
  margin-bottom: 0.35rem;
}

.mineraze-footer-copy p {
  max-width: 760px;
  margin: 0;
  color: rgba(255,255,255,0.82);
  font-size: 0.78rem;
  line-height: 1.55;
  font-weight: 700;
}

.mineraze-footer-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.72rem 1rem;
  border-radius: 999px;
  background: rgba(57, 199, 102, 0.14);
  border: 1px solid rgba(57, 199, 102, 0.45);
  color: #9cf3b7 !important;
  text-decoration: none !important;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.mineraze-footer-bottom {
  padding: 1.1rem 0;
  background: #081421;
}

.mineraze-footer-bottom-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  color: rgba(255,255,255,0.76);
  font-size: 0.72rem;
  font-weight: 700;
}

.mineraze-footer-links {
  display: flex;
  gap: 1rem;
}

.mineraze-footer-links a {
  color: rgba(255,255,255,0.78) !important;
  text-decoration: none !important;
  font-weight: 800;
}

/* Dark mode */
[data-md-color-scheme="slate"] {
  --mineraze-text: #ffffff;
  --mineraze-muted: #cbd5e1;
  --mineraze-soft: #9aa8bc;
  --mineraze-border: rgba(255,255,255,0.10);
}

[data-md-color-scheme="slate"] body,
[data-md-color-scheme="slate"] {
  background: #111827;
}

[data-md-color-scheme="slate"] .mineraze-wiki-nav-wrap,
[data-md-color-scheme="slate"] .mineraze-store-card,
[data-md-color-scheme="slate"] .mineraze-category-card {
  background: #1f2937;
}

[data-md-color-scheme="slate"] .mineraze-store-body {
  background: #1f2937;
}

[data-md-color-scheme="slate"] .mineraze-wiki-nav-link,
[data-md-color-scheme="slate"] .mineraze-action-secondary {
  background: #111827;
  border-color: rgba(255,255,255,0.10);
  color: #ffffff !important;
}

[data-md-color-scheme="slate"] .mineraze-wiki-search-wrap .md-search__form {
  background: #111827;
}

[data-md-color-scheme="slate"] .mineraze-wiki-search-wrap .md-search__input,
[data-md-color-scheme="slate"] .mineraze-wiki-search-wrap .md-search__icon,
[data-md-color-scheme="slate"] .mineraze-wiki-palette .md-header__button {
  color: #ffffff;
}

[data-md-color-scheme="slate"] .md-sidebar--secondary .md-nav,
[data-md-color-scheme="slate"] .md-sidebar--primary .md-nav {
  border-color: rgba(255,255,255,0.14);
}

[data-md-color-scheme="slate"] .md-sidebar--secondary .md-nav__link,
[data-md-color-scheme="slate"] .md-sidebar--primary .md-nav__link {
  color: #b6c2d2;
}

[data-md-color-scheme="slate"] .md-typeset table:not([class]) th {
  background: #14304d;
  color: #ffffff;
}

/* Responsive */
@media (max-width: 1100px) {
  .mineraze-wiki-search-wrap {
    width: min(240px, 26vw);
    margin-left: 0.4rem;
  }

  .mineraze-wiki-nav-link {
    padding: 0 0.82rem;
  }
}

@media (max-width: 900px) {
  .mineraze-wiki-hero {
    min-height: 185px;
  }

  .mineraze-wiki-topbar-inner,
  .mineraze-wiki-nav-inner,
  .mineraze-footer-inner,
  .mineraze-footer-bottom-inner {
    width: min(100%, calc(100vw - 24px));
  }

  .mineraze-wiki-logo {
    width: 190px;
    margin-top: 34px;
  }

  .mineraze-wiki-mobile-menu {
    display: inline-flex;
  }

  .mineraze-wiki-primary-nav {
    display: none;
  }

  .mineraze-wiki-search-wrap {
    flex: 1;
    width: auto;
    margin-left: 0;
  }

  .mineraze-footer-inner,
  .mineraze-footer-bottom-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .mineraze-category-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .mineraze-wiki-toplinks {
    gap: 0.5rem;
  }

  .mineraze-wiki-toplinks a {
    font-size: 0;
    padding: 0.4rem;
  }

  .mineraze-wiki-toplinks a span {
    font-size: 0.85rem;
  }

  .mineraze-wiki-server-pill {
    display: none;
  }

  .mineraze-wiki-logo {
    width: 165px;
  }

  .mineraze-category-grid {
    grid-template-columns: 1fr;
  }

  .mineraze-store-header,
  .mineraze-store-body {
    padding: 24px;
  }

  .mineraze-store-header h1 {
    font-size: 24px;
  }

  .mineraze-action-row a {
    width: 100%;
  }

  .mineraze-footer-links {
    flex-wrap: wrap;
  }
}

/* ================================
   MineRaze UI fix v10
   - one-line store-style category navbar
   - GitBook-like sticky sidebars
   ================================ */

/* Make the category navbar use the full available width and stop wrapping one item to a second row. */
.mineraze-wiki-nav-inner {
  width: min(1180px, calc(100vw - 32px)) !important;
  min-height: 66px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.72rem !important;
  flex-wrap: nowrap !important;
}

.mineraze-wiki-primary-nav {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 auto !important;
  flex-wrap: nowrap !important;
  gap: 0.52rem !important;
  min-width: 0 !important;
}

.mineraze-wiki-nav-link {
  min-height: 34px !important;
  min-width: 132px !important;
  padding: 0 0.78rem !important;
  white-space: nowrap !important;
  border-radius: 7px !important;
  font-size: 0.70rem !important;
  box-shadow: 0 2px 5px rgba(15, 23, 42, 0.04) !important;
}

.mineraze-wiki-palette {
  flex: 0 0 auto !important;
  margin-left: 0.45rem !important;
}

.mineraze-wiki-search-wrap {
  flex: 0 0 250px !important;
  width: 250px !important;
  max-width: 250px !important;
  margin-left: 0.25rem !important;
}

.mineraze-wiki-search-wrap .md-search__form {
  height: 38px !important;
}

/* Keep the hero/store look, but make the navigation strip more compact. */
.mineraze-wiki-nav-wrap {
  box-shadow: 0 5px 18px rgba(15, 23, 42, 0.07) !important;
}

/* GitBook-like sidebars: they stay visible, but attach near the top instead of floating in the middle. */
@media screen and (min-width: 76.25em) {
  .md-main__inner {
    align-items: flex-start !important;
  }

  .md-sidebar {
    position: sticky !important;
    top: 1.2rem !important;
    align-self: flex-start !important;
    height: calc(100vh - 2.4rem) !important;
    max-height: calc(100vh - 2.4rem) !important;
  }

  .md-sidebar__scrollwrap {
    height: auto !important;
    max-height: calc(100vh - 2.4rem) !important;
    overflow-y: auto !important;
    scrollbar-width: thin;
  }

  .md-sidebar--primary .md-sidebar__scrollwrap,
  .md-sidebar--secondary .md-sidebar__scrollwrap {
    margin: 0 !important;
  }
}

/* Left sidebar: closer to GitBook, less heavy, less “table-looking”. */
.md-sidebar--primary {
  padding-top: 0 !important;
}

.md-sidebar--primary .md-nav__title {
  background: transparent !important;
  box-shadow: none !important;
}

.md-sidebar--primary .md-nav__link {
  border-radius: 6px !important;
  padding: 0.24rem 0.32rem !important;
  color: #111827 !important;
  font-size: 0.74rem !important;
  font-weight: 800 !important;
}

.md-sidebar--primary .md-nav__link:hover,
.md-sidebar--primary .md-nav__link--active {
  background: rgba(30, 155, 215, 0.07) !important;
  color: #1e88d1 !important;
}

.md-sidebar--primary .md-nav__item--section > .md-nav__link {
  margin-top: 0.72rem !important;
  background: transparent !important;
  color: #6b7280 !important;
  font-size: 0.68rem !important;
  font-weight: 900 !important;
}

/* Right TOC: GitBook-style subtle “On this page” block. */
.md-sidebar--secondary .md-nav {
  padding-left: 0.82rem !important;
  border-left: 1px solid rgba(15, 23, 42, 0.10) !important;
}

.md-sidebar--secondary .md-nav__title,
.md-sidebar--secondary .md-nav__title[for="__toc"] {
  margin-bottom: 0.55rem !important;
  color: #6b7280 !important;
  font-size: 0.62rem !important;
  font-weight: 900 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase !important;
}

.md-sidebar--secondary .md-nav__link {
  padding: 0.20rem 0 !important;
  color: #4b5563 !important;
  font-size: 0.72rem !important;
  font-weight: 500 !important;
  line-height: 1.42 !important;
}

.md-sidebar--secondary .md-nav__link:hover,
.md-sidebar--secondary .md-nav__link--active {
  color: #1e88d1 !important;
  font-weight: 500 !important;
}

/* Material's floating back-to-top bubble looks wrong with the store-style layout. */
.md-top {
  display: none !important;
}

/* On pages with sidebars, keep content comfortably centered. */
.md-main__inner {
  column-gap: 1.2rem !important;
}

.md-content__inner {
  padding-top: 0.15rem !important;
}

@media (max-width: 1150px) {
  .mineraze-wiki-nav-inner {
    width: min(1040px, calc(100vw - 24px)) !important;
    gap: 0.5rem !important;
  }

  .mineraze-wiki-nav-link {
    min-width: 116px !important;
    padding: 0 0.62rem !important;
    font-size: 0.66rem !important;
  }

  .mineraze-wiki-search-wrap {
    flex-basis: 220px !important;
    width: 220px !important;
    max-width: 220px !important;
  }
}

@media (max-width: 900px) {
  .mineraze-wiki-primary-nav {
    display: none !important;
  }

  .mineraze-wiki-search-wrap {
    flex: 1 1 auto !important;
    width: auto !important;
    max-width: none !important;
  }
}

/* ================================
   MineRaze UI fix v11
   - hover dropdown category navbar
   - 20% smaller side navigation / table of contents
   ================================ */

/* Keep the nav row compact and allow dropdowns to escape the strip. */
.mineraze-wiki-nav-wrap,
.mineraze-wiki-nav-inner,
.mineraze-wiki-primary-nav {
  overflow: visible !important;
}

.mineraze-wiki-nav-wrap {
  z-index: 60 !important;
}

.mineraze-wiki-nav-inner {
  width: min(1180px, calc(100vw - 32px)) !important;
  min-height: 62px !important;
  gap: 0.58rem !important;
}

.mineraze-wiki-primary-nav {
  flex-wrap: nowrap !important;
  gap: 0.48rem !important;
}

.mineraze-wiki-nav-item {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.mineraze-wiki-nav-link {
  min-width: 132px !important;
  min-height: 34px !important;
  padding: 0 0.72rem !important;
  gap: 0.35rem !important;
}

.mineraze-wiki-nav-caret {
  margin-left: 0.12rem;
  color: rgba(23, 32, 51, 0.58);
  font-size: 0.62rem;
  line-height: 1;
  transform: translateY(-0.02rem);
  transition: transform 0.14s ease, color 0.14s ease;
}

.mineraze-wiki-nav-item:hover .mineraze-wiki-nav-caret,
.mineraze-wiki-nav-item:focus-within .mineraze-wiki-nav-caret,
.mineraze-wiki-nav-item.is-active .mineraze-wiki-nav-caret {
  color: #1e88d1;
  transform: rotate(180deg);
}

.mineraze-wiki-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  z-index: 120;
  width: max-content;
  min-width: 250px;
  max-width: min(380px, calc(100vw - 32px));
  max-height: min(70vh, 620px);
  overflow-y: auto;
  padding: 0.58rem;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.10);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.18);
  transform: translateX(-50%) translateY(-6px);
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.14s ease, transform 0.14s ease, visibility 0.14s ease;
}

.mineraze-wiki-dropdown::before {
  content: "";
  position: absolute;
  top: -8px;
  left: 50%;
  width: 14px;
  height: 14px;
  background: #ffffff;
  border-left: 1px solid rgba(15, 23, 42, 0.08);
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  transform: translateX(-50%) rotate(45deg);
}

.mineraze-wiki-nav-item:hover > .mineraze-wiki-dropdown,
.mineraze-wiki-nav-item:focus-within > .mineraze-wiki-dropdown {
  opacity: 1;
  pointer-events: auto;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.mineraze-wiki-dropdown-link,
.mineraze-wiki-dropdown-heading {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 34px;
  padding: 0.48rem 0.62rem;
  border-radius: 8px;
  color: #172033 !important;
  text-decoration: none !important;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1.25;
  white-space: nowrap;
}

.mineraze-wiki-dropdown-link:hover,
.mineraze-wiki-dropdown-link.is-active {
  background: #eef8ff;
  color: #1e88d1 !important;
}

.mineraze-wiki-dropdown-heading {
  color: #6b7280 !important;
  font-size: 0.60rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.mineraze-wiki-dropdown-sublist {
  margin: 0 0 0.2rem 0.28rem;
  padding-left: 0.52rem;
  border-left: 1px solid rgba(15, 23, 42, 0.10);
}

.mineraze-wiki-dropdown-link-sub {
  min-height: 30px;
  padding: 0.38rem 0.52rem;
  color: #4b5563 !important;
  font-size: 0.66rem;
  font-weight: 700;
}

/* Search sits after the hover nav and does not force wrapping. */
.mineraze-wiki-search-wrap {
  flex: 0 0 245px !important;
  width: 245px !important;
  max-width: 245px !important;
  margin-left: 0.35rem !important;
}

/* 20% smaller side navigation and right table of contents. */
@media screen and (min-width: 76.25em) {
  .md-sidebar--primary {
    width: 9.7rem !important;
  }

  .md-sidebar--secondary {
    width: 9.7rem !important;
  }

  .md-sidebar--primary .md-sidebar__scrollwrap,
  .md-sidebar--secondary .md-sidebar__scrollwrap {
    padding-right: 0.42rem !important;
  }
}

.md-sidebar--primary .md-nav__link {
  padding: 0.18rem 0.25rem !important;
  border-radius: 5px !important;
  font-size: 0.59rem !important;
  line-height: 1.32 !important;
  font-weight: 760 !important;
}

.md-sidebar--primary .md-nav__item--section > .md-nav__link {
  margin-top: 0.58rem !important;
  font-size: 0.54rem !important;
  line-height: 1.25 !important;
  letter-spacing: 0.035em !important;
}

.md-sidebar--secondary .md-nav {
  padding-left: 0.66rem !important;
}

.md-sidebar--secondary .md-nav__title,
.md-sidebar--secondary .md-nav__title[for="__toc"] {
  margin-bottom: 0.45rem !important;
  font-size: 0.50rem !important;
  line-height: 1.2 !important;
}

.md-sidebar--secondary .md-nav__link {
  padding: 0.16rem 0 !important;
  font-size: 0.58rem !important;
  line-height: 1.32 !important;
  font-weight: 500 !important;
}

/* Dark mode support for dropdowns. */
[data-md-color-scheme="slate"] .mineraze-wiki-dropdown,
[data-md-color-scheme="slate"] .mineraze-wiki-dropdown::before {
  background: #1f2937;
  border-color: rgba(255,255,255,0.10);
}

[data-md-color-scheme="slate"] .mineraze-wiki-dropdown-link,
[data-md-color-scheme="slate"] .mineraze-wiki-dropdown-heading {
  color: #e5edf7 !important;
}

[data-md-color-scheme="slate"] .mineraze-wiki-dropdown-link-sub {
  color: #b6c2d2 !important;
}

[data-md-color-scheme="slate"] .mineraze-wiki-dropdown-link:hover,
[data-md-color-scheme="slate"] .mineraze-wiki-dropdown-link.is-active {
  background: rgba(30, 155, 215, 0.14);
  color: #8bd8ff !important;
}

@media (max-width: 1150px) {
  .mineraze-wiki-nav-link {
    min-width: 112px !important;
    padding: 0 0.58rem !important;
    font-size: 0.64rem !important;
  }

  .mineraze-wiki-search-wrap {
    flex-basis: 215px !important;
    width: 215px !important;
    max-width: 215px !important;
  }

  .mineraze-wiki-dropdown {
    min-width: 230px;
  }
}

@media (max-width: 900px) {
  .mineraze-wiki-primary-nav {
    display: none !important;
  }

  .mineraze-wiki-search-wrap {
    flex: 1 1 auto !important;
    width: auto !important;
    max-width: none !important;
  }
}

/* ================================
   MineRaze Wiki UI fix v12
   - stable hover dropdowns
   - search suggestions visible
   - store-like topbar / IP bar
   - smaller footer text
   ================================ */

#ipvalue {
  position: absolute !important;
  left: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

.mineraze-wiki-topbar-inner {
  width: min(960px, calc(100vw - 32px)) !important;
  min-height: 62px !important;
}

.mineraze-wiki-toplinks {
  gap: 1.12rem !important;
}

.mineraze-wiki-toplinks a {
  display: inline-flex !important;
  align-items: center !important;
  gap: 0.36rem !important;
  color: rgba(255,255,255,0.94) !important;
  font-size: 0.66rem !important;
  font-weight: 900 !important;
  letter-spacing: 0.03em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  opacity: 0.98 !important;
}

.mineraze-wiki-toplinks a:hover {
  color: #ffffff !important;
  opacity: 1 !important;
}

.mineraze-top-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 0.72rem;
  opacity: 0.9;
}

.mineraze-wiki-server-pill {
  position: relative !important;
  display: block !important;
  appearance: none !important;
  border: 0 !important;
  padding: 0 !important;
  background: transparent !important;
  color: #ffffff !important;
  cursor: pointer !important;
  text-align: right !important;
  line-height: 1.15 !important;
  box-shadow: none !important;
}

.mineraze-wiki-server-pill span {
  display: block !important;
  color: rgba(255,255,255,0.88) !important;
  font-size: 0.56rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.07em !important;
  text-transform: uppercase !important;
}

.mineraze-wiki-server-pill strong {
  display: block !important;
  color: #ffffff !important;
  font-size: 0.92rem !important;
  font-weight: 900 !important;
  letter-spacing: 0.02em !important;
}

.mineraze-wiki-server-pill.is-copied strong::after {
  content: " copied";
  margin-left: 0.35rem;
  color: #9cf3b7;
  font-size: 0.68rem;
  text-transform: uppercase;
}

/* Keep category nav on one clean row. */
.mineraze-wiki-nav-wrap,
.mineraze-wiki-nav-inner,
.mineraze-wiki-primary-nav,
.mineraze-wiki-nav-item {
  overflow: visible !important;
}

.mineraze-wiki-nav-wrap {
  z-index: 250 !important;
}

.mineraze-wiki-nav-inner {
  width: min(1080px, calc(100vw - 32px)) !important;
  min-height: 64px !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.62rem !important;
}

.mineraze-wiki-primary-nav {
  flex: 0 0 auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-wrap: nowrap !important;
  gap: 0.52rem !important;
}

.mineraze-wiki-nav-item {
  position: relative !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 12px 0 !important;
  margin: -12px 0 !important;
}

.mineraze-wiki-nav-link {
  min-width: 122px !important;
  min-height: 34px !important;
  padding: 0 0.72rem !important;
  border-radius: 8px !important;
  white-space: nowrap !important;
}

/* Dropdown stays selectable while moving from the button to the menu. */
.mineraze-wiki-dropdown {
  top: calc(100% - 1px) !important;
  left: 50% !important;
  z-index: 800 !important;
  transform: translateX(-50%) translateY(0) !important;
  opacity: 0 !important;
  pointer-events: none !important;
  visibility: hidden !important;
  transition: opacity 0.12s ease, visibility 0.12s ease !important;
}

.mineraze-wiki-dropdown::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -18px;
  height: 18px;
  background: transparent;
}

.mineraze-wiki-nav-item:hover > .mineraze-wiki-dropdown,
.mineraze-wiki-nav-item:focus-within > .mineraze-wiki-dropdown,
.mineraze-wiki-nav-item.is-hovered > .mineraze-wiki-dropdown {
  opacity: 1 !important;
  pointer-events: auto !important;
  visibility: visible !important;
}

.mineraze-wiki-dropdown-link,
.mineraze-wiki-dropdown-heading {
  position: relative;
  z-index: 2;
}

/* Search result dropdown/suggestions. */
.mineraze-wiki-search-wrap {
  position: relative !important;
  flex: 0 0 260px !important;
  width: 260px !important;
  max-width: 260px !important;
  margin-left: 0.35rem !important;
  z-index: 900 !important;
}

.mineraze-wiki-search-wrap .md-search {
  position: relative !important;
  width: 100% !important;
}

.mineraze-wiki-search-wrap .md-search__form {
  height: 42px !important;
  border-radius: 999px !important;
  background: #eef8ff !important;
  border: 1px solid rgba(30,155,215,0.24) !important;
  box-shadow: none !important;
}

.mineraze-wiki-search-wrap .md-search__output {
  position: absolute !important;
  top: calc(100% + 10px) !important;
  right: 0 !important;
  left: auto !important;
  z-index: 950 !important;
  width: min(560px, calc(100vw - 32px)) !important;
  max-height: min(68vh, 620px) !important;
  overflow: auto !important;
  border-radius: 12px !important;
  background: var(--md-default-bg-color) !important;
  border: 1px solid rgba(15, 23, 42, 0.12) !important;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.18) !important;
}

.mineraze-wiki-search-wrap .md-search__scrollwrap {
  max-height: min(68vh, 620px) !important;
}

.mineraze-wiki-search-wrap .md-search-result__meta {
  font-size: 0.62rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.03em !important;
  text-transform: uppercase !important;
}

.mineraze-wiki-search-wrap .md-search-result__link {
  padding: 0.6rem 0.75rem !important;
}

.mineraze-wiki-search-wrap .md-search-result__title {
  font-size: 0.78rem !important;
  font-weight: 850 !important;
}

.mineraze-wiki-search-wrap .md-search-result__teaser {
  font-size: 0.66rem !important;
  line-height: 1.35 !important;
}

/* Footer text about 20% smaller. */
.mineraze-footer-main {
  padding: 1.55rem 0 !important;
}

.mineraze-footer-copy strong {
  font-size: 0.80rem !important;
  margin-bottom: 0.28rem !important;
}

.mineraze-footer-copy p {
  max-width: 760px !important;
  font-size: 0.62rem !important;
  line-height: 1.45 !important;
  font-weight: 700 !important;
}

.mineraze-footer-badge {
  width: 2.65rem !important;
  height: 2.65rem !important;
  border-radius: 0.82rem !important;
  font-size: 1.05rem !important;
}

.mineraze-footer-pill {
  padding: 0.56rem 0.82rem !important;
  font-size: 0.58rem !important;
}

.mineraze-footer-bottom {
  padding: 0.85rem 0 !important;
}

.mineraze-footer-bottom-inner {
  font-size: 0.58rem !important;
  line-height: 1.45 !important;
}

/* Keep sidebars subtle and smaller without becoming unreadable. */
.md-sidebar--primary .md-nav__link,
.md-sidebar--secondary .md-nav__link {
  font-size: 0.60rem !important;
  line-height: 1.35 !important;
}

.md-sidebar--secondary .md-nav__title,
.md-sidebar--secondary .md-nav__title[for="__toc"] {
  font-size: 0.52rem !important;
}

@media (max-width: 1130px) {
  .mineraze-wiki-nav-inner {
    width: min(1000px, calc(100vw - 24px)) !important;
    gap: 0.42rem !important;
  }

  .mineraze-wiki-nav-link {
    min-width: 108px !important;
    padding: 0 0.55rem !important;
    font-size: 0.64rem !important;
  }

  .mineraze-wiki-search-wrap {
    flex-basis: 230px !important;
    width: 230px !important;
    max-width: 230px !important;
  }
}

@media (max-width: 900px) {
  .mineraze-wiki-primary-nav {
    display: none !important;
  }

  .mineraze-wiki-mobile-menu {
    display: inline-flex !important;
  }

  .mineraze-wiki-search-wrap {
    flex: 1 1 auto !important;
    width: auto !important;
    max-width: none !important;
  }

  .mineraze-wiki-search-wrap .md-search__output {
    left: 0 !important;
    right: auto !important;
    width: min(620px, calc(100vw - 32px)) !important;
  }
}

/* ================================
   MineRaze Wiki UI fix v13
   - CraftingStore-style topbar pills
   - one-row category nav
   - working hover dropdowns
   - custom clickable search suggestions
   ================================ */

/* Top header: mirror the store styling more closely. */
.mineraze-wiki-topbar {
  background: rgba(255,255,255,0.11) !important;
  border-bottom: 1px solid rgba(255,255,255,0.08) !important;
  box-shadow: 0 3px 3px rgba(0,0,0,0.05) !important;
  backdrop-filter: none !important;
}

.mineraze-wiki-topbar-inner {
  width: min(960px, calc(100vw - 32px)) !important;
  min-height: 64px !important;
  align-items: center !important;
}

.mineraze-wiki-toplinks {
  gap: 0.62rem !important;
}

.mineraze-wiki-toplinks a {
  min-height: 32px !important;
  padding: 0 1rem !important;
  border-radius: 999px !important;
  background: rgba(255,255,255,0.12) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  box-shadow: 0 3px 3px rgba(0,0,0,0.04) !important;
  color: rgba(255,255,255,0.95) !important;
  font-size: 0.66rem !important;
  line-height: 1 !important;
}

.mineraze-wiki-toplinks a:hover,
.mineraze-wiki-toplinks a:focus {
  background: rgba(255,255,255,0.19) !important;
  color: #ffffff !important;
}

.mineraze-top-icon {
  width: auto !important;
  min-width: 0.7rem !important;
  opacity: 0.95 !important;
}

.mineraze-wiki-server-pill {
  position: relative !important;
  padding: 0.45rem 1.05rem 0.48rem 1.35rem !important;
  border-radius: 999px !important;
  background: rgba(255,255,255,0.12) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  box-shadow: 0 3px 3px rgba(0,0,0,0.04) !important;
  text-align: center !important;
}

.mineraze-wiki-server-pill::before {
  content: "";
  position: absolute;
  left: 0.82rem;
  top: 50%;
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 999px;
  background: #39c766;
  box-shadow: 0 0 0 4px rgba(57,199,102,0.13);
  transform: translateY(-50%);
}

.mineraze-wiki-server-pill span {
  font-size: 0.56rem !important;
  font-weight: 900 !important;
  letter-spacing: 0.075em !important;
}

.mineraze-wiki-server-pill strong {
  margin-top: 0.06rem !important;
  font-size: 0.96rem !important;
  font-weight: 900 !important;
}

/* Keep the main category bar compact and on one row. */
.mineraze-wiki-nav-inner {
  width: min(960px, calc(100vw - 32px)) !important;
  min-height: 58px !important;
  display: flex !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.55rem !important;
}

.mineraze-wiki-primary-nav {
  flex: 0 0 auto !important;
  display: flex !important;
  flex-wrap: nowrap !important;
  gap: 0.52rem !important;
}

.mineraze-wiki-nav-link {
  min-width: 0 !important;
  min-height: 34px !important;
  padding: 0 1.05rem !important;
  border-radius: 8px !important;
  font-size: 0.70rem !important;
  white-space: nowrap !important;
}

.mineraze-wiki-palette {
  flex: 0 0 auto !important;
  width: 34px !important;
  justify-content: center !important;
}

.mineraze-wiki-search-wrap {
  flex: 0 0 250px !important;
  width: 250px !important;
  max-width: 250px !important;
  margin-left: 0.2rem !important;
}

/* Dropdowns: bridge the gap so the menu stays selectable. */
.mineraze-wiki-nav-item {
  padding: 14px 0 !important;
  margin: -14px 0 !important;
}

.mineraze-wiki-dropdown {
  top: calc(100% - 2px) !important;
  min-width: 240px !important;
  padding: 0.55rem !important;
}

.mineraze-wiki-dropdown::after {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  top: -24px !important;
  height: 24px !important;
  background: transparent !important;
}

.mineraze-wiki-nav-item:hover > .mineraze-wiki-dropdown,
.mineraze-wiki-nav-item:focus-within > .mineraze-wiki-dropdown,
.mineraze-wiki-nav-item.is-hovered > .mineraze-wiki-dropdown {
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

.mineraze-wiki-dropdown-home {
  margin-bottom: 0.3rem !important;
  background: #eef8ff !important;
  color: #12385c !important;
  font-weight: 900 !important;
}

/* Hide Material's own result box and use a controlled suggestions panel instead. */
.mineraze-wiki-search-wrap .md-search__output {
  display: none !important;
}

.mineraze-custom-search-suggestions {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 1200;
  width: min(520px, calc(100vw - 32px));
  max-height: min(68vh, 620px);
  overflow: auto;
  padding: 0.45rem;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.12);
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.18);
}

.mineraze-custom-search-suggestions[hidden] {
  display: none !important;
}

.mineraze-search-suggestion {
  display: block;
  padding: 0.62rem 0.7rem;
  border-radius: 9px;
  color: #172033 !important;
  text-decoration: none !important;
}

.mineraze-search-suggestion:hover,
.mineraze-search-suggestion:focus {
  background: #eef8ff;
  color: #12385c !important;
}

.mineraze-search-suggestion strong {
  display: block;
  margin-bottom: 0.12rem;
  font-size: 0.76rem;
  font-weight: 900;
  line-height: 1.25;
}

.mineraze-search-suggestion span {
  display: block;
  color: #5f6f84;
  font-size: 0.64rem;
  line-height: 1.35;
  font-weight: 600;
}

.mineraze-search-empty {
  padding: 0.75rem;
  color: #6b7280;
  font-size: 0.68rem;
  font-weight: 700;
}

/* Slightly smaller footer text, as requested. */
.mineraze-footer-copy strong {
  font-size: 0.72rem !important;
}

.mineraze-footer-copy p {
  font-size: 0.56rem !important;
}

.mineraze-footer-bottom-inner {
  font-size: 0.54rem !important;
}

[data-md-color-scheme="slate"] .mineraze-custom-search-suggestions {
  background: #1f2937;
  border-color: rgba(255,255,255,0.10);
}

[data-md-color-scheme="slate"] .mineraze-search-suggestion {
  color: #e5edf7 !important;
}

[data-md-color-scheme="slate"] .mineraze-search-suggestion:hover,
[data-md-color-scheme="slate"] .mineraze-search-suggestion:focus {
  background: rgba(30,155,215,0.14);
}

[data-md-color-scheme="slate"] .mineraze-search-suggestion span {
  color: #b6c2d2;
}

@media (max-width: 980px) {
  .mineraze-wiki-nav-inner {
    width: min(100%, calc(100vw - 24px)) !important;
  }

  .mineraze-wiki-nav-link {
    padding: 0 0.72rem !important;
    font-size: 0.62rem !important;
  }

  .mineraze-wiki-search-wrap {
    flex-basis: 210px !important;
    width: 210px !important;
    max-width: 210px !important;
  }
}

@media (max-width: 780px) {
  .mineraze-wiki-topbar-inner {
    width: min(100%, calc(100vw - 24px)) !important;
  }

  .mineraze-wiki-toplinks a {
    padding: 0 0.75rem !important;
  }
}

/* =========================================================
   MineRaze Wiki UI Fix v14
   - remove dark mode toggle
   - restore CraftingStore-style topbar pills/icons
   - cleaner custom search suggestions
   ========================================================= */

.mineraze-wiki-palette,
.md-header__option,
.md-header__button[for="__palette"],
.md-option {
  display: none !important;
}

.mineraze-wiki-topbar-inner {
  width: min(960px, calc(100vw - 32px)) !important;
  min-height: 62px !important;
  align-items: center !important;
}

.mineraze-wiki-toplinks {
  display: flex !important;
  align-items: center !important;
  gap: 0.62rem !important;
}

.mineraze-wiki-toplinks a {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.38rem !important;
  min-height: 30px !important;
  padding: 0 1rem !important;
  border-radius: 999px !important;
  background: rgba(255,255,255,0.12) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  box-shadow: 0 3px 3px rgba(0,0,0,0.04) !important;
  color: rgba(255,255,255,0.96) !important;
  font-size: 0.66rem !important;
  font-weight: 900 !important;
  letter-spacing: 0.035em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
}

.mineraze-wiki-toplinks a:hover,
.mineraze-wiki-toplinks a:focus {
  background: rgba(255,255,255,0.20) !important;
  color: #ffffff !important;
}

.mineraze-top-icon {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 0.82rem !important;
  height: 0.82rem !important;
  min-width: 0.82rem !important;
  line-height: 1 !important;
  color: currentColor !important;
  opacity: 0.96 !important;
}

.mineraze-top-icon svg {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  fill: currentColor !important;
}

.mineraze-wiki-server-pill {
  position: relative !important;
  min-width: 185px !important;
  padding: 0.44rem 1.05rem 0.48rem 1.35rem !important;
  border-radius: 999px !important;
  background: rgba(255,255,255,0.12) !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  box-shadow: 0 3px 3px rgba(0,0,0,0.04) !important;
  text-align: center !important;
}

.mineraze-wiki-server-pill::before {
  content: "" !important;
  position: absolute !important;
  left: 0.82rem !important;
  top: 50% !important;
  width: 0.42rem !important;
  height: 0.42rem !important;
  border-radius: 999px !important;
  background: #39c766 !important;
  box-shadow: 0 0 0 4px rgba(57,199,102,0.13) !important;
  transform: translateY(-50%) !important;
}

.mineraze-wiki-server-pill span {
  display: block !important;
  font-size: 0.55rem !important;
  font-weight: 900 !important;
  letter-spacing: 0.075em !important;
  text-transform: uppercase !important;
  color: rgba(255,255,255,0.88) !important;
}

.mineraze-wiki-server-pill strong {
  display: block !important;
  margin-top: 0.04rem !important;
  font-size: 0.96rem !important;
  font-weight: 900 !important;
  letter-spacing: 0.02em !important;
  color: #ffffff !important;
}

.mineraze-wiki-nav-inner {
  gap: 0.62rem !important;
}

.mineraze-wiki-search-wrap {
  margin-left: 0.25rem !important;
}

/* Search suggestions: remove the bulky look and make text smaller/cleaner. */
.mineraze-custom-search-suggestions {
  top: calc(100% + 8px) !important;
  width: min(460px, calc(100vw - 32px)) !important;
  max-height: min(60vh, 520px) !important;
  padding: 0.34rem !important;
  border-radius: 10px !important;
  background: #ffffff !important;
  border: 1px solid rgba(15, 23, 42, 0.11) !important;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.16) !important;
}

.mineraze-search-suggestion {
  display: block !important;
  padding: 0.52rem 0.62rem !important;
  border-radius: 8px !important;
  color: #172033 !important;
  text-decoration: none !important;
}

.mineraze-search-suggestion:hover,
.mineraze-search-suggestion:focus {
  background: #eef8ff !important;
  color: #12385c !important;
}

.mineraze-search-suggestion strong {
  display: block !important;
  margin-bottom: 0.1rem !important;
  color: #172033 !important;
  font-size: 0.68rem !important;
  font-weight: 900 !important;
  line-height: 1.22 !important;
}

.mineraze-search-suggestion span {
  display: block !important;
  color: #5f6f84 !important;
  font-size: 0.58rem !important;
  line-height: 1.33 !important;
  font-weight: 600 !important;
}

.mineraze-search-empty {
  padding: 0.65rem !important;
  color: #6b7280 !important;
  font-size: 0.62rem !important;
  font-weight: 700 !important;
}

@media (max-width: 780px) {
  .mineraze-wiki-toplinks a {
    padding: 0 0.75rem !important;
  }

  .mineraze-wiki-server-pill {
    min-width: 155px !important;
  }
}

/* v15 footer: match CraftingStore footer more closely. */
.md-footer-meta,
.md-footer__inner:not(.mineraze-footer-main-inner):not(.mineraze-footer-bottom-inner) {
  display: none !important;
}

.mineraze-footer {
  margin-top: 3rem !important;
  background: #071320 !important;
  color: #ffffff !important;
  font-family: "Montserrat", var(--md-text-font-family), sans-serif !important;
}

.mineraze-footer-main {
  background: #0b1f33 !important;
  border-top: 1px solid rgba(255, 255, 255, 0.06) !important;
  padding: 1.55rem 0 !important;
}

.mineraze-footer-main-inner,
.mineraze-footer-bottom-inner {
  width: min(960px, calc(100vw - 32px)) !important;
  margin-left: auto !important;
  margin-right: auto !important;
  max-width: none !important;
}

.mineraze-footer-main-inner {
  display: grid !important;
  grid-template-columns: 42px minmax(0, 1fr) !important;
  gap: 0.85rem !important;
  align-items: center !important;
}

.mineraze-footer-shield,
.mineraze-footer-badge {
  width: 38px !important;
  height: 38px !important;
  border-radius: 10px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: rgba(30, 155, 215, 0.16) !important;
  border: 1px solid rgba(30, 155, 215, 0.30) !important;
  color: #38bdf8 !important;
  font-size: 0 !important;
  flex: 0 0 auto !important;
}

.mineraze-footer-shield svg {
  width: 20px !important;
  height: 20px !important;
  display: block !important;
}

.mineraze-footer-shield path {
  fill: none !important;
  stroke: currentColor !important;
  stroke-width: 1.8 !important;
  stroke-linejoin: round !important;
}

.mineraze-footer-text,
.mineraze-footer-copy {
  min-width: 0 !important;
}

.mineraze-footer-text strong,
.mineraze-footer-copy strong {
  display: block !important;
  margin: 0 0 0.25rem !important;
  color: #ffffff !important;
  font-size: 0.78rem !important;
  line-height: 1.15 !important;
  font-weight: 900 !important;
  letter-spacing: 0.01em !important;
}

.mineraze-footer-text p,
.mineraze-footer-copy p {
  margin: 0 !important;
  max-width: 760px !important;
  color: rgba(255, 255, 255, 0.84) !important;
  font-size: 0.58rem !important;
  line-height: 1.55 !important;
  font-weight: 800 !important;
}

.mineraze-footer-bottom {
  background: #071320 !important;
  padding: 0.86rem 0 !important;
}

.mineraze-footer-bottom-inner {
  position: relative !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) !important;
  align-items: center !important;
  gap: 1rem !important;
  min-height: 30px !important;
  color: rgba(255, 255, 255, 0.78) !important;
  font-size: 0.54rem !important;
  line-height: 1.45 !important;
  font-weight: 800 !important;
}

.mineraze-footer-copyright {
  grid-column: 1 !important;
  justify-self: start !important;
  text-align: left !important;
}

.mineraze-footer-secure,
.mineraze-footer-pill {
  grid-column: 2 !important;
  justify-self: center !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-height: 24px !important;
  padding: 0 0.9rem !important;
  border-radius: 999px !important;
  background: rgba(57, 199, 102, 0.13) !important;
  border: 1px solid rgba(57, 199, 102, 0.42) !important;
  color: #9cf3b7 !important;
  font-size: 0.52rem !important;
  line-height: 1 !important;
  font-weight: 900 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  white-space: nowrap !important;
}

.mineraze-footer-links {
  display: none !important;
}

@media (max-width: 760px) {
  .mineraze-footer-main-inner {
    grid-template-columns: 36px minmax(0, 1fr) !important;
    gap: 0.75rem !important;
  }

  .mineraze-footer-shield,
  .mineraze-footer-badge {
    width: 34px !important;
    height: 34px !important;
    border-radius: 9px !important;
  }

  .mineraze-footer-bottom-inner {
    grid-template-columns: 1fr !important;
    text-align: left !important;
  }

  .mineraze-footer-secure,
  .mineraze-footer-pill {
    grid-column: 1 !important;
    justify-self: start !important;
    margin-top: 0.35rem !important;
  }
}

/* v16: match CraftingStore header/footer more closely. */
body .mineraze-wiki-header {
  position: relative !important;
  z-index: 20 !important;
  background: transparent !important;
  box-shadow: none !important;
  font-family: "Montserrat", var(--md-text-font-family), sans-serif !important;
}

body .mineraze-wiki-hero {
  position: relative !important;
  min-height: 285px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow: hidden !important;
  background: linear-gradient(135deg, rgba(18, 56, 92, 0.78), rgba(30, 155, 215, 0.62)) !important;
}

body .mineraze-wiki-hero-bg {
  position: absolute !important;
  inset: 0 !important;
  z-index: 0 !important;
  background: url("https://i.pinimg.com/originals/89/21/9b/89219b60d170d1b5fbb4b4ab11bf4996.jpg") center top / cover no-repeat !important;
  filter: blur(1px) !important;
  opacity: 0.9 !important;
}

body .mineraze-wiki-hero-glow {
  position: absolute !important;
  inset: 0 !important;
  z-index: 1 !important;
  background:
    radial-gradient(circle at 50% 35%, rgba(255, 255, 255, 0.18), transparent 28%),
    linear-gradient(180deg, rgba(12, 42, 72, 0.18), rgba(12, 42, 72, 0.44)) !important;
  pointer-events: none !important;
}

body .mineraze-wiki-topbar {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 3 !important;
  padding: 16px 0 !important;
  background: rgba(10, 37, 64, 0.22) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: none !important;
  backdrop-filter: blur(6px) !important;
}

body .mineraze-wiki-topbar-inner {
  width: min(960px, calc(100vw - 32px)) !important;
  max-width: none !important;
  min-height: 38px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 18px !important;
  padding: 0 !important;
}

body .mineraze-wiki-toplinks {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

body .mineraze-wiki-toplinks a {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  min-height: 34px !important;
  padding: 0 12px !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.10) !important;
  border: 0 !important;
  color: rgba(255, 255, 255, 0.94) !important;
  font-size: 11px !important;
  font-weight: 900 !important;
  line-height: 1 !important;
  letter-spacing: 0.45px !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  transition: 0.15s ease !important;
}

body .mineraze-wiki-toplinks a:hover,
body .mineraze-wiki-toplinks a:focus {
  background: rgba(255, 255, 255, 0.20) !important;
  color: #ffffff !important;
  transform: translateY(-1px) !important;
}

body .mineraze-top-icon {
  width: 14px !important;
  height: 14px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 auto !important;
}

body .mineraze-top-icon svg {
  width: 14px !important;
  height: 14px !important;
  display: block !important;
}

body .mineraze-top-icon path {
  fill: currentColor !important;
}

body .mineraze-wiki-server-pill {
  appearance: none !important;
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  min-width: 0 !important;
  padding: 9px 13px !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.12) !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  box-shadow: none !important;
  color: #ffffff !important;
  cursor: pointer !important;
  transition: 0.15s ease !important;
  user-select: none !important;
}

body .mineraze-wiki-server-pill:hover,
body .mineraze-wiki-server-pill:focus {
  background: rgba(255, 255, 255, 0.20) !important;
  transform: translateY(-1px) !important;
}

body .mineraze-server-dot {
  width: 9px !important;
  height: 9px !important;
  border-radius: 999px !important;
  background: #39c766 !important;
  box-shadow: 0 0 0 4px rgba(57, 199, 102, 0.20) !important;
  flex: 0 0 auto !important;
}

body .mineraze-server-text {
  display: block !important;
  text-align: right !important;
  line-height: 1.1 !important;
}

body .mineraze-server-small {
  display: block !important;
  font-size: 9px !important;
  font-weight: 900 !important;
  letter-spacing: 0.7px !important;
  text-transform: uppercase !important;
  color: rgba(255, 255, 255, 0.74) !important;
}

body .mineraze-server-ip {
  display: block !important;
  margin-top: 3px !important;
  font-size: 15px !important;
  font-weight: 900 !important;
  letter-spacing: 0.3px !important;
  color: #ffffff !important;
}

body .mineraze-wiki-logo {
  position: relative !important;
  z-index: 2 !important;
  display: inline-flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  width: auto !important;
  max-width: none !important;
  margin: 54px 0 0 !important;
  line-height: 0 !important;
  text-decoration: none !important;
  filter: none !important;
}

body .mineraze-wiki-logo img,
body .md-typeset .mineraze-wiki-logo img {
  width: 245px !important;
  max-width: 270px !important;
  height: auto !important;
  max-height: 175px !important;
  margin: 0 !important;
  object-fit: contain !important;
  animation: minerazeLogoPulseV16 4s infinite ease-in-out !important;
  filter: drop-shadow(0 16px 22px rgba(0, 0, 0, 0.28)) !important;
}

@keyframes minerazeLogoPulseV16 {
  0% { transform: scale(1); }
  50% { transform: scale(1.045); }
  100% { transform: scale(1); }
}

body #ipvalue {
  opacity: 0 !important;
  cursor: context-menu !important;
  position: fixed !important;
  pointer-events: none !important;
}

/* Keep the second-level wiki category nav clean below the hero. */
body .mineraze-wiki-nav-wrap {
  background: #ffffff !important;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08) !important;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08) !important;
}

body .mineraze-wiki-nav-inner {
  width: min(960px, calc(100vw - 32px)) !important;
  max-width: none !important;
  min-height: 60px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.7rem !important;
  padding: 0 !important;
}

body .mineraze-wiki-primary-nav {
  flex: 0 1 auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-wrap: nowrap !important;
  gap: 0.5rem !important;
}

body .mineraze-wiki-nav-link {
  min-height: 34px !important;
  padding: 0 1.1rem !important;
  border-radius: 8px !important;
  white-space: nowrap !important;
}

body .mineraze-wiki-search-wrap {
  flex: 0 0 240px !important;
  width: 240px !important;
  margin-left: 0.55rem !important;
}

body .mineraze-wiki-search-wrap .md-search__form {
  height: 40px !important;
}

/* v16 footer: 1:1 closer to CraftingStore, no secure badge. */
body .mineraze-footer-secure,
body .mineraze-footer-pill,
body .mineraze-footer-badge,
body .mineraze-footer-links {
  display: none !important;
}

body .mineraze-footer {
  margin-top: 0 !important;
  background: #10283f !important;
  color: rgba(255, 255, 255, 0.78) !important;
  font-family: "Montserrat", var(--md-text-font-family), sans-serif !important;
}

body .mineraze-footer-main {
  padding: 34px 0 !important;
  background:
    radial-gradient(circle at 50% 0%, rgba(30, 155, 215, 0.22), transparent 34%),
    linear-gradient(135deg, #10283f 0%, #0b1d30 100%) !important;
  border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}

body .mineraze-footer-main-inner {
  width: min(900px, calc(100vw - 32px)) !important;
  max-width: 900px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: flex !important;
  align-items: flex-start !important;
  gap: 16px !important;
  padding: 0 !important;
}

body .mineraze-footer-shield {
  width: 58px !important;
  height: 58px !important;
  flex: 0 0 58px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  color: inherit !important;
  overflow: visible !important;
}

body .mineraze-footer-shield img,
body .md-typeset .mineraze-footer-shield img {
  display: block !important;
  width: 58px !important;
  height: 58px !important;
  max-width: 58px !important;
  margin: 0 !important;
  object-fit: contain !important;
}

body .mineraze-footer-text {
  min-width: 0 !important;
  max-width: 780px !important;
}

body .mineraze-footer-text strong {
  display: block !important;
  margin: 0 0 7px !important;
  color: #ffffff !important;
  font-size: 18px !important;
  font-weight: 900 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
}

body .mineraze-footer-text p {
  margin: 0 !important;
  max-width: 780px !important;
  font-size: 13px !important;
  line-height: 1.75 !important;
  color: rgba(255, 255, 255, 0.76) !important;
  font-weight: 600 !important;
}

body .mineraze-footer-bottom {
  padding: 18px 0 !important;
  background: #0a1725 !important;
  border-top: 1px solid rgba(255, 255, 255, 0.07) !important;
}

body .mineraze-footer-bottom-inner {
  width: min(900px, calc(100vw - 32px)) !important;
  max-width: 900px !important;
  min-height: 0 !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: block !important;
  padding: 0 !important;
}

body .mineraze-footer-copyright {
  color: rgba(255, 255, 255, 0.58) !important;
  font-size: 12px !important;
  line-height: 1.6 !important;
  font-weight: 700 !important;
  text-align: left !important;
}

@media (max-width: 768px) {
  body .mineraze-wiki-hero {
    min-height: 255px !important;
  }

  body .mineraze-wiki-topbar-inner {
    flex-direction: column !important;
    align-items: center !important;
    gap: 12px !important;
  }

  body .mineraze-wiki-toplinks {
    flex-wrap: wrap !important;
    justify-content: center !important;
  }

  body .mineraze-server-text {
    text-align: center !important;
  }

  body .mineraze-wiki-logo img,
  body .md-typeset .mineraze-wiki-logo img {
    max-width: 220px !important;
  }

  body .mineraze-wiki-nav-inner {
    flex-wrap: wrap !important;
    padding: 0.7rem 0 !important;
  }

  body .mineraze-wiki-primary-nav {
    flex-wrap: wrap !important;
  }

  body .mineraze-wiki-search-wrap {
    flex-basis: min(280px, calc(100vw - 32px)) !important;
    width: min(280px, calc(100vw - 32px)) !important;
  }

  body .mineraze-footer-main-inner {
    width: min(900px, calc(100vw - 32px)) !important;
    align-items: flex-start !important;
  }
}

@media (max-width: 480px) {
  body .mineraze-wiki-toplinks a {
    padding: 0 10px !important;
    font-size: 10px !important;
  }

  body .mineraze-wiki-logo img,
  body .md-typeset .mineraze-wiki-logo img {
    max-width: 190px !important;
  }

  body .mineraze-footer-main-inner {
    flex-direction: column !important;
  }
}

/* =========================================================
   MineRaze Wiki UI Fix v17
   - CraftingStore-style header pasted from store structure
   - CraftingStore-style footer without secure badge
   ========================================================= */

body .mineraze-wiki-header {
  position: relative !important;
  z-index: 20 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body .mineraze-header {
  position: relative !important;
  min-height: 285px !important;
  overflow: hidden !important;
  background: linear-gradient(135deg, rgba(18, 56, 92, 0.78), rgba(30, 155, 215, 0.62)) !important;
}

body .mineraze-header .headerbg {
  position: absolute !important;
  inset: 0 !important;
  z-index: 0 !important;
  background-image: url("https://i.pinimg.com/originals/89/21/9b/89219b60d170d1b5fbb4b4ab11bf4996.jpg") !important;
  background-repeat: no-repeat !important;
  background-size: cover !important;
  background-position: center top !important;
  filter: blur(1px) !important;
  opacity: 0.9 !important;
}

body .mineraze-header::before {
  content: "" !important;
  position: absolute !important;
  inset: 0 !important;
  z-index: 1 !important;
  background:
    radial-gradient(circle at 50% 35%, rgba(255, 255, 255, 0.18), transparent 28%),
    linear-gradient(180deg, rgba(12, 42, 72, 0.18), rgba(12, 42, 72, 0.44)) !important;
  pointer-events: none !important;
}

body .mineraze-header #particles-header {
  position: absolute !important;
  inset: 0 !important;
  z-index: 2 !important;
  pointer-events: none !important;
}

body .mineraze-header-inner {
  position: relative !important;
  z-index: 3 !important;
  min-height: 285px !important;
  display: flex !important;
  flex-direction: column !important;
}

body .mineraze-header-top {
  padding: 16px 0 !important;
  background: rgba(10, 37, 64, 0.22) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  backdrop-filter: blur(6px) !important;
}

body .mineraze-header-top-container {
  width: min(960px, calc(100vw - 32px)) !important;
  max-width: 960px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: 0 !important;
}

body .mineraze-header-top-row {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 18px !important;
}

body .mineraze-header-links {
  display: flex !important;
  align-items: center !important;
  gap: 10px !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

body .mineraze-header-links li {
  margin: 0 !important;
  padding: 0 !important;
}

body .mineraze-header-links a {
  display: inline-flex !important;
  align-items: center !important;
  gap: 7px !important;
  min-height: 34px !important;
  padding: 0 12px !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.10) !important;
  color: rgba(255, 255, 255, 0.94) !important;
  font-size: 11px !important;
  font-weight: 900 !important;
  letter-spacing: 0.45px !important;
  text-transform: uppercase !important;
  text-decoration: none !important;
  transition: 0.15s ease !important;
}

body .mineraze-header-links a:hover,
body .mineraze-header-links a:focus {
  background: rgba(255, 255, 255, 0.20) !important;
  color: #ffffff !important;
  transform: translateY(-1px) !important;
}

body .mineraze-header-links svg {
  display: block !important;
  width: 14px !important;
  height: 14px !important;
  fill: currentColor !important;
  flex: 0 0 auto !important;
}

body .mineraze-server-pill {
  appearance: none !important;
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  padding: 9px 13px !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.12) !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  color: #ffffff !important;
  cursor: pointer !important;
  transition: 0.15s ease !important;
  user-select: none !important;
  min-width: 0 !important;
  box-shadow: none !important;
}

body .mineraze-server-pill:hover,
body .mineraze-server-pill:focus {
  background: rgba(255, 255, 255, 0.20) !important;
  transform: translateY(-1px) !important;
}

body .mineraze-server-dot {
  width: 9px !important;
  height: 9px !important;
  border-radius: 999px !important;
  background: #39c766 !important;
  box-shadow: 0 0 0 4px rgba(57, 199, 102, 0.20) !important;
  flex: 0 0 auto !important;
}

body .mineraze-server-text {
  text-align: right !important;
  line-height: 1.1 !important;
  display: block !important;
}

body .mineraze-server-small {
  display: block !important;
  font-size: 9px !important;
  font-weight: 900 !important;
  letter-spacing: 0.7px !important;
  text-transform: uppercase !important;
  color: rgba(255, 255, 255, 0.74) !important;
}

body .mineraze-server-ip {
  display: block !important;
  margin-top: 3px !important;
  font-size: 15px !important;
  font-weight: 900 !important;
  letter-spacing: 0.3px !important;
  color: #ffffff !important;
}

body .mineraze-logo-stage {
  flex: 1 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 26px 0 38px !important;
  text-align: center !important;
}

body .mineraze-logo-card {
  display: inline-flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-decoration: none !important;
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  line-height: 0 !important;
  filter: none !important;
}

body .mineraze-logo-card img,
body .md-typeset .mineraze-logo-card img {
  display: block !important;
  width: 245px !important;
  max-width: 270px !important;
  height: auto !important;
  max-height: 175px !important;
  margin: 0 !important;
  object-fit: contain !important;
  animation: minerazeLogoPulseV17 4s infinite ease-in-out !important;
  filter: drop-shadow(0 16px 22px rgba(0, 0, 0, 0.28)) !important;
}

@keyframes minerazeLogoPulseV17 {
  0% { transform: scale(1); }
  50% { transform: scale(1.045); }
  100% { transform: scale(1); }
}

body #ipvalue {
  opacity: 0 !important;
  cursor: context-menu !important;
  position: fixed !important;
  pointer-events: none !important;
}

/* Keep wiki category nav below the CraftingStore-style hero. */
body .mineraze-wiki-nav-wrap {
  position: relative !important;
  z-index: 30 !important;
  background: #ffffff !important;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08) !important;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08) !important;
}

body .mineraze-wiki-nav-inner {
  width: min(960px, calc(100vw - 32px)) !important;
  max-width: 960px !important;
  min-height: 60px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.7rem !important;
  padding: 0 !important;
}

body .mineraze-wiki-primary-nav {
  flex: 0 1 auto !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-wrap: nowrap !important;
  gap: 0.5rem !important;
}

body .mineraze-wiki-search-wrap {
  flex: 0 0 240px !important;
  width: 240px !important;
  margin-left: 0.55rem !important;
}

/* Footer: CraftingStore-style, no secure digital store badge. */
body .md-footer__inner:not(.mineraze-footer-main-inner):not(.mineraze-footer-bottom-inner),
body .md-footer-meta,
body .mineraze-footer-secure,
body .mineraze-footer-pill,
body .mineraze-footer-badge,
body .mineraze-footer-links {
  display: none !important;
}

body .mineraze-footer {
  margin-top: 0 !important;
  background: #10283f !important;
  color: rgba(255, 255, 255, 0.78) !important;
  font-family: "Montserrat", var(--md-text-font-family), sans-serif !important;
}

body .mineraze-footer-main {
  padding: 34px 0 !important;
  background:
    radial-gradient(circle at 50% 0%, rgba(30, 155, 215, 0.22), transparent 34%),
    linear-gradient(135deg, #10283f 0%, #0b1d30 100%) !important;
  border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}

body .mineraze-footer-main-inner {
  width: min(900px, calc(100vw - 32px)) !important;
  max-width: 900px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: flex !important;
  align-items: flex-start !important;
  gap: 16px !important;
  padding: 0 !important;
}

body .mineraze-footer-logo {
  width: 58px !important;
  height: 58px !important;
  flex: 0 0 58px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 0 !important;
  overflow: visible !important;
}

body .mineraze-footer-logo img,
body .md-typeset .mineraze-footer-logo img {
  display: block !important;
  width: 58px !important;
  height: 58px !important;
  max-width: 58px !important;
  margin: 0 !important;
  object-fit: contain !important;
}

body .mineraze-footer-text {
  min-width: 0 !important;
  max-width: 780px !important;
}

body .mineraze-footer-text h3 {
  display: block !important;
  margin: 0 0 7px !important;
  color: #ffffff !important;
  font-size: 18px !important;
  font-weight: 900 !important;
  line-height: 1.2 !important;
  letter-spacing: 0 !important;
}

body .mineraze-footer-text p {
  margin: 0 !important;
  max-width: 780px !important;
  font-size: 13px !important;
  line-height: 1.75 !important;
  color: rgba(255, 255, 255, 0.76) !important;
  font-weight: 600 !important;
}

body .mineraze-footer-bottom {
  padding: 18px 0 !important;
  background: #0a1725 !important;
  border-top: 1px solid rgba(255, 255, 255, 0.07) !important;
}

body .mineraze-footer-bottom-inner {
  width: min(900px, calc(100vw - 32px)) !important;
  max-width: 900px !important;
  min-height: 0 !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: block !important;
  padding: 0 !important;
}

body .mineraze-footer-copyright {
  color: rgba(255, 255, 255, 0.58) !important;
  font-size: 12px !important;
  line-height: 1.6 !important;
  font-weight: 700 !important;
  text-align: left !important;
}

body .mineraze-footer-copyright strong {
  color: rgba(255, 255, 255, 0.86) !important;
  font-weight: 900 !important;
}

@media (max-width: 768px) {
  body .mineraze-header,
  body .mineraze-header-inner {
    min-height: 255px !important;
  }

  body .mineraze-header-top-row {
    flex-direction: column !important;
    align-items: center !important;
    gap: 12px !important;
  }

  body .mineraze-header-links {
    flex-wrap: wrap !important;
    justify-content: center !important;
  }

  body .mineraze-server-text {
    text-align: center !important;
  }

  body .mineraze-logo-stage {
    padding: 20px 0 30px !important;
  }

  body .mineraze-logo-card img,
  body .md-typeset .mineraze-logo-card img {
    max-width: 220px !important;
  }

  body .mineraze-wiki-nav-inner {
    flex-wrap: wrap !important;
    padding: 0.7rem 0 !important;
  }

  body .mineraze-wiki-primary-nav {
    flex-wrap: wrap !important;
  }

  body .mineraze-wiki-search-wrap {
    flex-basis: min(280px, calc(100vw - 32px)) !important;
    width: min(280px, calc(100vw - 32px)) !important;
  }

  body .mineraze-footer-main-inner {
    flex-direction: column !important;
  }
}

@media (max-width: 480px) {
  body .mineraze-header-links a {
    padding: 0 10px !important;
    font-size: 10px !important;
  }

  body .mineraze-logo-card img,
  body .md-typeset .mineraze-logo-card img {
    max-width: 190px !important;
  }
}

/* --------------------------------------------------------------------------
   MineRaze Wiki UI Fix v19
   Fixes the wiki search bar position after flattened URLs.
   Category dropdown buttons are centered like the CraftingStore category bar;
   the search bar sits independently on the right so it no longer pulls the
   buttons off-center.
---------------------------------------------------------------------------- */
body .mineraze-wiki-nav-wrap {
  background: #ffffff !important;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08) !important;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08) !important;
}

body .mineraze-wiki-nav-inner {
  position: relative !important;
  width: min(1150px, calc(100vw - 32px)) !important;
  max-width: 1150px !important;
  min-height: 64px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0 !important;
}

body .mineraze-wiki-primary-nav {
  position: relative !important;
  z-index: 2 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-wrap: nowrap !important;
  gap: 0.55rem !important;
  margin: 0 auto !important;
  padding: 0 !important;
  max-width: calc(100% - 320px) !important;
}

body .mineraze-wiki-search-wrap {
  position: absolute !important;
  z-index: 4 !important;
  right: 0 !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  flex: 0 0 260px !important;
  width: 260px !important;
  margin: 0 !important;
}

body .mineraze-wiki-search-wrap .md-search,
body .mineraze-wiki-search-wrap .md-search__form {
  width: 100% !important;
}

body .mineraze-wiki-search-wrap .md-search__form {
  height: 42px !important;
}

/* Keep dropdowns above the search overlay if they open near it. */
body .mineraze-wiki-dropdown {
  z-index: 50 !important;
}

@media (max-width: 1100px) {
  body .mineraze-wiki-nav-inner {
    width: min(960px, calc(100vw - 32px)) !important;
    min-height: 64px !important;
    flex-wrap: wrap !important;
    gap: 0.7rem !important;
    padding: 0.7rem 0 !important;
  }

  body .mineraze-wiki-primary-nav {
    max-width: 100% !important;
    flex-wrap: wrap !important;
    margin: 0 !important;
  }

  body .mineraze-wiki-search-wrap {
    position: static !important;
    transform: none !important;
    flex: 0 0 min(300px, calc(100vw - 32px)) !important;
    width: min(300px, calc(100vw - 32px)) !important;
    margin: 0 !important;
  }
}

/*
   v20 fix: keep category buttons centered while moving search into its own
   right-side grid column. This prevents the search field from overlapping
   the Activities button.
*/
.mineraze-wiki-nav-inner {
  width: min(1180px, calc(100vw - 32px)) !important;
  max-width: 1180px !important;
  display: grid !important;
  grid-template-columns: minmax(250px, 1fr) auto minmax(290px, 1fr) !important;
  align-items: center !important;
  justify-content: normal !important;
  column-gap: 0 !important;
  row-gap: 0 !important;
  min-height: 58px !important;
}

.mineraze-wiki-primary-nav {
  grid-column: 2 !important;
  justify-self: center !important;
  flex: none !important;
  display: flex !important;
  flex-wrap: nowrap !important;
  gap: 0.52rem !important;
  max-width: none !important;
}

.mineraze-wiki-search-wrap {
  grid-column: 3 !important;
  justify-self: start !important;
  align-self: center !important;
  flex: none !important;
  width: 250px !important;
  max-width: 250px !important;
  min-width: 250px !important;
  margin-left: 1.15rem !important;
  position: relative !important;
  z-index: 20 !important;
}

.mineraze-wiki-search-wrap .md-search,
.mineraze-wiki-search-wrap .md-search__form {
  width: 250px !important;
  max-width: 250px !important;
}

.mineraze-wiki-palette,
.md-header__option {
  display: none !important;
}

@media (max-width: 1150px) {
  .mineraze-wiki-nav-inner {
    grid-template-columns: 1fr !important;
    justify-items: center !important;
    padding: 0.65rem 1rem !important;
    row-gap: 0.55rem !important;
  }

  .mineraze-wiki-primary-nav,
  .mineraze-wiki-search-wrap {
    grid-column: 1 !important;
    justify-self: center !important;
    margin-left: 0 !important;
  }
}

/* --------------------------------------------------------------------------
   MineRaze Wiki UI Fix v21
   Definitive nav/search spacing fix. Use body-qualified selectors to override
   earlier body .mineraze-wiki-* rules, and put search into a real dedicated
   grid column with a hard gap after Activities.
---------------------------------------------------------------------------- */
body .mineraze-wiki-nav-wrap {
  overflow: visible !important;
}

body .mineraze-wiki-nav-inner {
  width: min(1280px, calc(100vw - 32px)) !important;
  max-width: 1280px !important;
  min-height: 58px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: 0 !important;
  display: grid !important;
  grid-template-columns: minmax(180px, 1fr) auto 300px !important;
  align-items: center !important;
  justify-content: stretch !important;
  column-gap: 34px !important;
  row-gap: 0 !important;
}

body .mineraze-wiki-primary-nav {
  grid-column: 2 !important;
  justify-self: center !important;
  align-self: center !important;
  position: relative !important;
  z-index: 30 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: none !important;
  flex-wrap: nowrap !important;
  gap: 0.55rem !important;
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

body .mineraze-wiki-search-wrap {
  grid-column: 3 !important;
  justify-self: start !important;
  align-self: center !important;
  position: relative !important;
  top: auto !important;
  right: auto !important;
  left: auto !important;
  transform: none !important;
  z-index: 25 !important;
  display: block !important;
  flex: none !important;
  width: 260px !important;
  min-width: 260px !important;
  max-width: 260px !important;
  margin: 0 !important;
  padding: 0 !important;
}

body .mineraze-wiki-search-wrap .md-search,
body .mineraze-wiki-search-wrap .md-search__form {
  width: 260px !important;
  min-width: 260px !important;
  max-width: 260px !important;
}

body .mineraze-wiki-search-wrap .md-search__form {
  height: 42px !important;
}

body .mineraze-wiki-dropdown,
body .mineraze-custom-search-suggestions,
body .mineraze-wiki-search-wrap .md-search__output {
  z-index: 999 !important;
}

@media (max-width: 1240px) {
  body .mineraze-wiki-nav-inner {
    width: min(980px, calc(100vw - 32px)) !important;
    grid-template-columns: 1fr !important;
    justify-items: center !important;
    min-height: auto !important;
    padding: 0.7rem 1rem !important;
    row-gap: 0.65rem !important;
    column-gap: 0 !important;
  }

  body .mineraze-wiki-primary-nav,
  body .mineraze-wiki-search-wrap {
    grid-column: 1 !important;
    justify-self: center !important;
  }

  body .mineraze-wiki-primary-nav {
    flex-wrap: wrap !important;
  }

  body .mineraze-wiki-search-wrap,
  body .mineraze-wiki-search-wrap .md-search,
  body .mineraze-wiki-search-wrap .md-search__form {
    width: min(320px, calc(100vw - 48px)) !important;
    min-width: 0 !important;
    max-width: min(320px, calc(100vw - 48px)) !important;
  }
}

/* =========================================================
   v22 navbar layout fix
   Prevent the search field from overlapping the Activities
   dropdown by putting category buttons and search in fixed
   grid columns instead of one crowded flex row.
   ========================================================= */
@media (min-width: 1181px) {
  .mineraze-wiki-nav-wrap {
    overflow: visible !important;
  }

  .mineraze-wiki-nav-inner {
    width: min(1220px, calc(100vw - 56px)) !important;
    min-height: 58px !important;
    display: grid !important;
    grid-template-columns: minmax(180px, 1fr) max-content 280px !important;
    align-items: center !important;
    justify-content: center !important;
    column-gap: 1.65rem !important;
    row-gap: 0 !important;
  }

  .mineraze-wiki-primary-nav {
    grid-column: 2 !important;
    justify-self: center !important;
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.55rem !important;
    min-width: max-content !important;
  }

  .mineraze-wiki-search-wrap {
    grid-column: 3 !important;
    justify-self: start !important;
    align-self: center !important;
    flex: none !important;
    width: 260px !important;
    max-width: 260px !important;
    min-width: 260px !important;
    margin: 0 !important;
    position: relative !important;
    z-index: 20 !important;
  }

  .mineraze-wiki-search-wrap .md-search,
  .mineraze-wiki-search-wrap .md-search__form {
    width: 100% !important;
    max-width: 100% !important;
  }

  .mineraze-wiki-nav-link {
    min-width: 0 !important;
    padding-left: 1.08rem !important;
    padding-right: 1.08rem !important;
  }
}

@media (max-width: 1180px) {
  .mineraze-wiki-nav-inner {
    width: min(960px, calc(100vw - 32px)) !important;
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 0.65rem !important;
    padding-top: 0.75rem !important;
    padding-bottom: 0.75rem !important;
  }

  .mineraze-wiki-primary-nav {
    width: 100% !important;
    justify-content: center !important;
    flex-wrap: wrap !important;
  }

  .mineraze-wiki-search-wrap {
    flex: 0 1 320px !important;
    width: min(320px, calc(100vw - 48px)) !important;
    max-width: min(320px, calc(100vw - 48px)) !important;
    min-width: 0 !important;
    margin: 0 !important;
  }
}


/* =========================================================
   MineRaze Wiki UI Fix v23
   - final header/footer text fix
   - copy IP state
   - custom search suggestions styling
   ========================================================= */
body .mineraze-footer-text h3,
body .mineraze-footer-text strong {
  display: block !important;
  margin: 0 0 7px !important;
  color: #ffffff !important;
  font-size: 18px !important;
  font-weight: 900 !important;
  line-height: 1.2 !important;
}

body .mineraze-footer-text h3::after,
body .mineraze-footer-text strong::after {
  content: none !important;
}

body .mineraze-server-pill.is-copied .mineraze-server-small::after,
body .mineraze-wiki-server-pill.is-copied span:first-child::after {
  content: "  · copied";
  color: #9cf3b7;
}

body .mineraze-custom-search-suggestions {
  position: absolute !important;
  top: calc(100% + 8px) !important;
  right: 0 !important;
  z-index: 5000 !important;
  width: min(460px, calc(100vw - 32px)) !important;
  max-height: min(60vh, 520px) !important;
  overflow-y: auto !important;
  padding: 0.34rem !important;
  border-radius: 10px !important;
  background: #ffffff !important;
  border: 1px solid rgba(15, 23, 42, 0.11) !important;
  box-shadow: 0 16px 36px rgba(15, 23, 42, 0.16) !important;
}

body .mineraze-custom-search-suggestions[hidden] {
  display: none !important;
}

body .mineraze-search-suggestion {
  display: block !important;
  padding: 0.50rem 0.60rem !important;
  border-radius: 8px !important;
  color: #172033 !important;
  text-decoration: none !important;
}

body .mineraze-search-suggestion:hover,
body .mineraze-search-suggestion:focus {
  background: #eef8ff !important;
  color: #12385c !important;
}

body .mineraze-search-suggestion strong {
  display: block !important;
  margin-bottom: 0.10rem !important;
  color: #172033 !important;
  font-size: 0.68rem !important;
  font-weight: 900 !important;
  line-height: 1.22 !important;
}

body .mineraze-search-suggestion span {
  display: block !important;
  color: #5f6f84 !important;
  font-size: 0.58rem !important;
  line-height: 1.33 !important;
  font-weight: 600 !important;
}

body .mineraze-search-empty {
  padding: 0.65rem !important;
  color: #6b7280 !important;
  font-size: 0.62rem !important;
  font-weight: 700 !important;
}

/* Native Material output stays hidden because custom suggestions handle search previews. */
body .mineraze-wiki-search-wrap .md-search__output {
  display: none !important;
}
