/* Home: hero artwork stays fixed in the middle of the screen all the way to the footer. */
body.home::before,
body.home::after{
  content:"";position:fixed;z-index:0;top:50%;left:50%;
  width:clamp(420px,110vw,1700px);height:clamp(500px,92vw,1200px);
  transform:translate(-50%,-50%) scale(1.1);
  background:url("../images/hero-bg.webp") center / contain no-repeat;
  pointer-events:none;
}
body.home::before{filter:blur(14px);opacity:.95}
body.home::after{filter:blur(2px);opacity:.65}
body.home .hero::before,body.home .hero::after{display:none}

/* Hero content is pinned; "What we do" slides up and covers it like a sheet. */
body.home .hero{
  --hero-hdr:84px;
  position:sticky;top:0;z-index:1;
  margin-top:calc(-1 * var(--hero-hdr));           /* start under the sticky header */
  min-height:100vh;min-height:100svh;
  display:flex;align-items:center;justify-content:center;
  padding-top:var(--hero-hdr);padding-bottom:calc(var(--hero-hdr) + 2vh); /* content centred on the screen, nudged slightly up */
  background:transparent;
}
@media (max-width:1279px){body.home .hero{--hero-hdr:80px}}
@media (max-width:720px){body.home .hero{--hero-hdr:72px}}
/* title look: light weight, dark text, glass pill word */
body.home .hero h1{font-size:clamp(38px,6.6vw,92px);font-weight:600;line-height:1.1;max-width:none;letter-spacing:-.02em;color:#000}
/* liquid glass pill */
body.home .hero .glass-word{
  display:inline-flex;align-items:center;justify-content:center;
  line-height:1;padding:.04em .36em .17em;vertical-align:middle;
  font-weight:600;color:rgba(255,255,255,.95);
  text-shadow:0 2px 14px rgba(40,90,75,.55);
  background:
    radial-gradient(120% 140% at 20% 0%,rgba(255,255,255,.55) 0%,rgba(255,255,255,0) 55%),
    linear-gradient(180deg,rgba(255,255,255,.30),rgba(255,255,255,.10));
  border:1px solid rgba(255,255,255,.75);
  -webkit-backdrop-filter:blur(10px) saturate(180%) brightness(1.08);
  backdrop-filter:blur(10px) saturate(180%) brightness(1.08);
  -webkit-backdrop-filter:url(#liquid-glass) blur(6px) saturate(180%) brightness(1.1);
  backdrop-filter:url(#liquid-glass) blur(6px) saturate(180%) brightness(1.1);
  box-shadow:
    inset 0 2px 1px rgba(255,255,255,.95),
    inset 0 -3px 8px rgba(255,255,255,.35),
    inset 8px 0 14px -8px rgba(255,255,255,.7),
    inset -8px 0 14px -8px rgba(255,255,255,.7),
    0 18px 40px -18px rgba(12,100,75,.35);
}
body.home .hero-inner{margin:auto;will-change:opacity,transform}
body.home #services{
  border-radius:40px 40px 0 0;
  box-shadow:0 -24px 60px rgba(17,19,18,.10);
}
/* later sections sit above the pinned hero and let the fixed art softly show through */
body.home section:not(.hero),body.home footer{position:relative;z-index:2}
body.home section.bg-off:not(.hero){background:rgba(250,249,246,.58)}
body.home section.bg-cool{background:rgba(241,243,241,.6)}
body.home section.testimonials-section{background:rgba(255,255,255,.6)}
body.home section.bg-off:not(.hero),body.home section.bg-cool{-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px)}
body.home .hero.is-covered{visibility:hidden}
@media (max-height:640px){body.home .hero{position:relative;min-height:0;margin-top:0;padding-top:96px;padding-bottom:80px}}
@media (prefers-reduced-motion:reduce){body.home .hero{position:relative;min-height:0;margin-top:0;padding-top:96px;padding-bottom:80px}body.home .hero-inner{opacity:1!important;transform:none!important}}

/* Footer: two link columns, pushed to the right edge, same gap between columns */
@media (min-width:721px){
  footer .footer-top .footer-links{
    grid-template-columns:repeat(2,minmax(150px,195px))!important;
    column-gap:32px!important;
    justify-content:end;justify-self:end;margin-right:clamp(40px,9vw,190px);
  }
}

/* FAQ open/close: icon rotation. Height + fade handled by faq.js */
details.faq-item[open] .faq-toggle,
details.faq-card[open] summary > span:last-child{transition:transform .3s ease}
details.faq-card summary > span:last-child,details.faq-item .faq-toggle{transition:transform .3s ease}
details.faq-card[open] summary > span:last-child{transform:rotate(45deg)}
.faq-body,.faq-content{will-change:height,opacity}
@media (prefers-reduced-motion:reduce){
  details.faq-card summary > span:last-child,details.faq-item .faq-toggle{transition:none}
}

/* ---------- Product page heroes: clean responsive layout (overrides older stacked fixes) ---------- */
@media (max-width:1100px){
  body .bundles-hero__visual img,
  body .bundles-hero__visual img.product-hero-image{width:100% !important;max-width:100% !important;transform:none !important;height:auto !important;max-height:none !important;object-fit:contain !important}
}
@media (max-width:980px){
  body .bundles-hero{min-height:0 !important}
  body .bundles-hero__inner{grid-template-columns:1fr !important;min-height:0 !important;padding:40px 22px 32px !important;gap:28px !important}
  body .bundles-hero__copy{order:1 !important;padding:0 !important;min-width:0 !important}
  body .bundles-hero__visual{order:2 !important;height:auto !important;min-height:0 !important;width:100% !important;margin:0 !important;justify-content:center}
  body .bundles-hero__visual img,
  body .bundles-hero__visual img.product-hero-image{width:min(560px,100%) !important;margin:0 auto}
  body .bundles-hero h1{font-size:clamp(36px,9vw,60px) !important;white-space:normal !important;max-width:100%}

  body .epo-exact-hero{min-height:0 !important}
  body .epo-exact-hero__inner{display:flex !important;flex-direction:column;min-height:0 !important;height:auto !important}
  body .epo-exact-hero__copy{width:100% !important;min-height:0 !important;padding:40px 22px 8px !important}
  body .epo-exact-hero__editable-visual{position:relative !important;top:auto !important;right:auto !important;width:100% !important;height:auto !important;padding:12px 22px 32px !important}
  body .epo-exact-hero__editable-visual img{width:min(560px,100%) !important;height:auto !important;max-height:none !important;margin:0 auto}
  body .epo-exact-hero h1{font-size:clamp(36px,9vw,56px) !important}
}
@media (max-width:640px){
  html body .bundles-hero .bundles-hero__actions,
  html body .epo-exact-hero .epo-exact-hero__actions{display:flex !important;flex-wrap:wrap !important;gap:10px !important;width:100% !important;grid-template-columns:none !important}
  html body .bundles-hero .bundles-hero__actions .bundles-btn,
  html body .epo-exact-hero .epo-exact-hero__actions .epo-exact-hero__install,
  html body .epo-exact-hero .epo-exact-hero__actions .epo-exact-hero__docs{flex:1 1 calc(50% - 5px) !important;min-width:0 !important;width:auto !important;justify-content:center}
  html body .bundles-hero .bundles-hero__actions .bundles-rating,
  html body .epo-exact-hero .epo-exact-hero__actions .epo-exact-hero__rating{flex:1 1 100% !important;width:100% !important;max-width:100% !important;min-width:0 !important;flex-wrap:wrap;justify-content:center;box-sizing:border-box}
  body .bundles-hero__benefits,
  body .epo-exact-hero__benefits{flex-wrap:wrap;gap:10px 16px}
}

/* Home hero buttons: always one line, also on phones */
body.home .hero .hero-actions{flex-direction:row !important;flex-wrap:nowrap !important;justify-content:center;gap:10px;width:100%;max-width:440px}
body.home .hero .hero-actions .btn{width:auto !important;flex:1 1 0;min-width:0;justify-content:center;white-space:nowrap}
@media (max-width:420px){
  body.home .hero .hero-actions{gap:8px}
  body.home .hero .hero-actions .btn{padding-left:12px;padding-right:12px;font-size:14px}
}

/* Sharp product hero images: no scale() upscaling, size by width instead */
body .bundles-hero__visual img.product-hero-image{transform:none !important;image-rendering:auto;backface-visibility:hidden}
@media(min-width:1101px){
  body .bundles-hero__visual img.product-hero-image{width:min(994px,151%) !important;max-height:745px !important}
  body .epo-exact-hero__editable-visual img{transform:none !important;width:124% !important;height:auto !important;max-height:700px !important}
}

/* Documentation pages: visible hamburger + working mobile menu */
@media (max-width:720px){
  body.mandolly-doc-page header .nav{display:flex;align-items:center;justify-content:space-between;height:72px;padding:0 20px}
  body.mandolly-doc-page .nav-desktop-cta{display:none !important}
  body.mandolly-doc-page .nav-toggle{display:flex !important;flex-direction:column;align-items:center;justify-content:center;gap:4px;width:44px;height:44px;padding:10px;border:0;border-radius:12px;background:transparent;cursor:pointer}
  body.mandolly-doc-page .nav-toggle span{display:block;width:20px;height:2px;border-radius:2px;background:#111312}
  body.mandolly-doc-page .nav-links{display:none}
  body.mandolly-doc-page .nav-links.open{display:flex;flex-direction:column;align-items:stretch;position:absolute;top:72px;left:0;right:0;z-index:100;padding:24px 20px 28px;gap:8px;background:rgba(250,249,246,.97);backdrop-filter:blur(18px);-webkit-backdrop-filter:blur(18px);border-bottom:1px solid rgba(255,255,255,.75);box-shadow:0 12px 28px rgba(0,0,0,.08);font-size:15px}
  body.mandolly-doc-page .nav-links.open a:not(.btn){width:100%;min-height:48px;padding:10px 4px}
  body.mandolly-doc-page .nav-links.open .nav-cta{display:inline-flex !important;align-self:center;margin:4px auto 0;justify-content:center}
}

/* Footer: link columns side by side at every width; socials right-aligned */
footer .footer-top .footer-links{grid-template-columns:repeat(2,minmax(0,1fr)) !important;column-gap:72px !important;row-gap:0 !important}
@media (max-width:720px){
  footer .footer-top .footer-links{justify-self:stretch;justify-content:stretch;column-gap:32px !important}
}
footer .footer-bottom{display:flex !important;flex-direction:row !important;flex-wrap:wrap;align-items:center !important;justify-content:space-between !important;gap:14px 20px}
footer .footer-bottom .socials{margin-left:auto;display:flex;gap:10px;justify-content:flex-end}
footer .footer-top .footer-links>div:nth-child(1){grid-column:1 !important;grid-row:1 !important}
footer .footer-top .footer-links>div:nth-child(2){grid-column:2 !important;grid-row:1 !important}
footer .footer-top .footer-links>div{min-width:0}
footer .footer-top .footer-links a{overflow-wrap:anywhere}
@media (max-width:720px){footer .footer-top{grid-template-columns:minmax(0,1fr) !important}footer .footer-top>*{min-width:0}}

/* Go-to-top button: arrow circle with "Go to top" label below */
.mandolly-top{position:fixed;right:max(22px,env(safe-area-inset-right));bottom:max(52px,env(safe-area-inset-bottom));z-index:9990;display:flex;flex-direction:column;align-items:center;gap:6px;padding:0;border:0;background:transparent;color:#20221f;cursor:pointer;opacity:0;transform:translateY(14px) scale(.92);transition:opacity .25s ease,transform .25s ease,bottom .25s ease}
.mandolly-top__dial{position:relative;display:flex;align-items:center;justify-content:center;width:52px;height:52px;border-radius:50%;background:rgba(255,255,255,.96);box-shadow:0 10px 26px -10px rgba(10,10,8,.35),0 1px 0 rgba(255,255,255,.9) inset;transition:transform .2s ease,box-shadow .2s ease}
.mandolly-top__ring{position:absolute;inset:0;width:100%;height:100%;transform:rotate(-90deg);overflow:visible}
.mandolly-top__ring circle{fill:none;stroke-width:3}
.mandolly-top__track{stroke:rgba(17,19,18,.09)}
.mandolly-top__bar{stroke:var(--mint,#12a97e);stroke-linecap:round;transition:stroke-dashoffset .12s linear}
.mandolly-top .mandolly-top__arrow{position:relative;width:20px;height:20px;color:#20221f;transition:color .2s ease,transform .2s ease}
.mandolly-top__label{position:absolute;top:calc(100% + 6px);left:50%;font-size:11px;font-weight:700;line-height:1;letter-spacing:.02em;white-space:nowrap;padding:5px 9px;border-radius:999px;color:#20221f;background:rgba(255,255,255,.96);box-shadow:0 4px 14px rgba(10,10,8,.16);opacity:0;transform:translate(-50%,-4px);pointer-events:none;transition:opacity .18s ease,transform .18s ease}
.mandolly-top:hover .mandolly-top__label,.mandolly-top:focus-visible .mandolly-top__label{opacity:1;transform:translate(-50%,0)}
.mandolly-top[hidden]{display:none}
.mandolly-top.is-on{opacity:1;transform:none}
.mandolly-top.is-on:hover .mandolly-top__dial{transform:translateY(-3px);box-shadow:0 16px 30px -10px rgba(10,10,8,.4)}.mandolly-top:hover .mandolly-top__arrow{color:var(--mint-deep,#0c7f5f)}
.mandolly-top:focus-visible{outline:2px solid var(--mint-deep,#0c7f5f);outline-offset:4px;border-radius:14px}
@media (max-width:720px){.mandolly-top{bottom:max(112px,env(safe-area-inset-bottom))}.mandolly-top.is-lifted{bottom:max(184px,env(safe-area-inset-bottom))}}
@media (prefers-reduced-motion:reduce){.mandolly-top,.mandolly-top__dial,.mandolly-top__bar{transition:none}}

/* Newsletter: validation message goes below the input row, never beside it */
footer form.newsletter{flex-wrap:wrap !important;row-gap:8px !important}
footer form.newsletter .field-error,footer form.newsletter .form-error-message{order:5;flex:0 0 100%;width:100%;margin:0 !important;text-align:left}
footer form.newsletter .form-error-message{padding:10px 12px}
footer form.newsletter input:not(.hp-field){flex:1 1 0 !important;min-width:0 !important}

/* Navbar: full width at the top, floating pill after the first scroll (all sizes) */
html body header{--ph:64px;transition:background-color .35s ease,border-color .35s ease}
html body header .nav{width:100%;margin:0 auto;transition:width .45s cubic-bezier(.2,.7,.2,1),height .45s cubic-bezier(.2,.7,.2,1),margin .45s cubic-bezier(.2,.7,.2,1),padding .45s ease,border-radius .45s ease,background-color .35s ease,box-shadow .45s ease}
html body header.is-pill{background:transparent;-webkit-backdrop-filter:none;backdrop-filter:none;border-bottom-color:transparent;height:var(--hh,84px)}
html body header.is-pill .nav{width:min(1180px,calc(100% - 48px));height:var(--ph);margin:min(20px,calc(var(--hh,84px) - var(--ph) - 2px)) auto 0;padding:0 10px 0 26px;border-radius:999px;background:rgba(255,255,255,.95);-webkit-backdrop-filter:blur(22px) saturate(1.3);backdrop-filter:blur(22px) saturate(1.3);box-shadow:0 14px 36px -16px rgba(20,22,20,.3),0 0 0 1px rgba(255,255,255,.9) inset}
@media (max-width:980px){
  html body header{--ph:56px}
  html body header.is-pill .nav{width:calc(100% - 24px);padding:0 6px 0 18px}
  html body header.is-pill .nav-links.open{top:calc(100% + 10px);left:0;right:0;border-radius:24px;border:1px solid rgba(255,255,255,.9);box-shadow:0 22px 44px -18px rgba(20,22,20,.35);background:rgba(255,255,255,.98)}
}
@media (prefers-reduced-motion:reduce){html body header .nav,html body header{transition:none}}

/* Pill navbar: 16px gap above it. Padding on the header (margin on .nav collapsed through the sticky header, so the gap was 0). */
html body header.is-pill{box-sizing:border-box;padding-top:16px;height:max(var(--hh,84px),calc(var(--ph) + 16px))}
html body header.is-pill .nav{margin-top:0}

/* Pill navbar: blur the 16px strip above the pill so scrolled content does not show through it. */
html body header.is-pill::before{content:"";position:absolute;top:0;left:0;right:0;height:16px;z-index:0;pointer-events:none;background:var(--strip-bg,rgba(250,249,246,.55));transition:background-color .25s ease;-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px)}
html body header.is-pill .nav{position:relative;z-index:1}

/* ===== Mobile performance: drop the costly blur/backdrop effects on small screens (Lighthouse mobile: TBT, paint, scroll) ===== */
@media (max-width:760px){
  .eyebrow,.btn-light,.glass-word,.stat-pill,.card,.eco-card,.faq-item,.contact-pill,.contact-card,.contact-form-card,.blog-card,
  .form-group input,.form-group select,.form-group textarea,footer,.newsletter input,.social-btn,.mandolly-toast,.tsec-card,
  body.home section.bg-off:not(.hero),body.home section.bg-cool,
  body .btn-light,body .btn-outline,body .btn-outline-dark,body .app-docs-btn,body .eco-toggle,body .blog-toggle,body .arrow-circle-btn{-webkit-backdrop-filter:none !important;backdrop-filter:none !important}
  .tsec-orb{display:none !important}
  /* below-the-fold homepage sections: skip rendering work until near the viewport */
  .faq-section,.contact-section{content-visibility:auto;contain-intrinsic-size:auto 900px}
}

/* FAQ: fixed width. The grid sits in a centered flex column, so it used to shrink to its content and change width on open/close. */
html body .faq-grid{width:100%;max-width:1000px;margin-left:auto;margin-right:auto;grid-template-columns:repeat(2,minmax(0,1fr));box-sizing:border-box}
@media (max-width:760px){html body .faq-grid{grid-template-columns:minmax(0,1fr)}}

/* Phones in landscape (wide but short): one clear type scale, titles always larger than paragraph text. */
@media (orientation:landscape) and (max-height:520px){
  html body:not(#_) h1,html body:not(#_) .hero h1,html body:not(#_) .bundles-hero h1,html body:not(#_) .epo-exact-hero h1,html body:not(#_) .app-hero h1{font-size:clamp(28px,4.6vw,38px)!important;line-height:1.12!important}
  html body:not(#_) h2,html body:not(#_) .section-head h2,html body:not(#_) .section-heading-centered h2,html body:not(#_) .ecosystem-head h2,html body:not(#_) .faq-section h2,html body:not(#_) .testimonials-section h2,html body:not(#_) .testimonials-heading h2,html body:not(#_) .contact-section h2,html body:not(#_) .home-section-title,html body:not(#_) .product-pricing-title,html body:not(#_) .bundles-section-heading h2{font-size:clamp(24px,3.6vw,30px)!important;line-height:1.15!important}
  html body:not(#_) h3,html body:not(#_) .eco-title,html body:not(#_) .ecosystem-grid .eco-title,html body:not(#_) .fx-title,html body:not(#_) .bundles-feature-copy h3{font-size:clamp(18px,2.6vw,21px)!important;line-height:1.25!important}
  html body:not(#_) .pp-name{font-size:18px!important}
  html body:not(#_) .statement{font-size:clamp(16px,2.3vw,19px)!important;line-height:1.5!important}
  html body:not(#_) p,html body:not(#_) .home-section-copy,html body:not(#_) .eco-desc,html body:not(#_) .fx-desc,html body:not(#_) .faq-body{font-size:15px!important;line-height:1.6!important}
  html body:not(#_) .faq-item summary{font-size:15px!important}
  /* testimonial cards: shorter text, enough room so nothing is cut mid-line */
  html body:not(#_) .tsec-carousel{--card-w:min(62vw,420px)}
  html body:not(#_) .tsec-stage{height:300px}
  html body:not(#_) .tsec-card{height:280px;margin-top:-140px;padding:20px 22px 18px}
  html body:not(#_) .tsec-stars{font-size:16px;margin:2px 0 10px}
  html body:not(#_) .tsec-text{font-size:14px!important;line-height:1.5!important;-webkit-line-clamp:4}
  html body:not(#_) .tsec-author{padding-top:10px;gap:12px}
  html body:not(#_) .tsec-quote-mark{top:16px;right:18px;width:38px;height:38px}
}

/* Landscape phone: one type scale for every page. Section titles > card titles > body, same body size everywhere. */
@media (orientation:landscape) and (max-height:520px){
  /* section titles */
  html body:not(#_) .hp-title,html body:not(#_) .home-section-title,html body:not(#_) .home-faq-title,html body:not(#_) .tsec-title,html body:not(#_) .product-pricing-title,html body:not(#_) .home-contact-heading,html body:not(#_) .article-head h2,html body:not(#_) .doc-content-heading{font-size:clamp(24px,3.6vw,30px)!important;line-height:1.2!important}
  /* card / block titles */
  html body:not(#_) h4,html body:not(#_) h5,html body:not(#_) .hp-name,html body:not(#_) .hp-feature strong,html body:not(#_) .hp-feature b,html body:not(#_) .pp-incl__title,html body:not(#_) .related-title,html body:not(#_) .sidebar-title,html body:not(#_) .home-form-heading,html body:not(#_) .home-direct-heading,html body:not(#_) .doc-subheading,html body:not(#_) .fx-title,html body:not(#_) .eco-title,html body:not(#_) .pp-name{font-size:clamp(18px,2.6vw,21px)!important;line-height:1.25!important}
  /* body text: same size on every page */
  html body:not(#_) .hp-lead,html body:not(#_) .hp-desc,html body:not(#_) .pp-desc,html body:not(#_) .app-hero-desc,html body:not(#_) .epo-exact-hero__description,html body:not(#_) .bundles-hero__desc,html body:not(#_) .bundles-pricing__intro,html body:not(#_) .home-form-copy,html body:not(#_) .footer-blurb,html body:not(#_) .description,html body:not(#_) .mpe-intro,html body:not(#_) .doc-step-note,html body:not(#_) .article-body p,html body:not(#_) .article-body li,html body:not(#_) .doc-content p,html body:not(#_) .doc-content li,html body:not(#_) .fx-card li,html body:not(#_) .pp-card li,html body:not(#_) .hp-feature span:not(.hp-ficon),html body:not(#_) .hp-feature p{font-size:15px!important;line-height:1.6!important}
  html body:not(#_) p.statement,html body:not(#_) .statement{font-size:clamp(16px,2.3vw,19px)!important;line-height:1.5!important}
}
