/* K3s Homelab Build Log — Style */

:root {
  --bg-primary: #0f1117;
  --bg-secondary: #161922;
  --bg-tertiary: #1c1f2e;
  --bg-code: #1a1d2e;
  --text-primary: #e4e4e7;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --accent: #38bdf8;
  --accent-dim: rgba(56, 189, 248, 0.1);
  --green: #4ade80;
  --red: #f87171;
  --purple: #a78bfa;
  --yellow: #fbbf24;
  --border: #27272a;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', 'SF Mono', Consolas, monospace;
  --max-width: 1080px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

/* Layout */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
header {
  padding: 80px 0 40px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 60px;
}

header h1 {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
  color: var(--text-primary);
}

header .subtitle {
  font-size: 1.125rem;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: none;
}

header .meta {
  margin-top: 24px;
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  font-size: 0.875rem;
  color: var(--text-muted);
}

header .meta span {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Sections */
section {
  margin-bottom: 80px;
}

h2 {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
  color: var(--text-primary);
}

h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 16px;
  margin-top: 40px;
  color: var(--text-primary);
}

p {
  margin-bottom: 16px;
  color: var(--text-secondary);
}

strong {
  color: var(--text-primary);
  font-weight: 600;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: opacity 0.2s;
}

a:hover {
  opacity: 0.8;
}

/* Code blocks */
pre {
  background: var(--bg-code);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 20px 24px;
  overflow-x: auto;
  margin: 16px 0 24px;
  font-size: 0.875rem;
  line-height: 1.6;
}

pre code {
  font-family: var(--font-mono);
  color: var(--text-primary);
}

code {
  font-family: var(--font-mono);
  background: var(--bg-tertiary);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.875em;
  color: var(--accent);
}

pre code {
  background: none;
  padding: 0;
  color: var(--text-primary);
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 24px;
  font-size: 0.9rem;
}

th {
  text-align: left;
  padding: 12px 16px;
  background: var(--bg-secondary);
  border-bottom: 2px solid var(--border);
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}

tr:last-child td {
  border-bottom: none;
}

/* Screenshots */
figure {
  margin: 24px 0 32px;
}

figure img {
  width: 100%;
  border-radius: 8px;
  border: 1px solid var(--border);
}

figcaption {
  margin-top: 8px;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  font-style: italic;
}

/* Status badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.badge--green {
  background: rgba(74, 222, 128, 0.1);
  color: var(--green);
}

.badge--blue {
  background: var(--accent-dim);
  color: var(--accent);
}

.badge--purple {
  background: rgba(167, 139, 250, 0.1);
  color: var(--purple);
}

/* Decision boxes */
.decision {
  background: var(--bg-secondary);
  border-left: 3px solid var(--accent);
  padding: 16px 20px;
  border-radius: 0 8px 8px 0;
  margin: 16px 0 24px;
}

.decision p {
  margin-bottom: 0;
  color: var(--text-secondary);
}

.decision strong {
  color: var(--accent);
}

/* Live status bar */
.live-bar {
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 20px 24px;
  margin: 32px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.live-bar .pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.live-bar .label {
  font-size: 0.875rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.live-bar .value {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: var(--text-primary);
}

/* Footer */
footer {
  padding: 40px 0;
  border-top: 1px solid var(--border);
  text-align: center;
  margin-top: 80px;
}

footer p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 36px;
  margin-top: 12px;
  font-size: 0.8rem;
}

.footer-links a {
  color: var(--text-muted);
  display: flex;
  align-items: center;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--text-primary);
  opacity: 1;
}

.footer-links svg {
  vertical-align: middle;
}

/* Responsive */
@media (max-width: 640px) {
  header {
    padding: 40px 0 24px;
  }

  header h1 {
    font-size: 1.75rem;
  }

  h2 {
    font-size: 1.375rem;
  }

  .live-bar {
    flex-direction: column;
    align-items: flex-start;
  }

  table {
    font-size: 0.8rem;
  }

  th, td {
    padding: 8px 10px;
  }
}
