:root {
  color-scheme: light;
  --ink: #1F1B18;
  --muted: #6F6259;
  --line: #E4D8CB;
  --paper: #F8F5F0;
  --soft: #EFE7DC;
  --brand: #dddd6b;
  --brand-dark: #ff7456;
  --accent: #ff7456;
  --warn: #d95c42;
  --ok: #4f8436;
  --surface: #ffffff;
  --surface-alt: #fffaf5;
  --highlight: #dddd6b;
  --shadow: 0 18px 45px rgba(31, 27, 24, .08);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: linear-gradient(180deg, #fffaf5 0, var(--paper) 260px);
  color: var(--ink);
}

button, input, textarea, select {
  font: inherit;
}

button {
  border: 0;
  border-radius: 6px;
  background: var(--brand);
  color: var(--ink);
  padding: .64rem .9rem;
  cursor: pointer;
  min-height: 40px;
  font-weight: 650;
  transition: background .15s ease, border-color .15s ease, transform .15s ease;
}

button:hover { background: var(--brand-dark); }
button:hover { color: white; }
button.secondary { background: rgba(255, 255, 255, .62); color: var(--ink); border: 1px solid var(--line); }
button.secondary:hover { background: var(--soft); color: var(--ink); }
button.ghost { background: transparent; color: var(--muted); border: 1px solid var(--line); }
button.ghost:hover { background: #fffaf5; color: var(--ink); }
button.danger { background: var(--warn); color: white; }
button.icon { width: 40px; padding: 0; display: inline-grid; place-items: center; }

.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 40px;
  border: 1px solid rgba(33, 28, 24, .06);
  border-radius: 6px;
  padding: .64rem .9rem;
  background: var(--brand);
  color: var(--ink);
  font-weight: 650;
  text-decoration: none;
  transition: background .15s ease, border-color .15s ease, transform .15s ease;
}

.button-link:hover {
  background: var(--brand-dark);
  color: white;
}

.button-link.secondary {
  background: rgba(255, 255, 255, .62);
  color: var(--ink);
  border: 1px solid var(--line);
}

.button-link.secondary:hover {
  background: var(--soft);
  color: var(--ink);
}

input, textarea, select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: .68rem .75rem;
  background: var(--surface);
  color: var(--ink);
}

input:focus, textarea:focus, select:focus {
  outline: 3px solid rgba(255, 116, 86, .16);
  border-color: rgba(255, 116, 86, .62);
}

textarea { min-height: 90px; resize: vertical; }
label { display: grid; gap: .35rem; color: var(--muted); font-size: .9rem; }

.login {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(280px, 420px) 1fr;
}

.login-panel {
  padding: clamp(1.5rem, 5vw, 4rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.2rem;
  background: var(--surface);
  box-shadow: var(--shadow);
  z-index: 1;
}

.login-separator {
  display: flex;
  align-items: center;
  gap: .75rem;
  color: var(--muted);
  font-size: .85rem;
}

.login-separator::before,
.login-separator::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--line);
}

.google-signin {
  min-height: 42px;
}

.google-native-button {
  width: 100%;
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .8rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  font-weight: 700;
  box-shadow: none;
}

.google-native-button:hover {
  background: var(--card);
  color: var(--text);
  transform: none;
}

.google-g {
  width: 24px;
  height: 24px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  color: #4285f4;
  font-weight: 800;
  font-family: Arial, Helvetica, sans-serif;
  background: #fff;
}

.small { font-size: .82rem; }

.login-visual {
  background:
    linear-gradient(rgba(31, 27, 24, .14), rgba(31, 27, 24, .14)),
    url("https://images.unsplash.com/photo-1490645935967-10de6ba17061?auto=format&fit=crop&w=1600&q=80") center/cover;
  min-height: 320px;
}

.brand {
  display: flex;
  align-items: center;
  gap: .65rem;
  font-weight: 800;
  letter-spacing: 0;
  font-size: 1.15rem;
}

.mark {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  background: var(--brand);
  color: var(--ink);
  font-weight: 900;
}

.client-app {
  min-height: 100vh;
  max-width: 1180px;
  margin: 0 auto;
  padding: clamp(1.1rem, 3vw, 2.8rem);
  display: grid;
  gap: 1.25rem;
}

.client-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.client-brand {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  color: #72685f;
}

.client-logo-mark {
  width: 66px;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid #ded2c5;
  border-radius: 18px;
  background: linear-gradient(145deg, #efe7dc, #fffaf5);
  box-shadow: 0 14px 32px rgba(31, 27, 24, .08);
  font-family: "Playfair Display", Georgia, serif;
  font-size: 2.15rem;
  line-height: 1;
}

.client-logo-text {
  display: grid;
  gap: .05rem;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.client-logo-text strong {
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(2rem, 5vw, 3.8rem);
  font-weight: 500;
  line-height: .86;
}

.client-logo-text small {
  font-size: .78rem;
  color: var(--muted);
}

.client-top-logout,
.botanical-avatar,
.privacy-icon {
  display: grid;
  place-items: center;
  color: #736b62;
}

.client-top-logout {
  min-height: 44px;
  grid-auto-flow: column;
  align-items: center;
  gap: .45rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .58);
  color: var(--muted);
  padding: .45rem .75rem;
}

.client-top-logout:hover {
  background: #fffaf5;
  color: var(--ink);
}

.client-top-logout svg,
.privacy-icon svg {
  width: 22px;
  height: 22px;
}

.client-profile {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  padding-top: .4rem;
}

.botanical-avatar {
  width: 122px;
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: 50%;
  background:
    radial-gradient(circle at 68% 25%, rgba(221, 221, 107, .2), transparent 34%),
    linear-gradient(145deg, rgba(255, 255, 255, .82), rgba(239, 231, 220, .58));
}

.botanical-avatar svg {
  width: 58px;
  height: 58px;
  color: #9ba084;
}

.client-profile h1 {
  margin: 0;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(2.1rem, 5vw, 4rem);
  font-weight: 500;
}

.client-profile p {
  margin: .15rem 0 0;
  color: var(--muted);
  font-size: 1.35rem;
}

.client-section-menu {
  width: min(100%, 520px);
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, .72);
  box-shadow: 0 12px 30px rgba(31, 27, 24, .035);
  overflow: hidden;
}

.client-section-menu summary {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  padding: .95rem 1.1rem;
  cursor: pointer;
  list-style: none;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(1.35rem, 2.5vw, 1.8rem);
  color: var(--ink);
}

.client-section-menu summary::-webkit-details-marker {
  display: none;
}

.client-section-menu summary svg {
  width: 24px;
  height: 24px;
  transition: transform .18s ease;
}

.client-section-menu[open] summary svg {
  transform: rotate(90deg);
}

.client-section-menu nav {
  display: grid;
  gap: .25rem;
  padding: 0 .75rem .75rem;
}

.client-section-menu button {
  display: grid;
  grid-template-columns: 30px 1fr;
  align-items: center;
  gap: .7rem;
  min-height: 52px;
  padding: .7rem .8rem;
  border-radius: 12px;
  background: transparent;
  color: var(--ink);
  text-align: left;
}

.client-section-menu button:hover {
  background: #fffaf5;
  color: var(--ink);
}

.client-section-menu button.active {
  background: #fff0ea;
}

.client-section-menu button svg {
  width: 24px;
  height: 24px;
  color: #736b62;
}

.client-main {
  display: grid;
  gap: 1.2rem;
}

.client-highlights {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(260px, .75fr);
  gap: 1rem;
}

.highlight-banner {
  min-height: 210px;
  display: grid;
  align-content: end;
  gap: .65rem;
  padding: clamp(1rem, 2.5vw, 1.5rem);
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 18px 45px rgba(31, 27, 24, .05);
  overflow: hidden;
  position: relative;
}

.highlight-banner::after {
  content: "";
  position: absolute;
  right: -42px;
  top: -42px;
  width: 170px;
  height: 170px;
  border-radius: 50%;
  background: rgba(221, 221, 107, .25);
}

.highlight-banner.primary {
  background: linear-gradient(135deg, #fffaf5, #fff0ea);
}

.highlight-banner.promo {
  background: linear-gradient(135deg, #f8f5f0, #e9efe7);
}

.highlight-banner h2,
.highlight-banner p {
  margin: 0;
  max-width: 560px;
  position: relative;
  z-index: 1;
}

.highlight-banner .secondary {
  width: fit-content;
  position: relative;
  z-index: 1;
}

.benefit-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

.benefit-card {
  display: grid;
  gap: .75rem;
  padding: 1.1rem;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, .72);
  box-shadow: 0 14px 36px rgba(31, 27, 24, .045);
}

.benefit-card h2,
.benefit-card p {
  margin: 0;
}

.benefit-note {
  width: fit-content;
  border-radius: 999px;
  padding: .22rem .62rem;
  background: #fff0ea;
  color: var(--brand-dark);
  font-size: .78rem;
  font-weight: 700;
}

.benefit-code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  margin-top: .4rem;
  padding: .8rem;
  border: 1px dashed #cfc3ad;
  border-radius: 12px;
  background: #fffaf5;
}

.benefit-code span {
  font-weight: 800;
  letter-spacing: .08em;
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px 1fr;
}

.sidebar {
  background: rgba(248, 245, 240, .9);
  border-right: 1px solid var(--line);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  position: sticky;
  top: 0;
  height: 100vh;
  backdrop-filter: blur(10px);
}

.nav {
  display: grid;
  gap: .35rem;
}

.nav button {
  background: transparent;
  color: var(--ink);
  text-align: left;
  display: flex;
  gap: .6rem;
  align-items: center;
  border: 1px solid transparent;
}

.nav button.active, .nav button:hover {
  background: var(--soft);
  border-color: var(--line);
}

.main {
  padding: clamp(1rem, 3vw, 2rem);
  display: grid;
  gap: 1rem;
  align-content: start;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 1rem;
}

.topbar h1, h2 {
  color: var(--ink);
}

.topbar h1, .login h1, h2, .section-title {
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 600;
}

.topbar h1, .login h1 {
  margin: 0;
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  letter-spacing: 0;
}

.muted { color: var(--muted); }
.error { color: var(--warn); min-height: 1.2rem; }
.ok { color: var(--ok); }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}

.panel, .card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.panel { padding: 1rem; box-shadow: 0 1px 2px rgba(31, 27, 24, .03); }
.card { padding: .85rem; display: grid; gap: .6rem; }
.stack { display: grid; gap: .75rem; }
.row { display: flex; gap: .65rem; align-items: center; flex-wrap: wrap; }
.split { display: grid; grid-template-columns: minmax(240px, 340px) 1fr; gap: 1rem; align-items: start; }

.table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.table th, .table td {
  padding: .75rem;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.table th { background: var(--soft); color: var(--muted); font-size: .82rem; }

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: .22rem .55rem;
  background: var(--soft);
  color: var(--brand-dark);
  font-size: .82rem;
  white-space: nowrap;
}

.badge.warn { background: #ffe5de; color: var(--brand-dark); }
.badge.ok { background: #e9efe7; color: var(--ok); }

.calendar {
  display: grid;
  gap: .75rem;
}

.calendar-head {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: .45rem;
  color: var(--muted);
  font-size: .82rem;
  text-align: center;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: .45rem;
}

.day {
  min-height: 104px;
  border: 1px solid var(--line);
  background: white;
  border-radius: 8px;
  padding: .55rem;
  display: grid;
  align-content: start;
  gap: .35rem;
  text-align: left;
}

.day.out { opacity: .35; background: #f4ede5; }
.day.empty {
  min-height: 104px;
  border-color: transparent;
  background: transparent;
}

.day.unavailable {
  background: #ffe9e3;
  border-color: #f2c6bb;
  color: #a94531;
}

.day.available {
  background: #e9efe7;
  border-color: #c8d8bf;
  color: #4f8436;
}

.day.past {
  background: #f1eae1;
  border-color: #e4d8cb;
  color: #8b7b70;
}

.day.selected {
  outline: 3px solid rgba(255, 116, 86, .22);
  border-color: var(--brand);
}
.day strong { font-size: .95rem; line-height: 1; }
.slot-count { font-size: .78rem; color: var(--muted); }
.day.available .slot-count { color: #4f8436; }
.day.unavailable .slot-count { color: #a94531; }

.admin-calendar-layout {
  display: grid;
  grid-template-columns: minmax(520px, 1fr) minmax(300px, 380px);
  gap: 1rem;
  align-items: start;
}

.admin-calendar-grid .admin-day {
  min-height: 150px;
  text-align: left;
  color: var(--ink);
}

.appointment-chips {
  display: grid;
  gap: .3rem;
  min-width: 0;
}

.appointment-chip {
  display: block;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  border-radius: 5px;
  padding: .24rem .35rem;
  background: #e9efe7;
  color: var(--ok);
  font-size: .76rem;
  line-height: 1.2;
}

.appointment-chip.warn {
  background: #ffe5de;
  color: var(--brand-dark);
}

.appointment-chip.more {
  background: var(--soft);
  color: var(--muted);
}

.slots {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(86px, 1fr));
  gap: .45rem;
}

.slot {
  background: var(--soft);
  color: var(--ink);
  border: 1px solid var(--line);
}

.slot[disabled] {
  opacity: .4;
  cursor: not-allowed;
}

.field-list {
  display: grid;
  gap: .5rem;
}

.notice {
  padding: .85rem;
  border-left: 4px solid var(--accent);
  background: #fff6ef;
  color: #6F6259;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(31, 27, 24, .42);
  backdrop-filter: blur(6px);
}

.modal {
  width: min(460px, 100%);
  display: grid;
  gap: .85rem;
  padding: 1.15rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.modal h2 {
  margin: 0;
}

.modal p {
  margin: 0;
  color: var(--muted);
}

.modal-actions {
  justify-content: flex-end;
  padding-top: .25rem;
}

.patient-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 340px);
  gap: 1rem;
  align-items: stretch;
  padding: clamp(1.4rem, 4vw, 2.4rem);
  border: 1px solid var(--line);
  border-radius: 18px;
  background:
    radial-gradient(circle at 92% 32%, rgba(255, 255, 255, .75) 0 17%, transparent 17.5%),
    radial-gradient(circle at 84% 63%, rgba(239, 231, 220, .72) 0 26%, transparent 26.5%),
    linear-gradient(135deg, rgba(248, 245, 240, .95), rgba(255, 240, 234, .92)),
    var(--surface);
  overflow: hidden;
  position: relative;
  box-shadow: 0 18px 45px rgba(31, 27, 24, .05);
}

.patient-hero::after {
  content: "";
  position: absolute;
  right: 3%;
  bottom: 10%;
  width: 190px;
  height: 240px;
  opacity: .32;
  background:
    linear-gradient(115deg, transparent 47%, #9ba084 48% 50%, transparent 51%),
    radial-gradient(ellipse at 62% 18%, transparent 0 43%, #9ba084 44% 46%, transparent 47%),
    radial-gradient(ellipse at 35% 42%, transparent 0 43%, #9ba084 44% 46%, transparent 47%),
    radial-gradient(ellipse at 64% 66%, transparent 0 43%, #9ba084 44% 46%, transparent 47%);
  pointer-events: none;
}

.patient-hero h1 {
  margin: .25rem 0 .5rem;
  font-size: clamp(2.6rem, 5.6vw, 4.9rem);
  letter-spacing: 0;
  font-weight: 500;
  line-height: 1;
}

.patient-hero p {
  max-width: 680px;
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.privacy-note {
  display: flex;
  align-items: center;
  gap: 1rem;
  align-self: end;
  padding: 1rem;
  border: 1px solid rgba(255, 116, 86, .18);
  border-radius: 16px;
  background: rgba(255, 255, 255, .78);
  box-shadow: 0 14px 35px rgba(31, 27, 24, .06);
  z-index: 1;
}

.privacy-icon {
  flex: 0 0 auto;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: #f2ece2;
  border: 1px solid #e8dccf;
}

.privacy-note span {
  color: var(--muted);
  font-size: .92rem;
}

.client-profile-card {
  display: grid;
  grid-template-columns: minmax(220px, .42fr) minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
  border-color: #d8cbbb;
  background:
    linear-gradient(135deg, rgba(255, 253, 248, .96), rgba(233, 238, 225, .58)),
    var(--surface);
}

.client-profile-card.needs-profile {
  border-color: rgba(224, 111, 88, .32);
}

.client-profile-copy h2,
.client-profile-copy p {
  margin: 0;
}

.client-profile-copy {
  display: grid;
  gap: .45rem;
}

.client-profile-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)) minmax(120px, .4fr);
  gap: .75rem;
  align-items: end;
}

.client-profile-form label {
  min-width: 0;
}

.client-profile-form button {
  min-height: 46px;
}

.profile-age {
  display: grid;
  gap: .35rem;
  min-height: 72px;
  align-content: center;
  padding: .7rem .8rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 253, 248, .78);
}

.profile-age span {
  color: var(--muted);
  font-size: .82rem;
}

.profile-age strong {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.45rem;
  line-height: 1;
}

.patient-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 1rem;
}

.patient-card {
  display: grid;
  gap: .7rem;
  align-content: start;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: 0 1px 2px rgba(31, 27, 24, .03);
}

.patient-card.highlight {
  background: #fff6ef;
  border-color: #ead8c4;
}

.patient-card strong {
  font-size: 2rem;
  line-height: 1;
}

.patient-card h2 {
  margin: 0;
}

.card-kicker {
  color: var(--brand);
  font-size: .76rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.patient-timeline {
  display: grid;
  gap: .5rem;
}

.patient-timeline div {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: .75rem;
  padding: .7rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-alt);
}

.patient-timeline span {
  color: var(--muted);
  font-size: .85rem;
}

.patient-timeline p {
  margin: 0;
}

.patient-doc-layout,
.client-session-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, .55fr);
  gap: 1rem;
  align-items: start;
}

.patient-doc {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .85rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-alt);
}

.patient-doc p,
.soft-empty p {
  margin-bottom: 0;
}

.soft-empty {
  display: grid;
  gap: .6rem;
  padding: 1rem;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fffaf5;
}

.patient-upload {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(280px, 1fr);
  gap: 1.2rem;
  align-items: start;
}

.session-current {
  grid-template-columns: 1fr;
  background: #fff6ef;
  border-color: #ead8c4;
}

.session-type-grid {
  display: grid;
  gap: .55rem;
}

.session-type {
  display: grid;
  grid-template-columns: 1fr;
  gap: .25rem;
  align-items: center;
  padding: .8rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-alt);
  color: var(--ink);
  cursor: pointer;
  text-align: left;
  width: 100%;
}

.session-type input {
  width: auto;
  grid-row: span 2;
}

.session-type span {
  color: var(--muted);
  font-size: .86rem;
}

.session-type.selected {
  border-color: rgba(255, 116, 86, .55);
  background: #fff0ea;
}

.session-list {
  display: grid;
  gap: .8rem;
}

.session-cta {
  display: flex;
  justify-content: flex-start;
  padding-top: .25rem;
}

.booking-toolbar {
  justify-content: space-between;
  padding-bottom: .65rem;
}

.service-choice-grid {
  display: grid;
  gap: .7rem;
}

.service-choice {
  display: grid;
  gap: .25rem;
  width: 100%;
  padding: .9rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface-alt);
  color: var(--ink);
  text-align: left;
  box-shadow: none;
}

.service-choice.disabled,
.service-choice:disabled {
  opacity: .62;
  cursor: not-allowed;
  background: rgba(247, 241, 232, .65);
}

.service-choice span,
.service-choice small {
  color: var(--muted);
}

.service-choice em {
  display: block;
  color: var(--muted);
  font-style: normal;
  font-size: .82rem;
  line-height: 1.45;
}

.payment-code-box {
  display: grid;
  gap: .25rem;
  padding: .75rem .85rem;
  border: 1px dashed #c9bba6;
  border-radius: 10px;
  background: #fffaf5;
}

.payment-code-box span,
.payment-code-inline {
  color: var(--muted);
  font-size: .82rem;
}

.payment-code-box strong,
.payment-code-inline {
  font-weight: 850;
  letter-spacing: .08em;
  color: var(--ink);
}

.patient-form-card h2 {
  margin: 0;
}

.intake-form {
  gap: 1.15rem;
  background: linear-gradient(180deg, #fffaf5 0%, #ffffff 42%);
  border-color: #ead8c4;
}

.form-hero {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem;
  border-radius: 8px;
  background: #fff0ea;
  border: 1px solid #f0cbbf;
}

.form-hero h2 {
  margin: .2rem 0 .35rem;
}

.form-section {
  padding: 1rem;
  border: 1px solid #ead8c4;
  border-left: 5px solid var(--brand);
  border-radius: 8px;
  background: #fffaf5;
}

.form-section h3 {
  margin: 0 0 .35rem;
  color: var(--brand-dark);
}

.form-section p {
  margin: 0;
  color: var(--muted);
}

.form-question {
  padding: .9rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.form-question span {
  display: grid;
  gap: .35rem;
  font-weight: 700;
}

.form-question em {
  width: fit-content;
  border-radius: 999px;
  padding: .18rem .48rem;
  background: #ffe5de;
  color: #a94531;
  font-size: .72rem;
  font-style: normal;
  font-weight: 700;
}

.external-form-note {
  display: grid;
  gap: .65rem;
  padding: .9rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-alt);
}

.external-form-note p {
  margin: 0;
}

.external-confirmation {
  align-items: start;
}

.external-confirmation input {
  width: auto;
}

.availability-editor {
  display: grid;
  gap: .75rem;
}

.schedule-page {
  display: grid;
  gap: 1rem;
}

.schedule-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.schedule-summary h2 {
  margin: .15rem 0 .25rem;
  font-size: 1.35rem;
}

.eyebrow {
  color: var(--brand);
  font-size: .78rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.summary-metrics {
  display: flex;
  gap: .65rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.summary-metrics span {
  display: grid;
  min-width: 116px;
  padding: .65rem .8rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-alt);
  color: var(--muted);
  font-size: .82rem;
}

.summary-metrics strong {
  color: var(--ink);
  font-size: 1.25rem;
}

.availability-day {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0;
  display: grid;
  gap: 0;
  background: var(--surface);
  overflow: hidden;
}

.availability-day.open {
  border-color: rgba(255, 116, 86, .28);
}

.availability-day-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .8rem;
  padding: .85rem;
  border-bottom: 1px solid var(--line);
  background: var(--surface-alt);
}

.day-title {
  margin: 0;
  padding: 0;
  font-weight: 700;
  color: var(--brand-dark);
  font-size: 1rem;
}

.day-state {
  display: inline-flex;
  margin-top: .25rem;
  color: var(--muted);
  font-size: .82rem;
}

.availability-day.closed .day-state {
  color: #8b7b70;
}

.availability-ranges {
  display: grid;
  gap: .5rem;
  padding: .85rem;
}

.availability-range {
  display: grid;
  grid-template-columns: minmax(130px, 1fr) auto minmax(130px, 1fr) 40px;
  gap: .55rem;
  align-items: center;
  padding: .65rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.range-separator {
  color: var(--muted);
  font-size: .86rem;
  align-self: end;
  padding-bottom: .7rem;
}

.empty-day {
  margin: 0;
  padding: .65rem;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fffaf5;
}

.availability-actions {
  padding-top: .4rem;
  position: sticky;
  bottom: 0;
  background: rgba(248, 245, 240, .92);
  border-top: 1px solid var(--line);
  padding: .9rem 0 0;
  backdrop-filter: blur(8px);
}

.marketing-message textarea {
  min-height: 170px;
}

.marketing-message input[type="checkbox"] {
  width: auto;
}

@media (max-width: 850px) {
  .login, .shell, .split, .patient-hero, .patient-doc-layout, .client-session-layout, .patient-upload { grid-template-columns: 1fr; }
  .client-profile-card,
  .client-profile-form { grid-template-columns: 1fr; }
  .client-highlights { grid-template-columns: 1fr; }
  .login-visual { min-height: 240px; order: -1; }
  .sidebar {
    position: static;
    height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .nav { grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
  .calendar-grid, .calendar-head { gap: .25rem; }
  .day { min-height: 78px; padding: .4rem; }
  .day strong { display: block; font-size: .95rem; }
  .admin-calendar-layout { grid-template-columns: 1fr; }
  .admin-calendar-grid .admin-day { min-height: 112px; }
  .patient-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .schedule-summary { align-items: stretch; flex-direction: column; }
  .summary-metrics { justify-content: stretch; }
  .summary-metrics span { flex: 1; }
  .availability-day-head { align-items: stretch; flex-direction: column; }
  .availability-range { grid-template-columns: 1fr auto 1fr 40px; }
}

@media (max-width: 520px) {
  .client-app {
    padding: 1rem;
    gap: 1rem;
  }

  .client-logo-mark {
    width: 56px;
    border-radius: 16px;
  }

  .client-top-logout span {
    display: none;
  }

  .client-profile {
    gap: 1rem;
  }

  .botanical-avatar {
    width: 96px;
  }

  .client-profile h1 {
    font-size: clamp(2rem, 10vw, 3rem);
  }

  .client-profile p {
    font-size: 1.1rem;
  }

  .client-section-menu {
    width: 100%;
  }

  .client-section-menu summary {
    min-height: 66px;
    font-size: 1.45rem;
  }

  .client-top-logout {
    width: 46px;
    height: 46px;
    min-height: 46px;
    padding: 0;
    border-radius: 50%;
  }

  .patient-hero {
    padding: 1.2rem;
    border-radius: 16px;
  }

  .patient-hero::after {
    width: 150px;
    height: 190px;
    right: -18px;
    bottom: 90px;
  }

  .privacy-note {
    align-items: flex-start;
  }

  .privacy-icon {
    width: 56px;
    height: 56px;
  }

  .patient-grid { grid-template-columns: 1fr; }
  .patient-doc { align-items: stretch; flex-direction: column; }
  .patient-timeline div { grid-template-columns: 1fr; }
  .calendar-head { font-size: .72rem; }
  .calendar-grid, .calendar-head { gap: .18rem; }
  .day { min-height: 58px; padding: .32rem; border-radius: 6px; }
  .day .slot-count { display: none; }
  .availability-range { grid-template-columns: 1fr; }
  .range-separator { padding: 0; }
  .availability-range .icon { width: 100%; }
}

/* Visual refinement layer from the VPS baseline. Structure and behavior stay untouched. */
:root {
  --ink: #211c18;
  --muted: #776b60;
  --line: #e2d5c6;
  --paper: #f7f1e9;
  --soft: #efe5d9;
  --brand: #d9d96a;
  --brand-dark: #e06f58;
  --accent: #e06f58;
  --surface: rgba(255, 253, 248, .92);
  --surface-alt: #fff8f0;
  --olive: #899173;
  --olive-dark: #5f6d4d;
  --blush: #fff0ea;
  --shadow: 0 20px 55px rgba(44, 34, 25, .08);
  --shadow-small: 0 8px 22px rgba(44, 34, 25, .055);
}

html {
  background: var(--paper);
}

body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 8% -8%, rgba(217, 217, 106, .17), transparent 26rem),
    radial-gradient(circle at 96% 4%, rgba(224, 111, 88, .12), transparent 28rem),
    linear-gradient(180deg, #fffdf8 0, var(--paper) 360px, #f3eadf 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: .22;
  background-image:
    linear-gradient(rgba(33, 28, 24, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(33, 28, 24, .025) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(180deg, #000 0, transparent 72%);
}

button {
  border: 1px solid rgba(33, 28, 24, .06);
  border-radius: 8px;
  box-shadow: var(--shadow-small);
  letter-spacing: 0;
}

button:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(44, 34, 25, .12);
}

button.secondary,
button.ghost,
.slot {
  box-shadow: none;
}

input,
textarea,
select {
  border-radius: 8px;
  background: rgba(255, 253, 248, .9);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7);
}

.login-panel,
.panel,
.card,
.client-section-menu,
.highlight-banner,
.benefit-card,
.patient-hero,
.patient-card,
.modal,
.availability-day,
.schedule-summary {
  background: var(--surface);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.panel,
.card,
.table,
.day,
.patient-doc,
.soft-empty,
.session-type,
.form-question,
.form-section,
.availability-range,
.empty-day {
  border-color: var(--line);
}

.panel,
.card,
.table,
.patient-doc,
.soft-empty,
.session-type,
.form-question,
.form-section,
.availability-day,
.availability-range,
.schedule-summary {
  border-radius: 10px;
}

.client-app {
  max-width: 1200px;
}

.client-logo-mark,
.mark {
  background:
    radial-gradient(circle at 64% 20%, rgba(217, 217, 106, .25), transparent 34%),
    linear-gradient(145deg, #f1e8dc, #fffdf8);
}

.client-section-menu {
  border-radius: 18px;
}

.client-section-menu button:hover,
.nav button:hover,
.nav button.active {
  background: rgba(233, 238, 225, .72);
  color: var(--ink);
}

.client-section-menu button.active {
  background: var(--blush);
}

.client-section-menu button svg,
.botanical-avatar svg {
  color: var(--olive);
}

.client-highlights {
  align-items: stretch;
}

.highlight-banner,
.patient-hero {
  border-radius: 20px;
}

.highlight-banner::after {
  right: -56px;
  top: -56px;
  width: 190px;
  height: 190px;
  background:
    radial-gradient(circle, rgba(217, 217, 106, .25), transparent 68%);
}

.highlight-banner h2,
.benefit-card h2,
.patient-card h2,
.panel h2 {
  line-height: 1.08;
}

.patient-hero {
  background:
    radial-gradient(circle at 92% 28%, rgba(255, 255, 255, .75) 0 17%, transparent 17.5%),
    radial-gradient(circle at 86% 70%, rgba(233, 238, 225, .78) 0 28%, transparent 28.5%),
    linear-gradient(135deg, rgba(255, 253, 248, .96), rgba(255, 240, 234, .86));
}

.privacy-note {
  border-radius: 18px;
  background: rgba(255, 253, 248, .82);
  box-shadow: var(--shadow-small);
}

.patient-card,
.benefit-card {
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}

.patient-card:hover,
.benefit-card:hover {
  transform: translateY(-2px);
  border-color: #d5c6b6;
  box-shadow: 0 22px 50px rgba(44, 34, 25, .1);
}

.patient-card.highlight,
.session-current {
  background: linear-gradient(180deg, rgba(255, 240, 234, .9), rgba(255, 253, 248, .92));
}

.patient-card h2 strong {
  font-family: "Playfair Display", Georgia, serif;
}

.patient-timeline div,
.patient-doc,
.soft-empty {
  background: rgba(255, 253, 248, .72);
}

.shell {
  background:
    radial-gradient(circle at 100% 0, rgba(224, 111, 88, .08), transparent 24rem),
    linear-gradient(180deg, rgba(255, 253, 248, .78), rgba(247, 241, 233, .9));
}

.sidebar {
  background: rgba(255, 253, 248, .72);
  box-shadow: 12px 0 40px rgba(44, 34, 25, .035);
}

.sidebar .brand {
  padding: .15rem 0 .4rem;
}

.sidebar > .muted {
  padding: .8rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 253, 248, .62);
}

.nav button {
  min-height: 46px;
  border-radius: 9px;
  font-weight: 750;
}

.topbar {
  align-items: flex-end;
  min-height: 76px;
}

.grid > .panel strong:first-child {
  display: block;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(2.1rem, 4vw, 3.25rem);
  line-height: .95;
}

.table {
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
}

.table th {
  background: #f1e8dc;
  font-size: .76rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.table tr:last-child td {
  border-bottom: 0;
}

.table tbody tr {
  transition: background .15s ease;
}

.table tbody tr:hover {
  background: rgba(233, 238, 225, .28);
}

.badge {
  font-weight: 750;
}

.badge.ok {
  background: #e9eee1;
  color: var(--olive-dark);
}

.badge.warn {
  background: var(--blush);
  color: #a94835;
}

.calendar-head {
  align-items: center;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.calendar-head span {
  display: grid;
  place-items: center;
  min-height: 28px;
}

.day {
  box-shadow: none;
  transition: transform .14s ease, border-color .14s ease, box-shadow .14s ease;
}

button.day:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 26px rgba(44, 34, 25, .08);
}

.day.available {
  background: #edf3e8;
  border-color: #c8d8bf;
}

.day.unavailable {
  background: #fff1eb;
}

.day.selected {
  outline-color: rgba(224, 111, 88, .24);
  border-color: var(--accent);
}

.appointment-chip {
  border-radius: 999px;
  font-weight: 700;
}

.slot {
  border-radius: 999px;
}

.slot:hover {
  background: #e9eee1;
  color: var(--ink);
}

.notice {
  border: 1px solid rgba(224, 111, 88, .18);
  border-left: 4px solid var(--accent);
  border-radius: 10px;
  background: rgba(255, 240, 234, .7);
}

.client-notice-stack {
  display: grid;
  gap: .75rem;
  margin-bottom: 1rem;
}

.client-notice {
  padding: 1rem 1.1rem;
  border: 1px solid rgba(95, 103, 72, .22);
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(238, 241, 230, .9), rgba(255, 253, 248, .9));
}

.client-notice span {
  display: block;
  margin-bottom: .25rem;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.client-notice p {
  margin: .35rem 0 0;
  color: var(--muted);
}

.payment-modal {
  max-width: 520px;
}

.payment-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .8rem;
  margin: 1.25rem 0;
}

.payment-summary div {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 253, 248, .9);
}

.payment-summary .wide {
  grid-column: 1 / -1;
  border-color: rgba(255, 116, 86, .32);
  background: #fff4ef;
}

.payment-summary span {
  display: block;
  margin-bottom: .35rem;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.payment-summary strong {
  font-size: 1.35rem;
  color: var(--ink);
}

.payment-summary .wide strong {
  font-size: 2rem;
  letter-spacing: .08em;
}

.payment-help,
.move-current {
  padding: .9rem 1rem;
  border-radius: 12px;
  background: #eef1e6;
  color: var(--ink);
  line-height: 1.55;
}

.move-modal {
  max-width: 560px;
}

.move-slot-form {
  display: grid;
  gap: 1rem;
}

.form-hero,
.form-section,
.intake-form {
  border-color: #ead8c4;
}

.form-section {
  border-left-color: var(--olive);
}

.form-section h3 {
  color: var(--olive-dark);
}

.schedule-summary {
  background:
    linear-gradient(135deg, rgba(255, 253, 248, .96), rgba(233, 238, 225, .72)),
    var(--surface);
}

.day-title {
  color: var(--olive-dark);
}

.availability-day.open {
  border-color: rgba(137, 145, 115, .38);
}

.availability-range {
  background: rgba(255, 253, 248, .78);
}

@media (max-width: 850px) {
  .topbar {
    align-items: stretch;
    flex-direction: column;
  }

  .sidebar {
    box-shadow: 0 12px 34px rgba(44, 34, 25, .045);
  }
}

@media (max-width: 520px) {
  body::before {
    background-size: 34px 34px;
  }

  .client-app {
    padding: .9rem;
  }

  .client-header {
    align-items: flex-start;
  }

  .highlight-banner,
  .patient-hero,
  .patient-card,
  .benefit-card,
  .panel {
    border-radius: 16px;
  }

  .patient-hero h1 {
    font-size: clamp(2.25rem, 12vw, 3.25rem);
  }

  .table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}
