@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=JetBrains+Mono:wght@400;500&family=Space+Grotesk:wght@300;400;500;600&display=swap');

:root {
  --background: 228 20% 4%;
  --foreground: 210 40% 98%;
  --text: 210 40% 98%;
  --card: 228 20% 6%;
  --card-foreground: 210 40% 98%;
  --popover: 228 20% 4%;
  --popover-foreground: 210 40% 98%;
  --primary: 192 100% 50%;
  --primary-foreground: 228 20% 4%;
  --secondary: 217 91% 60%;
  --secondary-foreground: 210 40% 98%;
  --muted: 228 20% 12%;
  --muted-foreground: 215 20% 65%;
  --accent: 270 95% 64%;
  --accent-foreground: 210 40% 98%;
  --destructive: 0 84.2% 60.2%;
  --destructive-foreground: 210 40% 98%;
  --border: 228 20% 18%;
  --input: 228 20% 15%;
  --ring: 192 100% 50%;
  --radius: 0.5rem;
  --success: 142 76% 36%;
  --warning: 38 92% 50%;
  --error: 0 84% 60%;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: clamp(0.875rem, 0.5rem + 1vw, 1rem);
}

body {
  font-family: "Inter", "SF Pro Display", "Segoe UI", system-ui, sans-serif;
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  line-height: 1.6;
  min-height: 100vh;
  text-rendering: optimizeLegibility;
}

img,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
  height: auto;
}

input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease-in-out;
}

ul,
ol {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Space Grotesk", "Montserrat", "Helvetica Neue", sans-serif;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0.02em;
  color: hsl(var(--text));
  overflow-wrap: break-word;
}

h1 {
  font-size: clamp(2rem, 5vw, 2.5rem);
  font-weight: 300;
}

h2 {
  font-size: clamp(1.375rem, 3vw, 1.75rem);
  font-weight: 400;
}

h3 {
  font-size: clamp(1.125rem, 2vw, 1.25rem);
  font-weight: 500;
}

p {
  overflow-wrap: break-word;
  color: hsl(var(--muted-foreground));
}

code,
kbd,
samp,
pre {
  font-family: "JetBrains Mono", "Fira Code", "SF Mono", "Consolas", monospace;
  font-size: 0.875rem;
}

.container {
  width: 100%;
  margin-inline: auto;
  padding-inline: 1.25rem;
}

@media (min-width: 768px) {
  .container {
    max-width: 720px;
  }
}

@media (min-width: 1024px) {
  .container {
    max-width: 960px;
  }
}

@media (min-width: 1440px) {
  .container {
    max-width: 1200px;
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 1.75rem;
  font-family: "Inter", sans-serif;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.btn-primary {
  background: linear-gradient(135deg, hsl(192 100% 50%) 0%, hsl(217 91% 60%) 100%);
  color: hsl(228 20% 4%);
  box-shadow: 0 0 20px rgba(0, 212, 255, 0.3);
}

.btn-primary:hover {
  box-shadow: 0 0 30px rgba(0, 212, 255, 0.5);
  transform: translateY(-2px);
}

.btn-secondary {
  background: transparent;
  border: 1px solid hsl(var(--primary));
  color: hsl(var(--primary));
}

.btn-secondary:hover {
  background: rgba(0, 212, 255, 0.1);
}

.btn-ghost {
  background: rgba(248, 250, 252, 0.03);
  color: hsl(var(--foreground));
  border: 1px solid rgba(248, 250, 252, 0.1);
}

.btn-ghost:hover {
  border-color: hsl(var(--muted-foreground));
}

.card {
  background: rgba(248, 250, 252, 0.03);
  border: 1px solid rgba(248, 250, 252, 0.08);
  border-radius: calc(var(--radius) * 1.5);
  padding: 2rem;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
  transition: all 0.3s ease-out;
}

.card:hover {
  border-color: rgba(0, 212, 255, 0.3);
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.input {
  width: 100%;
  padding: 0.75rem 1rem;
  background: rgba(10, 11, 15, 0.6);
  border: 1px solid rgba(248, 250, 252, 0.1);
  border-radius: var(--radius);
  font-size: 0.9375rem;
  color: hsl(var(--foreground));
  transition: all 0.2s ease-in-out;
}

.input:focus {
  outline: none;
  border-color: hsl(var(--primary));
  box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.1);
}

.input::placeholder {
  color: hsl(var(--muted-foreground));
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  background: rgba(248, 250, 252, 0.05);
  border: 1px solid rgba(248, 250, 252, 0.1);
  border-radius: calc(var(--radius) * 0.5);
  font-size: 0.6875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: hsl(var(--muted-foreground));
}

.badge-live {
  background: rgba(34, 197, 94, 0.15);
  color: #22C55E;
  border-color: rgba(34, 197, 94, 0.3);
}

.badge-live::before {
  content: '';
  width: 6px;
  height: 6px;
  background: #22C55E;
  border-radius: 50%;
  animation: pulse 2s infinite;
}

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

.text-gradient {
  background: linear-gradient(135deg, hsl(192 100% 50%) 0%, hsl(210 40% 98%) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.glow-cyan {
  box-shadow: 0 0 40px rgba(0, 212, 255, 0.3);
}

.glass {
  background: rgba(248, 250, 252, 0.03);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.focus-ring:focus-visible {
  outline: 2px solid hsl(var(--primary));
  outline-offset: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

.prose {
  --tw-prose-body: hsl(var(--text));
  --tw-prose-headings: hsl(var(--text));
  --tw-prose-lead: hsl(var(--muted-foreground));
  --tw-prose-links: hsl(var(--primary));
  --tw-prose-bold: hsl(var(--text));
  --tw-prose-counters: hsl(var(--muted-foreground));
  --tw-prose-bullets: hsl(var(--border));
  --tw-prose-hr: hsl(var(--border));
  --tw-prose-quotes: hsl(var(--text));
  --tw-prose-quote-borders: hsl(var(--border));
  --tw-prose-captions: hsl(var(--muted-foreground));
  --tw-prose-kbd: hsl(var(--text));
  --tw-prose-kbd-shadows: rgba(248, 250, 252, 0.1);
  --tw-prose-code: hsl(var(--text));
  --tw-prose-pre-code: hsl(var(--muted-foreground));
  --tw-prose-pre-bg: hsl(228 20% 8%);
  --tw-prose-th-borders: hsl(var(--border));
  --tw-prose-td-borders: hsl(var(--border));
  --tw-prose-invert-body: hsl(var(--text));
  --tw-prose-invert-headings: hsl(var(--text));
  --tw-prose-invert-lead: hsl(var(--muted-foreground));
  --tw-prose-invert-links: hsl(var(--primary));
  --tw-prose-invert-bold: hsl(var(--text));
  --tw-prose-invert-counters: hsl(var(--muted-foreground));
  --tw-prose-invert-bullets: hsl(var(--border));
  --tw-prose-invert-hr: hsl(var(--border));
  --tw-prose-invert-quotes: hsl(var(--text));
  --tw-prose-invert-quote-borders: hsl(var(--border));
  --tw-prose-invert-captions: hsl(var(--muted-foreground));
  --tw-prose-invert-kbd: hsl(var(--text));
  --tw-prose-invert-kbd-shadows: rgba(248, 250, 252, 0.1);
  --tw-prose-invert-code: hsl(var(--text));
  --tw-prose-invert-pre-code: hsl(var(--muted-foreground));
  --tw-prose-invert-pre-bg: rgba(0, 0, 0, 0.5);
  --tw-prose-invert-th-borders: hsl(var(--border));
  --tw-prose-invert-td-borders: hsl(var(--border));
  font-size: 1rem;
  line-height: 1.75;
}

.posts-archive-grid img {
  aspect-ratio: 16/9;
  object-fit: cover;
  border-radius: calc(var(--radius) * 0.75);
}