/* ===================================================================================== */
/* Root Variables                                                                        */
/* ===================================================================================== */

:root {
  --brand-bg: #43382d;
  --brand-orange: #ff9a31;
  --brand-orange-hover: #ffb84d;
  --text-light: #fff;
  --text-dark: #292929;
  --border-dark: #000;
}

/* ===================================================================================== */
/* Base Layout & Resets                                                                  */
/* ===================================================================================== */

* { box-sizing: border-box; }

html, body { overflow-x: auto; }

body {
  margin: 0;
  height: 100%;
  width: 100%;
  min-width: 1240px;
  font-family: "Arial", sans-serif;
  background-color: var(--brand-bg);

  /* Optional background image:
  background: url("img/paradox_park.jpg") top no-repeat black fixed;
  background-size: cover;
  */
}

#wrap {
  margin: 0 auto;
  padding: 0;
  min-width: 1240px;
}

#flex { display: flex; }

/* ===================================================================================== */
/* Header                                                                                */
/* ===================================================================================== */

#header {
  width: 100%;
  min-width: 1200px;
  height: 156px; /* default larger */
  background: 
    url("../img/layout/top_back.png") repeat-x center,
    url("../img/layout/neb1.png") no-repeat center/cover,
    var(--brand-bg);
  background-size: auto, cover;
  position: relative;
  overflow: hidden;
  clear: both;
}

/* Left side */
#header-left {
  float: left;
  width: auto;
  padding: 8px 10px;
  color: var(--text-light);
  font-size: 9px;
}
/* Make sure WP menu is inline */
#header .headerlinks ul {
  margin: 0;
  padding: 0;
  list-style: none;
  margin-left:20px;
}

#header .headerlinks li {
  display: inline;
}

#header .headerlinks li + li::before {
  content: " | ";
  padding: 0 6px;
}
.headerlinks {
  margin-bottom: 5px;
  white-space: nowrap;
}
.headerlinks a {
  font-size: 9px;
  color: #fff;
  text-decoration: none;
}
.headerlinks a:hover {
  text-decoration: underline;
}
.headerlinks ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: inline;
}

.headerlinks li {
  display: inline;
  margin: 0;
  padding: 0;
}
#header-left a img,
#header-right img{
  display: block;
}
.headerlinks li + li::before{
  content: " | ";
  color: var(--brand-orange);
  padding: 0 6px;
}

#header #logo,
#header .logo {
  position: absolute;
  top: 42px;        /* tweak until perfect */
  left: 18px;       /* tweak until perfect */
  z-index: 40;
  margin: 0 !important;
}
/* Logo */
#header-left img {
  max-height: 140px;
  width: auto;
  height: auto;
  margin-left: 30px;
  margin-top: -12px;
}

/* Right side */
#header-right {
  float: right;
}
#header-right img {
  max-height: 186px;
  height: auto;
  width: auto;
  margin-top: -27px;
}

header {
  position: relative;
  overflow: hidden; /* Contain snowflakes */
}

/* ===================================================================================== */
/* WordPress Accessibility Helpers                                                       */
/* ===================================================================================== */

/* WordPress uses this class for headings/labels that should be visually hidden.
   If it's missing, you'll see things like "Post navigation" rendered as a normal heading. */
.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  width: 1px;
  word-wrap: normal !important;
}

.screen-reader-text:focus {
  clip: auto !important;
  clip-path: none;
  height: auto;
  width: auto;
  margin: 0;
  overflow: visible;
  position: static;
}

/* Snowflake effect */
.snowflake {
  position: absolute;
  top: -50px;
  font-size: 1em;
  color: var(--text-light);
  pointer-events: none;
  animation: fall linear;
}
@keyframes fall {
  0%   { transform: translate(0, 0) rotate(0); }
  50%  { transform: translate(20px, 50vh) rotate(180deg); }
  100% { transform: translate(-20px, 100vh) rotate(360deg); }
}

/* ===================================================================================== */
/* Sidebars                                                                              */
/* ===================================================================================== */

#sidebar-left {
  float: left;
  width: 190px;
  height: 100%;
  margin-left: -208px;
  padding: 10px 12px;
  background: #000;
  border-radius: 0 15px 15px 0;
}

/* Paragraphs just handle spacing */
#sidebar-left p {
  margin: 6px 0;
}

#sidebar-left a { 
  font-size: 0.7rem; 
  line-height: 1.1;
}

/* Links define the actual text look */
#sidebar-left a {
  display: block;
  padding-left: 10px;
  font-size: 1em;
  font-weight: 500;
  color: var(--brand-orange);
  text-decoration: none;
}

#sidebar-left a:hover {
  color: var(--brand-orange-hover);
  text-decoration: underline;
}

#sidebar-left ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
/* Right Sidebar */
#sidebar-right {
  flex: 0 0 167px;
  width: 167px;
  margin-left: 20px;
  padding-top: 60px;
  position: relative;
  z-index: 0;
  align-self: stretch;
  overflow: hidden;
  background:transparent;
}
#sidebar-right::before {
  content: "";
  position: absolute;
  top: 62px;
  left: 0; right: 0; bottom: 0;
  background: #000;
  border-radius: 15px 0 15px 0;
  z-index: -1;
}
#sidebar-right h3,
#sidebar-right h4 {
  width: 100%;
  margin: 0;
  padding: 10px 0;
  font-size: 0.9rem;
  line-height: 1;
  color: var(--text-light);
  text-align: center;
  border-left: 0 solid var(--brand-orange);
}
#sidebar-right h4 { background-color: var(--brand-bg); }
#sidebar-right h4 a { color: var(--text-light); }

/* ===================================================================================== */
/* GoldSrc Status Widget (right sidebar sizing + classic look)                            */
/* ===================================================================================== */

/* The plugin ships with a "card" layout intended for full-width content areas.
   In the classic theme, the right sidebar is narrow (~167px), so we stack servers
   vertically and remove large/glassy styling. */

#sidebar-right .gssw-list{
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0;
  margin: 0;
}

#sidebar-right .gssw-card {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

#sidebar-right .gssw-top{
  margin: 0;
  padding: 0;
  background: var(--brand-bg);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

#sidebar-right .gssw-label{
  font-size: 0.85rem;
  font-weight: 800;
}

#sidebar-right .gssw-status{
  font-size: 10px;
  padding: 2px 6px;
}

#sidebar-right .gssw-body{
  padding: 0 !important;
  gap: 0 !important;

}

/* Stats row: keep it compact for the narrow column */
#sidebar-right .gssw-stats{
  grid-template-rows: auto auto;
  gap: 8px;
}

#sidebar-right .gssw-stats .gssw-item{
  padding: 6px;
}

#sidebar-right .gssw-stats .gssw-k{
  font-size: 10px;
}

#sidebar-right .gssw-stats .gssw-v{
  font-size: 12px;
}

/* Map area: make the image feel like the old sidebar boxes */
#sidebar-right .gssw-mapBox{
  margin: 0;
  /* no boxing in the sidebar */
  padding: 0;
  border-radius: 0;
  border: 0;
  background: transparent;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#sidebar-right .gssw-mapMedia{
  min-height: 90px;
  border-radius: 0;
}

/* Put the map name UNDER the image (above players) */
#sidebar-right .gssw-mapMedia{ order: 1; }
#sidebar-right .gssw-mapLabel{ order: 2; text-align: left;
  padding: 6px 8px 0; }
#sidebar-right .gssw-mapLabel .gssw-k{ opacity: .75; }
#sidebar-right .gssw-mapLabel .gssw-v{ font-weight: 700; }

/* Ensure ALL widget text is white */
#sidebar-right .gssw-body,
#sidebar-right .gssw-body *,
#sidebar-right .gssw-mapLabel,
#sidebar-right .gssw-mapLabel *,
#sidebar-right .gssw-players,
#sidebar-right .gssw-players *,
#sidebar-right .gssw-stats,
#sidebar-right .gssw-stats * {
  color: #fff !important;
}

/* Remove curved edges from the actual thumbnail image too */
#sidebar-right .gssw-mapThumb{ border-radius: 6px !important; }

/* Players list: small + readable */
#sidebar-right .gssw-players{
  /* no boxing in the sidebar */
  padding: 0;
  border-radius: 0;
  border: 0;
  background: transparent;
}

#sidebar-right .gssw-playersTitle{
  font-size: 10px;
}

#sidebar-right .gssw-playersList{
  padding-left: 6px;
  font-size: 0.72rem;
  line-height: 1.2;
}

/* Align Now Playing / Players line left (details summary in plugin) */
#sidebar-right .gssw-playersSummary,
#sidebar-right .gssw-playersTitle{
  text-align: left !important;
  justify-content: flex-start !important;
  padding-left: 8px !important;
}
#sidebar-right .gssw-playersSummaryCount{
  margin-left: auto;
}

/* Server title should look like part of the theme (centered on brand background) */
#sidebar-right .gssw-top{ padding: 0; margin: 0; }
#sidebar-right .gssw-label{
  display: block;
  width: 100%;
  text-align: center;
  padding: 10px 0;
  background: var(--brand-bg);
  color: var(--text-light);
  font-weight: 600;
}

/* Hide ONLINE pill (not needed in the sidebar) */
#sidebar-right .gssw-status{ display: none !important; }

/* Pull in the overall padding so it sits flush */
#sidebar-right .gssw-body{ padding: 0 !important; 
  gap: 0 !important;
}

/* The plugin lightbox should sit above the theme lightbox */
.gssw-lightbox{ z-index: 999999; }

/* Sidebar search: mimic legacy (single field, no big button) */
#sidebar-right .search-bar button{ display:none; }


.wp-block-separator {
  border-top: 0px solid!important;
}


/* ===================================================================================== */
/* Search                                                                                */
/* ===================================================================================== */

/* =========================================
   Sidebar Search (Gutenberg Search block)
   ========================================= */

   #sidebar-right .wp-block-search {
    margin: 14px 8px 32px 8px; 
  }
  
  #sidebar-right .wp-block-search__inside-wrapper {
    display: block;
  }
  
  /* The input */
  #sidebar-right .wp-block-search__input {
    width: 100%;
    padding: 12px 14px;
    background: linear-gradient(to bottom, #1a1a1a, #0d0d0d);
    border: 1px solid #ff9f1c; /* HL amber */
    border-radius: 6px;
    color: #fff;
    font-size: 14px;
    font-family: inherit;
    outline: none;
    box-shadow:
      inset 0 0 6px rgba(0, 0, 0, 0.8),
      0 0 10px rgba(255, 159, 28, 0.15);
  }
  
  /* Placeholder */
  #sidebar-right .wp-block-search__input::placeholder {
    color: #bbb;
    opacity: 0.85;
  }
  
  /* Focus glow */
  #sidebar-right .wp-block-search__input:focus {
    border-color: #ff6600;
    box-shadow:
      inset 0 0 6px rgba(0, 0, 0, 0.9),
      0 0 12px rgba(255, 102, 0, 0.6);
  }
  
  /* Hide the button completely (button-less search) */
  #sidebar-right .wp-block-search__button {
    display: none !important;
  }
  
  /* If WP still reserves space for the button, force clean layout */
  #sidebar-right .wp-block-search__inside-wrapper {
    gap: 0 !important;
  }
  
/* ===================================================================================== */
/* Main Content                                                                          */
/* ===================================================================================== */

#container {
  margin: 0 18px 0 205px;
  min-height: 300px;
  display: flex;
  align-items: stretch;
  background: var(--text-dark);
  border: 2px solid var(--border-dark);
  border-radius: 15px;
  z-index: 3;
}
#content {
  flex: 1 1 0;
  min-width: 0;
  padding: 0 40px;
  position: relative;
  font-family: "Verdana", sans-serif;
  color: var(--text-light);
}

/* ===================================================================================== */
/* Front Page                                                                            */
/* ===================================================================================== */

/*
  Home page: show a single featured News post (sticky first) with the classic bar + accent.
  This is intentionally scoped to the front-page template markup to avoid affecting other pages.
*/
.mx-front-feature {
  margin: 40px 0 40px;
}

.mx-feature-header {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px 12px 18px;
  border-radius: 10px;
  background: linear-gradient(180deg, #161616, #0d0d0d);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.mx-feature-header::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  bottom: 10px;
  width: 4px;
  background: var(--brand-orange);
  border-radius: 4px;
}

.mx-feature-title {
  margin: 0;
  font-size: 22px;
  line-height: 1.1;
  font-family: Arial, sans-serif;
  font-weight: 700;
  color: #ffcc66;
}

.mx-feature-badge {
  margin-left: auto;
  font-size: 12px;
  line-height: 1;
  color: var(--text-light);
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 4px 9px;
  border-radius: 999px;
}

.mx-feature-body {
  margin-top: 18px;
  font-size: 13px;
  line-height: 1.65;
}

.mx-feature-body a {
  color: var(--brand-orange);
  text-decoration: none;
}

.mx-feature-body a:hover {
  color: var(--brand-orange-hover);
  text-decoration: underline;
}

.mx-feature-body h2,
.mx-feature-body h4 {
  margin: 18px 0 10px;
  font-family: Arial, sans-serif;
}

.mx-feature-body p {
  margin: 10px 0;
}

.mx-feature-body ul,
.mx-feature-body ol {
  margin: 10px 0 18px 22px;
  padding: 0;
}

.mx-feature-body li {
  margin: 6px 0;
}

/* ===================================================================================== */
/* Footer                                                                                */
/* ===================================================================================== */

#footer {
  width: 100%;
  margin: 0 auto;
}
#footer-left,
#footer-right {
  margin: 0;
  padding: 0 10px;
  font-size: 0.7rem;
  color: var(--text-light);
}
#footer-left  { float: left;  text-align: left; }
#footer-right { float: right; text-align: right; }

.footerlinks p {
  margin: 0;
  padding: 3px;
  font-size: 0.7rem;

  color: var(--text-light);
}

.footerlinks { margin-bottom: 5px; }
.footerlinks a {
  color: var(--brand-orange);
  text-decoration: none;
}
.footerlinks a:hover { text-decoration: underline; }

/* ===================================================================================== */
/* Content Styling (Images, Buttons, Callouts, Pre/Code)                                 */
/* ===================================================================================== */

.image-container,
.image-container-maps { margin: 20px 0; }

.image-container-maps img {
  width: 100%;
  max-width: 1024px;
}

/* Download list styling */
.download-button { margin: 20px 0 0 20px; }

.download-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.download-list li {
  padding-left: 0;
  margin: 8px 0;
  line-height: 1.6;
}
.download-list a::before {
  content: "⬇ ";
  font-weight: normal;
}
.download-list {
  margin-left: 2px;
}
.download-list a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border-radius: 10px;
  text-decoration: none;
  background: #ff9a31;
  color: #fff;
  font-weight: 600;
}

.download-list a:hover { filter: brightness(1.05); color:#fff; }

/* Buttons */
.btn {
  display: inline-block;
  padding: 10px 20px;
  font-size: 16px;
  color: var(--text-light);
  background: var(--brand-orange);
  border-radius: 5px;
  text-decoration: none;
  transition: background 0.3s ease;
}
.btn:hover { background: #E88C2F; }

/* Update banner */
#update {
  display: flex;
  align-items: center;
  justify-content: left;
  height: 30px;
  margin-bottom: 20px;
  background: #000;
  border-radius: 20px;
}
#update img { margin-right: 20px; }
#update h1 {
  margin: 0;
  font-size: 14px;
  font-weight: bold;
  line-height: 1;
  font-family: Arial, sans-serif;
  color: var(--text-light);
}

/* Pre / Code */
pre {
  margin: 16px 0;
  padding: 10px 14px;
  font-size: 13px;
  font-family: "Courier New", monospace;
  background: #111;
  color: var(--brand-orange);
  border-radius: 6px;
  white-space: pre-wrap;
  word-wrap: break-word;
  overflow-x: auto;
}
code {
  padding: 2px 6px;
  font-size: 12px;
  font-family: "Courier New", monospace;
  background: #222;
  color: #ffd280;
  border-radius: 4px;
}

/* Code blocks: copy button + roomier spacing */
.code-block {
  position: relative;
  margin: 16px 0;
  overflow: visible;
}

/* Roomier block padding (covers both <pre> and standalone <code> blocks) */
.code-block pre,
.code-block > code {
  display: block;
  padding: 16px 52px 16px 16px; /* room for copy button */
  font-size: 13px;
  line-height: 1.5;
  background: #111;
  border-radius: 6px;
  overflow-x: auto;
}

/* In case WP outputs <pre><code>...</code></pre>, keep code transparent */
.code-block pre code {
  padding: 0;
  background: transparent;
  color: inherit;
}

.code-block .copy-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 3;
  background: #222;
  color: var(--brand-orange);
  border: 1px solid #333;
  border-radius: 4px;
  padding: 4px 10px;
  font-size: 12px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.code-block .copy-btn:hover {
  background: var(--brand-orange);
  color: #111;
}

.code-block .copy-btn.is-copied {
  background: var(--brand-orange);
  color: #111;
}

/* Callouts */
.callout {
  margin: 15px 0;
  padding: 8px 12px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-light);
  background: #1a1a1a;
  border-left: 4px solid var(--brand-orange);
  border-radius: 4px;
}
.callout strong { color: var(--brand-orange); }

.callout.funfact {
  margin: 20px 0;
  padding: 16px 20px;
  background: #222;
  border-left: 4px solid var(--brand-orange);
  border-radius: 6px;
}
.callout.funfact h2 {
  margin: 0 0 10px;
  font-size: 16px;
  color: var(--brand-orange);
  display: flex;
  align-items: center;
  gap: 6px;
}
.callout.funfact p {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-light);
}

/* Example pairs */
.example-pair {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
}
.example-pair .gallery {
  flex: 1;
  padding: 6px;
  background: #000;
  border: 1px solid #444;
  border-radius: 6px;
  text-align: center;
}
.example-pair img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 4px;
}

/* Spacers */
hr {
  border: 0;
  height: 1px;
  margin: 30px 0;
  background: linear-gradient(to right, transparent, #555, transparent);
}
#adsense, #spacer, #spacer-small, .imgspacer {
  margin: auto;
  text-align: center;
}
#adsense      { padding: 40px 40px 0px 40px; }
#spacer       { padding: 20px; }
#spacer-small { padding: 10px; }
.imgspacer    { padding: 20px 0; }

/* ===================================================================================== */
/* Map Review Monday                                                                     */
/* ===================================================================================== */

.section-title {
  margin-top: 40px;
  margin-bottom: 10px;
  padding-left: 6px;
  border-left: 3px solid var(--brand-orange);
  color: var(--text-light);
}
.section-title.highlight {
  margin: 15px 0;
  padding: 8px 12px;
  line-height: 1.5;
  color: var(--text-light);
  background: #1a1a1a;
  border-left: 4px solid var(--brand-orange);
  border-radius: 4px;
}

/* Review header */
.review-header {
  margin: 20px 0;
  padding: 12px 16px;
  background: #111;
  border-left: 5px solid #ff6600;
  border-radius: 6px;
}
.review-header .map-title {
  font-size: 1.6rem;
  font-weight: bold;
  color: #ffcc66;
}
.review-header .map-date {
  font-size: 0.9rem;
  color: #aaa;
}

.recommend    { display: block; color: #77dd77; margin-top: 4px; }
.notrecommend { display: block; color: #df492e; margin-top: 4px; }

/* Map Facts */
.map-facts {
  margin: 20px 0;
  padding: 12px;
  background: #1a1a1a;
  border: 1px solid #333;
  border-radius: 6px;
}
.map-facts h4 {
  margin-bottom: 8px;
  color: #ffcc66;
}
.map-facts ul {
  margin: 0;
  padding-left: 18px;
  color: #ccc;
}

/* Score Section */
.score-section {
  margin: 20px 0;
  padding: 8px 12px;
  background: #222;
  border-left: 5px solid var(--brand-orange);
  border-radius: 4px;
}
.score-section h3 {
  margin: 0;
  font-size: 16px;
  color: #ffcc66;
  border: none;
  padding-left: 0;
}
.score-section .recommend {
  margin-top: 6px;
  font-size: 13px;
  color: #77dd77;
}

/* Video Section */
.video-section h3 {
  margin-bottom: 10px;
  padding: 8px 12px;
  color: #ffcc66;
  background: #222;
  border-left: 5px solid #ff6600;
  border-radius: 4px;
}
.video-wrapper {
  display: flex;
  justify-content: center;
}

/* ===================================================================================== */
/* Responsive Image Galleries                                                            */
/* ===================================================================================== */

.gallery-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

/* Maps */
.gallery-item-maps {
  width: 320px;
  margin-bottom: 10px;
  text-align: center;
  background: #000;
  border: 1px solid #777;
  transition: border-color 0.3s;
}
.gallery-item-maps img {
  display: block;
  width: 100%;
  height: auto;
  background: #111;
}
.gallery-item-maps:hover { border-color: #ccc; }
@media (max-width: 1450px) {
  .gallery-item-maps { width: 260px; }
}

/* Models */
.gallery-item-models {
  width: 164px;
  margin-bottom: 10px;
  text-align: center;
  background: #000;
  border: 1px solid #777;
  transition: border-color 0.3s;
}
.gallery-item-models a {
  display: block;
  width: 100%;
  height: 200px;
  overflow: hidden;
  background: #111;
}
.gallery-item-models img {
  width: 164px;
  height: 200px;
  object-fit: cover;
  object-position: top center;
}
.gallery-item-models .desc {
  padding: 6px 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Weapons */
.gallery-item-weapons {
  width: 380px;
  margin-bottom: 10px;
  text-align: left;
  background: #000;
  border: 1px solid #777;
  transition: border-color 0.3s;
}
.gallery-item-weapons img {
  display: block;
  width: 100%;
  height: auto;
  background: #111;
}
.gallery-item-weapons:hover { border-color: #ccc; }

/* Captions */
.desc {
  margin-top: 5px;
  font-size: 14px;
  color: var(--text-light);
}

/* ==============================
   GALLERY (MAX 5 PER ROW)
   ============================== */
   .mx-feature-body .wp-block-gallery,
   .mx-feature-body .gallery {
     display: grid;
     grid-template-columns: repeat(5, 1fr);
     gap: 14px;
     margin: 20px 0;
   }
   
   @media (max-width: 1200px) {
     .mx-feature-body .wp-block-gallery,
     .mx-feature-body .gallery {
       grid-template-columns: repeat(4, 1fr);
     }
   }
   
   @media (max-width: 900px) {
     .mx-feature-body .wp-block-gallery,
     .mx-feature-body .gallery {
       grid-template-columns: repeat(3, 1fr);
     }
   }
   
   @media (max-width: 650px) {
     .mx-feature-body .wp-block-gallery,
     .mx-feature-body .gallery {
       grid-template-columns: repeat(2, 1fr);
     }
   }
   
   @media (max-width: 420px) {
     .mx-feature-body .wp-block-gallery,
     .mx-feature-body .gallery {
       grid-template-columns: 1fr;
     }
   }
   
   .mx-feature-body .wp-block-gallery figure,
   .mx-feature-body .gallery-item {
     width: 100% !important;
     margin: 0 !important;
   }
   
   .mx-feature-body .wp-block-gallery img,
   .mx-feature-body .gallery img {
     width: 100%;
     height: auto;
     display: block;
     border-radius: 3px;
     cursor: pointer;
   }
   

   /* Force 5-up grid for tracer blocks (falls back on smaller screens) */
.mx-grid-5.wp-block-group {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

/* 4 columns on medium widths */
@media (max-width: 1200px) {
  .mx-grid-5.wp-block-group { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* 2 columns on small */
@media (max-width: 800px) {
  .mx-grid-5.wp-block-group { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* 1 column on very small */
@media (max-width: 520px) {
  .mx-grid-5.wp-block-group { grid-template-columns: 1fr; }
}

   /* ==============================
      LIGHTBOX
      ============================== */
   .mx-lightbox {
     position: fixed;
     inset: 0;
     background: rgba(0,0,0,0.9);
     display: none;
     align-items: center;
     justify-content: center;
     z-index: 9999;
   }
   
   .mx-lightbox img {
     max-width: 92%;
     max-height: 92%;
   }
   
   .mx-lightbox.active {
     display: flex;
   }
   
/* ===================================================================================== */
/* Pagination                                                                            */
/* ===================================================================================== */

.pagination {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 20px;
}
.pagination a {
  padding: 2px 6px;
  margin-right: 2px;
  font-size: 9px;
  color: var(--brand-orange);
  background: #2b2b2b;
  border-radius: 5px;
  text-decoration: none;
  transition: background 0.3s;
}
.pagination a:hover,
.pagination a.active {
  color: var(--text-light);
  background: var(--brand-orange);
}
.pagination a.active { font-weight: bold; }

/* ===================================================================================== */
/* Single Post: Previous/Next navigation                                                  */
/* ===================================================================================== */

/* WordPress outputs this as <nav class="navigation post-navigation"> ... */
.post-navigation {
  margin: 14px 0 6px;
}

.post-navigation .nav-links {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.post-navigation .nav-previous,
.post-navigation .nav-next {
  display: inline-flex;
}

.post-navigation a {
  font-size: 0.8rem;
  color: var(--brand-orange);
  text-decoration: none;
  line-height: 1.2;
}

.post-navigation a:hover {
  color: var(--brand-orange-hover);
  text-decoration: underline;
}

.post-navigation .nav-subtitle {
  color: var(--brand-orange);
  font-weight: 400;
}

/* ===================================================================================== */
/* WordPress Block Gallery + Lightbox (keeps the same "legacy" gallery look & feel)       */
/* ===================================================================================== */

/* Gutenberg/Block gallery containers */
.wp-block-gallery,
.wp-block-gallery.has-nested-images,
.blocks-gallery-grid,
.gallery {
  /* Fixed max of 5 columns (then steps down) */
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0;

  /* Make sure items stretch (prevents tiny centered thumbs) */
  justify-items: stretch;
  align-items: stretch;
}

/* Ensure gallery items fill their grid cell */
.wp-block-gallery figure,
.wp-block-gallery .wp-block-image,
.wp-block-gallery .blocks-gallery-item,
.blocks-gallery-grid .blocks-gallery-item,
.gallery .gallery-item {
  margin: 0 !important;
  width: 100% !important;
  max-width: none !important;
}

.wp-block-gallery a,
.blocks-gallery-grid a,
.gallery .gallery-item a {
  display: block;
  width: 100%;
}

@media (max-width: 1200px) {
  .wp-block-gallery,
  .wp-block-gallery.has-nested-images,
  .blocks-gallery-grid,
  .gallery {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
@media (max-width: 900px) {
  .wp-block-gallery,
  .wp-block-gallery.has-nested-images,
  .blocks-gallery-grid,
  .gallery {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 650px) {
  .wp-block-gallery,
  .wp-block-gallery.has-nested-images,
  .blocks-gallery-grid,
  .gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 420px) {
  .wp-block-gallery,
  .wp-block-gallery.has-nested-images,
  .blocks-gallery-grid,
  .gallery {
    grid-template-columns: 1fr;
  }
}



/* Each image "tile" (gallery only)
   NOTE: WordPress also uses .wp-block-image for standalone images,
   so we only style it as a tile when it is inside a gallery. */
.wp-block-gallery figure,
.blocks-gallery-grid figure,
.gallery .gallery-item,
.wp-block-gallery .wp-block-image,
.blocks-gallery-grid .wp-block-image {
  margin: 0;
}

/* Legacy tile styling applied to gallery figures */
.wp-block-gallery figure,
.blocks-gallery-grid figure,
.wp-block-gallery .wp-block-image,
.blocks-gallery-grid .wp-block-image,
.gallery .gallery-item,
.gallery dl,
.gallery dt {
  background: #000;
  border: 1px solid #ccc;
}

.wp-block-gallery figure:hover,
.blocks-gallery-grid figure:hover,
.wp-block-gallery .wp-block-image:hover,
.blocks-gallery-grid .wp-block-image:hover,
.gallery .gallery-item:hover {
  background: #111;
  border-color: #777;
}

/*
  WordPress block galleries (and some themes/plugins) position captions as an
  overlay on top of the image. We want the classic MightyXen look: a black
  caption bar *below* the thumbnail, and only when a caption exists.
*/
.wp-block-gallery figure,
.blocks-gallery-grid figure,
.wp-block-gallery .wp-block-image,
.blocks-gallery-grid .wp-block-image,
.gallery .gallery-item {
  display: flex;
  flex-direction: column;
}

.wp-block-gallery figcaption,
.gallery .gallery-caption,
.wp-block-gallery .wp-block-image figcaption,
.blocks-gallery-grid .wp-block-image figcaption {
  /* Ensure this is not an overlay */
  position: static !important;
  inset: auto !important;
  transform: none !important;
  backdrop-filter: none !important;
  filter: none !important;

  /* Classic caption bar */
  background: #000;
  margin: 0;
  width: 100%;
  padding: 8px;
  font-size: 10px;
  text-align: center;
  color: #ddd;
}

/* Hide the bar completely when there is no caption */
.wp-block-gallery figcaption:empty,
.wp-block-gallery .wp-block-image figcaption:empty,
.blocks-gallery-grid .wp-block-image figcaption:empty,
.gallery .gallery-caption:empty {
  display: none !important;
}

.wp-block-gallery img,
.blocks-gallery-grid img,
.gallery img,
.wp-block-gallery .wp-block-image img,
.blocks-gallery-grid .wp-block-image img {
  width: 100%;
  height: auto;
  display: block;

  /* Keep thumbs tidy; prevents odd stretching if WP outputs fixed heights */
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

/* (caption styling handled above) */

/* Lightbox overlay */
#mx-lightbox {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
}
#mx-lightbox.is-open { display: block; }

.mx-lb-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.8);
}

.mx-lb-panel {
  position: relative;
  width: min(1200px, 94vw);
  height: min(780px, 90vh);
  margin: 5vh auto 0;
  background: #111;
  border-radius: 8px;
  border: 1px solid #222;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0,0,0,0.55);
}

.mx-lb-x {
  position: absolute;
  top: 10px;
  right: 14px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 6px;
  background: rgba(0,0,0,0.45);
  color: #fff;
  font-size: 22px;
  cursor: pointer;
}
.mx-lb-x:hover { background: rgba(0,0,0,0.7); }

.mx-lb-stage {
  height: calc(100% - 110px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
}

.mx-lb-img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 6px;
}

.mx-lb-footer {
  height: 110px;
  padding: 10px 18px;
  border-top: 1px solid #222;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
}

.mx-lb-caption {
  text-align: center;
  color: #fff;
  font-weight: bold;
}

.mx-lb-controls {
  display: flex;
  justify-content: center;
  gap: 10px;
}

.mx-lb-btn {
  padding: 6px 14px;
  border-radius: 4px;
  border: 1px solid #333;
  background: #222;
  color: #fff;
  cursor: pointer;
}
.mx-lb-btn:hover {
  background: var(--brand-orange);
  color: #111;
}

/* Prevent background scroll when open */
html.mx-lb-open,
html.mx-lb-open body {
  overflow: hidden;
}

/* Game Icons */
img.game_icon { width: 28px; }
.status_icon_onl,
.status_icon_nrs { display: none; }
.connectlink_cell,
.map_cell,
.players_cell { text-align: center; }

/* ===================================================================================== */
/* Typography                                                                            */
/* ===================================================================================== */

h1, h2, h3, h4 {
  margin: 0;
  font-weight: bold;
  color: var(--text-light);
}
h1 { font-size: 1.2rem; }
h2 { font-size: 1rem; }
h3 { font-size: 1rem; }
h4 { font-size: 1rem; line-height: 2.6; margin-left: 5px; }

h1 a {
  color: var(--text-light) !important;
  text-decoration: none;
}
h1 a:hover { text-decoration: underline; }

h2 {
  margin: 20px 0 10px;
  font-size: 16px;
  font-weight: bold;
  color: var(--text-light);
  border: none;
  padding: 0;
}
h3 {
  margin: 20px 0 10px;
  font-size: 16px;
  font-weight: bold;
  color: var(--text-light);
  border: none;
  padding: 0;
}

a { color: var(--brand-orange); text-decoration: none; }
a:hover { text-decoration: underline; }

ul, li {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-light);
}
ul, ol {
  margin: 12px 0;
  padding-left: 24px;
}
ul li:last-child { margin-bottom: 1rem; }
li { margin-bottom: 6px; }
ol { margin-top: 1rem; }

p {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-light);
}
small { font-size: 11px; color: var(--brand-orange); }

table {
  margin: 20px 0;
  text-align: center;
  font: 12px "Arial", sans-serif;
  color: var(--text-light);
}
th { text-align: center; }

/* ===================================================================================== */
/* Lightbox (Downloads)                                                                  */
/* ===================================================================================== */

.mx-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.75);
  z-index: 9999;
}
.mx-modal.mx-open { display: flex; }

.mx-modal__dialog {
  max-width: min(1000px, 92vw);
  max-height: 90vh;
  background: #111;
  color: var(--text-light);
  border-radius: 12px;
  overflow: auto;
  box-shadow: 0 10px 40px rgba(0,0,0,.4);
}
.mx-modal__img { display: block; max-width: 100%; height: auto; }
.mx-modal__meta { padding: 16px; }
.mx-modal__title { margin: 0 0 12px; font-size: 1.25rem; }
.mx-modal__actions { display: flex; gap: 10px; flex-wrap: wrap; }

.mx-modal__close {
  position: absolute;
  top: 10px; right: 14px;
  font-size: 28px;
  line-height: 1;
  border: 0;
  cursor: pointer;
  background: transparent;
  color: var(--text-light);
}

.mx-btn {
  display: inline-block;
  padding: 10px 14px;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  background: var(--brand-orange);
  color: var(--text-light);
  text-decoration: none;
}
.mx-btn:hover { filter: brightness(1.1); }
.mx-btn--ghost { background: transparent; border: 1px solid var(--text-light); }

@media (prefers-reduced-motion:no-preference){
  .mx-modal__dialog { transition: transform .18s ease, opacity .18s ease; }
  .mx-open .mx-modal__dialog { transform: translateY(0); opacity: 1; }
}

/* ===================================================================================== */
/* Plugins Table                                                                         */
/* ===================================================================================== */
.plugin-table {
  width: 90%;
  margin: 20px auto;
  border-collapse: collapse;
  font-size: 14px;
}

.plugin-table th,
.plugin-table td {
  padding: 10px;
  border: 1px solid #444;
  text-align: left;
}

.plugin-table th {
  background-color: var(--brand-orange);
  color: #000;
}

.plugin-table tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.05);
}

.plugin-table tr:hover {
  background: rgba(255, 255, 255, 0.1);
}
/* ===================================================================================== */
/* Responsive Adjustments                                                                */
/* ===================================================================================== */

/* ===================================================================================== */
/* MX Posts Grid (Shortcode: [mx_posts])                                                 */
/* ===================================================================================== */

.mx-postgrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
  padding: 10px 0;
}

.mx-postgrid--empty {
  padding: 12px 0;
  opacity: 0.85;
}

.mx-postcard {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(255, 102, 0, 0.35);
  border-radius: 8px;
  overflow: hidden;
  background: #111;
  background-size: cover;
  background-position: center;
  text-decoration: none;
}

/* Fallback for browsers without aspect-ratio support */
@supports not (aspect-ratio: 1 / 1) {
  .mx-postcard::before {
    content: "";
    display: block;
    padding-top: 56.25%; /* 16:9 */
  }
}

/* Bottom gradient + title overlay */
.mx-postcard::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.0) 60%);
  pointer-events: none;
}

.mx-postcard-title {
  position: absolute;
  left: 0;
  bottom: 0;
  right: 0;
  padding: 10px 12px;
  color: #fff;
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1.15;
  text-shadow: 0 1px 2px rgba(0,0,0,0.85);
}

.mx-postcard:hover,
.mx-postcard:focus-visible {
  outline: none;
  border-color: rgba(255, 102, 0, 0.85);
}

@media (max-width: 600px) {
  .mx-postgrid {
    grid-template-columns: 1fr;
  }
}

/* At 1366px (HD ready) and below */
@media (max-width: 1366px) {
  #sidebar-left {
    width: 150px;         /* reduced from 190px */
    margin-left: -168px;  /* width + 8px padding */
  }

  #container {
    margin: 0 18px 0 165px;  /* sidebar width (150) + 5px buffer */
  }

  #sidebar-left a { font-size: 0.7rem; }
  #sidebar-left p { line-height: 1.0; }
  p, ul, li       { font-size: 0.8rem; }
  .review-header .map-title { font-size: 1.1rem !important; }
  h1 { font-size: 1.0rem; }

  }

/* At 1920px (Full HD) and below */
@media (max-width: 1920px) {
  #sidebar-left {
    width: 165px;         /* reduced from 190px */
    margin-left: -183px;  /* width + 8px padding */
  }

  #container {
    margin: 0 18px 0 180px;  /* sidebar width (175) + 5px buffer */
  }

  #sidebar-left a { font-size: 0.8rem; }
  #sidebar-left p { line-height: 1.1; }
  p, ul, li       { font-size: 0.85rem; }
  .review-header .map-title { font-size: 1.2rem !important; }
  h1 { font-size: 1.1rem; }
}

/* ===================================================================================== */
/* Search Results (match single/page spacing + tidy header)                               */
/* ===================================================================================== */

.mx-search-kicker{
  margin: 0 0 10px;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-light);
  opacity: 0.95;
}

/* Keep results readable with consistent spacing */
.mx-search-result{
  margin: 18px 0 0;
}
.mx-search-result:first-child{
  margin-top: 0;
}
