/* Global search palette (public/js/search.js). Matches the CRM: white panel,
 * navy header, teal focus, Lexend. Sits above the drawer and modals (z-palette 60). */
.gs-root { position: fixed; inset: 0; z-index: var(--z-palette, 60); font-family: var(--font-sans); }
.gs-root[hidden] { display: none !important; }
.gs-mask { position: absolute; inset: 0; background: rgba(26, 29, 44, .42); backdrop-filter: blur(1.5px); }
.gs-panel {
  position: relative; margin: 9vh auto 0; width: min(680px, 94vw); max-height: 78vh;
  background: var(--paper, #fff); border-radius: 14px; overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .32); display: flex; flex-direction: column;
  animation: gs-in .12s ease-out;
}
@keyframes gs-in { from { transform: translateY(-6px); opacity: 0; } to { transform: none; opacity: 1; } }

.gs-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: var(--ncc-blue, #444970); color: #fff; }
.gs-ico { display: inline-flex; align-items: center; line-height: 1; opacity: .85; }
.gs-input {
  flex: 1; min-width: 0; font: inherit; font-size: 17px; font-weight: 400; color: #fff;
  background: transparent; border: 0; outline: 0; padding: 6px 2px; caret-color: var(--ncc-teal, #56F0D1);
}
.gs-input::placeholder { color: rgba(255, 255, 255, .6); }
.gs-input::-webkit-search-cancel-button { -webkit-appearance: none; }
.gs-root .gs-input:focus, .gs-root .gs-input:focus-visible { outline: 0; box-shadow: none; border-radius: 0; }  /* the header bar below carries the focus cue */
.gs-head:focus-within { box-shadow: inset 0 -3px 0 var(--ncc-teal, #56F0D1); }
.gs-kbd {
  display: inline-block; font-size: 10.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  padding: 2px 6px; border-radius: 5px; border: 1px solid rgba(255, 255, 255, .35); color: rgba(255, 255, 255, .85);
}
.gs-status { padding: 8px 16px 4px; font-size: 12px; color: var(--ncc-grey-dark, #6e6e6e); }

.gs-list { overflow: auto; flex: 1; padding: 4px 8px 8px; }
.gs-group { margin-top: 6px; }
.gs-group-title { font-size: 10.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--ncc-blue-light, #6d728f); padding: 6px 8px 4px; }
.gs-item {
  display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 9px; cursor: pointer;
  border: 1px solid transparent;
}
.gs-item.is-active { background: #eefcf8; border-color: var(--ncc-teal, #56F0D1); }
.gs-item-main { flex: 1; min-width: 0; }
.gs-item-title { font-size: 14px; font-weight: 500; color: var(--ink, #1a1d2c); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-item-sub { font-size: 12px; color: var(--ncc-grey-dark, #6e6e6e); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gs-item-right { display: flex; flex-direction: column; align-items: flex-end; gap: 3px; flex-shrink: 0; }
.gs-type {
  flex-shrink: 0; width: 74px; text-align: center; font-size: 10.5px; font-weight: 600; letter-spacing: .03em;
  padding: 3px 0; border-radius: 6px; background: var(--ncc-grey, #ECEAEA); color: var(--ncc-blue-dark, #2f344f);
}
.gs-type-scheme { background: #e4e6f2; }
.gs-type-task { background: #fff5dc; color: #7a5a00; }
.gs-type-switchoff { background: #fde6e6; color: #8a2e2e; }
.gs-type-site { background: #e0f4f1; color: #1f6f66; }
.gs-type-person { background: #eaf1f6; color: #2f6f8f; }
.gs-pill { font-size: 10.5px; font-weight: 600; padding: 2px 8px; border-radius: 999px; background: var(--ncc-blue, #444970); color: #fff; white-space: nowrap; }
.gs-pill-done, .gs-pill-cancelled { background: var(--ncc-grey-mid, #d4d2d2); color: var(--ink, #1a1d2c); }
.gs-pill-in_progress { background: var(--ok, #2a9d8f); }
.gs-district { font-size: 11px; color: var(--ncc-grey-dark, #6e6e6e); white-space: nowrap; }

.gs-foot { display: flex; gap: 14px; padding: 8px 16px; border-top: 1px solid var(--ncc-grey, #ECEAEA); font-size: 11.5px; color: var(--ncc-grey-dark, #6e6e6e); background: var(--bg, #f5f4f1); }
.gs-foot .gs-kbd { border-color: var(--ncc-grey-mid, #d4d2d2); color: var(--ncc-blue-dark, #2f344f); }

@media (max-width: 600px) {
  .gs-panel { margin-top: 4vh; width: 96vw; max-height: 86vh; }
  .gs-type { width: 62px; font-size: 10px; }
  .gs-item-right { display: none; }
  .gs-foot { display: none; }
}
