/* ==========================================================================
   ShulkerHub v3 — 3D Voxel Depth, Animated Pixel Sprites, Enchantment Glint,
   Nether Portal Vortex, SGA Runes & Authentic Minecraft Inventory UI
   ========================================================================== */

:root {
  --bg-canvas: #07090d;
  --bg-surface: #0f141c;
  --bg-card: #151c27;
  --bg-card-hover: #1b2534;
  --bg-input: #090d12;
  --bg-glass: rgba(10, 14, 20, 0.88);

  --border-subtle: #1f2a3a;
  --border-default: #2d3c52;
  --border-strong: #435978;
  --border-color: #1f2a3a;

  --accent-emerald: #1bd96a;
  --accent-emerald-dark: #0e8a3e;
  --accent-emerald-soft: rgba(27, 217, 106, 0.15);
  --accent-emerald-glow: rgba(27, 217, 106, 0.35);

  --accent-nether: #a855f7;
  --accent-nether-dark: #6b21a8;
  --accent-nether-soft: rgba(168, 85, 247, 0.18);
  --accent-amethyst: #a855f7;
  --accent-amethyst-soft: rgba(168, 85, 247, 0.18);

  --accent-gold: #f59e0b;
  --accent-gold-soft: rgba(245, 158, 11, 0.16);

  --accent-redstone: #ef4444;
  --accent-redstone-soft: rgba(239, 68, 68, 0.16);

  --accent-diamond: #38bdf8;
  --accent-diamond-soft: rgba(56, 189, 248, 0.16);

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;

  --container: 1280px;
  /* Deep 3D Voxel Block Shadow */
  --shadow-voxel-card: 0 6px 0 #06080c, 0 18px 38px -6px rgba(0, 0, 0, 0.7);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-canvas);
  background-image:
    radial-gradient(circle at 18% 8%, rgba(168, 85, 247, 0.14), transparent 38%),
    radial-gradient(circle at 82% 14%, rgba(27, 217, 106, 0.12), transparent 38%),
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 100% 100%, 100% 100%, 32px 32px, 32px 32px;
  color: var(--text-primary);
  font-family: var(--font-sans), sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s ease;
}

button, input, select {
  font-family: inherit;
  color: inherit;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 2;
}

/* ==========================================================================
   Ambient Background Particle Canvas (End Rods, Portal Sparks & XP Orbs)
   ========================================================================== */
#ambient-mc-particles {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 1;
  opacity: 0.75;
}

/* ==========================================================================
   Minecraft Enchantment Glint Shimmer Effect
   ========================================================================== */
@keyframes enchantGlintMove {
  0% { background-position: -220% 0; }
  100% { background-position: 220% 0; }
}

.enchanted-glint {
  position: relative;
  overflow: hidden;
}

.enchanted-glint::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    115deg,
    transparent 25%,
    rgba(192, 132, 252, 0.28) 42%,
    rgba(56, 189, 248, 0.32) 50%,
    rgba(232, 121, 249, 0.28) 58%,
    transparent 75%
  );
  background-size: 220% 100%;
  animation: enchantGlintMove 5s linear infinite;
  pointer-events: none;
}

/* ==========================================================================
   Sticky Header & Animated Shulker Box Brand
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  border-bottom: 2px solid var(--border-subtle);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  height: 70px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  font-weight: 900;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
}

.brand-shulker {
  width: 38px;
  height: 38px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 2px;
  border-radius: 7px;
  background: #08060c;
  border: 2px solid #a855f7;
  box-shadow: 0 4px 0 #4c1d95, 0 0 20px rgba(168, 85, 247, 0.45);
}

@keyframes shulkerPeek {
  0%, 100% { transform: translateY(0); }
  45%, 65% { transform: translateY(-4px); }
}

.shulker-lid-top {
  height: 13px;
  background: linear-gradient(180deg, #d8b4fe 0%, #9333ea 100%);
  border-radius: 4px 4px 2px 2px;
  border-bottom: 2px solid #581c87;
  animation: shulkerPeek 4s ease-in-out infinite;
}

@keyframes shulkerBlink {
  0%, 92%, 100% { transform: scaleY(1); }
  95% { transform: scaleY(0.15); }
}

.shulker-core-eyes {
  height: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: #09050f;
}

.shulker-core-eyes::before,
.shulker-core-eyes::after {
  content: "";
  width: 4px;
  height: 4px;
  background: #fde047;
  box-shadow: 0 0 8px #facc15;
  border-radius: 1px;
  animation: shulkerBlink 3.6s infinite;
}

.shulker-lid-bottom {
  height: 11px;
  background: linear-gradient(180deg, #7e22ce 0%, #581c87 100%);
  border-radius: 2px 2px 4px 4px;
}

.brand:hover .shulker-lid-top {
  transform: translateY(-5px) !important;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 900;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
  flex-shrink: 0;
  white-space: nowrap;
}

.brand-version {
  font-family: var(--font-mono), monospace;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.2rem 0.55rem;
  border-radius: 5px;
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.25), rgba(27, 217, 106, 0.2));
  color: #e9d5ff;
  border: 1px solid rgba(192, 132, 252, 0.5);
  box-shadow: 0 2px 0 #3b0764;
  flex-shrink: 0;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-shrink: 1;
  min-width: 0;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  padding: 0.42rem 0.62rem;
  border-radius: var(--radius-xs);
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-secondary);
  border: 1px solid transparent;
  transition: all 0.15s ease;
  white-space: nowrap;
  flex-shrink: 0;
  line-height: 1.2;
}

.nav-link .nav-icon {
  font-size: 0.95rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
  background: var(--bg-card);
  border-color: var(--border-default);
  box-shadow: 0 3px 0 #070a0f;
  transform: translateY(-1px);
}

.nav-link.active {
  color: var(--accent-emerald);
  border-color: rgba(27, 217, 106, 0.45);
}

@keyframes redstoneTorchPulse {
  0%, 100% { box-shadow: 0 0 8px #f59e0b, 0 0 16px #ef4444; transform: scale(1); }
  50% { box-shadow: 0 0 14px #fde047, 0 0 24px #f59e0b; transform: scale(1.22); }
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: #fde047;
  border: 1px solid #ef4444;
  animation: redstoneTorchPulse 1.6s ease-in-out infinite;
  flex-shrink: 0;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

/* Mobile Nav Toggle Button */
.mobile-nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  width: 38px;
  height: 38px;
  background: var(--bg-card);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-xs);
  color: var(--text-primary);
  cursor: pointer;
  box-shadow: 0 3px 0 #06080c;
  transition: all 0.15s ease;
  padding: 0;
}

.mobile-nav-toggle:hover {
  border-color: var(--accent-emerald);
  background: var(--bg-card-hover);
}

.hamburger-bar {
  width: 18px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.mobile-nav-toggle.open .hamburger-bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.mobile-nav-toggle.open .hamburger-bar:nth-child(2) {
  opacity: 0;
}

.mobile-nav-toggle.open .hamburger-bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* Mobile Nav Dropdown Panel & Backdrop */
.mobile-nav-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(4, 6, 9, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 95;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.mobile-nav-backdrop.open {
  opacity: 1;
  visibility: visible;
}

.mobile-nav-drawer {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  width: 100%;
  max-height: calc(100dvh - 72px);
  background: #0d1217;
  background: linear-gradient(180deg, #10161d 0%, #0a0e13 100%);
  border-bottom: 2px solid var(--accent-emerald);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.85);
  z-index: 99;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-12px);
  transition: opacity 0.22s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.22s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.22s ease;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0.65rem 0.85rem 1rem;
}

.mobile-nav-drawer.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.mobile-drawer-header {
  display: none;
}

.mobile-drawer-close {
  display: none;
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  padding: 0.25rem 0;
  gap: 0.45rem;
  flex: 1;
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.75rem 0.95rem;
  border-radius: var(--radius-xs);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  text-decoration: none;
  transition: all 0.15s ease;
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
  background: var(--bg-card-hover);
  border-color: var(--accent-emerald);
  box-shadow: 0 3px 0 #06080c;
  transform: translateX(3px);
}

.mobile-nav-link.active {
  border-left: 3px solid var(--accent-emerald);
}

.mobile-nav-icon {
  font-size: 1.3rem;
  line-height: 1;
  flex-shrink: 0;
}

.mobile-nav-text {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.mobile-nav-text strong {
  font-size: 0.92rem;
  font-weight: 700;
  color: #fff;
}

.mobile-nav-text small {
  font-size: 0.74rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mobile-drawer-footer {
  padding: 0.85rem 0.25rem 0.25rem;
  border-top: 1px solid var(--border-subtle);
  margin-top: 0.35rem;
}

.mobile-lang-title {
  font-size: 0.72rem;
  font-family: var(--font-mono), monospace;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.mobile-lang-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

.mobile-lang-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.55rem 0.4rem;
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xs);
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 2px 0 #06080c;
  transition: all 0.15s ease;
}

.mobile-lang-btn:hover {
  color: #fff;
  border-color: var(--border-strong);
  background: var(--bg-card-hover);
}

.mobile-lang-btn.active {
  border-color: var(--accent-emerald);
  background: rgba(27, 217, 106, 0.14);
  color: var(--accent-emerald);
  box-shadow: 0 2px 0 #0d8b41;
}

/* ==========================================================================
   Language Selector Dropdown (Extensible for Multi-Language Expansion)
   ========================================================================== */
.lang-dropdown {
  position: relative;
  display: inline-block;
}

.lang-dropdown-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.65rem;
  background: var(--bg-card);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-xs);
  color: var(--text-primary);
  font-family: var(--font-mono), monospace;
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 3px 0 #06080c;
  transition: all 0.15s ease;
  user-select: none;
}

.lang-dropdown-btn:hover,
.lang-dropdown.open .lang-dropdown-btn {
  border-color: var(--accent-emerald);
  background: var(--bg-card-hover);
  color: #fff;
}

.lang-dropdown-btn .lang-flag {
  font-size: 0.95rem;
  line-height: 1;
}

.lang-dropdown-btn .lang-code {
  letter-spacing: 0.5px;
}

.lang-dropdown-btn .lang-chevron {
  transition: transform 0.2s ease;
  color: var(--text-muted);
}

.lang-dropdown.open .lang-chevron {
  transform: rotate(180deg);
  color: var(--accent-emerald);
}

.lang-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 170px;
  background: #061e10;
  border: 2px solid var(--accent-emerald);
  border-radius: var(--radius-xs);
  padding: 0.35rem;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.7), 0 0 16px rgba(27, 217, 106, 0.15);
  display: none;
  flex-direction: column;
  gap: 2px;
  z-index: 1000;
  animation: menuDrop 0.15s ease-out;
}

.lang-dropdown.open .lang-menu {
  display: flex;
}

/* Dropup variation (e.g. in Footer) */
.lang-dropdown.dropup .lang-menu {
  top: auto;
  bottom: calc(100% + 6px);
  left: 0;
  right: auto;
  animation: menuDropUp 0.15s ease-out;
}

.lang-dropdown.dropup .lang-chevron {
  transform: rotate(180deg);
}

.lang-dropdown.dropup.open .lang-chevron {
  transform: rotate(0deg);
}

.lang-current-label {
  font-family: var(--font-sans), sans-serif;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-left: 0.2rem;
}

.lang-dropdown-btn:hover .lang-current-label,
.lang-dropdown.open .lang-current-label {
  color: #fff;
}

@keyframes menuDrop {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes menuDropUp {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.lang-menu-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.45rem 0.65rem;
  color: var(--text-secondary);
  font-size: 0.84rem;
  font-weight: 600;
  text-decoration: none;
  border-radius: 3px;
  transition: all 0.12s ease;
}

.lang-menu-item:hover {
  background: rgba(27, 217, 106, 0.14);
  color: #fff;
  transform: translateX(2px);
}

.lang-menu-item.active {
  background: var(--accent-emerald);
  color: #04190c;
  font-weight: 800;
}

.lang-menu-item .lang-flag {
  font-size: 1rem;
}

.lang-menu-item .lang-label {
  flex: 1;
}

.lang-menu-item .lang-check {
  font-weight: 900;
  font-size: 0.85rem;
}

.lang-switch {
  display: inline-flex;
  background: var(--bg-input);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-xs);
  padding: 2px;
  box-shadow: 0 3px 0 #06080c;
}

.lang-pill {
  padding: 0.25rem 0.6rem;
  font-size: 0.78rem;
  font-weight: 800;
  font-family: var(--font-mono), monospace;
  border-radius: 4px;
  color: var(--text-secondary);
}

.lang-pill.active {
  background: var(--accent-emerald);
  color: #04190c;
}

/* ==========================================================================
   3D Voxel-Bevel Buttons & Badges
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.7rem 1.3rem;
  border-radius: var(--radius-xs);
  font-weight: 800;
  font-size: 0.92rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: transform 0.1s ease, box-shadow 0.1s ease, background 0.15s ease;
  position: relative;
  max-width: 100%;
  text-align: center;
  box-sizing: border-box;
}

.btn-emerald {
  background: linear-gradient(180deg, #2ef07b 0%, var(--accent-emerald) 100%);
  color: #03170a;
  border-color: #6ee7b7;
  box-shadow: 0 5px 0 var(--accent-emerald-dark), 0 8px 20px rgba(27, 217, 106, 0.35);
}

.btn-emerald:hover {
  transform: translateY(-2px);
  box-shadow: 0 7px 0 var(--accent-emerald-dark), 0 12px 26px rgba(27, 217, 106, 0.5);
}

.btn-emerald:active {
  transform: translateY(3px);
  box-shadow: 0 2px 0 var(--accent-emerald-dark);
}

.btn-secondary {
  background: linear-gradient(180deg, #1e2938 0%, #141c27 100%);
  color: var(--text-primary);
  border: 2px solid var(--border-default);
  box-shadow: 0 5px 0 #070a0f;
}

.btn-secondary:hover {
  border-color: var(--accent-emerald);
  transform: translateY(-2px);
  box-shadow: 0 7px 0 #070a0f, 0 0 16px rgba(27, 217, 106, 0.2);
}

.btn-secondary:active {
  transform: translateY(3px);
  box-shadow: 0 2px 0 #070a0f;
}

.btn-sm {
  padding: 0.4rem 0.85rem;
  font-size: 0.8rem;
  box-shadow: 0 3px 0 #06080c;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  padding: 0.22rem 0.65rem;
  border-radius: 6px;
  font-family: var(--font-mono), monospace;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.45);
}

.badge-emerald {
  background: var(--accent-emerald-soft);
  color: var(--accent-emerald);
  border: 1px solid rgba(27, 217, 106, 0.4);
}

.badge-nether {
  background: var(--accent-nether-soft);
  color: #d8b4fe;
  border: 1px solid rgba(168, 85, 247, 0.45);
}

.badge-gold {
  background: var(--accent-gold-soft);
  color: #fde047;
  border: 1px solid rgba(245, 158, 11, 0.45);
}

.badge-diamond {
  background: var(--accent-diamond-soft);
  color: var(--accent-diamond);
  border: 1px solid rgba(56, 189, 248, 0.45);
}

/* ==========================================================================
   3D Isometric Spinning & Opening Shulker Box Stage + Hero Showcase
   ========================================================================== */
.hero-section {
  padding: 2.5rem 0 1.75rem;
}

.bento-hero {
  display: grid;
  grid-template-columns: 7fr 5fr;
  gap: 1.5rem;
  align-items: stretch;
}

.hero-main-card {
  background:
    radial-gradient(circle at 85% 35%, rgba(168, 85, 247, 0.22), transparent 52%),
    linear-gradient(155deg, #16202e 0%, #0d131c 100%);
  border: 2px solid var(--border-default);
  border-top-color: #3d526f;
  border-radius: var(--radius-lg);
  padding: 2.25rem;
  display: grid;
  grid-template-columns: 1fr 210px;
  gap: 1.5rem;
  align-items: center;
  box-shadow: var(--shadow-voxel-card);
  position: relative;
  overflow: hidden;
}

/* Floating Standard Galactic Alphabet (Enchanting Table Runes) */
@keyframes floatRuneUp {
  0% { transform: translateY(20px) scale(0.8); opacity: 0; }
  30% { opacity: 0.55; }
  80% { opacity: 0.45; }
  100% { transform: translateY(-95px) scale(1.15); opacity: 0; }
}

.sga-rune {
  position: absolute;
  font-family: var(--font-mono), monospace;
  color: #c084fc;
  text-shadow: 0 0 10px #a855f7;
  pointer-events: none;
  user-select: none;
  font-size: 1rem;
  animation: floatRuneUp 5.5s ease-in-out infinite;
}

/* 3D Isometric Voxel Shulker Scene */
.shulker-3d-stage {
  width: 195px;
  height: 220px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  perspective: 750px;
  cursor: pointer;
  position: relative;
  user-select: none;
}

.shulker-3d-stage-hint {
  font-family: var(--font-mono), monospace;
  font-size: 0.68rem;
  color: #c084fc;
  background: rgba(15, 20, 28, 0.85);
  border: 1px solid rgba(168, 85, 247, 0.4);
  padding: 0.18rem 0.5rem;
  border-radius: 4px;
  margin-top: 1.25rem;
  text-align: center;
  box-shadow: 0 2px 0 #05070a;
}

@keyframes spinShulker3D {
  0%   { transform: rotateX(-22deg) rotateY(25deg); }
  50%  { transform: rotateX(-18deg) rotateY(205deg); }
  100% { transform: rotateX(-22deg) rotateY(385deg); }
}

@keyframes liftShulkerLid3D {
  0%, 15%, 85%, 100% { transform: translateY(0px) rotateY(0deg); }
  40%, 65% { transform: translateY(-28px) rotateY(90deg); }
}

.shulker-cube-assembly {
  width: 96px;
  height: 96px;
  position: relative;
  transform-style: preserve-3d;
  animation: spinShulker3D 14s linear infinite;
}

.shulker-3d-stage.overcharged .shulker-cube-assembly {
  animation-duration: 4s;
}

.shulker-lid-3d {
  width: 96px;
  height: 54px;
  position: absolute;
  top: 0;
  left: 0;
  transform-style: preserve-3d;
  animation: liftShulkerLid3D 5.2s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.shulker-3d-stage:hover .shulker-lid-3d,
.shulker-3d-stage.overcharged .shulker-lid-3d {
  transform: translateY(-34px) rotateY(135deg) !important;
}

.shulker-base-3d {
  width: 96px;
  height: 48px;
  position: absolute;
  bottom: 0;
  left: 0;
  transform-style: preserve-3d;
}

.voxel-face {
  position: absolute;
  image-rendering: pixelated;
  border: 2px solid #3b0764;
}

/* Top Lid Faces */
.shulker-lid-3d .face-front  { width: 96px; height: 54px; transform: translateZ(48px); background: repeating-linear-gradient(90deg, #9333ea 0 12px, #a855f7 12px 24px); border-bottom: 4px dashed #581c87; }
.shulker-lid-3d .face-back   { width: 96px; height: 54px; transform: rotateY(180deg) translateZ(48px); background: repeating-linear-gradient(90deg, #7e22ce 0 12px, #9333ea 12px 24px); }
.shulker-lid-3d .face-right  { width: 96px; height: 54px; transform: rotateY(90deg) translateZ(48px); background: repeating-linear-gradient(90deg, #86198f 0 12px, #a21caf 12px 24px); }
.shulker-lid-3d .face-left   { width: 96px; height: 54px; transform: rotateY(-90deg) translateZ(48px); background: repeating-linear-gradient(90deg, #6b21a8 0 12px, #7e22ce 12px 24px); }
.shulker-lid-3d .face-top    { width: 96px; height: 96px; transform: rotateX(90deg) translateZ(48px); background: radial-gradient(circle, #d8b4fe 20%, #9333ea 75%); border: 4px solid #7e22ce; }

/* Bottom Base Faces */
.shulker-base-3d .face-front { width: 96px; height: 48px; transform: translateZ(48px); background: linear-gradient(180deg, #581c87 0%, #3b0764 100%); }
.shulker-base-3d .face-back  { width: 96px; height: 48px; transform: rotateY(180deg) translateZ(48px); background: #3b0764; }
.shulker-base-3d .face-right { width: 96px; height: 48px; transform: rotateY(90deg) translateZ(48px); background: #4c1d95; }
.shulker-base-3d .face-left  { width: 96px; height: 48px; transform: rotateY(-90deg) translateZ(48px); background: #4c1d95; }
.shulker-base-3d .face-bottom{ width: 96px; height: 96px; transform: rotateX(-90deg) translateZ(0px); background: #1e0536; box-shadow: 0 0 35px rgba(168, 85, 247, 0.8); }

/* Glowing Inner Shulker Mob Head + Nether Star Core */
@keyframes corePulse3D {
  0%, 100% { transform: translateZ(0) scale(0.95); filter: drop-shadow(0 0 10px #fde047); }
  50% { transform: translateZ(0) scale(1.12); filter: drop-shadow(0 0 22px #1bd96a); }
}

.shulker-inner-mob {
  position: absolute;
  width: 44px;
  height: 44px;
  top: 26px;
  left: 26px;
  background: #fef08a;
  border: 4px solid #ca8a04;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 4px;
  animation: corePulse3D 2.2s ease-in-out infinite;
}

.shulker-inner-mob::before,
.shulker-inner-mob::after {
  content: "";
  width: 8px;
  height: 8px;
  background: #09050f;
  border-top: 3px solid #fde047;
}

.hero-title {
  font-size: clamp(1.8rem, 3vw, 2.55rem);
  font-weight: 900;
  line-height: 1.13;
  letter-spacing: -0.03em;
  margin: 0.75rem 0;
  text-shadow: 0 3px 0 #05070a;
}

.hero-subtitle {
  color: var(--text-secondary);
  font-size: 1rem;
  max-width: 60ch;
  margin-bottom: 1.25rem;
}

/* Shulker 27-Slot Hotbar with Bobbing Item Physics */
.shulker-slots-strip {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1.35rem;
  padding: 0.6rem;
  background: #080b10;
  border: 2px solid #3b4c66;
  border-radius: var(--radius-xs);
  box-shadow: inset 0 3px 6px rgba(0, 0, 0, 0.75), 0 4px 0 #05070a;
}

@keyframes mcItemBob {
  0%, 100% { transform: translateY(0px) rotate(-2deg); }
  50% { transform: translateY(-4px) rotate(3deg); }
}

.mc-bob-icon {
  display: inline-block;
  animation: mcItemBob 2.4s ease-in-out infinite;
  filter: drop-shadow(0 3px 3px rgba(0, 0, 0, 0.65));
}

.shulker-slot {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.65rem;
  background: linear-gradient(180deg, #1b2432 0%, #111722 100%);
  border: 2px solid #2e3d52;
  border-top-color: #475d7a;
  border-radius: 5px;
  font-family: var(--font-mono), monospace;
  font-size: 0.74rem;
  color: var(--text-secondary);
  box-shadow: 0 3px 0 #06080c;
  transition: transform 0.12s ease, border-color 0.12s ease;
}

.shulker-slot:hover {
  transform: translateY(-2px);
  border-color: #c084fc;
  color: var(--text-primary);
}

.shulker-slot.slot-active {
  border-color: var(--accent-emerald);
  background: linear-gradient(180deg, rgba(27, 217, 106, 0.22), rgba(16, 150, 72, 0.12));
  color: var(--accent-emerald);
  font-weight: 800;
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-bottom: 1.35rem;
}

/* Minecraft Green XP Level 30 Bar inside Hero */
@keyframes xpShimmer {
  0% { background-position: 0 50%; }
  100% { background-position: 200% 50%; }
}

.mc-xp-bar-wrap {
  margin-top: 0.75rem;
}

.mc-xp-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-mono), monospace;
  font-size: 0.75rem;
  margin-bottom: 0.3rem;
}

.mc-xp-level {
  color: #84cc16;
  font-weight: 900;
  text-shadow: 0 2px 0 #000, 0 0 10px rgba(132, 204, 22, 0.6);
}

.mc-xp-track {
  height: 10px;
  background: #070a0d;
  border: 2px solid #1e293b;
  border-radius: 3px;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.8);
}

.mc-xp-fill {
  height: 100%;
  width: 82%;
  background: repeating-linear-gradient(
    90deg,
    #4ade80 0px,
    #22c55e 18px,
    #15803d 18px,
    #15803d 20px
  );
  box-shadow: 0 0 12px #22c55e;
}

.hero-side-card {
  background:
    radial-gradient(circle at 90% 10%, rgba(245, 158, 11, 0.15), transparent 45%),
    linear-gradient(160deg, rgba(168, 85, 247, 0.16) 0%, #121923 100%);
  border: 2px solid var(--border-default);
  border-top-color: #5b3e85;
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-voxel-card);
  position: relative;
  overflow: hidden;
}

/* ==========================================================================
   Animated Pixel-Art SVG Portal & Item Sprites
   ========================================================================== */
@keyframes portalSwirlPulse {
  0%, 100% { filter: hue-rotate(0deg) drop-shadow(0 0 8px #a855f7); transform: scale(1); }
  50% { filter: hue-rotate(22deg) drop-shadow(0 0 15px #e879f9); transform: scale(1.06); }
}

.pixel-portal-sprite {
  width: 44px;
  height: 52px;
  flex-shrink: 0;
  animation: portalSwirlPulse 3s ease-in-out infinite;
}

/* ==========================================================================
   Live Countdown Timer Component (3D Voxel Slots)
   ========================================================================== */
.countdown-box {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.55rem;
  margin: 1rem 0;
}

.cd-segment {
  background: var(--bg-input);
  border: 2px solid var(--border-default);
  border-top-color: #3e526e;
  border-radius: var(--radius-xs);
  padding: 0.55rem 0.35rem;
  text-align: center;
  box-shadow: 0 4px 0 #05070a;
}

.cd-num {
  display: block;
  font-family: var(--font-mono), monospace;
  font-size: 1.32rem;
  font-weight: 900;
  color: #fde047;
  text-shadow: 0 2px 0 #713f12, 0 0 10px rgba(250, 204, 21, 0.35);
  line-height: 1.1;
}

.cd-label {
  font-size: 0.68rem;
  text-transform: uppercase;
  color: var(--text-muted);
  font-family: var(--font-mono), monospace;
}

/* TBA Live Status Radar Box */
.tba-radar-box {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: rgba(16, 26, 38, 0.85);
  border: 2px solid rgba(56, 189, 248, 0.3);
  border-left: 4px solid var(--accent-diamond);
  border-radius: var(--radius-xs);
  padding: 0.7rem 0.85rem;
  margin: 1rem 0;
  box-shadow: 0 4px 0 #05070a;
}

.tba-radar-pulse {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent-diamond);
  box-shadow: 0 0 10px var(--accent-diamond);
  animation: radarBeaconPulse 2s infinite ease-in-out;
  flex-shrink: 0;
}

@keyframes radarBeaconPulse {
  0%, 100% {
    transform: scale(0.85);
    opacity: 0.6;
    box-shadow: 0 0 6px var(--accent-diamond);
  }
  50% {
    transform: scale(1.3);
    opacity: 1;
    box-shadow: 0 0 16px var(--accent-diamond), 0 0 24px rgba(56, 189, 248, 0.5);
  }
}

.tba-radar-info {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.tba-radar-title {
  font-family: var(--font-mono), monospace;
  font-size: 0.76rem;
  font-weight: 800;
  color: #38bdf8;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.tba-radar-sub {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.35;
}

/* ==========================================================================
   Workbench Layout: Nether Portal Calculator & Animated Portal Vortex
   ========================================================================== */
.workbench-section {
  padding: 1.5rem 0 2.5rem;
}

.workbench-grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: 1.5rem;
  align-items: start;
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

.panel-card {
  background: var(--bg-surface);
  border: 2px solid var(--border-default);
  border-top-color: #3b4f6b;
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-voxel-card);
  position: relative;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}

.panel-card-promo {
  padding: 2.2rem;
  background: linear-gradient(180deg, #101c15 0%, #070e0a 100%);
  border-color: var(--accent-emerald);
}

/* Sponsored Partner Card (Apex Hosting) */
.sponsor-card {
  background: linear-gradient(180deg, #101720 0%, #090e14 100%);
  border: 2px solid #223244;
  border-top-color: var(--accent-emerald);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
  margin-top: 1rem;
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
}

.sponsor-card::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 110px;
  height: 110px;
  background: radial-gradient(circle, rgba(27, 217, 106, 0.1) 0%, transparent 70%);
  pointer-events: none;
}

.sponsor-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--accent-emerald);
  background: rgba(27, 217, 106, 0.1);
  border: 1px solid rgba(27, 217, 106, 0.25);
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  margin-bottom: 0.65rem;
}

.sponsor-title {
  font-size: 1.02rem;
  font-weight: 800;
  color: var(--text-primary);
  margin: 0 0 0.45rem 0;
  line-height: 1.3;
}

.sponsor-desc {
  font-size: 0.83rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0 0 0.95rem 0;
}

.sponsor-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.6rem 0.9rem;
  font-size: 0.86rem;
  font-weight: 800;
  color: #041b0d !important;
  background: var(--accent-emerald);
  border-radius: var(--radius-sm);
  box-shadow: 0 3px 0 #0d8b41;
  text-decoration: none;
  transition: transform 0.1s ease, box-shadow 0.1s ease, background 0.15s ease;
  box-sizing: border-box;
}

.sponsor-btn:hover {
  background: #25e877;
  color: #041b0d !important;
}

.sponsor-btn:active {
  transform: translateY(2px);
  box-shadow: 0 1px 0 #0d8b41;
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--border-subtle);
  min-width: 0;
}

.edition-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
  background: var(--bg-input);
  padding: 0.3rem;
  border-radius: var(--radius-xs);
  border: 2px solid var(--border-subtle);
  margin-bottom: 1.15rem;
}

.edition-btn {
  padding: 0.48rem 0.65rem;
  border-radius: 5px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
}

.edition-btn.active {
  background: var(--bg-card-hover);
  color: var(--accent-emerald);
  border: 1px solid rgba(27, 217, 106, 0.45);
  box-shadow: 0 2px 0 #05070a;
}

.dim-block {
  background: var(--bg-card);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 1.1rem;
  margin-bottom: 1rem;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.4);
}

@keyframes netherPortalGlow {
  0%, 100% { border-color: rgba(168, 85, 247, 0.55); box-shadow: 0 0 18px rgba(168, 85, 247, 0.15); }
  50% { border-color: rgba(232, 121, 249, 0.85); box-shadow: 0 0 28px rgba(168, 85, 247, 0.32); }
}

.dim-block.nether-theme {
  background:
    radial-gradient(circle at 90% 20%, rgba(168, 85, 247, 0.2), transparent 55%),
    linear-gradient(180deg, rgba(168, 85, 247, 0.09), var(--bg-card));
  animation: netherPortalGlow 4s ease-in-out infinite;
}

.dim-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.dim-title {
  font-weight: 800;
  font-size: 0.95rem;
}

.dim-hint {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-family: var(--font-mono), monospace;
}

.xyz-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
}

.coord-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.coord-label {
  font-family: var(--font-mono), monospace;
  font-size: 0.75rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.axis-tag {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 2px;
}

.axis-x { background: #ef4444; box-shadow: 0 0 6px #ef4444; }
.axis-y { background: #22c55e; box-shadow: 0 0 6px #22c55e; }
.axis-z { background: #38bdf8; box-shadow: 0 0 6px #38bdf8; }

.coord-input {
  width: 100%;
  background: var(--bg-input);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-xs);
  padding: 0.6rem 0.65rem;
  font-family: var(--font-mono), monospace;
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-primary);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.75);
}

.coord-input:focus {
  outline: none;
  border-color: var(--accent-emerald);
  box-shadow: 0 0 0 3px var(--accent-emerald-soft);
}

.status-banner {
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-xs);
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 1rem;
  background: var(--accent-emerald-soft);
  color: var(--accent-emerald);
  border: 1px solid rgba(27, 217, 106, 0.38);
}

.status-banner.warn {
  background: var(--accent-redstone-soft);
  color: #fca5a5;
  border-color: rgba(239, 68, 68, 0.45);
}

.cmd-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  padding: 0.5rem 0.75rem;
  margin-top: 0.55rem;
  font-family: var(--font-mono), monospace;
  font-size: 0.78rem;
  color: var(--text-secondary);
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}

.cmd-row code {
  flex: 1;
  min-width: 0;
  white-space: normal;
  word-break: break-all;
  overflow-wrap: anywhere;
  line-height: 1.45;
  user-select: all;
}

.cmd-row .btn {
  flex-shrink: 0;
}

.radar-controls {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
  align-items: center;
}

/* Canvas Radar Panel */
.canvas-wrapper {
  position: relative;
  background: #06080c;
  border: 2px solid var(--border-default);
  border-radius: var(--radius-sm);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  min-height: 300px;
  max-width: 100%;
  box-shadow: inset 0 0 30px rgba(168, 85, 247, 0.18);
}

#portal-radar-canvas {
  width: 100%;
  height: 100%;
  display: block;
  cursor: crosshair;
  touch-action: pan-y;
}

.canvas-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.85rem;
}

.radar-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  font-size: 0.78rem;
  color: var(--text-secondary);
  font-family: var(--font-mono), monospace;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.legend-swatch {
  width: 10px;
  height: 10px;
  border-radius: 2px;
}

.collision-box {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-subtle);
}

/* Voxel Circle & Sphere Generator Styles */
.coord-slider {
  -webkit-appearance: none;
  appearance: none;
  height: 8px;
  background: var(--bg-input);
  border: 1px solid var(--border-default);
  border-radius: 4px;
  outline: none;
  cursor: pointer;
}

.coord-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  background: var(--accent-emerald);
  border: 2px solid #06080c;
  border-radius: 4px;
  box-shadow: 0 0 8px rgba(27, 217, 106, 0.6);
  cursor: pointer;
  transition: transform 0.15s ease;
}

.coord-slider::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

.btn-xs {
  padding: 0.25rem 0.5rem;
  font-size: 0.72rem;
  font-family: var(--font-mono), monospace;
}

.custom-checkbox {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
}

.custom-checkbox input[type="checkbox"] {
  accent-color: var(--accent-emerald);
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.stat-mini-card {
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  padding: 0.55rem 0.75rem;
  text-align: center;
}

.stat-mini-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  font-family: var(--font-mono), monospace;
  margin-bottom: 0.2rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stat-mini-val {
  font-family: var(--font-mono), monospace;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
}

/* ==========================================================================
   3D Voxel Content Cards with Interactive Tilt & Depth
   ========================================================================== */
.section-block {
  padding: 2.6rem 0;
  border-top: 1px solid var(--border-subtle);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.section-title {
  font-size: 1.65rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  text-shadow: 0 2px 0 #05070a;
}

.section-sub {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 68ch;
  margin-top: 0.25rem;
}

.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-bottom: 1.5rem;
}

.tab-btn {
  padding: 0.48rem 0.95rem;
  border-radius: var(--radius-xs);
  background: var(--bg-card);
  border: 2px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.84rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 3px 0 #06080c;
  transition: transform 0.12s ease, border-color 0.12s ease;
}

.tab-btn.active,
.tab-btn:hover {
  background: var(--accent-emerald-soft);
  color: var(--accent-emerald);
  border-color: rgba(27, 217, 106, 0.5);
  transform: translateY(-2px);
}

.cards-grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.35rem;
}

.cards-grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(440px, 1fr));
  gap: 1.35rem;
}

.content-card {
  --rx: 0deg;
  --ry: 0deg;
  background: linear-gradient(165deg, #18212e 0%, #111822 100%);
  border: 2px solid var(--border-default);
  border-top-color: #3b4f6b;
  border-radius: var(--radius-md);
  padding: 1.55rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
  box-shadow: var(--shadow-voxel-card);
  transition: transform 0.18s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.18s ease, box-shadow 0.18s ease;
  transform-style: preserve-3d;
  position: relative;
}

.content-card:hover {
  transform: translateY(-5px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  border-color: #a855f7;
  box-shadow: 0 10px 0 #06080c, 0 24px 44px -6px rgba(168, 85, 247, 0.25);
}

.card-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.card-thumb-wrap {
  border-radius: var(--radius-xs);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  background: var(--bg-input);
  aspect-ratio: 16 / 9;
  margin-bottom: 0.85rem;
}

.card-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.25s ease;
}

.content-card:hover .card-thumb-img {
  transform: scale(1.03);
}

.card-title {
  font-size: 1.22rem;
  font-weight: 800;
  line-height: 1.3;
  margin: 0.45rem 0;
}

.card-desc {
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.feature-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin: 0.5rem 0;
  font-size: 0.86rem;
  color: var(--text-secondary);
}

.feature-list li::before {
  content: "✦ ";
  color: var(--accent-emerald);
  font-weight: 800;
}

/* ==========================================================================
   Authentic Minecraft Inventory Item Tooltip (#100010 + Purple Pixel Frame)
   ========================================================================== */
#mc-item-tooltip {
  position: fixed;
  pointer-events: none;
  z-index: 9999;
  background: rgba(16, 0, 16, 0.94);
  border: 2px solid #5000ff;
  outline: 2px solid #100010;
  box-shadow: inset 0 0 0 1px #28007f, 0 10px 25px rgba(0, 0, 0, 0.85);
  padding: 0.55rem 0.75rem;
  border-radius: 3px;
  font-family: var(--font-mono), monospace;
  font-size: 0.78rem;
  line-height: 1.4;
  max-width: 290px;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.12s ease, transform 0.12s ease;
}

#mc-item-tooltip.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (hover: none), (max-width: 980px) {
  #mc-item-tooltip {
    display: none !important;
  }
}

.mc-tt-title {
  color: #55ffff;
  font-weight: 800;
  text-shadow: 1px 1px 0 #003f3f;
  margin-bottom: 0.15rem;
}

.mc-tt-lore {
  color: #aa00aa;
  font-style: italic;
  text-shadow: 1px 1px 0 #2a002a;
}

.mc-tt-stat {
  color: #55ff55;
  margin-top: 0.25rem;
  font-weight: 700;
  text-shadow: 1px 1px 0 #153f15;
}

/* ==========================================================================
   Article, Guide & SEO Content Styling
   ========================================================================== */
.reader-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 2.25rem;
  align-items: start;
  padding: 2rem 0 3.5rem;
}

.prose-card {
  background: var(--bg-surface);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 2.25rem;
  box-shadow: var(--shadow-voxel-card);
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}

.reader-layout > * {
  min-width: 0;
  max-width: 100%;
}

.prose-card h1 {
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  line-height: 1.2;
  margin: 0.75rem 0 1rem;
}

.prose-card h2 {
  font-size: 1.4rem;
  margin: 2rem 0 0.75rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-primary);
}

.prose-card h3 {
  font-size: 1.15rem;
  margin: 1.5rem 0 0.5rem;
  color: var(--accent-emerald);
}

.prose-card p,
.prose-card li {
  color: var(--text-secondary);
  margin-bottom: 0.85rem;
  font-size: 1rem;
}

.prose-card ul,
.prose-card ol {
  padding-left: 1.35rem;
  margin-bottom: 1.1rem;
}

.prose-card code {
  font-family: var(--font-mono), monospace;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.88em;
  color: var(--accent-emerald);
  word-break: break-word;
  overflow-wrap: anywhere;
}

.prose-card pre {
  background: var(--bg-input);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xs);
  padding: 0.9rem 1.1rem;
  margin: 1.1rem 0;
  overflow-x: auto;
  max-width: 100%;
  box-sizing: border-box;
}

.prose-card pre code {
  background: none;
  border: none;
  padding: 0;
  color: var(--accent-emerald);
  font-family: var(--font-mono), monospace;
  font-size: 0.86rem;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-all;
  overflow-wrap: anywhere;
  display: block;
}

.formula-callout {
  background: var(--bg-input);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 1.1rem;
  margin: 1.25rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  max-width: 100%;
  overflow-x: auto;
  box-sizing: border-box;
}

.formula-callout code {
  word-break: break-word;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}

.article-hero-wrap {
  margin: 1.25rem 0 1.5rem;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 2px solid var(--border-default);
  background: var(--bg-input);
  box-shadow: var(--shadow-voxel-card);
  aspect-ratio: 16 / 9;
  max-height: 480px;
}

.article-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.tldr-box {
  background: linear-gradient(90deg, var(--accent-emerald-soft), rgba(16, 21, 28, 0.9));
  border-left: 4px solid var(--accent-emerald);
  border-radius: var(--radius-xs);
  padding: 1.1rem 1.25rem;
  margin: 1.25rem 0 1.75rem;
  max-width: 100%;
  box-sizing: border-box;
  overflow-wrap: anywhere;
}

.tldr-label {
  font-family: var(--font-mono), monospace;
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--accent-emerald);
  margin-bottom: 0.3rem;
}


.formula-title {
  font-size: 0.78rem;
  font-family: var(--font-mono), monospace;
  color: var(--text-muted);
  text-transform: uppercase;
}

.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
  margin: 1.25rem 0;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.data-table th,
.data-table td {
  border: 1px solid var(--border-subtle);
  padding: 0.7rem 0.9rem;
  text-align: left;
}

.data-table th {
  background: var(--bg-card);
  color: var(--text-primary);
  font-weight: 700;
}

.sticky-sidebar {
  position: sticky;
  top: 88px;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.toc-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-top: 0.75rem;
}

.toc-list a {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.toc-list a:hover {
  color: var(--accent-emerald);
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
  font-size: 0.82rem;
  color: var(--text-muted);
  padding: 1.25rem 0 0.25rem;
  font-family: var(--font-mono), monospace;
}

.breadcrumbs a:hover {
  color: var(--accent-emerald);
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

.faq-item {
  background: var(--bg-card);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  box-shadow: 0 4px 0 #06080c;
}

.faq-item summary {
  font-weight: 800;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-item summary::after {
  content: "+";
  font-family: var(--font-mono), monospace;
  color: var(--accent-emerald);
  font-size: 1.1rem;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-answer {
  margin-top: 0.75rem;
  color: var(--text-secondary);
  font-size: 0.94rem;
}

/* Footer */
.site-footer {
  margin-top: auto;
  border-top: 2px solid var(--border-subtle);
  background: #05070b;
  padding: 3rem 0 2rem;
  position: relative;
  z-index: 2;
}

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

.footer-title {
  font-size: 0.85rem;
  font-family: var(--font-mono), monospace;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: 0.85rem;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

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

.footer-contact {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.85rem;
  font-size: 0.88rem;
  min-height: 1.5rem;
}

.footer-contact-label {
  color: var(--text-muted);
}

.footer-contact-link {
  color: var(--accent-emerald);
  font-family: var(--font-mono), monospace;
  font-size: 0.84rem;
  text-decoration: none;
  border-bottom: 1px dashed rgba(27, 217, 106, 0.45);
  transition: color 0.15s ease, border-color 0.15s ease;
}

.footer-contact-link:hover,
.footer-contact-link:focus-visible {
  color: #4ade80;
  border-bottom-color: #4ade80;
}

.footer-bottom {
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.8rem;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-legal-links {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.footer-legal-link {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.15s ease;
}

.footer-legal-link:hover,
.footer-legal-link:focus-visible {
  color: var(--accent-emerald);
}

@media (max-width: 1220px) {
  .brand-version {
    display: none;
  }
  .header-inner {
    gap: 0.5rem;
  }
  .nav-link {
    padding: 0.38rem 0.48rem;
    font-size: 0.82rem;
    gap: 0.25rem;
  }
}

@media (max-width: 1020px) {
  .main-nav {
    display: none;
  }
  .mobile-nav-toggle {
    display: inline-flex;
  }
}

@media (max-width: 980px) {
  .bento-hero,
  .hero-main-card,
  .workbench-grid,
  .reader-layout,
  .footer-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .shulker-3d-stage {
    order: -1;
    margin: 0.25rem auto 1.5rem;
  }
  .cards-grid-2,
  .cards-grid-3 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 1rem;
  }
  .panel-card {
    padding: 1.15rem 1rem;
  }
  .prose-card {
    padding: 1.35rem 1rem;
  }
  .panel-card-promo {
    padding: 1.35rem 1rem;
  }
  .hero-main-card {
    padding: 1.5rem 1.15rem;
  }
  .hero-cta-row,
  .promo-cta-row {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 0.65rem;
  }
  .hero-cta-row .btn,
  .promo-cta-row .btn {
    width: 100%;
    text-align: center;
    justify-content: center;
    white-space: normal;
    padding: 0.75rem 1rem;
  }
}

@media (max-width: 540px) {
  .container {
    padding: 0 0.75rem;
  }
  .header-inner {
    height: 62px;
  }
  .brand {
    font-size: 1.1rem;
    gap: 0.5rem;
  }
  .brand-shulker {
    width: 32px;
    height: 32px;
  }
  .shulker-3d-stage {
    width: 170px;
    height: 190px;
    margin: 0 auto 1.15rem;
  }
  .shulker-3d-stage-hint {
    margin-top: 0.95rem;
    font-size: 0.65rem;
  }
  .lang-dropdown-btn {
    padding: 0.3rem 0.45rem;
    font-size: 0.76rem;
  }
  .panel-card {
    padding: 0.95rem 0.75rem;
  }
  .prose-card {
    padding: 1.1rem 0.85rem;
  }
  .tldr-box {
    padding: 0.9rem 0.85rem;
  }
  .dim-block {
    padding: 0.85rem 0.65rem;
  }
  .xyz-row {
    gap: 0.45rem;
  }
  .coord-input {
    padding: 0.5rem 0.35rem;
    font-size: 0.88rem;
    text-align: center;
  }
  .coord-label {
    font-size: 0.7rem;
  }
  .cmd-row {
    flex-direction: column;
    align-items: stretch;
    gap: 0.45rem;
  }
  .cmd-row code {
    width: 100%;
    word-break: break-all;
    overflow-wrap: anywhere;
    white-space: normal;
    padding: 0.25rem 0;
  }
  .canvas-wrapper {
    min-height: 220px;
    aspect-ratio: 4 / 3;
  }
  .cmd-row .btn {
    width: 100%;
    text-align: center;
    justify-content: center;
  }
  .radar-controls {
    width: 100%;
  }
  .radar-controls .btn {
    flex: 1;
    padding: 0.42rem 0.35rem;
    font-size: 0.74rem;
    text-align: center;
  }
}

/* ==========================================================================
   Parents & Family Hub & Minecraft Glossary Styles
   ========================================================================== */
.parents-facts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin: 2rem 0;
}

.parent-fact-card {
  background: var(--bg-card);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 1.25rem;
  box-shadow: 0 4px 0 #06080c;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.parent-fact-icon {
  font-size: 2rem;
  line-height: 1;
}

.parent-fact-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

.parent-fact-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
}

/* Glossary Controls */
.glossary-controls-bar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  background: var(--bg-card);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 1.25rem;
  margin-bottom: 2rem;
  box-shadow: 0 4px 0 #06080c;
}

.glossary-search-input-wrap {
  position: relative;
  width: 100%;
}

.glossary-search-input {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 2.5rem;
  background: var(--bg-input);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-xs);
  color: #fff;
  font-family: var(--font-sans), sans-serif;
  font-size: 0.95rem;
  transition: border-color 0.15s ease;
}

.glossary-search-input:focus {
  outline: none;
  border-color: var(--accent-emerald);
}

.glossary-search-icon {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

.glossary-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.glossary-filter-pill {
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.glossary-filter-pill:hover,
.glossary-filter-pill.active {
  background: rgba(27, 217, 106, 0.18);
  border-color: var(--accent-emerald);
  color: #fff;
}

.glossary-filter-pill.active {
  font-weight: 700;
  box-shadow: 0 0 10px rgba(27, 217, 106, 0.2);
}

.glossary-stats-bar {
  font-family: var(--font-mono), monospace;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Glossary Cards */
.glossary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 1.5rem;
}

.glossary-card {
  background: var(--bg-card);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 1.4rem;
  box-shadow: 0 4px 0 #06080c;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.glossary-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-2px);
}

.glossary-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.5rem;
}

.glossary-term-title {
  font-size: 1.2rem;
  font-weight: 800;
  color: #fff;
  margin: 0;
}

.glossary-term-aka {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-family: var(--font-mono), monospace;
  margin-top: 0.2rem;
}

.glossary-def-text {
  font-size: 0.92rem;
  color: var(--text-primary);
  line-height: 1.55;
  margin: 0;
}

.glossary-quote-box {
  background: rgba(234, 179, 8, 0.08);
  border-left: 3px solid #eab308;
  border-radius: 0 var(--radius-xs) var(--radius-xs) 0;
  padding: 0.65rem 0.85rem;
}

.glossary-quote-label {
  font-size: 0.72rem;
  font-family: var(--font-mono), monospace;
  text-transform: uppercase;
  color: #eab308;
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.glossary-quote-text {
  font-size: 0.88rem;
  font-style: italic;
  color: #fef08a;
  margin: 0;
  line-height: 1.4;
}

.glossary-tip-box {
  background: rgba(27, 217, 106, 0.08);
  border-left: 3px solid var(--accent-emerald);
  border-radius: 0 var(--radius-xs) var(--radius-xs) 0;
  padding: 0.65rem 0.85rem;
}

.glossary-tip-label {
  font-size: 0.72rem;
  font-family: var(--font-mono), monospace;
  text-transform: uppercase;
  color: var(--accent-emerald);
  font-weight: 700;
  margin-bottom: 0.25rem;
}

.glossary-tip-text {
  font-size: 0.86rem;
  color: #a7f3d0;
  margin: 0;
  line-height: 1.45;
}

@media (max-width: 768px) {
  .parents-facts-grid,
  .glossary-grid,
  .dict-entries-list {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================================
   Compact Dictionary & General Gaming Terms Glossary Styles
   ========================================================================== */
.dict-alphabet-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xs);
  padding: 0.75rem 1rem;
}

.dict-letter-btn {
  width: 2rem;
  height: 2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: var(--text-primary);
  font-family: var(--font-mono), monospace;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.12s ease;
}

.dict-letter-btn:hover,
.dict-letter-btn.active {
  background: var(--accent-emerald);
  border-color: var(--accent-emerald);
  color: #041b0d;
}

.dict-entries-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(420px, 1fr));
  gap: 1rem;
}

.dict-entry-card {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-left: 3px solid var(--accent-emerald);
  border-radius: var(--radius-xs);
  padding: 1rem 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.dict-entry-card:hover {
  border-color: var(--accent-emerald);
  transform: translateX(2px);
}

.dict-entry-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
}

.dict-entry-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
  margin: 0;
}

.dict-entry-def {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}

.dict-entry-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.35rem;
  font-size: 0.76rem;
}

/* ==========================================================================
   Tool #4: Anvil Enchantment Optimizer Component Styles
   ========================================================================== */

.cat-tab-btn {
  padding: 0.35rem 0.65rem;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border-subtle);
  background: var(--bg-input);
  color: var(--text-secondary);
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.cat-tab-btn:hover {
  border-color: var(--accent-emerald);
  color: var(--text-primary);
}

.cat-tab-btn.active {
  border-color: var(--accent-emerald);
  background: rgba(27, 217, 106, 0.15);
  color: var(--accent-emerald);
}

.penalty-pill-btn {
  padding: 0.4rem 0.2rem;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border-subtle);
  background: var(--bg-input);
  color: var(--text-muted);
  font-family: var(--font-mono), monospace;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.penalty-pill-btn:hover {
  border-color: var(--accent-amethyst);
  color: var(--text-primary);
}

.penalty-pill-btn.active {
  border-color: var(--accent-amethyst);
  background: rgba(168, 85, 247, 0.18);
  color: #fff;
  box-shadow: 0 0 8px rgba(168, 85, 247, 0.3);
}

.item-grid-selector {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(95px, 1fr));
  gap: 0.45rem;
  margin-top: 0.55rem;
  max-height: 220px;
  overflow-y: auto;
  padding-right: 0.25rem;
}

.item-select-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  padding: 0.45rem 0.3rem;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  color: var(--text-secondary);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.item-select-btn:hover {
  border-color: var(--accent-emerald);
  color: var(--text-primary);
  background: rgba(27, 217, 106, 0.08);
}

.item-select-btn.active {
  border-color: var(--accent-emerald);
  background: rgba(27, 217, 106, 0.18);
  color: #fff;
  box-shadow: 0 0 10px rgba(27, 217, 106, 0.25);
}

.item-btn-icon {
  font-size: 1.25rem;
  line-height: 1;
}

.item-btn-name {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.enchants-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  max-height: 380px;
  overflow-y: auto;
  padding-right: 0.35rem;
}

.enchant-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.45rem 0.65rem;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  transition: all 0.15s ease;
}

.enchant-row:hover:not(.disabled) {
  border-color: rgba(27, 217, 106, 0.4);
}

.enchant-row.selected {
  border-color: var(--accent-emerald);
  background: rgba(27, 217, 106, 0.08);
}

.enchant-row.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  filter: grayscale(0.6);
}

.enchant-toggle-label {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  flex: 1;
  min-width: 0;
}

.enchant-checkbox {
  width: 1.1rem;
  height: 1.1rem;
  accent-color: var(--accent-emerald);
  cursor: pointer;
}

.enchant-meta {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.enchant-name {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.conflict-notice {
  font-size: 0.72rem;
  color: var(--accent-redstone);
  font-weight: 600;
}

.enchant-actions {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.enchant-levels-group {
  display: flex;
  gap: 0.2rem;
  background: rgba(0, 0, 0, 0.3);
  padding: 0.15rem;
  border-radius: 4px;
}

.ench-lvl-btn {
  padding: 0.15rem 0.4rem;
  border: 1px solid transparent;
  border-radius: 3px;
  background: transparent;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-family: var(--font-mono), monospace;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.ench-lvl-btn:hover {
  color: var(--text-primary);
}

.ench-lvl-btn.active {
  background: var(--accent-emerald);
  color: #0b0e11;
  border-color: var(--accent-emerald);
}

.single-level-badge {
  font-size: 0.72rem;
  font-family: var(--font-mono), monospace;
  color: var(--text-muted);
  background: rgba(0, 0, 0, 0.3);
  padding: 0.15rem 0.4rem;
  border-radius: 3px;
}

/* Anvil Display Simulator */
.anvil-display-box {
  background: linear-gradient(180deg, #18202a 0%, #10161d 100%);
  border: 2px solid var(--border-default);
  border-top-color: #4b6282;
  border-radius: var(--radius-sm);
  padding: 1rem 1.15rem;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.5);
}

.anvil-slots-row {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.anvil-slot {
  flex: 1;
  min-width: 110px;
  background: #090c0f;
  border: 2px solid #2d3b4d;
  border-radius: var(--radius-xs);
  padding: 0.65rem 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.7);
}

.anvil-slot.highlight {
  border-color: var(--accent-emerald);
  background: rgba(27, 217, 106, 0.08);
  box-shadow: inset 0 0 12px rgba(27, 217, 106, 0.2), 0 0 8px rgba(27, 217, 106, 0.2);
}

.slot-title {
  font-size: 0.68rem;
  text-transform: uppercase;
  color: var(--text-muted);
  font-family: var(--font-mono), monospace;
}

.slot-item {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-primary);
  word-break: break-word;
}

.slot-item.highlight {
  color: var(--accent-emerald);
}

.anvil-math-op {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-muted);
}

.anvil-cost-readout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 0.75rem;
  padding-top: 0.6rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--font-mono), monospace;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* Combining Steps List */
.combining-steps-container {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  max-height: 480px;
  overflow-y: auto;
  padding-right: 0.25rem;
}

.combine-step-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--accent-emerald);
  border-radius: var(--radius-xs);
  padding: 0.75rem 0.9rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.combine-step-card:hover {
  border-color: var(--accent-emerald);
  background: rgba(27, 217, 106, 0.04);
}

.combine-step-card.active {
  border-color: var(--accent-emerald);
  background: rgba(27, 217, 106, 0.09);
  box-shadow: 0 0 12px rgba(27, 217, 106, 0.15);
}

.step-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.45rem;
}

.step-badge {
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--accent-emerald);
  font-family: var(--font-mono), monospace;
}

.step-cost-badge {
  background: rgba(27, 217, 106, 0.2);
  border: 1px solid var(--accent-emerald);
  color: var(--accent-emerald);
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  font-size: 0.78rem;
  font-weight: 800;
  font-family: var(--font-mono), monospace;
}

.step-combine-formula {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  font-size: 0.82rem;
  line-height: 1.4;
}

.combine-slot {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  background: rgba(0, 0, 0, 0.25);
  padding: 0.3rem 0.5rem;
  border-radius: 4px;
  flex: 1;
  min-width: 90px;
}

.combine-slot.god-item {
  border: 1px solid var(--accent-emerald);
  background: rgba(27, 217, 106, 0.12);
}

.slot-role {
  font-size: 0.65rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

.slot-name {
  font-weight: 700;
  color: var(--text-primary);
}

.plus-sign, .arrow-sign {
  font-weight: 800;
  color: var(--text-muted);
}

.step-footer-breakdown {
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
  margin-top: 0.45rem;
  padding-top: 0.35rem;
  border-top: 1px dashed rgba(255, 255, 255, 0.08);
  font-size: 0.72rem;
  color: var(--text-muted);
  font-family: var(--font-mono), monospace;
}

.step-footer-breakdown strong {
  color: var(--text-secondary);
}

.empty-state-notice {
  text-align: center;
  padding: 2.5rem 1rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}


/* ==========================================================================
   COLOR CODE, MOTD & RGB GRADIENT STYLER WORKBENCH
   ========================================================================== */

.color-mode-tabs {
  display: flex;
  gap: 0.5rem;
  background: rgba(0, 0, 0, 0.35);
  padding: 0.3rem;
  border-radius: 8px;
  border: 1px solid var(--border-subtle);
}

.mc-input-area {
  width: 100%;
  background: #080c0f;
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  color: var(--text-primary);
  font-family: var(--font-mono), monospace;
  font-size: 0.92rem;
  padding: 0.75rem;
  resize: vertical;
  line-height: 1.5;
  transition: border-color 0.15s ease;
}

.mc-input-area:focus {
  outline: none;
  border-color: var(--accent-emerald);
  box-shadow: 0 0 0 2px rgba(27, 217, 106, 0.15);
}

.format-toggles-bar {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.format-btn {
  background: #141c24;
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  border-radius: 4px;
  padding: 0.4rem 0.75rem;
  font-size: 0.88rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  transition: all 0.15s ease;
}

.format-btn:hover {
  background: #1e2834;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.2);
}

.format-btn.active {
  background: rgba(27, 217, 106, 0.2);
  border-color: var(--accent-emerald);
  color: var(--accent-emerald);
  font-weight: 700;
}

.format-btn-reset {
  margin-left: auto;
  color: var(--accent-redstone, #ef4444);
}

.format-btn-reset:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: #ef4444;
}

.gradient-panel-wrap {
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 8px;
  padding: 1rem;
}

.gradient-pickers-row {
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.picker-unit {
  flex: 1;
  min-width: 100px;
}

.picker-sublabel {
  display: block;
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.35rem;
}

.picker-field {
  display: flex;
  align-items: center;
  background: #080c0f;
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 0.25rem 0.4rem;
}

.color-picker-native {
  -webkit-appearance: none;
  appearance: none;
  border: none;
  width: 100%;
  height: 34px;
  border-radius: 4px;
  cursor: pointer;
  background: none;
}

.color-picker-native::-webkit-color-swatch-wrapper {
  padding: 0;
}

.color-picker-native::-webkit-color-swatch {
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}

.presets-pills-wrap {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.preset-pill {
  background: #141c24;
  border: 1px solid var(--border-subtle);
  border-radius: 20px;
  color: var(--text-secondary);
  font-size: 0.76rem;
  padding: 0.3rem 0.65rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.preset-pill:hover {
  background: #1e2936;
  border-color: var(--accent-emerald);
  color: #fff;
  transform: translateY(-1px);
}

.swatches-grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 0.4rem;
}

@media (max-width: 600px) {
  .swatches-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.swatch-btn {
  height: 38px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-family: var(--font-mono), monospace;
  font-size: 0.8rem;
  font-weight: 800;
  color: #000;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.4);
  transition: transform 0.1s ease, box-shadow 0.15s ease;
}

.swatch-btn.dark-bg {
  color: #fff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8);
}

.swatch-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  z-index: 2;
}

/* Preview Tabs */
.preview-tabs-bar {
  display: flex;
  gap: 0.3rem;
  background: rgba(0, 0, 0, 0.4);
  padding: 0.25rem;
  border-radius: 6px;
  border: 1px solid var(--border-subtle);
}

.preview-tab-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.35rem 0.65rem;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.preview-tab-btn:hover {
  color: var(--text-primary);
}

.preview-tab-btn.active {
  background: #1a2530;
  color: var(--accent-emerald);
}

/* View 1: Server List MOTD */
.mc-server-card {
  background: #11151a;
  border: 2px solid #202b36;
  border-radius: 4px;
  padding: 0.85rem;
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.6);
}

.mc-server-icon {
  width: 64px;
  height: 64px;
  background: #070a0d;
  border: 2px solid #2c3a49;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

.mc-server-info {
  flex: 1;
  min-width: 0;
}

.mc-server-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.35rem;
}

.mc-server-title {
  font-family: var(--font-mono), monospace;
  font-weight: 700;
  font-size: 0.95rem;
  color: #fff;
}

.mc-server-stats {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.mc-player-count {
  font-family: var(--font-mono), monospace;
  font-size: 0.82rem;
  color: #aaa;
}

.mc-ping-bars {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 14px;
  width: 14px;
}

.mc-ping-bars i {
  display: block;
  width: 2px;
  background: #22c55e;
  border-radius: 1px;
}

.mc-ping-bars i:nth-child(1) { height: 25%; }
.mc-ping-bars i:nth-child(2) { height: 45%; }
.mc-ping-bars i:nth-child(3) { height: 65%; }
.mc-ping-bars i:nth-child(4) { height: 85%; }
.mc-ping-bars i:nth-child(5) { height: 100%; }

.mc-font {
  font-family: "Minecraftia", "Courier New", Courier, monospace;
  letter-spacing: 0.04em;
  line-height: 1.45;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.85);
}

.mc-motd-body {
  font-size: 0.92rem;
  min-height: 2.9rem;
  word-break: break-word;
}

/* View 2: In-Game Chat Box */
.mc-chat-card {
  background: rgba(0, 0, 0, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  padding: 1.25rem 1rem;
  min-height: 100px;
  display: flex;
  align-items: flex-end;
}

.mc-chat-line {
  font-size: 0.95rem;
  word-break: break-word;
}

.mc-chat-timestamp {
  color: #aaa;
  margin-right: 0.35rem;
  font-family: var(--font-mono), monospace;
}

.mc-chat-sender {
  color: #fff;
  font-weight: 700;
  margin-right: 0.4rem;
}

/* View 3: Wooden Hanging Sign */
.mc-sign-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.mc-sign-chains {
  display: flex;
  justify-content: space-around;
  width: 180px;
  height: 18px;
}

.mc-chain {
  width: 6px;
  height: 100%;
  background: repeating-linear-gradient(
    0deg,
    #475569 0px,
    #475569 4px,
    #1e293b 4px,
    #1e293b 8px
  );
  border-radius: 2px;
}

.mc-hanging-board {
  width: 100%;
  max-width: 440px;
  min-height: 120px;
  background: #a16207 linear-gradient(180deg, #b45309 0%, #78350f 100%);
  border: 4px solid #451a03;
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6), inset 0 2px 4px rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  text-align: center;
  transition: all 0.2s ease;
}

.mc-hanging-board.glow-ink-active .mc-sign-content {
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.85), 0 0 20px currentColor, 2px 2px 0 #000;
}

.mc-sign-content {
  font-size: 0.92rem;
  word-break: break-word;
  max-width: 100%;
}

.mc-sign-controls-row {
  margin-top: 0.6rem;
}

/* Formatting classes */
.mc-bold { font-weight: 700; }
.mc-italic { font-style: italic; }
.mc-underline { text-decoration: underline; }
.mc-strikethrough { text-decoration: line-through; }
.mc-obfuscated {
  display: inline-block;
  animation: mc-jitter 0.1s steps(2) infinite;
}

@keyframes mc-jitter {
  0% { transform: translate(0, 0); }
  50% { transform: translate(1px, -1px); }
  100% { transform: translate(-1px, 1px); }
}

.mc-select-compact {
  background: #141c24;
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  border-radius: 4px;
  padding: 0.35rem 0.6rem;
  font-size: 0.8rem;
  cursor: pointer;
}

.mc-select-compact:focus {
  outline: none;
  border-color: var(--accent-emerald);
}

.mc-code-output {
  width: 100%;
  background: #070a0d;
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  color: #1bd96a;
  font-family: var(--font-mono), monospace;
  font-size: 0.85rem;
  padding: 0.75rem;
  resize: vertical;
  line-height: 1.45;
}

.mc-code-output:focus {
  outline: none;
  border-color: var(--accent-emerald);
}

/* Spawn Sphere & Despawn Radar Tool */
.status-verdict {
  padding: 0.75rem 0.9rem;
  border-radius: var(--radius-xs);
  font-size: 0.84rem;
  line-height: 1.45;
  border: 1px solid transparent;
  box-sizing: border-box;
}

.verdict-success {
  background: rgba(27, 217, 106, 0.12);
  border-color: rgba(27, 217, 106, 0.4);
  color: #1bd96a;
}

.verdict-warning {
  background: rgba(245, 158, 11, 0.12);
  border-color: rgba(245, 158, 11, 0.4);
  color: #fbbf24;
}

.verdict-danger {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.4);
  color: #f87171;
}

/* ==========================================================================
   EU Cookie & Privacy Consent Banner (Dark Emerald Voxel UI)
   ========================================================================== */
.cookie-banner {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  max-width: 520px;
  width: calc(100% - 2rem);
  z-index: 999999;
  background: #0f151e;
  background: rgba(15, 21, 30, 0.98);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-default);
  border-bottom: 4px solid var(--accent-emerald-dark);
  border-radius: var(--radius-md);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.85), 0 0 28px rgba(27, 217, 106, 0.2);
  padding: 1.15rem 1.25rem;
  display: block;
  opacity: 1;
  pointer-events: auto;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.cookie-banner.dismissed {
  display: none !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

.cookie-banner-inner {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.cookie-banner-header {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.35rem;
}

.cookie-badge {
  font-family: var(--font-mono), monospace;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 0.2rem 0.5rem;
  background: var(--accent-emerald-soft);
  color: var(--accent-emerald);
  border: 1px solid rgba(27, 217, 106, 0.3);
  border-radius: var(--radius-xs);
}

.cookie-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-primary);
}

.cookie-text {
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--text-secondary);
  margin: 0;
}

.cookie-banner-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
  margin-top: 0.25rem;
}

@media (max-width: 640px) {
  .cookie-banner {
    bottom: 1rem;
    right: 1rem;
    left: 1rem;
    width: auto;
    max-width: none;
    padding: 1rem;
  }
  .cookie-banner-actions {
    flex-direction: column-reverse;
    width: 100%;
  }
  .cookie-banner-actions button {
    width: 100%;
    justify-content: center;
  }
}

/* ==========================================================================
   Slot #8: Modpack Server RAM & Aikar's Flags Calculator
   ========================================================================== */
.ram-kpi-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.ram-kpi-card {
  background: var(--bg-input);
  border: 2px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 0.85rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.ram-kpi-card.primary {
  border-color: var(--accent-emerald);
  box-shadow: 0 0 0 1px rgba(27, 217, 106, 0.22);
}

.ram-kpi-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.ram-kpi-value {
  font-size: 1.45rem;
  font-weight: 900;
  font-family: var(--font-mono), monospace;
  color: #fff;
  line-height: 1.15;
}

.ram-kpi-card.primary .ram-kpi-value {
  color: var(--accent-emerald);
}

.ram-form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

.ram-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.ram-field-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.ram-field-val {
  font-family: var(--font-mono), monospace;
  color: var(--accent-emerald);
  font-weight: 800;
}

.ram-select,
.ram-input {
  width: 100%;
  background: #0b0e11;
  color: #f8fafc;
  border: 1.5px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 0.55rem 0.7rem;
  font-size: 0.86rem;
  font-family: inherit;
}

.ram-select:focus,
.ram-input:focus {
  outline: none;
  border-color: var(--accent-emerald);
}

.ram-range {
  width: 100%;
  accent-color: var(--accent-emerald);
  cursor: pointer;
}

.ram-checkbox-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.82rem;
  color: var(--text-secondary);
  cursor: pointer;
  margin-top: 0.65rem;
}

.ram-checkbox-row input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--accent-emerald);
}

.ram-pack-meta {
  font-size: 0.8rem;
  line-height: 1.45;
  color: var(--text-secondary);
  background: rgba(168, 85, 247, 0.08);
  border: 1px solid rgba(168, 85, 247, 0.3);
  border-radius: var(--radius-sm);
  padding: 0.6rem 0.75rem;
  margin-bottom: 0.85rem;
}

.ram-gc-badge-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.ram-canvas-box {
  background: #0b0e11;
  border: 1.5px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 0.5rem;
  margin-bottom: 0.9rem;
}

.ram-canvas-box canvas {
  width: 100%;
  display: block;
}

.ram-warnings-stack {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-bottom: 0.9rem;
}

.ram-warnings-stack .status-banner {
  margin: 0;
  font-size: 0.8rem;
  line-height: 1.4;
}

.ram-script-tabs {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.55rem;
}

.ram-script-pre {
  background: #0b0e11;
  border: 1.5px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 0.85rem;
  margin: 0 0 0.75rem;
  overflow-x: auto;
  font-size: 0.78rem;
  line-height: 1.5;
  color: #e2e8f0;
  font-family: var(--font-mono), monospace;
  max-height: 240px;
}

.ram-script-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

@media (max-width: 640px) {
  .ram-kpi-grid {
    grid-template-columns: 1fr;
  }
  .ram-form-grid {
    grid-template-columns: 1fr;
  }
}



