/* eNvision trade demos — shared base (reset, icons, form, FAQ, slider, entrances, phone bar).
   Each trade's look lives in ../<trade>/style.css. Tokens each trade sets:
   --display --text --ground --ink --muted --accent --on-accent --line --focus --r (radius) --m (margin) */

*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%;scroll-behavior:smooth;scroll-padding-top:96px}
body{margin:0;background:var(--ground);color:var(--ink);font:400 17px/1.6 var(--text);-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;overflow-x:hidden}
img{display:block;max-width:100%;height:auto}
a{color:inherit}
button,input,select,textarea{font:inherit;color:inherit}
h1,h2,h3,h4,p,ul,ol,figure,blockquote,dl,dd{margin:0}
ul,ol{padding:0;list-style:none}
::selection{background:var(--accent);color:var(--on-accent)}
:focus-visible{outline:3px solid var(--focus);outline-offset:3px}
.vh{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.wrap{width:min(1240px,100% - 2*var(--m));margin-inline:auto}

/* icons + stars */
.ic{width:1.25em;height:1.25em;flex:none;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.stars{display:inline-flex;gap:2px}
.stars svg{width:16px;height:16px;fill:var(--star,#F5B700);stroke:none}

/* demo form: structure only, colours come from the trade */
.demo-form{display:grid;gap:6px}
.demo-form label{font-size:14px;font-weight:600;margin-top:8px}
.demo-form input,.demo-form select{width:100%;min-height:50px;padding:12px 14px;border:1.5px solid var(--line);border-radius:var(--r-in,8px);background:#fff;color:#1a1a1a}
.demo-form input:focus,.demo-form select:focus{outline:3px solid var(--focus);outline-offset:1px;border-color:transparent}
.demo-form .btn{margin-top:16px;width:100%;justify-content:center}
.demo-form .ok{display:none;margin-top:12px;font-weight:600}
.demo-form.sent .ok{display:block}
.demo-form.sent .btn{opacity:.55}

/* FAQ: native details */
.faq details{border-bottom:1px solid var(--line)}
.faq summary{list-style:none;cursor:pointer;display:flex;justify-content:space-between;align-items:center;gap:24px;padding:22px 0;font-weight:600;font-size:19px}
.faq summary::-webkit-details-marker{display:none}
.faq summary::after{content:"";flex:none;width:12px;height:12px;border-right:2px solid currentColor;border-bottom:2px solid currentColor;transform:rotate(45deg) translate(-3px,-3px);transition:transform .3s var(--ease)}
.faq details[open] summary::after{transform:rotate(225deg)}
.faq details p{padding:0 0 24px;max-width:62ch;color:var(--muted)}

/* before / after slider */
.ba{position:relative;overflow:hidden;--pos:50%;user-select:none;touch-action:pan-y}
.ba img{width:100%;height:100%;object-fit:cover}
.ba .after{position:absolute;inset:0;clip-path:inset(0 0 0 var(--pos))}
.ba .handle{position:absolute;top:0;bottom:0;left:var(--pos);width:3px;margin-left:-1.5px;background:#fff;pointer-events:none}
.ba .handle::after{content:"";position:absolute;top:50%;left:50%;width:52px;height:52px;margin:-26px 0 0 -26px;border-radius:50%;background:#fff;box-shadow:0 4px 18px rgba(0,0,0,.25);
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23222' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 6l-6 6 6 6M15 6l6 6-6 6'/%3E%3C/svg%3E");background-size:24px;background-position:center;background-repeat:no-repeat}
.ba input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:ew-resize;margin:0}
.ba .tag{position:absolute;top:16px;padding:6px 12px;border-radius:99px;background:rgba(0,0,0,.6);color:#fff;font-size:13px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;pointer-events:none}
.ba .tag.b{left:16px}.ba .tag.a{right:16px}

/* entrances: parts rise once, in turn */
:root{--ease:cubic-bezier(.2,.7,.2,1)}
html:not(.no-js) [data-rise] .rise{opacity:0;transform:translateY(24px);transition:opacity .7s var(--ease),transform .7s var(--ease);transition-delay:calc(var(--k,0)*70ms)}
html:not(.no-js) [data-rise].in .rise{opacity:1;transform:none}

/* phone quick bar */
.callbar{display:none}
@media (max-width:760px){
  body{padding-bottom:72px}
  .callbar{display:grid;grid-template-columns:1fr 1fr;position:fixed;left:0;right:0;bottom:0;z-index:50;padding:10px 12px calc(10px + env(safe-area-inset-bottom));gap:10px;background:var(--bar-bg,#111);box-shadow:0 -6px 24px rgba(0,0,0,.18)}
  .callbar a{display:flex;align-items:center;justify-content:center;gap:8px;min-height:48px;border-radius:var(--r-btn,8px);font-weight:700;text-decoration:none}
  .callbar .c1{background:#fff;color:#111}
  .callbar .c2{background:var(--accent);color:var(--on-accent)}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{transition-duration:.01ms!important;animation-duration:.01ms!important}
  html:not(.no-js) [data-rise] .rise{opacity:1;transform:none}
}
