/* KINGZ V5.9.3 sitewide private support chat, Gold Forge-compatible. */
.k93-fab{position:fixed;right:18px;bottom:22px;z-index:9900;display:flex;align-items:center;gap:9px;border:1px solid #d6a745;border-radius:50px;padding:14px 18px;background:linear-gradient(125deg,#1b1710,#372711);color:#fff1ce;box-shadow:0 10px 34px #000b,0 0 14px #a16b2944;cursor:pointer;font:800 13px/1.1 system-ui,sans-serif;letter-spacing:.035em}
.k93-fab:focus-visible,.k93-panel button:focus-visible,.k93-panel textarea:focus-visible{outline:2px solid #fff1bb;outline-offset:3px}
.k93-panel{position:fixed;z-index:9901;right:18px;bottom:88px;width:min(380px,calc(100vw - 28px));height:min(510px,calc(100dvh - 145px));background:#0e1113;border:1px solid #c5943d;box-shadow:0 20px 80px #000d;border-radius:13px;display:flex;flex-direction:column;overflow:hidden;color:#f6ebd9;font:14px/1.5 system-ui,sans-serif}
.k93-panel[hidden]{display:none!important}
.k93-head{padding:14px 16px;background:linear-gradient(135deg,#211912,#473117);border-bottom:1px solid #a47839;display:flex;justify-content:space-between;align-items:center;gap:10px}
.k93-head strong{font-size:14px;color:#ffe2a1;letter-spacing:.05em}.k93-head small{display:block;color:#d7c5a2;font-size:11px}.k93-x{background:transparent;border:1px solid #9d855e;color:#fff;padding:3px 10px;font-size:21px;cursor:pointer;border-radius:5px}
.k93-messages{padding:15px;overflow:auto;flex:1;display:flex;flex-direction:column;gap:10px;background:radial-gradient(circle at 60% 0%,#3b2b192e,transparent 55%),#0f1316}
.k93-message{align-self:flex-start;max-width:92%;border:1px solid #4d4638;background:#1d2124;border-radius:11px;padding:9px 12px;overflow-wrap:anywhere;white-space:pre-wrap}
.k93-message.mine{align-self:flex-end;background:#3a2d19;border-color:#c29548}.k93-message small{display:block;color:#d8b66f;margin-bottom:4px;font-size:10px}
.k93-state{padding:8px 13px;border-top:1px solid #474135;color:#e6c98d;min-height:19px;font-size:11px}
.k93-form{padding:10px;display:flex;align-items:stretch;gap:7px;background:#171b1d}.k93-form textarea{background:#0c0f12;color:#fff;border:1px solid #6a5c45;border-radius:7px;flex:1;min-width:0;padding:10px;resize:vertical;max-height:100px;font:13px system-ui;line-height:1.4}.k93-form button{border:1px solid #f3d182;background:linear-gradient(#e8bd61,#a77426);color:#1d1206;font-weight:900;border-radius:7px;padding:0 13px;cursor:pointer}
.k93-form button:disabled{opacity:.55;cursor:wait}.k93-signin{padding:22px;line-height:1.6}.k93-signin a{display:inline-block;color:#16100a;background:#e6bc65;border-radius:6px;padding:9px 12px;margin-top:13px;font-weight:800;text-decoration:none}
@media(max-width:700px){.k93-fab{bottom:88px;right:10px;padding:11px 13px;font-size:12px}.k93-panel{right:8px;bottom:143px;width:calc(100vw - 16px);height:min(430px,calc(100dvh - 175px))}}

/* Replace the old desktop-only homepage button with the unified mobile+desktop entry point.
   Keep the legacy element in the DOM because the existing app.js binds its events. */
#chatFab{display:none!important}
@media(max-width:700px){
 .k93-fab{bottom:calc(82px + env(safe-area-inset-bottom,0px));right:12px;min-height:48px;max-width:calc(100vw - 24px);padding:12px 16px;box-shadow:0 7px 28px #000d,0 0 13px #bb873f66}
 .k93-panel{right:8px;bottom:calc(142px + env(safe-area-inset-bottom,0px));width:calc(100vw - 16px);height:min(480px,calc(100dvh - 184px));min-height:180px}
}
@media(max-height:500px) and (max-width:700px){
 .k93-panel{bottom:8px;height:calc(100dvh - 16px);min-height:0}
 .k93-head{padding:8px 12px}.k93-form{padding:6px}.k93-messages{padding:8px}
}

/* Ensure the authenticated-chat form disappears for signed-out visitors despite flex layout. */
.k93-form[hidden]{display:none!important}

/* My Account links back to the same authenticated, persistent chat. */
.k93-account-messages{scroll-margin-top:26px}
.k93-account-messages h3{margin:12px 0 8px}
.k93-account-messages p{line-height:1.6}
.k93-account-messages [data-kingz-open-messages]{min-height:44px;padding:12px 17px;cursor:pointer}
.k93-account-messages .k93-account-note{font-size:12px;color:#cbb78c;margin-top:12px}

/* Hide the floating support trigger while any cart/modal drawer is open so it never overlays checkout or Clear List. */
body.lock .k93-fab{display:none!important}
body.lock .k93-panel{display:none!important}

/* Customer notifications + review prompt (V5.9.7 review milestone). */
.k93-fab{position:fixed}
.k93-fab .krs-chat-unread{position:absolute;right:4px;top:-10px;min-width:22px;height:22px;padding:2px 5px;box-sizing:border-box;border-radius:999px;border:2px solid #101510;background:#c1ff68;color:#112313;display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:900}
.k93-fab .krs-chat-unread[hidden]{display:none}
.k93-fab.krs-has-unread{border-color:#c1ff68;box-shadow:0 0 13px #baff6580}
.krs-customer-toast{position:fixed;right:14px;bottom:calc(165px + env(safe-area-inset-bottom,0px));z-index:125;max-width:min(360px,calc(100vw - 28px));display:flex;flex-wrap:wrap;gap:9px;align-items:center;background:#16291e;border:2px solid #d5b574;border-radius:12px;padding:15px;color:#fae4b5;box-shadow:0 9px 27px #000c;font-size:13px;font-weight:700}
.krs-customer-toast[hidden],.krs-review-prompt[hidden]{display:none!important}
.krs-customer-toast>span{flex-basis:100%}
.krs-customer-toast button{border:1px solid #b99a55;border-radius:6px;padding:7px 12px;background:#271e12;color:#f4d18b;font-size:11px;font-weight:800;cursor:pointer}
.krs-customer-toast button:last-child{margin-left:auto}
.krs-review-prompt{position:fixed;inset:0;z-index:150;background:#000b;display:flex;align-items:center;justify-content:center;padding:18px}
.krs-review-dialog{position:relative;box-sizing:border-box;width:min(420px,100%);max-height:90vh;overflow:auto;background:linear-gradient(160deg,#17251b,#11150e 70%);border:2px solid #d2ae63;border-radius:17px;padding:30px 22px;text-align:center;color:#fbf5e7;box-shadow:0 15px 55px #000d}
.krs-review-dialog .krs-review-close{position:absolute;top:8px;right:10px;background:transparent;border:0;color:#f8e7bf;font-size:28px;cursor:pointer}
.krs-review-mark{font-size:30px;margin-bottom:8px}
.krs-review-dialog h2{font-size:24px;line-height:1.2;color:#f5d180;margin:8px 0 12px}
.krs-review-dialog p{font-size:14px;color:#d4d9c9}
.krs-review-stars{font-size:28px;color:#f1c66f;letter-spacing:3px;margin:14px 0}
.krs-review-action{display:block;background:linear-gradient(120deg,#f6d48b,#bb883f);padding:15px;margin:15px 0 9px;color:#1c1509!important;border-radius:7px;font-weight:900;text-decoration:none}
.krs-review-later{background:transparent;border:0;color:#d4c49c;text-decoration:underline;cursor:pointer;padding:8px;font-size:13px}
.krs-review-dialog small{display:block;font-size:11px;line-height:1.4;color:#b9c3b0;margin-top:8px}
@media(max-width:700px){.krs-customer-toast{right:9px;bottom:calc(164px + env(safe-area-inset-bottom,0px))}}

/* Reliable customer order notifications & order conversation chooser */
.k93-thread-label{display:block;margin:8px 12px;color:#e9ce91;font-size:10px;font-weight:900;letter-spacing:.08em}
.k93-thread-choice{display:block;width:100%;box-sizing:border-box;margin-top:5px;padding:9px;background:#121e17;border:1px solid #a88b52;color:#f7edce;border-radius:7px;font-size:12px;max-width:100%}
.krs-order-bell{position:fixed;right:14px;top:83px;z-index:96;width:46px;height:46px;border:1px solid #d8b66c;border-radius:50%;background:#171c12;color:#f6da98;box-shadow:0 4px 12px #0008;cursor:pointer;font-size:21px}
.krs-order-bell[hidden]{display:none!important}
.krs-order-bell-count{position:absolute;right:-5px;top:-6px;min-width:20px;padding:3px;border-radius:50%;background:#c4fa78;color:#172112;font-size:11px;font-weight:900}
.krs-order-bell-count[hidden]{display:none}
.krs-order-notice-tray{position:fixed;z-index:98;right:10px;top:137px;width:min(390px,calc(100vw - 20px));max-height:min(60dvh,480px);overflow-y:auto;box-sizing:border-box;background:#121c15;border:1px solid #bda167;border-radius:12px;color:#e8ecd9;box-shadow:0 12px 40px #000c;padding:13px}
.krs-order-notice-tray[hidden]{display:none}
.krs-order-tray-heading{display:flex;align-items:center;justify-content:space-between;font-size:13px;font-weight:900;color:#f1d18b;border-bottom:1px solid #60573a;padding-bottom:10px}
.krs-order-tray-heading button{border:0;background:transparent;color:#f1d18b;font-size:22px;cursor:pointer}
.krs-order-notice{display:grid;gap:4px;border-bottom:1px solid #344839;padding:11px 2px}
.krs-order-notice.is-unread{border-left:3px solid #b5fa71;padding-left:10px;background:#1b2a1c}
.krs-order-notice strong{font-size:13px;color:#f2d896}
.krs-order-notice span{font-size:12px;line-height:1.5}
.krs-order-notice small{font-size:10px;color:#a8baa6}
@media(max-width:700px){.krs-order-bell{top:68px;right:8px;width:39px;height:39px;font-size:18px}.krs-order-notice-tray{top:112px}}
