/* ===== Custom Styles for Mill Creek Lodge Senior Care ===== */

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

/* Custom selection color */
::selection {
    background-color: #5c8242;
    color: #faf9f6;
}

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

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

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

/* Navbar scrolled state */
.navbar-scrolled {
    background-color: rgba(250, 249, 246, 0.95) !important;
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 0 rgba(44, 64, 33, 0.1);
}

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

/* Menu animation */
.menu-line {
    transition: all 0.3s ease;
}

#menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menu-btn.active .menu-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== Typography ===== */
h1, h2, h3 {
    font-weight: 400;
}

/* ===== Image hover effects ===== */
img {
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

/* ===== Form styles ===== */
input:focus,
textarea:focus {
    border-color: #5c8242 !important;
    box-shadow: 0 0 0 2px rgba(92, 130, 66, 0.1);
}

/* ===== Scroll reveal animations ===== */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* Reduced motion preference */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Subtle line animations ===== */
.deco-line {
    stroke-dasharray: 1000;
    stroke-dashoffset: 1000;
    transition: stroke-dashoffset 1.5s ease;
}

.deco-line.animated {
    stroke-dashoffset: 0;
}

/* ===== Card hover effects ===== */
.service-card {
    transition: background-color 0.5s ease;
}

/* ===== Button transitions ===== */
a, button {
    transition: all 0.3s ease;
}

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

/* ===== Image aspect ratio utilities ===== */
.aspect-card {
    aspect-ratio: 4/5;
}

/* ===== Custom scrollbar ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #faf9f6;
}

::-webkit-scrollbar-thumb {
    background: #c7dabb;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a3be8e;
}

/* ===== Tablet adjustments ===== */
@media (max-width: 768px) {
    .font-serif {
        line-height: 1.1;
    }
}

/* ===== Print styles ===== */
@media print {
    nav, #mobile-menu, .reveal {
        display: none !important;
    }
    
    body {
        color: #1a1a1a;
        background: white;
    }
}
