/* MiniStream user guides — layered over ../../css/style.css.
   These pages are mostly opened from inside the app, in a phone-width browser tab,
   so everything here is tuned for a narrow screen first. */

.guide-hero {
  padding: 130px 0 56px;
}

.guide-hero h1 {
  font-size: 2.8rem;
}

.guide-crumb {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 14px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.14);
  color: var(--text-primary);
  font-size: 0.85rem;
  font-weight: 600;
}

.guide-crumb .material-icons {
  font-size: 18px;
  color: var(--primary);
}

.guide-hero .guide-where {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.guide-where .material-icons {
  font-size: 18px;
}

.guide-section {
  padding-top: 40px;
}

.guide-content h2:first-child {
  margin-top: 0;
}

.guide-content a {
  color: var(--accent);
}

.guide-content code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--bg-card-solid);
  color: var(--text-primary);
  word-break: break-all;
}

.guide-content strong {
  color: var(--text-primary);
}

/* Numbered steps */
.guide-steps {
  list-style: none;
  counter-reset: step;
  margin: 0 0 22px;
  padding: 0;
}

.guide-steps li {
  counter-increment: step;
  position: relative;
  padding: 4px 0 14px 46px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.guide-steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 2px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--gradient);
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Callouts */
.guide-callout {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin: 8px 0 24px;
  padding: 16px 18px;
  border-radius: 14px;
  background: var(--bg-card);
  border: 1px solid rgba(99, 102, 241, 0.25);
  color: var(--text-secondary);
  line-height: 1.7;
}

.guide-callout .material-icons {
  flex-shrink: 0;
  color: var(--primary);
}

.guide-callout-note {
  border-color: rgba(6, 182, 212, 0.3);
}

.guide-callout-note .material-icons {
  color: var(--accent);
}

.guide-callout-warn {
  border-color: rgba(245, 158, 11, 0.35);
}

.guide-callout-warn .material-icons {
  color: var(--warning);
}

/* Tables scroll inside themselves; the page never scrolls sideways. */
.guide-table {
  overflow-x: auto;
  margin: 8px 0 24px;
  border-radius: 14px;
  border: 1px solid rgba(99, 102, 241, 0.15);
}

.guide-table table {
  width: 100%;
  border-collapse: collapse;
  min-width: 420px;
}

.guide-table th,
.guide-table td {
  padding: 12px 14px;
  text-align: left;
  font-size: 0.95rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.guide-table th {
  background: var(--bg-card-solid);
  color: var(--text-primary);
  font-weight: 700;
}

.guide-table td {
  color: var(--text-secondary);
}

.guide-table tbody tr:last-child td {
  border-bottom: 0;
}

.guide-table td:first-child {
  color: var(--text-primary);
  font-weight: 600;
}

/* The base list style is a flex row; wrap the text in a span so inline markup stays inline. */
.guide-content ul li > span {
  flex: 1;
}

/* Help box + pager */
.guide-help {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 40px 0 24px;
  padding: 18px 20px;
  border-radius: 16px;
  background: var(--bg-card);
  color: var(--text-secondary);
}

.guide-help .material-icons {
  color: var(--primary);
  font-size: 28px;
}

.guide-help-hub {
  max-width: 850px;
  margin-left: auto;
  margin-right: auto;
}

.guide-pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.guide-pager a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--bg-card);
  border: 1px solid rgba(99, 102, 241, 0.12);
  color: var(--text-primary);
  font-weight: 600;
  transition: var(--transition);
}

.guide-pager a:hover {
  border-color: rgba(99, 102, 241, 0.4);
}

.guide-pager small {
  display: block;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.8rem;
}

.guide-pager-next {
  justify-content: flex-end;
  text-align: right;
}

.guide-updated {
  margin-top: 24px;
  font-size: 0.85rem;
  color: var(--text-muted) !important;
}

/* Hub grid */
.guide-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  max-width: 950px;
  margin: 0 auto;
}

.guide-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  border-radius: 18px;
  background: var(--bg-card);
  border: 1px solid rgba(99, 102, 241, 0.12);
  color: var(--text-primary);
  transition: var(--transition);
}

.guide-card:hover {
  border-color: rgba(99, 102, 241, 0.4);
  transform: translateY(-2px);
}

.guide-card-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
}

.guide-card-icon .material-icons {
  color: #fff;
}

.guide-card-text {
  flex: 1;
  min-width: 0;
}

.guide-card-text strong {
  display: block;
  font-size: 1.05rem;
  margin-bottom: 4px;
}

.guide-card-text span {
  display: block;
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.5;
}

.guide-card-arrow {
  color: var(--text-muted);
}

@media (max-width: 768px) {
  .guide-hero {
    padding: 104px 0 36px;
  }

  .guide-hero h1 {
    font-size: 2rem;
  }

  .guide-hero p {
    font-size: 1rem;
  }

  .guide-grid {
    grid-template-columns: 1fr;
  }

  .guide-pager {
    grid-template-columns: 1fr;
  }

  .guide-pager-next {
    justify-content: space-between;
    text-align: left;
  }
}
