/* Base Styles */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Custom Scrollbar */
.custom-scrollbar::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: #f3f4f6; /* gray-100 */
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background-color: #d1d5db; /* gray-300 */
    border-radius: 4px;
    border: 2px solid #f3f4f6;
}

.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background-color: #9ca3af; /* gray-400 */
}

@media (prefers-color-scheme: dark) {
    .custom-scrollbar::-webkit-scrollbar-track {
        background: #030712;
    }

    .custom-scrollbar::-webkit-scrollbar-thumb {
        background-color: #374151;
        border: 2px solid #030712;
    }

    .custom-scrollbar::-webkit-scrollbar-thumb:hover {
        background-color: #4b5563;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.3s ease-out forwards;
}

@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.98); }
    to { opacity: 1; transform: scale(1); }
}

.animate-scale-in {
    animation: scaleIn 0.2s ease-out forwards;
}

/* Markdown Content Styling */
.prose-content {
    font-size: 0.95rem;
}
.prose-content h1 { font-size: 1.4rem; font-weight: 700; margin-bottom: 0.75rem; margin-top: 0; }
.prose-content h2 { font-size: 1.2rem; font-weight: 600; margin-bottom: 0.5rem; margin-top: 1.5rem; }
.prose-content h3 { font-size: 1.1rem; font-weight: 600; margin-bottom: 0.5rem; margin-top: 1.25rem; }
.prose-content p { margin-bottom: 1rem; line-height: 1.6; }
.prose-content ul { list-style-type: disc; padding-left: 1.25rem; margin-bottom: 1rem; }
.prose-content ol { list-style-type: decimal; padding-left: 1.25rem; margin-bottom: 1rem; }
.prose-content blockquote { border-left: 3px solid #3b82f6; padding-left: 1rem; font-style: italic; background: rgba(0,0,0,0.05); padding: 0.5rem 0.5rem 0.5rem 1rem; border-radius: 0 4px 4px 0; }
.prose-content code { background-color: rgba(0,0,0,0.1); padding: 0.2rem 0.4rem; border-radius: 3px; font-family: monospace; font-size: 0.85em; }
.prose-content pre { background-color: #111827; padding: 1rem; border-radius: 4px; overflow-x: auto; margin-bottom: 1rem; border: 1px solid #1f2937; color: #e5e7eb; }
.prose-content pre code { background-color: transparent; padding: 0; }
.prose-content a { color: #2563eb; text-decoration: none; border-bottom: 1px dotted #2563eb; }
.prose-content a:hover { border-bottom-style: solid; }

@media (prefers-color-scheme: dark) {
    h1 { color: #fff!important;}
    .prose-content blockquote { background: #111827; }
    .prose-content code { background-color: #1f2937!important; }
    .prose-content a { color: #60a5fa; border-bottom-color: #60a5fa; }
}

/* Lightbox Utility */
#lightbox-img {
    max-height: 95vh;
    max-width: 95vw;
    object-fit: contain;
}

/* Inputs */
input[type=number]::-webkit-outer-spin-button,
input[type=number]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type=number] {
  -moz-appearance: textfield;
}