/* SernaFit admin panel */
/* Fonts are served from this site (no Google Fonts request), so they load on every network. */
/* Archivo italic, latin-ext */
@font-face { font-family: 'Fraunces'; font-style: normal; font-weight: 100 900; font-display: swap; src: url(../fonts/fraunces-latin.woff2) format('woff2'); }
@font-face { font-family: 'Fraunces'; font-style: italic; font-weight: 100 900; font-display: swap; src: url(../fonts/fraunces-italic-latin.woff2) format('woff2'); }
@font-face {
  font-family: 'Archivo';
  font-style: italic;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url(../fonts/archivo-italic-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Archivo italic, latin */
@font-face {
  font-family: 'Archivo';
  font-style: italic;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url(../fonts/archivo-italic-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Archivo normal, latin-ext */
@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url(../fonts/archivo-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Archivo normal, latin */
@font-face {
  font-family: 'Archivo';
  font-style: normal;
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  src: url(../fonts/archivo-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* JetBrains Mono normal, latin-ext */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 100 800;
  font-display: swap;
  src: url(../fonts/jetbrainsmono-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* JetBrains Mono normal, latin */
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 100 800;
  font-display: swap;
  src: url(../fonts/jetbrainsmono-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #0d0d0f;
  --side: #0a0a0b;
  --card: #141416;
  --card-2: #1a1a1d;
  --field: #0b0b0c;
  --line: rgba(244, 241, 234, 0.09);
  --line-2: rgba(244, 241, 234, 0.18);
  --text: #f4f1ea;
  --muted: #aaa69d;
  --dim: #7c7870;
  --accent: #ff4a1c;
  --accent-2: #ff6b42;
  --accent-soft: rgba(255, 74, 28, 0.12);
  --ink: #0b0b0c;
  --ok: #3ad07b;
  --warn: #ffd166;
  --info: #7cc4ff;
  --error: #ff8a80;
  --wa: #25d366;
  --font: 'Archivo', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--font); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }
h1, h2, h3, p, blockquote, dl, dd { margin: 0; }
svg { display: block; flex: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.muted { color: var(--muted); }
.no-scroll { overflow: hidden; }
code { font-family: var(--mono); font-size: 0.78rem; color: var(--dim); }

/* brand */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand__logo { display: block; width: auto; height: 40px; }

/* loading */
.boot { position: fixed; inset: 0; display: grid; place-items: center; }
.spinner { display: block; width: 28px; height: 28px; border: 3px solid var(--line-2); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.8s linear infinite; }
.loading { display: grid; place-items: center; min-height: 240px; }
@keyframes spin { to { transform: rotate(360deg); } }

/* buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: none;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, opacity 0.2s;
}
.btn svg { width: 16px; height: 16px; }
.btn--primary { background: var(--accent); color: var(--ink); }
.btn--primary:hover { background: var(--accent-2); }
.btn--ghost { border-color: var(--line-2); }
.btn--ghost:hover { border-color: var(--text); background: rgba(244, 241, 234, 0.05); }
.btn--danger { border-color: rgba(255, 138, 128, 0.35); color: var(--error); }
.btn--danger:hover { background: rgba(255, 138, 128, 0.1); }
.btn--wa { background: var(--wa); color: #fff; }
.btn--sm { min-height: 34px; padding: 0 12px; font-size: 0.84rem; }
.btn--lg { min-height: 48px; font-size: 0.98rem; }
.btn--block { width: 100%; }
.btn:disabled { opacity: 0.55; cursor: progress; }
.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  text-decoration: none;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, background-color 0.2s;
}
.icon-btn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn:hover { color: var(--text); border-color: var(--line-2); background: rgba(244, 241, 234, 0.04); }
.icon-btn--danger:hover { color: var(--error); border-color: rgba(255, 138, 128, 0.4); }
.icon-btn:disabled { opacity: 0.3; cursor: default; }
.ico { display: inline-flex; }
.ico svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ico--fill svg { fill: currentColor; stroke: none; }
.link { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 0.86rem; font-weight: 600; text-decoration: none; }
.link:hover { color: var(--text); }

/* fields */
.field { display: grid; align-content: start; gap: 6px; min-width: 0; }
.field > span:first-child { font-size: 0.82rem; font-weight: 600; color: var(--muted); }
.input {
  width: 100%;
  min-height: 42px;
  padding: 9px 12px;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--field);
  color: var(--text);
  transition: border-color 0.2s, box-shadow 0.2s;
}
textarea.input { min-height: 84px; line-height: 1.5; resize: vertical; }
select.input { cursor: pointer; }
.input:hover { border-color: rgba(244, 241, 234, 0.3); }
.input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255, 74, 28, 0.18); }
.field__help { color: var(--dim); font-size: 0.8rem; }
.field__error { color: var(--error); font-size: 0.82rem; }
.field__error:empty { display: none; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-grid .span-2 { grid-column: 1 / -1; }
.stack { display: grid; gap: 18px; }

/* switch */
.switch { position: relative; display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.switch__track { position: relative; flex: none; width: 40px; height: 22px; border-radius: 999px; background: var(--line-2); transition: background-color 0.2s; }
.switch__track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform 0.2s; }
.switch input:checked + .switch__track { background: var(--ok); }
.switch input:checked + .switch__track::after { transform: translateX(18px); }
.switch input:focus-visible + .switch__track { outline: 2px solid var(--accent); outline-offset: 2px; }
.switch__label { font-size: 0.88rem; font-weight: 600; }

/* login */
.login { display: grid; place-items: center; min-height: 100vh; padding: 24px; }
.login__card { display: grid; gap: 16px; width: min(420px, 100%); padding: 36px; border: 1px solid var(--line-2); border-radius: 24px; background: var(--card); box-shadow: 0 40px 80px -40px #000; }
.login__card .brand { margin-bottom: 10px; }
.login h1 { font-size: 2rem; font-stretch: 75%; font-weight: 850; line-height: 1; text-transform: uppercase; }
.login p { color: var(--muted); }
.login__error { min-height: 1.3em; color: var(--error) !important; font-size: 0.9rem; }
.login__error--info { color: var(--muted) !important; }
.login__back { color: var(--muted); font-size: 0.88rem; text-align: center; text-decoration: none; }
.login__back:hover { color: var(--text); }

/* layout */
.app { display: grid; grid-template-columns: 252px minmax(0, 1fr); min-height: 100vh; }
.sidebar { position: sticky; top: 0; display: flex; flex-direction: column; gap: 6px; height: 100vh; padding: 20px 14px; border-right: 1px solid var(--line); background: var(--side); overflow-y: auto; }
.sidebar__brand { padding: 6px 10px 22px; }
.sidebar__brand em { margin-left: 6px; padding: 3px 6px; border: 1px solid var(--line-2); border-radius: 6px; font-family: var(--mono); font-size: 0.62rem; font-style: normal; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim); }
.sidebar__nav { display: grid; gap: 2px; }
.sidebar__nav a,
.sidebar__foot a,
.sidebar__foot button {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 10px;
  background: none;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 600;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}
.sidebar svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sidebar__nav a:hover,
.sidebar__foot a:hover,
.sidebar__foot button:hover { background: rgba(244, 241, 234, 0.05); color: var(--text); }
.sidebar__nav a.is-active { background: var(--accent-soft); color: var(--accent); }
.count { margin-left: auto; min-width: 22px; padding: 2px 7px; border-radius: 999px; background: var(--accent); color: var(--ink); font-size: 0.72rem; font-weight: 700; text-align: center; }
.count:empty { display: none; }
.sidebar__foot { display: grid; gap: 2px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); }

.main { display: flex; flex-direction: column; min-width: 0; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 68px;
  padding: 12px 28px;
  border-bottom: 1px solid var(--line);
  background: rgba(13, 13, 15, 0.86);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
.topbar__title { font-size: 1.55rem; font-stretch: 75%; font-weight: 850; letter-spacing: 0.01em; text-transform: uppercase; }
.topbar__actions { display: flex; flex-wrap: wrap; gap: 8px; margin-left: auto; }
.topbar__menu { display: none; }
.topbar__menu svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.view { display: grid; align-content: start; gap: 20px; width: 100%; max-width: 1180px; padding: 28px; }

/* cards */
.card { min-width: 0; padding: 22px; border: 1px solid var(--line); border-radius: 18px; background: var(--card); }
.card__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.card__title { font-size: 1.02rem; font-weight: 700; }
.card__sub { margin-top: 4px; color: var(--dim); font-size: 0.86rem; }
.card > .card__title + .card__sub { margin-bottom: 18px; }
.card > .card__title:only-child,
.card > .card__title + .form-grid { margin-bottom: 0; }
.card > .card__title + .form-grid { margin-top: 18px; }
.card--row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.empty { padding: 32px 20px; border: 1px dashed var(--line-2); border-radius: 14px; color: var(--dim); text-align: center; }
.empty--flat { border: 0; }

/* dashboard */
.hello { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.hello h2 { font-size: clamp(1.8rem, 3vw, 2.4rem); font-stretch: 75%; font-weight: 850; line-height: 1; text-transform: uppercase; }
.hello p { margin-top: 6px; color: var(--muted); }
.hello__status { padding: 14px 18px; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.kpi { display: grid; gap: 8px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--card); text-decoration: none; transition: border-color 0.2s; }
.kpi:hover { border-color: var(--line-2); }
.kpi__label { font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim); }
.kpi__value { font-size: 2.8rem; font-stretch: 62%; font-weight: 850; line-height: 0.9; }
.kpi--accent { border-color: rgba(255, 74, 28, 0.5); box-shadow: inset 0 3px 0 var(--accent); }
.kpi--accent .kpi__value { color: var(--accent); }
.grid-2 { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.grid-2--even { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mini-list { display: grid; }
.mini { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); text-decoration: none; }
.mini:first-child { border-top: 0; padding-top: 0; }
.mini__main { display: grid; min-width: 0; }
.mini__main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mini__main span { color: var(--dim); font-size: 0.86rem; }
.mini__side { display: grid; justify-items: end; gap: 4px; }
.mini__side small { color: var(--dim); font-size: 0.78rem; white-space: nowrap; }
.mini:hover strong { color: var(--accent); }
.glance { display: grid; gap: 12px; margin: 0 0 18px; padding: 0; list-style: none; }
.glance li { display: flex; align-items: flex-start; gap: 10px; color: var(--muted); font-size: 0.92rem; }
.glance a { color: var(--text); text-decoration: none; }
.glance a:hover { color: var(--accent); }
.dot { flex: none; width: 8px; height: 8px; margin-top: 7px; border-radius: 50%; background: var(--dim); }
.dot--ok { background: var(--ok); }
.dot--off { background: var(--dim); }
.dot--accent { background: var(--accent); }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }

/* badges & chips */
.badge { display: inline-flex; align-items: center; padding: 3px 10px; border: 1px solid var(--line-2); border-radius: 999px; font-size: 0.74rem; font-weight: 600; white-space: nowrap; }
.badge--new { border-color: rgba(255, 74, 28, 0.45); background: var(--accent-soft); color: var(--accent); }
.badge--contacted { border-color: rgba(124, 196, 255, 0.35); color: var(--info); }
.badge--booked,
.badge--pending { border-color: rgba(255, 209, 102, 0.35); color: var(--warn); }
.badge--client,
.badge--approved { border-color: rgba(58, 208, 123, 0.35); color: var(--ok); }
.badge--closed,
.badge--hidden { color: var(--dim); }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { padding: 7px 12px; border: 1px solid var(--line); border-radius: 999px; background: transparent; color: var(--muted); font-size: 0.84rem; font-weight: 600; cursor: pointer; }
.chip:hover { border-color: var(--line-2); color: var(--text); }
.chip span { margin-left: 6px; opacity: 0.6; }
.chip.is-active { border-color: var(--text); background: var(--text); color: var(--ink); }
.search { width: min(320px, 100%); }

/* applications list */
.list { overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: var(--card); }
.list__head,
.item { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1.1fr) 110px 128px; gap: 14px; align-items: center; padding: 14px 18px; }
.list__head { border-bottom: 1px solid var(--line); font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim); }
.item { width: 100%; border: 0; border-top: 1px solid var(--line); background: none; color: inherit; text-align: left; cursor: pointer; transition: background-color 0.15s; }
.list__head + .item { border-top: 0; }
.item:hover { background: rgba(244, 241, 234, 0.03); }
.item > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 0.9rem; }
.item__who { display: grid; }
.item__who strong { overflow: hidden; text-overflow: ellipsis; }
.item__who small { overflow: hidden; color: var(--dim); font-size: 0.82rem; text-overflow: ellipsis; }
.item.is-new .item__who strong::before { content: ''; display: inline-block; width: 7px; height: 7px; margin: 0 8px 2px 0; border-radius: 50%; background: var(--accent); vertical-align: middle; }

/* drawer */
.drawer { position: fixed; inset: 0; z-index: 50; display: flex; justify-content: flex-end; background: rgba(0, 0, 0, 0.55); }
.drawer__panel { display: flex; flex-direction: column; width: min(580px, 100%); height: 100%; border-left: 1px solid var(--line-2); background: #111113; animation: slide-in 0.25s ease; }
.drawer__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 22px; border-bottom: 1px solid var(--line); }
.drawer__head h2 { font-size: 1.35rem; font-stretch: 75%; font-weight: 850; text-transform: uppercase; overflow-wrap: anywhere; }
.drawer__head .icon-btn svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.drawer__body { flex: 1; overflow-y: auto; padding: 22px; }
.drawer__actions { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding-top: 18px; border-top: 1px solid var(--line); }
.drawer__actions > :only-child { margin-left: auto; }
@keyframes slide-in { from { opacity: 0; transform: translateX(30px); } }
.enquiry-top { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.details { display: grid; grid-template-columns: 120px 1fr; gap: 10px 16px; }
.details dt { padding-top: 3px; font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); }
.details dd { overflow-wrap: anywhere; }
.label { margin-bottom: 8px; font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); }
.message { padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--field); white-space: pre-wrap; overflow-wrap: anywhere; }

/* posts & plans */
.posts { display: grid; }
.post { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px 16px; align-items: start; padding: 16px 0; border-top: 1px solid var(--line); }
.post:first-child { padding-top: 0; border-top: 0; }
.post:last-child { padding-bottom: 0; }
.order { display: grid; gap: 4px; }
.post__main { display: grid; gap: 8px; min-width: 0; }
.post__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; color: var(--dim); font-size: 0.82rem; }
.post__side { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px; }
.post.is-hidden .post__main { opacity: 0.5; }
.plan-title { font-size: 1.05rem; }
.input--title { font-weight: 700; }
.add-post__row { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) auto; gap: 12px; align-items: end; }
.add-post__row .btn { min-height: 42px; }

/* reviews */
.reviews-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.review-card { display: grid; align-content: start; gap: 12px; }
.review-card__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.stars { color: var(--accent); letter-spacing: 2px; }
.review-card__quote { font-size: 0.98rem; line-height: 1.6; white-space: pre-wrap; }

/* settings */
.settings { display: grid; gap: 20px; }
.savebar { position: sticky; bottom: 0; z-index: 5; display: flex; justify-content: flex-end; gap: 10px; padding: 16px 0 4px; background: linear-gradient(transparent, var(--bg) 35%); }

/* toasts */
.toasts { position: fixed; right: 20px; bottom: 20px; z-index: 100; display: grid; gap: 8px; max-width: min(380px, calc(100vw - 40px)); }
.toast { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border: 1px solid var(--line-2); border-radius: 12px; background: #1d1d20; box-shadow: 0 20px 40px -20px #000; font-size: 0.9rem; font-weight: 600; animation: toast-in 0.25s ease; transition: opacity 0.3s, transform 0.3s; }
.toast::before { content: ''; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--ok); }
.toast--error { border-color: rgba(255, 138, 128, 0.5); }
.toast--error::before { background: var(--error); }
.toast.is-leaving { opacity: 0; transform: translateY(8px); }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } }

/* responsive */
@media (max-width: 1060px) {
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; inset: 0 auto 0 0; z-index: 40; width: 270px; transform: translateX(-100%); transition: transform 0.25s ease; }
  .sidebar.is-open { transform: none; }
  .scrim { position: fixed; inset: 0; z-index: 30; background: rgba(0, 0, 0, 0.55); }
  .topbar { padding: 10px 16px; }
  .topbar__menu { display: inline-grid; }
  .topbar__title { font-size: 1.3rem; }
  .view { padding: 16px; }
  .list__head { display: none; }
  .item { grid-template-columns: minmax(0, 1fr) auto; }
  .item .hide-sm { display: none; }
  .form-grid,
  .add-post__row { grid-template-columns: 1fr; }
  .details { grid-template-columns: 1fr; gap: 2px; }
  .details dd { margin-bottom: 10px; }
}
@media (max-width: 560px) {
  .post { grid-template-columns: minmax(0, 1fr); }
  .order { display: flex; }
  .post__side { justify-content: flex-start; }
  .reviews-grid { grid-template-columns: 1fr; }
}

/* ---------- videos ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.add-video { display: grid; grid-template-columns: minmax(180px, 240px) minmax(0, 1fr); gap: 22px; align-items: start; }
.drop { display: grid; place-items: center; align-content: center; gap: 6px; min-height: 180px; padding: 18px; border: 1px dashed var(--line-2); border-radius: 14px; color: var(--muted); text-align: center; cursor: pointer; transition: border-color 0.2s, background-color 0.2s; }
.drop:hover { border-color: var(--accent); background: var(--accent-soft); }
#video-file:focus-visible + .drop { outline: 2px solid var(--accent); outline-offset: 2px; }
.drop__icon svg { width: 26px; height: 26px; }
.drop strong { color: var(--text); }
.drop small { font-size: 0.8rem; }
.drop__preview { display: grid; gap: 8px; margin-top: 12px; }
.drop__preview video { width: 100%; aspect-ratio: 9 / 16; max-height: 380px; object-fit: cover; border-radius: 12px; background: #000; }
.drop__preview span { color: var(--dim); font-size: 0.8rem; overflow-wrap: anywhere; }
.progress { height: 6px; overflow: hidden; border-radius: 999px; background: var(--line); }
.progress i { display: block; width: 0; height: 100%; background: var(--accent); transition: width 0.2s; }
.video-row { display: grid; grid-template-columns: 78px minmax(0, 1fr); gap: 16px; min-width: 0; }
.thumb { position: relative; display: grid; place-items: center; width: 78px; aspect-ratio: 9 / 16; padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: #000; cursor: pointer; }
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb span { padding: 6px; color: var(--dim); font-size: 0.7rem; }
.thumb__play { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0, 0, 0, 0.3); opacity: 0; transition: opacity 0.2s; }
.thumb:hover .thumb__play,
.thumb:focus-visible .thumb__play { opacity: 1; }
.thumb__play::before { content: ''; border-style: solid; border-width: 8px 0 8px 13px; border-color: transparent transparent transparent #fff; }
.star svg { fill: none; }
.star.is-on { color: var(--warn); border-color: rgba(255, 209, 102, 0.5); }
.star.is-on svg { fill: currentColor; }
.drawer-video { width: 100%; max-height: 70vh; border-radius: 12px; background: #000; }
@media (max-width: 820px) {
  .add-video { grid-template-columns: 1fr; }
}

/* hosting warning on the dashboard */
.card--warn { margin-bottom: 18px; border-color: rgba(255, 209, 102, 0.45); box-shadow: inset 3px 0 0 #ffd166; }
.card--warn .card__title { color: var(--warn); }
.card--warn .card__sub { color: var(--muted, #b9b4aa); }

/* ---------- bookings ---------- */
.stack { display: grid; gap: 20px; align-content: start; }
.booking-day + .booking-day { margin-top: 8px; }
.booking-day__title { margin: 20px 0 4px; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--dim); }
.booking-row { display: grid; grid-template-columns: 72px 1fr; gap: 16px; padding: 16px 0; border-top: 1px solid var(--line); }
.booking-row__time { display: grid; align-content: start; }
.booking-row__time strong { font-size: 1.15rem; font-variant-numeric: tabular-nums; }
.booking-row__time small { color: var(--dim); }
.booking-row__main { display: grid; gap: 8px; min-width: 0; }
.booking-row__top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.booking-row__msg { padding: 10px 12px; border-radius: 10px; background: rgba(255, 255, 255, 0.04); white-space: pre-wrap; font-size: 0.9rem; }
.badge--b-pending { border-color: rgba(255, 209, 102, 0.35); color: var(--warn); }
.badge--b-confirmed { border-color: rgba(58, 208, 123, 0.35); color: var(--ok); }
.badge--b-completed, .badge--b-cancelled { color: var(--dim); }
.badge--free { border-color: rgba(255, 74, 28, 0.45); background: var(--accent-soft); color: var(--accent); }

/* ---------- analytics ---------- */
.kpis--5 { grid-template-columns: repeat(5, 1fr); margin-bottom: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: 20px; align-items: start; }
.chart svg { width: 100%; height: 200px; }
.chart .bar-v { fill: rgba(255, 255, 255, 0.12); }
.chart .bar-u { fill: var(--accent); }
.legend { display: inline-flex; align-items: center; gap: 6px; color: var(--dim); font-size: 0.8rem; }
.legend i { width: 10px; height: 10px; border-radius: 3px; margin-left: 8px; }
.legend__u { background: var(--accent); }
.legend__v { background: rgba(255, 255, 255, 0.18); }
.rank { display: grid; gap: 6px; margin: 0 0 14px; padding: 0; list-style: none; }
.rank li { position: relative; display: flex; justify-content: space-between; gap: 12px; padding: 8px 10px; border-radius: 8px; overflow: hidden; font-size: 0.9rem; }
.rank li::before { content: ''; position: absolute; inset: 0; width: var(--w); background: var(--accent-soft); z-index: 0; }
.rank li > * { position: relative; }
.small-print { margin-top: 18px; font-size: 0.8rem; }
@media (max-width: 1100px) { .kpis--5 { grid-template-columns: repeat(3, 1fr); } .grid-3 { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .kpis--5 { grid-template-columns: repeat(2, 1fr); } .booking-row { grid-template-columns: 1fr; gap: 6px; } }

/* email alerts status (Settings) */
.email-status { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.email-status p { display: flex; align-items: center; gap: 10px; margin: 0; color: var(--muted); font-size: 0.9rem; }
.form-grid + .actions { margin-top: 18px; }
.email-status--stack { display: block; }
.email-connect { display: grid; gap: 16px; }
.email-connect > p { display: flex; align-items: center; gap: 10px; margin: 0; color: var(--muted); font-size: 0.9rem; }
.email-connect .form-grid + .actions { margin-top: 0; }

/* =========================================================
   Coaching business tools: calendar, bookings, availability,
   clients, account, activity log, dialogs
   ========================================================= */

/* nav sections, small buttons */
.sidebar__label { margin: 16px 12px 4px; font-family: var(--mono); font-size: 0.6rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--dim); }
.btn--danger-solid { background: #e5484d; color: #fff; }
.btn--danger-solid:hover { background: #f2555a; }
.btn--warn:hover { border-color: rgba(255, 138, 128, 0.5); color: var(--error); background: rgba(255, 138, 128, 0.06); }
.btn--icon { width: 34px; padding: 0; }
.link-btn { padding: 0; border: 0; background: none; color: var(--accent); font: inherit; font-size: 0.86rem; font-weight: 600; cursor: pointer; }
.link-btn:hover { text-decoration: underline; text-underline-offset: 3px; }
.small { font-size: 0.84rem; }
.stack--tight { gap: 14px; }
.actions--spaced { margin-top: 16px; }
.actions--center { justify-content: center; margin-top: 16px; }
.field--switch { align-content: end; padding-bottom: 9px; }
.avatar { display: grid; place-items: center; flex: none; width: 34px; height: 34px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-size: 0.76rem; font-style: normal; font-weight: 800; letter-spacing: 0.02em; }

/* login: forgotten password */
.login__forgot { justify-self: center; padding: 0; border: 0; background: none; color: var(--muted); font-size: 0.88rem; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.login__forgot:hover { color: var(--text); }
.login__help { display: grid; gap: 8px; padding: 14px 16px; border: 1px solid var(--line-2); border-radius: 12px; background: var(--field); font-size: 0.86rem; }
.login__help strong { color: var(--text); }

/* dialogs */
.modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; background: rgba(0, 0, 0, 0.62); }
.modal__box { display: grid; gap: 16px; width: min(470px, 100%); max-height: calc(100vh - 40px); overflow-y: auto; padding: 24px; border: 1px solid var(--line-2); border-radius: 18px; background: #161618; box-shadow: 0 40px 80px -30px #000; animation: pop 0.18s ease; }
.modal__box h2 { font-size: 1.2rem; font-weight: 750; line-height: 1.25; }
.modal__body { display: grid; gap: 12px; color: var(--muted); }
.modal__body strong { color: var(--text); }
.modal__actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.clash-list { display: grid; gap: 6px; margin: 0; padding-left: 18px; }
@keyframes pop { from { opacity: 0; transform: scale(0.97); } }

/* dashboard */
.kpi__hint { color: var(--dim); font-size: 0.78rem; }
.agenda { display: grid; }
.agenda__row { display: grid; grid-template-columns: 62px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 11px 0; border-top: 1px solid var(--line); }
.agenda__row:first-child { padding-top: 0; border-top: 0; }
.agenda__time,
.agenda__main { display: grid; min-width: 0; padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.agenda__time strong { font-size: 1.05rem; font-variant-numeric: tabular-nums; }
.agenda__time small,
.agenda__main span { color: var(--dim); font-size: 0.82rem; }
.agenda__main strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.agenda__main:hover strong { color: var(--accent); }
.agenda__side { display: flex; align-items: center; gap: 8px; }
.agenda__row.is-no_show .agenda__main strong { color: var(--dim); text-decoration: line-through; }
.all-good { display: flex; align-items: center; gap: 8px; color: var(--ok); font-weight: 600; }
.quick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.quick__btn { display: flex; align-items: center; gap: 10px; padding: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card-2); color: var(--text); font: inherit; font-size: 0.9rem; font-weight: 600; text-align: left; text-decoration: none; cursor: pointer; transition: border-color 0.2s; }
.quick__btn:hover { border-color: var(--accent); }
.quick__btn .ico { color: var(--accent); }

/* calendar toolbar */
.cal-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.cal-nav { display: flex; flex: 1 1 auto; align-items: center; gap: 8px; min-width: 0; }
.cal-nav .icon-btn svg { width: 18px; height: 18px; }
.cal-title { margin-left: 6px; overflow: hidden; font-size: 1.15rem; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.segmented { display: inline-flex; padding: 3px; border: 1px solid var(--line-2); border-radius: 11px; background: var(--field); }
.segmented button { padding: 6px 13px; border: 0; border-radius: 8px; background: none; color: var(--muted); font-size: 0.84rem; font-weight: 600; cursor: pointer; }
.segmented button:hover { color: var(--text); }
.segmented button.is-active { background: var(--text); color: var(--ink); }
.legend-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; color: var(--dim); font-size: 0.8rem; }
.legend-row > span { display: inline-flex; align-items: center; gap: 6px; }
.legend-row__tip { margin-left: auto; }
.sw { width: 12px; height: 12px; border-left: 3px solid var(--ok); border-radius: 3px; background: rgba(58, 208, 123, 0.2); }
.sw--pending { border-color: var(--warn); background: rgba(255, 209, 102, 0.22); }
.sw--completed { border-color: var(--dim); background: rgba(244, 241, 234, 0.12); }
.sw--no_show { border-color: var(--error); background: rgba(255, 138, 128, 0.2); }
.sw--off { border: 0; background: repeating-linear-gradient(135deg, rgba(255, 138, 128, 0.5) 0 2px, transparent 2px 4px); }

/* day / week grid */
.tgrid-wrap { min-width: 0; overflow-x: auto; border: 1px solid var(--line); border-radius: 18px; background: var(--card); }
.tgrid { --gutter: 56px; min-width: calc(var(--gutter) + var(--cols) * 118px); }
.tgrid--day { min-width: 0; }
.tgrid__head { display: grid; grid-template-columns: var(--gutter) repeat(var(--cols), minmax(0, 1fr)); border-bottom: 1px solid var(--line); }
.tgrid__day { display: grid; justify-items: center; align-content: start; gap: 3px; padding: 10px 4px; border-left: 1px solid var(--line); text-decoration: none; }
.tgrid__day small { font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim); }
.tgrid__day b { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; font-size: 1.2rem; font-stretch: 80%; font-weight: 800; line-height: 1; }
.tgrid__day:hover b { background: rgba(244, 241, 234, 0.07); }
.tgrid__day.is-today b { background: var(--accent); color: var(--ink); }
.tgrid__day em { max-width: 100%; overflow: hidden; color: var(--info); font-size: 0.62rem; font-style: normal; text-overflow: ellipsis; white-space: nowrap; }
.tgrid__body { display: grid; grid-template-columns: var(--gutter) minmax(0, 1fr); max-height: max(440px, calc(100vh - 280px)); overflow-y: auto; }
.tgrid__hours { position: relative; border-right: 1px solid var(--line); }
.tgrid__hours span { position: absolute; right: 8px; transform: translateY(-50%); font-family: var(--mono); font-size: 0.64rem; color: var(--dim); }
.tgrid__hours span:first-child { transform: translateY(4px); }
.tgrid__cols { position: relative; display: grid; grid-template-columns: repeat(var(--cols), minmax(0, 1fr)); }
.tgrid__cols::after { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; background-image: repeating-linear-gradient(to bottom, rgba(244, 241, 234, 0.07) 0 1px, transparent 1px var(--hour)); }
.tgrid__col { position: relative; border-left: 1px solid var(--line); background: rgba(0, 0, 0, 0.45); cursor: cell; }
.tgrid__col:first-child { border-left: 0; }
.tgrid__open { position: absolute; left: 0; right: 0; background: #19191c; pointer-events: none; }
.tgrid__col.is-today .tgrid__open { background: #1d1a1b; }
.tgrid__off { position: absolute; left: 0; right: 0; z-index: 1; overflow: hidden; border-block: 1px dashed rgba(255, 138, 128, 0.35); background: repeating-linear-gradient(135deg, rgba(255, 138, 128, 0.1) 0 6px, transparent 6px 12px), rgba(255, 138, 128, 0.04); cursor: default; }
.tgrid__off span { display: block; padding: 4px 6px; color: var(--error); font-size: 0.7rem; font-weight: 600; }
.tgrid__now { position: absolute; left: 0; right: 0; z-index: 3; height: 2px; background: var(--accent); pointer-events: none; }
.tgrid__now::before { content: ''; position: absolute; left: -4px; top: -3px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.ev { position: absolute; z-index: 2; display: grid; align-content: start; gap: 1px; padding: 4px 7px; overflow: hidden; border: 0; border-left: 3px solid var(--ok); border-radius: 6px; background: #1f3328; color: var(--text); font: inherit; font-size: 0.74rem; line-height: 1.25; text-align: left; cursor: pointer; transition: filter 0.15s; }
.ev strong { overflow: hidden; font-size: 0.78rem; text-overflow: ellipsis; white-space: nowrap; }
.ev span { overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; }
.ev--short { grid-auto-flow: column; justify-content: start; align-items: center; gap: 6px; padding-block: 1px; }
.ev:hover { filter: brightness(1.22); }
.ev:focus-visible { outline-offset: 0; }
.ev.is-pending { border-left-color: var(--warn); background: #3a3220; }
.ev.is-completed { border-left-color: var(--dim); background: #26262a; }
.ev.is-no_show { border-left-color: var(--error); background: #3b2423; }

/* day view */
.week-strip { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.week-strip__day { display: grid; justify-items: center; gap: 2px; padding: 8px 4px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); text-decoration: none; }
.week-strip__day small { font-family: var(--mono); font-size: 0.6rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); }
.week-strip__day b { font-size: 1.1rem; }
.week-strip__day.is-today b { color: var(--accent); }
.week-strip__day.is-active { border-color: var(--accent); background: var(--accent-soft); }
.week-strip__n { min-height: 1.2em; color: var(--ok); font-size: 0.7rem; font-style: normal; font-weight: 700; }
.day-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 20px; align-items: start; }
.day-list { display: grid; gap: 14px; }
.day-list .card__head { margin-bottom: 0; }
.off-note { display: flex; align-items: center; gap: 8px; color: var(--error); font-size: 0.86rem; }

/* month view */
.mgrid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 1px; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: var(--line); }
.mgrid__head { padding: 10px 6px; background: var(--card); font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.12em; text-align: center; text-transform: uppercase; color: var(--dim); }
.mcell { display: flex; flex-direction: column; gap: 4px; min-width: 0; min-height: 112px; padding: 8px; overflow: hidden; background: var(--card); text-decoration: none; transition: background-color 0.15s; }
.mcell:hover { background: var(--card-2); }
.mcell.is-closed { background: #111113; }
.mcell.is-other { background: #0f0f11; }
.mcell.is-other .mcell__n { color: var(--dim); }
.mcell.is-off { background: repeating-linear-gradient(135deg, rgba(255, 138, 128, 0.07) 0 6px, transparent 6px 12px), var(--card); }
.mcell__n { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; font-size: 0.88rem; }
.mcell.is-today .mcell__n { background: var(--accent); color: var(--ink); }
.mcell__off { overflow: hidden; color: var(--error); font-size: 0.7rem; text-overflow: ellipsis; white-space: nowrap; }
.mcell__more { color: var(--dim); font-size: 0.7rem; }
.mchip { overflow: hidden; padding: 2px 6px; border-left: 2px solid var(--ok); border-radius: 4px; background: #1f3328; font-size: 0.72rem; text-overflow: ellipsis; white-space: nowrap; }
.mchip.is-pending { border-color: var(--warn); background: #3a3220; }
.mchip.is-completed { border-color: var(--dim); background: #26262a; }
.mchip.is-no_show { border-color: var(--error); background: #3b2423; }

/* booking list */
.blist { display: grid; padding-top: 4px; }
.blist > .booking-day:first-child .booking-day__title { margin-top: 0; }
.brow { display: flex; align-items: center; gap: 10px; border-top: 1px solid var(--line); }
.booking-day__title + .brow { border-top: 0; }
.brow__open { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 14px; align-items: center; flex: 1; min-width: 0; padding: 12px 2px; border: 0; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.brow__open:hover .brow__who strong { color: var(--accent); }
.brow__time { display: grid; }
.brow__time strong { font-variant-numeric: tabular-nums; }
.brow__time small { color: var(--dim); font-size: 0.8rem; }
.brow__who { display: grid; min-width: 0; }
.brow__who strong,
.brow__who small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brow__who small { color: var(--dim); font-size: 0.82rem; }
.brow__badges { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.badge--b-no_show { border-color: rgba(255, 138, 128, 0.4); color: var(--error); }
.badge--paid { border-color: rgba(58, 208, 123, 0.35); color: var(--ok); }
.badge--unpaid { border-color: rgba(255, 209, 102, 0.3); color: var(--warn); }
.mini--btn { width: 100%; border: 0; border-top: 1px solid var(--line); background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.mini--btn:first-child { border-top: 0; }
.mini.is-muted { opacity: 0.55; }
.mini__side { display: flex; flex-wrap: wrap; justify-content: flex-end; }

/* booking panel */
.when-card { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 1px solid var(--line-2); border-radius: 14px; background: var(--card-2); }
.when-card__icon svg { width: 24px; height: 24px; fill: none; stroke: var(--accent); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.when-card strong { display: block; }
.when-card span { color: var(--muted); font-size: 0.9rem; }
.notice { display: grid; gap: 10px; padding: 14px 16px; border: 1px solid rgba(37, 211, 102, 0.35); border-radius: 14px; background: rgba(37, 211, 102, 0.07); }
.subcard { display: grid; gap: 14px; padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: rgba(255, 255, 255, 0.015); }
.subcard > .label,
.subsection > .label { margin: 0; }
.subsection { display: grid; gap: 10px; }
.form-grid--3 { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 0.8fr); }
.checks { display: grid; gap: 6px; }
.checks:empty { display: none; }
.check { display: flex; align-items: center; gap: 8px; font-size: 0.86rem; }
.check--bad { color: var(--error); }
.check--warn { color: var(--warn); }
.check--ok { color: var(--ok); }
.free-times { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.free-times:empty { display: none; }
.free-times__label { margin-right: 2px; color: var(--dim); font-size: 0.8rem; }
.time-chip { padding: 5px 9px; border: 1px solid var(--line-2); border-radius: 8px; background: none; color: var(--text); font-family: var(--mono); font-size: 0.76rem; cursor: pointer; }
.time-chip:hover,
.time-chip.is-active { border-color: var(--accent); color: var(--accent); }
.menu { position: relative; }
.menu > summary { list-style: none; }
.menu > summary::-webkit-details-marker { display: none; }
.menu__list { position: absolute; top: calc(100% + 6px); left: 0; z-index: 6; display: grid; min-width: 200px; padding: 6px; border: 1px solid var(--line-2); border-radius: 12px; background: #1c1c1f; box-shadow: 0 20px 40px -18px #000; }
.menu__list a { padding: 9px 10px; border-radius: 8px; font-size: 0.88rem; text-decoration: none; }
.menu__list a:hover { background: rgba(244, 241, 234, 0.06); }
.timeline { display: grid; gap: 12px; margin: 0; padding: 0 0 0 16px; border-left: 1px solid var(--line-2); list-style: none; }
.timeline li { position: relative; display: grid; gap: 2px; font-size: 0.88rem; }
.timeline li::before { content: ''; position: absolute; top: 7px; left: -20px; width: 7px; height: 7px; border-radius: 50%; background: var(--line-2); }
.timeline small { color: var(--dim); font-size: 0.76rem; }

/* new booking: finding the client */
.suggest { display: grid; margin-top: 6px; overflow: hidden; border: 1px solid var(--line-2); border-radius: 10px; background: var(--field); }
.suggest button { display: grid; gap: 1px; padding: 9px 12px; border: 0; border-top: 1px solid var(--line); background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.suggest button:first-child { border-top: 0; }
.suggest button:hover,
.suggest button:focus-visible { background: rgba(244, 241, 234, 0.05); }
.suggest small { color: var(--dim); font-size: 0.8rem; }
.chosen { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 12px; background: var(--card-2); }
.chosen__main { display: grid; flex: 1; min-width: 0; }
.chosen__main small { overflow: hidden; color: var(--dim); font-size: 0.82rem; text-overflow: ellipsis; white-space: nowrap; }

/* availability */
.card--warn .card__title { color: var(--warn); }
.wh-list { display: grid; }
.wh { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 6px 16px; align-items: start; padding: 12px 0; border-top: 1px solid var(--line); }
.wh:first-child { padding-top: 0; border-top: 0; }
.wh__day { padding-top: 9px; }
.wh__ranges > .muted { display: inline-block; padding-top: 9px; font-size: 0.9rem; }
.wh__error { grid-column: 2; }
.ranges { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.range { display: inline-flex; align-items: center; gap: 8px; }
.input--time { width: 112px; min-height: 38px; padding: 6px 10px; font-variant-numeric: tabular-nums; }
.range__to { color: var(--dim); font-size: 0.84rem; }
.range .icon-btn { width: 32px; height: 32px; }
.savebar.savebar--float { position: sticky; bottom: 16px; z-index: 6; display: flex; align-items: center; justify-content: flex-end; gap: 10px; padding: 12px 14px; border: 1px solid var(--line-2); border-radius: 14px; background: rgba(28, 28, 31, 0.95); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); box-shadow: 0 20px 40px -20px #000; }
.savebar--float > span { margin-right: auto; color: var(--warn); font-size: 0.88rem; font-weight: 600; }
.rows { display: grid; margin: 0; padding: 0; list-style: none; }
.row { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.row:first-child { padding-top: 0; border-top: 0; }
.row__icon { display: grid; place-items: center; flex: none; width: 34px; height: 34px; border-radius: 10px; background: var(--card-2); color: var(--muted); }
.row__icon svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.row__main { display: grid; flex: 1; min-width: 0; }
.row__main strong { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.row__main small { color: var(--dim); font-size: 0.82rem; }
.preview li { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 10px; }
.preview li strong { color: var(--text); font-size: 0.88rem; }
.preview li span { font-family: var(--mono); font-size: 0.76rem; line-height: 1.7; }

/* clients */
.list--clients .list__head,
.list--clients .item { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1.2fr) minmax(0, 0.8fr) minmax(0, 0.9fr) 96px; }
.item__who--avatar { display: flex; align-items: center; gap: 12px; }
.item__who--avatar > span { display: grid; min-width: 0; }
.item__who--avatar strong,
.item__who--avatar small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item__who--avatar small { color: var(--dim); font-size: 0.82rem; }
.owed { color: var(--warn); font-weight: 600; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.stat { display: grid; gap: 6px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--card-2); }
.stat span { font-family: var(--mono); font-size: 0.58rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); }
.stat strong { font-size: 1.5rem; font-stretch: 75%; font-weight: 800; line-height: 1; }
.stat--warn strong { color: var(--error); }
.stat--accent strong { color: var(--warn); }
.pkgs { display: grid; gap: 8px; }
.pkg { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; }
.pkg.is-done { opacity: 0.6; }
.pkg__main { display: grid; flex: 1; gap: 4px; min-width: 0; }
.pkg__main small { color: var(--dim); font-size: 0.8rem; }
.pkg__side { display: flex; align-items: center; gap: 6px; }
.meter { display: block; height: 6px; overflow: hidden; border-radius: 999px; background: var(--line); }
.meter i { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.danger-zone { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border: 1px solid rgba(255, 138, 128, 0.3); border-radius: 14px; background: rgba(255, 138, 128, 0.05); }
.danger-zone > div { display: grid; }
.danger-zone small { color: var(--dim); }

/* account */
.copy-row { display: flex; gap: 8px; }
.input--mono { font-family: var(--mono); font-size: 0.74rem; }
.steps { display: grid; gap: 8px; margin: 16px 0 0; padding-left: 18px; color: var(--muted); font-size: 0.88rem; }
.steps strong { color: var(--text); }

/* activity log */
.log { display: grid; margin: 0; padding: 0; list-style: none; }
.log__row { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 12px; align-items: baseline; padding: 10px 0; border-top: 1px solid var(--line); font-size: 0.9rem; }
.log__row:first-child { border-top: 0; }
.log__time { color: var(--dim); font-family: var(--mono); font-size: 0.76rem; }
.log__who { color: var(--dim); font-size: 0.8rem; white-space: nowrap; }
.log__link { padding: 0; border: 0; background: none; color: inherit; font: inherit; text-align: left; text-decoration: none; cursor: pointer; }
.log__link:hover { color: var(--accent); }
.log__row.is-alert .log__text { color: var(--warn); }

@media (max-width: 1060px) {
  .day-layout { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .cal-title { font-size: 1rem; }
  .legend-row .legend-row__tip { display: none; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .form-grid.form-grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .list--clients .item { grid-template-columns: minmax(0, 1fr) auto; }
  .tgrid__body { max-height: none; overflow: visible; }
}
@media (max-width: 640px) {
  /* phones: keep the top bar to one line; the secondary actions are on the page itself */
  .topbar__actions .btn--ghost { display: none; }
  .topbar__actions { flex-wrap: nowrap; }
  .topbar__title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .tgrid--day .tgrid__head { display: none; }
  .brow__open { grid-template-columns: 52px minmax(0, 1fr); }
  .brow__badges { grid-column: 2; justify-content: flex-start; }
  .mcell { min-height: 64px; padding: 5px; }
  .mchip { height: 6px; padding: 0; font-size: 0; }
  .mcell__more,
  .mcell__off { display: none; }
  .log__row { grid-template-columns: 44px minmax(0, 1fr); }
  .log__who { grid-column: 2; }
  .quick { grid-template-columns: 1fr; }
  .copy-row { flex-direction: column; }
  .cal-toolbar { align-items: stretch; }
  .segmented { justify-content: space-between; }
  .segmented button { flex: 1; }
}
@media (max-width: 560px) {
  .wh { grid-template-columns: 1fr; }
  .wh__day { padding-top: 0; }
  .wh__error { grid-column: 1; }
  .agenda__row { grid-template-columns: 52px minmax(0, 1fr) auto; }
}

/* users & access */
.user-card { display: grid; gap: 14px; }
.user-card.is-off { opacity: 0.7; }
.user-card__head { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }
.user-card__who { flex: 1; min-width: 0; }
.avatar--lg { width: 44px; height: 44px; font-size: 0.9rem; }
.perms { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.perm { display: grid; gap: 6px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card-2); }
.perm small { color: var(--dim); font-size: 0.78rem; }
.check-list { display: grid; gap: 8px; }
.check-row { display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.check-row input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--accent); }
.check-row span { display: grid; }
.check-row small { color: var(--dim); font-size: 0.8rem; }

/* TechScot panel: same layout, its own blue-violet accent */
body.platform { --accent: #9cc7a8; --accent-2: #b4d6bd; --accent-soft: rgba(156, 199, 168, 0.14); }
body.platform .input:focus { box-shadow: 0 0 0 3px rgba(156, 199, 168, 0.22); }
body.platform .kpi--accent { border-color: rgba(156, 199, 168, 0.5); box-shadow: inset 0 3px 0 #9cc7a8; }
body.platform .badge--new,
body.platform .badge--free { border-color: rgba(156, 199, 168, 0.45); }
.st-brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-family: 'Fraunces', Georgia, serif; font-size: 1.2rem; font-weight: 600; letter-spacing: -0.01em; text-decoration: none; }
.st-brand svg { flex: none; width: 34px; height: 34px; }
.st-brand b { color: #9cc7a8; font-style: italic; font-weight: 500; }
.login__card .st-brand { margin-bottom: 10px; }
.login__back { justify-self: center; color: var(--dim); font-size: 0.86rem; text-decoration: none; }
.login__back:hover { color: var(--text); }
.st-offer { border-color: rgba(214, 177, 98, 0.45); box-shadow: inset 3px 0 0 #d6b162; }
.feat-group { display: grid; gap: 8px; margin-top: 6px; }
.feat-group > .label { margin: 0; }
.list--sites .list__head,
.list--sites .item { grid-template-columns: minmax(0, 1.5fr) 120px minmax(0, 1fr) minmax(0, 1.1fr) 96px; }
.list--leads .list__head,
.list--leads .item { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) 110px minmax(0, 1.1fr) 120px; }
.price-row { display: grid; grid-template-columns: 120px minmax(0, 1fr) minmax(0, 1fr) 76px; gap: 14px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.price-row:first-child { border-top: 0; padding-top: 0; }
.price-row .field__error:empty { display: none; }
.price-row__off { justify-self: end; padding: 3px 9px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-size: 0.76rem; font-weight: 700; white-space: nowrap; }
@media (max-width: 900px) {
  .list--sites .item,
  .list--leads .item { grid-template-columns: minmax(0, 1fr) auto; }
  .price-row { grid-template-columns: 1fr 1fr; }
  .price-row > strong { grid-column: 1 / -1; }
  .price-row__off { grid-column: 1 / -1; justify-self: start; }
}

/* PT panel: website name (sites other than SernaFit), "Software by TechScot", Refer a PT */
.brand__text { font-size: 1.2rem; font-stretch: 80%; font-weight: 850; letter-spacing: -0.01em; line-height: 1.1; text-transform: uppercase; color: var(--text); }
.sidebar__foot .sidebar__powered { display: flex; align-items: baseline; gap: 5px; margin: 0 0 6px; padding: 8px 10px; border: 1px dashed var(--line-2); border-radius: 10px; color: var(--dim); font-size: 0.76rem; text-decoration: none; }
.sidebar__foot .sidebar__powered b { color: #9cc7a8; font-weight: 700; }
.sidebar__foot .sidebar__powered:hover { border-color: rgba(156, 199, 168, 0.5); color: var(--muted); }
.refer { box-shadow: inset 3px 0 0 #9cc7a8; }
.refer__eyebrow { margin: 0; font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: #9cc7a8; }
.refer__title { margin: 6px 0 8px; font-size: clamp(1.6rem, 3vw, 2.2rem); font-stretch: 80%; font-weight: 850; line-height: 1.02; text-transform: uppercase; }
.refer .copy-row { margin-top: 16px; }
.refer-stat { display: grid; gap: 6px; }
.refer-stat__value { font-size: 3rem; font-weight: 850; line-height: 1; font-variant-numeric: tabular-nums; }

/* TechScot panel: recording the sales video's voice-over */
.tips { display: grid; gap: 8px; margin: 14px 0 0; padding-left: 18px; color: var(--muted); font-size: 0.9rem; }
.voice-part { display: grid; gap: 12px; }
.voice-part__head { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.voice-part__head .card__title { flex: 1; min-width: 0; }
.voice-part__n { display: grid; place-items: center; width: 30px; height: 30px; border: 1px solid var(--line-2); border-radius: 50%; color: var(--accent); font-family: var(--mono); font-size: 0.8rem; }
.voice-part__line { color: var(--text); font-family: 'Fraunces', Georgia, serif; font-size: 1.12rem; line-height: 1.5; }
.voice-part__audio, .rec-preview audio { width: 100%; height: 40px; }
.rec-box { display: grid; gap: 14px; padding: 18px; border: 1px solid var(--line-2); border-radius: 14px; background: var(--card-2); transition: border-color 0.2s; }
.rec-box.is-live { border-color: #e5484d; }
.rec-line { color: var(--text); font-family: 'Fraunces', Georgia, serif; font-size: 1.5rem; line-height: 1.45; }
.rec-bar { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 0.88rem; }
.rec-state { flex: 1; }
.rec-timer { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.rec-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--line-2); }
.rec-box.is-live .rec-dot { background: #e5484d; animation: recPulse 1s ease-in-out infinite; }
@keyframes recPulse { 50% { opacity: 0.35; } }
.rec-meter { height: 6px; overflow: hidden; border-radius: 3px; background: rgba(244, 241, 234, 0.08); }
.rec-meter i { display: block; width: 0; height: 100%; border-radius: 3px; background: var(--accent); transition: width 0.06s linear; }
.rec-meter.is-hot i { background: #e5484d; }
.rec-preview { display: grid; gap: 12px; }
.rec-preview:empty { display: none; }

/* ---------- the client area (a trainer's clients, at /client) ---------- */
body.client { min-height: 100vh; }
.cl-gate { gap: 14px; }
.cl-gate h1 { font-size: 1.7rem; }
.cl-gate__links { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 16px; }
.cl-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.cl-app { width: min(760px, 100%); margin: 0 auto; padding: 0 16px 48px; }
.cl-top { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 12px; padding: 14px 0; background: var(--bg); }
.cl-top__brand .brand__logo { height: 34px; }
.cl-top__who { flex: 1; min-width: 0; overflow: hidden; color: var(--muted); font-size: 0.9rem; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
.cl-tabs { position: sticky; top: 62px; z-index: 9; display: flex; gap: 4px; margin: 0 -16px 18px; padding: 6px 16px 10px; overflow-x: auto; border-bottom: 1px solid var(--line); background: var(--bg); scrollbar-width: none; }
.cl-tabs::-webkit-scrollbar { display: none; }
.cl-tabs a { display: inline-flex; align-items: center; gap: 6px; flex: none; padding: 8px 13px; border-radius: 999px; color: var(--muted); font-size: 0.92rem; font-weight: 600; text-decoration: none; }
.cl-tabs a:hover { color: var(--text); }
.cl-tabs a.is-active { background: var(--accent-soft); color: var(--accent); }
.cl-tabs .count { margin-left: 2px; }
.cl-view { display: grid; gap: 16px; }
.cl-hello h1 { font-size: clamp(1.8rem, 6vw, 2.4rem); font-stretch: 80%; font-weight: 850; line-height: 1; text-transform: uppercase; }
.cl-hello p { margin-top: 6px; }
.cl-next { display: grid; gap: 6px; border-color: rgba(255, 74, 28, 0.45); box-shadow: inset 3px 0 0 var(--accent); }
.cl-next--none { border-color: var(--line); background: var(--card); }
.cl-next .label { margin: 0; }
.cl-next__when { font-size: clamp(1.3rem, 5vw, 1.7rem); font-weight: 800; }
.cl-next__what { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--muted); }
.cl-next .actions { margin-top: 10px; }
.cl-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.cl-ask { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; }
.cl-contact { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.cl-list { display: grid; }
.cl-session { display: grid; grid-template-columns: 112px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.cl-session:first-child { border-top: 0; }
.cl-session__when, .cl-session__what { display: grid; min-width: 0; }
.cl-session__when span, .cl-session__what span { color: var(--muted); font-size: 0.86rem; }
.cl-session__what strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cl-session__side { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px; }
.cl-days { display: flex; gap: 8px; margin: 0 -4px; padding: 0 4px 6px; overflow-x: auto; scrollbar-width: thin; }
.cl-day { display: grid; justify-items: center; flex: none; min-width: 64px; padding: 9px 8px; border: 1px solid var(--line-2); border-radius: 12px; background: transparent; color: var(--text); cursor: pointer; }
.cl-day small { color: var(--muted); font-size: 0.74rem; }
.cl-day b { font-size: 1.25rem; }
.cl-day.is-on { border-color: var(--accent); background: var(--accent-soft); }
.cl-day.is-on small { color: var(--accent); }
.cl-times { display: flex; flex-wrap: wrap; gap: 8px; }
.cl-times .time-chip { padding: 9px 13px; font-size: 0.86rem; }
.cl-done { display: grid; justify-items: center; gap: 10px; padding: 34px 20px; text-align: center; }
.cl-done__tick { position: relative; width: 56px; height: 56px; border-radius: 50%; background: var(--ok); }
.cl-done__tick::after { content: ''; position: absolute; top: 19px; left: 18px; width: 20px; height: 10px; border-bottom: 3px solid #0b0b0c; border-left: 3px solid #0b0b0c; transform: rotate(-45deg); }
.cl-notes { display: grid; }
.cl-note { display: grid; gap: 6px; padding: 14px 0; border-top: 1px solid var(--line); }
.cl-note:first-child { border-top: 0; padding-top: 4px; }
.cl-note__body { white-space: pre-wrap; }
.cl-note__stars { color: var(--warn); letter-spacing: 2px; }
.cl-stars { display: flex; gap: 4px; }
.cl-star { width: 42px; height: 42px; border: 1px solid var(--line-2); border-radius: 10px; background: transparent; color: var(--dim); cursor: pointer; font-size: 1.3rem; }
.cl-star.is-on { border-color: rgba(255, 209, 102, 0.6); color: var(--warn); }
@media (max-width: 560px) {
  /* Phone: when and what on top, the status badge beside them, the buttons in a row underneath. */
  .cl-session { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); row-gap: 10px; }
  .cl-session__side { grid-column: 1 / -1; justify-content: flex-start; }
  .cl-session__side .badge { order: -1; }
  .cl-session__side .btn { flex: 1 1 auto; justify-content: center; }
  .cl-session__what strong { white-space: normal; }
}

/* ---------- PT panel: client accounts ---------- */
.ca-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 16px; align-items: center; padding: 14px 0; border-top: 1px solid var(--line); }
.ca-row:first-child { border-top: 0; }
.ca-row__who { display: grid; min-width: 0; }
.ca-row__who small { color: var(--muted); }
.ca-row__who .badge { justify-self: start; }
.ca-row__msg { grid-column: 1 / -1; padding: 10px 12px; border-radius: 10px; background: var(--card-2); color: var(--muted); font-size: 0.9rem; white-space: pre-wrap; }
.ca-row .actions { justify-content: flex-end; }
.fb-item { display: grid; gap: 6px; padding: 14px 0; border-top: 1px solid var(--line); }
.fb-item:first-child { border-top: 0; }
.fb-item.is-new { position: relative; padding-left: 14px; }
.fb-item.is-new::before { content: ''; position: absolute; top: 20px; left: 0; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.fb-item__stars { color: var(--warn); letter-spacing: 2px; }
.fb-item__body { white-space: pre-wrap; }
.link-box { display: grid; gap: 10px; }
.link-box .input { font-family: var(--mono); font-size: 0.8rem; }
.cl-ask--warn { border-color: rgba(229, 103, 63, 0.55); }
.mode-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.mode-card { position: relative; display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }
.mode-card:has(input:checked) { border-color: var(--accent); background: var(--card-2); }
.mode-card input { margin-top: 3px; accent-color: var(--accent); }
.mode-card__body { display: grid; gap: 2px; }
.mode-card__body small { color: var(--muted); }
.pw-row { display: flex; gap: 6px; }
.pw-row .input { flex: 1; min-width: 0; }
.login-card { padding: 12px 14px; border-radius: 12px; background: var(--card-2); }
.login-card code { font-size: 1.02em; letter-spacing: 0.02em; }

/* Client area: password Show / Hide, offline message */
.pw-wrap { position: relative; display: block; }
.pw-wrap .input { padding-right: 68px; }
.pw-toggle { position: absolute; top: 50%; right: 6px; transform: translateY(-50%); padding: 6px 10px; border: 0; border-radius: 6px; background: transparent; color: var(--muted, #6b6b6b); font: inherit; font-size: 0.8rem; font-weight: 600; cursor: pointer; }
.pw-toggle:hover, .pw-toggle:focus-visible { color: var(--text, #111); background: rgba(127, 127, 127, 0.12); }
.cl-offline { max-width: 340px; margin: 0 auto; text-align: center; justify-items: center; }

/* Bookings: Simple / Calendar switch, and the simple list */
.modebar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-bottom: 16px; }
.segmented--mode button { min-width: 96px; }
.modebar__tip { font-size: 0.82rem; }
.sblock { display: grid; gap: 10px; }
.sblock + .sblock { margin-top: 14px; }
.sblock__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.sblock__n { color: var(--dim); font-size: 0.82rem; font-weight: 600; }
.sblock__empty { margin: 0; padding: 14px 0 4px; color: var(--dim); }
.sblock__tip { margin: 16px 2px 0; }
.slist { display: grid; }
.srow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 14px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.slist > .srow:first-child { border-top: 0; }
.srow__open { display: grid; grid-template-columns: 76px minmax(0, 1fr) auto; gap: 14px; align-items: center; min-width: 0; padding: 4px 6px; margin: -4px -6px; border: 0; border-radius: 10px; background: none; color: inherit; font: inherit; text-align: left; cursor: pointer; transition: background-color 0.15s; }
.srow__open:hover { background: rgba(127, 127, 127, 0.08); }
.srow__time, .srow__who { display: grid; min-width: 0; }
.srow__time strong { font-size: 1.15rem; font-variant-numeric: tabular-nums; }
.srow__time small, .srow__who small { color: var(--dim); font-size: 0.82rem; }
.srow__who strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.srow__badges { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
.srow__acts { display: flex; gap: 8px; }
.srow.is-pending .srow__time strong { color: var(--accent); }
@media (max-width: 640px) {
  .srow { grid-template-columns: 1fr; }
  .srow__open { grid-template-columns: 64px minmax(0, 1fr); }
  .srow__badges { grid-column: 2; justify-content: flex-start; }
  .srow__acts:empty { display: none; }
  .srow__acts .btn { flex: 1; justify-content: center; }
}

/* Quiet, purposeful motion in the panels: each page's cards settle in one after another (no bounce,
   no glow), and rows lift a touch under the pointer. */
@media (prefers-reduced-motion: no-preference) {
  #view > *, .view > * { animation: panel-in 0.42s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
  #view > :nth-child(2), .view > :nth-child(2) { animation-delay: 40ms; }
  #view > :nth-child(3), .view > :nth-child(3) { animation-delay: 80ms; }
  #view > :nth-child(4), .view > :nth-child(4) { animation-delay: 120ms; }
  #view > :nth-child(n + 5), .view > :nth-child(n + 5) { animation-delay: 160ms; }
  .srow, .brow, .cl-session { transition: background-color 0.15s; }
}
@keyframes panel-in { from { opacity: 0; transform: translateY(8px); } }

/* Settings > Emails to your clients: the list and the preview */
.email-list { margin-top: 6px; }
.email-list .rows { margin-top: 8px; }
.modal__box:has(.email-preview) { width: min(680px, 100%); }
.email-preview { display: block; width: 100%; height: min(70vh, 720px); border: 1px solid var(--line-2); border-radius: 10px; background: #f3f1ec; }
.agenda__auto { font-size: 0.75rem; }

/* Client app: Messages */
.cl-msgs { display: grid; }
.cl-msg { display: grid; gap: 8px; padding: 18px 0; border-top: 1px solid var(--line); }
.cl-msg:first-child { padding-top: 4px; border-top: 0; }
.cl-msg__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0; color: var(--dim); font-size: 0.8rem; }
.cl-msg__tag { padding: 2px 8px; border: 1px solid var(--line-2); border-radius: 999px; color: var(--muted); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.cl-msg.is-new .cl-msg__tag { border-color: var(--accent); color: var(--accent); }
.cl-msg__title { margin: 0; font-size: 1.05rem; }
.cl-msg__details { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 4px 14px; margin: 2px 0; padding: 10px 14px; border-left: 3px solid var(--accent); border-radius: 0 8px 8px 0; background: rgba(127, 127, 127, 0.06); font-size: 0.9rem; }
.cl-msg__details dt { color: var(--dim); }
.cl-msg__details dd { margin: 0; }
.cl-msg__body p { margin: 0 0 6px; color: var(--muted); }
.cl-msg .btn { justify-self: start; }

/* ---------- App feel: the client app and the trainer panel on phones (and installed) ---------- */
html { -webkit-tap-highlight-color: transparent; }
button, a, .btn, input, select, textarea { touch-action: manipulation; }
@media (display-mode: standalone) {
  html, body { overscroll-behavior-y: none; }
  .login__back { display: none; }
}
.cl-tabs svg, .tabbar svg { flex: none; width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.cl-avatar { display: none; }
.tabbar { display: none; }

/* Get the app */
.install { display: flex; align-items: center; gap: 16px; }
.install__icon img { display: block; width: 48px; height: 48px; border-radius: 12px; }
.install__text { flex: 1; min-width: 0; }
.install__text .card__title { margin-bottom: 2px; }

/* Client app: the "more" list on the Account page */
.cl-more { display: grid; padding: 4px 18px; }
.cl-more__row { display: flex; align-items: center; justify-content: space-between; min-height: 52px; padding: 0; border: 0; border-top: 1px solid var(--line); background: none; color: var(--text); font: inherit; font-weight: 600; text-align: left; text-decoration: none; cursor: pointer; }
.cl-more__row:first-child { border-top: 0; }
.cl-more__row i { color: var(--dim); font-size: 1.4rem; font-style: normal; }
.cl-more__out { color: var(--error); }

/* Sign-in on a phone: full screen, no floating card. */
@media (max-width: 560px) {
  .login { place-items: stretch; padding: 0; }
  .login__card { width: 100%; min-height: 100svh; align-content: center; padding: calc(28px + env(safe-area-inset-top)) 22px calc(28px + env(safe-area-inset-bottom)); border: 0; border-radius: 0; box-shadow: none; background: var(--bg); }
  .input { font-size: 16px; } /* stops iPhones zooming in on the box */
}

/* Client app on a phone: a slim header with the account avatar, and a tab bar at the bottom. */
@media (max-width: 720px) {
  .cl-app { padding: 0 16px calc(96px + env(safe-area-inset-bottom)); }
  .cl-top { justify-content: space-between; margin: 0 -16px 14px; padding: calc(10px + env(safe-area-inset-top)) 16px 10px; border-bottom: 1px solid var(--line); background: rgba(13, 13, 15, 0.92); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
  .cl-top__brand .brand__logo { height: 28px; }
  .cl-top__who, .cl-top__out { display: none; }
  .cl-avatar { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-size: 0.82rem; font-weight: 800; letter-spacing: 0.02em; text-decoration: none; }
  .cl-tabs { position: fixed; top: auto; right: 0; bottom: 0; left: 0; z-index: 20; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 0; margin: 0; padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); overflow: visible; border-top: 1px solid var(--line); border-bottom: 0; background: rgba(17, 17, 19, 0.94); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
  .cl-tabs a { position: relative; flex-direction: column; justify-content: center; gap: 3px; padding: 7px 2px 5px; border-radius: 12px; font-size: 0.66rem; font-weight: 600; letter-spacing: 0.01em; }
  .cl-tabs a.is-active { background: none; color: var(--accent); }
  .cl-tabs a.is-active svg { stroke-width: 2.2; }
  .cl-tabs svg { width: 22px; height: 22px; }
  .cl-tabs [data-route="notes"], .cl-tabs [data-route="feedback"] { display: none; }
  .cl-tabs .count { position: absolute; top: 2px; left: calc(50% + 5px); min-width: 17px; margin: 0; padding: 1px 5px; font-size: 0.62rem; }
  .toasts { right: 16px; bottom: calc(84px + env(safe-area-inset-bottom)); left: 16px; max-width: none; }
}

/* Trainer panel on a phone: Today, Bookings, Clients, Messages and More at the bottom. */
@media (max-width: 820px) {
  .topbar { padding-top: calc(10px + env(safe-area-inset-top)); }
  .topbar__menu { display: none; }
  .view { padding-bottom: calc(100px + env(safe-area-inset-bottom)); }
  .sidebar { padding-top: calc(20px + env(safe-area-inset-top)); padding-bottom: calc(20px + env(safe-area-inset-bottom)); }
  .tabbar { position: fixed; right: 0; bottom: 0; left: 0; z-index: 25; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: rgba(17, 17, 19, 0.94); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
  .tabbar a, .tabbar button { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 7px 2px 5px; border: 0; border-radius: 12px; background: none; color: var(--muted); font: inherit; font-size: 0.66rem; font-weight: 600; text-decoration: none; cursor: pointer; }
  .tabbar .is-active { color: var(--accent); }
  .tabbar .is-active svg { stroke-width: 2.2; }
  .tabbar svg { width: 22px; height: 22px; }
  .tabbar .count { position: absolute; top: 2px; left: calc(50% + 5px); min-width: 17px; margin: 0; padding: 1px 5px; font-size: 0.62rem; }
  .savebar, .savebar.savebar--float { bottom: calc(76px + env(safe-area-inset-bottom)); }
  .toasts { right: 16px; bottom: calc(84px + env(safe-area-inset-bottom)); left: 16px; max-width: none; }
  .drawer__panel { padding-top: env(safe-area-inset-top); padding-bottom: env(safe-area-inset-bottom); }
}

/* ---------- Chat (client app and trainer panel) ---------- */
.chat { display: grid; gap: 12px; }
.chat__head { display: flex; align-items: center; gap: 12px; padding: 4px 2px 10px; border-bottom: 1px solid var(--line); }
.chat__head strong { display: block; font-size: 1.05rem; }
.chat__head small { color: var(--dim); }
.chat__avatar { display: grid; flex: none; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-size: 0.85rem; font-weight: 800; letter-spacing: 0.02em; }
.chat__thread { display: flex; flex-direction: column; gap: 8px; min-height: 30vh; padding: 4px 0 8px; }
.chat__day { align-self: center; margin: 10px 0 4px; padding: 3px 12px; border-radius: 999px; background: rgba(127, 127, 127, 0.1); color: var(--dim); font-size: 0.74rem; font-weight: 600; }
.chat__empty { margin: 30px auto; max-width: 300px; color: var(--dim); text-align: center; }
.bubble { display: grid; gap: 3px; max-width: min(78%, 520px); padding: 9px 13px 7px; border-radius: 18px; animation: bubble-in 0.18s ease-out; }
.bubble--me { align-self: flex-end; border-bottom-right-radius: 6px; background: var(--accent); color: #111; }
.bubble--them { align-self: flex-start; border: 1px solid var(--line-2); border-bottom-left-radius: 6px; background: var(--card); }
.bubble__text { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.45; }
.bubble__time { justify-self: end; font-size: 0.68rem; opacity: 0.65; }
@keyframes bubble-in { from { opacity: 0; transform: translateY(6px); } }
.chat-card { display: grid; gap: 4px; align-self: flex-start; max-width: min(88%, 520px); padding: 11px 14px; border: 1px solid var(--line-2); border-left: 3px solid var(--accent); border-radius: 12px; background: rgba(127, 127, 127, 0.05); }
.chat-card--center { align-self: center; max-width: min(92%, 460px); text-align: left; }
.chat-card__meta { display: flex; gap: 10px; margin: 0; color: var(--dim); font-size: 0.72rem; }
.chat-card__tag { color: var(--accent); font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.chat-card__title { font-size: 0.95rem; }
.chat-card__details { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 2px 12px; margin: 2px 0 0; font-size: 0.84rem; }
.chat-card__details dt { color: var(--dim); }
.chat-card__details dd { margin: 0; }
.chat-card__link { justify-self: start; margin-top: 4px; color: var(--accent); font-size: 0.86rem; font-weight: 600; text-decoration: none; }
.chat__composer { position: sticky; bottom: 0; z-index: 8; display: flex; align-items: flex-end; gap: 8px; margin: 0 -2px; padding: 10px 2px 14px; border-top: 1px solid var(--line); background: var(--bg); }
.chat__input { flex: 1; min-height: 44px; max-height: 140px; padding: 11px 16px; border: 1px solid var(--line-2); border-radius: 22px; background: var(--field); color: var(--text); font: inherit; font-size: 16px; line-height: 1.35; resize: none; outline: none; }
.chat__input:focus { border-color: var(--accent); }
.chat__send { display: grid; flex: none; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; background: var(--accent); color: #111; cursor: pointer; transition: opacity 0.15s, transform 0.15s; }
.chat__send:disabled { opacity: 0.35; cursor: default; }
.chat__send:not(:disabled):active { transform: scale(0.94); }
.chat__send svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.chat__note { margin: 0; }
.cl-chatcard { display: flex; align-items: center; gap: 14px; color: var(--text); text-decoration: none; }
.cl-chatcard__text { display: grid; flex: 1; min-width: 0; }
.cl-chatcard > i { color: var(--dim); font-size: 1.4rem; font-style: normal; }
.cl-chatcard:hover { border-color: var(--line-2); }
.chat-intro { margin: 0 0 12px; }
.chat-list { display: grid; padding: 4px 0; }
.chat-row { display: flex; align-items: center; gap: 14px; padding: 12px 18px; border-top: 1px solid var(--line); color: var(--text); text-decoration: none; transition: background-color 0.15s; }
.chat-row:first-child { border-top: 0; }
.chat-row:hover { background: rgba(127, 127, 127, 0.06); }
.chat-row__main { display: grid; flex: 1; min-width: 0; }
.chat-row__main strong { display: flex; align-items: center; gap: 8px; }
.chat-row__main small { overflow: hidden; color: var(--dim); text-overflow: ellipsis; white-space: nowrap; }
.chat-row.is-unread .chat-row__main small { color: var(--text); font-weight: 600; }
.chat-row__side { display: grid; justify-items: end; gap: 4px; }
.chat-row__side small { color: var(--dim); font-size: 0.74rem; }
.chat-row__side .count { margin: 0; }
.chat-row__noapp { font-size: 0.66rem; }
.chat--panel { max-width: 760px; }
@media (max-width: 720px) {
  body.client .chat__composer { bottom: calc(66px + env(safe-area-inset-bottom)); }
}
@media (max-width: 820px) {
  .chat--panel .chat__composer { bottom: calc(66px + env(safe-area-inset-bottom)); }
  .chat--panel { max-width: none; }
}
