/* The Running T — Custom Styles */

/* Base & Typography */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* Selection color */
::selection {
    background-color: rgba(74, 191, 150, 0.25);
    color: #0A1628;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #FDF8F5;
}
::-webkit-scrollbar-thumb {
    background: #D4C4B0;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #B8A48E;
}

/* Navbar scroll state */
#navbar.scrolled {
    background: rgba(253, 248, 245, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(10, 22, 40, 0.06);
}

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

/* Mobile link hover */
.mobile-link {
    position: relative;
}
.mobile-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 2px;
    background: #4ABF96;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}
.mobile-link:hover::after {
    width: 100%;
}

/* Menu toggle animation */
#menu-toggle.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}
#menu-toggle.active .menu-line:nth-child(2) {
    opacity: 0;
}
#menu-toggle.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
    width: 1.25rem;
}

/* Image hover effects */
img {
    display: block;
    max-width: 100%;
}

/* Button focus states */
button:focus-visible,
a:focus-visible {
    outline: 2px solid #4ABF96;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Form input focus */
input:focus,
textarea:focus {
    outline: none;
}

/* Smooth image loading */
img {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Print styles */
@media print {
    nav, #mobile-menu, button {
        display: none !important;
    }
    body {
        color: #000;
        background: #fff;
    }
}
