/* Custom styles — overrides and additions beyond Tailwind */

/* Smooth focus styles for accessibility */
*:focus-visible {
    outline: 2px solid #a11533;
    outline-offset: 2px;
}

/* Selection color */
::selection {
    background: rgba(161, 21, 51, 0.15);
    color: #3b0713;
}

/* Prevent layout shift on select elements */
select {
    background-image: url('data:image/svg+xml,%3Csvg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 24 24" fill="none" stroke="%23a11533" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"%3E%3Cpolyline points="6 9 12 15 18 9"%2F%3E%3C/svg%3E');
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    .reveal {
        opacity: 1 !important;
        transform: none !important;
    }
}

/* Image placeholder fallback */
img {
    image-rendering: auto;
}

/* Ensure serif font renders well at small sizes */
.font-display {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Custom scrollbar for webkit */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #fefdfb;
}
::-webkit-scrollbar-thumb {
    background: #c22545;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #a11533;
}
