/* Resources > Documentation (2026-10-27): topic tree on the left, the
   selected topic step by step on the right. Colours from css/style.css. */

.docs-app {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  min-height: calc(100vh - 64px);
}

/* ── Left: tree ── */
.docs-side {
  position: sticky;
  top: 64px;
  height: calc(100vh - 64px);
  overflow-y: auto;
  background: var(--navy-deep);
  border-right: 1px solid var(--border);
  padding: 22px 16px 28px;
}
.docs-side-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 14px;
}
.docs-side-title i { color: var(--cyan); margin-right: 6px; }
.docs-filter {
  width: 100%;
  padding: 9px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--navy-mid);
  color: var(--white);
  font: inherit;
  font-size: 14px;
  margin-bottom: 18px;
}
.docs-filter:focus { outline: none; border-color: var(--cyan); }
.docs-tree-group { margin-bottom: 18px; }
.docs-tree-section {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--steel);
  margin: 0 0 6px 6px;
}
.docs-tree-section i { color: var(--cyan); width: 16px; }
.docs-tree-list { list-style: none; }
.docs-tree-link {
  display: block;
  padding: 7px 10px 7px 28px;
  border-radius: 7px;
  color: var(--white);
  opacity: 0.82;
  font-size: 14px;
  text-decoration: none;
  border-left: 2px solid transparent;
}
.docs-tree-link:hover { background: var(--cyan-dim); opacity: 1; }
.docs-tree-link.active {
  background: var(--cyan-dim);
  border-left-color: var(--cyan);
  color: var(--cyan);
  opacity: 1;
  font-weight: 600;
}
.docs-tree-empty { color: var(--steel); font-size: 14px; padding: 6px; }
.docs-signin-note {
  display: flex;
  gap: 10px;
  margin-top: 8px;
  padding: 12px;
  border-radius: 8px;
  background: var(--amber-dim);
  color: var(--white);
  font-size: 13px;
  line-height: 1.5;
}
.docs-signin-note i { color: var(--amber); margin-top: 3px; }
.docs-signin-note a { color: var(--amber); font-weight: 600; }

/* ── Right: topic ── */
.docs-main { padding: 32px clamp(16px, 4vw, 56px) 56px; min-width: 0; }
.docs-content { max-width: 980px; }
.docs-topics-btn { display: none; }
.docs-loading { color: var(--steel); }

.docs-crumb {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 6px;
}
.docs-title { font-family: var(--font-display); font-size: clamp(24px, 3vw, 32px); line-height: 1.2; }
.docs-summary { color: var(--steel); font-size: 16px; margin-top: 10px; max-width: 760px; }
.docs-meta { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 14px; font-size: 13px; }
.docs-who { color: var(--white); opacity: 0.85; }
.docs-who i, .docs-open-page i { color: var(--cyan); }
.docs-open-page { color: var(--cyan); text-decoration: none; font-weight: 600; }
.docs-open-page:hover { text-decoration: underline; }

.docs-dots { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 26px 0 22px; }
.docs-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--border-hover);
  background: transparent;
  color: var(--steel);
  font: 600 13px var(--font-mono);
  cursor: pointer;
}
.docs-dot:hover { border-color: var(--cyan); color: var(--white); }
.docs-dot.done { border-color: rgba(0, 212, 255, 0.45); color: var(--cyan); }
.docs-dot.active { background: var(--cyan); border-color: var(--cyan); color: var(--navy-deep); }

.docs-step {
  background: var(--navy-mid);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px clamp(16px, 3vw, 30px);
}
.docs-step-title { font-family: var(--font-display); font-size: 20px; margin-bottom: 10px; }
.docs-step-text { margin-bottom: 10px; max-width: 760px; }
.docs-step-bullets { margin: 4px 0 12px 20px; max-width: 760px; }
.docs-step-bullets li { margin-bottom: 4px; }
.docs-tip {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin: 12px 0;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--amber-dim);
  font-size: 14px;
  max-width: 760px;
}
.docs-tip i { color: var(--amber); margin-top: 3px; }

/* Screenshot + numbered highlight boxes (positions are % of the image). */
.docs-shot { margin: 18px 0 0; }
.docs-shot-frame {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border-hover);
  background: var(--navy-deep);
}
.docs-shot-img { display: block; width: 100%; height: auto; }
.docs-mark {
  position: absolute;
  border: 3px solid var(--amber);
  border-radius: 8px;
  box-shadow: 0 0 0 4px rgba(255, 179, 64, 0.25), 0 0 18px rgba(255, 179, 64, 0.35);
  pointer-events: none;
}
.docs-mark-badge {
  position: absolute;
  top: -13px;
  left: -13px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--amber);
  color: var(--navy-deep);
  font: 700 13px/26px var(--font-mono);
  text-align: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.45);
}
.docs-mark-badge.static { position: static; display: inline-block; flex: none; }
.docs-shot-legend { display: grid; gap: 8px; margin-top: 12px; font-size: 14px; }
.docs-legend-row { display: flex; align-items: center; gap: 10px; }

/* Last page of a topic: what you can / can't do. */
.docs-rules { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; margin-top: 6px; }
.docs-rules-box { border-radius: 10px; padding: 16px 18px; border: 1px solid var(--border); }
.docs-rules-box h4 { font-family: var(--font-display); font-size: 15px; margin-bottom: 8px; }
.docs-rules-box ul { margin-left: 18px; }
.docs-rules-box li { margin-bottom: 6px; font-size: 14px; }
.docs-rules-yes { background: rgba(74, 222, 128, 0.07); border-color: rgba(74, 222, 128, 0.3); }
.docs-rules-yes h4 i { color: var(--green); }
.docs-rules-no { background: rgba(248, 113, 113, 0.07); border-color: rgba(248, 113, 113, 0.3); }
.docs-rules-no h4 i { color: #F87171; }

.docs-pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 22px; }
.docs-count { color: var(--steel); font-size: 13px; font-family: var(--font-mono); white-space: nowrap; }
.docs-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 8px;
  border: 1px solid var(--cyan);
  background: var(--cyan);
  color: var(--navy-deep);
  font: 600 14px var(--font-body);
  text-decoration: none;
  cursor: pointer;
  max-width: 45%;
}
.docs-btn:hover:not(:disabled) { filter: brightness(1.1); }
.docs-btn:disabled { opacity: 0.35; cursor: default; }
.docs-btn-ghost { background: transparent; color: var(--cyan); }

.docs-message {
  text-align: center;
  padding: 60px 20px;
  border: 1px dashed var(--border-hover);
  border-radius: 12px;
}
.docs-message > i { font-size: 34px; color: var(--cyan); margin-bottom: 14px; }
.docs-message h2 { font-family: var(--font-display); font-size: 22px; margin-bottom: 8px; }
.docs-message p { color: var(--steel); margin-bottom: 18px; }

/* ── Narrow screens: the tree slides in from the left ── */
@media (max-width: 900px) {
  .docs-app { grid-template-columns: minmax(0, 1fr); }
  .docs-side {
    position: fixed;
    left: 0;
    top: 64px;
    bottom: 0;
    width: min(320px, 86vw);
    z-index: 900;
    transform: translateX(-100%);
    transition: transform 0.2s ease;
    box-shadow: 8px 0 24px rgba(0, 0, 0, 0.4);
  }
  .docs-side.open { transform: none; }
  .docs-topics-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 8px 14px;
    border-radius: 8px;
    border: 1px solid var(--border-hover);
    background: var(--navy-mid);
    color: var(--white);
    font: 600 14px var(--font-body);
    cursor: pointer;
  }
  .docs-main { padding-top: 22px; }
  .docs-pager { flex-wrap: wrap; }
  .docs-btn { max-width: 100%; }
  .docs-mark-badge { width: 20px; height: 20px; font-size: 11px; line-height: 20px; top: -10px; left: -10px; }
}
