/* github.css — Estilos para la Guía de GitHub */

main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 100px 20px 80px;
}

/* ── Cabecera de página ── */
.page-header { text-align: center; margin-bottom: 60px; }

.page-title {
  font-size: 2.8rem;
  font-family: "Outfit", sans-serif;
  font-weight: 700;
  background: linear-gradient(135deg, #34d399, #10b981, #3b82f6);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 12px;
  line-height: 1.2;
}

.page-subtitle {
  color: var(--text-secondary);
  font-size: 1.05rem;
  max-width: 600px;
  margin: 0 auto 30px;
  line-height: 1.6;
}

/* ── Tabs ── */
.section-tabs {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 50px;
  flex-wrap: wrap;
}

.tab-btn {
  padding: 10px 22px;
  border: 1px solid var(--glass-border);
  background: var(--card-bg);
  color: var(--text-secondary);
  border-radius: 50px;
  cursor: pointer;
  font-size: 0.9rem;
  font-family: "Outfit", sans-serif;
  font-weight: 500;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 7px;
}

.tab-btn.active, .tab-btn:hover {
  background: var(--accent-primary);
  color: white;
  border-color: var(--accent-primary);
  box-shadow: 0 4px 15px var(--accent-glow);
}

.tab-content { display: none; }
.tab-content.active { display: block; animation: fadeIn 0.4s ease; }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Título de sección ── */
.section-title {
  font-family: "Outfit", sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 40px 0 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.section-title::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--glass-border);
}

/* ── Cards ── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 18px;
}

.git-card {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: 14px;
  padding: 22px;
  backdrop-filter: blur(10px);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  overflow: hidden;
}

.git-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 3px;
  background: linear-gradient(90deg, #10b981, #3b82f6);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.git-card:hover { transform: translateY(-5px); box-shadow: 0 12px 30px rgba(16, 185, 129, 0.15); }
.git-card:hover::before { opacity: 1; }

.git-card h3 {
  font-family: "Outfit", sans-serif;
  font-size: 1rem;
  color: var(--accent-hover);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.git-card .desc {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-bottom: 12px;
  line-height: 1.6;
}

/* ── Código ── */
.code-snippet {
  background: var(--input-bg);
  border-radius: 8px;
  padding: 13px 16px;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.8rem;
  color: var(--accent-primary);
  overflow-x: auto;
  border-left: 3px solid #10b981;
  line-height: 1.8;
}

.code-snippet .cmd    { color: #34d399; font-weight: 500; }
.code-snippet .flag   { color: #60a5fa; }
.code-snippet .arg    { color: #fbbf24; }
.code-snippet .comment{ color: #4b5563; font-style: italic; }
.code-snippet .out    { color: #9ca3af; }

/* ── Flujo de trabajo visual ── */
.workflow-wrap { margin: 20px 0 40px; }

.workflow-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  align-items: stretch;
  justify-content: center;
}

.wf-step {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  padding: 20px 18px;
  text-align: center;
  flex: 1;
  min-width: 130px;
  max-width: 180px;
  transition: transform 0.3s ease;
}

.wf-step:hover { transform: translateY(-5px); }
.wf-step .wf-icon { font-size: 2rem; margin-bottom: 10px; display: block; }
.wf-step h4 { font-family: "Outfit", sans-serif; font-size: 0.9rem; font-weight: 600; color: var(--text-primary); margin-bottom: 5px; }
.wf-step p  { font-size: 0.75rem; color: var(--text-secondary); line-height: 1.4; }

.wf-arrow {
  display: flex;
  align-items: center;
  padding: 0 4px;
  color: #10b981;
  font-size: 1.4rem;
  align-self: center;
}

@media (max-width: 640px) {
  .wf-arrow { transform: rotate(90deg); }
  .workflow-steps { flex-direction: column; align-items: center; }
  .wf-step { max-width: 90%; width: 100%; }
}

/* ── Diagrama de ramas ── */
.branch-diagram {
  background: rgba(0, 0, 0, 0.35);
  border-radius: 14px;
  border: 1px solid var(--glass-border);
  padding: 28px 24px;
  overflow-x: auto;
  margin-bottom: 30px;
}

.branch-line {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 8px 0;
  font-family: "JetBrains Mono", monospace;
  font-size: 0.85rem;
}

.commit-dot { width: 14px; height: 14px; border-radius: 50%; flex-shrink: 0; }
.commit-dot.main-dot  { background: #10b981; box-shadow: 0 0 8px #10b981; }
.commit-dot.feat-dot  { background: #3b82f6; box-shadow: 0 0 8px #3b82f6; }
.commit-dot.merge-dot { background: #a78bfa; box-shadow: 0 0 8px #a78bfa; }

.branch-connector { width: 30px; height: 2px; background: var(--glass-border); flex-shrink: 0; }

.branch-label { padding: 3px 10px; border-radius: 20px; font-size: 0.78rem; font-weight: 600; }
.label-main  { background: rgba(16,185,129,0.15); color: #10b981; }
.label-feat  { background: rgba(59,130,246,0.15);  color: #3b82f6; }
.label-merge { background: rgba(167,139,250,0.15); color: #a78bfa; }

.branch-msg { color: var(--text-secondary); font-size: 0.8rem; }
.indent     { margin-left: 40px; }

/* ── Tabla de comandos ── */
.cmd-table-wrap {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: 14px;
  overflow: hidden;
  overflow-x: auto;
  margin-bottom: 24px;
}

.cmd-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; margin-top: 10px; }

.cmd-table th {
  font-family: "Outfit", sans-serif;
  font-weight: 600;
  color: var(--accent-hover);
  text-align: left;
  padding: 10px 14px;
  border-bottom: 1px solid var(--glass-border);
  background: rgba(16,185,129,0.05);
}

.cmd-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--glass-border);
  vertical-align: top;
  color: var(--text-secondary);
}

.cmd-table td:first-child { font-family: "JetBrains Mono", monospace; color: #34d399; white-space: nowrap; }
.cmd-table tr:hover td { background: rgba(16,185,129,0.04); }

/* ── Tips ── */
.tip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 10px;
}

.tip-card {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  padding: 18px 20px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  transition: transform 0.3s ease;
}

.tip-card:hover { transform: translateY(-3px); }
.tip-icon { font-size: 1.6rem; flex-shrink: 0; margin-top: 2px; }
.tip-card h4 { font-family: "Outfit", sans-serif; font-size: 0.95rem; font-weight: 600; color: var(--text-primary); margin-bottom: 5px; }
.tip-card p  { font-size: 0.82rem; color: var(--text-secondary); line-height: 1.5; }

.badge {
  display: inline-block;
  font-size: 0.72rem;
  font-family: "JetBrains Mono", monospace;
  padding: 2px 8px;
  border-radius: 4px;
  margin: 2px 3px 2px 0;
  background: rgba(16,185,129,0.12);
  color: #10b981;
  border: 1px solid rgba(16,185,129,0.3);
}

.badge.blue   { background: rgba(59,130,246,0.12);  color: #60a5fa;  border-color: rgba(59,130,246,0.3); }
.badge.purple { background: rgba(167,139,250,0.12); color: #a78bfa;  border-color: rgba(167,139,250,0.3); }

/* ── Commit Convention ── */
.commit-table-wrap {
  background: var(--card-bg);
  border: 1px solid var(--glass-border);
  border-radius: 14px;
  overflow: hidden;
  overflow-x: auto;
}

.commit-row {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--glass-border);
  transition: background 0.2s ease;
}

.commit-row:last-child { border-bottom: none; }
.commit-row:hover { background: rgba(16,185,129,0.04); }

.commit-type {
  font-family: "JetBrains Mono", monospace;
  font-size: 0.82rem;
  padding: 3px 10px;
  border-radius: 6px;
  flex-shrink: 0;
  min-width: 100px;
  text-align: center;
  font-weight: 500;
}

.t-feat  { background: rgba(59,130,246,0.15);  color: #3b82f6; }
.t-fix   { background: rgba(239,68,68,0.15);   color: #f87171; }
.t-docs  { background: rgba(251,191,36,0.15);  color: #fbbf24; }
.t-style { background: rgba(167,139,250,0.15); color: #a78bfa; }
.t-ref   { background: rgba(16,185,129,0.15);  color: #10b981; }
.t-test  { background: rgba(52,211,153,0.15);  color: #34d399; }
.t-chore { background: rgba(100,116,139,0.15); color: #94a3b8; }

.commit-desc h4 { font-family: "Outfit", sans-serif; font-size: 0.9rem; font-weight: 600; color: var(--text-primary); margin-bottom: 3px; }
.commit-desc p  { font-size: 0.8rem; color: var(--text-secondary); line-height: 1.4; }
