@font-face {
  font-family: Editorial;
  src: url("assets/fonts/editorial.ttf");
}
@font-face {
  font-family: Editorial;
  src: url("assets/fonts/editorial-italic.ttf");
  font-style: italic;
}
:root {
  /* Proposed lighter cream — pending owner approval. */
  --cream: #f8f5ef;
  --brown: #5d1f00;
  --charcoal: #2c2a29;
  --olive: #baba86;
  --tan: #d7995a;
  --line: #e8ded5;
  --surface: #f5f1ea;
  --muted: #2c2a29;
  --serif: Editorial, Georgia, serif;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--cream);
  color: var(--charcoal);
  font:
    16px/1.6 Arial,
    Helvetica,
    sans-serif;
}
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}
button,
a {
  touch-action: manipulation;
}
button {
  cursor: pointer;
  background: transparent;
  border: 1px solid var(--line);
  padding: 8px 20px;
  min-height: 40px;
  font-size: 14px;
  line-height: 1.2;
}
a {
  color: inherit;
}
button.active,
.primary {
  background: var(--brown);
  color: var(--cream);
  border-color: var(--brown);
}
/* Fields use their existing border, without a second surrounding box. */
input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--brown);
  box-shadow: none;
}
/* A fine, close ring keeps keyboard navigation visible on all buttons/links. */
button:focus-visible,
a:focus-visible,
input[type="checkbox"]:focus-visible {
  outline: 1px solid var(--brown);
  outline-offset: 2px;
}
@media (forced-colors: active) {
  input:focus,
  select:focus,
  textarea:focus {
    outline: 1px solid Highlight;
    outline-offset: 0;
  }
}
.prototype {
  text-align: center;
  background: var(--surface);
  font-size: 12px;
  letter-spacing: 0.1em;
  padding: 7px 12px;
}
header {
  height: 100px;
  margin: 0 6%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}
.logo {
  position: relative;
  display: block;
  overflow: hidden;
  width: 156px;
  height: 52px;
}
.logo img {
  position: absolute;
  width: 174.575px;
  max-width: none;
  left: -8.287px;
  top: -64.106px;
}
.location,
.eyebrow {
  font-size: 12px;
  letter-spacing: 0.16em;
}
.location {
  margin-inline-start: auto;
  margin-inline-end: 40px;
}
nav {
  display: flex;
  gap: 24px;
  padding: 12px 6%;
  border-bottom: 1px solid var(--line);
}
nav button {
  border: 0;
  padding: 10px 0;
  border-bottom: 2px solid transparent;
}
nav button.active {
  color: var(--brown);
  background: transparent;
  border-bottom-color: var(--brown);
}
main {
  max-width: 1320px;
  margin: auto;
  padding: 38px 6% 70px;
  min-height: 70vh;
}
h1,
h2,
h3 {
  color: var(--brown);
  font-family: var(--serif);
  font-weight: 400;
  line-height: 1.12;
  margin: 0 0 18px;
}
h1 {
  font-size: 58px;
  letter-spacing: -0.035em;
}
h2 {
  font-size: 34px;
}
h3 {
  font-size: 27px;
}
p {
  margin: 0 0 16px;
}
.muted,
small {
  color: var(--muted);
}
small {
  font-size: 13px;
}
.heading {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  align-items: center;
  margin-bottom: 32px;
}
.heading p {
  margin: 0;
}
.eyebrow {
  margin-bottom: 12px;
}
.tabs,
.filters,
.actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.tabs {
  margin-bottom: 26px;
}
.tabs button {
  border: 0;
  border-bottom: 1px solid var(--line);
}
.grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 290px;
  gap: 38px;
}
.week {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  border: 1px solid var(--line);
  margin-bottom: 24px;
}
.week button {
  border: 0;
  border-inline-end: 1px solid var(--line);
  padding: 12px 3px;
  font-size: 13px;
}
.week strong {
  display: block;
  font-family: var(--serif);
  font-size: 28px;
}
.filters {
  margin: 20px 0;
}
.filters button {
  padding: 7px 14px;
  font-size: 14px;
  border-radius: 30px;
}
/* Days in the week strip that have free appointment times. */
.week button.has-times strong::after {
  content: "";
  display: block;
  width: 6px;
  height: 6px;
  margin: 4px auto 0;
  border-radius: 50%;
  background: currentColor;
}
.class-row {
  display: grid;
  grid-template-columns: 76px 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 25px 0;
  border-top: 1px solid var(--line);
}
.class-row h3 {
  margin: 0 0 6px;
}
.class-row p {
  margin: 0;
  font-size: 14px;
}
.time {
  font-size: 19px;
}
.time small {
  display: block;
}
.spots {
  font-size: 14px;
  margin-bottom: 8px;
}
.class-action {
  display: grid;
  gap: 14px;
  text-align: end;
  min-width: 156px;
}
.class-action .spots {
  margin: 0;
}
.waitlist-section {
  margin-block-start: 40px;
}
.waitlist-empty p {
  margin: 0;
}
.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 26px;
  margin-bottom: 20px;
}
.balance-panel {
  background: var(--surface);
}
.big {
  font: 64px var(--serif);
  line-height: 1.1;
}
.balance-panel h3 {
  font-size: 26px;
}
.rule {
  border-top: 1px solid var(--line);
  margin: 18px 0;
  padding-top: 18px;
}
.pill {
  display: inline-block;
  background: var(--olive);
  color: var(--charcoal);
  padding: 4px 9px;
  font-size: 12px;
}
.draft {
  background: #f1ede8;
  color: var(--brown);
}
.quiet {
  font-size: 14px;
}
.empty {
  background: var(--surface);
  padding: 48px 20px;
  text-align: center;
  border: 1px solid var(--line);
}
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.cards .panel {
  background: var(--surface);
  margin: 0;
}
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-block: 1px solid var(--line);
  margin: 25px 0;
}
.stats > div {
  padding: 18px;
}
.stats strong {
  font: 36px var(--serif);
  display: block;
}
.roster-row {
  display: flex;
  gap: 15px;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  padding: 15px 0;
}
.avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--olive);
  display: grid;
  place-items: center;
}
.person {
  flex: 1;
}
.person small {
  display: block;
}
.scanner {
  background: var(--surface);
}
.scanner-steps {
  border-inline-start: 1px solid var(--tan);
  padding-inline-start: 20px;
  margin: 22px 0;
}
.scanner-steps p {
  margin-bottom: 12px;
}
label {
  display: block;
  font-size: 14px;
  margin-bottom: 16px;
}
input,
select,
textarea {
  display: block;
  width: 100%;
  padding: 11px;
  border: 1px solid var(--line);
  background: #ffffff;
  border-color: #c5b5a8;
  min-height: 46px;
  margin-top: 5px;
  border-radius: 0;
}
textarea {
  min-height: 85px;
}
input[type="checkbox"] {
  display: inline;
  width: 20px;
  min-height: 20px;
  vertical-align: middle;
  margin-inline-end: 8px;
}
.fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}
.fields label {
  margin: 0;
}
.admin-row {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 24px;
  margin-bottom: 20px;
}
.admin-row .actions {
  margin-top: 15px;
}
.notice {
  border-inline-start: 3px solid var(--tan);
  padding: 12px 16px;
  background: var(--surface);
  margin-bottom: 24px;
  font-size: 14px;
}
.package-price {
  font: 34px var(--serif);
  margin: 20px 0;
}
.mark {
  width: 80px;
  height: 80px;
  object-fit: cover;
}
dialog {
  background: var(--surface);
  color: var(--charcoal);
  border: 1px solid var(--line);
  padding: 32px;
  max-width: 510px;
  width: calc(100% - 32px);
  max-height: 90vh;
}
dialog::backdrop {
  background: #2c160c66;
  backdrop-filter: blur(3px);
}
.close {
  float: inline-end;
  border: 0;
  padding: 0 8px;
  font-size: 25px;
}
.dialog-body {
  clear: both;
  padding-top: 10px;
}
dialog h2 {
  font-size: 38px;
}
dialog .primary {
  width: 100%;
  min-height: 46px;
  margin-top: 12px;
}
.success {
  text-align: center;
}
.success .mark {
  margin-bottom: 20px;
}
#toast:not(:empty) {
  position: fixed;
  bottom: 24px;
  inset-inline: 20px;
  margin: auto;
  max-width: 500px;
  padding: 15px 24px;
  background: var(--brown);
  color: var(--cream);
  z-index: 10;
  text-align: center;
}
footer {
  border-top: 1px solid var(--line);
  padding: 24px 6%;
  font-size: 13px;
  display: flex;
  justify-content: space-between;
}
footer span {
  font: italic 20px var(--serif);
}
.skip {
  position: absolute;
  top: -100px;
}
.skip:focus {
  top: 0;
  z-index: 100;
  background: var(--cream);
}
[dir="rtl"] h1,
[dir="rtl"] h2,
[dir="rtl"] h3 {
  color: var(--brown);
  font-family: "Balance Arabic", sans-serif;
  line-height: 1.4;
}
[dir="rtl"] .eyebrow {
  letter-spacing: 0;
}
@media (max-width: 800px) {
  .grid {
    grid-template-columns: 1fr;
  }
  .grid aside {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
  }
  .cards {
    grid-template-columns: 1fr 1fr;
  }
  .location {
    display: none;
  }
  h1 {
    font-size: 44px;
  }
  .heading {
    align-items: start;
  }
  .heading > button {
    flex-shrink: 0;
  }
}
@media (max-width: 540px) {
  header {
    height: 85px;
  }
  nav {
    gap: 22px;
    padding-inline: 5%;
    font-size: 14px;
  }
  main {
    padding: 28px 5% 45px;
  }
  .prototype {
    font-size: 10px;
  }
  .heading {
    display: block;
    margin-bottom: 24px;
  }
  .heading > button {
    margin-top: 15px;
  }
  h1 {
    font-size: 43px;
  }
  .grid {
    gap: 20px;
  }
  .grid aside {
    display: block;
  }
  .class-row {
    grid-template-columns: 60px 1fr;
    gap: 12px;
    padding: 20px 0;
  }
  .class-action {
    grid-column: 2;
    text-align: start;
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    align-items: center;
    min-width: 0;
  }
  .class-action .spots {
    margin: 0;
  }
  .class-row h3 {
    font-size: 25px;
  }
  .class-action button {
    width: 100%;
  }
  .week strong {
    font-size: 25px;
  }
  .week button {
    font-size: 12px;
  }
  .cards {
    grid-template-columns: 1fr;
  }
  .fields {
    grid-template-columns: 1fr;
  }
  .panel {
  background: var(--surface);
    padding: 20px;
  }
  .stats > div {
    padding: 15px 7px;
    font-size: 13px;
  }
  .stats strong {
    font-size: 30px;
  }
  footer {
    display: block;
  }
  footer span {
    display: block;
    margin-top: 10px;
  }
  .tabs {
    gap: 4px;
  }
  .tabs button {
    padding: 8px;
    font-size: 14px;
  }
  dialog {
    padding: 23px;
  }
}
/* Stage 2 forms extend the approved Stage 1 visual system. */
.section-title {
  margin-top: 36px;
}
fieldset {
  border: 1px solid var(--line);
  padding: 18px;
  margin: 18px 0;
}
legend {
  padding: 0 8px;
  font-size: 14px;
}
pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 14px;
}
nav {
  flex-wrap: wrap;
}
form > .primary {
  margin-top: 16px;
}
select {
  max-width: 100%;
}
.roster-row .actions {
  justify-content: flex-end;
}
.scanner h3 {
  margin-top: 20px;
}
.grid > section {
  min-width: 0;
}
input[type="hidden"] {
  display: none;
}
[hidden] {
  display: none !important;
}
@media (max-width: 540px) {
  .roster-row {
    flex-wrap: wrap;
  }
  .roster-row .actions {
    width: 100%;
    justify-content: flex-start;
  }
  .stats {
    overflow-wrap: anywhere;
  }
  nav {
    gap: 12px;
  }
  .prototype {
    letter-spacing: 0.04em;
  }
}

/* Stage 3 onboarding uses the approved forms and logical RTL spacing. */
.auth-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-block-start: 24px;
}
.form-error {
  margin-block-start: 20px;
  overflow-wrap: anywhere;
}
.test-code strong {
  font-size: 24px;
  letter-spacing: 0.12em;
  display: inline-block;
}
/* Explicit foreground/background pairs prevent pale text on pale hover states. */
button:not(:disabled):hover {
  background: #eee4d8;
  color: var(--brown);
}
button.primary:not(:disabled):hover,
button.active:not(:disabled):hover {
  background: #783819;
  color: #fffcf8;
}
button:not(:disabled):active {
  background: #dfcdbb;
  color: var(--brown);
}
button.primary:not(:disabled):active,
button.active:not(:disabled):active {
  background: #421600;
  color: #fffcf8;
}
button:disabled,
input:disabled,
select:disabled,
textarea:disabled {
  background: #e9e1d8;
  color: #644a38;
  -webkit-text-fill-color: #644a38;
  border-color: #ad9785;
  opacity: 1;
  cursor: not-allowed;
}
button[aria-busy="true"] { cursor: progress; }

/* Top navigation stays quiet, including selected and pressed items. */
nav button:not(:disabled):hover,
nav button.active:not(:disabled):hover,
nav button:not(:disabled):active,
nav button.active:not(:disabled):active,
nav button:focus-visible {
  background: transparent;
  color: var(--brown);
}
nav button:not(:disabled):hover {
  border-bottom-color: #b99c88;
}
nav button.active:not(:disabled):hover,
nav button.active {
  border-bottom-color: var(--brown);
}
nav button:focus-visible {
  outline: none;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}

/* Language switch matches the minimal top navigation. */
#language {
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 10px 0;
  background: transparent;
  color: var(--brown);
}
#language:not(:disabled):hover,
#language:not(:disabled):active,
#language:focus-visible {
  background: transparent;
  color: var(--brown);
}
#language:not(:disabled):hover {
  border-bottom-color: #b99c88;
}
#language:focus-visible {
  outline: none;
  text-decoration: underline dotted;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}

/* Palette preview: olive signals selection; charcoal carries practical content. */
.eyebrow, .big, .stats strong, .package-price { color: var(--brown); }
nav button { color: var(--brown); }
/* Class filters keep the warm brown primary selection treatment. */
.filters button.active {
  background: var(--brown);
  color: #ffffff;
  border-color: var(--brown);
}
.filters button.active:not(:disabled):hover {
  background: #783819;
  color: #ffffff;
  border-color: #783819;
}
.filters button.active:not(:disabled):active {
  background: #421600;
  color: #ffffff;
  border-color: #421600;
}
.filters button:not(:disabled):hover { border-color: var(--brown); }
.balance-panel { border-top: 3px solid var(--olive); }
.notice { border-inline-start-color: var(--olive); }

.week-navigation { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.week-navigation > div { text-align: center; }
.week-navigation small { display: block; }
.week-navigation button { min-width: 44px; padding: 8px 12px; color: var(--brown); }

/* Same bundled families as the Balance Studio website, so every device renders alike. */
@font-face {
  font-family: "Balance Arabic";
  src: url("assets/fonts/arabic-ui.ttf") format("truetype");
  font-weight: 100 900;
  font-display: swap;
}
/* Editorial hierarchy; practical controls retain clear, generous text. */
/* One bundled text family for English and Arabic, so phones and laptops match. */
body { font-family: "Balance Arabic", "Segoe UI", Arial, sans-serif; font-weight: 350; }
h1, h2, h3, .big, .week strong, .stats strong, .package-price, .week-navigation strong { font-variant-numeric: lining-nums; }
nav button, .tabs button, #language { font-family: var(--serif); font-size: 20px; }
.week-navigation strong { font-family: var(--serif); font-size: 24px; font-weight: 500; }
.panel > p:not(.eyebrow):not(.quiet), .heading > p { font-size: 17px; line-height: 1.65; }
label, .filters button { font-weight: 500; }
[dir="rtl"] body { font-family: "Balance Arabic", sans-serif; font-weight: 350; line-height: 1.8; font-synthesis: none; }
[dir="rtl"] label, [dir="rtl"] .filters button, [dir="rtl"] button { font-weight: 400; }
[dir="rtl"] nav button, [dir="rtl"] .tabs button, [dir="rtl"] #language,
[dir="rtl"] .week-navigation strong {
  font-family: "Balance Arabic", sans-serif;
  letter-spacing: 0;
}
[dir="rtl"] nav button, [dir="rtl"] .tabs button, [dir="rtl"] #language { font-size: 15px; font-weight: 500; }
[dir="rtl"] .week-navigation strong { font-size: 19px; }
/* Arabic headings are the light cut of the text family: airy, like the Latin serif. */
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] dialog h2 { font-weight: 250; line-height: 1.5; }
[dir="rtl"] h3 { font-weight: 300; }
/* Latin fragments inside Arabic headings (class names, numbers) keep the editorial serif. */
[dir="rtl"] h1 bdi, [dir="rtl"] h2 bdi { font-family: var(--serif); }
[dir="rtl"] h1 { font-size: 46px; letter-spacing: 0; }
[dir="rtl"] h2 { font-size: 29px; }
[dir="rtl"] h3 { font-size: 23px; }
@media (max-width: 600px) {
  nav { gap: 14px; }
  nav button, .tabs button { font-size: 18px; }
  [dir="rtl"] nav button, [dir="rtl"] .tabs button { font-size: 13px; }
  [dir="rtl"] h1 { font-size: 34px; }
  [dir="rtl"] h2 { font-size: 26px; }
}

/* Sub-navigation (tabs, day tiles, text links) stays as quiet as the top navigation:
   no filled hover block, only a brown label and a fine underline. */
.tabs button:not(.active):not(:disabled):hover,
.tabs button:not(.active):not(:disabled):active,
.week button:not(.active):not(:disabled):hover,
.week button:not(.active):not(:disabled):active,
.week-navigation button:not(:disabled):hover,
.week-navigation button:not(:disabled):active,
.auth-actions button:not(:disabled):hover,
.auth-actions button:not(:disabled):active {
  background: transparent;
  color: var(--brown);
}
.tabs button:not(.active):not(:disabled):hover { border-bottom-color: var(--brown); }
.week button:not(.active):not(:disabled):hover { box-shadow: inset 0 -2px 0 #b99c88; }
.week-navigation button:not(:disabled):hover,
.auth-actions button:not(:disabled):hover { border-color: var(--brown); }
.filters button:not(.active):not(:disabled):hover,
.filters button:not(.active):not(:disabled):active { background: transparent; }

/* Empty states share one card: bookings, waitlist and schedule. */
.empty p { margin: 0; }
.empty button { margin-inline-start: 10px; }
.admin-row h3, .panel h3 { margin-bottom: 14px; }
.actions { align-items: center; }
form .actions { margin-top: 16px; }
form .actions .primary { margin-top: 0; }
dialog label { margin-top: 14px; }

/* -- Refinement layer, October 2026 --------------------------------------------
   Softer geometry and one numeral style. No new elements; same palette. */
:root {
  --r-sm: 12px;
  --r-md: 16px;
  --r-lg: 22px;
  --pill: 999px;
  --lift: 0 1px 2px rgba(93, 31, 0, 0.04), 0 10px 28px rgba(93, 31, 0, 0.05);
}
button { border-radius: var(--pill); padding: 8px 20px; transition: border-color 0.15s, background-color 0.15s, color 0.15s; }
nav button, #language, .close { border-radius: 0; }
button:not(.primary):not(.active):not(:disabled):hover,
button:not(.primary):not(.active):not(:disabled):active { background: transparent; border-color: var(--brown); }
input, select, textarea { border-radius: var(--r-sm); padding: 12px 14px; transition: border-color 0.15s; }
input[type="checkbox"] { border-radius: 4px; accent-color: var(--brown); padding: 0; }
.panel, .admin-row, .empty, fieldset, .stats { border-radius: var(--r-md); }
.panel, .admin-row, .empty { box-shadow: var(--lift); }
.stats { border: 1px solid var(--line); background: var(--surface); }
.notice { border-radius: var(--r-sm); }
.pill { border-radius: var(--pill); padding: 4px 12px; }
dialog { border-radius: var(--r-lg); box-shadow: 0 24px 60px rgba(44, 22, 12, 0.18); }
#toast:not(:empty) { border-radius: var(--r-md); }

/* Credits card: a short olive rule replaces the full-width top border. */
.balance-panel { border-top: 1px solid var(--line); position: relative; padding-top: 34px; }
.balance-panel::before {
  content: "";
  position: absolute;
  top: 0;
  inset-inline-start: 26px;
  width: 44px;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: var(--olive);
}
.balance-panel .big { line-height: 1; margin: 6px 0 4px; }

/* Section tabs: quiet text, the selected one is a brown pill. */
.tabs { gap: 6px; }
.tabs button { border: 0; padding: 9px 20px; }
.tabs button:not(.active):not(:disabled):hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 7px; }

/* Week strip: seven separate rounded tiles instead of one ruled box. */
.week { border: 0; gap: 8px; }
.week button {
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--surface);
  padding: 12px 2px 10px;
}
.week button.active { border-color: var(--brown); background: var(--brown); box-shadow: 0 8px 18px rgba(93, 31, 0, 0.18); }
.week button:not(.active):not(:disabled):hover { box-shadow: none; border-color: var(--brown); background: var(--surface); }
.week-navigation button { width: 44px; height: 44px; min-width: 44px; padding: 0; border-radius: 50%; }

/* One numeral style everywhere, in both languages: the editorial serif, lining figures. */
.week strong, .big, .time, .stats strong, .package-price,
[dir="rtl"] .week strong, [dir="rtl"] .big, [dir="rtl"] .time, [dir="rtl"] .stats strong {
  font-family: var(--serif);
  font-weight: 400;
  font-variant-numeric: lining-nums;
  letter-spacing: 0;
}
.week strong, [dir="rtl"] .week strong { font-size: 30px; line-height: 1.15; margin-top: 2px; }
.time { font-size: 26px; line-height: 1.1; color: var(--brown); }
.time small { font-family: "Balance Arabic", "Segoe UI", Arial, sans-serif; color: var(--charcoal); margin-top: 4px; }
.class-row { grid-template-columns: 84px 1fr auto; }

/* Arabic rhythm: lighter weights, no bold fallbacks, labels in the same family. */
[dir="rtl"] h1 { font-size: 44px; }
[dir="rtl"] h2 { font-size: 30px; }
[dir="rtl"] h3 { font-size: 23px; }
[dir="rtl"] .eyebrow { font-size: 14px; font-weight: 400; color: var(--brown); }
[dir="rtl"] nav button, [dir="rtl"] .tabs button, [dir="rtl"] #language { font-weight: 400; font-size: 16px; }
[dir="rtl"] .week-navigation strong { font-weight: 300; font-size: 21px; }
[dir="rtl"] .week button { font-size: 13px; font-weight: 350; }
[dir="rtl"] button.primary { font-weight: 400; }
[dir="rtl"] strong, [dir="rtl"] b { font-weight: 500; }
@media (max-width: 540px) {
  button { padding: 10px 18px; }
  .week { gap: 5px; }
  .week button { border-radius: var(--r-sm); padding: 10px 0 8px; }
  .week strong, [dir="rtl"] .week strong { font-size: 25px; }
  [dir="rtl"] .week button { font-size: 10.5px; }
  .tabs button { padding: 8px 14px; }
  .class-row { grid-template-columns: 66px 1fr; }
  .time { font-size: 22px; }
  [dir="rtl"] h1 { font-size: 34px; }
  [dir="rtl"] h2 { font-size: 26px; }
  [dir="rtl"] nav button, [dir="rtl"] .tabs button { font-size: 14px; }
}

/* Packages: lighter cards. Small supporting text, a calmer price, currency in the text font. */
.panel > p.fine, .fine { font-size: 14px; line-height: 1.55; color: #5b534e; margin: 0; }
.fine.lead { margin: -6px 0 22px; }
.cards { align-items: stretch; }
.package, .credit { display: flex; flex-direction: column; padding: 24px; }
.package h3, .credit h3 { font-size: 23px; margin-bottom: 8px; }
.package .package-price { margin: auto 0 4px; padding-top: 18px; font-size: 30px; line-height: 1; display: flex; align-items: baseline; gap: 7px; }
.package-price .currency {
  font-family: "Balance Arabic", "Segoe UI", Arial, sans-serif;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--charcoal);
}
[dir="rtl"] .package-price .currency { letter-spacing: 0; font-size: 14px; }
.credit .big { font-size: 52px; margin: 2px 0 6px; }
[dir="rtl"] .package h3, [dir="rtl"] .credit h3 { font-size: 20px; }
[dir="rtl"] .fine { font-size: 13.5px; line-height: 1.75; }

/* Package cards: the name is as large as the price; only the supporting lines are small. */
.package h3 { font-size: 30px; line-height: 1.15; margin-bottom: 10px; }
.credit h3 { font-size: 27px; }
[dir="rtl"] .package h3 { font-size: 24px; line-height: 1.4; }
[dir="rtl"] .credit h3 { font-size: 23px; }
.panel.package > p.fine { font-size: 13px; line-height: 1.5; }
[dir="rtl"] .panel.package > p.fine { font-size: 13px; line-height: 1.7; }

/* Notices and messages are complete boxes: an even border on all four sides, no side bar. */
.notice {
  border: 1px solid var(--line);
  border-inline-start: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--cream);
  padding: 12px 16px;
}
.panel > p.notice { font-size: 14px; line-height: 1.55; }
.form-error { border-color: #c9a58f; color: var(--brown); }
.scanner-steps { border-inline-start: 0; padding-inline-start: 0; }

/* -- Reading order ---------------------------------------------------------------
   Three clear steps on every screen: the title is largest, the main fact is next,
   supporting text is small and soft. Same rule in English and Arabic. */
h2 { font-size: 36px; margin-bottom: 20px; }
h3, .panel h3, .admin-row h3 { font-size: 28px; line-height: 1.2; margin-bottom: 10px; }
.class-row h3 { font-size: 27px; }
[dir="rtl"] h2 { font-size: 32px; font-weight: 300; line-height: 1.45; }
[dir="rtl"] h3, [dir="rtl"] .panel h3, [dir="rtl"] .admin-row h3 { font-size: 26px; font-weight: 300; line-height: 1.45; }
[dir="rtl"] .class-row h3 { font-size: 24px; }
[dir="rtl"] .package h3 { font-size: 25px; }
[dir="rtl"] .credit h3 { font-size: 24px; }

/* Body copy inside cards steps down so the title leads. */
.panel > p:not(.eyebrow):not(.quiet), .admin-row > p, dialog p, .empty, .empty p {
  font-size: 14.5px;
  line-height: 1.6;
  color: #5b534e;
}
.heading > p { font-size: 16px; color: #5b534e; }
[dir="rtl"] .panel > p:not(.eyebrow):not(.quiet), [dir="rtl"] .admin-row > p, [dir="rtl"] dialog p,
[dir="rtl"] .empty, [dir="rtl"] .empty p { font-size: 14px; line-height: 1.8; }
.panel > p.notice, .notice, dialog .notice { font-size: 13px; line-height: 1.55; color: #5b534e; padding: 10px 14px; }
.panel > p.fine, .fine, dialog p.fine, small, .quiet, .class-row p, .spots { font-size: 13px; color: #5b534e; }
.rule.quiet { font-size: 13px; }
label { font-size: 13.5px; color: var(--charcoal); }
.pill { font-size: 11.5px; letter-spacing: 0.02em; }
[dir="rtl"] .pill { font-size: 12px; letter-spacing: 0; }
.panel > .pill + h3 { margin-top: 12px; }
/* The main fact on a booking card (date and time) sits between title and fine print. */
article.panel > h3 + p:not(.fine) { font-size: 16px; color: var(--charcoal); margin-bottom: 8px; }
dialog h2 { font-size: 34px; margin-bottom: 8px; }
dialog h2 + p { font-size: 16px; color: var(--charcoal); }
[dir="rtl"] dialog h2 { font-size: 28px; }
.test-code { font-size: 14px; }
@media (max-width: 540px) {
  h2 { font-size: 31px; }
  h3, .panel h3, .admin-row h3 { font-size: 26px; }
  [dir="rtl"] h2 { font-size: 28px; }
  [dir="rtl"] h3, [dir="rtl"] .panel h3, [dir="rtl"] .admin-row h3 { font-size: 24px; }
  [dir="rtl"] .class-row h3 { font-size: 22px; }
}

/* Package name stays as large as its price. */
.panel.package h3 { font-size: 30px; line-height: 1.15; }
[dir="rtl"] .panel.package h3 { font-size: 25px; line-height: 1.4; }

/* Sign-in: the helper note is plain text beside (or under) the form, not another box. */
.aside-note { align-self: start; padding: 10px 4px 0; }
.aside-note h3 { font-size: 24px; margin-bottom: 6px; }
.aside-note p { font-size: 14px; line-height: 1.6; color: #5b534e; margin: 0; max-width: 34ch; }
[dir="rtl"] .aside-note h3 { font-size: 22px; }
[dir="rtl"] .aside-note p { line-height: 1.8; }
@media (max-width: 800px) {
  .grid aside.aside-note { display: block; padding: 4px 4px 0; }
}
[dir="rtl"] footer span { font: 300 15px "Balance Arabic", sans-serif; }
[dir="rtl"] .location { letter-spacing: 0; font-size: 13px; }

/* Sign-in: one wider form, with the "New here?" note underneath it. */
.auth { max-width: 720px; }
.auth > .panel { padding: 34px; margin-bottom: 26px; }
.auth .aside-note { padding: 0 4px; }
.auth .aside-note p { max-width: none; }
.heading p.muted:empty { display: none; }
@media (max-width: 540px) {
  .auth > .panel { padding: 22px; }
}

/* Header actions: language and sign out, as quiet text links. */
#signout {
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 0;
  padding: 10px 0;
  margin-inline-start: 26px;
  background: transparent;
  color: var(--brown);
  font-family: var(--serif);
  font-size: 20px;
}
#signout:not(:disabled):hover, #signout:not(:disabled):active { background: transparent; border-bottom-color: #b99c88; }
[dir="rtl"] #signout { font-family: "Balance Arabic", sans-serif; font-size: 16px; font-weight: 400; }
nav:empty { display: none; }
@media (max-width: 540px) {
  #signout { margin-inline-start: 18px; font-size: 18px; }
  [dir="rtl"] #signout { font-size: 14px; }
  .logo { transform: scale(0.88); transform-origin: left center; }
  [dir="rtl"] .logo { transform-origin: right center; }
}
#language { margin-inline-start: auto; }
.location + #language { margin-inline-start: 0; }
@media (max-width: 800px) { .location + #language { margin-inline-start: auto; } }

/* Sign out sits in the footer, opposite the studio name. */
footer { align-items: center; gap: 16px; }
footer #signout { margin-inline-start: auto; padding: 6px 0; font-size: 18px; }
[dir="rtl"] footer #signout { font-size: 15px; }
@media (max-width: 540px) { footer { display: flex; flex-wrap: wrap; } footer #signout { margin-inline-start: auto; } }

/* Footer stacks: studio line, then a small Sign out link beneath it. */
footer, footer:not(:empty) { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
footer #signout { margin-inline-start: 0; padding: 4px 0; min-height: 36px; font-size: 17px; }
[dir="rtl"] footer #signout { font-size: 14px; }
@media (max-width: 540px) { footer { flex-wrap: nowrap; } footer #signout { margin-inline-start: 0; } }

/* Footer is centred: studio line, Sign out beneath it. */
footer, footer:not(:empty) { align-items: center; text-align: center; }
footer #signout { margin-inline: auto; }

/* Language switch: the word itself on every screen, underlined on phones and tablets. */
@media (max-width: 1024px) {
  #language, [dir="rtl"] #language {
    min-width: 34px;
    padding: 6px 2px 4px;
    border-bottom: 1px solid var(--brown);
    font-size: 17px;
    line-height: 1.2;
    text-align: center;
  }
  #language:not(:disabled):hover { border-bottom-color: var(--brown); }
}

/* Client page (reception) and My details (client). */
h4 { font: 400 13px "Balance Arabic", "Segoe UI", Arial, sans-serif; letter-spacing: 0.12em; text-transform: uppercase; color: var(--brown); margin: 26px 0 4px; }
[dir="rtl"] h4 { letter-spacing: 0; font-size: 14px; }
.client-card { margin-top: 18px; }
.client-card .stats { margin: 18px 0 12px; }
.client-card .stats > div { font-size: 13px; color: #5b534e; }
.client-card .roster-row { padding: 11px 0; font-size: 14.5px; }
.client-card .roster-row:first-of-type { border-top: 0; }
.client-edit { border-top: 1px solid var(--line); margin-top: 26px; }
.client-edit button { margin-top: 16px; }
#password-form h3 { margin-bottom: 16px; }

.panel button + button { margin-inline-start: 10px; }
dialog .primary + button, dialog button + .primary { margin-inline-start: 0; }

/* Reception client search: matches appear as a short tappable list under the box. */
.client-results { display: grid; gap: 8px; margin: -6px 0 18px; }
.client-results:empty { display: none; }
.client-results button {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  width: 100%;
  border-radius: var(--r-sm);
  background: var(--surface);
  padding: 10px 16px;
  text-align: start;
  margin: 0;
}
.client-results button + button { margin-inline-start: 0; }
.client-results bdi { font-size: 13px; color: #5b534e; }

/* Reception: one search at the top; choosing a client turns the page into her page. */
.client-search { font-size: 15px; max-width: 720px; }
.client-search input { min-height: 54px; font-size: 17px; }
.client-results { max-width: 720px; }
.client-card h2 { margin-bottom: 6px; }
.client-card .actions button { padding: 7px 14px; min-height: 38px; font-size: 13.5px; }
.client-card .actions button + button { margin-inline-start: 0; }
.inline-form { margin-top: 10px; }
.inline-form .primary { margin-top: 14px; }
button.link {
  border: 0;
  border-radius: 0;
  padding: 0;
  min-height: 0;
  background: transparent;
  color: var(--charcoal);
  text-decoration: underline;
  text-decoration-color: #c5b5a8;
  text-underline-offset: 4px;
  font-weight: 400;
}
button.link:not(:disabled):hover { color: var(--brown); text-decoration-color: var(--brown); }

/* Receipt: shown in the dialog, and the only thing on the page when printed. */
.receipt { text-align: start; }
.receipt .logo { margin-bottom: 22px; }
.receipt h2 { font-size: 34px; margin-bottom: 2px; letter-spacing: 0.02em; }
.receipt > .fine { margin-bottom: 18px; }
.receipt-line { display: flex; justify-content: space-between; gap: 18px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14px; }
.receipt-line span { color: #5b534e; }
.receipt-line strong { font-weight: 400; text-align: end; color: var(--charcoal); }
[dir="rtl"] .receipt-line strong { font-weight: 400; }
.receipt-total { display: flex; justify-content: space-between; align-items: baseline; border-top: 1px solid var(--brown); margin-top: 4px; padding-top: 14px; font-size: 14px; }
.receipt-total .package-price { margin: 0; font-size: 32px; display: flex; align-items: baseline; gap: 7px; }
.receipt-foot { margin: 18px 0 6px !important; text-align: center; }
.roster-row .actions strong { font-weight: 500; }
.roster-row .actions button { padding: 6px 14px; min-height: 36px; font-size: 13px; }
@media print {
  @page { margin: 14mm; }
  body { background: #fff; }
  body > :not(dialog) { display: none !important; }
  dialog[open] {
    position: static;
    display: block;
    width: 100%;
    max-width: 420px;
    max-height: none;
    margin: 0 auto;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: #fff;
  }
  dialog::backdrop { display: none; }
  .close, .no-print { display: none !important; }
}

/* Front-desk additions: fold-away sections, cancelled sales, single-column class list. */
details.history { margin-top: 26px; }
details.history > summary {
  cursor: pointer;
  font-size: 14px;
  color: var(--brown);
  padding: 8px 0;
  list-style-position: inside;
}
.client-card details.history { margin-top: 12px; }
.struck { text-decoration: line-through; color: #8a7f78; }
.reception-classes { max-width: 860px; }
.heading h1:only-child, .heading div > h1:first-child { margin-top: 0; }

/* 4. Section tabs are one joined control: a soft track holding every choice, the
   current one filled. Clearly buttons, and unlike the separate filter chips below. */
.tabs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(78px, 1fr));
  gap: 4px;
  padding: 5px;
  max-width: 760px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--lift);
}
.tabs button, [dir="rtl"] .tabs button {
  border: 0;
  border-radius: 13px;
  padding: 10px 8px;
  min-height: 46px;
  line-height: 1.2;
  text-align: center;
  white-space: normal;
  color: var(--charcoal);
}
.tabs button.active, [dir="rtl"] .tabs button.active { color: var(--cream); box-shadow: 0 4px 12px rgba(93, 31, 0, 0.18); }
.tabs button:not(.active):not(:disabled):hover { text-decoration: none; background: #ece4da; color: var(--brown); }
@media (max-width: 540px) {
  .tabs { gap: 3px; padding: 4px; border-radius: 16px; }
  .tabs button { font-size: 16px; padding: 8px 4px; border-radius: 12px; }
  [dir="rtl"] .tabs button { font-size: 13px; }
}

/* 6. Reception booking: day tiles, then that day's classes. */
.book-picker { margin-top: 10px; }
.book-picker .week-navigation { margin-top: 4px; }
.book-picker .roster-row .time { min-width: 62px; font-size: 22px; }
.book-picker .roster-row .primary { padding: 8px 22px; min-height: 40px; }
.book-picker .person small { margin-top: 2px; }

/* Client page credits: a compact tile per type instead of one long row per purchase. */
.credit-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-top: 10px; }
.credit-tile {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--cream);
}
.credit-tile span { font-size: 14px; color: var(--charcoal); }
.credit-tile strong { font: 400 34px/1.1 var(--serif); font-variant-numeric: lining-nums; color: var(--brown); }
[dir="rtl"] .credit-tile strong { font-weight: 400; }
.credit-tile small { font-size: 12.5px; color: #5b534e; }
.credit-tile button { margin-top: 10px; padding: 6px 12px; min-height: 36px; font-size: 13px; align-self: flex-start; }
@media (max-width: 540px) {
  .credit-tiles { grid-template-columns: 1fr 1fr; gap: 8px; }
  .credit-tile { padding: 12px; }
  .credit-tile strong { font-size: 30px; }
}

/* Header: logo centred on every screen size; location on one side, language on the other. */
header { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; column-gap: 16px; }
header .logo { grid-column: 2; grid-row: 1; justify-self: center; transform-origin: center; }
[dir="rtl"] header .logo { transform-origin: center; }
header .location { grid-column: 1; grid-row: 1; justify-self: start; margin: 0; }
header #language, header .location + #language { grid-column: 3; grid-row: 1; justify-self: end; margin: 0; }

/* Brand line in the footer. */
footer #footer-brand { margin: 0 0 6px; color: var(--brown); }
.heading h1 { margin-bottom: 8px; }

/* Client greeting: room between the name and the tabs now that no line sits between them. */
.heading { margin-bottom: 26px; }
[dir="rtl"] h1 bdi { font-family: inherit; }

/* My bookings: the next class stands out; everything else is a quiet list under a heading. */
.next-class { border-color: #d9c7b6; padding: 30px; }
.next-class .eyebrow { margin-bottom: 10px; }
.next-class h2 { margin-bottom: 8px; }
.panel.next-class > p.when { font-size: 19px; color: var(--charcoal); margin-bottom: 6px; }
.next-class button { margin-top: 18px; }
h3.list-title { font-size: 22px; margin: 34px 0 6px; }
[dir="rtl"] h3.list-title { font-size: 20px; }
h3.list-title + .roster-row { border-top: 0; }
.empty .primary { margin: 16px 0 0; }
@media (max-width: 540px) {
  .next-class { padding: 22px; }
  .panel.next-class > p.when { font-size: 17px; }
}

/* My details: an open page, not stacked boxes. */
.profile { max-width: 680px; }
.profile-head { display: flex; align-items: center; gap: 18px; margin: 6px 0 30px; }
.profile-head .avatar { width: 68px; height: 68px; flex: none; font: 400 32px/1 var(--serif); color: var(--charcoal); }
[dir="rtl"] .profile-head .avatar { font: 300 28px/1 "Balance Arabic", sans-serif; }
.profile-head h2 { margin: 0 0 2px; }
.profile-section { border-top: 1px solid var(--line); padding: 26px 0; }
.profile-section h3 { font-size: 24px; margin-bottom: 16px; }
.profile-section .fine { margin-top: 14px; }
.profile-password > summary {
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  list-style: none;
  font-size: 15px;
}
.profile-password > summary::-webkit-details-marker { display: none; }
.profile-password > summary .fine { margin: 0; letter-spacing: 0.15em; }
.profile-password > summary .change {
  margin-inline-start: auto;
  border: 1px solid var(--line);
  border-radius: var(--pill);
  padding: 8px 20px;
  font-size: 14px;
}
.profile-password > summary:hover .change { border-color: var(--brown); color: var(--brown); }
.profile-password[open] > summary .change { visibility: hidden; }
.profile-password form { margin-top: 22px; max-width: 420px; }
@media (max-width: 540px) {
  .profile-head .avatar { width: 56px; height: 56px; font-size: 26px; }
}

/* ── Dashboard ───────────────────────────────────────────────────────────────
   Figures first. One measure per chart and one colour (the brand brown) on the card
   surface; values are always written out, so nothing depends on colour alone. */
.dash-period { margin: 0 0 6px; }
.stat-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); grid-auto-flow: column; gap: 12px; }
.stat-tile {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--lift);
}
.stat-tile strong { font: 400 40px/1.05 var(--serif); font-variant-numeric: lining-nums; color: var(--brown); }
[dir="rtl"] .stat-tile strong { font-weight: 400; }
.stat-tile span { font-size: 14px; color: var(--charcoal); }
.stat-tile small { font-size: 12.5px; color: #5b534e; }
.dash-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 38px; align-items: start; margin-top: 6px; }
.dash-split h4:first-child { margin-top: 6px; }
.hero-number { font: 400 58px/1 var(--serif); font-variant-numeric: lining-nums; color: var(--brown); }
.hero-number small { font: 400 15px "Balance Arabic", "Segoe UI", Arial, sans-serif; letter-spacing: 0.06em; color: var(--charcoal); margin-inline-start: 6px; }
.stat-tile strong small, .meter-value small { font: 400 12px "Balance Arabic", "Segoe UI", Arial, sans-serif; color: var(--charcoal); }
.hero-number + .fine small { font-size: inherit; color: inherit; }

.bar-chart { margin: 22px 0 0; }
.bar-top { display: flex; font-size: 12px; color: #5b534e; border-bottom: 1px dashed var(--line); padding-bottom: 3px; }
.bars { display: flex; align-items: flex-end; gap: 2px; height: 150px; border-bottom: 1px solid #cdbfb2; }
.bar { position: relative; flex: 1; height: 100%; display: flex; align-items: flex-end; min-width: 3px; outline: 0; }
.bar i { display: block; width: 100%; background: var(--brown); border-radius: 4px 4px 0 0; }
.bar:hover i, .bar:focus-visible i { background: #8a4a2a; }
.bar:hover::after, .bar:focus-visible::after {
  content: attr(data-tip);
  position: absolute;
  bottom: calc(100% + 6px);
  inset-inline-start: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
  background: var(--charcoal);
  color: #fff;
  font-size: 12px;
  padding: 5px 9px;
  border-radius: 8px;
  z-index: 5;
  pointer-events: none;
}
[dir="rtl"] .bar:hover::after, [dir="rtl"] .bar:focus-visible::after { transform: translateX(50%); }
.bar:first-child:hover::after { transform: none; inset-inline-start: 0; }
.bar:last-child:hover::after { transform: none; inset-inline-start: auto; inset-inline-end: 0; }
.bar-chart figcaption { display: flex; justify-content: space-between; font-size: 12px; color: #5b534e; margin-top: 6px; }

.meter { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(60px, 1fr) auto; align-items: center; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14px; }
.meter:first-of-type { border-top: 0; }
.meter-label small { color: #5b534e; font-size: 12.5px; }
.meter-track { height: 6px; background: #e9dfd4; border-radius: 4px; overflow: hidden; }
.meter-track i { display: block; height: 100%; background: var(--brown); border-radius: 4px; }
.meter-value { font-variant-numeric: tabular-nums lining-nums; text-align: end; min-width: 52px; }
@media (max-width: 800px) {
  .stat-tiles { grid-template-columns: 1fr 1fr; gap: 8px; }
  .stat-tile { padding: 14px; }
  .stat-tile strong { font-size: 32px; }
  .dash-split { grid-template-columns: 1fr; gap: 18px; }
  .hero-number { font-size: 46px; }
  .bars { height: 120px; }
}

footer #footer-place { color: inherit; text-decoration: none; }
footer #footer-place:hover { text-decoration: underline; text-underline-offset: 4px; }

/* Arabic title font restored (it had been removed on a wrong diagnosis; the file covers the
   full Arabic alphabet). Same face as the Balance Studio website's Arabic headings. */
@font-face {
  font-family: "Balance Arabic Display";
  src: url("assets/fonts/arabic-title.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] dialog h2 {
  font-family: "Balance Arabic Display", "Balance Arabic", sans-serif;
  font-weight: 400;
}

/* Photo and video consent: two plain choices on one line. */
.consent label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  margin-inline-end: 28px;
}
.consent input[type="radio"] {
  width: 20px;
  min-height: 20px;
  margin: 0;
}
.fields + label,
.fields + fieldset {
  margin-top: 15px;
}

/* Reception is a desk screen for a computer: blocks side by side, nothing to scroll past. */
body[data-area="reception"] main { max-width: 1680px; padding: 24px 28px 60px; }
.desk { display: grid; grid-template-columns: 330px minmax(0, 1fr) 330px; gap: 20px; align-items: start; }
.desk-col { display: grid; gap: 20px; align-content: start; min-width: 0; }
.desk-block, .desk .callbacks { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: 20px; margin: 0; min-width: 0; }
.desk-block h2 { font-size: 30px; margin-bottom: 4px; }
.desk-block h3, .desk .callbacks h2 { font-size: 21px; margin-bottom: 12px; }
.desk-block h4 { margin: 18px 0 8px; }
.desk .client-search, .desk .client-results { max-width: none; }
.desk .client-search input { min-height: 46px; font-size: 16px; background: var(--cream); }
.desk .client-results { margin: 8px 0 0; }
.desk-block > p:last-child, .desk-block .client-search + .client-results + p { margin-bottom: 0; }
.desk-day { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 8px; text-align: center; margin-bottom: 12px; }
.desk-day small { display: block; margin-top: 2px; }
.desk-day > button { min-width: 40px; min-height: 38px; padding: 6px 10px; color: var(--brown); }
.desk-classes { display: grid; gap: 6px; }
.desk-class { display: grid; grid-template-columns: 54px minmax(0, 1fr) auto; gap: 10px; align-items: center; width: 100%; text-align: start; border-radius: var(--r-sm); padding: 10px 12px; background: var(--cream); }
.desk-class + .desk-class { margin-inline-start: 0; }
.desk-class.active { background: var(--brown); border-color: var(--brown); color: var(--cream); }
.desk-class.active small { color: var(--cream); }
.desk-class.cancelled { opacity: 0.6; }
.desk-time { font-family: var(--serif); font-size: 19px; }
.desk-name small { display: block; font-size: 12px; }
.desk-count { font-size: 13px; }
.desk-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; }
.desk-head .eyebrow { margin-bottom: 6px; }
.desk-more { position: relative; flex: none; }
.desk-more summary { cursor: pointer; list-style: none; border: 1px solid var(--line); border-radius: var(--pill); padding: 8px 16px; font-size: 14px; }
.desk-more summary::-webkit-details-marker { display: none; }
.desk-more[open] button { position: absolute; inset-inline-end: 0; top: calc(100% + 6px); white-space: nowrap; background: var(--cream); z-index: 2; }
.desk .stats { margin: 16px 0; }
.desk .hero-number { margin-bottom: 4px; }
.client-desk { grid-template-columns: 330px minmax(0, 1fr); align-items: stretch; }
.client-desk .client-card { margin-top: 0; }
/* Both sides end at the same line: the shorter one stretches. Nothing scrolls inside a box. */
.client-side { display: flex; flex-direction: column; }
.client-side > .client-card { flex: 1; }
.client-main { display: flex; flex-direction: column; }
.client-tab-body { flex: 1; }
details.show-all { margin-top: 8px; }
.desk-back { margin-bottom: 14px; }
.desk-back button { padding: 6px 14px; min-height: 36px; font-size: 14px; }
.client-main .tabs { margin-bottom: 18px; }
/* Number boxes: one fixed size, the name on one line, the numbers on one line. */
.credit-tiles { grid-template-columns: repeat(var(--tiles, 4), minmax(0, 210px)); justify-content: start; gap: 12px; }
.credit-tiles .credit-tile { padding: 14px; }
.credit-tile { display: grid; grid-template-rows: auto auto 1fr; align-content: start; }
.credit-tile span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.credit-tile button { justify-self: start; align-self: end; }
.desk .stats { grid-template-columns: repeat(3, 150px); width: max-content; max-width: 100%; }
.desk .stats > div { border-inline-end: 1px solid var(--line); }
.desk .stats > div:last-child { border-inline-end: 0; }
/* Her three numbers on the side: one row each, label then number, nothing wrapping. */
.client-side .stats { grid-template-columns: 1fr; width: auto; }
.client-side .stats > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 9px 14px; border-inline-end: 0; border-bottom: 1px solid var(--line); }
.client-side .stats > div:last-child { border-bottom: 0; }
.client-side .stats strong { order: 2; font-size: 24px; }
@media (max-width: 1100px) {
  .desk { grid-template-columns: 300px minmax(0, 1fr); }
  .desk > .desk-col:last-child { grid-column: 1 / -1; }
  .client-desk { grid-template-columns: 1fr; }
}

/* A client's details: a label, then its value, one per line. */
.facts { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 8px 16px; margin: 14px 0 0; font-size: 14px; }
.facts dt { color: #5b534e; }
.facts dd { margin: 0; color: var(--charcoal); overflow-wrap: anywhere; }
.desk-buttons { display: flex; gap: 8px; flex-wrap: nowrap; }
.desk-buttons button { flex: 1; padding: 8px 10px; min-height: 40px; font-size: 14px; white-space: nowrap; }
.desk-buttons button + button { margin-inline-start: 0; }

/* All packages and the main rules, in one wide window. */
dialog.wide { max-width: 1180px; overflow: auto; }
.guide { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; align-items: start; }
.guide h3 { font-size: 20px; margin: 18px 0 10px; }
.guide-group { display: grid; grid-template-columns: repeat(auto-fill, 240px); grid-auto-rows: 1fr; gap: 12px; }
.guide-card { display: grid; gap: 4px; align-content: start; min-height: 176px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--cream); }
.guide-card h4 { margin: 0; font: 400 15px/1.4 "Balance Arabic", "Segoe UI", Arial, sans-serif; text-transform: none; letter-spacing: 0; color: var(--charcoal); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.guide-price { font: 400 26px/1.1 var(--serif); color: var(--brown); }
.guide-card p { margin: 0; font-size: 12.5px; }
.guide-waiting { margin-top: 18px; }
.guide-rules { position: sticky; top: 0; margin-top: 18px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--cream); }
.guide-rules h3 { margin-top: 0; }
.guide-rules ul { margin: 0; padding-inline-start: 18px; display: grid; gap: 8px; font-size: 14px; }

/* Staff fields (reception and its windows) use the cream fill, not white. */
.desk input:not([type="checkbox"]):not([type="radio"]),
.desk select,
.desk textarea,
dialog input:not([type="checkbox"]):not([type="radio"]),
dialog select,
dialog textarea {
  background-color: var(--cream);
}

/* Receipts print on an 80 mm receipt roll (72 mm printable): black only, nothing shrunk. */
@media print {
  @page { margin: 0; }
  html, body { background: #fff !important; }
  dialog[open] { width: 72mm; max-width: 72mm; margin: 0 auto; padding: 4mm 0 8mm; background: #fff; }
  .receipt, .receipt * { color: #000 !important; background: transparent !important; }
  .receipt { font: 10pt/1.35 Arial, Helvetica, sans-serif; }
  .receipt .logo { display: block; text-align: center; margin-bottom: 4mm; }
  .receipt .logo img { width: 42mm; height: auto; filter: brightness(0); }
  .receipt .eyebrow { margin: 0 0 1mm; font-size: 8pt; letter-spacing: 0.12em; text-align: center; }
  .receipt h2 { font: 700 15pt/1.2 Arial, Helvetica, sans-serif; text-align: center; margin: 0; }
  .receipt > .fine { text-align: center; font-size: 9pt; margin-bottom: 3mm; }
  .receipt-line { gap: 3mm; padding: 1.5mm 0; border-top: 1px dashed #000; font-size: 9.5pt; }
  .receipt-line strong { font-weight: 700; }
  .receipt-total { border-top: 2px solid #000; margin-top: 1mm; padding-top: 2mm; font-size: 10pt; }
  .receipt-total .package-price { font: 700 16pt/1.1 Arial, Helvetica, sans-serif; }
  .receipt-foot { font-size: 8.5pt; margin: 4mm 0 0 !important; }
  .receipt .notice { border: 1px solid #000; padding: 2mm; font-weight: 700; text-align: center; }
}

/* Reception search: one large bar across the top of every reception screen; results drop
   down below it. Press / to jump to it, arrows to move, Enter to open. */
.desk-search { display: grid; grid-template-columns: minmax(0, 760px) auto; justify-content: center; align-items: center; gap: 14px; margin: 4px 0 24px; }
.search-bar { position: relative; display: flex; align-items: center; gap: 12px; height: 60px; padding: 0 16px 0 22px; border: 1px solid #c5b5a8; border-radius: var(--pill); background: var(--cream); box-shadow: 0 6px 22px rgba(44, 22, 12, 0.06); transition: border-color 0.15s, box-shadow 0.15s; }
.search-bar:focus-within { border-color: var(--brown); box-shadow: 0 10px 30px rgba(44, 22, 12, 0.12); }
.search-icon { width: 22px; height: 22px; flex: none; fill: none; stroke: var(--brown); stroke-width: 1.6; stroke-linecap: round; }
.search-bar input { flex: 1; min-width: 0; height: 100%; min-height: 0; margin: 0; padding: 0; border: 0; background: transparent !important; font-size: 18px; -webkit-appearance: none; appearance: none; }
.search-bar input:focus { border: 0; box-shadow: none; }
.search-bar input::placeholder { color: #8a7f78; font-family: var(--serif); font-size: 21px; }
.search-bar input::-webkit-search-cancel-button { display: none; }
.search-bar kbd { flex: none; padding: 4px 8px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: #8a7f78; font: 12px/1 Arial, Helvetica, sans-serif; }
.search-results { position: absolute; top: calc(100% + 8px); inset-inline: 0; z-index: 20; display: grid; gap: 2px; padding: 8px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); box-shadow: 0 18px 40px rgba(44, 22, 12, 0.14); }
.search-results:empty, .search-bar:not(:focus-within) .search-results { display: none; }
.search-results button { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 8px 12px; border: 0; border-radius: var(--r-sm); background: transparent; text-align: start; }
.search-results button + button { margin-inline-start: 0; }
.search-results button.active, .search-results button:hover { background: var(--cream); }
.search-results .avatar { width: 36px; height: 36px; font-size: 15px; color: var(--charcoal); }
.result-name { overflow: hidden; color: var(--charcoal); font-size: 16px; text-overflow: ellipsis; white-space: nowrap; }
.result-phone { color: #5b534e; font-size: 13px; }
.search-empty { padding: 10px 12px; }
.search-empty p { margin: 0 0 8px; }
.search-actions { display: flex; gap: 8px; }
.search-actions button { white-space: nowrap; }
.search-actions button + button { margin-inline-start: 0; }

/* Reception home: the class happening now (or next) is the main block; the rest beside it. */
.desk-home { grid-template-columns: minmax(0, 1fr) 360px; }
.desk-main h2 { font-size: 34px; }
.moment { display: inline-block; margin-bottom: 10px; padding: 4px 11px; border-radius: var(--pill); background: var(--line); color: var(--charcoal); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; }
[dir="rtl"] .moment { letter-spacing: 0; }
.moment.now { background: var(--brown); color: var(--cream); }
.moment.next { background: var(--olive); }
.moment.cancelled { border: 1px solid var(--line); background: transparent; }
.desk-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 6px; }
.desk-chips span { padding: 6px 14px; border: 1px solid var(--line); border-radius: var(--pill); background: var(--cream); font-size: 13.5px; }
.desk-chips strong { margin-inline-end: 4px; color: var(--brown); font: 400 17px var(--serif); }
.desk-class.done:not(.active) { opacity: 0.55; }
.desk-class.now:not(.active) { border-color: var(--brown); }
.desk-empty { padding: 60px 20px; color: #5b534e; text-align: center; }
.desk-home { align-items: start; }
.desk-main .empty { border: 0; background: transparent; box-shadow: none; padding: 18px 0 4px; color: #5b534e; }
.desk-classes .desk-class { padding: 8px 12px; }
/* Day headings in her bookings: Today, Tomorrow, then the date. */
.day-label { margin: 16px 0 2px; color: var(--brown); font-size: 13.5px; font-weight: 600; }
.client-tab-body h4 + .day-label { margin-top: 6px; }

/* Reception home day list: the Book tab's week calendar and rows, in the side column. */
.desk-home { grid-template-columns: minmax(0, 1fr) 400px; }
.desk-day-block .week { gap: 6px; margin-bottom: 10px; }
.desk-day-block .week button { padding: 10px 0 8px; }
.desk-day-block .week strong { font-size: 24px; }
.desk-day-block .week-navigation strong { font-size: 20px; }
.day-row { width: 100%; min-height: 0; padding: 13px 10px; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: transparent; text-align: start; color: inherit; }
.day-row + .day-row { margin-inline-start: 0; }
.day-row .time { flex: none; width: 58px; }
.day-row .person { flex: 1; min-width: 0; }
.day-row .person small { display: block; }
.day-row:hover { background: var(--cream); }
.day-row.active { background: var(--cream); color: var(--charcoal); border-color: transparent; box-shadow: inset 0 0 0 1px var(--brown); border-radius: var(--r-sm); }
.day-row.done:not(.active), .day-row.cancelled:not(.active) { opacity: 0.5; }
/* "Back to today" under the week heading: one small pill, never wrapped. */
.week-navigation > div { flex: 1; min-width: 0; }
.week-navigation [data-today] { display: inline-block; width: auto; height: auto; min-width: 0; margin-top: 6px; padding: 4px 14px; min-height: 0; line-height: 1.4; border: 1px solid var(--line); border-radius: var(--pill); color: var(--brown); font-size: 12.5px; text-decoration: none; white-space: nowrap; }
.week-navigation [data-today]:hover { border-color: var(--brown); }
.day-row:hover { border-top-color: var(--line); }

/* Reception dashboard: today's numbers on one row, and the day's to-do list. */
.glance { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 28px; margin: 0 0 20px; padding: 14px 22px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); color: #5b534e; font-size: 14px; }
.glance-title { color: var(--brown); font: 400 13px "Balance Arabic", "Segoe UI", Arial, sans-serif; letter-spacing: 0.12em; text-transform: uppercase; }
[dir="rtl"] .glance-title { letter-spacing: 0; font-size: 14px; }
.glance strong { margin-inline-end: 4px; color: var(--brown); font: 400 22px var(--serif); }
.glance strong small { font-size: 12px; }
.desk-home .desk-block h3 { margin-bottom: 8px; }
.todo-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; min-height: 0; padding: 10px 6px; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: transparent; color: inherit; text-align: start; }
.todo-row + .todo-row { margin-inline-start: 0; }
.todo h3 + .todo-row { border-top: 0; }
.todo-row strong { display: block; color: var(--charcoal); font-size: 14.5px; font-weight: 600; }
.todo-row small { display: block; color: #5b534e; font-size: 12.5px; }
.todo-row::after { content: "›"; flex: none; color: var(--brown); font-size: 20px; }
[dir="rtl"] .todo-row::after { content: "‹"; }
.todo-row:hover { border-top-color: var(--line); background: var(--cream); }
.todo-flag { color: var(--brown); font-weight: 600; }

/* Every staff page: the full desk width, cream fields, tab labels on one line. */
body[data-area="dashboard"] main,
body[data-area="reports"] main,
body[data-area="admin"] main,
body[data-area="health"] main,
body[data-area="studio"] main,
body[data-area="coach"] main { max-width: 1680px; padding: 24px 28px 60px; }
body:not([data-area="client"]):not([data-area=""]) input:not([type="checkbox"]):not([type="radio"]),
body:not([data-area="client"]):not([data-area=""]) select,
body:not([data-area="client"]):not([data-area=""]) textarea { background-color: var(--cream); }
body:not([data-area="client"]):not([data-area=""]) .tabs { width: max-content; max-width: 100%; grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 1fr; }
body:not([data-area="client"]):not([data-area=""]) .tabs button { white-space: nowrap; padding-inline: 12px; }
.page-note { margin: 0 0 16px; }

/* Dashboard: today's numbers on one row, then three columns of equal blocks. */
.dash-top { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.dash-top .glance { flex: 1; margin: 0; }
.dash-top .dash-period { flex: none; margin: 0; }
.dash-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.dash-grid .desk-block h3 { margin-bottom: 12px; }
.dash-grid .stat-tiles { grid-template-columns: 1fr 1fr; grid-auto-flow: row; }
.dash-grid .hero-number { font-size: 48px; }
.dash-grid h4 { margin-top: 18px; }
/* Dashboard number boxes: every label and note on one line. */
.dash-grid .stat-tile { padding: 14px 16px; }
.dash-grid .stat-tile span, .dash-grid .stat-tile small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-grid .stat-tile span { font-size: 13.5px; }
.dash-grid .stat-tiles { grid-auto-rows: 1fr; }
.dash-grid .meter { grid-template-columns: minmax(0, 2.4fr) minmax(36px, 0.6fr) auto; gap: 10px; }
.dash-grid .meter-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-methods { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 14px; margin: 4px 0 14px; }
.dash-methods span { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 6px 0; border-top: 1px solid var(--line); font-size: 13.5px; white-space: nowrap; }
.dash-methods small { color: #5b534e; font-size: 12.5px; }
.dash-methods em { font-style: normal; }
/* Dashboard blocks: body grows, a download button sits at the bottom. */
.dash-grid .desk-block { display: flex; flex-direction: column; }
.dash-grid .block-body { flex: 1; }
.dash-grid .block-foot { margin-top: 16px; }
.dash-grid .block-foot button { padding: 8px 16px; min-height: 0; font-size: 13.5px; }
.dash-grid .up { color: #4f6b3a; font-weight: 600; }
.dash-grid .down { color: #9b3d2a; font-weight: 600; }
.inline-number { color: var(--brown); font: 400 22px var(--serif); margin-inline-end: 4px; }
.dash-grid .roster-row { padding: 9px 0; font-size: 14px; }
.dash-grid .meter { font-size: 13px; }
/* Before launch, and the package flag on her page. */
.glance-closed { margin-inline-start: auto; color: var(--brown); font-weight: 600; }
.recommend { display: inline-block; margin: 4px 0 8px; padding: 5px 12px; border-radius: var(--pill); background: var(--olive); color: var(--charcoal); font-size: 13px; }
#footer-privacy { font-size: 13px; text-decoration: underline; text-underline-offset: 3px; }
.todo-group { margin: 14px 0 2px; color: var(--brown); font-size: 12.5px; font-weight: 600; letter-spacing: 0.04em; }
.todo h3 + .todo-group { margin-top: 2px; }
.todo-group + .todo-row { border-top: 0; }
.todo details.show-all summary { font-size: 13px; }

/* Client tabs on a computer: every label on one line, every tab the same width.
   Phones keep their own compact layout. */
@media (min-width: 900px) {
  body[data-area="client"] .tabs { width: max-content; max-width: 100%; grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 1fr; }
  body[data-area="client"] .tabs button { white-space: nowrap; padding-inline: 16px; }
}


/* ---------- Phones (most clients book from a phone) ---------- */
.phone-only { display: none; }
@media (max-width: 760px) {
  .desk-only { display: none !important; }
  .phone-only { display: inline !important; }
  /* The six tabs: three across, two rows, every label on one line, every tab the same size. */
  body[data-area="client"] main .tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-flow: row; grid-auto-columns: auto; width: auto; max-width: none; gap: 4px; padding: 5px; }
  body[data-area="client"] main .tabs button { min-height: 42px; padding: 8px 2px; font-size: 19px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  [dir="rtl"] body[data-area="client"] main .tabs button, body[data-area="client"][dir="rtl"] main .tabs button { font-size: 14px; }
  body[data-area="client"] h1 { font-size: 34px; margin-bottom: 4px; }
  body[data-area="client"] .heading { margin-bottom: 14px; }
  /* Credits first, as a short summary at the top. */
  .grid { display: flex; flex-direction: column; gap: 14px; }
  .grid > aside { order: -1; display: block; }
  .balance-panel { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 0 14px; margin: 0; padding: 14px 18px; }
  .balance-panel::before { display: none; }
  .balance-panel .eyebrow { grid-column: 1 / -1; margin: 0 0 4px; }
  .balance-panel .big { grid-row: span 2; font-size: 42px; }
  .balance-panel h3 { margin: 0; font-size: 18px; }
  .balance-panel .quiet { margin: 0; font-size: 12px; }
  .balance-panel button { display: none; }
  /* Classes and appointments: one compact row each. */
  .class-row { grid-template-columns: 52px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 14px 0; }
  .class-row h3 { margin: 0 0 2px; font-size: 21px; }
  .class-row p.muted { margin: 0; font-size: 12.5px; }
  .time { font-size: 20px; }
  .time small { font-size: 11px; }
  .class-action { grid-column: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; min-width: 0; text-align: end; }
  .class-action .spots { margin: 0; font-size: 12px; white-space: nowrap; }
  .class-action button { width: auto; min-height: 38px; padding: 8px 18px; font-size: 14px; }
  .class-action .quiet { display: none; }
  .filters button { padding: 6px 12px; font-size: 13px; min-height: 36px; }
  .filters { gap: 6px; margin: 14px 0; }
  /* Credits two across. */
  .cards.credit-cards { grid-template-columns: 1fr 1fr; grid-auto-rows: 1fr; gap: 10px; }
  .cards.credit-cards .panel { margin: 0; padding: 14px; }
  .cards.credit-cards .big { font-size: 34px; }
  .cards.credit-cards h3 { font-size: 17px; margin-bottom: 6px; }
  /* Windows slide up from the bottom of the screen. */
  dialog { width: 100%; max-width: 100%; margin: auto 0 0; border-radius: 22px 22px 0 0; max-height: 88vh; padding: 20px 20px calc(22px + env(safe-area-inset-bottom)); }
  dialog h2 { font-size: 30px; }
}

/* The schedule's second filter row: the kinds inside the chosen group. */
.sub-filters { margin-top: -8px; }
.sub-filters button { padding: 5px 12px; font-size: 13px; min-height: 34px; background: var(--surface); }
.sub-filters button.active { background: var(--charcoal); border-color: var(--charcoal); color: var(--cream); }
.profile-health .health-inner, .profile-health form { margin-top: 12px; border: 0; padding: 0; }
@media (max-width: 760px) {
  /* The groups always fit on one row. */
  .filters.groups { flex-wrap: nowrap; gap: 5px; }
  .filters.groups button { flex: 1 1 auto; padding: 6px 8px; white-space: nowrap; }
}
.profile-health summary .fine { letter-spacing: 0; }


/* ── Coaches' tablet ─────────────────────────────────────────────────────
   Built from the reception panel's pieces (glance strip, desk blocks, day rows, roster rows);
   only what reception does not have is styled here. */
.glance-out { margin-inline-start: auto; min-height: 36px; padding: 6px 16px; font-size: 14px; }
.coach-tabs { margin-bottom: 20px; }
.coach-day { margin: 14px 0 4px; font-size: 13px; font-weight: 400; letter-spacing: 0.08em; text-transform: uppercase; color: #5b534e; }
[dir="rtl"] .coach-day { letter-spacing: 0; font-size: 14px; }
.desk-day-block h3 + .coach-day { margin-top: 0; }
.coach-row { align-items: flex-start; }
.coach-row .avatar { flex: none; }
.coach-row .person strong { display: block; font-weight: 600; }
.coach-row .person small { display: block; color: #5b534e; }
.coach-row .actions { flex: none; width: 190px; justify-content: flex-end; align-items: center; }
.pill.here { background: var(--olive); color: var(--charcoal); }
.coach-notes { margin: 8px 0 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.coach-notes li { padding: 7px 12px; border-inline-start: 3px solid var(--tan); background: var(--cream); border-radius: 0 var(--r-sm) var(--r-sm) 0; font-size: 14px; }
[dir="rtl"] .coach-notes li { border-radius: var(--r-sm) 0 0 var(--r-sm); }
.coach-notes li.health-note { border-inline-start-color: var(--olive); }
.coach-notes small { display: block; margin-top: 2px; font-size: 12px; }
.coach-add-note { margin-top: 6px; min-height: 0; padding: 0; font-size: 13.5px; }
.coach-note-form { margin-top: 8px; display: grid; gap: 8px; }
.coach-note-form textarea { width: 100%; min-height: 60px; }
.coach-note-form .actions { display: flex; gap: 8px; }
.coach-note-form .actions button { padding: 6px 14px; min-height: 36px; font-size: 13px; }
.coach-dash { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
@media (max-width: 1024px) {
  .coach-dash { grid-template-columns: 1fr; }
  /* A tablet held upright: her classes first, then the chosen class, full width. */
  body[data-area="coach"] .desk-home { grid-template-columns: 1fr; }
  body[data-area="coach"] .desk-home > .desk-col:last-child { order: -1; grid-column: auto; }
}

/* ── End of day ─────────────────────────────────────────────────────────── */
.desk-block > .desk-head h3 { margin-bottom: 0; }
.desk-block > .desk-head { align-items: center; margin-bottom: 8px; }
.day-open { min-height: 36px; padding: 6px 16px; font-size: 14px; }
.day-step { min-height: 32px; min-width: 36px; padding: 2px 10px; font-size: 14px; color: var(--brown); }
.day-name { font: 400 17px "Balance Arabic", "Segoe UI", Arial, sans-serif !important; color: var(--charcoal) !important; }
.day-total { font-weight: 600; }
.day-total strong { font: 400 26px var(--serif); color: var(--brown); }
.day-figure { display: grid; justify-items: end; text-align: end; gap: 2px; }
.day-ok { color: #4d5527; font-size: 13px; }
.day-off { color: var(--brown); font-size: 13px; font-weight: 600; }
.day-live { margin: -4px 0 12px; }
.day-note { margin: 10px 0 0; padding: 8px 12px; border-inline-start: 3px solid var(--tan); background: var(--cream); }
.day-closed button { margin-top: 14px; }
#day-close-form label { display: grid; gap: 6px; margin-bottom: 8px; }
#day-close-form input, #day-close-form textarea { width: 100%; }
.day-view .roster-row span small { display: block; }

/* ── Reports ────────────────────────────────────────────────────────────── */
.report-top .tabs { margin: 0; }
.report-top .glance { align-items: center; }
.report-grid .roster-row strong { font-weight: 500; }
.report-grid h4 { margin: 16px 0 4px; }
.report-grid .roster-row span small { display: block; }

/* Coach pay: one row per coach, numbers in aligned columns. */
.report-wide { grid-column: 1 / -1; }
.pay-table { display: grid; margin-top: 8px; }
.pay-row { display: grid; grid-template-columns: minmax(140px, 2fr) repeat(5, minmax(0, 1fr)); gap: 12px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.pay-row span:not(:first-child) { text-align: end; font-variant-numeric: tabular-nums; }
.pay-head { border-top: 0; padding-top: 4px; font-size: 12.5px; color: #5b534e; }
@media (max-width: 800px) {
  .pay-table { overflow-x: auto; }
  .pay-row { min-width: 620px; }
}

/* Places left: quiet in the grey line; brown only when a class is nearly full. */
.class-row .few { color: var(--brown); font-weight: 600; }
.class-action { align-self: center; }
.class-row .places { display: block; margin-top: 2px; }

/* Class details: the facts as aligned rows, then a short "good to know" list. */
.detail-about { margin: 6px 0 0; color: #5b534e; }
.detail-facts { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0 16px; margin: 18px 0 0; border-top: 1px solid var(--line); }
.detail-facts dt, .detail-facts dd { margin: 0; padding: 11px 0; border-bottom: 1px solid var(--line); }
.detail-facts dt { color: #5b534e; font-size: 13.5px; }
.detail-facts dd { text-align: end; font-weight: 500; }
.detail-notes { margin: 16px 0 4px; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 14px; color: #5b534e; }
.detail-notes li { position: relative; padding-inline-start: 16px; }
.detail-notes li::before { content: ""; position: absolute; inset-inline-start: 0; top: 0.6em; width: 6px; height: 6px; border-radius: 50%; background: var(--olive); }

/* Schedule time column: the time, then the length quietly underneath, never touching the class name. */
.time small { color: #6f6660; font-weight: 300; white-space: nowrap; letter-spacing: 0; }
@media (max-width: 540px) {
  .class-row { grid-template-columns: 62px minmax(0, 1fr) auto; gap: 12px; }
  .time small { font-size: 11.5px; margin-top: 3px; }
}
/* Facts: one unbroken line per row, and quieter answers. */
.detail-facts { column-gap: 0; }
.detail-facts dt { padding-inline-end: 16px; font-size: 13px; }
.detail-facts dd, [dir="rtl"] .detail-facts dd { font-size: 14px; font-weight: 400; color: var(--charcoal); }

/* Paying online by bank transfer. */
.package button[data-bank-buy] { margin-top: 14px; width: 100%; }
.transfer-note { margin: 14px 0 0; font-size: 13px; color: var(--brown); }
.transfers { margin: 4px 0 18px; }
.transfer-to { margin: 18px 0 6px; font-size: 15px; }
.bank-details { white-space: pre-line; margin: 0 0 16px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r-sm); background: #fffdf9; font-size: 14px; }
.fields label.wide { grid-column: 1 / -1; }

/* Dashboard on a phone (the partner checks it there): one column, today's numbers in a
   neat two-by-two, the period buttons on their own line. Tablets get two columns. */
@media (max-width: 1100px) {
  .dash-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 899px) {
  .dash-top { flex-direction: column; align-items: stretch; gap: 12px; }
  .dash-top .glance { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; padding: 14px 18px; }
  .dash-top .glance-title { grid-column: 1 / -1; }
  .dash-top .dash-period { display: flex; gap: 8px; }
  .dash-top .dash-period button { flex: 1; }
  .dash-grid { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .dash-grid .hero-number { font-size: 44px; }
  .dash-grid .meter-label { white-space: normal; }
  .dash-methods { grid-template-columns: minmax(0, 1fr); }
  .dash-grid .stat-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dash-grid .stat-tile { min-width: 0; padding: 12px 14px; }
  .dash-grid .stat-tile span, .dash-grid .stat-tile small { white-space: normal; }
  /* Staff sections in one swipeable line instead of wrapping onto a second row. */
  #areas { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  #areas::-webkit-scrollbar { display: none; }
  #areas button { flex: none; }
}
/* The narrowest phones: the English tab names step down so none is cut short. */
@media (max-width: 359px) {
  body[data-area="client"] main .tabs button { font-size: 17px; }
}

/* Reception on an iPad. Upright: one full-width column, today's classes first. Sideways:
   the class list beside a narrower side column, both using the whole screen. */
@media (max-width: 899px) {
  .desk-home { grid-template-columns: minmax(0, 1fr); }
}
@media (min-width: 900px) and (max-width: 1100px) {
  .desk-home { grid-template-columns: minmax(0, 1fr) 340px; }
  .desk-home > .desk-col:last-child { grid-column: auto; }
}
/* Touch screens (iPad and phones): no keyboard hint; fields at 16px so Safari does not zoom in
   when one is tapped; small arrows large enough for a finger. */
@media (hover: none), (max-width: 1180px) {
  .search-bar kbd { display: none; }
  input:not([type="checkbox"]):not([type="radio"]), select, textarea { font-size: 16px !important; }
  .day-top button, .desk-day > button { min-width: 44px; min-height: 44px; }
}
/* A client's page on an iPad: her three numbers side by side, not a tall list. */
@media (min-width: 541px) and (max-width: 1100px) {
  .client-side .stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .client-side .stats > div { border-bottom: 0; border-inline-end: 1px solid var(--line); }
  .client-side .stats > div:last-child { border-inline-end: 0; }
}
/* The packages sheet is shown to clients on the iPad: bigger type, cards filling the width,
   and when upright the rules underneath. */
@media (max-width: 1180px) {
  .guide-group { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
  .guide-card { min-height: 0; padding: 16px 18px; gap: 6px; }
  .guide-card h4 { font-size: 17px; white-space: normal; }
  .guide-price { font-size: 30px; }
  .guide-card p { font-size: 14px; }
  .guide-rules ul { font-size: 15px; }
}
@media (max-width: 899px) {
  .guide { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .guide-rules { position: static; }
}
/* Check-in on an iPad: the client's name on its own line, her buttons in a row beneath,
   each large enough for a finger. */
@media (max-width: 1180px) {
  .desk-main .roster-row { flex-wrap: wrap; row-gap: 10px; }
  .desk-main .roster-row .person { flex: 1 1 0; min-width: 60%; }
  .desk-main .roster-row .actions { flex: 1 1 100%; flex-wrap: wrap; justify-content: flex-start; gap: 8px; }
  .desk-main .roster-row .actions button { min-height: 44px; margin: 0; }
}

/* Reception home: both columns end level, and today's sales runs the whole width beneath
   them, so no empty corner is left. The calendar column has room to breathe. */
.desk-reception { align-items: stretch; }
.desk-reception > .desk-col { display: flex; flex-direction: column; }
.desk-reception > .desk-col > :last-child { flex: 1; }
.desk-wide { margin-top: 20px; }
.desk-reception .desk-day-block { padding: 24px; }
.desk-reception .desk-day-block .week-navigation { margin-bottom: 16px; }
.desk-reception .desk-day-block .week { gap: 10px; margin-bottom: 16px; }
.desk-reception .desk-day-block .week button { padding: 12px 0 10px; }
@media (min-width: 1101px) {
  .desk-reception { grid-template-columns: minmax(0, 1fr) 470px; }
}
@media (min-width: 900px) and (max-width: 1100px) {
  .desk-reception { grid-template-columns: minmax(0, 1fr) 390px; }
  .desk-reception .desk-day-block .week { gap: 6px; }
}

/* Packages sheet: the on-request packages stay folded until a client asks. */
.guide-request { margin-top: 22px; padding-top: 14px; border-top: 1px solid var(--line); }
.guide-request summary { cursor: pointer; min-height: 40px; color: var(--brown); font: 400 20px var(--serif); }
[dir="rtl"] .guide-request summary { font-family: inherit; }

/* Nothing changes colour when the mouse passes over it: every control looks the same as at rest. */
button.primary:not(:disabled):hover, button.active:not(:disabled):hover,
.tabs button.active:not(:disabled):hover, .filters button.active:not(:disabled):hover, .week button.active:not(:disabled):hover { background: var(--brown); color: #f8f5ef; border-color: var(--brown); }
button:not(.primary):not(.active):not(:disabled):hover { background: transparent; color: var(--charcoal); border-color: var(--line); text-decoration: none; }
.week button:not(.active):not(:disabled):hover { background: var(--surface); color: var(--charcoal); border-color: var(--line); box-shadow: none; }
.week-navigation button:not(:disabled):hover, #language:not(:disabled):hover, nav button:not(.active):not(:disabled):hover, button.link:not(:disabled):hover { color: var(--brown); }
#language:not(:disabled):hover { border-color: var(--brown); }
.tabs button:not(.active):not(:disabled):hover { background: transparent; color: var(--charcoal); text-decoration: none; }
.day-row:not(.active):not(:disabled):hover, .todo-row:not(:disabled):hover, .search-results button:not(.active):not(:disabled):hover { background: transparent; color: var(--charcoal); border-color: var(--line); }
.day-row.active:not(:disabled):hover { background: var(--cream); color: var(--charcoal); border-color: transparent; }

/* The client's start: her next class and her credits, two equal boxes side by side. */
.home-hero { margin: 0 0 12px; padding: 26px 30px; overflow: hidden; border: 1px solid #d9c7b6; border-radius: var(--r-md); background: transparent; color: var(--charcoal); }
.home-label { margin: 0 0 8px; font-size: 13.5px; color: #5b534e; }
.home-hero h2, [dir="rtl"] .home-hero h2 { margin: 0; color: var(--brown); font-size: clamp(32px, 4.4vw, 46px); line-height: 1.15; }
.home-line { margin: 8px 0 18px; color: var(--charcoal); font-size: 15px; line-height: 1.55; }
.home-hero button.primary, .home-hero button.primary:not(:disabled):hover, .home-hero button.primary:not(:disabled):active { width: auto; background: var(--brown); border-color: var(--brown); color: var(--cream); }
.client-schedule { scroll-margin-top: 12px; }
body[data-area="client"] .client-schedule .class-row { grid-template-columns: 84px minmax(0, 1fr) auto; }

/* One dot per place; filled when taken. */
.seats { display: inline-flex; flex-wrap: wrap; gap: 4px; vertical-align: middle; }
.seats i { width: 9px; height: 9px; border: 1px solid #a4876f; border-radius: 50%; background: transparent; }
.seats i.taken { border-color: var(--brown); background: var(--brown); }
.class-row .places { display: flex; align-items: center; gap: 8px; margin-top: 6px; }
.detail-facts .seats { margin-inline-end: 8px; }
@media (max-width: 540px) {
  .home-hero { padding: 22px 20px; }
  .home-line { margin-bottom: 14px; font-size: 14px; }
  body[data-area="client"] .client-schedule .class-row { grid-template-columns: 62px minmax(0, 1fr) auto; }
  .seats { gap: 3px; }
  .seats i { width: 8px; height: 8px; }
}
.seats { flex: none; flex-wrap: nowrap; }
@media (max-width: 540px) {
  [dir="rtl"] .client-schedule .week-navigation strong { font-size: 18px; white-space: nowrap; }
}

/* A waitlist member sees she is a founding member. */
.founding-mark { display: flex; align-items: center; gap: 8px; margin: -2px 0 14px; color: #5b534e; font-size: 13.5px; }
.founding-mark i { width: 8px; height: 8px; border-radius: 50%; background: var(--olive); }

/* The start card on class day: a second, quieter step. */
.home-hero button.home-form, .home-hero button.home-form:not(:disabled):not(.primary):not(.active):hover { display: block; width: auto; min-height: 0; margin-top: 12px; padding: 0 0 2px; border: 0; border-bottom: 1px solid var(--brown); border-radius: 0; background: transparent; color: var(--brown); font-size: 14px; }

/* Free-cancellation countdown: a thin bar that runs down. */

/* The Reformer room: tap a reformer to choose it. */
.room { margin: 18px auto 8px; max-width: 320px; }
.room-title { margin-bottom: 10px; font-size: 14px; text-align: center; color: var(--charcoal); }
.room-coach { width: 34%; margin: 0 auto 12px; padding: 7px 0; border-radius: 8px; background: var(--olive); color: var(--charcoal); font-size: 12.5px; text-align: center; }
.room-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.seat, .seat:not(:disabled):not(.primary):not(.active):hover { position: relative; display: grid; place-items: center; width: 100%; min-height: 0; aspect-ratio: 3 / 4; padding: 0; border: 1.5px solid #a4876f; border-radius: 12px; background: transparent; color: var(--brown); font-size: 15px; cursor: pointer; opacity: 1; }
.seat i { position: absolute; top: 12%; inset-inline: 22%; height: 38%; border-radius: 7px; background: #efe7dc; }
.seat span { margin-top: 44%; }
.seat.taken, .seat.taken:disabled { border-color: var(--brown); background: var(--brown); color: var(--cream); cursor: default; opacity: 1; }
.seat.taken i { background: #7a3a1c; }
.seat.free:disabled { cursor: default; }
.seat.chosen, .seat.chosen:not(:disabled):not(.primary):not(.active):hover, .seat.mine, .seat.mine:disabled { border-color: var(--olive); background: var(--olive); color: var(--charcoal); opacity: 1; }
.seat.chosen i, .seat.mine i { background: #d3d3a9; }
.seat span small { display: block; max-width: 84px; margin-top: 1px; overflow: hidden; color: inherit; font-size: 11.5px; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.seat.taken:not(:disabled), .seat.taken:not(:disabled):not(.primary):not(.active):hover { border-color: var(--brown); background: var(--brown); color: var(--cream); cursor: pointer; }
.room-desk { margin-top: 14px; }
.room-key { display: flex; justify-content: center; gap: 16px; margin: 10px 0 0; font-size: 12.5px; color: #5b534e; }
.room-key span { display: inline-flex; align-items: center; gap: 6px; }
.room-key i { width: 10px; height: 10px; border-radius: 3px; }
.room-key i.free { border: 1px solid #a4876f; }
.room-key i.taken { background: var(--brown); }
.room-key i.mine { background: var(--olive); }

/* Reception and coaches: who is new, who has a health note, at a glance. */
.who-dot { display: inline-block; width: 9px; height: 9px; margin-inline-start: 7px; border-radius: 50%; vertical-align: middle; }
.who-dot.first { background: var(--olive); }
.who-dot.health { background: var(--brown); }
.who-legend { display: flex; gap: 16px; margin: 12px 0 0; font-size: 12.5px; color: #5b534e; }
.who-legend .who-dot { margin-inline: 0 6px; }

/* Dashboard week map. */
.dash-wide { grid-column: 1 / -1; }
.heat { display: grid; grid-template-columns: 46px repeat(7, minmax(0, 1fr)); gap: 3px; font-size: 12px; }
.heat b { font-weight: 400; color: #5b534e; text-align: center; padding-bottom: 3px; }
.heat .heat-time { align-self: center; padding: 0; text-align: start; font-variant-numeric: tabular-nums; }
.heat-cell { display: grid; place-items: center; min-height: 30px; border-radius: 4px; font-size: 11px; color: var(--charcoal); }
.heat-cell.none { background: transparent; }
.heat-cell.l0 { background: #f0e8dc; color: #8a7a6b; }
.heat-cell.l1 { background: #ecd9bb; }
.heat-cell.l2 { background: #d7995a; }
.heat-cell.l3 { background: #8e4a22; color: var(--cream); }
.heat-cell.l4 { background: var(--brown); color: var(--cream); }
.heat-key { margin: 10px 0 0; font-size: 12.5px; color: #5b534e; }
@media (max-width: 540px) {
  .heat { grid-template-columns: 40px repeat(7, minmax(0, 1fr)); gap: 2px; font-size: 11px; }
  .heat-cell { min-height: 28px; font-size: 10.5px; }
}

/* Welcome: a small architectural arch behind the identity, with an open compact form. */
body[data-gate="1"] { background: var(--cream); }
body[data-gate="1"] .prototype, body[data-gate="1"] #areas, body[data-gate="1"] > footer, body[data-gate="1"] .location { display: none; }
body[data-gate="1"] header { position: relative; z-index: 2; display: flex; align-items: center; justify-content: center; width: 100%; max-width: none; height: 100px; margin: 0; padding: 24px; border: 0; background: transparent; }
body[data-gate="1"] header #language { position: absolute; inset-block-start: 28px; inset-inline-end: 24px; display: flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; margin: 0; padding: 8px; border: 0; color: var(--brown); font-size: 13px; }
body[data-gate="1"] header .logo { margin: 0; transform: none; }
body[data-gate="1"] header .logo img { display: block; width: 148px; height: auto; }
body[data-gate="1"] main { position: relative; display: block; isolation: isolate; width: min(440px, calc(100% - 48px)); max-width: none; min-height: 0; margin: 0 auto; padding: 0; border-radius: 0; background: transparent; animation: none; }
body[data-gate="1"] main::before { content: ""; position: absolute; z-index: -1; top: -76px; left: 50%; width: 210px; height: 168px; transform: translateX(-50%); border: 1px solid #d9cbb9; border-radius: 110px 110px 0 0; border-bottom: 0; background: #f0e9de; pointer-events: none; -webkit-mask-image: linear-gradient(#000 45%, transparent); mask-image: linear-gradient(#000 45%, transparent); }
@keyframes gate-arch { from { opacity: 0; } to { opacity: 1; } }
.gate { position: relative; width: 100%; padding: 28px 0 24px; }
.gate-inner { display: flex; flex-direction: column; width: 100%; min-width: 0; max-width: none; }
.gate-label { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 0 0 12px; color: var(--brown); font-size: 12px; letter-spacing: 0.18em; text-transform: uppercase; }
.gate-label::before, .gate-label::after { content: ""; width: 26px; height: 1px; background: var(--tan); }
[dir="rtl"] .gate-label { font-size: 14px; letter-spacing: 0; }
.gate h1 { margin: 0 0 30px; color: var(--brown); font-size: 42px; font-weight: 300; line-height: 1.12; letter-spacing: -0.025em; text-align: center; }
.gate h1 em { display: inline; white-space: nowrap; }
[dir="rtl"] .gate h1 { font-size: 34px; line-height: 1.45; letter-spacing: 0; }
[dir="rtl"] .gate h1 em { font-style: normal; }
.gate form { display: grid; gap: 18px; margin: 0; }
.gate form label { display: block; margin: 0; color: #5b534e; font-size: 13px; font-weight: 400; }
.gate form input:not([type="radio"]):not([type="checkbox"]), .gate form select { display: block; width: 100%; min-height: 46px; margin: 0; padding: 10px 0; border: 0; border-bottom: 1px solid #b48e6f; border-radius: 0; background: transparent; color: var(--charcoal); font-size: 16px; }
.gate form input:focus, .gate form select:focus { outline: 0; border-bottom-color: var(--brown); box-shadow: 0 1px 0 var(--brown); }
.gate form input:-webkit-autofill { -webkit-box-shadow: 0 0 0 40px var(--cream) inset; -webkit-text-fill-color: var(--charcoal); }
.gate form input::placeholder { color: #a49688; }
.gate form .fine { margin: 0; }
.gate form fieldset { min-width: 0; margin: 0; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.gate form fieldset legend { padding: 0; color: #5b534e; font-size: 13px; }
.gate form .consent label { display: inline-flex; margin-block-start: 8px; margin-inline-end: 28px; }
.gate-submit, .gate-submit:not(:disabled):hover, .gate-submit:not(:disabled):active { display: flex; align-items: center; justify-content: space-between; width: 100%; min-height: 56px; margin-block-start: 6px; padding: 16px 24px; border: 1px solid var(--brown); border-radius: 0; background: var(--brown); color: var(--cream); font-size: 12.5px; font-weight: 400; letter-spacing: 0.16em; text-transform: uppercase; }
[dir="rtl"] .gate-submit, [dir="rtl"] .gate-submit:not(:disabled):hover, [dir="rtl"] .gate-submit:not(:disabled):active { font-size: 15px; letter-spacing: 0; }
.gate-submit::after { content: "→"; font-size: 18px; line-height: 1; letter-spacing: 0; }
[dir="rtl"] .gate-submit::after { content: "←"; }
.gate form .form-error { margin: 0; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; color: #7c2210; font-size: 14px; text-align: center; }
.gate-link, .gate-link:not(:disabled):hover, .gate-link:not(:disabled):active { display: inline-block; min-height: 0; margin-block: -10px; padding: 10px 0; border: 0; border-radius: 0; background: transparent; color: var(--brown); font-size: 14px; font-weight: 400; text-decoration: underline 1px #b48e6f; text-underline-offset: 5px; }
.gate-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 24px; margin-block-start: 18px; }
.gate-new { margin: 18px 0 0; padding-block-start: 16px; border-top: 1px solid var(--line); color: #5b534e; font-size: 14px; text-align: center; }
.gate-new .gate-link { margin-inline-start: 6px; }
.gate-fine { margin: 8px 0 0; color: #6b625b; font-size: 12.5px; line-height: 1.55; text-align: center; }
.gate-foot { margin: 28px 0 0; padding-block-start: 18px; border-top: 1px solid var(--line); color: #6b625b; font-size: 12px; line-height: 1.7; text-align: center; }
.gate-foot a { color: inherit; }

/* The arch belongs to the welcome, not around the entire form. */
body[data-gate="1"] .gate-link { min-height: 44px; margin-block: 0; padding-block: 10px; }
body[data-gate="1"] .gate-links { margin-block-start: 8px; }
body[data-gate="1"] .gate-new { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; column-gap: 6px; margin-block-start: 8px; padding-block-start: 10px; }
body[data-gate="1"] .gate-fine { margin-block-start: 6px; }
body[data-gate="1"] .gate-submit { min-height: 52px; border-radius: 4px; }
body[data-gate="1"] #language { transform: none; }
@media (min-width: 900px) {
  body[data-gate="1"] header { height: 136px; padding-block: 36px; }
  body[data-gate="1"] main { margin-block-start: 16px; }
  body[data-gate="1"] main::before { width: 260px; height: 202px; top: -104px; border-radius: 140px 140px 0 0; }
}
@media (max-width: 599px) {
  body[data-gate="1"] header .logo img { width: 132px; }
  body[data-gate="1"] header #language { inset-inline-end: 12px; }
  .gate h1 { font-size: 36px; margin-block-end: 26px; }
  [dir="rtl"] .gate h1 { font-size: 29px; }
  .gate form { gap: 16px; }
}
@media (max-width: 359px) {
  body[data-gate="1"] main { width: calc(100% - 40px); }
  .gate h1 { font-size: 32px; }
  [dir="rtl"] .gate h1 { font-size: 27px; }
}

/* A booked class: its row's button says so, olive like "your place" in the room, and sits where every View button sits. */
.class-action .booked-button, .class-action .booked-button:not(:disabled):not(.primary):not(.active):hover, .class-action .booked-button:not(:disabled):active { border: 1px solid var(--olive); background: var(--olive); color: var(--charcoal); }
@media (max-width: 760px) {
  .class-action .booked-button, .class-action .booked-button:not(:disabled):not(.primary):not(.active):hover, .class-action .booked-button:not(:disabled):active { width: 71px; padding-inline: 4px; }
}

/* The client's four sections: more room between the words. Each word takes its own width and the space is shared evenly. */
@media (min-width: 900px) {
  body[data-area="client"] main .tabs { grid-auto-columns: auto; }
  body[data-area="client"] main .tabs button { padding-inline: 30px; }
}
@media (max-width: 760px) {
  body[data-area="client"] main .tabs { display: flex; justify-content: space-between; gap: 0; }
  body[data-area="client"] main .tabs button { flex: 0 0 auto; padding-inline: 9px; overflow: visible; }
}

/* My bookings: the next class as a pass, in the same brown as the home card. */
.pass { margin: 0 0 22px; padding: 28px 30px; border-radius: var(--r-md); background: var(--brown); color: var(--cream); }
.pass-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.pass-label { margin: 0 0 8px; color: #e7d3b4; font-size: 13.5px; }
.pass h2, [dir="rtl"] .pass h2 { margin: 0; color: var(--cream); font-size: clamp(32px, 4.4vw, 46px); line-height: 1.12; }
.pass-room, .pass-room:not(:disabled):not(.primary):not(.active):hover, .pass-room:not(:disabled):active { flex: none; display: block; width: 84px; min-height: 0; margin: 0; padding: 0; border: 0; border-radius: 0; background: transparent; cursor: pointer; }
.pass-room .pass-coach { display: block; width: 38%; height: 7px; margin: 0 auto 6px; border-radius: 3px; background: #e7d3b4; }
.pass-room span { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
.pass-room span i { aspect-ratio: 3 / 4; border: 1px solid rgba(248, 245, 239, 0.5); border-radius: 5px; }
.pass-room span i.taken { border-color: transparent; background: rgba(248, 245, 239, 0.28); }
.pass-room span i.mine { border-color: var(--olive); background: var(--olive); }
.pass-facts { display: grid; grid-template-columns: repeat(3, auto); justify-content: space-between; gap: 12px; margin: 22px 0 0; padding: 16px 0; border-block: 1px solid rgba(248, 245, 239, 0.26); }
.pass-facts div { min-width: 0; }
.pass-facts dt { margin: 0 0 3px; color: #e7d3b4; font-size: 12.5px; }
.pass-facts dd { margin: 0; color: var(--cream); font: 400 25px/1.15 var(--serif); font-variant-numeric: lining-nums; white-space: nowrap; }
[dir="rtl"] .pass-facts dd { font-family: "Balance Arabic", sans-serif; font-size: 19px; }
.pass-actions { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 20px; }
.pass-actions button.primary, .pass-actions button.primary:not(:disabled):hover, .pass-actions button.primary:not(:disabled):active { width: auto; margin: 0; background: var(--cream); border-color: var(--cream); color: var(--brown); }
.pass-cancel, .pass-cancel:not(:disabled):not(.primary):not(.active):hover, .pass-cancel:not(:disabled):active { width: auto; min-height: 44px; margin: 0; padding: 0; border: 0; border-radius: 0; background: transparent; color: var(--cream); font-size: 14px; text-decoration: underline 1px rgba(248, 245, 239, 0.6); text-underline-offset: 5px; }
@media (max-width: 540px) {
  .pass { padding: 22px 20px; }
  .pass-room, .pass-room:not(:disabled):not(.primary):not(.active):hover, .pass-room:not(:disabled):active { width: 66px; }
  .pass-room span { gap: 4px; }
  .pass-room span i { border-radius: 4px; }
  .pass-facts dd { font-size: 21px; }
  [dir="rtl"] .pass-facts dd { font-size: 16px; }
}

/* The free-cancellation deadline: a plain date and time, then what happens after it. */
.cancel-left { margin: 14px 0; }
.cancel-left strong { display: block; font-size: 15px; font-weight: 500; color: var(--charcoal); }
.cancel-left small { display: block; margin-top: 2px; font-size: 12.5px; color: #5b534e; }
.pass .cancel-left { margin: 14px 0 0; }
.pass .cancel-left strong { color: var(--cream); }
.pass .cancel-left small { color: #e7d3b4; }

/* Also coming up, Cancelled and Past classes: a date tile from the pass, then the class. */
.stub { display: grid; grid-template-columns: 62px minmax(0, 1fr) auto; align-items: center; gap: 14px; margin: 0 0 10px; padding: 10px; padding-inline-end: 16px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); }
.stub-date { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 66px; border-radius: 10px; background: var(--brown); color: var(--cream); }
.stub-date strong { font: 400 28px/1 var(--serif); font-variant-numeric: lining-nums; }
.stub-date span { margin-top: 3px; color: #e7d3b4; font-size: 11.5px; line-height: 1.2; }
.stub-body { min-width: 0; }
.stub h3, [dir="rtl"] .stub h3, [dir="rtl"] .panel .stub h3 { margin: 0 0 2px; color: var(--brown); font-size: 22px; line-height: 1.2; }
[dir="rtl"] .stub h3 { font-size: 19px; line-height: 1.35; }
.stub p, .panel .stub p { margin: 0; color: #5b534e; font-size: 13px; }
.stub-end { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
.stub-end button.primary { width: auto; min-height: 36px; margin: 0; padding: 6px 18px; font-size: 13.5px; }
.stub-cancel, .stub-cancel:not(:disabled):not(.primary):not(.active):hover, .stub-cancel:not(:disabled):active { width: auto; min-height: 0; margin: 0; padding: 2px 0; border: 0; border-radius: 0; background: transparent; color: var(--brown); font-size: 13px; text-decoration: underline 1px #b48e6f; text-underline-offset: 4px; }
.stub-status { padding: 4px 12px; border: 1px solid #d9c7b6; border-radius: var(--pill); color: #5b534e; font-size: 12px; white-space: nowrap; }
.stub-status.here { border-color: var(--olive); background: var(--olive); color: var(--charcoal); }
.stub.faded .stub-date { background: transparent; box-shadow: inset 0 0 0 1px #cdb39a; color: var(--brown); }
.stub.faded .stub-date span { color: #5b534e; }
.stub.faded h3, [dir="rtl"] .stub.faded h3 { color: #5b534e; }
.history .stub:first-of-type { margin-top: 10px; }
@media (max-width: 540px) {
  .stub { grid-template-columns: 54px minmax(0, 1fr) auto; gap: 11px; padding: 8px; padding-inline-end: 12px; }
  .stub-date { min-height: 60px; }
  .stub-date strong { font-size: 24px; }
  .stub h3, [dir="rtl"] .stub h3, [dir="rtl"] .panel .stub h3 { font-size: 19px; }
  [dir="rtl"] .stub h3 { font-size: 16px; }
}

/* Every text field the same height on every device. */
input:not([type="checkbox"]):not([type="radio"]), select { min-height: 46px; padding-block: 10px; line-height: 1.25; }

/* The photo question: a label and two choices, without a box around them. */
fieldset.consent { margin: 4px 0 18px; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
fieldset.consent legend { margin-bottom: 8px; padding: 0; font-size: 13.5px; }

/* A package: what it is, then the price and Buy on one line, at the same height in every card. */
.package .package-foot { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: auto; padding-top: 14px; border-top: 1px solid var(--line); }
.package > p.fine { margin-bottom: 16px; }
.package .package-foot .package-price { margin: 0; padding: 0; }
.package .package-foot p.fine { margin: 4px 0 0; font-size: 12px; }
.package .package-foot button[data-bank-buy] { flex: none; width: auto; margin: 0; }
.package .package-foot .transfer-note { flex: 0 1 50%; margin: 0; font-size: 12.5px; line-height: 1.4; text-align: end; }
@media (max-width: 540px) {
  .panel.package { padding: 20px; }
  .panel.package h3 { font-size: 26px; }
  .package .package-foot .package-price { font-size: 28px; }
}

/* One page edge: the logo line, the section bar and the content all start and end at the same place. */
body { --gutter: clamp(20px, 3.6vw, 72px); --page: 1680px; font-variant-numeric: lining-nums; }
body[data-area="client"] { --page: 1320px; }
body:not([data-gate="1"]) header, body:not([data-gate="1"]) nav#areas { width: calc(100% - 2 * var(--gutter)); max-width: calc(var(--page) - 2 * var(--gutter)); margin-inline: auto; padding-inline: 0; }
body:not([data-gate="1"]) main { max-width: var(--page); padding-inline: var(--gutter); }

/* Field text is regular weight, whatever the label around it. */
input, select, textarea { font-weight: 400; }

/* The search row at reception: search and its two buttons one height, edge to edge. */
.desk-search { grid-template-columns: minmax(0, 1fr) auto; justify-content: stretch; }
.search-bar { height: 46px; padding: 0; padding-inline: 18px 14px; }
.search-bar input:not([type="checkbox"]):not([type="radio"]) { min-height: 0; padding-block: 0; font-size: 16px; }
.search-bar input::placeholder { font-family: inherit; font-size: 15px; }
.search-actions button { min-height: 46px; }

/* Round arrows are one size. */
.week-navigation button, [data-report-shift] { width: 40px; min-width: 40px; height: 40px; min-height: 40px; padding: 0; border-radius: 50%; }

/* The small download buttons are one size. */
[data-dash-export], [data-report-csv], [data-coach-csv] { min-height: 36px; padding: 6px 16px; font-size: 13px; }
.dash-top .dash-period button { min-height: 40px; }

/* Popups: the close button is a clean circle level with the title, and prices keep their gap. */
.close { display: grid; place-items: center; width: 40px; height: 40px; min-height: 40px; margin: -6px; margin-inline-start: 8px; padding: 0; border-radius: 50%; font-size: 22px; line-height: 1; }
.dialog-body { clear: none; padding-top: 0; }
dialog .package-price { display: flex; align-items: baseline; gap: 7px; }

/* All packages at reception: the cards fill the row. */
.guide-group { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }

/* Every number in the whole system stands on the line, so a zero never reads as the letter o. */
* { font-variant-numeric: lining-nums !important; }


/* One star per page. The schedule: the next class in solid brown beside the quiet credits box. */
.home-next { border-color: var(--brown); background: var(--brown); color: var(--cream); }
.home-next .home-label { color: #e7d3b4; }
.home-next h2, [dir="rtl"] .home-next h2 { color: var(--cream); }
.home-next .home-line { color: var(--cream); }
.home-next button.primary, .home-next button.primary:not(:disabled):hover, .home-next button.primary:not(:disabled):active { background: var(--cream); border-color: var(--cream); color: var(--brown); }
.home-next button.home-form, .home-next button.home-form:not(:disabled):not(.primary):not(.active):hover { border-bottom-color: var(--cream); color: var(--cream); }

.stub-amount { color: var(--charcoal); font-size: 14px; font-weight: 500; white-space: nowrap; }

/* My details: her membership card, then quiet boxes for the rest. */
.profile { max-width: none; }
.member-card .member-top { display: flex; align-items: center; gap: 18px; }
.member-card .avatar { flex: none; width: 68px; height: 68px; background: var(--cream); color: var(--brown); font: 400 32px/1 var(--serif); }
[dir="rtl"] .member-card .avatar { font: 400 28px/1 "Balance Arabic", sans-serif; }
.member-card .pass-label { margin-bottom: 4px; }
.member-phone { margin: 4px 0 0; color: var(--cream); font-size: 14px; }
.profile-grid { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 14px; align-items: start; }
.profile-side { display: grid; gap: 14px; min-width: 0; }
.profile-grid .profile-section { min-width: 0; padding: 24px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); }
.profile-grid .profile-section h3 { margin-bottom: 14px; font-size: 22px; }
.profile-grid .profile-section > .fine { margin-top: 0; }
.profile-grid .profile-password > summary > span:first-child { color: var(--brown); font: 400 22px/1.2 var(--serif); }
[dir="rtl"] .profile-grid .profile-password > summary > span:first-child { font-family: "Balance Arabic Display", "Balance Arabic", sans-serif; font-size: 19px; }
.profile-grid .profile-password > summary .fine { flex: 1 1 auto; min-width: 0; font-size: 12.5px; }
.profile-grid .profile-password > summary .change { flex: none; padding: 7px 16px; font-size: 13px; line-height: 1.2; }
@media (max-width: 760px) {
  .profile-grid { grid-template-columns: minmax(0, 1fr); }
  .profile-grid .profile-section { padding: 20px; }
  .member-card .avatar { width: 56px; height: 56px; font-size: 26px; }
  .member-card .pass-facts { grid-template-columns: repeat(3, minmax(0, auto)); }
}
.member-card .pass-facts { padding-bottom: 0; border-bottom: 0; }

/* Less red: selected things are ivory with a thin brown line. Solid brown is kept for the star box and the buttons. */
.tabs button.active, [dir="rtl"] .tabs button.active, .tabs button.active:not(:disabled):hover, .tabs button.active:not(:disabled):active,
.filters button.active, .filters button.active:not(:disabled):hover, .filters button.active:not(:disabled):active,
.sub-filters button.active, .sub-filters button.active:not(:disabled):hover, .sub-filters button.active:not(:disabled):active,
.week button.active, .week button.active:not(:disabled):hover, .week button.active:not(:disabled):active { border: 1px solid var(--brown); background: var(--cream); color: var(--brown); box-shadow: none; }
.tabs button.active { box-shadow: inset 0 0 0 1px var(--brown); border-color: transparent; }
.week button.active *, .tabs button.active * { color: var(--brown); }
.stub:not(.faded) .stub-date { background: var(--cream); box-shadow: inset 0 0 0 1px var(--brown); color: var(--brown); }
.stub:not(.faded) .stub-date span { color: var(--brown); }
.stub.faded .stub-date strong { color: #5b534e; }
.stub.faded .stub-date { box-shadow: inset 0 0 0 1px var(--line); }
.tabs button.active, [dir="rtl"] .tabs button.active, .tabs button.active:not(:disabled):hover, .tabs button.active:not(:disabled):active { border: 0; box-shadow: inset 0 0 0 1px var(--brown); }
@media (max-width: 760px) {
  body[data-area="client"] main .tabs { flex-wrap: nowrap; }
}
@media (max-width: 374px) {
  body[data-area="client"] main .tabs button { padding-inline: 5px; }
}

/* The close button has its own row at the top of a popup: only the content under it scrolls, so it never covers anything. */
@media screen {
  dialog[open] { display: flex; flex-direction: column; overflow: hidden; }
  dialog[open] > .close, dialog[open] > .close:not(:disabled):not(.primary):not(.active):hover, dialog[open] > .close:not(:disabled):not(.primary):not(.active):active { flex: none; float: none; align-self: flex-end; width: 44px; height: 44px; min-height: 44px; margin: -8px 0 2px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--charcoal); font-size: 24px; }
  dialog[open] > .dialog-body { flex: 1 1 auto; min-height: 0; overflow-y: auto; margin-inline: -4px; padding-inline: 4px; padding-bottom: 2px; }
  dialog.wide[open] { overflow: hidden; }
}



/* Client pages: the section bar sits at the very top, the greeting under it. */
body[data-area="client"] main > .tabs { margin: 0 0 22px; }
body[data-area="client"] main { padding-top: 22px; }

/* The next class on one compact band, so the schedule itself is on the first screen. */
.home-next { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 0 0 22px; padding: 18px 24px; }
.home-next .home-words { min-width: 0; }
.home-next .home-label { margin: 0 0 4px; font-size: 13px; }
.home-next h2, [dir="rtl"] .home-next h2 { font-size: clamp(24px, 2.6vw, 32px); line-height: 1.15; }
.home-next .home-line { margin: 4px 0 0; font-size: 14px; line-height: 1.4; }
.home-next .home-action { flex: none; }
@media (max-width: 540px) {
  .home-next { padding: 16px 18px; }
  .home-next h2, [dir="rtl"] .home-next h2 { font-size: 24px; }
  .home-next .home-action button.primary { padding-inline: 16px; }
}

/* A small label in the corner of the package we recommend; the card itself stays like the others. */

/* Package cards share one set of lines across a row: names level, descriptions level, prices and Buy level. */
.panel.package { position: relative; display: grid; grid-row: span 3; grid-template-rows: subgrid; row-gap: 0; align-content: start; }
.panel.package h3 { align-self: start; }
.panel.package > p.fine { align-self: start; }
.panel.package .package-foot { margin-top: 0; }
/* The label sits on the card's top edge, so it never touches the name or moves anything. */
.package-tag { position: absolute; inset-block-start: -11px; inset-inline-end: 16px; padding: 2px 10px; border: 1px solid #b48e6f; border-radius: var(--pill); background: var(--cream); color: var(--brown); font-size: 11.5px; line-height: 1.4; white-space: nowrap; }
/* Every row of cards the same height, and names on one line where the cards are narrow. */
@media (min-width: 541px) {
  .panel.package > p.fine { min-height: 3lh; }
}
@media (min-width: 541px) and (max-width: 1100px) {
  .panel.package > p.fine { min-height: 5lh; }
  .panel.package h3, [dir="rtl"] .panel.package h3 { font-size: 25px; line-height: 1.2; }
}

/* Cancelling a booking lives in its popup, so a list card only needs one button. */
.popup-cancel, .popup-cancel:not(:disabled):not(.primary):not(.active):hover, .popup-cancel:not(:disabled):not(.primary):not(.active):active { width: 100%; min-height: 46px; margin-top: 14px; border: 1px solid #b48e6f; color: var(--brown); }

/* Fields side by side always share one line, even if a label above one of them runs to two lines. */
.fields { align-items: end; }
/* My details: the side boxes sit under the form until there is real room beside it, and the two field columns are equal. */
@media (max-width: 1000px) {
  .profile-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (min-width: 541px) {
  #profile-form .fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.profile-grid .profile-password > summary > span:first-child { white-space: nowrap; }
/* My details on every device: your details across the whole width, the health form and password under it. */
.profile-grid { grid-template-columns: minmax(0, 1fr); }

/* My details: the same light underlined fields as the sign-in page, no white boxes. */
.profile form input:not([type="checkbox"]):not([type="radio"]), .profile form select, .profile form textarea { min-height: 42px; margin-top: 2px; padding: 8px 0; border: 0; border-bottom: 1px solid #b48e6f; border-radius: 0; background: transparent; box-shadow: none; color: var(--charcoal); font-size: 16px; }
.profile form input:focus, .profile form select:focus, .profile form textarea:focus { outline: 0; border-bottom-color: var(--brown); box-shadow: 0 1px 0 var(--brown); }
.profile form input:-webkit-autofill { -webkit-box-shadow: 0 0 0 40px var(--surface) inset; -webkit-text-fill-color: var(--charcoal); }
.profile form label { font-weight: 400; color: #5b534e; font-size: 13px; }
.profile #profile-form .fields { gap: 18px 24px; }

/* Preferred times: small choices to tap, the selected one outlined. */
.time-choice { margin: 20px 0 18px; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.time-choice legend { margin-bottom: 8px; padding: 0; color: #5b534e; font-size: 13px; }
.time-choice > div { display: flex; flex-wrap: wrap; gap: 8px; }
.profile form .time-choice label { position: relative; margin: 0; cursor: pointer; }
.time-choice input { position: absolute; width: 1px; height: 1px; min-height: 0; margin: 0; opacity: 0; }
.time-choice span { display: block; padding: 7px 14px; border: 1px solid var(--line); border-radius: var(--pill); color: var(--charcoal); font-size: 13px; line-height: 1.3; }
.time-choice input:checked + span { border-color: var(--brown); color: var(--brown); }
.time-choice input:focus-visible + span { outline: 2px solid var(--brown); outline-offset: 2px; }
.profile fieldset.consent { margin-bottom: 16px; }
.profile fieldset.consent legend { color: #5b534e; font-size: 13px; }

.profile form input::placeholder { color: #a49688; opacity: 1; }
/* Date of birth: a plain hint instead of mm/dd/yyyy and no calendar icon; the whole line opens the picker. */
.date-field { position: relative; display: block; }
.date-field input { position: relative; cursor: pointer; }
.date-field input::-webkit-calendar-picker-indicator { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; padding: 0; opacity: 0; cursor: pointer; }
.date-field input.is-empty::-webkit-datetime-edit { opacity: 0; }
.date-field:has(input.is-empty)::after { content: attr(data-hint); position: absolute; inset-inline-start: 0; inset-block-start: 10px; color: #a49688; font-size: 16px; line-height: 1.5; pointer-events: none; }

/* Clients: one list of everyone. Same lines in every row. */
.clients-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 14px; }
.clients-top h2 { margin: 0; }
.clients-search { width: 100%; margin: 0 0 16px; }
.client-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 10px; }
.client-row, .client-row:not(:disabled):not(.primary):not(.active):hover, .client-row:not(:disabled):not(.primary):not(.active):active { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 12px; width: 100%; min-height: 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); color: var(--charcoal); font-size: 14px; text-align: start; white-space: normal; }
.client-row .avatar { width: 44px; height: 44px; font-size: 18px; color: var(--charcoal); }
.client-row-who { min-width: 0; }
.client-row-who strong { display: block; overflow: hidden; color: var(--brown); font: 400 20px/1.2 var(--serif); text-overflow: ellipsis; white-space: nowrap; }
[dir="rtl"] .client-row-who strong { font-family: "Balance Arabic", sans-serif; font-size: 16px; line-height: 1.4; }
.client-row-who small { display: block; margin-top: 2px; color: #5b534e; font-size: 12.5px; line-height: 1.35; }
.client-row-left { display: flex; flex-direction: column; align-items: center; min-width: 40px; }
.client-row-left strong { color: var(--brown); font: 400 24px/1 var(--serif); }
.client-row-left small { margin-top: 2px; color: #5b534e; font-size: 11.5px; }

/* Staff tab bars with many tabs wrap inside the bar, so no tab is ever cut off. */
body:not([data-area="client"]):not([data-area=""]) main .tabs { display: flex; flex-wrap: wrap; width: fit-content; max-width: 100%; gap: 4px; }
body:not([data-area="client"]):not([data-area=""]) main .tabs button { flex: 0 0 auto; padding-inline: 14px; font-size: 18px; }

/* A client's habits: label on one side, answer on the other, every row on the same lines. */
.client-habits { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.client-habits h3 { margin: 0 0 10px; font-size: 20px; }
.client-habits dl { display: grid; gap: 6px; margin: 0; }
.client-habits dl > div { display: grid; grid-template-columns: 111px minmax(0, 1fr); gap: 0; }
.client-habits dt { color: #5b534e; font-size: 13px; }
.client-habits dd { margin: 0; color: var(--charcoal); font-size: 13.5px; }
.client-habits dd small { color: #5b534e; font-size: 12.5px; }
/* The client's details and her habits use one column line, so the answers all start at the same place. */
.client-card .facts, .client-habits dl { display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 8px 16px; font-size: 14px; }
.client-habits dl > div { display: contents; }
.client-habits dt { font-size: 14px; }
.client-habits dd { font-size: 14px; }

/* Studio today: the operations manager's board, made for an iPad held either way. */
.ops-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin: 0 0 16px; }
.ops-head h1 { margin: 0; font-size: 42px; line-height: 1.1; }
.ops-head p { margin: 0; color: #5b534e; font-size: 15px; }
.ops-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 0 0 14px; }
.ops-tile { display: flex; flex-direction: column; min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); }
.ops-tile strong { overflow: hidden; color: var(--brown); font: 400 28px/1.15 var(--serif); text-overflow: ellipsis; white-space: nowrap; }
.ops-tile span { margin-top: 2px; font-size: 13px; }
.ops-tile small { margin-top: 2px; overflow: hidden; color: #5b534e; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.ops-attention { margin: 0 0 14px; padding: 16px 18px; border-radius: var(--r-md); background: var(--brown); color: var(--cream); }
.ops-attention h2, [dir="rtl"] .ops-attention h2 { margin: 0 0 10px; color: var(--cream); font-size: 22px; }
.ops-attention-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 24px; }
.ops-attention-list div { display: flex; flex-direction: column; min-width: 0; padding-block-start: 8px; border-top: 1px solid rgba(248, 245, 239, 0.26); }
.ops-attention-list strong { font-size: 14px; font-weight: 500; }
.ops-attention-list span { color: #e7d3b4; font-size: 13.5px; }
.ops-attention.ops-clear { padding: 12px 18px; border: 1px solid var(--line); background: var(--surface); color: var(--charcoal); }
.ops-clear strong { font-size: 14px; font-weight: 500; }
.ops-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; }
.ops-col { display: grid; gap: 14px; min-width: 0; }
.ops-card { min-width: 0; padding: 18px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); }
.ops-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 12px; min-height: 40px; }
.ops-card-head h2 { margin: 0; font-size: 24px; }
.ops-class { display: grid; grid-template-columns: 62px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.ops-class.over { opacity: 0.55; }
.ops-class-time strong { display: block; color: var(--brown); font: 400 21px/1.1 var(--serif); }
.ops-class-time small { color: var(--brown); font-size: 12px; }
.ops-class-body { min-width: 0; }
.ops-class-body h3, [dir="rtl"] .ops-class-body h3 { margin: 0 0 2px; font-size: 19px; line-height: 1.2; }
.ops-class-body p { margin: 0; color: #5b534e; font-size: 13px; line-height: 1.45; }
.ops-warn { color: var(--brown); font-weight: 600; }
.ops-tick, .ops-tick:not(:disabled):not(.primary):not(.active):hover, .ops-tick:not(:disabled):not(.primary):not(.active):active { min-height: 44px; padding: 8px 12px; border: 1px solid #b48e6f; background: transparent; color: var(--brown); font-size: 13px; }
.ops-tick.done, .ops-tick.done:not(:disabled):not(.primary):not(.active):hover, .ops-tick.done:not(:disabled):not(.primary):not(.active):active { border-color: var(--olive); background: var(--olive); color: var(--charcoal); }
.ops-switch { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin: 0 0 10px; }
.ops-switch button, .ops-switch button:not(:disabled):not(.active):hover { min-height: 44px; padding: 6px 4px; border: 1px solid var(--line); border-radius: var(--r-sm); background: transparent; color: var(--charcoal); font-size: 13.5px; }
.ops-switch button.active, .ops-switch button.active:not(:disabled):hover { border-color: var(--brown); background: var(--cream); color: var(--brown); }
h3.ops-room, [dir="rtl"] h3.ops-room { margin: 14px 0 2px; color: #5b534e; font: 500 12.5px/1.3 "Balance Arabic", "Segoe UI", Arial, sans-serif; }
.ops-task { display: flex; align-items: center; border-bottom: 1px solid var(--line); }
.ops-task .ops-check { flex: 1 1 auto; min-width: 0; }
.ops-task .ops-remove { flex: none; }
.ops-head-actions { display: flex; gap: 8px; }
.ops-check, .ops-check:not(:disabled):not(.primary):not(.active):hover, .ops-check:not(:disabled):not(.primary):not(.active):active { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 6px 0; border: 0; border-radius: 0; background: transparent; color: var(--charcoal); font-size: 15px; text-align: start; white-space: normal; }
.ops-check i { flex: none; width: 26px; height: 26px; border: 1.5px solid #b48e6f; border-radius: 8px; }
.ops-check span { min-width: 0; }
.ops-check small { display: block; color: #5b534e; font-size: 12px; }
.ops-task.done .ops-check i { border-color: var(--olive); background: var(--olive) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232c2a29' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5 10 17.5 19 7.5'/%3E%3C/svg%3E") center / 18px no-repeat; }
.ops-remove, .ops-remove:not(:disabled):not(.primary):not(.active):hover, .ops-remove:not(:disabled):not(.primary):not(.active):active { width: 44px; min-height: 44px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: #a49688; font-size: 20px; }
.ops-issue { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.ops-issue div { min-width: 0; }
.ops-issue strong { display: block; font-size: 15px; font-weight: 500; }
.ops-issue small { color: #5b534e; font-size: 12.5px; }
.ops-issue.urgent strong { color: var(--brown); }
.ops-issue.fixed { opacity: 0.55; }
.ops-issue button { flex: none; min-height: 44px; }
.ops-stock { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 14px; }
.ops-levels { flex: none; display: flex; gap: 4px; }
.ops-levels button, .ops-levels button:not(:disabled):not(.active):hover { min-width: 48px; min-height: 44px; padding: 4px 8px; border: 1px solid var(--line); border-radius: var(--r-sm); background: transparent; color: #5b534e; font-size: 13px; }
.ops-levels button.active.ok, .ops-levels button.active.ok:not(:disabled):hover { border-color: var(--olive); background: var(--olive); color: var(--charcoal); }
.ops-levels button.active.low, .ops-levels button.active.low:not(:disabled):hover { border-color: var(--tan); background: var(--tan); color: var(--charcoal); }
.ops-levels button.active.out, .ops-levels button.active.out:not(:disabled):hover { border-color: var(--brown); background: var(--brown); color: var(--cream); }
.ops-week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.ops-week > div { display: flex; flex-direction: column; align-items: center; min-width: 0; }
.ops-bar { display: flex; align-items: flex-end; width: 100%; max-width: 30px; height: 56px; overflow: hidden; border-radius: 6px; background: #e9dfd4; }
.ops-bar i { display: block; width: 100%; background: var(--brown); }
.ops-week strong { margin-top: 4px; font-size: 11.5px; font-weight: 400; }
.ops-week small { color: #5b534e; font-size: 11.5px; }
.ops-week .today small, .ops-week .today strong { color: var(--brown); font-weight: 600; }
.ops-fill-0 { height: 0%; }
.ops-fill-10 { height: 10%; }
.ops-fill-20 { height: 20%; }
.ops-fill-30 { height: 30%; }
.ops-fill-40 { height: 40%; }
.ops-fill-50 { height: 50%; }
.ops-fill-60 { height: 60%; }
.ops-fill-70 { height: 70%; }
.ops-fill-80 { height: 80%; }
.ops-fill-90 { height: 90%; }
.ops-fill-100 { height: 100%; }
@media (max-width: 899px) {
  .ops-tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .ops-tile strong { font-size: 24px; }
}
@media (max-width: 700px) {
  .ops-grid { grid-template-columns: minmax(0, 1fr); }
  .ops-attention-list { grid-template-columns: minmax(0, 1fr); }
  .ops-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ops-head h1 { font-size: 34px; }
}

/* Gifts and birthdays: one row each, a name that opens her page and one button. */
.nav-count { display: inline-block; min-width: 20px; padding: 0 6px; border-radius: 10px; background: var(--brown); color: var(--cream); font-size: 12px; font-weight: 500; line-height: 20px; text-align: center; vertical-align: 1px; }
.care-block h3 { margin: 0 0 8px; font-size: 22px; }
.care-list { display: grid; }
.care-list details.show-all { grid-column: 1 / -1; }
.care-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.care-who, .care-who:not(:disabled):not(.primary):not(.active):hover { display: block; flex: 1 1 auto; min-width: 0; min-height: 0; padding: 0; border: 0; border-radius: 0; background: none; color: inherit; font: inherit; text-align: start; }
.care-who strong { display: block; color: var(--charcoal); font-size: 15px; font-weight: 600; }
.care-who small { display: block; color: #5b534e; font-size: 13px; }
.care-row.now .care-who small:first-of-type { color: var(--brown); font-weight: 600; }
.care-gift { display: block; }
.care-done, .care-done:not(:disabled):not(.primary):not(.active):hover { flex: none; min-width: 72px; min-height: 44px; padding: 6px 14px; border: 1px solid var(--brown); border-radius: var(--r-sm); background: transparent; color: var(--brown); font-size: 14px; }
.care-given { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid var(--line); }
.care-given strong { display: block; font-size: 14px; font-weight: 500; }
.care-given small { display: block; color: #5b534e; font-size: 12.5px; }
.care-add, .care-add:not(:disabled):not(.primary):not(.active):hover { width: 100%; min-height: 40px; margin-top: 10px; padding: 6px 12px; border: 1px solid var(--line); border-radius: var(--r-sm); background: transparent; color: var(--brown); font-size: 14px; }
.client-gifts .fine { margin: 6px 0; }
.client-months { grid-template-columns: repeat(6, minmax(0, 1fr)); margin-top: 14px; }
.clients-filters { flex-wrap: wrap; margin-bottom: 12px; }
.care-rule .actions { display: flex; gap: 8px; }
/* Each event says what it is before anything else. */
.event-tag { display: inline-block; margin-bottom: 4px; padding: 1px 9px; border: 1px solid transparent; border-radius: 10px; font-size: 11.5px; font-weight: 600; line-height: 18px; letter-spacing: 0.02em; white-space: nowrap; }
.tag-birthday { background: var(--brown); color: var(--cream); }
.tag-anniversary { background: var(--tan); color: var(--charcoal); }
.tag-milestone { background: var(--olive); color: var(--charcoal); }
.tag-first, .tag-welcome { border-color: var(--olive); color: var(--charcoal); }
.tag-event, .tag-team_class, .tag-terrace { border-color: var(--brown); color: var(--brown); }
.tag-visitor, .tag-delivery, .tag-maintenance, .tag-cover, .tag-lead { border-color: var(--charcoal); color: var(--charcoal); }
strong .event-tag { margin: 0 0 0 6px; }
[dir="rtl"] strong .event-tag { margin: 0 6px 0 0; }
.care-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.care-head h3 { margin: 0; }
.care-all, .care-all:not(:disabled):not(.primary):not(.active):hover { min-height: 36px; padding: 4px 14px; font-size: 13.5px; }
.events-group { margin: 18px 0 4px; font-size: 22px; }
.ops-shift { margin-bottom: 14px; }
.ops-shift .care-row { min-height: 0; }
/* Records */
.records-body { display: grid; gap: 14px; margin-top: 14px; min-width: 0; }
.records-head { display: flex; align-items: center; justify-content: center; gap: 14px; }
.records-head .day-step:disabled { background: transparent; opacity: 0.3; }
.records-head h2 { margin: 0; font-size: 26px; text-align: center; }
.records-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; }
#numbers-form { display: grid; gap: 12px; }
#numbers-body { min-height: 300px; line-height: 1.5; }
.rota-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.rota-day.today { border-color: var(--brown); }
.rota-day h3 { margin: 0; font-size: 19px; }
.rota-shift { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; padding: 9px 0; border-top: 1px solid var(--line); }
.rota-shift > div { min-width: 0; }
.rota-shift strong { display: block; font-size: 14.5px; font-weight: 600; }
.rota-shift small { display: block; color: #5b534e; font-size: 12.5px; }
.ops-issue small { display: block; }
@media (max-width: 1000px) {
  .rota-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .rota-grid { grid-template-columns: minmax(0, 1fr); }
  .ops-issue { flex-wrap: wrap; }
}
@media (min-width: 700px) {
  .care-wide-list { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 28px; }
}
.care-wide { margin-bottom: 14px; }
/* Rows of different lengths still start on one line. */
.client-row-who { align-self: flex-start; }
.client-gifts .care-who strong { display: none; }
.client-gifts .care-row { border-top: 0; }
.ops-switch button { display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.25; }
.ops-stock span small { display: block; color: #5b534e; font-size: 12px; }
@media (min-width: 700px) {
  .care-wide .care-list { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 28px; }
}

/* The word "العربية" always in our Arabic font, level with the location opposite it. */
#language .long[lang="ar"] { font-family: "Balance Arabic", sans-serif; font-size: 15px; font-weight: 400; letter-spacing: 0; line-height: 1; position: relative; top: -0.6px; }
@media (max-width: 1024px) {
  #language .long[lang="ar"] { top: -0.9px; }
  #language .long:not([lang="ar"]) { position: relative; top: -2px; }
}

/* Our classes and sessions: the name and its length on one line, what happens in it underneath. */
.offer-group { margin: 26px 0 8px; font-size: 24px; }
.offer-note { margin: 0 0 8px; }
.offers { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); column-gap: 32px; }
.offer { min-width: 0; padding: 14px 0; border-block-start: 1px solid var(--line); }
.offer-head { display: grid; gap: 2px; }
.offer-head h4 { margin: 0; color: var(--brown); font-family: var(--serif); font-size: 22px; font-weight: 400; letter-spacing: 0; line-height: 1.25; text-transform: none; }
.offer-head small { color: #6b625b; font-size: 12.5px; }
.offer p.fine { margin: 6px 0 0; font-size: 13.5px; line-height: 1.55; }
[dir="rtl"] .offer-head h4 { font-family: "Balance Arabic", sans-serif; font-size: 17px; line-height: 1.5; }
[dir="rtl"] .offer p.fine { line-height: 1.75; }

/* The owner's list: each row opens the place to deal with it. */
.owner-alerts .ops-attention-list button, .owner-alerts .ops-attention-list button:not(:disabled):hover, .owner-alerts .ops-attention-list button:not(:disabled):active { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; min-height: 44px; margin: 0; padding: 8px 0 0; border: 0; border-top: 1px solid rgba(248, 245, 239, 0.26); border-radius: 0; background: transparent; color: var(--cream); font: inherit; text-align: start; white-space: normal; }
/* A finger has no hover: the first tap must not stop at a grey line. */
nav button, .tabs button { -webkit-tap-highlight-color: transparent; }
@media (hover: none) {
  nav button:not(.active):not(:disabled):hover { border-bottom-color: transparent; }
}
