:root {
    --mgwdvp-accent: #384d86;
    --mgwdvp-pill-bg: #ffffff;
    --mgwdvp-pill-text: #1f2937;
    --mgwdvp-panel-bg: #ffffff;
    --mgwdvp-panel-text: #111827;
    --mgwdvp-border: rgba(17, 24, 39, 0.14);
    --mgwdvp-shadow: 0 10px 30px rgba(15, 23, 42, 0.12);
    --mgwdvp-radius-pill: 999px;
    --mgwdvp-radius-panel: 18px;
}

.mgwdvp-root {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    font-family: inherit;
}

.mgwdvp-root[hidden] {
    display: none !important;
}

.mgwdvp-root.mgwdvp-is-floating {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
}

body.mgwdvp-floating-top-left .mgwdvp-root.mgwdvp-is-floating {
    left: 20px;
    right: auto;
}

.mgwdvp-root .mgwdvp-shell {
    position: relative;
}

.mgwdvp-trigger {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    padding: 8px 14px;
    border: 1px solid var(--mgwdvp-border);
    border-radius: var(--mgwdvp-radius-pill);
    background: var(--mgwdvp-pill-bg);
    color: var(--mgwdvp-pill-text);
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.08);
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.mgwdvp-trigger:hover,
.mgwdvp-trigger:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.12);
    border-color: color-mix(in srgb, var(--mgwdvp-accent) 30%, transparent);
    outline: none;
}

.mgwdvp-trigger__icon {
    font-size: 15px;
    line-height: 1;
}

.mgwdvp-panel {
    position: fixed;
    top: 50%;
    left: 50%;
    right: auto;
    width: min(380px, calc(100vw - 24px));
    max-height: min(78vh, 620px);
    transform: translate(-50%, -50%);
    background: var(--mgwdvp-panel-bg);
    color: var(--mgwdvp-panel-text);
    border: 1px solid var(--mgwdvp-border);
    border-radius: var(--mgwdvp-radius-panel);
    box-shadow: var(--mgwdvp-shadow);
    overflow: auto;
    z-index: 10001;
}

.mgwdvp-root.mgwdvp-panel-open::before {
    content: '';
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.18);
    z-index: 10000;
}

html.mgwdvp-modal-open {
    overflow: hidden;
}

.mgwdvp-panel[hidden] {
    display: none !important;
}

.mgwdvp-panel__header,
.mgwdvp-panel__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
}

.mgwdvp-panel__header {
    border-bottom: 1px solid var(--mgwdvp-border);
}

.mgwdvp-panel__title {
    font-size: 15px;
    line-height: 1.3;
}

.mgwdvp-panel__close,
.mgwdvp-reset {
    border: 1px solid var(--mgwdvp-border);
    background: transparent;
    color: inherit;
    border-radius: 10px;
    min-height: 34px;
    padding: 6px 10px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
}

.mgwdvp-panel__close {
    min-width: 34px;
    padding: 0;
    font-size: 22px;
    line-height: 1;
}

.mgwdvp-panel__body {
    display: grid;
    gap: 14px;
    padding: 16px;
}

.mgwdvp-control__group {
    display: grid;
    gap: 8px;
}

.mgwdvp-control__label {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.mgwdvp-segmented {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
}

.mgwdvp-choice {
    min-height: 34px;
    padding: 7px 12px;
    border-radius: 999px;
    border: 1px solid var(--mgwdvp-border);
    background: transparent;
    color: inherit;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.mgwdvp-choice.is-active,
.mgwdvp-choice:hover,
.mgwdvp-choice:focus-visible,
.mgwdvp-reset:hover,
.mgwdvp-reset:focus-visible,
.mgwdvp-panel__close:hover,
.mgwdvp-panel__close:focus-visible {
    border-color: color-mix(in srgb, var(--mgwdvp-accent) 35%, transparent);
    background: color-mix(in srgb, var(--mgwdvp-accent) 9%, transparent);
    outline: none;
}

.mgwdvp-root-manual {
    margin-left: 8px;
}

.mgwdvp-root.mgwdvp-fallback-insert {
    margin-left: 12px;
}

@media (max-width: 980px) {
    .mgwdvp-root.mgwdvp-is-floating {
        top: 14px;
        right: 14px;
    }

    body.mgwdvp-floating-top-left .mgwdvp-root.mgwdvp-is-floating {
        left: 14px;
        right: auto;
    }

    .mgwdvp-trigger {
        min-height: 36px;
        padding: 8px 12px;
        font-size: 13px;
    }

    .mgwdvp-panel {
        width: min(340px, calc(100vw - 20px));
        max-height: 82vh;
    }
}

body.mgwdvp-hide-divi-search.mgwdvp-placement-auto_replace #main-header .et_search_outer,
body.mgwdvp-hide-divi-search.mgwdvp-placement-auto_replace #main-header #et_top_search,
body.mgwdvp-hide-divi-search.mgwdvp-placement-auto_replace .et-l--header .et_search_outer,
body.mgwdvp-hide-divi-search.mgwdvp-placement-auto_replace .et-l--header #et_top_search {
    display: none !important;
}

/* Motion reduction */
html.mgwdvp-motion-reduced {
    scroll-behavior: auto !important;
}

html.mgwdvp-motion-reduced *,
html.mgwdvp-motion-reduced *::before,
html.mgwdvp-motion-reduced *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0ms !important;
    scroll-behavior: auto !important;
}

html.mgwdvp-motion-reduced .et_pb_animation_top,
html.mgwdvp-motion-reduced .et_pb_animation_bottom,
html.mgwdvp-motion-reduced .et_pb_animation_left,
html.mgwdvp-motion-reduced .et_pb_animation_right,
html.mgwdvp-motion-reduced .et_pb_animation_fade_in,
html.mgwdvp-motion-reduced .et-waypoint,
html.mgwdvp-motion-reduced [class*="et_pb_animation"],
html.mgwdvp-motion-reduced [style*="transform"] {
    opacity: 1 !important;
    transform: none !important;
}

/* Font size */
html.mgwdvp-font-large {
    font-size: 112.5%;
}

html.mgwdvp-font-larger {
    font-size: 125%;
}

/* Theme overlay */
html.mgwdvp-theme-dark {
    color-scheme: dark;
    --mgwdvp-border: rgba(255, 255, 255, 0.16);
    --mgwdvp-shadow: 0 14px 32px rgba(0, 0, 0, 0.35);
}

html.mgwdvp-theme-dark body,
html.mgwdvp-theme-dark #page-container,
html.mgwdvp-theme-dark .et-l,
html.mgwdvp-theme-dark .et-l--body,
html.mgwdvp-theme-dark .et-l--header,
html.mgwdvp-theme-dark .et-l--footer,
html.mgwdvp-theme-dark .et_pb_section,
html.mgwdvp-theme-dark .et_pb_row,
html.mgwdvp-theme-dark .et_pb_column,
html.mgwdvp-theme-dark .et_pb_module,
html.mgwdvp-theme-dark .et_pb_with_background,
html.mgwdvp-theme-dark .et_pb_post,
html.mgwdvp-theme-dark .et_pb_blog_grid .et_pb_post,
html.mgwdvp-theme-dark .et_pb_pricing,
html.mgwdvp-theme-dark .et_pb_team_member,
html.mgwdvp-theme-dark .et_pb_blurb,
html.mgwdvp-theme-dark .et_pb_tabs,
html.mgwdvp-theme-dark .et_pb_tab,
html.mgwdvp-theme-dark .et_pb_toggle,
html.mgwdvp-theme-dark .et_pb_accordion_item,
html.mgwdvp-theme-dark .et_pb_testimonial,
html.mgwdvp-theme-dark .et_pb_promo,
html.mgwdvp-theme-dark .et_pb_text,
html.mgwdvp-theme-dark .et_pb_text_inner,
html.mgwdvp-theme-dark .et_pb_code_inner,
html.mgwdvp-theme-dark .et_pb_wc_add_to_cart form.cart,
html.mgwdvp-theme-dark .et_pb_shop ul.products li.product,
html.mgwdvp-theme-dark .woocommerce,
html.mgwdvp-theme-dark .woocommerce-page {
    background-color: #101114 !important;
    color: #f5f7fb !important;
}

html.mgwdvp-theme-dark h1,
html.mgwdvp-theme-dark h2,
html.mgwdvp-theme-dark h3,
html.mgwdvp-theme-dark h4,
html.mgwdvp-theme-dark h5,
html.mgwdvp-theme-dark h6,
html.mgwdvp-theme-dark p,
html.mgwdvp-theme-dark li,
html.mgwdvp-theme-dark span,
html.mgwdvp-theme-dark div,
html.mgwdvp-theme-dark label,
html.mgwdvp-theme-dark td,
html.mgwdvp-theme-dark th,
html.mgwdvp-theme-dark input,
html.mgwdvp-theme-dark textarea,
html.mgwdvp-theme-dark select,
html.mgwdvp-theme-dark .et_pb_module a:not(.et_pb_button),
html.mgwdvp-theme-dark .woocommerce a:not(.button),
html.mgwdvp-theme-dark a {
    color: #f5f7fb !important;
}

html.mgwdvp-theme-dark a {
    text-decoration-color: rgba(245, 247, 251, 0.5);
}

html.mgwdvp-theme-dark .et_pb_button,
html.mgwdvp-theme-dark .button,
html.mgwdvp-theme-dark button,
html.mgwdvp-theme-dark input[type="submit"] {
    background: #1c2340 !important;
    border-color: #8799d1 !important;
    color: #ffffff !important;
}

html.mgwdvp-theme-dark input,
html.mgwdvp-theme-dark textarea,
html.mgwdvp-theme-dark select {
    background: #121826 !important;
    color: #f5f7fb !important;
    border-color: rgba(255, 255, 255, 0.18) !important;
}

/* High contrast */
html.mgwdvp-contrast-high body,
html.mgwdvp-contrast-high #page-container,
html.mgwdvp-contrast-high .et-l,
html.mgwdvp-contrast-high .et_pb_section,
html.mgwdvp-contrast-high .et_pb_row,
html.mgwdvp-contrast-high .et_pb_module,
html.mgwdvp-contrast-high .et_pb_text,
html.mgwdvp-contrast-high .et_pb_text_inner {
    color: #0b0b0b !important;
}

html.mgwdvp-contrast-high a,
html.mgwdvp-contrast-high button,
html.mgwdvp-contrast-high .et_pb_button {
    text-decoration-thickness: 2px;
}

html.mgwdvp-theme-dark.mgwdvp-contrast-high body,
html.mgwdvp-theme-dark.mgwdvp-contrast-high #page-container,
html.mgwdvp-theme-dark.mgwdvp-contrast-high .et-l,
html.mgwdvp-theme-dark.mgwdvp-contrast-high .et_pb_section,
html.mgwdvp-theme-dark.mgwdvp-contrast-high .et_pb_row,
html.mgwdvp-theme-dark.mgwdvp-contrast-high .et_pb_module,
html.mgwdvp-theme-dark.mgwdvp-contrast-high .et_pb_text,
html.mgwdvp-theme-dark.mgwdvp-contrast-high .et_pb_text_inner,
html.mgwdvp-theme-dark.mgwdvp-contrast-high p,
html.mgwdvp-theme-dark.mgwdvp-contrast-high li,
html.mgwdvp-theme-dark.mgwdvp-contrast-high span,
html.mgwdvp-theme-dark.mgwdvp-contrast-high div,
html.mgwdvp-theme-dark.mgwdvp-contrast-high a,
html.mgwdvp-theme-dark.mgwdvp-contrast-high h1,
html.mgwdvp-theme-dark.mgwdvp-contrast-high h2,
html.mgwdvp-theme-dark.mgwdvp-contrast-high h3,
html.mgwdvp-theme-dark.mgwdvp-contrast-high h4,
html.mgwdvp-theme-dark.mgwdvp-contrast-high h5,
html.mgwdvp-theme-dark.mgwdvp-contrast-high h6 {
    color: #ffffff !important;
}
