/* ============================================
   Wise Construction Improvement - Custom Styles
   ============================================ */

/* Custom Properties */
:root {
    --color-forest-950: #08140d;
    --color-forest-900: #0f271a;
    --color-forest-800: #1a3a2a;
    --color-gold-400: #d4af37;
    --color-gold-500: #c9a227;
}

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

body {
    overflow-x: hidden;
}

/* Selection Color */
::selection {
    background-color: rgba(201, 162, 39, 0.3);
    color: #faf9f6;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #08140d;
}
::-webkit-scrollbar-thumb {
    background: #1a3a2a;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #2a4a2e;
}

/* ============================================
   Floating Card Animations
   ============================================ */
.floating-card {
    animation: float 6s ease-in-out infinite;
}

.floating-card:nth-child(1) {
    animation-delay: 0s;
}
.floating-card:nth-child(2) {
    animation-delay: -1.5s;
}
.floating-card:nth-child(3) {
    animation-delay: -3s;
}
.floating-card:nth-child(4) {
    animation-delay: -4.5s;
}

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

/* ============================================
   Scroll Reveal Animations
   ============================================ */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* ============================================
   Navbar Scroll State
   ============================================ */
.nav-scrolled {
    background: rgba(8, 20, 13, 0.92) !important;
    backdrop-filter: blur(20px) !important;
    border-bottom: 1px solid rgba(26, 58, 42, 0.6) !important;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3) !important;
}

.nav-scrolled .navbar-logo {
    filter: brightness(1.1);
}

/* ============================================
   Gold Gradient Text Utility
   ============================================ */
.text-gold-gradient {
    background: linear-gradient(135deg, #e8d5a0, #d4af37, #c9a227);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ============================================
   Card Hover Effects
   ============================================ */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--color-gold-400), transparent);
    opacity: 0;
    transition: opacity 0.5s ease;
}

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

/* ============================================
   Button Ripple Effect
   ============================================ */
.btn-gold {
    position: relative;
    overflow: hidden;
}

.btn-gold::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-gold:active::after {
    width: 300px;
    height: 300px;
}

/* ============================================
   Image Hover Zoom
   ============================================ */
.project-card img {
    transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover img {
    transform: scale(1.08);
}

/* ============================================
   Input Focus Glow
   ============================================ */
input:focus,
select:focus,
textarea:focus {
    box-shadow: 0 0 0 1px rgba(201, 162, 39, 0.3), 
                0 0 20px rgba(201, 162, 39, 0.08);
}

/* ============================================
   Mobile Menu Transitions
   ============================================ */
#mobileMenu {
    animation: slideDown 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

#mobileMenu.hidden {
    animation: slideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUp {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(-10px);
    }
}

/* ============================================
   Reduced Motion
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .floating-card {
        animation: none;
    }
}

/* ============================================
   Responsive Adjustments
   ============================================ */
@media (max-width: 768px) {
    .floating-card {
        position: relative !important;
        top: auto !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
        width: 100% !important;
        margin-bottom: 1rem;
        animation: none !important;
    }
    
    #hero .relative {
        height: auto !important;
    }
}
