*,
*::before,
*::after {
  box-sizing: border-box;
}

.hr-root {
  width: 100%;
  height: 100%;
  display: flex;
  padding: 0;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  background: #f8fafc;
  color: #141823;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

.hr-app {
  width: 100%;
  height: 100%;
  min-height: 0;
  background: #f8fafc;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.hr-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
}

.hr-filters {
  padding: 12px 14px 10px;
  background: #fff;
}

.hr-filter-grid {
  display: grid;
  grid-template-columns: 1fr 1.35fr 0.85fr;
  gap: 12px 14px;
}

.hr-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.hr-field > span {
  font-size: 0.78rem;
  font-weight: 600;
  color: #334155;
}

.hr-field input {
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  padding: 8px 10px;
  font-size: 0.82rem;
  background: #f8fafc;
  color: #334155;
  outline: none;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.hr-field input.is-focused {
  border-color: #0284c7;
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.14);
  background: #fff;
}

.hr-select {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: #0f172a;
  font-weight: 500;
}

.hr-select.is-open {
  border-color: #0284c7;
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.14);
  background: #fff;
}

.hr-select svg {
  color: #64748b;
  flex-shrink: 0;
}

.hr-result-hint {
  flex: 1;
  font-size: 0.82rem;
  color: #64748b;
  font-weight: 500;
  align-self: center;
}

.hr-result-hint.is-success {
  color: #0369a1;
}

.hr-filters__label {
  margin: 0 0 6px;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #64748b;
}

.hr-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 34px;
}

.hr-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 500;
  background: #e0f2fe;
  color: #0369a1;
  border: 1px solid #bae6fd;
  opacity: 0;
  transform: translateY(6px) scale(0.96);
  transition:
    opacity 0.45s ease,
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.hr-chip.is-in {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.hr-chip svg {
  width: 14px;
  height: 14px;
  opacity: 0.7;
}

.hr-search-row {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  align-items: center;
}

.hr-btn {
  border: none;
  border-radius: 10px;
  padding: 9px 16px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  background: linear-gradient(180deg, #0ea5e9 0%, #0284c7 100%);
  color: #fff;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hr-btn.is-pressed {
  transform: scale(0.97);
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.3);
}

.hr-results {
  flex: 1;
  padding: 0;
  position: relative;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #fff;
}

.hr-table-shell {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  width: 100%;
  margin: 0;
  padding: 12px 14px 14px;
  background: #fff;
  border: none;
  border-top: 1px solid #e2e8f0;
  border-radius: 0;
  overflow: hidden;
}

.hr-table-shell:not(:has(.hr-candidates.is-in)) {
  display: none;
}

.hr-loader {
  position: absolute;
  inset: 0 0 0;
  border-radius: 0;
  background: linear-gradient(90deg, #f1f5f9 0%, #e2e8f0 50%, #f1f5f9 100%);
  background-size: 200% 100%;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.hr-loader.is-on {
  opacity: 1;
  animation: hr-shimmer 1.1s ease-in-out infinite;
}

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

.hr-candidates {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 2px 12px rgba(15, 23, 42, 0.06);
  overflow: hidden;
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity 0.5s ease,
    transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.hr-candidates.is-in {
  opacity: 1;
  transform: translateY(0);
}

.hr-candidates__header,
.hr-candidates__row {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.65fr) 108px;
  gap: 10px;
  align-items: center;
}

.hr-candidates__header {
  padding: 10px 16px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
}

.hr-candidates__header > span:nth-child(3) {
  justify-self: center;
  text-align: center;
  width: 100%;
}

.hr-candidates__body {
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.hr-candidates__row {
  padding: 10px 16px;
  border-bottom: 1px solid #e2e8f0;
  background: #fff;
  transition: background 0.2s ease;
}

.hr-candidates__row:last-child {
  border-bottom: none;
}

.hr-candidates__row.is-highlight {
  background: rgba(2, 132, 199, 0.05);
  box-shadow: inset 3px 0 0 #0284c7;
}

.hr-location {
  font-size: 0.78rem;
  color: #334155;
  line-height: 1.3;
}

.hr-person {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.hr-avatar {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0ea5e9, #0284c7);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hr-avatar--violet {
  background: linear-gradient(135deg, #a78bfa, #6366f1);
}

.hr-avatar--rose {
  background: linear-gradient(135deg, #fb7185, #e11d48);
}

.hr-avatar--teal {
  background: linear-gradient(135deg, #2dd4bf, #0d9488);
}

.hr-person__text strong {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: #1e293b;
}

.hr-person__text span {
  display: block;
  font-size: 0.68rem;
  color: #64748b;
  margin-top: 2px;
}

.hr-match {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  width: 100%;
  max-width: 108px;
  margin-inline: auto;
  text-align: center;
}

.hr-match-tier {
  margin: 0;
  font-family: 'Montserrat', 'Inter', system-ui, sans-serif;
  font-size: 10px;
  line-height: 1.2;
  font-weight: 700;
  white-space: nowrap;
}

.hr-match--best .hr-match-tier {
  color: #16a34a;
}

.hr-match--good .hr-match-tier {
  color: #0284c7;
}

.hr-match-subtitle {
  margin: 0;
  font-size: 11px;
  line-height: 1.2;
  font-weight: 400;
  color: #64748b;
  text-transform: lowercase;
}

.hr-match-track {
  width: 100%;
  margin-top: 4px;
  height: 7px;
  border-radius: 999px;
  background: #f8fafc;
  border: 1px solid rgba(2, 132, 199, 0.2);
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04);
  overflow: hidden;
}

.hr-match-fill {
  height: 100%;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.08);
}

.hr-match--best .hr-match-track {
  border-color: rgba(34, 197, 94, 0.45);
}

.hr-match--best .hr-match-fill {
  background: linear-gradient(90deg, #4ade80 0%, #16a34a 100%);
  box-shadow: inset 0 0 0 1px rgba(22, 163, 74, 0.35);
}

.hr-match--good .hr-match-track {
  border-color: rgba(2, 132, 199, 0.45);
}

.hr-match--good .hr-match-fill {
  background: linear-gradient(90deg, #38bdf8 0%, #0284c7 100%);
  box-shadow: inset 0 0 0 1px rgba(2, 132, 199, 0.35);
}

.hr-candidates__row > .hr-match {
  justify-self: center;
  width: 100%;
  min-width: 0;
  max-width: 108px;
}

.hr-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
  z-index: 10;
}

.hr-modal-backdrop.is-in {
  opacity: 1;
}

.hr-modal {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -46%) scale(0.94);
  width: min(520px, calc(100% - 20px));
  max-height: calc(100% - 12px);
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 24px 64px rgba(15, 23, 42, 0.28);
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.4s ease,
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 20;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.hr-modal.is-in {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  pointer-events: auto;
}

.hr-modal__head {
  padding: 14px 16px;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  flex-shrink: 0;
}

.hr-avatar--lg {
  width: 48px;
  height: 48px;
  font-size: 15px;
  flex-shrink: 0;
}

.hr-modal__identity strong {
  display: block;
  font-weight: 700;
  letter-spacing: -0.02em;
  font-size: 1.1rem;
  line-height: 1.25;
}

.hr-modal__identity > span {
  display: block;
  margin-top: 4px;
  font-size: 0.72rem;
  color: #64748b;
}

.hr-modal__content {
  padding: 0 16px 16px;
  overflow: hidden;
  flex: 1;
  min-height: 0;
}

.hr-modal__section {
  margin-bottom: 10px;
}

.hr-modal__section--experience h3 {
  margin-bottom: 8px;
}

.hr-modal__section h3 {
  margin: 0 0 4px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #64748b;
}

.hr-timeline {
  list-style: none;
  margin: 0;
  padding: 0;
}

.hr-timeline li {
  padding: 0 0 8px 10px;
  border-left: 2px solid #e2e8f0;
  margin-left: 4px;
}

.hr-timeline li strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 600;
  color: #0f172a;
}

.hr-timeline li > span {
  display: block;
  font-size: 0.82rem;
  color: #64748b;
  margin-top: 2px;
}

.hr-timeline li p {
  margin: 3px 0 0;
  font-size: 0.75rem;
  line-height: 1.4;
  color: #475569;
}

.hr-skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.hr-skill-tags span {
  font-size: 0.75rem;
  font-weight: 500;
  padding: 4px 9px;
  border-radius: 8px;
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #e2e8f0;
}

.hr-about {
  margin: 0;
  font-size: 0.75rem;
  line-height: 1.45;
  color: #475569;
}

.hr-profile-panel {
  padding: 12px 14px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.hr-profile-label {
  margin: 0 0 10px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #64748b;
}

.hr-profile-list {
  margin: 0 0 14px;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.hr-profile-list li {
  font-size: 0.72rem;
  line-height: 1.45;
  color: #475569;
}

.hr-profile-list strong {
  color: #1e293b;
}

.hr-open-email {
  width: 100%;
  border: none;
  border-radius: 10px;
  padding: 11px 16px;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  color: #fff;
  background: #0284c7;
  cursor: default;
  transition: background 0.15s ease, transform 0.15s ease;
}

.hr-open-email.is-pressed {
  transform: scale(0.98);
  background: #0369a1;
}

.hr-email-panel {
  padding: 14px 16px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.hr-email-label {
  margin: 0 0 12px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #64748b;
}

.hr-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.hr-field > span {
  font-size: 0.68rem;
  font-weight: 600;
  color: #475569;
}

.hr-field input,
.hr-field textarea {
  width: 100%;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  font-size: 0.78rem;
  line-height: 1.5;
  outline: none;
  background: #fff;
  color: #1e293b;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.hr-field textarea {
  min-height: 4.6em;
  max-height: 4.6em;
  resize: none;
  overflow: hidden;
  line-height: 1.45;
}

.hr-email-send {
  margin-top: 4px;
  width: 100%;
  border: none;
  border-radius: 10px;
  padding: 11px 16px;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  color: #fff;
  background: #0284c7;
  cursor: default;
  transition: background 0.15s ease, transform 0.15s ease;
}

.hr-email-send.is-pressed {
  transform: scale(0.98);
  background: #0369a1;
}

.hr-toast {
  position: absolute;
  top: 14px;
  right: 14px;
  left: auto;
  z-index: 60;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  max-width: calc(100% - 28px);
  padding: 10px 14px 10px 10px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #fff;
  color: #0f172a;
  font-size: 0.76rem;
  font-weight: 600;
  box-shadow:
    0 4px 6px rgba(15, 23, 42, 0.04),
    0 12px 28px rgba(15, 23, 42, 0.1);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-8px) scale(0.98);
  transition:
    opacity 0.3s ease,
    transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}

.hr-toast__icon {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  position: relative;
}

.hr-toast__icon::after {
  content: '';
  position: absolute;
  left: 9px;
  top: 7px;
  width: 6px;
  height: 10px;
  border: solid #047857;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.hr-toast__text {
  line-height: 1.3;
  white-space: nowrap;
}

.hr-toast.is-in {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.hr-cursor {
  position: absolute;
  width: 18px;
  height: 18px;
  margin: -2px 0 0 -2px;
  border-radius: 50%;
  border: 2px solid #0f172a;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.25);
  pointer-events: none;
  opacity: 0;
  transition:
    left 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    top 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.15s ease;
  z-index: 50;
}

.hr-cursor.is-on {
  opacity: 1;
}
