/* OneOrtho Patient Concierge v3 — light institutional panel, home + messages.
   Spacing system: 20px panel gutters, 12px message rhythm, 10px chip gaps. */
#oo-concierge{position:fixed;right:24px;bottom:24px;z-index:9999;font-family:"Inter",system-ui,-apple-system,"Segoe UI",sans-serif;display:flex;flex-direction:column;align-items:flex-end;gap:12px;-webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility}
#oo-concierge *{box-sizing:border-box;margin:0}
#oo-concierge button{font-family:inherit}

/* ---------- Launcher ---------- */
.oo-launcher{width:60px;height:60px;border-radius:50%;border:1px solid #D5DDE3;background:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:0 14px 34px rgba(8,19,32,.28);position:relative;flex:none;transition:transform .15s ease,box-shadow .15s ease}
.oo-launcher:hover{transform:translateY(-2px);box-shadow:0 18px 38px rgba(8,19,32,.32)}
.oo-launcher svg{width:32px;height:32px;display:block}
.oo-badge{position:absolute;top:-3px;right:-3px;width:21px;height:21px;border-radius:50%;background:#C1272D;color:#fff;font-size:12px;font-weight:700;display:flex;align-items:center;justify-content:center;border:2px solid #fff;line-height:1}

/* ---------- Teaser (dark greeting + pills) ---------- */
.oo-teaser{display:none;flex-direction:column;align-items:flex-end;gap:10px;width:min(336px,calc(100vw - 48px))}
.oo-teaser.show{display:flex;animation:ooUp .28s ease}
@keyframes ooUp{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
.oo-greet{background:#0B1B2B;border:1px solid rgba(132,148,161,.45);border-radius:18px;padding:18px 40px 18px 18px;position:relative;box-shadow:0 18px 38px rgba(8,19,32,.35);width:100%;cursor:pointer}
.oo-greet-head{display:flex;gap:12px;align-items:flex-start}
.oo-tile{width:38px;height:38px;border-radius:11px;background:#fff;flex:none;display:flex;align-items:center;justify-content:center}
.oo-tile svg{width:24px;height:24px}
.oo-greet h4{color:#fff;font-size:15px;line-height:1.45;font-weight:700;letter-spacing:-.01em}
.oo-greet p{color:#93A5B3;font-size:12.5px;margin-top:4px;display:flex;align-items:center;gap:6px}
.oo-dot{width:7px;height:7px;border-radius:50%;background:#7FB685;display:inline-block;flex:none}
.oo-greet-x{position:absolute;top:10px;right:12px;background:none;border:none;color:#8494A1;font-size:18px;cursor:pointer;line-height:1;padding:4px}
.oo-greet-x:hover{color:#fff}
.oo-pill{background:#0B1B2B;border:1px solid rgba(132,148,161,.55);color:#fff;border-radius:999px;padding:11px 18px;font-size:13.5px;font-weight:600;cursor:pointer;text-align:right;box-shadow:0 10px 22px rgba(8,19,32,.26);transition:background .15s ease;line-height:1.35}
.oo-pill:hover{background:#16324E;border-color:#A9BACA}

/* ---------- Panel ---------- */
.oo-panel{display:none;width:min(392px,calc(100vw - 32px));height:min(668px,80vh);background:#fff;border:1px solid #DFE6EB;border-radius:22px;box-shadow:0 28px 60px rgba(8,19,32,.30);flex-direction:column;overflow:hidden;color:#17222B}
.oo-panel.open{display:flex;animation:ooUp .25s ease}

/* Home view */
.oo-home{display:flex;flex-direction:column;flex:1;min-height:0}
.oo-home-scroll{padding:22px 22px 18px;overflow-y:auto;overscroll-behavior:contain;flex:1}
.oo-home-top{display:flex;align-items:flex-start;justify-content:space-between;margin-bottom:20px}
.oo-logo-tile{width:46px;height:46px;border-radius:13px;background:#0B1B2B;display:flex;align-items:center;justify-content:center}
.oo-logo-tile svg{width:29px;height:29px}
.oo-x{background:none;border:none;color:#8494A1;font-size:22px;cursor:pointer;line-height:1;padding:4px}
.oo-x:hover{color:#0B1B2B}
.oo-home h2{font-size:24px;line-height:1.28;font-weight:800;letter-spacing:-.02em;color:#0B1B2B;margin-bottom:8px}
.oo-home-sub{font-size:14px;line-height:1.55;color:#52606D;margin-bottom:20px}
.oo-ask{display:flex;align-items:center;gap:8px;background:#fff;border:1px solid #D5DDE3;border-radius:999px;padding:6px 6px 6px 18px;box-shadow:0 4px 14px rgba(8,19,32,.06);margin-bottom:22px}
.oo-ask input{flex:1;border:none;outline:none;font-size:14.5px;font-family:inherit;color:#17222B;min-width:0;background:transparent}
.oo-ask input::placeholder{color:#8494A1}
.oo-ask-send{background:#0B1B2B;border:none;border-radius:50%;width:38px;height:38px;flex:none;cursor:pointer;display:flex;align-items:center;justify-content:center}
.oo-ask-send:hover{background:#16324E}
.oo-ask-send svg{width:16px;height:16px}
.oo-menu{display:flex;flex-direction:column;gap:10px}
.oo-menu-row{display:flex;align-items:center;gap:13px;width:100%;text-align:left;background:#fff;border:1px solid #E2E7EB;border-radius:15px;padding:15px 16px;cursor:pointer;transition:border-color .15s ease,box-shadow .15s ease}
.oo-menu-row:hover{border-color:#B7C5CF;box-shadow:0 6px 16px rgba(8,19,32,.07)}
.oo-menu-ico{width:38px;height:38px;border-radius:50%;background:#EEF3F6;flex:none;display:flex;align-items:center;justify-content:center}
.oo-menu-ico svg{width:19px;height:19px}
.oo-menu-tx{flex:1;min-width:0}
.oo-menu-tx strong{display:block;font-size:14.5px;font-weight:700;color:#0B1B2B;line-height:1.3}
.oo-menu-tx span{display:block;font-size:12.5px;color:#8494A1;line-height:1.45;margin-top:2px}
.oo-menu-arrow{color:#8494A1;font-size:20px;flex:none;line-height:1}

/* Chat view */
.oo-chat{display:none;flex-direction:column;flex:1;min-height:0}
.oo-chat.show{display:flex}
.oo-home.hide{display:none}
.oo-chat-head{display:flex;align-items:center;gap:11px;padding:14px 18px;border-bottom:1px solid #E7EDF1;flex:none;background:#fff}
.oo-back{background:none;border:none;color:#52606D;font-size:22px;cursor:pointer;line-height:1;padding:2px 4px 2px 0}
.oo-back:hover{color:#0B1B2B}
.oo-chat-head .oo-tile{background:#0B1B2B;width:36px;height:36px;border-radius:10px}
.oo-chat-head .oo-tile svg{width:22px;height:22px}
.oo-chat-title{font-size:15px;font-weight:700;color:#0B1B2B;line-height:1.25}
.oo-chat-sub{font-size:12px;color:#8494A1;display:flex;align-items:center;gap:5px;margin-top:1px}
.oo-chat-head .oo-x{margin-left:auto}
.oo-msgs{padding:18px;overflow-y:auto;overscroll-behavior:contain;overflow-x:hidden;display:flex;flex-direction:column;gap:10px;flex:1;background:#F7F9FA;scrollbar-width:thin}
.oo-msg{max-width:86%;padding:11px 14px;border-radius:15px;font-size:14px;line-height:1.58;word-break:break-word;overflow-wrap:anywhere;white-space:pre-wrap}
.oo-msg.bot{background:#fff;color:#24333F;border:1px solid #E2E7EB;align-self:flex-start;border-bottom-left-radius:5px;box-shadow:0 2px 6px rgba(8,19,32,.04)}
.oo-msg.user{background:#0B1B2B;color:#fff;align-self:flex-end;border-bottom-right-radius:5px}
.oo-msg a{color:#0B5FA5}
.oo-typing{align-self:flex-start;background:#fff;border:1px solid #E2E7EB;border-radius:15px;border-bottom-left-radius:5px;padding:13px 15px;display:flex;gap:5px}
.oo-typing i{width:6px;height:6px;border-radius:50%;background:#8494A1;display:block;animation:ooBlink 1.1s infinite}
.oo-typing i:nth-child(2){animation-delay:.18s}.oo-typing i:nth-child(3){animation-delay:.36s}
@keyframes ooBlink{0%,80%,100%{opacity:.3}40%{opacity:1}}
.oo-actions{display:flex;flex-wrap:wrap;gap:8px;align-self:flex-start;width:100%;padding:2px 0}
.oo-btn{background:#0B1B2B;color:#fff;border:1px solid #0B1B2B;border-radius:999px;padding:9px 15px;font-size:13px;font-weight:700;cursor:pointer;text-decoration:none;display:inline-flex;align-items:center;line-height:1.35;transition:background .15s ease;max-width:100%}
.oo-btn:hover{background:#16324E}
.oo-btn.ghost{background:#fff;color:#0B1B2B;border:1px solid #C9D2D9}
.oo-btn.ghost:hover{border-color:#0B1B2B;background:#F3F5F7}
.oo-form{align-self:stretch;background:#fff;border:1px solid #E2E7EB;border-radius:15px;padding:16px;display:flex;flex-direction:column;gap:11px;box-shadow:0 2px 6px rgba(8,19,32,.04)}
.oo-form label{font-size:10.5px;font-weight:700;letter-spacing:.09em;text-transform:uppercase;color:#8494A1;display:block;margin-bottom:4px}
.oo-form input,.oo-form select{width:100%;background:#fff;border:1px solid #C9D2D9;border-radius:9px;color:#17222B;padding:10px 11px;font-size:14px;font-family:inherit}
.oo-form input:focus,.oo-form select:focus{outline:2px solid #0B1B2B;outline-offset:0}
.oo-form .oo-btn{width:100%;text-align:center;justify-content:center;padding:12px}
.oo-inputrow{border-top:1px solid #E7EDF1;padding:12px 14px 8px;flex:none;background:#fff}
.oo-inputwrap{display:flex;gap:9px;align-items:center}
.oo-inputwrap input{flex:1;background:#F3F5F7;border:1px solid #E2E7EB;border-radius:999px;color:#17222B;padding:11px 16px;font-size:14px;font-family:inherit;min-width:0}
.oo-inputwrap input::placeholder{color:#8494A1}
.oo-inputwrap input:focus{outline:2px solid #0B1B2B;background:#fff}
.oo-send{background:#0B1B2B;color:#fff;border:none;border-radius:50%;width:40px;height:40px;flex:none;cursor:pointer;display:flex;align-items:center;justify-content:center}
.oo-send:hover{background:#16324E}
.oo-send svg{width:16px;height:16px}
.oo-note{font-size:11px;color:#8494A1;text-align:center;padding:8px 10px 4px;line-height:1.45}

/* Tabs */
.oo-tabs{display:flex;border-top:1px solid #E7EDF1;flex:none;background:#fff}
.oo-tab{flex:1;background:none;border:none;padding:11px 0 12px;cursor:pointer;display:flex;flex-direction:column;align-items:center;gap:3px;color:#8494A1;font-size:12px;font-weight:600}
.oo-tab svg{width:20px;height:20px}
.oo-tab.active{color:#0B1B2B}
.oo-tab.active svg{stroke:#0B1B2B}

@media (max-width:820px){
  #oo-concierge{bottom:88px;right:16px}
  .oo-panel{height:min(620px,76vh)}
}

/* Mobile compaction (2026-10-26): teaser shrinks to greeting + one shortcut
   so it never blankets the page; the full menu lives in the panel. */
@media (max-width:820px){
  .oo-teaser{width:min(302px,calc(100vw - 32px))}
  .oo-greet{padding:14px 34px 14px 14px}
  .oo-greet h4{font-size:14px}
  .oo-teaser>.oo-pill{display:none}
  .oo-teaser>.oo-pill:first-of-type{display:block;padding:10px 16px;font-size:13px}
  .oo-panel{height:min(624px,calc(100dvh - 116px))}
  .oo-home-scroll{padding:18px 18px 14px}
  .oo-home h2{font-size:21px}
  .oo-msgs{padding:14px}
}
