:root {
  color-scheme: light;
  --bg: #f8f5f0;
  --paper: #fffcf8;
  --ink: #292b23;
  --muted: #65675b;
  --line: #e6dfd4;
  --green: #364d3c;
  --light: #e7ede2;
  --rose: #f3e5e1;
  font: 16px/1.45 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100dvh; }
button, input, select { font: inherit; }
button { cursor: pointer; color: inherit; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid #728970; outline-offset: 3px; }
button:disabled, fieldset:disabled button { cursor: wait; opacity: .65; }
h1, h2, p { margin: 0; }
h1, .hero strong, #dialog-title { font-family: Georgia, serif; font-weight: 400; }
h1 { font-size: clamp(2.4rem, 6vw, 3.9rem); line-height: 1.03; letter-spacing: -.055em; }
h2 { font-size: 1.2rem; letter-spacing: -.025em; }
small, .muted { color: var(--muted); }
small { display: block; }
[hidden] { display: none !important; }
.top {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: calc(15px + env(safe-area-inset-top)) max(20px, env(safe-area-inset-right)) 15px max(20px, env(safe-area-inset-left));
  border-bottom: 1px solid var(--line); background: var(--paper);
}
.brand { display: flex; align-items: center; gap: 11px; }
.brand strong { display: block; font-size: .96rem; line-height: 1.18; }
.brand small { font-size: .75rem; margin-top: 3px; }
.mark { flex: 0 0 42px; display: grid; place-items: center; height: 42px; border-radius: 15px; background: var(--green); color: white; font: 1.65rem Georgia, serif; }
.action, .secondary, .danger, .icon-button {
  min-height: 44px; padding: 9px 14px; border: 1px solid transparent; border-radius: 12px;
  font-weight: 650; white-space: nowrap;
}
.action { color: #fff; background: var(--green); }
.secondary, .icon-button { background: var(--paper); border-color: var(--line); }
.danger { color: #852d2c; background: var(--rose); }
.icon-button { padding: 6px 12px; }
.layout { display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 34px; max-width: 1150px; margin: auto; padding: 32px 28px 45px; }
nav { display: grid; align-content: start; gap: 6px; }
nav button { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 9px 12px; border: 0; border-radius: 11px; background: none; text-align: left; }
nav button[aria-current] { background: var(--light); color: #2a4730; font-weight: 700; }
svg { flex-shrink: 0; }
main { min-width: 0; }
.page-top { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin: 6px 0 22px; }
.eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .075em; text-transform: uppercase; margin-bottom: 8px; color: var(--muted); }
.hero { background: #e4ebdf; border: 1px solid #d6e0d1; border-radius: 22px; padding: 22px; color: #253e2c; }
.hero p { margin-top: 4px; }
.hero strong { display: block; font-size: clamp(1.7rem, 5vw, 2.45rem); overflow-wrap: anywhere; }
.hero .eyebrow { color: #4a6550; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 27px 0 10px; }
.section-head small { text-align: right; }
.stack { display: grid; gap: 9px; }
.card, .row, .calendar { border: 1px solid var(--line); background: var(--paper); border-radius: 15px; }
.card { padding: 17px; }
.row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; text-align: left; gap: 12px; min-height: 65px; padding: 11px 13px; width: 100%; }
.row strong, .row small { overflow-wrap: anywhere; }
.row .time { font-weight: 650; min-width: 46px; font-variant-numeric: tabular-nums; align-self: start; }
.row .time small { font-weight: 400; }
.row .chevron { color: var(--muted); }
.badge { display: inline-block; font-size: .73rem; font-weight: 650; padding: 4px 8px; border-radius: 20px; background: var(--light); color: #34543f; text-align: center; }
.badge.cancelled, .badge.no-show { background: var(--rose); color: #763c34; }
.badge.completed { background: #eee8dd; color: #514638; }
.calendar { padding: 12px; }
.week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; text-align: center; }
.week .day { min-height: 47px; display: grid; align-content: center; justify-items: center; gap: 3px; border: 0; border-radius: 10px; background: transparent; padding: 3px; }
.week .outside { color: var(--muted); }
.week .day[aria-pressed=true] { color: white; background: var(--green); }
.day .dot { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.month-controls, .buttons { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.month-controls { justify-content: space-between; margin-bottom: 10px; }
input, select { width: 100%; min-width: 0; color: var(--ink); background: white; border: 1px solid #d2c9bc; border-radius: 10px; padding: 9px; min-height: 44px; }
label { display: grid; gap: 4px; font-weight: 620; font-size: .91rem; min-width: 0; }
label input, label select { font-size: 1rem; font-weight: 400; }
.pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.search { margin-bottom: 10px; }
#dialog { width: min(94vw, 500px); max-height: 90dvh; overscroll-behavior: contain; border: 1px solid var(--line); border-radius: 20px; background: var(--paper); padding: 19px; color: var(--ink); }
#dialog::backdrop { background: #22282077; }
#dialog-title { font-size: 1.8rem; }
.dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 14px; }
.dialog-head button { font-size: 1.36rem; }
fieldset { padding: 0; margin: 0; border: 0; min-width: 0; }
.error { color: #8d2927; }
#toast { position: fixed; right: 16px; bottom: calc(20px + env(safe-area-inset-bottom)); max-width: calc(100vw - 32px); padding: 10px 14px; background: var(--green); color: white; border-radius: 12px; z-index: 3; }
#toast:empty { display: none; }
@media (max-width: 700px) {
  .layout { display: block; padding: 17px 15px calc(88px + env(safe-area-inset-bottom)); }
  nav { position: fixed; z-index: 2; bottom: 0; left: 0; right: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 2px; padding: 6px 5px calc(6px + env(safe-area-inset-bottom)); background: var(--paper); border-top: 1px solid var(--line); }
  nav button { flex-direction: column; justify-content: center; font-size: .69rem; text-align: center; gap: 3px; padding: 5px 2px; }
  .top { padding-left: 15px; padding-right: 15px; }
  .quick { font-size: .82rem; padding: 8px 10px; }
  #toast { bottom: calc(72px + env(safe-area-inset-bottom)); }
}
.check { display: flex; align-items: center; gap: 8px; }
.check input { width: 21px; min-height: 21px; accent-color: var(--green); }
#download { justify-self: start; color: var(--green); font-weight: 650; padding: 8px 0; }
