/* Custom styles that complement Tailwind */

/* Smooth scroll offset for fixed nav */
section[id] {
    scroll-margin-top: 80px;
}

/* Selection color */
::selection {
    background-color: rgba(69, 179, 113, 0.25);
    color: #102a43;
}

/* Focus visible styles */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #45b371;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Subtle grain texture on hero (optional enhancement) */
.hero-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 30% 50%, transparent 0%, rgba(10, 22, 40, 0.3) 100%);
    pointer-events: none;
}

/* Button press effect */
button:active,
a:active {
    transform: scale(0.98);
}

/* Image lazy-load fade (progressive enhancement) */
img[loading="lazy"] {
    opacity: 0;
    transition: opacity 0.5s ease;
}
img[loading="lazy"].loaded {
    opacity: 1;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f0f4f8;
}
::-webkit-scrollbar-thumb {
    background: #9fb3cc;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #627d98;
}

/* Ensure all text meets contrast on dark backgrounds */
.bg-navy-900,
.bg-navy-950,
.bg-navy-800 {
    color: white;
}

/* Card image hover zoom */
.card-hover img {
    transition: transform 0.5s ease;
}
.card-hover:hover img {
    transform: scale(1.03);
}
