/* Custom styles for Richard A. Kocurek website */

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

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0a0a0c;
}
::-webkit-scrollbar-thumb {
    background: #2a2a30;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #d4af5a;
}

/* Selection color */
::selection {
    background: rgba(196, 42, 74, 0.3);
    color: #fff;
}

/* Gold shimmer animation for accents */
@keyframes shimmer {
    0% { background-position: -200% center; }
    100% { background-position: 200% center; }
}

/* Subtle pulse for decorative elements */
@keyframes subtle-pulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.6; }
}

/* Fade up animation for scroll reveals */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Scroll reveal base state - content always visible by default */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

/* Only apply animation when JS adds the animated class */
body.js-enabled .scroll-reveal {
    opacity: 0;
    transform: translateY(20px);
}

body.js-enabled .scroll-reveal.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger delays */
.scroll-reveal.delay-1 { transition-delay: 0.1s; }
.scroll-reveal.delay-2 { transition-delay: 0.2s; }
.scroll-reveal.delay-3 { transition-delay: 0.3s; }
.scroll-reveal.delay-4 { transition-delay: 0.4s; }

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    .scroll-reveal,
    .scroll-reveal.animated {
        opacity: 1;
        transform: translateY(0);
        transition: none;
    }
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Navbar glass effect */
#navbar {
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

#navbar.scrolled {
    background: rgba(10, 10, 12, 0.95);
    border-bottom: 1px solid rgba(212, 175, 90, 0.1);
}

/* Mobile menu transitions */
#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

/* Mobile link transitions */
.mobile-link {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease, color 0.3s ease;
}

/* Hamburger animation */
#menuLine1.open {
    transform: rotate(45deg) translate(4px, 4px);
}
#menuLine2.open {
    opacity: 0;
}
#menuLine3.open {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 1.5rem;
}

/* Form focus styles */
input:focus,
select:focus,
textarea:focus {
    box-shadow: 0 0 0 1px rgba(212, 175, 90, 0.2);
}

/* Button ripple effect */
button, a {
    position: relative;
    overflow: visible;
}

/* Service card hover lift */
.group:hover {
    transform: translateY(-2px);
}

.group {
    transition: transform 0.3s ease;
}

/* Gold gradient text utility */
.text-gold-gradient {
    background: linear-gradient(135deg, #d4af5a 0%, #f5e6c8 50%, #d4af5a 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Decorative corner accent */
.corner-accent {
    position: relative;
}
.corner-accent::before,
.corner-accent::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 24px;
    border-color: rgba(212, 175, 90, 0.3);
    border-style: solid;
}
.corner-accent::before {
    top: -1px;
    left: -1px;
    border-width: 1px 0 0 1px;
}
.corner-accent::after {
    bottom: -1px;
    right: -1px;
    border-width: 0 1px 1px 0;
}

/* Image lazy loading placeholder */
img {
    opacity: 1;
}

/* Focus visible for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid #d4af5a;
    outline-offset: 2px;
}
