.night-theme {
  background: #4B4B4B;
  color: #e0e0e0;
}
/* Base Styling */
.night-theme {
  font-family: Arial, sans-serif;
  color: #e0e0e0;
  background-color: #121212;
  transition: background-color 0.3s ease-in-out, color 0.3s ease-in-out;
}

/* Title */
.night-theme #title {
  font-size: 3rem;
  font-weight: 800;
  background: linear-gradient(45deg, #B13818, #BC9125, #B6BC25);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 20px 0;
}

/* Subtitle */
.night-theme #subtitle {
  font-size: 1.25rem;
  color: #b0b0b0;
  margin-bottom: 40px;
}

/* Navbar Styling */
.night-theme #navbar ul {
  list-style-type: none;
  padding: 0;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  background-color: #1e1e1e;
  border-radius: 10px;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.5);
  border: 1px solid #333;
}

.night-theme #navbar li {
  margin: 0 15px;
  position: relative; /* Position relative for dropdowns */
}

.night-theme #navbar a {
  display: inline-block;
  padding: 12px 20px;
  font-weight: 600;
  text-transform: uppercase;
  color: #b0b0b0;
  text-decoration: none;
  transition: all 0.3s ease;
  border-radius: 8px;
}

.night-theme #navbar a:hover {
  background-color: #2d2d2d;
  color: #ff7043;
}

/* Dropdown Menu */
.night-theme #navbar .dropdown {
  display: none; /* Hide dropdowns by default */
  position: absolute;
  top: 100%;
  left: 0;
  background-color: #252525;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.7);
  z-index: 10;
  border: 1px solid #444;
  transition: opacity 0.3s ease;
}

.night-theme #navbar li:hover .dropdown {
  display: block; /* Show dropdown on hover */
}

.night-theme #navbar .dropdown a {
  display: block;
  padding: 10px 15px;
  color: #b0b0b0;
  transition: background-color 0.3s;
  border-bottom: 1px solid #333;
}

.night-theme #navbar .dropdown a:hover {
  background-color: #333;
  color: #ff7043;
}

.night-theme #saving-pop {
  color: #B13818;
}

/* Editor Container */
.night-theme #editor-container {
  width: 80%;
  max-width: 1200px;
  margin: auto;
  padding: 20px;
  border: 2px solid #333;
  border-radius: 15px;
  background-color: #1a1a1a;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
  text-align: center; /* Center content */
  transition: transform 0.3s ease;
}

/* Toolbar */
.night-theme #toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  padding: 8px 6px;
  margin-bottom: 10px;
}

.night-theme #toolbar button {
  padding: 12px 16px;
  border: 1px solid #333;
  border-radius: 8px;
  background-color: #2d2d2d;
  color: #b0b0b0;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.night-theme #toolbar button:hover {
  background-color: #3d3d3d;
  color: #fff;
  border-color: #ff7043;
  transform: scale(1.03);
}

.night-theme #toolbar button i {
  margin-right: 0 auto; /* Space for icons */
}

/* Editor */
.night-theme #editor {
  min-height: 300px;
  padding: 15px;
  border: 1px solid #444;
  border-radius: 10px;
  background-color: #252525;
  font-size: 1rem;
  color: #e0e0e0;
  outline: none;
  text-align: left;
}

.night-theme #editor a {
  color: #B13818;
}

.night-theme .menu {
  position: fixed; /* better than absolute for screen bounds */
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);

  width: min(90vw, 420px); 
  max-height: 80vh; 
  color: #e0e0e0;
  padding: 20px;
  background-color: #1e1e1e !important;
  border-radius: 10px;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.8);

  overflow-y: auto; 
  overscroll-behavior: contain;

  z-index: 1000;
  display: none;

  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
    border: 1px solid #333;
}

.night-theme .menu h3 {
  top: 0;

  margin: -20px -20px 15px -20px;
  padding: 15px 20px;

  font-size: 1.4rem;
  text-align: center;
  color: #ff7043;

  background-color: #1e1e1e;
  border-bottom: 1px solid #3d3d3d;

  z-index: 1;
}

.night-theme .menu .ending-section {
  bottom: 0;

  margin: 0px -20px 5px -20px;
  padding: 15px 20px;

  font-size: 1.4rem;
  text-align: center;
  color: #ff7043;

  background-color: #1e1e1e;
  border-top: 1px solid #3d3d3d;
  z-index: 1;
}

.night-theme .menu button {
  display: block;
  width: 100%;

  padding: 12px 16px;
  margin: 6px 0;

  border: 1px solid #444;
  border-radius: 8px;

  background-color: #2d2d2d;
  color: #b0b0b0;

  font-size: 1rem;
  font-weight: 600;

  cursor: pointer;
  transition:
    background-color 0.25s ease,
    transform 0.15s ease;
}

.night-theme .menu button:hover {
  background-color: #3d3d3d;
  color: #fff;
  border-color: #ff7043;
  transform: scale(1.03);
}

.night-theme .menu .menu-section {
  margin-bottom: 15px;
  border: #3d3d3d;
  background-color: #1e1e1e;
  color: #e0e0e0;
}

.night-theme .menu .menu-section-title {
  font-size: 0.9999rem;
  font-weight: bold;
  text-transform: uppercase;
  opacity: 0.6;
  margin: 10px 0 15px;
}

/* Overlay */
.night-theme #overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  display: none;
}

/* Light/Dark Themes */
.night-theme {
  background-color: #4B4B4B;
  color: #fff;
}

/* Codeblock */
.night-theme .codeblock {
  background-color: #0d0d0d;
  color: #d4d4d4;
  font-family: 'Consolas', 'Courier New', monospace;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #333;
  outline: none;
  white-space: pre;
  overflow: auto;
}

/* Animations */
.night-theme #editor-container {
  transition: transform 0.3s ease;
}

.night-theme #editor-container:hover {
  transform: scale(1.01);
  box-shadow: 0 6px 25px rgba(0, 0, 0, 0.7);
}



/* Input Fields and Selectors */
.night-theme input[type="checkbox"],
.night-theme select {
  width: auto; /* Full width for inputs */
  padding: 10px;
  margin: 15px 0;
  border: 1px solid #333;
  background-color: #252525;
  color: #e0e0e0;
  border-radius: 5px;
  font-size: 1rem;
  outline: none;
  transition: border 0.3s ease;
}

.night-theme input[type="checkbox"]:checked {
 accent-color: #ff7043; /* Custom color for checked checkboxes */
}

.night-theme select option {
  background-color: #1e1e1e;
  color: #e0e0e0;
}



.night-theme .highlight {
  font-weight: bold;
  background: linear-gradient(45deg, #B13818, #BC9125, #B6BC25);;
  background-size: 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: highlightAnimation 3s ease infinite;
}

.night-theme .current-highlight {
  font-weight: bold;
  background: linear-gradient(90deg, #B73850, #BC9B6F, #B6C585);
  background-size: 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: highlightAnimation 3s ease infinite;
}
@keyframes highlightAnimation {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Custom scrollbar styling */
.night-theme #plugin-controls::-webkit-scrollbar {
  width: none;
}

.night-theme #plugin-controls::-webkit-scrollbar-thumb {
  background-color: #555;
  border-radius: 5px;
}

.night-theme #plugin-controls::-webkit-scrollbar-thumb:hover {
  background-color: #666;
}

.night-theme #plugin-controls::-webkit-scrollbar-track {
  background-color: #2d2d2d;
  border-radius: 5px;
}

/* ===============================
   Snapshot System Styling
   =============================== */
/* Snapshot menu container */
.night-theme #snapshotMenu {
  margin-top: 20px;
  text-align: left;
  border-left: 3px solid #333;
  padding-left: 16px;
}

/* Snapshot card */
.night-theme .snapshot-item {
  position: relative;
  padding: 14px;
  margin-bottom: 14px;
  border-radius: 12px;
  background-color: #252525;
  border: 1px solid #444;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);

  font-size: 0.95rem;
  color: #fff;
  line-height: 1.5;

  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

/* Timeline dot */
.night-theme .snapshot-item::before {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  background: #ff7043;
  border-radius: 50%;
  left: -22px;
  top: 20px;
}

/* Hover effect */
.night-theme .snapshot-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.14);
}

/* Snapshot title */
.night-theme .snapshot-item strong {
  font-size: 1.05rem;
  font-weight: 700;
  color: #ff7043;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
}

/* Pinned snapshot */
.night-theme .snapshot-item.pinned {
  border: 2px solid #ff7043;
  }

.night-theme .snapshot-item.pinned::before {
  background: #ff7043;
}

/* Metadata row */
.night-theme .snapshot-meta {
  display: flex;
  gap: 12px;
  font-size: 0.85rem;
  color: #fff;
  margin-bottom: 8px;
}

/* Action buttons row */
.night-theme .snapshot-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

/* Icon-only buttons */
.night-theme .snapshot-actions button {
  padding: 8px;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Buttons */
.night-theme .snapshot-item button {
  border-radius: 8px;
  border: none;
  font-weight: 600;
  cursor: pointer;
  background-color: #3d3d3d;
  transition: all 0.25s ease;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  margin-right: 0 auto;
}

/* Button hover */
.night-theme .snapshot-item button:hover {
  transform: scale(1.05);
}

/* Restore button */

.night-theme .snapshot-item button.restore {
  background: #16653422;
  color: #22c55e;
}

.night-theme .snapshot-item button.restore:hover {
  background: #22c55e;
  color: #ffffff;
}

.night-theme .snapshot-item button.delete {
  background: #991b1b22;
  color: #dc2626;
}

.night-theme .snapshot-item button.delete:hover {
  background: #dc2626;
  color: #ffffff;
}

.night-theme .snapshot-item button.pin {
  background-color: #5d4037;
  color: #ffab91;
}

.night-theme .snapshot-item button.pin:hover {
  background-color: #8d6e63;
  color: #ffffff;
}

.night-theme .snapshot-item button:focus-visible {
  outline: 3px solid #ff7043;
  outline-offset: 2px;
}

/* Create snapshot button */
.night-theme #createSnapshotBtn {
  margin-top: 16px;
  padding: 12px 20px;
  border-radius: 10px;
  background: linear-gradient(45deg, #B13818, #BC9125, #B6BC25);
  color: #ffffff !important;
  font-weight: 800;
  border: none;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.night-theme #createSnapshotBtn:hover {
  transform: scale(1.07);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2);
}

/* Filtering toggle */
.night-theme #enableFiltering {
  margin-right: 10px;
  transform: scale(1.2);
}


/* ALERT FUCKASS ALERT */
.night-theme input,
.night-theme textarea,
.night-theme select {
  font-family: 'Raleway', sans-serif;
  font-size: 1rem;
  padding: 10px 14px;
  margin: 6px 0;
  border: 1px solid #444;
  border-radius: 10px;
  background-color: #252525;
  color: #e0e0e0;
  outline: none;
  transition: all 0.25s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  width: 100%; /* full-width by default */
  box-sizing: border-box;
}

/* Focus state */
.night-theme input:focus,
.night-theme textarea:focus,
.night-theme select:focus {
   border-color: #ff7043;
  box-shadow: 0 4px 12px rgba(255, 112, 67, 1) ;
}

/* Placeholder color */
.night-theme input::placeholder,
.night-theme textarea::placeholder {
  color: #777;
  opacity: 1;
}

/* Disabled state */
.night-theme input:disabled,
.night-theme textarea:disabled,
.night-theme select:disabled {
  background-color: #1a1a1a;
  color: #666;
  cursor: not-allowed;
}

/* Buttons inside forms (optional consistency) */
.night-theme input[type="submit"],
.night-theme input[type="button"] {
  background: linear-gradient(45deg, #ff6b9d, #8a5cc8, #4a9be8);
  color: #fff;
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.night-theme input[type="submit"]:hover,
.night-theme input[type="button"]:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 16px rgba(43, 134, 197, 0.3);
}

.sister-features {
  display: flex;
  padding: 6px;
  border-radius: 10px;

  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);

 /* box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.02),
    0 2px 6px rgba(0, 0, 0, 0.35);
    */
  position: relative;
}

.night-theme #update-badge {
  background-color: #2d2d2d;
  color: #b0b0b0;
  border: 1px solid #333 !important;
  border-radius: 8px;
}
.night-theme #update-badge:hover {
  background-color: #3d3d3d;
  color: #fff;
  border-color: #ff7043;
}

.night-theme .toolbar-remap {
  position: relative;
  padding: 14px;
  margin-bottom: 14px;
  border-radius: 12px;

  background-color: #252525;
  border: 1px solid #444;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);

  font-size: 0.95rem;
  color: #fff;
  line-height: 1.5;

  /* section behavior */
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.night-theme .toolbar-remap .section-title {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #6b7280;
}

.night-theme .toolbar-remap .tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
  gap: 10px;
}

.night-theme .toolbar-remap .tool-btn {
  position: relative;
  height: 40px;

  border-radius: 8px;

  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 14px;
}

.night-theme .toolbar-remap .tool-toggle {
  position: absolute;
  top: -6px;
  right: -6px;

  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: none;
  background-color: #3d3d3d;
  font-size: 11px;

  display: flex;
  align-items: center;
  justify-content: center;
}

.night-theme .toolbar-remap .tool-hidden {
  opacity: 0.45;
  filter: grayscale(1.5);
}

.night-theme .toolbar-remap .section-hint {
  font-size: 0.8rem;
  color: #9ca3af;
}


.night-theme .status-bar {
  border: 1px solid #444;
  color: #e0e0e0;
}


.night-theme .km-panel {
  color: #fff;
  background-color: #252525;
  border: 1px solid #444;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.night-theme .km-actions button {
  background-color: #3d3d3d;
  color: #fff;
  border: 1px solid;
  border-color: #ff7043;
}

.night-theme .km-actions button:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 16px rgba(197, 128, 43, 0.3);
}

.night-theme .reload-plugin {
  border: 1px solid;
  background: #3d3d3d;
  color: #fff;
  border-color: #ff7043;
}

.night-theme .reload-plugin:focus-visible {
  outline: 2px solid #ff7043;
  outline-offset: 2px;
}

.night-theme .plugin-health.running {
  border-color: #16a34a; /* green-600 */
  color: #e0e0e0;
}

.night-theme .plugin-health.running::before {
  border-color: #16a34a;
  color: #e0e0e0;
}

.night-theme .plugin-health.disabled {
  border-color: #dc2626; /* red-600 */
  color: #e0e0e0;
}

.night-theme .plugin-health.disabled::before {
  border-color: #dc2626;
  color: #e0e0e0;
}

.night-theme .plugin-health.failed {
  border-color: #d97706; /* amber-600 */
  color: #e0e0e0;
}

.night-theme .plugin-health.failed::before {
  border-color: #d97706;
  color: #e0e0e0;
}

.night-theme .plugin-toggle {
  border: 1px solid;
  background: #3d3d3d;
  color: #fff;
}

.night-theme .plugin-toggle:hover:not(:disabled) {
  border-color: #ff7043;
}

.night-theme .perm-badge {
  background: #FFEED0; /* indigo-50 */
  border: 1px solid #FBD3C6; /* indigo-200 */
  color: #ff7043; /* indigo-700 */
}

.night-theme .plugin-versionText {
  background: #374151;
  border: 1px solid #555555;
  padding: 2px 7px;
  border-radius: 999px;
  font-weight: 500;
  color: #f3f4f6;
}

.night-theme .plugin-item {
color: #e0e0e0;
background-color: #1e1e1e !important;
  border-radius: 10px;
border: 1px solid #3d3d3d;
}

.night-theme .plugin-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 112, 67, 1) ;
}



/* Description */
.night-theme .plugin-description {
  margin-top: 6px;
  font-size: 0.85rem;
  line-height: 1.45;
 color: #e0e0e0; /* gray-600 */
}

/* Meta row */
.night-theme .plugin-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
  font-size: 0.75rem;
  color: #e0e0e0; /* gray-500 */
}