/* Sursum Meet home. Light, ruled, one accent. Lists are rows divided by hairlines, not cards. */
body.mh { min-height: 100%; }

/* ---------------------------------------------------------------- header */
.mh-head {
  position: sticky; top: 0; z-index: 20; height: 64px; display: flex; align-items: center; gap: 36px;
  padding: 0 max(24px, calc((100vw - 992px) / 2));
  background: color-mix(in srgb, var(--canvas) 90%, transparent); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.mh-nav { display: flex; height: 100%; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.mh-nav::-webkit-scrollbar { display: none; }
.mh-nav button {
  position: relative; height: 100%; padding: 0 14px; display: inline-flex; align-items: center; gap: 8px;
  font-size: var(--t-md); font-weight: 500; color: var(--ink-3); white-space: nowrap; transition: color .15s;
}
.mh-nav button:hover { color: var(--ink); }
.mh-nav button.on { color: var(--ink); }
.mh-nav button.on::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: -1px; height: 2px; background: var(--accent); border-radius: 2px 2px 0 0; }
.mh-dot {
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--accent); color: #fff;
  font-size: 11px; font-weight: 600; display: inline-grid; place-items: center; font-variant-numeric: tabular-nums;
}
.mh-me { margin-left: auto; position: relative; }
.mh-me-btn {
  display: flex; align-items: center; gap: 10px; padding: 4px 10px 4px 4px; border-radius: 999px;
  border: 1px solid transparent; color: var(--ink-3); transition: border-color .15s, background .15s;
}
.mh-me-btn:hover, .mh-me-btn[aria-expanded="true"] { border-color: var(--line); background: var(--surface); color: var(--ink); }
.mh-who { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--t-sm); font-weight: 500; color: var(--ink-2); }
.mh-menu {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 210px; padding: 6px; z-index: 30;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow-pop);
}
.mh-menu a, .mh-menu button {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border-radius: 8px;
  font-size: var(--t-sm); font-weight: 500; text-decoration: none; color: var(--ink-2); text-align: left;
}
.mh-menu a:hover, .mh-menu button:hover { background: var(--sunken); color: var(--ink); }

/* ---------------------------------------------------------------- page */
.mh-main { max-width: 1040px; margin: 0 auto; padding: 72px 24px 120px; }
.mh-tab:not(.wide) { max-width: 720px; margin: 0 auto; }
.mh-tab.wide { padding-top: 0; margin-top: -24px; }
.mh-state { padding: 120px 0; text-align: center; color: var(--ink-3); }
.mh-state .btn { margin-top: 16px; }
.mh-h1 { font-size: var(--t-2xl); line-height: 1.1; letter-spacing: -.03em; font-weight: 600; margin-right: auto; }
.mh-bar { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 28px; }
.mh-seg { display: inline-flex; padding: 3px; background: var(--sunken); border-radius: 10px; }
.mh-seg button { height: 30px; padding: 0 14px; border-radius: 8px; font-size: var(--t-sm); font-weight: 500; color: var(--ink-3); }
.mh-seg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(23, 35, 29, .1); }

/* ---------------------------------------------------------------- home: command-first */
.mh-greet { font-size: var(--t-3xl); line-height: 1.05; letter-spacing: -.04em; font-weight: 600; text-wrap: balance; }
.mh-sub { margin-top: 12px; font-size: var(--t-lg); color: var(--ink-3); }
.mh-cmd {
  margin-top: 40px; display: flex; align-items: center; gap: 14px; height: 60px; padding: 0 20px;
  background: var(--surface); border: 1px solid var(--line-strong); border-radius: 18px; color: var(--ink-3);
  box-shadow: 0 1px 2px rgba(23, 35, 29, .04), 0 10px 28px -16px rgba(23, 35, 29, .22);
  transition: border-color .15s, box-shadow .2s var(--ease);
}
.mh-cmd:focus-within { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(22, 134, 90, .13), 0 10px 28px -16px rgba(23, 35, 29, .22); color: var(--accent-text); }
.mh-cmd input { flex: 1; min-width: 0; height: 100%; border: 0; outline: none; background: transparent; font-size: 18px; color: var(--ink); letter-spacing: -.01em; }
.mh-cmd input:focus-visible { outline: none; }

.mh-cmd-list { margin-top: 8px; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-pop); }
.mh-cmd-group { padding: 10px 12px 4px; font-size: var(--t-xs); font-weight: 600; color: var(--ink-3); }
.mh-cmd-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 12px; border-radius: 10px; text-align: left; }
.mh-cmd-item[aria-selected="true"] { background: var(--accent-soft); }
.mh-cmd-ico { display: grid; place-items: center; width: 34px; height: 34px; flex: none; border-radius: 9px; background: var(--sunken); color: var(--ink-2); }
.mh-cmd-item[aria-selected="true"] .mh-cmd-ico { background: var(--surface); color: var(--accent-text); }
.mh-cmd-txt { min-width: 0; flex: 1; display: grid; }
.mh-cmd-txt b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mh-cmd-txt small { font-size: var(--t-sm); color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mh-cmd-item kbd { visibility: hidden; }
.mh-cmd-item[aria-selected="true"] kbd { visibility: visible; }

.mh-quick { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.mh-drawer { margin-top: 16px; padding: 20px; display: grid; gap: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
.mh-row { display: flex; gap: 10px; flex-wrap: wrap; }
.mh-row .input { flex: 1 1 180px; min-width: 0; }
.mh-slug {
  flex: 2 1 260px; display: flex; align-items: center; height: 44px; min-width: 0; padding-left: 14px; border-radius: var(--r-md);
  border: 1px solid var(--line-strong); background: var(--surface); transition: border-color .15s, box-shadow .15s;
}
.mh-slug:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(22, 134, 90, .18); }
.mh-slug span { font-family: var(--mono); font-size: var(--t-sm); color: var(--ink-4); white-space: nowrap; }
.mh-slug input { flex: 1; min-width: 0; height: 100%; border: 0; outline: none; background: transparent; padding: 0 12px 0 2px; font-size: var(--t-md); }
.mh-slug input:focus-visible { outline: none; }
.mh-result { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 14px; border-radius: var(--r-md); background: var(--accent-soft); }
.mh-result code { flex: 1 1 220px; font-family: var(--mono); font-size: var(--t-sm); color: var(--accent-text); overflow-wrap: anywhere; }

/* agenda: day heading, then ruled rows */
.mh-agenda { margin-top: 64px; }
.mh-day { padding-bottom: 10px; border-bottom: 1px solid var(--line); font-size: var(--t-sm); font-weight: 600; color: var(--ink-3); }
.mh-agenda .mh-day:not(:first-child) { margin-top: 32px; }

/* ---------------------------------------------------------------- rows: meetings, people */
.mh-list { display: grid; }
.mh-item { display: grid; grid-template-columns: 92px minmax(0, 1fr) auto; gap: 8px 20px; align-items: start; padding: 18px 0; border-bottom: 1px solid var(--line); }
.mh-item.cancelled { opacity: .55; }
.mh-list .mh-item { grid-template-columns: 136px minmax(0, 1fr) auto; }
.mh-when { display: grid; gap: 2px; padding-top: 1px; }
.mh-when time { font-size: var(--t-md); font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.mh-when span { font-size: var(--t-sm); color: var(--ink-3); font-variant-numeric: tabular-nums; }
.mh-body { min-width: 0; display: grid; gap: 6px; }
.mh-title { font-size: var(--t-lg); font-weight: 600; letter-spacing: -.015em; line-height: 1.3; overflow-wrap: anywhere; }
.mh-meta { font-size: var(--t-sm); color: var(--ink-3); line-height: 1.5; overflow-wrap: anywhere; }
.mh-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.mh-tag { font-size: var(--t-xs); font-weight: 500; padding: 2px 9px; border-radius: 999px; background: var(--sunken); color: var(--ink-3); }
.mh-tag.host { background: var(--accent-soft); color: var(--accent-text); }
.mh-chip { font-size: var(--t-sm); padding: 3px 10px; border-radius: 999px; background: var(--sunken); color: var(--ink-2); display: inline-flex; align-items: center; gap: 6px; }
.mh-chip.st-accepted { background: var(--accent-soft); color: var(--accent-text); }
.mh-chip.st-declined { color: var(--danger); text-decoration: line-through; }
.mh-chip button { color: var(--ink-3); line-height: 1; display: inline-grid; }
.mh-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.mh-link { display: flex; gap: 8px; align-items: center; min-width: 0; }
.mh-link code { font-family: var(--mono); font-size: var(--t-xs); color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mh-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; justify-content: flex-end; }
.mh-empty { padding: 56px 0; text-align: center; color: var(--ink-3); line-height: 1.6; }
.mh-empty .link { margin-left: 4px; }
.mh-more { padding-top: 20px; }

.mh-person { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 18px 0; border-bottom: 1px solid var(--line); }
.mh-person h3 { font-size: var(--t-lg); font-weight: 600; letter-spacing: -.015em; overflow-wrap: anywhere; }
.mh-person h3 small { margin-left: 6px; font-size: var(--t-sm); font-weight: 400; color: var(--ink-3); }
.mh-optin { padding: 0 0 24px; margin-bottom: 20px; border-bottom: 1px solid var(--line); max-width: 640px; }
.mh-search { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 16px; margin-bottom: 8px; border: 1px solid var(--line-strong); border-radius: var(--r-md); background: var(--surface); color: var(--ink-3); }
.mh-search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(22, 134, 90, .18); }
.mh-search input { flex: 1; min-width: 0; height: 100%; border: 0; outline: none; background: transparent; font-size: var(--t-md); color: var(--ink); }
.mh-search input:focus-visible { outline: none; }

/* ---------------------------------------------------------------- schedule form */
.mh-form { margin-bottom: 32px; padding: 24px; display: grid; gap: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); }
.mh-form h2 { font-size: var(--t-xl); font-weight: 600; letter-spacing: -.02em; }
.mh-fgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.mh-fgrid .full { grid-column: 1 / -1; }
.mh-label { display: grid; gap: 6px; font-size: var(--t-sm); font-weight: 500; color: var(--ink-2); }
.mh-input, .mh-select {
  width: 100%; height: 44px; padding: 0 14px; border-radius: var(--r-md); outline: none; font-size: var(--t-md); font-weight: 400;
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); transition: border-color .15s, box-shadow .15s;
}
textarea.mh-input { height: auto; min-height: 76px; padding: 11px 14px; line-height: 1.45; resize: vertical; }
.mh-input.mono { font-family: var(--mono); font-size: var(--t-sm); }
.mh-input:focus, .mh-select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(22, 134, 90, .18); }
.mh-radio { display: flex; gap: 12px 28px; flex-wrap: wrap; font-size: var(--t-md); color: var(--ink-2); }
.mh-radio label { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.mh-radio input { margin-top: 3px; }
.mh-radio small { display: block; color: var(--ink-3); font-size: var(--t-sm); }
.mh-picker { position: relative; }
.mh-pick-results { position: absolute; left: 0; right: 0; top: 100%; margin-top: 6px; z-index: 6; max-height: 260px; overflow: auto; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--shadow-pop); }
.mh-pick-results button { display: block; width: 100%; text-align: left; padding: 9px 12px; border-radius: 8px; font-size: var(--t-md); }
.mh-pick-results button:hover { background: var(--sunken); }
.mh-pick-results small { display: block; color: var(--ink-3); font-size: var(--t-sm); }
.mh-fbtns { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

/* ---------------------------------------------------------------- messages */
.mh-msgs {
  display: grid; grid-template-columns: 340px minmax(0, 1fr); overflow: hidden;
  height: calc(100dvh - 64px - 180px); min-height: 480px; max-height: 760px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
}
.mh-threads { overflow: auto; border-right: 1px solid var(--line); }
.mh-thread { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 16px; text-align: left; border-bottom: 1px solid var(--line); }
.mh-thread:hover { background: var(--sunken); }
.mh-thread.on { background: var(--accent-soft); }
.mh-tbody { min-width: 0; flex: 1; display: grid; gap: 2px; }
.mh-tbody b { display: flex; justify-content: space-between; gap: 8px; font-weight: 600; font-size: var(--t-md); }
.mh-tbody b time { font-weight: 400; font-size: var(--t-xs); color: var(--ink-3); font-variant-numeric: tabular-nums; }
.mh-tbody span { font-size: var(--t-sm); color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mh-convo { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; min-width: 0; min-height: 0; }
.mh-chead { display: flex; align-items: center; gap: 12px; padding: 14px 20px; border-bottom: 1px solid var(--line); }
.mh-chead b { flex: 1; min-width: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mh-back { display: none; width: 32px; height: 32px; place-items: center; border-radius: 8px; color: var(--ink-3); }
.mh-mlist { overflow: auto; padding: 20px; display: flex; flex-direction: column; gap: 6px; }
.mh-msg { max-width: min(78%, 480px); padding: 9px 14px; border-radius: 16px 16px 16px 4px; background: var(--sunken); line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; align-self: flex-start; }
.mh-msg.me { align-self: flex-end; background: var(--accent); color: #fff; border-radius: 16px 16px 4px 16px; }
.mh-msg time { display: block; margin-top: 2px; font-size: 11px; opacity: .7; font-variant-numeric: tabular-nums; }
.mh-mcard { align-self: flex-start; max-width: min(88%, 400px); display: grid; gap: 6px; padding: 14px 16px; border: 1px solid var(--line-strong); border-radius: var(--r-md); }
.mh-mcard.me { align-self: flex-end; }
.mh-mcard .k { font-size: var(--t-xs); font-weight: 600; color: var(--accent-text); }
.mh-mcard b { font-weight: 600; overflow-wrap: anywhere; }
.mh-compose { display: flex; gap: 10px; align-items: flex-end; padding: 12px 16px; border-top: 1px solid var(--line); }
.mh-compose textarea { flex: 1; min-height: 44px; max-height: 120px; }
.mh-pad { padding: 48px 28px; text-align: center; color: var(--ink-3); line-height: 1.6; }

/* ---------------------------------------------------------------- phones */
@media (max-width: 760px) {
  .mh-head { gap: 8px; padding: 0 16px; flex-wrap: wrap; height: auto; padding-top: 10px; }
  .mh-brand { order: 0; }
  .mh-me { order: 1; }
  .mh-nav { order: 2; flex-basis: 100%; height: 44px; margin: 0 -8px; }
  .mh-who { display: none; }
  .mh-me-btn { padding-right: 4px; }
  .mh-me-btn > .i { display: none; }
  .mh-main { padding: 40px 16px 96px; }
  .mh-tab.wide { margin-top: 0; }
  .mh-greet { font-size: 34px; }
  .mh-sub { font-size: var(--t-md); }
  .mh-cmd { height: 56px; margin-top: 28px; }
  .mh-cmd input { font-size: 16px; }
  .mh-cmd kbd { display: none; }
  .mh-item, .mh-list .mh-item { grid-template-columns: 76px minmax(0, 1fr); }
  .mh-item .mh-actions { grid-column: 2; justify-content: flex-start; }
  .mh-person { grid-template-columns: auto minmax(0, 1fr); }
  .mh-person .mh-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .mh-fgrid { grid-template-columns: 1fr; }
  .mh-msgs { grid-template-columns: 1fr; height: calc(100dvh - 190px); }
  .mh-msgs .mh-convo { display: none; }
  .mh-msgs.open .mh-threads { display: none; }
  .mh-msgs.open .mh-convo { display: grid; }
  .mh-back { display: grid; }
}

.mh-foot { max-width: 1040px; margin: 0 auto; padding: 28px 24px 44px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 22px; border-top: 1px solid var(--line); font-size: var(--t-sm); color: var(--ink-3); }
.mh-foot-brand { display: inline-flex; align-items: center; gap: 8px; margin-right: auto; }
.mh-foot-brand img { display: block; }
.mh-foot a { color: var(--ink-3); text-decoration: none; }
.mh-foot a:hover { color: var(--accent-text); text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 760px) { .mh-foot { padding: 24px 16px 40px; } }
