*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::selection {
    background-color: rgba(232, 93, 74, 0.3);
    color: #f0f4f8;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #0F1419;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #3A4552;
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: #E85D4A;
    transition: all 0.2s ease;
    transform: translateX(-50%);
}

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

.mobile-link {
    border-radius: 8px;
}

/* Scroll reveal — progressive enhancement, only applies when JS runs */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
        transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    }

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

    .reveal:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
    .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* Default: always visible for no-JS / reduced-motion */
.reveal {
    opacity: 1;
    transform: none;
}

/* Back to top button */
#back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

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

/* Image loading placeholder */
img {
    background-color: #1A2028;
}

/* Ensure map iframe is readable */
iframe[src*="google.com/maps"] {
    border-radius: 0 0 1rem 1rem;
}
