/* ── Custom Styles for Henry Ford Hospital: D'Allemand ── */

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

body {
    overflow-x: hidden;
}

/* ── Typography ── */
.section-eyebrow {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #c9613a;
    font-family: 'Inter', system-ui, sans-serif;
}

.section-title {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 600;
    line-height: 1.15;
    color: #1c1917;
}

/* ── Navigation ── */
#site-header {
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease, backdrop-filter 0.4s ease;
}

#site-header.scrolled {
    background: rgba(254, 252, 248, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1.5px;
    background: #a84728;
    transition: width 0.3s ease;
}

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

.nav-link.scrolled {
    color: #57534e;
}

.nav-link.scrolled:hover {
    color: #a84728;
}

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

.menu-line.active:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

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

.menu-line.active:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
    width: 1.4rem;
}

.mobile-nav-link {
    position: relative;
}

.mobile-nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 1.5px;
    background: #a84728;
    transition: width 0.3s ease;
}

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

/* ── Hero Animations ── */
.hero-anim {
    opacity: 0;
    transform: translateY(24px);
    animation: heroReveal 0.8s ease forwards;
}

.hero-anim:nth-child(1) { animation-delay: 0.15s; }
.hero-anim:nth-child(2) { animation-delay: 0.35s; }
.hero-anim:nth-child(3) { animation-delay: 0.55s; }
.hero-anim:nth-child(4) { animation-delay: 0.75s; }

@keyframes heroReveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ── Scroll Reveal Animations ── */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1; /* Always visible — progressive enhancement */
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-up {
    transform: translateY(32px);
}

.reveal-left {
    transform: translateX(-32px);
}

.reveal-right {
    transform: translateX(32px);
}

.reveal-up.revealed,
.reveal-left.revealed,
.reveal-right.revealed {
    opacity: 1;
    transform: translate(0, 0);
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    .reveal-up,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .hero-anim {
        opacity: 1;
        transform: none;
        animation: none;
    }
}

/* ── Card Hover ── */
.card-elevate {
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

.card-elevate:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(168, 71, 40, 0.08);
}

/* ── Form Styles ── */
input:focus,
textarea:focus {
    box-shadow: 0 0 0 3px rgba(168, 71, 40, 0.12);
}

input::placeholder,
textarea::placeholder {
    color: #a8a29e;
}

/* ── Subtle Pattern Overlay ── */
.pattern-overlay {
    background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 20.5V18H0v-2h20v-2H0v-2h20v-2H0V8h20V6H0V4h20V2H0V0h22v20h2V0h2v20h2V0h2v20h2V0h2v20h2v2H20v-1.5zM0 20h2v20H0V20zm4 4v4h4v-4H4zm0 8v4h4v-4H4zm8-12v2h4v-2H8zm0 4v4h4v-4H8zm0 8v4h4v-4H8zm0 8v4h4v-4H8zm8-24v2h4v-2H8zm0 4v4h4v-4H8zm0 8v4h4v-4H8zm0 8v4h4v-4H8zm8-24v2h4v-2h-4zm0 4v4h4v-4h-4zm0 8v4h4v-4h-4zm0 8v4h4v-4h-4zm8-24v2h4v-2h-4zm0 4v4h4v-4h-4zm0 8v4h4v-4h-4zm0 8v4h4v-4h-4z' fill='%23c9613a' fill-opacity='0.03' fill-rule='evenodd'/%3E%3C/svg%3E");
}

/* ── Selection Color ── */
::selection {
    background: rgba(201, 97, 58, 0.2);
    color: #1c1917;
}

/* ── Scrollbar ── */
::-webkit-scrollbar {
    width: 8px;
}

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

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

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