/* Rise Personal - Wix to Static Migration Fixes */

/* 1. UNPAUSE ALL ANIMATIONS */
[data-motion-enter]:not([data-motion-enter="done"]) {
    animation-play-state: running !important;
}

/* Ensure animations complete properly */
@media (prefers-reduced-motion: no-preference) {
    [data-motion-enter]:not([data-motion-enter="done"]) {
        animation-play-state: running !important;
        animation-fill-mode: forwards !important;
    }
}

/* 2. FONT FIXES - Replace Wix CDN fonts */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,400;0,700;1,400;1,700&family=Helvetica&display=swap');

/* Override font-face declarations to use Google Fonts */
* {
    font-family: 'Montserrat', 'Helvetica', Arial, sans-serif !important;
}

/* 3. MOBILE RESPONSIVENESS */
/* Make containers fluid */
#c1dmp, 
#comp-lf4jvw10, 
#comp-lf8xpfbi, 
#comp-lf4jvw11, 
#comp-lfadtkaq, 
#comp-lf4jvw111, 
#comp-lf947pu3 {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
}

/* Make all grid containers responsive */
[data-mesh-id$="inlineContent-gridContainer"] {
    width: 100% !important;
    padding: 0 20px !important;
    box-sizing: border-box !important;
}

/* Make all sections responsive */
#comp-kpmmpn3f,
#comp-kpmo2tso,
#comp-kpmo8zok,
#comp-lf947pvo2 {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
}

/* Fix section backgrounds */
#comp-kpmmpn4w,
#comp-kpmo2tuf,
#comp-kpmo8zqa,
#comp-lf947pvw1 {
    width: 100% !important;
    min-width: 0 !important;
}

/* 4. MOBILE BREAKPOINTS */
@media (max-width: 768px) {
    /* Reset all fixed margins and positions */
    [data-mesh-id$="inlineContent-gridContainer"] > *,
    [data-mesh-id$="inlineContent-gridContainer"] > interact-element > * {
        position: relative !important;
        margin: 10px auto !important;
        left: 0 !important;
        right: 0 !important;
        width: calc(100% - 40px) !important;
        max-width: 500px !important;
    }
    
    /* Stack elements vertically on mobile */
    [data-mesh-id$="inlineContent-gridContainer"] {
        grid-template-columns: 1fr !important;
        padding: 10px !important;
    }
    
    /* Make text sections responsive */
    #comp-kpmnf522,
    #comp-kpmngd4v,
    #comp-lf8y8l9a,
    #comp-kpmod20x,
    #comp-lfb2yvd2,
    #comp-lf8xpfel,
    #comp-lfadtki1,
    #comp-lfadtki9,
    #comp-lf9dtyv6,
    #comp-kpmousd8,
    #comp-kpmov7y7,
    #comp-kpmowyc0,
    #comp-kpmox7pt,
    #comp-kpmow97a,
    #comp-kpmowe0g,
    #comp-kpmoxcdz,
    #comp-kpmoxixv,
    #comp-lf947pw1,
    #comp-lf947pw51 {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    /* Make buttons responsive */
    #comp-kpmnhowo,
    #comp-kpmni82o,
    #comp-kpmofl4p,
    #comp-lf94i25u {
        width: auto !important;
        min-width: 140px !important;
        margin: 10px auto !important;
        display: block !important;
    }
    
    /* Make images responsive */
    #comp-lfadtkh6,
    #comp-lfadtkhx {
        width: 80px !important;
        height: auto !important;
        margin: 10px auto !important;
    }
    
    /* Center icons */
    #comp-kpmpa4wu,
    #comp-kpmpc2jn,
    #comp-kpmpbfkd,
    #comp-kpmpcc84 {
        margin: 20px auto !important;
    }
    
    /* Make gallery responsive */
    #comp-lfadtkid {
        width: calc(100% - 20px) !important;
        margin: 20px 10px !important;
        height: auto !important;
        min-height: 200px !important;
    }
    
    /* Center divider */
    #comp-lf9dvb1f {
        margin: 20px auto !important;
    }
}

/* 5. HEADER/NAVIGATION FIXES */
/* Ensure header is always visible */
.site-header,
nav,
.navigation {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* 6. GALLERY FIXES */
/* Ensure gallery components are visible */
#comp-lfadtkid,
.gallery,
.portfolio {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    overflow: visible !important;
}

/* 7. BUTTON FIXES */
/* Ensure all buttons are clickable and visible */
button,
.button,
[role="button"],
#comp-kpmnhowo,
#comp-kpmni82o,
#comp-kpmofl4p,
#comp-lf94i25u {
    cursor: pointer !important;
    pointer-events: auto !important;
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    z-index: 10 !important;
}

/* 8. FORM FIXES */
form,
.form,
.contact-form {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* 9. GENERAL VISIBILITY FIXES */
/* Ensure all content is visible */
* {
    visibility: visible !important;
}

/* Remove potential blocking overlays */
.wix-ads,
.wix-overlay,
.loading-overlay {
    display: none !important;
}

/* 10. IMAGE FIXES */
img {
    max-width: 100% !important;
    height: auto !important;
}

/* 11. TEXT FIXES */
/* Ensure text is readable on mobile */
@media (max-width: 768px) {
    p, span, div, h1, h2, h3, h4, h5, h6 {
        font-size: 14px !important;
        line-height: 1.4 !important;
    }
    
    h1 {
        font-size: 24px !important;
    }
    
    h2 {
        font-size: 20px !important;
    }
    
    h3 {
        font-size: 18px !important;
    }
}

/* 12. PREVENT HORIZONTAL SCROLL */
html, body {
    overflow-x: hidden !important;
    max-width: 100% !important;
}

/* 13. FLEXBOX FALLBACKS */
/* For better mobile support */
.flex-container {
    display: flex !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
}

/* 14. GRID FALLBACKS */
/* Ensure grid works on older browsers */
.grid-container {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 20px !important;
}

@media (min-width: 768px) {
    .grid-container {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)) !important;
    }
}