/* Final surfaces and control states shared by discovery, booking, and the workspaces. */
:root {
  --frame: #181818;
  --frame-hover: #282828;
  --frame-edge: #393939;
  --reading-muted: #bdbdbd;
  --action-border: #505050;
  --panel-radius: 12px;
  --control-radius: 8px;
}

body .appbar { border-color: #303030; }
.public-nav a {
  font-weight: 560;
  padding-inline: 4px;
}
.public-nav a[aria-current=page] { font-weight: 720; }
.public-nav a[aria-current=page]::after { inset-inline: 3px; }
body .bar-user, body .bar-icon { border-radius: var(--control-radius); }

.night-hero {
  grid-template-columns: minmax(0, .98fr) minmax(0, 1.02fr);
  min-height: clamp(324px, 37vw, 486px);
  border: 1px solid #393939;
  border-radius: 15px;
  background: #f2efe9;
}
.hero-copy { padding: clamp(24px, 4.8vw, 66px); }
.night-hero .hero-copy h1 {
  max-inline-size: 11ch;
  font-size: clamp(40px, 5.95vw, 79px);
  line-height: 1.23;
  text-wrap: balance;
  letter-spacing: -.052em;
}
.hero-copy > p {
  max-inline-size: 34ch;
  margin-block: 16px 23px;
  color: #414141;
  font-size: clamp(14px, 1.35vw, 18px);
  line-height: 1.75;
}
.hero-actions { gap: 8px 18px; }
.night-hero .hero-actions .primary { min-height: 48px; padding-inline: 16px; border-radius: 8px; }
.hero-textlink { color: #303030; }
.hero-textlink:hover { color: #111; }
.hero-network img { object-position: 50% 45%; }

.finder-title { gap: 12px; }
.finder-title :is(h1, h2) { flex: 1; scroll-margin-block-start: 18px; }
.finder-title .finder-locate {
  flex: none;
  min-height: 44px;
  padding-inline: 12px;
  border-color: var(--action-border);
  font-weight: 650;
}
.finder-locate .icon { width: 17px; height: 17px; }
.finder-bar .finder-search,
.finder-bar .area-picker select { border-color: var(--frame-edge); }
.finder-bar .area-picker select { width: 100%; min-width: 122px; }
.finder-bar .area-picker select:focus-visible { outline-offset: 2px; }
.finder-filters { scrollbar-width: thin; scrollbar-color: #565656 transparent; }
.finder-filters .filter-pill { min-height: 44px; }
.finder-filters .filter-pill:focus-visible { outline-offset: -3px; }
.finder-filters .filter-pill:not([aria-pressed=true]):hover { background: #202020; }
.finder .map-panel, .finder .results-panel { border-radius: var(--panel-radius); }
.finder .results-panel { padding: clamp(13px, 2vw, 21px); }
.results-head { gap: 10px; }
.results-head h2 { font-size: clamp(18px, 2vw, 22px); }
#resultCount {
  flex: none;
  border: 1px solid var(--frame-edge);
  border-radius: 5px;
  padding: 3px 8px;
  color: var(--reading-muted);
  font-size: 12px;
}
.finder .salon-result { gap: 9px; padding: 10px 2px; }
.finder .pick-salon { min-height: 48px; }
.finder .pick-salon > span { min-width: 0; overflow-wrap: anywhere; }
.finder .result-open { display: inline-grid; place-items: center; min-height: 44px; padding-inline: 7px; }
.finder .result-open:hover { text-decoration: underline; text-underline-offset: 3px; }
.finder .selected-salon .btn { min-height: 44px; }
.finder #salonResults { scrollbar-gutter: stable; }
.finder .quick-title { margin-top: clamp(24px, 5vw, 58px); }

#main :is(.pagehead, .work-title) { gap: 13px; }
#main :is(.pagehead, .work-title) h1 { text-wrap: balance; }
#main :is(.pagehead, .work-title) :is(p, .eyeline) { color: var(--reading-muted); }
body #main :is(.box, .formbox, .viz-card, .authbox, .card, .skin-card) {
  border-radius: var(--panel-radius);
  border-color: var(--frame-edge);
}
#main :is(.box, .formbox, .viz-card) :is(h2, h3) { text-wrap: pretty; }
body #main .field :is(input:not([type=checkbox]):not([type=radio]):not([type=file]), select, textarea) {
  border-radius: var(--control-radius);
}
#main .field :is(input, textarea)::placeholder { color: #ababab; }
#main .field :is(input:not([type=file]), select, textarea)[aria-invalid=true] { border-color: #a0a0a0; }
#main .field select { min-width: 0; text-overflow: ellipsis; }
#main :is(.btn, .quiet-btn, .slot, .tab), .workspace-exit { touch-action: manipulation; }
#main :is(.btn, .quiet-btn) { border-radius: var(--control-radius); }
#main .btn:not(.primary, .on):hover { background: var(--frame-hover); }
#main .btn:disabled { cursor: default; }
#main .empty { line-height: 1.85; }
#main .note, #main .error { border-radius: var(--control-radius); }
#main .textlink:hover { text-decoration: underline; text-underline-offset: 3px; }
#main :is(.facts, .metrics, .book-table, .tariff-row, .jgrid, .stock-quantity) { font-variant-numeric: tabular-nums; }

.authgrid { overflow: hidden; }
body #main .authbox { padding: clamp(20px, 3.5vw, 46px); }
.authbox h1 { font-size: clamp(25px, 3.5vw, 45px); letter-spacing: -.05em; }
.authbox #auth { gap: 12px; }
.authbox #auth .primary { min-height: 46px; }
.authbox .formactions a { min-height: 44px; display: inline-flex; align-items: center; }
#main .booking-layout { align-items: start; }
.booking-layout > aside .facts > div { align-items: baseline; gap: 8px; }
.booking-layout > aside .facts > div:last-child { font-weight: 720; }
.booking-week button { min-height: 53px; }
.booking-week button:not([aria-pressed=true]):hover { border-color: #a3a3a3; }
#main .booking-layout .slot { min-height: 44px; }
#main .booking-layout .facts > div { flex-wrap: wrap; }

.lookbook .catalog-cover { border-radius: var(--panel-radius); }
.catalog-tools.catalog-search-tools {
  border-radius: var(--panel-radius);
  background: var(--frame);
  padding: clamp(13px, 2vw, 22px);
}
.catalog-traits { padding-block-start: 8px; }
.catalog-traits summary { padding-inline: 3px; overflow-wrap: anywhere; }
.catalog-traits summary:hover { color: #fff; }
.lookbook .groupbar { scrollbar-width: thin; scrollbar-color: #565656 transparent; }
.lookbook .groupbar .chip:focus-visible { outline-offset: -3px; }
body #main .look-card:nth-child(n) { border-radius: 8px; }
#main .look-card:focus-visible { outline-offset: 2px; }
.look-card .look-caption { padding: 11px 12px 14px; border-color: #3b3b3b; }
.look-card .look-caption h3 { line-height: 1.45; }
.look-detail .portrait-panel { border-radius: 10px; }
.skin-directory .finder-search { border-radius: 8px; min-height: 46px; }
.skin-card > div { padding-block: 13px 15px; }
.explore-head { gap: 13px; }
.explore-choice { border-color: var(--action-border); border-radius: 8px; }
.explore-choice select { min-height: 46px; }
.explore-grid { border-radius: 8px; isolation: isolate; }
.explore-tile:focus-visible { outline-width: 2px; outline-offset: -3px; }
.explore-foot { min-height: 24px; }
#main .social-identity {
  max-width: none;
  padding: clamp(18px, 3.8vw, 46px);
  margin: clamp(19px, 3vw, 36px) 0 15px;
  border: 1px solid var(--frame-edge);
  border-radius: var(--panel-radius);
  background: var(--frame);
}
.social-identity small { color: var(--reading-muted); }
#main .social-identity .formactions { gap: 8px; }
#main .social-tabs { justify-content: flex-start; overflow-x: auto; scrollbar-width: thin; }
#main .social-tab { flex: none; min-height: 44px; }
#main .social-tab:focus-visible { outline-offset: -3px; }
#main .social-identity .social-avatar { outline-color: #898989; }
body #main .identity-card { border-radius: var(--panel-radius); }
.identity-card .identity-copy p { color: #d4d4d4; }
.identity-actions { gap: 8px; }
.identity-sample > h2 { margin-block-end: 12px; }

.dashdark .workspace-location { color: #bdbdbd; }
.dashdark .workspace-location strong { font-weight: 720; }
.dashdark .panel-group > small { color: #b7b7b7; }
.dashdark .panel-group a { transition: background-color .14s ease, color .14s ease; }
.dashdark #main .work-title { align-items: flex-end; }
.dashdark #main .work-title h1 { font-size: clamp(29px, 3.3vw, 46px); letter-spacing: -.038em; }
.dashdark #main .work-title .eyeline { margin-bottom: 5px; }
.dashdark #main .metrics { border-radius: var(--panel-radius); }
.dashdark #main .metrics > div { min-height: 92px; align-content: center; }
.dashdark #main .metrics > div small { min-width: 0; }
.dashdark #main :is(.work-heading, .booking-list-head) { align-items: baseline; }
.dashdark #main :is(.desk-tabs, .booking-tabs) button {
  min-height: 44px;
  padding-inline: 12px;
}
.dashdark #main :is(.booking-ticket, .booking-empty-next, .schedule-pulse) { border-radius: var(--panel-radius); }
.dashdark #main .booking-ticket.next-ticket { border-inline-start-width: 3px; }
#main .book-table { overscroll-behavior-inline: contain; scrollbar-width: thin; }
#main .book-table :is(th, td) { padding-block: 12px; }
#main :is(.desk-entry, .crm-row, .stock-row, .team-member) { padding-block: 14px; }
#main :is(.section-heading, .desk-section-title) { margin-block-end: 12px; }
#main .jgrid { gap: 4px; }
#main .jgrid button { min-height: 42px; border-radius: 6px; }
#main .jgrid button:not(:disabled, [aria-pressed=true]):hover { border-color: #8f8f8f; background: #333; }
#main .month-tools .month-label { font-weight: 720; }
#main .tariff-row:focus-within { border-color: #777; }
#main :is(.followup-total, .followup-entry, .message-offer) { border-radius: 8px; }
#main :is(.crm-row, .stock-row, .tariff-row) :where(small) { color: var(--reading-muted); }
dialog:not(.workspace-drawer) { max-height: calc(100dvh - 24px); scrollbar-width: thin; }
dialog :is(.formactions, footer) { row-gap: 8px; }

@media (min-width: 950px) {
  .finder-split { grid-template-columns: minmax(0, 1.55fr) minmax(270px, 1fr); }
  .booking-layout > aside { position: sticky; inset-block-start: 20px; }
  .dashdark .panel-group a { min-height: 39px; }
}
@media (max-width: 820px) {
  .finder-title .finder-locate { padding-inline: 9px; }
  #main .social-identity { gap: 15px; }
}
@media (max-width: 740px) {
  .night-hero { border-radius: 12px; }
  .hero-copy { padding: 20px; }
  .night-hero .hero-copy h1 { font-size: clamp(33px, 6.8vw, 49px); }
  .hero-copy > p { margin-block: 10px 15px; }
  .finder-title :is(h1, h2) { font-size: clamp(21px, 6.1vw, 30px); }
  .finder-title .finder-locate { font-size: 12px; }
  .finder-bar { display: grid; grid-template-columns: minmax(0, 1fr) minmax(112px, .48fr); align-items: stretch; gap: 7px; }
  .finder-bar .area-picker { max-width: none; }
  .finder-bar .area-picker select { min-width: 0; }
  #main .finder-search input { font-size: 16px; }
  .finder .selected-salon { gap: 8px; }
  .finder .selected-salon .btn { font-size: 12px; padding-inline: 8px; }
  .explore-grid { border-radius: 0; }
  .dashdark #main .work-title h1 { font-size: clamp(25px, 7vw, 35px); }
  .dashdark #main .metrics > div { min-height: 72px; }
  #main .stock-row .contact-actions { justify-content: flex-start; }
}
@media (max-width: 510px) {
  .night-hero { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .hero-network { grid-row: auto; }
  .hero-network img { position: static; height: auto; }
  .hero-copy { padding: 17px 16px 15px; }
  .night-hero .hero-copy h1 { max-inline-size: none; font-size: clamp(27px, 8.1vw, 40px); text-wrap: wrap; }
  .hero-copy > p { font-size: 13px; margin-block: 7px 12px; }
  .hero-actions { gap: 6px 14px; }
  .night-hero .hero-actions :is(.btn, .hero-textlink) { font-size: 12px; }
  .finder-bar .finder-search { padding-inline: 8px; }
  .finder-bar .finder-search .icon { width: 16px; height: 16px; }
  .look-card .look-caption { padding: 10px 8px 12px; }
  #main .social-identity { padding: 14px; align-items: flex-start; }
  #main .social-identity .social-avatar { width: 62px; }
  .social-identity p { font-size: 13px; }
  #main .identity-editor { gap: 15px; }
  #main .jgrid button { min-height: 37px; }
  .dashdark #main .desk-tabs button { padding-inline: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .dashdark .panel-group a { transition: none; }
}
/* Separate amounts from their units and keep account headers compact. */
.night-hero .hero-copy h1 { max-inline-size: none; }
.night-hero .hero-copy h1 > span { display: inline-block; }
body #main .identity-card,
body[data-screen=preferences] #main .identity-card,
body[data-screen=account] #main .identity-card {
  display: block;
  padding: 0;
  border: 1px solid var(--frame-edge);
  border-radius: var(--panel-radius);
  background-color: var(--frame);
}
#main .identity-cover { height: clamp(70px, 9vw, 114px); }
#main .identity-cover.pattern-plain {
  background: linear-gradient(136deg, #222 25%, #383838 100%);
}
#main .identity-card .identity-actions { padding-block-end: 17px; }
.dashdark #main .metric-money { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 6px; }
.dashdark #main .metric-money bdi { min-width: 0; overflow-wrap: anywhere; }
.dashdark #main .metric-money > small { display: inline; color: var(--reading-muted); font-size: .53em; }
.dashdark[data-screen=barber] #main .schedule-pulse { margin-top: 16px; }
@media(min-width:741px) {
  .night-hero .hero-copy h1 > span { display: block; }
}
@media(max-width:740px) {
  .dashdark[data-screen=barber] #main .metrics { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .dashdark[data-screen=barber] #main .metrics > div { padding: 10px 7px; }
  .dashdark[data-screen=barber] #main .metrics > div > small { font-size: 11px; }
  .dashdark[data-screen=barber] #main .metrics > div > small .icon { display: none; }
}
