.instruction-page {
  padding: 60px 0 90px;
  background: radial-gradient(ellipse at 50% 0%, rgba(59,130,246,0.08), transparent 50%);
}

.instruction-header {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 56px;
}

.instruction-icon-large {
  font-size: 56px;
  margin-bottom: 16px;
}

.instruction-header h1 {
  font-size: 38px;
  font-weight: 800;
  margin: 0 0 14px;
}

.lead {
  font-size: 17px;
  color: var(--text-muted);
  margin: 0;
}

.instruction-content {
  max-width: 760px;
  margin: 0 auto;
}

.step-block {
  background: var(--surface);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius);
  padding: 28px 30px;
  margin-bottom: 20px;
}

.step-block h2 {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 20px;
  font-weight: 700;
  margin: 0 0 18px;
}

.num {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #8b5cf6);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 800;
  flex-shrink: 0;
}

.step-block ol {
  margin: 0;
  padding-left: 22px;
  color: var(--text-muted);
}

.step-block li {
  margin-bottom: 10px;
  line-height: 1.6;
}

.step-block li strong,
.step-block li code { color: var(--text); }

.step-block code {
  background: rgba(255,255,255,0.08);
  padding: 2px 6px;
  border-radius: 5px;
  font-size: 13px;
  word-break: break-all;
}

.tip {
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: 10px;
  background: rgba(34,197,94,0.08);
  border: 1px solid rgba(34,197,94,0.2);
  color: #bbf7d0;
  font-size: 14px;
}

/* --- Кликабельные скриншоты (открытие на весь экран) --- */
.screenshot-frame {
  cursor: zoom-in;
  overflow: hidden;
}

.screenshot-frame img {
  transition: transform 0.25s ease;
}

.screenshot-frame:hover img {
  transform: scale(1.02);
}

.screenshot-frame::after {
  content: "⌖";
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(15, 18, 34, 0.75);
  color: #fff;
  font-size: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}

.screenshot-frame:hover::after {
  opacity: 1;
}

.screenshot-frame:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(5, 7, 18, 0.92);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  cursor: zoom-out;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.lightbox.open {
  opacity: 1;
  visibility: visible;
}

.lightbox img {
  max-width: min(96vw, 1600px);
  max-height: 88vh;
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.6);
  cursor: default;
}

.lightbox-caption {
  margin-top: 14px;
  color: #cbd5e1;
  font-size: 14px;
  text-align: center;
}

.lightbox-hint {
  position: absolute;
  top: 18px;
  right: 22px;
  color: #94a3b8;
  font-size: 13px;
}

.lightbox-close {
  position: absolute;
  top: 14px;
  left: 18px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.18);
}

body.lightbox-open {
  overflow: hidden;
}

.instruction-nav {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  max-width: 760px;
  margin: 40px auto 0;
  flex-wrap: wrap;
}

@media (max-width: 600px) {
  .instruction-header h1 { font-size: 28px; }
  .step-block { padding: 22px; }
  .instruction-nav { flex-direction: column; }
  .instruction-nav .btn { width: 100%; }
}
