/* Shimikhan entity search — modal + results */

.sk-search-root {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 4.5rem 1rem 1.5rem;
}

.sk-search-root[hidden] {
  display: none;
}

.sk-search-veil {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.28);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.sk-search-dialog {
  position: relative;
  z-index: 1;
  width: min(920px, calc(100vw - 1.5rem));
  max-height: min(82vh, 860px);
  display: flex;
  flex-direction: column;
  padding: 1.25rem 1.35rem 1.1rem;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 1.5rem;
  background: #ffffff;
  box-shadow:
    0 24px 60px -28px rgba(15, 23, 42, 0.4),
    0 8px 24px -16px rgba(15, 23, 42, 0.18);
  overflow: hidden;
  animation: sk-search-in 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes sk-search-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.sk-search-dialog__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.85rem;
}

.sk-search-dialog__kicker,
.sk-search-page__kicker {
  margin: 0 0 0.25rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #94a3b8;
}

.sk-search-dialog__title {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 800;
  color: #0f172a;
}

.sk-search-dialog__close {
  width: 2.4rem;
  height: 2.4rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 999px;
  background: #f1f5f9;
  color: #334155;
  cursor: pointer;
}

.sk-search-dialog__close svg {
  width: 1.1rem;
  height: 1.1rem;
}

.sk-search-dialog__close:hover {
  background: #e2e8f0;
}

.sk-search-form__field {
  position: relative;
}

.sk-search-form__icon {
  position: absolute;
  top: 50%;
  right: 0.95rem;
  width: 1.2rem;
  height: 1.2rem;
  color: #0ea5e9;
  transform: translateY(-50%);
  pointer-events: none;
}

.sk-search-form__icon svg {
  width: 100%;
  height: 100%;
}

.sk-search-form__input {
  width: 100%;
  padding: 0.85rem 2.7rem 0.85rem 1rem;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  background: #f8fafc;
  color: #0f172a;
  font-family: inherit;
  font-size: 0.98rem;
  outline: none;
}

.sk-search-form__input:focus {
  border-color: #38bdf8;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.15);
}

.sk-search-hints {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  margin: 0.75rem 0 0.35rem;
  font-size: 0.78rem;
  color: #94a3b8;
}

.sk-search-chip {
  border: 0;
  border-radius: 999px;
  padding: 0.28rem 0.7rem;
  background: #e0f2fe;
  color: #0369a1;
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
}

.sk-search-chip:hover {
  background: #bae6fd;
}

.sk-search-body {
  margin-top: 0.7rem;
  min-height: 180px;
  overflow: auto;
  padding-left: 0.15rem;
}

.sk-search-idle__text {
  margin: 0.4rem 0 0.8rem;
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.85;
}

.sk-search-skel {
  height: 76px;
  margin-bottom: 0.65rem;
  border-radius: 1.1rem;
  background: linear-gradient(90deg, #f1f5f9 0%, #e2e8f0 50%, #f1f5f9 100%);
  background-size: 200% 100%;
  animation: sk-search-shimmer 1.1s ease infinite;
}

@keyframes sk-search-shimmer {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

.sk-search-group {
  margin-bottom: 1.15rem;
}

.sk-search-group__title {
  margin: 0 0 0.55rem;
  padding-bottom: 0.35rem;
  border-bottom: 1px solid #eef2f7;
  font-size: 0.82rem;
  font-weight: 800;
  color: #0f172a;
}

.sk-search-group__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.sk-search-card {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 0.85rem;
  align-items: center;
  padding: 0.55rem;
  border: 1px solid #eef2f7;
  border-radius: 1.1rem;
  background: #fbfdff;
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.sk-search-card:hover {
  transform: translateY(-1px);
  border-color: #bae6fd;
  box-shadow: 0 10px 22px -16px rgba(14, 165, 233, 0.7);
}

.sk-search-card__thumb {
  display: block;
  width: 72px;
  height: 72px;
  border-radius: 0.9rem;
  overflow: hidden;
  background: #e2e8f0;
}

.sk-search-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sk-search-card__body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 0;
}

.sk-search-card__badge {
  display: inline-flex;
  margin-bottom: 0.2rem;
  padding: 0.12rem 0.55rem;
  border-radius: 999px;
  background: #fce7f3;
  color: #9d174d;
  font-size: 0.68rem;
  font-weight: 800;
}

.sk-search-card__title {
  font-size: 0.98rem;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.45;
}

.sk-search-card__desc {
  margin-top: 0.15rem;
  font-size: 0.8rem;
  line-height: 1.7;
  color: #64748b;
}

.sk-search-empty {
  padding: 1.2rem 0.4rem 0.6rem;
  text-align: right;
}

.sk-search-empty__title {
  margin: 0 0 0.35rem;
  font-weight: 800;
  color: #0f172a;
}

.sk-search-empty__text {
  margin: 0;
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.85;
}

.sk-search-page__header {
  margin-bottom: 1.5rem;
}

.sk-search-page__title {
  margin: 0 0 1rem;
  font-size: 1.65rem;
  font-weight: 800;
  color: #0f172a;
}

.sk-search-page__form {
  display: flex;
  gap: 0.6rem;
  max-width: 640px;
}

.sk-search-page__form .sk-search-form__input {
  padding-right: 1.1rem;
}

.sk-search-page__submit {
  flex: 0 0 auto;
  padding: 0.75rem 1.2rem;
  border: 0;
  border-radius: 999px;
  background: #0ea5e9;
  color: #fff;
  font-family: inherit;
  font-weight: 700;
  cursor: pointer;
}

.sk-search-page__submit:hover {
  background: #0284c7;
}

.sk-search-page__meta {
  margin: 0.75rem 0 0;
  color: #64748b;
  font-size: 0.85rem;
}

.sk-search-recent__list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

body.sk-search-open {
  overflow: hidden;
}

.sk-search-root .sr-only,
.sk-search-page .sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 640px) {
  .sk-search-root {
    padding: 3.6rem 0.55rem 0.55rem;
  }

  .sk-search-dialog {
    width: 100%;
    max-height: calc(100vh - 4.2rem);
    border-radius: 1.25rem;
    padding: 1rem;
  }

  .sk-search-page__form {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  .sk-search-dialog,
  .sk-search-card,
  .sk-search-skel {
    animation: none !important;
    transition: none !important;
  }
}

html.dark .sk-search-dialog,
html.dark .sk-search-page {
  color: #e2e8f0;
}

html.dark .sk-search-dialog {
  background: #161616;
  border-color: #2a2a2a;
}

html.dark .sk-search-dialog__title,
html.dark .sk-search-page__title,
html.dark .sk-search-group__title,
html.dark .sk-search-card__title,
html.dark .sk-search-empty__title {
  color: #f8fafc;
}

html.dark .sk-search-form__input {
  background: #1c1c1c;
  border-color: #2a2a2a;
  color: #f8fafc;
}

html.dark .sk-search-dialog__close {
  background: #262626;
  color: #e2e8f0;
}

html.dark .sk-search-card {
  background: #1c1c1c;
  border-color: #2a2a2a;
}

html.dark .sk-search-group__title {
  border-bottom-color: #2a2a2a;
}

html.dark .sk-search-card__desc,
html.dark .sk-search-idle__text,
html.dark .sk-search-empty__text,
html.dark .sk-search-page__meta {
  color: #94a3b8;
}

html.dark .sk-search-skel {
  background: linear-gradient(90deg, #1c1c1c 0%, #2a2a2a 50%, #1c1c1c 100%);
  background-size: 200% 100%;
}
