/* Public site: homepage, booking flow, appointment page. Mobile first. */

.wrap {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.wrap--narrow {
  max-width: 760px;
}
.wrap--flow {
  max-width: 560px;
}
@media (min-width: 700px) {
  :root {
    --gutter: 32px;
  }
}

.skip {
  position: absolute;
  inset-inline-start: 8px;
  top: -60px;
  z-index: 50;
  background: var(--paper);
  color: var(--ink);
  padding: 10px 14px;
}
.skip:focus {
  top: 8px;
}

/* ---------------------------------------------------------------- header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--black);
  color: var(--porcelain);
  border-bottom: 1px solid var(--charcoal-2);
}
.site-header__inner {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 60px;
}
.site-nav {
  display: none;
  gap: 28px;
  margin-inline-start: auto;
  font-size: 0.9375rem;
}
.site-nav a {
  text-decoration: none;
  color: var(--muted-dark);
  padding-block: 8px;
}
.site-nav a:hover {
  color: var(--porcelain);
}
.site-header__end {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-inline-start: auto;
}
.site-nav + .site-header__end {
  margin-inline-start: 0;
}
.lang-switch {
  color: var(--porcelain);
  text-decoration: none;
  font-size: 0.9375rem;
  padding: 10px 4px;
}
.lang-switch:hover {
  text-decoration: underline;
  text-underline-offset: 4px;
}
.lang-switch[lang='ar'] {
  font-family: var(--font-arabic);
}
.lang-switch[lang='en'] {
  font-family: 'Plex', sans-serif;
}
@media (min-width: 860px) {
  .site-nav {
    display: flex;
  }
}

/* ---------------------------------------------------------------- hero */

.hero {
  position: relative;
  isolation: isolate;
  background: var(--porcelain);
  color: var(--ink);
  padding-block: 28px 36px;
  overflow: hidden;
}
/* Keffiyeh fishnet behind the wordmark: black thread on off-white, like the scarf itself.
   It fades out before the smaller text so the introduction and buttons stay easy to read. */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--keffiyeh) repeat center top;
  opacity: 0.2;
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 34%, transparent 64%);
  mask-image: linear-gradient(to bottom, #000 0%, #000 34%, transparent 64%);
}
@media (min-width: 900px) {
  .hero::before {
    -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 50%, transparent 92%);
    mask-image: linear-gradient(to bottom, #000 0%, #000 50%, transparent 92%);
  }
}
.hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 36px;
}
.hero__mark {
  margin: 0;
  font-family: var(--font-display);
  font-stretch: 125%;
  font-weight: 800;
  /* Sized so "CUTZ" (3.55em wide at this width/weight) spans the column exactly. */
  font-size: min(calc((100vw - 2 * var(--gutter)) / 3.6), 11rem);
  line-height: 0.82;
  letter-spacing: -0.01em;
  text-align: left;
}
.hero__mark span {
  display: block;
}
[dir='rtl'] .hero__mark {
  /* The wordmark stays Latin and left-set; the text block around it is right-aligned. */
  text-align: right;
}
.hero__trade {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 18px 0 0;
  font-family: var(--font-arabic);
  font-weight: 600;
  font-size: 1.75rem;
  line-height: 1;
  color: var(--brass-ink);
}
.hero__rule {
  width: calc(var(--tatreez-rule-w) * 4);
  height: var(--tatreez-rule-h);
  background: var(--tatreez-rule-ink) repeat-x left center;
}
[dir='rtl'] .hero__rule {
  background-position: right center;
}
/* Closes the hero with a stitched border, like the hem of an embroidered thobe. */
.stitch-band {
  background: var(--black);
  padding-bottom: 28px;
}
.hero__sub {
  margin: 26px 0 0;
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1.35;
}
.hero__intro {
  margin: 10px 0 0;
  max-width: 34em;
  color: var(--muted);
  font-size: 1.0625rem;
}
.status {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 22px 0 0;
  font-size: 0.9375rem;
  color: var(--ink);
}
.status__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #a9a8a1;
  flex: none;
}
.status.is-open .status__dot {
  background: var(--brass);
  box-shadow: 0 0 0 4px rgba(184, 151, 90, 0.22);
}
.hero__actions {
  display: grid;
  gap: 12px;
  margin-top: 26px;
}
.hero__paused {
  margin: 14px 0 0;
  color: var(--muted);
}
.hero__photo {
  margin: 0;
}
.hero__photo img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

@media (min-width: 560px) {
  .hero__actions {
    display: flex;
    flex-wrap: wrap;
  }
}
@media (min-width: 900px) {
  .hero {
    padding-block: 64px 56px;
  }
  .stitch-band {
    padding-bottom: 40px;
  }
  .hero__inner {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
    align-items: end;
    gap: 56px;
  }
  .hero__mark {
    font-size: min(calc((min(100vw, 1120px) - 2 * var(--gutter) - 56px) * 0.625 / 3.6), 12rem);
  }
  /* No photo yet: the wordmark and text take the whole width. */
  .hero--text .hero__inner {
    grid-template-columns: minmax(0, 1fr);
  }
  .hero--text .hero__mark {
    font-size: min(calc((min(100vw, 1120px) - 2 * var(--gutter)) / 3.6), 13rem);
  }
}

/* ---------------------------------------------------------------- sections */

.section {
  padding-block: 56px;
}
.section--light {
  background: var(--porcelain);
  color: var(--ink);
}
.section--black {
  background: var(--black);
  color: var(--porcelain);
}
.section--charcoal {
  background: var(--charcoal);
  color: var(--porcelain);
}
.section__title {
  margin: 0 0 28px;
  font-family: var(--font-display);
  font-stretch: 112%;
  font-weight: 760;
  font-size: 2rem;
  line-height: 1.05;
  letter-spacing: -0.01em;
}
[lang='ar'] .section__title {
  font-family: var(--font-arabic);
  font-weight: 700;
  letter-spacing: 0;
  font-size: 1.875rem;
  line-height: 1.3;
}
@media (min-width: 900px) {
  .section {
    padding-block: 88px;
  }
  .section__title {
    font-size: 2.75rem;
  }
  [lang='ar'] .section__title {
    font-size: 2.375rem;
  }
}

/* ---------------------------------------------------------------- price board
   The same grammar as the price list on a shop wall: name, dotted leader, price. */

.board {
  list-style: none;
  margin: 0;
  padding: 0;
  max-width: 760px;
}
.board__row {
  display: grid;
  grid-template-columns: auto minmax(24px, 1fr) auto;
  column-gap: 10px;
  align-items: baseline;
  padding-block: 16px;
  text-decoration: none;
  color: inherit;
}
.board__name {
  font-size: 1.125rem;
  font-weight: 500;
  max-width: 15em;
}
.board__leader {
  border-bottom: 2px dotted currentColor;
  opacity: 0.35;
  transform: translateY(-0.3em);
}
.board__price {
  font-family: var(--font-display);
  font-stretch: 110%;
  font-weight: 700;
  font-size: 1.375rem;
  font-variant-numeric: tabular-nums;
}
.board__details {
  grid-column: 1 / 3;
  max-width: 34em;
  margin-top: 4px;
  font-size: 0.9375rem;
  line-height: 1.45;
}
.board__meta {
  grid-column: 1;
  font-size: 0.9375rem;
  color: var(--muted);
}
.board__book {
  grid-column: 3;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  justify-self: end;
  font-size: 0.9375rem;
  font-weight: 600;
}
.board__book .i {
  width: 1.1em;
  height: 1.1em;
}
a.board__row:hover .board__name {
  text-decoration: underline;
  text-underline-offset: 4px;
}
a.board__row:focus-visible {
  box-shadow: none;
  outline: 2px solid var(--brass);
  outline-offset: 4px;
}
.board__note {
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 0.9375rem;
}

.board--hours .board__row {
  padding-block: 11px;
  position: relative;
}
.board--hours .board__name {
  font-size: 1rem;
}
.board--hours .board__price {
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
}
.board--hours .is-closed .board__price,
.board--hours .is-closed .board__name {
  color: var(--muted-dark);
}
.board--hours .is-today .board__name,
.board--hours .is-today .board__price {
  font-weight: 700;
}
.board--hours .is-today::before {
  content: '';
  position: absolute;
  inset-inline-start: -14px;
  top: 50%;
  width: 4px;
  height: 18px;
  margin-top: -9px;
  background: var(--brass);
}

/* ---------------------------------------------------------------- work */

/* Photo strip between the price board and the hours: edge to edge, black and white. */
.band {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3px;
  background: var(--black);
}
.band--1 {
  grid-template-columns: 1fr;
}
.band--3 {
  grid-template-columns: repeat(3, 1fr);
}
.band img {
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  filter: grayscale(1) contrast(1.06);
}
.band--1 img {
  aspect-ratio: 16 / 9;
}
@media (min-width: 900px) {
  .band--4 {
    grid-template-columns: repeat(4, 1fr);
  }
  .band img {
    aspect-ratio: 3 / 4;
  }
  .band--1 img {
    aspect-ratio: 21 / 9;
  }
}

/* ---------------------------------------------------------------- visit */

.visit__inner {
  display: grid;
  gap: 56px;
}
.visit__hours .board__leader {
  opacity: 0.25;
}
.visit__last {
  margin: 16px 0 0;
  color: var(--muted-dark);
  font-size: 0.9375rem;
}
.visit__address {
  font-style: normal;
  font-size: 1.375rem;
  line-height: 1.4;
  font-weight: 500;
}
.visit__note {
  margin: 8px 0 0;
  color: var(--muted-dark);
}
.visit__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 22px;
}
.visit__map {
  margin-top: 24px;
  aspect-ratio: 4 / 3;
  background: var(--charcoal-2);
  border: 1px solid var(--line-dark);
}
.visit__map iframe {
  width: 100%;
  height: 100%;
  border: 0;
  /* Monochrome map so it sits inside the palette. */
  filter: grayscale(1) contrast(1.05);
}
@media (min-width: 900px) {
  .visit__inner {
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 80px;
  }
}

/* ---------------------------------------------------------------- footer */

.site-footer {
  background: var(--black);
  color: var(--porcelain);
  padding-block: 0 28px;
}
.site-footer__stitch {
  margin-bottom: 36px;
  border-top: 14px solid var(--black);
}
.site-footer__inner {
  display: grid;
  gap: 24px;
}
.site-footer__addr {
  margin: 12px 0 0;
  color: var(--muted-dark);
  font-size: 0.9375rem;
}
.site-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  font-size: 0.9375rem;
}
.site-footer__links a {
  color: var(--porcelain);
  padding-block: 6px;
}
.site-footer__legal {
  margin-top: 28px;
  font-size: 0.8125rem;
  color: var(--muted-dark);
}
@media (min-width: 700px) {
  .site-footer__inner {
    grid-template-columns: 1fr auto;
    align-items: end;
  }
}

/* ---------------------------------------------------------------- mobile dock */

.dock {
  position: fixed;
  inset-inline: 0;
  bottom: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 10px;
  padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom));
  background: var(--black);
  color: var(--porcelain);
  border-top: 1px solid var(--charcoal-2);
  transform: translateY(110%);
  transition: transform 0.2s ease;
}
.dock[hidden] {
  display: none;
}
.dock.is-visible {
  transform: none;
}
@media (min-width: 860px) {
  .dock {
    display: none !important;
  }
}
.page-home {
  padding-bottom: 0;
}
.page-home.has-dock .site-footer {
  padding-bottom: calc(96px + env(safe-area-inset-bottom));
}

/* ================================================================ booking flow */

.page-flow {
  background: var(--porcelain);
  min-height: 100vh;
}
.flow {
  padding-block: 24px 64px;
}
.flow__progress {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  margin-bottom: 14px;
}
.flow__progress span {
  height: 3px;
  background: var(--line);
}
.flow__progress span.is-done {
  background: var(--ink);
}
.flow__progress span.is-current {
  background: var(--brass);
}
.flow__step {
  margin: 0 0 4px;
  font-size: 0.875rem;
  color: var(--muted);
}
.flow__title {
  margin: 0 0 20px;
  font-family: var(--font-display);
  font-stretch: 112%;
  font-weight: 760;
  font-size: 1.75rem;
  line-height: 1.1;
}
[lang='ar'] .flow__title {
  font-family: var(--font-arabic);
  font-weight: 700;
  font-size: 1.625rem;
  line-height: 1.35;
}
.flow__actions {
  display: grid;
  gap: 10px;
  margin-top: 24px;
}
.flow__lead {
  margin: -8px 0 20px;
  color: var(--muted);
}

/* Picked-so-far summary */
.picked {
  display: grid;
  margin: 0 0 22px;
  border-top: 1px solid var(--line);
}
.picked__row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-block: 10px;
  border-bottom: 1px solid var(--line);
  font-size: 0.9375rem;
}
.picked__row .i {
  color: var(--muted);
}
.picked__text {
  flex: 1;
  min-width: 0;
}
.picked__change {
  background: none;
  border: 0;
  padding: 8px 0;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  font-size: 0.9375rem;
}

/* Service choice */
.choices {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}
.choice {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 2px 16px;
  width: 100%;
  min-height: 68px;
  padding: 14px 16px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-align: start;
  cursor: pointer;
}
.choice:hover {
  border-color: var(--ink);
}
.choice[aria-pressed='true'] {
  border-color: var(--ink);
  box-shadow: inset 3px 0 0 var(--brass);
}
[dir='rtl'] .choice[aria-pressed='true'] {
  box-shadow: inset -3px 0 0 var(--brass);
}
.choice__name {
  font-weight: 600;
  font-size: 1.0625rem;
}
.choice__details {
  grid-column: 1;
  font-size: 0.9375rem;
  line-height: 1.45;
  margin-block: 2px;
}
.choice--details .choice__price {
  grid-row: 1 / span 3;
}
.choice__meta {
  grid-column: 1;
  font-size: 0.875rem;
  color: var(--muted);
}
.choice__price {
  grid-row: 1 / span 2;
  grid-column: 2;
  font-family: var(--font-display);
  font-stretch: 110%;
  font-weight: 700;
  font-size: 1.25rem;
}

/* Month calendar */
.cal {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 10px 14px;
}
.cal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.cal__month {
  font-weight: 600;
  font-size: 1.0625rem;
}
.cal__nav {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  background: none;
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
}
.cal__nav:hover:not(:disabled) {
  border-color: var(--line);
}
.cal__nav:disabled {
  opacity: 0.25;
  cursor: default;
}
.cal__grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 2px;
}
.cal__dow {
  text-align: center;
  font-size: 0.75rem;
  color: var(--muted);
  padding-block: 6px;
}
[lang='ar'] .cal__dow {
  font-size: 0.6875rem;
}
.cal__day {
  position: relative;
  aspect-ratio: 1;
  min-height: 40px;
  display: grid;
  place-items: center;
  background: none;
  border: 0;
  border-radius: var(--radius);
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}
.cal__day:disabled {
  color: #a9a8a1;
  cursor: default;
}
.cal__day.is-available {
  font-weight: 600;
  background: var(--porcelain);
}
.cal__day.is-available:hover {
  background: #e0dfd8;
}
.cal__day.is-today::after {
  content: '';
  position: absolute;
  bottom: 5px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--brass);
}
.cal__day[aria-pressed='true'],
.cal__day[aria-pressed='true']:hover {
  background: var(--ink);
  color: var(--porcelain);
}
.cal__day.is-outside {
  visibility: hidden;
}

/* Times */
.times {
  margin-top: 26px;
}
.times__title {
  margin: 0 0 14px;
  font-size: 1.125rem;
  font-weight: 600;
}
.times__group {
  margin: 0 0 18px;
}
.times__label {
  margin: 0 0 8px;
  font-size: 0.8125rem;
  color: var(--muted);
}
.times__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
  gap: 8px;
}
.slot {
  min-height: var(--tap);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}
.slot:hover {
  border-color: var(--ink);
}
.slot[aria-pressed='true'] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--porcelain);
}
.times__empty {
  padding: 16px;
  background: var(--paper);
  border: 1px dashed var(--line);
  color: var(--muted);
}

/* Review / appointment details */
.ticket {
  margin: 0;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 4px 16px;
}
.ticket__row {
  display: grid;
  grid-template-columns: 7.5em 1fr;
  gap: 12px;
  padding-block: 12px;
  border-bottom: 1px solid #e7e5de;
}
.ticket__row:last-child {
  border-bottom: 0;
}
.ticket dt {
  color: var(--muted);
  font-size: 0.9375rem;
}
.ticket dd {
  margin: 0;
  font-weight: 500;
  overflow-wrap: anywhere;
}
.ticket__sub {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.9375rem;
}
.ticket__link {
  display: block;
  margin-top: 4px;
  font-weight: 600;
}
.ticket--cancelled dd {
  text-decoration: line-through;
  color: var(--muted);
}
.fineprint {
  margin: 16px 0 0;
  font-size: 0.9375rem;
  color: var(--muted);
}
.fineprint + .fineprint {
  margin-top: 6px;
}

/* Confirmation hero */
.done {
  margin-bottom: 22px;
}
.done__mark {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 2px solid var(--brass);
  color: var(--brass-ink);
  margin-bottom: 14px;
}
.done__when {
  margin: -10px 0 0;
  font-size: 1.25rem;
  font-weight: 600;
}
.done .tatreez-line {
  width: calc(var(--tatreez-rule-w) * 5);
  margin-top: 16px;
  background-image: var(--tatreez-rule-ink);
  background-position: left center;
}
[dir='rtl'] .done .tatreez-line {
  background-position: right center;
}
.linkbox {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}
.linkbox__row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.linkbox__row .btn {
  flex: 1 1 auto;
}

.confirm-box {
  margin-top: 18px;
  padding: 16px;
  background: var(--paper);
  border: 1px solid var(--danger);
  border-radius: var(--radius);
}
.confirm-box p {
  margin: 0 0 12px;
  font-weight: 600;
}
.confirm-box .flow__actions {
  margin-top: 0;
}

.honeypot {
  position: absolute;
  inset-inline-start: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  vertical-align: -3px;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.loading-line {
  padding: 18px 0;
  color: var(--muted);
}

/* Privacy page: plain reading text, one column. */
.legal {
  font-size: 1.0625rem;
  line-height: 1.6;
}
.legal > p,
.legal > ul {
  max-width: 64ch;
  margin: 0 0 16px;
}
.legal ul {
  padding-inline-start: 1.2em;
}
.legal li + li {
  margin-top: 8px;
}
.legal h2 {
  margin: 40px 0 12px;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
}
.legal a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--brass-ink);
  text-underline-offset: 3px;
}
.legal__updated {
  color: var(--muted);
  font-size: 0.9375rem;
}
[lang='ar'] .legal {
  line-height: 1.8;
}
