/* Utopia Hire FDE Talent Portal — Brand CI locked (tokens.css + system.css + chrome.css)
   Sleek editorial portal: instant search, Intermediate/Expert filter, mobile swipe or scroll,
   ultra-realistic Malaysian graduate portraits, pop-out profile sheet, direct WhatsApp connect. */

.hf-hero {
  position: relative;
  padding: clamp(90px, 8.5vw, 112px) 0 clamp(20px, 2.4vw, 28px);
  overflow: hidden;
  background: var(--linen);
}
.hf-hero__in {
  position: relative;
  z-index: 2;
  max-width: 820px;
}
.hf-hero__title {
  font-family: var(--f-display);
  font-size: clamp(32px, 4.2vw, 52px);
  font-weight: 700;
  line-height: 1.06;
  letter-spacing: -.03em;
  color: var(--ink);
  margin: 0;
}
.hf-hero__title em {
  font-style: normal;
  color: var(--blue-deep);
}
.hf-hero__sub {
  margin: 12px 0 0;
  font-size: clamp(15px, 1.25vw, 17.5px);
  line-height: 1.5;
  color: var(--ink-2);
  max-width: 660px;
}
.hf-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--hair);
  font-size: 13.5px;
  font-weight: 500;
  color: var(--ink-2);
}
.hf-hero__meta span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.hf-check-ic {
  width: 17px;
  height: 17px;
  color: var(--ok);
  flex: none;
  display: block;
}

/* Sticky Search & Filter Toolbar */
.hf-bar-wrap {
  position: sticky;
  top: 74px;
  z-index: 30;
  padding: 12px 0;
  background: rgba(248, 247, 244, .92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
}
.hf-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.hf-search {
  position: relative;
  flex: 1 1 260px;
  min-width: 220px;
}
.hf-search__ic {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: var(--mute);
  pointer-events: none;
}
.hf-search__input {
  width: 100%;
  height: 46px;
  padding: 0 40px 0 42px;
  border-radius: var(--r-btn);
  border: 1px solid rgba(23, 24, 28, .15);
  background: var(--surface);
  color: var(--ink);
  font: 500 15px/1 var(--f-body);
  outline: none;
  transition: border-color 150ms var(--ease), box-shadow 150ms var(--ease);
}
.hf-search__input:focus {
  border-color: var(--blue-deep);
  box-shadow: 0 0 0 3px rgba(39, 116, 174, .16);
}
.hf-search__clear {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
}
.hf-search__clear.is-vis { display: inline-flex; }

/* Experience Level Segmented Control */
.hf-levels {
  display: inline-flex;
  padding: 4px;
  border-radius: var(--r-btn);
  background: var(--paper);
  border: 1px solid var(--hair);
  gap: 4px;
}
.hf-lvl {
  height: 38px;
  padding: 0 14px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--ink-2);
  font: 600 14px/1 var(--f-body);
  cursor: pointer;
  transition: background 150ms var(--ease), color 150ms var(--ease), transform 120ms ease-out;
  white-space: nowrap;
}
.hf-lvl:active { transform: scale(.97); }
.hf-lvl.is-active {
  background: var(--ink);
  background-image: var(--sheen);
  color: var(--white);
}
.hf-lvl__cnt {
  margin-left: 5px;
  font-size: 12px;
  opacity: .78;
}

/* Mobile View Switcher (Swipe vs Scroll) */
.hf-view-toggle {
  display: none;
  padding: 4px;
  border-radius: var(--r-btn);
  background: var(--paper);
  border: 1px solid var(--hair);
  gap: 4px;
}
.hf-vbtn {
  height: 36px;
  padding: 0 12px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--ink-2);
  font: 600 13px/1 var(--f-body);
  cursor: pointer;
}
.hf-vbtn.is-active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 1px 3px rgba(11, 11, 13, .10);
}

/* University Quick-Filter Rail */
.hf-unis {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 2px;
  -webkit-overflow-scrolling: touch;
}
.hf-unis::-webkit-scrollbar { display: none; }
.hf-uni {
  flex: none;
  height: 34px;
  padding: 0 13px;
  border-radius: 999px;
  border: 1px solid var(--hair);
  background: var(--surface);
  color: var(--ink-2);
  font: 500 13.5px/1 var(--f-body);
  cursor: pointer;
  transition: background 150ms var(--ease), color 150ms var(--ease), border-color 150ms var(--ease);
}
.hf-uni.is-active {
  background: var(--blue-wash);
  border-color: var(--blue);
  color: var(--blue-darker);
  font-weight: 600;
}

/* Portal Grid & Cards */
.hf-portal {
  padding: clamp(20px, 2.2vw, 28px) 0 clamp(60px, 6.5vw, 88px);
  background: var(--linen);
}
.hf-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
  font-size: 14px;
  color: var(--mute);
}
.hf-swipe-hint {
  display: none;
  font-size: 13px;
  font-weight: 600;
  color: var(--blue-deep);
}

.hf-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}
@media (max-width: 1120px) {
  .hf-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 820px) {
  .hf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.hf-card {
  background: var(--surface);
  border: 1px solid var(--hair);
  border-radius: var(--r-card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow);
  transition: transform 200ms var(--ease), box-shadow 200ms var(--ease), border-color 200ms var(--ease);
  cursor: pointer;
}
.hf-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lift);
  border-color: rgba(39, 116, 174, .34);
}
.hf-card:active { transform: scale(.985); }

.hf-card__media {
  position: relative;
  aspect-ratio: 4 / 4.2;
  background: var(--paper);
  overflow: hidden;
}
.hf-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 16%;
  display: block;
  transition: transform 320ms var(--ease);
}
.hf-card:hover .hf-card__media img { transform: scale(1.03); }

.hf-badge {
  position: absolute;
  left: 10px;
  bottom: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(253, 252, 250, .95);
  color: var(--ink);
  font: 600 12px/1 var(--f-body);
  box-shadow: 0 2px 8px rgba(11, 11, 13, .14);
}
.hf-badge svg { width: 15px; height: 15px; color: var(--ok); flex: none; }

.hf-lvl-chip {
  position: absolute;
  right: 10px;
  top: 10px;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(23, 24, 28, .76);
  color: var(--white);
  font: 600 11.5px/1 var(--f-body);
  backdrop-filter: blur(6px);
}

.hf-card__body {
  padding: 16px 16px 14px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.hf-card__name {
  font-family: var(--f-display);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--ink);
  margin: 0;
}
.hf-card__uni {
  margin: 4px 0 0;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--blue-deep);
}
.hf-card__desc {
  margin: 10px 0 0;
  font-size: 14px;
  line-height: 1.48;
  color: var(--ink-2);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.hf-card__actions {
  margin-top: auto;
  padding-top: 14px;
  display: flex;
  gap: 8px;
}
.hf-card__view {
  flex: 0 0 auto;
  height: 40px;
  padding: 0 12px;
  border-radius: 9px;
  border: 1px solid var(--hair);
  background: var(--paper);
  color: var(--ink);
  font: 600 13.5px/1 var(--f-body);
  cursor: pointer;
}
.hf-card__wa {
  flex: 1;
  height: 40px;
  padding: 0 12px;
  border-radius: 9px;
  background: var(--wa-grad);
  color: var(--wa-ink);
  font: 600 13.5px/1 var(--f-body);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  white-space: nowrap;
}
.hf-card__wa svg { width: 16px; height: 16px; flex: none; }

/* Mobile Swipe Rail Mode (< 761px) */
.hf-dots {
  display: none;
  justify-content: center;
  gap: 7px;
  margin-top: 16px;
}
.hf-dot {
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: rgba(23, 24, 28, .22);
  border: 0;
  padding: 0;
  transition: width 180ms var(--ease), background 180ms var(--ease);
}
.hf-dot.is-active {
  width: 22px;
  background: var(--blue-deep);
}

@media (max-width: 760px) {
  .hf-bar-wrap { position: static; }
  .hf-bar { gap: 8px; justify-content: space-between; }
  .hf-search { flex: 1 1 100%; }
  .hf-lvl { height: 34px; padding: 0 10px; font-size: 13px; }
  .hf-vbtn { height: 32px; padding: 0 10px; font-size: 12.5px; }
  .hf-view-toggle { display: inline-flex; }
  .hf-grid { grid-template-columns: 1fr; gap: 16px; }
  .hf-grid.is-swipe {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 14px;
    padding: 4px 2px 10px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .hf-grid.is-swipe::-webkit-scrollbar { display: none; }
  .hf-grid.is-swipe .hf-card {
    flex: 0 0 84vw;
    max-width: 340px;
    scroll-snap-align: center;
  }
  .hf-grid.is-swipe ~ .hf-dots { display: flex; }
  .hf-swipe-hint.is-on { display: inline; }
}

/* Empty State (e.g. Expert filter or no search matches) */
.hf-empty {
  background: var(--surface);
  border: 1px solid var(--hair);
  border-radius: var(--r-lg);
  padding: clamp(28px, 4vw, 48px) 24px;
  text-align: center;
  max-width: 620px;
  margin: 12px auto 0;
}
.hf-empty h3 {
  font-family: var(--f-display);
  font-size: 22px;
  margin: 0 0 10px;
  color: var(--ink);
}
.hf-empty p {
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-2);
  margin: 0 0 20px;
}
.hf-empty__acts {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

/* Pop-Out Detail Modal (Desktop centered dialog, Mobile clean bottom sheet) */
.hf-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(11, 11, 13, .56);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms var(--ease);
}
.hf-modal.is-open {
  opacity: 1;
  pointer-events: auto;
}
.hf-dialog {
  position: relative;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  background: var(--surface);
  border-radius: var(--r-lg);
  box-shadow: 0 24px 64px rgba(11, 11, 13, .28);
  transform: translateY(16px) scale(.97);
  transition: transform 220ms var(--ease);
}
.hf-modal.is-open .hf-dialog {
  transform: translateY(0) scale(1);
}
.hf-dialog__close {
  position: absolute;
  right: 14px;
  top: 14px;
  z-index: 5;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 0;
  background: rgba(253, 252, 250, .92);
  color: var(--ink);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(11, 11, 13, .16);
}
.hf-dialog__top {
  display: grid;
  grid-template-columns: 164px 1fr;
  gap: 20px;
  padding: 24px 24px 18px;
  align-items: center;
  border-bottom: 1px solid var(--hair);
}
.hf-dialog__pic {
  width: 164px;
  height: 184px;
  border-radius: 14px;
  object-fit: cover;
  object-position: center 16%;
  display: block;
  background: var(--paper);
}
.hf-dialog__name {
  font-family: var(--f-display);
  font-size: 24px;
  font-weight: 700;
  line-height: 1.15;
  margin: 0;
  color: var(--ink);
  padding-right: 32px;
}
.hf-dialog__uni {
  margin: 6px 0 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--blue-deep);
}
.hf-dialog__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.hf-cert-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 11px;
  border-radius: 999px;
  background: var(--ok-wash);
  color: #0E623B;
  font: 600 13px/1 var(--f-body);
}
.hf-cert-pill svg { width: 16px; height: 16px; color: var(--ok); flex: none; }
.hf-exp-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 11px;
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink-2);
  font: 600 13px/1 var(--f-body);
}
.hf-dialog__body {
  padding: 20px 24px 24px;
}
.hf-dialog__desc {
  font-size: 15.5px;
  line-height: 1.62;
  color: var(--ink-2);
  margin: 0 0 18px;
}
.hf-dialog__list {
  list-style: none;
  padding: 0;
  margin: 0 0 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.hf-dialog__list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14.5px;
  line-height: 1.45;
  color: var(--ink);
}
.hf-dialog__list svg { width: 18px; height: 18px; color: var(--ok); flex: none; margin-top: 2px; }
.hf-dialog__cta {
  width: 100%;
  height: 50px;
  border-radius: var(--r-btn);
  background: var(--wa-grad);
  color: var(--wa-ink);
  font: 700 15.5px/1 var(--f-body);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 8px 24px rgba(37, 211, 102, .28);
}
.hf-dialog__cta svg { width: 20px; height: 20px; }

@media (max-width: 600px) {
  .hf-modal { align-items: flex-end; padding: 0; }
  .hf-dialog { border-radius: 20px 20px 0 0; max-height: 88vh; }
  .hf-dialog__top { grid-template-columns: 100px 1fr; gap: 14px; padding: 20px 54px 16px 18px; }
  .hf-dialog__pic { width: 100px; height: 114px; }
  .hf-dialog__name { font-size: 19px; padding-right: 0; }
  .hf-dialog__uni { font-size: 13.5px; }
  .hf-dialog__body { padding: 16px 18px 24px; }
}

/* Bottom Employer CTA Strip */
.hf-close {
  padding: clamp(56px, 6vw, 84px) 0;
  background: var(--graphite);
  background-image: var(--sheen);
  color: var(--on-dark);
}
.hf-close__in {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.hf-close h2 {
  font-family: var(--f-display);
  font-size: clamp(26px, 3.2vw, 40px);
  line-height: 1.12;
  margin: 0;
  color: var(--white);
}
.hf-close p {
  margin: 10px 0 0;
  font-size: 16px;
  color: var(--on-dark-2);
  max-width: 560px;
}

@media (prefers-reduced-motion: reduce) {
  .hf-card, .hf-card__media img, .hf-modal, .hf-dialog, .hf-lvl, .hf-dot {
    transition: none !important;
  }
}
