/* Help. Its own sheet, like every other feature.

   Reading measure is capped at 68 characters. A help article that runs the full
   width of a 27 inch monitor is a help article people skim and misread. */

.help-hero { max-width: 780px; margin: 0 auto 26px; text-align: center; padding: 18px 0 0; }
.help-hero h2 { font-size: 26px; margin-bottom: 8px; }
.help-hero p { color: var(--muted); margin-bottom: 18px; line-height: 1.6; }
.help-hero p svg { width: 15px; height: 15px; vertical-align: -3px; color: var(--blue); }

.help-search { position: relative; display: flex; align-items: center; gap: 10px;
  background: var(--card); border: 1px solid var(--border); border-radius: 12px;
  padding: 0 16px; box-shadow: var(--shadow); }
.help-search:focus-within { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37, 99, 235, .12); }
.help-search svg { color: var(--muted); }
.help-search input { flex: 1; border: 0; outline: 0; background: transparent; padding: 14px 0; font-size: 15px; }

.help-group { max-width: 980px; margin: 0 auto 30px; }
.help-group-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 12px;
  padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.help-group-head h3 { font-size: 15px; }
.help-group-head span { color: var(--muted); font-size: 13px; }

.help-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.help-card { display: block; background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 14px 16px; color: var(--text);
  transition: border-color .12s, transform .12s, box-shadow .12s; }
.help-card:hover { border-color: var(--blue); transform: translateY(-1px);
  box-shadow: var(--shadow); text-decoration: none; }
.help-card b { display: block; margin-bottom: 5px; font-size: 14.5px; }
.help-card span { color: var(--muted); font-size: 13px; line-height: 1.5; display: block; }

/* ---- An article ---- */
.help-art { max-width: 760px; margin: 0 auto; padding-bottom: 40px; }
.help-back { display: inline-flex; align-items: center; gap: 5px; color: var(--muted);
  font-size: 13px; margin-bottom: 14px; }
.help-back svg { width: 14px; height: 14px; }
.help-crumb { display: block; color: var(--blue); font-size: 12px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .5px; margin-bottom: 5px; }
.help-art-head { margin-bottom: 20px; }
.help-art-head h2 { font-size: 25px; line-height: 1.25; }

.help-body { font-size: 14.5px; line-height: 1.7; }
.help-body p { margin: 0 0 15px; }
.help-lead { font-size: 16.5px; line-height: 1.6; color: var(--muted); margin-bottom: 20px !important; }
.help-h { font-size: 16px; margin: 28px 0 12px; padding-top: 4px; }
.help-body .btn { margin-top: 4px; }
.help-body .btn svg { width: 14px; height: 14px; }

/* Steps. The number is the anchor a diagram's marker points at, so it is drawn
   the same way: a filled blue disc with the number in it. */
.help-steps { list-style: none; counter-reset: hstep; margin: 0 0 18px; padding: 0; }
.help-steps li { counter-increment: hstep; position: relative; padding: 0 0 16px 40px; }
.help-steps li::before { content: counter(hstep); position: absolute; left: 0; top: 1px;
  width: 24px; height: 24px; border-radius: 50%; background: var(--blue); color: #fff;
  font-size: 12.5px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
/* The line joining one step to the next, so a list reads as a sequence. */
.help-steps li:not(:last-child)::after { content: ''; position: absolute; left: 11.5px; top: 29px;
  bottom: 4px; width: 1px; background: var(--border); }
.hs-do { font-weight: 600; }
.hs-note { color: var(--muted); font-size: 13.5px; margin-top: 3px; }

/* Callouts. Three tones and no more: something worth knowing, something that
   bites, and something only an admin can do. */
.help-cal { display: flex; gap: 11px; align-items: flex-start; border-radius: var(--radius);
  padding: 13px 15px; margin: 0 0 18px; font-size: 13.5px; line-height: 1.6; }
.help-cal svg { width: 17px; height: 17px; margin-top: 1px; }
.help-cal.note { background: #eff6ff; border: 1px solid #bfdbfe; color: #1e3a8a; }
.help-cal.note svg { color: var(--blue); }
.help-cal.warn { background: #fffbeb; border: 1px solid #fde68a; color: #78350f; }
.help-cal.warn svg { color: var(--amber); }
.help-cal.admin { background: #f8fafc; border: 1px solid var(--border); color: var(--muted); }
.help-cal.admin svg { color: var(--muted); }

/* A live yes or no about this account. */
.help-live { display: flex; align-items: center; gap: 10px; padding: 10px 14px;
  border-radius: var(--radius); margin-bottom: 10px; font-size: 13.5px; border: 1px solid; }
.help-live svg { width: 16px; height: 16px; }
.help-live.on { background: #ecfdf5; border-color: #a7f3d0; color: #065f46; }
.help-live.off { background: #fef2f2; border-color: #fecaca; color: #991b1b; }

/* Tables of what a button does. They are wide, so they scroll inside
   themselves rather than pushing the page sideways. */
.help-tablewrap { overflow-x: auto; margin: 0 0 20px; border: 1px solid var(--border);
  border-radius: var(--radius); }
.help-table { border-collapse: collapse; width: 100%; font-size: 13.5px; }
.help-table th { text-align: left; background: var(--bg); padding: 9px 14px;
  font-size: 12px; text-transform: uppercase; letter-spacing: .4px; color: var(--muted);
  border-bottom: 1px solid var(--border); white-space: nowrap; }
.help-table td { padding: 10px 14px; border-bottom: 1px solid var(--line, #f1f5f9);
  vertical-align: top; line-height: 1.55; }
.help-table tr:last-child td { border-bottom: 0; }
.help-table td.hk { font-weight: 600; white-space: nowrap; }

/* Figures. The drawing scales with the column and never sets its own width. */
.help-fig { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px; margin: 0 0 20px; }
.help-fig svg { width: 100%; height: auto; display: block; }

.help-see { border-top: 1px solid var(--border); margin-top: 28px; padding-top: 16px; }
.help-see h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .5px;
  color: var(--muted); margin-bottom: 8px; }
.help-see a { display: flex; align-items: center; gap: 6px; padding: 5px 0; font-size: 14px; }
.help-see a svg { width: 14px; height: 14px; }

.help-nav { display: flex; justify-content: space-between; gap: 14px; margin-top: 30px; }
.help-nav a { display: flex; align-items: center; gap: 10px; flex: 1; padding: 12px 15px;
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--card);
  color: var(--text); font-weight: 600; font-size: 14px; }
.help-nav a:hover { border-color: var(--blue); text-decoration: none; }
.help-nav a.r { justify-content: flex-end; text-align: right; }
.help-nav a small { display: block; font-weight: 400; font-size: 11.5px;
  color: var(--muted); text-transform: uppercase; letter-spacing: .4px; }
.help-nav a svg { width: 16px; height: 16px; color: var(--muted); }

.help-foot { margin-top: 26px; padding-top: 14px; border-top: 1px solid var(--border);
  color: var(--muted); font-size: 13px; }

/* The ? beside the page title. Quiet until you look for it. */
.help-btn { display: inline-flex; align-items: center; justify-content: center;
  width: 26px; height: 26px; border-radius: 50%; color: var(--muted);
  border: 1px solid transparent; flex: none; }
.help-btn svg { width: 17px; height: 17px; }
.help-btn:hover { color: var(--blue); background: #eff6ff; border-color: #bfdbfe; text-decoration: none; }

@media (max-width: 640px) {
  .help-cards { grid-template-columns: 1fr; }
  .help-nav { flex-direction: column; }
  .help-art-head h2 { font-size: 21px; }
}

/* A route that does not exist. Lives here rather than in styles.css because
   the only thing that shows it is the fallback that points at the help. */
.unknown-route { padding: 14px 16px; margin-bottom: 16px; border-left: 3px solid var(--amber);
  background: #fffbeb; border-color: #fde68a; color: #78350f; font-size: 13.5px; line-height: 1.6; }
.unknown-route b { display: inline; }
