:root{--blue:#0a5bb5;--blue2:#0d74dd;--navy:#073a78;--ink:#142b46;--muted:#677f99;--line:#dce8f4;--page:#edf5fc;--white:#fff;--green:#16a36c;--shadow:0 24px 70px rgba(16,61,107,.16)}
*{box-sizing:border-box}html,body{margin:0;min-height:100%}body{font-family:Inter,"Segoe UI",Arial,sans-serif;background:radial-gradient(circle at 15% 0,#dceeff 0,transparent 34%),linear-gradient(145deg,#f7fbff,#eaf3fb 58%,#e5eef8);color:var(--ink);padding:24px;overflow:auto}.pb-app{position:relative;width:min(1040px,100%);height:min(820px,calc(100dvh - 48px));min-height:660px;margin:0 auto;display:flex;flex-direction:column;background:linear-gradient(180deg,#fbfdff 0,#f2f7fc 100%);border:1px solid rgba(179,204,228,.85);border-radius:30px;overflow:hidden;box-shadow:var(--shadow)}
.pb-header{height:78px;flex:0 0 78px;display:flex;align-items:center;justify-content:space-between;padding:0 24px;background:rgba(255,255,255,.97);backdrop-filter:blur(14px);border-bottom:1px solid var(--line);z-index:30}.pb-brand{display:flex;align-items:center;gap:13px;min-width:0}.pb-brand img{width:48px;height:48px;border-radius:16px;box-shadow:0 9px 24px rgba(10,91,181,.18)}.pb-brand div{min-width:0}.pb-brand strong{display:block;font-size:17px;letter-spacing:-.25px}.pb-brand span{display:flex;align-items:center;gap:6px;font-size:12px;color:var(--muted);margin-top:3px}.pb-brand span i{width:8px;height:8px;border-radius:50%;background:var(--green);box-shadow:0 0 0 4px rgba(22,163,108,.12)}.pb-head-actions{display:flex;gap:9px;align-items:center}.pb-login,.pb-install{border:0;text-decoration:none;border-radius:13px;padding:11px 15px;font-size:12px;font-weight:800;cursor:pointer}.pb-login{background:linear-gradient(135deg,var(--blue),var(--blue2));color:#fff;box-shadow:0 8px 20px rgba(10,91,181,.2)}.pb-install{background:#fff;color:var(--blue);border:1px solid #c8dff4}.pb-install[hidden]{display:none}
.pb-chat{flex:1;overflow-y:auto;overscroll-behavior:contain;padding:24px 28px 196px;scroll-behavior:smooth}.pb-day{width:max-content;margin:0 auto 22px;padding:7px 13px;border-radius:999px;background:#e2effc;color:#4f7094;font-size:11px;font-weight:800}.pb-row{display:flex;gap:11px;align-items:flex-end;margin:0 0 16px}.pb-row.user{justify-content:flex-end}.pb-avatar{width:38px;height:38px;flex:0 0 38px;border-radius:13px;display:grid;place-items:center;background:linear-gradient(145deg,var(--blue2),var(--navy));color:#fff;font-size:13px;font-weight:900;box-shadow:0 7px 18px rgba(10,91,181,.15)}.pb-avatar.soft{background:#dcecff;color:var(--blue);box-shadow:none}.pb-bubble{max-width:min(780px,86%);border-radius:21px 21px 21px 7px;background:#fff;border:1px solid var(--line);box-shadow:0 10px 30px rgba(31,73,120,.08);padding:17px 18px;min-width:0}.pb-bubble.user-bubble{max-width:min(650px,80%);border:0;border-radius:21px 21px 7px 21px;background:linear-gradient(145deg,#0d68c9,#084986);color:#fff;padding:14px 17px;box-shadow:0 10px 25px rgba(10,91,181,.2);font-size:14px;line-height:1.6}.pb-bubble-title{font-size:15px;font-weight:900;color:#123f70;margin-bottom:9px}.pb-bubble p{font-size:14px;line-height:1.72;color:#526d89;margin:0 0 10px}.pb-bubble p:last-child{margin-bottom:0}.pb-note{padding:11px 12px;border-radius:13px;background:#f2f8fe;border:1px solid #deebf7}.pb-bubble.mini{padding:13px 15px}.pb-mini-title{font-size:12px;font-weight:800;color:#58708f}.pb-quick,.pb-result-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:13px}.pb-quick button,.pb-result-actions button,.pb-result-actions a,.pb-suggestion-scroll button{border:1px solid #c7def3;background:#f5faff;color:var(--blue);text-decoration:none;border-radius:999px;padding:9px 12px;font-size:11.5px;font-weight:800;cursor:pointer}.pb-quick button:hover,.pb-result-actions button:hover,.pb-result-actions a:hover{background:var(--blue);color:#fff;border-color:var(--blue)}.pb-suggestion-scroll{display:flex;gap:7px;overflow-x:auto;padding:9px 1px 3px;scrollbar-width:none}.pb-suggestion-scroll::-webkit-scrollbar{display:none}.pb-suggestion-scroll button{white-space:nowrap;background:#fff}
.pb-answer-head{display:flex;justify-content:space-between;gap:10px;align-items:start;margin-bottom:9px}.pb-answer-head strong{font-size:15px;color:#123f70}.pb-answer-head small{display:block;font-size:11px;color:#8093a8;margin-top:3px}.pb-answer-message{font-size:13.5px!important;line-height:1.72!important;color:#506c89!important}.pb-metrics{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:9px;margin:12px 0}.pb-metric{background:#f5faff;border:1px solid #dceaf7;border-radius:14px;padding:12px}.pb-metric small{display:block;font-size:10px;color:#7088a3}.pb-metric b{display:block;font-size:14px;color:#0a5bb5;margin-top:5px;overflow-wrap:anywhere}.pb-records{display:grid;gap:9px;margin-top:11px}.pb-record{border:1px solid #dfe9f4;border-radius:15px;background:#fbfdff;overflow:hidden}.pb-record summary{list-style:none;cursor:pointer;padding:13px 14px;display:flex;align-items:center;justify-content:space-between;gap:9px}.pb-record summary::-webkit-details-marker{display:none}.pb-record summary div{min-width:0}.pb-record summary b{display:block;font-size:12.5px;color:#183f6a;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.pb-record summary small{display:block;font-size:10px;color:#8193a8;margin-top:3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.pb-record summary:after{content:"＋";font-size:15px;color:#5f83aa}.pb-record[open] summary:after{content:"−"}.pb-fields{border-top:1px solid #e5eef7;padding:5px 13px 10px}.pb-field{display:grid;grid-template-columns:150px minmax(0,1fr);gap:10px;padding:9px 0;border-bottom:1px dashed #e4edf6}.pb-field:last-child{border-bottom:0}.pb-field span{font-size:11px;color:#748aa3}.pb-field b{font-size:12.5px;line-height:1.5;overflow-wrap:anywhere}.pb-record-action{padding:0 13px 13px}.pb-record-action a{display:block;text-align:center;text-decoration:none;background:#eaf4ff;color:#0a5bb5;border-radius:11px;padding:10px;font-size:11.5px;font-weight:800}.pb-loading{display:flex;align-items:center;gap:10px;font-size:12px;color:#6f829b}.pb-spinner{width:18px;height:18px;border-radius:50%;border:2px solid #d9e8f6;border-top-color:var(--blue2);animation:pbspin .7s linear infinite}@keyframes pbspin{to{transform:rotate(360deg)}}.pb-error{color:#b42318!important;background:#fff3f2;border:1px solid #ffd7d2;border-radius:12px;padding:11px!important}
.pb-composer-wrap{position:absolute;left:0;right:0;bottom:68px;z-index:40;padding:13px 24px 10px;background:linear-gradient(180deg,rgba(242,247,252,0),rgba(242,247,252,.96) 30%,#f2f7fc 62%)}.pb-composer{display:flex;align-items:center;gap:10px;background:#fff;border:1px solid #c9dff2;border-radius:22px;padding:8px 9px;box-shadow:0 16px 40px rgba(21,62,111,.16)}.pb-composer-logo{width:39px;height:39px;flex:0 0 39px;border-radius:13px;display:grid;place-items:center;background:linear-gradient(145deg,var(--blue2),var(--navy));color:#fff;font-size:13px;font-weight:900}.pb-composer input{flex:1;min-width:0;border:0;outline:0;background:transparent;font-size:14.5px;padding:11px 4px;color:var(--ink)}.pb-composer input::placeholder{color:#8ea2b6}.pb-composer button{width:44px;height:44px;flex:0 0 44px;border:0;border-radius:14px;background:linear-gradient(145deg,var(--blue2),var(--blue));color:#fff;font-size:17px;cursor:pointer;box-shadow:0 8px 18px rgba(10,91,181,.22)}.pb-composer button:disabled{opacity:.55}.pb-helper{text-align:center;margin-top:7px;font-size:10px;color:#7d91a8}.pb-bottom{height:68px;position:absolute;left:0;right:0;bottom:0;z-index:45;display:grid;grid-template-columns:repeat(5,1fr);background:rgba(255,255,255,.99);backdrop-filter:blur(14px);border-top:1px solid var(--line);padding:6px 8px 7px;box-shadow:0 -9px 25px rgba(29,68,112,.07)}.pb-bottom button,.pb-bottom a{border:0;background:none;text-decoration:none;color:#7088a3;text-align:center;font-size:10px;font-weight:800;cursor:pointer;padding:2px}.pb-bottom span{width:31px;height:31px;margin:0 auto 3px;display:grid;place-items:center;border-radius:10px;font-size:16px}.pb-bottom .active,.pb-bottom button:hover,.pb-bottom a:hover{color:var(--blue)}.pb-bottom .active span{background:#e8f3ff;color:var(--blue)}
@media(max-width:760px){body{padding:10px}.pb-app{height:calc(100dvh - 20px);min-height:580px;border-radius:22px}.pb-header{height:68px;flex-basis:68px;padding:0 14px}.pb-brand img{width:41px;height:41px;border-radius:14px}.pb-brand strong{font-size:15px}.pb-brand span{font-size:10px}.pb-install{display:none!important}.pb-login{font-size:10.5px;padding:9px 11px}.pb-chat{padding:17px 12px 186px}.pb-day{font-size:10px;margin-bottom:17px}.pb-row{gap:7px;margin-bottom:13px}.pb-avatar{width:32px;height:32px;flex-basis:32px;border-radius:10px;font-size:11px}.pb-bubble{max-width:91%;border-radius:18px 18px 18px 6px;padding:13px}.pb-bubble.user-bubble{max-width:87%;font-size:13px;padding:12px 14px}.pb-bubble-title,.pb-answer-head strong{font-size:14px}.pb-bubble p,.pb-answer-message{font-size:13px!important;line-height:1.67!important}.pb-quick{gap:6px}.pb-quick button,.pb-result-actions button,.pb-result-actions a{font-size:10.5px;padding:8px 10px}.pb-metrics{grid-template-columns:1fr 1fr}.pb-field{grid-template-columns:112px minmax(0,1fr);gap:8px}.pb-field span{font-size:10.5px}.pb-field b{font-size:11.5px}.pb-record summary b{font-size:11.5px}.pb-record summary small{font-size:9.5px}.pb-composer-wrap{bottom:64px;padding:9px 9px 7px}.pb-composer{border-radius:18px;padding:6px 7px}.pb-composer-logo{width:34px;height:34px;flex-basis:34px;border-radius:11px;font-size:11px}.pb-composer input{font-size:13.5px;padding:9px 2px}.pb-composer button{width:38px;height:38px;flex-basis:38px;border-radius:12px;font-size:15px}.pb-helper{display:none}.pb-bottom{height:64px;padding-top:5px}.pb-bottom span{width:28px;height:28px;font-size:15px}.pb-bottom button,.pb-bottom a{font-size:9px}}
@media(max-width:420px){body{padding:6px}.pb-app{height:calc(100dvh - 12px);border-radius:18px}.pb-head-actions{gap:5px}.pb-brand span{max-width:145px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.pb-login{padding:8px 9px}.pb-chat{padding-left:9px;padding-right:9px}.pb-field{grid-template-columns:100px minmax(0,1fr)}}

/* =====================================================================
   GUARDIAN125 v9 - MOBILE LOCKED COMPOSER + BOTTOM MENU
   Mobile-first stability for Android/iOS/PWA.
   ===================================================================== */
:root{
  --pb-mobile-edge:8px;
  --pb-nav-h:68px;
  --pb-composer-h:70px;
  --pb-kb:0px;
}
html,body{max-width:100%;overflow-x:hidden}
.pb-chat{-webkit-overflow-scrolling:touch;touch-action:pan-y;scrollbar-gutter:stable}
.pb-composer input{font-size:15px}

@media(max-width:760px){
  html{height:100%;background:#eaf3fb}
  body{
    height:100dvh;
    min-height:100dvh;
    padding:var(--pb-mobile-edge);
    overflow:hidden;
    overscroll-behavior:none;
  }
  .pb-app{
    width:100%;
    height:calc(100dvh - (var(--pb-mobile-edge) * 2));
    min-height:0;
    margin:0;
    border-radius:22px;
    overflow:hidden;
    isolation:isolate;
  }
  .pb-header{position:relative;z-index:20}
  .pb-chat{
    min-height:0;
    overflow-y:auto;
    overflow-x:hidden;
    padding:17px 12px calc(var(--pb-nav-h) + var(--pb-composer-h) + 34px + env(safe-area-inset-bottom));
  }
  .pb-composer-wrap{
    position:fixed;
    left:var(--pb-mobile-edge);
    right:var(--pb-mobile-edge);
    bottom:calc(var(--pb-nav-h) + var(--pb-kb) + env(safe-area-inset-bottom));
    z-index:1002;
    padding:8px 9px 7px;
    background:linear-gradient(180deg,rgba(242,247,252,0),rgba(242,247,252,.98) 25%,#f2f7fc 54%);
    transform:translateZ(0);
  }
  .pb-composer{
    min-height:56px;
    border-radius:20px;
    padding:6px 7px;
    box-shadow:0 10px 28px rgba(21,62,111,.19);
  }
  .pb-composer-logo{width:38px;height:38px;flex-basis:38px}
  .pb-composer input{
    font-size:16px; /* prevents iOS input auto-zoom */
    line-height:1.35;
    min-height:42px;
    padding:9px 3px;
  }
  .pb-composer button{width:42px;height:42px;flex-basis:42px}
  .pb-bottom{
    position:fixed;
    left:var(--pb-mobile-edge);
    right:var(--pb-mobile-edge);
    bottom:var(--pb-kb);
    z-index:1003;
    height:auto;
    min-height:var(--pb-nav-h);
    padding:6px 6px calc(7px + env(safe-area-inset-bottom));
    border-radius:0 0 18px 18px;
    background:rgba(255,255,255,.985);
    box-shadow:0 -8px 25px rgba(29,68,112,.09);
    transform:translateZ(0);
  }
  .pb-bottom button,.pb-bottom a{
    min-width:0;
    min-height:48px;
    font-size:10px;
    line-height:1.1;
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:center;
  }
  .pb-bottom span{width:30px;height:30px;font-size:16px;margin-bottom:2px}
  .pb-bubble{max-width:92%}
  .pb-bubble p,.pb-answer-message{font-size:14px!important;line-height:1.65!important}
  .pb-field{grid-template-columns:110px minmax(0,1fr)}
  .pb-field span{font-size:11px}.pb-field b{font-size:12.5px}
}

@media(max-width:480px){
  :root{--pb-mobile-edge:6px;--pb-nav-h:66px;--pb-composer-h:68px}
  .pb-app{border-radius:18px}
  .pb-header{height:64px;flex-basis:64px;padding:0 11px}
  .pb-brand img{width:39px;height:39px;border-radius:13px}
  .pb-brand strong{font-size:15px}.pb-brand span{font-size:10px}
  .pb-login{padding:8px 9px;font-size:10.5px}
  .pb-chat{padding-left:9px;padding-right:9px}
  .pb-row{gap:6px}.pb-avatar{width:30px;height:30px;flex-basis:30px}
  .pb-bubble{max-width:94%;padding:13px 12px}
  .pb-bubble.user-bubble{max-width:89%;font-size:14px}
  .pb-metrics{grid-template-columns:1fr 1fr}
  .pb-record summary{padding:12px}
  .pb-field{grid-template-columns:100px minmax(0,1fr);gap:7px}
  .pb-composer-wrap{padding-left:7px;padding-right:7px}
}

@media(max-width:360px){
  .pb-brand span{display:none}
  .pb-login{font-size:10px;padding:8px}
  .pb-composer-logo{display:none}
  .pb-composer{gap:5px}
  .pb-composer input{padding-left:8px}
  .pb-bottom button,.pb-bottom a{font-size:9px}
  .pb-bottom span{width:27px;height:27px;font-size:14px}
  .pb-metrics{grid-template-columns:1fr}
  .pb-field{grid-template-columns:1fr;gap:3px}
  .pb-field span{font-weight:700;color:#647c96}
}

/* When the mobile keyboard is open, keep input visible and make room for it. */
html.pb-keyboard-open .pb-chat{scroll-padding-bottom:calc(var(--pb-nav-h) + var(--pb-composer-h) + 24px)}
html.pb-keyboard-open .pb-bottom{opacity:.98}
