/* LogeMate main site — app mode on phones (≤820px). Desktop is untouched. */
#lmTab{display:none}
@media(max-width:820px){
html.lmApp{-webkit-tap-highlight-color:transparent;-webkit-text-size-adjust:100%}
html.lmApp body{overscroll-behavior-y:contain;padding-bottom:calc(88px + env(safe-area-inset-bottom))}
html.lmApp a,html.lmApp button,html.lmApp summary,html.lmApp label{touch-action:manipulation}
html.lmApp img{-webkit-user-drag:none;-webkit-touch-callout:none}

/* the Menu button lives in the tab bar now */
html.lmApp .pill .burger{display:none!important}

#lmTab{display:flex;align-items:flex-end;position:fixed;z-index:125;left:12px;right:12px;bottom:calc(10px + env(safe-area-inset-bottom));height:66px;padding:6px;border-radius:24px;background:rgba(255,255,255,.84);-webkit-backdrop-filter:blur(22px) saturate(1.6);backdrop-filter:blur(22px) saturate(1.6);border:1px solid rgba(0,70,160,.12);box-shadow:0 18px 40px -16px rgba(0,50,130,.45),0 2px 6px rgba(0,40,100,.06);transition:transform .3s cubic-bezier(.2,.8,.2,1),opacity .2s}
html[data-theme=dark] #lmTab,body.dk #lmTab{background:rgba(10,20,38,.82);border-color:rgba(120,170,255,.2)}
body.lmKb #lmTab{transform:translateY(140%);opacity:0;pointer-events:none}
#lmTab a{flex:1;height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;border-radius:18px;color:#6B7A93;text-decoration:none;position:relative;transition:color .2s,background .25s,transform .12s}
#lmTab a:active{transform:scale(.92)}
#lmTab .ti{position:relative;display:grid;place-items:center;width:28px;height:28px}
#lmTab .ti svg{width:23px;height:23px;transition:transform .3s cubic-bezier(.3,1.6,.5,1)}
#lmTab em{font:600 10.5px/1 Inter,system-ui,sans-serif;font-style:normal;letter-spacing:.01em}
#lmTab a.on{color:#005BD3;background:rgba(0,91,211,.1)}
#lmTab a.on .ti svg{transform:translateY(-1px) scale(1.12);stroke-width:2.2}
/* centre "Book" button stands out */
#lmTab a.ctr{flex:0 0 76px;margin-top:-22px;height:auto;padding-bottom:6px;background:transparent}
#lmTab a.ctr .ti{width:54px;height:54px;border-radius:50%;background:linear-gradient(135deg,#005BD3,#00A6FF);color:#fff;box-shadow:0 14px 26px -10px rgba(0,91,211,.9),0 0 0 5px rgba(255,255,255,.9)}
html[data-theme=dark] #lmTab a.ctr .ti,body.dk #lmTab a.ctr .ti{box-shadow:0 14px 26px -10px rgba(0,91,211,.9),0 0 0 5px rgba(10,20,38,.95)}
#lmTab a.ctr .ti svg{width:26px;height:26px}
#lmTab a.ctr.on{background:transparent;color:#005BD3}
#lmTab a.ctr.on .ti{animation:lmPulse 2.2s ease-in-out infinite}
@keyframes lmPulse{0%,100%{box-shadow:0 14px 26px -10px rgba(0,91,211,.9),0 0 0 5px rgba(255,255,255,.9)}50%{box-shadow:0 14px 26px -10px rgba(0,91,211,.9),0 0 0 9px rgba(0,166,255,.25)}}
@media(prefers-reduced-motion:reduce){#lmTab a.ctr.on .ti{animation:none}}

/* things that sat at the screen's bottom step above the bar */
html.lmApp .toTop{bottom:calc(98px + env(safe-area-inset-bottom))!important;right:16px!important}
html.lmApp .toast{bottom:calc(96px + env(safe-area-inset-bottom))!important}
body #lmc-l{bottom:calc(98px + env(safe-area-inset-bottom))!important}
body #lmc-p{bottom:calc(166px + env(safe-area-inset-bottom))!important}

/* menu screen: keep the last items clear of the bar */
html.lmApp .mnav{padding-bottom:calc(110px + env(safe-area-inset-bottom))!important}
.mnav .lmInst{display:flex;align-items:center;gap:13px;width:100%;text-align:start;margin:0 0 12px;padding:12px 14px;border-radius:18px;border:1px dashed rgba(0,91,211,.45);background:rgba(0,91,211,.07);color:inherit;font:inherit;cursor:pointer}
.mnav .lmInst .lmI{flex:none;width:38px;height:38px;border-radius:12px;display:grid;place-items:center;background:linear-gradient(135deg,#005BD3,#00A6FF);color:#fff}
.mnav .lmInst .lmI svg{width:19px;height:19px}
.mnav .lmInst b{display:block;font:700 14.5px Sora,Inter,sans-serif}.mnav .lmInst small{display:block;opacity:.7;font-size:12px;margin-top:2px}

@media(hover:none){
html.lmApp .btn:active,html.lmApp .card:active,html.lmApp .zbtn:active{transform:scale(.97);transition:transform .08s}
}
}

@media(max-width:820px){
/* chat opens as a full sheet above header + tab bar; page below the bar is blurred */
html.lmApp.lmc-open #lmTab,html.lmApp.lmc-open body::after{display:none!important}
html.lmApp.lmc-open body #lmc-p{bottom:0!important;z-index:2147483000!important;height:calc(100dvh - env(safe-area-inset-top) - 8px)!important;max-height:none}
html.lmApp #lmc-l{z-index:130!important}
html.lmApp body::after{content:"";position:fixed;left:0;right:0;bottom:0;height:calc(92px + env(safe-area-inset-bottom));z-index:120;pointer-events:none;-webkit-backdrop-filter:blur(16px) saturate(1.4);backdrop-filter:blur(16px) saturate(1.4);background:linear-gradient(to top,color-mix(in srgb,var(--bg,#fff) 70%,transparent),transparent);-webkit-mask-image:linear-gradient(to top,#000 55%,transparent);mask-image:linear-gradient(to top,#000 55%,transparent)}
}
