/**
 * IP Live Centre - CSS Priority Override
 * This file ensures plugin styles take priority over theme and page builder styles
 * All plugin content is wrapped in .microservice-cont for precise targeting
 *
 * STRATEGY:
 * 1. Main plugin styles: livematchdetail.min.css (CDN) - loaded with priority 999
 * 2. This file adds !important to critical properties to override theme/builders
 * 3. Uses high specificity selectors to beat page builder styles
 */

/* ============================================
   CRITICAL: Isolate plugin container from theme
   ============================================ */

/* Ensure box-sizing is consistent throughout plugin */
.microservice-cont,
.microservice-cont *,
.microservice-cont *::before,
.microservice-cont *::after {
    box-sizing: border-box !important;
}

/* ============================================
   Override WordPress/Theme Content Wrappers
   ============================================ */

/* High specificity to beat Elementor, Divi, WPBakery, etc. */
body .entry-content .microservice-cont,
body .post-content .microservice-cont,
body .page-content .microservice-cont,
body .site-content .microservice-cont,
body article .microservice-cont,
body main .microservice-cont,
body div .microservice-cont,
.elementor .microservice-cont,
.et-db .microservice-cont,
.vc_row .microservice-cont {
    max-width: none !important;
    width: auto !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* ============================================
   Prevent Spacing Interference
   ============================================ */

/* Prevent theme from adding unwanted spacing to first/last children */
.microservice-cont > *:first-child {
    margin-top: 0 !important;
}

.microservice-cont > *:last-child {
    margin-bottom: 0 !important;
}

/* ============================================
   Page Builder Overrides
   ============================================ */

/* Elementor */
.elementor-widget-container .microservice-cont {
    all: unset !important;
    display: block !important;
}

/* Divi Builder */
.et_pb_module .microservice-cont {
    all: unset !important;
    display: block !important;
}

/* WPBakery (Visual Composer) */
.wpb_wrapper .microservice-cont {
    all: unset !important;
    display: block !important;
}

/* Beaver Builder */
.fl-module-content .microservice-cont {
    all: unset !important;
    display: block !important;
}

/* ============================================
   Font Inheritance Protection
   ============================================ */

/* Ensure fonts load correctly inside plugin */
.microservice-cont {
    font-family: 'Lexend Deca', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif !important;
}

/* ============================================
   Common Theme/Builder Style Resets
   ============================================ */

/* Reset common interfering styles but preserve plugin's own styles */
body .microservice-cont {
    line-height: normal !important;
    font-size: medium !important;
    color: inherit !important;
    background: transparent !important;
}
