/* Customer support chat — shared by the site widget and the admin chat screen.
   Plain CSS (no Tailwind build needed). Colours match the site palette. */

/* ---------- Floating widget ---------- */
.gel-chat { position: fixed; right: 20px; bottom: 20px; z-index: 55; font-family: Inter, 'Segoe UI', Arial, sans-serif; }
.gel-chat.has-cookie { bottom: 96px; }
.gel-chat-btn {
  position: relative; display: flex; align-items: center; gap: 8px; height: 54px; padding: 0 20px 0 16px;
  border: 0; border-radius: 999px; background: #0fdb6a; color: #070b13; font-weight: 700; font-size: 14px; cursor: pointer;
  box-shadow: 0 8px 24px rgba(15, 219, 106, .35), 0 2px 6px rgba(7, 11, 19, .25);
  transition: transform .15s ease, box-shadow .15s ease;
}
.gel-chat-btn:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(15, 219, 106, .45), 0 2px 6px rgba(7, 11, 19, .25); }
.gel-chat-btn svg { flex: none; }
.gel-chat-badge {
  position: absolute; top: -6px; right: -4px; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px;
  background: #ef4444; color: #fff; font-size: 11px; font-weight: 700; line-height: 20px; text-align: center; display: none;
}
.gel-chat-badge.on { display: block; }

.gel-chat-panel {
  position: absolute; right: 0; bottom: 70px; width: 370px; max-width: calc(100vw - 24px); height: 540px; max-height: calc(100vh - 110px);
  display: none; flex-direction: column; overflow: hidden; border-radius: 18px; background: #fff;
  box-shadow: 0 24px 60px rgba(7, 11, 19, .35), 0 0 0 1px rgba(7, 11, 19, .08);
}
.gel-chat.open .gel-chat-panel { display: flex; animation: gel-chat-in .18s ease-out; }
@keyframes gel-chat-in { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }

.gel-chat-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: #070b13; color: #f4f6f9; }
.gel-chat-avatar { flex: none; display: flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 50%; background: #0fdb6a; color: #070b13; }
.gel-chat-title { font-family: 'Space Grotesk', Inter, sans-serif; font-weight: 700; font-size: 15px; line-height: 1.2; }
.gel-chat-sub { margin-top: 2px; font-size: 12px; color: #9aabc5; display: flex; align-items: center; gap: 6px; }
.gel-chat-sub::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #39ff8f; box-shadow: 0 0 8px #39ff8f; }
.gel-chat-close { margin-left: auto; border: 0; background: transparent; color: #9aabc5; cursor: pointer; padding: 6px; border-radius: 8px; }
.gel-chat-close:hover { color: #fff; background: rgba(255, 255, 255, .08); }

.gel-chat-body { flex: 1; overflow-y: auto; padding: 16px; background: #f4f6f9; display: flex; flex-direction: column; gap: 10px; }
.gel-chat-empty { margin: auto; text-align: center; color: #455f88; font-size: 13px; line-height: 1.6; padding: 0 12px; }
.gel-chat-empty strong { display: block; margin-bottom: 4px; color: #070b13; font-size: 15px; font-family: 'Space Grotesk', Inter, sans-serif; }

.gel-msg { max-width: 82%; display: flex; flex-direction: column; }
.gel-msg-bubble { padding: 9px 13px; border-radius: 16px; font-size: 14px; line-height: 1.45; white-space: pre-wrap; word-wrap: break-word; overflow-wrap: anywhere; }
.gel-msg-time { margin-top: 3px; font-size: 11px; color: #657da5; }
.gel-msg.me { align-self: flex-end; align-items: flex-end; }
.gel-msg.me .gel-msg-bubble { background: #2563eb; color: #fff; border-bottom-right-radius: 5px; }
.gel-msg.them { align-self: flex-start; }
.gel-msg.them .gel-msg-bubble { background: #fff; color: #0b1220; border: 1px solid #e4e9f1; border-bottom-left-radius: 5px; }

.gel-chat-form { display: flex; align-items: flex-end; gap: 8px; padding: 12px; border-top: 1px solid #e4e9f1; background: #fff; }
.gel-chat-input {
  flex: 1; resize: none; max-height: 110px; min-height: 40px; padding: 10px 12px; border: 1px solid #c7d1e0; border-radius: 12px;
  font: inherit; font-size: 14px; line-height: 1.4; color: #0b1220; outline: none;
}
.gel-chat-input:focus { border-color: #60a5fa; box-shadow: 0 0 0 3px rgba(96, 165, 250, .25); }
.gel-chat-send {
  flex: none; display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border: 0; border-radius: 12px;
  background: #0fdb6a; color: #070b13; cursor: pointer;
}
.gel-chat-send:disabled { opacity: .5; cursor: default; }
.gel-chat-note { padding: 0 14px 10px; background: #fff; font-size: 11px; color: #657da5; text-align: center; }
.gel-chat-error { margin: 0 12px 8px; padding: 6px 10px; border-radius: 8px; background: #fef2f2; color: #b91c1c; font-size: 12px; display: none; }
.gel-chat-error.on { display: block; }

/* Sign-in / verify prompt inside the panel */
.gel-chat-gate { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 28px; text-align: center; background: #f4f6f9; }
.gel-chat-gate h3 { margin: 0; font-family: 'Space Grotesk', Inter, sans-serif; font-size: 18px; color: #070b13; }
.gel-chat-gate p { margin: 0; font-size: 13px; line-height: 1.6; color: #455f88; }
.gel-chat-gate .row { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; margin-top: 4px; }
.gel-chat-link {
  display: inline-block; padding: 10px 18px; border-radius: 10px; font-size: 14px; font-weight: 700; text-decoration: none; border: 1px solid transparent; cursor: pointer;
}
.gel-chat-link.primary { background: #0fdb6a; color: #070b13; }
.gel-chat-link.ghost { background: #fff; color: #293c59; border-color: #c7d1e0; }

@media (max-width: 480px) {
  .gel-chat { right: 12px; bottom: 12px; }
  .gel-chat.has-cookie { bottom: 130px; }
  .gel-chat-btn span { display: none; }
  .gel-chat-btn { width: 54px; padding: 0; justify-content: center; }
  .gel-chat.open .gel-chat-panel { position: fixed; inset: 0; width: auto; max-width: none; height: auto; max-height: none; border-radius: 0; }
}

/* ---------- Admin chat screen ---------- */
.gel-admin-chat { display: grid; grid-template-columns: 320px 1fr; gap: 16px; height: calc(100vh - 190px); min-height: 460px; }
@media (max-width: 800px) { .gel-admin-chat { grid-template-columns: 1fr; height: auto; } .gel-admin-chat .gel-ac-main { height: 70vh; } }
.gel-ac-list, .gel-ac-main { border: 1px solid #1c2a40; border-radius: 16px; background: rgba(28, 42, 64, .5); overflow: hidden; display: flex; flex-direction: column; }
.gel-ac-list-body { overflow-y: auto; flex: 1; }
.gel-ac-item { display: block; width: 100%; padding: 13px 16px; border: 0; border-bottom: 1px solid #1c2a40; background: transparent; text-align: left; cursor: pointer; color: #c7d1e0; }
.gel-ac-item:hover { background: rgba(255, 255, 255, .04); }
.gel-ac-item.active { background: rgba(57, 255, 143, .08); box-shadow: inset 3px 0 0 #39ff8f; }
.gel-ac-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.gel-ac-name { font-weight: 600; font-size: 14px; color: #f4f6f9; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gel-ac-when { font-size: 11px; color: #657da5; flex: none; }
.gel-ac-prev { margin-top: 3px; font-size: 12px; color: #9aabc5; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gel-ac-dot { flex: none; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: #39ff8f; color: #070b13; font-size: 11px; font-weight: 700; text-align: center; line-height: 18px; }
.gel-ac-empty { margin: auto; padding: 24px; text-align: center; font-size: 14px; color: #657da5; }
.gel-ac-head { padding: 14px 18px; border-bottom: 1px solid #1c2a40; }
.gel-ac-head strong { color: #f4f6f9; font-family: 'Space Grotesk', Inter, sans-serif; font-size: 16px; }
.gel-ac-head span { display: block; margin-top: 2px; font-size: 12px; color: #9aabc5; }
.gel-ac-main .gel-chat-body { background: transparent; }
.gel-ac-main .gel-msg.them .gel-msg-bubble { background: #1c2a40; color: #e4e9f1; border-color: #293c59; }
.gel-ac-main .gel-msg.me .gel-msg-bubble { background: #0fdb6a; color: #070b13; }
.gel-ac-main .gel-msg-time { color: #657da5; }
.gel-ac-main .gel-chat-empty { color: #9aabc5; }
.gel-ac-main .gel-chat-form { background: rgba(7, 11, 19, .4); border-top-color: #1c2a40; flex-wrap: wrap; }
.gel-ac-main .gel-chat-input { background: #0b1220; color: #f4f6f9; border-color: #293c59; }
.gel-ac-quick { width: 100%; padding: 7px 10px; border-radius: 10px; border: 1px solid #293c59; background: #0b1220; color: #9aabc5; font-size: 13px; }

/* Admin leads: process-guide number badges and legend dots */
.gel-num { width: 24px; height: 24px; }
.gel-dot { display: inline-block; width: 8px; height: 8px; margin-right: 4px; }
.lead-card.hidden { display: none; }

/* Main menu: keep every label on one line and tighten spacing on mid-size screens so six links fit */
.gel-nav a { white-space: nowrap; }
@media (max-width: 1180px) { .gel-nav { gap: 0.9rem; font-size: 0.8rem; } }

/* Tablet / small-laptop widths (768-1365px): six menu links + currency/login controls don't fit on one row, so use the
   compact hamburger menu there too (phones already do). */
@media (min-width: 768px) and (max-width: 1365px) {
  header nav > .gel-nav, header nav > .gel-nav-right { display: none !important; }
  #mobile-menu-btn { display: block !important; }
  #mobile-menu:not(.hidden) { display: block !important; }
}


/* Top bar: give it room. Wider container, nothing wraps, comfortable gaps. */
.gel-navbar { column-gap: 2rem; }
.gel-navbar > a:first-child { white-space: nowrap; flex: none; }
.gel-nav { gap: 1.75rem; flex: 1 1 auto; justify-content: center; }
.gel-nav-right { gap: 1rem; flex: none; white-space: nowrap; }
.gel-nav-right a { white-space: nowrap; }
@media (min-width: 1366px) and (max-width: 1500px) { .gel-nav { gap: 1.25rem; } .gel-navbar { column-gap: 1.25rem; } }

/* Admin top bar: two rows — brand + account on top, the section tabs on their own row underneath. */
.gel-admin-bar { max-width: 84rem; margin: 0 auto; padding: 0.9rem 1.5rem 0; }
.gel-admin-top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.gel-admin-tabs { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 1.75rem; margin-top: 0.8rem; padding: 0.7rem 0 0.8rem; border-top: 1px solid rgba(100, 116, 139, .25); font-size: 0.9rem; }
.gel-admin-tabs a { white-space: nowrap; padding: 0.2rem 0; }
.gel-admin-user { display: flex; align-items: center; gap: 1.1rem; white-space: nowrap; }
@media (max-width: 640px) { .gel-admin-bar { padding: 0.75rem 1rem 0; } .gel-admin-tabs { gap: 0.3rem 1.2rem; } }
/* Admin pages: let wide list pages use the same stretched width as the top bar (forms keep their narrower width). */
body.bg-hull-900 main.max-w-6xl { max-width: 84rem; }
body.bg-hull-900 main.max-w-5xl { max-width: 72rem; }

