/* Custom Scrollbar */
.scrollbar-thin::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

.scrollbar-thin::-webkit-scrollbar-track {
  background: transparent;
}

.scrollbar-thin::-webkit-scrollbar-thumb {
  background: #2a2a36;
  border-radius: 3px;
}

.scrollbar-thin::-webkit-scrollbar-thumb:hover {
  background: #3f3f50;
}

/* Prism.js Overrides */
code[class*="language-"],
pre[class*="language-"] {
  color: #e8e8f0 !important;
  text-shadow: none !important;
  font-family: 'Fira Code', monospace !important;
  font-size: 13px !important;
  line-height: 1.6 !important;
  direction: ltr !important;
  text-align: left !important;
  white-space: pre !important;
  word-spacing: normal !important;
  word-break: normal !important;
  background: transparent !important;
  border: none !important;
  margin: 0 !important;
  padding: 0 !important;
  box-shadow: none !important;
}

/* Type Tree Guide Lines */
.type-tree {
  position: relative;
  margin-left: 2px;
}

.type-tree::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: -12px;
  width: 1px;
  background-image: linear-gradient(to bottom, #2a2a36 50%, transparent 50%);
  background-size: 1px 8px;
  background-repeat: repeat-y;
}

/* Fullscreen Loader */
.loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(600px circle at 15% 20%, rgba(248, 174, 13, 0.18), transparent 45%),
    radial-gradient(700px circle at 85% 80%, rgba(124, 58, 237, 0.16), transparent 50%),
    #0d0e16;
  transition: opacity 0.6s ease;
}

.loading-overlay.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.loading-overlay.hidden {
  display: none;
}

.loading-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  color: #ececec;
  text-align: center;
}

.loading-orb {
  position: relative;
  width: 86px;
  height: 86px;
}

.loading-orb::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid rgba(248, 174, 13, 0.2);
  border-top-color: #f8ae0d;
  border-right-color: rgba(248, 174, 13, 0.6);
  box-shadow: 0 0 24px rgba(248, 174, 13, 0.25);
  animation: spin 1.1s linear infinite;
}

.loading-orb::after {
  content: "";
  position: absolute;
  inset: 12px;
  border-radius: 50%;
  border: 2px solid rgba(124, 58, 237, 0.25);
  border-top-color: #7c3aed;
  animation: spinReverse 1.6s linear infinite;
}

.loading-title {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.loading-message {
  font-size: 13px;
  color: #94a3b8;
}

.loading-overlay.loading-error .loading-message {
  color: #fca5a5;
}

.app-fade {
  opacity: 0;
  transition: opacity 0.6s ease;
}

.app-fade.app-ready {
  opacity: 1;
}

.app-hidden {
  pointer-events: none;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes spinReverse {
  to { transform: rotate(-360deg); }
}
