/* Git Pills Docs — Base Styles */

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg: #0a0a0c;
  --bg-card: #111116;
  --bg-elevated: #1a1a24;
  --border: #2a2a38;
  --accent: #8b5cf6;
  --accent-light: #a78bfa;
  --accent-glow: rgba(139, 92, 246, 0.12);
  --text: #e8e8f0;
  --text-muted: #8888aa;
  --text-subtle: #555570;
  --green: #22c55e;
  --green-glow: rgba(34, 197, 94, 0.12);
  --blue: #3b82f6;
  --yellow: #eab308;
  --pink: #ec4899;
  --radius: 10px;
  --radius-lg: 14px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ==================== SCROLLBAR ==================== */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* ==================== TYPOGRAPHY ==================== */
h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); font-weight: 800; line-height: 1.15; }
h2 { font-size: 1.5rem; font-weight: 700; line-height: 1.3; }
h3 { font-size: 1.1rem; font-weight: 600; line-height: 1.4; }
h4 { font-size: 0.95rem; font-weight: 600; }

h1, h2, h3, h4 { color: var(--text); }

p { color: var(--text-muted); margin-bottom: 0.85rem; }
p:last-child { margin-bottom: 0; }

a { color: var(--accent-light); text-decoration: none; transition: color 0.2s; }
a:hover { color: white; text-decoration: underline; }

strong { color: var(--text); font-weight: 600; }
em { color: var(--accent-light); font-style: normal; }

ul, ol { padding-left: 1.5rem; color: var(--text-muted); }
li { margin-bottom: 0.4rem; }

hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2rem 0;
}

/* ==================== CODE ==================== */
code {
  font-family: 'Fira Code', 'JetBrains Mono', Consolas, 'Courier New', monospace;
  font-size: 0.875em;
}

:not(pre) > code {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--accent-light);
  padding: 0.15em 0.45em;
  border-radius: 4px;
}

pre {
  background: #0d0d14;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  overflow-x: auto;
  margin: 1rem 0;
  font-size: 0.875rem;
  line-height: 1.75;
}

pre code {
  color: var(--text);
  background: none;
  border: none;
  padding: 0;
  font-size: inherit;
}

/* ==================== LAYOUT ==================== */
.container {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 2rem;
}

.container-sm {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* ==================== HEADER ==================== */
.docs-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 10, 12, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  height: 64px;
}

.docs-header-inner {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 2rem;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.docs-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
}

.docs-logo:hover { text-decoration: none; color: var(--text); }

.docs-logo .logo-emoji { font-size: 1.3rem; }

.docs-logo .logo-name {
  background: linear-gradient(135deg, var(--accent), var(--accent-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.docs-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.docs-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  transition: all 0.2s;
}

.docs-nav a:hover {
  color: var(--text);
  background: var(--bg-elevated);
  text-decoration: none;
}

.docs-nav a.active {
  color: var(--accent-light);
  background: var(--accent-glow);
}

/* ==================== HERO ==================== */
.docs-hero {
  padding: 4rem 2rem 3rem;
  text-align: center;
}

.docs-hero .badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--accent-glow);
  border: 1px solid rgba(139, 92, 246, 0.4);
  color: var(--accent-light);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.3rem 0.9rem;
  border-radius: 999px;
  margin-bottom: 1.5rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.docs-hero h1 {
  margin-bottom: 1rem;
}

.docs-hero h1 .gradient {
  background: linear-gradient(135deg, var(--accent), var(--accent-light), #c084fc);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.docs-hero p {
  font-size: 1.05rem;
  max-width: 560px;
  margin: 0 auto 2rem;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ==================== BUTTONS ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.3rem;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: white;
}

.btn-primary:hover {
  background: var(--accent-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(139, 92, 246, 0.35);
  text-decoration: none;
  color: white;
}

.btn-secondary {
  background: var(--bg-elevated);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent-light);
  transform: translateY(-1px);
  text-decoration: none;
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid transparent;
}

.btn-ghost:hover {
  background: var(--bg-elevated);
  color: var(--text);
  border-color: var(--border);
  text-decoration: none;
}

/* ==================== CARDS ==================== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: all 0.2s;
}

.card:hover {
  border-color: rgba(139, 92, 246, 0.4);
  background: var(--bg-elevated);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.card-sm {
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
}

.card-icon {
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
  display: block;
}

.card h3 {
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
}

.card p {
  font-size: 0.85rem;
  margin: 0;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

/* ==================== BADGES ==================== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  line-height: 1;
  white-space: nowrap;
}

.badge-success {
  background: var(--green-glow);
  border: 1px solid rgba(34, 197, 94, 0.35);
  color: var(--green);
}

.badge-accent {
  background: var(--accent-glow);
  border: 1px solid rgba(139, 92, 246, 0.35);
  color: var(--accent-light);
}

.badge-muted {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text-muted);
}

/* ==================== SECTION ==================== */
.docs-section {
  margin-bottom: 3.5rem;
  scroll-margin-top: 80px;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border);
}

.section-icon {
  width: 34px;
  height: 34px;
  background: var(--accent-glow);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  flex-shrink: 0;
}

/* ==================== INFO / TIP BOXES ==================== */
.info-box,
.tip-box,
.warn-box {
  border-radius: var(--radius);
  padding: 0.9rem 1.1rem;
  margin: 1rem 0;
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
}

.info-box {
  background: rgba(59, 130, 246, 0.07);
  border: 1px solid rgba(59, 130, 246, 0.25);
}

.tip-box {
  background: rgba(34, 197, 94, 0.07);
  border: 1px solid rgba(34, 197, 94, 0.25);
}

.warn-box {
  background: rgba(234, 179, 8, 0.07);
  border: 1px solid rgba(234, 179, 8, 0.25);
}

.info-box p, .tip-box p, .warn-box p {
  font-size: 0.875rem;
  color: var(--text);
  margin: 0;
}

.box-icon { font-size: 1rem; flex-shrink: 0; margin-top: 0.1rem; }

/* ==================== STEPS ==================== */
.steps { display: flex; flex-direction: column; gap: 0.75rem; }

.step {
  display: flex;
  gap: 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  align-items: flex-start;
  transition: border-color 0.2s;
}

.step:hover { border-color: rgba(139, 92, 246, 0.3); }

.step-num {
  width: 28px;
  height: 28px;
  background: var(--accent);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  flex-shrink: 0;
}

.step-body h4 { font-size: 0.9rem; margin-bottom: 0.25rem; }
.step-body p { font-size: 0.85rem; margin: 0; }

/* ==================== TABLE ==================== */
.docs-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin: 1rem 0;
}

.docs-table th {
  text-align: left;
  padding: 0.7rem 1rem;
  background: var(--bg-elevated);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid var(--border);
}

.docs-table td {
  padding: 0.7rem 1rem;
  color: var(--text);
  border-bottom: 1px solid rgba(42, 42, 56, 0.5);
}

.docs-table tr:last-child td { border-bottom: none; }
.docs-table tr:hover td { background: var(--bg-elevated); }

/* ==================== TASK LIST ==================== */
.task-list { display: flex; flex-direction: column; gap: 0.75rem; }

.task-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  transition: all 0.2s;
  text-decoration: none;
  color: inherit;
}

.task-item:hover {
  border-color: rgba(139, 92, 246, 0.4);
  background: var(--bg-elevated);
  transform: translateX(4px);
  text-decoration: none;
}

.task-status { font-size: 1.1rem; flex-shrink: 0; }

.task-info { flex: 1; }
.task-title { font-size: 0.95rem; font-weight: 600; color: var(--text); margin-bottom: 0.2rem; }
.task-meta { font-size: 0.8rem; color: var(--text-muted); }

.task-arrow { color: var(--text-subtle); font-size: 1.1rem; }

/* ==================== GUIDES LIST ==================== */
.guides-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; }

.guide-card {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  transition: all 0.2s;
  text-decoration: none;
  color: inherit;
}

.guide-card:hover {
  border-color: var(--accent);
  background: var(--bg-elevated);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
  text-decoration: none;
}

.guide-icon {
  width: 42px;
  height: 42px;
  background: var(--accent-glow);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.guide-body .guide-title { font-size: 0.95rem; font-weight: 700; color: var(--text); margin-bottom: 0.3rem; }
.guide-body p { font-size: 0.82rem; margin: 0; }

/* ==================== STATS ==================== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  text-align: center;
}

.stat-value { font-size: 2rem; font-weight: 800; color: var(--accent-light); display: block; }
.stat-label { font-size: 0.8rem; color: var(--text-muted); margin-top: 0.25rem; }

/* ==================== FOOTER ==================== */
.docs-footer {
  border-top: 1px solid var(--border);
  padding: 2rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.docs-footer a { color: var(--accent-light); }
.docs-footer a:hover { text-decoration: underline; }

/* ==================== RESPONSIVE ==================== */
@media (max-width: 768px) {
  .container, .container-sm { padding: 0 1rem; }
  .docs-hero { padding: 2.5rem 1rem 2rem; }
  .docs-nav { display: none; }
  .cards-grid { grid-template-columns: 1fr; }
  .guides-list { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 480px) {
  h1 { font-size: 1.75rem; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  pre { font-size: 0.8rem; padding: 1rem; }
}
