/* Home page sections (Admin > CMS & Frontend > Custom Scripts & CSS).
   Everything is scoped under .mxh and follows the site theme colours. The class names are fixed: sections
   already saved on a site pick up any change made here. Scroll animations come from frontend/js/home-sections.js;
   without it (or with reduced motion) everything is simply shown. */
.mxh {
    --mxh-primary: var(--theme-primary, #1e293b);
    --mxh-accent: var(--theme-accent, #2563eb);
    --mxh-accent-soft: color-mix(in srgb, var(--mxh-accent) 10%, #fff);
    --mxh-grad: linear-gradient(135deg, var(--mxh-accent) 0%, color-mix(in srgb, var(--mxh-accent) 55%, var(--mxh-primary)) 100%);
    --mxh-ink: #0b1220;
    --mxh-text: #3f4a5c;
    --mxh-muted: #667085;
    --mxh-line: #e7eaf0;
    --mxh-soft: #f7f8fa;
    --mxh-surface: #ffffff;
    --mxh-radius: 18px;
    --mxh-shadow: 0 1px 2px rgba(16,24,40,.04), 0 8px 24px -16px rgba(16,24,40,.18);
    --mxh-shadow-hover: 0 1px 2px rgba(16,24,40,.05), 0 12px 28px -14px rgba(16,24,40,.22);
    --mxh-line-hover: #d0d5dd;
    color: var(--mxh-text);
    font-size: 15px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}
.mxh *, .mxh *::before, .mxh *::after { box-sizing: border-box; }
.mxh h2, .mxh h3, .mxh h4 { color: var(--mxh-ink); margin: 0; line-height: 1.2; letter-spacing: -.02em; }
.mxh p { margin: 0; }
.mxh a { text-decoration: none; }
.mxh svg { flex-shrink: 0; }

/* section + heading */
.mxh-section { margin: 0 0 104px; }
.mxh-head { max-width: 660px; margin: 0 auto 48px; text-align: center; }
.mxh-eyebrow { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 16px; padding: 6px 14px; border-radius: 999px; background: var(--mxh-accent-soft); border: 1px solid color-mix(in srgb, var(--mxh-accent) 18%, transparent); color: var(--mxh-accent); font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.mxh-eyebrow::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 3px color-mix(in srgb, var(--mxh-accent) 22%, transparent); }
.mxh-head h2 { font-size: clamp(27px, 3.5vw, 40px); font-weight: 800; }
.mxh-head p { margin-top: 16px; font-size: 16.5px; color: var(--mxh-muted); line-height: 1.65; }

/* buttons */
.mxh-btn { position: relative; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 24px; border-radius: 12px; font-size: 15px; font-weight: 650; line-height: 1; white-space: nowrap; border: 1px solid transparent; transition: transform .2s ease, background .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease; }
.mxh-btn:hover { transform: translateY(-1px); }
.mxh-btn:active { transform: translateY(0); }
.mxh-btn-accent { background: var(--mxh-grad); color: #fff !important; box-shadow: 0 10px 24px -10px color-mix(in srgb, var(--mxh-accent) 75%, transparent); }
.mxh-btn-accent:hover { box-shadow: 0 16px 32px -12px color-mix(in srgb, var(--mxh-accent) 85%, transparent); }
.mxh-btn-accent::after { content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.35), transparent); transform: skewX(-20deg); animation: mxh-shine 4.5s ease-in-out infinite; }
.mxh-btn-light { background: var(--mxh-surface); color: var(--mxh-ink) !important; border-color: var(--mxh-line); box-shadow: 0 1px 2px rgba(16,24,40,.05); }
.mxh-btn-light:hover { border-color: var(--mxh-line-hover, #d0d5dd); background: var(--mxh-soft); }
.mxh-btn-ghost { background: rgba(255,255,255,.06); color: #fff !important; border-color: rgba(255,255,255,.3); backdrop-filter: blur(4px); }
.mxh-btn-ghost:hover { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.5); }

/* shared icon tile: theme gradient, soft glow */
.mxh-hl-icon, .mxh-service-icon, .mxh-feature-icon { position: relative; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; color: #fff; background: var(--mxh-grad); box-shadow: 0 6px 14px -8px color-mix(in srgb, var(--mxh-accent) 70%, transparent), inset 0 1px 0 rgba(255,255,255,.25); }

/* 1. highlights: four floating tiles */
.mxh-highlights { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 8px 0 104px; }
.mxh-hl { display: flex; align-items: flex-start; gap: 14px; padding: 22px 20px; border: 1px solid var(--mxh-line); border-radius: var(--mxh-radius); background: var(--mxh-surface); box-shadow: var(--mxh-shadow); transition: box-shadow .25s ease, border-color .25s ease; }
.mxh-hl:hover { box-shadow: var(--mxh-shadow-hover); border-color: var(--mxh-line-hover); }
.mxh-hl-icon { width: 44px; height: 44px; border-radius: 12px; }
.mxh-hl-icon svg { width: 21px; height: 21px; }
.mxh-hl h3 { font-size: 15.5px; font-weight: 700; letter-spacing: -.01em; }
.mxh-hl p { margin-top: 4px; font-size: 13.5px; color: var(--mxh-muted); line-height: 1.5; }

/* 2. service cards */
.mxh-services { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.mxh-service { position: relative; overflow: hidden; display: flex; flex-direction: column; padding: 30px 24px 24px; border: 1px solid var(--mxh-line); border-radius: var(--mxh-radius); background: var(--mxh-surface); color: inherit !important; box-shadow: var(--mxh-shadow); transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
.mxh-service:hover { transform: translateY(-2px); box-shadow: var(--mxh-shadow-hover); border-color: var(--mxh-line-hover); }
.mxh-service-icon { width: 54px; height: 54px; margin-bottom: 24px; border-radius: 15px; }
.mxh-service-icon svg { width: 26px; height: 26px; }
.mxh-service h3 { font-size: 18.5px; font-weight: 750; }
.mxh-service > p { margin-top: 8px; font-size: 14.5px; color: var(--mxh-muted); line-height: 1.6; }
.mxh-service .mxh-list { display: none; }
.mxh-list { list-style: none; margin: 16px 0 20px; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.mxh-list li { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; color: var(--mxh-text); }
.mxh-list li::before { content: ""; width: 18px; height: 18px; margin-top: 2px; flex-shrink: 0; background: var(--mxh-accent); -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / contain no-repeat; }
.mxh-service-link { position: relative; margin-top: auto; padding-top: 22px; display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; color: var(--mxh-accent); }
.mxh-service-link svg { transition: transform .25s ease; }
.mxh-service:hover .mxh-service-link svg { transform: translateX(3px); }

/* 3. steps: numbered circles on a connecting line */
.mxh-steps { position: relative; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; counter-reset: mxh-step; }
.mxh-steps::before { content: ""; position: absolute; top: 28px; left: 12.5%; right: 12.5%; height: 2px; background: repeating-linear-gradient(90deg, color-mix(in srgb, var(--mxh-accent) 45%, transparent) 0 8px, transparent 8px 16px); }
.mxh-step { position: relative; text-align: center; padding: 0 8px; }
.mxh-step-num { position: relative; z-index: 1; width: 56px; height: 56px; margin: 0 auto 22px; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: var(--mxh-grad); color: #fff; font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums lining-nums; box-shadow: 0 0 0 6px var(--mxh-surface), 0 0 0 7px color-mix(in srgb, var(--mxh-accent) 22%, transparent), 0 10px 20px -10px color-mix(in srgb, var(--mxh-accent) 70%, transparent); }
.mxh-step-num::after { content: ""; position: absolute; inset: -7px; border-radius: 50%; border: 2px solid color-mix(in srgb, var(--mxh-accent) 40%, transparent); opacity: 0; animation: mxh-ring 3.2s ease-out infinite; }
.mxh-step:nth-child(2) .mxh-step-num::after { animation-delay: .8s; }
.mxh-step:nth-child(3) .mxh-step-num::after { animation-delay: 1.6s; }
.mxh-step:nth-child(4) .mxh-step-num::after { animation-delay: 2.4s; }
.mxh-step h3 { font-size: 17.5px; font-weight: 750; }
.mxh-step p { margin-top: 8px; font-size: 14.5px; color: var(--mxh-muted); line-height: 1.6; }

/* 4. features: soft cards */
.mxh-features { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.mxh-feature { display: flex; flex-direction: column; gap: 18px; padding: 26px 24px; border-radius: var(--mxh-radius); border: 1px solid var(--mxh-line); background: linear-gradient(180deg, var(--mxh-surface) 0%, var(--mxh-soft) 100%); transition: box-shadow .25s ease, border-color .25s ease; }
.mxh-feature:hover { box-shadow: var(--mxh-shadow-hover); border-color: var(--mxh-line-hover); }
.mxh-feature-icon { width: 46px; height: 46px; border-radius: 13px; }
.mxh-feature-icon svg { width: 21px; height: 21px; }
.mxh-feature h3 { font-size: 16.5px; font-weight: 750; }
.mxh-feature p { margin-top: 6px; font-size: 14.5px; color: var(--mxh-muted); line-height: 1.6; }

/* 5. API / reseller band: moving theme gradient with soft light */
.mxh-band { position: relative; overflow: hidden; isolation: isolate; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 48px; align-items: center; padding: 60px; border-radius: 24px; color: rgba(255,255,255,.8);
    background: linear-gradient(120deg, var(--mxh-primary) 0%, color-mix(in srgb, var(--mxh-primary) 70%, var(--mxh-accent)) 50%, var(--mxh-primary) 100%); background-size: 200% 200%; animation: mxh-pan 14s ease-in-out infinite; box-shadow: 0 30px 60px -30px color-mix(in srgb, var(--mxh-primary) 80%, transparent); }
.mxh-band::before, .mxh-band::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; pointer-events: none; }
.mxh-band::before { width: 420px; height: 420px; top: -180px; right: -120px; background: radial-gradient(circle, rgba(255,255,255,.16) 0%, transparent 65%); animation: mxh-float 9s ease-in-out infinite; }
.mxh-band::after { width: 320px; height: 320px; bottom: -160px; left: -80px; background: radial-gradient(circle, color-mix(in srgb, var(--mxh-accent) 45%, transparent) 0%, transparent 65%); animation: mxh-float 11s ease-in-out infinite reverse; }
.mxh-band .mxh-eyebrow { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.2); color: #fff; }
.mxh-band .mxh-eyebrow::before { box-shadow: 0 0 0 3px rgba(255,255,255,.2); }
.mxh-band h2 { color: #fff; font-size: clamp(26px, 3.1vw, 36px); font-weight: 800; }
.mxh-band p { margin-top: 14px; font-size: 16px; line-height: 1.65; }
.mxh-band-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.mxh-band .mxh-btn-light { border-color: #fff; }
.mxh-band-card { padding: 28px; border-radius: 18px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16); backdrop-filter: blur(6px); }
.mxh-band-card .mxh-list { margin: 0; gap: 16px; }
.mxh-band-card .mxh-list li { color: #fff; font-size: 15px; font-weight: 500; }
.mxh-band-card .mxh-list li::before { width: 22px; height: 22px; margin-top: 0; padding: 4px; border-radius: 50%; background: #fff; opacity: .95; -webkit-mask-size: 14px; mask-size: 14px; }

/* 6. FAQ: separate rounded rows */
.mxh-faq { max-width: 800px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.mxh-faq details { border: 1px solid var(--mxh-line); border-radius: 14px; background: var(--mxh-surface); transition: border-color .25s ease, box-shadow .25s ease; }
.mxh-faq details:hover { border-color: var(--mxh-line-hover); }
.mxh-faq details[open] { border-color: color-mix(in srgb, var(--mxh-accent) 40%, var(--mxh-line)); box-shadow: var(--mxh-shadow-hover); }
.mxh-faq summary { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 22px; cursor: pointer; list-style: none; color: var(--mxh-ink); font-size: 16.5px; font-weight: 650; letter-spacing: -.01em; }
.mxh-faq summary::-webkit-details-marker { display: none; }
.mxh-faq summary::after { content: ""; width: 30px; height: 30px; flex-shrink: 0; border-radius: 50%; background: var(--mxh-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23667085' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center / 16px no-repeat; border: 1px solid var(--mxh-line); transition: transform .3s ease, background-color .3s ease; }
.mxh-faq details[open] summary::after { transform: rotate(135deg); background-color: var(--mxh-accent-soft); border-color: color-mix(in srgb, var(--mxh-accent) 25%, transparent); }
.mxh-faq details > p { padding: 0 64px 22px 22px; font-size: 15px; color: var(--mxh-muted); line-height: 1.7; }
.mxh-faq details[open] > p { animation: mxh-drop .35s ease; }

/* 7. closing call to action: gradient band */
.mxh-cta { position: relative; overflow: hidden; isolation: isolate; display: flex; align-items: center; justify-content: space-between; gap: 32px; padding: 48px 52px; border-radius: 24px; background: var(--mxh-grad); box-shadow: 0 30px 60px -30px color-mix(in srgb, var(--mxh-accent) 80%, transparent); }
.mxh-cta::before { content: ""; position: absolute; z-index: -1; inset: 0; background-image: radial-gradient(rgba(255,255,255,.18) 1px, transparent 1px); background-size: 18px 18px; -webkit-mask-image: linear-gradient(90deg, transparent, #000 70%); mask-image: linear-gradient(90deg, transparent, #000 70%); }
.mxh-cta::after { content: ""; position: absolute; z-index: -1; width: 300px; height: 300px; top: -140px; left: 30%; border-radius: 50%; background: radial-gradient(circle, rgba(255,255,255,.22) 0%, transparent 65%); animation: mxh-float 10s ease-in-out infinite; }
.mxh-cta h2 { color: #fff; font-size: clamp(23px, 2.7vw, 30px); font-weight: 800; }
.mxh-cta p { margin-top: 8px; color: rgba(255,255,255,.85); font-size: 16px; }
.mxh-cta-actions { display: flex; flex-wrap: wrap; gap: 12px; flex-shrink: 0; }
.mxh-cta .mxh-btn-accent { background: #fff; color: var(--mxh-accent) !important; box-shadow: 0 12px 24px -12px rgba(0,0,0,.35); }
.mxh-cta .mxh-btn-accent::after { background: linear-gradient(100deg, transparent, color-mix(in srgb, var(--mxh-accent) 20%, transparent), transparent); }
.mxh-cta .mxh-btn-light { background: rgba(255,255,255,.12); color: #fff !important; border-color: rgba(255,255,255,.4); box-shadow: none; }
.mxh-cta .mxh-btn-light:hover { background: rgba(255,255,255,.2); border-color: rgba(255,255,255,.6); }

/* scroll reveal: home-sections.js puts html.mxh-anim and data-mxh-reveal on the blocks, then .is-in as they come into view */
html.mxh-anim .mxh [data-mxh-reveal] { opacity: 0; transform: translateY(26px); transition: opacity .7s cubic-bezier(.22,.61,.36,1), transform .7s cubic-bezier(.22,.61,.36,1), box-shadow .3s ease, border-color .3s ease; transition-delay: var(--mxh-delay, 0s); }
html.mxh-anim .mxh [data-mxh-reveal="zoom"] { transform: translateY(18px) scale(.97); }
html.mxh-anim .mxh [data-mxh-reveal].is-in { opacity: 1; transform: none; }
/* after the entrance, hover movement works again without the reveal delay */
html.mxh-anim .mxh [data-mxh-reveal].is-done { transition-delay: 0s; }
html.mxh-anim .mxh .mxh-service.is-done:hover { transform: translateY(-2px); }

@keyframes mxh-shine { 0%, 60% { left: -60%; } 100% { left: 130%; } }
@keyframes mxh-ring { 0% { opacity: .9; transform: scale(.9); } 70%, 100% { opacity: 0; transform: scale(1.35); } }
@keyframes mxh-pan { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes mxh-float { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(-24px, 18px); } }
@keyframes mxh-drop { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }

/* tablet */
@media (max-width: 1199px) {
    .mxh-services { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .mxh-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 24px; }
    .mxh-steps::before { display: none; }
    .mxh-highlights { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .mxh-band { grid-template-columns: 1fr; padding: 44px; gap: 32px; }
}
@media (max-width: 991px) {
    .mxh-features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .mxh-cta { flex-direction: column; align-items: flex-start; }
}
/* phone */
@media (max-width: 640px) {
    .mxh { font-size: 14px; }
    .mxh-section { margin-bottom: 72px; }
    .mxh-head { margin-bottom: 32px; }
    .mxh-head p { font-size: 15px; }
    .mxh-highlights { gap: 10px; margin-bottom: 72px; }
    .mxh-hl { flex-direction: column; gap: 12px; padding: 18px 14px; }
    .mxh-hl-icon { width: 40px; height: 40px; }
    .mxh-hl h3 { font-size: 14px; }
    .mxh-hl p { font-size: 12.5px; }
    .mxh-services, .mxh-steps, .mxh-features { grid-template-columns: 1fr; }
    .mxh-service { padding: 24px 20px 20px; }
    .mxh-service-icon { margin-bottom: 18px; }
    .mxh-steps { gap: 0; }
    .mxh-step { display: grid; grid-template-columns: 56px 1fr; column-gap: 16px; text-align: left; padding: 0 0 28px; }
    .mxh-step:not(:last-child)::before { content: ""; position: absolute; top: 60px; bottom: 4px; left: 27px; width: 2px; background: repeating-linear-gradient(180deg, color-mix(in srgb, var(--mxh-accent) 45%, transparent) 0 6px, transparent 6px 12px); }
    .mxh-step-num { grid-row: span 2; margin: 0; }
    .mxh-step h3 { align-self: end; margin-top: 4px; }
    .mxh-feature { flex-direction: row; gap: 14px; padding: 20px 18px; }
    .mxh-band { padding: 34px 22px; border-radius: 20px; }
    .mxh-band-card { padding: 22px 18px; }
    .mxh-band-actions .mxh-btn, .mxh-cta-actions .mxh-btn { flex: 1 1 100%; }
    .mxh-cta { padding: 32px 22px; border-radius: 20px; }
    .mxh-cta-actions { width: 100%; }
    .mxh-faq summary { padding: 16px 16px; font-size: 15px; }
    .mxh-faq details > p { padding: 0 16px 18px; font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) {
    .mxh *, .mxh *::before, .mxh *::after { transition: none !important; animation: none !important; }
    html.mxh-anim .mxh [data-mxh-reveal] { opacity: 1; transform: none; }
}

/* dark mode (html.mx-dark, chosen by the visitor) */
html.mx-dark .mxh { --mxh-ink: #f5f7fa; --mxh-text: #cbd5e1; --mxh-muted: #94a3b8; --mxh-line: rgba(148,163,184,.16); --mxh-soft: #131c30; --mxh-surface: #0f1729; --mxh-accent-soft: color-mix(in srgb, var(--mxh-accent) 18%, transparent); --mxh-shadow: none; --mxh-shadow-hover: 0 12px 28px -16px rgba(0,0,0,.6); --mxh-line-hover: rgba(148,163,184,.32); }
html.mx-dark .mxh-eyebrow { color: color-mix(in srgb, var(--mxh-accent) 60%, #fff); }
html.mx-dark .mxh-service-link { color: color-mix(in srgb, var(--mxh-accent) 60%, #fff); }
html.mx-dark .mxh-band { border: 1px solid rgba(148,163,184,.16); }
html.mx-dark .mxh-band .mxh-btn-light { background: #fff; color: #0b1220 !important; }
html.mx-dark .mxh-faq summary::after { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E"); }
