@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;700&family=Silkscreen&display=swap');

/* Global Variables - Floral Enchantment Emerald Theme */
:root, [data-md-color-scheme="default"] {
  --md-text-font: 'Outfit', sans-serif;
  --md-code-font: 'Roboto Mono', monospace;
  font-family: 'Outfit', sans-serif !important;

  --md-primary-color: #064e3b !important;
  --md-primary-color--dark: #022c22 !important;
  --md-accent-color: #10b981 !important;

  --md-default-bg-color: #091310 !important;
  --md-default-bg-color--light: #11221c !important;
  --md-default-fg-color: #e2f8f0 !important;
  --md-default-fg-color--light: #8ee0c2 !important;

  --md-card-bg-color: #11221c !important;
  --md-card-bg-color--active: #1a332a !important;
  --md-code-bg-color: #0d1f19 !important;

  --md-typeset-border-color: rgba(16, 185, 129, 0.15) !important;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: #091310;
}
::-webkit-scrollbar-thumb {
  background: #16382c;
  border-radius: 4px;
  border: 1px solid #235241;
}
::-webkit-scrollbar-thumb:hover {
  background: #10b981;
}

/* Typography Overrides */
h1, h2, h3, h4, h5, h6, .md-nav__title, .md-header__topic, .md-nav__link--active {
  font-family: 'Silkscreen', monospace !important;
  font-weight: normal !important;
  letter-spacing: 0.8px;
}

h1 {
  color: #34d399 !important;
  text-shadow: 2px 2px 0px rgba(0, 0, 0, 0.9);
  border-bottom: 2px dashed rgba(16, 185, 129, 0.4) !important;
  padding-bottom: 12px;
  margin-top: 1.5em !important;
  margin-bottom: 1em !important;
}

h2 {
  color: #6ee7b7 !important;
  text-shadow: 1.5px 1.5px 0px rgba(0, 0, 0, 0.8);
  border-bottom: 1px solid rgba(16, 185, 129, 0.15);
  padding-bottom: 6px;
  margin-top: 1.8em !important;
}

h3 {
  color: #f472b6 !important;
  text-shadow: 1px 1px 0px rgba(0, 0, 0, 0.8);
}

/* Sidebar Navigation */
.md-nav__link {
  transition: transform 0.2s ease, color 0.2s ease, padding-left 0.2s ease !important;
}
.md-nav__link:hover {
  color: #34d399 !important;
  transform: translateX(4px);
}

/* Admonitions */
.md-typeset .admonition, .md-typeset details {
  background-color: #11221c !important;
  border-left: 4px solid var(--md-accent-color) !important;
  border-radius: 4px;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
  border-top: 1px solid rgba(255, 255, 255, 0.02) !important;
  border-right: 1px solid rgba(255, 255, 255, 0.02) !important;
  border-bottom: 1px solid rgba(0, 0, 0, 0.2) !important;
}

/* Code Blocks & Inline Code Badges */
.md-typeset pre {
  background-color: #091310 !important;
  border: 1px solid rgba(16, 185, 129, 0.15) !important;
  border-radius: 4px;
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.8) !important;
}

.md-typeset :not(pre) > code {
  color: #34d399 !important;
  background-color: #0d1f19 !important;
  padding: 2px 6px !important;
  border-radius: 4px !important;
  border: 1px solid rgba(16, 185, 129, 0.25) !important;
  font-size: 0.85em !important;
  font-weight: 500 !important;
}

.md-typeset strong :not(pre) > code {
  color: #34d399 !important;
  font-weight: 700 !important;
}

/* Table Styling */
.md-typeset table {
  border: 1px solid rgba(16, 185, 129, 0.2) !important;
  border-radius: 6px;
  overflow: hidden;
}

.md-typeset table tr:nth-child(even) {
  background-color: #11221c !important;
}
.md-typeset table tr:nth-child(odd) {
  background-color: #0d1a15 !important;
}

.md-typeset table th {
  background-color: #16382c !important;
  color: #34d399 !important;
  font-family: 'Silkscreen', monospace !important;
  font-size: 13px !important;
}

/* Interactive Crown Menu Selector Container */
.crown-selector-container {
  display: flex;
  align-items: flex-start;
  gap: 28px;
  margin: 24px 0 32px 0;
  flex-wrap: wrap;
}

.crown-menu-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 220px;
  min-width: 220px;
  background: #0d1f19;
  padding: 12px;
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.crown-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  background: #11221c;
  border: 1px solid rgba(16, 185, 129, 0.15);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.crown-menu-item img {
  width: 28px;
  height: 28px;
  image-rendering: pixelated;
}

.crown-menu-item span {
  font-family: 'Outfit', sans-serif;
  font-size: 13.5px;
  font-weight: 500;
  color: #e2f8f0;
}

.crown-menu-item:hover {
  background: #1a332a;
  border-color: #34d399;
  transform: translateX(3px);
}

.crown-menu-item.active {
  background: #16382c;
  border-color: #10b981;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.3);
}

.crown-menu-item.active span {
  color: #34d399;
  font-weight: 700;
}

/* Minecraft UI Elements (Direct from Nameless Trinkets Wiki) */
.mc-recipe {
  display: flex;
  align-items: center;
  gap: 20px;
  background: #c6c6c6 !important;
  padding: 12px;
  border: 4px solid #373737;
  border-color: #dfdfdf #555555 #555555 #dfdfdf;
  border-radius: 2px;
  width: fit-content;
  margin-bottom: 25px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6), inset 0 2px 0 rgba(255, 255, 255, 0.2);
}

.mc-grid {
  display: grid;
  grid-template-columns: repeat(3, 36px);
  gap: 4px;
}

.mc-slot {
  width: 36px;
  height: 36px;
  background: #8b8b8b !important;
  border: 2px solid;
  border-color: #373737 #ffffff #ffffff #373737;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  cursor: pointer;
  box-shadow: inset 2px 2px 4px rgba(0, 0, 0, 0.4);
  transition: transform 0.1s ease;
}

.mc-slot img {
  width: 32px;
  height: 32px;
  image-rendering: pixelated;
}

img.vibrant-vine-img {
  filter: sepia(0.8) hue-rotate(85deg) saturate(2.5) !important;
}

.mc-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
}

.mc-arrow img {
  width: 28px;
  height: auto;
  image-rendering: pixelated;
  filter: brightness(0.28) drop-shadow(1px 1px 0px rgba(0, 0, 0, 0.4));
}

.mc-result {
  width: 56px;
  height: 56px;
  background: #8b8b8b !important;
  border: 2px solid;
  border-color: #373737 #ffffff #ffffff #373737;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  cursor: pointer;
  box-shadow: inset 3px 3px 6px rgba(0, 0, 0, 0.5);
  transition: transform 0.1s ease;
}

.mc-result img {
  width: 48px;
  height: 48px;
  image-rendering: pixelated;
}

.mc-slot:hover, .mc-result:hover {
  background: rgba(255, 255, 255, 0.28) !important;
  box-shadow: inset 2px 2px 4px rgba(255, 255, 255, 0.2);
}

.mc-slot[data-title]:hover::after, .mc-result[data-title]:hover::after {
  content: attr(data-title);
  position: absolute;
  bottom: 44px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  
  background: rgba(16, 0, 16, 0.94) !important;
  color: #ffffff !important;
  font-family: 'Outfit', sans-serif !important;
  font-size: 13px !important;
  font-weight: 500 !important;
  padding: 6px 12px;
  border-radius: 4px;
  border: 2px solid #10b981 !important;
  box-shadow: 0 0 0 2px rgba(16, 0, 16, 0.94), 0 0 10px #10b981, 0 8px 24px rgba(0, 0, 0, 0.7);
  white-space: nowrap;
  pointer-events: none;
  text-shadow: 1px 1px 0px rgba(0, 0, 0, 0.6);
  animation: tooltipFadeIn 0.12s ease-out;
}

.mc-result[data-title]:hover::after {
  bottom: 64px;
}

@keyframes tooltipFadeIn {
  from {
    opacity: 0;
    transform: translate(-50%, 4px);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

/* Glassmorphism Header */
.md-header {
  background-color: rgba(9, 19, 16, 0.7) !important;
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  border-bottom: 1px solid rgba(16, 185, 129, 0.15) !important;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4) !important;
}

/* Item & Block Grid Cards (Direct from Nameless Trinkets Wiki) */
.trinket-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
  margin: 24px 0;
}

.trinket-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: #11221c !important;
  border: 1px solid rgba(16, 185, 129, 0.15) !important;
  border-radius: 8px;
  text-decoration: none !important;
  color: #e2f8f0 !important;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
  transition: all 0.2s ease-in-out;
}

.trinket-card:hover {
  transform: translateY(-3px);
  border-color: #34d399 !important;
  background: #1a332a !important;
  box-shadow: 0 8px 16px rgba(16, 185, 129, 0.2);
}

.trinket-card img {
  width: 48px;
  height: 48px;
  image-rendering: pixelated;
  margin-bottom: 8px;
}

.trinket-card span {
  font-family: 'Outfit', sans-serif;
  font-size: 13.5px;
  font-weight: 500;
  text-align: center;
  color: #6ee7b7;
  transition: color 0.2s ease;
}

.trinket-card:hover span {
  color: #34d399;
}
