/* ========================================
   Elida Hernandez Medical & Health
   Custom Styles
======================================== */

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    overflow-x: hidden;
}

/* ========================================
   Geometric Background Shapes
======================================== */
.geometric-shape {
    position: absolute;
    pointer-events: none;
    opacity: 0.6;
}

.shape-circle-1 {
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.15) 0%, transparent 70%);
    top: -100px;
    left: -100px;
    animation: float 8s ease-in-out infinite;
}

.shape-circle-2 {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.1) 0%, transparent 70%);
    top: 40%;
    right: -50px;
    animation: float 10s ease-in-out infinite reverse;
}

.shape-circle-3 {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.08) 0%, transparent 70%);
    bottom: 15%;
    left: 30%;
    animation: float 6s ease-in-out infinite;
}

.shape-square-1 {
    width: 120px;
    height: 120px;
    background: rgba(251, 191, 36, 0.06);
    border: 2px solid rgba(251, 191, 36, 0.1);
    border-radius: 20px;
    top: 25%;
    right: 10%;
    transform: rotate(45deg);
    animation: spin 20s linear infinite;
}

.shape-triangle-1 {
    width: 0;
    height: 0;
    border-left: 60px solid transparent;
    border-right: 60px solid transparent;
    border-bottom: 104px solid rgba(251, 191, 36, 0.05);
    bottom: 20%;
    right: 25%;
    animation: float 7s ease-in-out infinite reverse;
}

.shape-gold-circle {
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.08) 0%, transparent 70%);
    top: -150px;
    right: -150px;
    animation: float 12s ease-in-out infinite;
}

.shape-navy-square {
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.03);
    border: 2px solid rgba(255, 255, 255, 0.05);
    border-radius: 30px;
    bottom: 10%;
    left: -50px;
    transform: rotate(30deg);
    animation: spin 25s linear infinite reverse;
}

/* ========================================
   Animations
======================================== */
@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    33% {
        transform: translateY(-20px) rotate(2deg);
    }
    66% {
        transform: translateY(10px) rotate(-1deg);
    }
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================================
   Scroll Reveal Animations
   Progressive enhancement — only active
   when JS runs and user prefers motion
======================================== */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.8s ease, transform 0.8s ease;
    }

    .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; }
}

/* ========================================
   Navbar Transition
======================================== */
#navbar.scrolled {
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(20px);
    box-shadow: 0 4px 30px rgba(16, 42, 67, 0.08);
}

#navbar.scrolled .nav-link {
    color: #102a43;
}

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

#navbar.scrolled .logo-text {
    color: #102a43;
}

#navbar.scrolled .logo-sub {
    color: #486581;
}

/* ========================================
   Service Card Hover Effects
======================================== */
.service-card {
    will-change: transform;
}

/* ========================================
   Custom Select Arrow
======================================== */
select.appearance-none {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23627d98' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

/* ========================================
   Selection Color
======================================== */
::selection {
    background: #fbbf24;
    color: #102a43;
}

/* ========================================
   Focus Visible
======================================== */
:focus-visible {
    outline: 2px solid #fbbf24;
    outline-offset: 2px;
}

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

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

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

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

/* ========================================
   Mobile Menu Transition
======================================== */
#mobileMenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
}

#mobileMenu.open {
    max-height: 400px;
    padding-top: 0;
}

/* ========================================
   Responsive Adjustments
======================================== */
@media (max-width: 767px) {
    .shape-circle-1 {
        width: 250px;
        height: 250px;
    }
    
    .shape-circle-2 {
        width: 150px;
        height: 150px;
    }
    
    .shape-square-1 {
        width: 80px;
        height: 80px;
    }
    
    .shape-triangle-1 {
        border-left: 40px solid transparent;
        border-right: 40px solid transparent;
        border-bottom: 69px solid rgba(251, 191, 36, 0.05);
    }
}
