@charset "UTF-8";
:root {
  --bg: #0f172a;
  --card-bg: rgba(39, 64, 86, 0.85); /* Brand color background */
  --bg-card: var(--card-bg);
  --brand-color-readonly: #274056;
  --brand-color: var(--brand-color-readonly);
  --accent: #00ff9d; /* Retro Green Accent */
  --accent-glow: rgba(0, 255, 157, 0.4);
  --secondary-glow: rgba(76, 201, 240, 0.3);
  --text-main: #e2e8f0;
  --text-dim: #94a3b8;
  --glass: rgba(39, 64, 86, 0.5);
  --border: #475569;
  --nav-height: 68px;
  --ticker-height: 32px;
  --base-font-size: 16px;
  --h1-size: 3rem;
  --h2-size: 2.4rem;
  --h3-size: 2rem;
  --h4-size: 1.6rem;
  --h5-size: 1.3rem;
  --h6-size: 1.1rem;
  --text-shadow: 4px 4px 0px #000;
  --page-gradient-start: #202d3f;
  --page-gradient-end: #0d1624;
  --hero-scene-sky-start: #32608f;
  --hero-scene-sky-mid: #173653;
  --hero-scene-sky-end: #05080f;
  --ui-transition-speed: 0.18s;
  --ui-transition-ease: ease-out;
  --page-fade-duration: 0.4s;
  --ticker-duration: 30s;
  --hero-scene-anim-duration: 2.2s;
  --press-start-pulse-duration: 1s;
}

[data-theme=light] {
  --bg: #f8fafc;
  --card-bg: rgba(255, 255, 255, 0.8);
  --accent: #7c3aed;
  --accent-glow: rgba(124, 58, 237, 0.15);
  --text-main: #0f172a;
  --text-dim: #475569;
  --border: rgba(0, 0, 0, 0.08);
}

/* Mario Colors Pixel */
[data-theme=mario] {
  --bg: #202020;
  --card-bg: rgba(0, 0, 0, 0.9);
  --accent: #E60012; /* Mario Red */
  --accent-glow: rgba(230, 0, 18, 0.4);
  --text-main: #ffffff;
  --text-dim: #dddddd;
  --border: #FFD700; /* Coin Gold */
}

/* CRT Greenish Gameboy */
[data-theme=gb-green] {
  --bg: #0f380f;
  --card-bg: rgba(48, 98, 48, 0.9);
  --accent: #9bbc0f; /* Lightest Green */
  --accent-glow: rgba(139, 172, 15, 0.4);
  --text-main: #9bbc0f;
  --text-dim: #8bac0f;
  --border: #306230;
}

/* Blueish Gameboy */
[data-theme=gb-blue] {
  --bg: #002b59;
  --card-bg: rgba(0, 64, 128, 0.8);
  --accent: #00aaff;
  --accent-glow: rgba(0, 170, 255, 0.4);
  --text-main: #e0f0ff;
  --text-dim: #80aaff;
  --border: #005580;
}

/* Modern (Sleek Dark) */
[data-theme=modern-dark] {
  --bg: #09090b;
  --card-bg: rgba(24, 24, 27, 0.9);
  --accent: #3b82f6;
  --accent-glow: rgba(59, 130, 246, 0.3);
  --text-main: #fafafa;
  --text-dim: #a1a1aa;
  --border: #27272a;
}

[data-theme=modern-dark] body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  letter-spacing: normal;
}

[data-theme=modern-dark] h1, [data-theme=modern-dark] h2, [data-theme=modern-dark] h3 {
  text-transform: none;
  letter-spacing: -0.025em;
}

[data-theme=modern-dark] .logo {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* Modern (Sleek Light) */
[data-theme=modern-light] {
  --bg: #cbcbf5;
  --card-bg: rgba(203, 203, 231, 0.9);
  --accent: #3b82f6;
  --accent-glow: rgba(19, 40, 75, 0.3);
  --text-main: #0f172a;
  --text-dim: #414146;
  --border: #d1d1e4;
}

[data-theme=modern-light] body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  letter-spacing: normal;
}

[data-theme=modern-light] h1, [data-theme=modern-light] h2, [data-theme=modern-light] h3 {
  text-transform: none;
  letter-spacing: -0.025em;
}

[data-theme=modern-light] .logo {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* Auto-generated custom themes */
[data-theme=modern-dark] {
  --base-font-size: 16px;
  --h1-size: 2rem;
  --h2-size: 1.4rem;
  --h3-size: 1rem;
  --h4-size: 0.6rem;
  --h5-size: 0.3rem;
  --h6-size: 0.1rem;
  --text-shadow: 4px 4px 0px #000;
  --page-gradient-start: #202d3f;
  --page-gradient-end: #0d1624;
  --hero-scene-sky-start: #32608f;
  --hero-scene-sky-mid: #173653;
  --hero-scene-sky-end: #05080f;
  --ui-transition-speed: 0.18s;
  --ui-transition-ease: ease-out;
  --page-fade-duration: 0.4s;
  --ticker-duration: 30s;
  --hero-scene-anim-duration: 2.2s;
  --press-start-pulse-duration: 1s;
  --brand-color-readonly: #274056;
  --bg: #09090b;
  --card-bg: #18181b;
  --accent: #3b82f6;
  --text-main: #fafafa;
  --text-dim: #a1a1aa;
  --border: #27272a;
  --accent-glow: #3b82f6;
  --brand-color: var(--brand-color-readonly);
}

[data-theme=modern-light] {
  --base-font-size: 14px;
  --h1-size: 2rem;
  --h2-size: 1.4rem;
  --h3-size: 1rem;
  --h4-size: 0.6rem;
  --h5-size: 0.3rem;
  --h6-size: 0.1rem;
  --text-shadow: 4px 4px 0px #fff;
  --page-gradient-start: #fbfcfd;
  --page-gradient-end: #eff3fa;
  --hero-scene-sky-start: #f4f8fb;
  --hero-scene-sky-mid: #f3f8fc;
  --hero-scene-sky-end: #eff2fa;
  --ui-transition-speed: 0.18s;
  --ui-transition-ease: ease-out;
  --page-fade-duration: 0.4s;
  --ticker-duration: 30s;
  --hero-scene-anim-duration: 2.2s;
  --press-start-pulse-duration: 1s;
  --brand-color-readonly: #274056;
  --bg: #cbcbf5;
  --card-bg: #cbcbe7;
  --accent: #3b82f6;
  --text-main: #0f172a;
  --text-dim: #414146;
  --border: #d1d1e4;
  --accent-glow: #13284b;
  --brand-color: var(--brand-color-readonly);
}

[data-theme=dark] {
  --base-font-size: 16px;
  --h1-size: 3rem;
  --h2-size: 2.4rem;
  --h3-size: 2rem;
  --h4-size: 1.6rem;
  --h5-size: 1.3rem;
  --h6-size: 1.1rem;
  --text-shadow: 4px 4px 0px #000;
  --page-gradient-start: #202d3f;
  --page-gradient-end: #0d1624;
  --hero-scene-sky-start: #32608f;
  --hero-scene-sky-mid: #173653;
  --hero-scene-sky-end: #05080f;
  --ui-transition-speed: 0.18s;
  --ui-transition-ease: ease-out;
  --page-fade-duration: 0.4s;
  --ticker-duration: 30s;
  --hero-scene-anim-duration: 2.2s;
  --press-start-pulse-duration: 1s;
  --brand-color-readonly: #274056;
  --bg: #0f172a;
  --card-bg: #32516d;
  --accent: #2fa6b3;
  --text-main: #e2e8f0;
  --text-dim: #94a3b8;
  --border: #475569;
  --accent-glow: #00ff9d;
  --brand-color: var(--brand-color-readonly);
}

[data-theme=mario] {
  --base-font-size: 16px;
  --h1-size: 3rem;
  --h2-size: 2.4rem;
  --h3-size: 2rem;
  --h4-size: 1.6rem;
  --h5-size: 1.3rem;
  --h6-size: 1.1rem;
  --text-shadow: 4px 4px 0px #000;
  --page-gradient-start: #411f31;
  --page-gradient-end: #240d14;
  --hero-scene-sky-start: #923055;
  --hero-scene-sky-mid: #551521;
  --hero-scene-sky-end: #0f0407;
  --ui-transition-speed: 0.18s;
  --ui-transition-ease: ease-out;
  --page-fade-duration: 0.4s;
  --ticker-duration: 30s;
  --hero-scene-anim-duration: 2.2s;
  --press-start-pulse-duration: 1s;
  --brand-color-readonly: #274056;
  --bg: #1e1717;
  --card-bg: #14121b;
  --accent: #e60012;
  --text-main: #ffffff;
  --text-dim: #dddddd;
  --border: #ffd700;
  --accent-glow: #e60012;
  --brand-color: #e60012;
}

[data-theme=gb-green] {
  --base-font-size: 16px;
  --h1-size: 3rem;
  --h2-size: 2.4rem;
  --h3-size: 2rem;
  --h4-size: 1.6rem;
  --h5-size: 1.3rem;
  --h6-size: 1.1rem;
  --text-shadow: 4px 4px 0px #000;
  --page-gradient-start: #1e4229;
  --page-gradient-end: #0c2513;
  --hero-scene-sky-start: #2f9340;
  --hero-scene-sky-mid: #155528;
  --hero-scene-sky-end: #040f0a;
  --ui-transition-speed: 0.18s;
  --ui-transition-ease: ease-out;
  --page-fade-duration: 0.4s;
  --ticker-duration: 30s;
  --hero-scene-anim-duration: 2.2s;
  --press-start-pulse-duration: 1s;
  --brand-color-readonly: #274056;
  --bg: #0f380f;
  --card-bg: #306230;
  --accent: #9bbc0f;
  --text-main: #9bbc0f;
  --text-dim: #8bac0f;
  --border: #387238;
  --accent-glow: #8bac0f;
  --brand-color: #7c960c;
}

[data-theme=gb-blue] {
  --base-font-size: 16px;
  --h1-size: 3rem;
  --h2-size: 2.4rem;
  --h3-size: 2rem;
  --h4-size: 1.6rem;
  --h5-size: 1.3rem;
  --h6-size: 1.1rem;
  --text-shadow: 4px 4px 0px #000;
  --page-gradient-start: #202d3f;
  --page-gradient-end: #0d1624;
  --hero-scene-sky-start: #32608f;
  --hero-scene-sky-mid: #173653;
  --hero-scene-sky-end: #05080f;
  --ui-transition-speed: 0.18s;
  --ui-transition-ease: ease-out;
  --page-fade-duration: 0.4s;
  --ticker-duration: 30s;
  --hero-scene-anim-duration: 2.2s;
  --press-start-pulse-duration: 1s;
  --brand-color-readonly: #274056;
  --bg: #002b59;
  --card-bg: #004080;
  --accent: #00aaff;
  --text-main: #e0f0ff;
  --text-dim: #80aaff;
  --border: #005580;
  --accent-glow: #00aaff;
  --brand-color: #0088cc;
}

/* --- 2. GLOBAL RESET --- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "VT323", monospace;
  font-size: 1.2rem;
  background-color: var(--bg);
  color: var(--text-main);
  transition: background-color 0.5s ease, color 0.3s ease;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column; /* Force footer to bottom */
  position: relative;
  z-index: 0; /* Create stacking context for fixed bg */
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  width: 100%;
}

/* --- FIXED HEADER STACK --- */
.ticker {
  background: var(--card-bg);
  border-bottom: 1px solid var(--accent);
  color: var(--accent);
  height: var(--ticker-height);
  display: flex;
  align-items: center;
  font-size: 1rem;
  font-weight: 400;
  text-transform: uppercase;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1100;
  overflow: hidden;
  pointer-events: none; /* Allow clicking through to elements behind if needed, though usually not for ticker */
  transition: transform 0.28s ease, opacity 0.28s ease;
}

.ticker-content {
  display: inline-block;
  white-space: nowrap;
  animation: ticker var(--ticker-duration, 30s) linear infinite;
  line-height: var(--ticker-height);
  will-change: transform;
}

@keyframes ticker {
  0% {
    transform: translateX(100vw);
  }
  100% {
    transform: translateX(-100%);
  }
}
.navbar {
  height: var(--nav-height);
  position: fixed;
  top: var(--ticker-height);
  left: 0;
  width: 100%;
  z-index: 1000;
  background: var(--card-bg);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  transition: top var(--ui-transition-speed, 0.18s) var(--ui-transition-ease, ease-out), background var(--ui-transition-speed, 0.18s) var(--ui-transition-ease, ease-out), border-color var(--ui-transition-speed, 0.18s) var(--ui-transition-ease, ease-out), backdrop-filter var(--ui-transition-speed, 0.18s) var(--ui-transition-ease, ease-out);
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
  width: 100%;
  padding: 0 15px;
}

.logo {
  font-weight: 400;
  font-size: 2rem;
  color: var(--text-main);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  letter-spacing: 2px;
}

.logo > span:first-child {
  width: 48px;
  height: 48px;
  background: var(--brand-color, var(--accent));
  color: var(--bg) !important;
  padding: 0px 0px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo > span:first-child img {
  width: 48px;
  height: 48px;
}

footer .logo > span:first-child {
  width: 128px;
  height: 128px;
  background: var(--brand-color, var(--accent));
  color: var(--bg) !important;
  padding: 0px 0px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

footer .logo > span:first-child img {
  width: 128px;
  height: 128px;
}

.nav-menu {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}

.nav-menu::-webkit-scrollbar {
  display: none;
}

body.nav-compact .ticker {
  transform: translateY(-100%);
  opacity: 0;
}

body.nav-compact .navbar {
  top: 0;
  height: 56px;
  background: color-mix(in srgb, var(--card-bg) 64%, transparent);
  border-bottom-color: color-mix(in srgb, var(--border) 70%, transparent);
  backdrop-filter: blur(18px) saturate(1.2);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
}

body.nav-compact .navbar .logo {
  font-size: 1.72rem;
}

body.nav-compact .navbar .logo > span:first-child,
body.nav-compact .navbar .logo > span:first-child img {
  width: 40px;
  height: 40px;
}

body.nav-compact .navbar .chip {
  padding: 7px 12px;
  font-size: 0.98rem;
}

body.nav-compact .navbar .theme-select {
  padding-top: 7px;
  padding-bottom: 7px;
  font-size: 0.98rem;
}

body.home-nav-scroll .navbar {
  top: var(--home-nav-top, var(--ticker-height));
}

/* --- VIEWS & HERO --- */
.view {
  display: none;
  padding-top: calc(var(--nav-height) + var(--ticker-height) + 60px);
  animation: fadeIn var(--page-fade-duration, 0.4s) var(--ui-transition-ease, ease-out);
  flex: 1; /* Allows content to push footer */
}

.view.active {
  display: block;
}

#view-home {
  padding-top: calc(var(--nav-height) + var(--ticker-height));
  background: radial-gradient(circle at 85% 12%, color-mix(in srgb, var(--accent) 24%, transparent) 0%, transparent 45%), linear-gradient(130deg, var(--page-gradient-start, #202d3f) 0%, var(--page-gradient-end, #0d1624) 100%);
}

.view:not(#view-home):not(#view-blog-post) {
  padding-top: calc(var(--nav-height) + var(--ticker-height));
}

#view-home > .content-wrapper {
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-left: 0;
  border-right: 0;
  padding-top: 0;
  margin-top: 0;
}

.view:not(#view-home) {
  background: radial-gradient(circle at 85% 12%, color-mix(in srgb, var(--accent) 24%, transparent) 0%, transparent 45%), linear-gradient(130deg, var(--page-gradient-start, #202d3f) 0%, var(--page-gradient-end, #0d1624) 100%);
}

.view:not(#view-home) > .content-wrapper {
  background: transparent;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border-left: 0;
  border-right: 0;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
main {
  width: 100%;
}

.content-wrapper {
  background: var(--bg);
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 2rem;
  padding-bottom: 2rem;
  flex: 1;
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
}

.content-wrapper .container {
  margin: 0 auto;
  padding: 0 2rem;
  width: 100%;
}

.hero {
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
  padding-bottom: 60px;
}

.hero:not(.home-hero) {
  min-height: auto;
}

.view:not(#view-home) h1.hero {
  font-size: clamp(2.1rem, 5.4vw, 3.4rem);
  margin-bottom: 1.1rem;
  text-shadow: 2px 2px 0 #000;
}

.view:not(#view-home):not(#view-blog-post) > .page-hero {
  --page-hero-pixel-float-y: 0px;
  margin: 0;
  width: 100%;
  padding: clamp(18px, 4.2vw, 30px) 2rem;
  min-height: clamp(112px, 18vh, 170px);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  max-width: none;
  overflow: hidden;
  background: color-mix(in srgb, var(--card-bg) 62%, var(--bg));
  border-bottom: 1px solid var(--border);
  box-shadow: inset 0 -1px 0 color-mix(in srgb, var(--border) 75%, transparent), inset 0 0 0 1px color-mix(in srgb, var(--border) 30%, transparent);
}

.view:not(#view-home):not(#view-blog-post) > .page-hero > .pixel-bg-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  transform: translate3d(0, var(--page-hero-pixel-float-y), 0);
  will-change: transform;
}

.view:not(#view-home):not(#view-blog-post) > .page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.18;
  background: repeating-linear-gradient(0deg, transparent 0px, transparent 7px, rgba(255, 255, 255, 0.04) 7px, rgba(255, 255, 255, 0.04) 8px), repeating-linear-gradient(90deg, transparent 0px, transparent 11px, rgba(0, 0, 0, 0.12) 11px, rgba(0, 0, 0, 0.12) 12px);
}

.view:not(#view-home):not(#view-blog-post) > .page-hero h1 {
  position: relative;
  z-index: 2;
  margin: 0;
  font-size: clamp(2.1rem, 6.4vw, 3.6rem);
  line-height: 1.04;
  text-shadow: 2px 2px 0 #000;
}

.home-hero {
  position: relative;
  text-align: center;
  max-width: none;
  width: 100%;
  margin: 0;
  padding: 26px;
  min-height: calc(100vh - (var(--nav-height) + var(--ticker-height)));
  min-height: calc(100svh - (var(--nav-height) + var(--ticker-height)));
  border: 0;
  background: transparent;
  box-shadow: none;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: stretch;
  --hero-main-float-y: 0px;
  --hero-scene-float-y: 0px;
  --hero-start-float-y: 0px;
  --hero-noise-float-y: 0px;
  --hero-pixel-float-y: 0px;
}

#view-home .home-hero > #pixel-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  transform: translate3d(0, var(--hero-pixel-float-y), 0);
  will-change: transform;
}

.home-hero-noise {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.2;
  background: repeating-linear-gradient(0deg, transparent 0px, transparent 7px, rgba(255, 255, 255, 0.04) 7px, rgba(255, 255, 255, 0.04) 8px), repeating-linear-gradient(90deg, transparent 0px, transparent 11px, rgba(0, 0, 0, 0.12) 11px, rgba(0, 0, 0, 0.12) 12px);
  transform: translate3d(0, var(--hero-noise-float-y), 0);
  will-change: transform;
}

.home-hero-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
  align-items: stretch;
  flex: 1;
  align-content: center;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 2rem;
}

.home-hero-main {
  max-width: 980px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform: translate3d(0, var(--hero-main-float-y), 0);
  will-change: transform;
}

.home-hero-scene {
  position: relative;
  width: min(430px, 94%);
  height: 132px;
  margin: 0 0 16px;
  border: 2px solid var(--border);
  background: linear-gradient(180deg, var(--hero-scene-sky-start, #32608f) 0%, var(--hero-scene-sky-mid, #173653) 62%, var(--hero-scene-sky-end, #05080f) 100%);
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.38);
  overflow: hidden;
  transform: translate3d(0, var(--hero-scene-float-y), 0);
  will-change: transform;
}

.hero-scene-cloud {
  position: absolute;
  height: 14px;
  background: #f7f8ff;
  image-rendering: pixelated;
  box-shadow: 0 0 0 2px #121e31;
}

.hero-scene-cloud::before,
.hero-scene-cloud::after {
  content: "";
  position: absolute;
  background: inherit;
  box-shadow: 0 0 0 2px #121e31;
}

.hero-scene-cloud::before {
  width: 12px;
  height: 12px;
  top: -8px;
  left: 10px;
}

.hero-scene-cloud::after {
  width: 10px;
  height: 10px;
  top: -6px;
  right: 8px;
}

.hero-scene-cloud-a {
  width: 54px;
  top: 16px;
  left: 42px;
}

.hero-scene-cloud-b {
  width: 44px;
  top: 34px;
  right: 50px;
}

.hero-scene-ground {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 30px;
  background: repeating-linear-gradient(90deg, #924d18 0 12px, #80400f 12px 24px);
  border-top: 3px solid #5f2d06;
}

.hero-scene-block {
  position: absolute;
  left: 50%;
  top: 32px;
  width: 46px;
  height: 46px;
  transform: translateX(-50%);
  background: linear-gradient(180deg, #f0ad53 0%, #d97f2b 100%);
  border: 3px solid #7f3f10;
  box-shadow: inset -4px -4px 0 rgba(0, 0, 0, 0.18), 3px 3px 0 rgba(0, 0, 0, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: heroBlockBump var(--hero-scene-anim-duration, 2.2s) steps(2, end) infinite;
}

.hero-scene-block span {
  font-size: 1.35rem;
  color: #fff7db;
  text-shadow: 2px 2px 0 #7f3f10;
}

.hero-scene-mario {
  position: absolute;
  left: 50%;
  bottom: 30px;
  width: 42px;
  height: 54px;
  transform: translate3d(-108px, 0, 0);
  image-rendering: pixelated;
  background: linear-gradient(#b31b1b 0 0) 4px 2px/34px 10px no-repeat, linear-gradient(#f5bd8b 0 0) 11px 12px/20px 12px no-repeat, linear-gradient(#2b3f98 0 0) 10px 24px/22px 17px no-repeat, linear-gradient(#ad1a1a 0 0) 10px 25px/22px 7px no-repeat, linear-gradient(#2f1d12 0 0) 13px 22px/14px 3px no-repeat, linear-gradient(#3f2312 0 0) 10px 41px/9px 9px no-repeat, linear-gradient(#3f2312 0 0) 23px 41px/9px 9px no-repeat;
  animation: heroMarioJump var(--hero-scene-anim-duration, 2.2s) steps(18, end) infinite;
}

@keyframes heroMarioJump {
  0% {
    transform: translate3d(-108px, 0, 0);
  }
  12% {
    transform: translate3d(-76px, -10px, 0);
  }
  21% {
    transform: translate3d(-42px, -24px, 0);
  }
  28% {
    transform: translate3d(0, -62px, 0);
  }
  36% {
    transform: translate3d(24px, -24px, 0);
  }
  48% {
    transform: translate3d(52px, 0, 0);
  }
  72% {
    transform: translate3d(52px, 0, 0);
  }
  100% {
    transform: translate3d(-108px, 0, 0);
  }
}
@keyframes heroBlockBump {
  0%, 24%, 100% {
    transform: translate(-50%, 0);
  }
  28% {
    transform: translate(-50%, -8px);
  }
  34% {
    transform: translate(-50%, 0);
  }
}
.home-hero-main h1 {
  font-size: clamp(2.8rem, 7vw, 4.8rem);
  margin: 0 0 18px;
}

.home-hero .home-hero-copy {
  margin: 0 0 20px;
  color: var(--text-dim);
  max-width: 760px;
  font-size: 1.22rem;
  line-height: 1.35;
}

.home-hero-actions {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 14px;
}

.press-start-btn {
  font-size: 1.05rem;
  letter-spacing: 1.4px;
  border-color: var(--accent);
  color: var(--accent);
  animation: pressStartPulse var(--press-start-pulse-duration, 1s) steps(2, end) infinite;
}

.press-start-btn:hover {
  animation: none;
}

@keyframes pressStartPulse {
  0%, 49% {
    opacity: 1;
  }
  50%, 100% {
    opacity: 0.55;
  }
}
.home-hero-start-wrap {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  align-items: center;
  padding-top: 10px;
  padding-bottom: 4px;
  transform: translate3d(0, var(--hero-start-float-y), 0);
  will-change: transform;
}

.home-hero-secondary {
  padding: 14px 24px;
  border-radius: 0;
}

#homeContentStart {
  margin-top: 0;
}

.markdown-content,
.post-content,
.blog-content {
  line-height: 1.8;
  color: var(--text-main);
}
.markdown-content p,
.post-content p,
.blog-content p {
  margin: 0 0 1rem;
}
.markdown-content ul, .markdown-content ol,
.post-content ul,
.post-content ol,
.blog-content ul,
.blog-content ol {
  margin-left: 2rem;
  margin-bottom: 1.5rem;
  display: block;
}
.markdown-content li,
.post-content li,
.blog-content li {
  margin-bottom: 0.5rem;
  display: list-item;
}
.markdown-content h1, .markdown-content h2, .markdown-content h3, .markdown-content h4, .markdown-content h5, .markdown-content h6,
.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6,
.blog-content h1,
.blog-content h2,
.blog-content h3,
.blog-content h4,
.blog-content h5,
.blog-content h6 {
  margin: 1.2rem 0 0.8rem;
  line-height: 1.2;
  text-transform: none;
  text-shadow: none;
}
.markdown-content blockquote,
.post-content blockquote,
.blog-content blockquote {
  margin: 1.1rem 0;
  padding: 0.7rem 1rem;
  border-left: 4px solid var(--accent);
  background: color-mix(in srgb, var(--card-bg) 65%, transparent);
  color: var(--text-dim);
}
.markdown-content a,
.post-content a,
.blog-content a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.markdown-content code,
.post-content code,
.blog-content code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.9em;
  background: color-mix(in srgb, var(--bg) 75%, black);
  border: 1px solid var(--border);
  padding: 0.08em 0.35em;
}
.markdown-content pre,
.post-content pre,
.blog-content pre {
  overflow-x: auto;
  background: color-mix(in srgb, var(--bg) 75%, black);
  border: 1px solid var(--border);
  padding: 0.9rem;
  margin: 1rem 0 1.2rem;
}
.markdown-content pre code,
.post-content pre code,
.blog-content pre code {
  background: transparent;
  border: 0;
  padding: 0;
}
.markdown-content img,
.post-content img,
.blog-content img {
  max-width: 100%;
  height: auto;
  margin: 20px 0;
  border: 2px solid var(--border);
}

/* --- FOOTER --- */
footer {
  border-top: 1px solid var(--border);
  padding: 40px 0 20px;
  margin-top: 0px;
  background: rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
}

.footer-links h4 {
  color: white;
  margin-bottom: 1.5rem;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 2px;
}

.footer-links a {
  display: block;
  color: var(--text-dim);
  text-decoration: none;
  margin-bottom: 10px;
  font-size: 0.95rem;
  transition: 0.2s;
}

.footer-links a:hover {
  color: var(--accent);
}

/* --- 5. UI ELEMENTS --- */
.chip {
  padding: 8px 16px;
  background: var(--card-bg);
  border: 2px solid var(--border);
  border-radius: 0;
  color: var(--text-dim);
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--ui-transition-speed, 0.18s) var(--ui-transition-ease, ease-out);
  font-size: 1.1rem;
  font-weight: 400;
  text-transform: uppercase;
}

.chip.active, .chip:hover {
  background: var(--accent);
  color: var(--bg);
  border-color: var(--accent);
  box-shadow: 4px 4px 0px rgba(0, 0, 0, 0.5);
  transform: translate(-2px, -2px);
}

/* Slightly smaller nav chips for modern themes only */
html[data-theme=modern-dark] .navbar .chip,
html[data-theme=modern-light] .navbar .chip {
  padding: 6px 13px;
  font-size: 1rem;
}

html[data-theme=modern-dark] body.nav-compact .navbar .chip,
html[data-theme=modern-light] body.nav-compact .navbar .chip {
  padding: 6px 11px;
  font-size: 0.94rem;
}

.theme-select, select {
  padding: 8px 16px;
  background: var(--bg); /* Use darker background */
  border: 2px solid var(--border);
  border-radius: 0;
  color: var(--text-main);
  cursor: pointer;
  font-family: inherit;
  font-size: 1.1rem;
  font-weight: 400;
  text-transform: uppercase;
  outline: none;
  -webkit-appearance: menulist;
  appearance: auto;
  color-scheme: dark;
  transition: all var(--ui-transition-speed, 0.18s) var(--ui-transition-ease, ease-out);
}

.theme-select option,
select option,
select optgroup {
  background: color-mix(in srgb, var(--bg) 90%, #000 10%);
  color: var(--text-main);
}

.theme-select option,
select option {
  padding: 10px;
  text-transform: uppercase;
}

.theme-select option:checked,
select option:checked {
  background: color-mix(in srgb, var(--accent) 72%, var(--bg) 28%);
  color: var(--bg);
}

.theme-select option:hover,
select option:hover {
  background: color-mix(in srgb, var(--accent) 40%, var(--bg) 60%);
  color: var(--text-main);
}

.theme-select:hover, .theme-select:focus, select:hover, select:focus {
  border-color: var(--accent);
  color: var(--text-main);
  box-shadow: 4px 4px 0px rgba(0, 0, 0, 0.5);
  transform: translate(-2px, -2px);
}

/* Progressive enhancement: browsers with full popover-style select support */
@supports (appearance: base-select) {
  .theme-select,
  select {
    appearance: base-select;
  }
  .theme-select::picker(select),
  select::picker(select) {
    border: 2px solid var(--border);
    border-radius: 0;
    background: color-mix(in srgb, var(--bg) 92%, #000 8%);
    color: var(--text-main);
    box-shadow: 6px 6px 0px rgba(0, 0, 0, 0.45);
    padding: 6px;
  }
}
.btn-primary {
  background: var(--accent);
  color: var(--bg);
  padding: 15px 30px;
  border-radius: 0;
  font-weight: 400;
  cursor: pointer;
  border: none;
  transition: all var(--ui-transition-speed, 0.18s) var(--ui-transition-ease, ease-out);
  text-transform: uppercase;
  font-size: 1.3rem;
  box-shadow: 6px 6px 0px rgba(0, 0, 0, 0.5);
  border: 2px solid var(--accent);
}

.btn-primary:hover {
  transform: translate(-2px, -2px);
  box-shadow: 8px 8px 0px rgba(0, 0, 0, 0.5);
  background: #fff;
  color: var(--bg);
}

.badge {
  display: inline-block;
  padding: 5px 10px;
  background: transparent;
  color: var(--accent);
  border-radius: 0;
  font-size: 1rem;
  font-weight: 400;
  text-transform: uppercase;
  margin-bottom: 2rem;
  border: 2px solid var(--accent);
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.5);
}

.go-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 1700;
  padding: 10px 14px;
  border: 2px solid var(--border);
  background: color-mix(in srgb, var(--card-bg) 84%, black);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.95rem;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.35);
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.go-top.visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.go-top:hover {
  border-color: var(--accent);
}

h1 {
  font-size: clamp(3.5rem, 10vw, 6rem);
  font-weight: 400;
  line-height: 0.95;
  letter-spacing: 0px;
  margin-bottom: 2rem;
  text-transform: uppercase;
  text-shadow: var(--text-shadow, 4px 4px 0px #000);
}

h2 {
  font-size: var(--h2-size);
}

h3 {
  font-size: var(--h3-size);
}

h4 {
  font-size: var(--h4-size);
}

h5 {
  font-size: var(--h5-size);
}

h6 {
  font-size: var(--h6-size);
}

.gradient-text {
  background: none;
  -webkit-text-fill-color: var(--accent);
  color: var(--accent);
  text-shadow: 2px 2px 0px var(--bg);
}

.hero p {
  font-size: 1.3rem;
  color: var(--text-dim);
  max-width: 700px;
  margin: 0 auto 3rem;
  line-height: 1.4;
}

/* Grids & Cards */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.card {
  background: var(--card-bg);
  padding: 2rem;
  border-radius: 0;
  border: 2px solid var(--border);
  backdrop-filter: none;
  transition: all var(--ui-transition-speed, 0.18s) var(--ui-transition-ease, ease-out);
  box-shadow: 6px 6px 0px rgba(0, 0, 0, 0.3);
}

.card:hover {
  border-color: var(--accent);
  transform: translate(-2px, -2px);
  box-shadow: 8px 8px 0px rgba(0, 0, 0, 0.3);
}

/* Netflix Carousel */
.carousel {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  padding-bottom: 30px;
  scrollbar-width: none;
}

.poster {
  min-width: 220px;
  aspect-ratio: 2/3;
  background: var(--card-bg);
  border-radius: 0;
  border: 2px solid var(--border);
  transition: 0.3s;
  position: relative;
  overflow: hidden;
}

.poster:hover {
  transform: scale(1.05);
  border-color: var(--accent);
  z-index: 10;
}

.poster-title {
  position: absolute;
  bottom: 0;
  width: 100%;
  padding: 20px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.9));
  font-weight: 800;
  font-size: 0.9rem;
  color: white;
}

/* --- 7. SEARCH MODAL --- */
#searchModal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.92);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(15px);
}

#searchModal.active {
  display: flex;
}

.modal-box {
  width: 90%;
  max-width: 720px;
  max-height: min(86vh, 860px);
  background: var(--bg);
  padding: 28px;
  border-radius: 0;
  border: 2px solid var(--accent);
  box-shadow: 10px 10px 0px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
}

#modalInput {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 4px solid var(--accent);
  font-size: 2.2rem;
  color: var(--accent);
  outline: none;
  padding: 10px 0;
  font-weight: 400;
  font-family: "VT323", monospace;
}

#searchResults {
  margin-top: 16px;
  overflow-y: auto;
  min-height: 100px;
  max-height: calc(86vh - 140px);
  padding-right: 6px;
}

.search-empty {
  color: var(--text-dim);
  padding: 8px 2px;
}

.search-result-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  padding: 10px;
  border: 1px solid var(--border);
  margin-bottom: 8px;
  color: var(--text-main);
  background: rgba(0, 0, 0, 0.2);
}

.search-result-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.search-result-subtitle {
  font-size: 0.85rem;
  color: var(--text-dim);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.search-result-kind {
  font-size: 0.8rem;
  color: var(--accent);
  align-self: center;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .modal-box {
    width: 94%;
    padding: 18px;
    max-height: 88vh;
  }
  #modalInput {
    font-size: 1.6rem;
  }
  #searchResults {
    max-height: calc(88vh - 120px);
  }
}
.home-section-head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.bsky-view-all {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: var(--accent);
  border: 2px solid var(--accent);
  padding: 6px 12px;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  font-size: 0.92rem;
  transition: 0.12s ease;
}

.bsky-view-all:hover {
  background: var(--accent);
  color: var(--bg);
  transform: translate(-1px, -1px);
}

.home-social-links li a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.footer-links #footerSocialLinks {
  display: grid;
  gap: 10px;
}

.footer-links #footerSocialLinks a {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 0;
}

.home-social-links li a i,
.home-social-links li a .social-glyph,
#footerSocialLinks a i,
#footerSocialLinks a .social-glyph {
  width: 18px;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.92rem;
  line-height: 1;
}

.discord-server-list {
  margin-top: 10px;
  display: grid;
  gap: 12px;
}

.discord-join-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #ffffff;
  background: #5865f2;
  border: 1px solid #7584ff;
  border-radius: 10px;
  padding: 9px 12px;
  font-size: 0.92rem;
  font-weight: 700;
  box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.35);
  transition: 0.12s ease;
  margin-top: auto;
}

.discord-join-btn:hover {
  background: #6e7dff;
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.35);
}

.discord-invite-card {
  border: 1px solid color-mix(in srgb, #5865f2 45%, var(--border));
  border-radius: 16px;
  overflow: hidden;
  background: #1f1c31;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.34);
}

.discord-invite-banner {
  height: 72px;
  background: linear-gradient(180deg, #486381 0%, #86a8bf 100%);
}

.discord-invite-content {
  padding: 14px 16px 16px;
  margin-top: -30px;
  display: grid;
  gap: 10px;
  min-height: 250px;
}

.discord-invite-top {
  display: flex;
  gap: 10px;
  align-items: flex-end;
}

.discord-invite-avatar {
  width: 68px;
  height: 68px;
  border-radius: 20px;
  background: #29385f;
  border: 4px solid #1f1c31;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.discord-invite-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.discord-invite-avatar--flame {
  color: #ffb26b;
  font-size: 2.1rem;
  background: radial-gradient(circle at 30% 30%, #4e2e51 0%, #2a203f 100%);
}

.discord-invite-meta h4 {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 1.55rem;
  color: #f2f5ff;
  text-transform: none;
}

.discord-invite-meta h4 i {
  font-size: 0.95rem;
  color: #d5d8e4;
}

.discord-verified {
  font-size: 0.95rem;
  color: #d5d8e4;
}

.discord-flame {
  font-size: 2.1rem;
  line-height: 1;
}

.discord-invite-stats {
  margin: 4px 0 0;
  color: #c4cadf;
  font-size: 0.92rem;
}

.discord-invite-since {
  margin: 2px 0 0;
  color: #c4cadf;
  font-size: 0.92rem;
}

.discord-invite-description {
  margin: 0;
  color: #cfd4e7;
  font-size: 1rem;
  line-height: 1.3;
}

.status-online,
.status-total {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 3px;
  vertical-align: middle;
}

.status-online {
  background: #3ba55c;
}

.status-total {
  background: #9ea4b5;
}

.discord-invite-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.discord-invite-tags span {
  border: 1px solid rgba(230, 233, 245, 0.15);
  color: #d7dcf0;
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 0.9rem;
  line-height: 1;
}

.discord-invite-card--emubro .discord-join-btn {
  background: #0a7d3e;
  border-color: #0ea153;
}

.discord-invite-card--emubro .discord-join-btn:hover {
  background: #0b8a45;
}

.discord-invite-card--urage {
  border-color: color-mix(in srgb, #e6b170 40%, var(--border));
}

.discord-invite-card--urage .discord-invite-banner {
  background: linear-gradient(180deg, #eca95f 0%, #f2df9f 100%);
}

.discord-invite-card--urage .discord-join-btn {
  background: #0a7d3e;
  border-color: #0ea153;
}

.discord-invite-card--urage .discord-join-btn:hover {
  background: #0b8a45;
}

@media (max-width: 640px) {
  .discord-invite-content {
    min-height: 0;
  }
  .discord-invite-meta h4 {
    font-size: 1.35rem;
  }
  .discord-join-btn {
    width: 100%;
  }
}
/* Blog Post Sidebar */
.blog-post-container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.blog-sidebar {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 1.5rem;
  border-radius: 0;
}

.sidebar-section {
  margin-bottom: 1.5rem;
}

.sidebar-section h3 {
  margin-bottom: 1rem;
  font-size: 1.2rem;
  color: var(--accent);
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.5rem;
}

.sidebar-section .sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-section .sidebar-list > li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
}

.sidebar-section .sidebar-list > li:last-child {
  border-bottom: none;
}

.sidebar-section a {
  color: var(--text-main);
  text-decoration: none;
  transition: color 0.3s ease;
}

.sidebar-section a:hover {
  color: var(--accent);
}

/* Responsive layout for blog post */
@media (min-width: 768px) {
  .blog-post-container {
    flex-direction: row;
  }
  .blog-sidebar {
    width: 300px;
    position: sticky;
    top: 2rem;
  }
  .blog-post-content {
    flex: 1;
  }
}
/* --- Admin Multi-Poster --- */
.mp-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(0, 0.82fr);
  gap: 20px;
}

.mp-layout .card {
  padding: 18px;
}

.mp-headline p {
  margin-top: 6px;
  color: var(--text-dim);
  font-size: 0.95rem;
}

.mp-message {
  margin: 0 0 14px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card-bg) 74%, black 26%);
  list-style: none;
  display: grid;
  gap: 6px;
}

.mp-message-error {
  border-color: color-mix(in srgb, #ff6b6b 55%, var(--border));
  color: #ffd4d4;
}

.mp-message-warning {
  border-color: color-mix(in srgb, #f3cc67 55%, var(--border));
  color: #f5e7c4;
}

.mp-platforms {
  margin-top: 10px;
  display: grid;
  gap: 12px;
}

.mp-platform-block {
  border: 1px solid color-mix(in srgb, var(--border) 76%, transparent);
  background: color-mix(in srgb, var(--card-bg) 82%, black 18%);
  padding: 12px;
}

.mp-platform-toggle {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.05rem;
}

.mp-platform-toggle small {
  margin-left: auto;
}

.mp-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 8px;
  border: 1px solid var(--border);
  text-transform: uppercase;
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  color: var(--text-dim);
  background: rgba(0, 0, 0, 0.24);
}

.mp-status-success {
  border-color: color-mix(in srgb, var(--accent) 82%, #3ddb7f);
  color: var(--accent);
}

.mp-status-failed {
  border-color: #ff6b6b;
  color: #ff9f9f;
}

.mp-status-running {
  border-color: #4fc3f7;
  color: #9edfff;
}

.mp-status-queued {
  border-color: #f7cf6b;
  color: #ffe5a6;
}

.mp-platform-panel {
  margin-top: 12px;
  display: none;
}

.mp-help {
  margin: 0 0 10px;
  color: var(--text-dim);
  font-size: 0.86rem;
}

.mp-stack {
  display: grid;
  gap: 8px;
}

.mp-webhook-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.mp-inline-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.mp-danger {
  border-color: #ff6b6b;
  color: #ff9f9f;
}

.mp-danger:hover {
  background: #ff6b6b;
  border-color: #ff6b6b;
  color: #1b0f0f;
}

.mp-field-grid {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.mp-image-grid {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 10px;
}

.mp-image-card {
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card-bg) 80%, black 20%);
  padding: 8px;
  display: grid;
  gap: 8px;
}

.mp-image-card img {
  width: 100%;
  aspect-ratio: 1/1;
  object-fit: cover;
  border: 1px solid var(--border);
}

.mp-image-card .chip {
  font-size: 0.82rem;
  padding: 6px 10px;
}

.mp-actions {
  margin-top: 14px;
}

.mp-results-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}

.mp-jobs-table-wrap {
  border: 1px solid var(--border);
  overflow: auto;
  max-height: 260px;
}

.mp-jobs-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 520px;
}

.mp-jobs-table th,
.mp-jobs-table td {
  padding: 8px;
  text-align: left;
  border-bottom: 1px solid color-mix(in srgb, var(--border) 72%, transparent);
  font-size: 0.86rem;
}

.mp-job-row {
  cursor: pointer;
}

.mp-job-row:hover {
  background: color-mix(in srgb, var(--accent) 16%, transparent);
}

.mp-job-detail {
  margin-top: 14px;
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card-bg) 82%, black 18%);
  padding: 10px;
}

.mp-detail-body {
  margin-top: 8px;
  color: var(--text-main);
}

.mp-job-meta {
  display: grid;
  gap: 5px;
  margin-bottom: 10px;
  font-size: 0.9rem;
}

.mp-result-grid {
  display: grid;
  gap: 10px;
}

.mp-result-card {
  border: 1px solid var(--border);
  background: color-mix(in srgb, var(--card-bg) 84%, black 16%);
  padding: 10px;
}

.mp-result-card header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.mp-result-body {
  display: grid;
  gap: 6px;
  font-size: 0.85rem;
}

.mp-result-body a {
  color: var(--accent);
  overflow-wrap: anywhere;
}

.mp-error-text {
  margin: 0;
  color: #ffd4d4;
}

.mp-spinner {
  width: 14px;
  height: 14px;
  border: 2px solid color-mix(in srgb, var(--border) 70%, transparent);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: mp-spin 0.9s linear infinite;
}

@keyframes mp-spin {
  to {
    transform: rotate(360deg);
  }
}
@media (max-width: 1150px) {
  .mp-layout {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 760px) {
  .mp-field-grid {
    grid-template-columns: 1fr;
  }
  .mp-webhook-row {
    grid-template-columns: 1fr;
  }
}
/* --- 9. TOOLS SPECIFIC --- */
.btn-indicator {
  padding: 5px 10px;
  border: 1px solid var(--border);
  border-radius: 0;
  font-size: 0.8rem;
  color: var(--text-dim);
  transition: 0.1s;
}

.btn-indicator.pressed {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow);
}

.game-list-container {
  display: grid;
  gap: 10px;
}

.games-disclaimer {
  margin-top: 10px;
  padding: 14px 16px;
  border: 2px solid #b3222b;
  background: rgba(146, 24, 33, 0.3);
  color: #ffd8dd;
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.35);
  line-height: 1.35;
}

.games-disclaimer strong {
  color: #ff9ca4;
}

.emulators-disclaimer {
  margin-top: 10px;
  margin-bottom: 18px;
  padding: 14px 16px;
  border: 2px solid #c57f1d;
  background: rgba(191, 124, 23, 0.24);
  color: #ffe3c0;
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.35);
  line-height: 1.35;
}

.emulators-disclaimer strong {
  color: #ffd08a;
}

.emulators-info {
  margin-top: 10px;
  margin-bottom: 20px;
  padding: 14px 16px;
  border: 2px solid color-mix(in srgb, #2d87c7 60%, var(--border));
  background: color-mix(in srgb, #1f5f8b 28%, transparent);
  color: #d6eeff;
  box-shadow: 6px 6px 0 rgba(0, 0, 0, 0.35);
  line-height: 1.35;
}

.emulators-info strong {
  color: #9fd9ff;
}

.games-toolbar h2 {
  margin: 0;
}

.games-controls {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.games-controls .games-control {
  min-width: 150px;
}

.emu-toolbar {
  display: flex;
  gap: 15px;
  align-items: center;
}

.emu-toolbar .emu-control {
  min-width: 220px;
}

.game-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 0;
  transition: 0.2s;
}

.game-row:hover {
  border-color: var(--accent);
}

.game-video-note {
  margin-top: 10px;
  margin-bottom: 0;
  padding: 10px 12px;
  border: 2px solid #c87412;
  background: rgba(191, 115, 18, 0.24);
  color: #ffe3c5;
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.28);
  font-size: 0.9rem;
  line-height: 1.35;
}

.tool-hub-card {
  display: grid;
  grid-template-columns: minmax(92px, 33%) minmax(0, 1fr);
  align-items: stretch;
  overflow: hidden;
  padding: 0;
  min-height: 140px;
}

.tool-hub-card-media {
  display: block;
  min-height: 100%;
  border-right: 1px solid var(--border);
  background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 24%, transparent), color-mix(in srgb, var(--card-bg) 90%, black));
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.tool-hub-card-body {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  padding: 14px 16px;
}

.tool-hub-card-body h3 {
  margin: 0;
}

.tool-hub-card-body p {
  margin: 0;
  color: var(--text-dim);
  line-height: 1.25;
}

.tool-section {
  margin-bottom: 40px;
}

.mobile-menu-toggle {
  display: none;
}

.nav-actions {
  display: flex;
  gap: 15px;
  align-items: center;
}

@media (max-width: 960px) {
  body.nav-compact .navbar {
    height: var(--nav-height);
  }
  body.nav-compact .navbar .logo {
    font-size: 1.6rem;
  }
  body.nav-compact .navbar .logo > span:first-child,
  body.nav-compact .navbar .logo > span:first-child img {
    width: 40px;
    height: 40px;
  }
  body.nav-compact .navbar .chip {
    font-size: 1rem;
    padding: 8px 16px;
  }
  body.nav-compact .navbar .theme-select {
    font-size: 16px;
    padding-top: 8px;
    padding-bottom: 8px;
  }
  .navbar {
    height: var(--nav-height);
    padding: 0;
  }
  .navbar .container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 8px;
    min-height: var(--nav-height);
    position: relative;
  }
  .logo {
    grid-column: 1;
    grid-row: 1;
    order: unset;
    font-size: 1.5rem;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .logo .site-brand-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .logo > span:first-child,
  .logo > span:first-child img {
    width: 40px;
    height: 40px;
  }
  .mobile-menu-toggle {
    display: block;
    grid-column: 3;
    grid-row: 1;
    order: unset;
    width: 42px;
    height: 42px;
    background: color-mix(in srgb, var(--card-bg) 72%, black 28%);
    border: 2px solid var(--border);
    border-radius: 0;
    color: var(--text-main);
    line-height: 0;
    padding: 0;
    cursor: pointer;
    transition: all 0.18s ease;
  }
  .mobile-menu-toggle:hover,
  .mobile-menu-toggle:focus-visible {
    border-color: var(--accent);
    color: var(--accent);
    transform: translate(-1px, -1px);
    box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.35);
    outline: none;
  }
  .mobile-menu-icon,
  .mobile-menu-icon::before,
  .mobile-menu-icon::after {
    display: block;
    width: 18px;
    height: 2px;
    background: currentColor;
    transition: transform 0.22s ease, opacity 0.18s ease, background 0.18s ease;
  }
  .mobile-menu-icon {
    position: relative;
    margin: 0 auto;
  }
  .mobile-menu-icon::before,
  .mobile-menu-icon::after {
    content: "";
    position: absolute;
    left: 0;
  }
  .mobile-menu-icon::before {
    top: -6px;
  }
  .mobile-menu-icon::after {
    top: 6px;
  }
  .mobile-menu-toggle.is-open {
    border-color: var(--accent);
    color: var(--accent);
  }
  .mobile-menu-toggle.is-open .mobile-menu-icon {
    background: transparent;
  }
  .mobile-menu-toggle.is-open .mobile-menu-icon::before {
    transform: translateY(6px) rotate(45deg);
  }
  .mobile-menu-toggle.is-open .mobile-menu-icon::after {
    transform: translateY(-6px) rotate(-45deg);
  }
  .nav-actions {
    grid-column: 2;
    grid-row: 1;
    order: unset;
    width: auto;
    min-width: 0;
    display: flex;
    flex-direction: row;
    gap: 8px;
    margin-top: 0;
    align-items: center;
  }
  .nav-actions .theme-select {
    flex: none;
    width: clamp(88px, 30vw, 130px);
    min-width: 0;
    height: 40px;
    font-size: 16px;
    padding-right: 10px;
    touch-action: manipulation;
  }
  .nav-actions .chip {
    flex: none;
    width: 40px;
    min-width: 40px;
    height: 40px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0;
  }
  #searchButton {
    width: 40px;
    min-width: 40px;
    height: 40px;
    padding: 0;
    font-size: 0;
    text-indent: -9999px;
    position: relative;
    overflow: hidden;
  }
  #searchButton::before {
    content: "🔍";
    text-indent: 0;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: 1rem;
    line-height: 1;
  }
  .nav-menu {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: min(320px, 100vw - 24px);
    position: absolute;
    right: 0;
    top: calc(100% + 10px);
    z-index: 1105;
    padding: 10px;
    border: 1px solid var(--border);
    background: color-mix(in srgb, var(--card-bg) 88%, black 12%);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.38);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px) scale(0.98);
    transform-origin: top right;
    pointer-events: none;
    transition: opacity 0.18s ease, transform 0.2s ease, visibility 0.2s ease;
  }
  .nav-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
  }
  body.nav-compact .nav-actions .chip {
    width: 40px;
    min-width: 40px;
    height: 40px;
    padding: 0;
    font-size: 0;
  }
  body.nav-compact .nav-actions .theme-select {
    width: clamp(88px, 30vw, 130px);
    height: 40px;
  }
  html[data-theme=modern-dark] .nav-actions .theme-select,
  html[data-theme=modern-light] .nav-actions .theme-select {
    width: clamp(96px, 32vw, 128px);
    font-size: 0.9rem;
    padding-left: 8px;
    padding-right: 8px;
  }
  html[data-theme=modern-dark] body.nav-compact .nav-actions .theme-select,
  html[data-theme=modern-light] body.nav-compact .nav-actions .theme-select {
    width: clamp(96px, 32vw, 128px);
    font-size: 0.9rem;
    padding-left: 8px;
    padding-right: 8px;
  }
  .nav-menu .chip {
    width: 100%;
    text-align: center;
    height: 46px;
    font-size: 1.18rem;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .hero h1 {
    font-size: 2.8rem;
  }
  .view {
    padding-top: calc(var(--nav-height) + var(--ticker-height) + 120px);
  }
  #view-home {
    padding-top: calc(var(--nav-height) + var(--ticker-height));
  }
  .view:not(#view-home):not(#view-blog-post) {
    padding-top: calc(var(--nav-height) + var(--ticker-height));
  }
  .home-hero {
    padding: 18px;
    margin: 0;
    min-height: calc(100vh - (var(--nav-height) + var(--ticker-height)));
    min-height: calc(100svh - (var(--nav-height) + var(--ticker-height)));
  }
  .home-hero-grid {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 0 0.4rem;
  }
  .home-hero-main h1 {
    font-size: clamp(2.2rem, 9vw, 3.6rem);
  }
  .home-hero-scene {
    width: min(360px, 96%);
    height: 116px;
  }
  .hero-scene-block {
    width: 40px;
    height: 40px;
    top: 30px;
  }
  .hero-scene-mario {
    transform: translate3d(-96px, 0, 0);
  }
  .home-hero-actions {
    gap: 10px;
  }
  .home-hero-start-wrap {
    padding-top: 14px;
  }
  .go-top {
    right: 12px;
    bottom: 12px;
    padding: 9px 12px;
  }
  .games-toolbar {
    align-items: flex-start;
  }
  .games-toolbar h2 {
    width: 100%;
    font-size: 1.6rem;
  }
  .games-controls {
    width: 100%;
  }
  .games-controls .games-control {
    flex: 1 1 calc(50% - 10px);
    min-width: 140px;
  }
  .emu-toolbar {
    flex-direction: column;
    align-items: stretch !important;
    gap: 10px !important;
  }
  .emu-toolbar .emu-control {
    width: 100%;
    min-width: 0;
  }
}
/* Additional fix for very small screens */
@media (max-width: 768px) {
  .navbar .container {
    padding: 0 10px;
  }
  .hero h1 {
    font-size: 2.5rem;
  }
  .home-hero {
    padding: 14px;
    margin: 0;
    min-height: calc(100vh - (var(--nav-height) + var(--ticker-height)));
    min-height: calc(100svh - (var(--nav-height) + var(--ticker-height)));
  }
  .home-hero-copy {
    font-size: 1.05rem;
  }
  .home-hero-actions .btn-primary,
  .home-hero-actions .home-hero-secondary {
    width: 100%;
    text-align: center;
  }
  .home-hero-scene {
    width: min(320px, 98%);
    height: 106px;
    margin-bottom: 12px;
  }
  .hero-scene-cloud {
    transform: scale(0.9);
    transform-origin: top left;
  }
  .hero-scene-block {
    width: 36px;
    height: 36px;
    top: 26px;
  }
  .hero-scene-block span {
    font-size: 1.1rem;
  }
  .hero-scene-mario {
    width: 36px;
    height: 46px;
    transform: translate3d(-88px, 0, 0);
    background: linear-gradient(#b31b1b 0 0) 4px 1px/28px 9px no-repeat, linear-gradient(#f5bd8b 0 0) 9px 10px/18px 11px no-repeat, linear-gradient(#2b3f98 0 0) 8px 21px/20px 14px no-repeat, linear-gradient(#ad1a1a 0 0) 8px 22px/20px 6px no-repeat, linear-gradient(#2f1d12 0 0) 11px 19px/12px 3px no-repeat, linear-gradient(#3f2312 0 0) 8px 35px/8px 8px no-repeat, linear-gradient(#3f2312 0 0) 20px 35px/8px 8px no-repeat;
  }
  .view:not(#view-home) h1.hero {
    font-size: clamp(1.9rem, 8vw, 2.7rem);
  }
  .view:not(#view-home):not(#view-blog-post) > .page-hero h1 {
    font-size: clamp(1.9rem, 8vw, 2.7rem);
  }
  .games-controls .games-control {
    flex: 1 1 100%;
    min-width: 0;
  }
}
@media (max-width: 480px) {
  .navbar .container {
    padding: 0 5px;
  }
  .nav-actions .theme-select {
    min-width: 90px;
    font-size: 0.8rem;
    padding: 5px 10px;
  }
  .nav-actions .chip {
    width: 36px;
    min-width: 36px;
    height: 36px;
    font-size: 0;
    padding: 0;
  }
  .logo {
    font-size: 1.4rem;
  }
  .logo > span:first-child,
  .logo > span:first-child img {
    width: 32px;
    height: 32px;
  }
}
/* Third media view for smallest width devices */
@media (max-width: 360px) {
  .navbar .container {
    padding: 0 5px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 4px;
  }
  .logo {
    grid-column: 1;
    font-size: 1.2rem;
    gap: 4px;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .logo .site-brand-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .logo > span:first-child,
  .logo > span:first-child img {
    width: 28px;
    height: 28px;
  }
  .mobile-menu-toggle {
    grid-column: 3;
    grid-row: 1;
    order: unset;
    width: 36px;
    height: 36px;
    padding: 0;
  }
  .nav-actions {
    grid-column: 2;
    grid-row: 1;
    order: unset;
    width: auto;
    margin-top: 0;
    gap: 5px;
  }
  .nav-actions .theme-select {
    display: none;
  }
  .nav-actions .chip {
    min-width: 32px;
    padding: 0;
    font-size: 0;
  }
  .nav-menu {
    width: min(300px, 100vw - 16px);
    right: 0;
    top: calc(100% + 8px);
  }
  /* Hide text from search button on smallest screens */
  #searchButton {
    text-indent: -9999px;
    position: relative;
    width: 32px;
    min-width: 32px;
    padding: 0;
  }
  #searchButton::before {
    content: "🔍";
    text-indent: 0;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: 1rem;
  }
}