/* ================================================================
   VisitCircle — sage & cream. Calm, warm, unclinical.
   This appears on the screen of someone having a hard week.
   Design at 380px, cap content ~560px. No dashboards, no metrics.
   ================================================================ */

:root {
  --cream:        #F7F5EF;
  --cream-deep:   #EFEBE0;
  --sage:         #8CA88C;
  --sage-deep:    #3D5344;
  --ink:          #2F3730;
  --ink-soft:     #6B7A6D;
  --clay:         #C4785F;

  --status-welcome: #7FA37F;
  --status-family:  #C9A961;
  --status-resting: #A88C8C;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 3px rgba(47, 55, 48, 0.07), 0 4px 14px rgba(47, 55, 48, 0.05);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: 'Manrope', -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.55;
}

/* ---- shell: phone-shaped everywhere ---- */
.vc-shell {
  max-width: 560px;
  margin: 0 auto;
  padding: 20px 16px 88px;   /* room for the bottom nav */
  min-height: 100vh;
}

h1, h2, h3 { color: var(--sage-deep); letter-spacing: -0.02em; margin: 0 0 4px; }
h1 { font-size: 28px; font-weight: 700; }
h2 { font-size: 22px; font-weight: 700; }
h3 { font-size: 18px; font-weight: 700; }

p { margin: 0 0 12px; }

.vc-meta { font-size: 13px; font-weight: 500; color: var(--ink-soft); }
.vc-quiet { color: var(--ink-soft); }

a { color: var(--sage-deep); }

/* ---- cards ---- */
.vc-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  margin-bottom: 14px;
}
.vc-card--flat { background: var(--cream-deep); box-shadow: none; }

/* ---- buttons: they say what happens ---- */
.vc-btn {
  display: inline-block;
  font-family: inherit;
  font-size: 16px;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-sm);
  padding: 12px 20px;
  cursor: pointer;
  background: var(--sage);
  color: #fff;
  text-decoration: none;
  text-align: center;
  transition: background 0.15s;
}
.vc-btn:hover { background: #7d987d; }
.vc-btn--quiet {
  background: var(--cream-deep);
  color: var(--sage-deep);
}
.vc-btn--quiet:hover { background: #e6e1d3; }
.vc-btn--ghost {
  background: transparent;
  color: var(--ink-soft);
  padding: 12px 10px;
}
.vc-btn--ghost:hover { background: var(--cream-deep); }
/* destructive confirmation ONLY */
.vc-btn--clay { background: var(--clay); }
.vc-btn--clay:hover { background: #b56b53; }
.vc-btn--block { display: block; width: 100%; }
.vc-btn:disabled { opacity: 0.45; cursor: default; }

/* ---- the two equal cards on home ---- */
.vc-ask-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}
.vc-ask-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px 16px;
  text-align: center;
  text-decoration: none;
  color: var(--sage-deep);
  font-weight: 600;
  font-size: 16px;
  transition: transform 0.1s;
}
.vc-ask-card:hover { transform: translateY(-1px); }
.vc-ask-card span { display: block; font-size: 26px; margin-bottom: 6px; }

/* ================================================================
   The status control — the signature element. A soft horizontal
   control; the selected state expands to show its own words and,
   when a duration is set, a quiet line underneath.
   ================================================================ */
.vc-status {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 8px;
  margin-bottom: 14px;
}
.vc-status-row { display: flex; gap: 6px; }
.vc-status-opt {
  flex: 1;
  border: none;
  background: transparent;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-soft);
  padding: 12px 6px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition: background 0.15s, flex-grow 0.2s;
}
.vc-status-opt:hover { background: var(--cream); }
.vc-status-opt.selected {
  background: var(--cream-deep);
  color: var(--sage-deep);
  flex-grow: 1.6;
  font-size: 15px;
}
.vc-status-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  flex-shrink: 0;
}
.vc-status-dot--welcome { background: var(--status-welcome); }
.vc-status-dot--family  { background: var(--status-family); }
.vc-status-dot--resting { background: var(--status-resting); }
.vc-status-until {
  text-align: center;
  padding: 8px 6px 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-soft);
}
.vc-status-expand { padding: 12px 10px 8px; border-top: 1px solid var(--cream-deep); margin-top: 8px; }

/* ---- chips ---- */
.vc-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.vc-chip {
  border: 1.5px solid var(--cream-deep);
  background: #fff;
  color: var(--ink);
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.12s;
}
.vc-chip:hover { border-color: var(--sage); }
.vc-chip.selected {
  background: var(--sage);
  border-color: var(--sage);
  color: #fff;
}

/* ---- list rows ---- */
.vc-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--cream-deep);
}
.vc-row:last-child { border-bottom: none; }
.vc-row-main { flex: 1; min-width: 0; }
.vc-row-name { font-weight: 600; }

.vc-avatar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--cream-deep);
  color: var(--sage-deep);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* ---- form bits ---- */
.vc-input, .vc-select, .vc-textarea {
  width: 100%;
  font-family: inherit;
  font-size: 16px;
  color: var(--ink);
  background: #fff;
  border: 1.5px solid var(--cream-deep);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  outline: none;
}
.vc-input:focus, .vc-textarea:focus { border-color: var(--sage); }
.vc-label { display: block; font-size: 13px; font-weight: 600; color: var(--ink-soft); margin: 14px 0 6px; }
.vc-error { color: var(--clay); font-size: 14px; margin: 8px 0; }

/* ---- bottom nav ---- */
.vc-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: #fff;
  border-top: 1px solid var(--cream-deep);
  display: flex;
  justify-content: center;
  gap: 4px;
  padding: 6px 8px calc(6px + env(safe-area-inset-bottom));
}
.vc-nav-inner { display: flex; width: 100%; max-width: 560px; }
.vc-nav a {
  flex: 1;
  text-align: center;
  text-decoration: none;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 600;
  padding: 6px 0 4px;
  border-radius: var(--radius-sm);
}
.vc-nav a span { display: block; font-size: 20px; margin-bottom: 1px; }
.vc-nav a.active { color: var(--sage-deep); background: var(--cream); }

/* ---- calendar-ish day groups ---- */
.vc-day { margin-bottom: 18px; }
.vc-day-head { font-size: 13px; font-weight: 700; color: var(--ink-soft); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 6px; }
.vc-item {
  background: #fff;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  padding: 12px 14px;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.vc-item--pending { background: var(--cream-deep); box-shadow: none; }
.vc-item--need { border-left: 3px solid var(--status-family); }

/* ---- dev phone ---- */
.vc-phone-thread { display: flex; flex-direction: column; gap: 8px; padding: 12px 0; }
.vc-bubble {
  max-width: 82%;
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 15px;
  white-space: pre-wrap;
  overflow-wrap: break-word;
}
.vc-bubble--out { align-self: flex-start; background: #fff; box-shadow: var(--shadow); border-bottom-left-radius: 4px; }
.vc-bubble--in  { align-self: flex-end; background: var(--sage); color: #fff; border-bottom-right-radius: 4px; }
.vc-bubble--held { opacity: 0.6; border: 1.5px dashed var(--sage); }

@media (min-width: 561px) {
  .vc-shell { padding-top: 32px; }
}

/* ---- consent box, legal pages, public footer ---- */
.vc-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 14px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
  cursor: pointer;
}
.vc-check input {
  width: 20px; height: 20px;
  margin: 2px 0 0;
  flex-shrink: 0;
  accent-color: var(--sage);
}

.vc-legal h1 { margin-bottom: 6px; }
.vc-legal h2 { font-size: 18px; margin: 24px 0 6px; }
.vc-legal ul { padding-left: 20px; margin: 0 0 12px; }
.vc-legal li { margin-bottom: 4px; }
.vc-legal dl { margin: 0 0 12px; }
.vc-legal dt { font-weight: 600; color: var(--sage-deep); margin-top: 12px; }
.vc-legal dd { margin: 2px 0 0; }
.vc-legal address { font-style: normal; line-height: 1.6; }

.vc-footer {
  margin-top: 36px;
  padding-top: 14px;
  border-top: 1px solid var(--cream-deep);
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-soft);
}
.vc-footer a { color: var(--ink-soft); }
