:root {
  --bg: #1f232b;
  --page: #2b303a;
  --panel: #303540;
  --panel-2: #252a33;
  --panel-3: #3b414b;
  --rail: #191d23;
  --rail-box: #20242b;
  --line: #11151b;
  --line-soft: #4d535d;
  --text: #eef2f7;
  --muted: #c0c7d2;
  --link: #7db7ff;
  --green: #137f3c;
  --green-2: #0f6832;
  --gold: #8b7133;
  --blue: #3178c6;
  --danger: #b94040;
  --input-bg: #4a4f57;
  --post-text: #eef2f7;
  --color-base: #eef2f7;
  --button-color: #48494a;
  --button-color-progressive: #137342;
  --button-text-color: #fff;
  --button-text-shadow-color: #00000020;
  --button-border-color: #242424;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font: 14px/1.5 "Segoe UI", Arial, sans-serif;
  background:
    linear-gradient(180deg, rgba(8,18,30,.85) 0 44px, transparent 44px),
    repeating-linear-gradient(90deg, transparent 0 28px, rgba(255,255,255,.025) 28px 30px),
    linear-gradient(180deg, #0c1b25 0 58px, #0f4729 58px 72px, #5a3824 72px 96px, var(--bg) 96px);
}

a { color: var(--link); text-decoration: none; }
a:hover { color: #b9d8ff; text-decoration: underline; }
img { display: block; max-width: 100%; }
.wrap { width: min(1320px, calc(100% - 32px)); margin: 0 auto; }

.mp-wrapper *, .mp-wrapper ::before, .mp-wrapper ::after {
  box-sizing: border-box;
}

.mp-wrapper {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  gap: 6px;
}

.mp-wrapper > .mp-section,
.mp-section.mp-section-full {
  width: 100%;
}

.mp-left, .mp-right {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.mp-inline-sections {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-areas: "site" "left" "right";
  gap: 6px;
  width: 100%;
}

#mp-section-site { grid-area: site; }
.mp-left { grid-area: left; }
.mp-right { grid-area: right; }

.mp-sticky {
  position: sticky;
  top: 20px;
}

.mp-section-center {
  text-align: center;
}

.wiki-rail {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  z-index: 30;
  width: 172px;
  padding: 10px 12px;
  overflow: auto;
  background:
    linear-gradient(180deg, rgba(18,48,38,.7), transparent 78px),
    var(--rail);
  border-right: 4px solid #0d1015;
  box-shadow: inset -1px 0 0 #3e4650;
}

.wiki-logo {
  display: grid;
  place-items: center;
  gap: 5px;
  margin: 0 0 14px;
  color: #fff;
  text-align: center;
  font-weight: 900;
  text-transform: uppercase;
  text-shadow: 2px 2px 0 #000;
}
.wiki-logo img {
  width: 86px;
  height: 86px;
  object-fit: contain;
  image-rendering: pixelated;
  filter: drop-shadow(0 4px 0 rgba(0,0,0,.45));
}

.wiki-box {
  margin-bottom: 10px;
  border: 2px solid #0c0f13;
  background: var(--rail-box);
  box-shadow: inset 1px 1px 0 #4c535c, inset -1px -1px 0 #111;
}
.wiki-box h3 {
  margin: 0;
  padding: 7px 9px;
  border-bottom: 2px solid #0c0f13;
  background: #4a4f56;
  color: #fff;
  font-size: 13px;
  font-weight: 800;
}
.wiki-box a {
  display: block;
  padding: 4px 9px;
  color: #dbe7f6;
  font-size: 13px;
}
.wiki-box a:hover { background: #2d3540; color: #fff; text-decoration: none; }

.topbar, .hero, .wiki-tabs, .page, .site-footer {
  margin-left: 172px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 48px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.05), rgba(0,0,0,.08)),
    #232832;
  border-bottom: 3px solid #12161d;
  box-shadow: inset 0 -1px 0 #4e5663;
}
.nav-wrap { min-height: 48px; display: flex; align-items: stretch; gap: 12px; }

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-weight: 900;
  min-width: max-content;
}
.brand-mark { display: none; }

.main-nav {
  display: flex;
  align-items: stretch;
  gap: 0;
  flex: 1;
}
.main-nav a {
  display: flex;
  align-items: center;
  padding: 0 18px;
  border-left: 1px solid #151a22;
  border-right: 1px solid #333a45;
  color: #fff;
  font-weight: 800;
}
.main-nav a.active {
  background: var(--button-color-progressive);
  box-shadow: inset 0 -3px 0 #7ee18e;
}

.nav-actions { display: flex; align-items: center; gap: 6px; padding: 6px 0; }
.circle, .nav-login, .user-pill, .btn, .search-box button, .mp-button {
  position: relative;
  border: 2px solid #15181d;
  background: var(--button-color);
  color: #fff;
  font-weight: 800;
  box-shadow: none;
  cursor: pointer;
  user-select: none;
  transition: background-color .1s, color .1s, border-color .1s, box-shadow .1s, opacity .1s, padding .1s, margin .1s;
}

.circle::after, .nav-login::after, .user-pill::after, .btn::after, .search-box button::after, .wiki-tabs a::after, .mp-button::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  box-shadow:
    0 -6px 0 0 rgb(104, 104, 104) inset,
    2px 2px 0 0 rgba(178, 178, 178, .5) inset,
    -2px -8px 0 0 rgba(153, 153, 153, .5) inset;
  mix-blend-mode: hard-light;
  pointer-events: none;
  transition: .1s background-color, box-shadow;
}

.circle:hover::after, .nav-login:hover::after, .user-pill:hover::after, .btn:hover::after, .search-box button:hover::after, .wiki-tabs a:hover::after, .mp-button:hover::after {
  background-color: rgba(255,255,255,.1);
}

.circle:active::after, .nav-login:active::after, .user-pill:active::after, .btn:active::after, .search-box button:active::after, .wiki-tabs a:active::after, .wiki-tabs a.active::after, .mp-button:active::after {
  box-shadow:
    2px 2px 0 0 rgba(178, 178, 178, .5) inset,
    -2px -2px 0 0 rgba(153, 153, 153, .5) inset;
  background-color: rgba(0,0,0,.1);
}
.circle {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
}
.nav-login { display: inline-flex; align-items: center; min-height: 34px; padding: 0 12px; }
.user-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 4px 10px 4px 4px;
}
.user-pill img {
  width: 24px;
  height: 24px;
  border: 1px solid #111;
  background: #1b1f25;
}

.hero {
  padding: 16px 0 8px;
  background: transparent;
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(220px, .75fr);
  gap: 10px;
  align-items: stretch;
}
.hero-title {
  grid-column: 1 / -1;
  padding: 12px;
  border: 2px solid #15181d;
  background:
    linear-gradient(180deg, #279292 4px, transparent 4px),
    url(https://minecraft.wiki/images/Dark-GrassBackground-nether.png?f7521) 0 4px repeat-x,
    #000;
  background-origin: border-box;
  box-shadow: inset 1px 1px 0 #535b66;
  min-height: 58px;
  text-align: center;
}
.hero-title h1 {
  margin: 0;
  color: #fff;
  font-size: 24px;
  line-height: 1.1;
  text-shadow: 2px 2px 0 rgba(0,0,0,.45);
}
.hero-title p { margin: 4px 0 0; color: #fff; text-shadow: 2px 2px 0 rgba(0,0,0,.45); }
.hero-side {
  padding: 12px 14px;
  border: 2px solid #15181d;
  background: var(--panel);
  box-shadow: inset 1px 1px 0 #535b66;
  display: flex;
  align-items: center;
  gap: 12px;
}
.hero-side strong { color: #fff; font-size: 16px; }
.hero-side span { color: var(--muted); }
.hero-side.right { justify-content: flex-end; text-align: right; }
.play-icon {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  background:
    linear-gradient(45deg, transparent 0 45%, #ff9f2d 45% 72%, transparent 72%),
    #188d42;
  border: 2px solid #0b351d;
}
.discord-dot { color: #7db7ff; font-weight: 900; }

.wiki-tabs {
  display: grid;
  grid-template-columns: repeat(5, minmax(120px, 1fr));
  gap: 4px;
  padding-bottom: 10px;
}
.wiki-tabs a {
  position: relative;
  padding: 8px 12px;
  border: 2px solid #15181d;
  background: var(--button-color);
  color: #fff;
  text-align: center;
  font-weight: 900;
  text-shadow: 2px 2px 0 var(--button-text-shadow-color);
}
.wiki-tabs a.active {
  background: var(--button-color-progressive);
  color: #fff;
}

.mp-button {
  width: 100%;
  gap: 6px;
  text-align: center;
  background-color: var(--button-color);
  color: var(--button-text-color, #fff);
  border-color: var(--button-border-color);
  font-size: 1em;
  font-weight: 800;
}

.mp-button.mp-button-progressive,
.mp-portal-wrapper .mp-button.mp-portal-active,
.mp-portal-wrapper .mp-button.mp-portal:hover,
.mp-portal-wrapper .mp-button.mp-portal:active {
  background-color: var(--button-color-progressive);
  --button-text-color: #fff;
}

.mp-button.mp-button-mcwiki-header {
  cursor: default;
  background:
    linear-gradient(180deg, #279292 4px, transparent 4px),
    url(https://minecraft.wiki/images/Dark-GrassBackground-nether.png?f7521) 0 4px repeat-x,
    #000;
  background-origin: border-box;
  --button-text-color: #fff;
  min-height: 46px;
  font-size: 1.2em;
  padding: 8px;
  margin-bottom: 4px;
}

.mp-button > *, .mp-button-link {
  position: relative;
  z-index: 2;
  width: calc(100% + 4px);
  min-height: calc(100% + 4px);
  margin: -2px;
  display: flex;
  gap: 6px;
  padding: 8px 10px 14px;
  align-items: center;
  justify-content: center;
  color: var(--button-text-color, #fff);
  text-shadow: 2px 2px 0 var(--button-text-shadow-color);
}

.mp-button:active > *, .mp-portal-active > * {
  padding: 14px 10px 8px;
  margin-top: -8px;
}

.mp-button-wrapper,
.mp-portal-wrapper {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 4px;
  width: 100%;
}

.mp-button-wrapper-vertical {
  flex-direction: column;
}

.mp-button-wrapper .mp-button,
.mp-portal-wrapper .mp-button {
  flex: 1 1 0;
  min-width: max-content;
  white-space: nowrap;
}

.mp-portal-active > ::after {
  content: "";
  display: block;
  position: absolute;
  bottom: 0;
  width: 20%;
  height: 2px;
  background-color: #fff;
}

.mp-portal-minecraft { --button-color-progressive: #137342; }
.mp-portal-dungeons { --button-color-progressive: #894425; }
.mp-portal-legends { --button-color-progressive: #166a64; }
.mp-portal-movie { --button-color-progressive: #5a361e; }
.mp-portal-earth { --button-color-progressive: #15673c; }
.mp-portal-story-mode { --button-color-progressive: #6e5726; }

.mp-social-wrapper {
  display: grid;
  grid-auto-columns: minmax(0, 1fr);
  grid-auto-flow: column;
  gap: 4px;
  width: 100%;
}

.mp-button.mp-social-discord { --button-color: #5865f2; }
.mp-button.mp-social-twitter { --button-color: #1da1f2; }
.mp-button.mp-social-bluesky { --button-color: #006aff; }
.mp-button.mp-social-youtube { --button-color: #f00; }

.mp-icon-wrapper {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: auto;
  --icon-base-width: 90px;
  --icon-max-width: 200px;
}

.mp-icon {
  flex: 1 auto;
  width: var(--icon-base-width);
  max-width: var(--icon-max-width);
  display: flex;
  flex-direction: column;
}

.mp-icon-img {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(255,255,255,.06);
  box-shadow: inset 0 4px rgba(0,0,0,.18), inset 0 -4px rgba(255,255,255,.12);
  border: 2px solid #242424;
}

.mp-icon-img a {
  padding: 12px;
}

.mp-icon-img img {
  width: 60px;
  height: 60px;
  object-fit: contain;
  filter: drop-shadow(2px 2px 1px rgba(0,0,0,.35));
}

.page { padding: 0 0 26px; }
.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr);
  gap: 6px;
  align-items: start;
}
.server-board, .admin-board { min-width: 0; }

.breadcrumb, .server-tools, .server-filter, .server-card, .panel, .form-card, .category, .rss-feed-list, .mp-section {
  background-color: rgba(76, 78, 82, .42);
  border: 2px solid #202125;
  box-shadow:
    inset -2px -2px rgba(0,0,0,.18),
    inset 2px 2px rgba(255,255,255,.07);
  padding: 12px;
}
.breadcrumb { margin-bottom: 10px; font-weight: 800; }

.server-tools {
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.server-tools h2, .form-card h2, .category h2 {
  margin: 0;
  color: #fff;
  font-size: 20px;
}
.server-tools p, .muted, small { color: var(--muted); }

.server-filter {
  margin-bottom: 10px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 160px auto;
  gap: 8px;
}

input, textarea, select {
  width: 100%;
  border: 2px solid #15181d;
  background: var(--input-bg);
  color: #fff;
  padding: 10px 12px;
  font: inherit;
  outline: none;
  box-shadow: inset 1px 1px 0 #6b7078, inset -1px -1px 0 #2c3036;
}
textarea { resize: vertical; min-height: 170px; }
input:focus, textarea:focus, select:focus { border-color: #7db7ff; box-shadow: 0 0 0 2px rgba(125,183,255,.22); }

.btn {
  position: relative;
  min-height: 36px;
  padding: 8px 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.btn.primary { background: var(--button-color-progressive); --button-text-color: #fff; }
.btn.ghost { background: var(--button-color); }
.btn.danger { background: var(--danger); --button-text-color: #fff; }

.mc-server-row {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr) 150px;
  gap: 12px;
  align-items: center;
  min-height: 96px;
  margin-bottom: 6px;
  padding: 0;
  border: 2px solid rgba(0,0,0,.4);
  background:
    linear-gradient(90deg, rgba(0,0,0,.14), transparent),
    rgba(76,78,82,.38);
  box-shadow:
    inset 0 4px rgba(0,0,0,.18),
    inset 0 -4px rgba(255,255,255,.16);
}
.mc-server-row.featured { border-color: #a88a3e; background: #353126; }
.mc-server-icon img {
  width: 60px;
  height: 60px;
  margin: 12px;
  border: 2px solid #111;
  background: #1a1d23;
  image-rendering: pixelated;
}
.mc-server-main { min-width: 0; }
.mc-server-title {
  display: flex;
  align-items: center;
  gap: 7px;
  flex-wrap: wrap;
  font-size: 18px;
  line-height: 1.15;
  font-weight: 900;
}
.mc-server-title a { color: #fff; }
.mc-server-title span {
  padding: 2px 7px;
  background: var(--gold);
  color: #fff;
  font-size: 12px;
  font-weight: 900;
}
.mc-server-title .advertiser-pill { background: #4a4f56; color: #b9d8ff; }
.mc-server-address {
  margin-top: 3px;
  color: #91c7ff;
  font-family: Consolas, "Lucida Console", monospace;
}
.mc-list-motd { margin-top: 4px; min-height: 36px; }
.mc-server-stats {
  padding: 12px;
  display: grid;
  gap: 3px;
  justify-items: end;
  color: #c7ccd4;
  font-family: Consolas, "Lucida Console", monospace;
}
.mc-server-stats strong {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #fff;
  font-size: 16px;
  font-weight: 500;
}
.mc-server-stats span {
  max-width: 150px;
  overflow: hidden;
  color: #b6bdc8;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ping-icon { width: 14px; height: 14px; object-fit: contain; image-rendering: pixelated; }
.offline-ping { filter: grayscale(1) opacity(.55); }
.mc-copy-ip {
  position: relative;
  border: 2px solid #15181d;
  background: var(--button-color-progressive);
  color: #fff;
  font: 900 12px Consolas, "Lucida Console", monospace;
  padding: 6px 8px;
  cursor: pointer;
}

.mc-server-main {
  padding: 12px 0;
}

.rss-feed-list { margin-top: 10px; overflow: hidden; }
.rss-feed-list header, .category header {
  padding: 12px 14px;
  border-bottom: 2px solid #15181d;
  background: var(--button-color);
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.rss-feed-list h2, .rss-feed-list h3 { margin: 0; }
.rss-feed-group { padding: 12px 14px 4px; border-bottom: 2px solid #15181d; }
.rss-feed-group:last-child { border-bottom: 0; }
.rss-feed-group h3 { margin-bottom: 8px; color: #fff; font-size: 15px; }
.rss-feed-row { padding: 10px 0; border-top: 1px solid #4b525d; }
.rss-feed-row a { color: var(--link); font-weight: 900; }
.rss-feed-row p { margin: 4px 0; color: var(--muted); }
.rss-feed-row small { display: block; }

.server-card { overflow: hidden; margin-bottom: 10px; }
.ad-banner {
  min-height: 150px;
  padding: 18px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(20,24,30,.88), rgba(20,24,30,.32)),
    linear-gradient(135deg, #2d5835, #25303b);
  background-size: cover;
  background-position: center;
  border-bottom: 2px solid #15181d;
}
.ad-banner h2 { margin: 6px 0 0; font-size: 28px; line-height: 1.08; }
.ad-banner p { margin: 4px 0 0; color: #d9e4ef; font-weight: 900; }
.badge, .online, .offline {
  display: inline-flex;
  width: fit-content;
  padding: 5px 9px;
  border: 2px solid #15181d;
  background: #4a4f56;
  color: #fff;
  font-weight: 900;
}
.online { color: #7ee18e; }
.offline { color: #ff8a8a; }

.xf-post { display: grid; grid-template-columns: 172px minmax(0, 1fr); }
.xf-post.no-advertiser { grid-template-columns: 1fr; }
.post-user {
  padding: 16px;
  background: var(--panel-2);
  border-right: 2px solid #15181d;
  text-align: center;
}
.post-user img {
  width: 86px;
  height: 86px;
  margin: 0 auto 10px;
  border: 2px solid #111;
  background: #1a1d23;
  image-rendering: pixelated;
}
.post-user strong, .post-user em, .post-user small { display: block; }
.post-user em { margin-top: 4px; color: #91c7ff; font-style: normal; font-weight: 900; }
.post-main { min-width: 0; }
.post-main header {
  padding: 12px 14px;
  border-bottom: 2px solid #15181d;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-weight: 800;
}
.post-main header span, .post-main header a {
  padding: 4px 8px;
  border: 1px solid #15181d;
  background: #3e444d;
}
.post-main p, .server-description { margin: 0; padding: 16px 14px; color: var(--post-text); overflow-wrap: anywhere; }
.collapsed-description {
  position: relative;
  max-height: 154px;
  margin: 14px;
  overflow: hidden;
  border: 2px solid #15181d;
  background: var(--panel-2);
  cursor: pointer;
}
.collapsed-description-inner { padding: 14px; color: var(--post-text); overflow-wrap: anywhere; }
.collapsed-description::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 56px;
  background: linear-gradient(180deg, rgba(37,42,51,0), var(--panel-2));
  pointer-events: none;
}
.collapsed-description > span {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 8px;
  z-index: 1;
  text-align: center;
  color: #91c7ff;
  font-weight: 900;
}
.collapsed-description.open { max-height: none; }
.collapsed-description.open::after, .collapsed-description.open > span { display: none; }
.post-main blockquote, .motd-box {
  margin: 14px 14px 0;
  padding: 10px 12px;
  border: 2px solid #15181d;
  border-left: 5px solid var(--green);
  background: #1b1f25;
  color: #f8fbff;
}
.motd-box strong {
  display: block;
  margin-bottom: 6px;
  color: #c4c9d1;
  font-size: 12px;
  text-transform: uppercase;
}
.minecraft-motd {
  color: #fff;
  font-family: Consolas, "Lucida Console", monospace;
  font-size: 14px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
.post-main footer {
  border-top: 2px solid #15181d;
  padding: 14px;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.sidebar { display: grid; gap: 10px; }
.search-box { display: grid; grid-template-columns: 1fr 42px; gap: 6px; }
.search-box button { padding: 0; font-size: 20px; }
.panel { overflow: hidden; }
.panel h3 {
  margin: 0;
  padding: 10px 12px;
  border-bottom: 2px solid #15181d;
  background: var(--button-color);
  color: #fff;
  font-size: 15px;
}
.panel footer { border-top: 2px solid #15181d; padding: 12px 14px; }
.member-card, .empty-card {
  margin: 0 12px 12px;
  padding: 12px;
  border: 2px solid #15181d;
  background: var(--panel-2);
}
.empty-card.standalone { margin: 0; }
.member-card { display: flex; align-items: center; gap: 12px; }
.member-card img { width: 36px; height: 36px; border: 1px solid #111; background: #1a1d23; }
.member-card strong { color: #ff8a8a; display: block; }
.member-card em {
  display: inline-block;
  margin-top: 2px;
  padding: 2px 8px;
  background: var(--danger);
  color: #fff;
  font-style: normal;
  font-weight: 800;
}
.stats p { display: flex; justify-content: space-between; gap: 12px; margin: 0; padding: 5px 12px 10px; }
.stats strong { color: #fff; }

.auth-shell { max-width: 540px; margin: 0 auto; }
.form-card { padding: 18px; }
.wide-card { width: 100%; }
.form-card form { display: grid; gap: 14px; }
.form-card label { display: grid; gap: 6px; color: #dbe7f6; font-weight: 800; }
.inline-form { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; align-items: end; }
.password-grid { grid-template-columns: repeat(3, minmax(0, 1fr)) auto; align-items: end; }
.banner-preview {
  min-height: 150px;
  border: 2px solid #15181d;
  background-size: cover;
  background-position: center;
}
.check-row {
  display: flex !important;
  grid-template-columns: none !important;
  flex-direction: row;
  align-items: center;
}
.check-row input { width: auto; }
.category { overflow: hidden; margin-top: 10px; }
.member-row, .admin-row {
  padding: 12px 14px;
  border-bottom: 1px solid #4b525d;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.member-row img { width: 44px; height: 44px; border: 1px solid #111; background: #1a1d23; }
.member-row div { flex: 1; }
.member-row strong, .member-row small, .admin-row strong, .admin-row small { display: block; }
.admin-row form, .row-actions { display: flex; gap: 7px; flex-wrap: wrap; justify-content: flex-end; }
.admin-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 16px; }
.active-tab { background: var(--green) !important; }

.flash {
  padding: 12px 14px;
  margin-bottom: 10px;
  border: 2px solid #15181d;
  background: var(--panel);
  font-weight: 800;
}
.flash.error { color: #ff8a8a; }
.flash.success, .success-text { color: #7ee18e; }
.site-footer {
  color: var(--muted);
  padding: 18px 0 36px;
  text-align: center;
}

@media (max-width: 1100px) {
  .content-grid { grid-template-columns: 1fr; }
  .sidebar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .search-box { grid-column: 1 / -1; }
}

@media screen and (min-width: 990px) {
  .mp-inline-sections {
    grid-template-columns: 2fr 1fr;
    grid-template-rows: auto 1fr;
    grid-template-areas: "left site" "left right";
  }
}

@media screen and (max-width: 950px) {
  .mp-portal-wrapper .mp-button:not(.mp-portal-active) > * {
    font-size: 0;
    gap: 0;
  }

  .mp-icon-wrapper {
    --icon-base-width: 70px;
    --icon-max-width: 100px;
  }

  .mp-icon-img a {
    padding: 6px;
  }

  .mp-icon-img img {
    width: 40px;
    height: 40px;
  }
}

@media (max-width: 820px) {
  .wiki-rail { display: none; }
  .topbar, .hero, .wiki-tabs, .page, .site-footer { margin-left: 0; }
  .main-nav { display: none; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-title { grid-column: auto; }
  .wiki-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 680px) {
  .wrap { width: min(100% - 20px, 1320px); }
  .circle, .nav-login { display: none; }
  .server-tools { align-items: stretch; flex-direction: column; }
  .server-filter, .xf-post, .inline-form, .password-grid { grid-template-columns: 1fr; }
  .post-user { border-right: 0; border-bottom: 2px solid #15181d; }
  .sidebar { grid-template-columns: 1fr; }
  .admin-row, .member-row { align-items: stretch; flex-direction: column; }
  .mc-server-row { grid-template-columns: 58px minmax(0, 1fr); }
  .mc-server-icon img { width: 48px; height: 48px; }
  .mc-server-stats {
    grid-column: 2;
    justify-items: start;
    grid-auto-flow: column;
    justify-content: start;
    gap: 10px;
  }
  .mc-server-stats span { max-width: 100px; }
}
