/* R&D Amplifier Website Styles */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom line clamping for article cards */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Article content styling enhancements */
.prose figure {
    margin: 2rem 0;
}

.prose figure img {
    margin: 0 auto;
}

.prose figcaption {
    margin-top: 0.75rem;
}

/* Custom scrollbar for dark mode */
.dark ::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.dark ::-webkit-scrollbar-track {
    background: #1f2937;
}

.dark ::-webkit-scrollbar-thumb {
    background: #4b5563;
    border-radius: 5px;
}

.dark ::-webkit-scrollbar-thumb:hover {
    background: #6b7280;
}

/* Focus styles for accessibility */
a:focus,
button:focus {
    outline: 2px solid #0ea5e9;
    outline-offset: 2px;
}

/* Smooth transitions for theme switching */
body,
header,
footer,
main,
article,
nav a {
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

/* Article card hover effect */
article.bg-white:hover,
article.dark\:bg-gray-800:hover {
    transform: translateY(-2px);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Loading state for images */
.prose img {
    background-color: #f3f4f6;
    transition: opacity 0.3s ease;
}

.dark .prose img {
    background-color: #374151;
}

/* Mobile menu animation */
[x-transition] {
    transition: all 0.2s ease;
}

/* Print styles */
@media print {
    header,
    footer,
    nav,
    .no-print {
        display: none !important;
    }

    .prose {
        max-width: 100% !important;
    }

    a {
        text-decoration: underline;
    }

    a[href]:after {
        content: " (" attr(href) ")";
        font-size: 0.8em;
    }
}
