/* Hairsalon category v3: interactive hairstyle explorer + live partner browser. */
:root {
  --hair-v3-blue: #1557ff;
  --hair-v3-blue-dark: #0f43cf;
  --hair-v3-navy: #0e1c3c;
  --hair-v3-ink: #101b36;
  --hair-v3-muted: #667085;
  --hair-v3-line: #e6e9f0;
  --hair-v3-rose: #e64f91;
  --hair-v3-shadow: 0 18px 48px rgba(24, 39, 75, .10);
}

.hair-v3-container {
  width: min(calc(100% - 48px), 1440px);
  margin-inline: auto;
}

.hair-v3-hero-wrap {
  overflow: hidden;
  padding: 42px 0 48px;
  background:
    radial-gradient(circle at 10% 18%, #fff1f5 0, transparent 30%),
    radial-gradient(circle at 92% 14%, #f7f3ff 0, transparent 32%),
    linear-gradient(180deg, #fff 0%, #fffafb 100%);
}

.hair-v3-hero {
  display: grid;
  grid-template-columns: minmax(330px, 38fr) minmax(0, 62fr);
  gap: 32px;
  align-items: center;
}

.hair-v3-copy {
  max-width: 500px;
  padding-left: 8px;
}

.hair-v3-eyebrow {
  margin: 0 0 14px;
  color: var(--hair-v3-rose);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: .13em;
  text-transform: uppercase;
}

.hair-v3-copy h1 {
  max-width: 500px;
  margin: 0 0 18px;
  color: var(--hair-v3-navy);
  font-size: clamp(46px, 4vw, 60px);
  font-weight: 800;
  line-height: 1.03;
  letter-spacing: -.055em;
}

.hair-v3-copy h1 span { display: block; color: var(--hair-v3-rose); }

.hair-v3-lead {
  max-width: 460px;
  margin: 0 0 25px;
  color: #3e4a66;
  font-size: 16px;
  line-height: 1.62;
}

.hair-v3-primary {
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 13px;
  padding: 0 24px;
  background: var(--hair-v3-blue);
  box-shadow: 0 12px 24px rgba(21, 87, 255, .21);
  color: #fff;
  font-size: 15px;
  font-weight: 800;
  text-decoration: none;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease;
}

.hair-v3-primary:hover {
  background: var(--hair-v3-blue-dark);
  box-shadow: 0 14px 28px rgba(21, 87, 255, .25);
  transform: translateY(-1px);
}

.hair-v3-primary:focus-visible,
.hair-v3-style-explorer button:focus-visible {
  outline: 3px solid rgba(21, 87, 255, .45);
  outline-offset: 3px;
}

.hair-v3-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.hair-v3-trust span {
  border: 1px solid #eadfe8;
  border-radius: 999px;
  padding: 8px 11px;
  background: rgba(255, 255, 255, .82);
  color: #4b5570;
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}

.hair-v3-style-explorer {
  display: grid;
  min-width: 0;
  grid-template-columns: minmax(0, 1fr) minmax(232px, .48fr);
  grid-template-areas:
    "toolbar tabs"
    "preview picker"
    "status status";
  gap: 12px 14px;
  align-items: start;
  border: 1px solid rgba(221, 225, 235, .94);
  border-radius: 24px;
  padding: 14px;
  background: rgba(255, 255, 255, .88);
  box-shadow: var(--hair-v3-shadow);
  backdrop-filter: blur(8px);
}

.hair-v3-explorer-toolbar { grid-area: toolbar; min-width: 0; padding: 3px 4px 0; }
.hair-v3-explorer-heading strong { display: block; color: var(--hair-v3-navy); font-size: 14px; line-height: 1.25; }
.hair-v3-explorer-heading span { display: block; margin-top: 3px; color: var(--hair-v3-muted); font-size: 11px; }

.hair-v3-gender-tabs {
  grid-area: tabs;
  justify-self: end;
  display: grid;
  width: 190px;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  border: 1px solid var(--hair-v3-line);
  border-radius: 999px;
  padding: 4px;
  background: #f6f7fb;
}

.hair-v3-gender-tab {
  min-height: 36px;
  border: 0;
  border-radius: 999px;
  padding: 0 13px;
  background: transparent;
  color: #5c667d;
  font-size: 12px;
  font-weight: 800;
}

.hair-v3-gender-tab[aria-selected="true"] {
  background: var(--hair-v3-blue);
  box-shadow: 0 5px 12px rgba(21, 87, 255, .20);
  color: #fff;
}

.hair-v3-preview-column { grid-area: preview; min-width: 0; }
.hair-v3-preview-card { position: relative; min-width: 0; aspect-ratio: 1; overflow: hidden; border-radius: 18px; background: #f4efee; isolation: isolate; }
.hair-v3-preview-card::after { content: ""; position: absolute; inset: 0; z-index: 2; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(25, 35, 60, .05); pointer-events: none; }
.hair-v3-main-image { width: 100%; height: 100%; object-fit: cover; object-position: center; transition: opacity .18s ease, transform .3s ease; }
.hair-v3-main-image.is-changing { opacity: .16; transform: scale(1.012); }

.hair-v3-preview-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 3;
  border-radius: 999px;
  padding: 7px 10px;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 7px 18px rgba(20, 31, 57, .12);
  color: var(--hair-v3-navy);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .05em;
  text-transform: uppercase;
  backdrop-filter: blur(8px);
}

.hair-v3-caption { min-width: 0; margin-top: 10px; border: 1px solid var(--hair-v3-line); border-radius: 14px; padding: 13px 15px 12px; background: #fff; box-shadow: 0 8px 20px rgba(24, 39, 75, .06); }
.hair-v3-caption-title { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; }
.hair-v3-style-name { margin: 0; color: var(--hair-v3-navy); font-size: clamp(18px, 1.55vw, 22px); line-height: 1.15; letter-spacing: -.035em; overflow-wrap: anywhere; }
.hair-v3-style-category { flex: 0 0 auto; border-radius: 999px; padding: 5px 8px; background: #eef4ff; color: #1744a0; font-size: 9px; font-weight: 850; letter-spacing: .09em; text-transform: uppercase; }
.hair-v3-style-category[data-category="Perm"] { background: #fff0f6; color: #aa3168; }
.hair-v3-style-description { margin: 7px 0 0; color: #46516a; font-size: 11px; line-height: 1.5; }
.hair-v3-style-note { margin: 4px 0 0; color: #7a8399; font-size: 9px; line-height: 1.45; }

.hair-v3-style-picker { grid-area: picker; min-width: 0; border: 1px solid #e8ebf3; border-radius: 16px; padding: 10px; background: #fbfcff; }
.hair-v3-rail-heading { display: flex; gap: 14px; align-items: baseline; justify-content: space-between; padding: 1px 2px 9px; }
.hair-v3-rail-heading strong { color: var(--hair-v3-navy); font-size: 12px; }
.hair-v3-rail-heading span { color: var(--hair-v3-muted); font-size: 10px; }
.hair-v3-style-rail { display: grid; min-width: 0; max-height: 510px; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: max-content; gap: 6px; align-items: start; overflow-y: auto; padding: 4px 4px 6px; overscroll-behavior: contain; scrollbar-color: #c9d1e3 transparent; scrollbar-width: thin; }
.hair-v3-style-rail::-webkit-scrollbar { width: 6px; height: 6px; }
.hair-v3-style-rail::-webkit-scrollbar-thumb { border-radius: 999px; background: #c9d1e3; }

.hair-v3-style-option { display: grid; width: 100%; min-width: 0; min-height: max-content; grid-template-rows: auto minmax(27px, auto) auto; align-content: start; align-self: start; border: 1px solid transparent; border-radius: 13px; padding: 5px 5px 7px; background: transparent; color: var(--hair-v3-ink); text-align: left; transition: border-color .18s ease, background .18s ease, transform .18s ease; }
.hair-v3-style-option:hover { background: #f7f8fc; transform: translateY(-1px); }
.hair-v3-style-option[aria-pressed="true"] { border-color: #e85892; background: #fff8fb; box-shadow: 0 0 0 3px rgba(232, 88, 146, .14), 0 8px 18px rgba(24, 39, 75, .10); }
.hair-v3-thumb { display: block; width: 100%; aspect-ratio: 1; overflow: hidden; border-radius: 9px; background: #f2eeee; }
.hair-v3-thumb img { width: 100%; height: 100%; object-fit: cover; }
.hair-v3-option-name { display: -webkit-box; width: 100%; min-height: 27px; margin-top: 6px; overflow: hidden; color: var(--hair-v3-navy); font-size: 9px; font-weight: 800; line-height: 1.35; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.hair-v3-option-category { display: block; width: 100%; margin-top: 3px; color: var(--hair-v3-muted); font-size: 8px; font-weight: 700; line-height: 1.3; }
.hair-v3-selection-status { grid-area: status; min-height: 18px; margin: 7px 4px 0; color: #5f6980; font-size: 10px; line-height: 1.4; }
.hair-v3-selection-status strong { color: var(--hair-v3-navy); }
.hair-v3-sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }

/* Live Mapbox + approved advertiser cards. */
.hair-v3-discovery { max-width: 1440px; padding-top: 58px; scroll-margin-top: 88px; }
.hair-v3-discovery-head { margin-bottom: 22px; }
.hair-v3-browser { display: grid; grid-template-columns: minmax(410px, .92fr) minmax(620px, 1.08fr); gap: 22px; align-items: start; }
.hair-v3-map-column { position: sticky; top: 92px; }
.hair-v3-map-shell { position: relative; min-height: 620px; aspect-ratio: 1; overflow: hidden; border: 1px solid var(--hair-v3-line); border-radius: 16px; background: #edf3f7; box-shadow: 0 10px 28px rgba(24, 39, 75, .06); }
.hair-v3-map-shell .partner-mapbox-map { position: absolute; inset: 0; width: 100%; height: 100%; }
.hair-v3-map-count { position: absolute; top: 14px; left: 14px; z-index: 3; border: 1px solid #dfe4ee; border-radius: 12px; padding: 10px 14px; background: rgba(255, 255, 255, .94); box-shadow: 0 6px 18px rgba(33, 46, 75, .1); font-size: 12px; font-weight: 800; backdrop-filter: blur(8px); }
.hair-v3-map-count em { color: var(--hair-v3-rose); font-style: normal; }
.hair-v3-stay { display: grid; gap: 10px; margin-top: 12px; border: 1px solid var(--hair-v3-line); border-radius: 14px; padding: 14px 15px; background: #fff; box-shadow: 0 7px 20px rgba(24, 39, 75, .05); }
.hair-v3-stay-copy strong { display: block; color: #17233d; font-size: 14px; font-weight: 850; line-height: 1.4; }
.hair-v3-stay-field { display: grid; min-width: 0; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.hair-v3-stay-input { width: 100%; min-width: 0; height: 44px; border: 1px solid #dfe4ec; border-radius: 9px; padding: 0 12px; background: #fff; color: #17233d; font-size: 13px; outline: 0; }
.hair-v3-stay-input:focus { border-color: #7c9cff; box-shadow: 0 0 0 3px rgba(21, 87, 255, .1); }
.hair-v3-stay-submit { min-width: 126px; height: 44px; border: 0; border-radius: 9px; padding: 0 15px; background: var(--hair-v3-blue); color: #fff; font-size: 12px; font-weight: 850; white-space: nowrap; }
.hair-v3-stay-submit:disabled { cursor: wait; opacity: .68; }
.hair-v3-stay-status { margin: 0; color: #526078; font-size: 11px; font-weight: 700; line-height: 1.45; }
.hair-v3-stay-status[hidden] { display: none; }
.hair-v3-stay-status.is-error { color: #b42318; }
.hair-v3-stay-status.is-success { color: #146c43; }

.hair-v3-studio-list { min-width: 0; padding-top: 0; }
.hair-v3-sort-row { display: flex; min-height: 32px; align-items: center; justify-content: flex-end; margin-bottom: 8px; }
.hair-v3-sort-row .pm-sort-trigger { min-height: 30px; gap: 6px; padding: 5px 10px; font-size: 11px; }
#mList { display: grid; gap: 12px; }
.pc-studio-card { display: grid; min-width: 0; grid-template-columns: 220px minmax(0, 1fr) 160px; gap: 16px; align-items: center; border: 1px solid var(--hair-v3-line); border-radius: 15px; padding: 10px; background: #fff; box-shadow: 0 7px 20px rgba(24, 39, 75, .05); color: inherit; text-decoration: none; transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease; }
.pc-studio-card:hover, .pc-studio-card:focus-visible { border-color: #aebefa; box-shadow: 0 10px 25px rgba(21, 87, 255, .12); transform: translateY(-1px); }
.pc-studio-photo { height: 148px; overflow: hidden; border-radius: 12px; background: linear-gradient(135deg, #fff0f5, #f1efff); }
.pc-studio-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.pc-studio-photo.is-empty { visibility: hidden; }
.pc-studio-info { min-width: 0; }
.pc-studio-name { display: -webkit-box; overflow: hidden; margin: 0 0 5px; color: var(--hair-v3-ink); font-size: 18px; font-weight: 800; line-height: 1.3; overflow-wrap: anywhere; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.pc-studio-meta { min-height: 17px; margin: 4px 0; color: #5e6880; font-size: 11px; line-height: 1.35; }
.pc-studio-rating { color: var(--hair-v3-blue); font-weight: 800; }
.pc-studio-tags { display: flex; min-height: 24px; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.pc-studio-tag { border-radius: 999px; padding: 5px 8px; font-size: 9px; }
.pc-studio-tag--mint { background: #e9f8f0; }
.pc-studio-tag--pink { background: #fff0f6; }
.pc-studio-tag--lilac { background: #f2efff; }
.pc-studio-side { align-self: stretch; display: flex; min-width: 0; flex-direction: column; justify-content: flex-end; text-align: right; }
.pc-studio-price-label { display: block; color: #69738a; font-size: 11px; }
.pc-studio-price { display: block; overflow: hidden; color: var(--hair-v3-ink); font-size: 17px; font-weight: 850; text-overflow: ellipsis; white-space: nowrap; }
.pc-studio-fx-price { display: block; margin-top: 1px; color: var(--hair-v3-blue); font-size: 10px; font-weight: 750; line-height: 1.2; white-space: nowrap; }
.pc-studio-duration { display: block; margin-top: 1px; color: #69738a; font-size: 11px; }
.pc-studio-cta { display: flex; min-height: 38px; align-items: center; justify-content: center; margin-top: 14px; border: 1px solid #9fb4fc; border-radius: 9px; background: #fff; color: var(--hair-v3-blue); font-size: 11px; font-weight: 800; }
.pc-card-skeleton-slot:empty { display: none; }
.hair-v3-map-pagination { margin-top: 16px; }
.hair-v3-map-pagination[hidden], .vendor-pagination[hidden] { display: none; }
.vendor-pagination { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; justify-content: center; }
.vendor-page-btn { min-width: 34px; height: 34px; border: 1px solid var(--hair-v3-line); border-radius: 9px; background: #fff; color: #43506a; font-size: 12px; font-weight: 800; }
.vendor-page-btn.active { border-color: var(--hair-v3-blue); background: var(--hair-v3-blue); color: #fff; }
.vendor-page-btn:disabled { cursor: default; opacity: .4; }
.hair-v3-list-view { margin-top: 22px; border: 1px solid var(--hair-v3-line); border-radius: 16px; padding: 16px; background: #fff; }
.hair-v3-list-view[hidden] { display: none; }
.hair-v3-region-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 13px; }
.hair-v3-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.hair-v3-empty { padding: 46px 20px; color: #69738a; text-align: center; }
.hair-v3-load-more { display: none; }

@media (max-width: 1160px) {
  .hair-v3-container { width: min(calc(100% - 28px), 1080px); }
  .hair-v3-hero { grid-template-columns: minmax(300px, .82fr) minmax(0, 1.18fr); }
  .hair-v3-copy h1 { font-size: clamp(42px, 5vw, 58px); }
  .hair-v3-style-explorer { grid-template-columns: minmax(0, 1fr) minmax(210px, .46fr); }
}

@media (max-width: 1160px) and (min-width: 761px) {
  .hair-v3-style-rail { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hair-v3-browser { grid-template-columns: minmax(360px, .9fr) minmax(0, 1.1fr); }
  .pc-studio-card { grid-template-columns: 170px minmax(0, 1fr); }
  .pc-studio-side { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr) 150px; align-items: end; gap: 12px; text-align: left; }
  .pc-studio-cta { margin-top: 0; }
}

@media (max-width: 940px) {
  .hair-v3-hero { grid-template-columns: 1fr; gap: 30px; }
  .hair-v3-copy { max-width: 720px; justify-self: center; padding-left: 0; text-align: center; }
  .hair-v3-copy h1, .hair-v3-lead { margin-inline: auto; }
  .hair-v3-trust { justify-content: center; }
  .hair-v3-browser { grid-template-columns: 1fr; }
  .hair-v3-map-column { position: static; }
}

@media (max-width: 760px) {
  .hair-v3-container { width: calc(100% - 24px); }
  .hair-v3-hero-wrap { padding: 24px 0 30px; }
  .hair-v3-hero { gap: 24px; }
  .hair-v3-eyebrow { margin-bottom: 10px; font-size: 11px; }
  .hair-v3-copy h1 { margin-bottom: 16px; font-size: clamp(30px, 8.2vw, 38px); line-height: 1.08; }
  .hair-v3-lead { margin-bottom: 20px; font-size: 13px; }
  .hair-v3-primary { width: min(100%, 290px); }
  .hair-v3-trust { gap: 7px; margin-top: 20px; }
  .hair-v3-trust span { padding: 7px 9px; font-size: 10px; }
  .hair-v3-style-explorer { grid-template-columns: 1fr; grid-template-areas: "toolbar" "tabs" "picker" "preview" "status"; gap: 10px; border-radius: 20px; padding: 10px; }
  .hair-v3-explorer-toolbar { padding: 3px 2px 0; text-align: center; }
  .hair-v3-gender-tabs { width: 100%; justify-self: stretch; }
  .hair-v3-gender-tab { min-height: 40px; }
  .hair-v3-style-picker { border-radius: 14px; padding: 8px; }
  .hair-v3-style-rail { display: flex; min-height: max-content; max-height: none; align-items: flex-start; gap: 8px; overflow-x: auto; overflow-y: hidden; padding: 4px 4px 7px; scroll-snap-type: x proximity; }
  .hair-v3-style-option { flex: 0 0 116px; width: auto; scroll-snap-align: start; }
  .hair-v3-preview-card { border-radius: 15px; }
  .hair-v3-caption { margin-top: 8px; padding: 12px 13px 11px; }
  .hair-v3-style-name { font-size: 21px; }
  .hair-v3-selection-status { margin-top: 5px; text-align: center; }
  .hair-v3-discovery { padding: 44px 12px 52px; }
  .hair-v3-map-shell { min-height: 0; aspect-ratio: 16 / 9; border-radius: 15px; }
  .hair-v3-map-count { top: 10px; left: 10px; padding: 8px 10px; }
  .hair-v3-stay-field { grid-template-columns: 1fr; }
  .hair-v3-stay-submit { width: 100%; }
  .pc-studio-card { grid-template-columns: 120px minmax(0, 1fr); gap: 12px; padding: 8px; }
  .pc-studio-photo { height: 120px; }
  .pc-studio-name { font-size: 15px; }
  .pc-studio-side { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; text-align: left; }
  .pc-studio-cta { min-height: 42px; margin-top: 0; }
  .hair-v3-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}

@media (max-width: 370px) {
  .hair-v3-container { width: calc(100% - 18px); }
  .hair-v3-copy h1 { font-size: 29px; }
  .hair-v3-style-option { flex-basis: 96px; }
  .pc-studio-card { grid-template-columns: 92px minmax(0, 1fr); }
  .pc-studio-photo { height: 92px; }
  .pc-studio-price { font-size: 13px; }
}

/* Six advertiser cards fit beside the desktop map; mobile keeps the roomier
   five-card layout below 760px. */
@media (min-width: 761px) {
  #mList { gap: 8px; }
  .pc-studio-card { min-height: 90px; grid-template-columns: 108px minmax(0, 1fr) 104px; gap: 8px; border-radius: 12px; padding: 6px; }
  .pc-studio-photo { height: 78px; border-radius: 9px; }
  .pc-studio-name { display: block; overflow: hidden; margin-bottom: 2px; font-size: 13px; line-height: 1.22; text-overflow: ellipsis; white-space: nowrap; }
  .pc-studio-meta { min-height: 0; overflow: hidden; margin: 1px 0; font-size: 8.5px; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
  .pc-studio-area, .pc-studio-languages { display: block; -webkit-line-clamp: unset; }
  .pc-studio-tags { min-height: 0; flex-wrap: nowrap; gap: 3px; overflow: hidden; margin-top: 3px; }
  .pc-studio-tag { flex: 0 1 auto; padding: 2px 4px; font-size: 7px; }
  .pc-studio-side { grid-column: auto; align-self: stretch; display: flex; min-width: 0; flex-direction: column; justify-content: flex-end; gap: 0; text-align: right; }
  .pc-studio-price-label, .pc-studio-duration { font-size: 8px; }
  .pc-studio-price { font-size: 12.5px; }
  .pc-studio-fx-price { font-size: 7.5px; }
  .pc-studio-cta { min-height: 26px; margin-top: 1px; border-radius: 6px; font-size: 8.5px; }
  .hair-v3-map-pagination { margin-top: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .hair-v3-hero-wrap *,
  .hair-v3-discovery * { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
