:root {
  color-scheme: light;
  --canvas: #dce7ea;
  --glass: rgba(255, 255, 255, 0.52);
  --glass-strong: rgba(255, 255, 255, 0.72);
  --panel: rgba(248, 251, 252, 0.78);
  --line: rgba(255, 255, 255, 0.7);
  --line-dark: rgba(28, 45, 54, 0.13);
  --text: #142028;
  --muted: #697780;
  --blue: #2f6bff;
  --blue-soft: rgba(47, 107, 255, 0.12);
  --teal: #0d7b83;
  --teal-soft: rgba(13, 123, 131, 0.12);
  --gold: #d8aa50;
  --green: #218659;
  --green-soft: rgba(33, 134, 89, 0.12);
  --red: #c93e51;
  --red-soft: rgba(201, 62, 81, 0.11);
  --amber: #9c6612;
  --amber-soft: rgba(216, 170, 80, 0.18);
  --glass-shadow: 0 18px 45px rgba(34, 61, 73, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  --panel-shadow: 0 10px 28px rgba(41, 67, 78, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

* { box-sizing: border-box; }
.is-hidden { display: none !important; }
html, body { min-width: 320px; min-height: 100%; }

body {
  margin: 0;
  background: #cfdadd;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
  letter-spacing: 0;
}

button, textarea, select, input { font: inherit; }
button { color: inherit; }
button, select, input { -webkit-tap-highlight-color: transparent; }
button { transition: transform 160ms ease, filter 160ms ease, box-shadow 160ms ease; }
button:active { transform: scale(0.975); filter: brightness(1.03); }
svg { width: 20px; height: 20px; stroke-width: 1.9; }

.app-shell {
  position: relative;
  width: min(100%, 480px);
  min-height: 100dvh;
  margin: 0 auto;
  padding: calc(env(safe-area-inset-top) + 12px) 14px calc(env(safe-area-inset-bottom) + 100px);
  overflow: hidden;
  isolation: isolate;
  background-color: #d9dfe1;
  background-image:
    repeating-linear-gradient(55deg, rgba(83, 96, 101, 0.1) 0 1px, transparent 1px 5px),
    repeating-linear-gradient(125deg, rgba(255, 255, 255, 0.34) 0 1px, transparent 1px 5px),
    repeating-linear-gradient(0deg, transparent 0 7px, rgba(87, 101, 106, 0.055) 7px 8px);
  background-size: 10px 10px, 10px 10px, 100% 8px;
}

.app-shell::before {
  position: absolute;
  z-index: -2;
  inset: 0;
  background: linear-gradient(145deg, rgba(255,255,255,.22), transparent 42%, rgba(103,118,124,.07));
  content: "";
}

.app-shell::after {
  position: absolute;
  z-index: -1;
  inset: 0;
  background: rgba(233, 238, 239, 0.09);
  content: "";
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.app-header,
.install-strip,
.schedule-overview,
.segmented,
.tabbar,
.icon-button,
.sheet {
  border: 1px solid var(--line);
  background:
    radial-gradient(110px circle at var(--glass-x, 24%) var(--glass-y, 0%), rgba(255,255,255,.92), transparent 72%),
    linear-gradient(135deg, rgba(255,255,255,.57), rgba(255,255,255,.2));
  box-shadow:
    0 18px 45px rgba(34, 61, 73, 0.16),
    inset 0 2px 1px rgba(255,255,255,.96),
    inset 0 -1px 1px rgba(73,94,103,.13);
  backdrop-filter: blur(22px) saturate(175%);
  -webkit-backdrop-filter: blur(22px) saturate(175%);
}

.app-header {
  display: flex;
  min-height: 76px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 11px;
  border-radius: 25px;
}

.brand-block { display: flex; min-width: 0; align-items: center; gap: 11px; }
.brand-icon {
  position: relative;
  display: grid;
  width: 50px;
  height: 50px;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(255,255,255,.72);
  border-radius: 17px;
  overflow: hidden;
  background: linear-gradient(145deg, #2a2c2f, #090a0b);
  box-shadow: 0 12px 26px rgba(15,18,20,.24), inset 0 1px 0 rgba(255,255,255,.26);
  color: #fff;
  font-size: 20px;
  font-weight: 850;
}
.brand-icon::after { display: none; }
.brand-copy { min-width: 0; }
.brand-parent { display: block; width: fit-content; color: var(--teal); font-size: 9px; font-weight: 820; text-decoration: none; }
.brand-copy small { display: block; margin-top: 2px; color: var(--muted); font-size: 10px; }
h1 { display: flex; align-items: center; gap: 7px; margin: 1px 0 0; font-size: 23px; line-height: 1.05; }
h1 span, .count-pill {
  display: inline-grid;
  min-width: 25px;
  height: 25px;
  place-items: center;
  padding: 0 7px;
  border-radius: 999px;
  background: linear-gradient(145deg, #4b7cff, #2360ee);
  box-shadow: 0 6px 14px rgba(47,107,255,.25), inset 0 1px 0 rgba(255,255,255,.42);
  color: #fff;
  font-size: 11px;
  font-weight: 760;
}

.icon-button, .close-button {
  display: grid;
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 50%;
  cursor: pointer;
}
.close-button { width: 30px; height: 30px; border: 0; background: transparent; box-shadow: none; color: var(--muted); }
.close-button svg { width: 16px; height: 16px; }

.install-strip {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto 28px;
  align-items: center;
  gap: 9px;
  margin: 12px 0;
  padding: 9px 8px 9px 9px;
  border-radius: 22px;
}
.install-icon { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 14px; background: linear-gradient(145deg, #26383e, #111a1f); color: #fff; box-shadow: inset 0 1px 0 rgba(255,255,255,.28); }
.install-copy { min-width: 0; }
.install-copy strong, .install-copy small { display: block; }
.install-copy strong { font-size: 13px; }
.install-copy small { margin-top: 2px; overflow: hidden; color: var(--muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.text-button { min-height: 38px; padding: 0 13px; border: 1px solid rgba(255,255,255,.65); border-radius: 19px; background: rgba(47,107,255,.13); color: var(--blue); font-size: 12px; font-weight: 760; cursor: pointer; }

.schedule-overview {
  margin: 12px 0;
  padding: 13px 12px 12px;
  border-radius: 26px;
}
.overview-header { display: flex; align-items: end; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.overview-header > span:first-child { min-width: 0; }
.overview-header small, .overview-header strong { display: block; }
.overview-header small { color: var(--muted); font-size: 9px; }
.overview-header strong { margin-top: 2px; font-size: 14px; }
.overview-legend { display: flex; flex: 0 0 auto; align-items: center; gap: 4px; color: var(--muted); font-size: 8px; }
.overview-legend .slot-dot + .slot-dot { margin-left: 3px; }
.overview-week + .overview-week { margin-top: 9px; padding-top: 9px; border-top: 1px solid rgba(42,61,69,.1); }
.overview-week-title { display: block; margin: 0 2px 5px; color: var(--muted); font-size: 9px; font-weight: 680; }
.overview-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.overview-day {
  display: grid;
  min-width: 0;
  min-height: 54px;
  place-items: center;
  gap: 1px;
  padding: 5px 1px;
  border: 1px solid rgba(255,255,255,.68);
  border-radius: 15px;
  background: rgba(255,255,255,.28);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.82);
  cursor: pointer;
}
.overview-day small { color: var(--muted); font-size: 8px; }
.overview-day strong { font-size: 12px; }
.overview-day > span { display: flex; min-height: 7px; align-items: center; justify-content: center; gap: 2px; }
.overview-day.is-today { border-color: rgba(47,107,255,.42); background: rgba(47,107,255,.11); box-shadow: 0 6px 14px rgba(47,107,255,.1), inset 0 1px 0 rgba(255,255,255,.86); }
.slot-dot { display: inline-block; width: 5px; height: 5px; border-radius: 50%; }
.slot-dot.is-free { background: #54a98a; box-shadow: 0 0 6px rgba(55,156,118,.42); }
.slot-dot.is-busy { background: #b87b83; box-shadow: 0 0 5px rgba(172,91,103,.3); }
.slot-dot.is-off { background: rgba(105,119,128,.24); box-shadow: none; }

.segmented {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  padding: 4px;
  border-radius: 23px;
}
.segmented button {
  min-width: 0;
  min-height: 42px;
  padding: 0 8px;
  overflow: hidden;
  border: 0;
  border-radius: 19px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 690;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}
.segmented button.is-active { background: rgba(255,255,255,.78); color: var(--text); box-shadow: 0 6px 18px rgba(35,58,67,.12), inset 0 1px 0 #fff; }
.segmented button span { margin-left: 3px; color: var(--blue); }

.queue { display: grid; gap: 11px; padding: 13px 1px 12px; }
.queue-empty { padding: 56px 20px; color: var(--muted); text-align: center; }
.queue-empty svg { width: 34px; height: 34px; margin-bottom: 8px; }

.conversation-row {
  position: relative;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) auto;
  gap: 11px;
  width: 100%;
  min-height: 102px;
  align-items: start;
  padding: 14px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.72);
  border-radius: 24px;
  background:
    radial-gradient(120px circle at var(--glass-x, 16%) var(--glass-y, 0%), rgba(255,255,255,.86), transparent 72%),
    rgba(248,251,252,.53);
  box-shadow:
    0 14px 30px rgba(41,67,78,.13),
    inset 0 2px 1px rgba(255,255,255,.97),
    inset 0 -1px 1px rgba(75,96,105,.12);
  text-align: left;
  backdrop-filter: blur(18px) saturate(135%);
  -webkit-backdrop-filter: blur(18px) saturate(135%);
  cursor: pointer;
}
.conversation-row::before { position: absolute; inset: 0; background: linear-gradient(118deg, rgba(255,255,255,.52), transparent 38%); content: ""; pointer-events: none; }
.conversation-row > * { position: relative; }
.avatar { display: grid; width: 48px; height: 48px; place-items: center; border: 1px solid rgba(255,255,255,.72); border-radius: 50%; background: var(--avatar-bg); box-shadow: inset 0 1px 0 #fff, 0 6px 14px rgba(31,56,67,.1); color: var(--avatar-text); font-size: 13px; font-weight: 760; }
.row-copy { min-width: 0; }
.row-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.row-title strong { min-width: 0; overflow: hidden; font-size: 15px; text-overflow: ellipsis; white-space: nowrap; }
.row-title time { flex: 0 0 auto; color: var(--muted); font-size: 10px; }
.row-preview { display: -webkit-box; margin: 5px 0 8px; overflow: hidden; color: #42515a; font-size: 13px; line-height: 1.38; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.row-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.status, .hint-chip { display: inline-flex; min-height: 23px; align-items: center; padding: 0 9px; border-radius: 999px; background: var(--blue-soft); color: #175ac7; font-size: 10px; font-weight: 720; }
.status--overdue { background: var(--red-soft); color: var(--red); }
.status--today { background: var(--amber-soft); color: var(--amber); }
.status--snoozed { background: rgba(94, 111, 124, 0.12); color: #53636d; }
.status--suggested { background: var(--green-soft); color: var(--green); }
.unread-dot { display: grid; min-width: 23px; height: 23px; place-items: center; margin-top: 2px; padding: 0 6px; border-radius: 999px; background: var(--blue); box-shadow: 0 6px 12px rgba(47,107,255,.24); color: #fff; font-size: 10px; font-weight: 760; }

.tabbar {
  position: fixed;
  z-index: 20;
  right: 0;
  bottom: calc(env(safe-area-inset-bottom) + 10px);
  left: 0;
  display: grid;
  width: min(calc(100% - 24px), 456px);
  grid-template-columns: repeat(3, 1fr);
  margin: 0 auto;
  padding: 6px;
  border-radius: 31px;
}
.tabbar button { display: grid; min-height: 52px; place-items: center; gap: 2px; border: 0; border-radius: 25px; background: transparent; color: #6c7980; font-size: 10px; cursor: pointer; }
.tabbar button.is-active { background: rgba(255,255,255,.64); box-shadow: 0 6px 16px rgba(41,65,75,.11), inset 0 1px 0 #fff; color: var(--blue); }
.tabbar svg { width: 21px; height: 21px; }

.sheet-layer {
  position: fixed;
  z-index: 40;
  inset: 0;
  display: none;
  align-items: end;
  justify-content: center;
  padding: 12px 10px calc(env(safe-area-inset-bottom) + 10px);
}
.sheet-layer.is-open { display: flex; }
.sheet-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(40, 53, 58, 0.18);
  backdrop-filter: blur(12px) saturate(115%);
  -webkit-backdrop-filter: blur(12px) saturate(115%);
}
.sheet {
  position: relative;
  z-index: 1;
  width: min(100%, 460px);
  max-height: calc(100dvh - env(safe-area-inset-top) - env(safe-area-inset-bottom) - 30px);
  padding: 12px 15px 20px;
  overflow-y: auto;
  border: 1px solid rgba(255,255,255,.82);
  border-radius: 38px;
  background:
    radial-gradient(220px circle at var(--glass-x, 24%) var(--glass-y, 0%), rgba(255,255,255,.94), transparent 72%),
    linear-gradient(145deg, rgba(247,251,252,.66), rgba(219,230,233,.42));
  box-shadow:
    0 30px 80px rgba(25,50,61,.28),
    0 3px 10px rgba(25,50,61,.12),
    inset 0 2px 1px rgba(255,255,255,.98),
    inset 0 -2px 2px rgba(75,96,105,.12);
  backdrop-filter: blur(30px) saturate(185%);
  -webkit-backdrop-filter: blur(30px) saturate(185%);
}
.sheet::before {
  display: block;
  width: 42px;
  height: 5px;
  margin: 0 auto 10px;
  border: 1px solid rgba(255,255,255,.55);
  border-radius: 999px;
  background: rgba(88,104,111,.24);
  box-shadow: inset 0 1px 1px rgba(255,255,255,.75);
  content: "";
}
.sheet::after {
  position: absolute;
  z-index: -1;
  top: 1px;
  right: 20px;
  left: 20px;
  height: 38%;
  border-radius: 36px 36px 50% 50%;
  background: linear-gradient(180deg, rgba(255,255,255,.3), transparent);
  content: "";
  pointer-events: none;
}
.sheet-header { display: flex; min-height: 46px; align-items: center; justify-content: space-between; gap: 12px; }
.sheet-header h2 { margin: 0; font-size: 21px; }
.sheet-header .icon-button {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255,255,255,.78);
  background: rgba(255,255,255,.38);
  box-shadow: 0 7px 18px rgba(42,65,75,.1), inset 0 2px 1px rgba(255,255,255,.94);
}
.person-line { display: flex; align-items: center; gap: 11px; margin: 3px 2px 16px; }
.person-line h2 { margin: 0; font-size: 21px; }
.person-line p { margin: 3px 0 0; color: var(--muted); font-size: 11px; }

.message-panel, .reply-panel, .settings-group {
  margin: 10px 0;
  padding: 15px;
  border: 1px solid rgba(255,255,255,.76);
  border-radius: 22px;
  background:
    radial-gradient(120px circle at var(--glass-x, 18%) var(--glass-y, 0%), rgba(255,255,255,.9), transparent 74%),
    rgba(255,255,255,.42);
  box-shadow:
    0 13px 28px rgba(41,67,78,.12),
    inset 0 2px 1px rgba(255,255,255,.96),
    inset 0 -1px 1px rgba(73,94,103,.13);
  backdrop-filter: blur(18px) saturate(155%);
  -webkit-backdrop-filter: blur(18px) saturate(155%);
}
.section-label { margin: 0 0 8px; color: var(--muted); font-size: 11px; font-weight: 690; }
.message-panel p { margin: 0; font-size: 15px; line-height: 1.46; }
.message-panel time { display: block; margin-top: 7px; color: var(--muted); font-size: 10px; text-align: right; }
.classification-callout {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 10px 0;
  padding: 12px 14px;
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(238,255,247,.64), rgba(211,240,226,.34));
  box-shadow: 0 11px 24px rgba(41,67,78,.09), inset 0 2px 1px rgba(255,255,255,.94);
  color: #24633d;
  font-size: 12px;
  font-weight: 680;
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
}
.classification-actions, .slot-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 8px; }
.quick-actions { display: grid; grid-template-columns: 1fr; gap: 8px; margin-top: 9px; }
.action-button, .primary-button, .secondary-button, .danger-button {
  display: inline-flex;
  min-height: 49px;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 0 14px;
  border: 1px solid rgba(255,255,255,.72);
  border-radius: 22px;
  box-shadow: inset 0 2px 1px rgba(255,255,255,.82), inset 0 -1px 1px rgba(54,77,87,.1), 0 9px 20px rgba(39,63,74,.1);
  font-size: 13px;
  font-weight: 720;
  cursor: pointer;
}
.primary-button { background: linear-gradient(145deg, rgba(92,137,255,.96), rgba(40,94,234,.94)); color: #fff; }
.secondary-button { background: rgba(255,255,255,.36); color: #25343c; backdrop-filter: blur(20px) saturate(155%); -webkit-backdrop-filter: blur(20px) saturate(155%); }
.danger-button { background: linear-gradient(145deg, rgba(255,242,244,.62), rgba(244,211,217,.38)); color: var(--red); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
.action-button { min-height: 45px; padding: 6px 10px; background: rgba(255,255,255,.38); color: #34434b; line-height: 1.2; backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
.action-button.is-selected { border-color: rgba(47,107,255,.5); background: rgba(47,107,255,.15); box-shadow: inset 0 1px 0 rgba(255,255,255,.8), 0 8px 17px rgba(47,107,255,.14); color: #1258c6; }
.full-width { width: 100%; margin-top: 9px; }
.week-group { margin: 10px 0 13px; }
.week-title { display: flex; align-items: center; justify-content: space-between; margin: 0 2px 5px; color: var(--text); font-size: 12px; font-weight: 720; }
.week-title small { color: var(--muted); font-size: 10px; font-weight: 580; }
.no-slots { margin: 0; padding: 12px 2px; color: var(--muted); font-size: 12px; }
.custom-slot { display: flex; width: 100%; min-height: 47px; align-items: center; justify-content: center; gap: 8px; margin: 7px 0 0; border: 1px solid rgba(255,255,255,.8); border-radius: 22px; background: rgba(255,255,255,.35); box-shadow: 0 9px 20px rgba(39,63,74,.08), inset 0 2px 1px rgba(255,255,255,.92); color: var(--blue); font-size: 13px; font-weight: 720; backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); cursor: pointer; }
.custom-slot svg { width: 18px; height: 18px; }
.custom-date-panel { display: none; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; padding: 12px; border: 1px solid rgba(255,255,255,.8); border-radius: 24px; background: rgba(255,255,255,.34); box-shadow: 0 12px 26px rgba(41,67,78,.09), inset 0 2px 1px rgba(255,255,255,.92); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); }
.custom-date-panel.is-open { display: grid; }
.custom-date-panel label { display: grid; gap: 5px; color: var(--muted); font-size: 10px; font-weight: 650; }
.custom-date-panel input { width: 100%; min-width: 0; height: 42px; padding: 0 9px; border: 1px solid rgba(255,255,255,.82); border-radius: 16px; outline: 0; background: rgba(255,255,255,.36); box-shadow: inset 0 2px 1px rgba(255,255,255,.92); color: var(--text); }
.custom-date-panel .primary-button { grid-column: 1 / -1; }
.reply-panel textarea, .settings-group textarea, .settings-group select { width: 100%; border: 0; outline: 0; background: transparent; color: var(--text); resize: vertical; }
.reply-panel textarea { min-height: 108px; font-size: 15px; line-height: 1.45; }
.reply-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.reply-heading .section-label { margin: 0; }
.context-badge { display: inline-flex; min-height: 24px; align-items: center; gap: 4px; padding: 0 9px; border-radius: 999px; background: rgba(33,134,89,.1); color: var(--green); font-size: 9px; font-weight: 720; white-space: nowrap; }
.context-badge svg { width: 12px; height: 12px; }
.context-summary { margin: 0 0 10px; padding: 10px 11px; border: 1px solid rgba(255,255,255,.7); border-radius: 16px; background: rgba(255,255,255,.28); color: var(--muted); font-size: 11px; line-height: 1.35; }
.privacy-line { display: flex; align-items: center; gap: 6px; margin: 13px 3px 2px; color: var(--muted); font-size: 10px; }
.privacy-line svg { width: 14px; height: 14px; }

.settings-group label, .setting-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 9px; font-size: 13px; font-weight: 720; }
.settings-group select { min-height: 38px; color: var(--blue); }
.settings-group textarea { min-height: 110px; line-height: 1.4; }
.setting-value { color: var(--blue); font-size: 11px; font-weight: 680; }
.switch-row, .select-row { min-height: 48px; margin: 0 !important; border-top: 1px solid var(--line-dark); }
.switch-row:first-of-type, .setting-title + .select-row { border-top: 0; }
.switch-row span, .select-row span { min-width: 0; font-weight: 540; }
.switch-row small { display: block; margin-top: 2px; color: var(--muted); font-size: 10px; font-weight: 500; }
.switch-row input { position: relative; width: 50px; height: 30px; flex: 0 0 auto; margin: 0; border: 0; border-radius: 15px; appearance: none; background: rgba(105,119,128,.28); box-shadow: inset 0 1px 4px rgba(30,45,52,.12); cursor: pointer; transition: background 160ms ease; }
.switch-row input::after { position: absolute; top: 2px; left: 2px; width: 26px; height: 26px; border-radius: 50%; background: rgba(255,255,255,.95); box-shadow: 0 3px 8px rgba(0,0,0,.18); content: ""; transition: transform 160ms ease; }
.switch-row input:checked { background: #32c75a; }
.switch-row input:checked::after { transform: translateX(20px); }
.select-row select { width: auto; max-width: 64%; border: 0; outline: 0; background: transparent; text-align: right; }
.weekday-picker { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; margin: 8px 0 12px; }
.weekday-picker button { aspect-ratio: 1; min-width: 0; border: 1px solid rgba(255,255,255,.7); border-radius: 50%; background: rgba(236,241,243,.75); color: var(--muted); font-size: 11px; font-weight: 720; cursor: pointer; }
.weekday-picker button.is-selected { border-color: rgba(47,107,255,.45); background: var(--blue); box-shadow: 0 6px 14px rgba(47,107,255,.2), inset 0 1px 0 rgba(255,255,255,.4); color: #fff; }
.time-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-bottom: 3px; }
.time-grid label { min-height: 50px; margin: 0; padding: 0 11px; border: 1px solid rgba(255,255,255,.74); border-radius: 18px; background: rgba(242,247,248,.72); }
.time-grid label span { color: var(--muted); font-size: 10px; font-weight: 620; }
.time-grid input { min-width: 0; border: 0; outline: 0; background: transparent; color: var(--blue); text-align: right; }
.snooze-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
.snooze-fields:has(label:only-child) { grid-template-columns: 1fr; }
.snooze-fields label { min-height: 50px; margin: 0; padding: 0 11px; border: 1px solid rgba(255,255,255,.76); border-radius: 18px; background: rgba(255,255,255,.4); box-shadow: inset 0 2px 1px rgba(255,255,255,.9), inset 0 -1px 1px rgba(73,94,103,.1); }
.snooze-fields label span { color: var(--muted); font-size: 10px; font-weight: 620; }
.snooze-fields input { min-width: 0; border: 0; outline: 0; background: transparent; color: var(--blue); text-align: right; }
.snooze-fields input[readonly], .time-grid input[readonly], .custom-date-panel input[readonly] { cursor: pointer; }
.snooze-fields input[readonly]:focus, .time-grid input[readonly]:focus, .custom-date-panel input[readonly]:focus { color: #174fb8; }
.excluded-row { display: flex; min-height: 46px; align-items: center; justify-content: space-between; gap: 10px; border-top: 1px solid var(--line-dark); }
.excluded-row:first-child { border-top: 0; }
.excluded-row span { min-width: 0; overflow: hidden; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.excluded-row button { min-height: 34px; flex: 0 0 auto; border: 1px solid rgba(255,255,255,.7); border-radius: 17px; background: var(--blue-soft); color: var(--blue); font-size: 11px; font-weight: 720; cursor: pointer; }

.plans-head { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin: 16px 3px 10px; }
.plans-head h2 { margin: 0; font-size: 23px; }
.plans-head small { color: var(--muted); font-size: 10px; }
.day-strip { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; margin-bottom: 12px; }
.day-button { display: grid; min-width: 0; min-height: 58px; place-items: center; padding: 6px 0; border: 1px solid rgba(255,255,255,.74); border-radius: 18px; background: rgba(255,255,255,.52); box-shadow: inset 0 1px 0 #fff, 0 6px 13px rgba(37,60,70,.06); color: var(--muted); cursor: pointer; }
.day-button small, .day-button strong { display: block; }
.day-button small { font-size: 9px; }
.day-button strong { margin-top: 3px; color: var(--text); font-size: 14px; }
.day-button.is-selected { border-color: rgba(47,107,255,.42); background: var(--blue); box-shadow: 0 8px 18px rgba(47,107,255,.2), inset 0 1px 0 rgba(255,255,255,.4); color: #fff; }
.day-button.is-selected strong { color: #fff; }
.plan-section-title { display: flex; align-items: center; justify-content: space-between; margin: 17px 3px 8px; font-size: 12px; }
.plan-section-title span { color: var(--muted); }
.appointment-row { display: grid; grid-template-columns: 54px minmax(0, 1fr) auto; gap: 10px; min-height: 76px; align-items: center; padding: 12px; border: 1px solid rgba(255,255,255,.78); border-radius: 23px; background: radial-gradient(120px circle at var(--glass-x, 18%) var(--glass-y, 0%), rgba(255,255,255,.88), transparent 74%), rgba(248,251,252,.46); box-shadow: 0 13px 28px rgba(41,67,78,.12), inset 0 2px 1px rgba(255,255,255,.96), inset 0 -1px 1px rgba(73,94,103,.13); backdrop-filter: blur(18px) saturate(155%); -webkit-backdrop-filter: blur(18px) saturate(155%); }
.appointment-time { color: var(--blue); font-size: 13px; font-weight: 780; }
.appointment-copy { min-width: 0; }
.appointment-copy strong, .appointment-copy small { display: block; }
.appointment-copy strong { overflow: hidden; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.appointment-copy small { margin-top: 4px; color: var(--muted); font-size: 10px; }
.appointment-row .icon-button { width: 36px; height: 36px; box-shadow: inset 0 1px 0 #fff; }
.available-slots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; }
.available-slots button { display: grid; min-height: 48px; place-items: center; gap: 1px; border: 1px solid rgba(255,255,255,.75); border-radius: 17px; background: rgba(255,255,255,.56); box-shadow: inset 0 1px 0 #fff; color: var(--blue); font-size: 12px; font-weight: 720; cursor: pointer; }
.available-slots button small { font-size: 8px; font-weight: 650; }
.available-slots button.is-busy:disabled { border-color: rgba(176,112,121,.16); background: rgba(178,126,133,.11); box-shadow: inset 0 1px 0 rgba(255,255,255,.72); color: #9a7379; cursor: default; opacity: 1; }

.install-settings {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}
.install-settings .install-icon { width: 44px; height: 44px; }
.install-settings .text-button:disabled { color: var(--muted); background: rgba(112,124,130,.1); cursor: default; }

.picker-layer { z-index: 70; }
.picker-sheet { max-height: min(72dvh, 650px); padding-bottom: 18px; }
.picker-sheet .sheet-header { align-items: flex-start; padding: 0 2px 8px; }
.picker-sheet .sheet-header small { display: block; margin-bottom: 3px; color: var(--muted); font-size: 10px; }
.picker-content { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 4px 0; }
.picker-option {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 54px;
  place-items: center;
  gap: 1px;
  padding: 7px 4px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 19px;
  background:
    radial-gradient(80px circle at var(--glass-x, 18%) var(--glass-y, 0%), rgba(255,255,255,.9), transparent 72%),
    rgba(255,255,255,.36);
  box-shadow: 0 8px 18px rgba(41,67,78,.09), inset 0 2px 1px rgba(255,255,255,.94), inset 0 -1px 1px rgba(73,94,103,.1);
  color: var(--text);
  cursor: pointer;
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
}
.picker-date small { color: var(--muted); font-size: 9px; font-weight: 650; text-transform: uppercase; }
.picker-date strong { font-size: 17px; }
.picker-date span { color: var(--blue); font-size: 9px; font-weight: 700; }
.picker-time { min-height: 46px; color: var(--blue); font-size: 13px; font-weight: 750; }

.toast { position: fixed; z-index: 80; right: 16px; bottom: calc(env(safe-area-inset-bottom) + 90px); left: 16px; width: min(calc(100% - 32px), 448px); margin: 0 auto; padding: 13px 15px; border: 1px solid rgba(255,255,255,.28); border-radius: 22px; background: rgba(22,32,38,.84); box-shadow: 0 16px 32px rgba(20,35,42,.2), inset 0 1px 0 rgba(255,255,255,.18); backdrop-filter: blur(22px) saturate(140%); -webkit-backdrop-filter: blur(22px) saturate(140%); color: #fff; font-size: 13px; text-align: center; opacity: 0; transform: translateY(10px) scale(.98); transition: 180ms ease; pointer-events: none; }
.toast.is-visible { opacity: 1; transform: translateY(0) scale(1); }

@media (min-width: 700px) {
  .app-shell { box-shadow: 0 0 0 1px rgba(255,255,255,.42), 0 24px 70px rgba(26,48,58,.18); }
}

@media (prefers-reduced-transparency: reduce) {
  .app-header, .install-strip, .schedule-overview, .segmented, .tabbar, .icon-button, .sheet, .conversation-row { background: #f3f6f7; backdrop-filter: none; -webkit-backdrop-filter: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
