/* Custom Styles for Amanda Rexwinkle Therapy Website */

/* Base Styles */
html {
    scroll-behavior: smooth;
}

body {
    font-feature-settings: "cv02", "cv03", "cv04";
}

/* Smooth Scroll Offset for Fixed Header */
section[id] {
    scroll-margin-top: 80px;
}

/* Navigation */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: #d4af37;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Mobile Menu */
.mobile-nav-link {
    position: relative;
}

.mobile-nav-link::before {
    content: '';
    position: absolute;
    left: -24px;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 1px;
    background-color: #d4af37;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.mobile-nav-link:hover::before {
    opacity: 1;
}

/* Hero Animation */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-up {
    animation: fadeUp 0.8s ease-out;
}

/* Scroll Line Animation */
@keyframes scrollLine {
    0% {
        transform: scaleY(0);
        transform-origin: top;
    }
    50% {
        transform: scaleY(1);
        transform-origin: top;
    }
    51% {
        transform-origin: bottom;
    }
    100% {
        transform: scaleY(0);
        transform-origin: bottom;
    }
}

.animate-scroll-line {
    animation: scrollLine 2s ease-in-out infinite;
}

/* Scroll Reveal Animation */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-on-scroll.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Reveal with stagger */
.reveal-on-scroll:nth-child(2) {
    transition-delay: 0.1s;
}

.reveal-on-scroll:nth-child(3) {
    transition-delay: 0.2s;
}

.reveal-on-scroll:nth-child(4) {
    transition-delay: 0.3s;
}

/* Service Card Hover Effect */
.group:hover .group-hover\:bg-gold-400\/30 {
    background-color: rgba(212, 175, 55, 0.3);
}

/* Input Focus Styles */
input:focus,
textarea:focus {
    box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.2);
}

/* Custom Selection */
::selection {
    background-color: #d4af37;
    color: #0f1c36;
}

/* Back to Top Button */
#back-to-top.visible {
    opacity: 1;
    pointer-events: all;
}

/* Image Hover Zoom */
.group:hover img {
    transform: scale(1.05);
}

/* Smooth Image Transitions */
img {
    transition: transform 0.6s ease;
}

/* Print Styles */
@media print {
    header,
    #back-to-top,
    .animate-scroll-line {
        display: none;
    }
    
    body {
        color: #000;
        background: #fff;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .bg-gold-400\/20 {
        background-color: rgba(212, 175, 55, 0.4);
    }
    
    .text-white\/60 {
        color: rgba(255, 255, 255, 0.9);
    }
}

/* Focus Visible for Accessibility */
:focus-visible {
    outline: 2px solid #d4af37;
    outline-offset: 2px;
}

/* Button Hover Lift */
button[type="submit"],
a:not(.nav-link):not(.mobile-nav-link) {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

button[type="submit"]:hover,
a:hover {
    transform: translateY(-1px);
}

button[type="submit"]:active {
    transform: translateY(0);
}

/* Form Error States */
input:invalid:not(:placeholder-shown),
textarea:invalid:not(:placeholder-shown) {
    border-color: #ef4444;
}

input:valid:not(:placeholder-shown),
textarea:valid:not(:placeholder-shown) {
    border-color: #22c55e;
}
