/* ============================================
   Mobile Orthopedic Center — Custom Styles
   ============================================ */

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

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

body {
    background-color: #FFF8F5;
}

/* ============================================
   HERO DECORATIVE SHAPES
   ============================================ */
.hero-shape {
    position: absolute;
    pointer-events: none;
    will-change: transform;
}

.shape-circle-1 {
    width: 420px;
    height: 420px;
    background: linear-gradient(135deg, #fce7eb 0%, #fad0d9 100%);
    border-radius: 50%;
    top: -100px;
    left: -120px;
    opacity: 0.5;
    animation: float-slow 8s ease-in-out infinite;
}

.shape-circle-2 {
    width: 200px;
    height: 200px;
    background: #81192f;
    border-radius: 50%;
    bottom: 15%;
    right: 5%;
    opacity: 0.08;
    animation: float-slow 6s ease-in-out infinite reverse;
}

.shape-circle-3 {
    width: 100px;
    height: 100px;
    background: #ff7ba3;
    border-radius: 50%;
    top: 40%;
    right: 38%;
    opacity: 0.15;
    animation: float-slow 5s ease-in-out infinite;
}

.shape-rect-1 {
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, #b92640 0%, #d43f5c 100%);
    border-radius: 24px;
    top: 20%;
    right: 35%;
    opacity: 0.06;
    transform: rotate(45deg);
    animation: rotate-slow 12s linear infinite;
}

.shape-triangle {
    width: 0;
    height: 0;
    border-left: 60px solid transparent;
    border-right: 60px solid transparent;
    border-bottom: 104px solid #fad0d9;
    opacity: 0.2;
    top: 30%;
    left: 8%;
    animation: float-slow 7s ease-in-out infinite;
}

@keyframes float-slow {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

@keyframes rotate-slow {
    from { transform: rotate(45deg); }
    to { transform: rotate(405deg); }
}

/* ============================================
   FLOATING CARD ANIMATION
   ============================================ */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.animate-float {
    animation: float 4s ease-in-out infinite;
}

/* ============================================
   NAVBAR
   ============================================ */
#navbar {
    background: rgba(255, 248, 245, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(129, 25, 47, 0.08);
}

#navbar.scrolled {
    background: rgba(255, 248, 245, 0.95);
    box-shadow: 0 4px 30px rgba(129, 25, 47, 0.08);
}

/* ============================================
   MOBILE MENU
   ============================================ */
.mobile-link {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.3s ease;
}

#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

#mobileMenu.closed {
    opacity: 0;
    pointer-events: none;
}

/* Hamburger animation */
.menu-line {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

#menuBtn.active .menu-line:nth-child(2) {
    opacity: 0;
    transform: translateX(-10px);
}

#menuBtn.active .menu-line:nth-child(3) {
    width: 1.25rem;
    transform: rotate(-45deg) translate(4px, -4px);
}

/* ============================================
   SERVICE CARDS
   ============================================ */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #81192f, #ff7ba3);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.service-card:hover::before {
    opacity: 1;
}

/* ============================================
   SCROLL REVEAL (Progressive Enhancement)
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1), transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    }

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

    .reveal-delay-1 { transition-delay: 0.1s; }
    .reveal-delay-2 { transition-delay: 0.2s; }
    .reveal-delay-3 { transition-delay: 0.3s; }
    .reveal-delay-4 { transition-delay: 0.4s; }
    .reveal-delay-5 { transition-delay: 0.5s; }
    .reveal-delay-6 { transition-delay: 0.6s; }
}

/* When JS is enabled, set initial state via JS */
.js-enabled .reveal {
    opacity: 0;
    transform: translateY(30px);
}

/* ============================================
   FORM STYLES
   ============================================ */
input:focus,
select:focus,
textarea:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(129, 25, 47, 0.1);
}

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

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .shape-circle-1 {
        width: 250px;
        height: 250px;
        left: -80px;
        top: -60px;
    }

    .shape-circle-2 {
        width: 120px;
        height: 120px;
    }

    .shape-rect-1 {
        width: 80px;
        height: 80px;
    }

    .shape-triangle {
        border-left: 40px solid transparent;
        border-right: 40px solid transparent;
        border-bottom: 69px solid #fad0d9;
    }

    .floating-card {
        position: relative !important;
        bottom: auto !important;
        left: auto !important;
        margin-top: 1rem;
    }
}

/* ============================================
   FOCUS VISIBLE
   ============================================ */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid #81192f;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ============================================
   SELECTION
   ============================================ */
::selection {
    background: #fad0d9;
    color: #3b0710;
}
